merge develop

This commit is contained in:
Alex Holliday committed 2026-08-31 10:26:38 -07:00
commit a7ee90e1ee
35 files changed
+859 -266

No files matched your search

+1 -1
View File
@@ -109,7 +109,7 @@ client/src/
- **Data Fetching**: SWR + Axios - **Data Fetching**: SWR + Axios
- **Database**: MongoDB with Mongoose ODM - **Database**: MongoDB with Mongoose ODM
- **Queue/Cache**: Redis + BullMQ + Pulse (cron scheduling) - **Queue/Cache**: Redis + BullMQ + Pulse (cron scheduling)
- **i18n**: i18next + react-i18next (translations via PoEditor) - **i18n**: i18next + react-i18next (non-English locales are machine translated, not managed through a translation service)
--- ---
+10 -1
View File
@@ -3,6 +3,7 @@ import Menu from "@mui/material/Menu";
import MenuItem from "@mui/material/MenuItem"; import MenuItem from "@mui/material/MenuItem";
import IconButton from "@mui/material/IconButton"; import IconButton from "@mui/material/IconButton";
import { Settings } from "lucide-react"; import { Settings } from "lucide-react";
import { useTheme } from "@mui/material/styles";
export type ActionMenuItem = { export type ActionMenuItem = {
id: number | string; id: number | string;
@@ -12,6 +13,7 @@ export type ActionMenuItem = {
}; };
export const ActionsMenu = ({ items }: { items: ActionMenuItem[] }) => { export const ActionsMenu = ({ items }: { items: ActionMenuItem[] }) => {
const theme = useTheme();
const [anchorEl, setAnchorEl] = useState<null | any>(null); const [anchorEl, setAnchorEl] = useState<null | any>(null);
const open = Boolean(anchorEl); const open = Boolean(anchorEl);
@@ -27,7 +29,14 @@ export const ActionsMenu = ({ items }: { items: ActionMenuItem[] }) => {
return ( return (
<div> <div>
<IconButton onClick={handleClick}> <IconButton
onClick={handleClick}
sx={{
"&:hover": {
backgroundColor: theme.palette.action.controlHover,
},
}}
>
<Settings <Settings
size={20} size={20}
strokeWidth={1.5} strokeWidth={1.5}
@@ -12,6 +12,7 @@ type BaseChartProps = React.PropsWithChildren<{
title: string; title: string;
width?: number | string; width?: number | string;
maxWidth?: number | string; maxWidth?: number | string;
flexBasis?: number | string;
padding?: number | string | ResponsiveStyleValue<number | string>; padding?: number | string | ResponsiveStyleValue<number | string>;
onClick?: () => void; onClick?: () => void;
}>; }>;
@@ -21,6 +22,7 @@ export const BaseChart = ({
title, title,
width = "100%", width = "100%",
maxWidth = "100%", maxWidth = "100%",
flexBasis = "0%",
padding, padding,
onClick, onClick,
}: BaseChartProps) => { }: BaseChartProps) => {
@@ -32,6 +34,7 @@ export const BaseChart = ({
padding: padding ?? theme.spacing(LAYOUT.MD), padding: padding ?? theme.spacing(LAYOUT.MD),
display: "flex", display: "flex",
flex: 1, flex: 1,
flexBasis,
width: width, width: width,
maxWidth: maxWidth, maxWidth: maxWidth,
...(onClick && { ...(onClick && {
@@ -39,9 +39,9 @@ export const Gauge = forwardRef<HTMLDivElement, GaugeProps>(function Gauge(
() => ({ () => ({
circumference: 2 * Math.PI * radius, circumference: 2 * Math.PI * radius,
totalSize: radius * 2 + strokeWidth * 2, totalSize: radius * 2 + strokeWidth * 2,
strokeLength: (progress / 100) * (2 * Math.PI * radius), strokeLength: (progressWithinRange / 100) * (2 * Math.PI * radius),
}), }),
[radius, strokeWidth, progress] [radius, strokeWidth, progressWithinRange]
); );
const [offset, setOffset] = useState(circumference); const [offset, setOffset] = useState(circumference);
@@ -52,7 +52,7 @@ export const Gauge = forwardRef<HTMLDivElement, GaugeProps>(function Gauge(
}, 100); }, 100);
return () => clearTimeout(timer); return () => clearTimeout(timer);
}, [progress, circumference, strokeLength]); }, [circumference, strokeLength]);
const fillColor = getInfraGaugeColor(progressWithinRange, theme); const fillColor = getInfraGaugeColor(progressWithinRange, theme);
@@ -123,6 +123,7 @@ export const DetailGauge = ({
lowerLabel, lowerLabel,
lowerValue, lowerValue,
maxWidth = 225, maxWidth = 225,
flexBasis = "0%",
}: { }: {
title: string; title: string;
progress: number; progress: number;
@@ -131,6 +132,7 @@ export const DetailGauge = ({
lowerLabel?: string; lowerLabel?: string;
lowerValue?: string | number; lowerValue?: string | number;
maxWidth?: number; maxWidth?: number;
flexBasis?: number | string;
}) => { }) => {
const theme = useTheme(); const theme = useTheme();
return ( return (
@@ -138,6 +140,7 @@ export const DetailGauge = ({
icon={null} icon={null}
title={title} title={title}
maxWidth={maxWidth} maxWidth={maxWidth}
flexBasis={flexBasis}
> >
<Stack <Stack
alignItems={"center"} alignItems={"center"}
@@ -11,9 +11,10 @@ import type { SxProps } from "@mui/material";
type GradientBox = React.PropsWithChildren<{ type GradientBox = React.PropsWithChildren<{
palette?: PaletteKey; palette?: PaletteKey;
sx?: SxProps; sx?: SxProps;
interactive?: boolean;
}>; }>;
export const GradientBox = ({ children, palette, sx }: GradientBox) => { export const GradientBox = ({ children, palette, sx, interactive }: GradientBox) => {
const theme = useTheme(); const theme = useTheme();
const isSmall = useMediaQuery(theme.breakpoints.down("md")); const isSmall = useMediaQuery(theme.breakpoints.down("md"));
const isLight = theme.palette.mode === "light"; const isLight = theme.palette.mode === "light";
@@ -30,6 +31,12 @@ export const GradientBox = ({ children, palette, sx }: GradientBox) => {
padding: `${theme.spacing(4)} ${theme.spacing(8)}`, padding: `${theme.spacing(4)} ${theme.spacing(8)}`,
width: isSmall ? `100%` : `calc(25% - (3 * ${theme.spacing(8)} / 4))`, width: isSmall ? `100%` : `calc(25% - (3 * ${theme.spacing(8)} / 4))`,
background: bg, background: bg,
...(interactive && {
cursor: "pointer",
"&:hover": {
backgroundImage: `linear-gradient(${theme.palette.action.rowHover}, ${theme.palette.action.rowHover}), ${bg}`,
},
}),
...sx, ...sx,
}} }}
> >
@@ -62,10 +69,8 @@ export const StatBox = ({
return ( return (
<GradientBox <GradientBox
palette={palette} palette={palette}
sx={{ interactive={Boolean(onClick)}
...(sx as object), sx={{ ...(sx as object) }}
...(onClick ? { cursor: "pointer", "&:hover": { opacity: 0.95 } } : {}),
}}
> >
<Stack onClick={onClick}> <Stack onClick={onClick}>
<Box sx={{ display: "flex", alignItems: "center", gap: theme.spacing(2) }}> <Box sx={{ display: "flex", alignItems: "center", gap: theme.spacing(2) }}>
@@ -79,6 +79,7 @@ export function DataTable<
}; };
const isSmall = useMediaQuery(theme.breakpoints.down("md")); const isSmall = useMediaQuery(theme.breakpoints.down("md"));
const isInteractive = Boolean(onRowClick) || expandableRows;
if (data.length === 0 || headers.length === 0) { if (data.length === 0 || headers.length === 0) {
return ( return (
@@ -108,6 +109,11 @@ export function DataTable<
borderRadius: theme.shape.borderRadius, borderRadius: theme.shape.borderRadius,
padding: theme.spacing(LAYOUT.XS), padding: theme.spacing(LAYOUT.XS),
cursor: onRowClick ? "pointer" : "default", cursor: onRowClick ? "pointer" : "default",
...(onRowClick && {
"&:hover": {
backgroundColor: theme.palette.action.rowHover,
},
}),
}} }}
key={key} key={key}
> >
@@ -207,6 +213,10 @@ export function DataTable<
"& .MuiTableBody-root .MuiTableRow-root:last-child .MuiTableCell-root": { "& .MuiTableBody-root .MuiTableRow-root:last-child .MuiTableCell-root": {
borderBottom: "none", borderBottom: "none",
}, },
"& .MuiTableBody-root .MuiTableRow-root.is-clickable:hover .MuiTableCell-root":
{
backgroundColor: theme.palette.action.rowHover,
},
}} }}
> >
<TableHead> <TableHead>
@@ -231,8 +241,9 @@ export function DataTable<
return ( return (
<Fragment key={key}> <Fragment key={key}>
<TableRow <TableRow
className={isInteractive ? "is-clickable" : undefined}
sx={{ sx={{
cursor: onRowClick ? "pointer" : "default", cursor: isInteractive ? "pointer" : "default",
...(getRowSx?.(row) as object), ...(getRowSx?.(row) as object),
}} }}
onClick={() => { onClick={() => {
@@ -292,6 +303,12 @@ interface TablePaginationActionsProps {
onPageChange: (event: React.MouseEvent<HTMLButtonElement>, newPage: number) => void; onPageChange: (event: React.MouseEvent<HTMLButtonElement>, newPage: number) => void;
} }
const controlHoverSx = (theme: Theme): SxProps<Theme> => ({
"&:hover": {
backgroundColor: theme.palette.action.controlHover,
},
});
function TablePaginationActions(props: TablePaginationActionsProps) { function TablePaginationActions(props: TablePaginationActionsProps) {
const theme = useTheme(); const theme = useTheme();
const { count, page, rowsPerPage, onPageChange } = props; const { count, page, rowsPerPage, onPageChange } = props;
@@ -321,6 +338,7 @@ function TablePaginationActions(props: TablePaginationActionsProps) {
onClick={handleFirstPageButtonClick} onClick={handleFirstPageButtonClick}
disabled={page === 0} disabled={page === 0}
aria-label="first page" aria-label="first page"
sx={controlHoverSx(theme)}
> >
{theme.direction === "rtl" ? ( {theme.direction === "rtl" ? (
<ChevronsRight <ChevronsRight
@@ -338,6 +356,7 @@ function TablePaginationActions(props: TablePaginationActionsProps) {
onClick={handleBackButtonClick} onClick={handleBackButtonClick}
disabled={page === 0} disabled={page === 0}
aria-label="previous page" aria-label="previous page"
sx={controlHoverSx(theme)}
> >
{theme.direction === "rtl" ? ( {theme.direction === "rtl" ? (
<ChevronRight <ChevronRight
@@ -355,6 +374,7 @@ function TablePaginationActions(props: TablePaginationActionsProps) {
onClick={handleNextButtonClick} onClick={handleNextButtonClick}
disabled={page >= Math.ceil(count / rowsPerPage) - 1} disabled={page >= Math.ceil(count / rowsPerPage) - 1}
aria-label="next page" aria-label="next page"
sx={controlHoverSx(theme)}
> >
{theme.direction === "rtl" ? ( {theme.direction === "rtl" ? (
<ChevronLeft <ChevronLeft
@@ -372,6 +392,7 @@ function TablePaginationActions(props: TablePaginationActionsProps) {
onClick={handleLastPageButtonClick} onClick={handleLastPageButtonClick}
disabled={page >= Math.ceil(count / rowsPerPage) - 1} disabled={page >= Math.ceil(count / rowsPerPage) - 1}
aria-label="last page" aria-label="last page"
sx={controlHoverSx(theme)}
> >
{theme.direction === "rtl" ? ( {theme.direction === "rtl" ? (
<ChevronsLeft <ChevronsLeft
@@ -419,6 +440,7 @@ function HasMoreTablePaginationActions(props: HasMoreTablePaginationActionsProps
onClick={handleFirstPageButtonClick} onClick={handleFirstPageButtonClick}
disabled={page === 0} disabled={page === 0}
aria-label="first page" aria-label="first page"
sx={controlHoverSx(theme)}
> >
{theme.direction === "rtl" ? ( {theme.direction === "rtl" ? (
<ChevronsRight <ChevronsRight
@@ -436,6 +458,7 @@ function HasMoreTablePaginationActions(props: HasMoreTablePaginationActionsProps
onClick={handleBackButtonClick} onClick={handleBackButtonClick}
disabled={page === 0} disabled={page === 0}
aria-label="previous page" aria-label="previous page"
sx={controlHoverSx(theme)}
> >
{theme.direction === "rtl" ? ( {theme.direction === "rtl" ? (
<ChevronRight <ChevronRight
@@ -453,6 +476,7 @@ function HasMoreTablePaginationActions(props: HasMoreTablePaginationActionsProps
onClick={handleNextButtonClick} onClick={handleNextButtonClick}
disabled={hasMore === false} disabled={hasMore === false}
aria-label="next page" aria-label="next page"
sx={controlHoverSx(theme)}
> >
{theme.direction === "rtl" ? ( {theme.direction === "rtl" ? (
<ChevronLeft <ChevronLeft
@@ -470,6 +494,7 @@ function HasMoreTablePaginationActions(props: HasMoreTablePaginationActionsProps
<IconButton <IconButton
disabled={hasMore === false} disabled={hasMore === false}
aria-label="next page" aria-label="next page"
sx={controlHoverSx(theme)}
> >
<Ellipsis <Ellipsis
size={20} size={20}
+46 -26
View File
@@ -23,6 +23,9 @@ import {
} from "lucide-react"; } from "lucide-react";
export const getMenu = (t: Function) => { export const getMenu = (t: Function) => {
return [ return [
{
group: t("components.sidebar.menu.groups.monitoring"),
items: [
{ {
name: t("components.sidebar.menu.uptime"), name: t("components.sidebar.menu.uptime"),
path: "uptime", path: "uptime",
@@ -43,11 +46,51 @@ export const getMenu = (t: Function) => {
path: "docker", path: "docker",
icon: <Icon icon={Container} />, icon: <Icon icon={Container} />,
}, },
],
},
{
group: t("components.sidebar.menu.groups.alerting"),
items: [
{
name: t("components.sidebar.menu.incidents"),
path: "incidents",
icon: <Icon icon={AlertTriangle} />,
},
{ {
name: t("components.sidebar.menu.notifications"), name: t("components.sidebar.menu.notifications"),
path: "notifications", path: "notifications",
icon: <Icon icon={Bell} />, icon: <Icon icon={Bell} />,
}, },
{
name: t("components.sidebar.menu.maintenance"),
path: "maintenance",
icon: <Icon icon={Wrench} />,
},
],
},
{
group: t("components.sidebar.menu.groups.reporting"),
items: [
{
name: t("components.sidebar.menu.statusPages"),
path: "status",
icon: <Icon icon={Wifi} />,
},
{
name: t("components.sidebar.menu.checks"),
path: "checks",
icon: <Icon icon={FileText} />,
},
{
name: t("components.sidebar.menu.logs"),
path: "logs",
icon: <Icon icon={ScrollText} />,
},
],
},
{
group: t("components.sidebar.menu.groups.configuration"),
items: [
{ {
name: t("components.sidebar.menu.tags"), name: t("components.sidebar.menu.tags"),
path: "tags", path: "tags",
@@ -58,35 +101,12 @@ export const getMenu = (t: Function) => {
path: "proxies", path: "proxies",
icon: <Icon icon={Waypoints} />, icon: <Icon icon={Waypoints} />,
}, },
{
name: t("components.sidebar.menu.checks"),
path: "checks",
icon: <Icon icon={FileText} />,
},
{
name: t("components.sidebar.menu.incidents"),
path: "incidents",
icon: <Icon icon={AlertTriangle} />,
},
{
name: t("components.sidebar.menu.statusPages"),
path: "status",
icon: <Icon icon={Wifi} />,
},
{
name: t("components.sidebar.menu.maintenance"),
path: "maintenance",
icon: <Icon icon={Wrench} />,
},
{
name: t("components.sidebar.menu.logs"),
path: "logs",
icon: <Icon icon={ScrollText} />,
},
{ {
name: t("components.sidebar.menu.settings"), name: t("components.sidebar.menu.settings"),
icon: <Icon icon={Settings} />,
path: "settings", path: "settings",
icon: <Icon icon={Settings} />,
},
],
}, },
]; ];
}; };
+40 -2
View File
@@ -1,9 +1,12 @@
import { useEffect } from "react"; import { useEffect } from "react";
import Backdrop from "@mui/material/Backdrop"; import Backdrop from "@mui/material/Backdrop";
import Stack from "@mui/material/Stack"; import Stack from "@mui/material/Stack";
import Box from "@mui/material/Box";
import Typography from "@mui/material/Typography";
import List from "@mui/material/List"; import List from "@mui/material/List";
import Divider from "@mui/material/Divider"; import Divider from "@mui/material/Divider";
import { LAYOUT } from "@/Utils/Theme/constants"; import { LAYOUT } from "@/Utils/Theme/constants";
import { typographyLevels } from "@/Utils/Theme/Palette";
import { useSidebar } from "@/Hooks/useSidebar.js"; import { useSidebar } from "@/Hooks/useSidebar.js";
import { Logo } from "@/Components/sidebar/Logo"; import { Logo } from "@/Components/sidebar/Logo";
import { getMenu, getAccountMenu } from "@/Components/sidebar/Menu"; import { getMenu, getAccountMenu } from "@/Components/sidebar/Menu";
@@ -29,7 +32,7 @@ export const Sidebar = () => {
const navigate = useNavigate(); const navigate = useNavigate();
const location = useLocation(); const location = useLocation();
const { t } = useTranslation(); const { t } = useTranslation();
const { width, transition, collapsed } = useSidebar(); const { width, transition, transitionTiming, collapsed } = useSidebar();
const theme = useTheme(); const theme = useTheme();
const isSmall = useMediaQuery(theme.breakpoints.down("md")); const isSmall = useMediaQuery(theme.breakpoints.down("md"));
const menu = getMenu(t); const menu = getMenu(t);
@@ -89,7 +92,40 @@ export const Sidebar = () => {
pt={theme.spacing(LAYOUT.MD)} pt={theme.spacing(LAYOUT.MD)}
pb={theme.spacing(LAYOUT.MD)} pb={theme.spacing(LAYOUT.MD)}
/> />
{menu.map((item) => { {menu.map((group) => (
<Box key={group.group}>
<Box
position="relative"
overflow="hidden"
>
<Typography
variant="eyebrow"
component="div"
color={theme.palette.text.disabled}
fontSize={typographyLevels.s}
paddingLeft={theme.spacing(5)}
paddingTop={theme.spacing(LAYOUT.SM)}
paddingBottom={theme.spacing(LAYOUT.XXS)}
whiteSpace="nowrap"
sx={{
opacity: collapsed ? 0 : 1,
transition: `opacity ${transitionTiming}`,
}}
>
{group.group}
</Typography>
<Divider
sx={{
position: "absolute",
top: "50%",
left: 0,
right: 0,
opacity: collapsed ? 1 : 0,
transition: `opacity ${transitionTiming}`,
}}
/>
</Box>
{group.items.map((item) => {
const selected = location.pathname.startsWith(`/${item.path}`); const selected = location.pathname.startsWith(`/${item.path}`);
return ( return (
<NavItem <NavItem
@@ -100,6 +136,8 @@ export const Sidebar = () => {
/> />
); );
})} })}
</Box>
))}
</List> </List>
<StarPrompt /> <StarPrompt />
+3 -1
View File
@@ -6,7 +6,8 @@ const SIDEBAR_WIDTH_VAR = 250;
const SIDEBAR_COLLAPSED_WIDTH_VAR = 64; const SIDEBAR_COLLAPSED_WIDTH_VAR = 64;
// Transition timing for sidebar width changes // Transition timing for sidebar width changes
const SIDEBAR_TRANSITION = "width 650ms cubic-bezier(0.36, -0.01, 0, 0.77)"; const SIDEBAR_TRANSITION_TIMING = "650ms cubic-bezier(0.36, -0.01, 0, 0.77)";
const SIDEBAR_TRANSITION = `width ${SIDEBAR_TRANSITION_TIMING}`;
export const useSidebar = () => { export const useSidebar = () => {
const collapsed = useSelector( const collapsed = useSelector(
@@ -19,6 +20,7 @@ export const useSidebar = () => {
expandedWidth: SIDEBAR_WIDTH_VAR, expandedWidth: SIDEBAR_WIDTH_VAR,
width: collapsed ? SIDEBAR_COLLAPSED_WIDTH_VAR : SIDEBAR_WIDTH_VAR, width: collapsed ? SIDEBAR_COLLAPSED_WIDTH_VAR : SIDEBAR_WIDTH_VAR,
transition: SIDEBAR_TRANSITION, transition: SIDEBAR_TRANSITION,
transitionTiming: SIDEBAR_TRANSITION_TIMING,
}; };
}; };
@@ -63,19 +63,42 @@ const getChartConfigs = (
return configs; return configs;
}; };
// Loopback / bridge names Capture sees when it can only observe the container's // Loopback / bridge names Capture reports when it can only observe the
// own network namespace. When ALL reported interfaces match this set we assume // container's own network namespace.
// the "no real interfaces visible" case and surface the notice.
const CONTAINER_ONLY_IFACE_NAMES = new Set(["lo", "lo0", "docker0"]); const CONTAINER_ONLY_IFACE_NAMES = new Set(["lo", "lo0", "docker0"]);
// Below this, an interface is carrying no traffic worth charting. Real host
// NICs sit orders of magnitude above it; a container's veth sits at or near
// zero.
const IDLE_INTERFACE_BYTES_PER_SECOND = 1024;
const interfaceIsIdle = (checks: HardwareCheckStats[], name: string): boolean =>
checks.every((check) => {
const iface = check.net?.find((candidate) => candidate.name === name);
if (!iface) {
return true;
}
return (
(iface.bytesSentPerSecond || 0) < IDLE_INTERFACE_BYTES_PER_SECOND &&
(iface.deltaBytesRecv || 0) < IDLE_INTERFACE_BYTES_PER_SECOND
);
});
const onlyContainerVisibleInterfaces = (checks: HardwareCheckStats[]): boolean => { const onlyContainerVisibleInterfaces = (checks: HardwareCheckStats[]): boolean => {
const named = new Set<string>(); const named = new Set<string>();
checks.forEach((c) => c.net?.forEach((iface) => named.add(iface.name))); checks.forEach((c) => c.net?.forEach((iface) => named.add(iface.name)));
if (named.size === 0) return false; if (named.size === 0) {
for (const name of named) { return false;
if (!CONTAINER_ONLY_IFACE_NAMES.has(name)) return false;
} }
const names = [...named];
if (names.every((name) => CONTAINER_ONLY_IFACE_NAMES.has(name))) {
return true; return true;
}
if (!names.some((name) => CONTAINER_ONLY_IFACE_NAMES.has(name))) {
return false;
}
return names.every((name) => interfaceIsIdle(checks, name));
}; };
export const InfraNetworkCharts = ({ export const InfraNetworkCharts = ({
@@ -8,6 +8,8 @@ import { useTheme } from "@mui/material";
import useMediaQuery from "@mui/material/useMediaQuery"; import useMediaQuery from "@mui/material/useMediaQuery";
import type { CheckSnapshot } from "@/Types/Check"; import type { CheckSnapshot } from "@/Types/Check";
const GAUGE_MAX_WIDTH = 260;
export const InfraDetailsGauges = ({ export const InfraDetailsGauges = ({
snapshot, snapshot,
}: { }: {
@@ -26,37 +28,42 @@ export const InfraDetailsGauges = ({
direction={isSmall ? "column" : "row"} direction={isSmall ? "column" : "row"}
spacing={theme.spacing(8)} spacing={theme.spacing(8)}
alignItems={"stretch"} alignItems={"stretch"}
flexWrap={"wrap"}
useFlexGap
> >
<DetailGauge <DetailGauge
title={t("pages.infrastructure.gauges.memory.title")} title={t("pages.infrastructure.gauges.memory.title")}
maxWidth={260} maxWidth={GAUGE_MAX_WIDTH}
progress={(snapshot?.memory?.usage_percent || 0) * 100} progress={(snapshot?.memory?.usage_percent || 0) * 100}
upperLabel={t("pages.infrastructure.gauges.memory.upperLabel")} upperLabel={t("pages.infrastructure.gauges.memory.upperLabel")}
upperValue={prettyBytes(snapshot?.memory?.used_bytes || 0)} upperValue={prettyBytes(snapshot?.memory?.used_bytes || 0)}
lowerLabel={t("pages.infrastructure.gauges.memory.lowerLabel")} lowerLabel={t("pages.infrastructure.gauges.memory.lowerLabel")}
lowerValue={prettyBytes(snapshot?.memory?.total_bytes || 0)} lowerValue={prettyBytes(snapshot?.memory?.total_bytes || 0)}
flexBasis={isSmall ? "auto" : GAUGE_MAX_WIDTH}
/> />
<DetailGauge <DetailGauge
title={t("pages.infrastructure.gauges.cpu.title")} title={t("pages.infrastructure.gauges.cpu.title")}
maxWidth={260} maxWidth={GAUGE_MAX_WIDTH}
progress={(snapshot?.cpu?.usage_percent || 0) * 100} progress={(snapshot?.cpu?.usage_percent || 0) * 100}
upperLabel={t("pages.infrastructure.gauges.cpu.upperLabel")} upperLabel={t("pages.infrastructure.gauges.cpu.upperLabel")}
upperValue={getFrequency(snapshot?.cpu?.current_frequency || 0)} upperValue={getFrequency(snapshot?.cpu?.current_frequency || 0)}
lowerLabel={t("pages.infrastructure.gauges.cpu.lowerLabel")} lowerLabel={t("pages.infrastructure.gauges.cpu.lowerLabel")}
lowerValue={getFrequency(snapshot?.cpu?.frequency || 0)} lowerValue={getFrequency(snapshot?.cpu?.frequency || 0)}
flexBasis={isSmall ? "auto" : GAUGE_MAX_WIDTH}
/> />
{snapshot?.disk?.map((disk, idx) => { {snapshot?.disk?.map((disk, idx) => {
return ( return (
<DetailGauge <DetailGauge
key={disk?.device || 0 + idx} key={disk?.device || `disk-${idx}`}
// title={`Disk ${idx} usage`} // title={`Disk ${idx} usage`}
title={t("pages.infrastructure.gauges.disk.title", { idx })} title={t("pages.infrastructure.gauges.disk.title", { idx })}
maxWidth={260} maxWidth={GAUGE_MAX_WIDTH}
progress={(disk.usage_percent || 0) * 100} progress={(disk.usage_percent || 0) * 100}
upperLabel={t("pages.infrastructure.gauges.disk.upperLabel")} upperLabel={t("pages.infrastructure.gauges.disk.upperLabel")}
upperValue={prettyBytes(disk?.used_bytes || 0)} upperValue={prettyBytes(disk?.used_bytes || 0)}
lowerLabel={t("pages.infrastructure.gauges.disk.lowerLabel")} lowerLabel={t("pages.infrastructure.gauges.disk.lowerLabel")}
lowerValue={prettyBytes(disk?.total_bytes || 0)} lowerValue={prettyBytes(disk?.total_bytes || 0)}
flexBasis={isSmall ? "auto" : GAUGE_MAX_WIDTH}
/> />
); );
})} })}
+24 -1
View File
@@ -1,7 +1,8 @@
import Stack from "@mui/material/Stack"; import Stack from "@mui/material/Stack";
import Typography from "@mui/material/Typography";
import { logger } from "@/Utils/logger"; import { logger } from "@/Utils/logger";
import { SPACING, LAYOUT } from "@/Utils/Theme/constants"; import { SPACING, LAYOUT } from "@/Utils/Theme/constants";
import { BasePage, ConfigBox } from "@/Components/design-elements"; import { BasePage, ColoredLabel, ConfigBox } from "@/Components/design-elements";
import { Button } from "@/Components/inputs"; import { Button } from "@/Components/inputs";
import { useTheme } from "@mui/material"; import { useTheme } from "@mui/material";
@@ -15,6 +16,7 @@ import { useGet, usePost, usePatch } from "@/Hooks/UseApi";
import { mutate } from "swr"; import { mutate } from "swr";
import { useParams, useNavigate } from "react-router-dom"; import { useParams, useNavigate } from "react-router-dom";
import type { Monitor } from "@/Types/Monitor"; import type { Monitor } from "@/Types/Monitor";
import type { Tag } from "@/Types/Tag";
import { useForm, FormProvider } from "react-hook-form"; import { useForm, FormProvider } from "react-hook-form";
import { useEffect } from "react"; import { useEffect } from "react";
import { zodResolver } from "@hookform/resolvers/zod/dist/zod.js"; import { zodResolver } from "@hookform/resolvers/zod/dist/zod.js";
@@ -41,6 +43,7 @@ const CreateMaintenanceWindowPage = () => {
); );
const { data: monitors } = useGet<Monitor[]>("/monitors/team"); const { data: monitors } = useGet<Monitor[]>("/monitors/team");
const { data: tags } = useGet<Tag[]>("/tags/team");
const { post, loading: isPosting } = usePost(); const { post, loading: isPosting } = usePost();
const { patch, loading: isPatching } = usePatch(); const { patch, loading: isPatching } = usePatch();
@@ -203,6 +206,26 @@ const CreateMaintenanceWindowPage = () => {
"pages.maintenanceWindow.form.startTime.monitors.option.addMonitors.label" "pages.maintenanceWindow.form.startTime.monitors.option.addMonitors.label"
)} )}
options={monitors ?? []} options={monitors ?? []}
renderOptionContent={(monitor) => (
<Stack
direction="row"
alignItems="center"
gap={theme.spacing(2)}
flexWrap="wrap"
>
<Typography>{monitor.name}</Typography>
{monitor.tags.map((tagId) => {
const tag = tags?.find(({ id }) => id === tagId);
return tag ? (
<ColoredLabel
key={tag.id}
text={tag.name}
color={tag.color}
/>
) : null;
})}
</Stack>
)}
/> />
} }
/> />
+366 -193
View File
@@ -1,4 +1,4 @@
import { BasePage, ConfigBox, TextLink } from "@/Components/design-elements"; import { BasePage, ConfigBox, TextLink, Tabs, Tab } from "@/Components/design-elements";
import { Autocomplete, Select, Dialog } from "@/Components/inputs"; import { Autocomplete, Select, Dialog } from "@/Components/inputs";
import { logger } from "@/Utils/logger"; import { logger } from "@/Utils/logger";
import { LAYOUT } from "@/Utils/Theme/constants"; import { LAYOUT } from "@/Utils/Theme/constants";
@@ -46,6 +46,80 @@ import { FormNumberField } from "@/Components/inputs/forms/FormNumberField";
import { FormSelectField } from "@/Components/inputs/forms/FormSelectField"; import { FormSelectField } from "@/Components/inputs/forms/FormSelectField";
import type { ProxyResponse } from "@/Types/Proxy"; import type { ProxyResponse } from "@/Types/Proxy";
import type { AppSettingsResponse } from "@/Types/Settings"; import type { AppSettingsResponse } from "@/Types/Settings";
import { useSearchParams } from "react-router-dom";
const SETTINGS_TABS = [
{ key: "general", labelKey: "pages.settings.tabs.general" },
{ key: "monitoring", labelKey: "pages.settings.tabs.monitoring", adminOnly: true },
{ key: "email", labelKey: "pages.settings.tabs.email", adminOnly: true },
{ key: "integrations", labelKey: "pages.settings.tabs.integrations", adminOnly: true },
{ key: "data", labelKey: "pages.settings.tabs.data", adminOnly: true },
] as const;
type SettingsTabKey = (typeof SETTINGS_TABS)[number]["key"];
const FIELD_TAB: Record<string, SettingsTabKey> = {
checkTTL: "monitoring",
globalThresholds: "monitoring",
pagespeedApiKey: "integrations",
globalProxyEnabled: "integrations",
globalProxyId: "integrations",
showURL: "general",
};
const tabForField = (field: string): SettingsTabKey =>
field.startsWith("systemEmail")
? "email"
: (FIELD_TAB[field.split(".")[0]] ?? "general");
const FIELD_LABEL_KEY: Record<string, string> = {
checkTTL: "pages.settings.form.retention.option.days.label",
"globalThresholds.cpu": "pages.settings.form.thresholds.option.cpu.label",
"globalThresholds.memory": "pages.settings.form.thresholds.option.memory.label",
"globalThresholds.disk": "pages.settings.form.thresholds.option.disk.label",
"globalThresholds.temperature":
"pages.settings.form.thresholds.option.temperature.label",
pagespeedApiKey: "pages.settings.form.pagespeed.option.apiKey.label",
globalProxyEnabled: "pages.settings.form.globalProxy.option.enabled.label",
showURL: "pages.settings.form.url.option.showURL.label",
systemEmailHost: "pages.settings.form.email.option.host.label",
systemEmailPort: "pages.settings.form.email.option.port.label",
systemEmailAddress: "pages.settings.form.email.option.address.label",
systemEmailDisplayName: "pages.settings.form.email.option.displayName.label",
systemEmailUser: "pages.settings.form.email.option.user.label",
systemEmailPassword: "pages.settings.form.email.option.password.label",
systemEmailTLSServername: "pages.settings.form.email.option.tlsServername.label",
systemEmailConnectionHost: "pages.settings.form.email.option.connectionHost.label",
systemEmailSecure: "pages.settings.form.email.option.secure.label",
systemEmailPool: "pages.settings.form.email.option.pool.label",
systemEmailIgnoreTLS: "pages.settings.form.email.option.ignoreTLS.label",
systemEmailRequireTLS: "pages.settings.form.email.option.requireTLS.label",
systemEmailRejectUnauthorized:
"pages.settings.form.email.option.rejectUnauthorized.label",
};
type FieldErrorLeaf = { path: string; message?: string };
const flattenFieldErrors = (errors: unknown, prefix = ""): FieldErrorLeaf[] => {
if (typeof errors !== "object" || errors === null) {
return [];
}
return Object.entries(errors).flatMap(([key, value]) => {
if (key === "ref") {
return [];
}
const path = prefix ? `${prefix}.${key}` : key;
if (typeof value !== "object" || value === null) {
return [];
}
const message = (value as { message?: unknown }).message;
if (typeof message === "string") {
return [{ path, message }];
}
const nested = flattenFieldErrors(value, path);
return nested.length > 0 ? nested : [{ path }];
});
};
export const SettingsPage = () => { export const SettingsPage = () => {
const theme = useTheme(); const theme = useTheme();
@@ -53,6 +127,42 @@ export const SettingsPage = () => {
const dispatch = useDispatch(); const dispatch = useDispatch();
const isAdmin = useIsAdmin(); const isAdmin = useIsAdmin();
const { toastError } = useToast(); const { toastError } = useToast();
const [searchParams, setSearchParams] = useSearchParams();
const visibleTabs = useMemo(
() => SETTINGS_TABS.filter((tab) => !("adminOnly" in tab) || isAdmin),
[isAdmin]
);
const requestedTab = searchParams.get("tab");
const firstVisibleTab: SettingsTabKey = visibleTabs[0]?.key ?? SETTINGS_TABS[0].key;
const activeTab: SettingsTabKey =
visibleTabs.find((tab) => tab.key === requestedTab)?.key ?? firstVisibleTab;
const handleTabChange = (tab: SettingsTabKey) => {
const updated = new URLSearchParams(searchParams);
if (tab === firstVisibleTab) {
updated.delete("tab");
} else {
updated.set("tab", tab);
}
setSearchParams(updated, { replace: true });
};
// Drop a "tab" param that does not resolve to a rendered tab, or that names
// the first tab, which is addressed with no param at all.
useEffect(() => {
if (requestedTab === null) {
return;
}
if (requestedTab === activeTab && activeTab !== firstVisibleTab) {
return;
}
const updated = new URLSearchParams(searchParams);
updated.delete("tab");
setSearchParams(updated, { replace: true });
}, [requestedTab, activeTab, firstVisibleTab, searchParams, setSearchParams]);
// Local state for demo monitors dialog // Local state for demo monitors dialog
const [isDemoMonitorsDialogOpen, setIsDemoMonitorsDialogOpen] = useState(false); const [isDemoMonitorsDialogOpen, setIsDemoMonitorsDialogOpen] = useState(false);
const { post: postDemoMonitors, loading: isPostingDemoMonitors } = usePost(); const { post: postDemoMonitors, loading: isPostingDemoMonitors } = usePost();
@@ -300,6 +410,13 @@ export const SettingsPage = () => {
logger.debug("Form validation errors", errors); logger.debug("Form validation errors", errors);
}; };
const revealField = (field: string) => {
const target = tabForField(field);
if (visibleTabs.some((tab) => tab.key === target)) {
handleTabChange(target);
}
};
const languages = Object.keys(i18n.options.resources || {}); const languages = Object.keys(i18n.options.resources || {});
const globalProxyEnabled = watch("globalProxyEnabled"); const globalProxyEnabled = watch("globalProxyEnabled");
@@ -324,6 +441,23 @@ export const SettingsPage = () => {
component="form" component="form"
onSubmit={form.handleSubmit(onSubmit, onError)} onSubmit={form.handleSubmit(onSubmit, onError)}
> >
{visibleTabs.length > 1 && (
<Tabs
value={activeTab}
onChange={(_, value: SettingsTabKey) => handleTabChange(value)}
>
{visibleTabs.map((tab) => (
<Tab
key={tab.key}
value={tab.key}
label={t(tab.labelKey)}
/>
))}
</Tabs>
)}
{/* general tab */}
{activeTab === "general" && (
<Stack gap={theme.spacing(LAYOUT.MD)}> <Stack gap={theme.spacing(LAYOUT.MD)}>
<ConfigBox <ConfigBox
title={t("pages.settings.form.timezone.title")} title={t("pages.settings.form.timezone.title")}
@@ -390,74 +524,6 @@ export const SettingsPage = () => {
</Stack> </Stack>
} }
/> />
{isAdmin && (
<ConfigBox
title={t("pages.settings.form.globalProxy.title")}
subtitle={t("pages.settings.form.globalProxy.description")}
rightContent={
proxyOptions.length > 0 ? (
<Stack>
<FormSwitchField
name="globalProxyEnabled"
labelPlacement="start"
label={t("pages.settings.form.globalProxy.option.enabled.label")}
/>
{globalProxyEnabled && (
<FormSelectField
fieldLabel={t(
"pages.settings.form.globalProxy.option.proxy.label"
)}
name="globalProxyId"
options={proxyOptions}
/>
)}
</Stack>
) : (
<TextLink
text={t("pages.settings.form.globalProxy.option.empty.text")}
linkText={t("pages.settings.form.globalProxy.option.empty.link")}
href="/proxies"
/>
)
}
/>
)}
{isAdmin && (
<ConfigBox
title={t("pages.settings.form.pagespeed.title")}
subtitle={t("pages.settings.form.pagespeed.description")}
rightContent={
<>
{(isApiKeySet === false || apiKeyHasBeenReset === true) && (
<FormTextField
name="pagespeedApiKey"
type="password"
fieldLabel={t("pages.settings.form.pagespeed.option.apiKey.label")}
placeholder={t(
"pages.settings.form.pagespeed.option.apiKey.placeholder"
)}
/>
)}
{isApiKeySet === true && apiKeyHasBeenReset === false && (
<Box>
<FieldLabel>
{t("pages.settings.form.pagespeed.option.apiKey.labelSet")}
</FieldLabel>
<Button
onClick={handleResetApiKey}
variant="contained"
color="error"
>
{t("common.buttons.reset")}
</Button>
</Box>
)}
</>
}
/>
)}
{/* URL Settings */} {/* URL Settings */}
<ConfigBox <ConfigBox
title={t("pages.settings.form.url.title")} title={t("pages.settings.form.url.title")}
@@ -470,51 +536,37 @@ export const SettingsPage = () => {
/> />
} }
/> />
{/* About */}
{/* Clear All Stats */}
{isAdmin && (
<ConfigBox <ConfigBox
title={t("pages.settings.form.stats.title")} title={t("pages.settings.form.about.title")}
subtitle={t("pages.settings.form.stats.description")} subtitle=""
rightContent={ rightContent={
<Button <Stack spacing={2}>
variant="contained" <Typography variant="body1">
color="error" {t("common.appName")} {__APP_VERSION__}
onClick={() => setIsStatsDialogOpen(true)} </Typography>
<Typography
variant="body2"
sx={{ opacity: 0.6 }}
> >
{t("common.buttons.clear")} {t("pages.settings.form.about.developedBy")}
</Button> </Typography>
} <Link
/> href="https://github.com/bluewave-labs/checkmate"
)} target="_blank"
rel="noopener noreferrer"
{/* Check Retention */} >
{isAdmin && ( https://github.com/bluewave-labs/checkmate
<ConfigBox </Link>
title={t("pages.settings.form.retention.title")} </Stack>
subtitle={t("pages.settings.form.retention.description")}
rightContent={
<FormSliderField
name="checkTTL"
fieldLabel={t("pages.settings.form.retention.option.days.label")}
min={1}
max={CHECK_TTL_SENTINEL}
valueLabelDisplay="auto"
valueLabelFormat={(value: number) =>
value >= CHECK_TTL_SENTINEL
? t("pages.settings.form.retention.option.days.unlimited")
: `${value}`
}
formatDisplayValue={(value: number) =>
value >= CHECK_TTL_SENTINEL
? t("pages.settings.form.retention.option.days.unlimited")
: `${value}`
}
/>
} }
/> />
</Stack>
)} )}
{/* monitoring tab */}
{activeTab === "monitoring" && (
<Stack gap={theme.spacing(LAYOUT.MD)}>
{/* Global Thresholds */} {/* Global Thresholds */}
{isAdmin && ( {isAdmin && (
<ConfigBox <ConfigBox
@@ -557,8 +609,59 @@ export const SettingsPage = () => {
} }
/> />
)} )}
</Stack> {/* Check Retention */}
{isAdmin && (
<ConfigBox
title={t("pages.settings.form.retention.title")}
subtitle={t("pages.settings.form.retention.description")}
rightContent={
<FormSliderField
name="checkTTL"
fieldLabel={t("pages.settings.form.retention.option.days.label")}
min={1}
max={CHECK_TTL_SENTINEL}
valueLabelDisplay="auto"
valueLabelFormat={(value: number) =>
value >= CHECK_TTL_SENTINEL
? t("pages.settings.form.retention.option.days.unlimited")
: `${value}`
}
formatDisplayValue={(value: number) =>
value >= CHECK_TTL_SENTINEL
? t("pages.settings.form.retention.option.days.unlimited")
: `${value}`
}
/>
}
/>
)}
{/* Demo Monitors - Admin Only */}
{isAdmin && (
<ConfigBox
title={t("pages.settings.form.demoMonitors.title")}
subtitle={t("pages.settings.form.demoMonitors.description")}
rightContent={
<Box>
<Button
variant="contained"
loading={isPostingDemoMonitors}
onClick={async () => {
await postDemoMonitors("/monitors/demo", {});
}}
>
{t("common.buttons.addDemo")}
</Button>
</Box>
}
/>
)}
</Stack>
)}
{/* email tab */}
{activeTab === "email" && (
<Stack gap={theme.spacing(LAYOUT.MD)}>
{/* Email Settings - Admin Only */} {/* Email Settings - Admin Only */}
{isAdmin && ( {isAdmin && (
<ConfigBox <ConfigBox
@@ -598,14 +701,18 @@ export const SettingsPage = () => {
pass: "<your_password>", pass: "<your_password>",
}, },
name: name:
form.watch("systemEmailConnectionHost") || "localhost", form.watch("systemEmailConnectionHost") ||
"localhost",
pool: form.watch("systemEmailPool") ?? false, pool: form.watch("systemEmailPool") ?? false,
tls: { tls: {
rejectUnauthorized: rejectUnauthorized:
form.watch("systemEmailRejectUnauthorized") ?? true, form.watch("systemEmailRejectUnauthorized") ?? true,
ignoreTLS: form.watch("systemEmailIgnoreTLS") ?? false, ignoreTLS:
requireTLS: form.watch("systemEmailRequireTLS") ?? false, form.watch("systemEmailIgnoreTLS") ?? false,
servername: form.watch("systemEmailTLSServername") || "", requireTLS:
form.watch("systemEmailRequireTLS") ?? false,
servername:
form.watch("systemEmailTLSServername") || "",
}, },
}, },
null, null,
@@ -655,7 +762,9 @@ export const SettingsPage = () => {
name="systemEmailAddress" name="systemEmailAddress"
type="email" type="email"
fieldLabel={t("pages.settings.form.email.option.address.label")} fieldLabel={t("pages.settings.form.email.option.address.label")}
placeholder={t("pages.settings.form.email.option.address.placeholder")} placeholder={t(
"pages.settings.form.email.option.address.placeholder"
)}
/> />
{/* Email Display Name (Optional) */} {/* Email Display Name (Optional) */}
@@ -709,7 +818,9 @@ export const SettingsPage = () => {
{/* TLS Servername (Optional) */} {/* TLS Servername (Optional) */}
<FormTextField <FormTextField
name="systemEmailTLSServername" name="systemEmailTLSServername"
fieldLabel={t("pages.settings.form.email.option.tlsServername.label")} fieldLabel={t(
"pages.settings.form.email.option.tlsServername.label"
)}
placeholder={t( placeholder={t(
"pages.settings.form.email.option.tlsServername.placeholder" "pages.settings.form.email.option.tlsServername.placeholder"
)} )}
@@ -718,7 +829,9 @@ export const SettingsPage = () => {
{/* Connection Host (Optional) */} {/* Connection Host (Optional) */}
<FormTextField <FormTextField
name="systemEmailConnectionHost" name="systemEmailConnectionHost"
fieldLabel={t("pages.settings.form.email.option.connectionHost.label")} fieldLabel={t(
"pages.settings.form.email.option.connectionHost.label"
)}
placeholder={t( placeholder={t(
"pages.settings.form.email.option.connectionHost.placeholder" "pages.settings.form.email.option.connectionHost.placeholder"
)} )}
@@ -760,24 +873,136 @@ export const SettingsPage = () => {
} }
/> />
)} )}
</Stack>
)}
{/* Demo Monitors - Admin Only */} {/* integrations tab */}
{activeTab === "integrations" && (
<Stack gap={theme.spacing(LAYOUT.MD)}>
{isAdmin && ( {isAdmin && (
<ConfigBox <ConfigBox
title={t("pages.settings.form.demoMonitors.title")} title={t("pages.settings.form.globalProxy.title")}
subtitle={t("pages.settings.form.demoMonitors.description")} subtitle={t("pages.settings.form.globalProxy.description")}
rightContent={ rightContent={
proxyOptions.length > 0 ? (
<Stack>
<FormSwitchField
name="globalProxyEnabled"
labelPlacement="start"
label={t("pages.settings.form.globalProxy.option.enabled.label")}
/>
{globalProxyEnabled && (
<FormSelectField
fieldLabel={t(
"pages.settings.form.globalProxy.option.proxy.label"
)}
name="globalProxyId"
options={proxyOptions}
/>
)}
</Stack>
) : (
<TextLink
text={t("pages.settings.form.globalProxy.option.empty.text")}
linkText={t("pages.settings.form.globalProxy.option.empty.link")}
href="/proxies"
/>
)
}
/>
)}
{isAdmin && (
<ConfigBox
title={t("pages.settings.form.pagespeed.title")}
subtitle={t("pages.settings.form.pagespeed.description")}
rightContent={
<>
{(isApiKeySet === false || apiKeyHasBeenReset === true) && (
<FormTextField
name="pagespeedApiKey"
type="password"
fieldLabel={t(
"pages.settings.form.pagespeed.option.apiKey.label"
)}
placeholder={t(
"pages.settings.form.pagespeed.option.apiKey.placeholder"
)}
/>
)}
{isApiKeySet === true && apiKeyHasBeenReset === false && (
<Box> <Box>
<FieldLabel>
{t("pages.settings.form.pagespeed.option.apiKey.labelSet")}
</FieldLabel>
<Button <Button
onClick={handleResetApiKey}
variant="contained" variant="contained"
loading={isPostingDemoMonitors} color="error"
onClick={async () => {
await postDemoMonitors("/monitors/demo", {});
}}
> >
{t("common.buttons.addDemo")} {t("common.buttons.reset")}
</Button> </Button>
</Box> </Box>
)}
</>
}
/>
)}
</Stack>
)}
{/* data tab */}
{activeTab === "data" && (
<Stack gap={theme.spacing(LAYOUT.MD)}>
{/* Export Monitors - Admin Only */}
{isAdmin && (
<ConfigBox
title={t("pages.settings.form.importExportMonitors.title")}
subtitle={t("pages.settings.form.importExportMonitors.description")}
rightContent={
<Stack
gap={theme.spacing(LAYOUT.MD)}
direction={"row"}
>
<input
id="monitor-import-input"
type="file"
accept=".json"
style={{ display: "none" }}
onChange={handleFileSelect}
/>
<Button
variant="contained"
onClick={() =>
document.getElementById("monitor-import-input")?.click()
}
disabled={isImportingMonitors}
>
{t("common.buttons.importFromJSON")}
</Button>
<Button
variant="contained"
onClick={handleExportMonitors}
>
{t("common.buttons.exportToJSON")}
</Button>
</Stack>
}
/>
)}
{/* Clear All Stats */}
{isAdmin && (
<ConfigBox
title={t("pages.settings.form.stats.title")}
subtitle={t("pages.settings.form.stats.description")}
rightContent={
<Button
variant="contained"
color="error"
onClick={() => setIsStatsDialogOpen(true)}
>
{t("common.buttons.clear")}
</Button>
} }
/> />
)} )}
@@ -801,68 +1026,9 @@ export const SettingsPage = () => {
} }
/> />
)} )}
{/* Export Monitors - Admin Only */}
{isAdmin && (
<ConfigBox
title={t("pages.settings.form.importExportMonitors.title")}
subtitle={t("pages.settings.form.importExportMonitors.description")}
rightContent={
<Stack
gap={theme.spacing(LAYOUT.MD)}
direction={"row"}
>
<input
id="monitor-import-input"
type="file"
accept=".json"
style={{ display: "none" }}
onChange={handleFileSelect}
/>
<Button
variant="contained"
onClick={() => document.getElementById("monitor-import-input")?.click()}
disabled={isImportingMonitors}
>
{t("common.buttons.importFromJSON")}
</Button>
<Button
variant="contained"
onClick={handleExportMonitors}
>
{t("common.buttons.exportToJSON")}
</Button>
</Stack> </Stack>
}
/>
)} )}
{/* About */}
<ConfigBox
title={t("pages.settings.form.about.title")}
subtitle=""
rightContent={
<Stack spacing={2}>
<Typography variant="body1">
{t("common.appName")} {__APP_VERSION__}
</Typography>
<Typography
variant="body2"
sx={{ opacity: 0.6 }}
>
{t("pages.settings.form.about.developedBy")}
</Typography>
<Link
href="https://github.com/bluewave-labs/checkmate"
target="_blank"
rel="noopener noreferrer"
>
https://github.com/bluewave-labs/checkmate
</Link>
</Stack>
}
/>
{/* Clear Stats Confirmation Dialog */} {/* Clear Stats Confirmation Dialog */}
<Dialog <Dialog
open={isStatsDialogOpen} open={isStatsDialogOpen}
@@ -895,6 +1061,8 @@ export const SettingsPage = () => {
<Stack <Stack
direction="row" direction="row"
justifyContent="flex-end" justifyContent="flex-end"
alignItems="center"
gap={theme.spacing(LAYOUT.MD)}
sx={{ sx={{
position: "sticky", position: "sticky",
bottom: 0, bottom: 0,
@@ -904,10 +1072,7 @@ export const SettingsPage = () => {
> >
{/* Validation Error Display */} {/* Validation Error Display */}
{Object.keys(form.formState.errors).length > 0 && ( {Object.keys(form.formState.errors).length > 0 && (
<Alert <Alert severity="error">
severity="error"
sx={{ mb: 2, flexGrow: 1, mr: 2 }}
>
<Typography <Typography
variant="body2" variant="body2"
sx={{ fontWeight: 600, mb: 1 }} sx={{ fontWeight: 600, mb: 1 }}
@@ -918,15 +1083,23 @@ export const SettingsPage = () => {
component="ul" component="ul"
sx={{ m: 0, pl: 2 }} sx={{ m: 0, pl: 2 }}
> >
{Object.entries(form.formState.errors).map(([field, error]) => { {flattenFieldErrors(form.formState.errors).map(({ path, message }) => {
const message = const labelKey = FIELD_LABEL_KEY[path];
typeof error === "object" && error?.message // Labels read "Name - explanation"; keep the name.
? error.message const label = labelKey ? t(labelKey).split(" - ")[0] : path;
: "Invalid value";
return ( return (
<li key={field}> <li key={path}>
<Typography variant="body2"> <Typography variant="body2">
<strong>{field}:</strong> {message} <Link
component="button"
type="button"
variant="body2"
color={theme.palette.error.main}
onClick={() => revealField(path)}
>
<strong>{label}</strong>
</Link>
{message ? `: ${message}` : ""}
</Typography> </Typography>
</li> </li>
); );
+9
View File
@@ -1,4 +1,5 @@
import { alpha } from "@mui/material/styles"; import { alpha } from "@mui/material/styles";
import { HOVER } from "@/Utils/Theme/constants";
const typographyBase = 13; const typographyBase = 13;
@@ -39,6 +40,10 @@ export const lightPalette = {
primary: { primary: {
main: colors.brandGreen, main: colors.brandGreen,
}, },
action: {
rowHover: alpha(colors.gray900, HOVER.ROW),
controlHover: alpha(colors.gray900, HOVER.CONTROL),
},
secondary: { secondary: {
main: colors.gray200, main: colors.gray200,
}, },
@@ -65,6 +70,10 @@ export const darkPalette = {
primary: { primary: {
main: colors.brandGreen, main: colors.brandGreen,
}, },
action: {
rowHover: alpha("#FFFFFF", HOVER.ROW),
controlHover: alpha("#FFFFFF", HOVER.CONTROL),
},
secondary: { secondary: {
main: colors.gray700, main: colors.gray700,
}, },
+4
View File
@@ -13,6 +13,10 @@ declare module "@mui/material/styles" {
eyebrow?: React.CSSProperties; eyebrow?: React.CSSProperties;
fontFamilyMonospace?: string; fontFamilyMonospace?: string;
} }
interface TypeAction {
rowHover: string;
controlHover: string;
}
interface Palette { interface Palette {
sidebar: { accent: string }; sidebar: { accent: string };
rowStatus: { running: string; paused: string }; rowStatus: { running: string; paused: string };
+2
View File
@@ -20,4 +20,6 @@ export const LAYOUT = {
export const HOVER = { export const HOVER = {
DARKEN: 0.06, // This is a coefficient for darkening function DARKEN: 0.06, // This is a coefficient for darkening function
ROW: 0.025, // Overlay alpha for hoverable rows and cards
CONTROL: 0.05, // Stronger overlay for controls nested inside a hoverable row
} as const; } as const;
+14 -1
View File
@@ -181,7 +181,13 @@
"statusPages": "صفحات الحالة", "statusPages": "صفحات الحالة",
"maintenance": "الصيانة", "maintenance": "الصيانة",
"logs": "السجلات", "logs": "السجلات",
"settings": "الإعدادات" "settings": "الإعدادات",
"groups": {
"monitoring": "المراقبة",
"alerting": "التنبيهات",
"reporting": "التقارير",
"configuration": "الإعدادات العامة"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "الدعم", "support": "الدعم",
@@ -1141,6 +1147,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "عام",
"monitoring": "المراقبة",
"email": "البريد الإلكتروني",
"integrations": "التكاملات",
"data": "البيانات"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "المنطقة الزمنية للعرض", "title": "المنطقة الزمنية للعرض",
+14 -1
View File
@@ -189,7 +189,13 @@
"statusPages": "Pàgines d'estat", "statusPages": "Pàgines d'estat",
"maintenance": "Manteniment", "maintenance": "Manteniment",
"logs": "Registres", "logs": "Registres",
"settings": "Configuració" "settings": "Configuració",
"groups": {
"monitoring": "Monitoratge",
"alerting": "Alertes",
"reporting": "Informes",
"configuration": "Configuració"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "Suport", "support": "Suport",
@@ -1141,6 +1147,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "General",
"monitoring": "Monitoratge",
"email": "Correu electrònic",
"integrations": "Integracions",
"data": "Dades"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "Zona horària de visualització", "title": "Zona horària de visualització",
+14 -1
View File
@@ -181,7 +181,13 @@
"statusPages": "Stavové stránky", "statusPages": "Stavové stránky",
"maintenance": "Údržba", "maintenance": "Údržba",
"logs": "Záznamy", "logs": "Záznamy",
"settings": "Nastavení" "settings": "Nastavení",
"groups": {
"monitoring": "Monitorování",
"alerting": "Upozornění",
"reporting": "Přehledy",
"configuration": "Konfigurace"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "Podpora", "support": "Podpora",
@@ -1141,6 +1147,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "Obecné",
"monitoring": "Monitorování",
"email": "E-mail",
"integrations": "Integrace",
"data": "Data"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "Zobrazované časové pásmo", "title": "Zobrazované časové pásmo",
+14 -1
View File
@@ -181,7 +181,13 @@
"statusPages": "Statusseite", "statusPages": "Statusseite",
"maintenance": "Wartung", "maintenance": "Wartung",
"logs": "Protokolle", "logs": "Protokolle",
"settings": "Einstellungen" "settings": "Einstellungen",
"groups": {
"monitoring": "Überwachung",
"alerting": "Benachrichtigungen",
"reporting": "Berichte",
"configuration": "Konfiguration"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "Support", "support": "Support",
@@ -1141,6 +1147,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "Allgemein",
"monitoring": "Überwachung",
"email": "E-Mail",
"integrations": "Integrationen",
"data": "Daten"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "Anzeigesprache Zeitzone", "title": "Anzeigesprache Zeitzone",
+17 -4
View File
@@ -212,7 +212,13 @@
"statusPages": "Status pages", "statusPages": "Status pages",
"maintenance": "Maintenance", "maintenance": "Maintenance",
"logs": "Logs", "logs": "Logs",
"settings": "Settings" "settings": "Settings",
"groups": {
"monitoring": "Monitoring",
"alerting": "Alerting",
"reporting": "Reporting",
"configuration": "Configuration"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "Support", "support": "Support",
@@ -945,7 +951,7 @@
"memory": "Memory usage", "memory": "Memory usage",
"netBytesRecv": "{{name}} - Bytes Received", "netBytesRecv": "{{name}} - Bytes Received",
"netBytesSent": "{{name}} - Bytes Sent", "netBytesSent": "{{name}} - Bytes Sent",
"loopbackOnlyNotice": "Capture is only reporting loopback or container-bridge interfaces (lo, lo0, docker0). This is normal when Capture runs inside a container that can only see its own network namespace — run Capture directly on the host to see real network activity.", "loopbackOnlyNotice": "Capture is only seeing container network interfaces, and none of them are carrying real traffic. This is normal when Capture runs inside a container that can only observe its own network namespace — interfaces with host-like names (eth0, ens3) are the container's virtual interfaces, not the host's. Run Capture directly on the host to see real network activity.",
"temp": "CPU temperature" "temp": "CPU temperature"
} }
}, },
@@ -1352,6 +1358,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "General",
"monitoring": "Monitoring",
"email": "Email",
"integrations": "Integrations",
"data": "Data"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "Display timezone", "title": "Display timezone",
@@ -1409,7 +1422,7 @@
} }
}, },
"url": { "url": {
"title": "Monitor IP/URL on Status Page", "title": "Monitor IP/URL on status page",
"description": "Display the IP address or URL of monitor on the public Status page. If it's disabled, only the monitor name will be shown to protect sensitive information.", "description": "Display the IP address or URL of monitor on the public Status page. If it's disabled, only the monitor name will be shown to protect sensitive information.",
"option": { "option": {
"showURL": { "showURL": {
@@ -1441,7 +1454,7 @@
} }
}, },
"thresholds": { "thresholds": {
"title": "Global Thresholds", "title": "Global thresholds",
"description": "Set global CPU, Memory, Disk, and Temperature thresholds for infrastructure monitoring. These apply to all hardware monitors unless overridden.", "description": "Set global CPU, Memory, Disk, and Temperature thresholds for infrastructure monitoring. These apply to all hardware monitors unless overridden.",
"option": { "option": {
"cpu": { "cpu": {
+14 -1
View File
@@ -181,7 +181,13 @@
"statusPages": "Páginas de estado", "statusPages": "Páginas de estado",
"maintenance": "Mantenimiento", "maintenance": "Mantenimiento",
"logs": "Registros", "logs": "Registros",
"settings": "Configuración" "settings": "Configuración",
"groups": {
"monitoring": "Monitorización",
"alerting": "Alertas",
"reporting": "Informes",
"configuration": "Configuración"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "Soporte", "support": "Soporte",
@@ -1141,6 +1147,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "General",
"monitoring": "Monitorización",
"email": "Correo electrónico",
"integrations": "Integraciones",
"data": "Datos"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "Zona horaria de visualización", "title": "Zona horaria de visualización",
+14 -1
View File
@@ -181,7 +181,13 @@
"statusPages": "Tilasivut", "statusPages": "Tilasivut",
"maintenance": "Huolto", "maintenance": "Huolto",
"logs": "Lokit", "logs": "Lokit",
"settings": "Asetukset" "settings": "Asetukset",
"groups": {
"monitoring": "Valvonta",
"alerting": "Hälytykset",
"reporting": "Raportointi",
"configuration": "Määritykset"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "Tuki", "support": "Tuki",
@@ -1141,6 +1147,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "Yleiset",
"monitoring": "Valvonta",
"email": "Sähköposti",
"integrations": "Integraatiot",
"data": "Tiedot"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "Näytettävä aikavyöhyke", "title": "Näytettävä aikavyöhyke",
+14 -1
View File
@@ -181,7 +181,13 @@
"statusPages": "Pages de statut", "statusPages": "Pages de statut",
"maintenance": "Maintenance", "maintenance": "Maintenance",
"logs": "Journaux", "logs": "Journaux",
"settings": "Paramètres" "settings": "Paramètres",
"groups": {
"monitoring": "Surveillance",
"alerting": "Alertes",
"reporting": "Rapports",
"configuration": "Configuration"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "Support", "support": "Support",
@@ -1141,6 +1147,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "Général",
"monitoring": "Surveillance",
"email": "E-mail",
"integrations": "Intégrations",
"data": "Données"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "Fuseau horaire d'affichage", "title": "Fuseau horaire d'affichage",
+14 -1
View File
@@ -193,7 +193,13 @@
"statusPages": "Pagine di stato", "statusPages": "Pagine di stato",
"maintenance": "Manutenzione", "maintenance": "Manutenzione",
"logs": "Log", "logs": "Log",
"settings": "Impostazioni" "settings": "Impostazioni",
"groups": {
"monitoring": "Monitoraggio",
"alerting": "Avvisi",
"reporting": "Report",
"configuration": "Configurazione"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "Supporto", "support": "Supporto",
@@ -1237,6 +1243,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "Generale",
"monitoring": "Monitoraggio",
"email": "Email",
"integrations": "Integrazioni",
"data": "Dati"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "Fuso orario di visualizzazione", "title": "Fuso orario di visualizzazione",
+14 -1
View File
@@ -181,7 +181,13 @@
"statusPages": "ステータスページ", "statusPages": "ステータスページ",
"maintenance": "メンテナンス", "maintenance": "メンテナンス",
"logs": "ログ", "logs": "ログ",
"settings": "設定" "settings": "設定",
"groups": {
"monitoring": "監視",
"alerting": "アラート",
"reporting": "レポート",
"configuration": "設定"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "サポート", "support": "サポート",
@@ -1141,6 +1147,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "一般",
"monitoring": "監視",
"email": "メール",
"integrations": "連携",
"data": "データ"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "表示タイムゾーン", "title": "表示タイムゾーン",
+14 -1
View File
@@ -214,7 +214,13 @@
"settings": "Ustawienia", "settings": "Ustawienia",
"statusPages": "Strony statusu", "statusPages": "Strony statusu",
"tags": "Tagi", "tags": "Tagi",
"uptime": "Czas działania" "uptime": "Czas działania",
"groups": {
"monitoring": "Monitorowanie",
"alerting": "Alerty",
"reporting": "Raporty",
"configuration": "Konfiguracja"
}
}, },
"starPrompt": { "starPrompt": {
"description": "Zobacz najnowsze wydania i pomóż rozwijać społeczność na GitHub", "description": "Zobacz najnowsze wydania i pomóż rozwijać społeczność na GitHub",
@@ -1207,6 +1213,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "Ogólne",
"monitoring": "Monitorowanie",
"email": "E-mail",
"integrations": "Integracje",
"data": "Dane"
},
"form": { "form": {
"about": { "about": {
"developedBy": "Opracowane przez Bluewave Labs", "developedBy": "Opracowane przez Bluewave Labs",
+14 -1
View File
@@ -181,7 +181,13 @@
"statusPages": "Pagina de status", "statusPages": "Pagina de status",
"maintenance": "Manutenção", "maintenance": "Manutenção",
"logs": "Registros", "logs": "Registros",
"settings": "Configurações" "settings": "Configurações",
"groups": {
"monitoring": "Monitoramento",
"alerting": "Alertas",
"reporting": "Relatórios",
"configuration": "Configuração"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "Suporte", "support": "Suporte",
@@ -1141,6 +1147,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "Geral",
"monitoring": "Monitoramento",
"email": "E-mail",
"integrations": "Integrações",
"data": "Dados"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "Fuso horário de exibição", "title": "Fuso horário de exibição",
+14 -1
View File
@@ -181,7 +181,13 @@
"statusPages": "Страницы статуса", "statusPages": "Страницы статуса",
"maintenance": "Обслуживание", "maintenance": "Обслуживание",
"logs": "Логи", "logs": "Логи",
"settings": "Настройки" "settings": "Настройки",
"groups": {
"monitoring": "Мониторинг",
"alerting": "Оповещения",
"reporting": "Отчёты",
"configuration": "Конфигурация"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "Поддержка", "support": "Поддержка",
@@ -1141,6 +1147,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "Общие",
"monitoring": "Мониторинг",
"email": "Электронная почта",
"integrations": "Интеграции",
"data": "Данные"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "Часовой пояс отображения", "title": "Часовой пояс отображения",
+14 -1
View File
@@ -181,7 +181,13 @@
"statusPages": "หน้าสถานะ", "statusPages": "หน้าสถานะ",
"maintenance": "การบำรุงรักษา", "maintenance": "การบำรุงรักษา",
"logs": "บันทึก", "logs": "บันทึก",
"settings": "การตั้งค่า" "settings": "การตั้งค่า",
"groups": {
"monitoring": "การตรวจสอบ",
"alerting": "การแจ้งเตือน",
"reporting": "รายงาน",
"configuration": "การกำหนดค่า"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "การสนับสนุน", "support": "การสนับสนุน",
@@ -1141,6 +1147,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "ทั่วไป",
"monitoring": "การตรวจสอบ",
"email": "อีเมล",
"integrations": "การเชื่อมต่อ",
"data": "ข้อมูล"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "เขตเวลาที่แสดง", "title": "เขตเวลาที่แสดง",
+14 -1
View File
@@ -181,7 +181,13 @@
"statusPages": "Durum sayfaları", "statusPages": "Durum sayfaları",
"maintenance": "Bakım", "maintenance": "Bakım",
"logs": "Günlükler", "logs": "Günlükler",
"settings": "Ayarlar" "settings": "Ayarlar",
"groups": {
"monitoring": "İzleme",
"alerting": "Uyarılar",
"reporting": "Raporlama",
"configuration": "Yapılandırma"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "Destek", "support": "Destek",
@@ -1141,6 +1147,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "Genel",
"monitoring": "İzleme",
"email": "E-posta",
"integrations": "Entegrasyonlar",
"data": "Veri"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "Görüntüleme saat dilimi", "title": "Görüntüleme saat dilimi",
+14 -1
View File
@@ -181,7 +181,13 @@
"statusPages": "Сторінки статусу", "statusPages": "Сторінки статусу",
"maintenance": "Обслуговування", "maintenance": "Обслуговування",
"logs": "Журнали", "logs": "Журнали",
"settings": "Налаштування" "settings": "Налаштування",
"groups": {
"monitoring": "Моніторинг",
"alerting": "Сповіщення",
"reporting": "Звіти",
"configuration": "Конфігурація"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "Підтримка", "support": "Підтримка",
@@ -1141,6 +1147,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "Загальні",
"monitoring": "Моніторинг",
"email": "Електронна пошта",
"integrations": "Інтеграції",
"data": "Дані"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "Часовий пояс відображення", "title": "Часовий пояс відображення",
+14 -1
View File
@@ -181,7 +181,13 @@
"statusPages": "Trang trạng thái", "statusPages": "Trang trạng thái",
"maintenance": "Bảo trì", "maintenance": "Bảo trì",
"logs": "Nhật ký", "logs": "Nhật ký",
"settings": "Cài đặt" "settings": "Cài đặt",
"groups": {
"monitoring": "Giám sát",
"alerting": "Cảnh báo",
"reporting": "Báo cáo",
"configuration": "Cấu hình"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "Hỗ trợ", "support": "Hỗ trợ",
@@ -1141,6 +1147,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "Chung",
"monitoring": "Giám sát",
"email": "Email",
"integrations": "Tích hợp",
"data": "Dữ liệu"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "Múi giờ hiển thị", "title": "Múi giờ hiển thị",
+14 -1
View File
@@ -181,7 +181,13 @@
"statusPages": "状态页", "statusPages": "状态页",
"maintenance": "维护", "maintenance": "维护",
"logs": "日志", "logs": "日志",
"settings": "设置" "settings": "设置",
"groups": {
"monitoring": "监控",
"alerting": "告警",
"reporting": "报表",
"configuration": "配置"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "支持", "support": "支持",
@@ -1142,6 +1148,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "常规",
"monitoring": "监控",
"email": "邮件",
"integrations": "集成",
"data": "数据"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "显示时区", "title": "显示时区",
+14 -1
View File
@@ -181,7 +181,13 @@
"statusPages": "狀態頁面", "statusPages": "狀態頁面",
"maintenance": "維護", "maintenance": "維護",
"logs": "日誌", "logs": "日誌",
"settings": "設定" "settings": "設定",
"groups": {
"monitoring": "監控",
"alerting": "警示",
"reporting": "報表",
"configuration": "設定"
}
}, },
"bottomMenu": { "bottomMenu": {
"support": "支援", "support": "支援",
@@ -1141,6 +1147,13 @@
} }
}, },
"settings": { "settings": {
"tabs": {
"general": "一般",
"monitoring": "監控",
"email": "郵件",
"integrations": "整合",
"data": "資料"
},
"form": { "form": {
"timezone": { "timezone": {
"title": "顯示時區", "title": "顯示時區",