Update Breadcrumbs to include dynamic path for configuration page

This commit is contained in:
nbgslv committed 2025-04-16 20:36:18 +03:00
1 parent 9b63016d56
commit a7fa3ccb77
2 files changed
+7 -5

No files matched your search

+1 -1
View File
@@ -69,7 +69,7 @@ const CreateStatusPage = () => {
} else { } else {
crumbs.push( crumbs.push(
{ name: t("statusBredCrumbsDetails"), path: `/status/uptime/${statusPage?.url}` }, { name: t("statusBredCrumbsDetails"), path: `/status/uptime/${statusPage?.url}` },
{ name: t("configure"), path: "" } { name: t("configure"), path: `/status/uptime/configure/${statusPage?.url}` }
); );
} }
+6 -4
View File
@@ -29,15 +29,17 @@ const PublicStatus = () => {
const { t } = useTranslation(); const { t } = useTranslation();
const location = useLocation(); const location = useLocation();
const navigate = useNavigate(); const navigate = useNavigate();
const crumbs = [
{ name: t("statusBredCrumbsStatusPages"), path: "/status" },
{ name: t("statusBredCrumbsDetails"), path: "" },
];
const [statusPage, monitors, isLoading, networkError, fetchStatusPage] = const [statusPage, monitors, isLoading, networkError, fetchStatusPage] =
useStatusPageFetch(false, url); useStatusPageFetch(false, url);
const [deleteStatusPage, isDeleting] = useStatusPageDelete(fetchStatusPage, url); const [deleteStatusPage, isDeleting] = useStatusPageDelete(fetchStatusPage, url);
// Breadcrumbs
const crumbs = [
{ name: t("statusBredCrumbsStatusPages"), path: "/status" },
{ name: t("statusBredCrumbsDetails"), path: `/status/uptime/${statusPage?.url}` },
];
// Setup // Setup
let sx = { paddingLeft: theme.spacing(20), paddingRight: theme.spacing(20) }; let sx = { paddingLeft: theme.spacing(20), paddingRight: theme.spacing(20) };
let link = undefined; let link = undefined;