@mgamadeus/ddd-admin-ui 0.1.0-rc.3 → 0.1.0-rc.5

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 (180) hide show
  1. package/.claude/skills/ddd-admin-ui-specialist/SKILL.md +17 -2
  2. package/CHANGELOG.md +76 -0
  3. package/README.md +51 -8
  4. package/STANDARDS.md +55 -5
  5. package/dist/components.css +10 -5
  6. package/dist/form/FormActions.d.ts.map +1 -1
  7. package/dist/form/FormActions.js +7 -2
  8. package/dist/form/FormActions.js.map +1 -1
  9. package/dist/i18n/hints.json +11 -7
  10. package/dist/i18n-keys.json +45 -8
  11. package/dist/list/Combobox.d.ts +33 -3
  12. package/dist/list/Combobox.d.ts.map +1 -1
  13. package/dist/list/Combobox.js +71 -13
  14. package/dist/list/Combobox.js.map +1 -1
  15. package/dist/list/CopyButton.d.ts +23 -0
  16. package/dist/list/CopyButton.d.ts.map +1 -0
  17. package/dist/list/CopyButton.js +28 -0
  18. package/dist/list/CopyButton.js.map +1 -0
  19. package/dist/list/EntityListBody.d.ts +2 -2
  20. package/dist/list/EntityListBody.d.ts.map +1 -1
  21. package/dist/list/EntityListBody.js +2 -2
  22. package/dist/list/EntityListBody.js.map +1 -1
  23. package/dist/list/EntityListEmpty.d.ts +6 -1
  24. package/dist/list/EntityListEmpty.d.ts.map +1 -1
  25. package/dist/list/EntityListEmpty.js +4 -1
  26. package/dist/list/EntityListEmpty.js.map +1 -1
  27. package/dist/list/EntityListTable.d.ts +12 -3
  28. package/dist/list/EntityListTable.d.ts.map +1 -1
  29. package/dist/list/EntityListTable.js +8 -7
  30. package/dist/list/EntityListTable.js.map +1 -1
  31. package/dist/list/filters.d.ts +8 -1
  32. package/dist/list/filters.d.ts.map +1 -1
  33. package/dist/list/filters.js +5 -2
  34. package/dist/list/filters.js.map +1 -1
  35. package/dist/list/index.d.ts +2 -0
  36. package/dist/list/index.d.ts.map +1 -1
  37. package/dist/list/index.js +1 -0
  38. package/dist/list/index.js.map +1 -1
  39. package/dist/logic/browser/storage.d.ts +17 -0
  40. package/dist/logic/browser/storage.d.ts.map +1 -0
  41. package/dist/logic/browser/storage.js +40 -0
  42. package/dist/logic/browser/storage.js.map +1 -0
  43. package/dist/logic/index.d.ts +8 -1
  44. package/dist/logic/index.d.ts.map +1 -1
  45. package/dist/logic/index.js +4 -0
  46. package/dist/logic/index.js.map +1 -1
  47. package/dist/logic/pure/confirm.d.ts +4 -0
  48. package/dist/logic/pure/confirm.d.ts.map +1 -1
  49. package/dist/logic/pure/confirm.js.map +1 -1
  50. package/dist/logic/pure/dateInput.d.ts +21 -0
  51. package/dist/logic/pure/dateInput.d.ts.map +1 -0
  52. package/dist/logic/pure/dateInput.js +79 -0
  53. package/dist/logic/pure/dateInput.js.map +1 -0
  54. package/dist/logic/pure/listSort.d.ts +11 -3
  55. package/dist/logic/pure/listSort.d.ts.map +1 -1
  56. package/dist/logic/pure/listSort.js +9 -5
  57. package/dist/logic/pure/listSort.js.map +1 -1
  58. package/dist/logic/pure/stickyParams.d.ts +10 -0
  59. package/dist/logic/pure/stickyParams.d.ts.map +1 -0
  60. package/dist/logic/pure/stickyParams.js +31 -0
  61. package/dist/logic/pure/stickyParams.js.map +1 -0
  62. package/dist/logic/react/useLatestSearch.d.ts +18 -0
  63. package/dist/logic/react/useLatestSearch.d.ts.map +1 -0
  64. package/dist/logic/react/useLatestSearch.js +37 -0
  65. package/dist/logic/react/useLatestSearch.js.map +1 -0
  66. package/dist/logic/react/useRowSelection.d.ts +12 -2
  67. package/dist/logic/react/useRowSelection.d.ts.map +1 -1
  68. package/dist/logic/react/useRowSelection.js +16 -8
  69. package/dist/logic/react/useRowSelection.js.map +1 -1
  70. package/dist/next/storage.d.ts +2 -10
  71. package/dist/next/storage.d.ts.map +1 -1
  72. package/dist/next/storage.js +2 -33
  73. package/dist/next/storage.js.map +1 -1
  74. package/dist/page/DefinitionList.d.ts +7 -2
  75. package/dist/page/DefinitionList.d.ts.map +1 -1
  76. package/dist/page/DefinitionList.js +4 -1
  77. package/dist/page/DefinitionList.js.map +1 -1
  78. package/dist/page/EntityDetailShell.d.ts +2 -2
  79. package/dist/page/EntityDetailShell.d.ts.map +1 -1
  80. package/dist/page/EntityDetailShell.js +3 -2
  81. package/dist/page/EntityDetailShell.js.map +1 -1
  82. package/dist/page/EntityListPage.d.ts +3 -1
  83. package/dist/page/EntityListPage.d.ts.map +1 -1
  84. package/dist/page/EntityListPage.js +1 -1
  85. package/dist/page/EntityListPage.js.map +1 -1
  86. package/dist/page/EntityTabs.d.ts +2 -2
  87. package/dist/page/EntityTabs.d.ts.map +1 -1
  88. package/dist/page/EntityTabs.js +3 -2
  89. package/dist/page/EntityTabs.js.map +1 -1
  90. package/dist/page/PageFrame.d.ts +6 -1
  91. package/dist/page/PageFrame.d.ts.map +1 -1
  92. package/dist/page/PageFrame.js +1 -1
  93. package/dist/page/PageFrame.js.map +1 -1
  94. package/dist/page/PageToolbar.d.ts +2 -2
  95. package/dist/page/PageToolbar.d.ts.map +1 -1
  96. package/dist/page/PageToolbar.js +3 -2
  97. package/dist/page/PageToolbar.js.map +1 -1
  98. package/dist/page/SectionHeader.d.ts +1 -1
  99. package/dist/page/SectionHeader.d.ts.map +1 -1
  100. package/dist/page/links.d.ts +2 -17
  101. package/dist/page/links.d.ts.map +1 -1
  102. package/dist/page/links.js +3 -3
  103. package/dist/page/links.js.map +1 -1
  104. package/dist/primitives/breadcrumb.d.ts.map +1 -1
  105. package/dist/primitives/breadcrumb.js +7 -0
  106. package/dist/primitives/breadcrumb.js.map +1 -1
  107. package/dist/primitives/command.js +1 -1
  108. package/dist/primitives/command.js.map +1 -1
  109. package/dist/primitives/index.d.ts +2 -0
  110. package/dist/primitives/index.d.ts.map +1 -1
  111. package/dist/primitives/index.js +2 -0
  112. package/dist/primitives/index.js.map +1 -1
  113. package/dist/primitives/link.d.ts +28 -0
  114. package/dist/primitives/link.d.ts.map +1 -0
  115. package/dist/primitives/link.js +15 -0
  116. package/dist/primitives/link.js.map +1 -0
  117. package/dist/primitives/segmented-control.d.ts +65 -0
  118. package/dist/primitives/segmented-control.d.ts.map +1 -0
  119. package/dist/primitives/segmented-control.js +224 -0
  120. package/dist/primitives/segmented-control.js.map +1 -0
  121. package/dist/primitives/segmentedControlNavigation.d.ts +31 -0
  122. package/dist/primitives/segmentedControlNavigation.d.ts.map +1 -0
  123. package/dist/primitives/segmentedControlNavigation.js +65 -0
  124. package/dist/primitives/segmentedControlNavigation.js.map +1 -0
  125. package/dist/provider/AdminUiProvider.d.ts +3 -3
  126. package/dist/provider/AdminUiProvider.d.ts.map +1 -1
  127. package/dist/provider/AdminUiProvider.js +5 -4
  128. package/dist/provider/AdminUiProvider.js.map +1 -1
  129. package/dist/provider/types.d.ts +6 -0
  130. package/dist/provider/types.d.ts.map +1 -1
  131. package/dist/scripts/build-i18n-manifest.mjs +9 -3
  132. package/dist/showcase/Showcase.d.ts +35 -0
  133. package/dist/showcase/Showcase.d.ts.map +1 -0
  134. package/dist/showcase/Showcase.js +47 -0
  135. package/dist/showcase/Showcase.js.map +1 -0
  136. package/dist/showcase/coverage.d.ts +11 -0
  137. package/dist/showcase/coverage.d.ts.map +1 -0
  138. package/dist/showcase/coverage.js +80 -0
  139. package/dist/showcase/coverage.js.map +1 -0
  140. package/dist/showcase/index.d.ts +6 -0
  141. package/dist/showcase/index.d.ts.map +1 -0
  142. package/dist/showcase/index.js +5 -0
  143. package/dist/showcase/index.js.map +1 -0
  144. package/dist/showcase/sections/FormShowcase.d.ts +3 -0
  145. package/dist/showcase/sections/FormShowcase.d.ts.map +1 -0
  146. package/dist/showcase/sections/FormShowcase.js +26 -0
  147. package/dist/showcase/sections/FormShowcase.js.map +1 -0
  148. package/dist/showcase/sections/GlassShowcase.d.ts +3 -0
  149. package/dist/showcase/sections/GlassShowcase.d.ts.map +1 -0
  150. package/dist/showcase/sections/GlassShowcase.js +19 -0
  151. package/dist/showcase/sections/GlassShowcase.js.map +1 -0
  152. package/dist/showcase/sections/ListShowcase.d.ts +13 -0
  153. package/dist/showcase/sections/ListShowcase.d.ts.map +1 -0
  154. package/dist/showcase/sections/ListShowcase.js +97 -0
  155. package/dist/showcase/sections/ListShowcase.js.map +1 -0
  156. package/dist/showcase/sections/MediaShowcase.d.ts +3 -0
  157. package/dist/showcase/sections/MediaShowcase.d.ts.map +1 -0
  158. package/dist/showcase/sections/MediaShowcase.js +28 -0
  159. package/dist/showcase/sections/MediaShowcase.js.map +1 -0
  160. package/dist/showcase/sections/OptionalShowcase.d.ts +14 -0
  161. package/dist/showcase/sections/OptionalShowcase.d.ts.map +1 -0
  162. package/dist/showcase/sections/OptionalShowcase.js +32 -0
  163. package/dist/showcase/sections/OptionalShowcase.js.map +1 -0
  164. package/dist/showcase/sections/PageShowcase.d.ts +3 -0
  165. package/dist/showcase/sections/PageShowcase.d.ts.map +1 -0
  166. package/dist/showcase/sections/PageShowcase.js +41 -0
  167. package/dist/showcase/sections/PageShowcase.js.map +1 -0
  168. package/dist/showcase/sections/PrimitivesShowcase.d.ts +13 -0
  169. package/dist/showcase/sections/PrimitivesShowcase.d.ts.map +1 -0
  170. package/dist/showcase/sections/PrimitivesShowcase.js +40 -0
  171. package/dist/showcase/sections/PrimitivesShowcase.js.map +1 -0
  172. package/dist/showcase/sections/TranslationsShowcase.d.ts +3 -0
  173. package/dist/showcase/sections/TranslationsShowcase.d.ts.map +1 -0
  174. package/dist/showcase/sections/TranslationsShowcase.js +30 -0
  175. package/dist/showcase/sections/TranslationsShowcase.js.map +1 -0
  176. package/dist/tokens.json +17 -1
  177. package/dist/translations/TranslationControls.d.ts.map +1 -1
  178. package/dist/translations/TranslationControls.js +8 -6
  179. package/dist/translations/TranslationControls.js.map +1 -1
  180. package/package.json +6 -2
@@ -1,6 +1,6 @@
1
1
  ---
2
2
  name: ddd-admin-ui-specialist
3
- description: "Build admin screens with @mgamadeus/ddd-admin-ui and extend the package. Covers entries and import matrix, host setup (AdminUiProvider above every page, theme.css and components.css, tokens.json with ddd-admin-ui-check-tokens, one Radix copy with ddd-admin-ui-check-radix), list pages with URL filters, grid/table view, selection and bulk actions, wide tables (column tracks, pins, sortable headers, row index), detail shells, form drawers with conditions, server errors and the unsaved-changes guard, translations on full locale::style keys, media fields, toasts, layers, the portal container, the text manifest i18n-keys.json and text contexts, server vs client files, and adding a block. Use when building or reviewing a list, detail or form screen with these blocks, a page fails with Tooltip must be used within TooltipProvider, a wide table squeezes or needs pinned columns or sorting, a colour, layer or overlay misbehaves, translations lose a style variant, URL filters get lost, or a block is added."
3
+ description: "Build admin screens with @mgamadeus/ddd-admin-ui and extend the package. Covers entries, import matrix, host setup (AdminUiProvider above every page, theme.css and components.css, tokens.json with ddd-admin-ui-check-tokens, one Radix copy with ddd-admin-ui-check-radix), list pages with URL filters, grid/table view, selection and bulk actions, wide tables (column tracks, pins, sortable headers, row index), the segmented control, the showcase, detail shells, form drawers, server errors, the unsaved-changes guard, translations on full locale::style keys, media fields, toasts, layers, the portal container, i18n-keys.json and text contexts, server vs client files, and adding a block. Use when building or reviewing a list, detail or form screen with these blocks, a page fails with Tooltip must be used within TooltipProvider, a wide table squeezes or needs pinned columns or sorting, a colour, layer or overlay misbehaves, translations lose a style variant, URL filters get lost, or a block is added."
4
4
  metadata:
5
5
  author: mgamadeus
6
6
  version: 0.1.0
@@ -22,7 +22,13 @@ installed package (`node_modules/@mgamadeus/ddd-admin-ui/`). This skill reaches
22
22
  | checkbox column and bulk actions | `useRowSelection` + `EntityListBulkBar` + `runSequentialWithSummary` | logic, list |
23
23
  | status pill of an enum | `defineStatusMap` + `StatusBadge` (a `context` for an ambiguous word) | logic, list |
24
24
  | a wide table: column tracks, pinned columns, sortable headers, row numbers | `EntityListColumn` `width` / `minWidth` / `pin` / `align` / `sortKey` + `sort` / `onSortChange` / `showRowIndex` | list |
25
- | the sort in the URL | `formatListSort` / `parseListSort` / `nextListSort` (`key:asc`) | logic |
25
+ | the sort in the URL | `formatListSort` / `parseListSort` / `nextListSort` (`key:asc`; `sortStart`, `sortRequired`) | logic |
26
+ | one value out of a few (period, scope, view) | `SegmentedControl` (not tabs, not toggle chips) | primitives |
27
+ | a picker over a server search, with clear / create | `Combobox` `onSearch` + `useLatestSearch`, `clearable`, `onRequestCreate` | list, logic |
28
+ | copy a value next to it | `CopyButton` | list |
29
+ | one router link for every block, sticky search parameters | `AdminUiProvider.linkComponent` + `withStickyParams` | provider, logic |
30
+ | a `type="date"` / `datetime-local` value | `toDateInputValue` / `fromDateTimeInputValue` … with `'local'` or `'utc'` | logic |
31
+ | see every block in the host theme, light and dark | `Showcase` on a development route | showcase |
26
32
  | a view that loads its own data (a tree) in the list card | `EntityListBody.renderOwnView` | list |
27
33
  | an entity detail with tabs | `EntityDetailShell` (+ `SectionHeader`, `DefinitionList`) | page |
28
34
  | a form page or drawer | `Form` + `FormField` / `FormSection` + `FormActions`, in `FormDrawer` | form |
@@ -57,6 +63,15 @@ installed package (`node_modules/@mgamadeus/ddd-admin-ui/`). This skill reaches
57
63
  px); the table then scrolls sideways inside its card instead of squeezing. `pin: 'end'` always holds; `pin: 'start'`
58
64
  only while the table overflows by 120 px or more and the pinned columns stay under a third of the visible width. The
59
65
  table never sorts rows: map `sortKey` to the request. Sizes are measured after hydration only.
66
+ - **SegmentedControl** is a radio group: exactly one value, one tab stop, arrows select (`activation="manual"`: Space /
67
+ Enter). Tooltips (`iconOnly`, `disabledReason`) need `AdminUiProvider`. Corner and slide come from
68
+ `--segmented-control-radius` / `--segmented-control-duration`.
69
+ - **Combobox server search**: pass `onSearch` and `isSearching` (from `useLatestSearch`, which drops answers to older
70
+ terms); the block debounces and never shows the previous term's options. A picked value outside the results needs
71
+ `selectedOption`.
72
+ - **Links**: set `linkComponent` once on `AdminUiProvider`; without it blocks render plain `<a>` (full page loads).
73
+ - **Showcase** needs no optional peer: pass `loadNotifySonner={() => import('@mgamadeus/ddd-admin-ui/notify-sonner')}`
74
+ only when sonner is installed. A new block gets a showcase sample and a `SHOWCASE_COVERAGE` entry, or the checks fail.
60
75
  - **Text contexts are literals.** `m('Failed', { context: 'import-status' })`: extractors (the package manifest and
61
76
  host exports) read the text and the context as string literals; a context only on the status map or in a variable is
62
77
  not exported. Put the same context on the definition or the map so `StatusBadge` translates with it.
package/CHANGELOG.md CHANGED
@@ -3,6 +3,82 @@
3
3
  All notable changes to `@mgamadeus/ddd-admin-ui`. 0.x: each minor may break; pin the exact version while the package
4
4
  is in 0.x prereleases.
5
5
 
6
+ ## 0.1.0-rc.5
7
+
8
+ - `EntityListTable` / `EntityListBody`: `rowClassName(item, index)` for extra row classes.
9
+ - `useRowSelection`: `isSelectable(item)`. A row it refuses gets a disabled checkbox; "Select all loaded", the header
10
+ state, the count and `selectedKeys` take selectable rows only. `EntityListSelection` gains the optional
11
+ `isItemSelectionDisabled` (a row without a key still gets no checkbox).
12
+ - `Combobox`: `clearable` (a clear control; re-picking the picked option clears; without it the value is kept, as
13
+ before), `onSearch` (server search: no client filtering, debounced 300 ms, `''` on close; the list never shows the
14
+ previous term's options) with `isSearching`, option `group` (headings in first-appearance order) and `badge`,
15
+ `onRequestCreate` (a "Create “…”" row while no label equals the trimmed term), `selectedOption` (the label of a picked
16
+ value outside the options), `popoverClassName`; `COMBOBOX_SEARCH_DEBOUNCE_MS`. With `clearable`, `className` sizes a
17
+ wrapper around trigger and clear control.
18
+ - `./logic`: `useLatestSearch` (only the answer to the last term counts; aborts the previous request), date input
19
+ values `toDateInputValue`, `fromDateInputValue`, `toDateTimeInputValue`, `fromDateTimeInputValue` with an explicit
20
+ `'local' | 'utc'` zone (`DateInputZone`), `withStickyParams(href, names, currentSearch)`, the guarded storage helpers
21
+ `readStored` / `writeStored` (`StorageArea`, moved from the Next adapters, which use them from here) and
22
+ `buildStorageKey(prefix, area, name)` → `<prefix>.<area>.<name>`.
23
+ - `CopyButton` in `./list`: `value`, `label`, `reveal` (`always` / `hover`), `notify` (a toast through `notify`).
24
+ - Links: `AdminUiProvider.linkComponent` sets the router link of every block that renders a link (`EntityTabs`,
25
+ `SectionHeader` tabs, `EntityDetailShell` back link, `AddEntityButton`, and `BreadcrumbLink` with an `href`); a
26
+ block's own `linkComponent` still wins. Without the provider prop every link renders as before.
27
+ The link contract (`PageLinkProps`, `PageLinkComponent`, `AnchorLink`) moved to `./primitives` with
28
+ `LinkComponentContext`, `LinkComponentProvider`, `useLinkComponent`; `./page` still exports the old names.
29
+ - `EntityListEmpty size="compact"`: one inline line. `DefinitionList layout="rows"`: divided rows, label left, value
30
+ right. `FilterDateRange hideLabel` with `fromLabel` / `toLabel` (and `className`) for an inline range.
31
+ - `PageFrame` / `EntityListPage` `asSpecimen`: no `data-page-frame`, no full-height frame (used by the showcase, so a
32
+ host rule keyed to the attribute no longer fires there).
33
+ - `SegmentedControl`: a control wider than its container scrolls inside itself, keeping the selected and the focused
34
+ option in view (touch swipes scroll then, the drag preview stays for mouse and pen); options no longer shrink.
35
+ Options take `context` (passed to `t()`) and `translate: false` for already translated text.
36
+ - `ConfirmOptions.description`: documented — may be a React node; the package's own confirmations pass plain text.
37
+ - Showcase: samples of the new props and blocks; specimen cells shrink (`min-w-0`), so a wide specimen does not widen
38
+ the page at 390 px.
39
+ - DOM change: `FormActions` renders `data-form-actions="admin-ui"` (was an empty value), and `components.css` selects
40
+ that value only, so a host's own action bar with a bare `data-form-actions` is no longer restyled.
41
+ - Text keys changed (move host translations):
42
+ - `Search for a command to run...` → `Search for a command to run…`
43
+ - the translation progress statuses got the context `translation-status`: `Waiting`, `Translating`, `Done`,
44
+ `Failed`, `Cancelled` → `Waiting__translation-status`, `Translating__translation-status`,
45
+ `Done__translation-status`, `Failed__translation-status`, `Cancelled__translation-status`.
46
+ `Translating…` (the running button label) stays a separate key: a button text, not a status word.
47
+ - new: `Clear`, `Copied`, `Could not copy`, `Create “%term%”`.
48
+ - Consumer checks: Combobox in the browser (out-of-order answers, picked label outside the results, reset on close,
49
+ keyboard through groups and the create row, clearing), selectable rows, SegmentedControl in a 358 px container, the
50
+ showcase at 390 px without page scroll and without `data-page-frame`, links through the provider's link component
51
+ keeping sticky parameters; unit tests for the date values (UTC and Europe/Berlin around midnight and both clock
52
+ changes), `withStickyParams` and the storage helpers.
53
+
54
+ ## 0.1.0-rc.4
55
+
56
+ - `SegmentedControl` in `./primitives`: one value out of a few. Props `value`, `onValueChange`, `options` (`value`,
57
+ `label`, `icon`, `badge`, `description`, `disabled`, `disabledReason`, `className`), `aria-label` (required),
58
+ `height` (32 / 36 / 40 / 48), `iconOnly`, `fullWidth`, `selection` (`surface` / `primary`), `tone`
59
+ (`default` / `onBrand`), `activation` (`automatic` / `manual`), `className`; types `SegmentedControlProps`,
60
+ `SegmentedControlOption`. A radio group (`role="radiogroup"`, `role="radio"` + `aria-checked`, one tab stop): arrows,
61
+ Home and End move and select (manual: move the focus, Space / Enter select), right to left aware, disabled options
62
+ skipped with their reason announced and shown as a tooltip, `description` announced through `aria-describedby`,
63
+ `badge` hidden from assistive technology, `iconOnly` keeps the label as name and tooltip. A sliding indicator,
64
+ measured after layout, without motion under reduced motion; at least a 44 px target on coarse pointers. Pressing and
65
+ dragging across the options previews the choice; the value changes once on release; Escape or a cancelled pointer
66
+ restores it; a touch drag starts only after a sideways movement. New optional properties in `tokens.json`:
67
+ `--segmented-control-radius` (9999px) and `--segmented-control-duration` (200ms), defaults in `components.css`.
68
+ - New entry `./showcase`: `Showcase` draws every block of the package in the host's theme, light and dark, one section
69
+ per entry, with the host's sections appended (`sections`, `themes`, `omit`); `SHOWCASE_COVERAGE` lists the drawn
70
+ components per entry. It needs none of the optional peers: `./notify-sonner` loads lazily through `loadNotifySonner`
71
+ and is skipped without it or when the import fails; `./next` is described, never imported. Its texts stay out of
72
+ `i18n-keys.json` (the manifest builder skips the entry). `check-package` allows the entry the block entries only.
73
+ - List table sort: `EntityListColumn.sortStart` (`'asc'` / `'desc'`, the first direction when the column becomes
74
+ sorted) and `sortRequired` on `EntityListTable` / `EntityListBody` (never unsorted: the third click returns to the
75
+ first direction). `nextListSort(current, key, { start, required })` takes the same cycle (new type `ListSortCycle`);
76
+ calls without it keep the old cycle. A sortable header with `align: 'end'` puts the arrow before the label.
77
+ - Consumer checks: SegmentedControl in the browser (roles, both activation modes, right to left, disabled reason,
78
+ description, icon-only name and tooltip, drag preview with one change on release and none on Escape or cancel); the
79
+ showcase rendered on the server, bundled for the browser without optional peers and hydrated in the Next app; the
80
+ sort cycle with `sortStart` on an end-aligned column. The fixture app sets its UI language in one shared module.
81
+
6
82
  ## 0.1.0-rc.3
7
83
 
8
84
  - List table, all optional (a table without the new props renders the same DOM and classes as 0.1.0-rc.2, proven by
package/README.md CHANGED
@@ -20,9 +20,9 @@ pnpm add @mgamadeus/ddd-admin-ui @mgamadeus/ddd-web radix-ui react react-dom luc
20
20
 
21
21
  | Entry | What it holds | May import (besides React and its peers) |
22
22
  |---|---|---|
23
- | `./logic` | pure helpers (`formatDate`, `defineStatusMap`, conditions, schemas, `notify`, `runSequential`), React hooks without markup (`useUrlListState`, `useEntityDrawer`, `useRowSelection`, `useEntityTranslations`, …), browser helpers (`prepareImageFile`) | `./i18n` |
23
+ | `./logic` | pure helpers (`formatDate`, `defineStatusMap`, conditions, schemas, `notify`, `runSequential`), React hooks without markup (`useUrlListState`, `useEntityDrawer`, `useRowSelection`, `useEntityTranslations`, …), browser helpers (`prepareImageFile`, `readStored` / `writeStored`, `buildStorageKey`), date input values (`toDateInputValue`, `fromDateTimeInputValue`, …), `withStickyParams`, `useLatestSearch` | `./i18n` |
24
24
  | `./i18n` | the UI text store (`m`, `translateText`, `setTranslations`), `useTranslate`, `<Translate>`, number / date formats of the UI locale, server-message translation | — |
25
- | `./primitives` | buttons, inputs, selects, dialogs, sheets, popovers, menus, tooltips, tables, badges, `cn`, the portal container | `./i18n` |
25
+ | `./primitives` | buttons, inputs, selects, dialogs, sheets, popovers, menus, tooltips, tables, badges, `SegmentedControl`, `cn`, the portal container | `./i18n` |
26
26
  | `./list` | entity list card, toolbar, search, filters, table, grid, load-more, status badge, cells, multi-select, combobox, bulk bar | logic, i18n, primitives |
27
27
  | `./page` | page header and frame, `EntityListPage`, detail shell and header, tabs, section header, definition list, page toolbar, editable card, status callout, entity metadata | logic, i18n, primitives; from list only `EmptyValue`, `EntityListEmpty`, `EntityListCard` |
28
28
  | `./form` | `Form`, `FormField`, `FormSection`, `FormActions`, `FormDrawer`, `FormHeader`, `FormWrapper`, `FormJumpBar`, `FormErrors`, `FormSubmitButton`, `useConfirmDialog` | logic, i18n, primitives; from page only `DetailHeader`, `EntityMetadata` |
@@ -32,6 +32,7 @@ pnpm add @mgamadeus/ddd-admin-ui @mgamadeus/ddd-web radix-ui react react-dom luc
32
32
  | `./provider` | `AdminUiProvider`, `useAdminUi`, `defaultStorageKey` | logic, i18n, primitives; types only from media and translations |
33
33
  | `./next` | Next.js adapters: `useNextUrlStateAdapter`, `useNextDrawerUrlAdapter`, `useListViewParam`, the one URL writer (`queueSearchParamsWrite`) | logic, provider; the only entry importing `next/*` |
34
34
  | `./notify-sonner` | `sonnerNotifications` (the notification adapter on `sonner`) and its `Toaster` | logic; the only entry importing `sonner` |
35
+ | `./showcase` | `Showcase`: a development page drawing every block in the host theme, light and dark, one section per entry, the host's sections appended; `SHOWCASE_COVERAGE` | logic, i18n, primitives, list, page, form, translations, media, glass; never `./next` or `./notify-sonner` |
35
36
  | `./theme.css`, `./components.css` | the Tailwind theme binding and the structural CSS of the blocks | — |
36
37
  | `./tokens.json`, `./i18n-keys.json` | the host contract (colour roles, properties, layers, data attributes) and the text manifest | — |
37
38
 
@@ -113,7 +114,9 @@ It reads the host's `node_modules` (npm and pnpm layouts) and the folders above
113
114
  [`tokens.json`](./tokens.json): the 31 colour roles, `--nav-h`, `--content-max`, `--radius`, the surface and glass
114
115
  alphas and shadows, `--glass-control-shadow`. Dark mode is a `.dark` class on an ancestor; the default border
115
116
  colour is the `border` role. `components.css` sets the four `--layer-*` defaults (`raised` 10, `sticky` 20,
116
- `overlay` 50, `popover` 50) with zero specificity in the lowest cascade layer, so any host value wins. Check a built
117
+ `overlay` 50, `popover` 50) and the two optional properties of `SegmentedControl` (`--segmented-control-radius`
118
+ 9999px, `--segmented-control-duration` 200ms) with zero specificity in the lowest cascade layer, so any host value
119
+ wins. Check a built
117
120
  stylesheet against the contract:
118
121
 
119
122
  ```sh
@@ -152,8 +155,17 @@ It reads the host's `node_modules` (npm and pnpm layouts) and the folders above
152
155
  `ddd-admin-ui.<kind>.<id>`), `portalContainer` (where dialogs, sheets, popovers, selects, menus and tooltips mount;
153
156
  default `document.body`), `tooltipDelayMs`, `translations` (a `TranslationAdapter` that feeds the text store from a
154
157
  host store), `useUrlStateAdapter`, `useDrawerUrlAdapter`, `upload`, `renderMarkdownEditor`, `aiTranslation`,
155
- `preserveSearchParams` (search parameters the URL writer never removes). Without a notification adapter `notify.*`
156
- does nothing and warns once outside production.
158
+ `preserveSearchParams` (search parameters the URL writer never removes), `linkComponent` (the router link of every
159
+ block that renders a link; wrap it with `withStickyParams` to keep sticky search parameters). Without a
160
+ notification adapter `notify.*` does nothing and warns once outside production.
161
+
162
+ ```tsx
163
+ const StickyLink: PageLinkComponent = ({ href, ...props }) => {
164
+ const search = useSearchParams();
165
+ return <Link href={withStickyParams(href, ['workspace', 'debug'], search)} {...props} />;
166
+ };
167
+ <AdminUiProvider linkComponent={StickyLink} …>
168
+ ```
157
169
 
158
170
  4. **Confirmations.** Blocks that ask before a step open the package's confirm dialog (`useConfirmDialog`). A host
159
171
  with its own confirmation service passes it as `confirm` (`(options: ConfirmOptions) => Promise<boolean>`, a stable
@@ -177,6 +189,37 @@ const STATUS = defineStatusMap({ ACTIVE: { label: 'Active', tone: 'success' } })
177
189
  Client components (`DateCell`, `EntityListTable`, `Form`, …) render from server components as long as they get no
178
190
  function props there.
179
191
 
192
+ ## Dates in native inputs
193
+
194
+ `<input type="date">` and `type="datetime-local"` hold wall-clock text. Translate it with an explicit zone, `'local'`
195
+ (the browser's clock) or `'utc'`: `toDateInputValue(date, zone)` / `fromDateInputValue(text, zone)` and
196
+ `toDateTimeInputValue` / `fromDateTimeInputValue` (`./logic`). Empty or invalid gives `''` / `null`; no arithmetic. A
197
+ local time skipped when the clocks go forward resolves an hour later, a repeated one to its first occurrence.
198
+
199
+ ## Showcase
200
+
201
+ `./showcase` is a development page, not a screen block: mount it on a route of the host, below `AdminUiProvider`, to
202
+ see every block in the host's theme and tokens, light and dark side by side (each pane's dialogs and menus open inside
203
+ it).
204
+
205
+ ```tsx
206
+ 'use client';
207
+ import { Showcase } from '@mgamadeus/ddd-admin-ui/showcase';
208
+
209
+ export const ShowcaseScreen = () => (
210
+ <Showcase
211
+ // only a host with the optional peer sonner passes it; without it the section says it is skipped
212
+ loadNotifySonner={() => import('@mgamadeus/ddd-admin-ui/notify-sonner')}
213
+ sections={[{ id: 'host', title: 'Host blocks', content: <HostBlocks /> }]}
214
+ />
215
+ );
216
+ ```
217
+
218
+ It needs none of the optional peers: `./notify-sonner` loads only through `loadNotifySonner` (lazily, skipped when the
219
+ import fails), `./next` is described, never imported. `themes` limits the panes, `omit` leaves package sections out.
220
+ Its texts are developer-facing English and not part of `i18n-keys.json`. `SHOWCASE_COVERAGE` lists per entry the
221
+ components it draws and why the others are not drawn alone; the package's checks compare it with the exports.
222
+
180
223
  A list rendered on the server hydrates without a mismatch: the stored grid/table view (`useListViewParam`) and the
181
224
  saved filters of a list (`useUrlListState` with an adapter's `restore`) are read from browser storage only after
182
225
  hydration, and applied in the render right after it. A list that mounts on the client (no server HTML) reads them in
@@ -196,7 +239,7 @@ the context reaches the renderer separately, e.g. as `StatusDefinition.context`
196
239
  `context:` is a string literal, and `<Translate context="…">text</Translate>`; the key is `<text>__<context>`. A
197
240
  context held in a variable, or only on the map, is invisible to an extractor, so each label carries its literal.
198
241
 
199
- The package ships its texts as [`i18n-keys.json`](./i18n-keys.json) (`./i18n-keys.json`): every key with its text,
242
+ The package ships its texts (all entries except `./showcase`) as [`i18n-keys.json`](./i18n-keys.json) (`./i18n-keys.json`): every key with its text,
200
243
  context, translator hint and the files that use it, sorted by key. A host's text export merges this manifest instead of
201
244
  scanning the package (one usage per key, the hints with the host's own hint precedence). `ddd-admin-ui-i18n-manifest
202
245
  --check` verifies that the installed package's manifest matches its built files (`--dir <package>` checks another
@@ -224,7 +267,7 @@ pnpm install
224
267
  pnpm typecheck
225
268
  pnpm test # unit tests beside the sources, script tests and a failing fixture per check-package rule
226
269
  pnpm build # tsc → dist, declaration specifiers, stylesheets, manifests and shipped scripts
227
- pnpm test:render # after the build: list tables without the optional props render as in 0.1.0-rc.2
270
+ pnpm test:render # after the build: list snapshot (as in 0.1.0-rc.2), status contexts, the showcase
228
271
  node scripts/check-package.mjs --dir .
229
272
  pnpm pack --pack-destination "$TMPDIR" && test/consumer/run.sh "$TMPDIR"/mgamadeus-ddd-admin-ui-*.tgz pnpm "$TMPDIR/consumer-pnpm"
230
273
  ```
@@ -234,7 +277,7 @@ pnpm pack --pack-destination "$TMPDIR" && test/consumer/run.sh "$TMPDIR"/mgamade
234
277
  | `node scripts/build.mjs` (`pnpm build`) | removes `dist`, `tsc -p tsconfig.build.json` (one JS and declaration file per source file, directives kept, `.js` specifiers), rewrites the declarations' specifiers to `.js`, copies CSS, JSON and the shipped scripts into `dist` |
235
278
  | `node scripts/check-package.mjs --dir <package root or extracted tarball>` | the 13 package rules: exports and bins, directives, specifiers, no app alias, deny list (`--deny a,b` or `CHECK_PACKAGE_DENY`; `--require-deny-list` on release), declared dependencies, entry edges and reach, module state once, `files` and `sideEffects`, declarations in a strict consumer, no tests, fresh text manifest, tokens |
236
279
  | `node scripts/tokens-utilities.mjs [--write]` | checks (or regenerates) the `utilities` lists of `tokens.json` from the source |
237
- | `pnpm test:render` | server-renders list tables, bodies and badges from the build: without the optional table props the markup equals `test/consumer/fixtures/plain/list-snapshot.html` (taken from 0.1.0-rc.2); a status map's translation context reaches `StatusBadge` |
280
+ | `pnpm test:render` | server-renders list tables, bodies and badges from the build: without the optional table props the markup equals `test/consumer/fixtures/plain/list-snapshot.html` (taken from 0.1.0-rc.2); a status map's translation context reaches `StatusBadge`; the showcase renders (light, dark, every section) and its coverage list matches the exports |
238
281
  | `node scripts/build-i18n-manifest.mjs [--check]` (`pnpm i18n:manifest`) | regenerates `i18n-keys.json` from the source and `i18n/hints.json`; run it after changing a text or the version |
239
282
  | `node scripts/check-tokens.mjs <css> [tokens.json]` | the host check above (shipped as `ddd-admin-ui-check-tokens`) |
240
283
  | `node scripts/check-radix.mjs [host folder]` | the Radix copy check above (shipped as `ddd-admin-ui-check-radix`) |
package/STANDARDS.md CHANGED
@@ -13,7 +13,7 @@ Where the names below come from (setup and the entry list: [`README.md`](./READM
13
13
  | `@mgamadeus/ddd-admin-ui/page` | `EntityListPage`, `PageToolbar`, `ExportButton`, `AddEntityButton`, `EntityDetailShell`, `SectionHeader`, `DefinitionList`, `EditableCard`, `IconValue`, `IconValueRow`, `PageSections`, `CardGrid`, `PageFrame`, `PageHeader` |
14
14
  | `@mgamadeus/ddd-admin-ui/form` | `FormDrawer`, `FormActions`, `FormField`, `FormSection`, `useConfirmDialog` |
15
15
  | `@mgamadeus/ddd-admin-ui/glass` | `QuickFilterPills`, `CollapsibleCard`, `GlassGroup`, `ActionRow` |
16
- | `@mgamadeus/ddd-admin-ui/primitives` | `Button`, `Card`, `CardContent` |
16
+ | `@mgamadeus/ddd-admin-ui/primitives` | `Button`, `Card`, `CardContent`, `SegmentedControl` |
17
17
  | `@mgamadeus/ddd-admin-ui/next` | `useNextUrlStateAdapter`, `useNextDrawerUrlAdapter`, `useListViewParam` |
18
18
 
19
19
  Every screen renders below `AdminUiProvider`.
@@ -108,6 +108,7 @@ const selection = useRowSelection({
108
108
  getKey: task => toNumericId(task.id), // a host helper
109
109
  resetKey: filterString ?? '', // new filters → empty selection
110
110
  disabled: busy,
111
+ isSelectable: canDelete, // optional: other rows get a disabled checkbox, "select all" skips them
111
112
  });
112
113
 
113
114
  const handleBulkDelete = async () => {
@@ -168,7 +169,10 @@ const columns: EntityListColumn<Project>[] = [
168
169
  - Dates: `DateCell` in tables, `formatDateTime` / `formatDate` in text. Never raw strings, never
169
170
  `toLocaleString()`, never `new Date(value)`.
170
171
  - Numbers and ids: the host's formatters (one per kind), never ad-hoc `toFixed` calls.
171
- - Copy next to a value outside the ID column: a copy button on `useCopyToClipboard`.
172
+ - Copy next to a value outside the ID column: `CopyButton` (`value`, `label`, `reveal="hover"` in rows, `notify` for a
173
+ toast).
174
+ - A row that looks different (archived, muted): `rowClassName={(item, index) => …}` on the table or body.
175
+ - Small lists inside a card or section: `EntityListEmpty size="compact"` (one inline line, no 64 px block).
172
176
 
173
177
  ### Wide tables: tracks, pins, sort, row index
174
178
 
@@ -200,9 +204,12 @@ const columns: EntityListColumn<Project>[] = [
200
204
  scrolls like the others. The selection column and the row index always pin in a table that uses tracks, pins or the
201
205
  row index. A pinned cell paints the card surface and its edge only while content scrolls under it.
202
206
  - **Sort.** `sortKey` makes the header a button (with `aria-sort` on the sorted header); a click moves the sort on: not
203
- sorted → ascending → descending → not sorted (`null`: the request's default order). The table never sorts rows
204
- itself; the screen maps the key to its request. One sort at a time; keep it in the URL list state as one value
205
- (`formatListSort` / `parseListSort`, `key:asc`).
207
+ sorted → ascending → descending → not sorted (`null`: the request's default order). `sortStart: 'desc'` on a column
208
+ starts it descending (dates: newest first); `sortRequired` on the table never returns to unsorted (the third click
209
+ goes back to the first direction). An end-aligned sortable header puts the arrow before the label, so the label lines
210
+ up with the numbers. The table never sorts rows itself; the screen maps the key to its request. One sort at a time;
211
+ keep it in the URL list state as one value (`formatListSort` / `parseListSort`, `key:asc`; `nextListSort` takes the
212
+ same cycle).
206
213
  - **Row index.** `showRowIndex`: a leading `#` column, 1-based among the loaded rows.
207
214
  - `align: 'center' | 'end'` aligns header and cells (numbers and actions `end`).
208
215
 
@@ -251,6 +258,13 @@ Always with an icon.
251
258
 
252
259
  Single searchable select (not a filter): `Combobox`.
253
260
 
261
+ - Long or server-side lists: `onSearch` + `isSearching` with `useLatestSearch` (the block debounces, never shows a stale
262
+ term's options, resets the search on close); a picked value outside the current results passes `selectedOption`.
263
+ - `clearable` for an optional value (a clear control; picking the picked option clears it); without it a pick is kept.
264
+ An option whose value is `''` and means something ("No parent") stays an ordinary option.
265
+ - Headings with `group`, a count or status after the label with `badge`, a "Create “…”" row with `onRequestCreate`.
266
+ - A date range in a toolbar row or table header: `FilterDateRange hideLabel` with `fromLabel` / `toLabel`.
267
+
254
268
  ## 8. Detail screens — `EntityDetailShell`
255
269
 
256
270
  Every entity detail uses the shell: back + centred title + description + actions, `EntityMetadata` (ID, Created,
@@ -299,6 +313,12 @@ Inside a tab:
299
313
  </CardContent></Card>
300
314
  ```
301
315
 
316
+ A summary card or side panel lists facts as divided rows, label left and value right: `layout="rows"`.
317
+
318
+ Every link a block renders (tabs, the back link, the Add button, breadcrumb links) goes through the host's link component, set once as
319
+ `AdminUiProvider.linkComponent` (a block's own `linkComponent` prop still wins). A host with sticky search parameters
320
+ wraps its router link with `withStickyParams(href, names, currentSearch)`.
321
+
302
322
  Create screens: no `metadata` id yet → the strip renders nothing. Edit screens outside a shell keep
303
323
  `<EntityMetadata id={…} changeHistory={…} />` right under their `FormHeader`.
304
324
 
@@ -430,4 +450,34 @@ const entity = id ? (query.currentData?.supplier ?? null) : null; // currentDa
430
450
  - A list hosting two drawers passes its own `editKey` / `createKey`.
431
451
  - **Confirm**: the drawer asks through the package dialog; a host with its own confirmation service passes
432
452
  `confirm={hostConfirm}` (stable function, same Radix copy). The same prop exists on the translatable fields.
453
+ `ConfirmOptions.description` may be a React node; the package's own confirmations always pass plain text, so a
454
+ service that renders text only can show them.
433
455
  - One column inside the drawer (≤ 760 px): no `md:grid-cols-2` form grids.
456
+
457
+ ## 13. One value out of a few — `SegmentedControl`
458
+
459
+ | Need | Use |
460
+ |---|---|
461
+ | switch what one area shows, without own panels or routes (a period, a scope, a chart metric, a view mode) | `SegmentedControl` (`./primitives`) |
462
+ | sections of an entity with their own content or route | `EntityTabs` / `EntityDetailShell` tabs / `SectionHeader tabs` |
463
+ | quick filters on the clouds, "All" allowed, counts | `QuickFilterPills` |
464
+ | several values on at once (languages, weekdays) | `ChipToggleGroup` (or `MultiSelect` when the set grows) |
465
+ | the list's grid / table switch | `EntityListViewToggle` |
466
+
467
+ ```tsx
468
+ <SegmentedControl aria-label="Period" value={period} onValueChange={setPeriod} options={[
469
+ { value: 'week', label: 'Week' },
470
+ { value: 'month', label: 'Month', description: 'Calendar month' },
471
+ { value: 'year', label: 'Year', disabled: !hasYearData, disabledReason: 'Not enough data yet' },
472
+ ]} />
473
+ ```
474
+
475
+ - Always exactly one value; 2–5 short options. More, or long labels: a select.
476
+ - `activation="manual"` when a change is expensive (loads data): arrows move the focus, Space / Enter select.
477
+ - `iconOnly` keeps the label as the accessible name and shows it as a tooltip (needs `AdminUiProvider`).
478
+ - In a row with form controls use `height={36}` (the height of a select trigger).
479
+ - On a phone the control keeps its size and scrolls inside itself (the selected and the focused option stay in view);
480
+ with more than three options or long labels prefer `fullWidth` with short labels, or a select.
481
+ - Labels are English UI texts, translated by the control (`context` for an ambiguous word, marked as literal
482
+ `m('Open', { context: 'filter' })`); already translated text (names from the server) passes `translate: false`.
483
+ - A disabled option says why (`disabledReason`); a count goes in `badge` and, when it matters, in `description`.
@@ -6,15 +6,20 @@
6
6
  */
7
7
  @source './';
8
8
 
9
- /* Layer scale. The blocks and primitives stack with `z-(--layer-<name>)`; these are only defaults: zero specificity
10
- (`:where`) in the lowest cascade layer (`theme`), so any host declaration of a `--layer-*` variable wins, layered or
11
- not. Equal overlay / popover values: a later portal paints on top. */
9
+ /* Layer scale and component defaults. The blocks and primitives stack with `z-(--layer-<name>)`; these are only
10
+ defaults: zero specificity (`:where`) in the lowest cascade layer (`theme`), so any host declaration of a `--layer-*`
11
+ or `--segmented-control-*` variable wins, layered or not. Equal overlay / popover values: a later portal paints on
12
+ top. */
12
13
  @layer theme {
13
14
  :where(:root) {
14
15
  --layer-raised: 10;
15
16
  --layer-sticky: 20;
16
17
  --layer-overlay: 50;
17
18
  --layer-popover: 50;
19
+ /* SegmentedControl: corner of the track, the options and the indicator (the pill of the other toggles), and the
20
+ slide of the indicator (no slide with reduced motion). */
21
+ --segmented-control-radius: 9999px;
22
+ --segmented-control-duration: 200ms;
18
23
  }
19
24
  }
20
25
 
@@ -96,11 +101,11 @@
96
101
  }
97
102
  /* Sticky glass bars (bulk bar, form action bar). */
98
103
  /* Form actions at the top of the form: written last, shown first, sticky under the chrome. */
99
- form:has(> [data-form-actions]) {
104
+ form:has(> [data-form-actions='admin-ui']) {
100
105
  display: flex;
101
106
  flex-direction: column;
102
107
  }
103
- form > [data-form-actions] {
108
+ form > [data-form-actions='admin-ui'] {
104
109
  order: -1;
105
110
  }
106
111
  .glass-bar {
@@ -1 +1 @@
1
- {"version":3,"file":"FormActions.d.ts","sourceRoot":"","sources":["../../src/form/FormActions.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,SAAS,EAAqB,MAAM,OAAO,CAAC;AAS1D,MAAM,WAAW,gBAAgB;IAC/B,OAAO,CAAC,EAAE,SAAS,CAAC;IACpB,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB;;;;OAIG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB;;;;OAIG;IACH,SAAS,CAAC,EAAE,MAAM,GAAG,KAAK,CAAC;IAC3B;;;;OAIG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,4FAA4F;IAC5F,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAgED;;;;;;GAMG;AACH,eAAO,MAAM,WAAW,GAAI,0EAQzB,gBAAgB,gCAiDlB,CAAC"}
1
+ {"version":3,"file":"FormActions.d.ts","sourceRoot":"","sources":["../../src/form/FormActions.tsx"],"names":[],"mappings":"AAEA,OAAO,EAAE,KAAK,SAAS,EAAqB,MAAM,OAAO,CAAC;AAS1D,MAAM,WAAW,gBAAgB;IAC/B,OAAO,CAAC,EAAE,SAAS,CAAC;IACpB,SAAS,CAAC,EAAE,SAAS,CAAC;IACtB,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB;;;;OAIG;IACH,MAAM,CAAC,EAAE,OAAO,CAAC;IACjB;;;;OAIG;IACH,SAAS,CAAC,EAAE,MAAM,GAAG,KAAK,CAAC;IAC3B;;;;OAIG;IACH,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,4FAA4F;IAC5F,SAAS,CAAC,EAAE,MAAM,CAAC;CACpB;AAsED;;;;;;GAMG;AACH,eAAO,MAAM,WAAW,GAAI,0EAQzB,gBAAgB,gCAiDlB,CAAC"}
@@ -7,11 +7,16 @@ import { cn } from "../primitives/cn.js";
7
7
  import { DrawerFooter } from "./DrawerFooter.js";
8
8
  import { useIsInDrawer } from "./drawerSlots.js";
9
9
  import { useFormDirty } from "../logic/react/useFormDirty.js";
10
+ /**
11
+ * The value of the bar's `data-form-actions` attribute: `components.css` selects exactly this value, so a host's own
12
+ * action bar with a bare `data-form-actions` is not restyled by the package.
13
+ */
14
+ const FORM_ACTIONS_MARKER = 'admin-ui';
10
15
  /** Below `sm` the buttons share the row; from `sm` up each keeps its own width. */
11
16
  const ACTION_CLASS = 'flex-1 min-w-fit *:w-full sm:flex-none sm:*:w-auto';
12
17
  /**
13
18
  * The page action pill (host CSS `.glass-bar`): compact, right-aligned at the top of the form and sticky under the
14
- * fixed chrome (`--nav-h`) while the form scrolls. Forms write `<FormActions>` last; `data-form-actions` + the host
19
+ * fixed chrome (`--nav-h`) while the form scrolls. Forms write `<FormActions>` last; `data-form-actions="admin-ui"` + the host
15
20
  * CSS move it first (`order: -1`), so the DOM / tab order is unchanged everywhere.
16
21
  */
17
22
  // No row of its own where the page has tabs: the wrapper is 0 px tall and pulled 3.5 rem up (and as
@@ -75,6 +80,6 @@ export const FormActions = ({ primary, secondary, tertiary, sticky = true, place
75
80
  if (!sticky) {
76
81
  return (_jsx(DrawerFooter, { inlineClassName: cn('pt-6', className), children: _jsxs("div", { ref: anchor, className: "flex flex-wrap-reverse items-center gap-2", children: [secondary && _jsx("div", { className: ACTION_CLASS, children: secondary }), tertiary && _jsx("div", { className: ACTION_CLASS, children: tertiary }), primary && _jsx("div", { className: cn(ACTION_CLASS, 'sm:ml-auto'), children: primary })] }) }));
77
82
  }
78
- return (_jsx(DrawerFooter, { inlineClassName: cn(STICKY_WRAPPER_CLASS, placement === 'auto' && BESIDE_TABS_CLASS, className), inlineProps: { 'data-form-actions': '' }, children: _jsxs("div", { ref: anchor, className: STICKY_PILL_CLASS, children: [_jsx(ChangeStatus, { control: formContext?.control, isDirty: isDirty }), tertiary && _jsx("div", { className: ACTION_CLASS, children: tertiary }), secondary && _jsx("div", { className: ACTION_CLASS, children: secondary }), primary && _jsx("div", { className: ACTION_CLASS, children: primary })] }) }));
83
+ return (_jsx(DrawerFooter, { inlineClassName: cn(STICKY_WRAPPER_CLASS, placement === 'auto' && BESIDE_TABS_CLASS, className), inlineProps: { 'data-form-actions': FORM_ACTIONS_MARKER }, children: _jsxs("div", { ref: anchor, className: STICKY_PILL_CLASS, children: [_jsx(ChangeStatus, { control: formContext?.control, isDirty: isDirty }), tertiary && _jsx("div", { className: ACTION_CLASS, children: tertiary }), secondary && _jsx("div", { className: ACTION_CLASS, children: secondary }), primary && _jsx("div", { className: ACTION_CLASS, children: primary })] }) }));
79
84
  };
80
85
  //# sourceMappingURL=FormActions.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"FormActions.js","sourceRoot":"","sources":["../../src/form/FormActions.tsx"],"names":[],"mappings":"AAAA,YAAY,CAAC;;AAEb,OAAO,EAAkB,SAAS,EAAE,MAAM,EAAE,MAAM,OAAO,CAAC;AAC1D,OAAO,EAAgB,cAAc,EAAE,MAAM,iBAAiB,CAAC;AAE/D,OAAO,EAAE,YAAY,EAAE,MAAM,kBAAkB,CAAC;AAChD,OAAO,EAAE,EAAE,EAAE,MAAM,qBAAqB,CAAC;AACzC,OAAO,EAAE,YAAY,EAAE,MAAM,mBAAoB,CA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AE,MAAM,EAAE,SAAS,EAAE,iBAAiB,aAC5C,KAAC,YAAY,IAAC,OAAO,EAAE,WAAW,EAAE,OAAO,EAAE,OAAO,EAAE,OAAO,GAAI,EAChE,QAAQ,IAAI,cAAK,SAAS,EAAE,YAAY,YAAG,QAAQ,GAAO,EAC1D,SAAS,IAAI,cAAK,SAAS,EAAE,YAAY,YAAG,SAAS,GAAO,EAC5D,OAAO,IAAI,cAAK,SAAS,EAAE,YAAY,YAAG,OAAO,GAAO,IACrD,GACO,CAChB,CAAC;AACJ,CAAC,CAAC"}
@@ -24,7 +24,6 @@
24
24
  "Cancel": "Button at the bottom of the world form that discards the entries and returns to the world list; asks for confirmation if there are unsaved changes.",
25
25
  "Cancel__confirm-dialog": "Button on the left of a generic confirmation dialog that dismisses it without doing the action. Shown when the caller did not set its own label.",
26
26
  "Cancel__media-picker": "Footer button of the media picker dialog; click to close the dialog without changing the chosen media item.",
27
- "Cancelled": "Status badge label (short pill) in lists, cards and detail views, describing the state of a partner contract. Keep it short, like a status word.",
28
27
  "Change__media-field-action": "Button label under a media field preview; click to open the picker and replace the currently chosen image. Shown only when an image is already set.",
29
28
  "Clear %label%": "Accessible label of the small X button inside a text filter that empties it. %label% is the filter name, e.g. Name or Account ID.",
30
29
  "Clear all": "Button at the bottom of a multi-select dropdown that deselects every option in the list.",
@@ -46,11 +45,9 @@
46
45
  "Discard changes?": "Title of the confirmation dialog shown when the user closes a form drawer that has unsaved edits. Phrased as a question.",
47
46
  "Discard__unsaved-changes-confirm": "Destructive confirm button of the discard dialog; clicking it closes the form and loses the unsaved edits. Imperative verb.",
48
47
  "Dismiss": "Button in the AI translation panel that hides the finished progress list of the last translation run. Imperative.",
49
- "Done": "Status badge of one language in the translation progress list: the translation finished successfully.",
50
48
  "Edit__action": "Default accessible name and tooltip of the small pencil icon button in the top-right corner of a settings card; clicking it opens the edit form for that card. Imperative verb.",
51
49
  "Enter %language% text…": "Placeholder of a text input in a translatable field; %language% is the name of the active language tab, e.g. 'German'.",
52
50
  "Export to Excel": "Sample text of the outline button specimen in the UI showcase; imperative, exports a list as a spreadsheet. Maintenance UI showcase screen, Buttons section.",
53
- "Failed": "Status badge label (short pill) in lists, cards and detail views, describing the state of a push notification or mail delivery attempt. Keep it short, like a status word. Also used for other status families.",
54
51
  "Filters": "Button text in a list toolbar that opens or closes the collapsible panel with extra filters. Hidden on phones, where only the icon shows.",
55
52
  "Form sections": "Accessible label (aria-label) of the small sticky navigation bar at the top of a long admin form (challenge, campaign) that jumps between its panels.",
56
53
  "Grid view": "Tooltip and accessible label of the icon button in a list toolbar that switches the list to a grid of cards.",
@@ -80,7 +77,6 @@
80
77
  "Request contains invalid data": "Title of the red error toast and error box above a form after the server rejected a save because one or more fields are invalid (the fields are listed below it).",
81
78
  "Save changes": "Sample text of the primary button specimen in the UI showcase; imperative, a typical save action. Maintenance UI showcase screen, Buttons section.",
82
79
  "Search": "Accessible label of a search input field in a list toolbar, read by screen readers. Use the plain noun or verb for searching.",
83
- "Search for a command to run...": "Hidden (screen-reader only) description of the command palette dialog, telling the user to search for a command or page to run.",
84
80
  "Search…": "Placeholder text inside a search box above a list or table, and the generic placeholder of a dropdown's search field. Ends with an ellipsis.",
85
81
  "Sections": "Accessible name (screen reader label) of the sub-tab bar below a section heading when the heading is not plain text.",
86
82
  "Sections__tab-navigation": "Default accessible name (screen reader label, not visible) of the tab bar under the header of a detail screen, whose tabs switch between sections of the record such as General, Teams or Rides. Plural noun.",
@@ -111,7 +107,6 @@
111
107
  "Token authentication failed": "Error message from the server when the login session token is invalid or expired; the user has to sign in again.",
112
108
  "Translate to": "Form label above the language chips in the AI translation panel of an admin form; the chips are the target languages.",
113
109
  "Translate to selected locales": "Button in the AI translation panel that starts translating the texts into all language chips the user selected. Imperative.",
114
- "Translating": "Status badge of one language in the translation progress list: the translation request is running right now.",
115
110
  "Translating…": "Label of a button while the automatic AI translation is running for the selected languages; progress state, keep the ellipsis.",
116
111
  "Translation failed": "Fallback error message shown in the tooltip of a failed language in the translation progress list when the server gave no message.",
117
112
  "Unauthorized": "Short error message from the server when the request needs a valid login (session expired or missing); the user has to sign in again.",
@@ -122,10 +117,19 @@
122
117
  "Upload__media-picker": "Button in the media picker dialog header; click to choose image files from the computer and upload them as new media items.",
123
118
  "Uploading…__media-picker": "Button label in the media picker dialog while selected image files are being uploaded; the button is disabled meanwhile.",
124
119
  "View": "Label and accessible name of the toggle on the Home screen that switches between the Timeline and Kanban views.",
125
- "Waiting": "Short form of the status 'Waiting for Customer', on a compact status button in the support ticket sidebar. Keep it to one short word.",
126
120
  "Wrong credentials.": "Error message on the login page when the e-mail address / username or the password is wrong.",
127
121
  "Yes": "Option of a yes/no filter in the filter panel of a list; selecting it shows only records where the flag is set.",
128
122
  "Yes__boolean-flag": "Default label of a yes/no flag cell in a list table, shown with a green check when the flag is on, e.g. Active column.",
129
123
  "You have unsaved changes. Closing now will lose them.": "Body text of the discard confirmation dialog, warning that closing the form drawer throws away the user's unsaved edits.",
130
- "Row number": "Screen-reader name of the narrow '#' column at the start of a list table that numbers the loaded rows 1, 2, 3 …"
124
+ "Row number": "Screen-reader name of the narrow '#' column at the start of a list table that numbers the loaded rows 1, 2, 3 …",
125
+ "Clear": "Accessible name and tooltip of the small × inside a picker (combobox) that removes the picked value, leaving the field empty.",
126
+ "Copied": "Toast after a copy button put a value (an id, a link, a code) on the clipboard.",
127
+ "Could not copy": "Error toast when the browser refused to put a value on the clipboard (no permission or an insecure page).",
128
+ "Create “%term%”": "Last row of a picker's search list: creates a new entry named by the typed text (%term%) because no existing entry has that name.",
129
+ "Search for a command to run…": "Hidden (screen-reader only) description of the command palette dialog, telling the user to search for a command or page to run.",
130
+ "Waiting__translation-status": "Short form of the status 'Waiting for Customer', on a compact status button in the support ticket sidebar. Keep it to one short word.",
131
+ "Translating__translation-status": "Status badge of one language in the translation progress list: the translation request is running right now.",
132
+ "Done__translation-status": "Status badge of one language in the translation progress list: the translation finished successfully.",
133
+ "Failed__translation-status": "Status badge label (short pill) in lists, cards and detail views, describing the state of a push notification or mail delivery attempt. Keep it short, like a status word. Also used for other status families.",
134
+ "Cancelled__translation-status": "Status badge label (short pill) in lists, cards and detail views, describing the state of a partner contract. Keep it short, like a status word."
131
135
  }