@tamagui/themes 1.116.1 → 1.116.3

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 (37) hide show
  1. package/dist/cjs/componentThemeDefinitions.js +123 -0
  2. package/dist/cjs/generated-new.js +1806 -0
  3. package/dist/cjs/generated-v2.js +1788 -0
  4. package/dist/cjs/generated-v3.js +3564 -0
  5. package/dist/cjs/helpers.js +29 -0
  6. package/dist/cjs/index.js +22 -0
  7. package/dist/cjs/masks.js +86 -0
  8. package/dist/cjs/palettes.js +82 -0
  9. package/dist/cjs/shadows.js +34 -0
  10. package/dist/cjs/templates.js +106 -0
  11. package/dist/cjs/themes-new.js +76 -0
  12. package/dist/cjs/themes-old.js +266 -0
  13. package/dist/cjs/themes.js +29 -0
  14. package/dist/cjs/tokens.js +143 -0
  15. package/dist/cjs/v2-themes.js +479 -0
  16. package/dist/cjs/v2.js +47 -0
  17. package/dist/cjs/v3-themes.js +594 -0
  18. package/dist/cjs/v3.js +47 -0
  19. package/package.json +7 -7
  20. /package/dist/cjs/{componentThemeDefinitions.cjs.map → componentThemeDefinitions.js.map} +0 -0
  21. /package/dist/cjs/{generated-new.cjs.map → generated-new.js.map} +0 -0
  22. /package/dist/cjs/{generated-v2.cjs.map → generated-v2.js.map} +0 -0
  23. /package/dist/cjs/{generated-v3.cjs.map → generated-v3.js.map} +0 -0
  24. /package/dist/cjs/{helpers.cjs.map → helpers.js.map} +0 -0
  25. /package/dist/cjs/{index.cjs.map → index.js.map} +0 -0
  26. /package/dist/cjs/{masks.cjs.map → masks.js.map} +0 -0
  27. /package/dist/cjs/{palettes.cjs.map → palettes.js.map} +0 -0
  28. /package/dist/cjs/{shadows.cjs.map → shadows.js.map} +0 -0
  29. /package/dist/cjs/{templates.cjs.map → templates.js.map} +0 -0
  30. /package/dist/cjs/{themes-new.cjs.map → themes-new.js.map} +0 -0
  31. /package/dist/cjs/{themes-old.cjs.map → themes-old.js.map} +0 -0
  32. /package/dist/cjs/{themes.cjs.map → themes.js.map} +0 -0
  33. /package/dist/cjs/{tokens.cjs.map → tokens.js.map} +0 -0
  34. /package/dist/cjs/{v2-themes.cjs.map → v2-themes.js.map} +0 -0
  35. /package/dist/cjs/{v2.cjs.map → v2.js.map} +0 -0
  36. /package/dist/cjs/{v3-themes.cjs.map → v3-themes.js.map} +0 -0
  37. /package/dist/cjs/{v3.cjs.map → v3.js.map} +0 -0
@@ -0,0 +1,594 @@
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 v3_themes_exports = {};
16
+ __export(v3_themes_exports, {
17
+ defaultComponentThemes: () => defaultComponentThemes,
18
+ defaultPalettes: () => defaultPalettes,
19
+ defaultSubThemes: () => defaultSubThemes,
20
+ defaultTemplates: () => defaultTemplates,
21
+ objectFromEntries: () => objectFromEntries,
22
+ objectKeys: () => objectKeys,
23
+ postfixObjKeys: () => postfixObjKeys,
24
+ radius: () => radius,
25
+ size: () => size,
26
+ sizeToSpace: () => sizeToSpace,
27
+ space: () => space,
28
+ spaces: () => spaces,
29
+ spacesNegative: () => spacesNegative,
30
+ themes: () => themes,
31
+ tokens: () => tokens,
32
+ zIndex: () => zIndex
33
+ });
34
+ module.exports = __toCommonJS(v3_themes_exports);
35
+ var import_colors = require("@tamagui/colors"), import_theme_builder = require("@tamagui/theme-builder"), import_web = require("@tamagui/web");
36
+ const colorTokens = {
37
+ light: {
38
+ blue: import_colors.blue,
39
+ gray: import_colors.gray,
40
+ green: import_colors.green,
41
+ orange: import_colors.orange,
42
+ pink: import_colors.pink,
43
+ purple: import_colors.purple,
44
+ red: import_colors.red,
45
+ yellow: import_colors.yellow
46
+ },
47
+ dark: {
48
+ blue: import_colors.blueDark,
49
+ gray: import_colors.grayDark,
50
+ green: import_colors.greenDark,
51
+ orange: import_colors.orangeDark,
52
+ pink: import_colors.pinkDark,
53
+ purple: import_colors.purpleDark,
54
+ red: import_colors.redDark,
55
+ yellow: import_colors.yellowDark
56
+ }
57
+ }, 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)", darkColors = {
58
+ ...colorTokens.dark.blue,
59
+ ...colorTokens.dark.gray,
60
+ ...colorTokens.dark.green,
61
+ ...colorTokens.dark.orange,
62
+ ...colorTokens.dark.pink,
63
+ ...colorTokens.dark.purple,
64
+ ...colorTokens.dark.red,
65
+ ...colorTokens.dark.yellow
66
+ }, lightColors = {
67
+ ...colorTokens.light.blue,
68
+ ...colorTokens.light.gray,
69
+ ...colorTokens.light.green,
70
+ ...colorTokens.light.orange,
71
+ ...colorTokens.light.pink,
72
+ ...colorTokens.light.purple,
73
+ ...colorTokens.light.red,
74
+ ...colorTokens.light.yellow
75
+ }, color = {
76
+ white0: "rgba(255,255,255,0)",
77
+ white075: "rgba(255,255,255,0.75)",
78
+ white05: "rgba(255,255,255,0.5)",
79
+ white025: "rgba(255,255,255,0.25)",
80
+ black0: "rgba(10,10,10,0)",
81
+ black075: "rgba(10,10,10,0.75)",
82
+ black05: "rgba(10,10,10,0.5)",
83
+ black025: "rgba(10,10,10,0.25)",
84
+ white1: "#fff",
85
+ white2: "#f8f8f8",
86
+ white3: "hsl(0, 0%, 96.3%)",
87
+ white4: "hsl(0, 0%, 94.1%)",
88
+ white5: "hsl(0, 0%, 92.0%)",
89
+ white6: "hsl(0, 0%, 90.0%)",
90
+ white7: "hsl(0, 0%, 88.5%)",
91
+ white8: "hsl(0, 0%, 81.0%)",
92
+ white9: "hsl(0, 0%, 56.1%)",
93
+ white10: "hsl(0, 0%, 50.3%)",
94
+ white11: "hsl(0, 0%, 42.5%)",
95
+ white12: "hsl(0, 0%, 9.0%)",
96
+ black1: "#050505",
97
+ black2: "#151515",
98
+ black3: "#191919",
99
+ black4: "#232323",
100
+ black5: "#282828",
101
+ black6: "#323232",
102
+ black7: "#424242",
103
+ black8: "#494949",
104
+ black9: "#545454",
105
+ black10: "#626262",
106
+ black11: "#a5a5a5",
107
+ black12: "#fff",
108
+ ...postfixObjKeys(lightColors, "Light"),
109
+ ...postfixObjKeys(darkColors, "Dark")
110
+ }, defaultPalettes = (() => {
111
+ const transparent = (hsl, opacity = 0) => hsl.replace("%)", `%, ${opacity})`).replace("hsl(", "hsla("), getColorPalette = (colors, accentColors) => {
112
+ const colorPalette = Object.values(colors), colorI = colorPalette.length - 4, accentPalette = Object.values(accentColors), accentBackground = accentPalette[0], accentColor = accentPalette[accentPalette.length - 1];
113
+ return [
114
+ accentBackground,
115
+ transparent(colorPalette[0], 0),
116
+ transparent(colorPalette[0], 0.25),
117
+ transparent(colorPalette[0], 0.5),
118
+ transparent(colorPalette[0], 0.75),
119
+ ...colorPalette,
120
+ transparent(colorPalette[colorI], 0.75),
121
+ transparent(colorPalette[colorI], 0.5),
122
+ transparent(colorPalette[colorI], 0.25),
123
+ transparent(colorPalette[colorI], 0),
124
+ accentColor
125
+ ];
126
+ }, brandColor = {
127
+ light: color.blue4Light,
128
+ dark: color.blue4Dark
129
+ }, lightPalette = [
130
+ brandColor.light,
131
+ color.white0,
132
+ color.white025,
133
+ color.white05,
134
+ color.white075,
135
+ color.white1,
136
+ color.white2,
137
+ color.white3,
138
+ color.white4,
139
+ color.white5,
140
+ color.white6,
141
+ color.white7,
142
+ color.white8,
143
+ color.white9,
144
+ color.white10,
145
+ color.white11,
146
+ color.white12,
147
+ color.black075,
148
+ color.black05,
149
+ color.black025,
150
+ color.black0,
151
+ brandColor.dark
152
+ ], darkPalette = [
153
+ brandColor.dark,
154
+ color.black0,
155
+ color.black025,
156
+ color.black05,
157
+ color.black075,
158
+ color.black1,
159
+ color.black2,
160
+ color.black3,
161
+ color.black4,
162
+ color.black5,
163
+ color.black6,
164
+ color.black7,
165
+ color.black8,
166
+ color.black9,
167
+ color.black10,
168
+ color.black11,
169
+ color.black12,
170
+ color.white075,
171
+ color.white05,
172
+ color.white025,
173
+ color.white0,
174
+ brandColor.light
175
+ ], lightColorNames = objectKeys(colorTokens.light), lightPalettes = objectFromEntries(
176
+ lightColorNames.map(
177
+ (key, index) => [
178
+ `light_${key}`,
179
+ getColorPalette(
180
+ colorTokens.light[key],
181
+ colorTokens.light[lightColorNames[(index + 1) % lightColorNames.length]]
182
+ )
183
+ ]
184
+ )
185
+ ), darkColorNames = objectKeys(colorTokens.dark), darkPalettes = objectFromEntries(
186
+ darkColorNames.map(
187
+ (key, index) => [
188
+ `dark_${key}`,
189
+ getColorPalette(
190
+ colorTokens.dark[key],
191
+ colorTokens.light[darkColorNames[(index + 1) % darkColorNames.length]]
192
+ )
193
+ ]
194
+ )
195
+ ), colorPalettes = {
196
+ ...lightPalettes,
197
+ ...darkPalettes
198
+ };
199
+ return {
200
+ light: lightPalette,
201
+ dark: darkPalette,
202
+ ...colorPalettes
203
+ };
204
+ })(), getTemplates = () => {
205
+ const getBaseTemplates = (scheme) => {
206
+ const isLight = scheme === "light", bgIndex = 5, lighten = isLight ? -1 : 1, darken = -lighten, borderColor = bgIndex + 3, base = {
207
+ accentBackground: 0,
208
+ accentColor: -0,
209
+ background0: 1,
210
+ background025: 2,
211
+ background05: 3,
212
+ background075: 4,
213
+ color1: bgIndex,
214
+ color2: bgIndex + 1,
215
+ color3: bgIndex + 2,
216
+ color4: bgIndex + 3,
217
+ color5: bgIndex + 4,
218
+ color6: bgIndex + 5,
219
+ color7: bgIndex + 6,
220
+ color8: bgIndex + 7,
221
+ color9: bgIndex + 8,
222
+ color10: bgIndex + 9,
223
+ color11: bgIndex + 10,
224
+ color12: bgIndex + 11,
225
+ color0: -1,
226
+ color025: -2,
227
+ color05: -3,
228
+ color075: -4,
229
+ // the background, color, etc keys here work like generics - they make it so you
230
+ // can publish components for others to use without mandating a specific color scale
231
+ // the @tamagui/button Button component looks for `$background`, so you set the
232
+ // dark_red_Button theme to have a stronger background than the dark_red theme.
233
+ background: bgIndex,
234
+ backgroundHover: bgIndex + lighten,
235
+ // always lighten on hover no matter the scheme
236
+ backgroundPress: bgIndex + darken,
237
+ // always darken on press no matter the theme
238
+ backgroundFocus: bgIndex + darken,
239
+ borderColor,
240
+ borderColorHover: borderColor + lighten,
241
+ borderColorPress: borderColor + darken,
242
+ borderColorFocus: borderColor,
243
+ color: -bgIndex,
244
+ colorHover: -bgIndex - 1,
245
+ colorPress: -bgIndex,
246
+ colorFocus: -bgIndex - 1,
247
+ colorTransparent: -1,
248
+ placeholderColor: -bgIndex - 3,
249
+ outlineColor: -2
250
+ }, surface12 = {
251
+ background: base.background + 1,
252
+ backgroundHover: base.backgroundHover + 1,
253
+ backgroundPress: base.backgroundPress + 1,
254
+ backgroundFocus: base.backgroundFocus + 1,
255
+ borderColor: base.borderColor + 1,
256
+ borderColorHover: base.borderColorHover + 1,
257
+ borderColorFocus: base.borderColorFocus + 1,
258
+ borderColorPress: base.borderColorPress + 1
259
+ }, surface22 = {
260
+ background: base.background + 2,
261
+ backgroundHover: base.backgroundHover + 2,
262
+ backgroundPress: base.backgroundPress + 2,
263
+ backgroundFocus: base.backgroundFocus + 2,
264
+ borderColor: base.borderColor + 2,
265
+ borderColorHover: base.borderColorHover + 2,
266
+ borderColorFocus: base.borderColorFocus + 2,
267
+ borderColorPress: base.borderColorPress + 2
268
+ }, surface32 = {
269
+ background: base.background + 3,
270
+ backgroundHover: base.backgroundHover + 3,
271
+ backgroundPress: base.backgroundPress + 3,
272
+ backgroundFocus: base.backgroundFocus + 3,
273
+ borderColor: base.borderColor + 3,
274
+ borderColorHover: base.borderColorHover + 3,
275
+ borderColorFocus: base.borderColorFocus + 3,
276
+ borderColorPress: base.borderColorPress + 3
277
+ }, surfaceActiveBg = {
278
+ background: base.background + 5,
279
+ backgroundHover: base.background + 5,
280
+ backgroundPress: base.backgroundPress + 5,
281
+ backgroundFocus: base.backgroundFocus + 5
282
+ }, surfaceActive = {
283
+ ...surfaceActiveBg,
284
+ // match border to background when active
285
+ borderColor: surfaceActiveBg.background,
286
+ borderColorHover: surfaceActiveBg.backgroundHover,
287
+ borderColorFocus: surfaceActiveBg.backgroundFocus,
288
+ borderColorPress: surfaceActiveBg.backgroundPress
289
+ }, inverseSurface12 = {
290
+ color: surface12.background,
291
+ colorHover: surface12.backgroundHover,
292
+ colorPress: surface12.backgroundPress,
293
+ colorFocus: surface12.backgroundFocus,
294
+ background: base.color,
295
+ backgroundHover: base.colorHover,
296
+ backgroundPress: base.colorPress,
297
+ backgroundFocus: base.colorFocus,
298
+ borderColor: base.color - 2,
299
+ borderColorHover: base.color - 3,
300
+ borderColorFocus: base.color - 4,
301
+ borderColorPress: base.color - 5
302
+ }, inverseActive = {
303
+ ...inverseSurface12,
304
+ background: base.color - 2,
305
+ backgroundHover: base.colorHover - 2,
306
+ backgroundPress: base.colorPress - 2,
307
+ backgroundFocus: base.colorFocus - 2,
308
+ borderColor: base.color - 2 - 2,
309
+ borderColorHover: base.color - 3 - 2,
310
+ borderColorFocus: base.color - 4 - 2,
311
+ borderColorPress: base.color - 5 - 2
312
+ }, alt1 = {
313
+ color: base.color - 1,
314
+ colorHover: base.colorHover - 1,
315
+ colorPress: base.colorPress - 1,
316
+ colorFocus: base.colorFocus - 1
317
+ }, alt2 = {
318
+ color: base.color - 2,
319
+ colorHover: base.colorHover - 2,
320
+ colorPress: base.colorPress - 2,
321
+ colorFocus: base.colorFocus - 2
322
+ };
323
+ return {
324
+ base,
325
+ alt1,
326
+ alt2,
327
+ surface1: surface12,
328
+ surface2: surface22,
329
+ surface3: surface32,
330
+ inverseSurface1: inverseSurface12,
331
+ inverseActive,
332
+ surfaceActive
333
+ };
334
+ }, lightTemplates = getBaseTemplates("light"), darkTemplates = getBaseTemplates("dark");
335
+ return {
336
+ ...objectFromEntries(
337
+ objectKeys(lightTemplates).map(
338
+ (name) => [`light_${name}`, lightTemplates[name]]
339
+ )
340
+ ),
341
+ ...objectFromEntries(
342
+ objectKeys(darkTemplates).map(
343
+ (name) => [`dark_${name}`, darkTemplates[name]]
344
+ )
345
+ )
346
+ };
347
+ }, defaultTemplates = getTemplates(), shadows = {
348
+ light: {
349
+ shadowColor: lightShadowColorStrong,
350
+ shadowColorHover: lightShadowColorStrong,
351
+ shadowColorPress: lightShadowColor,
352
+ shadowColorFocus: lightShadowColor
353
+ },
354
+ dark: {
355
+ shadowColor: darkShadowColorStrong,
356
+ shadowColorHover: darkShadowColorStrong,
357
+ shadowColorPress: darkShadowColor,
358
+ shadowColorFocus: darkShadowColor
359
+ }
360
+ }, nonInherited = {
361
+ light: {
362
+ ...lightColors,
363
+ ...shadows.light
364
+ },
365
+ dark: {
366
+ ...darkColors,
367
+ ...shadows.dark
368
+ }
369
+ }, overlayThemeDefinitions = [
370
+ {
371
+ parent: "light",
372
+ theme: {
373
+ background: "rgba(0,0,0,0.5)"
374
+ }
375
+ },
376
+ {
377
+ parent: "dark",
378
+ theme: {
379
+ background: "rgba(0,0,0,0.8)"
380
+ }
381
+ }
382
+ ], inverseSurface1 = [
383
+ {
384
+ parent: "active",
385
+ template: "inverseActive"
386
+ },
387
+ {
388
+ parent: "",
389
+ template: "inverseSurface1"
390
+ }
391
+ ], surface1 = [
392
+ {
393
+ parent: "active",
394
+ template: "surfaceActive"
395
+ },
396
+ {
397
+ parent: "",
398
+ template: "surface1"
399
+ }
400
+ ], surface2 = [
401
+ {
402
+ parent: "active",
403
+ template: "surfaceActive"
404
+ },
405
+ {
406
+ parent: "",
407
+ template: "surface2"
408
+ }
409
+ ], surface3 = [
410
+ {
411
+ parent: "active",
412
+ template: "surfaceActive"
413
+ },
414
+ {
415
+ parent: "",
416
+ template: "surface3"
417
+ }
418
+ ], defaultComponentThemes = {
419
+ ListItem: {
420
+ template: "surface1"
421
+ },
422
+ SelectTrigger: surface1,
423
+ Card: surface1,
424
+ Button: surface3,
425
+ Checkbox: surface2,
426
+ Switch: surface2,
427
+ SwitchThumb: inverseSurface1,
428
+ TooltipContent: surface2,
429
+ Progress: {
430
+ template: "surface1"
431
+ },
432
+ RadioGroupItem: surface2,
433
+ TooltipArrow: {
434
+ template: "surface1"
435
+ },
436
+ SliderTrackActive: {
437
+ template: "surface3"
438
+ },
439
+ SliderTrack: {
440
+ template: "surface1"
441
+ },
442
+ SliderThumb: inverseSurface1,
443
+ Tooltip: inverseSurface1,
444
+ ProgressIndicator: inverseSurface1,
445
+ SheetOverlay: overlayThemeDefinitions,
446
+ DialogOverlay: overlayThemeDefinitions,
447
+ ModalOverlay: overlayThemeDefinitions,
448
+ Input: surface1,
449
+ TextArea: surface1
450
+ }, defaultSubThemes = {
451
+ alt1: {
452
+ template: "alt1"
453
+ },
454
+ alt2: {
455
+ template: "alt2"
456
+ },
457
+ active: {
458
+ template: "surface3"
459
+ },
460
+ surface1: {
461
+ template: "surface1"
462
+ },
463
+ surface2: {
464
+ template: "surface2"
465
+ },
466
+ surface3: {
467
+ template: "surface3"
468
+ },
469
+ surface4: {
470
+ template: "surfaceActive"
471
+ }
472
+ }, themeBuilder = (0, import_theme_builder.createThemeBuilder)().addPalettes(defaultPalettes).addTemplates(defaultTemplates).addThemes({
473
+ light: {
474
+ template: "base",
475
+ palette: "light",
476
+ nonInheritedValues: nonInherited.light
477
+ },
478
+ dark: {
479
+ template: "base",
480
+ palette: "dark",
481
+ nonInheritedValues: nonInherited.dark
482
+ }
483
+ }).addChildThemes({
484
+ orange: {
485
+ palette: "orange",
486
+ template: "base"
487
+ },
488
+ yellow: {
489
+ palette: "yellow",
490
+ template: "base"
491
+ },
492
+ green: {
493
+ palette: "green",
494
+ template: "base"
495
+ },
496
+ blue: {
497
+ palette: "blue",
498
+ template: "base"
499
+ },
500
+ purple: {
501
+ palette: "purple",
502
+ template: "base"
503
+ },
504
+ pink: {
505
+ palette: "pink",
506
+ template: "base"
507
+ },
508
+ red: {
509
+ palette: "red",
510
+ template: "base"
511
+ },
512
+ gray: {
513
+ palette: "gray",
514
+ template: "base"
515
+ }
516
+ }).addChildThemes(defaultSubThemes).addComponentThemes(defaultComponentThemes, {
517
+ avoidNestingWithin: ["alt1", "alt2", "surface1", "surface2", "surface3", "surface4"]
518
+ }), themesIn = themeBuilder.build(), themes = themesIn, size = {
519
+ $0: 0,
520
+ "$0.25": 2,
521
+ "$0.5": 4,
522
+ "$0.75": 8,
523
+ $1: 20,
524
+ "$1.5": 24,
525
+ $2: 28,
526
+ "$2.5": 32,
527
+ $3: 36,
528
+ "$3.5": 40,
529
+ $4: 44,
530
+ $true: 44,
531
+ "$4.5": 48,
532
+ $5: 52,
533
+ $6: 64,
534
+ $7: 74,
535
+ $8: 84,
536
+ $9: 94,
537
+ $10: 104,
538
+ $11: 124,
539
+ $12: 144,
540
+ $13: 164,
541
+ $14: 184,
542
+ $15: 204,
543
+ $16: 224,
544
+ $17: 224,
545
+ $18: 244,
546
+ $19: 264,
547
+ $20: 284
548
+ }, spaces = Object.entries(size).map(([k, v]) => [k, sizeToSpace(v)]), spacesNegative = spaces.slice(1).map(([k, v]) => [`-${k.slice(1)}`, -v]), space = {
549
+ ...Object.fromEntries(spaces),
550
+ ...Object.fromEntries(spacesNegative)
551
+ }, zIndex = {
552
+ 0: 0,
553
+ 1: 100,
554
+ 2: 200,
555
+ 3: 300,
556
+ 4: 400,
557
+ 5: 500
558
+ }, radius = {
559
+ 0: 0,
560
+ 1: 3,
561
+ 2: 5,
562
+ 3: 7,
563
+ 4: 9,
564
+ true: 9,
565
+ 5: 10,
566
+ 6: 16,
567
+ 7: 19,
568
+ 8: 22,
569
+ 9: 26,
570
+ 10: 34,
571
+ 11: 42,
572
+ 12: 50
573
+ }, tokens = (0, import_web.createTokens)({
574
+ color,
575
+ radius,
576
+ zIndex,
577
+ space,
578
+ size
579
+ });
580
+ function postfixObjKeys(obj, postfix) {
581
+ return Object.fromEntries(
582
+ Object.entries(obj).map(([k, v]) => [`${k}${postfix}`, v])
583
+ );
584
+ }
585
+ function sizeToSpace(v) {
586
+ 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);
587
+ }
588
+ function objectFromEntries(arr) {
589
+ return Object.fromEntries(arr);
590
+ }
591
+ function objectKeys(obj) {
592
+ return Object.keys(obj);
593
+ }
594
+ //# sourceMappingURL=v3-themes.js.map
package/dist/cjs/v3.js ADDED
@@ -0,0 +1,47 @@
1
+ var __create = Object.create;
2
+ var __defProp = Object.defineProperty;
3
+ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
4
+ var __getOwnPropNames = Object.getOwnPropertyNames;
5
+ var __getProtoOf = Object.getPrototypeOf, __hasOwnProp = Object.prototype.hasOwnProperty;
6
+ var __export = (target, all) => {
7
+ for (var name in all)
8
+ __defProp(target, name, { get: all[name], enumerable: !0 });
9
+ }, __copyProps = (to, from, except, desc) => {
10
+ if (from && typeof from == "object" || typeof from == "function")
11
+ for (let key of __getOwnPropNames(from))
12
+ !__hasOwnProp.call(to, key) && key !== except && __defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
13
+ return to;
14
+ };
15
+ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
16
+ // If the importer is in node compatibility mode or this is not an ESM
17
+ // file that has been converted to a CommonJS file using a Babel-
18
+ // compatible transform (i.e. "__esModule" has not been set), then set
19
+ // "default" to the CommonJS "module.exports" for node compatibility.
20
+ isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: !0 }) : target,
21
+ mod
22
+ )), __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: !0 }), mod);
23
+ var v3_exports = {};
24
+ __export(v3_exports, {
25
+ blue: () => import_colors.blue,
26
+ blueDark: () => import_colors.blueDark,
27
+ gray: () => import_colors8.gray,
28
+ grayDark: () => import_colors8.grayDark,
29
+ green: () => import_colors2.green,
30
+ greenDark: () => import_colors2.greenDark,
31
+ orange: () => import_colors4.orange,
32
+ orangeDark: () => import_colors4.orangeDark,
33
+ pink: () => import_colors6.pink,
34
+ pinkDark: () => import_colors6.pinkDark,
35
+ purple: () => import_colors7.purple,
36
+ purpleDark: () => import_colors7.purpleDark,
37
+ red: () => import_colors3.red,
38
+ redDark: () => import_colors3.redDark,
39
+ themes: () => themes,
40
+ tokens: () => import_v3_themes.tokens,
41
+ yellow: () => import_colors5.yellow,
42
+ yellowDark: () => import_colors5.yellowDark
43
+ });
44
+ module.exports = __toCommonJS(v3_exports);
45
+ var generatedThemes = __toESM(require("./generated-v3")), import_v3_themes = require("./v3-themes"), import_colors = require("@tamagui/colors"), import_colors2 = require("@tamagui/colors"), import_colors3 = require("@tamagui/colors"), import_colors4 = require("@tamagui/colors"), import_colors5 = require("@tamagui/colors"), import_colors6 = require("@tamagui/colors"), import_colors7 = require("@tamagui/colors"), import_colors8 = require("@tamagui/colors");
46
+ const themes = generatedThemes;
47
+ //# sourceMappingURL=v3.js.map
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tamagui/themes",
3
- "version": "1.116.1",
3
+ "version": "1.116.3",
4
4
  "types": "./types/index.d.ts",
5
5
  "main": "dist/cjs",
6
6
  "module": "dist/esm",
@@ -58,14 +58,14 @@
58
58
  }
59
59
  },
60
60
  "dependencies": {
61
- "@tamagui/colors": "1.116.1",
62
- "@tamagui/create-theme": "1.116.1",
63
- "@tamagui/theme-builder": "1.116.1",
64
- "@tamagui/web": "1.116.1"
61
+ "@tamagui/colors": "1.116.3",
62
+ "@tamagui/create-theme": "1.116.3",
63
+ "@tamagui/theme-builder": "1.116.3",
64
+ "@tamagui/web": "1.116.3"
65
65
  },
66
66
  "devDependencies": {
67
- "@tamagui/build": "1.116.1",
68
- "@tamagui/cli": "1.116.1",
67
+ "@tamagui/build": "1.116.3",
68
+ "@tamagui/cli": "1.116.3",
69
69
  "vitest": "^2.1.3"
70
70
  },
71
71
  "publishConfig": {
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes
File without changes