fix(settings): full-bleed layout so the page fills wide screens

The Settings page was the only dashboard route capped at
max-w-[1040px] mx-auto, so it floated centered with large empty
gutters on wide monitors while every other page is full-bleed.

Remove the cap so the page fills the available width like the rest of
the app, and spend the space where it helps readability:
- Overview status tiles go 3-up on xl (from 2-up).
- Templates list goes 2-up on xl.
- Form-heavy panels (Profile, Login & security, Deals) keep a readable
  max-w-2xl; Fields & tags and Appearance use max-w-3xl — so inputs
  don't stretch edge-to-edge on large displays.
- Grid uses minmax(0,1fr) to avoid blowout from long content.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
Arnas Donauskas 2026-06-18 15:30:41 +03:00
parent 7e531e6fbd
commit 1de99be73a
No known key found for this signature in database
8 changed files with 9 additions and 9 deletions

View File

@ -62,7 +62,7 @@ export default function SettingsPage() {
}; };
return ( return (
<div className="mx-auto max-w-[1040px]"> <div>
<div> <div>
<h1 className="text-2xl font-bold tracking-tight text-foreground"> <h1 className="text-2xl font-bold tracking-tight text-foreground">
Settings Settings
@ -73,7 +73,7 @@ export default function SettingsPage() {
</p> </p>
</div> </div>
<div className="mt-6 grid gap-6 lg:grid-cols-[236px_1fr] lg:items-start"> <div className="mt-6 grid gap-6 lg:grid-cols-[236px_minmax(0,1fr)] lg:items-start">
<SettingsRail active={section} onSelect={go} hints={hints} /> <SettingsRail active={section} onSelect={go} hints={hints} />
<div className="min-w-0">{panel[section]}</div> <div className="min-w-0">{panel[section]}</div>
</div> </div>

View File

@ -22,7 +22,7 @@ import { SettingsPanelHead } from "./settings-panel-head";
export function AppearancePanel() { export function AppearancePanel() {
const { theme, setTheme, mode, setMode } = useTheme(); const { theme, setTheme, mode, setMode } = useTheme();
return ( return (
<section className="animate-in fade-in-50 duration-200"> <section className="max-w-3xl animate-in fade-in-50 duration-200">
<SettingsPanelHead <SettingsPanelHead
title="Appearance" title="Appearance"
description="Set the mode and accent colour used across the app. Saved to this device — try it, it changes live." description="Set the mode and accent colour used across the app. Saved to this device — try it, it changes live."

View File

@ -68,7 +68,7 @@ export function DealsSettings() {
} }
return ( return (
<section className="animate-in fade-in-50 duration-200"> <section className="max-w-2xl animate-in fade-in-50 duration-200">
<SettingsPanelHead <SettingsPanelHead
title="Deals & currency" title="Deals & currency"
description="The currency used for new deals and for pipeline and dashboard totals." description="The currency used for new deals and for pipeline and dashboard totals."

View File

@ -17,7 +17,7 @@ export function FieldsAndTagsPanel() {
const canEditSettings = useCan('edit-settings'); const canEditSettings = useCan('edit-settings');
return ( return (
<section className="animate-in fade-in-50 space-y-4 duration-200"> <section className="max-w-3xl animate-in fade-in-50 space-y-4 duration-200">
<SettingsPanelHead <SettingsPanelHead
title="Fields & tags" title="Fields & tags"
description="Two ways to organize contacts: colour-coded tags for quick grouping, and custom fields for structured data." description="Two ways to organize contacts: colour-coded tags for quick grouping, and custom fields for structured data."

View File

@ -205,7 +205,7 @@ export function ProfileForm() {
: '—'; : '—';
return ( return (
<section className="animate-in fade-in-50 duration-200"> <section className="max-w-2xl animate-in fade-in-50 duration-200">
<SettingsPanelHead <SettingsPanelHead
title="Your profile" title="Your profile"
description="How you show up across the app. Your avatar and name appear in the header, sidebar, and anywhere your teammates see you." description="How you show up across the app. Your avatar and name appear in the header, sidebar, and anywhere your teammates see you."

View File

@ -10,7 +10,7 @@ import { SettingsPanelHead } from './settings-panel-head';
*/ */
export function SecurityPanel() { export function SecurityPanel() {
return ( return (
<section className="animate-in fade-in-50 duration-200"> <section className="max-w-2xl animate-in fade-in-50 duration-200">
<SettingsPanelHead <SettingsPanelHead
title="Login & security" title="Login & security"
description="Change your password and sign out of your devices. These keep your account safe." description="Change your password and sign out of your devices. These keep your account safe."

View File

@ -248,7 +248,7 @@ export function SettingsOverview({
</Card> </Card>
{/* Status tiles */} {/* Status tiles */}
<div className="mt-4 grid gap-3 sm:grid-cols-2"> <div className="mt-4 grid gap-3 sm:grid-cols-2 xl:grid-cols-3">
{tiles.map(({ section, loading, subtitle }) => { {tiles.map(({ section, loading, subtitle }) => {
const meta = SECTION_META[section]; const meta = SECTION_META[section];
const Icon = meta.icon; const Icon = meta.icon;

View File

@ -515,7 +515,7 @@ export function TemplateManager() {
</CardContent> </CardContent>
</Card> </Card>
) : ( ) : (
<div className="grid gap-3"> <div className="grid gap-3 xl:grid-cols-2">
{templates.map((template) => { {templates.map((template) => {
const statusKey = template.status || 'DRAFT'; const statusKey = template.status || 'DRAFT';
const status = templateStatusConfig[statusKey]; const status = templateStatusConfig[statusKey];