@digdir/designsystemet 1.0.6 → 1.0.7
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/configs/digdir.config.json +59 -0
- package/configs/test-tokens.config.json +45 -0
- package/dist/bin/designsystemet.js +45 -58
- package/dist/config.schema.json +38 -27
- package/dist/src/config.d.ts +24 -176
- package/dist/src/config.d.ts.map +1 -1
- package/dist/src/config.js +22 -32
- package/dist/src/index.js +17 -20
- package/dist/src/migrations/beta-to-v1.js +2 -2
- package/dist/src/migrations/codemods/css/run.js +2 -2
- package/dist/src/migrations/color-rename-next49.js +2 -2
- package/dist/src/migrations/index.js +2 -2
- package/dist/src/scripts/createJsonSchema.js +32 -1292
- package/dist/src/scripts/update-design-tokens.js +4 -4
- package/dist/src/scripts/update-template.js +7 -7
- package/dist/src/tokens/build.js +20 -23
- package/dist/src/tokens/create/generators/$designsystemet.js +17 -17
- package/dist/src/tokens/create/write.js +19 -19
- package/dist/src/tokens/format.js +17 -20
- package/dist/src/tokens/index.js +17 -20
- package/dist/src/tokens/process/theme.d.ts.map +1 -1
- package/dist/src/tokens/process/theme.js +17 -20
- package/dist/src/utils.js +1 -1
- package/package.json +17 -17
package/dist/src/config.d.ts
CHANGED
|
@@ -1,49 +1,17 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
1
|
+
import { z } from 'zod/v4';
|
|
2
2
|
export declare function mapPathToOptionName(path: (string | number)[]): string | undefined;
|
|
3
3
|
export declare const colorRegex: RegExp;
|
|
4
4
|
declare const themeSchema: z.ZodObject<{
|
|
5
5
|
colors: z.ZodObject<{
|
|
6
|
-
main: z.
|
|
7
|
-
support: z.ZodDefault<z.ZodOptional<z.
|
|
8
|
-
neutral: z.
|
|
9
|
-
},
|
|
10
|
-
neutral: `#${string}`;
|
|
11
|
-
main: Record<string, `#${string}`>;
|
|
12
|
-
support: Record<string, `#${string}`>;
|
|
13
|
-
}, {
|
|
14
|
-
neutral: string;
|
|
15
|
-
main: Record<string, string>;
|
|
16
|
-
support?: Record<string, string> | undefined;
|
|
17
|
-
}>;
|
|
6
|
+
main: z.ZodRecord<z.ZodString, z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
|
|
7
|
+
support: z.ZodDefault<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>>>;
|
|
8
|
+
neutral: z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>;
|
|
9
|
+
}, z.core.$strip>;
|
|
18
10
|
typography: z.ZodOptional<z.ZodObject<{
|
|
19
11
|
fontFamily: z.ZodString;
|
|
20
|
-
},
|
|
21
|
-
fontFamily: string;
|
|
22
|
-
}, {
|
|
23
|
-
fontFamily: string;
|
|
24
|
-
}>>;
|
|
12
|
+
}, z.core.$strip>>;
|
|
25
13
|
borderRadius: z.ZodOptional<z.ZodNumber>;
|
|
26
|
-
},
|
|
27
|
-
colors: {
|
|
28
|
-
neutral: `#${string}`;
|
|
29
|
-
main: Record<string, `#${string}`>;
|
|
30
|
-
support: Record<string, `#${string}`>;
|
|
31
|
-
};
|
|
32
|
-
typography?: {
|
|
33
|
-
fontFamily: string;
|
|
34
|
-
} | undefined;
|
|
35
|
-
borderRadius?: number | undefined;
|
|
36
|
-
}, {
|
|
37
|
-
colors: {
|
|
38
|
-
neutral: string;
|
|
39
|
-
main: Record<string, string>;
|
|
40
|
-
support?: Record<string, string> | undefined;
|
|
41
|
-
};
|
|
42
|
-
typography?: {
|
|
43
|
-
fontFamily: string;
|
|
44
|
-
} | undefined;
|
|
45
|
-
borderRadius?: number | undefined;
|
|
46
|
-
}>;
|
|
14
|
+
}, z.core.$strip>;
|
|
47
15
|
/**
|
|
48
16
|
* This defines the structure of the JSON config file
|
|
49
17
|
*/
|
|
@@ -52,155 +20,35 @@ export declare const configFileSchema: z.ZodObject<{
|
|
|
52
20
|
clean: z.ZodOptional<z.ZodBoolean>;
|
|
53
21
|
themes: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
54
22
|
colors: z.ZodObject<{
|
|
55
|
-
main: z.
|
|
56
|
-
support: z.ZodDefault<z.ZodOptional<z.
|
|
57
|
-
neutral: z.
|
|
58
|
-
},
|
|
59
|
-
neutral: `#${string}`;
|
|
60
|
-
main: Record<string, `#${string}`>;
|
|
61
|
-
support: Record<string, `#${string}`>;
|
|
62
|
-
}, {
|
|
63
|
-
neutral: string;
|
|
64
|
-
main: Record<string, string>;
|
|
65
|
-
support?: Record<string, string> | undefined;
|
|
66
|
-
}>;
|
|
23
|
+
main: z.ZodRecord<z.ZodString, z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
|
|
24
|
+
support: z.ZodDefault<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>>>;
|
|
25
|
+
neutral: z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>;
|
|
26
|
+
}, z.core.$strip>;
|
|
67
27
|
typography: z.ZodOptional<z.ZodObject<{
|
|
68
28
|
fontFamily: z.ZodString;
|
|
69
|
-
},
|
|
70
|
-
fontFamily: string;
|
|
71
|
-
}, {
|
|
72
|
-
fontFamily: string;
|
|
73
|
-
}>>;
|
|
29
|
+
}, z.core.$strip>>;
|
|
74
30
|
borderRadius: z.ZodOptional<z.ZodNumber>;
|
|
75
|
-
},
|
|
76
|
-
|
|
77
|
-
neutral: `#${string}`;
|
|
78
|
-
main: Record<string, `#${string}`>;
|
|
79
|
-
support: Record<string, `#${string}`>;
|
|
80
|
-
};
|
|
81
|
-
typography?: {
|
|
82
|
-
fontFamily: string;
|
|
83
|
-
} | undefined;
|
|
84
|
-
borderRadius?: number | undefined;
|
|
85
|
-
}, {
|
|
86
|
-
colors: {
|
|
87
|
-
neutral: string;
|
|
88
|
-
main: Record<string, string>;
|
|
89
|
-
support?: Record<string, string> | undefined;
|
|
90
|
-
};
|
|
91
|
-
typography?: {
|
|
92
|
-
fontFamily: string;
|
|
93
|
-
} | undefined;
|
|
94
|
-
borderRadius?: number | undefined;
|
|
95
|
-
}>>;
|
|
96
|
-
}, "strip", z.ZodTypeAny, {
|
|
97
|
-
themes: Record<string, {
|
|
98
|
-
colors: {
|
|
99
|
-
neutral: `#${string}`;
|
|
100
|
-
main: Record<string, `#${string}`>;
|
|
101
|
-
support: Record<string, `#${string}`>;
|
|
102
|
-
};
|
|
103
|
-
typography?: {
|
|
104
|
-
fontFamily: string;
|
|
105
|
-
} | undefined;
|
|
106
|
-
borderRadius?: number | undefined;
|
|
107
|
-
}>;
|
|
108
|
-
clean?: boolean | undefined;
|
|
109
|
-
outDir?: string | undefined;
|
|
110
|
-
}, {
|
|
111
|
-
themes: Record<string, {
|
|
112
|
-
colors: {
|
|
113
|
-
neutral: string;
|
|
114
|
-
main: Record<string, string>;
|
|
115
|
-
support?: Record<string, string> | undefined;
|
|
116
|
-
};
|
|
117
|
-
typography?: {
|
|
118
|
-
fontFamily: string;
|
|
119
|
-
} | undefined;
|
|
120
|
-
borderRadius?: number | undefined;
|
|
121
|
-
}>;
|
|
122
|
-
clean?: boolean | undefined;
|
|
123
|
-
outDir?: string | undefined;
|
|
124
|
-
}>;
|
|
31
|
+
}, z.core.$strip>>;
|
|
32
|
+
}, z.core.$strip>;
|
|
125
33
|
/**
|
|
126
34
|
* This defines the structure of the final configuration after combining the config file,
|
|
127
35
|
* command-line options and default values.
|
|
128
36
|
*/
|
|
129
37
|
export declare const combinedConfigSchema: z.ZodObject<{
|
|
130
|
-
outDir: z.ZodString
|
|
131
|
-
clean: z.ZodBoolean
|
|
132
|
-
themes: z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
38
|
+
outDir: z.ZodNonOptional<z.ZodOptional<z.ZodString>>;
|
|
39
|
+
clean: z.ZodNonOptional<z.ZodOptional<z.ZodBoolean>>;
|
|
40
|
+
themes: z.ZodNonOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
133
41
|
colors: z.ZodObject<{
|
|
134
|
-
main: z.
|
|
135
|
-
support: z.ZodDefault<z.ZodOptional<z.
|
|
136
|
-
neutral: z.
|
|
137
|
-
},
|
|
138
|
-
neutral: `#${string}`;
|
|
139
|
-
main: Record<string, `#${string}`>;
|
|
140
|
-
support: Record<string, `#${string}`>;
|
|
141
|
-
}, {
|
|
142
|
-
neutral: string;
|
|
143
|
-
main: Record<string, string>;
|
|
144
|
-
support?: Record<string, string> | undefined;
|
|
145
|
-
}>;
|
|
42
|
+
main: z.ZodRecord<z.ZodString, z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
|
|
43
|
+
support: z.ZodDefault<z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>>>;
|
|
44
|
+
neutral: z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>;
|
|
45
|
+
}, z.core.$strip>;
|
|
146
46
|
typography: z.ZodOptional<z.ZodObject<{
|
|
147
47
|
fontFamily: z.ZodString;
|
|
148
|
-
},
|
|
149
|
-
fontFamily: string;
|
|
150
|
-
}, {
|
|
151
|
-
fontFamily: string;
|
|
152
|
-
}>>;
|
|
48
|
+
}, z.core.$strip>>;
|
|
153
49
|
borderRadius: z.ZodOptional<z.ZodNumber>;
|
|
154
|
-
},
|
|
155
|
-
|
|
156
|
-
neutral: `#${string}`;
|
|
157
|
-
main: Record<string, `#${string}`>;
|
|
158
|
-
support: Record<string, `#${string}`>;
|
|
159
|
-
};
|
|
160
|
-
typography?: {
|
|
161
|
-
fontFamily: string;
|
|
162
|
-
} | undefined;
|
|
163
|
-
borderRadius?: number | undefined;
|
|
164
|
-
}, {
|
|
165
|
-
colors: {
|
|
166
|
-
neutral: string;
|
|
167
|
-
main: Record<string, string>;
|
|
168
|
-
support?: Record<string, string> | undefined;
|
|
169
|
-
};
|
|
170
|
-
typography?: {
|
|
171
|
-
fontFamily: string;
|
|
172
|
-
} | undefined;
|
|
173
|
-
borderRadius?: number | undefined;
|
|
174
|
-
}>>;
|
|
175
|
-
}, "strip", z.ZodTypeAny, {
|
|
176
|
-
clean: boolean;
|
|
177
|
-
themes: Record<string, {
|
|
178
|
-
colors: {
|
|
179
|
-
neutral: `#${string}`;
|
|
180
|
-
main: Record<string, `#${string}`>;
|
|
181
|
-
support: Record<string, `#${string}`>;
|
|
182
|
-
};
|
|
183
|
-
typography?: {
|
|
184
|
-
fontFamily: string;
|
|
185
|
-
} | undefined;
|
|
186
|
-
borderRadius?: number | undefined;
|
|
187
|
-
}>;
|
|
188
|
-
outDir: string;
|
|
189
|
-
}, {
|
|
190
|
-
clean: boolean;
|
|
191
|
-
themes: Record<string, {
|
|
192
|
-
colors: {
|
|
193
|
-
neutral: string;
|
|
194
|
-
main: Record<string, string>;
|
|
195
|
-
support?: Record<string, string> | undefined;
|
|
196
|
-
};
|
|
197
|
-
typography?: {
|
|
198
|
-
fontFamily: string;
|
|
199
|
-
} | undefined;
|
|
200
|
-
borderRadius?: number | undefined;
|
|
201
|
-
}>;
|
|
202
|
-
outDir: string;
|
|
203
|
-
}>;
|
|
50
|
+
}, z.core.$strip>>>;
|
|
51
|
+
}, z.core.$strip>;
|
|
204
52
|
export type Config = z.infer<typeof combinedConfigSchema>;
|
|
205
53
|
export type ThemeConfig = z.infer<typeof themeSchema>;
|
|
206
54
|
export {};
|
package/dist/src/config.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/config.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,
|
|
1
|
+
{"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/config.ts"],"names":[],"mappings":"AACA,OAAO,EAAE,CAAC,EAAE,MAAM,QAAQ,CAAC;AAK3B,wBAAgB,mBAAmB,CAAC,IAAI,EAAE,CAAC,MAAM,GAAG,MAAM,CAAC,EAAE,sBAQ5D;AAWD,eAAO,MAAM,UAAU,QAA2C,CAAC;AAyBnE,QAAA,MAAM,WAAW;;;;;;;;;;iBAiBmG,CAAC;AAErH;;GAEG;AACH,eAAO,MAAM,gBAAgB;;;;;;;;;;;;;;iBAO3B,CAAC;AAEH;;;GAGG;AACH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;iBAA8B,CAAC;AAChE,MAAM,MAAM,MAAM,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,oBAAoB,CAAC,CAAC;AAC1D,MAAM,MAAM,WAAW,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,CAAC"}
|
package/dist/src/config.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
// src/config.ts
|
|
2
2
|
import * as R7 from "ramda";
|
|
3
|
-
import { z } from "zod";
|
|
3
|
+
import { z } from "zod/v4";
|
|
4
4
|
|
|
5
5
|
// src/colors/utils.ts
|
|
6
6
|
import chroma from "chroma-js";
|
|
@@ -327,45 +327,35 @@ var hexPatterns = [
|
|
|
327
327
|
];
|
|
328
328
|
var reservedColorsPattern = `^(?!(?:${RESERVED_COLORS.join("|")})$)`;
|
|
329
329
|
var colorRegex = new RegExp(`^${hexPatterns.join("|")}$`);
|
|
330
|
-
var colorSchema = z.string(
|
|
331
|
-
|
|
332
|
-
|
|
330
|
+
var colorSchema = z.string().regex(colorRegex).transform(convertToHex).describe(
|
|
331
|
+
`A hex color, which is used for creating a color scale. Invalid color names: ${RESERVED_COLORS.join(", ")}`
|
|
332
|
+
);
|
|
333
333
|
var colorCategorySchema = z.record(
|
|
334
334
|
z.string().regex(new RegExp(reservedColorsPattern, "i"), {
|
|
335
|
-
|
|
335
|
+
error: `Color names cannot include reserved names: ${RESERVED_COLORS.join(", ")}`
|
|
336
336
|
}),
|
|
337
337
|
colorSchema,
|
|
338
338
|
{
|
|
339
|
-
|
|
340
|
-
invalid_type_error: "Color definitions must be hex color values"
|
|
339
|
+
error: "Color definitions must be hex color values"
|
|
341
340
|
}
|
|
342
341
|
).refine((colors) => !Object.keys(colors).some((key) => RESERVED_COLORS.includes(key.toLowerCase())), {
|
|
343
|
-
|
|
344
|
-
});
|
|
345
|
-
var themeSchema = z.object(
|
|
346
|
-
{
|
|
347
|
-
|
|
348
|
-
|
|
349
|
-
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
{
|
|
357
|
-
fontFamily: z.string({ description: "Sets the font-family for this theme" })
|
|
358
|
-
},
|
|
359
|
-
{ description: "Defines the typography for a given theme" }
|
|
360
|
-
).optional(),
|
|
361
|
-
borderRadius: z.number({ description: "Defines the border-radius for this theme" }).optional()
|
|
362
|
-
},
|
|
363
|
-
{ description: "An object defining a theme. The property name holding the object becomes the theme name." }
|
|
364
|
-
);
|
|
342
|
+
error: `Color names cannot include reserved names: ${RESERVED_COLORS.join(", ")}`
|
|
343
|
+
}).describe("An object with one or more color definitions. The property name is used as the color name.");
|
|
344
|
+
var themeSchema = z.object({
|
|
345
|
+
colors: z.object({
|
|
346
|
+
main: colorCategorySchema,
|
|
347
|
+
support: colorCategorySchema.optional().default({}),
|
|
348
|
+
neutral: colorSchema
|
|
349
|
+
}).meta({ description: "Defines the colors for this theme" }),
|
|
350
|
+
typography: z.object({
|
|
351
|
+
fontFamily: z.string().meta({ description: "Sets the font-family for this theme" })
|
|
352
|
+
}).describe("Defines the typography for a given theme").optional(),
|
|
353
|
+
borderRadius: z.number().meta({ description: "Defines the border-radius for this theme" }).optional()
|
|
354
|
+
}).meta({ description: "An object defining a theme. The property name holding the object becomes the theme name." });
|
|
365
355
|
var configFileSchema = z.object({
|
|
366
|
-
outDir: z.string({ description: "Path to the output directory for the created design tokens" }).optional(),
|
|
367
|
-
clean: z.boolean({ description: "Delete the output directory before building or creating tokens" }).optional(),
|
|
368
|
-
themes: z.record(
|
|
356
|
+
outDir: z.string().meta({ description: "Path to the output directory for the created design tokens" }).optional(),
|
|
357
|
+
clean: z.boolean().meta({ description: "Delete the output directory before building or creating tokens" }).optional(),
|
|
358
|
+
themes: z.record(z.string(), themeSchema).meta({
|
|
369
359
|
description: "An object with one or more themes. Each property defines a theme, and the property name is used as the theme name."
|
|
370
360
|
})
|
|
371
361
|
});
|
package/dist/src/index.js
CHANGED
|
@@ -3499,11 +3499,11 @@ import chalk3 from "chalk";
|
|
|
3499
3499
|
// package.json
|
|
3500
3500
|
var package_default = {
|
|
3501
3501
|
name: "@digdir/designsystemet",
|
|
3502
|
-
version: "1.0.
|
|
3502
|
+
version: "1.0.7",
|
|
3503
3503
|
description: "CLI for Designsystemet",
|
|
3504
3504
|
author: "Designsystemet team",
|
|
3505
3505
|
engines: {
|
|
3506
|
-
node: ">=22.
|
|
3506
|
+
node: ">=22.16.0"
|
|
3507
3507
|
},
|
|
3508
3508
|
repository: {
|
|
3509
3509
|
type: "git",
|
|
@@ -3514,7 +3514,8 @@ var package_default = {
|
|
|
3514
3514
|
type: "module",
|
|
3515
3515
|
main: "./dist/src/index.js",
|
|
3516
3516
|
files: [
|
|
3517
|
-
"./dist/**"
|
|
3517
|
+
"./dist/**",
|
|
3518
|
+
"./configs/**"
|
|
3518
3519
|
],
|
|
3519
3520
|
bin: "dist/bin/designsystemet.js",
|
|
3520
3521
|
exports: {
|
|
@@ -3533,22 +3534,22 @@ var package_default = {
|
|
|
3533
3534
|
},
|
|
3534
3535
|
scripts: {
|
|
3535
3536
|
designsystemet: "tsx ./bin/designsystemet.ts",
|
|
3536
|
-
"build:tokens": "pnpm run designsystemet tokens build -p -t ../../design-tokens -o ../../packages/theme/brand --clean",
|
|
3537
|
-
"build:tokens:debug": "tsx --inspect-brk ./bin/designsystemet.ts tokens build -p -t ../../design-tokens -o ../../packages/theme/brand --clean",
|
|
3537
|
+
"build:tokens": "pnpm run designsystemet tokens build -p -t ../../internal/design-tokens -o ../../packages/theme/brand --clean",
|
|
3538
|
+
"build:tokens:debug": "tsx --inspect-brk ./bin/designsystemet.ts tokens build -p -t ../../internal/design-tokens -o ../../packages/theme/brand --clean",
|
|
3538
3539
|
build: "tsup && pnpm build:types && pnpm build:json-schema",
|
|
3539
3540
|
"build:types": "tsc --emitDeclarationOnly --declaration",
|
|
3540
3541
|
"build:json-schema": "tsx ./src/scripts/createJsonSchema.ts",
|
|
3541
3542
|
types: "tsc --noEmit",
|
|
3542
|
-
"test:tokens-create-options": 'pnpm run designsystemet tokens create -m dominant:"#007682" -n "#003333" -b 99 -o ./
|
|
3543
|
-
"test:tokens-create-config": "pnpm run designsystemet tokens create --config ./
|
|
3544
|
-
"test:tokens-build": "pnpm run designsystemet tokens build -t ./
|
|
3545
|
-
"test:tokens-build-config": "pnpm run designsystemet tokens build -t ./
|
|
3543
|
+
"test:tokens-create-options": 'pnpm run designsystemet tokens create -m dominant:"#007682" -n "#003333" -b 99 -o ./temp/options/design-tokens --theme options --clean',
|
|
3544
|
+
"test:tokens-create-config": "pnpm run designsystemet tokens create --config ./configs/test-tokens.config.json",
|
|
3545
|
+
"test:tokens-build": "pnpm run designsystemet tokens build -t ./temp/options/design-tokens -o ./temp/options/build --clean",
|
|
3546
|
+
"test:tokens-build-config": "pnpm run designsystemet tokens build -t ./temp/config/design-tokens -o ./temp/config/build --clean",
|
|
3546
3547
|
"test:tokens-create-and-build-options": "pnpm test:tokens-create-options && pnpm test:tokens-build",
|
|
3547
3548
|
"test:tokens-create-and-build-config": "pnpm test:tokens-create-config && pnpm test:tokens-build-config",
|
|
3548
3549
|
test: "pnpm test:tokens-create-and-build-options && pnpm test:tokens-create-and-build-config",
|
|
3549
|
-
"
|
|
3550
|
+
"digdir:tokens-create": "pnpm run designsystemet tokens create --config ./configs/digdir.config.json",
|
|
3550
3551
|
"update:template": "tsx ./src/scripts/update-template.ts",
|
|
3551
|
-
"update:design-tokens": "pnpm
|
|
3552
|
+
"update:design-tokens": "pnpm digdir:tokens-create && tsx ./src/scripts/update-design-tokens.ts",
|
|
3552
3553
|
verify: "pnpm test && pnpm update:template && pnpm update:design-tokens"
|
|
3553
3554
|
},
|
|
3554
3555
|
dependencies: {
|
|
@@ -3566,8 +3567,8 @@ var package_default = {
|
|
|
3566
3567
|
postcss: "^8.5.3",
|
|
3567
3568
|
ramda: "^0.30.1",
|
|
3568
3569
|
"style-dictionary": "^4.4.0",
|
|
3569
|
-
zod: "^3.
|
|
3570
|
-
"zod-validation-error": "^3.4.
|
|
3570
|
+
zod: "^3.25.30",
|
|
3571
|
+
"zod-validation-error": "^3.4.1"
|
|
3571
3572
|
},
|
|
3572
3573
|
devDependencies: {
|
|
3573
3574
|
"@tokens-studio/types": "0.5.2",
|
|
@@ -3576,16 +3577,15 @@ var package_default = {
|
|
|
3576
3577
|
"@types/fs-extra": "^11.0.4",
|
|
3577
3578
|
"@types/glob": "^8.1.0",
|
|
3578
3579
|
"@types/jscodeshift": "^0.12.0",
|
|
3579
|
-
"@types/node": "^22.15.
|
|
3580
|
+
"@types/node": "^22.15.21",
|
|
3580
3581
|
"@types/object-hash": "^3.0.6",
|
|
3581
3582
|
"@types/ramda": "^0.30.2",
|
|
3582
3583
|
"fs-extra": "^11.3.0",
|
|
3583
3584
|
"ts-toolbelt": "^9.6.0",
|
|
3584
3585
|
tslib: "^2.8.1",
|
|
3585
|
-
tsup: "^8.
|
|
3586
|
+
tsup: "^8.5.0",
|
|
3586
3587
|
tsx: "^4.19.4",
|
|
3587
|
-
typescript: "^5.8.3"
|
|
3588
|
-
"zod-to-json-schema": "^3.24.5"
|
|
3588
|
+
typescript: "^5.8.3"
|
|
3589
3589
|
}
|
|
3590
3590
|
};
|
|
3591
3591
|
|
|
@@ -3639,9 +3639,6 @@ order may change due to nondeterminism.`.trim()
|
|
|
3639
3639
|
return sortIndex;
|
|
3640
3640
|
});
|
|
3641
3641
|
const header = `@charset "UTF-8";
|
|
3642
|
-
|
|
3643
|
-
@layer ds.theme, ds.base, ds.utilities, ds.components;
|
|
3644
|
-
|
|
3645
3642
|
/*
|
|
3646
3643
|
${fileHeader2}
|
|
3647
3644
|
*/
|
|
@@ -42,12 +42,12 @@ var cssVarRename = (dictionary) => ({
|
|
|
42
42
|
});
|
|
43
43
|
|
|
44
44
|
// src/migrations/codemods/css/run.ts
|
|
45
|
-
import fs2 from "
|
|
45
|
+
import fs2 from "fs";
|
|
46
46
|
import glob from "fast-glob";
|
|
47
47
|
import postcss from "postcss";
|
|
48
48
|
|
|
49
49
|
// src/utils.ts
|
|
50
|
-
import fs from "
|
|
50
|
+
import fs from "fs/promises";
|
|
51
51
|
import chalk2 from "chalk";
|
|
52
52
|
var readFile = async (path, dry) => {
|
|
53
53
|
if (dry) {
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
// src/migrations/codemods/css/run.ts
|
|
2
|
-
import fs2 from "
|
|
2
|
+
import fs2 from "fs";
|
|
3
3
|
import glob from "fast-glob";
|
|
4
4
|
import postcss from "postcss";
|
|
5
5
|
|
|
6
6
|
// src/utils.ts
|
|
7
|
-
import fs from "
|
|
7
|
+
import fs from "fs/promises";
|
|
8
8
|
import chalk from "chalk";
|
|
9
9
|
var readFile = async (path, dry) => {
|
|
10
10
|
if (dry) {
|
|
@@ -33,12 +33,12 @@ var cssVarRename = (dictionary) => ({
|
|
|
33
33
|
});
|
|
34
34
|
|
|
35
35
|
// src/migrations/codemods/css/run.ts
|
|
36
|
-
import fs2 from "
|
|
36
|
+
import fs2 from "fs";
|
|
37
37
|
import glob from "fast-glob";
|
|
38
38
|
import postcss from "postcss";
|
|
39
39
|
|
|
40
40
|
// src/utils.ts
|
|
41
|
-
import fs from "
|
|
41
|
+
import fs from "fs/promises";
|
|
42
42
|
import chalk2 from "chalk";
|
|
43
43
|
var readFile = async (path, dry) => {
|
|
44
44
|
if (dry) {
|
|
@@ -42,12 +42,12 @@ var cssVarRename = (dictionary) => ({
|
|
|
42
42
|
});
|
|
43
43
|
|
|
44
44
|
// src/migrations/codemods/css/run.ts
|
|
45
|
-
import fs2 from "
|
|
45
|
+
import fs2 from "fs";
|
|
46
46
|
import glob from "fast-glob";
|
|
47
47
|
import postcss from "postcss";
|
|
48
48
|
|
|
49
49
|
// src/utils.ts
|
|
50
|
-
import fs from "
|
|
50
|
+
import fs from "fs/promises";
|
|
51
51
|
import chalk2 from "chalk";
|
|
52
52
|
var readFile = async (path, dry) => {
|
|
53
53
|
if (dry) {
|