basalt-ui 2.18.0 → 2.20.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.
- package/CHANGELOG.md +90 -0
- package/MIGRATING.md +238 -12
- package/agent/agents/basalt-design-reviewer.md +2 -2
- package/agent/rules/basalt-charts.md +1 -1
- package/agent/rules/basalt-mantine.md +1 -1
- package/agent/skills/basalt-app/SKILL.md +1 -1
- package/agent/skills/basalt-design/SKILL.md +1 -1
- package/agent/templates/DESIGN.md.tpl +1 -1
- package/configs/oxlint-plugin.js +33 -19
- package/configs/oxlint-plugin.test.ts +32 -2
- package/dist/charts/ChartCard.d.ts +28 -3
- package/dist/charts/ChartCard.d.ts.map +1 -1
- package/dist/charts/ChartCard.js +33 -11
- package/dist/charts/Donut.d.ts.map +1 -1
- package/dist/charts/Donut.js +13 -1
- package/dist/charts/Heatmap.js +1 -1
- package/dist/charts/Sparkline.d.ts +7 -1
- package/dist/charts/Sparkline.d.ts.map +1 -1
- package/dist/charts/Sparkline.js +137 -18
- package/dist/charts/box.d.ts +2 -0
- package/dist/charts/box.d.ts.map +1 -1
- package/dist/charts/box.js +2 -0
- package/dist/charts/chart-box.module.css +30 -0
- package/dist/charts/chart-box.module.css.d.ts +1 -0
- package/dist/charts/chart-card.module.css +47 -0
- package/dist/charts/chart-card.module.css.d.ts +7 -0
- package/dist/charts/compile.d.ts.map +1 -1
- package/dist/charts/compile.js +35 -8
- package/dist/charts/host.d.ts.map +1 -1
- package/dist/charts/host.js +2 -1
- package/dist/charts/index.d.ts +1 -1
- package/dist/charts/index.d.ts.map +1 -1
- package/dist/charts/sparkline.module.css +59 -0
- package/dist/charts/sparkline.module.css.d.ts +13 -0
- package/dist/charts/state.d.ts.map +1 -1
- package/dist/charts/state.js +32 -4
- package/dist/charts/types.d.ts +6 -0
- package/dist/charts/types.d.ts.map +1 -1
- package/dist/commands/notifications/center.d.ts.map +1 -1
- package/dist/commands/notifications/center.js +18 -26
- package/dist/content/callout.d.ts +1 -1
- package/dist/content/callout.d.ts.map +1 -1
- package/dist/content/callout.js +10 -1
- package/dist/content/callout.module.css +15 -3
- package/dist/content/callout.module.css.d.ts +1 -0
- package/dist/controls/sync-button.d.ts +3 -0
- package/dist/controls/sync-button.d.ts.map +1 -1
- package/dist/dashboard/bar-list.d.ts +15 -4
- package/dist/dashboard/bar-list.d.ts.map +1 -1
- package/dist/dashboard/bar-list.js +56 -19
- package/dist/dashboard/bar-list.module.css +110 -17
- package/dist/dashboard/bar-list.module.css.d.ts +2 -0
- package/dist/dashboard/delta-badge.d.ts +8 -3
- package/dist/dashboard/delta-badge.d.ts.map +1 -1
- package/dist/dashboard/delta-badge.js +9 -2
- package/dist/dashboard/index.d.ts +2 -0
- package/dist/dashboard/index.d.ts.map +1 -1
- package/dist/dashboard/meter-model.d.ts +68 -1
- package/dist/dashboard/meter-model.d.ts.map +1 -1
- package/dist/dashboard/meter-model.js +65 -4
- package/dist/dashboard/meter-parts.d.ts +5 -1
- package/dist/dashboard/meter-parts.d.ts.map +1 -1
- package/dist/dashboard/meter-parts.js +234 -60
- package/dist/dashboard/meter.d.ts +38 -6
- package/dist/dashboard/meter.d.ts.map +1 -1
- package/dist/dashboard/meter.js +4 -1
- package/dist/dashboard/meter.module.css +209 -13
- package/dist/dashboard/meter.module.css.d.ts +16 -0
- package/dist/dashboard/query-state.d.ts.map +1 -1
- package/dist/dashboard/query-state.js +14 -9
- package/dist/dashboard/settings-section.d.ts.map +1 -1
- package/dist/dashboard/settings-section.js +14 -25
- package/dist/dashboard/stat-card-parts.d.ts +3 -1
- package/dist/dashboard/stat-card-parts.d.ts.map +1 -1
- package/dist/dashboard/stat-card-parts.js +18 -3
- package/dist/dashboard/stat-card.d.ts +7 -6
- package/dist/dashboard/stat-card.d.ts.map +1 -1
- package/dist/dashboard/stat-card.js +51 -83
- package/dist/dashboard/stat-card.module.css +42 -14
- package/dist/dashboard/stat-group.d.ts +11 -2
- package/dist/dashboard/stat-group.d.ts.map +1 -1
- package/dist/dashboard/stat-group.js +9 -7
- package/dist/dashboard/stat-strip.d.ts +50 -0
- package/dist/dashboard/stat-strip.d.ts.map +1 -0
- package/dist/dashboard/stat-strip.js +85 -0
- package/dist/dashboard/stat-strip.module.css +208 -0
- package/dist/dashboard/stat-strip.module.css.d.ts +28 -0
- package/dist/dashboard/widget-header.d.ts +3 -3
- package/dist/dashboard/widget-header.d.ts.map +1 -1
- package/dist/dashboard/widget-header.js +2 -1
- package/dist/dashboard/widget-header.module.css +38 -7
- package/dist/format/date.d.ts.map +1 -1
- package/dist/format/date.js +4 -3
- package/dist/format/shared.d.ts +6 -0
- package/dist/format/shared.d.ts.map +1 -1
- package/dist/format/shared.js +6 -2
- package/dist/guard/index.d.ts +1 -1
- package/dist/guard/index.js +1 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js +4 -0
- package/dist/styles.css +6 -0
- package/dist/theme/card-inset.module.css +76 -0
- package/dist/theme/card-inset.module.css.d.ts +9 -0
- package/dist/theme/chrome-vars.d.ts +29 -17
- package/dist/theme/chrome-vars.d.ts.map +1 -1
- package/dist/theme/chrome-vars.js +18 -8
- package/dist/theme/controls.module.css +3 -0
- package/dist/theme/index.d.ts.map +1 -1
- package/dist/theme/index.js +32 -5
- package/dist/theme/nav-link.module.css +8 -10
- package/dist/theme/status-dot.d.ts +7 -0
- package/dist/theme/status-dot.d.ts.map +1 -0
- package/dist/theme/status-dot.js +18 -0
- package/dist/theme/status-dot.module.css +9 -0
- package/dist/theme/status-dot.module.css.d.ts +8 -0
- package/dist/theme/status-verdict.d.ts +10 -0
- package/dist/theme/status-verdict.d.ts.map +1 -0
- package/dist/theme/status-verdict.js +14 -0
- package/dist/theme/status-verdict.module.css +25 -0
- package/dist/theme/status-verdict.module.css.d.ts +9 -0
- package/llms.txt +30 -6
- package/package.json +1 -1
- package/src/charts/ChartCard.tsx +70 -4
- package/src/charts/Donut.tsx +9 -1
- package/src/charts/Heatmap.tsx +1 -1
- package/src/charts/Sparkline.tsx +180 -18
- package/src/charts/box.tsx +2 -0
- package/src/charts/chart-box.module.css +30 -0
- package/src/charts/chart-box.module.css.d.ts +1 -0
- package/src/charts/chart-card.module.css +47 -0
- package/src/charts/chart-card.module.css.d.ts +7 -0
- package/src/charts/compile.ts +42 -9
- package/src/charts/host.tsx +6 -3
- package/src/charts/index.ts +1 -1
- package/src/charts/sparkline.module.css +59 -0
- package/src/charts/sparkline.module.css.d.ts +13 -0
- package/src/charts/state.tsx +44 -4
- package/src/charts/types.ts +6 -0
- package/src/commands/notifications/center.tsx +29 -32
- package/src/content/callout.module.css +15 -3
- package/src/content/callout.module.css.d.ts +1 -0
- package/src/content/callout.tsx +15 -2
- package/src/controls/sync-button.tsx +3 -0
- package/src/dashboard/bar-list.module.css +110 -17
- package/src/dashboard/bar-list.module.css.d.ts +2 -0
- package/src/dashboard/bar-list.tsx +102 -21
- package/src/dashboard/delta-badge.tsx +21 -5
- package/src/dashboard/index.ts +2 -0
- package/src/dashboard/meter-model.ts +132 -4
- package/src/dashboard/meter-parts.tsx +305 -25
- package/src/dashboard/meter.module.css +209 -13
- package/src/dashboard/meter.module.css.d.ts +16 -0
- package/src/dashboard/meter.tsx +42 -7
- package/src/dashboard/query-state.tsx +28 -19
- package/src/dashboard/settings-section.tsx +1 -8
- package/src/dashboard/stat-card-parts.tsx +22 -2
- package/src/dashboard/stat-card.module.css +42 -14
- package/src/dashboard/stat-card.tsx +23 -60
- package/src/dashboard/stat-group.tsx +19 -8
- package/src/dashboard/stat-strip.module.css +208 -0
- package/src/dashboard/stat-strip.module.css.d.ts +28 -0
- package/src/dashboard/stat-strip.tsx +183 -0
- package/src/dashboard/widget-header.module.css +38 -7
- package/src/dashboard/widget-header.tsx +7 -4
- package/src/format/date.ts +6 -3
- package/src/format/shared.ts +11 -2
- package/src/guard/index.ts +1 -1
- package/src/index.ts +7 -0
- package/src/styles.css +6 -0
- package/src/theme/__snapshots__/plain-theme.test.ts.snap +242 -26
- package/src/theme/card-inset.module.css +76 -0
- package/src/theme/card-inset.module.css.d.ts +9 -0
- package/src/theme/chrome-vars.ts +48 -23
- package/src/theme/controls.module.css +3 -0
- package/src/theme/index.ts +40 -6
- package/src/theme/nav-link.module.css +8 -10
- package/src/theme/status-dot.module.css +9 -0
- package/src/theme/status-dot.module.css.d.ts +8 -0
- package/src/theme/status-dot.tsx +31 -0
- package/src/theme/status-verdict.module.css +25 -0
- package/src/theme/status-verdict.module.css.d.ts +9 -0
- package/src/theme/status-verdict.tsx +32 -0
package/CHANGELOG.md
CHANGED
|
@@ -1,3 +1,93 @@
|
|
|
1
|
+
# [2.20.0](https://github.com/jkrumm/basalt-ui/compare/v2.19.0...v2.20.0) (2026-10-17)
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
### Bug Fixes
|
|
5
|
+
|
|
6
|
+
* address review on chart font, Meter glue and slot hover test ([8027c08](https://github.com/jkrumm/basalt-ui/commit/8027c087f8c88f3f1188d69de316079489fb6adf))
|
|
7
|
+
* address review on round-2 fixtures ([ec9d619](https://github.com/jkrumm/basalt-ui/commit/ec9d619d1f7c1428815bf1709e2aeafe573e447c))
|
|
8
|
+
* drop the last redundant card inset pair and its stale guard hint ([8bc0500](https://github.com/jkrumm/basalt-ui/commit/8bc05005e41e31c672b205620500a55bc488b940))
|
|
9
|
+
* gate card facts by state and settle review round 1 ([22b4a49](https://github.com/jkrumm/basalt-ui/commit/22b4a49e6476eb5d3d78283ad923a539fb0f04f8))
|
|
10
|
+
* gate the item-flow facts by state ([34abefb](https://github.com/jkrumm/basalt-ui/commit/34abefb29507659b6dcef0a6677659bf63bd216e))
|
|
11
|
+
* keep the meter marker centred and pin the muted fill below line ([9da586d](https://github.com/jkrumm/basalt-ui/commit/9da586d789ae0d9049b6a92897f68e76888b3cab))
|
|
12
|
+
* match the vs prefix loosely and space the period ([1723364](https://github.com/jkrumm/basalt-ui/commit/172336484ba1acfa8dd26db8df0d070f6e225993))
|
|
13
|
+
* render the S3 day note as a meter and drop the budget legend ([3aec049](https://github.com/jkrumm/basalt-ui/commit/3aec0496568639faa8dd50c6dc48aa6df3680957))
|
|
14
|
+
* round-1 board fixes for facts, strip, meter and chart faces ([88d9e76](https://github.com/jkrumm/basalt-ui/commit/88d9e765d0894263c8e2fceb99ab5f3d5f4a68d0))
|
|
15
|
+
* round-1 fixture fixes on S3, S4 and the components page ([f48da52](https://github.com/jkrumm/basalt-ui/commit/f48da5298546140959e56e0dc641fd7ea1c262e0))
|
|
16
|
+
* round-2 fixture fixes on S2, S3, S4 and components ([e7d4076](https://github.com/jkrumm/basalt-ui/commit/e7d40765ed6646f928867c7d80ed51fbb5aac1ec))
|
|
17
|
+
* sparkline readout review round 1 ([ebef74f](https://github.com/jkrumm/basalt-ui/commit/ebef74f63a03a6199ab0f57239301e7cc0e5ebe0))
|
|
18
|
+
* split the bar list format part and keep tick text in the track ([c6efab8](https://github.com/jkrumm/basalt-ui/commit/c6efab8a4d93720c6df236e23dbde5f248190f84))
|
|
19
|
+
* stub Intl.RelativeTimeFormat through defineProperty in tests ([eac88ab](https://github.com/jkrumm/basalt-ui/commit/eac88ab70bbf605e22e7dd251015479282f6991e))
|
|
20
|
+
* tint the budget line by verdict and dedupe the forecast row ([fe964b8](https://github.com/jkrumm/basalt-ui/commit/fe964b8883253662a1e5440a0b7649aacfd4db4a))
|
|
21
|
+
* type the ref label mark generically and cover the flip band ([d0b1198](https://github.com/jkrumm/basalt-ui/commit/d0b1198de82efeed00ded4357bbfb663ce275e07))
|
|
22
|
+
|
|
23
|
+
|
|
24
|
+
### Features
|
|
25
|
+
|
|
26
|
+
* add a facts slot to the chart card for the headline figure ([f93c793](https://github.com/jkrumm/basalt-ui/commit/f93c7936e9d14bd9bda2c4d08759a96be41bbfd5))
|
|
27
|
+
* add a strip variant with typed cells and a footer row to StatGroup ([1dfcab8](https://github.com/jkrumm/basalt-ui/commit/1dfcab8f01a18c72761a69fe3fe6fc00e265cbe1))
|
|
28
|
+
* add BarList per-row max, thin rows and per-row ticks ([e79e503](https://github.com/jkrumm/basalt-ui/commit/e79e5034da1aa59a7ef72bf828583662d5edef03))
|
|
29
|
+
* add meter ticks, muted tone, row size and root part types ([a58c48d](https://github.com/jkrumm/basalt-ui/commit/a58c48d0c3767d7569a54f08f3c5b6f015d93971))
|
|
30
|
+
* add the agent-work scenario and a strip on training and spend ([f4ef65b](https://github.com/jkrumm/basalt-ui/commit/f4ef65bb6156e90e84f714b6e70a9d7934d2d5b8))
|
|
31
|
+
* chart error body uses the dot idiom, pin tab hover and padding ([41d7296](https://github.com/jkrumm/basalt-ui/commit/41d72962a239634a40faf6635cfda86611ce911d))
|
|
32
|
+
* compose the comparison period in DeltaBadge ([c903195](https://github.com/jkrumm/basalt-ui/commit/c90319555408abfa6e88ffa7646cc81687253abd))
|
|
33
|
+
* export StatusDot and StatusVerdict from the root ([eb835c6](https://github.com/jkrumm/basalt-ui/commit/eb835c6a6219d984765b20885840d5bc3e27fdd7))
|
|
34
|
+
* heatmap ticks keep the caption size at every width ([87e947f](https://github.com/jkrumm/basalt-ui/commit/87e947faad6dd00bd338f1c6ef01d2d6a9b32eda))
|
|
35
|
+
* keep the subtitle and gate chart card facts by state ([9c87401](https://github.com/jkrumm/basalt-ui/commit/9c87401e8cff18140fdb0b387cafcc618cd2c744))
|
|
36
|
+
* ledger the strip hairlines and draw its row rule between cells ([2d65e2e](https://github.com/jkrumm/basalt-ui/commit/2d65e2e6b59e7413b377eae5529cf56f4852b176))
|
|
37
|
+
* let strip cells carry hero and rows, stale state and derived anchors ([781e57e](https://github.com/jkrumm/basalt-ui/commit/781e57e97de0b7d3fd0f2bbba7099974fe62a2c1))
|
|
38
|
+
* let the status mark take className and style ([054d466](https://github.com/jkrumm/basalt-ui/commit/054d466b774066da757e965d1dcb49b476b36f37))
|
|
39
|
+
* measure the card inset in Chrome and let consumer classes win ([9a93f4c](https://github.com/jkrumm/basalt-ui/commit/9a93f4cdc84dfed95ad76d2e0f55d452e91044a1))
|
|
40
|
+
* on-plot labels for chart reference lines ([220663b](https://github.com/jkrumm/basalt-ui/commit/220663b869b5406f07609e81982a44fc617f9979))
|
|
41
|
+
* on-scale button padding, dark tab hover, neutral active row ([60b9abe](https://github.com/jkrumm/basalt-ui/commit/60b9abed5aa9a295df3e80bff4f4560154fcaeff))
|
|
42
|
+
* proportional hero numerals, mono only for captions and times ([9da4c3f](https://github.com/jkrumm/basalt-ui/commit/9da4c3fa1fbcf4141285e64eccd6acda43bb93fd))
|
|
43
|
+
* re-encode spend distribution and spend over time on s4 ([6048d83](https://github.com/jkrumm/basalt-ui/commit/6048d833f8d13a1b2fdc5718f85ff57cc2bf173f))
|
|
44
|
+
* relativeTime and SyncButton honour the format locale ([dea7750](https://github.com/jkrumm/basalt-ui/commit/dea7750960b4787acec078de4c624411636ebccb))
|
|
45
|
+
* reserve the sparkline readout line and set verdicts in the sans ([311c216](https://github.com/jkrumm/basalt-ui/commit/311c216261a487a65d4612b3d0c9545850e64e9a))
|
|
46
|
+
* round-2 board fixes for readout, chart error, ticks and rows ([ab632fb](https://github.com/jkrumm/basalt-ui/commit/ab632fbddb8dbc8be86f9b86c65740c01e70fc26))
|
|
47
|
+
* share one locale resolver across the format builders ([7431ae4](https://github.com/jkrumm/basalt-ui/commit/7431ae455f10ea6a26c20e007686ac8b36229428))
|
|
48
|
+
* sparkline reference line and a hover/focus readout ([aff4fb7](https://github.com/jkrumm/basalt-ui/commit/aff4fb7b76008164effee7c4db27918165491705))
|
|
49
|
+
* the theme owns the card inset; card-inset flags the pair ([a936467](https://github.com/jkrumm/basalt-ui/commit/a9364676a09ef9bd6048fa2fe3acb9c3ef5aee34))
|
|
50
|
+
|
|
51
|
+
# [2.19.0](https://github.com/jkrumm/basalt-ui/compare/v2.18.0...v2.19.0) (2026-10-17)
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
### Bug Fixes
|
|
55
|
+
|
|
56
|
+
* address round 1 on the S2 and S4 scenarios ([8ebc318](https://github.com/jkrumm/basalt-ui/commit/8ebc318b93c4ef1971705752c31378b943842667))
|
|
57
|
+
* address round 2 on the S2 and S4 scenarios ([48e992c](https://github.com/jkrumm/basalt-ui/commit/48e992cc8c65304ae87080b477a40974915185d2))
|
|
58
|
+
* anchor the zone reading at its marker and inset skeletons ([0f734ae](https://github.com/jkrumm/basalt-ui/commit/0f734ae56fabc5600d0c9e1e45330b650e983b63))
|
|
59
|
+
* caption Meter segments, wrap captions, size Meter in StatCard ([8125541](https://github.com/jkrumm/basalt-ui/commit/81255416395fbb01062a830a87114b5f1e6c9592))
|
|
60
|
+
* centre the zone reading logically and pin it in RTL ([6176606](https://github.com/jkrumm/basalt-ui/commit/61766066b3bd6f0c8ab58cc4e2720d9007908d8b))
|
|
61
|
+
* close review round 2 on Meter captions and the StatCard slot ([421ac71](https://github.com/jkrumm/basalt-ui/commit/421ac7144518a80b11e0f7f0a846d19be798500d))
|
|
62
|
+
* draw the info focus ring on a glyph-sized pseudo-element ([f11bf1c](https://github.com/jkrumm/basalt-ui/commit/f11bf1cc1a6ed03e28b7987d61be06839510a657))
|
|
63
|
+
* drop the shot hover from sparkline wrappers ([a2e2f5c](https://github.com/jkrumm/basalt-ui/commit/a2e2f5cf914ec6b08fb16afbf010b6562d85fd02))
|
|
64
|
+
* harden Meter caption modes and pin the layout in a browser ([0ab822d](https://github.com/jkrumm/basalt-ui/commit/0ab822ddc38ea62085dd2664edcc0fdcf28ec78c))
|
|
65
|
+
* keep the BarList bar inside the label column ([a227c53](https://github.com/jkrumm/basalt-ui/commit/a227c53be55e7692f1312367f63dfe3d0d1b406a))
|
|
66
|
+
* keep the fixture month labels independent of ICU data ([a226543](https://github.com/jkrumm/basalt-ui/commit/a226543d6f5b5bb1b3d91b582bfee77e6f356180))
|
|
67
|
+
* keep the info glyph focus ring off the caption text ([d66d178](https://github.com/jkrumm/basalt-ui/commit/d66d1782d479520edd1b6cd1267189f5f516368a))
|
|
68
|
+
* keep the loading skeleton inset in the narrow right slot ([cda6c98](https://github.com/jkrumm/basalt-ui/commit/cda6c98da806f61a88259783d81d1a1b1cc65579))
|
|
69
|
+
* key the Meter zone fit on the holding zone and test fonts ([7854b74](https://github.com/jkrumm/basalt-ui/commit/7854b74aa6eed8a9034d3f9fa7f41bd6686f2336))
|
|
70
|
+
* name the info glyph ring knobs and harden its layout test ([c7fb542](https://github.com/jkrumm/basalt-ui/commit/c7fb5428b68fa1805d1ae03eab497b937074d0d1))
|
|
71
|
+
* name the Meter zones on the band ([b321399](https://github.com/jkrumm/basalt-ui/commit/b321399230b86f6f4ae5160fc5bed401606374c1))
|
|
72
|
+
* name the S2 pace unit and hover specimens on /components ([d0a014d](https://github.com/jkrumm/basalt-ui/commit/d0a014d056c782a2ba5349629c116a3b6ab02136))
|
|
73
|
+
* name the status in words and share one StatusDot ([d3a16b8](https://github.com/jkrumm/basalt-ui/commit/d3a16b867037468296d07e435f638ec8c913f8c5))
|
|
74
|
+
* name the window under the S4 month-to-date sparkline ([67b59d0](https://github.com/jkrumm/basalt-ui/commit/67b59d0b981aa36b56155dbaace61bb2513a82d6))
|
|
75
|
+
* put the Meter ring padding on a spacing token ([ed28b4a](https://github.com/jkrumm/basalt-ui/commit/ed28b4a106170fa2179bfe56721b4d6fe9e82c36))
|
|
76
|
+
* re-measure Meter zone names on font load and prove the fit ([2390900](https://github.com/jkrumm/basalt-ui/commit/23909008a1aa6536d18a6314d46c37607225ca85))
|
|
77
|
+
* render the sparkline directly in the StatCard slot ([1c56983](https://github.com/jkrumm/basalt-ui/commit/1c56983f62d2c15e31a175efa0a7ca2c729a6fc4))
|
|
78
|
+
* show the notification intent word and share StatusVerdict ([64bb580](https://github.com/jkrumm/basalt-ui/commit/64bb5809a7ddef74afcf26c6e4f009ed8c6ade2d))
|
|
79
|
+
* treat an empty or null color as unnamed for ink vars ([4930bda](https://github.com/jkrumm/basalt-ui/commit/4930bdaff6f05d94aa359f5b174bbc05ab30390d))
|
|
80
|
+
|
|
81
|
+
|
|
82
|
+
### Features
|
|
83
|
+
|
|
84
|
+
* build the S2 training-log scenario ([94a7f91](https://github.com/jkrumm/basalt-ui/commit/94a7f9122ef47d5272889c6f7acd484ade06c69b))
|
|
85
|
+
* ink the light button on the subtle surface and add edge tests ([6fe99fa](https://github.com/jkrumm/basalt-ui/commit/6fe99fa2194337d4a7bb36993c5d59ea0c8c31f1))
|
|
86
|
+
* name the Callout and notification-center edges in MIGRATING ([2da8c8d](https://github.com/jkrumm/basalt-ui/commit/2da8c8d9ba2836ba3094efe497c02c3cc61c0813))
|
|
87
|
+
* paint light and outline buttons in ink by default ([47d566b](https://github.com/jkrumm/basalt-ui/commit/47d566b9b8b79351a0218a9f14ac53a2196a6090))
|
|
88
|
+
* put the S4 spend scenario on Meter and BarList ([37530a9](https://github.com/jkrumm/basalt-ui/commit/37530a9a54f6ed353c8e2a3faf0fcdbb1de22875))
|
|
89
|
+
* state a StatCard verdict as a dot and a word, not a rail ([1a4085d](https://github.com/jkrumm/basalt-ui/commit/1a4085db453aa05fd3195adf9436c7b3edecb0cc))
|
|
90
|
+
|
|
1
91
|
# [2.18.0](https://github.com/jkrumm/basalt-ui/compare/v2.17.0...v2.18.0) (2026-10-17)
|
|
2
92
|
|
|
3
93
|
|
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 | 2.17.0 | 2.18.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 | 2.18.0 | 2.19.0 | 2.20.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) | — | — | light/outline Buttons ink, no status edges (§ 2.19.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) | — | — | StatCard status dot, Meter/BarList refinements (§ 2.19.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,232 @@ 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.20.0 — the sparkline reference and readout
|
|
1050
|
+
|
|
1051
|
+
**`Sparkline` now answers hover and keyboard focus.** A pointer over the cell, or arrow keys /
|
|
1052
|
+
Home / End on the focused chart, show the point's value in one quiet in-cell line (Escape or blur
|
|
1053
|
+
clears it) and mark the point with a dot. It was inert before. Value text comes from the new
|
|
1054
|
+
`format` prop (default: the compact number format), the x text from the new `labels` array
|
|
1055
|
+
(index-aligned with `data`). **Opt out** by putting the sparkline under an `aria-hidden` ancestor,
|
|
1056
|
+
which disables the readout.
|
|
1057
|
+
|
|
1058
|
+
New, additive: `reference={n | 'mean'}` draws a dashed `--vx-line` hairline and widens the y domain
|
|
1059
|
+
to include it (`'mean'` is over the plotted values).
|
|
1060
|
+
|
|
1061
|
+
### `Meter` captions share one size, and gains `ticks`, `tone`, `size`
|
|
1062
|
+
|
|
1063
|
+
**Changed default:** the `Meter` empty line ("No data") was `--vx-text-sm`; every Meter caption
|
|
1064
|
+
(reading, target, forecast, part, zone and tick names, the empty line) now reads one token,
|
|
1065
|
+
`--basalt-meter-caption`, defaulting to `--vx-text-micro`. **Opt out** (or follow the host text) per
|
|
1066
|
+
Meter: `style={{ '--basalt-meter-caption': 'var(--vx-text-sm)' }}`, or `1em` to inherit the host size.
|
|
1067
|
+
The target tick now also carries a 1px track-coloured halo, and at `target === max` sits inside the
|
|
1068
|
+
track end instead of straddling it.
|
|
1069
|
+
|
|
1070
|
+
New, additive: `ticks={[{ at, label? }]}` (several marks; out-of-range ticks are dropped, not
|
|
1071
|
+
clamped), `tone="muted"` (a non-verdict fill, 3:1 against the track in both schemes), `size="row"`
|
|
1072
|
+
(one text line tall, no caption rows), and root types `MeterSegment`, `MeterZone`, `MeterTick`.
|
|
1073
|
+
|
|
1074
|
+
### `relativeTime` honours the format locale
|
|
1075
|
+
|
|
1076
|
+
`relativeTime` (and `SyncButton`, which calls it with no locale) now falls back to the
|
|
1077
|
+
`defineFormat` / `BasaltProvider` `locale`, like `numberFormat` and `dateFormat` always did. Before,
|
|
1078
|
+
it fell back to the runtime's own locale, so an `en-GB` app on a German system read "vor 4 Tagen".
|
|
1079
|
+
The fix is in `relativeTime`'s formatter only: `duration` and the date builders already resolved the default, and no other `Intl.RelativeTimeFormat` exists in `src`.
|
|
1080
|
+
|
|
1081
|
+
**Opt-out:** pass `locale` per call, or leave `defineFormat` / the provider `locale` unset to keep
|
|
1082
|
+
the runtime locale. argo can drop its `APP_LOCALE` wrapper around `relativeTime`.
|
|
1083
|
+
|
|
1084
|
+
### Proportional numerals (`StatCard`, `WidgetHeader`, `DeltaBadge`, `BarList`, `Meter`)
|
|
1085
|
+
|
|
1086
|
+
Hero values, row labels and body text are now the proportional sans with lining figures; mono is
|
|
1087
|
+
for captions, times and code only (`docs/DESIGN-CORE.md`). Before, every numeral rendered in
|
|
1088
|
+
JetBrains Mono.
|
|
1089
|
+
|
|
1090
|
+
- **What changed:** `StatCard` / `WidgetHeader` hero value, unit and count chip, `StatCard`
|
|
1091
|
+
breakdown values, `DeltaBadge`, `BarList` value and secondary, and `Meter` ring value, captions
|
|
1092
|
+
and zone labels now read `font-family: var(--basalt-font-numeral, var(--basalt-font-sans))` with
|
|
1093
|
+
`font-variant-numeric: lining-nums`. Sizes, weights and letter-spacing are unchanged. Headings
|
|
1094
|
+
(`h1`–`h6`, `.mantine-Title-root`) drop the face's slashed zero (`font-feature-settings: 'zero' 0`).
|
|
1095
|
+
- **Unchanged:** uppercase captions, qualifiers, the group-tier heading and times stay mono;
|
|
1096
|
+
`src/table/**`, `[data-numeric]` controls and axis ticks keep tabular figures.
|
|
1097
|
+
- **Opt out (old mono heroes):** one declaration restores every site above:
|
|
1098
|
+
|
|
1099
|
+
```css
|
|
1100
|
+
:root {
|
|
1101
|
+
--basalt-font-numeral: var(--basalt-font-mono);
|
|
1102
|
+
}
|
|
1103
|
+
```
|
|
1104
|
+
|
|
1105
|
+
Heading zeros: `h1, h2, h3, h4, h5, h6, .mantine-Title-root { font-feature-settings: normal; }`
|
|
1106
|
+
(needs to out-rank `@layer basalt` — declare it unlayered).
|
|
1107
|
+
|
|
1108
|
+
### `<Card>` and `<Paper>` default to the 12/16 inset
|
|
1109
|
+
|
|
1110
|
+
The theme now sets the inset itself — `--vx-space-card-inset-y` 12 / `-x` 16, density-scaled — on
|
|
1111
|
+
every `Card` and `Paper`. Before, a bare `<Card>` got Mantine's 16 px all round and a bare
|
|
1112
|
+
`<Paper>` got 0, so both missed the law and consumers wrote `py="sm" px="md"` on every card.
|
|
1113
|
+
|
|
1114
|
+
| You wrote | Before | Now |
|
|
1115
|
+
| ------------------------------ | ------------ | ------------------------------------------------------------- |
|
|
1116
|
+
| `<Card>` | 16 all round | 12 / 16 |
|
|
1117
|
+
| `<Paper>` | 0 | 12 / 16 |
|
|
1118
|
+
| `<Card py="sm" px="md">` | 12 / 16 | 12 / 16 — and `basalt/card-inset` flags the pair as redundant |
|
|
1119
|
+
| `<Card padding={0}>` / `p={0}` | flush | flush, flagged: use `variant="flush"` |
|
|
1120
|
+
|
|
1121
|
+
- **Delete** every `py="sm" px="md"` on a `Card` or `Paper`.
|
|
1122
|
+
- **Flush whole card** (a map, an image, a table that owns its own padding): `variant="flush"` on
|
|
1123
|
+
`Card` or `Paper`. **Full-bleed region inside a padded card**: `<Card.Section>`, whose negative
|
|
1124
|
+
margins now cancel the 12/16 pair rather than one `--card-padding`.
|
|
1125
|
+
- **Opt out of the theme inset for one card**: an explicit padding with
|
|
1126
|
+
`{/* theme-allow card-inset — <why> */}`. A Card `padding` prop still works (it retargets the same
|
|
1127
|
+
pair), and `p`/`py`/`px` style props win as inline styles.
|
|
1128
|
+
- A `Paper` you relied on being padding-free (a bare wrapper, a custom overlay) now has 12/16:
|
|
1129
|
+
add `variant="flush"`. Mantine's own `Modal`, `Drawer`, `Dialog`, `ActionBar` and `FloatingWindow`
|
|
1130
|
+
are excluded and gain nothing.
|
|
1131
|
+
- `basalt/card-inset` stays at `warn` (grace → 2.26.0); the redundant pair is a new finding, so a
|
|
1132
|
+
codebase that was clean last release will report until the pairs are deleted.
|
|
1133
|
+
|
|
1134
|
+
### `DeltaBadge` `period` composes "vs <period>"
|
|
1135
|
+
|
|
1136
|
+
`period` (and `deltaPeriod` on `StatCard`, `WidgetHeader`, `Section`) now renders `vs <period>`: `period="MoM"` reads "vs MoM" where it read "MoM". A period that already starts with the prefix is left alone, so a caller passing `"vs last week"` still renders "vs last week", not "vs vs last week". **Opt out** with `periodPrefix=""` on `DeltaBadge` (renders the period raw), or pass your locale's word (`periodPrefix="gegenüber"`). A period that is not a comparison (`"30d"`, a change over a window) now reads wrongly ("vs 30d"): pass `periodPrefix=""` on `DeltaBadge` itself, or reword it through the card props (`"30 days ago"`). Drop the hand-written "vs " at your leisure.
|
|
1137
|
+
|
|
1138
|
+
### Chrome: on-scale Button padding, neutral selected nav row, neutral error state
|
|
1139
|
+
|
|
1140
|
+
**Button inline padding is on the spacing scale.** Every size reads `--vx-space-stack-*` steps
|
|
1141
|
+
(density-scaled) instead of Mantine's 14/18/22/26/32 px and compact 7/8/10/12/14 px: `xs` 12, `sm` 16,
|
|
1142
|
+
`md` 20, `lg` 24, `xl` 32; `compact-xs`/`-sm` 8, `compact-md`/`-lg` 12, `compact-xl` 16 (at density 0).
|
|
1143
|
+
Heights are unchanged, and `size="ctl"` keeps its own 10 px inset. **Opt out** per component with
|
|
1144
|
+
`<Button styles={{ root: { '--button-padding-x': 'var(--button-padding-x-<size>)' } }}>`, using the
|
|
1145
|
+
matching Mantine size var (`--button-padding-x-xs`, `-compact-xs`, …), or globally by overriding
|
|
1146
|
+
`Button.vars` in your theme.
|
|
1147
|
+
|
|
1148
|
+
**The selected nav row is a neutral ink fill, not an accent tint.** `NavLink[data-active]` paints
|
|
1149
|
+
ink 10 % (14 % on hover) with the existing weight 600; the accent stays on the active icon, focus and
|
|
1150
|
+
the filled primary. **Opt out** with a consumer class on the row that sets `background-color`
|
|
1151
|
+
(consumer classes win over the theme module).
|
|
1152
|
+
|
|
1153
|
+
**Errors render as a dot, a word, the message and a retry.** `ErrorState` (and so `QueryState`
|
|
1154
|
+
and `StatCard` error bodies) no longer renders a red-tinted Mantine `Alert`; it is a neutral
|
|
1155
|
+
`role="alert"` stack led by a `StatusDot` and the title. `ChartCard`'s error body gets the same idiom
|
|
1156
|
+
(dot, "Error", the message, Retry); the compact sparkline `—` is unchanged. **Opt out** by rendering your own
|
|
1157
|
+
`<Alert color="red" variant="light">` in the `error` slot of the surface (or a custom `ErrorState`
|
|
1158
|
+
wrapper).
|
|
1159
|
+
|
|
1160
|
+
Also fixed (no action): a hovered `Tab` now shows an ink-5 % fill in dark as in light.
|
|
1161
|
+
|
|
1162
|
+
### Facts at rest, strip captions, tick fonts
|
|
1163
|
+
|
|
1164
|
+
**Changed default:** `ChartCard` `facts` show only at rest; while `state` is pending, errored or empty
|
|
1165
|
+
the header keeps its title row alone (the figure above a skeleton contradicted it). **Opt out:** none;
|
|
1166
|
+
pass the figure as `info`/`subtitle` text if a loading card must still state it.
|
|
1167
|
+
|
|
1168
|
+
**Changed default:** the lowercase `qualifier` of a `StatCard` and a `StatGroup` strip cell is the muted
|
|
1169
|
+
proportional sans (mono stays on the UPPERCASE caption), and a strip cell's `· ` separator is gone. The
|
|
1170
|
+
caption and its info glyph are one unit (the caption truncates with a `title`; the qualifier wraps
|
|
1171
|
+
whole below it). Chart axis ticks (the chart host's font) are the proportional sans with `tabular-nums`, not mono.
|
|
1172
|
+
**Opt out:** set `--basalt-chart-font: var(--basalt-font-mono)` on the chart or an ancestor.
|
|
1173
|
+
|
|
1174
|
+
`Meter` captions wrap with `text-wrap: pretty` and join a number and a known unit (`24 h`, `7 d`, `5 min`, `40 %`)
|
|
1175
|
+
with a no-break space, so `textContent` carries U+00A0 there; its visually-hidden summary now reads the caption
|
|
1176
|
+
size instead of the inherited body size.
|
|
1177
|
+
|
|
1178
|
+
### Round-2 board fixes: sparkline readout, chart error, tick size, captions, thin rows, verdict word
|
|
1179
|
+
|
|
1180
|
+
**Changed default — `Sparkline` readout.** The hover/focus chip is opaque and sits on a line ABOVE the plot
|
|
1181
|
+
box (it sat inside it and covered the line's last segment, a bar or the end dot). The `StatCard` `right`
|
|
1182
|
+
slot and a strip cell's `visual` now reserve that line (`--basalt-spark-readout-h`, 18px) as padding above
|
|
1183
|
+
a sparkline, so the card/cell grows by up to 18px and the chip never covers the hero value; `bleed` already
|
|
1184
|
+
had the room. **No opt-out for the position:** a chip inside the plot has to cover some mark. Resize the
|
|
1185
|
+
line with `--basalt-spark-readout-h` (chip and reserve move together); the readout itself is off under an
|
|
1186
|
+
`aria-hidden` ancestor.
|
|
1187
|
+
|
|
1188
|
+
**Changed default — chart error body.** A `ChartCard` (or any chart) error is StatCard's anatomy: a
|
|
1189
|
+
left-aligned stack of dot, "Could not load this chart", the message and `stateAction`; it was a centred
|
|
1190
|
+
"Error" word. The body now grows past the chart's height rather than clip its action. **No opt-out:** the
|
|
1191
|
+
old body clipped Retry at 390px, so there is no layout worth restoring; pass your own `state` copy via the
|
|
1192
|
+
error's message.
|
|
1193
|
+
|
|
1194
|
+
**Changed default — tick size.** Chart tick labels (every kind, `Heatmap` included) are `--vx-text-micro`
|
|
1195
|
+
at every container width; they were the 10px nano rung below 480px. **No opt-out:** one size is the law.
|
|
1196
|
+
|
|
1197
|
+
**Changed default — `Meter` captions.** They wrap with `text-wrap: balance`, and the last two words of a
|
|
1198
|
+
caption `Meter` composes are joined by a no-break space when the last is 6 characters or fewer
|
|
1199
|
+
(`textContent` carries U+00A0 there). **Opt out:** pass a node to `startCaption`/`endCaption` (a node is never
|
|
1200
|
+
glued).
|
|
1201
|
+
|
|
1202
|
+
**Changed default — `BarList variant="thin"`.** The label wraps to two lines before truncating (its `title`
|
|
1203
|
+
has the whole text) and the secondary column takes at most 40% of the list. **No opt-out:** the old width
|
|
1204
|
+
cut titles to a few characters at 390px.
|
|
1205
|
+
|
|
1206
|
+
**Changed default — `StatusVerdict` word.** It is the proportional sans (`--basalt-font-sans`) at the micro
|
|
1207
|
+
size in muted ink, not the mono: it is a sentence fragment, not an UPPERCASE caption. This reaches the
|
|
1208
|
+
`StatCard` tone word, `BarList` secondaries that use it, and the notification centre. **Opt out:** pass
|
|
1209
|
+
`className` with `font-family: var(--basalt-font-mono)`.
|
|
1210
|
+
|
|
1211
|
+
## 2.19.0 — the status dot, ink buttons and Meter refinements
|
|
1212
|
+
|
|
1213
|
+
### Status is a dot and a word, not an edge stripe (`StatCard`, `Callout`, notification centre)
|
|
1214
|
+
|
|
1215
|
+
Wave 34. `StatCard`'s `tone` no longer draws a 3 px coloured rail down the card's leading edge. It
|
|
1216
|
+
now puts a 6 px status dot and a short word on the caption row, after the title and `info` glyph:
|
|
1217
|
+
`good` → `OK`, `warn` → `Watch`, `bad` → `Over`. The dot carries the colour (`VX.status[tone]`);
|
|
1218
|
+
the word is muted ink and carries the meaning, so the verdict no longer rides on colour alone. Screen
|
|
1219
|
+
readers still hear the full phrase ("Past the severe threshold") from a visually hidden sibling, not a
|
|
1220
|
+
bare "Over".
|
|
1221
|
+
|
|
1222
|
+
Two other shipped status edges went the same way, each visible without any prop change:
|
|
1223
|
+
|
|
1224
|
+
- **`Callout`** loses its 2 px coloured left border. The tint, icon and title still carry the kind's
|
|
1225
|
+
colour (`info` / `good` / `warn` / `bad`), and a visually hidden kind word ("Info", "Success",
|
|
1226
|
+
"Warning", "Error") means a title-less callout is never tint-only. A consumer's CSS that restyled
|
|
1227
|
+
the border has nothing to target.
|
|
1228
|
+
- **Notification-centre rows** (`NotificationCenter`) lose their 3 px coloured leading border and show
|
|
1229
|
+
a 6 px status dot plus the intent as a visible muted word ("Success", "Error", "Warning", "Info")
|
|
1230
|
+
before the title, or before the message on an untitled row. The `info` dot is neutral ink, not the
|
|
1231
|
+
accent.
|
|
1232
|
+
|
|
1233
|
+
`tone?: 'good' | 'warn' | 'bad'` keeps its API, and omitting it still renders neither dot nor word.
|
|
1234
|
+
There is no opt-out: a coloured edge for status is retired (owner decision). A consumer's own
|
|
1235
|
+
`[data-tone]` CSS that targeted the rail element should target the card (`[data-tone]` stays on the
|
|
1236
|
+
root) or drop the rule.
|
|
1237
|
+
|
|
1238
|
+
The shipped `basalt-design-reviewer` now fails a status drawn as a coloured edge stripe (Craft 4,
|
|
1239
|
+
Expression 3), so boards that passed before this release can fail now: re-score them. The verdict
|
|
1240
|
+
words (`OK`, `Watch`, `Over`, and the phrases screen readers hear) are fixed English; for i18n, omit
|
|
1241
|
+
`tone` and render your own dot and word.
|
|
1242
|
+
|
|
1243
|
+
### Light and outline Buttons are ink
|
|
1244
|
+
|
|
1245
|
+
A `Button` or `ActionIcon` with `variant="light"` or `variant="outline"` and no `color` used to paint
|
|
1246
|
+
the primary (accent) colour. It is now ink: `light` takes the subtle surface (hover one ink step) with
|
|
1247
|
+
an ink label; `outline` takes the surface border with an ink label and the subtle-surface hover.
|
|
1248
|
+
Only `variant="filled"` and any explicit `color=` carry the accent. `default`, `filled`,
|
|
1249
|
+
`transparent` and `white` are unchanged, as are disabled, loading and focus-ring behaviour.
|
|
1250
|
+
|
|
1251
|
+
An empty or `null` `color` now counts as unnamed everywhere, matching Mantine's own
|
|
1252
|
+
`color || primaryColor`: `subtle` Buttons and ActionIcons and the `Tabs` underline with `color=""` or
|
|
1253
|
+
`color={null}` take ink too, where they kept the accent before.
|
|
1254
|
+
|
|
1255
|
+
Opt out: name the primary colour explicitly — `color="<primary>"`, your theme's `primaryColor` name.
|
|
1256
|
+
Omitting `color`, or passing `""` or `null`, does not restore the accent.
|
|
1257
|
+
|
|
1258
|
+
### `Meter` and `BarList` refinements since 2.18.0
|
|
1259
|
+
|
|
1260
|
+
No export, prop or type changes; the rendering moved after the Wave 34 board rounds:
|
|
1261
|
+
|
|
1262
|
+
- **`Meter` categorical `segments`** (no forecast part) caption every part under the track (swatch, name,
|
|
1263
|
+
value) and drop the default start caption that stated the total; pass `startCaption` to keep a total.
|
|
1264
|
+
- **`Meter` zones** name every zone on the band (the holding zone in ink and a weight step, a wrapped list
|
|
1265
|
+
when the names would collide) and anchor the reading at the marker; the start caption is the bare reading,
|
|
1266
|
+
no longer `Zone · reading`.
|
|
1267
|
+
- **`Meter` captions** wrap and never truncate; the ring value is on the hero type role and the ring grows
|
|
1268
|
+
square when the value is wider than its inner circle; ticks and the marker take the `fine` radius.
|
|
1269
|
+
- **`Meter` in a `StatCard` visual (`sparkline`) slot** sizes to its content and keeps the card inset
|
|
1270
|
+
instead of a 22 px bleed. The slot's loading skeleton keeps the card inset on both sides.
|
|
1271
|
+
- **`BarList`**: the bar spans the label column only, so a full-scale bar ends before its value; value and
|
|
1272
|
+
secondary are shared grid columns, and the secondary is `sm`.
|
|
1273
|
+
- A selector that targeted the old markup (`li > span[aria-hidden]` for a BarList bar) needs `[data-bar-track]`.
|
|
1274
|
+
|
|
1049
1275
|
## 2.18.0
|
|
1050
1276
|
|
|
1051
1277
|
### Status text derived per surface
|
|
@@ -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. A
|
|
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 status is a dot plus a word, or the value's own ink; a coloured edge stripe or rail down a card, row or callout for status fails here (Craft 4), and a card's `tone` dot-and-word verdict passes.
|
|
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 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.
|
|
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. A status drawn as a coloured leading-edge stripe fails here too: it is decoration, where the dot and the word carry the verdict in shape and text.
|
|
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
|
|
|
@@ -33,5 +33,5 @@ Every cartesian chart is `CartesianChart` or a kind built on it; props are in th
|
|
|
33
33
|
|
|
34
34
|
- `@visx/*` is banned. [basalt/chart-engine-boundary]
|
|
35
35
|
- Import engine marks only from `@tanstack/charts/{line,area,area-x,bar,rect,rule,dot,tick,text,vector,link,arrow,difference,stack,scales/*,transform/*,mark/decorative,d3/shape,types}`; the bare root and `@tanstack/charts/react` are errors. [basalt/chart-engine-boundary]
|
|
36
|
-
- Wrap a chart kind in `ChartCard`, never a raw `Card` or `Paper`. [basalt/chart-in-raw-surface]
|
|
36
|
+
- Wrap a chart kind in `ChartCard`, never a raw `Card` or `Paper`; its headline figure and period go in `facts`, not a filler `subtitle`. [basalt/chart-in-raw-surface] [type ChartCardProps]
|
|
37
37
|
- Series colors are `{ light, dark }` pairs from the app's series file (`defineSeries`); write no hex or `rgba()` in a chart file. [check-theme raw-hex] [check-theme raw-color-fn]
|
|
@@ -32,7 +32,7 @@ paths:
|
|
|
32
32
|
## Surfaces
|
|
33
33
|
|
|
34
34
|
- Never pass `withBorder` to `Card` or `Paper`; the theme draws the ring (`<Card.Section withBorder>` is fine). [check-theme card-with-border]
|
|
35
|
-
- Card/Paper
|
|
35
|
+
- The theme owns the Card/Paper inset (12/16) and radius: write no `p`, `padding`, `py`, `px` or `radius`, not even `py="sm" px="md"`. Flush is `variant="flush"` (whole card) or `<Card.Section>` (a full-bleed region). [basalt/card-inset]
|
|
36
36
|
- Lay out with `Box`/`Flex`/`Grid`/`Stack`/`Group`, not a `<div>` with `style`. [check-theme raw-html-layout] [check-theme hidden-inline-style]
|
|
37
37
|
- No inline `display: flex|grid`; no inline spacing; spacing props take `xs..xl`. [check-theme inline-display] [check-theme inline-spacing] [check-theme raw-spacing]
|
|
38
38
|
- Inputs come from `@mantine/core`, never `<input>`, `<select>` or `<textarea>`. [check-theme raw-form-control]
|
|
@@ -74,7 +74,7 @@ const columns = [
|
|
|
74
74
|
col.accessor('revenue', {
|
|
75
75
|
header: 'Revenue',
|
|
76
76
|
sortFn: 'basic', // v9 `sortFn`, not v8 `sortingFn`
|
|
77
|
-
meta: { align: 'right' }, //
|
|
77
|
+
meta: { align: 'right' }, // table number columns are mono-numeral by default (Wave 37 revisits the table face); `numeral: false` opts out
|
|
78
78
|
cell: (c) => money(c.getValue(), { currency: 'USD' }),
|
|
79
79
|
}),
|
|
80
80
|
]
|
|
@@ -20,7 +20,7 @@ Method only; the law is `.claude/rules/basalt-*.md` and `./DESIGN.md`.
|
|
|
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) |
|
|
21
21
|
| Distribution | small axis-less histogram | `Bars` in a `ChartCard` |
|
|
22
22
|
| Status over time | band strip; a heat grid for daily data | `BandStrip` / `Heatmap` |
|
|
23
|
-
| Many rows, several attributes | table, right-aligned
|
|
23
|
+
| Many rows, several attributes | table, right-aligned tabular figures | `BasaltDataTable` |
|
|
24
24
|
| Nothing yet / failed | why + what to do | `EmptyState` / the component's own state |
|
|
25
25
|
|
|
26
26
|
No row fits the data → say so; never default to a number in a box.
|
|
@@ -13,7 +13,7 @@ theme's config knobs (see the `basalt-tokens` rule) — so nothing here restates
|
|
|
13
13
|
|
|
14
14
|
- **Accent hue:** {{ACCENT_HUE}} (default: the shipped seed; a single-series mark stays neutral)
|
|
15
15
|
- **Theme knobs:** _(none — `createBasaltTheme()` bare)_ · record any non-zero `derive`/`fonts`/
|
|
16
|
-
`radius`/`density` level here, with its reason.
|
|
16
|
+
`radius`/`density` level or `--basalt-font-numeral` override here, with its reason.
|
|
17
17
|
|
|
18
18
|
## Series dictionary
|
|
19
19
|
|
package/configs/oxlint-plugin.js
CHANGED
|
@@ -588,15 +588,21 @@ const rawSizeLiteral = {
|
|
|
588
588
|
|
|
589
589
|
const CARD_TAGS = new Set(['Card', 'Paper'])
|
|
590
590
|
|
|
591
|
-
// The
|
|
592
|
-
// `
|
|
593
|
-
//
|
|
594
|
-
//
|
|
591
|
+
// The THEME owns the inset (Wave 35): a bare Card/Paper resolves to the level-0 12/16 pair
|
|
592
|
+
// (`cardInsetY`/`cardInsetX` = `SPACE_SCALE.sm`/`.md`; `tokens/space-scale.test.ts` pins that), so
|
|
593
|
+
// the idiom is to write nothing. The pair spelled out (`py="sm" px="md"`) is therefore REDUNDANT, any
|
|
594
|
+
// other explicit inset/radius is off-idiom, and flush is `variant="flush"` (whole card) or
|
|
595
|
+
// `Card.Section` (a full-bleed region of a padded card). `p`/`padding` take one value, so no
|
|
596
|
+
// uniform form can equal the 12/16 pair — they are always off-idiom.
|
|
595
597
|
export const CARD_INSET_PY = 'sm'
|
|
596
598
|
export const CARD_INSET_PX = 'md'
|
|
597
599
|
const CARD_INSET_MESSAGE =
|
|
598
|
-
'Card/Paper is off the card idiom —
|
|
599
|
-
|
|
600
|
+
'Card/Paper is off the card idiom — the theme owns the 12/16 inset and radius, so write no ' +
|
|
601
|
+
'p/padding/py/px/radius. Flush whole card: variant="flush"; full-bleed region in a padded card: ' +
|
|
602
|
+
'<Card.Section>; a deliberate exception: {/* theme-allow card-inset — reason */}. (basalt/card-inset)'
|
|
603
|
+
const CARD_INSET_REDUNDANT_MESSAGE =
|
|
604
|
+
'Card/Paper inset is redundant — the theme owns it (12/16, density-scaled); delete ' +
|
|
605
|
+
'py="sm" px="md". (basalt/card-inset)'
|
|
600
606
|
|
|
601
607
|
function isStringLiteral(node) {
|
|
602
608
|
return node !== null && node.type === 'Literal' && typeof node.value === 'string'
|
|
@@ -606,7 +612,7 @@ function attrValue(attr) {
|
|
|
606
612
|
return unwrapExpressionContainer(attr.value)
|
|
607
613
|
}
|
|
608
614
|
|
|
609
|
-
// Ships: warn (grace → 2.
|
|
615
|
+
// Ships: warn (grace → 2.26.0)
|
|
610
616
|
const cardInset = {
|
|
611
617
|
meta: {
|
|
612
618
|
type: 'suggestion',
|
|
@@ -639,16 +645,24 @@ const cardInset = {
|
|
|
639
645
|
for (const name of ['p', 'padding', 'radius']) {
|
|
640
646
|
if (attrs.has(name)) offenders.push(attrs.get(name))
|
|
641
647
|
}
|
|
642
|
-
// The
|
|
643
|
-
//
|
|
644
|
-
const
|
|
645
|
-
const
|
|
646
|
-
if (
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
648
|
+
// The theme's own pair, restated, is redundant; any other py/px (or a lone half) is
|
|
649
|
+
// off-idiom.
|
|
650
|
+
const isThemePair = isExactly(py, CARD_INSET_PY) && isExactly(px, CARD_INSET_PX)
|
|
651
|
+
const redundant = []
|
|
652
|
+
if (isThemePair) redundant.push(py, px)
|
|
653
|
+
else {
|
|
654
|
+
if (py) offenders.push(py)
|
|
655
|
+
if (px) offenders.push(px)
|
|
656
|
+
}
|
|
657
|
+
|
|
658
|
+
for (const [list, message] of [
|
|
659
|
+
[offenders, CARD_INSET_MESSAGE],
|
|
660
|
+
[redundant, CARD_INSET_REDUNDANT_MESSAGE],
|
|
661
|
+
]) {
|
|
662
|
+
for (const attr of list) {
|
|
663
|
+
if (hasThemeAllow(context, attr, 'card-inset')) continue
|
|
664
|
+
context.report({ node: attr, message })
|
|
665
|
+
}
|
|
652
666
|
}
|
|
653
667
|
},
|
|
654
668
|
}
|
|
@@ -4224,8 +4238,8 @@ const routeViewTransition = {
|
|
|
4224
4238
|
export const PLUGIN_RULE_GRACE = {
|
|
4225
4239
|
'card-inset': {
|
|
4226
4240
|
since: '2.16.0',
|
|
4227
|
-
promote: '2.
|
|
4228
|
-
why: 'Tightened in 2.16.0: only py="sm" px="md" together (or neither)
|
|
4241
|
+
promote: '2.26.0',
|
|
4242
|
+
why: 'Tightened in 2.16.0: only py="sm" px="md" together (or neither) passed. Inverted in 2.20.0 (Wave 35): the theme owns the 12/16 inset, so the pair is now a "redundant" finding and "neither" is the idiom; flush is variant="flush" or Card.Section. The redundant pair is a NEW finding class first shipping in 2.20.0, so consumers get the full grace again: promote moved 2.24.0 → 2.26.0.',
|
|
4229
4243
|
},
|
|
4230
4244
|
}
|
|
4231
4245
|
|
|
@@ -249,14 +249,44 @@ describe('basalt/card-inset', () => {
|
|
|
249
249
|
})
|
|
250
250
|
|
|
251
251
|
it.each([
|
|
252
|
-
['the sm/md pair', '<Paper py="sm" px="md" />'],
|
|
253
|
-
['the pair in either order', '<Card px="md" py="sm" />'],
|
|
254
252
|
['no padding at all', '<Card />'],
|
|
253
|
+
['a bare Paper', '<Paper />'],
|
|
254
|
+
['the flush Card', '<Card variant="flush" />'],
|
|
255
|
+
['the flush Paper', '<Paper variant="flush" />'],
|
|
256
|
+
['a full-bleed Card.Section in a padded card', '<Card><Card.Section /></Card>'],
|
|
257
|
+
[
|
|
258
|
+
'an explicit inset with a waiver',
|
|
259
|
+
'<div>\n{/* theme-allow card-inset — hero map */}\n<Card p={0} />\n</div>',
|
|
260
|
+
],
|
|
255
261
|
])('does NOT flag %s', (_name, jsx) => {
|
|
256
262
|
const { rules } = run(`export const C = () => ${jsx}\n`)
|
|
257
263
|
expect(rules).not.toContain('card-inset')
|
|
258
264
|
})
|
|
259
265
|
|
|
266
|
+
// The theme owns the 12/16 inset (Wave 35), so restating it is noise that drifts.
|
|
267
|
+
it.each([
|
|
268
|
+
['the sm/md pair', '<Paper py="sm" px="md" />'],
|
|
269
|
+
['the pair in either order', '<Card px="md" py="sm" />'],
|
|
270
|
+
['the pair in expression containers', '<Card py={"sm"} px={"md"} />'],
|
|
271
|
+
])('flags %s as redundant', (_name, jsx) => {
|
|
272
|
+
const { rules, output } = run(`export const C = () => ${jsx}\n`)
|
|
273
|
+
expect(rules).toContain('card-inset')
|
|
274
|
+
expect(output).toContain('redundant')
|
|
275
|
+
expect(output).toContain('theme owns')
|
|
276
|
+
})
|
|
277
|
+
|
|
278
|
+
it('names the flush idiom on any other explicit inset, and not "redundant"', () => {
|
|
279
|
+
const { output } = run(`export const C = () => <Card py={0} px={0} />\n`)
|
|
280
|
+
expect(output).toContain('variant="flush"')
|
|
281
|
+
expect(output).toContain('Card.Section')
|
|
282
|
+
expect(output).not.toContain('redundant')
|
|
283
|
+
})
|
|
284
|
+
|
|
285
|
+
it('flush does not excuse an explicit padding next to it', () => {
|
|
286
|
+
const { rules } = run(`export const C = () => <Card variant="flush" p="lg" />\n`)
|
|
287
|
+
expect(rules).toContain('card-inset')
|
|
288
|
+
})
|
|
289
|
+
|
|
260
290
|
it('ships warn through its grace minor, so a flagged card does not fail the run', () => {
|
|
261
291
|
const { code, rules } = run(`export const C = () => <Card p="lg" />\n`)
|
|
262
292
|
// The fixture config sets the rule to error; the SHIPPED level is pinned by the ledger tests.
|