@poodle64/ui 2026.10.25 → 2026.10.27

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (43) hide show
  1. package/README.md +142 -182
  2. package/dist/components/feedback/report-widget.svelte +8 -33
  3. package/dist/components/ui/app-dialog/app-dialog.svelte +2 -1
  4. package/dist/components/ui/app-identity/app-identity.svelte +4 -2
  5. package/dist/components/ui/app-identity/app-identity.svelte.d.ts +1 -1
  6. package/dist/components/ui/app-shell/app-shell.svelte +300 -147
  7. package/dist/components/ui/app-shell/app-shell.svelte.d.ts +15 -37
  8. package/dist/components/ui/app-shell/column-scope.svelte +15 -0
  9. package/dist/components/ui/app-shell/column-scope.svelte.d.ts +12 -0
  10. package/dist/components/ui/app-shell/index.d.ts +4 -2
  11. package/dist/components/ui/app-shell/index.js +4 -2
  12. package/dist/components/ui/app-shell/page-aside.svelte +58 -0
  13. package/dist/components/ui/app-shell/page-aside.svelte.d.ts +30 -0
  14. package/dist/components/ui/app-shell/page-pane.svelte +73 -0
  15. package/dist/components/ui/app-shell/page-pane.svelte.d.ts +37 -0
  16. package/dist/components/ui/app-shell/page.d.ts +77 -0
  17. package/dist/components/ui/app-shell/page.js +45 -0
  18. package/dist/components/ui/app-shell/report.svelte.d.ts +10 -0
  19. package/dist/components/ui/app-shell/report.svelte.js +8 -0
  20. package/dist/components/ui/app-shell/types.d.ts +6 -4
  21. package/dist/components/ui/app-shell/types.js +7 -5
  22. package/dist/components/ui/collection-detail/collection-detail.svelte +1 -1
  23. package/dist/components/ui/content-skeleton/content-skeleton.svelte +1 -1
  24. package/dist/components/ui/context-column/context-column.svelte +47 -129
  25. package/dist/components/ui/context-column/context-column.svelte.d.ts +3 -5
  26. package/dist/components/ui/document-reader/document-reader.svelte +56 -24
  27. package/dist/components/ui/document-reader/document-reader.svelte.d.ts +5 -4
  28. package/dist/components/ui/page-section/page-section.svelte +1 -1
  29. package/dist/components/ui/panel/panel.svelte +1 -0
  30. package/dist/components/ui/settings-shell/settings-shell.svelte +67 -81
  31. package/dist/components/ui/settings-shell/settings-shell.svelte.d.ts +21 -60
  32. package/dist/styles.css +248 -120
  33. package/package.json +1 -1
  34. package/registry/component-map.json +22 -15
  35. package/registry/component-map.md +8 -7
  36. package/dist/components/ui/app-shell/measure.d.ts +0 -28
  37. package/dist/components/ui/app-shell/measure.js +0 -21
  38. package/dist/components/ui/app-shell/padding.d.ts +0 -26
  39. package/dist/components/ui/app-shell/padding.js +0 -26
  40. package/dist/components/ui/list-shell/index.d.ts +0 -2
  41. package/dist/components/ui/list-shell/index.js +0 -2
  42. package/dist/components/ui/list-shell/list-shell.svelte +0 -85
  43. package/dist/components/ui/list-shell/list-shell.svelte.d.ts +0 -39
@@ -1,7 +1,7 @@
1
1
  # @poodle64/ui — situation → component map
2
2
 
3
3
  <!-- GENERATED by scripts/generate-registry.mjs from scripts/situations.json + package source. DO NOT EDIT. -->
4
- Generated from `@poodle64/ui@2026.10.25`. 76 components, 20 situations.
4
+ Generated from `@poodle64/ui@2026.10.27`. 75 components, 20 situations.
5
5
 
6
6
  **Read this before writing a `<div>`.** Find the SITUATION you are in below, then compose the component named for it — do not hand-build it from raw `Card` or utility classes. Import is `import { Name } from '<import path>'`. Props marked `?` are optional. This map is the retrieval step the [`frontend-design` skill] makes mandatory; the [CHI 2026 study] measured composing-from-a-registry at 95% design-system compliance against 71% for writing the CSS from a prose style guide.
7
7
 
@@ -157,11 +157,11 @@ _People, organisations, sources or any entities as nodes and their relations as
157
157
 
158
158
  ## The frame every route shares
159
159
 
160
- _The standing chrome — the app shell and its nav, the one page-title treatment and its trail, the page's own container and sections, the persistent right-hand context column, a foldable working list beside the page's own content._
160
+ _The standing chrome — the app shell and its nav, the one page-title treatment and its trail, the page's own container and sections — and the page type a route declares (`pageType`: reading, panel or tool), which decides every width, gutter and second column so a page writes none._
161
161
 
162
162
  | Component | Import | Key props | Reach for it instead of |
163
163
  | --- | --- | --- | --- |
164
- | `AppShell` | `@poodle64/ui/app-shell` | `nav, currentPath, brandTitle?, actions?, context?, children` | a bespoke nav rail + header layout per app |
164
+ | `AppShell` | `@poodle64/ui/app-shell` | `nav, currentPath, pageType?, title?, brandTitle?, actions?, context?, children` | a bespoke nav rail + header layout per app, and any width, padding or measure a page sets for itself |
165
165
  | `ShellControls` | `@poodle64/ui/app-shell` | `children` | a scope row (entity, financial year, chart/table) hand-placed above the page body; the shell's top bar carries it |
166
166
  | `Segmented` | `@poodle64/ui/segmented` | `value, options, label, size?` | a hand-built row of aria-pressed buttons for a small fixed choice |
167
167
  | `PageHeader` | `@poodle64/ui/page-header` | `title?, eyebrow?, breadcrumbs?, icon?, subtitle?, info?, meta?, actions?` | a hand-written <h1> and title bar (the drift gate fails this) |
@@ -169,17 +169,18 @@ _The standing chrome — the app shell and its nav, the one page-title treatment
169
169
  | `PageContainer` | `@poodle64/ui/page-container` | `children` | a per-page wrapper picking its own vertical rhythm (space-y-6, gap-10, …) |
170
170
  | `PageSection` | `@poodle64/ui/page-section` | `title, level?, description?, count?, actions?, children?, id?` | a hand-styled section heading (an uppercase kicker, text-lg font-semibold, a display h2) and its own gap to the content under it |
171
171
  | `RecordSwitcher` | `@poodle64/ui/record-switcher` | `name, groups, current?, noun?, placeholder?, icon?, all?, pages?, separator?` | a bare record name beside a small chevrons button in the top bar, and a dropdown of names with no search, groups or thumbnails; the record's own page tabs come with it |
172
- | `ContextColumn` | `@poodle64/ui/context-column` | `stats?, statsTitle?, statsInfo?, detail?, title?, subtitle?, onClose?, children?, documentPane?, ariaLabel?` | a hand-built right-hand <aside> with a stat card and a detail pane; on a record page, the one opened item (title, close, an inner scroll) and its DocumentPane, in the column's place or beside it once the page's row has room |
173
- | `ListShell` | `@poodle64/ui/list-shell` | `title, children, label?, open?, actions?` | a module hand-rolling its own foldable second column beside the rail — a queue, an inbox, a working list |
172
+ | `PagePane` | `@poodle64/ui/app-shell` | `label, body, icon?, location?, remember?, fill?, foot?, folded?` | a module hand-rolling a second column flush against the rail (past questions, a queue, a working list), its width, fold and phone sheet |
173
+ | `PageAside` | `@poodle64/ui/app-shell` | `label, children?, body?, icon?` | a hand-placed right-hand column or a sticky sidebar beside a page's content, with its own width and breakpoint |
174
+ | `ContextColumn` | `@poodle64/ui/context-column` | `stats?, statsTitle?, statsInfo?, detail?, title?, subtitle?, onClose?, children?, documentPane?, ariaLabel?` | a hand-built right-hand <aside> with a stat card and a detail pane; on a record page, the one opened item (title, close, an inner scroll) and its DocumentPane; the page aside places it |
174
175
  | `AppIdentity` | `@poodle64/ui/app-identity` | `user, workspace?, role?, entitlements?, onSignOut, onAccountSettings?, onSwitchTheme?` | a hand-rolled account/avatar dropdown wired to raw DropdownMenu.* + Avatar.* |
175
176
 
176
177
  ## The settings destination
177
178
 
178
- _The one settings surface: a grouped section list beside the section you are reading, inside AppShell’s content area (give AppShell padded={false}). Sections are grouped by whose setting it is — the person’s, then the workspace’s. The sections themselves are Panels._
179
+ _The one settings surface: a grouped section list as a panel page's pane beside the section you are reading (the route declares pageType 'panel'). Sections are grouped by whose setting it is — the person's, then the workspace's. The sections themselves are Panels._
179
180
 
180
181
  | Component | Import | Key props | Reach for it instead of |
181
182
  | --- | --- | --- | --- |
182
- | `SettingsShell` | `@poodle64/ui/settings-shell` | `sections, children, currentPath?, selected?, onSelect?, listLabel?` | a hand-built two-pane settings layout, or a card of tab links in a grid, per app |
183
+ | `SettingsShell` | `@poodle64/ui/settings-shell` | `sections, children, currentPath?, selected?, onSelect?, listLabel?, title?` | a hand-built two-pane settings layout, or a card of tab links in a grid, per app |
183
184
  | `SettingsRow` | `@poodle64/ui/settings-row` | `label, description?, controlId?, children` | a hand-built label + description + control row inside a settings Panel (use Panel pad={false}) |
184
185
  | `About` | `@poodle64/ui/about` | `name, version, description?, brand?, links?, diagnostics?, writeClipboard?` | a per-app About page or dialogue with duplicated version, links and diagnostic copying |
185
186
 
@@ -1,28 +0,0 @@
1
- /**
2
- * The content measure: how wide the page body is allowed to get.
3
- *
4
- * A named scale rather than a width, because a width at the call site is the
5
- * problem this exists to solve. Surveyed at 2560px, one consumer had six
6
- * distinct caps across nine routes — `max-w-4xl` here, `max-w-[1600px]` there,
7
- * a `max-w-md` form somewhere else — each written by whoever built that page,
8
- * none of them wrong on its own, and no two agreeing. Between them they used
9
- * 15% to 79% of the width available. A scale with four names cannot drift like
10
- * that: it is one decision, taken once, in the layout.
11
- *
12
- * The tiers resolve through `--ds-shell-measure-*` custom properties (see
13
- * `styles.css`), so an app retunes any of them in one declaration.
14
- */
15
- /**
16
- * - `prose` — a genuine reading measure (`40rem`, about 70 characters) for long-form running text.
17
- * - `page` — everyday pages: forms, detail views, settings (`80rem`).
18
- * - `wide` — indexes, card grids, tables, dashboards (`120rem`).
19
- * - `full` — no cap. The default, so omitting `measure` changes nothing.
20
- *
21
- * The 80rem tier is `page` rather than `default` on purpose. The prop's default
22
- * is `full`, and a value literally named `default` that you do NOT get by
23
- * default is a trap a reader falls into once each. It is also not `standard`,
24
- * which this package already retired for being a name that says nothing.
25
- */
26
- export type ShellMeasure = 'prose' | 'page' | 'wide' | 'full';
27
- /** Every measure, narrowest first — the order the scale is documented in. */
28
- export declare const SHELL_MEASURES: readonly ["prose", "page", "wide", "full"];
@@ -1,21 +0,0 @@
1
- /**
2
- * The content measure: how wide the page body is allowed to get.
3
- *
4
- * A named scale rather than a width, because a width at the call site is the
5
- * problem this exists to solve. Surveyed at 2560px, one consumer had six
6
- * distinct caps across nine routes — `max-w-4xl` here, `max-w-[1600px]` there,
7
- * a `max-w-md` form somewhere else — each written by whoever built that page,
8
- * none of them wrong on its own, and no two agreeing. Between them they used
9
- * 15% to 79% of the width available. A scale with four names cannot drift like
10
- * that: it is one decision, taken once, in the layout.
11
- *
12
- * The tiers resolve through `--ds-shell-measure-*` custom properties (see
13
- * `styles.css`), so an app retunes any of them in one declaration.
14
- */
15
- /** Every measure, narrowest first — the order the scale is documented in. */
16
- export const SHELL_MEASURES = [
17
- 'prose',
18
- 'page',
19
- 'wide',
20
- 'full'
21
- ];
@@ -1,26 +0,0 @@
1
- /**
2
- * The page padding the shell gives its content area.
3
- *
4
- * A constant rather than a literal in app-shell.svelte, because it is no longer
5
- * declared in one place: SettingsShell runs inside an UNPADDED content area (its
6
- * section list has to reach the area's edges to read as a pane rather than a
7
- * floating card) and then pads its own content pane, which must land on the same
8
- * rhythm as every other page or the settings destination is the one route whose
9
- * text sits somewhere else.
10
- *
11
- * Utilities rather than a class in styles.css, deliberately: both consumers pass
12
- * this through `cn()`, so an app overriding the padding — `mainClass="px-0"`, a
13
- * flush table — still resolves through tailwind-merge. A base-layer class would
14
- * be invisible to it, and the utility would win by layer order instead of by
15
- * being last, which is the cascade trap recorded against `.ds-nav`'s ink.
16
- *
17
- * The bottom pad carries `env(safe-area-inset-bottom)` so the last row of a page
18
- * clears a home-indicator gesture bar.
19
- *
20
- * The trailing `::after` is `--ds-report-reserve`, the footprint the mounted
21
- * report widget declares, so a page's last row can scroll clear of the button
22
- * floating over its corner. An element rather than padding: a page taller than
23
- * the content area overflows this box, which leaves its padding behind at the
24
- * area's foot, while a last flex item follows the overflow to its end.
25
- */
26
- export declare const CONTENT_PADDING = "px-4 pt-5 pb-[calc(1.25rem+env(safe-area-inset-bottom))] sm:px-6 md:px-8 md:pt-7 md:pb-[calc(1.75rem+env(safe-area-inset-bottom))] 2xl:px-12 after:block after:flex-none after:h-[var(--ds-report-reserve,0px)]";
@@ -1,26 +0,0 @@
1
- /**
2
- * The page padding the shell gives its content area.
3
- *
4
- * A constant rather than a literal in app-shell.svelte, because it is no longer
5
- * declared in one place: SettingsShell runs inside an UNPADDED content area (its
6
- * section list has to reach the area's edges to read as a pane rather than a
7
- * floating card) and then pads its own content pane, which must land on the same
8
- * rhythm as every other page or the settings destination is the one route whose
9
- * text sits somewhere else.
10
- *
11
- * Utilities rather than a class in styles.css, deliberately: both consumers pass
12
- * this through `cn()`, so an app overriding the padding — `mainClass="px-0"`, a
13
- * flush table — still resolves through tailwind-merge. A base-layer class would
14
- * be invisible to it, and the utility would win by layer order instead of by
15
- * being last, which is the cascade trap recorded against `.ds-nav`'s ink.
16
- *
17
- * The bottom pad carries `env(safe-area-inset-bottom)` so the last row of a page
18
- * clears a home-indicator gesture bar.
19
- *
20
- * The trailing `::after` is `--ds-report-reserve`, the footprint the mounted
21
- * report widget declares, so a page's last row can scroll clear of the button
22
- * floating over its corner. An element rather than padding: a page taller than
23
- * the content area overflows this box, which leaves its padding behind at the
24
- * area's foot, while a last flex item follows the overflow to its end.
25
- */
26
- export const CONTENT_PADDING = 'px-4 pt-5 pb-[calc(1.25rem+env(safe-area-inset-bottom))] sm:px-6 md:px-8 md:pt-7 md:pb-[calc(1.75rem+env(safe-area-inset-bottom))] 2xl:px-12 after:block after:flex-none after:h-[var(--ds-report-reserve,0px)]';
@@ -1,2 +0,0 @@
1
- export { default as ListShell } from './list-shell.svelte';
2
- export { default } from './list-shell.svelte';
@@ -1,2 +0,0 @@
1
- export { default as ListShell } from './list-shell.svelte';
2
- export { default } from './list-shell.svelte';
@@ -1,85 +0,0 @@
1
- <script lang="ts">
2
- /**
3
- * ListShell — a module's working list, folded away and brought back by
4
- * the app that owns it, beside the content it serves. Not an AppShell
5
- * slot: `sidebar` was removed 2026.8.11 after two apps disagreed on
6
- * where a module's own PAGES render (operator ruling 21/08/2026); a
7
- * working list is data, not navigation, so it is a page-level companion
8
- * like `SettingsShell`/`ContextColumn` — pair with `padded={false}` on
9
- * AppShell, as `SettingsShell` requires. `open` is the caller's own
10
- * bindable state, never persisted here; closed, this renders nothing,
11
- * and reopening is the caller's own control, placed wherever the module
12
- * chooses. Hidden below `md` at every state.
13
- */
14
- import type { Snippet } from 'svelte';
15
- import type { HTMLAttributes } from 'svelte/elements';
16
- import { cn, type WithElementRef } from '../../../utils.js';
17
- import PanelLeftClose from '@lucide/svelte/icons/panel-left-close';
18
-
19
- let {
20
- title,
21
- label = title,
22
- open = $bindable(true),
23
- actions,
24
- children,
25
- ref = $bindable(null),
26
- class: className,
27
- ...restProps
28
- }: WithElementRef<HTMLAttributes<HTMLElement>> & {
29
- /** The list's heading, in the shell's display face. */
30
- title: string;
31
- /**
32
- * The landmark's accessible name. Defaults to `title` — the visible
33
- * heading already says what this is, so a module only sets `label`
34
- * separately when the heading text would not stand alone as a name
35
- * (WCAG 2.4.1), e.g. a heading that leads with a live count.
36
- */
37
- label?: string;
38
- /**
39
- * Whether the list is open. Bindable, and NOT persisted by this
40
- * component — bind it to whatever the module already uses to persist a
41
- * user preference across a reload.
42
- */
43
- open?: boolean;
44
- /** Leading header actions beside the title — an "Add" button, a filter. */
45
- actions?: Snippet;
46
- /** The list body: tabs, group headings, rows — entirely the module's own. */
47
- children: Snippet;
48
- } = $props();
49
-
50
- const listId = $props.id();
51
- </script>
52
-
53
- {#if open}
54
- <aside
55
- bind:this={ref}
56
- id={listId}
57
- aria-label={label}
58
- class={cn(
59
- 'bg-shell text-shell-foreground border-border hidden w-[25rem] flex-none flex-col border-e md:flex',
60
- className
61
- )}
62
- {...restProps}
63
- >
64
- <div class="flex flex-none items-center gap-2 px-5 pt-5 pb-3">
65
- <h2 class="font-display text-display flex-1 truncate font-semibold tracking-[var(--ds-font-display-tracking,-0.025em)]">
66
- {title}
67
- </h2>
68
- {#if actions}{@render actions()}{/if}
69
- <button
70
- type="button"
71
- onclick={() => (open = false)}
72
- aria-expanded="true"
73
- aria-controls={listId}
74
- aria-label={`Fold ${label} away`}
75
- title={`Fold ${label} away`}
76
- class="text-shell-muted-foreground hover:text-shell-foreground border-border grid size-9 flex-none place-items-center rounded-md border transition-colors"
77
- >
78
- <PanelLeftClose class="size-4" />
79
- </button>
80
- </div>
81
- <div class="flex min-h-0 flex-1 flex-col overflow-y-auto">
82
- {@render children()}
83
- </div>
84
- </aside>
85
- {/if}
@@ -1,39 +0,0 @@
1
- /**
2
- * ListShell — a module's working list, folded away and brought back by
3
- * the app that owns it, beside the content it serves. Not an AppShell
4
- * slot: `sidebar` was removed 2026.8.11 after two apps disagreed on
5
- * where a module's own PAGES render (operator ruling 21/08/2026); a
6
- * working list is data, not navigation, so it is a page-level companion
7
- * like `SettingsShell`/`ContextColumn` — pair with `padded={false}` on
8
- * AppShell, as `SettingsShell` requires. `open` is the caller's own
9
- * bindable state, never persisted here; closed, this renders nothing,
10
- * and reopening is the caller's own control, placed wherever the module
11
- * chooses. Hidden below `md` at every state.
12
- */
13
- import type { Snippet } from 'svelte';
14
- import type { HTMLAttributes } from 'svelte/elements';
15
- import { type WithElementRef } from '../../../utils.js';
16
- type $$ComponentProps = WithElementRef<HTMLAttributes<HTMLElement>> & {
17
- /** The list's heading, in the shell's display face. */
18
- title: string;
19
- /**
20
- * The landmark's accessible name. Defaults to `title` — the visible
21
- * heading already says what this is, so a module only sets `label`
22
- * separately when the heading text would not stand alone as a name
23
- * (WCAG 2.4.1), e.g. a heading that leads with a live count.
24
- */
25
- label?: string;
26
- /**
27
- * Whether the list is open. Bindable, and NOT persisted by this
28
- * component — bind it to whatever the module already uses to persist a
29
- * user preference across a reload.
30
- */
31
- open?: boolean;
32
- /** Leading header actions beside the title — an "Add" button, a filter. */
33
- actions?: Snippet;
34
- /** The list body: tabs, group headings, rows — entirely the module's own. */
35
- children: Snippet;
36
- };
37
- declare const ListShell: import("svelte").Component<$$ComponentProps, {}, "ref" | "open">;
38
- type ListShell = ReturnType<typeof ListShell>;
39
- export default ListShell;