# Lovable — Settings Page UX Kit **GitHub repo:** `saravanakumardb/temp_lovable-settings-ux-kit` ## Push Instructions - Push directly to `main` — do NOT open a PR - Only modify files in this repo ## Rules - No `console.log` - No network calls — mock data / localStorage only - No hardcoded colors — no hex, no rgb/rgba/hsl, no `bg-[#123456]` Tailwind classes - Do NOT commit `.env*`, `.next/`, `node_modules/`, `.vercel/` - pnpm only - `pnpm run check` must pass (`tsc --noEmit` + `eslint`) - `pnpm run build` must pass (`next build --webpack`) ## CSS Token Contract Define in `src/app/globals.css` under `:root` (add `.dark` override): - `--ux-bg` — page background - `--ux-surface` — card/panel surface - `--ux-surface-2` — elevated surface - `--ux-border` — borders - `--ux-text` — primary text - `--ux-text-muted` — secondary text - `--ux-accent` — primary accent - `--ux-accent-foreground` — text on accent - `--ux-danger` — destructive/error - `--ux-warning` — warning - `--ux-success` — success - `--ux-ring` — focus ring - `--ux-shadow` — shadows Use only via Tailwind: `bg-[var(--ux-surface)]`, `text-[var(--ux-text)]`, `border-[var(--ux-border)]` ## Component Architecture - Reusable components → `src/components/` - Pages in `src/app/**` compose components only - Components must NOT import from `src/app/**` ## Stack - Next.js 16 App Router, React 19, TypeScript strict - TailwindCSS v4, pnpm ## Goal Build a **UI/UX-rich settings dashboard** micro-app with premium settings patterns reusable across dashboards and product web apps. Design-led: spacing, typography, states, interaction polish. ## Pages - `/` overview landing - `/settings` main settings dashboard - `/settings/account` - `/settings/notifications` - `/settings/privacy` - `/settings/appearance` ## App Shell Left settings nav, main content area, sticky top header: search settings (filters visible rows), "Reset changes" button, save status indicator (Saved / Saving / Error) ## Settings Rows Section headers with description, rows with: label, description, control (toggle/select/input), optional inline error ## Autosave (local-only) Persist to localStorage, simulate async save: - "Saving…" for 400–800ms → "Saved" - Demo toggle to simulate "Save failed" ## Danger Zone "Delete local profile" — confirm dialog requiring user to type `DELETE` ## UX Bar Premium spacing/typography, subtle animations, full keyboard nav, token-driven focus rings, mobile responsive (nav → drawer on small screens) ## Verification ``` pnpm install && pnpm run check && pnpm run build ```