+
+ );
+ };
+
+ return (
+
+
+ {metricValue !== "" && (
+ }
+ subheader={
+
+
+
+ }
+ classes={{
+ root: subStyles.root,
+ title: subStyles.title,
+ content: subStyles.content,
+ }}
+ />
+ )}
+
+
+ );
+};
+
+export default withStyles(styles)(CommonCard);
diff --git a/portal-ui/src/screens/Console/Dashboard/Prometheus/Widgets/SimpleWidget.tsx b/portal-ui/src/screens/Console/Dashboard/Prometheus/Widgets/SimpleWidget.tsx
new file mode 100644
index 000000000..c36ad27fd
--- /dev/null
+++ b/portal-ui/src/screens/Console/Dashboard/Prometheus/Widgets/SimpleWidget.tsx
@@ -0,0 +1,60 @@
+// 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 React from "react";
+import { createStyles, Theme, withStyles } from "@material-ui/core/styles";
+
+interface ISimpleWidget {
+ classes: any;
+ iconWidget: any;
+ label: string;
+ value: string;
+}
+
+const styles = (theme: Theme) =>
+ createStyles({
+ mainWidgetContainer: {
+ display: "inline-flex",
+ color: "#072A4D",
+ alignItems: "center",
+ },
+ icon: {
+ color: "#072A4D",
+ fill: "#072A4D",
+ marginRight: 5,
+ marginLeft: 12,
+ },
+ widgetLabel: {
+ fontWeight: "bold",
+ textTransform: "uppercase",
+ marginRight: 10,
+ },
+ widgetValue: {
+ marginRight: 25,
+ }
+ });
+
+const SimpleWidget = ({ classes, iconWidget, label, value }: ISimpleWidget) => {
+ return (
+
+ {iconWidget ? iconWidget : null}
+ {label}:
+ {value}
+
+ );
+};
+
+export default withStyles(styles)(SimpleWidget);
diff --git a/portal-ui/src/screens/Console/Tenants/TenantDetails/hop/Hop.tsx b/portal-ui/src/screens/Console/Tenants/TenantDetails/hop/Hop.tsx
index 197d0ba0a..4d602b14c 100644
--- a/portal-ui/src/screens/Console/Tenants/TenantDetails/hop/Hop.tsx
+++ b/portal-ui/src/screens/Console/Tenants/TenantDetails/hop/Hop.tsx
@@ -106,7 +106,7 @@ const Hop = ({ classes, match }: IHopSimple) => {
const next = `${loc}${add}cp=y`;
consoleFrame.current.contentDocument.location.replace(next);
} else {
- consoleFrame.current.contentDocument.location.reload(true);
+ consoleFrame.current.contentDocument.location.reload();
}
}
}}
diff --git a/portal-ui/yarn.lock b/portal-ui/yarn.lock
index e874d8028..f4ed30cb5 100644
--- a/portal-ui/yarn.lock
+++ b/portal-ui/yarn.lock
@@ -9306,10 +9306,10 @@ prepend-http@^1.0.0:
resolved "https://registry.yarnpkg.com/prepend-http/-/prepend-http-1.0.4.tgz#d4f4562b0ce3696e41ac52d0e002e57a635dc6dc"
integrity sha1-1PRWKwzjaW5BrFLQ4ALlemNdxtw=
-prettier@2.3.1:
- version "2.3.1"
- resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.3.1.tgz#76903c3f8c4449bc9ac597acefa24dc5ad4cbea6"
- integrity sha512-p+vNbgpLjif/+D+DwAZAbndtRrR0md0MwfmOVN9N+2RgyACMT+7tfaRnT+WDPkqnuVwleyuBIG2XBxKDme3hPA==
+prettier@2.3.2:
+ version "2.3.2"
+ resolved "https://registry.yarnpkg.com/prettier/-/prettier-2.3.2.tgz#ef280a05ec253712e486233db5c6f23441e7342d"
+ integrity sha512-lnJzDfJ66zkMy58OL5/NY5zp70S7Nz6KqcKkXYzn2tMVrNxvbqaBpg7H3qHaLxCJ5lNMsGuM8+ohS7cZrthdLQ==
pretty-bytes@^5.3.0:
version "5.6.0"
@@ -11499,10 +11499,10 @@ typeface-roboto@^0.0.75:
resolved "https://registry.yarnpkg.com/typeface-roboto/-/typeface-roboto-0.0.75.tgz#98d5ba35ec234bbc7172374c8297277099cc712b"
integrity sha512-VrR/IiH00Z1tFP4vDGfwZ1esNqTiDMchBEXYY9kilT6wRGgFoCAlgkEUMHb1E3mB0FsfZhv756IF0+R+SFPfdg==
-typescript@^4.3.2:
- version "4.3.2"
- resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.3.2.tgz#399ab18aac45802d6f2498de5054fcbbe716a805"
- integrity sha512-zZ4hShnmnoVnAHpVHWpTcxdv7dWP60S2FsydQLV8V5PbS3FifjWFFRiHSWpDJahly88PRyV5teTSLoq4eG7mKw==
+typescript@^4.4.3:
+ version "4.4.3"
+ resolved "https://registry.yarnpkg.com/typescript/-/typescript-4.4.3.tgz#bdc5407caa2b109efd4f82fe130656f977a29324"
+ integrity sha512-4xfscpisVgqqDfPaJo5vkd+Qd/ItkoagnHpufr+i2QCHBsNYp+G7UAoyFl8aPtx879u38wPV65rZ8qbGZijalA==
unbox-primitive@^1.0.1:
version "1.0.1"