basalt-ui 1.19.0 → 1.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/AGENTS.md +15 -1
- package/CHANGELOG.md +27 -0
- package/MIGRATING.md +228 -0
- package/README.md +53 -9
- package/agent/rules/basalt-app.md +43 -0
- package/agent/rules/basalt-charts.md +26 -14
- package/agent/rules/basalt-mantine.md +25 -10
- package/agent/rules/basalt-router.md +22 -10
- package/agent/rules/basalt-tokens.md +75 -6
- package/agent/skills/basalt-app/SKILL.md +42 -6
- package/configs/check.yml +11 -4
- package/configs/lefthook.yml +21 -2
- package/configs/oxlint-plugin.js +515 -25
- package/configs/oxlint-plugin.test.ts +383 -10
- package/configs/oxlint.json +10 -1
- package/dist/agent/stick-to-bottom.js +1 -1
- package/dist/agent-chat/thread-detail-panel.js +1 -1
- package/dist/agent-chat/thread-message.js +2 -2
- package/dist/agent-chat/tool-chip.js +1 -1
- package/dist/charts/kinds/Donut.d.ts.map +1 -1
- package/dist/charts/kinds/Donut.js +1 -1
- package/dist/charts/primitives/ChartLegend.js +2 -2
- package/dist/charts/primitives/ChartTooltip.js +1 -1
- package/dist/cli/index.d.ts +107 -15
- package/dist/cli/index.d.ts.map +1 -1
- package/dist/cli/index.js +610 -72
- package/dist/cli/toolchain-wiring.test.d.ts +2 -0
- package/dist/cli/toolchain-wiring.test.d.ts.map +1 -0
- package/dist/dashboard/delta-badge.js +2 -2
- package/dist/dashboard/stat-card.js +1 -1
- package/dist/data/virtual-list.js +5 -5
- package/dist/guard/index.d.ts +56 -2
- package/dist/guard/index.d.ts.map +1 -1
- package/dist/guard/index.js +326 -59
- package/dist/guard/types.d.ts +25 -5
- package/dist/guard/types.d.ts.map +1 -1
- package/dist/register.d.ts +25 -0
- package/dist/register.d.ts.map +1 -1
- package/dist/shell/app-mobile-nav.d.ts.map +1 -1
- package/dist/shell/app-mobile-nav.js +14 -14
- package/dist/shell/app-mobile-nav.module.css +44 -11
- package/dist/shell/app-mobile-nav.module.css.d.ts +1 -1
- package/dist/surfaces.d.ts +1 -1
- package/dist/surfaces.js +1 -1
- package/dist/tokens/index.d.ts +3 -3
- package/dist/tokens/index.d.ts.map +1 -1
- package/dist/tokens/index.js +2 -0
- package/dist/tokens/palette.d.ts +35 -27
- package/dist/tokens/palette.d.ts.map +1 -1
- package/dist/tokens/palette.js +24 -18
- package/dist/tokens.css +19 -17
- package/dist/vite-color-mix.js +2 -2
- package/llms.txt +3 -3
- package/package.json +4 -3
- package/src/agent/stick-to-bottom.tsx +1 -1
- package/src/agent-chat/thread-detail-panel.tsx +1 -1
- package/src/agent-chat/thread-message.tsx +3 -3
- package/src/agent-chat/tool-chip.tsx +1 -1
- package/src/charts/kinds/Donut.tsx +2 -1
- package/src/charts/primitives/ChartLegend.tsx +2 -2
- package/src/charts/primitives/ChartTooltip.tsx +1 -1
- package/src/cli/index.ts +1070 -99
- package/src/cli/init-sync.test.ts +19 -3
- package/src/cli/tokens-css.test.ts +27 -14
- package/src/cli/toolchain-wiring.test.ts +694 -0
- package/src/dashboard/delta-badge.tsx +3 -3
- package/src/dashboard/stat-card.tsx +1 -1
- package/src/data/virtual-list.tsx +8 -8
- package/src/guard/check-source.test.ts +663 -11
- package/src/guard/index.ts +727 -94
- package/src/guard/types.ts +29 -4
- package/src/register.ts +32 -0
- package/src/shell/app-mobile-nav.module.css +44 -11
- package/src/shell/app-mobile-nav.module.css.d.ts +1 -1
- package/src/shell/app-mobile-nav.test.tsx +34 -0
- package/src/shell/app-mobile-nav.tsx +16 -5
- package/src/surfaces.ts +1 -1
- package/src/theme/density-relations.test.ts +8 -5
- package/src/theme/spacing.test.ts +2 -0
- package/src/theme-toggle/index.tsx +2 -2
- package/src/tokens/index.ts +5 -3
- package/src/tokens/palette.ts +24 -18
- package/src/vite-color-mix.ts +2 -2
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "basalt-ui",
|
|
3
|
-
"version": "1.
|
|
3
|
+
"version": "1.20.0",
|
|
4
4
|
"description": "Opinionated framework for Mantine-based React apps — theme, app shell, visx charts, toolchain presets",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"charts",
|
|
@@ -37,7 +37,8 @@
|
|
|
37
37
|
"llms.txt",
|
|
38
38
|
"AGENTS.md",
|
|
39
39
|
"README.md",
|
|
40
|
-
"CHANGELOG.md"
|
|
40
|
+
"CHANGELOG.md",
|
|
41
|
+
"MIGRATING.md"
|
|
41
42
|
],
|
|
42
43
|
"type": "module",
|
|
43
44
|
"sideEffects": [
|
|
@@ -131,7 +132,7 @@
|
|
|
131
132
|
},
|
|
132
133
|
"scripts": {
|
|
133
134
|
"build": "tsup && tsc --emitDeclarationOnly --declarationMap && bun scripts/copy-assets.mjs && bun scripts/gen-tokens-css.mjs && bun scripts/fix-esm-extensions.mjs",
|
|
134
|
-
"typecheck": "tsc --noEmit",
|
|
135
|
+
"typecheck": "tsc --noEmit && tsc -p tests/layout/tsconfig.json",
|
|
135
136
|
"test": "cd ../.. && bun test packages/basalt-ui",
|
|
136
137
|
"pack-test": "bash scripts/pack-test.sh",
|
|
137
138
|
"prepack": "bun run build",
|
|
@@ -39,7 +39,7 @@ type WrapperProps = {
|
|
|
39
39
|
/** Plain scrollable container rendered when use-stick-to-bottom peer is absent. */
|
|
40
40
|
function PlainContainerFallback({ children, className, style }: WrapperProps): JSX.Element {
|
|
41
41
|
const props: { className?: string; style?: CSSProperties } = {
|
|
42
|
-
// theme-allow — scroll anchoring needs a real scrollable node it owns, not a ScrollArea.
|
|
42
|
+
// theme-allow raw-scroll-container — scroll anchoring needs a real scrollable node it owns, not a ScrollArea.
|
|
43
43
|
style: { overflowY: 'auto', ...style },
|
|
44
44
|
}
|
|
45
45
|
if (className !== undefined) props.className = className
|
|
@@ -135,7 +135,7 @@ export function ThreadDetailPanel({
|
|
|
135
135
|
<BasaltStickToBottom
|
|
136
136
|
style={{
|
|
137
137
|
height: '100%',
|
|
138
|
-
// theme-allow — BasaltStickToBottom owns this scroll node (see stick-to-bottom.tsx).
|
|
138
|
+
// theme-allow raw-scroll-container — BasaltStickToBottom owns this scroll node (see stick-to-bottom.tsx).
|
|
139
139
|
overflowY: 'auto',
|
|
140
140
|
padding: 'var(--vx-space-agent-transcript-inset)',
|
|
141
141
|
}}
|
|
@@ -615,7 +615,7 @@ type VirtualizedTranscriptProps = {
|
|
|
615
615
|
*/
|
|
616
616
|
function NonVirtualizedRows({ rows, height }: VirtualizedTranscriptProps): JSX.Element {
|
|
617
617
|
return (
|
|
618
|
-
// theme-allow — degrade target owns its own scroll node, same as the real virtualizer below.
|
|
618
|
+
// theme-allow raw-scroll-container — degrade target owns its own scroll node, same as the real virtualizer below.
|
|
619
619
|
<Box style={{ height, overflow: 'auto' }}>
|
|
620
620
|
<Stack gap="sm">
|
|
621
621
|
{rows.map((row) => (
|
|
@@ -895,7 +895,7 @@ const LazyVirtualizedRows = lazy(() =>
|
|
|
895
895
|
})
|
|
896
896
|
|
|
897
897
|
return (
|
|
898
|
-
// theme-allow — TanStack Virtual measures/scrolls this element (never nest in BasaltStickToBottom, see ./virtualize).
|
|
898
|
+
// theme-allow raw-scroll-container — TanStack Virtual measures/scrolls this element (never nest in BasaltStickToBottom, see ./virtualize).
|
|
899
899
|
<Box ref={parentRef} style={{ height, overflow: 'auto' }}>
|
|
900
900
|
<Box style={{ height: virtualizer.getTotalSize(), position: 'relative' }}>
|
|
901
901
|
{virtualizer.getVirtualItems().map((virtualItem) => {
|
|
@@ -938,7 +938,7 @@ const LazyVirtualizedRows = lazy(() =>
|
|
|
938
938
|
* flash without paying that cost — it settles state before any row has meaningfully mounted.
|
|
939
939
|
*/
|
|
940
940
|
function VirtualizeSuspenseFallback({ height }: { readonly height: number | string }): JSX.Element {
|
|
941
|
-
// theme-allow — placeholder owns its own scroll node, matching the real virtualizer's shape.
|
|
941
|
+
// theme-allow raw-scroll-container — placeholder owns its own scroll node, matching the real virtualizer's shape.
|
|
942
942
|
return <Box style={{ height, overflow: 'auto' }} />
|
|
943
943
|
}
|
|
944
944
|
|
|
@@ -138,7 +138,7 @@ export function ToolChip({
|
|
|
138
138
|
width: 6,
|
|
139
139
|
height: 6,
|
|
140
140
|
flexShrink: 0,
|
|
141
|
-
borderRadius: '50%', // theme-allow
|
|
141
|
+
borderRadius: '50%', // theme-allow raw-surface — a 6px state dot is a circle, not a surface corner
|
|
142
142
|
backgroundColor: dotToken,
|
|
143
143
|
}}
|
|
144
144
|
/>
|
|
@@ -208,7 +208,8 @@ function DonutPlot<K extends string = SeriesKey>(props: DonutPlotProps<K>) {
|
|
|
208
208
|
style={{
|
|
209
209
|
position: 'absolute',
|
|
210
210
|
inset: 0,
|
|
211
|
-
|
|
211
|
+
// Centering over the donut hole; charts/ is Mantine-free, so Center is unavailable here.
|
|
212
|
+
display: 'flex',
|
|
212
213
|
alignItems: 'center',
|
|
213
214
|
justifyContent: 'center',
|
|
214
215
|
pointerEvents: 'none',
|
|
@@ -158,7 +158,7 @@ function LegendSwatch({ item, idPrefix }: { item: LegendEntry; idPrefix: string
|
|
|
158
158
|
style={{
|
|
159
159
|
width: 11,
|
|
160
160
|
height: 11,
|
|
161
|
-
borderRadius: 3, // theme-allow
|
|
161
|
+
borderRadius: 3, // theme-allow raw-surface — sub-scale legend-swatch corner, below the 4px radius floor
|
|
162
162
|
backgroundColor: item.color,
|
|
163
163
|
opacity: item.fillOpacity ?? 0.7,
|
|
164
164
|
flexShrink: 0,
|
|
@@ -211,7 +211,7 @@ function LegendChildSwatch({ item }: { item: LegendEntry }) {
|
|
|
211
211
|
style={{
|
|
212
212
|
width: 10,
|
|
213
213
|
height: 10,
|
|
214
|
-
borderRadius: 2, // theme-allow
|
|
214
|
+
borderRadius: 2, // theme-allow raw-surface — sub-scale legend-swatch corner, below the 4px radius floor
|
|
215
215
|
backgroundColor: item.color,
|
|
216
216
|
opacity: item.fillOpacity ?? 0.7,
|
|
217
217
|
flexShrink: 0,
|
|
@@ -121,7 +121,7 @@ export function TooltipRow({
|
|
|
121
121
|
style={{
|
|
122
122
|
width: 8,
|
|
123
123
|
height: 8,
|
|
124
|
-
borderRadius: 2, // theme-allow
|
|
124
|
+
borderRadius: 2, // theme-allow raw-surface — sub-scale tooltip micro-corner, below the 4px radius floor
|
|
125
125
|
backgroundColor: color,
|
|
126
126
|
flexShrink: 0,
|
|
127
127
|
}}
|