mirror of
https://github.com/karl0ss/homepage.git
synced 2025-05-01 21:13:39 +01:00
FIx: glances containers header position (#4496)
This commit is contained in:
parent
f717e59085
commit
e4d42b5393
@ -38,10 +38,16 @@ export default function Component({ service }) {
|
|||||||
}
|
}
|
||||||
|
|
||||||
data.splice(chart ? 5 : 1);
|
data.splice(chart ? 5 : 1);
|
||||||
|
let headerYPosition = "top-4";
|
||||||
|
let listYPosition = "bottom-4";
|
||||||
|
if (chart) {
|
||||||
|
headerYPosition = "-top-6";
|
||||||
|
listYPosition = "-top-3";
|
||||||
|
}
|
||||||
|
|
||||||
return (
|
return (
|
||||||
<Container chart={chart}>
|
<Container chart={chart}>
|
||||||
<Block position="top-4 right-3 left-3">
|
<Block position={`${headerYPosition} right-3 left-3`}>
|
||||||
<div className="flex items-center text-xs">
|
<div className="flex items-center text-xs">
|
||||||
<div className="grow" />
|
<div className="grow" />
|
||||||
<div className="w-14 text-right italic">{t("resources.cpu")}</div>
|
<div className="w-14 text-right italic">{t("resources.cpu")}</div>
|
||||||
@ -49,7 +55,7 @@ export default function Component({ service }) {
|
|||||||
</div>
|
</div>
|
||||||
</Block>
|
</Block>
|
||||||
|
|
||||||
<Block position="bottom-4 right-3 left-3">
|
<Block position={`${listYPosition} right-3 left-3`}>
|
||||||
<div className="pointer-events-none text-theme-900 dark:text-theme-200">
|
<div className="pointer-events-none text-theme-900 dark:text-theme-200">
|
||||||
{data.map((item) => (
|
{data.map((item) => (
|
||||||
<div key={item[idKey]} className="text-[0.75rem] h-[0.8rem]">
|
<div key={item[idKey]} className="text-[0.75rem] h-[0.8rem]">
|
||||||
|
Loading…
x
Reference in New Issue
Block a user