@tamagui/themes 1.114.4 → 1.115.1

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/dist/cjs/componentThemeDefinitions.cjs +124 -0
  2. package/dist/cjs/generated-new.cjs +3425 -0
  3. package/dist/cjs/generated-v2.cjs +3327 -0
  4. package/dist/cjs/generated-v3.cjs +1995 -0
  5. package/dist/cjs/helpers.cjs +34 -0
  6. package/dist/cjs/index.cjs +25 -0
  7. package/dist/cjs/{masks.js → masks.cjs} +54 -26
  8. package/dist/cjs/palettes.cjs +52 -0
  9. package/dist/cjs/shadows.cjs +43 -0
  10. package/dist/cjs/templates.cjs +118 -0
  11. package/dist/cjs/themes-new.cjs +86 -0
  12. package/dist/cjs/themes-old.cjs +284 -0
  13. package/dist/cjs/{themes.js → themes.cjs} +22 -14
  14. package/dist/cjs/tokens.cjs +155 -0
  15. package/dist/cjs/v2-themes.cjs +466 -0
  16. package/dist/cjs/{v2.js → v2.cjs} +32 -15
  17. package/dist/cjs/v3-themes.cjs +556 -0
  18. package/dist/cjs/{v3.js → v3.cjs} +32 -15
  19. package/package.json +13 -12
  20. package/dist/cjs/componentThemeDefinitions.js +0 -123
  21. package/dist/cjs/generated-new.js +0 -1806
  22. package/dist/cjs/generated-v2.js +0 -1788
  23. package/dist/cjs/generated-v3.js +0 -3564
  24. package/dist/cjs/helpers.js +0 -29
  25. package/dist/cjs/index.js +0 -22
  26. package/dist/cjs/palettes.js +0 -82
  27. package/dist/cjs/shadows.js +0 -34
  28. package/dist/cjs/templates.js +0 -106
  29. package/dist/cjs/themes-new.js +0 -76
  30. package/dist/cjs/themes-old.js +0 -266
  31. package/dist/cjs/tokens.js +0 -143
  32. package/dist/cjs/v2-themes.js +0 -479
  33. package/dist/cjs/v3-themes.js +0 -594
  34. /package/dist/cjs/{componentThemeDefinitions.js.map → componentThemeDefinitions.cjs.map} +0 -0
  35. /package/dist/cjs/{generated-new.js.map → generated-new.cjs.map} +0 -0
  36. /package/dist/cjs/{generated-v2.js.map → generated-v2.cjs.map} +0 -0
  37. /package/dist/cjs/{generated-v3.js.map → generated-v3.cjs.map} +0 -0
  38. /package/dist/cjs/{helpers.js.map → helpers.cjs.map} +0 -0
  39. /package/dist/cjs/{index.js.map → index.cjs.map} +0 -0
  40. /package/dist/cjs/{masks.js.map → masks.cjs.map} +0 -0
  41. /package/dist/cjs/{palettes.js.map → palettes.cjs.map} +0 -0
  42. /package/dist/cjs/{shadows.js.map → shadows.cjs.map} +0 -0
  43. /package/dist/cjs/{templates.js.map → templates.cjs.map} +0 -0
  44. /package/dist/cjs/{themes-new.js.map → themes-new.cjs.map} +0 -0
  45. /package/dist/cjs/{themes-old.js.map → themes-old.cjs.map} +0 -0
  46. /package/dist/cjs/{themes.js.map → themes.cjs.map} +0 -0
  47. /package/dist/cjs/{tokens.js.map → tokens.cjs.map} +0 -0
  48. /package/dist/cjs/{v2-themes.js.map → v2-themes.cjs.map} +0 -0
  49. /package/dist/cjs/{v2.js.map → v2.cjs.map} +0 -0
  50. /package/dist/cjs/{v3-themes.js.map → v3-themes.cjs.map} +0 -0
  51. /package/dist/cjs/{v3.js.map → v3.cjs.map} +0 -0
@@ -1,143 +0,0 @@
1
- var __defProp = Object.defineProperty;
2
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
- var __getOwnPropNames = Object.getOwnPropertyNames;
4
- var __hasOwnProp = Object.prototype.hasOwnProperty;
5
- var __export = (target, all) => {
6
- for (var name in all)
7
- __defProp(target, name, { get: all[name], enumerable: !0 });
8
- }, __copyProps = (to, from, except, desc) => {
9
- if (from && typeof from == "object" || typeof from == "function")
10
- for (let key of __getOwnPropNames(from))
11
- !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
12
- return to;
13
- };
14
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
15
- var tokens_exports = {};
16
- __export(tokens_exports, {
17
- color: () => color,
18
- colorTokens: () => colorTokens,
19
- darkColors: () => darkColors,
20
- lightColors: () => lightColors,
21
- radius: () => radius,
22
- size: () => size,
23
- space: () => space,
24
- tokens: () => tokens,
25
- zIndex: () => zIndex
26
- });
27
- module.exports = __toCommonJS(tokens_exports);
28
- var import_colors = require("@tamagui/colors"), import_web = require("@tamagui/web");
29
- const size = {
30
- $0: 0,
31
- "$0.25": 2,
32
- "$0.5": 4,
33
- "$0.75": 8,
34
- $1: 20,
35
- "$1.5": 24,
36
- $2: 28,
37
- "$2.5": 32,
38
- $3: 36,
39
- "$3.5": 40,
40
- $4: 44,
41
- $true: 44,
42
- "$4.5": 48,
43
- $5: 52,
44
- $6: 64,
45
- $7: 74,
46
- $8: 84,
47
- $9: 94,
48
- $10: 104,
49
- $11: 124,
50
- $12: 144,
51
- $13: 164,
52
- $14: 184,
53
- $15: 204,
54
- $16: 224,
55
- $17: 224,
56
- $18: 244,
57
- $19: 264,
58
- $20: 284
59
- }, spaces = Object.entries(size).map(([k, v]) => [k, sizeToSpace(v)]);
60
- function sizeToSpace(v) {
61
- return v === 0 ? 0 : v === 2 ? 0.5 : v === 4 ? 1 : v === 8 ? 1.5 : v <= 16 ? Math.round(v * 0.333) : Math.floor(v * 0.7 - 12);
62
- }
63
- const spacesNegative = spaces.slice(1).map(([k, v]) => [`-${k.slice(1)}`, -v]), space = {
64
- ...Object.fromEntries(spaces),
65
- ...Object.fromEntries(spacesNegative)
66
- }, zIndex = {
67
- 0: 0,
68
- 1: 100,
69
- 2: 200,
70
- 3: 300,
71
- 4: 400,
72
- 5: 500
73
- }, colorTokens = {
74
- light: {
75
- blue: import_colors.blue,
76
- gray: import_colors.gray,
77
- green: import_colors.green,
78
- orange: import_colors.orange,
79
- pink: import_colors.pink,
80
- purple: import_colors.purple,
81
- red: import_colors.red,
82
- yellow: import_colors.yellow
83
- },
84
- dark: {
85
- blue: import_colors.blueDark,
86
- gray: import_colors.grayDark,
87
- green: import_colors.greenDark,
88
- orange: import_colors.orangeDark,
89
- pink: import_colors.pinkDark,
90
- purple: import_colors.purpleDark,
91
- red: import_colors.redDark,
92
- yellow: import_colors.yellowDark
93
- }
94
- }, darkColors = {
95
- ...colorTokens.dark.blue,
96
- ...colorTokens.dark.gray,
97
- ...colorTokens.dark.green,
98
- ...colorTokens.dark.orange,
99
- ...colorTokens.dark.pink,
100
- ...colorTokens.dark.purple,
101
- ...colorTokens.dark.red,
102
- ...colorTokens.dark.yellow
103
- }, lightColors = {
104
- ...colorTokens.light.blue,
105
- ...colorTokens.light.gray,
106
- ...colorTokens.light.green,
107
- ...colorTokens.light.orange,
108
- ...colorTokens.light.pink,
109
- ...colorTokens.light.purple,
110
- ...colorTokens.light.red,
111
- ...colorTokens.light.yellow
112
- }, color = {
113
- ...postfixObjKeys(lightColors, "Light"),
114
- ...postfixObjKeys(darkColors, "Dark")
115
- };
116
- function postfixObjKeys(obj, postfix) {
117
- return Object.fromEntries(
118
- Object.entries(obj).map(([k, v]) => [`${k}${postfix}`, v])
119
- );
120
- }
121
- const radius = {
122
- 0: 0,
123
- 1: 3,
124
- 2: 5,
125
- 3: 7,
126
- 4: 9,
127
- true: 9,
128
- 5: 10,
129
- 6: 16,
130
- 7: 19,
131
- 8: 22,
132
- 9: 26,
133
- 10: 34,
134
- 11: 42,
135
- 12: 50
136
- }, tokens = (0, import_web.createTokens)({
137
- color,
138
- radius,
139
- zIndex,
140
- space,
141
- size
142
- });
143
- //# sourceMappingURL=tokens.js.map
@@ -1,479 +0,0 @@
1
- var __defProp = Object.defineProperty;
2
- var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
3
- var __getOwnPropNames = Object.getOwnPropertyNames;
4
- var __hasOwnProp = Object.prototype.hasOwnProperty;
5
- var __export = (target, all) => {
6
- for (var name in all)
7
- __defProp(target, name, { get: all[name], enumerable: !0 });
8
- }, __copyProps = (to, from, except, desc) => {
9
- if (from && typeof from == "object" || typeof from == "function")
10
- for (let key of __getOwnPropNames(from))
11
- !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
12
- return to;
13
- };
14
- var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
15
- var v2_themes_exports = {};
16
- __export(v2_themes_exports, {
17
- maskOptions: () => maskOptions,
18
- masks: () => import_masks2.masks,
19
- palettes: () => palettes,
20
- templates: () => templates,
21
- themes: () => themes,
22
- tokens: () => tokens
23
- });
24
- module.exports = __toCommonJS(v2_themes_exports);
25
- var import_theme_builder = require("@tamagui/theme-builder"), import_colors = require("@tamagui/colors"), import_web = require("@tamagui/web"), import_masks = require("./masks"), import_masks2 = require("./masks");
26
- const colorTokens = {
27
- light: {
28
- blue: import_colors.blue,
29
- gray: import_colors.gray,
30
- green: import_colors.green,
31
- orange: import_colors.orange,
32
- pink: import_colors.pink,
33
- purple: import_colors.purple,
34
- red: import_colors.red,
35
- yellow: import_colors.yellow
36
- },
37
- dark: {
38
- blue: import_colors.blueDark,
39
- gray: import_colors.grayDark,
40
- green: import_colors.greenDark,
41
- orange: import_colors.orangeDark,
42
- pink: import_colors.pinkDark,
43
- purple: import_colors.purpleDark,
44
- red: import_colors.redDark,
45
- yellow: import_colors.yellowDark
46
- }
47
- }, palettes = (() => {
48
- const lightTransparent = "rgba(255,255,255,0)", darkTransparent = "rgba(10,10,10,0)", transparent = (hsl, opacity = 0) => hsl.replace("%)", `%, ${opacity})`).replace("hsl(", "hsla("), getColorPalette = (colors, color2 = colors[0]) => {
49
- const colorPalette = Object.values(colors), [head, tail] = [
50
- colorPalette.slice(0, 6),
51
- colorPalette.slice(colorPalette.length - 5)
52
- ];
53
- return [
54
- transparent(colorPalette[0]),
55
- ...head,
56
- ...tail,
57
- color2,
58
- transparent(colorPalette[colorPalette.length - 1])
59
- ];
60
- }, lightColor = "hsl(0, 0%, 9.0%)", lightPalette = [
61
- lightTransparent,
62
- "#fff",
63
- "#f8f8f8",
64
- "hsl(0, 0%, 96.3%)",
65
- "hsl(0, 0%, 94.1%)",
66
- "hsl(0, 0%, 92.0%)",
67
- "hsl(0, 0%, 90.0%)",
68
- "hsl(0, 0%, 88.5%)",
69
- "hsl(0, 0%, 81.0%)",
70
- "hsl(0, 0%, 56.1%)",
71
- "hsl(0, 0%, 50.3%)",
72
- "hsl(0, 0%, 42.5%)",
73
- lightColor,
74
- darkTransparent
75
- ], darkColor = "#fff", darkPalette = [
76
- darkTransparent,
77
- "#050505",
78
- "#151515",
79
- "#191919",
80
- "#232323",
81
- "#282828",
82
- "#323232",
83
- "#424242",
84
- "#494949",
85
- "#545454",
86
- "#626262",
87
- "#a5a5a5",
88
- darkColor,
89
- lightTransparent
90
- ], lightPalettes = objectFromEntries(
91
- objectKeys(colorTokens.light).map(
92
- (key) => [`light_${key}`, getColorPalette(colorTokens.light[key], lightColor)]
93
- )
94
- ), darkPalettes = objectFromEntries(
95
- objectKeys(colorTokens.dark).map(
96
- (key) => [`dark_${key}`, getColorPalette(colorTokens.dark[key], darkColor)]
97
- )
98
- ), colorPalettes = {
99
- ...lightPalettes,
100
- ...darkPalettes
101
- };
102
- return {
103
- light: lightPalette,
104
- dark: darkPalette,
105
- ...colorPalettes
106
- };
107
- })(), templateColorsSpecific = {
108
- color1: 1,
109
- color2: 2,
110
- color3: 3,
111
- color4: 4,
112
- color5: 5,
113
- color6: 6,
114
- color7: 7,
115
- color8: 8,
116
- color9: 9,
117
- color10: 10,
118
- color11: 11,
119
- color12: 12
120
- }, templates = (() => {
121
- const template = {
122
- ...templateColorsSpecific,
123
- // the background, color, etc keys here work like generics - they make it so you
124
- // can publish components for others to use without mandating a specific color scale
125
- // the @tamagui/button Button component looks for `$background`, so you set the
126
- // dark_red_Button theme to have a stronger background than the dark_red theme.
127
- background: 2,
128
- backgroundHover: 3,
129
- backgroundPress: 4,
130
- backgroundFocus: 5,
131
- backgroundStrong: 1,
132
- backgroundTransparent: 0,
133
- color: -1,
134
- colorHover: -2,
135
- colorPress: -1,
136
- colorFocus: -2,
137
- colorTransparent: -0,
138
- borderColor: 5,
139
- borderColorHover: 6,
140
- borderColorFocus: 4,
141
- borderColorPress: 5,
142
- placeholderColor: -4,
143
- // in the future this should be partially transparent
144
- outlineColor: 5
145
- };
146
- return {
147
- base: template,
148
- colorLight: {
149
- ...template,
150
- // light color themes are a bit less sensitive
151
- borderColor: 4,
152
- borderColorHover: 5,
153
- borderColorFocus: 4,
154
- borderColorPress: 4
155
- }
156
- };
157
- })(), maskOptions = (() => {
158
- const shadows2 = {
159
- shadowColor: 0,
160
- shadowColorHover: 0,
161
- shadowColorPress: 0,
162
- shadowColorFocus: 0
163
- }, colors = {
164
- ...shadows2,
165
- color: 0,
166
- colorHover: 0,
167
- colorFocus: 0,
168
- colorPress: 0
169
- }, baseMaskOptions = {
170
- override: shadows2,
171
- skip: shadows2,
172
- // avoids the transparent ends
173
- max: palettes.light.length - 2,
174
- min: 1
175
- }, skipShadowsAndSpecificColors = {
176
- ...shadows2,
177
- ...templateColorsSpecific
178
- };
179
- return {
180
- component: {
181
- ...baseMaskOptions,
182
- override: colors,
183
- skip: skipShadowsAndSpecificColors
184
- },
185
- alt: {
186
- ...baseMaskOptions
187
- },
188
- button: {
189
- ...baseMaskOptions,
190
- override: {
191
- ...colors,
192
- borderColor: "transparent",
193
- borderColorHover: "transparent"
194
- },
195
- skip: skipShadowsAndSpecificColors
196
- }
197
- };
198
- })(), lightShadowColor = "rgba(0,0,0,0.04)", lightShadowColorStrong = "rgba(0,0,0,0.085)", darkShadowColor = "rgba(0,0,0,0.2)", darkShadowColorStrong = "rgba(0,0,0,0.3)", size = {
199
- $0: 0,
200
- "$0.25": 2,
201
- "$0.5": 4,
202
- "$0.75": 8,
203
- $1: 20,
204
- "$1.5": 24,
205
- $2: 28,
206
- "$2.5": 32,
207
- $3: 36,
208
- "$3.5": 40,
209
- $4: 44,
210
- $true: 44,
211
- "$4.5": 48,
212
- $5: 52,
213
- $6: 64,
214
- $7: 74,
215
- $8: 84,
216
- $9: 94,
217
- $10: 104,
218
- $11: 124,
219
- $12: 144,
220
- $13: 164,
221
- $14: 184,
222
- $15: 204,
223
- $16: 224,
224
- $17: 224,
225
- $18: 244,
226
- $19: 264,
227
- $20: 284
228
- }, spaces = Object.entries(size).map(([k, v]) => [k, sizeToSpace(v)]), spacesNegative = spaces.slice(1).map(([k, v]) => [`-${k.slice(1)}`, -v]), space = {
229
- ...Object.fromEntries(spaces),
230
- ...Object.fromEntries(spacesNegative)
231
- }, zIndex = {
232
- 0: 0,
233
- 1: 100,
234
- 2: 200,
235
- 3: 300,
236
- 4: 400,
237
- 5: 500
238
- }, darkColors = {
239
- ...colorTokens.dark.blue,
240
- ...colorTokens.dark.gray,
241
- ...colorTokens.dark.green,
242
- ...colorTokens.dark.orange,
243
- ...colorTokens.dark.pink,
244
- ...colorTokens.dark.purple,
245
- ...colorTokens.dark.red,
246
- ...colorTokens.dark.yellow
247
- }, lightColors = {
248
- ...colorTokens.light.blue,
249
- ...colorTokens.light.gray,
250
- ...colorTokens.light.green,
251
- ...colorTokens.light.orange,
252
- ...colorTokens.light.pink,
253
- ...colorTokens.light.purple,
254
- ...colorTokens.light.red,
255
- ...colorTokens.light.yellow
256
- }, color = {
257
- ...postfixObjKeys(lightColors, "Light"),
258
- ...postfixObjKeys(darkColors, "Dark")
259
- }, radius = {
260
- 0: 0,
261
- 1: 3,
262
- 2: 5,
263
- 3: 7,
264
- 4: 9,
265
- true: 9,
266
- 5: 10,
267
- 6: 16,
268
- 7: 19,
269
- 8: 22,
270
- 9: 26,
271
- 10: 34,
272
- 11: 42,
273
- 12: 50
274
- }, tokens = (0, import_web.createTokens)({
275
- color,
276
- radius,
277
- zIndex,
278
- space,
279
- size
280
- }), shadows = {
281
- light: {
282
- shadowColor: lightShadowColorStrong,
283
- shadowColorHover: lightShadowColorStrong,
284
- shadowColorPress: lightShadowColor,
285
- shadowColorFocus: lightShadowColor
286
- },
287
- dark: {
288
- shadowColor: darkShadowColorStrong,
289
- shadowColorHover: darkShadowColorStrong,
290
- shadowColorPress: darkShadowColor,
291
- shadowColorFocus: darkShadowColor
292
- }
293
- }, colorThemeDefinition = (colorName) => [
294
- {
295
- parent: "light",
296
- palette: colorName,
297
- template: "colorLight"
298
- },
299
- {
300
- parent: "dark",
301
- palette: colorName,
302
- template: "base"
303
- }
304
- ], nonInherited = {
305
- light: {
306
- ...lightColors,
307
- ...shadows.light
308
- },
309
- dark: {
310
- ...darkColors,
311
- ...shadows.dark
312
- }
313
- }, overlayThemeDefinitions = [
314
- {
315
- parent: "light",
316
- theme: {
317
- background: "rgba(0,0,0,0.5)"
318
- }
319
- },
320
- {
321
- parent: "dark",
322
- theme: {
323
- background: "rgba(0,0,0,0.9)"
324
- }
325
- }
326
- ], themeBuilder = (0, import_theme_builder.createThemeBuilder)().addPalettes(palettes).addTemplates(templates).addMasks(import_masks.masks).addThemes({
327
- light: {
328
- template: "base",
329
- palette: "light",
330
- nonInheritedValues: nonInherited.light
331
- },
332
- dark: {
333
- template: "base",
334
- palette: "dark",
335
- nonInheritedValues: nonInherited.dark
336
- }
337
- }).addChildThemes({
338
- orange: colorThemeDefinition("orange"),
339
- yellow: colorThemeDefinition("yellow"),
340
- green: colorThemeDefinition("green"),
341
- blue: colorThemeDefinition("blue"),
342
- purple: colorThemeDefinition("purple"),
343
- pink: colorThemeDefinition("pink"),
344
- red: colorThemeDefinition("red"),
345
- gray: colorThemeDefinition("gray")
346
- }).addChildThemes({
347
- alt1: {
348
- mask: "soften",
349
- ...maskOptions.alt
350
- },
351
- alt2: {
352
- mask: "soften2Border1",
353
- ...maskOptions.alt
354
- },
355
- active: {
356
- mask: "soften3FlatBorder",
357
- skip: {
358
- color: 1
359
- }
360
- }
361
- }).addComponentThemes(
362
- {
363
- ListItem: [
364
- {
365
- parent: "light",
366
- avoidNestingWithin: ["active"],
367
- mask: "identity",
368
- ...maskOptions.component
369
- },
370
- {
371
- parent: "dark",
372
- avoidNestingWithin: ["active"],
373
- mask: "identity",
374
- ...maskOptions.component
375
- }
376
- ],
377
- Card: {
378
- mask: "soften",
379
- avoidNestingWithin: ["active"],
380
- ...maskOptions.component
381
- },
382
- Button: {
383
- mask: "soften2Border1",
384
- ...maskOptions.component
385
- },
386
- Checkbox: {
387
- mask: "softenBorder2",
388
- ...maskOptions.component
389
- },
390
- Switch: {
391
- mask: "soften2Border1",
392
- ...maskOptions.component
393
- },
394
- SwitchThumb: {
395
- mask: "inverseStrengthen2",
396
- avoidNestingWithin: ["active"],
397
- ...maskOptions.component
398
- },
399
- TooltipContent: {
400
- mask: "soften2Border1",
401
- avoidNestingWithin: ["active"],
402
- ...maskOptions.component
403
- },
404
- DrawerFrame: {
405
- mask: "soften",
406
- avoidNestingWithin: ["active"],
407
- ...maskOptions.component
408
- },
409
- Progress: {
410
- mask: "soften",
411
- avoidNestingWithin: ["active"],
412
- ...maskOptions.component
413
- },
414
- RadioGroupItem: {
415
- mask: "softenBorder2",
416
- avoidNestingWithin: ["active"],
417
- ...maskOptions.component
418
- },
419
- TooltipArrow: {
420
- mask: "soften",
421
- avoidNestingWithin: ["active"],
422
- ...maskOptions.component
423
- },
424
- SliderTrackActive: {
425
- mask: "inverseSoften",
426
- ...maskOptions.component
427
- },
428
- SliderTrack: {
429
- mask: "soften2Border1",
430
- avoidNestingWithin: ["active"],
431
- ...maskOptions.component
432
- },
433
- SliderThumb: {
434
- mask: "inverse",
435
- avoidNestingWithin: ["active"],
436
- ...maskOptions.component
437
- },
438
- Tooltip: {
439
- mask: "inverse",
440
- avoidNestingWithin: ["active"],
441
- ...maskOptions.component
442
- },
443
- ProgressIndicator: {
444
- mask: "inverse",
445
- avoidNestingWithin: ["active"],
446
- ...maskOptions.component
447
- },
448
- SheetOverlay: overlayThemeDefinitions,
449
- DialogOverlay: overlayThemeDefinitions,
450
- ModalOverlay: overlayThemeDefinitions,
451
- Input: {
452
- mask: "softenBorder2",
453
- ...maskOptions.component
454
- },
455
- TextArea: {
456
- mask: "softenBorder2",
457
- ...maskOptions.component
458
- }
459
- },
460
- {
461
- // to save bundle size but make alt themes not work on components
462
- // avoidNestingWithin: ['alt1', 'alt2'],
463
- }
464
- ), themesIn = themeBuilder.build(), themes = themesIn;
465
- function postfixObjKeys(obj, postfix) {
466
- return Object.fromEntries(
467
- Object.entries(obj).map(([k, v]) => [`${k}${postfix}`, v])
468
- );
469
- }
470
- function sizeToSpace(v) {
471
- return v === 0 ? 0 : v === 2 ? 0.5 : v === 4 ? 1 : v === 8 ? 1.5 : v <= 16 ? Math.round(v * 0.333) : Math.floor(v * 0.7 - 12);
472
- }
473
- function objectFromEntries(arr) {
474
- return Object.fromEntries(arr);
475
- }
476
- function objectKeys(obj) {
477
- return Object.keys(obj);
478
- }
479
- //# sourceMappingURL=v2-themes.js.map