diff --git a/docs/DESIGN.md b/docs/DESIGN.md index ee9f90b..f9ce538 100644 --- a/docs/DESIGN.md +++ b/docs/DESIGN.md @@ -30,11 +30,12 @@ Every page's root is `` from `@xenia/ui`. It provides: ``` -- `top={}` keeps a tab strip above the scrolling part (Online orders, Settings). The tab is kept in the address (`?tab=`). +- `top={}` keeps a tab strip above the scrolling part (Online orders, Settings). The tab is kept in the address (`?tab=`). Tabs that don't fit **wrap onto another row**; they are never hidden in a sideways scroll (6F.0, owner 2026-11-23). - `header={}` with `top`: the page's title and description come **first**, then the tabs (Offers & pricing). Each tab then starts with its own head: title, description, its "New" button at the top right. - `fit`: the page is exactly the screen's height and doesn't scroll; its `Pane`s do, each on its own (Products). Put them in an element with `x-page__fill`. Phones scroll as usual. - The scrollbar's room is always kept (`scrollbar-gutter: stable`), so a short tab is exactly as wide as a long one. -- `width="form"` for settings and forms (centred at `--x-page-form-max`, 880 px). Lists, tables and dashboards use the default (full). +- Every page is full width, **Settings included** (6F.0, owner 2026-11-23: an 880 px Settings page looked narrower than the rest and cut its tabs). Settings and other pages of cards put them in ``: cards flow top to bottom, then into the next column, each column at least 34rem (two on 1080p, three on an ultrawide, one on a laptop or phone); `x-columns__wide` / `` spans all columns (an intro row, a wide editor). `width="form"` (880 px, centred) stays only for a single form that reads better narrow; no page uses it now. +- A settings row (`SettingRow`) keeps its control in a 16rem box on the right: selects and inputs fill it, switches and buttons sit at its right edge. - **Never** put `p-*`, `max-w-*`, `mx-auto`, `h-full` or `overflow-*` on a page's root, and never nest a second width limit inside it. - Checked by `tests/e2e/manager_layout.mjs` (1920×1080 and 3440×1440: every page fills / is centred, and scrolls). Add a new page to its `PAGES` list. @@ -45,6 +46,7 @@ Every page is on `` except Inventory → Stock (a placeholder). Two-column | Need | Use | Notes | |---|---|---| | A page | `Page`, `PageHeader` | §2 | +| Cards in columns (settings) | `Columns`, `ColumnsWide` | §2; a card never splits across two columns | | Filters / actions over a list | `Toolbar`, `ToolbarSpacer` | every control in it the same height; the search box grows | | Search | `SearchInput` | icon, clear button; `onChange(text)` | | Choose one / several | `Dropdown` (`multiple`) | **never a native `