@nexub/tokens 6.9.0 → 7.0.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/bin/nexub-migrate.mjs +6 -7
- package/package.json +1 -1
package/bin/nexub-migrate.mjs
CHANGED
|
@@ -380,7 +380,6 @@ function migrateComponents(src) {
|
|
|
380
380
|
// Adds the 5.x value as an explicit prop, so upgrading to 6.0 changes nothing.
|
|
381
381
|
const selection = (a) => (a.enableRowSelection && !a.selectionColumn ? ' selectionColumn={false}' : null);
|
|
382
382
|
const PINS = {
|
|
383
|
-
Autocomplete: (a) => (a.mode ? null : ' mode="inline"'),
|
|
384
383
|
DataTable: selection,
|
|
385
384
|
DataTableVirtual: selection,
|
|
386
385
|
};
|
|
@@ -456,8 +455,8 @@ export function migrateSource(src, { ext, rules = new Set(DEFAULT_RULES), fix =
|
|
|
456
455
|
for (const m of src.matchAll(/<StepIndicator\b/g))
|
|
457
456
|
items.push({ at: m.index, rule: 'removed-in-7', message: 'StepIndicator (@nexub/patterns) is removed in 7.0: use <Stepper orientation="vertical" current={…}> from @nexub/react (currentStep -> current)' });
|
|
458
457
|
if (/@nexub\/react['"/]/.test(src))
|
|
459
|
-
for (const m of src.matchAll(/<Autocomplete\b[^>]*\bmode
|
|
460
|
-
items.push({ at: m.index, rule: 'removed-in-7', message: 'Autocomplete mode
|
|
458
|
+
for (const m of src.matchAll(/<Autocomplete\b[^>]*\bmode=/g))
|
|
459
|
+
items.push({ at: m.index, rule: 'removed-in-7', message: 'Autocomplete `mode` is removed in 7.0 (the popover is the only layout): remove it; for an always-open list use the Combobox parts' });
|
|
461
460
|
}
|
|
462
461
|
// Rewrites never add or remove newlines, so offsets in src and text share line numbers.
|
|
463
462
|
const lineOf = (at) => src.slice(0, at).split('\n').length;
|
|
@@ -521,11 +520,11 @@ Rules:
|
|
|
521
520
|
(dot and non-JSX uses reported); *Props types renamed
|
|
522
521
|
tailwind-3-preset report the Tailwind 3 preset (@nexub/tokens/tailwind), removed in 4.0;
|
|
523
522
|
use Tailwind 4 with @import "@nexub/tokens/tailwind.css"
|
|
524
|
-
keep-5-defaults opt-in: keep 5.x behaviour
|
|
525
|
-
<
|
|
526
|
-
|
|
523
|
+
keep-5-defaults opt-in: keep 5.x behaviour by pinning the defaults 6.0 changed:
|
|
524
|
+
<DataTable enableRowSelection> gets selectionColumn={false}
|
|
525
|
+
(Autocomplete's inline layout is gone in 7.0, so it is not pinned)
|
|
527
526
|
removed-in-7 report what 7.0 removes: <StepIndicator> (use Stepper) and
|
|
528
|
-
|
|
527
|
+
Autocomplete's mode prop
|
|
529
528
|
|
|
530
529
|
Ignored: node_modules, dist, build, .next, out, coverage, files over 1 MB.
|
|
531
530
|
Exit codes: 0 ok, 1 --check found something, 2 usage error.`;
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@nexub/tokens",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "7.0.0",
|
|
4
4
|
"description": "Design tokens for Nexub Design System — colours, typography, spacing, radii, shadows, and motion as CSS variables, a Tailwind 4 theme, Figma variables and native (React Native, SwiftUI, Compose) tokens.",
|
|
5
5
|
"type": "module",
|
|
6
6
|
"license": "MIT",
|