Skip to content

Commit b8b0832

Browse files
committed
Settings overview: collapse to single column on narrow viewports
Hardcoded grid-template-columns: 1fr 1fr was overflowing on mobile. Now uses a class that becomes 1fr at <=900px so cards stack instead of being clipped.
1 parent 3838076 commit b8b0832

2 files changed

Lines changed: 12 additions & 2 deletions

File tree

web/src/app/admin/admin.css

Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -37,6 +37,16 @@
3737
}
3838
}
3939

40+
/* Settings overview grid: 2 columns on wide viewports, 1 column when narrow. */
41+
.adm-settings-grid {
42+
grid-template-columns: 1fr 1fr;
43+
}
44+
@media (max-width: 900px) {
45+
.adm-settings-grid {
46+
grid-template-columns: 1fr !important;
47+
}
48+
}
49+
4050
/* Table rows hover */
4151
.adm-row:hover { background: #F4F2EE !important; }
4252

web/src/components/admin/pages/SettingsPage.tsx

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -432,8 +432,8 @@ export default function SettingsPage({ section }: { section?: SettingsSection }
432432

433433
<div style={{ maxWidth: section ? 720 : 1200 }}>
434434

435-
{/* ── 2-column grid (single column when a sub-section is selected) ── */}
436-
<div style={{ display: section ? "block" : "grid", gridTemplateColumns: "1fr 1fr", gap: 16, alignItems: "start" }}>
435+
{/* ── 2-column grid (single column when a sub-section is selected, or on narrow viewports) ── */}
436+
<div className={section ? undefined : "adm-settings-grid"} style={section ? { display: "block" } : { display: "grid", gap: 16, alignItems: "start" }}>
437437

438438
{/* ── LEFT column ── */}
439439
<div>

0 commit comments

Comments
 (0)