@poodle64/ui 2026.10.22 → 2026.10.24
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.
- package/README.md +23 -16
- package/dist/components/alerts/alert-bell.svelte +5 -3
- package/dist/components/alerts/alert-bell.svelte.d.ts +1 -0
- package/dist/components/feedback/report-widget.svelte +13 -3
- package/dist/components/feedback/report-widget.svelte.d.ts +1 -0
- package/dist/components/settings/settings-page.svelte +6 -2
- package/dist/components/settings/settings-page.svelte.d.ts +1 -0
- package/dist/components/ui/app-dialog/app-dialog.svelte +15 -3
- package/dist/components/ui/app-dialog/app-dialog.svelte.d.ts +2 -0
- package/dist/components/ui/app-identity/app-identity.svelte +10 -1
- package/dist/components/ui/app-identity/app-identity.svelte.d.ts +6 -0
- package/dist/components/ui/app-shell/app-shell.svelte +1 -1
- package/dist/components/ui/app-shell/app-shell.svelte.d.ts +1 -1
- package/dist/components/ui/app-shell/measure.d.ts +1 -1
- package/dist/components/ui/collection-detail/collection-detail.svelte +1 -1
- package/dist/components/ui/context-column/context-column.svelte +29 -15
- package/dist/components/ui/info-tip/info-tip.svelte +5 -1
- package/dist/components/ui/ledger/ledger.svelte +2 -2
- package/dist/components/ui/list-toolbar/list-toolbar.svelte +37 -27
- package/dist/components/ui/panel/panel.svelte +5 -5
- package/dist/components/ui/panel/panel.svelte.d.ts +4 -4
- package/dist/components/ui/record-switcher/record-switcher.svelte +36 -2
- package/dist/components/ui/schema-form/schema-form.svelte +5 -3
- package/dist/components/ui/schema-form/types.d.ts +8 -0
- package/dist/components/ui/stat-list/stat-list.svelte +14 -9
- package/dist/components/ui/stat-list/stat-list.svelte.d.ts +2 -0
- package/dist/styles.css +8 -8
- package/package.json +1 -1
- package/registry/component-map.json +1 -1
- package/registry/component-map.md +1 -1
package/README.md
CHANGED
|
@@ -98,8 +98,8 @@ rather than rebuilding it:
|
|
|
98
98
|
| `page-section` | A section of a page: `title` at `level` 2 or 3, an optional `description`, `count` and `actions`, and its content at one distance below. |
|
|
99
99
|
| `document-reader` | A document to read: PageHeader, the body (`html` the app sanitised, or `children`) in `.ds-prose` at the reading measure, and a contents list from its own headings. See [A document to read](#a-document-to-read). |
|
|
100
100
|
| `content-skeleton` | A region loading, shaped like what replaces it: `rows`, `tiles` or `prose`. A whole page waiting is LoadingState. |
|
|
101
|
-
| `panel` | The generic titled card, and the settings section: optional icon, a
|
|
102
|
-
| `list-toolbar` | The bar above a list, on the page ground: title, count, icon actions named by their tooltips, one labelled action. The Ledger and the RecordList draw theirs with it. |
|
|
101
|
+
| `panel` | The generic titled card, and the settings section: optional icon, a short `subtitle` or a longer `description`, both wrapping, trailing `action`s, a body that can opt out of padding or scroll inside the card (`scroll`), an optional `footer` strip for Save/Cancel, and `tone="destructive"` for a danger zone. There is no `SettingsSection`; see [The settings destination](#the-settings-destination). |
|
|
102
|
+
| `list-toolbar` | The bar above a list, on the page ground: title, count (both wrap when crowded, after the controls drop to their own line), icon actions named by their tooltips, one labelled action. The Ledger and the RecordList draw theirs with it. |
|
|
103
103
|
| `record-list` | The ledger's look for a list that is not money. See [Lists that are not money](#lists-that-are-not-money). |
|
|
104
104
|
| `record-switcher` | The open record's whole name as the top bar's control, its menu finding, grouping and picturing every record, and the record's pages as tabs. |
|
|
105
105
|
| `document-pane` | One document beside what it belongs to: titled, closable, its page fitted, with paging and zoom (a `PageCanvas` in a `Panel`). |
|
|
@@ -429,8 +429,8 @@ all three serve any route:
|
|
|
429
429
|
</Panel>
|
|
430
430
|
```
|
|
431
431
|
|
|
432
|
-
`description`
|
|
433
|
-
|
|
432
|
+
`description` and `subtitle` both wrap, never end in an ellipsis; the subtitle
|
|
433
|
+
is the short qualifier under the title. Carry one or the other. A page writes a run of `Panel`s and no
|
|
434
434
|
wrapper: the pane stacks them on the package's section rhythm itself.
|
|
435
435
|
|
|
436
436
|
### A working list beside a page's own content
|
|
@@ -489,7 +489,7 @@ How wide the page body may get, chosen once in the layout from a scale of four:
|
|
|
489
489
|
|
|
490
490
|
| Value | Width | Reach for it when the page is |
|
|
491
491
|
| ------- | -------- | -------------------------------------------------------------------- |
|
|
492
|
-
| `prose` | `
|
|
492
|
+
| `prose` | `40rem` | long-form running text: documentation, an article, a policy, a guide |
|
|
493
493
|
| `page` | `80rem` | an everyday page: a form, a detail view, settings, a wizard |
|
|
494
494
|
| `wide` | `120rem` | an index or a dashboard: card grids, tables, charts, board columns |
|
|
495
495
|
| `full` | no cap | a canvas that should use the whole panel: a map, a diagram, a board |
|
|
@@ -512,16 +512,17 @@ names cannot drift like that.
|
|
|
512
512
|
span a large display would be worse than what it replaces, and worse everywhere
|
|
513
513
|
at once. Measured in Chromium at 2560px: the same paragraph runs to **311
|
|
514
514
|
characters per line** uncapped, against an accepted band of 45–90 for continuous
|
|
515
|
-
text. `prose` puts it at
|
|
516
|
-
|
|
517
|
-
|
|
515
|
+
text. `prose` puts it at about 70. It is stated in `rem`, not `ch`: `ch` resolves
|
|
516
|
+
against each element's own font size, so a lead, a paragraph and a small intro in
|
|
517
|
+
one column ended at three right edges. A root-relative length gives every block
|
|
518
|
+
the same one.
|
|
518
519
|
|
|
519
520
|
Every tier is a CSS custom property, so an app retunes one without waiting on a
|
|
520
521
|
release of this package:
|
|
521
522
|
|
|
522
523
|
```css
|
|
523
524
|
:root {
|
|
524
|
-
--ds-shell-measure-prose:
|
|
525
|
+
--ds-shell-measure-prose: 36rem;
|
|
525
526
|
--ds-shell-measure-page: 72rem;
|
|
526
527
|
--ds-shell-measure-wide: 100rem;
|
|
527
528
|
}
|
|
@@ -532,10 +533,9 @@ Two things worth knowing before you set it:
|
|
|
532
533
|
- **The cap is a ceiling, never a floor.** `page` caps at 80rem; a 1440px laptop
|
|
533
534
|
has less than that available, so nothing changes there. A measure never narrows
|
|
534
535
|
a window that was already narrower than the tier.
|
|
535
|
-
- **`prose`
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
are lengths and never move.
|
|
536
|
+
- **`prose` is a length, so it does not follow the font.** Text set larger or
|
|
537
|
+
smaller than the body fits more or fewer characters in the same column and
|
|
538
|
+
ends at the same right edge as its neighbours; that is the point of it.
|
|
539
539
|
- **The cap is the border box, so `padded` spends its padding inside it.**
|
|
540
540
|
`measure="page"` with the default padding is 80rem of box holding 78rem of
|
|
541
541
|
content, which is the same arithmetic as the `mx-auto max-w-4xl px-6` idiom it
|
|
@@ -562,9 +562,9 @@ measure. Cap the block, not the route:
|
|
|
562
562
|
|
|
563
563
|
Same attribute and same custom properties as the shell's own measure, so the
|
|
564
564
|
block retunes when the scale does. That is the point of it: the alternative an
|
|
565
|
-
app reaches for is a local `max-w-prose` or `max-w-[72ch]`, a number typed once
|
|
565
|
+
app reaches for is a local `max-w-prose` or `max-w-[72ch]` (both in `ch`, so blocks of different sizes end at different edges), a number typed once
|
|
566
566
|
that never hears about a retune — four apps had written ten of them between
|
|
567
|
-
them and not one matched this package's own
|
|
567
|
+
them and not one matched this package's own measure.
|
|
568
568
|
|
|
569
569
|
`.ds-measure` caps and nothing else. `.ds-shell-measure`, which the shell puts
|
|
570
570
|
on its own content box, is that plus `margin-inline: auto` — right for a content
|
|
@@ -1015,7 +1015,7 @@ Settled here, the same in every module, and not props:
|
|
|
1015
1015
|
row with no note centres its title. The checkbox, the review chip, the date and
|
|
1016
1016
|
every single-value cell centre too.
|
|
1017
1017
|
- **One mark per kind.** A review chip (StatusBadge's dot and label on a tint)
|
|
1018
|
-
beside the title on line one, which
|
|
1018
|
+
beside the title on line one, which wraps (to two lines at most) before the chip gives any width; a synthetic row's "Not as printed" badge leads its second line and
|
|
1019
1019
|
opens the row in place to the lines it was made from.
|
|
1020
1020
|
- **PocketSmith's look.** No panel around the list; a head card exactly as wide
|
|
1021
1021
|
as the group cards, its columns on theirs; one rounded card per period with
|
|
@@ -1652,6 +1652,13 @@ routes by situation, so it stands outside the situation→component registry
|
|
|
1652
1652
|
for the same reason. `getSessionId()` reading null when telemetry is off is
|
|
1653
1653
|
ordinary, not an error: the report sends with a null `session_id`.
|
|
1654
1654
|
|
|
1655
|
+
The bottom-right corner is the widget's, and it publishes its footprint on the
|
|
1656
|
+
document: `--ds-report-reserve`, the room the shell leaves at a padded page's
|
|
1657
|
+
end so its last control scrolls clear; `--ds-report-beside`, where another
|
|
1658
|
+
fixed control in the corner sits, beside the trigger and inside that room
|
|
1659
|
+
(`ContextColumn`'s opener). A page control under the corner lifts the trigger
|
|
1660
|
+
with `--ds-report-clearance` instead (the librarian composer does).
|
|
1661
|
+
|
|
1655
1662
|
## The alerts bell
|
|
1656
1663
|
|
|
1657
1664
|
`@poodle64/ui/alerts` (`AlertBell`) is app machinery of the same kind: the app
|
|
@@ -33,8 +33,10 @@
|
|
|
33
33
|
|
|
34
34
|
let {
|
|
35
35
|
/** The app's alerts route, defaulting to the one every factory app serves. */
|
|
36
|
-
endpoint = '/api/alerts'
|
|
37
|
-
|
|
36
|
+
endpoint = '/api/alerts',
|
|
37
|
+
/** The request function; the app's own where its API client stamps every call (View as colleague, workspace). */
|
|
38
|
+
fetch: send
|
|
39
|
+
}: { endpoint?: string; fetch?: typeof fetch } = $props();
|
|
38
40
|
|
|
39
41
|
const POLL_MS = 60_000;
|
|
40
42
|
const TIMEOUT_MS = 30_000;
|
|
@@ -46,7 +48,7 @@
|
|
|
46
48
|
let open = $state(false);
|
|
47
49
|
|
|
48
50
|
function call(path: string, method = 'GET'): Promise<Response | null> {
|
|
49
|
-
return fetch(`${endpoint}/${path}`, { method, signal: AbortSignal.timeout(TIMEOUT_MS) }).catch(
|
|
51
|
+
return (send ?? fetch)(`${endpoint}/${path}`, { method, signal: AbortSignal.timeout(TIMEOUT_MS) }).catch(
|
|
50
52
|
() => null
|
|
51
53
|
);
|
|
52
54
|
}
|
|
@@ -36,9 +36,12 @@
|
|
|
36
36
|
/** Who reads a report, as "the <team> team". The app's own name, never an internal one. */
|
|
37
37
|
team = 'support',
|
|
38
38
|
/** Fired with the id the endpoint returned, once, on the success leg. */
|
|
39
|
-
onSubmitted
|
|
39
|
+
onSubmitted,
|
|
40
|
+
/** The request function; the app's own where its API client stamps every call (View as colleague, workspace). */
|
|
41
|
+
fetch: send
|
|
40
42
|
}: {
|
|
41
43
|
endpoint?: string;
|
|
44
|
+
fetch?: typeof fetch;
|
|
42
45
|
team?: string;
|
|
43
46
|
onSubmitted?: (id: string) => void;
|
|
44
47
|
} = $props();
|
|
@@ -62,7 +65,14 @@
|
|
|
62
65
|
$effect(() => {
|
|
63
66
|
const root = document.documentElement;
|
|
64
67
|
root.style.setProperty('--ds-report-reserve', 'calc(4.5rem - var(--ds-report-clearance, 0px))');
|
|
65
|
-
|
|
68
|
+
// The corner is this widget's. Another fixed control in it sits beside the
|
|
69
|
+
// trigger, this far in from the right edge with the same gap, so it stays
|
|
70
|
+
// inside the reserve too (ContextColumn's opener does).
|
|
71
|
+
root.style.setProperty('--ds-report-beside', '4.5rem');
|
|
72
|
+
return () => {
|
|
73
|
+
root.style.removeProperty('--ds-report-reserve');
|
|
74
|
+
root.style.removeProperty('--ds-report-beside');
|
|
75
|
+
};
|
|
66
76
|
});
|
|
67
77
|
|
|
68
78
|
async function submit() {
|
|
@@ -77,7 +87,7 @@
|
|
|
77
87
|
}
|
|
78
88
|
|
|
79
89
|
try {
|
|
80
|
-
const response = await fetch(endpoint, {
|
|
90
|
+
const response = await (send ?? fetch)(endpoint, {
|
|
81
91
|
method: 'POST',
|
|
82
92
|
headers: { 'Content-Type': 'application/json' },
|
|
83
93
|
body: JSON.stringify({
|
|
@@ -35,8 +35,11 @@
|
|
|
35
35
|
title = 'Application',
|
|
36
36
|
subtitle = "Runtime settings this deployment's operator can change without a code change or a deploy.",
|
|
37
37
|
/** What a 401 does: the app's own re-authentication (its API client's redirect), since only the app knows its sign-in. */
|
|
38
|
-
onunauthorized
|
|
38
|
+
onunauthorized,
|
|
39
|
+
/** The request function; the app's own where its API client stamps every call (View as colleague, workspace). */
|
|
40
|
+
fetch: send
|
|
39
41
|
}: {
|
|
42
|
+
fetch?: typeof fetch;
|
|
40
43
|
endpoint?: string;
|
|
41
44
|
title?: string;
|
|
42
45
|
subtitle?: string;
|
|
@@ -63,7 +66,7 @@
|
|
|
63
66
|
): Promise<{ data: T } | { failure: string }> {
|
|
64
67
|
let response: Response;
|
|
65
68
|
try {
|
|
66
|
-
response = await fetch(`${endpoint}/${path}`, {
|
|
69
|
+
response = await (send ?? fetch)(`${endpoint}/${path}`, {
|
|
67
70
|
...init,
|
|
68
71
|
credentials: 'include',
|
|
69
72
|
signal: AbortSignal.timeout(TIMEOUT_MS)
|
|
@@ -136,6 +139,7 @@
|
|
|
136
139
|
<LoadingState message="Loading…" class="mt-16" />
|
|
137
140
|
{:else}
|
|
138
141
|
<Panel title="Settings">
|
|
142
|
+
<!-- Not validated in the browser (SchemaForm's default): the server validates each PATCH and its refusal is the toast. -->
|
|
139
143
|
<SchemaForm schema={formSchema!} uischema={formLayout} value={formValue} onChange={handleChange} />
|
|
140
144
|
</Panel>
|
|
141
145
|
|
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
<script lang="ts">
|
|
2
2
|
import type { Snippet, Component } from 'svelte';
|
|
3
3
|
import * as Dialog from '../dialog/index.js';
|
|
4
|
+
import InfoTip from '../info-tip/info-tip.svelte';
|
|
4
5
|
import X from '@lucide/svelte/icons/x';
|
|
5
6
|
|
|
6
7
|
// The one dialogue frame: a titled header with optional icon and subtitle, a
|
|
@@ -11,6 +12,7 @@
|
|
|
11
12
|
onOpenChange,
|
|
12
13
|
title,
|
|
13
14
|
subtitle,
|
|
15
|
+
info,
|
|
14
16
|
icon: Icon,
|
|
15
17
|
size = 'md',
|
|
16
18
|
children,
|
|
@@ -35,6 +37,8 @@
|
|
|
35
37
|
onOpenChange?: (open: boolean) => void;
|
|
36
38
|
title: string;
|
|
37
39
|
subtitle?: string;
|
|
40
|
+
/** A tip beside the title, as PageHeader's: what the name means. */
|
|
41
|
+
info?: string;
|
|
38
42
|
icon?: Component<{ class?: string }>;
|
|
39
43
|
/**
|
|
40
44
|
* The dialogue's measure. Named rather than free-form for the same reason
|
|
@@ -81,9 +85,17 @@
|
|
|
81
85
|
</span>
|
|
82
86
|
{/if}
|
|
83
87
|
<div class="min-w-0 flex-1">
|
|
84
|
-
<
|
|
85
|
-
|
|
86
|
-
|
|
88
|
+
<div class="flex items-center gap-2">
|
|
89
|
+
<Dialog.Title class="font-display text-lg leading-tight font-semibold tracking-[var(--ds-font-display-tracking,-0.025em)]"
|
|
90
|
+
>{title}</Dialog.Title
|
|
91
|
+
>
|
|
92
|
+
{#if info}
|
|
93
|
+
<InfoTip
|
|
94
|
+
text={info}
|
|
95
|
+
class="text-muted-foreground/50 hover:text-muted-foreground size-4 transition-colors"
|
|
96
|
+
/>
|
|
97
|
+
{/if}
|
|
98
|
+
</div>
|
|
87
99
|
{#if subtitle}
|
|
88
100
|
<Dialog.Description class="text-muted-foreground mt-0.5 text-sm"
|
|
89
101
|
>{subtitle}</Dialog.Description
|
|
@@ -51,6 +51,7 @@
|
|
|
51
51
|
onAccountSettings,
|
|
52
52
|
onManageMembers,
|
|
53
53
|
onSwitchTheme,
|
|
54
|
+
themeToggle = true,
|
|
54
55
|
links = []
|
|
55
56
|
}: {
|
|
56
57
|
user: { username: string; display_name: string | null; email: string | null };
|
|
@@ -78,6 +79,12 @@
|
|
|
78
79
|
onManageMembers?: () => void;
|
|
79
80
|
/** Override the theme action. Defaults to mode-watcher's toggleMode, matching AppShell. */
|
|
80
81
|
onSwitchTheme?: () => void;
|
|
82
|
+
/**
|
|
83
|
+
* Show the "Switch theme" row. Same name and default as AppShell's
|
|
84
|
+
* `themeToggle`; set both false in a dark-only (or light-only) app, so no
|
|
85
|
+
* theme control is left that does nothing.
|
|
86
|
+
*/
|
|
87
|
+
themeToggle?: boolean;
|
|
81
88
|
/**
|
|
82
89
|
* App destinations the fixed entries have no room for, rendered in their
|
|
83
90
|
* own group.
|
|
@@ -232,7 +239,9 @@
|
|
|
232
239
|
</DropdownMenu.Group>
|
|
233
240
|
{/if}
|
|
234
241
|
<DropdownMenu.Separator />
|
|
235
|
-
|
|
242
|
+
{#if themeToggle}
|
|
243
|
+
<DropdownMenu.Item onSelect={switchTheme}>Switch theme</DropdownMenu.Item>
|
|
244
|
+
{/if}
|
|
236
245
|
<DropdownMenu.Item onSelect={onAccountSettings}>Account settings</DropdownMenu.Item>
|
|
237
246
|
<DropdownMenu.Separator />
|
|
238
247
|
<DropdownMenu.Item class="text-status-error" onSelect={onSignOut}>Sign out</DropdownMenu.Item>
|
|
@@ -67,6 +67,12 @@ type $$ComponentProps = {
|
|
|
67
67
|
onManageMembers?: () => void;
|
|
68
68
|
/** Override the theme action. Defaults to mode-watcher's toggleMode, matching AppShell. */
|
|
69
69
|
onSwitchTheme?: () => void;
|
|
70
|
+
/**
|
|
71
|
+
* Show the "Switch theme" row. Same name and default as AppShell's
|
|
72
|
+
* `themeToggle`; set both false in a dark-only (or light-only) app, so no
|
|
73
|
+
* theme control is left that does nothing.
|
|
74
|
+
*/
|
|
75
|
+
themeToggle?: boolean;
|
|
70
76
|
/**
|
|
71
77
|
* App destinations the fixed entries have no room for, rendered in their
|
|
72
78
|
* own group.
|
|
@@ -202,7 +202,7 @@
|
|
|
202
202
|
onToggleTheme?: () => void;
|
|
203
203
|
padded?: boolean;
|
|
204
204
|
/**
|
|
205
|
-
* How wide the page body may get, from a named scale: `prose` (
|
|
205
|
+
* How wide the page body may get, from a named scale: `prose` (40rem, for
|
|
206
206
|
* long-form running text), `page` (80rem — forms, detail views,
|
|
207
207
|
* settings), `wide` (120rem — indexes, grids, tables, dashboards), or
|
|
208
208
|
* `full` (no cap).
|
|
@@ -159,7 +159,7 @@ type $$ComponentProps = {
|
|
|
159
159
|
onToggleTheme?: () => void;
|
|
160
160
|
padded?: boolean;
|
|
161
161
|
/**
|
|
162
|
-
* How wide the page body may get, from a named scale: `prose` (
|
|
162
|
+
* How wide the page body may get, from a named scale: `prose` (40rem, for
|
|
163
163
|
* long-form running text), `page` (80rem — forms, detail views,
|
|
164
164
|
* settings), `wide` (120rem — indexes, grids, tables, dashboards), or
|
|
165
165
|
* `full` (no cap).
|
|
@@ -13,7 +13,7 @@
|
|
|
13
13
|
* `styles.css`), so an app retunes any of them in one declaration.
|
|
14
14
|
*/
|
|
15
15
|
/**
|
|
16
|
-
* - `prose` — a genuine reading measure (`
|
|
16
|
+
* - `prose` — a genuine reading measure (`40rem`, about 70 characters) for long-form running text.
|
|
17
17
|
* - `page` — everyday pages: forms, detail views, settings (`80rem`).
|
|
18
18
|
* - `wide` — indexes, card grids, tables, dashboards (`120rem`).
|
|
19
19
|
* - `full` — no cap. The default, so omitting `measure` changes nothing.
|
|
@@ -110,7 +110,7 @@
|
|
|
110
110
|
<p class="text-muted-foreground text-sm">{collection.subtitle}</p>
|
|
111
111
|
{/if}
|
|
112
112
|
{#if collection.description}
|
|
113
|
-
<p class="mt-2
|
|
113
|
+
<p class="ds-measure mt-2 text-sm" data-measure="prose">{collection.description}</p>
|
|
114
114
|
{/if}
|
|
115
115
|
{#if !collection.subtitle && !collection.description}
|
|
116
116
|
<p class="text-muted-foreground text-sm">No description recorded.</p>
|
|
@@ -78,8 +78,8 @@
|
|
|
78
78
|
onClose,
|
|
79
79
|
children,
|
|
80
80
|
documentPane,
|
|
81
|
-
/** The
|
|
82
|
-
|
|
81
|
+
/** The column's name: its landmark's, its opener's and its dialogue's.
|
|
82
|
+
Defaults to the opened item's title, else the stat card's. */
|
|
83
83
|
ariaLabel,
|
|
84
84
|
ref = $bindable(null),
|
|
85
85
|
class: className,
|
|
@@ -107,6 +107,8 @@
|
|
|
107
107
|
const BESIDE = 1250;
|
|
108
108
|
const beside = $derived(row !== null && row >= BESIDE);
|
|
109
109
|
const name = $derived(ariaLabel ?? title ?? statsTitle);
|
|
110
|
+
/** The dialogue's title is the body's own heading, so the body leaves it to the dialogue. */
|
|
111
|
+
const headed = $derived(name === (children ? title : statsTitle));
|
|
110
112
|
</script>
|
|
111
113
|
|
|
112
114
|
{#snippet close()}
|
|
@@ -115,12 +117,12 @@
|
|
|
115
117
|
</Tooltip.Provider>
|
|
116
118
|
{/snippet}
|
|
117
119
|
|
|
118
|
-
{#snippet item()}
|
|
120
|
+
{#snippet item(framed: boolean)}
|
|
119
121
|
{#key title}
|
|
120
122
|
<Panel
|
|
121
|
-
{title}
|
|
122
|
-
{subtitle}
|
|
123
|
-
action={onClose ? close : undefined}
|
|
123
|
+
title={framed ? undefined : title}
|
|
124
|
+
subtitle={framed ? undefined : subtitle}
|
|
125
|
+
action={onClose && !framed ? close : undefined}
|
|
124
126
|
pad={false}
|
|
125
127
|
scroll
|
|
126
128
|
class="max-h-full min-h-0"
|
|
@@ -131,11 +133,13 @@
|
|
|
131
133
|
{/key}
|
|
132
134
|
{/snippet}
|
|
133
135
|
|
|
134
|
-
|
|
136
|
+
<!-- `framed`: the dialogue's own header carries the name, with its subtitle or
|
|
137
|
+
info, so the body leaves its heading out rather than repeat it. -->
|
|
138
|
+
{#snippet body(framed: boolean)}
|
|
135
139
|
{#if children}
|
|
136
|
-
{#if documentPane && row !== null && !beside}{@render documentPane()}{:else}{@render item()}{/if}
|
|
140
|
+
{#if documentPane && row !== null && !beside}{@render documentPane()}{:else}{@render item(framed)}{/if}
|
|
137
141
|
{:else}
|
|
138
|
-
<StatList items={stats ?? []} title={statsTitle} info={statsInfo} />
|
|
142
|
+
<StatList items={stats ?? []} title={statsTitle} info={statsInfo} bare={framed} />
|
|
139
143
|
{#if detail}
|
|
140
144
|
{@render detail()}
|
|
141
145
|
{/if}
|
|
@@ -144,7 +148,7 @@
|
|
|
144
148
|
|
|
145
149
|
<aside
|
|
146
150
|
bind:this={ref}
|
|
147
|
-
aria-label={
|
|
151
|
+
aria-label={name}
|
|
148
152
|
class={cn(
|
|
149
153
|
'hidden max-h-full min-h-0 w-[clamp(360px,28vw,460px)] shrink-0 flex-col gap-5 xl:flex',
|
|
150
154
|
className
|
|
@@ -152,7 +156,7 @@
|
|
|
152
156
|
data-slot="context-column"
|
|
153
157
|
{...restProps}
|
|
154
158
|
>
|
|
155
|
-
{@render body()}
|
|
159
|
+
{@render body(false)}
|
|
156
160
|
</aside>
|
|
157
161
|
|
|
158
162
|
{#if children && documentPane && beside}
|
|
@@ -164,18 +168,28 @@
|
|
|
164
168
|
<!-- The reachable stand-in below xl. `size-11` (44px) rather than this
|
|
165
169
|
package's usual 36px control row: this is the one control whose entire
|
|
166
170
|
job is making otherwise-unreachable content reachable, so it earns the
|
|
167
|
-
full touch-target minimum rather than the shell's ordinary density.
|
|
171
|
+
full touch-target minimum rather than the shell's ordinary density.
|
|
172
|
+
The bottom-right corner is the feedback widget's; this sits beside it
|
|
173
|
+
(`--ds-report-beside`, which the widget publishes) and follows its lift, so
|
|
174
|
+
neither covers the other and both stay in the band the shell reserves at
|
|
175
|
+
the content's end. -->
|
|
168
176
|
<button
|
|
169
177
|
type="button"
|
|
170
178
|
onclick={() => (sheetOpen = true)}
|
|
171
|
-
class="border-border bg-card text-muted-foreground hover:text-foreground ds-edge fixed right-
|
|
179
|
+
class="border-border bg-card text-muted-foreground hover:text-foreground ds-edge fixed right-[var(--ds-report-beside,1rem)] bottom-[calc(1rem+var(--ds-report-clearance,0px)+env(safe-area-inset-bottom))] z-30 grid size-11 flex-none place-items-center rounded-full border xl:hidden"
|
|
172
180
|
aria-label="Open {name}"
|
|
173
181
|
>
|
|
174
182
|
<PanelRight class="size-4.5" />
|
|
175
183
|
</button>
|
|
176
184
|
|
|
177
|
-
<AppDialog
|
|
185
|
+
<AppDialog
|
|
186
|
+
bind:open={sheetOpen}
|
|
187
|
+
title={name}
|
|
188
|
+
subtitle={headed && children ? subtitle : undefined}
|
|
189
|
+
info={headed && !children ? statsInfo : undefined}
|
|
190
|
+
size="sm"
|
|
191
|
+
>
|
|
178
192
|
<div class={cn('flex flex-col gap-5', children && documentPane && 'h-[70dvh]')}>
|
|
179
|
-
{@render body()}
|
|
193
|
+
{@render body(headed)}
|
|
180
194
|
</div>
|
|
181
195
|
</AppDialog>
|
|
@@ -20,7 +20,11 @@
|
|
|
20
20
|
} = $props();
|
|
21
21
|
</script>
|
|
22
22
|
|
|
23
|
-
|
|
23
|
+
<!-- Opened by hover or a keyboard's focus, never by focus a script moves after a
|
|
24
|
+
click or tap: a dialogue whose first control is a tip (AppDialog's `info`)
|
|
25
|
+
opens with it shut. Opened from the keyboard, the focused tip shows, as
|
|
26
|
+
tabbing to it would. -->
|
|
27
|
+
<Tooltip.Provider delayDuration={150} ignoreNonKeyboardFocus>
|
|
24
28
|
<Tooltip.Root>
|
|
25
29
|
<!--
|
|
26
30
|
The icon trigger takes a 44x44 hit area (`size-11`) and hands the space
|
|
@@ -524,7 +524,7 @@
|
|
|
524
524
|
data-slot="ledger-title"
|
|
525
525
|
>
|
|
526
526
|
<span class="flex min-w-0 items-center gap-1.5">
|
|
527
|
-
<span class="min-w-0
|
|
527
|
+
<span class="min-w-0 line-clamp-2 break-words">{r.title}</span>
|
|
528
528
|
{#if r.attachment}{@render clip(r)}{/if}
|
|
529
529
|
{@render chip(r)}
|
|
530
530
|
{#if c.actions}<span class="pointer-events-auto flex flex-none items-center gap-1" data-slot="ledger-actions">{@render c.actions(r)}</span>{/if}
|
|
@@ -676,7 +676,7 @@
|
|
|
676
676
|
{/if}
|
|
677
677
|
<span class="pointer-events-none flex min-w-0 flex-col justify-center gap-0.5">
|
|
678
678
|
<span class="flex min-w-0 items-center gap-1.5">
|
|
679
|
-
<span class="min-w-0
|
|
679
|
+
<span class="min-w-0 line-clamp-2 font-medium break-words">{r.title}</span>
|
|
680
680
|
{#if r.attachment}{@render clip(r)}{/if}
|
|
681
681
|
{@render chip(r)}
|
|
682
682
|
{#if titleColumn?.actions}<span class="pointer-events-auto flex flex-none items-center gap-1" data-slot="ledger-actions">{@render titleColumn.actions(r)}</span>{/if}
|
|
@@ -50,36 +50,46 @@
|
|
|
50
50
|
<div
|
|
51
51
|
role="toolbar"
|
|
52
52
|
aria-label={label ?? title}
|
|
53
|
-
class={cn('flex min-h-11 flex-none items-center gap-2 px-2 pb-2', className)}
|
|
53
|
+
class={cn('flex min-h-11 flex-none flex-wrap items-center gap-x-2 gap-y-1 px-2 pb-2', className)}
|
|
54
54
|
data-slot="list-toolbar"
|
|
55
55
|
{...restProps}
|
|
56
56
|
>
|
|
57
57
|
{@render leading?.()}
|
|
58
|
-
<!--
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
<IconAction action={tool} />
|
|
69
|
-
{/each}
|
|
70
|
-
</Tooltip.Provider>
|
|
71
|
-
{/if}
|
|
72
|
-
{#if action}
|
|
73
|
-
<Button
|
|
74
|
-
variant="outline"
|
|
75
|
-
size="sm"
|
|
76
|
-
href={action.href}
|
|
77
|
-
download={action.href ? (action.download === true ? '' : action.download || undefined) : undefined}
|
|
78
|
-
disabled={action.disabled}
|
|
79
|
-
onclick={action.onclick}
|
|
80
|
-
data-slot="list-toolbar-action"
|
|
81
|
-
>
|
|
82
|
-
{#if ActionIcon}<ActionIcon />{/if}{action.label}
|
|
83
|
-
</Button>
|
|
58
|
+
<!--
|
|
59
|
+
Crowded, nothing ends in an ellipsis: the controls drop together to a
|
|
60
|
+
line of their own, still at the end, then the count drops under the
|
|
61
|
+
title, then the title wraps.
|
|
62
|
+
-->
|
|
63
|
+
{#if title || meta}
|
|
64
|
+
<div class="flex min-w-0 flex-wrap items-baseline gap-x-2.5">
|
|
65
|
+
{#if title}<h2 class="text-body min-w-0 font-semibold break-words">{title}</h2>{/if}
|
|
66
|
+
{#if meta}<span class="text-muted-foreground min-w-0 text-sm break-words">{meta}</span>{/if}
|
|
67
|
+
</div>
|
|
84
68
|
{/if}
|
|
69
|
+
<div
|
|
70
|
+
class="ml-auto flex min-w-0 flex-wrap items-center justify-end gap-2 [&:not(:has(>*))]:hidden"
|
|
71
|
+
data-slot="list-toolbar-controls"
|
|
72
|
+
>
|
|
73
|
+
{@render children?.()}
|
|
74
|
+
{#if tools.length}
|
|
75
|
+
<Tooltip.Provider delayDuration={150}>
|
|
76
|
+
{#each tools as tool (tool.label)}
|
|
77
|
+
<IconAction action={tool} />
|
|
78
|
+
{/each}
|
|
79
|
+
</Tooltip.Provider>
|
|
80
|
+
{/if}
|
|
81
|
+
{#if action}
|
|
82
|
+
<Button
|
|
83
|
+
variant="outline"
|
|
84
|
+
size="sm"
|
|
85
|
+
href={action.href}
|
|
86
|
+
download={action.href ? (action.download === true ? '' : action.download || undefined) : undefined}
|
|
87
|
+
disabled={action.disabled}
|
|
88
|
+
onclick={action.onclick}
|
|
89
|
+
data-slot="list-toolbar-action"
|
|
90
|
+
>
|
|
91
|
+
{#if ActionIcon}<ActionIcon />{/if}{action.label}
|
|
92
|
+
</Button>
|
|
93
|
+
{/if}
|
|
94
|
+
</div>
|
|
85
95
|
</div>
|
|
@@ -32,12 +32,12 @@
|
|
|
32
32
|
}: WithElementRef<HTMLAttributes<HTMLElement>> & {
|
|
33
33
|
title?: string;
|
|
34
34
|
/**
|
|
35
|
-
* A
|
|
36
|
-
*
|
|
37
|
-
* subtitle that wrapped would change it everywhere at once.
|
|
35
|
+
* A short qualifier under the title. It WRAPS: a header is as tall as its
|
|
36
|
+
* text, so a phone shows the whole qualifier rather than "Profit and l…".
|
|
38
37
|
*
|
|
39
38
|
* For the sentence or two that explains what the section is for, use
|
|
40
|
-
* `description`, which
|
|
39
|
+
* `description`, which sits in the same place with more room. Carry one
|
|
40
|
+
* or the other, not both.
|
|
41
41
|
*/
|
|
42
42
|
subtitle?: string;
|
|
43
43
|
/**
|
|
@@ -120,7 +120,7 @@
|
|
|
120
120
|
{title}
|
|
121
121
|
</h2>
|
|
122
122
|
{#if subtitle}
|
|
123
|
-
<p class="text-muted-foreground
|
|
123
|
+
<p class="text-muted-foreground text-xs break-words">{subtitle}</p>
|
|
124
124
|
{/if}
|
|
125
125
|
{#if description}
|
|
126
126
|
<p class="text-muted-foreground mt-1 text-sm">{description}</p>
|
|
@@ -4,12 +4,12 @@ import { type WithElementRef } from '../../../utils.js';
|
|
|
4
4
|
type $$ComponentProps = WithElementRef<HTMLAttributes<HTMLElement>> & {
|
|
5
5
|
title?: string;
|
|
6
6
|
/**
|
|
7
|
-
* A
|
|
8
|
-
*
|
|
9
|
-
* subtitle that wrapped would change it everywhere at once.
|
|
7
|
+
* A short qualifier under the title. It WRAPS: a header is as tall as its
|
|
8
|
+
* text, so a phone shows the whole qualifier rather than "Profit and l…".
|
|
10
9
|
*
|
|
11
10
|
* For the sentence or two that explains what the section is for, use
|
|
12
|
-
* `description`, which
|
|
11
|
+
* `description`, which sits in the same place with more room. Carry one
|
|
12
|
+
* or the other, not both.
|
|
13
13
|
*/
|
|
14
14
|
subtitle?: string;
|
|
15
15
|
/**
|
|
@@ -6,7 +6,9 @@
|
|
|
6
6
|
* a thumbnail each, and ends with the way to all of them, so it still
|
|
7
7
|
* works at fifty. The record's own pages follow as tabs. On a phone the
|
|
8
8
|
* breadcrumb (the section's name and the "/") gives way, and the tabs scroll
|
|
9
|
-
* sideways inside the row, so every page stays reachable.
|
|
9
|
+
* sideways inside the row, so every page stays reachable. The open page is
|
|
10
|
+
* scrolled into view, and a strip with more beyond an edge fades that edge,
|
|
11
|
+
* so a hidden tab is never silent.
|
|
10
12
|
*
|
|
11
13
|
* It places nothing itself: put it inside `ShellControls` with whatever
|
|
12
14
|
* else the page sets in the bar.
|
|
@@ -79,6 +81,33 @@
|
|
|
79
81
|
*/
|
|
80
82
|
// svelte-ignore state_referenced_locally
|
|
81
83
|
let highlighted = $state(here());
|
|
84
|
+
/** The page strip, and whether tabs lie past its left or right edge. */
|
|
85
|
+
let strip = $state<HTMLElement | null>(null);
|
|
86
|
+
let moreBefore = $state(false);
|
|
87
|
+
let moreAfter = $state(false);
|
|
88
|
+
const measure = () => {
|
|
89
|
+
if (!strip) return;
|
|
90
|
+
moreBefore = strip.scrollLeft > 1;
|
|
91
|
+
moreAfter = strip.scrollLeft + strip.clientWidth < strip.scrollWidth - 1;
|
|
92
|
+
};
|
|
93
|
+
$effect(() => {
|
|
94
|
+
const at = pages.findIndex((p) => p.current);
|
|
95
|
+
if (!strip) return;
|
|
96
|
+
const open = strip.children[at] as HTMLElement | undefined;
|
|
97
|
+
if (open) {
|
|
98
|
+
const left = open.offsetLeft;
|
|
99
|
+
const right = left + open.offsetWidth;
|
|
100
|
+
if (left < strip.scrollLeft) strip.scrollLeft = left;
|
|
101
|
+
else if (right > strip.scrollLeft + strip.clientWidth) strip.scrollLeft = right - strip.clientWidth;
|
|
102
|
+
}
|
|
103
|
+
measure();
|
|
104
|
+
if (typeof ResizeObserver === 'undefined') return;
|
|
105
|
+
// The tabs too: a label or a font that changes their width moves the strip's end.
|
|
106
|
+
const watch = new ResizeObserver(measure);
|
|
107
|
+
for (const el of [strip, ...strip.children]) watch.observe(el);
|
|
108
|
+
return () => watch.disconnect();
|
|
109
|
+
});
|
|
110
|
+
const fade = (edge: boolean) => (edge ? '1.5rem' : '0px');
|
|
82
111
|
const eyebrow = 'text-muted-foreground text-2xs tracking-eyebrow font-semibold uppercase';
|
|
83
112
|
</script>
|
|
84
113
|
|
|
@@ -150,8 +179,13 @@
|
|
|
150
179
|
|
|
151
180
|
{#if pages.length}
|
|
152
181
|
<nav
|
|
182
|
+
bind:this={strip}
|
|
153
183
|
aria-label="Pages of {name}"
|
|
154
|
-
class="ml-1 flex min-w-0 items-stretch gap-1 self-stretch overflow-x-auto sm:ml-3"
|
|
184
|
+
class="relative ml-1 flex min-w-0 items-stretch gap-1 self-stretch overflow-x-auto sm:ml-3"
|
|
185
|
+
style="--fade-start: {fade(moreBefore)}; --fade-end: {fade(moreAfter)}; mask-image: linear-gradient(to right, transparent, #000 var(--fade-start), #000 calc(100% - var(--fade-end)), transparent); -webkit-mask-image: linear-gradient(to right, transparent, #000 var(--fade-start), #000 calc(100% - var(--fade-end)), transparent);"
|
|
186
|
+
data-more-before={moreBefore || undefined}
|
|
187
|
+
data-more-after={moreAfter || undefined}
|
|
188
|
+
onscroll={measure}
|
|
155
189
|
>
|
|
156
190
|
{#each pages as p (p.href)}
|
|
157
191
|
<a
|
|
@@ -36,6 +36,7 @@
|
|
|
36
36
|
value,
|
|
37
37
|
onChange,
|
|
38
38
|
disabled = false,
|
|
39
|
+
validate = false,
|
|
39
40
|
idPrefix = 'sf',
|
|
40
41
|
class: className
|
|
41
42
|
}: SchemaFormProps = $props();
|
|
@@ -59,11 +60,12 @@
|
|
|
59
60
|
*/
|
|
60
61
|
const errors = $derived.by(() => {
|
|
61
62
|
const byPath: Record<string, string[]> = {};
|
|
63
|
+
if (!validate) return byPath;
|
|
62
64
|
try {
|
|
63
|
-
const
|
|
65
|
+
const check = ajv.compile(schema as object);
|
|
64
66
|
const probe = structuredClone($state.snapshot(value));
|
|
65
|
-
if (
|
|
66
|
-
for (const error of
|
|
67
|
+
if (check(probe)) return byPath;
|
|
68
|
+
for (const error of check.errors ?? []) {
|
|
67
69
|
const missing = (error.params as { missingProperty?: string })?.missingProperty;
|
|
68
70
|
const instance = error.instancePath.replace(/^\//, '').split('/').filter(Boolean).join('.');
|
|
69
71
|
const path = missing ? [instance, missing].filter(Boolean).join('.') : instance;
|
|
@@ -54,6 +54,14 @@ export interface SchemaFormProps {
|
|
|
54
54
|
onChange: (next: Record<string, unknown>, change: SchemaFormChange) => void;
|
|
55
55
|
/** Disable every control in the form. */
|
|
56
56
|
disabled?: boolean;
|
|
57
|
+
/**
|
|
58
|
+
* Validate the value against the schema in the browser; default false. Ajv
|
|
59
|
+
* compiles a schema with `new Function`, which a Content-Security-Policy
|
|
60
|
+
* without `'unsafe-eval'` refuses (every factory app's), so the form compiles
|
|
61
|
+
* nothing and marks no violation, and the page shows its server's refusals.
|
|
62
|
+
* Pass `true` on a host without that policy.
|
|
63
|
+
*/
|
|
64
|
+
validate?: boolean;
|
|
57
65
|
/** Prefix for generated element ids, when two forms share a page. */
|
|
58
66
|
idPrefix?: string;
|
|
59
67
|
/** Extra classes on the form's root element. */
|
|
@@ -29,6 +29,7 @@
|
|
|
29
29
|
items,
|
|
30
30
|
title = 'At a glance',
|
|
31
31
|
info,
|
|
32
|
+
bare = false,
|
|
32
33
|
class: klass = '',
|
|
33
34
|
ref = $bindable(null),
|
|
34
35
|
...restProps
|
|
@@ -36,6 +37,8 @@
|
|
|
36
37
|
items: StatItem[];
|
|
37
38
|
title?: string;
|
|
38
39
|
info?: string;
|
|
40
|
+
/** Leave the header out: the frame around the card (a dialogue) carries its title and info. */
|
|
41
|
+
bare?: boolean;
|
|
39
42
|
} = $props();
|
|
40
43
|
</script>
|
|
41
44
|
|
|
@@ -44,15 +47,17 @@
|
|
|
44
47
|
class="bg-card border-border ds-edge flex shrink-0 flex-col overflow-hidden rounded-lg border {klass}"
|
|
45
48
|
{...restProps}
|
|
46
49
|
>
|
|
47
|
-
|
|
48
|
-
<
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
50
|
+
{#if !bare}
|
|
51
|
+
<header class="border-border flex items-center gap-2 border-b px-4 py-3">
|
|
52
|
+
<h2 class="text-body leading-tight font-semibold tracking-tight">{title}</h2>
|
|
53
|
+
{#if info}
|
|
54
|
+
<InfoTip
|
|
55
|
+
text={info}
|
|
56
|
+
class="text-muted-foreground/50 hover:text-muted-foreground size-3.5 transition-colors"
|
|
57
|
+
/>
|
|
58
|
+
{/if}
|
|
59
|
+
</header>
|
|
60
|
+
{/if}
|
|
56
61
|
<dl class="flex flex-col">
|
|
57
62
|
{#each items as item (item.label)}
|
|
58
63
|
<div
|
|
@@ -17,6 +17,8 @@ type $$ComponentProps = WithElementRef<HTMLAttributes<HTMLElement>> & {
|
|
|
17
17
|
items: StatItem[];
|
|
18
18
|
title?: string;
|
|
19
19
|
info?: string;
|
|
20
|
+
/** Leave the header out: the frame around the card (a dialogue) carries its title and info. */
|
|
21
|
+
bare?: boolean;
|
|
20
22
|
};
|
|
21
23
|
declare const StatList: import("svelte").Component<$$ComponentProps, {}, "ref">;
|
|
22
24
|
type StatList = ReturnType<typeof StatList>;
|
package/dist/styles.css
CHANGED
|
@@ -357,14 +357,14 @@
|
|
|
357
357
|
for the same reason the rail width is one: an app retunes a tier in one
|
|
358
358
|
declaration instead of waiting on a release of this package.
|
|
359
359
|
|
|
360
|
-
`prose` is in `
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
360
|
+
`prose` is in `rem`, like the other two, though it is a reading measure.
|
|
361
|
+
`ch` resolves against each element's OWN font size, so blocks of 20, 16
|
|
362
|
+
and 14px in one column stopped at three different right edges (982, 770
|
|
363
|
+
and 674px measured). A root-relative length gives them one edge. 40rem
|
|
364
|
+
is about 70 characters of body text in the household face; a caller that
|
|
365
|
+
wants a different count retunes the property.
|
|
366
366
|
──────────────────────────────────────────────────────────────────────── */
|
|
367
|
-
--ds-shell-measure-prose:
|
|
367
|
+
--ds-shell-measure-prose: 40rem;
|
|
368
368
|
--ds-shell-measure-page: 80rem;
|
|
369
369
|
--ds-shell-measure-wide: 120rem;
|
|
370
370
|
}
|
|
@@ -1161,7 +1161,7 @@
|
|
|
1161
1161
|
rather than drifting from it. That is the whole point: the alternative an
|
|
1162
1162
|
app reaches for is a local `max-w-prose` or `max-w-[72ch]`, which is a
|
|
1163
1163
|
number typed once that never hears about a retune — four apps had written
|
|
1164
|
-
ten of them between them, and not one matched this package's own
|
|
1164
|
+
ten of them between them, and not one matched this package's own measure. */
|
|
1165
1165
|
.ds-measure[data-measure='prose'],
|
|
1166
1166
|
.ds-shell-measure[data-measure='prose'] {
|
|
1167
1167
|
max-width: var(--ds-shell-measure-prose);
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@poodle64/ui",
|
|
3
|
-
"version": "2026.10.
|
|
3
|
+
"version": "2026.10.24",
|
|
4
4
|
"description": "Household shared component layer: shadcn-svelte primitives (bits-ui) plus the composed page chrome every app builds its routes from, restyled by each app's @poodle64/design-tokens alias layer. One fix reaches every app.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|
|
@@ -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.
|
|
4
|
+
Generated from `@poodle64/ui@2026.10.24`. 76 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
|
|