diff --git a/src/styles/globals.css b/src/styles/globals.css index 1e91f86ee..b1cc1edbb 100644 --- a/src/styles/globals.css +++ b/src/styles/globals.css @@ -63,3 +63,7 @@ dialog ::-webkit-scrollbar { ::-webkit-details-marker { display: none; } + +.chart + .chart { + margin-top: 2em; +} diff --git a/src/widgets/glances/components/chart.jsx b/src/widgets/glances/components/chart.jsx index f41e4d114..132fcc8e4 100644 --- a/src/widgets/glances/components/chart.jsx +++ b/src/widgets/glances/components/chart.jsx @@ -8,7 +8,7 @@ class Chart extends PureComponent { const { dataPoints, formatter, label } = this.props; return ( -
+
diff --git a/src/widgets/glances/components/chart_dual.jsx b/src/widgets/glances/components/chart_dual.jsx index 5cc5dea68..5fabe755a 100644 --- a/src/widgets/glances/components/chart_dual.jsx +++ b/src/widgets/glances/components/chart_dual.jsx @@ -8,7 +8,7 @@ class ChartDual extends PureComponent { const { dataPoints, formatter, stack, label, stackOffset } = this.props; return ( -
+
diff --git a/src/widgets/glances/components/container.jsx b/src/widgets/glances/components/container.jsx index 92d7a45d7..01a7e05d5 100644 --- a/src/widgets/glances/components/container.jsx +++ b/src/widgets/glances/components/container.jsx @@ -18,9 +18,9 @@ export default function Container({ children, widget, error = null, chart = true } return ( -
+
{children} -
+
{chart &&
} {!chart &&
}
diff --git a/src/widgets/glances/metrics/fs.jsx b/src/widgets/glances/metrics/fs.jsx index d1ff412c1..3285bd0e5 100644 --- a/src/widgets/glances/metrics/fs.jsx +++ b/src/widgets/glances/metrics/fs.jsx @@ -43,7 +43,7 @@ export default function Component({ service }) { return ( {chart && ( -
+
- + + {chart && ( +
+ )} + + {quicklookData && quicklookData.cpu_name && chart && (
{quicklookData.cpu_name}
)} @@ -124,7 +128,7 @@ export default function Component({ service }) {
{chart && ( - + {systemData && systemData.linux_distro &&
{systemData.linux_distro}
} {systemData && systemData.os_version &&
{systemData.os_version}
} {systemData && systemData.hostname &&
{systemData.hostname}
} @@ -137,7 +141,7 @@ export default function Component({ service }) {
)} - + {chart && } {chart && } diff --git a/src/widgets/glances/metrics/process.jsx b/src/widgets/glances/metrics/process.jsx index b20b4c634..997948f41 100644 --- a/src/widgets/glances/metrics/process.jsx +++ b/src/widgets/glances/metrics/process.jsx @@ -42,10 +42,16 @@ export default function Component({ service }) { } data.splice(chart ? 5 : 1); + let headerYPosition = "top-4"; + let listYPosition = "bottom-4"; + if (chart) { + headerYPosition = "-top-6"; + listYPosition = "-top-3"; + } return ( - +
{t("resources.cpu")}
@@ -53,7 +59,7 @@ export default function Component({ service }) {
- +
{data.map((item) => (