From 875647577ac29b3bc1beac282e33733a7491410c Mon Sep 17 00:00:00 2001 From: Daniel Valdivia <18384552+dvaldivia@users.noreply.github.com> Date: Mon, 13 Sep 2021 15:29:19 -0700 Subject: [PATCH] Dashboard MinIO Version Icon (#1037) Signed-off-by: Daniel Valdivia <18384552+dvaldivia@users.noreply.github.com> --- portal-ui/src/icons/VersionIcon.tsx | 35 +++++++++++++++++++ portal-ui/src/icons/index.ts | 1 + .../BasicDashboard/BasicDashboard.tsx | 3 +- 3 files changed, 38 insertions(+), 1 deletion(-) create mode 100644 portal-ui/src/icons/VersionIcon.tsx diff --git a/portal-ui/src/icons/VersionIcon.tsx b/portal-ui/src/icons/VersionIcon.tsx new file mode 100644 index 000000000..ae6c4edc8 --- /dev/null +++ b/portal-ui/src/icons/VersionIcon.tsx @@ -0,0 +1,35 @@ +// This file is part of MinIO Console Server +// Copyright (c) 2021 MinIO, Inc. +// +// This program is free software: you can redistribute it and/or modify +// it under the terms of the GNU Affero General Public License as published by +// the Free Software Foundation, either version 3 of the License, or +// (at your option) any later version. +// +// This program is distributed in the hope that it will be useful, +// but WITHOUT ANY WARRANTY; without even the implied warranty of +// MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +// GNU Affero General Public License for more details. +// +// You should have received a copy of the GNU Affero General Public License +// along with this program. If not, see . + +import * as React from "react"; +import { SvgIcon, SvgIconProps } from "@material-ui/core"; + +const VersionIcon = (props: SvgIconProps) => { + return ( + + + + + + ); +}; + +export default VersionIcon; diff --git a/portal-ui/src/icons/index.ts b/portal-ui/src/icons/index.ts index ded193e54..1e9bef356 100644 --- a/portal-ui/src/icons/index.ts +++ b/portal-ui/src/icons/index.ts @@ -76,3 +76,4 @@ export { default as TotalObjectsIcon } from "./TotalObjectsIcon"; export { default as CircleIcon } from "./CircleIcon"; export { default as PreviewIcon } from "./PreviewIcon"; export { default as LockIcon } from "./LockIcon"; +export { default as VersionIcon } from "./VersionIcon"; diff --git a/portal-ui/src/screens/Console/Dashboard/BasicDashboard/BasicDashboard.tsx b/portal-ui/src/screens/Console/Dashboard/BasicDashboard/BasicDashboard.tsx index 9181c008d..8f8f6703d 100644 --- a/portal-ui/src/screens/Console/Dashboard/BasicDashboard/BasicDashboard.tsx +++ b/portal-ui/src/screens/Console/Dashboard/BasicDashboard/BasicDashboard.tsx @@ -28,6 +28,7 @@ import { ServersIcon, StorageIcon, TotalObjectsIcon, + VersionIcon, } from "../../../../icons"; import { Card, CardHeader } from "@material-ui/core"; @@ -143,7 +144,7 @@ const BasicDashboard = ({ classes, usage }: IDashboardProps) => { {usage ? usage.servers.length !== 0 && ( } + avatar={} title="MinIO Version" subheader={usage ? usage.servers[0].version : 0} />