@boost33/ui 0.8.1 → 0.9.0

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 (123) hide show
  1. package/CHANGELOG.md +131 -3
  2. package/dist/backdrop-icons.d.ts +53 -0
  3. package/dist/backdrop-icons.js +62 -0
  4. package/dist/backdrop-icons.js.map +1 -0
  5. package/dist/backdrop.css +1 -0
  6. package/dist/backdrop.d.ts +46 -0
  7. package/dist/backdrop.js +127 -0
  8. package/dist/backdrop.js.map +1 -0
  9. package/dist/components/Backdrop/BackdropAppMenu.d.ts +55 -0
  10. package/dist/components/Backdrop/BackdropAppMenu.js +79 -0
  11. package/dist/components/Backdrop/BackdropAppMenu.js.map +1 -0
  12. package/dist/components/Backdrop/BackdropAppMenu.module.css.js +48 -0
  13. package/dist/components/Backdrop/BackdropAppMenu.module.css.js.map +1 -0
  14. package/dist/components/Backdrop/BackdropBasics.d.ts +129 -0
  15. package/dist/components/Backdrop/BackdropBasics.js +130 -0
  16. package/dist/components/Backdrop/BackdropBasics.js.map +1 -0
  17. package/dist/components/Backdrop/BackdropBasics.module.css.js +71 -0
  18. package/dist/components/Backdrop/BackdropBasics.module.css.js.map +1 -0
  19. package/dist/components/Backdrop/BackdropButton.d.ts +63 -0
  20. package/dist/components/Backdrop/BackdropButton.js +59 -0
  21. package/dist/components/Backdrop/BackdropButton.js.map +1 -0
  22. package/dist/components/Backdrop/BackdropButton.module.css.js +41 -0
  23. package/dist/components/Backdrop/BackdropButton.module.css.js.map +1 -0
  24. package/dist/components/Backdrop/BackdropCharts.d.ts +158 -0
  25. package/dist/components/Backdrop/BackdropCharts.js +222 -0
  26. package/dist/components/Backdrop/BackdropCharts.js.map +1 -0
  27. package/dist/components/Backdrop/BackdropCharts.module.css.js +109 -0
  28. package/dist/components/Backdrop/BackdropCharts.module.css.js.map +1 -0
  29. package/dist/components/Backdrop/BackdropChrome.d.ts +26 -0
  30. package/dist/components/Backdrop/BackdropChrome.js +35 -0
  31. package/dist/components/Backdrop/BackdropChrome.js.map +1 -0
  32. package/dist/components/Backdrop/BackdropConversation.d.ts +67 -0
  33. package/dist/components/Backdrop/BackdropConversation.js +76 -0
  34. package/dist/components/Backdrop/BackdropConversation.js.map +1 -0
  35. package/dist/components/Backdrop/BackdropConversation.module.css.js +44 -0
  36. package/dist/components/Backdrop/BackdropConversation.module.css.js.map +1 -0
  37. package/dist/components/Backdrop/BackdropData.d.ts +195 -0
  38. package/dist/components/Backdrop/BackdropData.js +204 -0
  39. package/dist/components/Backdrop/BackdropData.js.map +1 -0
  40. package/dist/components/Backdrop/BackdropData.module.css.js +135 -0
  41. package/dist/components/Backdrop/BackdropData.module.css.js.map +1 -0
  42. package/dist/components/Backdrop/BackdropDisplay.d.ts +122 -0
  43. package/dist/components/Backdrop/BackdropDisplay.js +80 -0
  44. package/dist/components/Backdrop/BackdropDisplay.js.map +1 -0
  45. package/dist/components/Backdrop/BackdropDisplay.module.css.js +80 -0
  46. package/dist/components/Backdrop/BackdropDisplay.module.css.js.map +1 -0
  47. package/dist/components/Backdrop/BackdropFields.d.ts +122 -0
  48. package/dist/components/Backdrop/BackdropFields.js +196 -0
  49. package/dist/components/Backdrop/BackdropFields.js.map +1 -0
  50. package/dist/components/Backdrop/BackdropFields.module.css.js +104 -0
  51. package/dist/components/Backdrop/BackdropFields.module.css.js.map +1 -0
  52. package/dist/components/Backdrop/BackdropFlows.d.ts +128 -0
  53. package/dist/components/Backdrop/BackdropFlows.js +156 -0
  54. package/dist/components/Backdrop/BackdropFlows.js.map +1 -0
  55. package/dist/components/Backdrop/BackdropFlows.module.css.js +80 -0
  56. package/dist/components/Backdrop/BackdropFlows.module.css.js.map +1 -0
  57. package/dist/components/Backdrop/BackdropFrame.d.ts +36 -0
  58. package/dist/components/Backdrop/BackdropFrame.js +15 -0
  59. package/dist/components/Backdrop/BackdropFrame.js.map +1 -0
  60. package/dist/components/Backdrop/BackdropFrame.module.css.js +14 -0
  61. package/dist/components/Backdrop/BackdropFrame.module.css.js.map +1 -0
  62. package/dist/components/Backdrop/BackdropGlobalPanels.d.ts +272 -0
  63. package/dist/components/Backdrop/BackdropGlobalPanels.js +264 -0
  64. package/dist/components/Backdrop/BackdropGlobalPanels.js.map +1 -0
  65. package/dist/components/Backdrop/BackdropGlobalPanels.module.css.js +201 -0
  66. package/dist/components/Backdrop/BackdropGlobalPanels.module.css.js.map +1 -0
  67. package/dist/components/Backdrop/BackdropHub.d.ts +80 -0
  68. package/dist/components/Backdrop/BackdropHub.js +92 -0
  69. package/dist/components/Backdrop/BackdropHub.js.map +1 -0
  70. package/dist/components/Backdrop/BackdropHub.module.css.js +40 -0
  71. package/dist/components/Backdrop/BackdropHub.module.css.js.map +1 -0
  72. package/dist/components/Backdrop/BackdropLists.d.ts +165 -0
  73. package/dist/components/Backdrop/BackdropLists.js +162 -0
  74. package/dist/components/Backdrop/BackdropLists.js.map +1 -0
  75. package/dist/components/Backdrop/BackdropLists.module.css.js +114 -0
  76. package/dist/components/Backdrop/BackdropLists.module.css.js.map +1 -0
  77. package/dist/components/Backdrop/BackdropOverlays.d.ts +175 -0
  78. package/dist/components/Backdrop/BackdropOverlays.js +252 -0
  79. package/dist/components/Backdrop/BackdropOverlays.js.map +1 -0
  80. package/dist/components/Backdrop/BackdropOverlays.module.css.js +104 -0
  81. package/dist/components/Backdrop/BackdropOverlays.module.css.js.map +1 -0
  82. package/dist/components/Backdrop/BackdropPage.d.ts +73 -0
  83. package/dist/components/Backdrop/BackdropPage.js +65 -0
  84. package/dist/components/Backdrop/BackdropPage.js.map +1 -0
  85. package/dist/components/Backdrop/BackdropPage.module.css.js +46 -0
  86. package/dist/components/Backdrop/BackdropPage.module.css.js.map +1 -0
  87. package/dist/components/Backdrop/BackdropPatterns.d.ts +224 -0
  88. package/dist/components/Backdrop/BackdropPatterns.js +202 -0
  89. package/dist/components/Backdrop/BackdropPatterns.js.map +1 -0
  90. package/dist/components/Backdrop/BackdropPatterns.module.css.js +114 -0
  91. package/dist/components/Backdrop/BackdropPatterns.module.css.js.map +1 -0
  92. package/dist/components/Backdrop/BackdropRail.d.ts +63 -0
  93. package/dist/components/Backdrop/BackdropRail.js +98 -0
  94. package/dist/components/Backdrop/BackdropRail.js.map +1 -0
  95. package/dist/components/Backdrop/BackdropRail.module.css.js +42 -0
  96. package/dist/components/Backdrop/BackdropRail.module.css.js.map +1 -0
  97. package/dist/components/Backdrop/BackdropSheets.d.ts +68 -0
  98. package/dist/components/Backdrop/BackdropSheets.js +75 -0
  99. package/dist/components/Backdrop/BackdropSheets.js.map +1 -0
  100. package/dist/components/Backdrop/BackdropSheets.module.css.js +42 -0
  101. package/dist/components/Backdrop/BackdropSheets.module.css.js.map +1 -0
  102. package/dist/components/Backdrop/BackdropTabs.d.ts +20 -0
  103. package/dist/components/Backdrop/BackdropTabs.js +31 -0
  104. package/dist/components/Backdrop/BackdropTabs.js.map +1 -0
  105. package/dist/components/Backdrop/BackdropTabs.module.css.js +16 -0
  106. package/dist/components/Backdrop/BackdropTabs.module.css.js.map +1 -0
  107. package/dist/components/Backdrop/BackdropTooltip.d.ts +21 -0
  108. package/dist/components/Backdrop/BackdropTooltip.js +15 -0
  109. package/dist/components/Backdrop/BackdropTooltip.js.map +1 -0
  110. package/dist/components/Backdrop/BackdropTooltip.module.css.js +18 -0
  111. package/dist/components/Backdrop/BackdropTooltip.module.css.js.map +1 -0
  112. package/dist/components/Backdrop/BackdropTopStrip.d.ts +65 -0
  113. package/dist/components/Backdrop/BackdropTopStrip.js +46 -0
  114. package/dist/components/Backdrop/BackdropTopStrip.js.map +1 -0
  115. package/dist/components/Backdrop/BackdropTopStrip.module.css.js +40 -0
  116. package/dist/components/Backdrop/BackdropTopStrip.module.css.js.map +1 -0
  117. package/dist/components/Backdrop/cx.d.ts +2 -0
  118. package/dist/components/Backdrop/cx.js +7 -0
  119. package/dist/components/Backdrop/cx.js.map +1 -0
  120. package/dist/components/Backdrop/icons.d.ts +70 -0
  121. package/dist/components/Backdrop/icons.js +103 -0
  122. package/dist/components/Backdrop/icons.js.map +1 -0
  123. package/package.json +23 -4
@@ -0,0 +1,80 @@
1
+ import { ElementType, MouseEvent, ReactNode } from 'react';
2
+ import { BackdropPageAction } from './BackdropPage';
3
+ export interface BackdropQuickActionProps {
4
+ /**
5
+ * The 20px icon inside the round tile (D17). Decorative: the label names the
6
+ * action, so the icon is not announced.
7
+ */
8
+ icon: ReactNode;
9
+ /** The words under the tile: "New campaign". */
10
+ label: ReactNode;
11
+ href?: string;
12
+ /** Called on a press, with the event (see BackdropAppCard's `onClick`). */
13
+ onClick?: (event: MouseEvent<HTMLElement>) => void;
14
+ /** The link element for a card with an href (ADR-0011). */
15
+ linkComponent?: ElementType;
16
+ className?: string;
17
+ }
18
+ export declare function BackdropQuickAction({ icon, label, href, onClick, linkComponent, className }: BackdropQuickActionProps): import("react").JSX.Element;
19
+ export type BackdropAppCardLayout = 'inline' | 'stacked';
20
+ export interface BackdropAppCardProps {
21
+ /** The app's 32px mark (ProductMark). Decorative: the name names the card. */
22
+ mark?: ReactNode;
23
+ /** The app's name, as identity serves it. */
24
+ name: ReactNode;
25
+ /**
26
+ * `inline` (default) is Day 20's one-line card, 56 tall, with the action in
27
+ * a fixed lane at the end. `stacked` is Day 1's 64, with the action under
28
+ * the name, where it reads as the next thing to do rather than a way in.
29
+ */
30
+ layout?: BackdropAppCardLayout;
31
+ /** A second line on a `stacked` card. */
32
+ description?: ReactNode;
33
+ /** The trailing words: "Open", "Set up", "Request access". A chevron follows. */
34
+ actionLabel?: ReactNode;
35
+ /** Anything before the action: a Soon tag, a count badge. */
36
+ trailing?: ReactNode;
37
+ href?: string;
38
+ /**
39
+ * Called on a press, with or without `href`; with one, the link still
40
+ * navigates. It gets the event so a host can tell a plain click from one that
41
+ * opens a new tab (a modifier key, the middle button) before it paints a
42
+ * launch screen over the page it is leaving.
43
+ */
44
+ onClick?: (event: MouseEvent<HTMLElement>) => void;
45
+ linkComponent?: ElementType;
46
+ className?: string;
47
+ }
48
+ export declare function BackdropAppCard({ mark, name, layout, description, actionLabel, trailing, href, onClick, linkComponent, className, }: BackdropAppCardProps): import("react").JSX.Element;
49
+ export interface BackdropProfileStripProps {
50
+ /** The bold count: "Company profile 5 of 8". */
51
+ title: ReactNode;
52
+ /** 0–1, drawn in the 160px bar. */
53
+ progress: number;
54
+ /** The bar's accessible name: "Company profile, 5 of 8 done". */
55
+ progressLabel: string;
56
+ /** The muted line: "Missing: company size, website". One line; it truncates. */
57
+ description?: ReactNode;
58
+ /** The one action, drawn as the outline button. */
59
+ action?: BackdropPageAction;
60
+ linkComponent?: ElementType;
61
+ className?: string;
62
+ }
63
+ export declare function BackdropProfileStrip({ title, progress, progressLabel, description, action, linkComponent, className, }: BackdropProfileStripProps): import("react").JSX.Element;
64
+ export interface BackdropMapCardProps {
65
+ /** The card's heading: "Events near you". */
66
+ title: ReactNode;
67
+ /** A trailing link in the header: "See all events". */
68
+ action?: BackdropPageAction;
69
+ /**
70
+ * The map, which belongs to the product: this package has no map provider
71
+ * and holds no place data. Drawn in a fixed band that clips it, so a map
72
+ * that arrives late or at the wrong size cannot move the card.
73
+ */
74
+ map: ReactNode;
75
+ /** One line under the map: the fact the map is there to support. */
76
+ caption?: ReactNode;
77
+ linkComponent?: ElementType;
78
+ className?: string;
79
+ }
80
+ export declare function BackdropMapCard({ title, action, map, caption, linkComponent, className }: BackdropMapCardProps): import("react").JSX.Element;
@@ -0,0 +1,92 @@
1
+ import { jsxs as o, jsx as e } from "react/jsx-runtime";
2
+ import a from "./BackdropHub.module.css.js";
3
+ import { cx as t } from "./cx.js";
4
+ import { ChevronRight as h } from "./icons.js";
5
+ import { BackdropIconTile as v } from "./BackdropDisplay.js";
6
+ import { BackdropProgress as f } from "./BackdropGlobalPanels.js";
7
+ import { BackdropButton as B } from "./BackdropButton.js";
8
+ import { BackdropCard as A, BackdropSectionHeader as b } from "./BackdropPage.js";
9
+ function j({ icon: n, label: c, href: i, onClick: s, linkComponent: r = "a", className: p }) {
10
+ return /* @__PURE__ */ o(i !== void 0 ? r : "button", { ...i !== void 0 ? { href: i } : { type: "button" }, onClick: s, className: t(a.quickAction, p), children: [
11
+ /* @__PURE__ */ e(v, { size: "empty", shape: "circle", className: a.tile, children: n }),
12
+ /* @__PURE__ */ e("span", { className: a.quickActionLabel, children: c })
13
+ ] });
14
+ }
15
+ function q({
16
+ mark: n,
17
+ name: c,
18
+ layout: i = "inline",
19
+ description: s,
20
+ actionLabel: r,
21
+ trailing: p,
22
+ href: d,
23
+ onClick: m,
24
+ linkComponent: u = "a",
25
+ className: N
26
+ }) {
27
+ const k = d !== void 0 ? u : "button", C = d !== void 0 ? { href: d } : { type: "button" }, l = i === "stacked";
28
+ return /* @__PURE__ */ o(
29
+ k,
30
+ {
31
+ ...C,
32
+ onClick: m,
33
+ className: t(a.appCard, l && a.appCardStacked, N),
34
+ children: [
35
+ n !== void 0 && /* @__PURE__ */ e("span", { className: a.appCardMark, "aria-hidden": "true", children: n }),
36
+ /* @__PURE__ */ o("span", { className: a.appCardText, children: [
37
+ /* @__PURE__ */ e("span", { className: a.appCardName, children: c }),
38
+ s !== void 0 && /* @__PURE__ */ e("span", { className: a.appCardDescription, children: s }),
39
+ l && r !== void 0 && /* @__PURE__ */ o("span", { className: a.appCardAction, children: [
40
+ r,
41
+ /* @__PURE__ */ e(h, { size: 14 })
42
+ ] })
43
+ ] }),
44
+ p,
45
+ !l && r !== void 0 && /* @__PURE__ */ o("span", { className: a.appCardAction, children: [
46
+ r,
47
+ /* @__PURE__ */ e(h, { size: 14 })
48
+ ] })
49
+ ]
50
+ }
51
+ );
52
+ }
53
+ function D({
54
+ title: n,
55
+ progress: c,
56
+ progressLabel: i,
57
+ description: s,
58
+ action: r,
59
+ linkComponent: p,
60
+ className: d
61
+ }) {
62
+ return /* @__PURE__ */ o("div", { className: t(a.strip, d), children: [
63
+ /* @__PURE__ */ e("span", { className: a.stripTitle, children: n }),
64
+ /* @__PURE__ */ e("span", { className: a.stripBar, children: /* @__PURE__ */ e(f, { value: c, label: i }) }),
65
+ s !== void 0 && /* @__PURE__ */ e("span", { className: a.stripDescription, children: s }),
66
+ r && /* @__PURE__ */ e(
67
+ B,
68
+ {
69
+ variant: "outline",
70
+ size: "md",
71
+ href: r.href,
72
+ onClick: r.onClick,
73
+ linkComponent: p,
74
+ children: r.label
75
+ }
76
+ )
77
+ ] });
78
+ }
79
+ function M({ title: n, action: c, map: i, caption: s, linkComponent: r, className: p }) {
80
+ return /* @__PURE__ */ o(A, { padding: "none", className: t(a.mapCard, p), children: [
81
+ /* @__PURE__ */ e(b, { label: n, action: c, linkComponent: r }),
82
+ /* @__PURE__ */ e("div", { className: a.mapSlot, children: i }),
83
+ s !== void 0 && /* @__PURE__ */ e("p", { className: a.mapCaption, children: s })
84
+ ] });
85
+ }
86
+ export {
87
+ q as BackdropAppCard,
88
+ M as BackdropMapCard,
89
+ D as BackdropProfileStrip,
90
+ j as BackdropQuickAction
91
+ };
92
+ //# sourceMappingURL=BackdropHub.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BackdropHub.js","sources":["../../../src/components/Backdrop/BackdropHub.tsx"],"sourcesContent":["import type { ElementType, MouseEvent, ReactNode } from 'react'\nimport styles from './BackdropHub.module.css'\nimport { cx } from './cx'\nimport { ChevronRight } from './icons'\nimport { BackdropIconTile } from './BackdropDisplay'\nimport { BackdropProgress } from './BackdropGlobalPanels'\nimport { BackdropButton } from './BackdropButton'\nimport { BackdropCard, BackdropSectionHeader, type BackdropPageAction } from './BackdropPage'\n\n/*\n * Batch 5 · Hub. The four parts the Hub's home boards draw that nothing in the\n * package already covers: the quick-actions row, the app launcher card, the\n * completion strip and the map card.\n *\n * Stage A: static and presentational. An action is the package's\n * { label, onClick?, href? } shape so wiring is uniform later, and nothing here\n * holds state.\n *\n * Sizes are read from Hub Final \"Day 20\" and \"Day 1\" (Paper file\n * 01M70VHN0KBFJKNT6VD3DFE83K, page p-5-0) with get_computed_styles, except\n * where ADR-0017 fixes the value, which it wins.\n */\n\n/* ── Quick action ──────────────────────────────────────────────────────── */\n\nexport interface BackdropQuickActionProps {\n /**\n * The 20px icon inside the round tile (D17). Decorative: the label names the\n * action, so the icon is not announced.\n */\n icon: ReactNode\n /** The words under the tile: \"New campaign\". */\n label: ReactNode\n href?: string\n /** Called on a press, with the event (see BackdropAppCard's `onClick`). */\n onClick?: (event: MouseEvent<HTMLElement>) => void\n /** The link element for a card with an href (ADR-0011). */\n linkComponent?: ElementType\n className?: string\n}\n\n/*\n * One column of the quick-actions row: a 48px round panel tile over a 13/18\n * label, 94 wide on both Hub home boards. The tile is BackdropIconTile's\n * `empty` size drawn round, the same 48 the empty state and the result screen\n * use (D12, Batch 2 gate), rather than a fourth tile size.\n */\nexport function BackdropQuickAction({ icon, label, href, onClick, linkComponent = 'a', className }: BackdropQuickActionProps) {\n const Element: ElementType = href !== undefined ? linkComponent : 'button'\n const elementProps = href !== undefined ? { href } : { type: 'button' as const }\n return (\n <Element {...elementProps} onClick={onClick} className={cx(styles.quickAction, className)}>\n <BackdropIconTile size=\"empty\" shape=\"circle\" className={styles.tile}>\n {icon}\n </BackdropIconTile>\n <span className={styles.quickActionLabel}>{label}</span>\n </Element>\n )\n}\n\n/* ── App card ──────────────────────────────────────────────────────────── */\n\nexport type BackdropAppCardLayout = 'inline' | 'stacked'\n\nexport interface BackdropAppCardProps {\n /** The app's 32px mark (ProductMark). Decorative: the name names the card. */\n mark?: ReactNode\n /** The app's name, as identity serves it. */\n name: ReactNode\n /**\n * `inline` (default) is Day 20's one-line card, 56 tall, with the action in\n * a fixed lane at the end. `stacked` is Day 1's 64, with the action under\n * the name, where it reads as the next thing to do rather than a way in.\n */\n layout?: BackdropAppCardLayout\n /** A second line on a `stacked` card. */\n description?: ReactNode\n /** The trailing words: \"Open\", \"Set up\", \"Request access\". A chevron follows. */\n actionLabel?: ReactNode\n /** Anything before the action: a Soon tag, a count badge. */\n trailing?: ReactNode\n href?: string\n /**\n * Called on a press, with or without `href`; with one, the link still\n * navigates. It gets the event so a host can tell a plain click from one that\n * opens a new tab (a modifier key, the middle button) before it paints a\n * launch screen over the page it is leaving.\n */\n onClick?: (event: MouseEvent<HTMLElement>) => void\n linkComponent?: ElementType\n className?: string\n}\n\n/*\n * One app in the Hub's Apps grid. The grid itself is the host's: the product\n * list is served, never hardcoded, so this draws one card and the page decides\n * how many columns they sit in.\n *\n * The trailing action keeps a fixed-width lane on an `inline` card so every\n * chevron in a grid lines up; a gap alone leaves them ragged against names of\n * different lengths.\n */\nexport function BackdropAppCard({\n mark,\n name,\n layout = 'inline',\n description,\n actionLabel,\n trailing,\n href,\n onClick,\n linkComponent = 'a',\n className,\n}: BackdropAppCardProps) {\n const Element: ElementType = href !== undefined ? linkComponent : 'button'\n const elementProps = href !== undefined ? { href } : { type: 'button' as const }\n const stacked = layout === 'stacked'\n return (\n <Element\n {...elementProps}\n onClick={onClick}\n className={cx(styles.appCard, stacked && styles.appCardStacked, className)}\n >\n {mark !== undefined && (\n <span className={styles.appCardMark} aria-hidden=\"true\">\n {mark}\n </span>\n )}\n <span className={styles.appCardText}>\n <span className={styles.appCardName}>{name}</span>\n {description !== undefined && <span className={styles.appCardDescription}>{description}</span>}\n {stacked && actionLabel !== undefined && (\n <span className={styles.appCardAction}>\n {actionLabel}\n <ChevronRight size={14} />\n </span>\n )}\n </span>\n {trailing}\n {!stacked && actionLabel !== undefined && (\n <span className={styles.appCardAction}>\n {actionLabel}\n <ChevronRight size={14} />\n </span>\n )}\n </Element>\n )\n}\n\n/* ── Completion strip ──────────────────────────────────────────────────── */\n\nexport interface BackdropProfileStripProps {\n /** The bold count: \"Company profile 5 of 8\". */\n title: ReactNode\n /** 0–1, drawn in the 160px bar. */\n progress: number\n /** The bar's accessible name: \"Company profile, 5 of 8 done\". */\n progressLabel: string\n /** The muted line: \"Missing: company size, website\". One line; it truncates. */\n description?: ReactNode\n /** The one action, drawn as the outline button. */\n action?: BackdropPageAction\n linkComponent?: ElementType\n className?: string\n}\n\n/*\n * The strip at the foot of Hub Day 20: how far a long-running setup has got,\n * on one line, without the weight of a card. BackdropProgress draws the bar at\n * its default 6 height so the package keeps one bar, and the strip only fixes\n * its width.\n *\n * The board draws the action 36 tall with a 1px ink ring. D4 fixes button\n * heights at 32, 34, 40 and 44, so this takes the 34 (`md`) outline button and\n * the drawing is the thing that is out of date; it is in the batch report.\n */\nexport function BackdropProfileStrip({\n title,\n progress,\n progressLabel,\n description,\n action,\n linkComponent,\n className,\n}: BackdropProfileStripProps) {\n return (\n <div className={cx(styles.strip, className)}>\n <span className={styles.stripTitle}>{title}</span>\n <span className={styles.stripBar}>\n <BackdropProgress value={progress} label={progressLabel} />\n </span>\n {description !== undefined && <span className={styles.stripDescription}>{description}</span>}\n {action && (\n <BackdropButton\n variant=\"outline\"\n size=\"md\"\n href={action.href}\n onClick={action.onClick}\n linkComponent={linkComponent}\n >\n {action.label}\n </BackdropButton>\n )}\n </div>\n )\n}\n\n/* ── Map card ──────────────────────────────────────────────────────────── */\n\nexport interface BackdropMapCardProps {\n /** The card's heading: \"Events near you\". */\n title: ReactNode\n /** A trailing link in the header: \"See all events\". */\n action?: BackdropPageAction\n /**\n * The map, which belongs to the product: this package has no map provider\n * and holds no place data. Drawn in a fixed band that clips it, so a map\n * that arrives late or at the wrong size cannot move the card.\n */\n map: ReactNode\n /** One line under the map: the fact the map is there to support. */\n caption?: ReactNode\n linkComponent?: ElementType\n className?: string\n}\n\n/*\n * A card whose body is a map. It is BackdropCard and BackdropSectionHeader with\n * one thing added that neither has: a fixed, clipping slot for a surface the\n * product draws. Without that slot every product sizes its own map and the\n * cards stop matching, which is the drift ADR-0017 exists to stop.\n */\nexport function BackdropMapCard({ title, action, map, caption, linkComponent, className }: BackdropMapCardProps) {\n return (\n <BackdropCard padding=\"none\" className={cx(styles.mapCard, className)}>\n <BackdropSectionHeader label={title} action={action} linkComponent={linkComponent} />\n <div className={styles.mapSlot}>{map}</div>\n {caption !== undefined && <p className={styles.mapCaption}>{caption}</p>}\n </BackdropCard>\n )\n}\n"],"names":["BackdropQuickAction","icon","label","href","onClick","linkComponent","className","jsxs","cx","styles","jsx","BackdropIconTile","BackdropAppCard","mark","name","layout","description","actionLabel","trailing","Element","elementProps","stacked","ChevronRight","BackdropProfileStrip","title","progress","progressLabel","action","BackdropProgress","BackdropButton","BackdropMapCard","map","caption","BackdropCard","BackdropSectionHeader"],"mappings":";;;;;;;;AA+CO,SAASA,EAAoB,EAAE,MAAAC,GAAM,OAAAC,GAAO,MAAAC,GAAM,SAAAC,GAAS,eAAAC,IAAgB,KAAK,WAAAC,KAAuC;AAG5H,SACE,gBAAAC,EAH2BJ,MAAS,SAAYE,IAAgB,UAG/D,EAAS,GAFSF,MAAS,SAAY,EAAE,MAAAA,MAAS,EAAE,MAAM,SAAA,GAEhC,SAAAC,GAAkB,WAAWI,EAAGC,EAAO,aAAaH,CAAS,GACtF,UAAA;AAAA,IAAA,gBAAAI,EAACC,GAAA,EAAiB,MAAK,SAAQ,OAAM,UAAS,WAAWF,EAAO,MAC7D,UAAAR,EAAA,CACH;AAAA,IACA,gBAAAS,EAAC,QAAA,EAAK,WAAWD,EAAO,kBAAmB,UAAAP,EAAA,CAAM;AAAA,EAAA,GACnD;AAEJ;AA4CO,SAASU,EAAgB;AAAA,EAC9B,MAAAC;AAAA,EACA,MAAAC;AAAA,EACA,QAAAC,IAAS;AAAA,EACT,aAAAC;AAAA,EACA,aAAAC;AAAA,EACA,UAAAC;AAAA,EACA,MAAAf;AAAA,EACA,SAAAC;AAAA,EACA,eAAAC,IAAgB;AAAA,EAChB,WAAAC;AACF,GAAyB;AACvB,QAAMa,IAAuBhB,MAAS,SAAYE,IAAgB,UAC5De,IAAejB,MAAS,SAAY,EAAE,MAAAA,MAAS,EAAE,MAAM,SAAA,GACvDkB,IAAUN,MAAW;AAC3B,SACE,gBAAAR;AAAA,IAACY;AAAA,IAAA;AAAA,MACE,GAAGC;AAAA,MACJ,SAAAhB;AAAA,MACA,WAAWI,EAAGC,EAAO,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MAAgB,UAAa,gBAAAN,EAAC,UAAK,WAAWD,EAAO,kBAAmB,UAAAO,GAAY;AAAA,IACpFW,KACC,gBAAAjB;AAAA,MAACmB;AAAA,MAAA;AAAA,QACC,SAAQ;AAAA,QACR,MAAK;AAAA,QACL,MAAMF,EAAO;AAAA,QACb,SAASA,EAAO;AAAA,QAChB,eAAAtB;AAAA,QAEC,UAAAsB,EAAO;AAAA,MAAA;AAAA,IAAA;AAAA,EACV,GAEJ;AAEJ;AA2BO,SAASG,EAAgB,EAAE,OAAAN,GAAO,QAAAG,GAAQ,KAAAI,GAAK,SAAAC,GAAS,eAAA3B,GAAe,WAAAC,KAAmC;AAC/G,SACE,gBAAAC,EAAC0B,KAAa,SAAQ,QAAO,WAAWzB,EAAGC,EAAO,SAASH,CAAS,GAClE,UAAA;AAAA,IAAA,gBAAAI,EAACwB,GAAA,EAAsB,OAAOV,GAAO,QAAAG,GAAgB,eAAAtB,GAA8B;AAAA,IACnF,gBAAAK,EAAC,OAAA,EAAI,WAAWD,EAAO,SAAU,UAAAsB,GAAI;AAAA,IACpCC,MAAY,UAAa,gBAAAtB,EAAC,OAAE,WAAWD,EAAO,YAAa,UAAAuB,EAAA,CAAQ;AAAA,EAAA,GACtE;AAEJ;"}
@@ -0,0 +1,40 @@
1
+ const a = "_quickAction_acuka_3", p = "_quickActionLabel_acuka_21", t = "_tile_acuka_28", c = "_appCard_acuka_34", _ = "_appCardStacked_acuka_55", r = "_appCardMark_acuka_64", i = "_appCardText_acuka_73", o = "_appCardName_acuka_80", s = "_appCardDescription_acuka_89", n = "_appCardAction_acuka_103", k = "_strip_acuka_130", d = "_stripTitle_acuka_141", e = "_stripBar_acuka_148", C = "_stripDescription_acuka_153", u = "_mapCard_acuka_165", l = "_mapSlot_acuka_176", m = "_mapCaption_acuka_190", A = {
2
+ quickAction: a,
3
+ quickActionLabel: p,
4
+ tile: t,
5
+ appCard: c,
6
+ appCardStacked: _,
7
+ appCardMark: r,
8
+ appCardText: i,
9
+ appCardName: o,
10
+ appCardDescription: s,
11
+ appCardAction: n,
12
+ strip: k,
13
+ stripTitle: d,
14
+ stripBar: e,
15
+ stripDescription: C,
16
+ mapCard: u,
17
+ mapSlot: l,
18
+ mapCaption: m
19
+ };
20
+ export {
21
+ c as appCard,
22
+ n as appCardAction,
23
+ s as appCardDescription,
24
+ r as appCardMark,
25
+ o as appCardName,
26
+ _ as appCardStacked,
27
+ i as appCardText,
28
+ A as default,
29
+ m as mapCaption,
30
+ u as mapCard,
31
+ l as mapSlot,
32
+ a as quickAction,
33
+ p as quickActionLabel,
34
+ k as strip,
35
+ e as stripBar,
36
+ C as stripDescription,
37
+ d as stripTitle,
38
+ t as tile
39
+ };
40
+ //# sourceMappingURL=BackdropHub.module.css.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BackdropHub.module.css.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;;;;;;;;;;;;;;;;;"}
@@ -0,0 +1,165 @@
1
+ import { ElementType, HTMLAttributes, ReactNode } from 'react';
2
+ /**
3
+ * `flat` (default): bare on the page, rows 4 from the edge (the boards'
4
+ * majority). `card`: inside a flat card (ADR-0017, D3), rows 12 from the card's
5
+ * inner edge, as the next-step action list draws them.
6
+ */
7
+ export type BackdropListSurface = 'flat' | 'card';
8
+ export interface BackdropListProps extends Omit<HTMLAttributes<HTMLUListElement>, 'children'> {
9
+ /** BackdropListRow elements. */
10
+ children: ReactNode;
11
+ surface?: BackdropListSurface;
12
+ /** The list's accessible name ("Matches", "Up next"), when no heading names it. */
13
+ label?: string;
14
+ }
15
+ /** A <ul> of BackdropListRow, a soft hairline between each two rows. */
16
+ export declare function BackdropList({ children, surface, label, className, ...rest }: BackdropListProps): import("react").JSX.Element;
17
+ export interface BackdropListRowProps {
18
+ /**
19
+ * The leading slot: a BackdropIconTile (36, the row tile), a BackdropAvatar
20
+ * (36), or nothing. A checkbox goes here too when the row is selectable.
21
+ */
22
+ leading?: ReactNode;
23
+ /** One line; truncates with an ellipsis. Names the row's link or button when it has one. */
24
+ title: ReactNode;
25
+ /** The muted second line: one fact ("3 new offers · closes in 4 days"). One line, truncates. */
26
+ description?: ReactNode;
27
+ /** A short muted fact after the text, fixed to the end: "2 h ago", "7 Nov". */
28
+ meta?: ReactNode;
29
+ /**
30
+ * Something in this row has not been seen yet (a conversation with a new
31
+ * message). Draws the 8px ink dot after `meta`, sets `meta` in ink 600, and
32
+ * gives the dot this text for screen readers, translated by the caller:
33
+ * "Unread". Without it the row draws no dot (Batch 4, N28).
34
+ */
35
+ unreadLabel?: string;
36
+ /** The row's status: a BackdropStatusMark (ADR-0017, Batch 3 gate). The boxed BackdropPill is for a page's or card's main status, not a row's. */
37
+ status?: ReactNode;
38
+ /** The trailing figure: tabular numerals, right-aligned ("€1,760", "−575"). */
39
+ value?: ReactNode;
40
+ /** A muted line under the value ("Expected", "saved a year"). */
41
+ valueCaption?: ReactNode;
42
+ /** The trailing action: a BackdropButton or BackdropOverflowMenu. Sits above the row's own target. */
43
+ action?: ReactNode;
44
+ /** A 16px chevron at the end, for a row that opens something. Decorative. */
45
+ chevron?: boolean;
46
+ /**
47
+ * The whole row opens a page: the title renders as a link (through
48
+ * `linkComponent`) whose hit area covers the row. The handler is Stage B's.
49
+ */
50
+ href?: string;
51
+ /** `button`: the whole row is a <button type="button"> (opens a side panel). Ignored with `href`. */
52
+ as?: 'button';
53
+ linkComponent?: ElementType;
54
+ /**
55
+ * This row is the one open beside the list (its side panel is showing):
56
+ * the panel grey, and `aria-current="true"` on the row's link or button.
57
+ */
58
+ current?: boolean;
59
+ /** This row is ticked (its leading checkbox carries the state): the panel grey only. */
60
+ selected?: boolean;
61
+ className?: string;
62
+ }
63
+ export declare function BackdropListRow({ leading, title, description, meta, unreadLabel, status, value, valueCaption, action, chevron, href, as, linkComponent: Link, current, selected, className, }: BackdropListRowProps): import("react").JSX.Element;
64
+ /** One property: "Paid from" · "Monthly tokens", with an optional muted caption under the value. */
65
+ export interface BackdropKeyValueItem {
66
+ key: string;
67
+ label: ReactNode;
68
+ value: ReactNode;
69
+ caption?: ReactNode;
70
+ }
71
+ /**
72
+ * `inline` (default): label left, value right, 13/20 (the side-panel boards).
73
+ * `stacked`: label above a 15/22 value, as Score Leads draws its facts.
74
+ */
75
+ export type BackdropKeyValueLayout = 'inline' | 'stacked';
76
+ export interface BackdropKeyValueListProps extends Omit<HTMLAttributes<HTMLDListElement>, 'children'> {
77
+ items: BackdropKeyValueItem[];
78
+ layout?: BackdropKeyValueLayout;
79
+ /** The list's accessible name ("Entry details"), when no heading names it. */
80
+ label?: string;
81
+ }
82
+ /** A <dl>: each pair is a <div> holding its <dt> and <dd>, which the HTML spec allows for styling. */
83
+ export declare function BackdropKeyValueList({ items, layout, label, className, ...rest }: BackdropKeyValueListProps): import("react").JSX.Element;
84
+ export type BackdropSortDirection = 'ascending' | 'descending';
85
+ export interface BackdropDataTableColumn<Row> {
86
+ key: string;
87
+ /** The header's words. Short: "Company and need", "Commission". */
88
+ header: ReactNode;
89
+ /** `start` (default) or `end`. A `numeric` column defaults to `end`. */
90
+ align?: 'start' | 'end';
91
+ /** A fixed width as a CSS length, ideally a token (`var(--…)`). One column without a width takes the rest. */
92
+ width?: string;
93
+ /** The header becomes a sort button and the <th> carries `aria-sort`. */
94
+ sortable?: boolean;
95
+ /** Tabular numerals, aligned to the end unless `align` says otherwise. */
96
+ numeric?: boolean;
97
+ /** The cell. Without it the cell shows `row[key]`. */
98
+ cell?: (row: Row) => ReactNode;
99
+ }
100
+ /** What the first cell's content opens: a page (`link`) or a side panel (`button`). Stage B wires it. */
101
+ export type BackdropDataTableRowTarget<Row> = {
102
+ kind: 'link';
103
+ href: (row: Row) => string;
104
+ } | {
105
+ kind: 'button';
106
+ };
107
+ export interface BackdropDataTableSelection<Row> {
108
+ /** The keys of the ticked rows. */
109
+ selected: string[];
110
+ /** Each row checkbox's name: "Select Groupe Vivalyon". */
111
+ rowLabel: (row: Row) => string;
112
+ /** The header checkbox's name: "Select all". */
113
+ allLabel: string;
114
+ }
115
+ export interface BackdropDataTableProps<Row extends object> {
116
+ columns: BackdropDataTableColumn<Row>[];
117
+ rows: Row[];
118
+ rowKey: (row: Row) => string;
119
+ /** The table's name, in a visually hidden <caption> unless `showCaption`. */
120
+ caption: string;
121
+ showCaption?: boolean;
122
+ /** The column the rows are sorted by, and which way. Drawn, not performed: Stage A sorts nothing. */
123
+ sort?: {
124
+ key: string;
125
+ direction: BackdropSortDirection;
126
+ };
127
+ /** Adds the select column: a checkbox per row and a select-all in the header. */
128
+ selection?: BackdropDataTableSelection<Row>;
129
+ /** The first cell's content becomes the row's link or button; its hit area covers the row. */
130
+ rowTarget?: BackdropDataTableRowTarget<Row>;
131
+ /** The open row (its side panel is showing): the panel grey and `aria-current="true"` on its target. */
132
+ currentRowKey?: string;
133
+ /** Shown in place of the body when there are no rows: a BackdropEmptyState. */
134
+ empty?: ReactNode;
135
+ /** Skeleton rows in place of the body, and `aria-busy` on the table. */
136
+ loading?: boolean;
137
+ /** How many skeleton rows. Default 5. */
138
+ loadingRows?: number;
139
+ /** The header stays at the top of its scroll container. */
140
+ stickyHeader?: boolean;
141
+ linkComponent?: ElementType;
142
+ className?: string;
143
+ }
144
+ export declare function BackdropDataTable<Row extends object>({ columns, rows, rowKey, caption, showCaption, sort, selection, rowTarget, currentRowKey, empty, loading, loadingRows, stickyHeader, linkComponent: Link, className, }: BackdropDataTableProps<Row>): import("react").JSX.Element;
145
+ export interface BackdropListToolbarProps {
146
+ /** The group's name ("People list tools"). */
147
+ label: string;
148
+ /** A BackdropSearchField at size="md" (34), level with the filter button. */
149
+ search?: ReactNode;
150
+ /** ONE BackdropFilterButton (ADR-0017, D11). */
151
+ filter?: ReactNode;
152
+ /** Quick toggle chips: BackdropChip, filter kind. Grouped and named by `chipsLabel`. */
153
+ chips?: ReactNode;
154
+ chipsLabel?: string;
155
+ /** The result count, formatted by the caller: "50 people". */
156
+ count?: ReactNode;
157
+ /** A BackdropSelect, appearance="pill". */
158
+ sort?: ReactNode;
159
+ /** A BackdropSegmented with icons (List | Board). */
160
+ view?: ReactNode;
161
+ /** Trailing actions: an outline "Import a list", an "Export CSV". The page's one orange stays in the header. */
162
+ actions?: ReactNode;
163
+ className?: string;
164
+ }
165
+ export declare function BackdropListToolbar({ label, search, filter, chips, chipsLabel, count, sort, view, actions, className }: BackdropListToolbarProps): import("react").JSX.Element;
@@ -0,0 +1,162 @@
1
+ import { jsxs as c, jsx as a } from "react/jsx-runtime";
2
+ import e from "./BackdropLists.module.css.js";
3
+ import { cx as s } from "./cx.js";
4
+ import { ArrowUp as V, ArrowDown as D, ChevronRight as R } from "./icons.js";
5
+ import { BackdropCard as U } from "./BackdropPage.js";
6
+ import { BackdropCheckbox as I } from "./BackdropPatterns.js";
7
+ function z({ children: d, surface: t = "flat", label: o, className: i, ...h }) {
8
+ const l = /* @__PURE__ */ a("ul", { "aria-label": o, className: s(e.list, t === "card" && e.listInCard, t === "flat" && i), ...h, children: d });
9
+ return t === "card" ? /* @__PURE__ */ a(U, { surface: "flat", padding: "none", className: s(e.listCard, i), children: l }) : l;
10
+ }
11
+ function G({
12
+ leading: d,
13
+ title: t,
14
+ description: o,
15
+ meta: i,
16
+ unreadLabel: h,
17
+ status: l,
18
+ value: n,
19
+ valueCaption: p,
20
+ action: N,
21
+ chevron: b = !1,
22
+ href: u,
23
+ as: g,
24
+ linkComponent: L = "a",
25
+ current: k = !1,
26
+ selected: C = !1,
27
+ className: w
28
+ }) {
29
+ const S = u !== void 0 || g === "button";
30
+ let y = t;
31
+ return u !== void 0 ? y = /* @__PURE__ */ a(L, { href: u, className: e.rowTarget, "aria-current": k ? "true" : void 0, children: t }) : g === "button" && (y = /* @__PURE__ */ a("button", { type: "button", className: e.rowTarget, "aria-current": k ? "true" : void 0, children: t })), /* @__PURE__ */ c(
32
+ "li",
33
+ {
34
+ className: s(e.row, S && e.rowInteractive, (k || C) && e.rowSelected, w),
35
+ "data-current": k || void 0,
36
+ "data-selected": C || void 0,
37
+ children: [
38
+ d != null && /* @__PURE__ */ a("span", { className: e.rowLeading, children: d }),
39
+ /* @__PURE__ */ c("span", { className: e.rowText, children: [
40
+ /* @__PURE__ */ a("span", { className: e.rowTitle, children: y }),
41
+ o != null && /* @__PURE__ */ a("span", { className: e.rowDescription, children: o })
42
+ ] }),
43
+ i != null && /* @__PURE__ */ a("span", { className: s(e.rowMeta, h !== void 0 && e.rowMetaUnread), children: i }),
44
+ h !== void 0 && /* @__PURE__ */ a("span", { className: e.rowUnread, children: /* @__PURE__ */ a("span", { className: e.srOnly, children: h }) }),
45
+ l != null && /* @__PURE__ */ a("span", { className: e.rowStatus, children: l }),
46
+ (n != null || p != null) && /* @__PURE__ */ c("span", { className: e.rowValue, children: [
47
+ n != null && /* @__PURE__ */ a("span", { className: e.rowFigure, children: n }),
48
+ p != null && /* @__PURE__ */ a("span", { className: e.rowValueCaption, children: p })
49
+ ] }),
50
+ N != null && /* @__PURE__ */ a("span", { className: e.rowAction, children: N }),
51
+ b && /* @__PURE__ */ a("span", { className: e.rowChevron, "aria-hidden": "true", children: /* @__PURE__ */ a(R, {}) })
52
+ ]
53
+ }
54
+ );
55
+ }
56
+ function H({ items: d, layout: t = "inline", label: o, className: i, ...h }) {
57
+ return /* @__PURE__ */ a(
58
+ "dl",
59
+ {
60
+ "aria-label": o,
61
+ className: s(e.kv, e.kvOpen, t === "stacked" ? e.kvStacked : e.kvInline, i),
62
+ ...h,
63
+ children: d.map((l) => /* @__PURE__ */ c("div", { className: e.kvRow, children: [
64
+ /* @__PURE__ */ a("dt", { className: e.kvLabel, children: l.label }),
65
+ /* @__PURE__ */ c("dd", { className: e.kvValue, children: [
66
+ /* @__PURE__ */ a("span", { className: e.kvFigure, children: l.value }),
67
+ l.caption != null && /* @__PURE__ */ a("span", { className: e.kvCaption, children: l.caption })
68
+ ] })
69
+ ] }, l.key))
70
+ }
71
+ );
72
+ }
73
+ function T(d) {
74
+ return d.align ?? (d.numeric ? "end" : "start");
75
+ }
76
+ function J({
77
+ columns: d,
78
+ rows: t,
79
+ rowKey: o,
80
+ caption: i,
81
+ showCaption: h = !1,
82
+ sort: l,
83
+ selection: n,
84
+ rowTarget: p,
85
+ currentRowKey: N,
86
+ empty: b,
87
+ loading: u = !1,
88
+ loadingRows: g = 5,
89
+ stickyHeader: L = !1,
90
+ linkComponent: k = "a",
91
+ className: C
92
+ }) {
93
+ const w = n ? t.filter((r) => n.selected.includes(o(r))).length : 0, S = w === 0 ? !1 : w === t.length ? !0 : "mixed", y = d.length + (n ? 1 : 0), E = !u && t.length === 0 && b != null;
94
+ return /* @__PURE__ */ c("table", { className: s(e.table, L && e.tableSticky, p && e.tableInteractive, C), "aria-busy": u || void 0, children: [
95
+ /* @__PURE__ */ a("caption", { className: h ? e.caption : e.srOnly, children: i }),
96
+ /* @__PURE__ */ c("colgroup", { children: [
97
+ n && /* @__PURE__ */ a("col", { className: e.selectCol }),
98
+ d.map((r) => /* @__PURE__ */ a("col", { style: r.width ? { width: r.width } : void 0 }, r.key))
99
+ ] }),
100
+ /* @__PURE__ */ a("thead", { children: /* @__PURE__ */ c("tr", { children: [
101
+ n && /* @__PURE__ */ a("th", { scope: "col", className: s(e.th, e.selectCell), children: /* @__PURE__ */ a(I, { checked: S, label: n.allLabel, hideLabel: !0, disabled: t.length === 0 || u }) }),
102
+ d.map((r) => {
103
+ const m = (l == null ? void 0 : l.key) === r.key ? l.direction : void 0;
104
+ return /* @__PURE__ */ a(
105
+ "th",
106
+ {
107
+ scope: "col",
108
+ "aria-sort": r.sortable ? m ?? "none" : void 0,
109
+ className: s(e.th, T(r) === "end" && e.alignEnd),
110
+ children: r.sortable ? /* @__PURE__ */ c("button", { type: "button", className: s(e.sortButton, m && e.sortButtonActive), children: [
111
+ /* @__PURE__ */ a("span", { children: r.header }),
112
+ m && /* @__PURE__ */ a("span", { className: e.sortIcon, children: m === "ascending" ? /* @__PURE__ */ a(V, {}) : /* @__PURE__ */ a(D, {}) })
113
+ ] }) : r.header
114
+ },
115
+ r.key
116
+ );
117
+ })
118
+ ] }) }),
119
+ /* @__PURE__ */ c("tbody", { children: [
120
+ u && Array.from({ length: g }, (r, m) => /* @__PURE__ */ c("tr", { className: e.tr, "aria-hidden": "true", "data-loading": "true", children: [
121
+ n && /* @__PURE__ */ a("td", { className: s(e.td, e.selectCell) }),
122
+ d.map((v) => /* @__PURE__ */ a("td", { className: s(e.td, T(v) === "end" && e.alignEnd), children: /* @__PURE__ */ a("span", { className: e.skeleton }) }, v.key))
123
+ ] }, `loading-${m}`)),
124
+ E && /* @__PURE__ */ a("tr", { children: /* @__PURE__ */ a("td", { colSpan: y, className: e.emptyCell, children: b }) }),
125
+ !u && t.map((r) => {
126
+ const m = o(r), v = (n == null ? void 0 : n.selected.includes(m)) ?? !1, B = N === m;
127
+ return /* @__PURE__ */ c("tr", { className: s(e.tr, (v || B) && e.trSelected), "data-selected": v || void 0, "data-current": B || void 0, children: [
128
+ n && /* @__PURE__ */ a("td", { className: s(e.td, e.selectCell), children: /* @__PURE__ */ a(I, { checked: v, label: n.rowLabel(r), hideLabel: !0 }) }),
129
+ d.map((f, O) => {
130
+ const x = f.cell ? f.cell(r) : r[f.key];
131
+ let A = x;
132
+ return O === 0 && p && (A = p.kind === "link" ? /* @__PURE__ */ a(k, { href: p.href(r), className: e.cellTarget, "aria-current": B ? "true" : void 0, children: x }) : /* @__PURE__ */ a("button", { type: "button", className: e.cellTarget, "aria-current": B ? "true" : void 0, children: x })), /* @__PURE__ */ a("td", { className: s(e.td, T(f) === "end" && e.alignEnd, f.numeric && e.numeric), children: A }, f.key);
133
+ })
134
+ ] }, m);
135
+ })
136
+ ] })
137
+ ] });
138
+ }
139
+ function K({ label: d, search: t, filter: o, chips: i, chipsLabel: h, count: l, sort: n, view: p, actions: N, className: b }) {
140
+ const u = l != null || n != null || p != null || N != null;
141
+ return /* @__PURE__ */ c("div", { role: "group", "aria-label": d, className: s(e.toolbar, b), children: [
142
+ /* @__PURE__ */ c("div", { className: e.toolbarLead, children: [
143
+ t != null && /* @__PURE__ */ a("div", { className: e.toolbarSearch, children: t }),
144
+ o,
145
+ i != null && /* @__PURE__ */ a("div", { role: "group", "aria-label": h, className: e.toolbarChips, children: i })
146
+ ] }),
147
+ u && /* @__PURE__ */ c("div", { className: e.toolbarTrail, children: [
148
+ l != null && /* @__PURE__ */ a("span", { className: e.toolbarCount, children: l }),
149
+ n,
150
+ p,
151
+ N
152
+ ] })
153
+ ] });
154
+ }
155
+ export {
156
+ J as BackdropDataTable,
157
+ H as BackdropKeyValueList,
158
+ z as BackdropList,
159
+ G as BackdropListRow,
160
+ K as BackdropListToolbar
161
+ };
162
+ //# sourceMappingURL=BackdropLists.js.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"BackdropLists.js","sources":["../../../src/components/Backdrop/BackdropLists.tsx"],"sourcesContent":["import type { CSSProperties, ElementType, HTMLAttributes, ReactNode } from 'react'\nimport styles from './BackdropLists.module.css'\nimport { cx } from './cx'\nimport { ArrowDown, ArrowUp, ChevronRight } from './icons'\nimport { BackdropCard } from './BackdropPage'\nimport { BackdropCheckbox } from './BackdropPatterns'\n\n/*\n * Batch 3 · Lists (N17–N20). Stage A: static and presentational. Nothing here\n * sorts, filters, selects or navigates: the story passes the state (the sort\n * column and direction, the ticked rows, the open row) as props, and the\n * handlers are Stage B's. What opens something is already the right element\n * (a link through `linkComponent`, or a <button type=\"button\">), never a\n * clickable <div>, so Stage B adds a handler and changes no markup.\n *\n * List / ListRow the one flexible row: leading tile or avatar, a title\n * and a muted second line, then meta, status, a value and\n * a trailing action. Hairlines between rows; bare or in a\n * card.\n * KeyValueList property rows as a <dl>: label and value side by side\n * or stacked, with hairlines between rows.\n * DataTable a real <table>: one header style, sortable headers,\n * a select column, a row target, empty and loading.\n * ListToolbar the bar above a list or table. It composes the\n * existing controls and draws none of its own.\n *\n * No product nouns: rows and columns are data, cells are ReactNode. Status in\n * a row is a slot; this module draws no status dot or check of its own.\n */\n\n/* ── N17 · List and list row ───────────────────────────────────────────── */\n\n/**\n * `flat` (default): bare on the page, rows 4 from the edge (the boards'\n * majority). `card`: inside a flat card (ADR-0017, D3), rows 12 from the card's\n * inner edge, as the next-step action list draws them.\n */\nexport type BackdropListSurface = 'flat' | 'card'\n\nexport interface BackdropListProps extends Omit<HTMLAttributes<HTMLUListElement>, 'children'> {\n /** BackdropListRow elements. */\n children: ReactNode\n surface?: BackdropListSurface\n /** The list's accessible name (\"Matches\", \"Up next\"), when no heading names it. */\n label?: string\n}\n\n/** A <ul> of BackdropListRow, a soft hairline between each two rows. */\nexport function BackdropList({ children, surface = 'flat', label, className, ...rest }: BackdropListProps) {\n const list = (\n <ul aria-label={label} className={cx(styles.list, surface === 'card' && styles.listInCard, surface === 'flat' && className)} {...rest}>\n {children}\n </ul>\n )\n if (surface === 'card') {\n return (\n <BackdropCard surface=\"flat\" padding=\"none\" className={cx(styles.listCard, className)}>\n {list}\n </BackdropCard>\n )\n }\n return list\n}\n\nexport interface BackdropListRowProps {\n /**\n * The leading slot: a BackdropIconTile (36, the row tile), a BackdropAvatar\n * (36), or nothing. A checkbox goes here too when the row is selectable.\n */\n leading?: ReactNode\n /** One line; truncates with an ellipsis. Names the row's link or button when it has one. */\n title: ReactNode\n /** The muted second line: one fact (\"3 new offers · closes in 4 days\"). One line, truncates. */\n description?: ReactNode\n /** A short muted fact after the text, fixed to the end: \"2 h ago\", \"7 Nov\". */\n meta?: ReactNode\n /**\n * Something in this row has not been seen yet (a conversation with a new\n * message). Draws the 8px ink dot after `meta`, sets `meta` in ink 600, and\n * gives the dot this text for screen readers, translated by the caller:\n * \"Unread\". Without it the row draws no dot (Batch 4, N28).\n */\n unreadLabel?: string\n /** The row's status: a BackdropStatusMark (ADR-0017, Batch 3 gate). The boxed BackdropPill is for a page's or card's main status, not a row's. */\n status?: ReactNode\n /** The trailing figure: tabular numerals, right-aligned (\"€1,760\", \"−575\"). */\n value?: ReactNode\n /** A muted line under the value (\"Expected\", \"saved a year\"). */\n valueCaption?: ReactNode\n /** The trailing action: a BackdropButton or BackdropOverflowMenu. Sits above the row's own target. */\n action?: ReactNode\n /** A 16px chevron at the end, for a row that opens something. Decorative. */\n chevron?: boolean\n /**\n * The whole row opens a page: the title renders as a link (through\n * `linkComponent`) whose hit area covers the row. The handler is Stage B's.\n */\n href?: string\n /** `button`: the whole row is a <button type=\"button\"> (opens a side panel). Ignored with `href`. */\n as?: 'button'\n linkComponent?: ElementType\n /**\n * This row is the one open beside the list (its side panel is showing):\n * the panel grey, and `aria-current=\"true\"` on the row's link or button.\n */\n current?: boolean\n /** This row is ticked (its leading checkbox carries the state): the panel grey only. */\n selected?: boolean\n className?: string\n}\n\n/*\n * One row, every drawn variant. When the row has a target, the title is the\n * link or button and its ::after stretches over the row, so the hit area is\n * the whole row while the accessible name stays the title. Anything else in\n * the row that is itself a control (the trailing action, a checkbox) is lifted\n * above that layer and keeps its own click.\n */\nexport function BackdropListRow({\n leading,\n title,\n description,\n meta,\n unreadLabel,\n status,\n value,\n valueCaption,\n action,\n chevron = false,\n href,\n as,\n linkComponent: Link = 'a',\n current = false,\n selected = false,\n className,\n}: BackdropListRowProps) {\n const interactive = href !== undefined || as === 'button'\n let titleNode: ReactNode = title\n if (href !== undefined) {\n titleNode = (\n <Link href={href} className={styles.rowTarget} aria-current={current ? 'true' : undefined}>\n {title}\n </Link>\n )\n } else if (as === 'button') {\n titleNode = (\n <button type=\"button\" className={styles.rowTarget} aria-current={current ? 'true' : undefined}>\n {title}\n </button>\n )\n }\n return (\n <li\n className={cx(styles.row, interactive && styles.rowInteractive, (current || selected) && styles.rowSelected, className)}\n data-current={current || undefined}\n data-selected={selected || undefined}\n >\n {leading != null && <span className={styles.rowLeading}>{leading}</span>}\n <span className={styles.rowText}>\n <span className={styles.rowTitle}>{titleNode}</span>\n {description != null && <span className={styles.rowDescription}>{description}</span>}\n </span>\n {meta != null && <span className={cx(styles.rowMeta, unreadLabel !== undefined && styles.rowMetaUnread)}>{meta}</span>}\n {unreadLabel !== undefined && (\n <span className={styles.rowUnread}>\n <span className={styles.srOnly}>{unreadLabel}</span>\n </span>\n )}\n {status != null && <span className={styles.rowStatus}>{status}</span>}\n {(value != null || valueCaption != null) && (\n <span className={styles.rowValue}>\n {value != null && <span className={styles.rowFigure}>{value}</span>}\n {valueCaption != null && <span className={styles.rowValueCaption}>{valueCaption}</span>}\n </span>\n )}\n {action != null && <span className={styles.rowAction}>{action}</span>}\n {chevron && (\n <span className={styles.rowChevron} aria-hidden=\"true\">\n <ChevronRight />\n </span>\n )}\n </li>\n )\n}\n\n/* ── N18 · Key-value list ──────────────────────────────────────────────── */\n\n/** One property: \"Paid from\" · \"Monthly tokens\", with an optional muted caption under the value. */\nexport interface BackdropKeyValueItem {\n key: string\n label: ReactNode\n value: ReactNode\n caption?: ReactNode\n}\n\n/**\n * `inline` (default): label left, value right, 13/20 (the side-panel boards).\n * `stacked`: label above a 15/22 value, as Score Leads draws its facts.\n */\nexport type BackdropKeyValueLayout = 'inline' | 'stacked'\n\nexport interface BackdropKeyValueListProps extends Omit<HTMLAttributes<HTMLDListElement>, 'children'> {\n items: BackdropKeyValueItem[]\n layout?: BackdropKeyValueLayout\n /** The list's accessible name (\"Entry details\"), when no heading names it. */\n label?: string\n}\n\n/** A <dl>: each pair is a <div> holding its <dt> and <dd>, which the HTML spec allows for styling. */\nexport function BackdropKeyValueList({ items, layout = 'inline', label, className, ...rest }: BackdropKeyValueListProps) {\n return (\n <dl\n aria-label={label}\n className={cx(styles.kv, styles.kvOpen, layout === 'stacked' ? styles.kvStacked : styles.kvInline, className)}\n {...rest}\n >\n {items.map((item) => (\n <div key={item.key} className={styles.kvRow}>\n <dt className={styles.kvLabel}>{item.label}</dt>\n <dd className={styles.kvValue}>\n <span className={styles.kvFigure}>{item.value}</span>\n {item.caption != null && <span className={styles.kvCaption}>{item.caption}</span>}\n </dd>\n </div>\n ))}\n </dl>\n )\n}\n\n/* ── N19 · Data table ──────────────────────────────────────────────────── */\n\nexport type BackdropSortDirection = 'ascending' | 'descending'\n\nexport interface BackdropDataTableColumn<Row> {\n key: string\n /** The header's words. Short: \"Company and need\", \"Commission\". */\n header: ReactNode\n /** `start` (default) or `end`. A `numeric` column defaults to `end`. */\n align?: 'start' | 'end'\n /** A fixed width as a CSS length, ideally a token (`var(--…)`). One column without a width takes the rest. */\n width?: string\n /** The header becomes a sort button and the <th> carries `aria-sort`. */\n sortable?: boolean\n /** Tabular numerals, aligned to the end unless `align` says otherwise. */\n numeric?: boolean\n /** The cell. Without it the cell shows `row[key]`. */\n cell?: (row: Row) => ReactNode\n}\n\n/** What the first cell's content opens: a page (`link`) or a side panel (`button`). Stage B wires it. */\nexport type BackdropDataTableRowTarget<Row> = { kind: 'link'; href: (row: Row) => string } | { kind: 'button' }\n\nexport interface BackdropDataTableSelection<Row> {\n /** The keys of the ticked rows. */\n selected: string[]\n /** Each row checkbox's name: \"Select Groupe Vivalyon\". */\n rowLabel: (row: Row) => string\n /** The header checkbox's name: \"Select all\". */\n allLabel: string\n}\n\nexport interface BackdropDataTableProps<Row extends object> {\n columns: BackdropDataTableColumn<Row>[]\n rows: Row[]\n rowKey: (row: Row) => string\n /** The table's name, in a visually hidden <caption> unless `showCaption`. */\n caption: string\n showCaption?: boolean\n /** The column the rows are sorted by, and which way. Drawn, not performed: Stage A sorts nothing. */\n sort?: { key: string; direction: BackdropSortDirection }\n /** Adds the select column: a checkbox per row and a select-all in the header. */\n selection?: BackdropDataTableSelection<Row>\n /** The first cell's content becomes the row's link or button; its hit area covers the row. */\n rowTarget?: BackdropDataTableRowTarget<Row>\n /** The open row (its side panel is showing): the panel grey and `aria-current=\"true\"` on its target. */\n currentRowKey?: string\n /** Shown in place of the body when there are no rows: a BackdropEmptyState. */\n empty?: ReactNode\n /** Skeleton rows in place of the body, and `aria-busy` on the table. */\n loading?: boolean\n /** How many skeleton rows. Default 5. */\n loadingRows?: number\n /** The header stays at the top of its scroll container. */\n stickyHeader?: boolean\n linkComponent?: ElementType\n className?: string\n}\n\nfunction alignOf<Row>(column: BackdropDataTableColumn<Row>): 'start' | 'end' {\n return column.align ?? (column.numeric ? 'end' : 'start')\n}\n\n/*\n * One header style, the majority of the Final boards' tables: 36 tall, 12/500\n * in the muted grey, a hairline under it, no ground (Wallet History, Brokers\n * Opportunities, Financing applications x2). Outbound People draws 13/500 and\n * Content 13/400; those are the drawings that are out of date.\n */\nexport function BackdropDataTable<Row extends object>({\n columns,\n rows,\n rowKey,\n caption,\n showCaption = false,\n sort,\n selection,\n rowTarget,\n currentRowKey,\n empty,\n loading = false,\n loadingRows = 5,\n stickyHeader = false,\n linkComponent: Link = 'a',\n className,\n}: BackdropDataTableProps<Row>) {\n const selectedCount = selection ? rows.filter((row) => selection.selected.includes(rowKey(row))).length : 0\n const allState: boolean | 'mixed' = selectedCount === 0 ? false : selectedCount === rows.length ? true : 'mixed'\n const span = columns.length + (selection ? 1 : 0)\n const showEmpty = !loading && rows.length === 0 && empty != null\n\n return (\n <table className={cx(styles.table, stickyHeader && styles.tableSticky, rowTarget && styles.tableInteractive, className)} aria-busy={loading || undefined}>\n <caption className={showCaption ? styles.caption : styles.srOnly}>{caption}</caption>\n <colgroup>\n {selection && <col className={styles.selectCol} />}\n {columns.map((column) => (\n <col key={column.key} style={column.width ? ({ width: column.width } as CSSProperties) : undefined} />\n ))}\n </colgroup>\n <thead>\n <tr>\n {selection && (\n <th scope=\"col\" className={cx(styles.th, styles.selectCell)}>\n <BackdropCheckbox checked={allState} label={selection.allLabel} hideLabel disabled={rows.length === 0 || loading} />\n </th>\n )}\n {columns.map((column) => {\n const sorted = sort?.key === column.key ? sort.direction : undefined\n return (\n <th\n key={column.key}\n scope=\"col\"\n aria-sort={column.sortable ? (sorted ?? 'none') : undefined}\n className={cx(styles.th, alignOf(column) === 'end' && styles.alignEnd)}\n >\n {column.sortable ? (\n <button type=\"button\" className={cx(styles.sortButton, sorted && styles.sortButtonActive)}>\n <span>{column.header}</span>\n {sorted && <span className={styles.sortIcon}>{sorted === 'ascending' ? <ArrowUp /> : <ArrowDown />}</span>}\n </button>\n ) : (\n column.header\n )}\n </th>\n )\n })}\n </tr>\n </thead>\n <tbody>\n {loading &&\n Array.from({ length: loadingRows }, (_, i) => (\n <tr key={`loading-${i}`} className={styles.tr} aria-hidden=\"true\" data-loading=\"true\">\n {selection && <td className={cx(styles.td, styles.selectCell)} />}\n {columns.map((column) => (\n <td key={column.key} className={cx(styles.td, alignOf(column) === 'end' && styles.alignEnd)}>\n <span className={styles.skeleton} />\n </td>\n ))}\n </tr>\n ))}\n {showEmpty && (\n <tr>\n <td colSpan={span} className={styles.emptyCell}>\n {empty}\n </td>\n </tr>\n )}\n {!loading &&\n rows.map((row) => {\n const key = rowKey(row)\n const ticked = selection?.selected.includes(key) ?? false\n const current = currentRowKey === key\n return (\n <tr key={key} className={cx(styles.tr, (ticked || current) && styles.trSelected)} data-selected={ticked || undefined} data-current={current || undefined}>\n {selection && (\n <td className={cx(styles.td, styles.selectCell)}>\n <BackdropCheckbox checked={ticked} label={selection.rowLabel(row)} hideLabel />\n </td>\n )}\n {columns.map((column, index) => {\n const content = column.cell ? column.cell(row) : ((row as Record<string, unknown>)[column.key] as ReactNode)\n let body: ReactNode = content\n if (index === 0 && rowTarget) {\n body =\n rowTarget.kind === 'link' ? (\n <Link href={rowTarget.href(row)} className={styles.cellTarget} aria-current={current ? 'true' : undefined}>\n {content}\n </Link>\n ) : (\n <button type=\"button\" className={styles.cellTarget} aria-current={current ? 'true' : undefined}>\n {content}\n </button>\n )\n }\n return (\n <td key={column.key} className={cx(styles.td, alignOf(column) === 'end' && styles.alignEnd, column.numeric && styles.numeric)}>\n {body}\n </td>\n )\n })}\n </tr>\n )\n })}\n </tbody>\n </table>\n )\n}\n\n/* ── N20 · List toolbar ────────────────────────────────────────────────── */\n\nexport interface BackdropListToolbarProps {\n /** The group's name (\"People list tools\"). */\n label: string\n /** A BackdropSearchField at size=\"md\" (34), level with the filter button. */\n search?: ReactNode\n /** ONE BackdropFilterButton (ADR-0017, D11). */\n filter?: ReactNode\n /** Quick toggle chips: BackdropChip, filter kind. Grouped and named by `chipsLabel`. */\n chips?: ReactNode\n chipsLabel?: string\n /** The result count, formatted by the caller: \"50 people\". */\n count?: ReactNode\n /** A BackdropSelect, appearance=\"pill\". */\n sort?: ReactNode\n /** A BackdropSegmented with icons (List | Board). */\n view?: ReactNode\n /** Trailing actions: an outline \"Import a list\", an \"Export CSV\". The page's one orange stays in the header. */\n actions?: ReactNode\n className?: string\n}\n\n/*\n * Leading cluster: search, filter, chips. Trailing cluster, pushed to the end:\n * count, sort, view, actions. Both wrap, so a narrow sheet stacks the clusters\n * rather than squeezing a control. 10 between controls, as Outbound People\n * draws it.\n */\nexport function BackdropListToolbar({ label, search, filter, chips, chipsLabel, count, sort, view, actions, className }: BackdropListToolbarProps) {\n const trailing = count != null || sort != null || view != null || actions != null\n return (\n <div role=\"group\" aria-label={label} className={cx(styles.toolbar, className)}>\n <div className={styles.toolbarLead}>\n {search != null && <div className={styles.toolbarSearch}>{search}</div>}\n {filter}\n {chips != null && (\n <div role=\"group\" aria-label={chipsLabel} className={styles.toolbarChips}>\n {chips}\n </div>\n )}\n </div>\n {trailing && (\n <div className={styles.toolbarTrail}>\n {count != null && <span className={styles.toolbarCount}>{count}</span>}\n {sort}\n {view}\n {actions}\n </div>\n )}\n </div>\n )\n}\n"],"names":["BackdropList","children","surface","label","className","rest","list","jsx","cx","styles","BackdropCard","BackdropListRow","leading","title","description","meta","unreadLabel","status","value","valueCaption","action","chevron","href","as","Link","current","selected","interactive","titleNode","jsxs","ChevronRight","BackdropKeyValueList","items","layout","item","alignOf","column","BackdropDataTable","columns","rows","rowKey","caption","showCaption","sort","selection","rowTarget","currentRowKey","empty","loading","loadingRows","stickyHeader","selectedCount","row","allState","span","showEmpty","BackdropCheckbox","sorted","ArrowUp","ArrowDown","_","i","key","ticked","index","content","body","BackdropListToolbar","search","filter","chips","chipsLabel","count","view","actions","trailing"],"mappings":";;;;;;AAgDO,SAASA,EAAa,EAAE,UAAAC,GAAU,SAA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