@digdir/designsystemet 1.9.0 → 1.11.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/dist/bin/designsystemet.js +15 -18
- package/dist/{color.base.template-5XWYH2F5.json → color.base.template-Z7YWN2TF.json} +1 -1
- package/dist/config.schema.json +32 -32
- package/dist/src/index.js +15 -18
- package/dist/src/scripts/update-preview-tokens.js +20 -54
- package/dist/src/scripts/update-template.d.ts.map +1 -1
- package/dist/src/scripts/update-template.js +151 -280
- package/dist/src/tokens/build.js +15 -18
- package/dist/src/tokens/create/generators/$designsystemet.js +8 -17
- package/dist/src/tokens/create/write.js +8 -17
- package/dist/src/tokens/format.js +15 -18
- package/dist/src/tokens/index.js +15 -18
- package/dist/src/tokens/process/configs/color.js +0 -1
- package/dist/src/tokens/process/configs/semantic.js +0 -1
- package/dist/src/tokens/process/configs/size-mode.js +0 -1
- package/dist/src/tokens/process/configs/size.js +0 -1
- package/dist/src/tokens/process/configs/type-scale.js +0 -1
- package/dist/src/tokens/process/configs/typography.js +0 -1
- package/dist/src/tokens/process/configs.js +0 -1
- package/dist/src/tokens/process/formats/css/color.js +0 -1
- package/dist/src/tokens/process/formats/css/semantic.js +0 -1
- package/dist/src/tokens/process/formats/css/size-mode.js +0 -1
- package/dist/src/tokens/process/formats/css/size.js +0 -1
- package/dist/src/tokens/process/formats/css/type-scale.js +0 -1
- package/dist/src/tokens/process/formats/css/typography.js +0 -1
- package/dist/src/tokens/process/formats/css.js +0 -1
- package/dist/src/tokens/process/output/declarations.js +8 -18
- package/dist/src/tokens/process/output/theme.js +8 -17
- package/dist/src/tokens/process/platform.js +0 -1
- package/dist/src/tokens/process/utils/getMultidimensionalThemes.d.ts.map +1 -1
- package/dist/src/tokens/process/utils/getMultidimensionalThemes.js +5 -1
- package/dist/src/tokens/process/utils/kebab-case.d.ts +5 -0
- package/dist/src/tokens/process/utils/kebab-case.d.ts.map +1 -0
- package/dist/src/tokens/process/utils/kebab-case.js +7 -0
- package/dist/src/tokens/template/design-tokens/semantic/color.base.template.js +1 -1
- package/package.json +9 -18
- package/configs/digdir.config.json +0 -63
- package/dist/src/scripts/update-design-tokens.d.ts +0 -2
- package/dist/src/scripts/update-design-tokens.d.ts.map +0 -1
- package/dist/src/scripts/update-design-tokens.js +0 -37
package/dist/src/tokens/build.js
CHANGED
|
@@ -49,7 +49,7 @@ import pc4 from "picocolors";
|
|
|
49
49
|
// package.json
|
|
50
50
|
var package_default = {
|
|
51
51
|
name: "@digdir/designsystemet",
|
|
52
|
-
version: "1.
|
|
52
|
+
version: "1.11.0",
|
|
53
53
|
description: "CLI for Designsystemet",
|
|
54
54
|
author: "Designsystemet team",
|
|
55
55
|
engines: {
|
|
@@ -101,23 +101,18 @@ var package_default = {
|
|
|
101
101
|
"test:tokens-build-config-tailwind": "pnpm run designsystemet tokens build -t ./temp/config/design-tokens -o ./temp/config/build --clean --experimental-tailwind",
|
|
102
102
|
"test:tokens-create-and-build-options": "pnpm test:tokens-create-options && pnpm test:tokens-build",
|
|
103
103
|
"test:tokens-create-and-build-config": "pnpm test:tokens-create-config && pnpm test:tokens-build-config",
|
|
104
|
-
"test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/design-tokens --dry",
|
|
104
|
+
"test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/digdir/design-tokens --dry",
|
|
105
105
|
test: "node -v && pnpm test:tokens-create-and-build-options && pnpm test:generate-config-from-tokens && pnpm test:tokens-create-and-build-config",
|
|
106
|
-
"digdir:tokens-build": "pnpm run designsystemet tokens build -t ../../internal/design-tokens -o ../../packages/theme/brand --clean --experimental-tailwind",
|
|
107
|
-
"digdir:tokens-create": "pnpm run designsystemet tokens create --config ./configs/digdir.config.json",
|
|
108
106
|
"update:template": "tsx ./src/scripts/update-template.ts",
|
|
109
107
|
"update:preview-tokens": "tsx ./src/scripts/update-preview-tokens.ts",
|
|
110
|
-
|
|
111
|
-
verify: "pnpm test && pnpm update:template && pnpm update:theme-digdir && pnpm build:tokens"
|
|
108
|
+
verify: "pnpm test && pnpm update:template && pnpm --filter @internal/digdir update:theme-digdir"
|
|
112
109
|
},
|
|
113
110
|
dependencies: {
|
|
114
111
|
"@commander-js/extra-typings": "^14.0.0",
|
|
115
112
|
"@digdir/designsystemet-types": "workspace:^",
|
|
116
113
|
"@tokens-studio/sd-transforms": "2.0.3",
|
|
117
|
-
"apca-w3": "^0.1.9",
|
|
118
|
-
"change-case": "^5.4.4",
|
|
119
114
|
"chroma-js": "^3.2.0",
|
|
120
|
-
"colorjs.io": "^0.6.0
|
|
115
|
+
"colorjs.io": "^0.6.0",
|
|
121
116
|
commander: "^14.0.2",
|
|
122
117
|
"fast-glob": "^3.3.3",
|
|
123
118
|
hsluv: "^1.0.1",
|
|
@@ -125,20 +120,16 @@ var package_default = {
|
|
|
125
120
|
picocolors: "^1.1.1",
|
|
126
121
|
postcss: "^8.5.6",
|
|
127
122
|
ramda: "^0.32.0",
|
|
128
|
-
"style-dictionary": "^5.1.
|
|
129
|
-
zod: "^4.
|
|
130
|
-
"zod-validation-error": "^
|
|
123
|
+
"style-dictionary": "^5.1.3",
|
|
124
|
+
zod: "^4.3.5",
|
|
125
|
+
"zod-validation-error": "^5.0.0"
|
|
131
126
|
},
|
|
132
127
|
devDependencies: {
|
|
133
128
|
"@tokens-studio/types": "0.5.2",
|
|
134
|
-
"@types/apca-w3": "^0.1.3",
|
|
135
129
|
"@types/chroma-js": "^3.1.2",
|
|
136
|
-
"@types/
|
|
137
|
-
"@types/node": "^22.19.1",
|
|
130
|
+
"@types/node": "^24.10.7",
|
|
138
131
|
"@types/object-hash": "^3.0.6",
|
|
139
132
|
"@types/ramda": "^0.31.1",
|
|
140
|
-
"fs-extra": "^11.3.2",
|
|
141
|
-
tslib: "^2.8.1",
|
|
142
133
|
tsup: "^8.5.1",
|
|
143
134
|
tsx: "^4.21.0",
|
|
144
135
|
typescript: "^5.9.3"
|
|
@@ -1164,9 +1155,15 @@ var TypographyValues;
|
|
|
1164
1155
|
})(TypographyValues || (TypographyValues = {}));
|
|
1165
1156
|
|
|
1166
1157
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
1167
|
-
import { kebabCase } from "change-case";
|
|
1168
1158
|
import pc2 from "picocolors";
|
|
1169
1159
|
import * as R13 from "ramda";
|
|
1160
|
+
|
|
1161
|
+
// src/tokens/process/utils/kebab-case.ts
|
|
1162
|
+
function kebabCase(str) {
|
|
1163
|
+
return str.replace(/([a-z])([A-Z])/g, "$1-$2").replace(/[\s_]+/g, "-").toLowerCase();
|
|
1164
|
+
}
|
|
1165
|
+
|
|
1166
|
+
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
1170
1167
|
var getMultidimensionalThemes = (processed$themes, dimensions) => {
|
|
1171
1168
|
const verboseLogging = buildOptions?.verbose;
|
|
1172
1169
|
const grouped$themes = groupThemes(processed$themes);
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// package.json
|
|
2
2
|
var package_default = {
|
|
3
3
|
name: "@digdir/designsystemet",
|
|
4
|
-
version: "1.
|
|
4
|
+
version: "1.11.0",
|
|
5
5
|
description: "CLI for Designsystemet",
|
|
6
6
|
author: "Designsystemet team",
|
|
7
7
|
engines: {
|
|
@@ -53,23 +53,18 @@ var package_default = {
|
|
|
53
53
|
"test:tokens-build-config-tailwind": "pnpm run designsystemet tokens build -t ./temp/config/design-tokens -o ./temp/config/build --clean --experimental-tailwind",
|
|
54
54
|
"test:tokens-create-and-build-options": "pnpm test:tokens-create-options && pnpm test:tokens-build",
|
|
55
55
|
"test:tokens-create-and-build-config": "pnpm test:tokens-create-config && pnpm test:tokens-build-config",
|
|
56
|
-
"test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/design-tokens --dry",
|
|
56
|
+
"test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/digdir/design-tokens --dry",
|
|
57
57
|
test: "node -v && pnpm test:tokens-create-and-build-options && pnpm test:generate-config-from-tokens && pnpm test:tokens-create-and-build-config",
|
|
58
|
-
"digdir:tokens-build": "pnpm run designsystemet tokens build -t ../../internal/design-tokens -o ../../packages/theme/brand --clean --experimental-tailwind",
|
|
59
|
-
"digdir:tokens-create": "pnpm run designsystemet tokens create --config ./configs/digdir.config.json",
|
|
60
58
|
"update:template": "tsx ./src/scripts/update-template.ts",
|
|
61
59
|
"update:preview-tokens": "tsx ./src/scripts/update-preview-tokens.ts",
|
|
62
|
-
|
|
63
|
-
verify: "pnpm test && pnpm update:template && pnpm update:theme-digdir && pnpm build:tokens"
|
|
60
|
+
verify: "pnpm test && pnpm update:template && pnpm --filter @internal/digdir update:theme-digdir"
|
|
64
61
|
},
|
|
65
62
|
dependencies: {
|
|
66
63
|
"@commander-js/extra-typings": "^14.0.0",
|
|
67
64
|
"@digdir/designsystemet-types": "workspace:^",
|
|
68
65
|
"@tokens-studio/sd-transforms": "2.0.3",
|
|
69
|
-
"apca-w3": "^0.1.9",
|
|
70
|
-
"change-case": "^5.4.4",
|
|
71
66
|
"chroma-js": "^3.2.0",
|
|
72
|
-
"colorjs.io": "^0.6.0
|
|
67
|
+
"colorjs.io": "^0.6.0",
|
|
73
68
|
commander: "^14.0.2",
|
|
74
69
|
"fast-glob": "^3.3.3",
|
|
75
70
|
hsluv: "^1.0.1",
|
|
@@ -77,20 +72,16 @@ var package_default = {
|
|
|
77
72
|
picocolors: "^1.1.1",
|
|
78
73
|
postcss: "^8.5.6",
|
|
79
74
|
ramda: "^0.32.0",
|
|
80
|
-
"style-dictionary": "^5.1.
|
|
81
|
-
zod: "^4.
|
|
82
|
-
"zod-validation-error": "^
|
|
75
|
+
"style-dictionary": "^5.1.3",
|
|
76
|
+
zod: "^4.3.5",
|
|
77
|
+
"zod-validation-error": "^5.0.0"
|
|
83
78
|
},
|
|
84
79
|
devDependencies: {
|
|
85
80
|
"@tokens-studio/types": "0.5.2",
|
|
86
|
-
"@types/apca-w3": "^0.1.3",
|
|
87
81
|
"@types/chroma-js": "^3.1.2",
|
|
88
|
-
"@types/
|
|
89
|
-
"@types/node": "^22.19.1",
|
|
82
|
+
"@types/node": "^24.10.7",
|
|
90
83
|
"@types/object-hash": "^3.0.6",
|
|
91
84
|
"@types/ramda": "^0.31.1",
|
|
92
|
-
"fs-extra": "^11.3.2",
|
|
93
|
-
tslib: "^2.8.1",
|
|
94
85
|
tsup: "^8.5.1",
|
|
95
86
|
tsx: "^4.21.0",
|
|
96
87
|
typescript: "^5.9.3"
|
|
@@ -46,7 +46,7 @@ var readFile = async (path2, dry, allowFileNotFound) => {
|
|
|
46
46
|
// package.json
|
|
47
47
|
var package_default = {
|
|
48
48
|
name: "@digdir/designsystemet",
|
|
49
|
-
version: "1.
|
|
49
|
+
version: "1.11.0",
|
|
50
50
|
description: "CLI for Designsystemet",
|
|
51
51
|
author: "Designsystemet team",
|
|
52
52
|
engines: {
|
|
@@ -98,23 +98,18 @@ var package_default = {
|
|
|
98
98
|
"test:tokens-build-config-tailwind": "pnpm run designsystemet tokens build -t ./temp/config/design-tokens -o ./temp/config/build --clean --experimental-tailwind",
|
|
99
99
|
"test:tokens-create-and-build-options": "pnpm test:tokens-create-options && pnpm test:tokens-build",
|
|
100
100
|
"test:tokens-create-and-build-config": "pnpm test:tokens-create-config && pnpm test:tokens-build-config",
|
|
101
|
-
"test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/design-tokens --dry",
|
|
101
|
+
"test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/digdir/design-tokens --dry",
|
|
102
102
|
test: "node -v && pnpm test:tokens-create-and-build-options && pnpm test:generate-config-from-tokens && pnpm test:tokens-create-and-build-config",
|
|
103
|
-
"digdir:tokens-build": "pnpm run designsystemet tokens build -t ../../internal/design-tokens -o ../../packages/theme/brand --clean --experimental-tailwind",
|
|
104
|
-
"digdir:tokens-create": "pnpm run designsystemet tokens create --config ./configs/digdir.config.json",
|
|
105
103
|
"update:template": "tsx ./src/scripts/update-template.ts",
|
|
106
104
|
"update:preview-tokens": "tsx ./src/scripts/update-preview-tokens.ts",
|
|
107
|
-
|
|
108
|
-
verify: "pnpm test && pnpm update:template && pnpm update:theme-digdir && pnpm build:tokens"
|
|
105
|
+
verify: "pnpm test && pnpm update:template && pnpm --filter @internal/digdir update:theme-digdir"
|
|
109
106
|
},
|
|
110
107
|
dependencies: {
|
|
111
108
|
"@commander-js/extra-typings": "^14.0.0",
|
|
112
109
|
"@digdir/designsystemet-types": "workspace:^",
|
|
113
110
|
"@tokens-studio/sd-transforms": "2.0.3",
|
|
114
|
-
"apca-w3": "^0.1.9",
|
|
115
|
-
"change-case": "^5.4.4",
|
|
116
111
|
"chroma-js": "^3.2.0",
|
|
117
|
-
"colorjs.io": "^0.6.0
|
|
112
|
+
"colorjs.io": "^0.6.0",
|
|
118
113
|
commander: "^14.0.2",
|
|
119
114
|
"fast-glob": "^3.3.3",
|
|
120
115
|
hsluv: "^1.0.1",
|
|
@@ -122,20 +117,16 @@ var package_default = {
|
|
|
122
117
|
picocolors: "^1.1.1",
|
|
123
118
|
postcss: "^8.5.6",
|
|
124
119
|
ramda: "^0.32.0",
|
|
125
|
-
"style-dictionary": "^5.1.
|
|
126
|
-
zod: "^4.
|
|
127
|
-
"zod-validation-error": "^
|
|
120
|
+
"style-dictionary": "^5.1.3",
|
|
121
|
+
zod: "^4.3.5",
|
|
122
|
+
"zod-validation-error": "^5.0.0"
|
|
128
123
|
},
|
|
129
124
|
devDependencies: {
|
|
130
125
|
"@tokens-studio/types": "0.5.2",
|
|
131
|
-
"@types/apca-w3": "^0.1.3",
|
|
132
126
|
"@types/chroma-js": "^3.1.2",
|
|
133
|
-
"@types/
|
|
134
|
-
"@types/node": "^22.19.1",
|
|
127
|
+
"@types/node": "^24.10.7",
|
|
135
128
|
"@types/object-hash": "^3.0.6",
|
|
136
129
|
"@types/ramda": "^0.31.1",
|
|
137
|
-
"fs-extra": "^11.3.2",
|
|
138
|
-
tslib: "^2.8.1",
|
|
139
130
|
tsup: "^8.5.1",
|
|
140
131
|
tsx: "^4.21.0",
|
|
141
132
|
typescript: "^5.9.3"
|
|
@@ -2217,7 +2217,7 @@ import * as R8 from "ramda";
|
|
|
2217
2217
|
// package.json
|
|
2218
2218
|
var package_default = {
|
|
2219
2219
|
name: "@digdir/designsystemet",
|
|
2220
|
-
version: "1.
|
|
2220
|
+
version: "1.11.0",
|
|
2221
2221
|
description: "CLI for Designsystemet",
|
|
2222
2222
|
author: "Designsystemet team",
|
|
2223
2223
|
engines: {
|
|
@@ -2269,23 +2269,18 @@ var package_default = {
|
|
|
2269
2269
|
"test:tokens-build-config-tailwind": "pnpm run designsystemet tokens build -t ./temp/config/design-tokens -o ./temp/config/build --clean --experimental-tailwind",
|
|
2270
2270
|
"test:tokens-create-and-build-options": "pnpm test:tokens-create-options && pnpm test:tokens-build",
|
|
2271
2271
|
"test:tokens-create-and-build-config": "pnpm test:tokens-create-config && pnpm test:tokens-build-config",
|
|
2272
|
-
"test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/design-tokens --dry",
|
|
2272
|
+
"test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/digdir/design-tokens --dry",
|
|
2273
2273
|
test: "node -v && pnpm test:tokens-create-and-build-options && pnpm test:generate-config-from-tokens && pnpm test:tokens-create-and-build-config",
|
|
2274
|
-
"digdir:tokens-build": "pnpm run designsystemet tokens build -t ../../internal/design-tokens -o ../../packages/theme/brand --clean --experimental-tailwind",
|
|
2275
|
-
"digdir:tokens-create": "pnpm run designsystemet tokens create --config ./configs/digdir.config.json",
|
|
2276
2274
|
"update:template": "tsx ./src/scripts/update-template.ts",
|
|
2277
2275
|
"update:preview-tokens": "tsx ./src/scripts/update-preview-tokens.ts",
|
|
2278
|
-
|
|
2279
|
-
verify: "pnpm test && pnpm update:template && pnpm update:theme-digdir && pnpm build:tokens"
|
|
2276
|
+
verify: "pnpm test && pnpm update:template && pnpm --filter @internal/digdir update:theme-digdir"
|
|
2280
2277
|
},
|
|
2281
2278
|
dependencies: {
|
|
2282
2279
|
"@commander-js/extra-typings": "^14.0.0",
|
|
2283
2280
|
"@digdir/designsystemet-types": "workspace:^",
|
|
2284
2281
|
"@tokens-studio/sd-transforms": "2.0.3",
|
|
2285
|
-
"apca-w3": "^0.1.9",
|
|
2286
|
-
"change-case": "^5.4.4",
|
|
2287
2282
|
"chroma-js": "^3.2.0",
|
|
2288
|
-
"colorjs.io": "^0.6.0
|
|
2283
|
+
"colorjs.io": "^0.6.0",
|
|
2289
2284
|
commander: "^14.0.2",
|
|
2290
2285
|
"fast-glob": "^3.3.3",
|
|
2291
2286
|
hsluv: "^1.0.1",
|
|
@@ -2293,20 +2288,16 @@ var package_default = {
|
|
|
2293
2288
|
picocolors: "^1.1.1",
|
|
2294
2289
|
postcss: "^8.5.6",
|
|
2295
2290
|
ramda: "^0.32.0",
|
|
2296
|
-
"style-dictionary": "^5.1.
|
|
2297
|
-
zod: "^4.
|
|
2298
|
-
"zod-validation-error": "^
|
|
2291
|
+
"style-dictionary": "^5.1.3",
|
|
2292
|
+
zod: "^4.3.5",
|
|
2293
|
+
"zod-validation-error": "^5.0.0"
|
|
2299
2294
|
},
|
|
2300
2295
|
devDependencies: {
|
|
2301
2296
|
"@tokens-studio/types": "0.5.2",
|
|
2302
|
-
"@types/apca-w3": "^0.1.3",
|
|
2303
2297
|
"@types/chroma-js": "^3.1.2",
|
|
2304
|
-
"@types/
|
|
2305
|
-
"@types/node": "^22.19.1",
|
|
2298
|
+
"@types/node": "^24.10.7",
|
|
2306
2299
|
"@types/object-hash": "^3.0.6",
|
|
2307
2300
|
"@types/ramda": "^0.31.1",
|
|
2308
|
-
"fs-extra": "^11.3.2",
|
|
2309
|
-
tslib: "^2.8.1",
|
|
2310
2301
|
tsup: "^8.5.1",
|
|
2311
2302
|
tsx: "^4.21.0",
|
|
2312
2303
|
typescript: "^5.9.3"
|
|
@@ -3253,9 +3244,15 @@ var typographyVariables = ({ theme, typography: typography2 }) => {
|
|
|
3253
3244
|
};
|
|
3254
3245
|
|
|
3255
3246
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
3256
|
-
import { kebabCase } from "change-case";
|
|
3257
3247
|
import pc2 from "picocolors";
|
|
3258
3248
|
import * as R20 from "ramda";
|
|
3249
|
+
|
|
3250
|
+
// src/tokens/process/utils/kebab-case.ts
|
|
3251
|
+
function kebabCase(str) {
|
|
3252
|
+
return str.replace(/([a-z])([A-Z])/g, "$1-$2").replace(/[\s_]+/g, "-").toLowerCase();
|
|
3253
|
+
}
|
|
3254
|
+
|
|
3255
|
+
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
3259
3256
|
var getMultidimensionalThemes = (processed$themes, dimensions) => {
|
|
3260
3257
|
const verboseLogging = buildOptions?.verbose;
|
|
3261
3258
|
const grouped$themes = groupThemes(processed$themes);
|
package/dist/src/tokens/index.js
CHANGED
|
@@ -2233,7 +2233,7 @@ import * as R8 from "ramda";
|
|
|
2233
2233
|
// package.json
|
|
2234
2234
|
var package_default = {
|
|
2235
2235
|
name: "@digdir/designsystemet",
|
|
2236
|
-
version: "1.
|
|
2236
|
+
version: "1.11.0",
|
|
2237
2237
|
description: "CLI for Designsystemet",
|
|
2238
2238
|
author: "Designsystemet team",
|
|
2239
2239
|
engines: {
|
|
@@ -2285,23 +2285,18 @@ var package_default = {
|
|
|
2285
2285
|
"test:tokens-build-config-tailwind": "pnpm run designsystemet tokens build -t ./temp/config/design-tokens -o ./temp/config/build --clean --experimental-tailwind",
|
|
2286
2286
|
"test:tokens-create-and-build-options": "pnpm test:tokens-create-options && pnpm test:tokens-build",
|
|
2287
2287
|
"test:tokens-create-and-build-config": "pnpm test:tokens-create-config && pnpm test:tokens-build-config",
|
|
2288
|
-
"test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/design-tokens --dry",
|
|
2288
|
+
"test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/digdir/design-tokens --dry",
|
|
2289
2289
|
test: "node -v && pnpm test:tokens-create-and-build-options && pnpm test:generate-config-from-tokens && pnpm test:tokens-create-and-build-config",
|
|
2290
|
-
"digdir:tokens-build": "pnpm run designsystemet tokens build -t ../../internal/design-tokens -o ../../packages/theme/brand --clean --experimental-tailwind",
|
|
2291
|
-
"digdir:tokens-create": "pnpm run designsystemet tokens create --config ./configs/digdir.config.json",
|
|
2292
2290
|
"update:template": "tsx ./src/scripts/update-template.ts",
|
|
2293
2291
|
"update:preview-tokens": "tsx ./src/scripts/update-preview-tokens.ts",
|
|
2294
|
-
|
|
2295
|
-
verify: "pnpm test && pnpm update:template && pnpm update:theme-digdir && pnpm build:tokens"
|
|
2292
|
+
verify: "pnpm test && pnpm update:template && pnpm --filter @internal/digdir update:theme-digdir"
|
|
2296
2293
|
},
|
|
2297
2294
|
dependencies: {
|
|
2298
2295
|
"@commander-js/extra-typings": "^14.0.0",
|
|
2299
2296
|
"@digdir/designsystemet-types": "workspace:^",
|
|
2300
2297
|
"@tokens-studio/sd-transforms": "2.0.3",
|
|
2301
|
-
"apca-w3": "^0.1.9",
|
|
2302
|
-
"change-case": "^5.4.4",
|
|
2303
2298
|
"chroma-js": "^3.2.0",
|
|
2304
|
-
"colorjs.io": "^0.6.0
|
|
2299
|
+
"colorjs.io": "^0.6.0",
|
|
2305
2300
|
commander: "^14.0.2",
|
|
2306
2301
|
"fast-glob": "^3.3.3",
|
|
2307
2302
|
hsluv: "^1.0.1",
|
|
@@ -2309,20 +2304,16 @@ var package_default = {
|
|
|
2309
2304
|
picocolors: "^1.1.1",
|
|
2310
2305
|
postcss: "^8.5.6",
|
|
2311
2306
|
ramda: "^0.32.0",
|
|
2312
|
-
"style-dictionary": "^5.1.
|
|
2313
|
-
zod: "^4.
|
|
2314
|
-
"zod-validation-error": "^
|
|
2307
|
+
"style-dictionary": "^5.1.3",
|
|
2308
|
+
zod: "^4.3.5",
|
|
2309
|
+
"zod-validation-error": "^5.0.0"
|
|
2315
2310
|
},
|
|
2316
2311
|
devDependencies: {
|
|
2317
2312
|
"@tokens-studio/types": "0.5.2",
|
|
2318
|
-
"@types/apca-w3": "^0.1.3",
|
|
2319
2313
|
"@types/chroma-js": "^3.1.2",
|
|
2320
|
-
"@types/
|
|
2321
|
-
"@types/node": "^22.19.1",
|
|
2314
|
+
"@types/node": "^24.10.7",
|
|
2322
2315
|
"@types/object-hash": "^3.0.6",
|
|
2323
2316
|
"@types/ramda": "^0.31.1",
|
|
2324
|
-
"fs-extra": "^11.3.2",
|
|
2325
|
-
tslib: "^2.8.1",
|
|
2326
2317
|
tsup: "^8.5.1",
|
|
2327
2318
|
tsx: "^4.21.0",
|
|
2328
2319
|
typescript: "^5.9.3"
|
|
@@ -3269,9 +3260,15 @@ var typographyVariables = ({ theme, typography: typography2 }) => {
|
|
|
3269
3260
|
};
|
|
3270
3261
|
|
|
3271
3262
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
3272
|
-
import { kebabCase } from "change-case";
|
|
3273
3263
|
import pc2 from "picocolors";
|
|
3274
3264
|
import * as R20 from "ramda";
|
|
3265
|
+
|
|
3266
|
+
// src/tokens/process/utils/kebab-case.ts
|
|
3267
|
+
function kebabCase(str) {
|
|
3268
|
+
return str.replace(/([a-z])([A-Z])/g, "$1-$2").replace(/[\s_]+/g, "-").toLowerCase();
|
|
3269
|
+
}
|
|
3270
|
+
|
|
3271
|
+
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
3275
3272
|
var getMultidimensionalThemes = (processed$themes, dimensions) => {
|
|
3276
3273
|
const verboseLogging = buildOptions?.verbose;
|
|
3277
3274
|
const grouped$themes = groupThemes(processed$themes);
|
|
@@ -552,7 +552,6 @@ var TypographyValues;
|
|
|
552
552
|
})(TypographyValues || (TypographyValues = {}));
|
|
553
553
|
|
|
554
554
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
555
|
-
import { kebabCase } from "change-case";
|
|
556
555
|
import pc from "picocolors";
|
|
557
556
|
import * as R6 from "ramda";
|
|
558
557
|
var processed = Symbol("Type brand for ProcessedThemeObject");
|
|
@@ -578,7 +578,6 @@ var TypographyValues;
|
|
|
578
578
|
})(TypographyValues || (TypographyValues = {}));
|
|
579
579
|
|
|
580
580
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
581
|
-
import { kebabCase } from "change-case";
|
|
582
581
|
import pc from "picocolors";
|
|
583
582
|
import * as R6 from "ramda";
|
|
584
583
|
var processed = Symbol("Type brand for ProcessedThemeObject");
|
|
@@ -589,7 +589,6 @@ var TypographyValues;
|
|
|
589
589
|
})(TypographyValues || (TypographyValues = {}));
|
|
590
590
|
|
|
591
591
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
592
|
-
import { kebabCase } from "change-case";
|
|
593
592
|
import pc from "picocolors";
|
|
594
593
|
import * as R6 from "ramda";
|
|
595
594
|
var processed = Symbol("Type brand for ProcessedThemeObject");
|
|
@@ -584,7 +584,6 @@ var TypographyValues;
|
|
|
584
584
|
})(TypographyValues || (TypographyValues = {}));
|
|
585
585
|
|
|
586
586
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
587
|
-
import { kebabCase } from "change-case";
|
|
588
587
|
import pc from "picocolors";
|
|
589
588
|
import * as R6 from "ramda";
|
|
590
589
|
var processed = Symbol("Type brand for ProcessedThemeObject");
|
|
@@ -577,7 +577,6 @@ var TypographyValues;
|
|
|
577
577
|
})(TypographyValues || (TypographyValues = {}));
|
|
578
578
|
|
|
579
579
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
580
|
-
import { kebabCase } from "change-case";
|
|
581
580
|
import pc from "picocolors";
|
|
582
581
|
import * as R7 from "ramda";
|
|
583
582
|
var processed = Symbol("Type brand for ProcessedThemeObject");
|
|
@@ -579,7 +579,6 @@ var TypographyValues;
|
|
|
579
579
|
})(TypographyValues || (TypographyValues = {}));
|
|
580
580
|
|
|
581
581
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
582
|
-
import { kebabCase } from "change-case";
|
|
583
582
|
import pc from "picocolors";
|
|
584
583
|
import * as R7 from "ramda";
|
|
585
584
|
var processed = Symbol("Type brand for ProcessedThemeObject");
|
|
@@ -276,7 +276,6 @@ var TypographyValues;
|
|
|
276
276
|
})(TypographyValues || (TypographyValues = {}));
|
|
277
277
|
|
|
278
278
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
279
|
-
import { kebabCase } from "change-case";
|
|
280
279
|
import pc from "picocolors";
|
|
281
280
|
import * as R2 from "ramda";
|
|
282
281
|
var getMultidimensionalThemes = (processed$themes, dimensions) => {
|
|
@@ -914,7 +914,6 @@ var TypographyValues;
|
|
|
914
914
|
})(TypographyValues || (TypographyValues = {}));
|
|
915
915
|
|
|
916
916
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
917
|
-
import { kebabCase } from "change-case";
|
|
918
917
|
import pc from "picocolors";
|
|
919
918
|
import * as R12 from "ramda";
|
|
920
919
|
var processed = Symbol("Type brand for ProcessedThemeObject");
|
|
@@ -974,7 +974,6 @@ var TypographyValues;
|
|
|
974
974
|
})(TypographyValues || (TypographyValues = {}));
|
|
975
975
|
|
|
976
976
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
977
|
-
import { kebabCase } from "change-case";
|
|
978
977
|
import pc from "picocolors";
|
|
979
978
|
import * as R12 from "ramda";
|
|
980
979
|
var processed = Symbol("Type brand for ProcessedThemeObject");
|
|
@@ -948,7 +948,6 @@ var TypographyValues;
|
|
|
948
948
|
})(TypographyValues || (TypographyValues = {}));
|
|
949
949
|
|
|
950
950
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
951
|
-
import { kebabCase } from "change-case";
|
|
952
951
|
import pc from "picocolors";
|
|
953
952
|
import * as R12 from "ramda";
|
|
954
953
|
var processed = Symbol("Type brand for ProcessedThemeObject");
|
|
@@ -921,7 +921,6 @@ var TypographyValues;
|
|
|
921
921
|
})(TypographyValues || (TypographyValues = {}));
|
|
922
922
|
|
|
923
923
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
924
|
-
import { kebabCase } from "change-case";
|
|
925
924
|
import pc from "picocolors";
|
|
926
925
|
import * as R12 from "ramda";
|
|
927
926
|
var processed = Symbol("Type brand for ProcessedThemeObject");
|
|
@@ -951,7 +951,6 @@ var TypographyValues;
|
|
|
951
951
|
})(TypographyValues || (TypographyValues = {}));
|
|
952
952
|
|
|
953
953
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
954
|
-
import { kebabCase } from "change-case";
|
|
955
954
|
import pc from "picocolors";
|
|
956
955
|
import * as R12 from "ramda";
|
|
957
956
|
var processed = Symbol("Type brand for ProcessedThemeObject");
|
|
@@ -973,7 +973,6 @@ var TypographyValues;
|
|
|
973
973
|
})(TypographyValues || (TypographyValues = {}));
|
|
974
974
|
|
|
975
975
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
976
|
-
import { kebabCase } from "change-case";
|
|
977
976
|
import pc from "picocolors";
|
|
978
977
|
import * as R12 from "ramda";
|
|
979
978
|
var processed = Symbol("Type brand for ProcessedThemeObject");
|
|
@@ -619,7 +619,6 @@ var TypographyValues;
|
|
|
619
619
|
})(TypographyValues || (TypographyValues = {}));
|
|
620
620
|
|
|
621
621
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
622
|
-
import { kebabCase } from "change-case";
|
|
623
622
|
import pc from "picocolors";
|
|
624
623
|
import * as R7 from "ramda";
|
|
625
624
|
var processed = Symbol("Type brand for ProcessedThemeObject");
|
|
@@ -4,7 +4,7 @@ import pc3 from "picocolors";
|
|
|
4
4
|
// package.json
|
|
5
5
|
var package_default = {
|
|
6
6
|
name: "@digdir/designsystemet",
|
|
7
|
-
version: "1.
|
|
7
|
+
version: "1.11.0",
|
|
8
8
|
description: "CLI for Designsystemet",
|
|
9
9
|
author: "Designsystemet team",
|
|
10
10
|
engines: {
|
|
@@ -56,23 +56,18 @@ var package_default = {
|
|
|
56
56
|
"test:tokens-build-config-tailwind": "pnpm run designsystemet tokens build -t ./temp/config/design-tokens -o ./temp/config/build --clean --experimental-tailwind",
|
|
57
57
|
"test:tokens-create-and-build-options": "pnpm test:tokens-create-options && pnpm test:tokens-build",
|
|
58
58
|
"test:tokens-create-and-build-config": "pnpm test:tokens-create-config && pnpm test:tokens-build-config",
|
|
59
|
-
"test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/design-tokens --dry",
|
|
59
|
+
"test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/digdir/design-tokens --dry",
|
|
60
60
|
test: "node -v && pnpm test:tokens-create-and-build-options && pnpm test:generate-config-from-tokens && pnpm test:tokens-create-and-build-config",
|
|
61
|
-
"digdir:tokens-build": "pnpm run designsystemet tokens build -t ../../internal/design-tokens -o ../../packages/theme/brand --clean --experimental-tailwind",
|
|
62
|
-
"digdir:tokens-create": "pnpm run designsystemet tokens create --config ./configs/digdir.config.json",
|
|
63
61
|
"update:template": "tsx ./src/scripts/update-template.ts",
|
|
64
62
|
"update:preview-tokens": "tsx ./src/scripts/update-preview-tokens.ts",
|
|
65
|
-
|
|
66
|
-
verify: "pnpm test && pnpm update:template && pnpm update:theme-digdir && pnpm build:tokens"
|
|
63
|
+
verify: "pnpm test && pnpm update:template && pnpm --filter @internal/digdir update:theme-digdir"
|
|
67
64
|
},
|
|
68
65
|
dependencies: {
|
|
69
66
|
"@commander-js/extra-typings": "^14.0.0",
|
|
70
67
|
"@digdir/designsystemet-types": "workspace:^",
|
|
71
68
|
"@tokens-studio/sd-transforms": "2.0.3",
|
|
72
|
-
"apca-w3": "^0.1.9",
|
|
73
|
-
"change-case": "^5.4.4",
|
|
74
69
|
"chroma-js": "^3.2.0",
|
|
75
|
-
"colorjs.io": "^0.6.0
|
|
70
|
+
"colorjs.io": "^0.6.0",
|
|
76
71
|
commander: "^14.0.2",
|
|
77
72
|
"fast-glob": "^3.3.3",
|
|
78
73
|
hsluv: "^1.0.1",
|
|
@@ -80,20 +75,16 @@ var package_default = {
|
|
|
80
75
|
picocolors: "^1.1.1",
|
|
81
76
|
postcss: "^8.5.6",
|
|
82
77
|
ramda: "^0.32.0",
|
|
83
|
-
"style-dictionary": "^5.1.
|
|
84
|
-
zod: "^4.
|
|
85
|
-
"zod-validation-error": "^
|
|
78
|
+
"style-dictionary": "^5.1.3",
|
|
79
|
+
zod: "^4.3.5",
|
|
80
|
+
"zod-validation-error": "^5.0.0"
|
|
86
81
|
},
|
|
87
82
|
devDependencies: {
|
|
88
83
|
"@tokens-studio/types": "0.5.2",
|
|
89
|
-
"@types/apca-w3": "^0.1.3",
|
|
90
84
|
"@types/chroma-js": "^3.1.2",
|
|
91
|
-
"@types/
|
|
92
|
-
"@types/node": "^22.19.1",
|
|
85
|
+
"@types/node": "^24.10.7",
|
|
93
86
|
"@types/object-hash": "^3.0.6",
|
|
94
87
|
"@types/ramda": "^0.31.1",
|
|
95
|
-
"fs-extra": "^11.3.2",
|
|
96
|
-
tslib: "^2.8.1",
|
|
97
88
|
tsup: "^8.5.1",
|
|
98
89
|
tsx: "^4.21.0",
|
|
99
90
|
typescript: "^5.9.3"
|
|
@@ -1107,7 +1098,6 @@ var TypographyValues;
|
|
|
1107
1098
|
})(TypographyValues || (TypographyValues = {}));
|
|
1108
1099
|
|
|
1109
1100
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
1110
|
-
import { kebabCase } from "change-case";
|
|
1111
1101
|
import pc from "picocolors";
|
|
1112
1102
|
import * as R13 from "ramda";
|
|
1113
1103
|
var processed = Symbol("Type brand for ProcessedThemeObject");
|
|
@@ -5,7 +5,7 @@ import * as R2 from "ramda";
|
|
|
5
5
|
// package.json
|
|
6
6
|
var package_default = {
|
|
7
7
|
name: "@digdir/designsystemet",
|
|
8
|
-
version: "1.
|
|
8
|
+
version: "1.11.0",
|
|
9
9
|
description: "CLI for Designsystemet",
|
|
10
10
|
author: "Designsystemet team",
|
|
11
11
|
engines: {
|
|
@@ -57,23 +57,18 @@ var package_default = {
|
|
|
57
57
|
"test:tokens-build-config-tailwind": "pnpm run designsystemet tokens build -t ./temp/config/design-tokens -o ./temp/config/build --clean --experimental-tailwind",
|
|
58
58
|
"test:tokens-create-and-build-options": "pnpm test:tokens-create-options && pnpm test:tokens-build",
|
|
59
59
|
"test:tokens-create-and-build-config": "pnpm test:tokens-create-config && pnpm test:tokens-build-config",
|
|
60
|
-
"test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/design-tokens --dry",
|
|
60
|
+
"test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/digdir/design-tokens --dry",
|
|
61
61
|
test: "node -v && pnpm test:tokens-create-and-build-options && pnpm test:generate-config-from-tokens && pnpm test:tokens-create-and-build-config",
|
|
62
|
-
"digdir:tokens-build": "pnpm run designsystemet tokens build -t ../../internal/design-tokens -o ../../packages/theme/brand --clean --experimental-tailwind",
|
|
63
|
-
"digdir:tokens-create": "pnpm run designsystemet tokens create --config ./configs/digdir.config.json",
|
|
64
62
|
"update:template": "tsx ./src/scripts/update-template.ts",
|
|
65
63
|
"update:preview-tokens": "tsx ./src/scripts/update-preview-tokens.ts",
|
|
66
|
-
|
|
67
|
-
verify: "pnpm test && pnpm update:template && pnpm update:theme-digdir && pnpm build:tokens"
|
|
64
|
+
verify: "pnpm test && pnpm update:template && pnpm --filter @internal/digdir update:theme-digdir"
|
|
68
65
|
},
|
|
69
66
|
dependencies: {
|
|
70
67
|
"@commander-js/extra-typings": "^14.0.0",
|
|
71
68
|
"@digdir/designsystemet-types": "workspace:^",
|
|
72
69
|
"@tokens-studio/sd-transforms": "2.0.3",
|
|
73
|
-
"apca-w3": "^0.1.9",
|
|
74
|
-
"change-case": "^5.4.4",
|
|
75
70
|
"chroma-js": "^3.2.0",
|
|
76
|
-
"colorjs.io": "^0.6.0
|
|
71
|
+
"colorjs.io": "^0.6.0",
|
|
77
72
|
commander: "^14.0.2",
|
|
78
73
|
"fast-glob": "^3.3.3",
|
|
79
74
|
hsluv: "^1.0.1",
|
|
@@ -81,20 +76,16 @@ var package_default = {
|
|
|
81
76
|
picocolors: "^1.1.1",
|
|
82
77
|
postcss: "^8.5.6",
|
|
83
78
|
ramda: "^0.32.0",
|
|
84
|
-
"style-dictionary": "^5.1.
|
|
85
|
-
zod: "^4.
|
|
86
|
-
"zod-validation-error": "^
|
|
79
|
+
"style-dictionary": "^5.1.3",
|
|
80
|
+
zod: "^4.3.5",
|
|
81
|
+
"zod-validation-error": "^5.0.0"
|
|
87
82
|
},
|
|
88
83
|
devDependencies: {
|
|
89
84
|
"@tokens-studio/types": "0.5.2",
|
|
90
|
-
"@types/apca-w3": "^0.1.3",
|
|
91
85
|
"@types/chroma-js": "^3.1.2",
|
|
92
|
-
"@types/
|
|
93
|
-
"@types/node": "^22.19.1",
|
|
86
|
+
"@types/node": "^24.10.7",
|
|
94
87
|
"@types/object-hash": "^3.0.6",
|
|
95
88
|
"@types/ramda": "^0.31.1",
|
|
96
|
-
"fs-extra": "^11.3.2",
|
|
97
|
-
tslib: "^2.8.1",
|
|
98
89
|
tsup: "^8.5.1",
|
|
99
90
|
tsx: "^4.21.0",
|
|
100
91
|
typescript: "^5.9.3"
|
|
@@ -1017,7 +1017,6 @@ var TypographyValues;
|
|
|
1017
1017
|
})(TypographyValues || (TypographyValues = {}));
|
|
1018
1018
|
|
|
1019
1019
|
// src/tokens/process/utils/getMultidimensionalThemes.ts
|
|
1020
|
-
import { kebabCase } from "change-case";
|
|
1021
1020
|
import pc from "picocolors";
|
|
1022
1021
|
import * as R13 from "ramda";
|
|
1023
1022
|
var getMultidimensionalThemes = (processed$themes, dimensions) => {
|