Add admin site settings sections and locale defaults

This commit is contained in:
MOH
2026-03-15 04:06:33 +01:00
parent 3e9edc5873
commit 5d3f77962a
21 changed files with 993 additions and 456 deletions
+12 -2
View File
@@ -3,8 +3,10 @@ import {
FolderKanban,
Globe2,
ImageIcon,
Languages,
LayoutDashboard,
LogOut,
Palette,
PlusSquare,
ShieldAlert,
SwatchBook,
@@ -34,6 +36,8 @@ type AdminDashboardCopy = {
portfolio: string;
media: string;
siteSettings: string;
brandSettings?: string;
localizationSettings?: string;
marquee?: string;
smtp?: string;
contactProtection?: string;
@@ -46,6 +50,7 @@ type AdminDashboardShellProps = {
active: "overview" | "maintenance" | "ui-kit" | "portfolio" | "media" | "site-settings" | "smtp" | "marquee";
smtpChild?: "settings" | "contact-protection";
portfolioChild?: "overview" | "projects" | "new-project" | "categories";
siteSettingsChild?: "brand" | "localization";
logoutAction: () => Promise<void>;
headerTitle: string;
headerDescription: string;
@@ -60,6 +65,7 @@ export async function AdminDashboardShell({
active,
smtpChild,
portfolioChild,
siteSettingsChild,
logoutAction,
headerTitle,
headerDescription,
@@ -72,7 +78,7 @@ export async function AdminDashboardShell({
getSiteSettingsMediaBindings(),
getMaintenanceMode(),
]);
const sidebarItems = getAdminNavigation(copy, active, smtpChild, portfolioChild);
const sidebarItems = getAdminNavigation(copy, active, smtpChild, portfolioChild, siteSettingsChild);
const normalizedSidebarItems = sidebarItems.filter(
(item) =>
item.href !== getAdminAppPath("/maintenance") &&
@@ -91,7 +97,11 @@ export async function AdminDashboardShell({
: active === "ui-kit"
? SwatchBook
: active === "site-settings"
? Globe2
? siteSettingsChild === "localization"
? Languages
: siteSettingsChild === "brand"
? Palette
: Globe2
: active === "marquee"
? Type
: active === "smtp"