basalt-ui 2.16.0 → 2.17.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 (89) hide show
  1. package/CHANGELOG.md +149 -126
  2. package/MIGRATING.md +101 -15
  3. package/agent/agents/basalt-design-reviewer.md +2 -2
  4. package/agent/skills/basalt-design/SKILL.md +2 -2
  5. package/configs/oxlint-plugin.js +2 -2
  6. package/dist/charts/Donut.d.ts.map +1 -1
  7. package/dist/charts/Donut.js +2 -2
  8. package/dist/charts/DualPanel.js +2 -2
  9. package/dist/charts/Heatmap.d.ts.map +1 -1
  10. package/dist/charts/Heatmap.js +2 -2
  11. package/dist/charts/MirroredBars.js +2 -2
  12. package/dist/charts/Sparkline.d.ts +4 -2
  13. package/dist/charts/Sparkline.d.ts.map +1 -1
  14. package/dist/charts/Sparkline.js +3 -3
  15. package/dist/charts/compile.d.ts +8 -3
  16. package/dist/charts/compile.d.ts.map +1 -1
  17. package/dist/charts/compile.js +19 -9
  18. package/dist/charts/cursor.d.ts +14 -1
  19. package/dist/charts/cursor.d.ts.map +1 -1
  20. package/dist/charts/cursor.js +29 -3
  21. package/dist/charts/date-tick-format.d.ts +17 -0
  22. package/dist/charts/date-tick-format.d.ts.map +1 -0
  23. package/dist/charts/date-tick-format.js +81 -0
  24. package/dist/charts/panel.d.ts +2 -1
  25. package/dist/charts/panel.d.ts.map +1 -1
  26. package/dist/charts/panel.js +3 -2
  27. package/dist/charts/types.d.ts +5 -1
  28. package/dist/charts/types.d.ts.map +1 -1
  29. package/dist/cli/shot/capture.d.ts +16 -0
  30. package/dist/cli/shot/capture.d.ts.map +1 -1
  31. package/dist/cli/shot/capture.js +24 -3
  32. package/dist/cli/shot/playwright.d.ts +4 -0
  33. package/dist/cli/shot/playwright.d.ts.map +1 -1
  34. package/dist/dashboard/delta-badge.d.ts +2 -2
  35. package/dist/dashboard/delta-badge.d.ts.map +1 -1
  36. package/dist/dashboard/delta-badge.js +12 -14
  37. package/dist/dashboard/query-state.d.ts +35 -0
  38. package/dist/dashboard/query-state.d.ts.map +1 -1
  39. package/dist/dashboard/query-state.js +12 -1
  40. package/dist/dashboard/stat-card-parts.d.ts +40 -0
  41. package/dist/dashboard/stat-card-parts.d.ts.map +1 -0
  42. package/dist/dashboard/stat-card-parts.js +55 -0
  43. package/dist/dashboard/stat-card.d.ts +46 -34
  44. package/dist/dashboard/stat-card.d.ts.map +1 -1
  45. package/dist/dashboard/stat-card.js +148 -79
  46. package/dist/dashboard/stat-card.module.css +220 -7
  47. package/dist/dashboard/stat-card.module.css.d.ts +20 -0
  48. package/dist/dashboard/widget-header.d.ts.map +1 -1
  49. package/dist/dashboard/widget-header.js +73 -9
  50. package/dist/dashboard/widget-header.module.css +25 -17
  51. package/dist/guard/index.js +2 -2
  52. package/dist/theme/chrome-vars.d.ts +82 -0
  53. package/dist/theme/chrome-vars.d.ts.map +1 -0
  54. package/dist/theme/chrome-vars.js +36 -0
  55. package/dist/theme/controls.module.css +20 -1
  56. package/dist/theme/controls.module.css.d.ts +1 -0
  57. package/dist/theme/index.d.ts.map +1 -1
  58. package/dist/theme/index.js +30 -33
  59. package/dist/tokens/derive.d.ts.map +1 -1
  60. package/dist/tokens/derive.js +2 -2
  61. package/llms.txt +6 -3
  62. package/package.json +1 -1
  63. package/src/charts/Donut.tsx +2 -2
  64. package/src/charts/DualPanel.tsx +2 -2
  65. package/src/charts/Heatmap.tsx +2 -2
  66. package/src/charts/MirroredBars.tsx +2 -2
  67. package/src/charts/Sparkline.tsx +7 -5
  68. package/src/charts/compile.ts +31 -11
  69. package/src/charts/cursor.ts +48 -3
  70. package/src/charts/date-tick-format.ts +132 -0
  71. package/src/charts/panel.tsx +5 -3
  72. package/src/charts/types.ts +5 -1
  73. package/src/cli/shot/capture.ts +35 -3
  74. package/src/cli/shot/playwright.ts +1 -1
  75. package/src/dashboard/delta-badge.tsx +24 -18
  76. package/src/dashboard/query-state.tsx +38 -0
  77. package/src/dashboard/stat-card-parts.tsx +108 -0
  78. package/src/dashboard/stat-card.module.css +220 -7
  79. package/src/dashboard/stat-card.module.css.d.ts +20 -0
  80. package/src/dashboard/stat-card.tsx +282 -174
  81. package/src/dashboard/widget-header.module.css +25 -17
  82. package/src/dashboard/widget-header.tsx +103 -7
  83. package/src/guard/index.ts +2 -2
  84. package/src/theme/__snapshots__/plain-theme.test.ts.snap +128 -40
  85. package/src/theme/chrome-vars.ts +111 -0
  86. package/src/theme/controls.module.css +20 -1
  87. package/src/theme/controls.module.css.d.ts +1 -0
  88. package/src/theme/index.ts +39 -101
  89. package/src/tokens/derive.ts +7 -2
package/MIGRATING.md CHANGED
@@ -66,18 +66,18 @@ There is one row per SURFACE, not per export, and a surface earns a row once any
66
66
  shipped lefthook preset both changed in 1.30.0 with no row that owned them — which is how a
67
67
  consumer read this index, found nothing, and diffed a KPI row that had silently gone 4-up → 2-up.
68
68
 
69
- | Surface | 1.27.0 | 1.28.0 | 1.29.0 | 1.30.0 | 1.30.1 | 1.30.2 | 1.31.0 | 1.32.0 | 1.32.1 | 1.33.0 | 1.34.0 | 1.34.1 | 1.35.0 | 1.36.0 | 1.36.1 | 1.37.0 | 1.37.1 | 1.38.0 | 1.38.1 | 1.39.0 | 1.40.0 | 1.40.1 | 1.40.2 | 1.40.3 | 1.41.0 | 2.0.0 | 2.0.1 | 2.0.2 | 2.0.3 | 2.0.4 | 2.0.5 | 2.1.0 | 2.2.0 | 2.3.0 | 2.4.0 | 2.5.0 | 2.6.0 | 2.6.1 | 2.7.0 | 2.7.1 | 2.7.2 | 2.7.3 | 2.8.0 | 2.8.1 | 2.9.0 | 2.9.1 | 2.10.0 | 2.11.0 | 2.11.1 | 2.12.0 | 2.13.0 | 2.13.1 | 2.13.2 | 2.13.3 | 2.14.0 | 2.15.0 | 2.16.0 | Unreleased |
70
- | ----------------------------- | ------------------------------------------------------------ | -------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | --------------------------------------------------------------------- | ------ | ----------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------- | ---------------------------------- | ------ | ------ | -------------------------------------------------------------------------------------------- | ------ | ------ | ------ | ------ | ------ | ----------------------------------------------- | ------ | ------ | ------ | ------ | ------------------------------------------------------------ | ---------- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |
71
- | **tokens** (`./tokens`) | — | `--vx-divider` → `rgba()` on both schemes (§ Shell) | `--vx-space-touch-target` added (§ Additions) | eight spacing numbers (§ Chrome) | — | — | `--vx-hit` replaces the touch vars; `SIZE_CLASSES` (§ 1.31.0) | — | `SIZE_CLASSES`/`CONTAINER_CLASSES` actually exported (§ Fixes) | `CONTAINER_GRID_BREAKPOINTS`; `raw-breakpoint` trusts it (§ 1.33.0) | `CONTAINER_KEYS` (§ 1.34.0) | — | — | — | — | — | — | — | | `appShellInset` 20 → 16 (§ 1.38.1) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | § 1.x compatibility layer removed | — | — | — | — | — | — | — | — | — | — | — | spacing, radius, type and the dense tier (§ 2.16.0) | — |
72
- | **charts** (`./charts`) | — | phone tier, `curve`, formatters, `state`, log axis (§ preamble) | `ChartState.empty: string`, `AxisBottomNumeric` (§ Additions) | responsive `height`, `legend.maxRows` (§ Charts) | `height` reaches the kinds; `maxRows` beats the `fill` fit (§ Charts) | — | container-class tier + `height` keys (§ 1.31.0) | — | `ResponsiveChartHeight` `sm` → key (§ Container recipes) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | `BandSpan.absentFraction` + `absentState` (§ 2.8.0) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — |
73
- | **shell** (`.`) | — | scrollport, region seams, **the brand left the sidebar** (§§ scrollport, brand, Shell) | `PageTitle`, `BasaltDevDock`, `useBreakpoint` (§ Additions) | More popover, aside pill, the responsive gutter, `useBasaltSpacing` (§ Chrome) | — | — | `theme.breakpoints` derived, `useSizeClass`, `data-basalt-host`, `useBreakpoint` on notice (§ 1.31.0) | `useBreakpoint` removal → 1.33.0; `useSizeClass` is shell-only (§ 1.32.0) | shell-less `shell/` gutter, `AppShell` breakpoints, `useSizeClass` for overlays (§§ Shell-less, `useSizeClass`) | — | `useBreakpoint` removed (§ 1.34.0) | — | — | `useCoarsePointer()` (§ `useCoarsePointer()`) | — | — | — | — | | content gutter 16, block 8 from `sm` (§ 1.38.1) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | `BasaltProvider` embedded mode, `spotlight` (§ 2.8.0) | — | — | — | — | — | — | — | — | — | — | — | — | — | expanded gutter 24 (§ 2.16.0) | — |
74
- | **controls** (`./controls`) | `NumberFilter`, `field.number` (§ Controls) | sheet renders panel rows; `PanelRow`, `SliderControl` (§ `basalt-ui/controls`) | — | — | — | — | — | — | — | `NumberFilter clearable`; `createSearchStore` `resets` (§ State and controls) | — | — | — | `FormSection`/`FormRow`/`FormGroup`/`FormActions` move here (§ The form layout moves) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | dense 28 tier at a fine pointer (§ 2.16.0) | — |
75
- | **forms** (`./forms`) | — | `field` → `inputProps`, **`inputProps` drops `key`**, the layout tier (§ `inputProps`) | `field` DELETED — and the `--fix` recipe no longer works (§ Consolidation) | — | — | — | — | — | `FormGroup` row no longer stretches (§ Fixes) | — | — | — | — | the layout + `useForm`/`schemaResolver` deprecated, removed 1.37.0 (§ The form layout moves) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | § 1.x compatibility layer removed | — | — | — | — | — | — | — | — | — | — | — | — | — |
76
- | **data** (`./data/table`) | — | root is a `<div>`, row selection, `getItemKey` required (§ `basalt-ui/data`) | `./data` + `./query` + `./connectivity` dropped (§ Consolidation) | — | — | — | — | — | `renderCard` documented (§ `renderCard`) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — |
77
- | **dashboard** (`.`) | `StatCard`: `unit`, `breakdown`, delta format (§ `StatCard`) | `StatGroup`, `WidgetGrid`, query-aware `StatCard` — additive | — | **the column law keys on the CONTAINER; `cols={4}` is 2-up at `sm`** (§ Dashboard) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | § 1.x compatibility layer removed | — | — | — | — | — | — | — | — | — | — | — | card inset 12/16, `kpi` 22 / 500 (§ 2.16.0) | — |
78
- | **toolchain** (`./configs/*`) | — | — | the shipped lefthook preset's `check-theme` BROKE — the CLI resolver stopped ascending (§ CLI) | the preset's default bin, and the `root:` recipe (§ Toolchain) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — |
79
- | **CLI** (`basalt-ui`) | — | — | **resolver stops relocating; `doctor` loses 6 of 10 checks** (§ CLI) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | the managed block moves `CLAUDE.md` → `AGENTS.md` (§ 1.41.0) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | `doctor`: CSS + forced dropped subpaths, `oxlint-floor`, Start wiring (§ 2.8.0) | — | § 1.x compatibility layer removed | — | — | — | — | — | — | — | — | — | — | — | — | — |
80
- | **guards** | five rules → `error` (§ Guards) | six new ids at `warn` (§ preamble) | `query-dual-import` retired in 1.29.1 (§ Guards) | four rules → `error` (§ Guards) | — | — | — | `raw-breakpoint`: the container-grid answer, `error` at 1.33.0 (§ 1.32.0) | `FormRow`/`FormGroup` homes in both lanes; `basalt-main` dropped (§ Fixes) | C1 + breakpoint pairs → `error`; `unknown-vx-token` `warn` (§ Guards) | — | — | — | `unknown-vx-token` → `error`; the token factories throw (§ Guards) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | § 1.x compatibility layer removed | — | — | — | — | — | — | — | — | — | — | — | `inline-spacing` steps, `card-inset` accepts both pairs (§ 2.16.0) | — |
69
+ | Surface | 1.27.0 | 1.28.0 | 1.29.0 | 1.30.0 | 1.30.1 | 1.30.2 | 1.31.0 | 1.32.0 | 1.32.1 | 1.33.0 | 1.34.0 | 1.34.1 | 1.35.0 | 1.36.0 | 1.36.1 | 1.37.0 | 1.37.1 | 1.38.0 | 1.38.1 | 1.39.0 | 1.40.0 | 1.40.1 | 1.40.2 | 1.40.3 | 1.41.0 | 2.0.0 | 2.0.1 | 2.0.2 | 2.0.3 | 2.0.4 | 2.0.5 | 2.1.0 | 2.2.0 | 2.3.0 | 2.4.0 | 2.5.0 | 2.6.0 | 2.6.1 | 2.7.0 | 2.7.1 | 2.7.2 | 2.7.3 | 2.8.0 | 2.8.1 | 2.9.0 | 2.9.1 | 2.10.0 | 2.11.0 | 2.11.1 | 2.12.0 | 2.13.0 | 2.13.1 | 2.13.2 | 2.13.3 | 2.14.0 | 2.15.0 | 2.16.0 | 2.17.0 | Unreleased |
70
+ | ----------------------------- | ------------------------------------------------------------ | -------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------------------- | ---------------------------------------------------------------------------------- | --------------------------------------------------------------------- | ------ | ----------------------------------------------------------------------------------------------------- | ------------------------------------------------------------------------- | --------------------------------------------------------------------------------------------------------------- | ----------------------------------------------------------------------------- | ---------------------------------- | ------ | ------ | -------------------------------------------------------------------------------------------- | ------ | ------ | ------ | ------ | ------ | ----------------------------------------------- | ------ | ------ | ------ | ------ | ------------------------------------------------------------ | ---------- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- | --- |
71
+ | **tokens** (`./tokens`) | — | `--vx-divider` → `rgba()` on both schemes (§ Shell) | `--vx-space-touch-target` added (§ Additions) | eight spacing numbers (§ Chrome) | — | — | `--vx-hit` replaces the touch vars; `SIZE_CLASSES` (§ 1.31.0) | — | `SIZE_CLASSES`/`CONTAINER_CLASSES` actually exported (§ Fixes) | `CONTAINER_GRID_BREAKPOINTS`; `raw-breakpoint` trusts it (§ 1.33.0) | `CONTAINER_KEYS` (§ 1.34.0) | — | — | — | — | — | — | — | | `appShellInset` 20 → 16 (§ 1.38.1) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | § 1.x compatibility layer removed | — | — | — | — | — | — | — | — | — | — | — | spacing, radius, type and the dense tier (§ 2.16.0) | — | — |
72
+ | **charts** (`./charts`) | — | phone tier, `curve`, formatters, `state`, log axis (§ preamble) | `ChartState.empty: string`, `AxisBottomNumeric` (§ Additions) | responsive `height`, `legend.maxRows` (§ Charts) | `height` reaches the kinds; `maxRows` beats the `fill` fit (§ Charts) | — | container-class tier + `height` keys (§ 1.31.0) | — | `ResponsiveChartHeight` `sm` → key (§ Container recipes) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | `BandSpan.absentFraction` + `absentState` (§ 2.8.0) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — |
73
+ | **shell** (`.`) | — | scrollport, region seams, **the brand left the sidebar** (§§ scrollport, brand, Shell) | `PageTitle`, `BasaltDevDock`, `useBreakpoint` (§ Additions) | More popover, aside pill, the responsive gutter, `useBasaltSpacing` (§ Chrome) | — | — | `theme.breakpoints` derived, `useSizeClass`, `data-basalt-host`, `useBreakpoint` on notice (§ 1.31.0) | `useBreakpoint` removal → 1.33.0; `useSizeClass` is shell-only (§ 1.32.0) | shell-less `shell/` gutter, `AppShell` breakpoints, `useSizeClass` for overlays (§§ Shell-less, `useSizeClass`) | — | `useBreakpoint` removed (§ 1.34.0) | — | — | `useCoarsePointer()` (§ `useCoarsePointer()`) | — | — | — | — | | content gutter 16, block 8 from `sm` (§ 1.38.1) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | `BasaltProvider` embedded mode, `spotlight` (§ 2.8.0) | — | — | — | — | — | — | — | — | — | — | — | — | — | expanded gutter 24 (§ 2.16.0) | — | — |
74
+ | **controls** (`./controls`) | `NumberFilter`, `field.number` (§ Controls) | sheet renders panel rows; `PanelRow`, `SliderControl` (§ `basalt-ui/controls`) | — | — | — | — | — | — | — | `NumberFilter clearable`; `createSearchStore` `resets` (§ State and controls) | — | — | — | `FormSection`/`FormRow`/`FormGroup`/`FormActions` move here (§ The form layout moves) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | dense 28 tier at a fine pointer (§ 2.16.0) | — | — |
75
+ | **forms** (`./forms`) | — | `field` → `inputProps`, **`inputProps` drops `key`**, the layout tier (§ `inputProps`) | `field` DELETED — and the `--fix` recipe no longer works (§ Consolidation) | — | — | — | — | — | `FormGroup` row no longer stretches (§ Fixes) | — | — | — | — | the layout + `useForm`/`schemaResolver` deprecated, removed 1.37.0 (§ The form layout moves) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | § 1.x compatibility layer removed | — | — | — | — | — | — | — | — | — | — | — | — | — | — |
76
+ | **data** (`./data/table`) | — | root is a `<div>`, row selection, `getItemKey` required (§ `basalt-ui/data`) | `./data` + `./query` + `./connectivity` dropped (§ Consolidation) | — | — | — | — | — | `renderCard` documented (§ `renderCard`) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — |
77
+ | **dashboard** (`.`) | `StatCard`: `unit`, `breakdown`, delta format (§ `StatCard`) | `StatGroup`, `WidgetGrid`, query-aware `StatCard` — additive | — | **the column law keys on the CONTAINER; `cols={4}` is 2-up at `sm`** (§ Dashboard) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | § 1.x compatibility layer removed | — | — | — | — | — | — | — | — | — | — | — | card inset 12/16, `kpi` 22 / 500 (§ 2.16.0) | — | — |
78
+ | **toolchain** (`./configs/*`) | — | — | the shipped lefthook preset's `check-theme` BROKE — the CLI resolver stopped ascending (§ CLI) | the preset's default bin, and the `root:` recipe (§ Toolchain) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — |
79
+ | **CLI** (`basalt-ui`) | — | — | **resolver stops relocating; `doctor` loses 6 of 10 checks** (§ CLI) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | the managed block moves `CLAUDE.md` → `AGENTS.md` (§ 1.41.0) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | `doctor`: CSS + forced dropped subpaths, `oxlint-floor`, Start wiring (§ 2.8.0) | — | § 1.x compatibility layer removed | — | — | — | — | — | — | — | — | — | — | — | — | — | — |
80
+ | **guards** | five rules → `error` (§ Guards) | six new ids at `warn` (§ preamble) | `query-dual-import` retired in 1.29.1 (§ Guards) | four rules → `error` (§ Guards) | — | — | — | `raw-breakpoint`: the container-grid answer, `error` at 1.33.0 (§ 1.32.0) | `FormRow`/`FormGroup` homes in both lanes; `basalt-main` dropped (§ Fixes) | C1 + breakpoint pairs → `error`; `unknown-vx-token` `warn` (§ Guards) | — | — | — | `unknown-vx-token` → `error`; the token factories throw (§ Guards) | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | — | § 1.x compatibility layer removed | — | — | — | — | — | — | — | — | — | — | — | `inline-spacing` steps, `card-inset` accepts both pairs (§ 2.16.0) | — | — |
81
81
 
82
82
  ---
83
83
 
@@ -1046,6 +1046,92 @@ The `basalt-ui/router-tanstack` subpath is **removed** in 2.x, not moved: an imp
1046
1046
  _Nothing yet. Author the next section under this heading as `## Unreleased — <title>`; the
1047
1047
  release renames it and opens a new one here._
1048
1048
 
1049
+ ## 2.17.0 — the metric card and chrome
1050
+
1051
+ Wave 33 of the design-parity track (`docs/waves/design-parity/SPEC.md` § 6.10, § 6.12). No export is
1052
+ added, removed or renamed; three theme defaults change, each with a one-prop way back.
1053
+
1054
+ - **Grace extended: `basalt/card-inset`, `raw-spacing` and `inline-spacing` stay `warn` until 2.24.0** (they were dated 2.17.0). No consumer has run 2.16 yet, so promoting them now would skip their warn period. They become `error` at the fleet rollout.
1055
+
1056
+ ### Badge, subtle Button, Tabs
1057
+
1058
+ | What | Old | New | Opt out |
1059
+ | ------------------------------- | -------------------------------------- | --------------------------------------------------------- | -------------------------------------------------------------------- |
1060
+ | `Badge` default variant | `filled` (accent fill, on-colour text) | `light` (13% status tint, ink-pulled text) | `variant="filled"` |
1061
+ | `Badge` default colour | the primary colour (accent tint) | `gray` (neutral tint); the accent is not a status default | a Badge that relied on the accent default passes `color="<primary>"` |
1062
+ | `Badge` radius | `ctrl` (6 at level 0) | `tight` (5 at level 0; follows the `radius` knob) | `radius="md"` |
1063
+ | `Badge` leading glyph | Mantine's section, 4px gap, unsized | `leftSection` svg is 12px, 4px gap, centred at 20 high | `classNames={{ section: … }}` override |
1064
+ | `Button variant="subtle"` label | accent ink | neutral ink (`--vx-ink`) | `color="blue"` (any explicit colour) |
1065
+ | `Tabs` active underline | accent (`--tabs-color`) | ink (`--vx-ink`) | `color="blue"` on `Tabs` |
1066
+
1067
+ - `Badge` height stays 20 (Mantine `md`). `filled` remains right for a count on an accent surface.
1068
+ - The subtle opt-out is any explicit `color` prop, the primary colour included. An explicit colour
1069
+ keeps Mantine's own tinted label **and hover**: the ink-6% hover (1.x–2.16) now applies only to a
1070
+ subtle control that names no colour, so `color="blue"` hovers into the accent tint again.
1071
+ - `Tabs variant="pills"` is untouched: it fills with the colour, so it keeps the accent.
1072
+
1073
+ ### StatCard and Sparkline
1074
+
1075
+ Wave 33 of the design-parity track restyles the metric card (`docs/waves/design-parity/SPEC.md` § 6.1, § 6.2) and flips the `Sparkline` defaults. No export is removed or renamed, but **the `state` field of the `StatCardSparklineSize` type is removed** and the defaults and the card's anatomy change.
1076
+
1077
+ | What | Old | New | Opt-out / replacement |
1078
+ | ----------------------------- | --------------------------------------------------------------------------------- | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------ |
1079
+ | `Sparkline` `emphasizeLast` | `false` (no end dot) | `true` | `emphasizeLast={false}` |
1080
+ | `Sparkline` `emphasisColor` | `VX.accent` | `VX.line` (the line's own neutral) | `emphasisColor={VX.accent}`, or a status / trend colour |
1081
+ | `Sparkline` stroke | 1.6 | 1.5 | none |
1082
+ | `StatCard` composition | composed `WidgetHeader tier="widget"` (head-font title, merged title row ≥ 480) | renders its own caption row, value row and foot; `WidgetHeader`, `Section` and `ChartCard` are unchanged | `classNames.header` still reaches the caption + value block; there is no `WidgetHeader` slot to target |
1083
+ | `StatCard` `title` | head-font heading | mono uppercase `micro` caption, faint ink | none (`ChartCard` keeps its head-font title) |
1084
+ | `StatCard` `subtitle` | muted line under the title; folded into the info glyph below 480 px | **one muted `sm` line in the foot, under the visual, at every width**; ellipsized, full text in `title` | a period or target → the new `qualifier`; a method → `info`; a source or "as of" stays in `subtitle` |
1085
+ | `StatCard` `qualifier` | — | new `string`: `micro` muted, right-aligned on the caption row; when caption and qualifier do not fit it takes its own line under the caption, left-aligned, and breaks its words only if it alone exceeds the card | keep it on one line by shortening the copy |
1086
+ | `StatCard` value row | delta on the title row from 480 px | figure, `unit` inline at `sm` muted, then the delta, in one row at every width | none |
1087
+ | `StatCard` sparkline slot | 26 px, bled through the card bottom | 22 px (`'right'` slot 72×22), bled to the side edges, in the foot above the footer; the render prop receives `height: 22` | none |
1088
+ | `StatCard` footprint | height followed content | the foot reserves 22 + 4 + 20 px when a `sparkline` (bleed) or `subtitle` exists, so cards with and without either share a height; `'right'` keeps its 72×22 slot while pending | none |
1089
+ | `StatCard` `query` | `QueryState` wrapped the breakdown only; pending was a spinner, empty was blank | resolved by `resolveQueryBranch` (error > pending > empty > ready): pending is a skeleton at the card's footprint, empty is one muted line, error is `QueryState`'s error + Retry in place of the figure | `value` needs no `'—'` placeholder while pending |
1090
+ | `StatCard` `emptyText` | — | new `string`, default `No data for this period` | pass your own sentence that says why it is empty |
1091
+ | `StatCard` `loading` | — | new `boolean`: the same skeleton with no query, with a visually hidden `Loading <title>` and `aria-busy` | — |
1092
+ | `StatCardSparklineSize.state` | the query as a chart state, so `<Sparkline {...size} />` drew its own placeholder | **removed**: the card shows its own skeleton / error / empty branch and never calls the render prop outside `ready` | spread `size` as before; the placeholder is now the card's branch, not the chart's |
1093
+ | `DeltaBadge` / `deltaPeriod` | status colour on a 13 % tint, padding, control radius | text only: glyph and signed figure in `var(--vx-status-good\|bad)` (or `--vx-faint` for zero / neutral), no fill, no padding; `deltaPeriod` is `micro` muted | none |
1094
+ | `DeltaBadge` glyph | 0.8 em of its parent (9.6 px) | the `micro` rung (11 px) | none |
1095
+
1096
+ - **Behaviour: the delta is text only.** `DeltaBadge` paints no background in either scheme (DESIGN-CORE: "deltas are text colour only, never a fill"), so it reads the derived status token directly. `Section` and `WidgetHeader` deltas follow, since they render the same `DeltaBadge`.
1097
+ - **Behaviour: two status solids moved so the text clears 4.5:1.** With no tint behind it, the delta (and a toned `breakdown` row) is judged on the card surface. At the default seed `status.warn` (light) goes from tone 54.64 to 46 and `status.bad` (dark) from 58.58 to 66.5; hue and chroma are untouched. Every other use of those two solids (tone rail, ref lines, zone bands, the on-colour text on a status fill) reads the new hexes. `derive.test.ts` proves ≥ 4.5:1 for good / warn / bad on every text surface **at the default derive config only**; a retuned `derive` (`lightLevel`, `darkLevel`, `neutral`) is not covered by that proof.
1098
+ - **Behaviour: the `info` bubble is placed in the viewport.** It is portalled to `<body>` with `position: fixed`, opens below the glyph, flips above at the bottom edge and shifts off the left / right edges, so a card's `overflow: hidden` can no longer clip it (W32 rounds 0-3 at 390). `InfoGlyph` is shared, so `ChartCard`, `Section` and the inspector row `hint` get the same bubble. **Tests that looked for the bubble inside the card should query `document.body`** (`getByRole('tooltip')` is unaffected). A folded subtitle's note inside the bubble is revealed from the bubble's own `data-folded`.
1099
+ - **Migrating a card:** `<StatCard title="Revenue" subtitle="Trailing 30 days" …/>` becomes `<StatCard title="Revenue" qualifier="30 days" subtitle="Source: billing" …/>` — the period moves to `qualifier`, and `subtitle` is kept only for a source or "as of" line that does not restate the caption. Drop `icon` (it stays a prop; the recipe leaves it off).
1100
+ - **Migrating a sparkline:** a `Sparkline` that relied on the bare line now draws an end dot in the line neutral — pass `emphasizeLast={false}`. One that passed `emphasizeLast` alone drew a `VX.accent` dot; it now draws `VX.line`, so pass `emphasisColor={VX.accent}` to keep the accent (or a status colour where the end value carries a verdict).
1101
+
1102
+ ### Date ticks
1103
+
1104
+ The default x tick labels of a Date axis (`CartesianChart`, so `Lines`, `Bars`, `StackedArea`) follow
1105
+ the tick step instead of printing `DD.MM` everywhere, and never repeat on one axis. Reads stay UTC.
1106
+
1107
+ | Tick step | Old | New |
1108
+ | --------- | --------------------- | -------------------------------------------------------------------------- |
1109
+ | sub-day | `17.10`, `17.10`, ... | `HH:MM`, `DD.MM` on each midnight tick (`12:00, 18:00, 18.10, 06:00, ...`) |
1110
+ | days | `DD.MM` | `DD.MM` (unchanged) |
1111
+ | months+ | `DD.MM` | `Oct`, the year on each January (`2027`) |
1112
+
1113
+ A clock or month may recur on one axis, always behind a day or year label. With no such marker in
1114
+ reach (36 h with no midnight tick; two Aprils with no January) the first tick of each day carries
1115
+ its date (`17.10 06:00`), or the month its year (`Apr 2026`); sub-minute steps add seconds, then
1116
+ milliseconds. `BandStrip`, `DualPanel` and `MirroredBars` take the same default (they printed
1117
+ `DD.MM`).
1118
+
1119
+ Opt out: pass `formatX` (it always wins), e.g. the old one-liner:
1120
+
1121
+ ```ts
1122
+ const ddmm = (d: Date) =>
1123
+ `${String(d.getUTCDate()).padStart(2, '0')}.${String(d.getUTCMonth() + 1).padStart(2, '0')}`
1124
+ <Lines formatX={ddmm} … />
1125
+ ```
1126
+
1127
+ | Hover readout selector | Old | New |
1128
+ | ---------------------------------- | ----------------- | ----------------------------------- |
1129
+ | `.ts-chart-tooltip[role="status"]` | the engine's role | `.ts-chart-tooltip[role="tooltip"]` |
1130
+
1131
+ The hover readout now carries `role="tooltip"` (it was the engine's `role="status"`) and keeps
1132
+ `aria-live="polite"` on purpose: a tooltip role alone is not announced, and keyboard users should still
1133
+ hear the reading; a test that queried `.ts-chart-tooltip[role="status"]` must follow. `Donut`'s and `Heatmap`'s readouts follow.
1134
+
1049
1135
  ## 2.16.0 — the even-pixel grid
1050
1136
 
1051
1137
  Wave 32 of the design-parity track moves the spacing, inset, radius and type scales onto an
@@ -1074,7 +1160,7 @@ number below changes at level 0**, so a layout that was tuned against the old sc
1074
1160
 
1075
1161
  - **Behaviour: spacing props and `--mantine-spacing-*` reads shrink.** `p="xs"` is 8 (was 11), `"sm"` 12 (was 13), `"md"` 16 (was 18), `"xl"` 24 (was 26); `"lg"` is unchanged. Hand-written `px={18}` / `gap={26}` no longer equal a step, and `raw-spacing` reports them.
1076
1162
  - **Behaviour: the CSS sub-scale ceiling of `inline-spacing` drops from 10px to 7px** (it sits one below the smallest stop, now 8). A CSS `padding: 8px` or `10px` is now a finding; 2 / 4 / 6px clusters stay legal.
1077
- - **Behaviour: `basalt/card-inset` is strict.** The only accepted inset is the pair `py="sm" px="md"` (12/16) or leaving both to the theme. Uniform `p`/`padding` (any value) and every other pair, including the old `py="xs" px="sm"` (now 8/12), are findings. **Severity: `warn` for this minor, `error` from 2.17.0** (`PLUGIN_RULE_GRACE`, one entry for the rule); that also demotes the rule's older findings (explicit `radius`, `p="lg"`) to `warn` for the minor, because a level is per rule id. Also flagged now: numeric or non-literal `py`/`px`, and a lone `py="sm"` or `px="md"` without its partner. Move each `<Card py="xs" px="sm">` to `py="sm" px="md"`.
1163
+ - **Behaviour: `basalt/card-inset` is strict.** The only accepted inset is the pair `py="sm" px="md"` (12/16) or leaving both to the theme. Uniform `p`/`padding` (any value) and every other pair, including the old `py="xs" px="sm"` (now 8/12), are findings. **Severity: `warn` for this minor, `error` from 2.24.0** (re-dated in 2.17.0) (`PLUGIN_RULE_GRACE`, one entry for the rule); that also demotes the rule's older findings (explicit `radius`, `p="lg"`) to `warn` for the minor, because a level is per rule id. Also flagged now: numeric or non-literal `py`/`px`, and a lone `py="sm"` or `px="md"` without its partner. Move each `<Card py="xs" px="sm">` to `py="sm" px="md"`.
1078
1164
  - **Behaviour: the compact card inset reads `--vx-space-card-inset-x` below `sm`**, and `StatCard`'s full-bleed sparkline now bleeds by the card inset tokens rather than the `sm`/`xs` scale stops, so the bleed matches the inset at every width.
1079
1165
  - **Behaviour: the `SegmentedControl` concentricity law restated.** `RADIUS.card === RADIUS_STEP.tight + segmentedTrackInset` could not hold at card 10, so the track now takes the control radius and the indicator the `fine` tier: `RADIUS.ctrl === RADIUS_STEP.fine + 2`, exact down to `radius: -4` (at `-5`, `fine` clamps to 0 against a 1px track).
1080
1166
  - **Behaviour: `shot` `metrics.json` `radius` may be the string `"full"`** (also on `nested[]`) for a fully rounded box (a `50%` circle or `9999px` pill); it was the number `50` or `9999`. A consumer reading it as a number checks the type first.
@@ -1085,7 +1171,7 @@ number below changes at level 0**, so a layout that was tuned against the old sc
1085
1171
 
1086
1172
  ### Migrating the guards
1087
1173
 
1088
- `raw-spacing` and `inline-spacing` ship at **`warn` for this minor and `error` from 2.17.0** (`GRACE_PERIOD_KINDS`, since 2.16.0): their steps follow the new scale, so after the upgrade `p={16}` and `gap={24}` are findings (use `"md"` / `"xl"`) and `p={18}` / `gap={26}` are no longer flagged. To migrate on your own schedule, in the consumer's `package.json`:
1174
+ `raw-spacing` and `inline-spacing` ship at **`warn` for this minor and `error` from 2.24.0** (re-dated in 2.17.0) (`GRACE_PERIOD_KINDS`, since 2.16.0): their steps follow the new scale, so after the upgrade `p={16}` and `gap={24}` are findings (use `"md"` / `"xl"`) and `p={18}` / `gap={26}` are no longer flagged. To migrate on your own schedule, in the consumer's `package.json`:
1089
1175
 
1090
1176
  ```json
1091
1177
  "basalt": {
@@ -1094,7 +1180,7 @@ number below changes at level 0**, so a layout that was tuned against the old sc
1094
1180
  }
1095
1181
  ```
1096
1182
 
1097
- `spacingSteps` keeps the guard on the old numbers (matching a scale you have not moved off yet); `severity` pins both at `warn` past 2.17.0, when the grace entries are deleted and they become `error`. Drop both once the call sites read tokens. The CSS sub-scale ceiling (10 → 7px: a CSS `padding: 8px` or `10px` is now a finding) has no switch of its own; it rides on `inline-spacing`'s severity.
1183
+ `spacingSteps` keeps the guard on the old numbers (matching a scale you have not moved off yet); `severity` pins both at `warn` past 2.24.0, when the grace entries are deleted and they become `error`. Drop both once the call sites read tokens. The CSS sub-scale ceiling (10 → 7px: a CSS `padding: 8px` or `10px` is now a finding) has no switch of its own; it rides on `inline-spacing`'s severity.
1098
1184
 
1099
1185
  ### Restoring the old feel
1100
1186
 
@@ -35,7 +35,7 @@ Score per component, then add one line per page for the page items (Communicatio
35
35
  1. **[measured]** Every inset, gap and radius is a step in `metrics.json` `scale`; nested surfaces step by at least 3 px of radius. No `scale` → `unverified`. Never invent steps.
36
36
  2. **[measured]** No more than three font sizes inside one component: `fontSizes` with more than 3 distinct values fails.
37
37
  3. No empty region of 40 % or more of the component's height — **[measured]**: `emptyRatio` ≥ 0.4 fails; no dense-list row wraps at 390 — judged from the 390 crop.
38
- 4. One ring per surface, no bare hairline borders on cards, no accent on chrome: look at every crop for an accent hue on a tab underline, a selected row, a secondary button, a card ring or a solid-filled badge. The accent sites are the primary data series, active-nav icons and active child labels, links, primary buttons, focus rings and the leader bar in meters; chrome (borders, inactive states, backgrounds, general icons) stays neutral, and selection state (active nav row, selected tab) never takes the accent.
38
+ 4. One ring per surface, no bare hairline borders on cards, no accent on chrome: look at every crop for an accent hue on a tab underline, a selected row, a secondary button, a card ring or a solid-filled badge. The accent sites are the primary data series, active-nav icons and active child labels, links, primary buttons, focus rings and the leader bar in meters; chrome (borders, inactive states, backgrounds, general icons) stays neutral, and selection state (active nav row, selected tab) never takes the accent. A card's `tone` verdict rail is a status, not chrome.
39
39
  5. **[measured]** Text and meaningful marks meet contrast in both schemes (a non-empty `contrast.failures` fails); nothing is told apart only by colour.
40
40
  6. Nothing overflows, clips or truncates a value at 1440 or 390.
41
41
  7. Hover, focus and tooltip states are present in the shots; focus is the 2 px outline.
@@ -44,7 +44,7 @@ Score per component, then add one line per page for the page items (Communicatio
44
44
 
45
45
  1. Name the data's shape and the encoding used; both must match a row of the encoding table (the catalogue) in the `/basalt-design` skill.
46
46
  2. Every visual answers the question its caption names; a decorative visual fails.
47
- 3. A hue appears only for a trend, a status or a category; a single metric is neutral. A delta is neutral text with a trend glyph: a solid-filled badge or coloured fill on a delta fails here and Craft 4.
47
+ 3. A hue appears only for a trend, a status or a category; a single metric is neutral. A delta is text in its trend colour with a direction glyph and no fill: a fill or a badge on a delta fails here and Craft 4.
48
48
  4. A number with a target shows the target; a number with a history shows it; a whole with parts shows the parts.
49
49
  5. No axis repeats a label; ticks fit the span.
50
50
 
@@ -14,7 +14,7 @@ Method only; the law is `.claude/rules/basalt-*.md` and `./DESIGN.md`.
14
14
 
15
15
  | Data shape | Encoding | Component |
16
16
  | ----------------------------- | ------------------------------------------------------------------------------------------------------- | ------------------------------------------- |
17
- | Single value with a trend | figure, text delta, axis-less sparkline along the card's bottom | `StatCard` + `sparkline` slot (`Sparkline`) |
17
+ | Single value with a trend | figure, text delta, `qualifier`, axis-less sparkline (end dot) along the card's bottom | `StatCard` + `sparkline` slot (`Sparkline`) |
18
18
  | Value over time | line or stacked area | `Lines` / `StackedArea` in a `ChartCard` |
19
19
  | Compare categories | bars | `Bars layout="grouped"` |
20
20
  | Part of a whole, 2–6 parts | one segmented (stacked) bar, parts in order — not a donut plus a total card, not a row of N `StatCard`s | `Bars` (stacked, the default) |
@@ -26,7 +26,7 @@ Method only; the law is `.claude/rules/basalt-*.md` and `./DESIGN.md`.
26
26
  No row fits the data → say so; never default to a number in a box.
27
27
 
28
28
  4. Build with Mantine primitives and the composites; every color from `VX.*` or a series token. Tune by eye in the theme lab (`dev.theme` Spotlight command, dev only) in both schemes, then bake values into the `derive` knobs of `createBasaltTheme` and series colors into `src/lib/series.ts`.
29
- 5. **Mark up for the board.** Tag each scored component `data-shot="<name>"`; hover and tooltip targets inside it get `data-shot-hover` / `data-shot-tooltip`. Declare supported states with `data-shot-states="empty loading error"` and render them when the `shot-state` URL param asks.
29
+ 5. **Mark up for the board.** Tag each scored component `data-shot="<name>"`; hover and tooltip targets inside it get `data-shot-hover` / `data-shot-tooltip`; when the target's centre paints no readout (a donut's hole), add `data-shot-at="x,y"` (fractions of its box, e.g. `0.25,0.2`) and the shot hovers there. Declare supported states with `data-shot-states="empty loading error"` and render them when the `shot-state` URL param asks.
30
30
  6. **Rounds, at least three.** Playwright is the app's dev dependency: `bun add -d playwright && bunx playwright install chromium`. Then:
31
31
  - `basalt-ui shot <routes> --dist <built app>` (or `--base <url>` for a running server);
32
32
  - hand the out dir (`.basalt/shots`) to the `basalt-design-reviewer` subagent by name; it reads each component's contact sheet (`png/*__sheet.png`) and every page shot;
@@ -606,7 +606,7 @@ function attrValue(attr) {
606
606
  return unwrapExpressionContainer(attr.value)
607
607
  }
608
608
 
609
- // Ships: warn (grace → 2.17.0)
609
+ // Ships: warn (grace → 2.24.0)
610
610
  const cardInset = {
611
611
  meta: {
612
612
  type: 'suggestion',
@@ -4224,7 +4224,7 @@ const routeViewTransition = {
4224
4224
  export const PLUGIN_RULE_GRACE = {
4225
4225
  'card-inset': {
4226
4226
  since: '2.16.0',
4227
- promote: '2.17.0',
4227
+ promote: '2.24.0',
4228
4228
  why: 'Tightened in 2.16.0: only py="sm" px="md" together (or neither) passes; uniform p/padding, a lone half, numbers and expressions are findings.',
4229
4229
  },
4230
4230
  }
@@ -1 +1 @@
1
- {"version":3,"file":"Donut.d.ts","sourceRoot":"","sources":["../../src/charts/Donut.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAiB,YAAY,EAAE,MAAM,OAAO,CAAA;AACxD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAA;AAUlD,OAAO,KAAK,EAAe,UAAU,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAA;AAE7E,MAAM,MAAM,UAAU,CAAC,CAAC,SAAS,MAAM,GAAG,MAAM,IAAI;IAAE,GAAG,EAAE,CAAC,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAA;AAE7E,MAAM,MAAM,UAAU,CAAC,CAAC,SAAS,MAAM,GAAG,MAAM,IAAI,WAAW,GAAG;IAChE,qCAAqC;IACrC,SAAS,EAAE,MAAM,CAAA;IACjB,IAAI,EAAE,SAAS,UAAU,CAAC,CAAC,CAAC,EAAE,CAAA;IAC9B,uDAAuD;IACvD,WAAW,EAAE,CAAC,GAAG,EAAE,CAAC,KAAK,MAAM,CAAA;IAC/B,WAAW,EAAE,CAAC,CAAC,EAAE,MAAM,KAAK,MAAM,CAAA;IAClC,4DAA4D;IAC5D,WAAW,CAAC,EAAE,CAAC,CAAC,GAAG,EAAE,CAAC,KAAK,MAAM,CAAC,GAAG,SAAS,CAAA;IAC9C,6DAA6D;IAC7D,WAAW,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA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G,SAAS,CAAA;IACnC,mBAAmB;IACnB,MAAM,CAAC,EAAE,MAAM,GAAG,qBAAqB,GAAG,SAAS,CAAA;IACnD,KAAK,CAAC,EAAE,UAAU,GAAG,SAAS,CAAA;CAC/B,CAAA;AAkED,wBAAgB,KAAK,CAAC,CAAC,SAAS,MAAM,GAAG,MAAM,EAAE,KAAK,EAAE,UAAU,CAAC,CAAC,CAAC,GAAG,YAAY,CAkJnF"}
@@ -1,9 +1,9 @@
1
1
  import { jsx, jsxs } from "react/jsx-runtime";
2
- import { tooltip as tooltipHost } from "@tanstack/charts/tooltip";
3
2
  import { portal } from "@tanstack/charts/tooltip/portal";
4
3
  import { pie, polar, radialArc } from "@tanstack/charts/polar";
5
4
  import { useCallback, useId, useMemo, useState } from "react";
6
5
  import { alpha, VX } from "../tokens/index.js";
6
+ import { engineTooltip } from "./cursor.js";
7
7
  import { ChartEngine, idPrefixOf } from "./host.js";
8
8
  import { ChartLegend } from "./legend.js";
9
9
  import { useCoarsePointer } from "../common/use-media-query.js";
@@ -121,7 +121,7 @@ function Donut(props) {
121
121
  theme: CHART_THEME
122
122
  }),
123
123
  tooltip: {
124
- use: tooltipHost,
124
+ use: engineTooltip,
125
125
  portal,
126
126
  content: (points) => {
127
127
  const slice = points[0]?.datum;
@@ -7,7 +7,7 @@ import { scaleUtc } from "d3-scale";
7
7
  import { useCallback, useMemo } from "react";
8
8
  import { VX, alpha } from "../tokens/index.js";
9
9
  import { resolveContainerClass } from "../tokens/size-classes.js";
10
- import { defaultFormatX, defaultNumberFormat, engineRow, seriesRow, visibleSeries } from "./compile.js";
10
+ import { defaultNumberFormat, engineRow, seriesRow, visibleSeries } from "./compile.js";
11
11
  import { barMark, emphasis, lineMark, markersOf, thinFill } from "./marks.js";
12
12
  import { PanelRung, chartHeightOf, paneX, paneY, rowsOf } from "./panel.js";
13
13
  import { plotContext } from "./plot-context.js";
@@ -71,7 +71,7 @@ function DualPanel(props) {
71
71
  const pad = model.step / 2;
72
72
  const xScale = () => model.kind === "date" ? scaleUtc().domain([new Date(lo - pad), new Date(hi + pad)]) : scaleLinear().domain([lo - pad, hi + pad]);
73
73
  const fillAt = (v) => ((v instanceof Date ? v.getTime() : v) - (lo - pad)) / (hi - lo + 2 * pad);
74
- const format = (v) => formatX ? formatX(v) : defaultFormatX(v);
74
+ const format = formatX ? (v) => formatX(v) : void 0;
75
75
  const visible = visibleSeries(lines, hidden);
76
76
  const barOn = !hidden.has(BAR_KEY);
77
77
  const rows = (s) => visible.includes(s) ? rowsOf(data, x, s) : [];
@@ -1 +1 @@
1
- {"version":3,"file":"Heatmap.d.ts","sourceRoot":"","sources":["../../src/charts/Heatmap.tsx"],"names":[],"mappings":"AAiBA,OAAO,KAAK,EAAiB,YAAY,EAAE,MAAM,OAAO,CAAA;AACxD,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAA;AAMlD,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,aAAa,CAAA;AAQlD,OAAO,KAAK,EAAe,UAAU,EAAE,eAAe,EAAE,qBAAqB,EAAE,MAAM,SAAS,CAAA;AAE9F;;;;;GAKG;AACH,MAAM,MAAM,YAAY,CAAC,CAAC,SAAS,MAAM,GAAG,MAAM,IAAI,IAAI,CAAC,eAAe,EAAE,KAAK,GAAG,SAAS,CAAC,GAAG;IAC/F,GAAG,EAAE,CAAC,CAAA;CACP,CAAA;AAED,MAAM,MAAM,YAAY,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,GAAG,MAAM,IAAI,WAAW,GAAG;IACrE,qCAAqC;IACrC,SAAS,EAAE,MAAM,CAAA;IACjB,IAAI,EAAE,SAAS,CAAC,EAAE,CAAA;IAClB,qCAAqC;IACrC,MAAM,EAAE,CAAC,CAAC,EAAE,CAAC,KAAK,MAAM,CAAA;IACxB,wCAAwC;IACxC,MAAM,EAAE,CAAC,CAAC,EAAE,CAAC,KAAK,MAAM,CAAA;IACxB,4EAA4E;IAC5E,QAAQ,EAAE,CAAC,CAAC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I,CAAC,EAAE,CAAC,CAAC,CAAC,EAAE,CAAC,KAAK,SAAS,eAAe,EAAE,CAAC,GAAG,SAAS,CAAA;QACzD,8CAA8C;QAC9C,UAAU,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;KAChC,CACJ,GACD,SAAS,CAAA;IACb,qFAAqF;IACrF,MAAM,CAAC,EAAE,MAAM,GAAG,qBAAqB,GAAG,SAAS,CAAA;IACnD;;wGAEoG;IACpG,WAAW,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IACjC,KAAK,CAAC,EAAE,UAAU,GAAG,SAAS,CAAA;CAC/B,CAAA;AA0CD,wBAAgB,OAAO,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,GAAG,MAAM,EAAE,KAAK,EAAE,YAAY,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG,YAAY,CAwP7F"}
@@ -2,7 +2,6 @@ import { jsx, jsxs } from "react/jsx-runtime";
2
2
  import { colorGradientLegend } from "@tanstack/charts/legend";
3
3
  import { cell } from "@tanstack/charts/rect";
4
4
  import { scaleBand } from "@tanstack/charts/scales/band";
5
- import { tooltip as tooltipHost } from "@tanstack/charts/tooltip";
6
5
  import { portal } from "@tanstack/charts/tooltip/portal";
7
6
  import { scaleQuantize } from "d3-scale";
8
7
  import { useId, useMemo } from "react";
@@ -11,6 +10,7 @@ import { resolveContainerClass } from "../tokens/size-classes.js";
11
10
  import { engineRow, strideTicks } from "./compile.js";
12
11
  import { resolveNamedState } from "./band-fold.js";
13
12
  import { ABSENT_OPACITY, RAMP_LEVELS, RAMP_OPACITIES } from "./heatmap-fill.js";
13
+ import { engineTooltip } from "./cursor.js";
14
14
  import { ChartEngine, idPrefixOf } from "./host.js";
15
15
  import { ChartLegend } from "./legend.js";
16
16
  import { useCoarsePointer } from "../common/use-media-query.js";
@@ -113,7 +113,7 @@ function Heatmap(props) {
113
113
  const header = (c) => `${formatRow(c.row)} \xB7 ${formatCol(c.col)}`;
114
114
  const cellMark = (id, group, paint) => cell(group, { id, x: "col", y: "row", inset: CELL_INSET, key: "id", ...paint });
115
115
  const tooltipOptions = showTooltip ? {
116
- use: tooltipHost,
116
+ use: engineTooltip,
117
117
  portal,
118
118
  content: (points) => {
119
119
  const point = points[0];
@@ -6,7 +6,7 @@ import { scaleLinear } from "@tanstack/charts/scales/linear";
6
6
  import { useCallback, useMemo } from "react";
7
7
  import { VX, alpha } from "../tokens/index.js";
8
8
  import { resolveContainerClass } from "../tokens/size-classes.js";
9
- import { defaultFormatX, defaultNumberFormat, seriesRow, visibleSeries } from "./compile.js";
9
+ import { defaultNumberFormat, seriesRow, visibleSeries } from "./compile.js";
10
10
  import { barMark, emphasis } from "./marks.js";
11
11
  import { PanelRung, chartHeightOf, paneX, paneY, rowsOf } from "./panel.js";
12
12
  import { xScaleFor } from "./scales.js";
@@ -82,7 +82,7 @@ function MirroredBars(props) {
82
82
  const absentFill = absentEntry ? alpha(absentEntry.color, absentEntry.fillOpacity ?? 1) : VX.neutral;
83
83
  const upOn = visible.includes(upSeries);
84
84
  const downOn = visible.includes(downSeries);
85
- const format = (v) => formatX ? formatX(v) : defaultFormatX(v);
85
+ const format = formatX ? (v) => formatX(v) : void 0;
86
86
  const upMax = paneMax(up, upSeries, drawn, upOn);
87
87
  const downMax = paneMax(down, downSeries, drawn, downOn);
88
88
  const bandWidth = 2 * model.halfStep * BAND_FILL;
@@ -13,9 +13,11 @@ export type SparklineProps = BasaltProps & {
13
13
  mark?: 'line' | 'bar' | undefined;
14
14
  /** A `VX.*` ref or a series token. Default `VX.faint`. */
15
15
  color?: string | undefined;
16
- /** Paints the last point in `emphasisColor` — the one reading a trend beside a KPI is for. */
16
+ /** Paints the last point in `emphasisColor` — the one reading a trend beside a KPI is for.
17
+ * Default `true`; pass `false` for a bare line. */
17
18
  emphasizeLast?: boolean | undefined;
18
- /** Default `VX.accent`. */
19
+ /** Default `VX.line`, the line's own neutral, so a single metric stays neutral. Pass a status or
20
+ * trend colour to make the end dot carry a verdict. */
19
21
  emphasisColor?: string | undefined;
20
22
  /** Pending / error / empty, the same contract as every other kind. The placeholder fills the
21
23
  * sparkline's own `width` × `height`, so a loading tile does not shift when the trend lands. */
@@ -1 +1 @@
1
- {"version":3,"file":"Sparkline.d.ts","sourceRoot":"","sources":["../../src/charts/Sparkline.tsx"],"names":[],"mappings":"AAaA,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,OAAO,CAAA;AACzC,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,iBAAiB,CAAA;AAQlD,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,SAAS,CAAA;AAEzC,MAAM,MAAM,cAAc,GAAG,WAAW,GAAG;IACzC,gFAAgF;IAChF,SAAS,EAAE,MAAM,CAAA;IACjB,IAAI,EAAE,SAAS,MAAM,EAAE,CAAA;IACvB,oBAAoB;IACpB,MAAM,EAAE,MAAM,CAAA;IACd,mEAAmE;IACnE,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IAC1B,wBAAwB;IACxB,IAAI,CAAC,EAAE,MAAM,GAAG,KAAK,GAAG,SAAS,CAAA;IACjC,0DAA0D;IAC1D,KAAK,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IAC1B,8FAA8F;IAC9F,aAAa,CAAC,EAAE,OAAO,GAAG,SAAS,CAAA;IACnC,2BAA2B;IAC3B,aAAa,CAAC,EAAE,MAAM,GAAG,SAAS,CAAA;IAClC;oGACgG;IAChG,KAAK,CAAC,EAAE,UAAU,GAAG,SAAS,CAAA;CAC/B,CAAA;AAED,KAAK,KAAK,GAAG;IAAE,CAAC,EAAE,MAAM,CAAC;IAAC,CAAC,EAAE,MAAM,GAAG,IAAI,CAAA;CAAE,CAAA;AAwG5C;;;;;GAKG;AACH,wBAAgB,aAAa,CAC3B,IAAI,EAAE,SAAS,KAAK,EAAE,EACtB,KAAK,EAAE,MAAM,EACb,IAAI,EAAE,MAAM,GAAG,KAAK,GACnB,SAAS,KAAK,EAAE,CAIlB;AA8ED,qEA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YAAY,CAyC7D"}
@@ -11,7 +11,7 @@ import { barMark } from "./marks.js";
11
11
  import { ChartEngine, idPrefixOf } from "./host.js";
12
12
  import { ChartPlaceholder, resolveChartState } from "./state.js";
13
13
  import { CHART_THEME } from "./theme.js";
14
- const LINE_WIDTH = 1.6;
14
+ const LINE_WIDTH = 1.5;
15
15
  const DOT_R = 2.5;
16
16
  const BAR_GAP = 0.15;
17
17
  const LINE_PX_PER_POINT = 1;
@@ -156,8 +156,8 @@ function Sparkline(props) {
156
156
  width,
157
157
  mark = "line",
158
158
  color = VX.faint,
159
- emphasizeLast = false,
160
- emphasisColor = VX.accent,
159
+ emphasizeLast = true,
160
+ emphasisColor = VX.line,
161
161
  state,
162
162
  className,
163
163
  style
@@ -28,8 +28,6 @@ export type CartesianInput<T, X extends ChartX> = Pick<CartesianChartProps<T, X>
28
28
  plot?: PlotSizes | null;
29
29
  };
30
30
  export declare function defaultNumberFormat(v: number): string;
31
- /** `DD.MM`, read in UTC like the time scale that placed it (a local read shifts a day west of UTC). */
32
- export declare function utcAxisDate(d: Date): string;
33
31
  /** `Mon Sep 1 2026`, in UTC; a non-midnight instant adds `HH:MM`. */
34
32
  export declare function utcHeaderDate(d: Date): string;
35
33
  /**
@@ -72,10 +70,17 @@ export declare function yGuide<T>(opts: {
72
70
  * the ones that collide, so a short-label grid (18 hour columns) would otherwise draw all of them.
73
71
  */
74
72
  export declare function strideTicks<V>(values: readonly V[], cls: ContainerClass): V[];
73
+ /**
74
+ * The one decision between a consumer's x format and the default: the consumer's wins; else dates
75
+ * read span-aware from the given tick values; else the plain default (numbers, strings, and a lone
76
+ * Date with no ticks to read a span from).
77
+ */
78
+ export declare function xTickFormat(consumer: ((v: ChartValue) => string) | undefined, tickValues: readonly ChartValue[]): (v: ChartValue) => string;
75
79
  export declare function xGuide<X extends ChartX>(opts: {
76
80
  model: XScaleModel<X>;
77
81
  xTicks: number | readonly X[] | undefined;
78
- format: (v: ChartValue) => string;
82
+ /** A consumer's formatter; absent, Date ticks get the span-aware {@link xTickFormat}. */
83
+ format?: ((v: ChartValue) => string) | undefined;
79
84
  cls: ContainerClass;
80
85
  /** The whole chart's height: decides whether the left margin is locked to zero. */
81
86
  height: number;
@@ -1 +1 @@
1
- {"version":3,"file":"compile.d.ts","sourceRoot":"","sources":["../../src/charts/compile.ts"],"names":[],"mappings":"AAcA,OAAO,KAAK,EAEV,aAAa,EAEb,yBAAyB,EACzB,eAAe,IAAI,gBAAgB,EACnC,UAAU,EACV,yBAAyB,EAE1B,MAAM,6BAA6B,CAAA;AAIpC,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,wBAAwB,CAAA;AAK5D,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,gBAAgB,CAAA;AAG/C,OAAO,KAAK,EAAE,WAAW,EAAE,MAAM,UAAU,CAAA;AAE3C,OAAO,KAAK,EACV,UAAU,EACV,mBAAmB,EAEnB,WAAW,EACX,eAAe,EACf,MAAM,EAEN,OAAO,EAEP,QAAQ,EACT,MAAM,SAAS,CAAA;AAEhB;;;GAGG;AACH,MAAM,MAAM,mBAAmB,GAAG,yBAAyB,CAAC,OAAO,EAAE,UAAU,EAAE,MAAM,EAAE,KAAK,CAAC,CAAA;AAE/F,gGAAgG;AAChG,MAAM,MAAM,cAAc,CAAC,CAAC,EAAE,CAAC,SAAS,MAAM,IAAI,IAAI,CACpD,mBAAmB,CAAC,CAAC,EAAE,CAAC,CAAC,EACvB,MAAM,GACN,GAAG,GACH,QAAQ,GACR,OAAO,GACP,GAAG,GACH,IAAI,GACJ,QAAQ,GACR,SAAS,GACT,SAAS,GACT,OAAO,GACP,QAAQ,GACR,UAAU,GACV,aAAa,GACb,kBAAkB,GAClB,SAAS,CACZ,GAAG;IACF,8FAA8F;IAC9F,OAAO,EAAE,MAAM,CAAA;IACf,8CAA8C;IAC9C,MAAM,CAAC,EAAE,WAAW,CAAC,MAAM,CAAC,CAAA;IAC5B,0CAA0C;IAC1C,WAAW,CAAC,EAAE,MAAM,G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AxisDate } from "./date-tick-format.js";
1
2
  import { crosshair } from "@tanstack/charts/crosshair";
2
3
  import { decorative } from "@tanstack/charts/mark/decorative";
3
4
  import { rect } from "@tanstack/charts/rect";
@@ -28,14 +29,9 @@ const labelsInside = (cls, height) => cls === "compact" && height > 0 && height
28
29
  function defaultNumberFormat(v) {
29
30
  return compact(v, { digits: Math.abs(v) >= 1e3 ? 1 : 2 });
30
31
  }
31
- const MONTHS = ["Jan", "Feb", "Mar", "Apr", "May", "Jun", "Jul", "Aug", "Sep", "Oct", "Nov", "Dec"];
32
32
  const DAYS = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"];
33
- const pad2 = (n) => String(n).padStart(2, "0");
34
- function utcAxisDate(d) {
35
- return `${pad2(d.getUTCDate())}.${pad2(d.getUTCMonth() + 1)}`;
36
- }
37
33
  function utcHeaderDate(d) {
38
- const date = `${DAYS[d.getUTCDay()]} ${MONTHS[d.getUTCMonth()]} ${d.getUTCDate()} ${d.getUTCFullYear()}`;
34
+ const date = `${DAYS[d.getUTCDay()]} ${monthName(d)} ${d.getUTCDate()} ${d.getUTCFullYear()}`;
39
35
  const ms = d.getTime() % DAY_MS;
40
36
  return ms === 0 ? date : `${date} ${pad2(d.getUTCHours())}:${pad2(d.getUTCMinutes())}`;
41
37
  }
@@ -149,11 +145,19 @@ function xTickPolicy(model, xTicks) {
149
145
  function strideTicks(values, cls) {
150
146
  return strideEvery(values, LADDER[cls].xTicks);
151
147
  }
148
+ function xTickFormat(consumer, tickValues) {
149
+ if (consumer) return consumer;
150
+ if (tickValues.length === 0 || !tickValues.every((v) => v instanceof Date))
151
+ return defaultFormatX;
152
+ const dateFormat = dateTickFormat(tickValues);
153
+ return (v) => v instanceof Date ? dateFormat(v) : defaultFormatX(v);
154
+ }
152
155
  function xGuide(opts) {
153
- const { model, xTicks, format, cls, height } = opts;
156
+ const { model, xTicks, cls, height } = opts;
154
157
  const ladder = LADDER[cls];
155
158
  const inside = labelsInside(cls, height);
156
159
  const ticks = xTickPolicy(model, xTicks ?? ladder.xTicks);
160
+ const format = xTickFormat(opts.format, "values" in ticks ? ticks.values : []);
157
161
  const [leftEdgeX, spanX] = !model.band && model.extent ? [model.extent[0], model.extent[1] - model.extent[0]] : [Number.NaN, Number.NaN];
158
162
  return {
159
163
  axis: {
@@ -415,7 +419,13 @@ function buildScales(opts) {
415
419
  return {
416
420
  x: {
417
421
  scale: model.scale,
418
- ...xGuide({ model, xTicks: input.xTicks, format: formatX, cls, height })
422
+ ...xGuide({
423
+ model,
424
+ xTicks: input.xTicks,
425
+ format: input.formatX ? formatX : void 0,
426
+ cls,
427
+ height
428
+ })
419
429
  },
420
430
  y: {
421
431
  scale: yScaleFor(input.y, left.domain),
@@ -607,10 +617,10 @@ export {
607
617
  refLegendSeries,
608
618
  seriesRow,
609
619
  strideTicks,
610
- utcAxisDate,
611
620
  utcHeaderDate,
612
621
  visibleSeries,
613
622
  xGuide,
623
+ xTickFormat,
614
624
  yGuide,
615
625
  zoneAreaGradient
616
626
  };
@@ -56,10 +56,23 @@ export type TooltipFollowerOptions = {
56
56
  export declare function followerOptions(tooltip: {
57
57
  onFollow?: boolean | undefined;
58
58
  } | false | null | undefined, group: string | undefined, chartId: string): TooltipFollowerOptions;
59
+ /** The engine host's hover readout element. */
60
+ export declare const TOOLTIP_READOUT = ".ts-chart-tooltip";
61
+ /**
62
+ * Decorates a tooltip host so every `paint` is followed by {@link stampTooltipRole}. The one
63
+ * stamping seam: `quietWhileFollowing` is built on it, and so is any chart that wires the engine host
64
+ * directly (Donut, Heatmap).
65
+ */
66
+ export declare function withTooltipRole(extension: ChartTooltipExtension): ChartTooltipExtension;
67
+ /**
68
+ * The engine's tooltip host with its readout stamped, built once: a chart passes this as
69
+ * `tooltip.use`, so the extension keeps one identity across memo rebuilds.
70
+ */
71
+ export declare const engineTooltip: ChartTooltipExtension;
59
72
  /**
60
73
  * The engine's DOM tooltip host, silent while this chart FOLLOWS another's cursor. A follower
61
74
  * resolves the leader's focus group (so the engine draws the same dots at the shared x); the host
62
- * would then paint a tooltip and fill its `role="status"` live region. Whenever `isForeign` holds,
75
+ * would then paint a tooltip and fill its live region. Whenever `isForeign` holds,
63
76
  * this wrapper calls the host's `hide()` instead of `paint()`: a follower that has never led never
64
77
  * creates the element, and one that has led keeps it in the DOM, hidden. Otherwise (leader, no
65
78
  * `follower` option, or after the leader clears) it defers to the host.
@@ -1 +1 @@
1
- {"version":3,"file":"cursor.d.ts","sourceRoot":"","sources":["../../src/charts/cursor.ts"],"names":[],"mappings":"AAgBA,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,yBAAyB,CAAA;AAEpE,OAAO,KAAK,EAAE,qBAAqB,EAAE,MAAM,0BAA0B,CAAA;AACrE,OAAO,KAAK,EAAE,kBAAkB,EAAc,MAAM,6BAA6B,CAAA;AACjF,OAAO,KAAK,EAAE,MAAM,EAAE,gBAAgB,EAAE,MAAM,SAAS,CAAA;AAiEvD;;;;;;;;;;;GAWG;AACH,wBAAgB,WAAW,CAAC,KAAK,SAAY,GAAG,qBAAqB,CAQpE;AAED,yDAAyD;AACzD,eAAO,MAAM,cAAc,GAAI,OAAO,MAAM,KAAG,OAA4B,CAAA;AAc3E,wBAAgB,SAAS,CAAC,KAAK,EAAE,MAAM,GAAG,SAAS,EAAE,OAAO,EAAE,MAAM,GAAG,OAAO,CAG7E;AA4FD,MAAM,MAAM,iBAAiB,GAAG;IAC9B,KAAK,EAAE,MAAM,GAAG,SAAS,CAAA;IACzB,OAAO,EAAE,MAAM,CAAA;IACf,IAAI,EAAE,SAAS,MAAM,EAAE,CAAA;IACvB,IAAI,EAAE,gBAAgB,CAAA;IACtB,2FAA2F;IAC3F,MAAM,CAAC,EAAE,SAAS,CAAC,MAAM,EAAE,MAAM,CAAC,GAAG,SAAS,CAAA;CAC/C,CAAA;AAED;;;;;;;;;;GAUG;AACH,wBAAgB,eAAe,CAAC,IAAI,EAAE,iBAAiB,GAAG,qBAAqB,CAsB9E;AAED;;;G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