extract strings
This commit is contained in:
1 parent
fc9d2fe69d
commit
f10fb452ba
4 files changed
+27
-12
No files matched your search
@@ -44,7 +44,7 @@ export const DockerContainersTable = ({ containers }: DockerContainersTableProps
|
||||
const headers: Header<DockerContainerInfo>[] = [
|
||||
{
|
||||
id: "container",
|
||||
content: "Containers",
|
||||
content: t("pages.docker.host.table.headers.container"),
|
||||
render: (row) => {
|
||||
return (
|
||||
<DockerStateLabel
|
||||
@@ -57,35 +57,35 @@ export const DockerContainersTable = ({ containers }: DockerContainersTableProps
|
||||
},
|
||||
{
|
||||
id: "status",
|
||||
content: "Status",
|
||||
content: t("common.table.headers.status"),
|
||||
render: (row) => {
|
||||
return <Typography>{row.state}</Typography>;
|
||||
},
|
||||
},
|
||||
{
|
||||
id: "health",
|
||||
content: "Health",
|
||||
content: t("pages.docker.host.table.headers.health"),
|
||||
render: (row) => {
|
||||
return <Typography>{row.health}</Typography>;
|
||||
},
|
||||
},
|
||||
{
|
||||
id: "cpu",
|
||||
content: "CPU",
|
||||
content: t("pages.docker.host.table.headers.cpu"),
|
||||
render: (row) => {
|
||||
return <Typography>{formatPercentage(row.cpuPct ?? 0)}</Typography>;
|
||||
},
|
||||
},
|
||||
{
|
||||
id: "memory",
|
||||
content: "Memory",
|
||||
content: t("pages.docker.host.table.headers.memory"),
|
||||
render: (row) => {
|
||||
return <Typography>{formatPercentage(row.memoryPct ?? 0)}</Typography>;
|
||||
},
|
||||
},
|
||||
{
|
||||
id: "restarts",
|
||||
content: "Restarts",
|
||||
content: t("pages.docker.host.table.headers.restarts"),
|
||||
render: (row) => {
|
||||
return <Typography>{row.restartCount}</Typography>;
|
||||
},
|
||||
|
||||
@@ -9,7 +9,6 @@ import { useTheme } from "@mui/material";
|
||||
import { useTranslation } from "react-i18next";
|
||||
|
||||
// Utils
|
||||
import prettyBytes from "pretty-bytes";
|
||||
|
||||
export const DockerStatusBoxes = ({ stats }: { stats: DockerStats | undefined }) => {
|
||||
const { t } = useTranslation();
|
||||
@@ -26,21 +25,21 @@ export const DockerStatusBoxes = ({ stats }: { stats: DockerStats | undefined })
|
||||
flexWrap={"wrap"}
|
||||
>
|
||||
<StatBox
|
||||
title={"Containers"}
|
||||
title={t("pages.docker.host.statBoxes.containers")}
|
||||
subtitle={String(total)}
|
||||
/>
|
||||
<StatBox
|
||||
title={"Running"}
|
||||
title={t("pages.docker.host.statBoxes.running")}
|
||||
subtitle={String(running)}
|
||||
/>
|
||||
|
||||
<StatBox
|
||||
title={"Stopped"}
|
||||
title={t("pages.docker.host.statBoxes.stopped")}
|
||||
subtitle={String(stopped)}
|
||||
/>
|
||||
|
||||
<StatBox
|
||||
title={"Unhealthy"}
|
||||
title={t("pages.docker.host.statBoxes.unhealthy")}
|
||||
subtitle={String(unhealthy)}
|
||||
/>
|
||||
</Stack>
|
||||
|
||||
@@ -2,7 +2,6 @@ import type { MonitorStatus, MonitorType } from "@/Types/Monitor";
|
||||
import type { PaletteKey } from "@/Utils/Theme/Theme";
|
||||
import type { ValueType } from "@/Components/design-elements/StatusLabel";
|
||||
import type { DockerContainerState } from "@/Types/Check";
|
||||
import type { Doc } from "zod/v4/core";
|
||||
|
||||
export const getMonitorPath = (type: MonitorType): string => {
|
||||
const pathMap: Record<MonitorType, string> = {
|
||||
|
||||
@@ -941,6 +941,23 @@
|
||||
"containers": "Containers"
|
||||
},
|
||||
"containersRunning": "{{running}} of {{total}} running"
|
||||
},
|
||||
"host": {
|
||||
"statBoxes": {
|
||||
"containers": "Containers",
|
||||
"running": "Running",
|
||||
"stopped": "Stopped",
|
||||
"unhealthy": "Unhealthy"
|
||||
},
|
||||
"table": {
|
||||
"headers": {
|
||||
"container": "Containers",
|
||||
"health": "Health",
|
||||
"cpu": "CPU",
|
||||
"memory": "Memory",
|
||||
"restarts": "Restarts"
|
||||
}
|
||||
}
|
||||
}
|
||||
},
|
||||
"infrastructure": {
|
||||
|
||||
Reference in new issue
Block a user