fix admin save state architecture

This commit is contained in:
MOH
2026-03-10 05:24:50 +01:00
parent e219295327
commit f2b5a15191
12 changed files with 123 additions and 38 deletions
@@ -29,7 +29,6 @@ export function SidebarMaintenanceControl({
return (
<form id="sidebar-maintenance-form" action={action} className="space-y-2">
<input type="hidden" name="redirectPath" value={pathname} />
<input type="hidden" name="enabled" value={enabled ? "true" : "false"} />
<label
htmlFor="sidebar-maintenance-enabled"
@@ -66,7 +65,10 @@ export function SidebarMaintenanceControl({
<Checkbox
id="sidebar-maintenance-enabled"
name="enabled"
checked={enabled}
checkedValue="true"
uncheckedValue="false"
onCheckedChange={(checked) => setEnabled(checked === true)}
className="sr-only"
/>