@digdir/designsystemet 1.8.0 → 1.10.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.
Files changed (51) hide show
  1. package/configs/test-tokens.config.json +10 -0
  2. package/dist/bin/config.js +12 -1
  3. package/dist/bin/designsystemet.js +56 -22
  4. package/dist/{color.base.template-QGZJKXMN.json → color.base.template-Z7YWN2TF.json} +2 -2
  5. package/dist/config.schema.json +63 -30
  6. package/dist/src/config.d.ts +30 -0
  7. package/dist/src/config.d.ts.map +1 -1
  8. package/dist/src/config.js +12 -1
  9. package/dist/src/index.js +56 -22
  10. package/dist/src/scripts/createJsonSchema.js +12 -1
  11. package/dist/src/scripts/update-preview-tokens.js +50 -58
  12. package/dist/src/scripts/update-template.js +12 -2
  13. package/dist/src/tokens/build.js +14 -17
  14. package/dist/src/tokens/create/generators/$designsystemet.js +7 -16
  15. package/dist/src/tokens/create/generators/color.d.ts.map +1 -1
  16. package/dist/src/tokens/create/generators/color.js +18 -2
  17. package/dist/src/tokens/create/generators/semantic.js +2 -2
  18. package/dist/src/tokens/create/generators/theme.d.ts.map +1 -1
  19. package/dist/src/tokens/create/generators/theme.js +10 -0
  20. package/dist/src/tokens/create/write.js +7 -16
  21. package/dist/src/tokens/create.js +30 -4
  22. package/dist/src/tokens/format.js +44 -21
  23. package/dist/src/tokens/index.js +44 -21
  24. package/dist/src/tokens/process/configs/color.js +0 -1
  25. package/dist/src/tokens/process/configs/semantic.js +0 -1
  26. package/dist/src/tokens/process/configs/size-mode.js +0 -1
  27. package/dist/src/tokens/process/configs/size.js +0 -1
  28. package/dist/src/tokens/process/configs/type-scale.js +0 -1
  29. package/dist/src/tokens/process/configs/typography.js +0 -1
  30. package/dist/src/tokens/process/configs.js +0 -1
  31. package/dist/src/tokens/process/formats/css/color.js +0 -1
  32. package/dist/src/tokens/process/formats/css/semantic.js +0 -1
  33. package/dist/src/tokens/process/formats/css/size-mode.js +0 -1
  34. package/dist/src/tokens/process/formats/css/size.js +0 -1
  35. package/dist/src/tokens/process/formats/css/type-scale.js +0 -1
  36. package/dist/src/tokens/process/formats/css/typography.js +0 -1
  37. package/dist/src/tokens/process/formats/css.js +0 -1
  38. package/dist/src/tokens/process/output/declarations.js +7 -17
  39. package/dist/src/tokens/process/output/theme.js +7 -16
  40. package/dist/src/tokens/process/platform.js +0 -1
  41. package/dist/src/tokens/process/utils/getMultidimensionalThemes.d.ts.map +1 -1
  42. package/dist/src/tokens/process/utils/getMultidimensionalThemes.js +5 -1
  43. package/dist/src/tokens/process/utils/kebab-case.d.ts +5 -0
  44. package/dist/src/tokens/process/utils/kebab-case.d.ts.map +1 -0
  45. package/dist/src/tokens/process/utils/kebab-case.js +7 -0
  46. package/dist/src/tokens/template/design-tokens/semantic/color.base.template.js +1 -1
  47. package/package.json +8 -17
  48. package/configs/digdir.config.json +0 -63
  49. package/dist/src/scripts/update-design-tokens.d.ts +0 -2
  50. package/dist/src/scripts/update-design-tokens.d.ts.map +0 -1
  51. package/dist/src/scripts/update-design-tokens.js +0 -37
@@ -46,6 +46,16 @@
46
46
  "linkVisited": {
47
47
  "light": "#ff1234",
48
48
  "dark": "#1234ff"
49
+ },
50
+ "focus": {
51
+ "inner": {
52
+ "light": "#00ff00",
53
+ "dark": "#00ffff"
54
+ },
55
+ "outer": {
56
+ "light": "#ffff00",
57
+ "dark": "#ff00aa"
58
+ }
49
59
  }
50
60
  }
51
61
  },
@@ -397,10 +397,21 @@ var linkVisitedOverrideSchema = z.object({
397
397
  light: colorSchema.optional().describe("A hex color that overrides light mode"),
398
398
  dark: colorSchema.optional().describe("A hex color that overrides dark mode")
399
399
  }).describe('Overrides for the "link-visited" color');
400
+ var focusOverrideSchema = z.object({
401
+ inner: z.object({
402
+ light: colorSchema.optional().describe("A hex color that overrides light mode"),
403
+ dark: colorSchema.optional().describe("A hex color that overrides dark mode")
404
+ }).optional().describe('Overrides for the "focus-inner" color'),
405
+ outer: z.object({
406
+ light: colorSchema.optional().describe("A hex color that overrides light mode"),
407
+ dark: colorSchema.optional().describe("A hex color that overrides dark mode")
408
+ }).optional().describe('Overrides for the "focus-outer" color')
409
+ }).describe("Overrides for the focus colors");
400
410
  var overridesSchema = z.object({
401
411
  colors: semanticColorOverrideSchema.optional(),
402
412
  severity: severityColorOverrideSchema.optional(),
403
- linkVisited: linkVisitedOverrideSchema.optional()
413
+ linkVisited: linkVisitedOverrideSchema.optional(),
414
+ focus: focusOverrideSchema.optional()
404
415
  }).describe("Overrides for generated design tokens. Currently only supports colors defined in your theme").optional();
405
416
  var themeSchema = z.object({
406
417
  colors: z.object({
@@ -861,7 +861,7 @@ import pc5 from "picocolors";
861
861
  // package.json
862
862
  var package_default = {
863
863
  name: "@digdir/designsystemet",
864
- version: "1.8.0",
864
+ version: "1.10.0",
865
865
  description: "CLI for Designsystemet",
866
866
  author: "Designsystemet team",
867
867
  engines: {
@@ -913,23 +913,18 @@ var package_default = {
913
913
  "test:tokens-build-config-tailwind": "pnpm run designsystemet tokens build -t ./temp/config/design-tokens -o ./temp/config/build --clean --experimental-tailwind",
914
914
  "test:tokens-create-and-build-options": "pnpm test:tokens-create-options && pnpm test:tokens-build",
915
915
  "test:tokens-create-and-build-config": "pnpm test:tokens-create-config && pnpm test:tokens-build-config",
916
- "test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/design-tokens --dry",
916
+ "test:generate-config-from-tokens": "pnpm run designsystemet generate-config-from-tokens -d ../../internal/digdir/design-tokens --dry",
917
917
  test: "node -v && pnpm test:tokens-create-and-build-options && pnpm test:generate-config-from-tokens && pnpm test:tokens-create-and-build-config",
918
- "digdir:tokens-build": "pnpm run designsystemet tokens build -t ../../internal/design-tokens -o ../../packages/theme/brand --clean --experimental-tailwind",
919
- "digdir:tokens-create": "pnpm run designsystemet tokens create --config ./configs/digdir.config.json",
920
918
  "update:template": "tsx ./src/scripts/update-template.ts",
921
919
  "update:preview-tokens": "tsx ./src/scripts/update-preview-tokens.ts",
922
- "update:theme-digdir": "pnpm digdir:tokens-create && tsx ./src/scripts/update-design-tokens.ts && pnpm digdir:tokens-build",
923
- verify: "pnpm test && pnpm update:template && pnpm update:theme-digdir && pnpm build:tokens"
920
+ verify: "pnpm test && pnpm update:template && pnpm --filter @internal/digdir update:theme-digdir"
924
921
  },
925
922
  dependencies: {
926
923
  "@commander-js/extra-typings": "^14.0.0",
927
924
  "@digdir/designsystemet-types": "workspace:^",
928
- "@tokens-studio/sd-transforms": "2.0.2",
929
- "apca-w3": "^0.1.9",
930
- "change-case": "^5.4.4",
925
+ "@tokens-studio/sd-transforms": "2.0.3",
931
926
  "chroma-js": "^3.2.0",
932
- "colorjs.io": "^0.6.0-alpha.1",
927
+ "colorjs.io": "^0.6.0",
933
928
  commander: "^14.0.2",
934
929
  "fast-glob": "^3.3.3",
935
930
  hsluv: "^1.0.1",
@@ -938,19 +933,15 @@ var package_default = {
938
933
  postcss: "^8.5.6",
939
934
  ramda: "^0.32.0",
940
935
  "style-dictionary": "^5.1.1",
941
- zod: "^4.1.13",
936
+ zod: "^4.3.5",
942
937
  "zod-validation-error": "^4.0.2"
943
938
  },
944
939
  devDependencies: {
945
940
  "@tokens-studio/types": "0.5.2",
946
- "@types/apca-w3": "^0.1.3",
947
941
  "@types/chroma-js": "^3.1.2",
948
- "@types/fs-extra": "^11.0.4",
949
- "@types/node": "^22.19.1",
942
+ "@types/node": "^22.19.3",
950
943
  "@types/object-hash": "^3.0.6",
951
944
  "@types/ramda": "^0.31.1",
952
- "fs-extra": "^11.3.2",
953
- tslib: "^2.8.1",
954
945
  tsup: "^8.5.1",
955
946
  tsx: "^4.21.0",
956
947
  typescript: "^5.9.3"
@@ -1976,9 +1967,15 @@ var TypographyValues;
1976
1967
  })(TypographyValues || (TypographyValues = {}));
1977
1968
 
1978
1969
  // src/tokens/process/utils/getMultidimensionalThemes.ts
1979
- import { kebabCase } from "change-case";
1980
1970
  import pc3 from "picocolors";
1981
1971
  import * as R17 from "ramda";
1972
+
1973
+ // src/tokens/process/utils/kebab-case.ts
1974
+ function kebabCase(str) {
1975
+ return str.replace(/([a-z])([A-Z])/g, "$1-$2").replace(/[\s_]+/g, "-").toLowerCase();
1976
+ }
1977
+
1978
+ // src/tokens/process/utils/getMultidimensionalThemes.ts
1982
1979
  var getMultidimensionalThemes = (processed$themes, dimensions) => {
1983
1980
  const verboseLogging = buildOptions?.verbose;
1984
1981
  const grouped$themes = groupThemes(processed$themes);
@@ -3856,7 +3853,8 @@ var generateColorScheme = (themeName, colorScheme2, colors2, overrides) => {
3856
3853
  (color, colorName) => generateColor(generateColorScale(color, colorScheme2), createColorOverrides(colorName)),
3857
3854
  colors2.support
3858
3855
  );
3859
- const neutral = generateColor(generateColorScale(colors2.neutral, colorScheme2), createColorOverrides("neutral"));
3856
+ const neutralColorScale = generateColorScale(colors2.neutral, colorScheme2);
3857
+ const neutral = generateColor(neutralColorScale, createColorOverrides("neutral"));
3860
3858
  const baseColorsWithOverrides = {
3861
3859
  ...baseColors,
3862
3860
  ...overrides?.severity
@@ -3866,7 +3864,12 @@ var generateColorScheme = (themeName, colorScheme2, colors2, overrides) => {
3866
3864
  baseColorsWithOverrides
3867
3865
  );
3868
3866
  const linkColor = generateColor(generateColorScale(dsLinkColor, colorScheme2));
3867
+ const defaultLinkVisited = linkColor[12];
3869
3868
  const linkOverride = overrides?.linkVisited?.[colorScheme2] ? { $type: "color", $value: overrides.linkVisited[colorScheme2] } : void 0;
3869
+ const defaultFocusInner = neutralColorScale[0].hex;
3870
+ const defaultFocusOuter = neutralColorScale[10].hex;
3871
+ const focusInnerOverride = overrides?.focus?.inner?.[colorScheme2];
3872
+ const focusOuterOverride = overrides?.focus?.outer?.[colorScheme2];
3870
3873
  return {
3871
3874
  [themeName]: {
3872
3875
  ...main,
@@ -3874,7 +3877,17 @@ var generateColorScheme = (themeName, colorScheme2, colors2, overrides) => {
3874
3877
  neutral,
3875
3878
  ...globalColors,
3876
3879
  link: {
3877
- visited: linkOverride || linkColor[12]
3880
+ visited: linkOverride || defaultLinkVisited
3881
+ },
3882
+ focus: {
3883
+ inner: {
3884
+ $type: "color",
3885
+ $value: focusInnerOverride || defaultFocusInner
3886
+ },
3887
+ outer: {
3888
+ $type: "color",
3889
+ $value: focusOuterOverride || defaultFocusOuter
3890
+ }
3878
3891
  }
3879
3892
  }
3880
3893
  };
@@ -3889,11 +3902,11 @@ var color_base_template_default = {
3889
3902
  focus: {
3890
3903
  inner: {
3891
3904
  $type: "color",
3892
- $value: "{color.neutral.background-default}"
3905
+ $value: "{color.focus.inner-color}"
3893
3906
  },
3894
3907
  outer: {
3895
3908
  $type: "color",
3896
- $value: "{color.neutral.text-default}"
3909
+ $value: "{color.focus.outer-color}"
3897
3910
  }
3898
3911
  }
3899
3912
  },
@@ -4249,6 +4262,16 @@ var generateTheme = (colors2, themeName, borderRadius) => {
4249
4262
  $type: "color",
4250
4263
  $value: `{${themeName}.link.visited}`
4251
4264
  }
4265
+ },
4266
+ focus: {
4267
+ "inner-color": {
4268
+ $type: "color",
4269
+ $value: `{${themeName}.focus.inner}`
4270
+ },
4271
+ "outer-color": {
4272
+ $type: "color",
4273
+ $value: `{${themeName}.focus.outer}`
4274
+ }
4252
4275
  }
4253
4276
  },
4254
4277
  ...remainingThemeFile
@@ -4641,10 +4664,21 @@ var linkVisitedOverrideSchema = z.object({
4641
4664
  light: colorSchema.optional().describe("A hex color that overrides light mode"),
4642
4665
  dark: colorSchema.optional().describe("A hex color that overrides dark mode")
4643
4666
  }).describe('Overrides for the "link-visited" color');
4667
+ var focusOverrideSchema = z.object({
4668
+ inner: z.object({
4669
+ light: colorSchema.optional().describe("A hex color that overrides light mode"),
4670
+ dark: colorSchema.optional().describe("A hex color that overrides dark mode")
4671
+ }).optional().describe('Overrides for the "focus-inner" color'),
4672
+ outer: z.object({
4673
+ light: colorSchema.optional().describe("A hex color that overrides light mode"),
4674
+ dark: colorSchema.optional().describe("A hex color that overrides dark mode")
4675
+ }).optional().describe('Overrides for the "focus-outer" color')
4676
+ }).describe("Overrides for the focus colors");
4644
4677
  var overridesSchema = z.object({
4645
4678
  colors: semanticColorOverrideSchema.optional(),
4646
4679
  severity: severityColorOverrideSchema.optional(),
4647
- linkVisited: linkVisitedOverrideSchema.optional()
4680
+ linkVisited: linkVisitedOverrideSchema.optional(),
4681
+ focus: focusOverrideSchema.optional()
4648
4682
  }).describe("Overrides for generated design tokens. Currently only supports colors defined in your theme").optional();
4649
4683
  var themeSchema = z.object({
4650
4684
  colors: z.object({
@@ -3,11 +3,11 @@
3
3
  "focus": {
4
4
  "inner": {
5
5
  "$type": "color",
6
- "$value": "{color.neutral.background-default}"
6
+ "$value": "{color.focus.inner-color}"
7
7
  },
8
8
  "outer": {
9
9
  "$type": "color",
10
- "$value": "{color.neutral.text-default}"
10
+ "$value": "{color.focus.outer-color}"
11
11
  }
12
12
  }
13
13
  },
@@ -6,25 +6,21 @@
6
6
  "type": "string"
7
7
  },
8
8
  "outDir": {
9
- "description": "Path to the output directory for the created design tokens",
10
- "type": "string"
9
+ "type": "string",
10
+ "description": "Path to the output directory for the created design tokens"
11
11
  },
12
12
  "themes": {
13
- "description": "An object with one or more themes. Each property defines a theme, and the property name is used as the theme name.",
14
13
  "type": "object",
15
14
  "propertyNames": {
16
15
  "type": "string"
17
16
  },
18
17
  "additionalProperties": {
19
- "description": "An object defining a theme. The property name holding the object becomes the theme name.",
20
18
  "type": "object",
21
19
  "properties": {
22
20
  "colors": {
23
- "description": "Defines the colors for this theme",
24
21
  "type": "object",
25
22
  "properties": {
26
23
  "main": {
27
- "description": "An object with one or more color definitions. The property name is used as the color name.",
28
24
  "type": "object",
29
25
  "propertyNames": {
30
26
  "type": "string",
@@ -32,11 +28,11 @@
32
28
  },
33
29
  "additionalProperties": {
34
30
  "description": "A hex color, which is used for creating a color scale. Invalid color names: neutral, success, warning, danger, info"
35
- }
31
+ },
32
+ "description": "An object with one or more color definitions. The property name is used as the color name."
36
33
  },
37
34
  "support": {
38
35
  "default": {},
39
- "description": "An object with one or more color definitions. The property name is used as the color name.",
40
36
  "type": "object",
41
37
  "propertyNames": {
42
38
  "type": "string",
@@ -44,7 +40,8 @@
44
40
  },
45
41
  "additionalProperties": {
46
42
  "description": "A hex color, which is used for creating a color scale. Invalid color names: neutral, success, warning, danger, info"
47
- }
43
+ },
44
+ "description": "An object with one or more color definitions. The property name is used as the color name."
48
45
  },
49
46
  "neutral": {
50
47
  "description": "A hex color, which is used for creating a color scale."
@@ -55,38 +52,36 @@
55
52
  "support",
56
53
  "neutral"
57
54
  ],
58
- "additionalProperties": false
55
+ "additionalProperties": false,
56
+ "description": "Defines the colors for this theme"
59
57
  },
60
58
  "typography": {
61
- "description": "Defines the typography for a given theme",
62
59
  "type": "object",
63
60
  "properties": {
64
61
  "fontFamily": {
65
- "description": "Sets the font-family for this theme",
66
- "type": "string"
62
+ "type": "string",
63
+ "description": "Sets the font-family for this theme"
67
64
  }
68
65
  },
69
66
  "required": [
70
67
  "fontFamily"
71
68
  ],
72
- "additionalProperties": false
69
+ "additionalProperties": false,
70
+ "description": "Defines the typography for a given theme"
73
71
  },
74
72
  "borderRadius": {
75
- "description": "Defines the border-radius for this theme",
76
- "type": "number"
73
+ "type": "number",
74
+ "description": "Defines the border-radius for this theme"
77
75
  },
78
76
  "overrides": {
79
- "description": "Overrides for generated design tokens. Currently only supports colors defined in your theme",
80
77
  "type": "object",
81
78
  "properties": {
82
79
  "colors": {
83
- "description": "An object with color names as keys",
84
80
  "type": "object",
85
81
  "propertyNames": {
86
82
  "type": "string"
87
83
  },
88
84
  "additionalProperties": {
89
- "description": "The name of the color to add overrides for, e.g. \"accent\"",
90
85
  "type": "object",
91
86
  "propertyNames": {
92
87
  "type": "string",
@@ -110,7 +105,6 @@
110
105
  ]
111
106
  },
112
107
  "additionalProperties": {
113
- "description": "Override values for semantic color tokens like \"background-subtle\", \"border-default\", etc.",
114
108
  "type": "object",
115
109
  "properties": {
116
110
  "light": {
@@ -120,9 +114,12 @@
120
114
  "description": "A hex color that overrides dark mode"
121
115
  }
122
116
  },
123
- "additionalProperties": false
124
- }
125
- }
117
+ "additionalProperties": false,
118
+ "description": "Override values for semantic color tokens like \"background-subtle\", \"border-default\", etc."
119
+ },
120
+ "description": "The name of the color to add overrides for, e.g. \"accent\""
121
+ },
122
+ "description": "An object with color names as keys"
126
123
  },
127
124
  "severity": {
128
125
  "description": "An object with severity color names as keys",
@@ -141,7 +138,6 @@
141
138
  }
142
139
  },
143
140
  "linkVisited": {
144
- "description": "Overrides for the \"link-visited\" color",
145
141
  "type": "object",
146
142
  "properties": {
147
143
  "light": {
@@ -151,21 +147,58 @@
151
147
  "description": "A hex color that overrides dark mode"
152
148
  }
153
149
  },
154
- "additionalProperties": false
150
+ "additionalProperties": false,
151
+ "description": "Overrides for the \"link-visited\" color"
152
+ },
153
+ "focus": {
154
+ "type": "object",
155
+ "properties": {
156
+ "inner": {
157
+ "description": "Overrides for the \"focus-inner\" color",
158
+ "type": "object",
159
+ "properties": {
160
+ "light": {
161
+ "description": "A hex color that overrides light mode"
162
+ },
163
+ "dark": {
164
+ "description": "A hex color that overrides dark mode"
165
+ }
166
+ },
167
+ "additionalProperties": false
168
+ },
169
+ "outer": {
170
+ "description": "Overrides for the \"focus-outer\" color",
171
+ "type": "object",
172
+ "properties": {
173
+ "light": {
174
+ "description": "A hex color that overrides light mode"
175
+ },
176
+ "dark": {
177
+ "description": "A hex color that overrides dark mode"
178
+ }
179
+ },
180
+ "additionalProperties": false
181
+ }
182
+ },
183
+ "additionalProperties": false,
184
+ "description": "Overrides for the focus colors"
155
185
  }
156
186
  },
157
- "additionalProperties": false
187
+ "additionalProperties": false,
188
+ "description": "Overrides for generated design tokens. Currently only supports colors defined in your theme"
158
189
  }
159
190
  },
160
191
  "required": [
161
192
  "colors"
162
193
  ],
163
- "additionalProperties": false
164
- }
194
+ "additionalProperties": false,
195
+ "description": "An object defining a theme. The property name holding the object becomes the theme name."
196
+ },
197
+ "description": "An object with one or more themes. Each property defines a theme, and the property name is used as the theme name."
165
198
  },
166
199
  "clean": {
167
- "description": "Delete the output directory before building or creating tokens",
168
- "type": "boolean"
200
+ "type": "boolean",
201
+ "description": "Delete the output directory before building or creating tokens"
169
202
  }
170
203
  },
171
204
  "required": [
@@ -43,6 +43,16 @@ declare const overridesSchema: z.ZodOptional<z.ZodObject<{
43
43
  light: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
44
44
  dark: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
45
45
  }, z.core.$strip>>;
46
+ focus: z.ZodOptional<z.ZodObject<{
47
+ inner: z.ZodOptional<z.ZodObject<{
48
+ light: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
49
+ dark: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
50
+ }, z.core.$strip>>;
51
+ outer: z.ZodOptional<z.ZodObject<{
52
+ light: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
53
+ dark: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
54
+ }, z.core.$strip>>;
55
+ }, z.core.$strip>>;
46
56
  }, z.core.$strip>>;
47
57
  declare const themeSchema: z.ZodObject<{
48
58
  colors: z.ZodObject<{
@@ -86,6 +96,16 @@ declare const themeSchema: z.ZodObject<{
86
96
  light: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
87
97
  dark: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
88
98
  }, z.core.$strip>>;
99
+ focus: z.ZodOptional<z.ZodObject<{
100
+ inner: z.ZodOptional<z.ZodObject<{
101
+ light: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
102
+ dark: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
103
+ }, z.core.$strip>>;
104
+ outer: z.ZodOptional<z.ZodObject<{
105
+ light: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
106
+ dark: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
107
+ }, z.core.$strip>>;
108
+ }, z.core.$strip>>;
89
109
  }, z.core.$strip>>;
90
110
  }, z.core.$strip>;
91
111
  export declare const commonConfig: z.ZodObject<{
@@ -138,6 +158,16 @@ export declare const configFileCreateSchema: z.ZodObject<{
138
158
  light: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
139
159
  dark: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
140
160
  }, z.core.$strip>>;
161
+ focus: z.ZodOptional<z.ZodObject<{
162
+ inner: z.ZodOptional<z.ZodObject<{
163
+ light: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
164
+ dark: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
165
+ }, z.core.$strip>>;
166
+ outer: z.ZodOptional<z.ZodObject<{
167
+ light: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
168
+ dark: z.ZodOptional<z.ZodPipe<z.ZodString, z.ZodTransform<`#${string}`, string>>>;
169
+ }, z.core.$strip>>;
170
+ }, z.core.$strip>>;
141
171
  }, z.core.$strip>>;
142
172
  }, z.core.$strip>>>;
143
173
  clean: z.ZodOptional<z.ZodBoolean>;
@@ -1 +1 @@
1
- {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/config.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAuCxB;;;;;;;;GAQG;AACH,wBAAgB,cAAc,CAAC,CAAC,EAC9B,MAAM,EAAE,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,EACpB,iBAAiB,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAC1C,UAAU,EAAE,MAAM,GACjB,CAAC,CAUH;AAED,wBAAgB,WAAW,CAAC,CAAC,EAAE,UAAU,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,CAAC,CAexE;AAWD,eAAO,MAAM,UAAU,QAA2C,CAAC;AAoDnE,QAAA,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBAOR,CAAC;AAEd,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAkBmG,CAAC;AAErH,eAAO,MAAM,YAAY;;iBAEvB,CAAC;AAYH;;GAEG;AACH,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAAqD,CAAC;AACzF,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;AAC9D,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;AAC7D,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AACxE,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,CAAC;AAC5D,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC"}
1
+ {"version":3,"file":"config.d.ts","sourceRoot":"","sources":["../../src/config.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAuCxB;;;;;;;;GAQG;AACH,wBAAgB,cAAc,CAAC,CAAC,EAC9B,MAAM,EAAE,CAAC,CAAC,OAAO,CAAC,CAAC,CAAC,EACpB,iBAAiB,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,EAC1C,UAAU,EAAE,MAAM,GACjB,CAAC,CAUH;AAED,wBAAgB,WAAW,CAAC,CAAC,EAAE,UAAU,EAAE,MAAM,EAAE,UAAU,EAAE,MAAM,GAAG,CAAC,CAexE;AAWD,eAAO,MAAM,UAAU,QAA2C,CAAC;AAuEnE,QAAA,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBAQR,CAAC;AAEd,QAAA,MAAM,WAAW;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAkBmG,CAAC;AAErH,eAAO,MAAM,YAAY;;iBAEvB,CAAC;AAYH;;GAEG;AACH,eAAO,MAAM,sBAAsB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;iBAAqD,CAAC;AACzF,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;AAC9D,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,YAAY,CAAC,CAAC;AAC7D,MAAM,MAAM,kBAAkB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AACxE,MAAM,MAAM,iBAAiB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,WAAW,CAAC,CAAC;AAC5D,MAAM,MAAM,mBAAmB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,eAAe,CAAC,CAAC"}
@@ -392,10 +392,21 @@ var linkVisitedOverrideSchema = z.object({
392
392
  light: colorSchema.optional().describe("A hex color that overrides light mode"),
393
393
  dark: colorSchema.optional().describe("A hex color that overrides dark mode")
394
394
  }).describe('Overrides for the "link-visited" color');
395
+ var focusOverrideSchema = z.object({
396
+ inner: z.object({
397
+ light: colorSchema.optional().describe("A hex color that overrides light mode"),
398
+ dark: colorSchema.optional().describe("A hex color that overrides dark mode")
399
+ }).optional().describe('Overrides for the "focus-inner" color'),
400
+ outer: z.object({
401
+ light: colorSchema.optional().describe("A hex color that overrides light mode"),
402
+ dark: colorSchema.optional().describe("A hex color that overrides dark mode")
403
+ }).optional().describe('Overrides for the "focus-outer" color')
404
+ }).describe("Overrides for the focus colors");
395
405
  var overridesSchema = z.object({
396
406
  colors: semanticColorOverrideSchema.optional(),
397
407
  severity: severityColorOverrideSchema.optional(),
398
- linkVisited: linkVisitedOverrideSchema.optional()
408
+ linkVisited: linkVisitedOverrideSchema.optional(),
409
+ focus: focusOverrideSchema.optional()
399
410
  }).describe("Overrides for generated design tokens. Currently only supports colors defined in your theme").optional();
400
411
  var themeSchema = z.object({
401
412
  colors: z.object({