feat(client): PageHeader on every page; remove sidebar bottom menu
- New PageHeader component (variant D — grouped icon-pill toolbar): big title + muted description on the left, Support / Docs / Changelog as a 3-icon segmented pill on the right with tooltips. External links open in a new tab. - BasePage / BasePageWithStates / MonitorBasePageWithStates accept a headerKey prop; when set, render PageHeader pulling pages.<headerKey>.header.title and .description from i18n. When unset, falls back to the existing breadcrumb (no behavior change for not-yet-migrated pages). - All top-level pages (uptime, infrastructure, pageSpeed, notifications, maintenance, statusPages, incidents, logs, checks, account, settings) now pass their headerKey. - Sidebar: removed the bottom menu (Support / Discussions / Docs / Changelog) since those links now live in the page header.
This commit is contained in:
1 parent
031a6fdf3c
commit
262c4eee93
10 files changed
+212
-39
No files matched your search
@@ -6,7 +6,7 @@ import Divider from "@mui/material/Divider";
|
||||
import { LAYOUT } from "@/Utils/Theme/constants";
|
||||
import { useSidebar } from "@/Hooks/useSidebar.js";
|
||||
import { Logo } from "@/Components/sidebar/Logo";
|
||||
import { getMenu, getBottomMenu, getAccountMenu } from "@/Components/sidebar/Menu";
|
||||
import { getMenu, getAccountMenu } from "@/Components/sidebar/Menu";
|
||||
import { NavItem } from "@/Components/sidebar/NavItem";
|
||||
import { StarPrompt } from "@/Components/sidebar/StarPrompt";
|
||||
import { AuthFooter } from "@/Components/sidebar/Authfooter";
|
||||
@@ -33,7 +33,6 @@ export const Sidebar = () => {
|
||||
const theme = useTheme();
|
||||
const isSmall = useMediaQuery(theme.breakpoints.down("md"));
|
||||
const menu = getMenu(t);
|
||||
const bottomMenu = getBottomMenu(t);
|
||||
const accountMenu = getAccountMenu(t);
|
||||
|
||||
useEffect(() => {
|
||||
@@ -103,23 +102,6 @@ export const Sidebar = () => {
|
||||
})}
|
||||
</List>
|
||||
<StarPrompt />
|
||||
<List
|
||||
component="nav"
|
||||
disablePadding
|
||||
sx={{ px: theme.spacing(LAYOUT.SM) }}
|
||||
>
|
||||
{bottomMenu.map((item) => {
|
||||
const selected = location.pathname.startsWith(`/${item.path}`);
|
||||
return (
|
||||
<NavItem
|
||||
key={item.path}
|
||||
item={item}
|
||||
selected={selected}
|
||||
onClick={() => handleNavClick(item.path)}
|
||||
/>
|
||||
);
|
||||
})}
|
||||
</List>
|
||||
<Divider sx={{ borderColor: theme.palette.divider }} />
|
||||
|
||||
<AuthFooter
|
||||
|
||||
Reference in new issue
Block a user