@nadicodeai/ui 12.1.210 → 12.1.211

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 (125) hide show
  1. package/AGENTS.md +11 -4
  2. package/dist/components/account-menu.d.ts +3 -3
  3. package/dist/components/account-menu.d.ts.map +1 -1
  4. package/dist/components/account-menu.js +7 -5
  5. package/dist/components/activity-feed.d.ts +4 -2
  6. package/dist/components/activity-feed.d.ts.map +1 -1
  7. package/dist/components/activity-feed.js +10 -3
  8. package/dist/components/board.d.ts +45 -0
  9. package/dist/components/board.d.ts.map +1 -0
  10. package/dist/components/board.js +35 -0
  11. package/dist/components/breadcrumb.d.ts +3 -3
  12. package/dist/components/breadcrumb.d.ts.map +1 -1
  13. package/dist/components/button.d.ts +6 -1
  14. package/dist/components/button.d.ts.map +1 -1
  15. package/dist/components/button.js +5 -2
  16. package/dist/components/card-row.js +1 -1
  17. package/dist/components/chart-card.d.ts +19 -6
  18. package/dist/components/chart-card.d.ts.map +1 -1
  19. package/dist/components/chart-card.js +17 -7
  20. package/dist/components/collection-page.d.ts +4 -4
  21. package/dist/components/collection-page.d.ts.map +1 -1
  22. package/dist/components/collection-page.js +4 -8
  23. package/dist/components/column-foot.d.ts +53 -0
  24. package/dist/components/column-foot.d.ts.map +1 -0
  25. package/dist/components/column-foot.js +32 -0
  26. package/dist/components/conversation-card.d.ts +38 -0
  27. package/dist/components/conversation-card.d.ts.map +1 -0
  28. package/dist/components/conversation-card.js +19 -0
  29. package/dist/components/data-table.d.ts +26 -21
  30. package/dist/components/data-table.d.ts.map +1 -1
  31. package/dist/components/data-table.js +34 -22
  32. package/dist/components/entry-page.d.ts +55 -0
  33. package/dist/components/entry-page.d.ts.map +1 -0
  34. package/dist/components/entry-page.js +41 -0
  35. package/dist/components/entry-scene.d.ts +1 -1
  36. package/dist/components/entry-scene.js +1 -1
  37. package/dist/components/filter-toolbar.d.ts +43 -0
  38. package/dist/components/filter-toolbar.d.ts.map +1 -0
  39. package/dist/components/filter-toolbar.js +44 -0
  40. package/dist/components/hive-scene.d.ts +4 -1
  41. package/dist/components/hive-scene.d.ts.map +1 -1
  42. package/dist/components/hive-scene.js +6 -1
  43. package/dist/components/kpi-card.d.ts +10 -3
  44. package/dist/components/kpi-card.d.ts.map +1 -1
  45. package/dist/components/kpi-card.js +11 -3
  46. package/dist/components/message-notice.d.ts +3 -3
  47. package/dist/components/message-notice.js +1 -1
  48. package/dist/components/notice-banner.d.ts +1 -1
  49. package/dist/components/notice-banner.js +1 -1
  50. package/dist/components/object-workspace.d.ts +25 -5
  51. package/dist/components/object-workspace.d.ts.map +1 -1
  52. package/dist/components/object-workspace.js +30 -7
  53. package/dist/components/page-actions.d.ts +0 -2
  54. package/dist/components/page-actions.d.ts.map +1 -1
  55. package/dist/components/page-actions.js +1 -5
  56. package/dist/components/page-frame.d.ts +38 -0
  57. package/dist/components/page-frame.d.ts.map +1 -0
  58. package/dist/components/page-frame.js +29 -0
  59. package/dist/components/place-count.d.ts +20 -0
  60. package/dist/components/place-count.d.ts.map +1 -0
  61. package/dist/components/place-count.js +16 -0
  62. package/dist/components/plan-card.d.ts +49 -0
  63. package/dist/components/plan-card.d.ts.map +1 -0
  64. package/dist/components/plan-card.js +22 -0
  65. package/dist/components/product-band.d.ts +20 -0
  66. package/dist/components/product-band.d.ts.map +1 -0
  67. package/dist/components/product-band.js +23 -0
  68. package/dist/components/product-shell.d.ts +314 -44
  69. package/dist/components/product-shell.d.ts.map +1 -1
  70. package/dist/components/product-shell.js +465 -36
  71. package/dist/components/reading-column.d.ts +1 -1
  72. package/dist/components/reading-column.js +1 -1
  73. package/dist/components/record-list.d.ts +19 -3
  74. package/dist/components/record-list.d.ts.map +1 -1
  75. package/dist/components/record-list.js +23 -8
  76. package/dist/components/record-time.d.ts +6 -2
  77. package/dist/components/record-time.d.ts.map +1 -1
  78. package/dist/components/record-time.js +8 -5
  79. package/dist/components/row-edit-form.d.ts +1 -1
  80. package/dist/components/row-edit-form.js +1 -1
  81. package/dist/components/scope-switcher.d.ts +3 -1
  82. package/dist/components/scope-switcher.d.ts.map +1 -1
  83. package/dist/components/scope-switcher.js +3 -6
  84. package/dist/components/settings-page.d.ts +3 -3
  85. package/dist/components/settings-page.js +3 -3
  86. package/dist/components/settings-section.d.ts +18 -4
  87. package/dist/components/settings-section.d.ts.map +1 -1
  88. package/dist/components/settings-section.js +12 -4
  89. package/dist/components/sidebar-sections.d.ts.map +1 -1
  90. package/dist/components/sidebar-sections.js +4 -4
  91. package/dist/components/sidebar.d.ts +27 -5
  92. package/dist/components/sidebar.d.ts.map +1 -1
  93. package/dist/components/sidebar.js +55 -23
  94. package/dist/components/table-card.d.ts.map +1 -1
  95. package/dist/components/table-card.js +2 -1
  96. package/dist/components/toast.d.ts +10 -1
  97. package/dist/components/toast.d.ts.map +1 -1
  98. package/dist/components/toast.js +24 -1
  99. package/dist/index.d.ts +5 -0
  100. package/dist/index.d.ts.map +1 -1
  101. package/dist/index.js +5 -0
  102. package/dist/internal/button-classes.d.ts +2 -0
  103. package/dist/internal/button-classes.d.ts.map +1 -1
  104. package/dist/internal/button-classes.js +54 -46
  105. package/dist/internal/card-actions.d.ts +3 -0
  106. package/dist/internal/card-actions.d.ts.map +1 -0
  107. package/dist/internal/card-actions.js +4 -0
  108. package/dist/internal/footer-strip.d.ts.map +1 -1
  109. package/dist/internal/footer-strip.js +3 -1
  110. package/dist/lib/product-shell.d.ts +20 -0
  111. package/dist/lib/product-shell.d.ts.map +1 -0
  112. package/dist/lib/product-shell.js +19 -0
  113. package/dist/showcase/specimens/compositions.d.ts +15 -0
  114. package/dist/showcase/specimens/compositions.d.ts.map +1 -1
  115. package/dist/showcase/specimens/compositions.js +70 -0
  116. package/dist/showcase/specimens/index.d.ts +11 -0
  117. package/dist/showcase/specimens/index.d.ts.map +1 -1
  118. package/dist/showcase/specimens/navigation.d.ts +4 -0
  119. package/dist/showcase/specimens/navigation.d.ts.map +1 -1
  120. package/dist/showcase/specimens/navigation.js +26 -1
  121. package/dist/showcase/usage.generated.d.ts +1 -1
  122. package/dist/showcase/usage.generated.d.ts.map +1 -1
  123. package/dist/showcase/usage.generated.js +159 -38
  124. package/dist/styles/components.css +12 -0
  125. package/package.json +6 -2
package/AGENTS.md CHANGED
@@ -33,10 +33,16 @@ that draws it for all of them, never in `DESIGN.md`
33
33
  no drawing of its own of a job the kit owns, and no lint exemption stands in
34
34
  for the move.
35
35
  `packages/oxlint-plugin/oxlint-config/composition-exemptions.test.ts` holds
36
- the lint configs to the list of exemptions, the lint refuses a comment that
37
- turns a composition rule off in a product file, and
36
+ the lint configs to the list of exemptions, which stays empty, the lint
37
+ refuses a comment that turns a composition rule off in a product file, and
38
38
  `tools/git-hooks/composition-exemptions-guard.mjs` refuses a push that adds to
39
- the list, so it only shrinks.
39
+ the list. How the frame looks as each product uses it is held by the pictures
40
+ `tests/visual/appearance.visual.ts` compares before the push, so a look
41
+ changes only as new pictures made with `node tools/ci/appearance-baselines.mjs`
42
+ and committed, which the owner and the reviewers see before and after in the
43
+ diff. The pictures run only with `APPEARANCE_PICTURES=1`, which `test:visual`
44
+ hashes: the `ui visual` lane, post-merge's `test (website)` job and that
45
+ script set it, and a run without it skips them.
40
46
  - **Elements.** An app whose pages must reach an element through a shared
41
47
  component sets `jsxImportSource` to `#jsx`, a module of its own that types the
42
48
  intrinsic elements without it, so a raw `<table>` or `<h1>` on a page is a
@@ -73,7 +79,8 @@ that draws it for all of them, never in `DESIGN.md`
73
79
  Iconify's `logos` set (`platform-mark.tsx`).
74
80
  - **Charts** are stock shadcn registry items. What only a browser lays out, such
75
81
  as a category axis's labels, is held by the browser suite in `tests/visual/`,
76
- which post-merge's `test (website)` job runs. A chart the kit lacks is pulled from
82
+ which the pre-push `ui visual` lane and post-merge's `test (website)` job
83
+ run. A chart the kit lacks is pulled from
77
84
  `https://ui.shadcn.com/r/styles/new-york-v4/<name>.json`.
78
85
  - **Releases.** No change names a version; the publish picks it after merge:
79
86
  `../../docs/agents/publish.md`.
@@ -129,9 +129,9 @@ export type AccountMenuProps = AccountMenuEnd & {
129
129
  * and the menu opening on that same identity with what they can do beneath it.
130
130
  *
131
131
  * @family Menus
132
- * @when The account at the sidebar's foot in the Portal, Nadia and Alveare: the account's settings, Theme, Language, a product's own settings, its commands, and Sign out. In Alveare Server, which has no account to leave, the company's workspace on this computer: its mark, its status, Theme, Language, Check for updates, Help, and Stop workspace last (nadicode decision). `ProductShell` draws it from its `account`; Alveare mounts it in Buzz's sidebar (nadicode decision, 6 November 2026).
133
- * @instead A record's commands go to `RecordList` or `RecordCommands`, a page's to its composition's `actions`; a setting that changes what the product does is a draft on a `SettingsPage` until its card's Save (nadicode decision). A product never renders it outside `ProductShell`, which `nadicodeai/page-composition` refuses (nadicode decision).
134
- * @behaviour The menu opens 6 px above its trigger, 288 px wide: a header of the name and every line under it with the gear at its end and no picture, one divider, then 36 px rows, each its label leading and its icon or control trailing in muted ink, in an order the component draws and the product never sets: the product's leading commands first, Theme and Language as small round pills, the product's choices as submenus, the Settings row to the gear's destination, its other commands, each command with any reading before its icon, and Sign out last in the body colour, since signing out destroys nothing (owner ruling, 16 October 2026; the Settings row as well as the gear, owner ruling, 27 October 2026). Theme and Language apply at once and keep the menu open, with no Save; a product with a Preferences page may also show them there, where they apply at once too (owner ruling, 6 November 2026). While signing out, Sign out says its pending word, the menu stays open and the trigger is locked; a failure shows under it. A Sign out that `confirms` closes the menu instead, for the product's own confirmation (nadicode decision). A product with no account to leave ends on its own `last` command in Sign out's place; a destructive one, such as Stop workspace, stands after a divider in the error colour and carries its `confirm`, which the menu opens once it closes (nadicode decision). A command that `keepsOpen` runs with the menu open: it says its pending word, aria-busy, then its `outcome` under its row, a muted line or a failure in the error colour, until the menu closes (nadicode decision). A company's account (`identity.mark`) shows the company's `IdentityMark` at 20 px in the trigger in place of a person's picture (nadicode decision).
132
+ * @when The account at the sidebar's foot in the Portal, Nadia and Alveare: the account's settings, Theme, Language, a product's own settings, its commands, and Sign out. In Alveare Server, which has no account to leave, the company's workspace on this computer: its mark, its status, Theme, Language, Check for updates, Help, and Stop workspace last (nadicode decision). `ProductShell` draws it from its `account`; Alveare mounts it in Buzz's sidebar through `ColumnFoot` (nadicode decision, 6 November 2026).
133
+ * @instead A record's commands go to `RecordList` or `RecordCommands`, a page's to its composition's `actions`; a setting that changes what the product does is on a `SettingsPage`, and when a choice applies is `SettingsSection`'s rule. A product never renders it outside `ProductShell`, which `nadicodeai/page-composition` refuses (nadicode decision).
134
+ * @behaviour The menu opens 6 px above its trigger, 288 px wide: a header of the name and every line under it with the gear at its end and no picture, one divider, then 36 px rows, each its label leading and its icon or control trailing in muted ink, in an order the component draws and the product never sets: the product's leading commands first, Theme and Language as small round pills, the product's choices as submenus, the Settings row to the gear's destination, its other commands, each command with any reading before its icon, and Sign out last in the body colour, since signing out destroys nothing (owner ruling, 16 October 2026; the Settings row as well as the gear, owner ruling, 27 October 2026). Theme and Language keep the menu open when picked, so the result shows without reopening it; when they apply is `SettingsSection`'s rule, which holds here and on a product's preferences page alike. While signing out, Sign out says its pending word, the menu stays open and the trigger is locked; a failure shows under it. A Sign out that `confirms` closes the menu instead, for the product's own confirmation (nadicode decision). A product with no account to leave ends on its own `last` command in Sign out's place; a destructive one, such as Stop workspace, stands after a divider in the error colour and carries its `confirm`, which the menu opens once it closes (nadicode decision). A command that `keepsOpen` runs with the menu open: it says its pending word, aria-busy, then its `outcome` under its row, a muted line or a failure in the error colour, until the menu closes (nadicode decision). A company's account (`identity.mark`) shows the company's `IdentityMark` at 20 px in the trigger in place of a person's picture (nadicode decision).
135
135
  * @words The menu's name ("Account", "Workspace"), the account's name and lines, then each row's noun or verb from the product's catalogue: "Theme", "Language", "Usage", "Check for updates", "Sign out" and "Signing out".
136
136
  * @access The trigger and the menu are named "{label}: {name}"; the gear carries its label; the pending sign-out or command is aria-busy and announced through a status; a failure is an alert, a neutral outcome a status.
137
137
  */
@@ -1 +1 @@
1
- {"version":3,"file":"account-menu.d.ts","sour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EAAE,kBAAkB,CAAC,MAAM,CAAC,CAAC;IACtC,OAAO,CAAC,EAAE,SAAS,iBAAiB,EAAE,CAAC;IACvC,2EAA2E;IAC3E,eAAe,CAAC,EAAE,SAAS,kBAAkB,EAAE,CAAC;IAChD,gEAAgE;IAChE,QAAQ,CAAC,EAAE,SAAS,kBAAkB,EAAE,CAAC;IACzC;;;OAGG;IACH,WAAW,CAAC,EAAE,OAAO,CAAC;IACtB,KAAK,CAAC,EAAE,QAAQ,GAAG,KAAK,GAAG,OAAO,CAAC;IACnC,IAAI,CAAC,EAAE,QAAQ,GAAG,MAAM,GAAG,OAAO,GAAG,KAAK,CAAC;IAC3C,iFAAiF;IACjF,YAAY,CAAC,EAAE,CAAC,IAAI,EAAE,OAAO,KAAK,IAAI,CAAC;CACxC,CAAC;AAKF;;;;;;;;;;GAUG;AACH,wBAAgB,WAAW,CAAC,EAC1B,KAAe,EACf,OAAoB,EACpB,QAAsB,EACtB,QAAQ,EACR,KAAK,EACL,QAAQ,EACR,IAAI,EACJ,eAA6B,EAC7B,YAAY,EACZ,WAAmB,EACnB,QAAQ,EACR,IAAY,EACZ,OAAO,EACP,KAAK,GACN,EAAE,gBAAgB,+BA4ElB"}
@@ -18,7 +18,7 @@ import { cn } from "../lib/utils.js";
18
18
  * account menu's trigger draws it, and so does a sample of the Portal's column.
19
19
  */
20
20
  export function AccountMenuIdentity({ className, identity, pictureOnly = false, }) {
21
- return (_jsxs("span", { className: cn("flex min-w-0 items-center gap-2 text-left text-sm", !pictureOnly && "flex-1", className), "data-slot": "account-menu-identity", children: [identity.mark ? (_jsx(IdentityMark, { ...identity.mark, size: 20 })) : (_jsxs(Avatar, { className: "size-5", decorative: true, size: "sm", children: [identity.image ? _jsx(AvatarImage, { alt: "", src: identity.image }) : null, _jsx(AvatarFallback, { children: identity.initials === undefined || identity.initials === "" ? (_jsx(UserRound, { "aria-hidden": "true", className: "size-3/5" })) : (identity.initials) })] })), pictureOnly ? null : (_jsxs(_Fragment, { children: [_jsxs("span", { className: "grid min-w-0 flex-1 leading-tight", children: [_jsx("span", { className: "truncate text-foreground", children: identity.name }), identity.notice ? _jsx("span", { className: "truncate text-xs", children: identity.notice }) : null] }), _jsx("span", { "aria-hidden": "true", className: "grid size-6 shrink-0 place-content-center rounded-full border border-border bg-popover text-muted-foreground transition-colors group-hover/account:text-foreground group-data-popup-open/account:text-foreground", children: _jsx(Ellipsis, { className: "size-3" }) })] }))] }));
21
+ return (_jsxs("span", { className: cn("flex min-w-0 items-center gap-2 text-left text-sm", !pictureOnly && "flex-1 column-collapsed:flex-initial", className), "data-slot": "account-menu-identity", children: [identity.mark ? (_jsx(IdentityMark, { ...identity.mark, size: 20 })) : (_jsxs(Avatar, { className: "size-5", decorative: true, size: "sm", children: [identity.image ? _jsx(AvatarImage, { alt: "", src: identity.image }) : null, _jsx(AvatarFallback, { children: identity.initials === undefined || identity.initials === "" ? (_jsx(UserRound, { "aria-hidden": "true", className: "size-3/5" })) : (identity.initials) })] })), pictureOnly ? null : (_jsxs(_Fragment, { children: [_jsxs("span", { className: "grid min-w-0 flex-1 leading-tight column-collapsed:hidden", children: [_jsx("span", { className: "truncate text-foreground", children: identity.name }), identity.notice ? _jsx("span", { className: "truncate text-xs", children: identity.notice }) : null] }), _jsx("span", { "aria-hidden": "true", className: "grid size-6 shrink-0 place-content-center rounded-full border border-border bg-popover text-muted-foreground transition-colors group-hover/account:text-foreground group-data-popup-open/account:text-foreground column-collapsed:hidden", children: _jsx(Ellipsis, { className: "size-3" }) })] }))] }));
22
22
  }
23
23
  const NO_CHOICES = [];
24
24
  const NO_COMMANDS = [];
@@ -27,9 +27,9 @@ const NO_COMMANDS = [];
27
27
  * and the menu opening on that same identity with what they can do beneath it.
28
28
  *
29
29
  * @family Menus
30
- * @when The account at the sidebar's foot in the Portal, Nadia and Alveare: the account's settings, Theme, Language, a product's own settings, its commands, and Sign out. In Alveare Server, which has no account to leave, the company's workspace on this computer: its mark, its status, Theme, Language, Check for updates, Help, and Stop workspace last (nadicode decision). `ProductShell` draws it from its `account`; Alveare mounts it in Buzz's sidebar (nadicode decision, 6 November 2026).
31
- * @instead A record's commands go to `RecordList` or `RecordCommands`, a page's to its composition's `actions`; a setting that changes what the product does is a draft on a `SettingsPage` until its card's Save (nadicode decision). A product never renders it outside `ProductShell`, which `nadicodeai/page-composition` refuses (nadicode decision).
32
- * @behaviour The menu opens 6 px above its trigger, 288 px wide: a header of the name and every line under it with the gear at its end and no picture, one divider, then 36 px rows, each its label leading and its icon or control trailing in muted ink, in an order the component draws and the product never sets: the product's leading commands first, Theme and Language as small round pills, the product's choices as submenus, the Settings row to the gear's destination, its other commands, each command with any reading before its icon, and Sign out last in the body colour, since signing out destroys nothing (owner ruling, 16 October 2026; the Settings row as well as the gear, owner ruling, 27 October 2026). Theme and Language apply at once and keep the menu open, with no Save; a product with a Preferences page may also show them there, where they apply at once too (owner ruling, 6 November 2026). While signing out, Sign out says its pending word, the menu stays open and the trigger is locked; a failure shows under it. A Sign out that `confirms` closes the menu instead, for the product's own confirmation (nadicode decision). A product with no account to leave ends on its own `last` command in Sign out's place; a destructive one, such as Stop workspace, stands after a divider in the error colour and carries its `confirm`, which the menu opens once it closes (nadicode decision). A command that `keepsOpen` runs with the menu open: it says its pending word, aria-busy, then its `outcome` under its row, a muted line or a failure in the error colour, until the menu closes (nadicode decision). A company's account (`identity.mark`) shows the company's `IdentityMark` at 20 px in the trigger in place of a person's picture (nadicode decision).
30
+ * @when The account at the sidebar's foot in the Portal, Nadia and Alveare: the account's settings, Theme, Language, a product's own settings, its commands, and Sign out. In Alveare Server, which has no account to leave, the company's workspace on this computer: its mark, its status, Theme, Language, Check for updates, Help, and Stop workspace last (nadicode decision). `ProductShell` draws it from its `account`; Alveare mounts it in Buzz's sidebar through `ColumnFoot` (nadicode decision, 6 November 2026).
31
+ * @instead A record's commands go to `RecordList` or `RecordCommands`, a page's to its composition's `actions`; a setting that changes what the product does is on a `SettingsPage`, and when a choice applies is `SettingsSection`'s rule. A product never renders it outside `ProductShell`, which `nadicodeai/page-composition` refuses (nadicode decision).
32
+ * @behaviour The menu opens 6 px above its trigger, 288 px wide: a header of the name and every line under it with the gear at its end and no picture, one divider, then 36 px rows, each its label leading and its icon or control trailing in muted ink, in an order the component draws and the product never sets: the product's leading commands first, Theme and Language as small round pills, the product's choices as submenus, the Settings row to the gear's destination, its other commands, each command with any reading before its icon, and Sign out last in the body colour, since signing out destroys nothing (owner ruling, 16 October 2026; the Settings row as well as the gear, owner ruling, 27 October 2026). Theme and Language keep the menu open when picked, so the result shows without reopening it; when they apply is `SettingsSection`'s rule, which holds here and on a product's preferences page alike. While signing out, Sign out says its pending word, the menu stays open and the trigger is locked; a failure shows under it. A Sign out that `confirms` closes the menu instead, for the product's own confirmation (nadicode decision). A product with no account to leave ends on its own `last` command in Sign out's place; a destructive one, such as Stop workspace, stands after a divider in the error colour and carries its `confirm`, which the menu opens once it closes (nadicode decision). A command that `keepsOpen` runs with the menu open: it says its pending word, aria-busy, then its `outcome` under its row, a muted line or a failure in the error colour, until the menu closes (nadicode decision). A company's account (`identity.mark`) shows the company's `IdentityMark` at 20 px in the trigger in place of a person's picture (nadicode decision).
33
33
  * @words The menu's name ("Account", "Workspace"), the account's name and lines, then each row's noun or verb from the product's catalogue: "Theme", "Language", "Usage", "Check for updates", "Sign out" and "Signing out".
34
34
  * @access The trigger and the menu are named "{label}: {name}"; the gear carries its label; the pending sign-out or command is aria-busy and announced through a status; a failure is an alert, a neutral outcome a status.
35
35
  */
@@ -37,7 +37,9 @@ export function AccountMenu({ align = "start", choices = NO_CHOICES, commands =
37
37
  const name = `${label}: ${identity.name}`;
38
38
  const { arm, dialog } = useCommandRunner();
39
39
  const commandRows = (rows) => rows.map((command) => _jsx(AccountMenuCommandRow, { command: arm(command) }, command.label));
40
- return (_jsxs(_Fragment, { children: [_jsxs(DropdownMenu, { onOpenChange: onOpenChange, children: [_jsx(DropdownMenuTrigger, { "aria-label": name, className: cn("group/account flex min-h-9 min-w-0 items-center rounded-full outline-none focus-visible:nc-focus-outline focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50", pictureOnly ? "justify-center" : "w-full pr-2 pl-2.5"), disabled: signOut?.pending === true, children: _jsx(AccountMenuIdentity, { identity: identity, pictureOnly: pictureOnly }) }), _jsxs(DropdownMenuContent, { align: align, "aria-label": name, className: "w-72 max-w-[calc(100vw-2rem)] p-1.5", density: "comfortable", side: side, sideOffset: 6, children: [_jsxs(DropdownMenuGroup, { className: "flex min-w-0 items-center gap-2 py-1.5 pl-2", "data-slot": "account-menu-header", children: [_jsxs("span", { className: "grid min-w-0 flex-1 gap-0.5 text-left", children: [_jsx("span", { className: "truncate text-sm font-medium text-foreground", children: identity.name }), identity.notice ? _jsx("span", { className: "text-xs", children: identity.notice }) : null, identity.lines?.map((line, index) => (_jsx("span", { className: "truncate text-xs text-muted-foreground", children: line }, index)))] }), settings ? (_jsx(DropdownMenuItem, { "aria-label": settings.label, className: "text-muted-foreground", iconOnly: true, ...menuItemAction(settings), children: _jsx(Settings, { "aria-hidden": "true" }) })) : null] }), _jsx(DropdownMenuSeparator, { className: "-mx-1.5 my-1.5" }), _jsxs(DropdownMenuGroup, { children: [commandRows(leadingCommands), _jsx(ThemeModeMenu, { ...theme }), language ? _jsx(MenuChoiceRow, { ...language }) : null, choices.map((choice) => (_jsx(AccountMenuChoiceRow, { choice: choice }, choice.label))), settings ? (_jsx(AccountMenuRow, { icon: _jsx(Settings, {}), ...menuItemAction(settings), children: settings.label })) : null, commandRows(commands), signOut ? _jsx(AccountMenuSignOutRow, { signOut: signOut }) : null, last?.destructive ? _jsx(DropdownMenuSeparator, { className: "-mx-1.5 my-1.5" }) : null, last ? _jsx(AccountMenuCommandRow, { command: arm(last) }) : null] })] })] }), dialog] }));
40
+ return (_jsxs(_Fragment, { children: [_jsxs(DropdownMenu, { onOpenChange: onOpenChange, children: [_jsx(DropdownMenuTrigger, { "aria-label": name, className: cn("group/account flex min-h-9 min-w-0 items-center rounded-full outline-none focus-visible:nc-focus-outline focus-visible:outline-ring disabled:pointer-events-none disabled:opacity-50", pictureOnly
41
+ ? "justify-center"
42
+ : "w-full pr-2 pl-2.5 column-collapsed:w-auto column-collapsed:justify-center column-collapsed:px-0"), disabled: signOut?.pending === true, children: _jsx(AccountMenuIdentity, { identity: identity, pictureOnly: pictureOnly }) }), _jsxs(DropdownMenuContent, { align: align, "aria-label": name, className: "w-72 max-w-[calc(100vw-2rem)] p-1.5", density: "comfortable", side: side, sideOffset: 6, children: [_jsxs(DropdownMenuGroup, { className: "flex min-w-0 items-center gap-2 py-1.5 pl-2", "data-slot": "account-menu-header", children: [_jsxs("span", { className: "grid min-w-0 flex-1 gap-0.5 text-left", children: [_jsx("span", { className: "truncate text-sm font-medium text-foreground", children: identity.name }), identity.notice ? _jsx("span", { className: "text-xs", children: identity.notice }) : null, identity.lines?.map((line, index) => (_jsx("span", { className: "truncate text-xs text-muted-foreground", children: line }, index)))] }), settings ? (_jsx(DropdownMenuItem, { "aria-label": settings.label, className: "text-muted-foreground", iconOnly: true, ...menuItemAction(settings), children: _jsx(Settings, { "aria-hidden": "true" }) })) : null] }), _jsx(DropdownMenuSeparator, { className: "-mx-1.5 my-1.5" }), _jsxs(DropdownMenuGroup, { children: [commandRows(leadingCommands), _jsx(ThemeModeMenu, { ...theme }), language ? _jsx(MenuChoiceRow, { ...language }) : null, choices.map((choice) => (_jsx(AccountMenuChoiceRow, { choice: choice }, choice.label))), settings ? (_jsx(AccountMenuRow, { icon: _jsx(Settings, {}), ...menuItemAction(settings), children: settings.label })) : null, commandRows(commands), signOut ? _jsx(AccountMenuSignOutRow, { signOut: signOut }) : null, last?.destructive ? _jsx(DropdownMenuSeparator, { className: "-mx-1.5 my-1.5" }) : null, last ? _jsx(AccountMenuCommandRow, { command: arm(last) }) : null] })] })] }), dialog] }));
41
43
  }
42
44
  function AccountMenuSignOutRow({ signOut }) {
43
45
  return (_jsxs(_Fragment, { children: [_jsx(AccountMenuRow, { "aria-busy": signOut.pending || undefined, closeOnClick: signOut.confirms === true, disabled: signOut.pending, icon: _jsx(LogOut, {}), onClick: () => {
@@ -47,6 +47,8 @@ export type ActivityFeedProps = {
47
47
  noMatch?: Omit<EmptyStateKind<"noResults">, "kind">;
48
48
  failed?: EmptyStateKind<"failed">;
49
49
  };
50
+ /** What stands in an ActivityFeed's place while its page reads the events: the rows the feed draws while it loads, with no words. */
51
+ export declare function ActivityFeedSkeleton(): import("react").JSX.Element;
50
52
  /**
51
53
  * What happened to a record, and when: one row per event under its day,
52
54
  * newest first.
@@ -54,9 +56,9 @@ export type ActivityFeedProps = {
54
56
  * @family Compositions
55
57
  * @when A record's history: a Customer's, a Partner's or an Installation's Activity tab in the Portal, the company wiki's updates in Nadia. Each answers "what happened, and when?".
56
58
  * @instead The steps of one Agent run, read in order, are a RunTimeline; a list of records a person finds and acts on is a CollectionPage; a single "last changed" fact is a RecordTime.
57
- * @behaviour The search, filters and window sit right above the rows, kept in the URL by the product. Days stand newest first, each a title and a muted date over one card of rows; a row is the time of day, the actor's 24 px mark, the sentence with a status badge only for an exception, and one muted line of detail. "Show older events" follows the last day as a full-width `LoadMoreButton`, or as a `ButtonLink` when it navigates; there is never a page count. States, first that holds: failed, loading (still rows in the row's shape), no match with Clear filters, nothing yet in one line, the days. Nothing yet is one quiet line, never a picture; a failed read is the warning mark with Retry, never "no events". The time is the time of day in the viewer's own zone in tabular figures (`RecordTime`), with UTC and the viewer's zone in its hover card; one rule for every feed, never a time printed in UTC as the viewer's: a server-rendered page passes the viewer's `timeZone`, since without it the server and the first client render print UTC. The actor's mark is a person's initials, an Agent's real orb or an Installation's tile; the system's own work has no mark and never takes an orb. Under 900 px the time moves under the sentence. It draws no card header: the tab is the title.
59
+ * @behaviour The search, filters and window sit right above the rows, kept in the URL by the product. Days stand newest first, each a title and a muted date over one card of rows; a row is the time of day, the actor's 24 px mark, the sentence with a status badge only for an exception, and one muted line of detail. "Show older events" follows the last day as a full-width `LoadMoreButton`, or as a `ButtonLink` when it navigates; there is never a page count. States, first that holds: failed, loading (still rows in the row's shape, which `ActivityFeedSkeleton` also draws while a page reads the events before it can draw the feed; nadicode decision), no match with Clear filters, nothing yet in one line, the days. Nothing yet is one quiet line, never a picture; a failed read is the warning mark with Retry, never "no events". The time is the time of day in the viewer's own zone in tabular figures (`RecordTime`), with UTC and the viewer's zone in its hover card; one rule for every feed, never a time printed in UTC as the viewer's: a server-rendered page passes the viewer's `timeZone`, since without it the server and the first client render print UTC. The actor's mark is a person's initials, an Agent's real orb or an Installation's tile; the system's own work has no mark and never takes an orb. Under 900 px the time moves under the sentence. It draws no card header: the tab is the title.
58
60
  * @words The sentence names the actor in `<strong>`, the action in the past tense and the object as a link that keeps the text's colour: "Marco Rinaldi created the Agent Acme Quotes". Day titles are "Today", "Yesterday", then the weekday; dates are the product's own ("14 October"). Nothing yet: "No events yet." and what will appear. No match: "No events match these filters.".
59
- * @access The toolbar is named by `label`; each day's title is a level-3 heading over a list of its events; while loading, one status named by `loadingLabel` stands for the rows; each time is a `<time>` with its exact moment for assistive technology. A system event has no mark, so nothing empty is announced.
61
+ * @access The toolbar is named by `label`; each day's title is a level-3 heading over a list of its events; while loading, one status named by `loadingLabel` stands for the rows, and `ActivityFeedSkeleton`, a page's placeholder before it can draw the feed, is busy and carries no words; each time is a `<time>` with its exact moment for assistive technology. A system event has no mark, so nothing empty is announced.
60
62
  */
61
63
  export declare function ActivityFeed({ label, days, locale, timeZone, search, filters, range, older, loadingLabel, empty, noMatch, failed, }: ActivityFeedProps): import("react").JSX.Element;
62
64
  //# sourceMappingURL=activity-feed.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"activity-feed.d.ts","sourceRoot":"","sources":["../../src/components/activity-feed.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,EAAE,cAAc,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAIvD,OAAO,EAAE,gBAAgB,EAAE,MAAM,uCAAuC,CAAC;AACzE,OAAO,EAAqB,KAAK,sBAAs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EACJ,MAAM,EACN,QAAQ,EACR,MAAM,EACN,OAAO,EACP,KAAK,EACL,KAAK,EACL,YAAY,EACZ,KAAK,EACL,OAAO,EACP,MAAM,GACP,EAAE,iBAAiB,+BAiCnB"}
@@ -20,8 +20,15 @@ const LOADING_ROWS = ["first", "second", "third"];
20
20
  function EventRow({ event, locale, timeZone }) {
21
21
  return (_jsxs("li", { className: ROW, "data-slot": "activity-event", children: [_jsx("div", { className: `text-label-sm leading-5 ${UNDER_TEXT}`, "data-slot": "activity-event-time", children: _jsx(RecordTime, { at: event.at, locale: locale, mode: "clock", timeZone: timeZone }) }), _jsx("div", { className: `flex h-5 items-center ${MARK_CELL}`, children: event.actor ? _jsx(IdentityMark, { ...event.actor, size: 24 }) : null }), _jsxs("div", { className: `min-w-0 ${TEXT_CELL}`, children: [_jsxs("div", { className: "text-body-sm text-muted-foreground [&_strong]:font-medium [&_strong]:text-foreground", children: [event.summary, event.status ? (_jsx(StatusBadge, { className: "ml-1.5 align-middle", label: event.status.label, tone: event.status.tone })) : null] }), event.detail ? (_jsx("div", { className: "mt-0.5 text-label-sm text-muted-foreground", children: event.detail })) : null] })] }));
22
22
  }
23
+ function LoadingCard() {
24
+ return (_jsx(Card, { className: "gap-0 divide-y divide-border py-0", surface: "resting", children: LOADING_ROWS.map((row) => (_jsxs("div", { "aria-hidden": "true", className: ROW, children: [_jsx(Skeleton, { className: `mt-1 h-2.5 w-12 ${UNDER_TEXT}` }), _jsx(Skeleton, { className: `size-6 ${MARK_CELL}`, shape: "circle" }), _jsxs("div", { className: `grid gap-2 pt-1 ${TEXT_CELL}`, children: [_jsx(Skeleton, { className: "h-2.5 w-4/5" }), _jsx(Skeleton, { className: "h-2.5 w-3/5" })] })] }, row))) }));
25
+ }
23
26
  function LoadingRows({ label }) {
24
- return (_jsx(SkeletonRegion, { "aria-label": label, busy: true, role: "status", children: _jsx(Card, { className: "gap-0 divide-y divide-border py-0", surface: "resting", children: LOADING_ROWS.map((row) => (_jsxs("div", { "aria-hidden": "true", className: ROW, children: [_jsx(Skeleton, { className: `mt-1 h-2.5 w-12 ${UNDER_TEXT}` }), _jsx(Skeleton, { className: `size-6 ${MARK_CELL}`, shape: "circle" }), _jsxs("div", { className: `grid gap-2 pt-1 ${TEXT_CELL}`, children: [_jsx(Skeleton, { className: "h-2.5 w-4/5" }), _jsx(Skeleton, { className: "h-2.5 w-3/5" })] })] }, row))) }) }));
27
+ return (_jsx(SkeletonRegion, { "aria-label": label, busy: true, role: "status", children: _jsx(LoadingCard, {}) }));
28
+ }
29
+ /** What stands in an ActivityFeed's place while its page reads the events: the rows the feed draws while it loads, with no words. */
30
+ export function ActivityFeedSkeleton() {
31
+ return (_jsx("div", { "aria-busy": "true", className: "flex min-w-0 flex-col gap-4", "data-slot": "activity-feed-skeleton", children: _jsx(LoadingCard, {}) }));
25
32
  }
26
33
  function OlderEvents({ command }) {
27
34
  const loading = command.pending === true;
@@ -41,9 +48,9 @@ function Days({ days, locale, timeZone, older, }) {
41
48
  * @family Compositions
42
49
  * @when A record's history: a Customer's, a Partner's or an Installation's Activity tab in the Portal, the company wiki's updates in Nadia. Each answers "what happened, and when?".
43
50
  * @instead The steps of one Agent run, read in order, are a RunTimeline; a list of records a person finds and acts on is a CollectionPage; a single "last changed" fact is a RecordTime.
44
- * @behaviour The search, filters and window sit right above the rows, kept in the URL by the product. Days stand newest first, each a title and a muted date over one card of rows; a row is the time of day, the actor's 24 px mark, the sentence with a status badge only for an exception, and one muted line of detail. "Show older events" follows the last day as a full-width `LoadMoreButton`, or as a `ButtonLink` when it navigates; there is never a page count. States, first that holds: failed, loading (still rows in the row's shape), no match with Clear filters, nothing yet in one line, the days. Nothing yet is one quiet line, never a picture; a failed read is the warning mark with Retry, never "no events". The time is the time of day in the viewer's own zone in tabular figures (`RecordTime`), with UTC and the viewer's zone in its hover card; one rule for every feed, never a time printed in UTC as the viewer's: a server-rendered page passes the viewer's `timeZone`, since without it the server and the first client render print UTC. The actor's mark is a person's initials, an Agent's real orb or an Installation's tile; the system's own work has no mark and never takes an orb. Under 900 px the time moves under the sentence. It draws no card header: the tab is the title.
51
+ * @behaviour The search, filters and window sit right above the rows, kept in the URL by the product. Days stand newest first, each a title and a muted date over one card of rows; a row is the time of day, the actor's 24 px mark, the sentence with a status badge only for an exception, and one muted line of detail. "Show older events" follows the last day as a full-width `LoadMoreButton`, or as a `ButtonLink` when it navigates; there is never a page count. States, first that holds: failed, loading (still rows in the row's shape, which `ActivityFeedSkeleton` also draws while a page reads the events before it can draw the feed; nadicode decision), no match with Clear filters, nothing yet in one line, the days. Nothing yet is one quiet line, never a picture; a failed read is the warning mark with Retry, never "no events". The time is the time of day in the viewer's own zone in tabular figures (`RecordTime`), with UTC and the viewer's zone in its hover card; one rule for every feed, never a time printed in UTC as the viewer's: a server-rendered page passes the viewer's `timeZone`, since without it the server and the first client render print UTC. The actor's mark is a person's initials, an Agent's real orb or an Installation's tile; the system's own work has no mark and never takes an orb. Under 900 px the time moves under the sentence. It draws no card header: the tab is the title.
45
52
  * @words The sentence names the actor in `<strong>`, the action in the past tense and the object as a link that keeps the text's colour: "Marco Rinaldi created the Agent Acme Quotes". Day titles are "Today", "Yesterday", then the weekday; dates are the product's own ("14 October"). Nothing yet: "No events yet." and what will appear. No match: "No events match these filters.".
46
- * @access The toolbar is named by `label`; each day's title is a level-3 heading over a list of its events; while loading, one status named by `loadingLabel` stands for the rows; each time is a `<time>` with its exact moment for assistive technology. A system event has no mark, so nothing empty is announced.
53
+ * @access The toolbar is named by `label`; each day's title is a level-3 heading over a list of its events; while loading, one status named by `loadingLabel` stands for the rows, and `ActivityFeedSkeleton`, a page's placeholder before it can draw the feed, is busy and carries no words; each time is a `<time>` with its exact moment for assistive technology. A system event has no mark, so nothing empty is announced.
47
54
  */
48
55
  export function ActivityFeed({ label, days, locale, timeZone, search, filters, range, older, loadingLabel, empty, noMatch, failed, }) {
49
56
  const nothingYet = !failed && days?.length === 0 && !noMatch;
@@ -0,0 +1,45 @@
1
+ import type { ReactNode } from "react";
2
+ import { type CollectionSearchProps } from "./collection-search.js";
3
+ import { type EmptyStateKind } from "./empty-state.js";
4
+ import { type PageActionsProps } from "./page-actions.js";
5
+ export type BoardHeaderProps = {
6
+ /** The board's name, its page's h1. */
7
+ title: string;
8
+ /** One muted line under the title, saying what the board's cards are. */
9
+ description?: ReactNode;
10
+ /** The title row: secondary, primary, then the three dots. */
11
+ actions?: Omit<PageActionsProps, "period">;
12
+ /** The host's own controls for the board, before the search: which board is shown, its filters. */
13
+ controls?: ReactNode;
14
+ /** Finds the board's cards. */
15
+ search: CollectionSearchProps;
16
+ /** The toolbar's name: the board's tools. */
17
+ label: string;
18
+ };
19
+ /**
20
+ * The top of a board whose lanes the host app draws under it: the board's title row with its
21
+ * actions, then its toolbar.
22
+ *
23
+ * @family Compositions
24
+ * @when Nadia's Assignments: Hermes draws the board's lanes and lets Nadia draw its header through its `board.header` area.
25
+ * @instead A list of records with a toolbar is a `CollectionPage`; a page the product frames itself is a `PageFrame` with its composition. The board with no cards is `BoardEmpty`. A page never draws `PageHeader` or `CollectionToolbar` itself, which `nadicodeai/page-composition` refuses.
26
+ * @behaviour The board's page has no frame of its own, so the header keeps `PageFrame`'s: 24 px in from the page's sides and top, in the `full` column (1280 px), which the host's lanes below it follow. The title row is `PageHeader`'s: the title, the `description` under it and `actions` on its row through `PageActions` (the outline secondary, the filled primary, then the three dots). Under it the board's toolbar, the plain row, since cards never pass under it: the host's `controls` first, then the search, which grows; below 640 px the search takes the first line and the controls the one under it, as `CollectionToolbar` lays them out. It never shrinks, so the lanes take the page's height under it.
27
+ * @words The product's: the title names the board ("Assignments"); the description says what its cards are; the search says what it finds ("Find an assignment"); `label` names the board's tools.
28
+ * @access The title is the page's h1. The toolbar is a `toolbar` named by `label`, and the search a `searchbox` named by its own label. DOM order is visual order.
29
+ */
30
+ export declare function BoardHeader({ title, description, actions, controls, search, label, }: BoardHeaderProps): import("react").JSX.Element;
31
+ /** The board's absence, as `EmptyState` takes it: a first use, or a search or filter that matched nothing. */
32
+ export type BoardEmptyProps = EmptyStateKind<"firstUse"> | EmptyStateKind<"noResults">;
33
+ /**
34
+ * A board with no cards, in the place of its lanes: its first use, or a search or filter that
35
+ * matched nothing.
36
+ *
37
+ * @family Compositions
38
+ * @when Nadia's Assignments when Hermes's board has no assignment to show, drawn through its `board.empty` area under `BoardHeader`.
39
+ * @instead The absence itself is `EmptyState`'s; this only places it where the lanes stand. A list's absence is its `CollectionPage`'s or `RecordList`'s `empty` and `noMatch`.
40
+ * @behaviour Takes the absence as `EmptyState` takes it, `firstUse` (its picture, title, line and the board's primary action) or `noResults` (with its clear), and draws it as a region on its resting card, in the board's `full` column, 24 px in from the page's sides and bottom, so it lines up with `BoardHeader` above it. It takes the page's height under the header and scrolls on its own when the page is shorter than it.
41
+ * @words As `EmptyState`'s: a first use's title names what is missing ("No assignments yet") and its action is the board's primary ("New assignment"); no match says what found nothing and offers "Clear filters".
42
+ * @access As `EmptyState`'s: a first use's title is a heading at level 2, under the board's h1.
43
+ */
44
+ export declare function BoardEmpty(props: BoardEmptyProps): import("react").JSX.Element;
45
+ //# sourceMappingURL=board.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"board.d.ts","sourceRoot":"","sources":["../../src/components/board.tsx"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,OAAO,CAAC;AAEvC,OAAO,EAAoB,KAAK,qBAAqB,EAAE,MAAM,gCAAgC,CAAC;AAE9F,OAAO,EAAc,KAAK,cAAc,EAAE,MAAM,0BAA0B,CAAC;AAC3E,OAAO,EAGL,KAAK,gBAAgB,EACtB,MAAM,2BAA2B,CAAC;AAInC,MAAM,MAAM,gBAAgB,GAAG;IAC7B,uCAAuC;IACvC,KAAK,EAAE,MAAM,CAAC;IACd,yEAAyE;IACzE,WAAW,CAAC,EAAE,SAAS,CAAC;IACxB,8DAA8D;IAC9D,OAAO,CAAC,EAAE,IAAI,CAAC,gBAAgB,EAAE,QAAQ,CAAC,CAAC;IAC3C,mGAAmG;IACnG,QAAQ,CAAC,EAAE,SAAS,CAAC;IACrB,+BAA+B;IAC/B,MAAM,EAAE,qBAAqB,CAAC;IAC9B,6CAA6C;IAC7C,KAAK,EAAE,MAAM,CAAC;CACf,CAAC;AAEF;;;;;;;;;;GAUG;AACH,wBAAgB,WAAW,CAAC,EAC1B,KAAK,EACL,WAAW,EACX,OAAO,EACP,QAAQ,EACR,MAAM,EACN,KAAK,GACN,EAAE,gBAAgB,+BAiBlB;AAED,8GAA8G;AAC9G,MAAM,MAAM,eAAe,GAAG,cAAc,CAAC,UAAU,CAAC,GAAG,cAAc,CAAC,WAAW,CAAC,CAAC;AAEvF;;;;;;;;;;GAUG;AACH,wBAAgB,UAAU,CAAC,KAAK,EAAE,eAAe,+BAWhD"}
@@ -0,0 +1,35 @@
1
+ import { jsx as _jsx, jsxs as _jsxs } from "react/jsx-runtime";
2
+ import { CollectionSearch } from "./collection-search.js";
3
+ import { CollectionToolbar } from "./collection-toolbar.js";
4
+ import { EmptyState } from "./empty-state.js";
5
+ import { PageActions, PageActionsHostProvider, } from "./page-actions.js";
6
+ import { PageHeader } from "./page-header.js";
7
+ import { ReadingColumn } from "./reading-column.js";
8
+ /**
9
+ * The top of a board whose lanes the host app draws under it: the board's title row with its
10
+ * actions, then its toolbar.
11
+ *
12
+ * @family Compositions
13
+ * @when Nadia's Assignments: Hermes draws the board's lanes and lets Nadia draw its header through its `board.header` area.
14
+ * @instead A list of records with a toolbar is a `CollectionPage`; a page the product frames itself is a `PageFrame` with its composition. The board with no cards is `BoardEmpty`. A page never draws `PageHeader` or `CollectionToolbar` itself, which `nadicodeai/page-composition` refuses.
15
+ * @behaviour The board's page has no frame of its own, so the header keeps `PageFrame`'s: 24 px in from the page's sides and top, in the `full` column (1280 px), which the host's lanes below it follow. The title row is `PageHeader`'s: the title, the `description` under it and `actions` on its row through `PageActions` (the outline secondary, the filled primary, then the three dots). Under it the board's toolbar, the plain row, since cards never pass under it: the host's `controls` first, then the search, which grows; below 640 px the search takes the first line and the controls the one under it, as `CollectionToolbar` lays them out. It never shrinks, so the lanes take the page's height under it.
16
+ * @words The product's: the title names the board ("Assignments"); the description says what its cards are; the search says what it finds ("Find an assignment"); `label` names the board's tools.
17
+ * @access The title is the page's h1. The toolbar is a `toolbar` named by `label`, and the search a `searchbox` named by its own label. DOM order is visual order.
18
+ */
19
+ export function BoardHeader({ title, description, actions, controls, search, label, }) {
20
+ return (_jsx("div", { className: "shrink-0 px-nadicode-lg pt-nadicode-lg", "data-slot": "board-header", children: _jsxs(ReadingColumn, { width: "full", children: [_jsxs(PageActionsHostProvider, { children: [_jsx(PageHeader, { description: description, title: title }), actions ? _jsx(PageActions, { ...actions }) : null] }), _jsx(CollectionToolbar, { controls: controls, label: label, search: _jsx(CollectionSearch, { ...search }), surface: "plain" })] }) }));
21
+ }
22
+ /**
23
+ * A board with no cards, in the place of its lanes: its first use, or a search or filter that
24
+ * matched nothing.
25
+ *
26
+ * @family Compositions
27
+ * @when Nadia's Assignments when Hermes's board has no assignment to show, drawn through its `board.empty` area under `BoardHeader`.
28
+ * @instead The absence itself is `EmptyState`'s; this only places it where the lanes stand. A list's absence is its `CollectionPage`'s or `RecordList`'s `empty` and `noMatch`.
29
+ * @behaviour Takes the absence as `EmptyState` takes it, `firstUse` (its picture, title, line and the board's primary action) or `noResults` (with its clear), and draws it as a region on its resting card, in the board's `full` column, 24 px in from the page's sides and bottom, so it lines up with `BoardHeader` above it. It takes the page's height under the header and scrolls on its own when the page is shorter than it.
30
+ * @words As `EmptyState`'s: a first use's title names what is missing ("No assignments yet") and its action is the board's primary ("New assignment"); no match says what found nothing and offers "Clear filters".
31
+ * @access As `EmptyState`'s: a first use's title is a heading at level 2, under the board's h1.
32
+ */
33
+ export function BoardEmpty(props) {
34
+ return (_jsx("div", { className: "min-h-0 flex-1 overflow-y-auto px-nadicode-lg pb-nadicode-lg", "data-slot": "board-empty", children: _jsx(ReadingColumn, { width: "full", children: _jsx(EmptyState, { ...props }) }) }));
35
+ }
@@ -1,9 +1,9 @@
1
1
  import * as React from "react";
2
2
  import { useRender } from "@base-ui/react/use-render";
3
+ import type { AccessibleName } from "./button.js";
3
4
  type BreadcrumbType = "text" | "menu";
4
- type BreadcrumbProps = Omit<React.ComponentProps<"nav">, "aria-label"> & {
5
- /** The path's name in the product's language, such as "Path". */
6
- "aria-label": string;
5
+ /** The path's name in the product's language, such as "Path", or the id of the element that says it. */
6
+ type BreadcrumbProps = Omit<React.ComponentProps<"nav">, "aria-label" | "aria-labelledby"> & AccessibleName & {
7
7
  /** `text` is the line with a chevron between steps; `menu` is a row of small chips. */
8
8
  type?: BreadcrumbType;
9
9
  };
@@ -1 +1 @@
1
- {"version":3,"file":"breadcrumb.d.ts","sourceRoot":"","sources":["../../src/components/breadcrumb.tsx"],"names":[],"mappings":"AAEA,OAAO,KAAK,KAAK,MAAM,OAAO,CAAC;AAE/B,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AAOtD,KAAK,cAAc,GAAG,MAAM,GAAG,MAAM,CAAC;AAItC,KAAK,eAAe,GAAG,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,KAAK,CAAC,EAAE,YAAY,CAAC,GAAG;IACvE,iEAAiE;IACjE,YAAY,EAAE,MAAM,CAAC;IACrB,uFAAuF;IACvF,IAAI,CAAC,EAAE,cAAc,CAAC;CACvB,CAAC;AAEF;;;;;;;;;;GAUG;AACH,iBAAS,UAAU,CAAC,EAAE,SAAS,EAAE,IAAa,EAAE,GAAG,KAAK,EAAE,EAAE,eAAe,qBAW1E;AAED,iBAAS,cAAc,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK,CAAC,cAAc,CAAC,IAAI,CAAC,qBAW1E;AAED,iBAAS,cAAc,CAAC,EAAE,SAAS,EAAE,GAAG,KAAK,EAAE,EAAE,KAAK,CAAC,cAAc,CAAC,IAAI,CAAC,qBAW1E;AA8BD,KAAK,mBAAmB,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,KAAK,EACT,EAAE,IAAI,CAAC,KAAK,CAAC,cAAc,CAAC,MAAM,CAAC,EAAE,UAAU,CAAC,GAAG;IAClD,uEAAuE;IACvE,KAAK,EAAE,MAAM,CAAC;CACf,qBAWA;AAED,YAAY,EAAE,eAAe,EAAE,CAAC;AAChC,OAAO,EACL,UAAU,EACV,cAAc,EACd,cAAc,EACd,cAAc,EACd,cAAc,EACd,mBAAmB,EACnB,kBAAkB,GACnB,CAAC"}
@@ -32,6 +32,10 @@ type IconLook = AccessibleName & {
32
32
  };
33
33
  type ButtonBase = Omit<ButtonPrimitive.Props, "aria-busy" | "prefix"> & {
34
34
  variant?: ButtonVariant | undefined;
35
+ /** The look of another Button that draws this one as its element (its `render`), handed on by Base UI. */
36
+ "data-variant"?: string | undefined;
37
+ /** The size of that other Button, handed on the same way. */
38
+ "data-size"?: string | undefined;
35
39
  };
36
40
  export type TextButtonProps = ButtonBase & TextLook;
37
41
  export type IconButtonProps = ButtonBase & IconLook;
@@ -79,6 +83,7 @@ export type IconButtonPartProps = Omit<IconButtonProps, "size" | "aria-label" |
79
83
  * "Combination of `shape="rounded"` and the `shadow` prop, often used on marketing pages." (https://vercel.com/geist/button)
80
84
  * Ours: `shape="rounded"` is a pill for a call to action that stands apart (a banner's or a
81
85
  * scroller's), with no `shadow` prop.
86
+ * Ours: a Button drawn as another Button's element, through that Button's `render` (a product's component that opens a dialog), takes that Button's look and size, never its own default.
82
87
  * Ours: text children sit in a label box that adds 6 px each side to the padding, except at `xs` and
83
88
  * the icon sizes, which have none; an element child (a `render` target, a row with a trailing `Kbd`)
84
89
  * lays itself out and gets no box. Colour sits on
@@ -109,7 +114,7 @@ export type IconButtonPartProps = Omit<IconButtonProps, "size" | "aria-label" |
109
114
  * `button`, `type="button"` unless it submits. `loading` sets `aria-busy`. Focus shows the base
110
115
  * outline in one colour for every look; nothing repaints it.
111
116
  */
112
- declare function Button({ children, className, disabled, focusableWhenDisabled, loading, loadingLabel, prefix, shape, size, suffix, variant, ...props }: ButtonProps): import("react").JSX.Element;
117
+ declare function Button({ children, className, disabled, focusableWhenDisabled, loading, loadingLabel, prefix, shape, size: ownSize, suffix, variant: ownVariant, "data-variant": passedVariant, "data-size": passedSize, ...props }: ButtonProps): import("react").JSX.Element;
113
118
  type ButtonLinkBase = Omit<useRender.ComponentProps<"a">, "aria-busy" | "aria-disabled" | "prefix"> & {
114
119
  variant?: ButtonVariant | undefined;
115
120
  disabled?: boolean | undefined;
@@ -1 +1 @@
1
- {"version":3,"file":"button.d.ts","sourceRoot":"","sources":["../../src/components/button.tsx"],"names":[],"mappings":"AAAA,OAAO,EAAE,MAAM,IAAI,eAAe,EAAE,MAAM,uBAAuB,CAAC;AAElE,OAAO,EAAE,SAAS,EAAE,MAAM,2BAA2B,CAAC;AACtD,OAAO,EAA4B,KAAK,SAAS,EAAE,MAAM,OAAO,CAAC;AAGjE,OAAO,EAGL,KAAK,aAAa,EAClB,KAAK,QAAQ,EACb,KAAK,QAAQ,EACd,MAAM,2BAA2B,CAAC;AAGnC,MAAM,MAAM,WAAW,GACnB;IAAE,OAAO,CAAC,EAAE,SAAS,CAAC;IAAC,YAAY,CAAC,EAAE,SAAS,CAAA;CAAE,GACjD;IAAE,OAAO,EAAE,OAAO,CAAC;IAAC,YAAY,EAAE,MAAM,CAAA;CAAE,CAAC;AAE/C,KAAK,QAAQ,GAAG,WAAW,GAAG;IAC5B,IAAI,CAAC,EAAE,QAAQ,GAAG,SAAS,CAAC;IAC5B,KAAK,CAAC,EAAE,QAAQ,GAAG,SAAS,GAAG,SAAS,CAAC;IACzC,MAAM,CAAC,EAAE,SAAS,CAAC;IACnB,MAAM,CAAC,EAAE,SAAS,CAAC;CACpB,CAAC;AAEF,MAAM,MAAM,cAAc,GACtB;IAAE,YAAY,EAAE,MAAM,CAAC;IAAC,iBAAiB,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;CAAE,GAChE;IAAE,iBAAiB,EAAE,MAAM,CAAC;IAAC,YAAY,CAAC,E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AE,eAAe,CAAC,MAAM,CAAC,GAAG,SAAS,CAAC;IAC3C,YAAY,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;IAClC,iBAAiB,CAAC,EAAE,MAAM,GAAG,SAAS,CAAC;CACxC,CAAC;AAiFF;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GAmEG;AACH,iBAAS,MAAM,CAAC,EACd,QAAQ,EACR,SAAS,EACT,QAAQ,EACR,qBAAqB,EACrB,OAAO,EACP,YAAY,EACZ,MAAM,EACN,KAAgB,EAChB,IAAI,EAAE,OAAO,EACb,MAAM,EACN,OAAO,EAAE,UAAU,EACnB,cAAc,EAAE,aAAa,EAC7B,WAAW,EAAE,UAAU,EACvB,GAAG,KAAK,EACT,EAAE,WAAW,+BA2Bb;AAED,KAAK,cAAc,GAAG,IAAI,CACxB,SAAS,CAAC,cAAc,CAAC,GAAG,CAAC,EAC7B,WAAW,GAAG,eAAe,GAAG,QAAQ,CACzC,GAAG;IACF,OAAO,CAAC,EAAE,aAAa,GAAG,SAAS,CAAC;IACpC,QAAQ,CAAC,EAAE,OAAO,GAAG,SAAS,CAAC;CAChC,CAAC;AAEF,MAAM,MAAM,eAAe,GAAG,cAAc,GAAG,CAAC,QAAQ,GAAG,QAAQ,CAAC,CAAC;AAMrE;;;;;;;;;;;;;;;GAeG;AACH,iBAAS,UAAU,CAAC,EAClB,QAAQ,EACR,SAAS,EACT,QAAQ,EACR,OAAO,EACP,YAAY,EACZ,OAAO,EACP,MAAM,EACN,MAAM,EACN,KAAgB,EAChB,IAAgB,EAChB,MAAM,EACN,OAAmB,EACnB,GAAG,KAAK,EACT,EAAE,eAAe,8FA4BjB;AAED,OAAO,EAAE,MAAM,EAAE,UAAU,EAAE,CAAC"}
@@ -4,7 +4,7 @@ import { mergeProps } from "@base-ui/react/merge-props";
4
4
  import { useRender } from "@base-ui/react/use-render";
5
5
  import { Children, isValidElement } from "react";
6
6
  import { PendingLabel } from "./pending-label.js";
7
- import { buttonVariants, } from "../internal/button-classes.js";
7
+ import { buttonVariants, isButtonSize, isButtonVariant, } from "../internal/button-classes.js";
8
8
  import { cn } from "../lib/utils.js";
9
9
  function isIconSize(size) {
10
10
  return size.startsWith("icon");
@@ -61,6 +61,7 @@ function ButtonContent({ children, loading, loadingLabel, prefix, size, suffix,
61
61
  * "Combination of `shape="rounded"` and the `shadow` prop, often used on marketing pages." (https://vercel.com/geist/button)
62
62
  * Ours: `shape="rounded"` is a pill for a call to action that stands apart (a banner's or a
63
63
  * scroller's), with no `shadow` prop.
64
+ * Ours: a Button drawn as another Button's element, through that Button's `render` (a product's component that opens a dialog), takes that Button's look and size, never its own default.
64
65
  * Ours: text children sit in a label box that adds 6 px each side to the padding, except at `xs` and
65
66
  * the icon sizes, which have none; an element child (a `render` target, a row with a trailing `Kbd`)
66
67
  * lays itself out and gets no box. Colour sits on
@@ -91,7 +92,9 @@ function ButtonContent({ children, loading, loadingLabel, prefix, size, suffix,
91
92
  * `button`, `type="button"` unless it submits. `loading` sets `aria-busy`. Focus shows the base
92
93
  * outline in one colour for every look; nothing repaints it.
93
94
  */
94
- function Button({ children, className, disabled, focusableWhenDisabled, loading, loadingLabel, prefix, shape = "square", size = "default", suffix, variant = "default", ...props }) {
95
+ function Button({ children, className, disabled, focusableWhenDisabled, loading, loadingLabel, prefix, shape = "square", size: ownSize, suffix, variant: ownVariant, "data-variant": passedVariant, "data-size": passedSize, ...props }) {
96
+ const variant = ownVariant ?? (isButtonVariant(passedVariant) ? passedVariant : "default");
97
+ const size = ownSize ?? (isButtonSize(passedSize) ? passedSize : "default");
95
98
  const busy = loading === true;
96
99
  return (_jsx(ButtonPrimitive, { "data-slot": "button", "data-nc-ui": "", "data-size": size, "data-variant": variant, "aria-busy": busy || undefined, className: buttonVariants({ variant, size, shape, className }), disabled: disabled === true || busy, focusableWhenDisabled: focusableWhenDisabled === true || busy, ...props, children: _jsx(ButtonContent, { loading: loading, loadingLabel: loadingLabel, prefix: prefix, size: size, suffix: suffix, children: children }) }));
97
100
  }
@@ -72,7 +72,7 @@ function CardRow({ className, columns = 2, from = "md", render, ...props }) {
72
72
  return useRender({
73
73
  defaultTagName: "div",
74
74
  props: mergeProps({
75
- className: cn("grid grid-cols-1 items-stretch gap-4 *:data-[slot=card]:h-full [&>li]:flex [&>li>[data-slot=card]]:size-full ", columnClasses[from][columns], className),
75
+ className: cn("grid grid-cols-1 items-stretch gap-4 *:data-[slot=card]:h-full [&>li]:flex [&>li>*]:size-full", columnClasses[from][columns], className),
76
76
  }, props),
77
77
  render,
78
78
  state: { columns: String(columns), from, slot: "card-row" },
@@ -56,6 +56,8 @@ type ChartCardProps = {
56
56
  link?: ChartCardLink;
57
57
  /** A `ChartSummary` between the header and the plot. */
58
58
  summary?: React.ReactNode;
59
+ /** `beside` stands the summary at the plot's leading edge from `sm` up, as a period's total beside its activity calendar. */
60
+ summaryPlacement?: "above" | "beside";
59
61
  /** A ranking beside the plot on wide cards, never a second card. */
60
62
  aside?: React.ReactNode;
61
63
  footer?: ChartCardFooter;
@@ -73,6 +75,8 @@ type ChartCardProps = {
73
75
  otherLabel: string;
74
76
  /** Rendered in CardContent instead of the plot when `data` is empty. */
75
77
  emptyState?: React.ReactNode;
78
+ /** The card's own density, as `Card`'s `size`: `sm` for a reading that stands beside fuller cards. */
79
+ cardSize?: "default" | "sm";
76
80
  size?: ChartCardSize;
77
81
  className?: string;
78
82
  };
@@ -99,13 +103,22 @@ declare function foldOtherSeries(series: readonly ChartSeries[], data: readonly
99
103
  * @family Charts
100
104
  * @when Every chart and every reading built around one: the frame a page never builds by hand. A chart is a named section of its page.
101
105
  * @instead A single figure is a `KpiCard`, never nested inside a chart. A ranking beside the plot goes in the card's `aside`, not a second card.
102
- * @behaviour The default header puts controls at the trailing edge on wide cards, below the title on narrow cards. The way to the reading's owner is a › icon link after the controls, as Vercel's Observability preview cards open their page. The summary variant keeps controls immediately after the title, the owner link at the trailing edge, and the total and period above the plot. The ranking sits beside the plot only when the card itself reaches 48 rem; narrower cards keep a full-width plot and put the ranking below it. Controls wrap on narrow cards. An empty dataset shows its `emptyState` in the plot's place. The footer carries the reading time and at most one command on that reading.
106
+ * @behaviour `summaryPlacement="beside"` stands the summary at the plot's leading edge from `sm` up and above it on a phone, as Usage's Activity card puts the period's total beside its calendar (nadicode decision). The plot may be given as a node, for a plot that names itself, such as an `ActivityCalendar`, or a page rendered on the server. `cardSize="sm"` draws the compact card, as `Card`'s `size`, for a reading that stands beside fuller cards (nadicode decision). The default header puts controls at the trailing edge on wide cards, below the title on narrow cards. The way to the reading's owner is a › icon link after the controls, as Vercel's Observability preview cards open their page. The summary variant keeps controls immediately after the title, the owner link at the trailing edge, and the total and period above the plot. The ranking sits beside the plot only when the card itself reaches 48 rem; narrower cards keep a full-width plot and put the ranking below it. Controls wrap on narrow cards. An empty dataset shows its `emptyState` in the plot's place. The footer carries the reading time and at most one command on that reading. While its page reads the series, `ChartCardSkeleton` stands in its place: the same card, a bar for the title, the summary's figure when the card has one (`summary`), and the plot's area at its `size`'s height, with no words (nadicode decision).
103
107
  * @words Title names the measure and its split: "Model spend by Customer". Period as dates. The link's name says where it goes: "Explore Usage by model", "Open revenue in Analytics". Footer: the reading's time, "Updated 4 minutes ago" or "Read at 12:42". Sentence case throughout.
104
- * @access The title is a heading at the page's level (default 2) and labels the plot. The owner link is a native link named by its `label`. The plot is focusable and shows the 2 px focus outline only on keyboard focus.
108
+ * @access The title is a heading at the page's level (default 2) and labels the plot. The owner link is a native link named by its `label`. The plot is focusable and shows the 2 px focus outline only on keyboard focus. `ChartCardSkeleton` is busy and its bars are hidden from assistive technology.
105
109
  */
106
- declare function ChartCard({ variant, title, period, controls, link, summary, aside, footer, headingLevel, className, children, }: Pick<ChartCardProps, "title" | "variant" | "period" | "controls" | "link" | "summary" | "aside" | "footer" | "headingLevel" | "className"> & {
107
- /** Receives the title's id, which the plot takes as `aria-labelledby`. */
108
- children: (titleId: string) => React.ReactNode;
110
+ declare function ChartCard({ variant, title, period, controls, link, summary, summaryPlacement, aside, footer, headingLevel, className, cardSize, children, }: Pick<ChartCardProps, "title" | "variant" | "period" | "controls" | "link" | "summary" | "summaryPlacement" | "aside" | "footer" | "headingLevel" | "className" | "cardSize"> & {
111
+ /** The plot, or a function that receives the title's id, which the plot takes as `aria-labelledby`. */
112
+ children: React.ReactNode | ((titleId: string) => React.ReactNode);
113
+ }): React.JSX.Element;
114
+ /**
115
+ * What stands in a ChartCard's place while its page reads the series: the card, a bar for the
116
+ * title, the summary's figure when the card has one, and the plot's area at its height.
117
+ */
118
+ declare function ChartCardSkeleton({ summary, size, }: {
119
+ /** The card leads with a summary figure above its plot. */
120
+ summary?: boolean;
121
+ size?: ChartCardSize;
109
122
  }): React.JSX.Element;
110
123
  declare function ChartSummary({ variant, label, value, valueTitle, valueSize, trend, status, }: ChartSummaryProps): React.JSX.Element;
111
124
  /** The plot frame class: fixed height, no aspect ratio, full width. */
@@ -118,6 +131,6 @@ declare function chartPlotClassName(size: ChartCardSize): string;
118
131
  declare const CHART_FOCUS_CLASS = "[&_.recharts-surface:focus-visible]:nc-focus-outline [&_.recharts-surface:focus-visible]:outline-ring";
119
132
  /** Legend below the plot, left-aligned, wrapping to a second line. */
120
133
  declare const CHART_LEGEND_CLASS = "flex-wrap justify-start";
121
- export { CHART_FOCUS_CLASS, CHART_LEGEND_CLASS, ChartCard, ChartSummary, chartPlotClassName, chartSeriesConfig, defaultValueFormatter, foldOtherSeries, };
134
+ export { CHART_FOCUS_CLASS, CHART_LEGEND_CLASS, ChartCard, ChartCardSkeleton, ChartSummary, chartPlotClassName, chartSeriesConfig, defaultValueFormatter, foldOtherSeries, };
122
135
  export type { ChartCardFooter, ChartCardLink, ChartCardProps, ChartCardSize, ChartDatum, ChartSeries, ChartSummaryProps, ChartSummaryTrend, };
123
136
  //# sourceMappingURL=chart-card.d.ts.map
@@ -1 +1 @@
1
- {"version":3,"file":"chart-card.d.ts","sourceRoot":"","sources":["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,EACpB,QAAQ,GACT,EAAE,IAAI,CACL,cAAc,EACZ,OAAO,GACP,SAAS,GACT,QAAQ,GACR,UAAU,GACV,MAAM,GACN,SAAS,GACT,kBAAkB,GAClB,OAAO,GACP,QAAQ,GACR,cAAc,GACd,WAAW,GACX,UAAU,CACb,GAAG;IACF,uGAAuG;IACvG,QAAQ,EAAE,KAAK,CAAC,SAAS,GAAG,CAAC,CAAC,OAAO,EAAE,MAAM,KAAK,KAAK,CAAC,SAAS,CAAC,CAAC;CACpE,qBAwFA;AAED;;;GAGG;AACH,iBAAS,iBAAiB,CAAC,EACzB,OAAe,EACf,IAAgB,GACjB,EAAE;IACD,2DAA2D;IAC3D,OAAO,CAAC,EAAE,OAAO,CAAC;IAClB,IAAI,CAAC,EAAE,aAAa,CAAC;CACtB,qBAoBA;AAED,iBAAS,YAAY,CAAC,EACpB,OAAmB,EACnB,KAAK,EACL,KAAK,EACL,UAAU,EACV,SAAqB,EACrB,KAAK,EACL,MAAM,GACP,EAAE,iBAAiB,qBAiDnB;AAED,uEAAuE;AACvE,iBAAS,kBAAkB,CAAC,IAAI,EAAE,aAAa,GAAG,MAAM,CAEvD;AAED;;;;GAIG;AACH,QAAA,MAAM,iBAAiB,0GACkF,CAAC;AAE1G,sEAAsE;AACtE,QAAA,MAAM,kBAAkB,4BAA4B,CAAC;AAErD,OAAO,EACL,iBAAiB,EACjB,kBAAkB,EAClB,SAAS,EACT,iBAAiB,EACjB,YAAY,EACZ,kBAAkB,EAClB,iBAAiB,EACjB,qBAAqB,EACrB,eAAe,GAChB,CAAC;AACF,YAAY,EACV,eAAe,EACf,aAAa,EACb,cAAc,EACd,aAAa,EACb,UAAU,EACV,WAAW,EACX,iBAAiB,EACjB,iBAAiB,GAClB,CAAC"}
@@ -7,6 +7,7 @@ import { ButtonLink } from "./button.js";
7
7
  import { Card, CardAction, CardContent, CardDescription, CardHeader, CardTitle, } from "./card.js";
8
8
  import { CHART_ENTITY_OTHER_COLOR, entityColor, } from "./chart-entity-colors.js";
9
9
  import { PageCommandButton } from "./page-actions.js";
10
+ import { Skeleton, SkeletonRegion } from "./skeleton.js";
10
11
  import { TrendBadge } from "./trend-badge.js";
11
12
  import { FooterStrip } from "../internal/footer-strip.js";
12
13
  const chartSizes = {
@@ -62,16 +63,25 @@ function foldOtherSeries(series, data, entityColorMap, otherLabel) {
62
63
  * @family Charts
63
64
  * @when Every chart and every reading built around one: the frame a page never builds by hand. A chart is a named section of its page.
64
65
  * @instead A single figure is a `KpiCard`, never nested inside a chart. A ranking beside the plot goes in the card's `aside`, not a second card.
65
- * @behaviour The default header puts controls at the trailing edge on wide cards, below the title on narrow cards. The way to the reading's owner is a › icon link after the controls, as Vercel's Observability preview cards open their page. The summary variant keeps controls immediately after the title, the owner link at the trailing edge, and the total and period above the plot. The ranking sits beside the plot only when the card itself reaches 48 rem; narrower cards keep a full-width plot and put the ranking below it. Controls wrap on narrow cards. An empty dataset shows its `emptyState` in the plot's place. The footer carries the reading time and at most one command on that reading.
66
+ * @behaviour `summaryPlacement="beside"` stands the summary at the plot's leading edge from `sm` up and above it on a phone, as Usage's Activity card puts the period's total beside its calendar (nadicode decision). The plot may be given as a node, for a plot that names itself, such as an `ActivityCalendar`, or a page rendered on the server. `cardSize="sm"` draws the compact card, as `Card`'s `size`, for a reading that stands beside fuller cards (nadicode decision). The default header puts controls at the trailing edge on wide cards, below the title on narrow cards. The way to the reading's owner is a › icon link after the controls, as Vercel's Observability preview cards open their page. The summary variant keeps controls immediately after the title, the owner link at the trailing edge, and the total and period above the plot. The ranking sits beside the plot only when the card itself reaches 48 rem; narrower cards keep a full-width plot and put the ranking below it. Controls wrap on narrow cards. An empty dataset shows its `emptyState` in the plot's place. The footer carries the reading time and at most one command on that reading. While its page reads the series, `ChartCardSkeleton` stands in its place: the same card, a bar for the title, the summary's figure when the card has one (`summary`), and the plot's area at its `size`'s height, with no words (nadicode decision).
66
67
  * @words Title names the measure and its split: "Model spend by Customer". Period as dates. The link's name says where it goes: "Explore Usage by model", "Open revenue in Analytics". Footer: the reading's time, "Updated 4 minutes ago" or "Read at 12:42". Sentence case throughout.
67
- * @access The title is a heading at the page's level (default 2) and labels the plot. The owner link is a native link named by its `label`. The plot is focusable and shows the 2 px focus outline only on keyboard focus.
68
+ * @access The title is a heading at the page's level (default 2) and labels the plot. The owner link is a native link named by its `label`. The plot is focusable and shows the 2 px focus outline only on keyboard focus. `ChartCardSkeleton` is busy and its bars are hidden from assistive technology.
68
69
  */
69
- function ChartCard({ variant = "default", title, period, controls, link, summary, aside, footer, headingLevel = 2, className, children, }) {
70
+ function ChartCard({ variant = "default", title, period, controls, link, summary, summaryPlacement = "above", aside, footer, headingLevel = 2, className, cardSize = "default", children, }) {
70
71
  const titleId = React.useId();
71
- return (_jsxs(Card, { "data-slot": "chart-card", className: cn("@container/chart-card", className), children: [_jsxs(CardHeader, { narrowAction: variant === "summary" || controls ? "own" : undefined, className: cn(variant === "summary"
72
+ const beside = summary && variant !== "summary" && summaryPlacement === "beside";
73
+ const plot = typeof children === "function" ? children(titleId) : children;
74
+ return (_jsxs(Card, { "data-slot": "chart-card", className: cn("@container/chart-card", className), size: cardSize, children: [_jsxs(CardHeader, { narrowAction: variant === "summary" || controls ? "own" : undefined, className: cn(variant === "summary"
72
75
  ? "flex flex-wrap items-center gap-3"
73
- : controls && CONTROLS_UNDER_TITLE_WHEN_NARROW), children: [_jsx(CardTitle, { id: titleId, role: "heading", "aria-level": headingLevel, className: variant === "summary" ? "text-heading-xs" : undefined, children: title }), variant === "summary" ? controls : null, period && variant !== "summary" ? _jsx(CardDescription, { children: period }) : null, (variant === "summary" ? link : controls || link) ? (_jsxs(CardAction, { className: cn("flex flex-wrap items-center gap-2", variant === "summary" && "ml-auto"), children: [variant === "summary" ? null : controls, link ? (_jsx(ButtonLink, { variant: "ghost", size: "icon-sm", "aria-label": link.label, render: link.link, children: _jsx(ChevronRight, { "aria-hidden": "true" }) })) : null] })) : null] }), summary && variant !== "summary" ? (_jsx("div", { "data-slot": "chart-card-summary", className: "px-(--card-spacing)", children: summary })) : null, _jsxs(CardContent, { className: cn(aside &&
74
- "grid min-w-0 gap-(--card-spacing) @3xl/chart-card:grid-cols-[minmax(0,2fr)_minmax(16rem,1fr)]"), children: [_jsxs("div", { className: "flex min-w-0 flex-col gap-4", children: [variant === "summary" && (summary || period) ? (_jsxs("div", { "data-slot": "chart-card-summary", className: "flex flex-wrap items-start justify-between gap-3", children: [summary, period ? _jsx(CardDescription, { children: period }) : null] })) : null, children(titleId)] }), aside ? (_jsx("aside", { "data-slot": "chart-card-aside", className: "min-w-0 border-t border-border pt-(--card-spacing) @3xl/chart-card:border-t-0 @3xl/chart-card:border-l @3xl/chart-card:pt-0 @3xl/chart-card:pl-(--card-spacing)", children: aside })) : null] }), footer ? (_jsx(FooterStrip, { hint: footer.reading, hintSlot: "chart-card-reading", children: footer.link ? _jsx(PageCommandButton, { command: footer.link, variant: "outline" }) : null })) : null] }));
76
+ : controls && CONTROLS_UNDER_TITLE_WHEN_NARROW), children: [_jsx(CardTitle, { id: titleId, role: "heading", "aria-level": headingLevel, className: variant === "summary" ? "text-heading-xs" : undefined, children: title }), variant === "summary" ? controls : null, period && variant !== "summary" ? _jsx(CardDescription, { children: period }) : null, (variant === "summary" ? link : controls || link) ? (_jsxs(CardAction, { className: cn("flex flex-wrap items-center gap-2", variant === "summary" && "ml-auto"), children: [variant === "summary" ? null : controls, link ? (_jsx(ButtonLink, { variant: "ghost", size: "icon-sm", "aria-label": link.label, render: link.link, children: _jsx(ChevronRight, { "aria-hidden": "true" }) })) : null] })) : null] }), summary && variant !== "summary" && !beside ? (_jsx("div", { "data-slot": "chart-card-summary", className: "px-(--card-spacing)", children: summary })) : null, _jsxs(CardContent, { className: cn(aside &&
77
+ "grid min-w-0 gap-(--card-spacing) @3xl/chart-card:grid-cols-[minmax(0,2fr)_minmax(16rem,1fr)]"), children: [_jsxs("div", { className: "flex min-w-0 flex-col gap-4", children: [variant === "summary" && (summary || period) ? (_jsxs("div", { "data-slot": "chart-card-summary", className: "flex flex-wrap items-start justify-between gap-3", children: [summary, period ? _jsx(CardDescription, { children: period }) : null] })) : null, beside ? (_jsxs("div", { className: "flex max-w-full flex-col gap-6 sm:flex-row sm:items-start", children: [_jsx("div", { "data-slot": "chart-card-summary", className: "min-w-40 shrink-0", children: summary }), plot] })) : (plot)] }), aside ? (_jsx("aside", { "data-slot": "chart-card-aside", className: "min-w-0 border-t border-border pt-(--card-spacing) @3xl/chart-card:border-t-0 @3xl/chart-card:border-l @3xl/chart-card:pt-0 @3xl/chart-card:pl-(--card-spacing)", children: aside })) : null] }), footer ? (_jsx(FooterStrip, { hint: footer.reading, hintSlot: "chart-card-reading", children: footer.link ? _jsx(PageCommandButton, { command: footer.link, variant: "outline" }) : null })) : null] }));
78
+ }
79
+ /**
80
+ * What stands in a ChartCard's place while its page reads the series: the card, a bar for the
81
+ * title, the summary's figure when the card has one, and the plot's area at its height.
82
+ */
83
+ function ChartCardSkeleton({ summary = false, size = "default", }) {
84
+ return (_jsx(SkeletonRegion, { busy: true, "data-slot": "chart-card-skeleton", children: _jsxs(Card, { children: [_jsx(CardHeader, { children: _jsx(CardTitle, { children: _jsx(Skeleton, { boxHeight: 26, className: "max-w-full", height: 20, width: 160 }) }) }), summary ? (_jsx("div", { className: "px-(--card-spacing)", children: _jsx(Skeleton, { className: "max-w-full", height: 64, width: 192 }) })) : null, _jsx(CardContent, { children: _jsx(Skeleton, { className: cn("w-full", chartSizes[size]) }) })] }) }));
75
85
  }
76
86
  function ChartSummary({ variant = "default", label, value, valueTitle, valueSize = "default", trend, status, }) {
77
87
  return (_jsxs("div", { "data-slot": "chart-summary", className: "flex flex-col items-start gap-2", children: [_jsx("div", { className: cn(variant === "summary" ? "sr-only" : "text-muted-foreground text-sm"), children: label }), _jsxs("div", { className: "flex min-w-0 flex-wrap items-center gap-3", children: [_jsx("div", { "data-slot": "chart-summary-value", className: cn("truncate tabular-nums", variant === "summary"
@@ -92,4 +102,4 @@ function chartPlotClassName(size) {
92
102
  const CHART_FOCUS_CLASS = "[&_.recharts-surface:focus-visible]:nc-focus-outline [&_.recharts-surface:focus-visible]:outline-ring";
93
103
  /** Legend below the plot, left-aligned, wrapping to a second line. */
94
104
  const CHART_LEGEND_CLASS = "flex-wrap justify-start";
95
- export { CHART_FOCUS_CLASS, CHART_LEGEND_CLASS, ChartCard, ChartSummary, chartPlotClassName, chartSeriesConfig, defaultValueFormatter, foldOtherSeries, };
105
+ export { CHART_FOCUS_CLASS, CHART_LEGEND_CLASS, ChartCard, ChartCardSkeleton, ChartSummary, chartPlotClassName, chartSeriesConfig, defaultValueFormatter, foldOtherSeries, };