@tenerife.music/ui 1.0.16 → 1.1.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.
@@ -121,1071 +121,7 @@ var init_default = __esm({
121
121
  }
122
122
  });
123
123
 
124
- // src/themes/minimal.ts
125
- var minimalBrand = {
126
- id: "minimal",
127
- name: "Minimal",
128
- description: "Clean, minimal brand theme with muted colors, light typography, and compact spacing",
129
- namespace: "minimal",
130
- version: "1.0.0",
131
- author: "Tenerife UI",
132
- themes: [
133
- {
134
- id: "minimal-day",
135
- name: "Minimal Day",
136
- description: "Light minimal theme with grayscale colors and subtle accents",
137
- mode: "day",
138
- overrides: {
139
- name: "minimal-day",
140
- description: "Light minimal theme for day mode",
141
- // Muted, low-saturation color overrides
142
- primaryColors: {
143
- 400: "0 0% 60%",
144
- // Muted gray
145
- 500: "0 0% 50%",
146
- // Neutral gray (#808080)
147
- 600: "0 0% 40%",
148
- 700: "0 0% 30%"
149
- },
150
- accentColors: {
151
- 400: "210 20% 70%",
152
- // Muted blue-gray
153
- 500: "210 20% 60%",
154
- // Subtle blue-gray
155
- 600: "210 20% 50%",
156
- 700: "210 20% 40%"
157
- },
158
- secondaryColors: {
159
- 400: "0 0% 70%",
160
- // Light gray
161
- 500: "0 0% 65%",
162
- // Neutral light gray
163
- 600: "0 0% 55%",
164
- 700: "0 0% 45%"
165
- },
166
- // Muted base colors for day mode
167
- baseColorsDay: {
168
- primary: "0 0% 50%",
169
- // Neutral gray
170
- primaryForeground: "0 0% 100%",
171
- secondary: "0 0% 96%",
172
- // Very light gray
173
- secondaryForeground: "0 0% 20%",
174
- accent: "210 20% 60%",
175
- // Subtle blue-gray
176
- accentForeground: "0 0% 100%"
177
- },
178
- // Subtle semantic colors
179
- semanticColorsDay: {
180
- success: "140 30% 45%",
181
- // Muted green
182
- info: "210 30% 50%",
183
- // Muted blue
184
- warning: "40 30% 50%",
185
- // Muted orange
186
- error: "0 40% 55%"
187
- // Muted red
188
- },
189
- // Typography overrides - lighter and smaller
190
- typography: {
191
- fontWeight: {
192
- normal: "400",
193
- // Normal weight
194
- medium: "500",
195
- semibold: "600",
196
- // Lighter than default
197
- bold: "700"
198
- // Standard bold
199
- },
200
- fontSize: {
201
- xs: [
202
- "clamp(0.6875rem, 0.65rem + 0.125vw, 0.75rem)",
203
- { lineHeight: "1rem", letterSpacing: "0.05em" }
204
- ],
205
- // Smaller
206
- sm: [
207
- "clamp(0.8125rem, 0.75rem + 0.25vw, 0.875rem)",
208
- { lineHeight: "1.25rem", letterSpacing: "0.025em" }
209
- ],
210
- // Smaller
211
- base: [
212
- "clamp(0.9375rem, 0.875rem + 0.25vw, 1rem)",
213
- { lineHeight: "1.5rem", letterSpacing: "0em" }
214
- ],
215
- // Smaller
216
- lg: [
217
- "clamp(1.0625rem, 0.95rem + 0.5vw, 1.125rem)",
218
- { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
219
- ],
220
- // Smaller
221
- xl: [
222
- "clamp(1.1875rem, 1rem + 0.75vw, 1.375rem)",
223
- { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
224
- ]
225
- // Smaller
226
- }
227
- },
228
- // Spacing overrides - compact spacing for tight layout
229
- spacing: {
230
- semanticSpacing: {
231
- xs: "0.125rem",
232
- // 2px (was 4px)
233
- sm: "0.25rem",
234
- // 4px (was 8px)
235
- md: "0.5rem",
236
- // 8px (was 16px)
237
- lg: "0.75rem",
238
- // 12px (was 24px)
239
- xl: "1rem",
240
- // 16px (was 32px)
241
- "2xl": "1.5rem"
242
- // 24px (was 48px)
243
- }
244
- },
245
- // Shadow overrides - subtle and minimal
246
- shadows: {
247
- elevationShadows: {
248
- xs: "0 1px 1px 0 rgb(0 0 0 / 0.03)",
249
- sm: "0 1px 2px 0 rgb(0 0 0 / 0.05), 0 1px 1px -1px rgb(0 0 0 / 0.05)",
250
- md: "0 2px 4px -1px rgb(0 0 0 / 0.05), 0 1px 2px -2px rgb(0 0 0 / 0.05)",
251
- lg: "0 4px 8px -2px rgb(0 0 0 / 0.05), 0 2px 4px -3px rgb(0 0 0 / 0.05)",
252
- xl: "0 8px 12px -3px rgb(0 0 0 / 0.05), 0 4px 6px -4px rgb(0 0 0 / 0.05)"
253
- },
254
- glowEffects: {
255
- "glow-primary": "0 0 8px 0 hsl(0 0% 50% / 0.2)",
256
- "glow-primary-subtle": "0 0 4px 0 hsl(0 0% 50% / 0.15)",
257
- "glow-primary-medium": "0 0 8px 0 hsl(0 0% 50% / 0.25)",
258
- "glow-primary-strong": "0 0 12px 0 hsl(0 0% 50% / 0.3)"
259
- }
260
- },
261
- // Radius overrides - smaller, sharper corners
262
- radius: {
263
- borderRadius: {
264
- xs: "0.0625rem",
265
- // 1px
266
- sm: "0.125rem",
267
- // 2px (was 4px)
268
- md: "0.1875rem",
269
- // 3px (was 6px)
270
- lg: "0.25rem",
271
- // 4px (was 8px)
272
- xl: "0.375rem",
273
- // 6px (was 12px)
274
- "2xl": "0.5rem"
275
- // 8px (was 16px)
276
- },
277
- componentRadius: {
278
- button: {
279
- sm: "0.125rem",
280
- // 2px
281
- md: "0.1875rem",
282
- // 3px
283
- lg: "0.25rem"
284
- // 4px
285
- },
286
- card: {
287
- sm: "0.1875rem",
288
- // 3px
289
- md: "0.25rem",
290
- // 4px
291
- lg: "0.375rem",
292
- // 6px
293
- xl: "0.5rem"
294
- // 8px
295
- },
296
- input: {
297
- sm: "0.125rem",
298
- // 2px
299
- md: "0.1875rem",
300
- // 3px
301
- lg: "0.25rem"
302
- // 4px
303
- },
304
- badge: {
305
- sm: "0.0625rem",
306
- // 1px
307
- md: "0.125rem",
308
- // 2px
309
- lg: "0.1875rem"
310
- // 3px
311
- }
312
- }
313
- }
314
- }
315
- },
316
- {
317
- id: "minimal-night",
318
- name: "Minimal Night",
319
- description: "Dark minimal theme with muted grayscale colors",
320
- mode: "night",
321
- overrides: {
322
- name: "minimal-night",
323
- description: "Dark minimal theme for night mode",
324
- // Muted colors for night mode (slightly lighter than day for contrast)
325
- primaryColors: {
326
- 400: "0 0% 65%",
327
- // Lighter gray for night
328
- 500: "0 0% 55%",
329
- // Neutral gray
330
- 600: "0 0% 45%",
331
- 700: "0 0% 35%"
332
- },
333
- accentColors: {
334
- 400: "210 20% 75%",
335
- // Lighter blue-gray
336
- 500: "210 20% 65%",
337
- // Subtle blue-gray
338
- 600: "210 20% 55%",
339
- 700: "210 20% 45%"
340
- },
341
- secondaryColors: {
342
- 400: "0 0% 75%",
343
- // Light gray
344
- 500: "0 0% 70%",
345
- // Neutral light gray
346
- 600: "0 0% 60%",
347
- 700: "0 0% 50%"
348
- },
349
- // Darker base colors for night mode
350
- baseColorsNight: {
351
- background: "240 10% 8%",
352
- // Dark gray background
353
- foreground: "0 0% 95%",
354
- card: "240 10% 10%",
355
- cardForeground: "0 0% 95%"
356
- },
357
- surfaceColorsNight: {
358
- base: "240 10% 8%",
359
- elevated1: "240 10% 10%",
360
- elevated2: "240 10% 12%",
361
- elevated3: "240 10% 14%"
362
- },
363
- // Subtle semantic colors for night
364
- semanticColorsNight: {
365
- success: "140 30% 50%",
366
- // Muted green
367
- info: "210 30% 55%",
368
- // Muted blue
369
- warning: "40 30% 55%",
370
- // Muted orange
371
- error: "0 40% 60%"
372
- // Muted red
373
- },
374
- // Typography overrides - same as day
375
- typography: {
376
- fontWeight: {
377
- normal: "400",
378
- medium: "500",
379
- semibold: "600",
380
- bold: "700"
381
- },
382
- fontSize: {
383
- xs: [
384
- "clamp(0.6875rem, 0.65rem + 0.125vw, 0.75rem)",
385
- { lineHeight: "1rem", letterSpacing: "0.05em" }
386
- ],
387
- sm: [
388
- "clamp(0.8125rem, 0.75rem + 0.25vw, 0.875rem)",
389
- { lineHeight: "1.25rem", letterSpacing: "0.025em" }
390
- ],
391
- base: [
392
- "clamp(0.9375rem, 0.875rem + 0.25vw, 1rem)",
393
- { lineHeight: "1.5rem", letterSpacing: "0em" }
394
- ],
395
- lg: [
396
- "clamp(1.0625rem, 0.95rem + 0.5vw, 1.125rem)",
397
- { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
398
- ],
399
- xl: [
400
- "clamp(1.1875rem, 1rem + 0.75vw, 1.375rem)",
401
- { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
402
- ]
403
- }
404
- },
405
- // Spacing overrides - same as day
406
- spacing: {
407
- semanticSpacing: {
408
- xs: "0.125rem",
409
- sm: "0.25rem",
410
- md: "0.5rem",
411
- lg: "0.75rem",
412
- xl: "1rem",
413
- "2xl": "1.5rem"
414
- }
415
- },
416
- // Shadow overrides - subtle for night
417
- shadows: {
418
- elevationShadows: {
419
- xs: "0 1px 2px 0 rgb(0 0 0 / 0.15)",
420
- sm: "0 1px 3px 0 rgb(0 0 0 / 0.2), 0 1px 2px -1px rgb(0 0 0 / 0.2)",
421
- md: "0 2px 5px -1px rgb(0 0 0 / 0.2), 0 1px 3px -2px rgb(0 0 0 / 0.2)",
422
- lg: "0 4px 10px -2px rgb(0 0 0 / 0.2), 0 2px 5px -3px rgb(0 0 0 / 0.2)",
423
- xl: "0 8px 15px -3px rgb(0 0 0 / 0.2), 0 4px 8px -4px rgb(0 0 0 / 0.2)"
424
- },
425
- glowEffects: {
426
- "glow-primary": "0 0 8px 0 hsl(0 0% 55% / 0.25)",
427
- "glow-primary-subtle": "0 0 4px 0 hsl(0 0% 55% / 0.2)",
428
- "glow-primary-medium": "0 0 8px 0 hsl(0 0% 55% / 0.3)",
429
- "glow-primary-strong": "0 0 12px 0 hsl(0 0% 55% / 0.35)"
430
- }
431
- },
432
- // Radius overrides - same as day
433
- radius: {
434
- borderRadius: {
435
- xs: "0.0625rem",
436
- sm: "0.125rem",
437
- md: "0.1875rem",
438
- lg: "0.25rem",
439
- xl: "0.375rem",
440
- "2xl": "0.5rem"
441
- },
442
- componentRadius: {
443
- button: {
444
- sm: "0.125rem",
445
- md: "0.1875rem",
446
- lg: "0.25rem"
447
- },
448
- card: {
449
- sm: "0.1875rem",
450
- md: "0.25rem",
451
- lg: "0.375rem",
452
- xl: "0.5rem"
453
- },
454
- input: {
455
- sm: "0.125rem",
456
- md: "0.1875rem",
457
- lg: "0.25rem"
458
- },
459
- badge: {
460
- sm: "0.0625rem",
461
- md: "0.125rem",
462
- lg: "0.1875rem"
463
- }
464
- }
465
- }
466
- }
467
- }
468
- ]
469
- };
470
-
471
- // src/themes/neon.ts
472
- var neonBrand = {
473
- id: "neon",
474
- name: "Neon",
475
- description: "Vibrant brand theme with high-saturation neon colors, bold typography, and enhanced visual effects",
476
- namespace: "neon",
477
- version: "1.0.0",
478
- author: "Tenerife UI",
479
- themes: [
480
- {
481
- id: "neon-day",
482
- name: "Neon Day",
483
- description: "Bright neon theme for day mode with vibrant cyan, magenta, and yellow accents",
484
- mode: "day",
485
- overrides: {
486
- name: "neon-day",
487
- description: "Bright neon theme for day mode",
488
- // Vibrant neon color overrides
489
- primaryColors: {
490
- 400: "180 100% 50%",
491
- // Bright cyan
492
- 500: "180 100% 45%",
493
- // Vibrant cyan (#00e6ff)
494
- 600: "180 95% 40%",
495
- 700: "180 90% 35%"
496
- },
497
- accentColors: {
498
- 400: "320 100% 60%",
499
- // Bright magenta
500
- 500: "320 100% 55%",
501
- // Vibrant magenta (#ff00cc)
502
- 600: "320 95% 50%",
503
- 700: "320 90% 45%"
504
- },
505
- secondaryColors: {
506
- 400: "60 100% 60%",
507
- // Bright yellow
508
- 500: "60 100% 55%",
509
- // Vibrant yellow (#ffff00)
510
- 600: "60 95% 50%",
511
- 700: "60 90% 45%"
512
- },
513
- // Enhanced base colors for day mode
514
- baseColorsDay: {
515
- primary: "180 100% 45%",
516
- // Neon cyan
517
- primaryForeground: "0 0% 100%",
518
- accent: "320 100% 55%",
519
- // Neon magenta
520
- accentForeground: "0 0% 100%"
521
- },
522
- // Semantic colors with neon accents
523
- semanticColorsDay: {
524
- success: "145 80% 45%",
525
- // Neon green
526
- info: "180 100% 45%",
527
- // Neon cyan
528
- warning: "60 100% 55%",
529
- // Neon yellow
530
- error: "0 100% 60%"
531
- // Bright red
532
- },
533
- // Typography overrides - bolder and larger
534
- typography: {
535
- fontWeight: {
536
- normal: "500",
537
- // Heavier than default (400)
538
- medium: "600",
539
- // Heavier
540
- semibold: "700",
541
- // Bold
542
- bold: "800"
543
- // Extra bold
544
- },
545
- fontSize: {
546
- xs: [
547
- "clamp(0.875rem, 0.8rem + 0.25vw, 1rem)",
548
- { lineHeight: "1.25rem", letterSpacing: "0.025em" }
549
- ],
550
- // Larger than default
551
- sm: [
552
- "clamp(1rem, 0.95rem + 0.25vw, 1.125rem)",
553
- { lineHeight: "1.5rem", letterSpacing: "0em" }
554
- ],
555
- // Larger
556
- base: [
557
- "clamp(1.125rem, 1rem + 0.5vw, 1.25rem)",
558
- { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
559
- ],
560
- // Larger
561
- lg: [
562
- "clamp(1.25rem, 1.1rem + 0.75vw, 1.5rem)",
563
- { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
564
- ],
565
- // Larger
566
- xl: [
567
- "clamp(1.5rem, 1.25rem + 1.25vw, 2rem)",
568
- { lineHeight: "2rem", letterSpacing: "-0.05em" }
569
- ]
570
- // Larger
571
- }
572
- },
573
- // Spacing overrides - larger spacing for breathing room
574
- spacing: {
575
- semanticSpacing: {
576
- xs: "0.5rem",
577
- // 8px (was 4px)
578
- sm: "1rem",
579
- // 16px (was 8px)
580
- md: "1.5rem",
581
- // 24px (was 16px)
582
- lg: "2rem",
583
- // 32px (was 24px)
584
- xl: "3rem",
585
- // 48px (was 32px)
586
- "2xl": "4rem"
587
- // 64px (was 48px)
588
- }
589
- },
590
- // Shadow overrides - stronger and more prominent
591
- shadows: {
592
- elevationShadows: {
593
- xs: "0 2px 4px 0 rgb(0 0 0 / 0.1)",
594
- sm: "0 2px 6px 0 rgb(0 0 0 / 0.15), 0 2px 4px -1px rgb(0 0 0 / 0.15)",
595
- md: "0 6px 10px -1px rgb(0 0 0 / 0.15), 0 4px 6px -2px rgb(0 0 0 / 0.15)",
596
- lg: "0 12px 20px -3px rgb(0 0 0 / 0.15), 0 6px 10px -4px rgb(0 0 0 / 0.15)",
597
- xl: "0 24px 32px -5px rgb(0 0 0 / 0.15), 0 10px 14px -6px rgb(0 0 0 / 0.15)"
598
- },
599
- glowEffects: {
600
- "glow-primary": "0 0 30px 0 hsl(180 100% 45% / 0.7), 0 0 60px 0 hsl(180 100% 45% / 0.4)",
601
- "glow-primary-subtle": "0 0 12px 0 hsl(180 100% 45% / 0.5)",
602
- "glow-primary-medium": "0 0 24px 0 hsl(180 100% 45% / 0.7)",
603
- "glow-primary-strong": "0 0 36px 0 hsl(180 100% 45% / 0.8)",
604
- "glow-accent": "0 0 30px 0 hsl(320 100% 55% / 0.7), 0 0 60px 0 hsl(320 100% 55% / 0.4)",
605
- "glow-accent-subtle": "0 0 12px 0 hsl(320 100% 55% / 0.5)",
606
- "glow-accent-medium": "0 0 24px 0 hsl(320 100% 55% / 0.7)",
607
- "glow-accent-strong": "0 0 36px 0 hsl(320 100% 55% / 0.8)"
608
- }
609
- },
610
- // Radius overrides - more rounded corners
611
- radius: {
612
- borderRadius: {
613
- sm: "0.375rem",
614
- // 6px (was 4px)
615
- md: "0.5rem",
616
- // 8px (was 6px)
617
- lg: "0.75rem",
618
- // 12px (was 8px)
619
- xl: "1rem",
620
- // 16px (was 12px)
621
- "2xl": "1.5rem",
622
- // 24px (was 16px)
623
- "3xl": "2rem"
624
- // 32px (was 24px)
625
- },
626
- componentRadius: {
627
- button: {
628
- sm: "0.5rem",
629
- // 8px
630
- md: "0.75rem",
631
- // 12px
632
- lg: "1rem"
633
- // 16px
634
- },
635
- card: {
636
- sm: "0.75rem",
637
- // 12px
638
- md: "1rem",
639
- // 16px
640
- lg: "1.25rem",
641
- // 20px
642
- xl: "1.5rem"
643
- // 24px
644
- },
645
- input: {
646
- sm: "0.5rem",
647
- // 8px
648
- md: "0.75rem",
649
- // 12px
650
- lg: "1rem"
651
- // 16px
652
- },
653
- badge: {
654
- sm: "0.375rem",
655
- // 6px
656
- md: "0.5rem",
657
- // 8px
658
- lg: "0.75rem"
659
- // 12px
660
- }
661
- }
662
- }
663
- }
664
- },
665
- {
666
- id: "neon-night",
667
- name: "Neon Night",
668
- description: "Dark neon theme for night mode with glowing neon accents on dark backgrounds",
669
- mode: "night",
670
- overrides: {
671
- name: "neon-night",
672
- description: "Dark neon theme for night mode",
673
- // Vibrant neon color overrides (same as day but with different base)
674
- primaryColors: {
675
- 400: "180 100% 55%",
676
- // Brighter cyan for night
677
- 500: "180 100% 50%",
678
- // Vibrant cyan
679
- 600: "180 95% 45%",
680
- 700: "180 90% 40%"
681
- },
682
- accentColors: {
683
- 400: "320 100% 65%",
684
- // Brighter magenta for night
685
- 500: "320 100% 60%",
686
- // Vibrant magenta
687
- 600: "320 95% 55%",
688
- 700: "320 90% 50%"
689
- },
690
- secondaryColors: {
691
- 400: "60 100% 65%",
692
- // Brighter yellow for night
693
- 500: "60 100% 60%",
694
- // Vibrant yellow
695
- 600: "60 95% 55%",
696
- 700: "60 90% 50%"
697
- },
698
- // Darker base colors for night mode
699
- baseColorsNight: {
700
- background: "240 10% 5%",
701
- // Very dark background
702
- foreground: "0 0% 98%",
703
- card: "240 10% 6%",
704
- cardForeground: "0 0% 98%"
705
- },
706
- surfaceColorsNight: {
707
- base: "240 10% 5%",
708
- // Very dark
709
- elevated1: "240 10% 7%",
710
- elevated2: "240 10% 9%",
711
- elevated3: "240 10% 11%"
712
- },
713
- // Semantic colors with neon accents for night
714
- semanticColorsNight: {
715
- success: "145 75% 50%",
716
- // Neon green
717
- info: "180 100% 50%",
718
- // Neon cyan
719
- warning: "60 100% 60%",
720
- // Neon yellow
721
- error: "0 100% 65%"
722
- // Bright red
723
- },
724
- // Typography overrides - same as day
725
- typography: {
726
- fontWeight: {
727
- normal: "500",
728
- medium: "600",
729
- semibold: "700",
730
- bold: "800"
731
- },
732
- fontSize: {
733
- xs: [
734
- "clamp(0.875rem, 0.8rem + 0.25vw, 1rem)",
735
- { lineHeight: "1.25rem", letterSpacing: "0.025em" }
736
- ],
737
- sm: [
738
- "clamp(1rem, 0.95rem + 0.25vw, 1.125rem)",
739
- { lineHeight: "1.5rem", letterSpacing: "0em" }
740
- ],
741
- base: [
742
- "clamp(1.125rem, 1rem + 0.5vw, 1.25rem)",
743
- { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
744
- ],
745
- lg: [
746
- "clamp(1.25rem, 1.1rem + 0.75vw, 1.5rem)",
747
- { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
748
- ],
749
- xl: [
750
- "clamp(1.5rem, 1.25rem + 1.25vw, 2rem)",
751
- { lineHeight: "2rem", letterSpacing: "-0.05em" }
752
- ]
753
- }
754
- },
755
- // Spacing overrides - same as day
756
- spacing: {
757
- semanticSpacing: {
758
- xs: "0.5rem",
759
- sm: "1rem",
760
- md: "1.5rem",
761
- lg: "2rem",
762
- xl: "3rem",
763
- "2xl": "4rem"
764
- }
765
- },
766
- // Shadow overrides - even stronger glow for night
767
- shadows: {
768
- elevationShadows: {
769
- xs: "0 2px 4px 0 rgb(0 0 0 / 0.2)",
770
- sm: "0 2px 6px 0 rgb(0 0 0 / 0.25), 0 2px 4px -1px rgb(0 0 0 / 0.25)",
771
- md: "0 6px 10px -1px rgb(0 0 0 / 0.25), 0 4px 6px -2px rgb(0 0 0 / 0.25)",
772
- lg: "0 12px 20px -3px rgb(0 0 0 / 0.25), 0 6px 10px -4px rgb(0 0 0 / 0.25)",
773
- xl: "0 24px 32px -5px rgb(0 0 0 / 0.25), 0 10px 14px -6px rgb(0 0 0 / 0.25)"
774
- },
775
- glowEffects: {
776
- "glow-primary": "0 0 40px 0 hsl(180 100% 50% / 0.8), 0 0 80px 0 hsl(180 100% 50% / 0.5)",
777
- "glow-primary-subtle": "0 0 16px 0 hsl(180 100% 50% / 0.6)",
778
- "glow-primary-medium": "0 0 32px 0 hsl(180 100% 50% / 0.8)",
779
- "glow-primary-strong": "0 0 48px 0 hsl(180 100% 50% / 0.9)",
780
- "glow-accent": "0 0 40px 0 hsl(320 100% 60% / 0.8), 0 0 80px 0 hsl(320 100% 60% / 0.5)",
781
- "glow-accent-subtle": "0 0 16px 0 hsl(320 100% 60% / 0.6)",
782
- "glow-accent-medium": "0 0 32px 0 hsl(320 100% 60% / 0.8)",
783
- "glow-accent-strong": "0 0 48px 0 hsl(320 100% 60% / 0.9)"
784
- }
785
- },
786
- // Radius overrides - same as day
787
- radius: {
788
- borderRadius: {
789
- sm: "0.375rem",
790
- md: "0.5rem",
791
- lg: "0.75rem",
792
- xl: "1rem",
793
- "2xl": "1.5rem",
794
- "3xl": "2rem"
795
- },
796
- componentRadius: {
797
- button: {
798
- sm: "0.5rem",
799
- md: "0.75rem",
800
- lg: "1rem"
801
- },
802
- card: {
803
- sm: "0.75rem",
804
- md: "1rem",
805
- lg: "1.25rem",
806
- xl: "1.5rem"
807
- },
808
- input: {
809
- sm: "0.5rem",
810
- md: "0.75rem",
811
- lg: "1rem"
812
- },
813
- badge: {
814
- sm: "0.375rem",
815
- md: "0.5rem",
816
- lg: "0.75rem"
817
- }
818
- }
819
- }
820
- }
821
- }
822
- ]
823
- };
824
-
825
- // src/themes/brand_engine.ts
826
- var brandRegistry = /* @__PURE__ */ new Map();
827
- var activeBrand = null;
828
- var activeNamespace = null;
829
- var brandCache = /* @__PURE__ */ new Map();
830
- function validateBrand(brand) {
831
- const errors = [];
832
- const warnings = [];
833
- if (!brand || typeof brand !== "object") {
834
- return {
835
- valid: false,
836
- errors: ["Brand must be an object"],
837
- warnings: []
838
- };
839
- }
840
- const brandObj = brand;
841
- const requiredFields = ["id", "name", "namespace"];
842
- for (const field of requiredFields) {
843
- if (!(field in brandObj) || !brandObj[field]) {
844
- errors.push(`Missing required field: ${field}`);
845
- }
846
- }
847
- if (brandObj.id && typeof brandObj.id === "string") {
848
- const idRegex = /^[a-z0-9]+(?:-[a-z0-9]+)*$/;
849
- if (!idRegex.test(brandObj.id)) {
850
- errors.push(
851
- `Invalid brand ID format: "${brandObj.id}". Must be kebab-case (e.g., "neon-brand")`
852
- );
853
- }
854
- }
855
- if (brandObj.namespace && typeof brandObj.namespace === "string") {
856
- const namespaceRegex = /^[a-z0-9]+(?:-[a-z0-9]+)*$/;
857
- if (!namespaceRegex.test(brandObj.namespace)) {
858
- errors.push(
859
- `Invalid namespace format: "${brandObj.namespace}". Must be kebab-case (e.g., "neon")`
860
- );
861
- }
862
- }
863
- if (brandObj.themes) {
864
- if (!Array.isArray(brandObj.themes)) {
865
- errors.push("Brand themes must be an array");
866
- } else {
867
- const themes2 = brandObj.themes;
868
- if (themes2.length === 0) {
869
- warnings.push("Brand has no themes defined");
870
- }
871
- themes2.forEach((theme, index) => {
872
- if (!theme || typeof theme !== "object") {
873
- errors.push(`Theme at index ${index} must be an object`);
874
- return;
875
- }
876
- const themeObj = theme;
877
- if (!themeObj.id || typeof themeObj.id !== "string") {
878
- errors.push(`Theme at index ${index} is missing required field: id`);
879
- }
880
- if (!themeObj.name || typeof themeObj.name !== "string") {
881
- errors.push(`Theme at index ${index} is missing required field: name`);
882
- }
883
- if (!themeObj.mode || !["day", "night"].includes(themeObj.mode)) {
884
- errors.push(`Theme at index ${index} must have mode set to "day" or "night"`);
885
- }
886
- if (!themeObj.overrides || typeof themeObj.overrides !== "object") {
887
- errors.push(`Theme at index ${index} is missing required field: overrides`);
888
- }
889
- });
890
- }
891
- } else {
892
- errors.push("Brand must have at least one theme");
893
- }
894
- if (brandObj.version && typeof brandObj.version === "string") {
895
- const semverRegex = /^\d+\.\d+\.\d+$/;
896
- if (!semverRegex.test(brandObj.version)) {
897
- warnings.push(
898
- `Invalid version format: "${brandObj.version}". Should be semver (e.g., "1.0.0")`
899
- );
900
- }
901
- }
902
- if (brandObj.themes && Array.isArray(brandObj.themes)) {
903
- const themeIds = brandObj.themes.map(
904
- (theme) => theme?.id
905
- );
906
- const uniqueIds = new Set(themeIds);
907
- if (themeIds.length !== uniqueIds.size) {
908
- errors.push("Brand contains duplicate theme IDs");
909
- }
910
- }
911
- return {
912
- valid: errors.length === 0,
913
- errors,
914
- warnings
915
- };
916
- }
917
- function registerBrand(brand, options) {
918
- const validation = validateBrand(brand);
919
- if (!validation.valid) {
920
- throw new Error(`Invalid brand "${brand.id}": ${validation.errors.join(", ")}`);
921
- }
922
- if (validation.warnings.length > 0) {
923
- console.warn(`Brand "${brand.id}" validation warnings:`, validation.warnings.join(", "));
924
- }
925
- const existingEntry = brandRegistry.get(brand.id);
926
- if (existingEntry && existingEntry.brand.namespace === brand.namespace) {
927
- return;
928
- }
929
- if (brandRegistry.has(brand.id)) {
930
- throw new Error(`Brand "${brand.id}" is already registered`);
931
- }
932
- const existingBrand = Array.from(brandRegistry.values()).find(
933
- (entry) => entry.brand.namespace === brand.namespace
934
- );
935
- if (existingBrand) {
936
- throw new Error(
937
- `Brand namespace "${brand.namespace}" is already used by brand "${existingBrand.brand.id}"`
938
- );
939
- }
940
- brandRegistry.set(brand.id, {
941
- brand,
942
- enabled: options?.enabled !== false,
943
- loader: options?.loader
944
- });
945
- }
946
- async function loadBrand(brandId) {
947
- if (brandCache.has(brandId)) {
948
- return brandCache.get(brandId);
949
- }
950
- const entry = brandRegistry.get(brandId);
951
- if (!entry) {
952
- throw new Error(`Brand "${brandId}" not found in registry`);
953
- }
954
- if (entry.enabled === false) {
955
- throw new Error(`Brand "${brandId}" is disabled`);
956
- }
957
- if (entry.loader) {
958
- try {
959
- const module = await entry.loader();
960
- const loadedBrand = module.default;
961
- const validation = validateBrand(loadedBrand);
962
- if (!validation.valid) {
963
- throw new Error(`Invalid loaded brand "${brandId}": ${validation.errors.join(", ")}`);
964
- }
965
- brandCache.set(brandId, loadedBrand);
966
- return loadedBrand;
967
- } catch (error) {
968
- throw new Error(
969
- `Failed to load brand "${brandId}": ${error instanceof Error ? error.message : String(error)}`
970
- );
971
- }
972
- }
973
- brandCache.set(brandId, entry.brand);
974
- return entry.brand;
975
- }
976
- function getActiveBrand() {
977
- return activeBrand;
978
- }
979
- function setActiveBrand(brand) {
980
- activeBrand = brand;
981
- activeNamespace = brand?.namespace || null;
982
- }
983
- function clearActiveBrand() {
984
- activeBrand = null;
985
- activeNamespace = null;
986
- }
987
- function getBrandTheme(brand, mode) {
988
- return brand.themes.find((theme) => theme.mode === mode);
989
- }
990
- function applyBrandOverrides(brand, mode) {
991
- if (typeof document === "undefined") return;
992
- const theme = getBrandTheme(brand, mode);
993
- if (!theme) {
994
- console.warn(`Brand "${brand.id}" has no theme for mode "${mode}"`);
995
- return;
996
- }
997
- const root = document.documentElement;
998
- const { namespace } = brand;
999
- const { overrides } = theme;
1000
- if (overrides.primaryColors) {
1001
- Object.entries(overrides.primaryColors).forEach(([key, value]) => {
1002
- root.style.setProperty(`--brand-${namespace}-primary-${key}`, value);
1003
- });
1004
- }
1005
- if (overrides.accentColors) {
1006
- Object.entries(overrides.accentColors).forEach(([key, value]) => {
1007
- root.style.setProperty(`--brand-${namespace}-accent-${key}`, value);
1008
- });
1009
- }
1010
- if (overrides.secondaryColors) {
1011
- Object.entries(overrides.secondaryColors).forEach(([key, value]) => {
1012
- root.style.setProperty(`--brand-${namespace}-secondary-${key}`, value);
1013
- });
1014
- }
1015
- const modeColors = mode === "day" ? overrides.baseColorsDay : overrides.baseColorsNight;
1016
- if (modeColors) {
1017
- Object.entries(modeColors).forEach(([key, value]) => {
1018
- root.style.setProperty(`--brand-${namespace}-${key}`, value);
1019
- });
1020
- }
1021
- if (overrides.typography) {
1022
- if (overrides.typography.fontFamily) {
1023
- Object.entries(overrides.typography.fontFamily).forEach(([key, value]) => {
1024
- root.style.setProperty(
1025
- `--brand-${namespace}-font-${key}`,
1026
- Array.isArray(value) ? value.join(", ") : value
1027
- );
1028
- });
1029
- }
1030
- if (overrides.typography.fontSize) {
1031
- Object.entries(overrides.typography.fontSize).forEach(([key, value]) => {
1032
- const fontSizeValue = typeof value === "string" ? value : value[0];
1033
- root.style.setProperty(`--brand-${namespace}-font-size-${key}`, fontSizeValue);
1034
- });
1035
- }
1036
- if (overrides.typography.fontWeight) {
1037
- Object.entries(overrides.typography.fontWeight).forEach(([key, value]) => {
1038
- root.style.setProperty(`--brand-${namespace}-font-weight-${key}`, value);
1039
- });
1040
- }
1041
- if (overrides.typography.lineHeight) {
1042
- Object.entries(overrides.typography.lineHeight).forEach(([key, value]) => {
1043
- root.style.setProperty(`--brand-${namespace}-line-height-${key}`, value);
1044
- });
1045
- }
1046
- if (overrides.typography.letterSpacing) {
1047
- Object.entries(overrides.typography.letterSpacing).forEach(([key, value]) => {
1048
- root.style.setProperty(`--brand-${namespace}-letter-spacing-${key}`, value);
1049
- });
1050
- }
1051
- }
1052
- if (overrides.spacing) {
1053
- if (overrides.spacing.semanticSpacing) {
1054
- Object.entries(overrides.spacing.semanticSpacing).forEach(([key, value]) => {
1055
- root.style.setProperty(`--brand-${namespace}-spacing-${key}`, value);
1056
- });
1057
- }
1058
- if (overrides.spacing.layoutSpacing) {
1059
- const layout = overrides.spacing.layoutSpacing;
1060
- if (layout.section) {
1061
- Object.entries(layout.section).forEach(([key, value]) => {
1062
- if (typeof value === "string") {
1063
- root.style.setProperty(`--brand-${namespace}-layout-section-${key}`, value);
1064
- }
1065
- });
1066
- }
1067
- if (layout.container) {
1068
- Object.entries(layout.container).forEach(([key, value]) => {
1069
- if (typeof value === "string") {
1070
- root.style.setProperty(`--brand-${namespace}-layout-container-${key}`, value);
1071
- }
1072
- });
1073
- }
1074
- if (layout.grid) {
1075
- Object.entries(layout.grid).forEach(([key, value]) => {
1076
- if (typeof value === "string") {
1077
- root.style.setProperty(`--brand-${namespace}-layout-grid-${key}`, value);
1078
- }
1079
- });
1080
- }
1081
- if (layout.stack) {
1082
- Object.entries(layout.stack).forEach(([key, value]) => {
1083
- if (typeof value === "string") {
1084
- root.style.setProperty(`--brand-${namespace}-layout-stack-${key}`, value);
1085
- }
1086
- });
1087
- }
1088
- if (layout.component) {
1089
- Object.entries(layout.component).forEach(([key, value]) => {
1090
- if (typeof value === "string") {
1091
- root.style.setProperty(`--brand-${namespace}-layout-component-${key}`, value);
1092
- }
1093
- });
1094
- }
1095
- }
1096
- }
1097
- if (overrides.shadows) {
1098
- if (overrides.shadows.elevationShadows) {
1099
- Object.entries(overrides.shadows.elevationShadows).forEach(([key, value]) => {
1100
- root.style.setProperty(`--brand-${namespace}-shadow-${key}`, value);
1101
- });
1102
- }
1103
- if (overrides.shadows.primaryColoredShadows) {
1104
- Object.entries(overrides.shadows.primaryColoredShadows).forEach(([key, value]) => {
1105
- root.style.setProperty(`--brand-${namespace}-shadow-primary-${key}`, value);
1106
- });
1107
- }
1108
- if (overrides.shadows.accentColoredShadows) {
1109
- Object.entries(overrides.shadows.accentColoredShadows).forEach(([key, value]) => {
1110
- root.style.setProperty(`--brand-${namespace}-shadow-accent-${key}`, value);
1111
- });
1112
- }
1113
- if (overrides.shadows.glowEffects) {
1114
- Object.entries(overrides.shadows.glowEffects).forEach(([key, value]) => {
1115
- root.style.setProperty(`--brand-${namespace}-glow-${key}`, value);
1116
- });
1117
- }
1118
- if (overrides.shadows.focusRings) {
1119
- Object.entries(overrides.shadows.focusRings).forEach(([key, value]) => {
1120
- root.style.setProperty(`--brand-${namespace}-focus-ring-${key}`, value);
1121
- });
1122
- }
1123
- }
1124
- if (overrides.radius) {
1125
- if (overrides.radius.borderRadius) {
1126
- Object.entries(overrides.radius.borderRadius).forEach(([key, value]) => {
1127
- root.style.setProperty(`--brand-${namespace}-radius-${key}`, value);
1128
- });
1129
- }
1130
- if (overrides.radius.componentRadius) {
1131
- const { componentRadius: componentRadius2 } = overrides.radius;
1132
- if (componentRadius2.button) {
1133
- Object.entries(componentRadius2.button).forEach(([key, value]) => {
1134
- root.style.setProperty(`--brand-${namespace}-radius-button-${key}`, value);
1135
- });
1136
- }
1137
- if (componentRadius2.card) {
1138
- Object.entries(componentRadius2.card).forEach(([key, value]) => {
1139
- root.style.setProperty(`--brand-${namespace}-radius-card-${key}`, value);
1140
- });
1141
- }
1142
- if (componentRadius2.input) {
1143
- Object.entries(componentRadius2.input).forEach(([key, value]) => {
1144
- root.style.setProperty(`--brand-${namespace}-radius-input-${key}`, value);
1145
- });
1146
- }
1147
- }
1148
- }
1149
- setActiveBrand(brand);
1150
- root.setAttribute("data-brand", brand.id);
1151
- root.setAttribute("data-brand-namespace", namespace);
1152
- }
1153
- function removeBrandOverrides(namespace) {
1154
- if (typeof document === "undefined") return;
1155
- const root = document.documentElement;
1156
- const { style } = root;
1157
- const propsToRemove = [];
1158
- for (let i = 0; i < style.length; i++) {
1159
- const prop = style.item(i);
1160
- if (prop && prop.startsWith(`--brand-${namespace}-`)) {
1161
- propsToRemove.push(prop);
1162
- }
1163
- }
1164
- propsToRemove.forEach((prop) => {
1165
- style.removeProperty(prop);
1166
- });
1167
- root.removeAttribute("data-brand");
1168
- root.removeAttribute("data-brand-namespace");
1169
- if (activeNamespace === namespace) {
1170
- clearActiveBrand();
1171
- }
1172
- }
1173
-
1174
- // src/themes/index.ts
1175
- var themes = {
1176
- default: () => Promise.resolve().then(() => (init_default(), default_exports)).then((m) => m.defaultTheme),
1177
- dark: () => Promise.resolve().then(() => (init_dark(), dark_exports)).then((m) => m.darkTheme),
1178
- brand: () => Promise.resolve().then(() => (init_brand(), brand_exports)).then((m) => m.brandTheme)
1179
- };
1180
- async function getTheme(name) {
1181
- const themeLoader = themes[name];
1182
- if (!themeLoader) {
1183
- throw new Error(`Theme "${name}" not found`);
1184
- }
1185
- return await themeLoader();
1186
- }
1187
-
1188
- // src/tokens/colors.ts
124
+ // src/FOUNDATION/tokens/colors.ts
1189
125
  var primaryColors = {
1190
126
  50: "210 40% 98%",
1191
127
  // Lightest blue
@@ -1587,7 +523,7 @@ var tailwindThemeColors = {
1587
523
  }
1588
524
  };
1589
525
 
1590
- // src/tokens/motion/v2.ts
526
+ // src/FOUNDATION/tokens/motion/v2.ts
1591
527
  var motionV2Durations = {
1592
528
  fast: "150ms",
1593
529
  // Quick interactions
@@ -1631,7 +567,7 @@ var motionV2CSSVariables = {
1631
567
  "--motion-transition-reduced": motionV2Transitions.reduced
1632
568
  };
1633
569
 
1634
- // src/tokens/motion.ts
570
+ // src/FOUNDATION/tokens/motion.ts
1635
571
  var durations = {
1636
572
  instant: "0ms",
1637
573
  fast: "150ms",
@@ -1743,7 +679,7 @@ var motionCSSVariables = {
1743
679
  "--transition-elastic": transitions.elastic
1744
680
  };
1745
681
 
1746
- // src/tokens/radius.ts
682
+ // src/FOUNDATION/tokens/radius.ts
1747
683
  var borderRadius = {
1748
684
  // No radius
1749
685
  none: "0",
@@ -1837,7 +773,7 @@ var radiusCSSVariables = {
1837
773
  "--radius-image": componentRadius.image.md
1838
774
  };
1839
775
 
1840
- // src/tokens/shadows.ts
776
+ // src/FOUNDATION/tokens/shadows.ts
1841
777
  var shadowBase = {
1842
778
  black: "0 0 0"};
1843
779
  var shadowOpacity = {
@@ -1931,7 +867,7 @@ var shadowCSSVariables = {
1931
867
  "--focus-accent": focusRings["focus-accent"]
1932
868
  };
1933
869
 
1934
- // src/tokens/spacing.ts
870
+ // src/FOUNDATION/tokens/spacing.ts
1935
871
  var spacing = {
1936
872
  // Zero spacing
1937
873
  0: "0",
@@ -2146,7 +1082,7 @@ var spacingCSSVariables = {
2146
1082
  "--layout-component-xl": layoutSpacing.component.xl
2147
1083
  };
2148
1084
 
2149
- // src/tokens/typography.ts
1085
+ // src/FOUNDATION/tokens/typography.ts
2150
1086
  var fontFamily = {
2151
1087
  // Primary font - Inter (default sans)
2152
1088
  sans: [
@@ -2204,243 +1140,1307 @@ var fontFamily = {
2204
1140
  "monospace"
2205
1141
  ]
2206
1142
  };
2207
- var fontSize = {
2208
- // text-xs: 12px base, scales from 0.75rem to 0.875rem
2209
- xs: [
2210
- "clamp(0.75rem, 0.7rem + 0.125vw, 0.875rem)",
2211
- { lineHeight: "1rem", letterSpacing: "0.05em" }
2212
- ],
2213
- // text-sm: 14px base, scales from 0.875rem to 1rem
2214
- sm: [
2215
- "clamp(0.875rem, 0.8rem + 0.25vw, 1rem)",
2216
- { lineHeight: "1.25rem", letterSpacing: "0.025em" }
2217
- ],
2218
- // text-base: 16px base, scales from 1rem to 1.125rem
2219
- base: ["clamp(1rem, 0.95rem + 0.25vw, 1.125rem)", { lineHeight: "1.5rem", letterSpacing: "0em" }],
2220
- // text-lg: 18px base, scales from 1.125rem to 1.25rem
2221
- lg: [
2222
- "clamp(1.125rem, 1rem + 0.5vw, 1.25rem)",
2223
- { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
2224
- ],
2225
- // text-xl: 20px base, scales from 1.25rem to 1.5rem
2226
- xl: [
2227
- "clamp(1.25rem, 1.1rem + 0.75vw, 1.5rem)",
2228
- { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
2229
- ],
2230
- // text-2xl: 24px base, scales from 1.5rem to 2rem
2231
- "2xl": [
2232
- "clamp(1.5rem, 1.25rem + 1.25vw, 2rem)",
2233
- { lineHeight: "2rem", letterSpacing: "-0.05em" }
2234
- ],
2235
- // text-3xl: 30px base, scales from 1.875rem to 2.5rem
2236
- "3xl": [
2237
- "clamp(1.875rem, 1.5rem + 1.875vw, 2.5rem)",
2238
- { lineHeight: "2.25rem", letterSpacing: "-0.05em" }
2239
- ],
2240
- // text-4xl: 36px base, scales from 2.25rem to 3rem
2241
- "4xl": [
2242
- "clamp(2.25rem, 1.75rem + 2.5vw, 3rem)",
2243
- { lineHeight: "2.5rem", letterSpacing: "-0.025em" }
2244
- ],
2245
- // text-5xl: 48px base, scales from 3rem to 4rem
2246
- "5xl": ["clamp(3rem, 2rem + 5vw, 4rem)", { lineHeight: "1", letterSpacing: "-0.025em" }],
2247
- // text-6xl: 60px base, scales from 3.75rem to 5rem
2248
- "6xl": ["clamp(3.75rem, 2.5rem + 6.25vw, 5rem)", { lineHeight: "1", letterSpacing: "-0.05em" }],
2249
- // text-7xl: 72px base (optional, for hero sections)
2250
- "7xl": ["clamp(4.5rem, 3rem + 7.5vw, 6rem)", { lineHeight: "1", letterSpacing: "-0.05em" }],
2251
- // text-8xl: 96px base (optional, for hero sections)
2252
- "8xl": ["clamp(6rem, 4rem + 10vw, 8rem)", { lineHeight: "1", letterSpacing: "-0.05em" }],
2253
- // text-9xl: 128px base (optional, for hero sections)
2254
- "9xl": ["clamp(8rem, 5rem + 15vw, 12rem)", { lineHeight: "1", letterSpacing: "-0.05em" }]
2255
- };
2256
- var fontWeight = {
2257
- thin: "100",
2258
- extralight: "200",
2259
- light: "300",
2260
- normal: "400",
2261
- medium: "500",
2262
- semibold: "600",
2263
- bold: "700",
2264
- extrabold: "800",
2265
- black: "900"
2266
- };
2267
- var lineHeight = {
2268
- none: "1",
2269
- tight: "1.25",
2270
- snug: "1.375",
2271
- normal: "1.5",
2272
- relaxed: "1.625",
2273
- loose: "2"
2274
- };
2275
- var letterSpacing = {
2276
- tighter: "-0.05em",
2277
- tight: "-0.025em",
2278
- normal: "0em",
2279
- wide: "0.025em",
2280
- wider: "0.05em",
2281
- widest: "0.1em"
2282
- };
2283
- var typographyCSSVariables = {
2284
- // Font families
2285
- "--font-sans": fontFamily.sans.join(", "),
2286
- "--font-satoshi": fontFamily.satoshi.join(", "),
2287
- "--font-display": fontFamily.display.join(", "),
2288
- "--font-serif": fontFamily.serif.join(", "),
2289
- "--font-mono": fontFamily.mono.join(", "),
2290
- // Font sizes (using clamp values)
2291
- "--font-size-xs": fontSize.xs[0],
2292
- "--font-size-sm": fontSize.sm[0],
2293
- "--font-size-base": fontSize.base[0],
2294
- "--font-size-lg": fontSize.lg[0],
2295
- "--font-size-xl": fontSize.xl[0],
2296
- "--font-size-2xl": fontSize["2xl"][0],
2297
- "--font-size-3xl": fontSize["3xl"][0],
2298
- "--font-size-4xl": fontSize["4xl"][0],
2299
- "--font-size-5xl": fontSize["5xl"][0],
2300
- "--font-size-6xl": fontSize["6xl"][0],
2301
- // Font weights
2302
- "--font-weight-thin": fontWeight.thin,
2303
- "--font-weight-extralight": fontWeight.extralight,
2304
- "--font-weight-light": fontWeight.light,
2305
- "--font-weight-normal": fontWeight.normal,
2306
- "--font-weight-medium": fontWeight.medium,
2307
- "--font-weight-semibold": fontWeight.semibold,
2308
- "--font-weight-bold": fontWeight.bold,
2309
- "--font-weight-extrabold": fontWeight.extrabold,
2310
- "--font-weight-black": fontWeight.black,
2311
- // Line heights
2312
- "--line-height-none": lineHeight.none,
2313
- "--line-height-tight": lineHeight.tight,
2314
- "--line-height-snug": lineHeight.snug,
2315
- "--line-height-normal": lineHeight.normal,
2316
- "--line-height-relaxed": lineHeight.relaxed,
2317
- "--line-height-loose": lineHeight.loose,
2318
- // Letter spacing
2319
- "--letter-spacing-tighter": letterSpacing.tighter,
2320
- "--letter-spacing-tight": letterSpacing.tight,
2321
- "--letter-spacing-normal": letterSpacing.normal,
2322
- "--letter-spacing-wide": letterSpacing.wide,
2323
- "--letter-spacing-wider": letterSpacing.wider,
2324
- "--letter-spacing-widest": letterSpacing.widest
1143
+ var fontSize = {
1144
+ // text-xs: 12px base, scales from 0.75rem to 0.875rem
1145
+ xs: [
1146
+ "clamp(0.75rem, 0.7rem + 0.125vw, 0.875rem)",
1147
+ { lineHeight: "1rem", letterSpacing: "0.05em" }
1148
+ ],
1149
+ // text-sm: 14px base, scales from 0.875rem to 1rem
1150
+ sm: [
1151
+ "clamp(0.875rem, 0.8rem + 0.25vw, 1rem)",
1152
+ { lineHeight: "1.25rem", letterSpacing: "0.025em" }
1153
+ ],
1154
+ // text-base: 16px base, scales from 1rem to 1.125rem
1155
+ base: ["clamp(1rem, 0.95rem + 0.25vw, 1.125rem)", { lineHeight: "1.5rem", letterSpacing: "0em" }],
1156
+ // text-lg: 18px base, scales from 1.125rem to 1.25rem
1157
+ lg: [
1158
+ "clamp(1.125rem, 1rem + 0.5vw, 1.25rem)",
1159
+ { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
1160
+ ],
1161
+ // text-xl: 20px base, scales from 1.25rem to 1.5rem
1162
+ xl: [
1163
+ "clamp(1.25rem, 1.1rem + 0.75vw, 1.5rem)",
1164
+ { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
1165
+ ],
1166
+ // text-2xl: 24px base, scales from 1.5rem to 2rem
1167
+ "2xl": [
1168
+ "clamp(1.5rem, 1.25rem + 1.25vw, 2rem)",
1169
+ { lineHeight: "2rem", letterSpacing: "-0.05em" }
1170
+ ],
1171
+ // text-3xl: 30px base, scales from 1.875rem to 2.5rem
1172
+ "3xl": [
1173
+ "clamp(1.875rem, 1.5rem + 1.875vw, 2.5rem)",
1174
+ { lineHeight: "2.25rem", letterSpacing: "-0.05em" }
1175
+ ],
1176
+ // text-4xl: 36px base, scales from 2.25rem to 3rem
1177
+ "4xl": [
1178
+ "clamp(2.25rem, 1.75rem + 2.5vw, 3rem)",
1179
+ { lineHeight: "2.5rem", letterSpacing: "-0.025em" }
1180
+ ],
1181
+ // text-5xl: 48px base, scales from 3rem to 4rem
1182
+ "5xl": ["clamp(3rem, 2rem + 5vw, 4rem)", { lineHeight: "1", letterSpacing: "-0.025em" }],
1183
+ // text-6xl: 60px base, scales from 3.75rem to 5rem
1184
+ "6xl": ["clamp(3.75rem, 2.5rem + 6.25vw, 5rem)", { lineHeight: "1", letterSpacing: "-0.05em" }],
1185
+ // text-7xl: 72px base (optional, for hero sections)
1186
+ "7xl": ["clamp(4.5rem, 3rem + 7.5vw, 6rem)", { lineHeight: "1", letterSpacing: "-0.05em" }],
1187
+ // text-8xl: 96px base (optional, for hero sections)
1188
+ "8xl": ["clamp(6rem, 4rem + 10vw, 8rem)", { lineHeight: "1", letterSpacing: "-0.05em" }],
1189
+ // text-9xl: 128px base (optional, for hero sections)
1190
+ "9xl": ["clamp(8rem, 5rem + 15vw, 12rem)", { lineHeight: "1", letterSpacing: "-0.05em" }]
1191
+ };
1192
+ var fontWeight = {
1193
+ thin: "100",
1194
+ extralight: "200",
1195
+ light: "300",
1196
+ normal: "400",
1197
+ medium: "500",
1198
+ semibold: "600",
1199
+ bold: "700",
1200
+ extrabold: "800",
1201
+ black: "900"
1202
+ };
1203
+ var lineHeight = {
1204
+ none: "1",
1205
+ tight: "1.25",
1206
+ snug: "1.375",
1207
+ normal: "1.5",
1208
+ relaxed: "1.625",
1209
+ loose: "2"
1210
+ };
1211
+ var letterSpacing = {
1212
+ tighter: "-0.05em",
1213
+ tight: "-0.025em",
1214
+ normal: "0em",
1215
+ wide: "0.025em",
1216
+ wider: "0.05em",
1217
+ widest: "0.1em"
1218
+ };
1219
+ var typographyCSSVariables = {
1220
+ // Font families
1221
+ "--font-sans": fontFamily.sans.join(", "),
1222
+ "--font-satoshi": fontFamily.satoshi.join(", "),
1223
+ "--font-display": fontFamily.display.join(", "),
1224
+ "--font-serif": fontFamily.serif.join(", "),
1225
+ "--font-mono": fontFamily.mono.join(", "),
1226
+ // Font sizes (using clamp values)
1227
+ "--font-size-xs": fontSize.xs[0],
1228
+ "--font-size-sm": fontSize.sm[0],
1229
+ "--font-size-base": fontSize.base[0],
1230
+ "--font-size-lg": fontSize.lg[0],
1231
+ "--font-size-xl": fontSize.xl[0],
1232
+ "--font-size-2xl": fontSize["2xl"][0],
1233
+ "--font-size-3xl": fontSize["3xl"][0],
1234
+ "--font-size-4xl": fontSize["4xl"][0],
1235
+ "--font-size-5xl": fontSize["5xl"][0],
1236
+ "--font-size-6xl": fontSize["6xl"][0],
1237
+ // Font weights
1238
+ "--font-weight-thin": fontWeight.thin,
1239
+ "--font-weight-extralight": fontWeight.extralight,
1240
+ "--font-weight-light": fontWeight.light,
1241
+ "--font-weight-normal": fontWeight.normal,
1242
+ "--font-weight-medium": fontWeight.medium,
1243
+ "--font-weight-semibold": fontWeight.semibold,
1244
+ "--font-weight-bold": fontWeight.bold,
1245
+ "--font-weight-extrabold": fontWeight.extrabold,
1246
+ "--font-weight-black": fontWeight.black,
1247
+ // Line heights
1248
+ "--line-height-none": lineHeight.none,
1249
+ "--line-height-tight": lineHeight.tight,
1250
+ "--line-height-snug": lineHeight.snug,
1251
+ "--line-height-normal": lineHeight.normal,
1252
+ "--line-height-relaxed": lineHeight.relaxed,
1253
+ "--line-height-loose": lineHeight.loose,
1254
+ // Letter spacing
1255
+ "--letter-spacing-tighter": letterSpacing.tighter,
1256
+ "--letter-spacing-tight": letterSpacing.tight,
1257
+ "--letter-spacing-normal": letterSpacing.normal,
1258
+ "--letter-spacing-wide": letterSpacing.wide,
1259
+ "--letter-spacing-wider": letterSpacing.wider,
1260
+ "--letter-spacing-widest": letterSpacing.widest
1261
+ };
1262
+ ({
1263
+ // Display styles (for hero sections)
1264
+ display: {
1265
+ fontSize: fontSize["6xl"][0]},
1266
+ // Heading styles
1267
+ h1: {
1268
+ fontSize: fontSize["5xl"][0]},
1269
+ h2: {
1270
+ fontSize: fontSize["4xl"][0]},
1271
+ h3: {
1272
+ fontSize: fontSize["3xl"][0]},
1273
+ h4: {
1274
+ fontSize: fontSize["2xl"][0]},
1275
+ h5: {
1276
+ fontSize: fontSize.xl[0]},
1277
+ h6: {
1278
+ fontSize: fontSize.lg[0]},
1279
+ // Body text styles
1280
+ body: {
1281
+ fontSize: fontSize.base[0]},
1282
+ "body-sm": {
1283
+ fontSize: fontSize.sm[0]},
1284
+ "body-xs": {
1285
+ fontSize: fontSize.xs[0]},
1286
+ // Label styles
1287
+ label: {
1288
+ fontSize: fontSize.sm[0]},
1289
+ "label-sm": {
1290
+ fontSize: fontSize.xs[0]},
1291
+ // Caption styles
1292
+ caption: {
1293
+ fontSize: fontSize.xs[0]}
1294
+ });
1295
+ ({
1296
+ fontSize: {
1297
+ xs: [
1298
+ fontSize.xs[0],
1299
+ { lineHeight: fontSize.xs[1].lineHeight, letterSpacing: fontSize.xs[1].letterSpacing }
1300
+ ],
1301
+ sm: [
1302
+ fontSize.sm[0],
1303
+ { lineHeight: fontSize.sm[1].lineHeight, letterSpacing: fontSize.sm[1].letterSpacing }
1304
+ ],
1305
+ md: [
1306
+ fontSize.base[0],
1307
+ { lineHeight: fontSize.base[1].lineHeight, letterSpacing: fontSize.base[1].letterSpacing }
1308
+ ],
1309
+ base: [
1310
+ fontSize.base[0],
1311
+ { lineHeight: fontSize.base[1].lineHeight, letterSpacing: fontSize.base[1].letterSpacing }
1312
+ ],
1313
+ lg: [
1314
+ fontSize.lg[0],
1315
+ { lineHeight: fontSize.lg[1].lineHeight, letterSpacing: fontSize.lg[1].letterSpacing }
1316
+ ],
1317
+ xl: [
1318
+ fontSize.xl[0],
1319
+ { lineHeight: fontSize.xl[1].lineHeight, letterSpacing: fontSize.xl[1].letterSpacing }
1320
+ ],
1321
+ "2xl": [
1322
+ fontSize["2xl"][0],
1323
+ {
1324
+ lineHeight: fontSize["2xl"][1].lineHeight,
1325
+ letterSpacing: fontSize["2xl"][1].letterSpacing
1326
+ }
1327
+ ],
1328
+ "3xl": [
1329
+ fontSize["3xl"][0],
1330
+ {
1331
+ lineHeight: fontSize["3xl"][1].lineHeight,
1332
+ letterSpacing: fontSize["3xl"][1].letterSpacing
1333
+ }
1334
+ ],
1335
+ "4xl": [
1336
+ fontSize["4xl"][0],
1337
+ {
1338
+ lineHeight: fontSize["4xl"][1].lineHeight,
1339
+ letterSpacing: fontSize["4xl"][1].letterSpacing
1340
+ }
1341
+ ],
1342
+ "5xl": [
1343
+ fontSize["5xl"][0],
1344
+ {
1345
+ lineHeight: fontSize["5xl"][1].lineHeight,
1346
+ letterSpacing: fontSize["5xl"][1].letterSpacing
1347
+ }
1348
+ ],
1349
+ "6xl": [
1350
+ fontSize["6xl"][0],
1351
+ {
1352
+ lineHeight: fontSize["6xl"][1].lineHeight,
1353
+ letterSpacing: fontSize["6xl"][1].letterSpacing
1354
+ }
1355
+ ],
1356
+ "7xl": [
1357
+ fontSize["7xl"][0],
1358
+ {
1359
+ lineHeight: fontSize["7xl"][1].lineHeight,
1360
+ letterSpacing: fontSize["7xl"][1].letterSpacing
1361
+ }
1362
+ ],
1363
+ "8xl": [
1364
+ fontSize["8xl"][0],
1365
+ {
1366
+ lineHeight: fontSize["8xl"][1].lineHeight,
1367
+ letterSpacing: fontSize["8xl"][1].letterSpacing
1368
+ }
1369
+ ],
1370
+ "9xl": [
1371
+ fontSize["9xl"][0],
1372
+ {
1373
+ lineHeight: fontSize["9xl"][1].lineHeight,
1374
+ letterSpacing: fontSize["9xl"][1].letterSpacing
1375
+ }
1376
+ ]
1377
+ }});
1378
+
1379
+ // src/themes/minimal.ts
1380
+ var minimalBrand = {
1381
+ id: "minimal",
1382
+ name: "Minimal",
1383
+ description: "Clean, minimal brand theme with muted colors, light typography, and compact spacing",
1384
+ namespace: "minimal",
1385
+ version: "1.0.0",
1386
+ author: "Tenerife UI",
1387
+ themes: [
1388
+ {
1389
+ id: "minimal-day",
1390
+ name: "Minimal Day",
1391
+ description: "Light minimal theme with grayscale colors and subtle accents",
1392
+ mode: "day",
1393
+ overrides: {
1394
+ name: "minimal-day",
1395
+ description: "Light minimal theme for day mode",
1396
+ // Muted, low-saturation color overrides
1397
+ primaryColors: {
1398
+ 400: "0 0% 60%",
1399
+ // Muted gray
1400
+ 500: "0 0% 50%",
1401
+ // Neutral gray (#808080)
1402
+ 600: "0 0% 40%",
1403
+ 700: "0 0% 30%"
1404
+ },
1405
+ accentColors: {
1406
+ 400: "210 20% 70%",
1407
+ // Muted blue-gray
1408
+ 500: "210 20% 60%",
1409
+ // Subtle blue-gray
1410
+ 600: "210 20% 50%",
1411
+ 700: "210 20% 40%"
1412
+ },
1413
+ secondaryColors: {
1414
+ 400: "0 0% 70%",
1415
+ // Light gray
1416
+ 500: "0 0% 65%",
1417
+ // Neutral light gray
1418
+ 600: "0 0% 55%",
1419
+ 700: "0 0% 45%"
1420
+ },
1421
+ // Muted base colors for day mode
1422
+ baseColorsDay: {
1423
+ primary: "0 0% 50%",
1424
+ // Neutral gray
1425
+ primaryForeground: "0 0% 100%",
1426
+ secondary: "0 0% 96%",
1427
+ // Very light gray
1428
+ secondaryForeground: "0 0% 20%",
1429
+ accent: "210 20% 60%",
1430
+ // Subtle blue-gray
1431
+ accentForeground: "0 0% 100%"
1432
+ },
1433
+ // Subtle semantic colors
1434
+ semanticColorsDay: {
1435
+ success: "140 30% 45%",
1436
+ // Muted green
1437
+ info: "210 30% 50%",
1438
+ // Muted blue
1439
+ warning: "40 30% 50%",
1440
+ // Muted orange
1441
+ error: "0 40% 55%"
1442
+ // Muted red
1443
+ },
1444
+ // Typography overrides - lighter and smaller
1445
+ typography: {
1446
+ fontWeight: {
1447
+ normal: "400",
1448
+ // Normal weight
1449
+ medium: "500",
1450
+ semibold: "600",
1451
+ // Lighter than default
1452
+ bold: "700"
1453
+ // Standard bold
1454
+ },
1455
+ fontSize: {
1456
+ xs: [
1457
+ "clamp(0.6875rem, 0.65rem + 0.125vw, 0.75rem)",
1458
+ { lineHeight: "1rem", letterSpacing: "0.05em" }
1459
+ ],
1460
+ // Smaller
1461
+ sm: [
1462
+ "clamp(0.8125rem, 0.75rem + 0.25vw, 0.875rem)",
1463
+ { lineHeight: "1.25rem", letterSpacing: "0.025em" }
1464
+ ],
1465
+ // Smaller
1466
+ base: [
1467
+ "clamp(0.9375rem, 0.875rem + 0.25vw, 1rem)",
1468
+ { lineHeight: "1.5rem", letterSpacing: "0em" }
1469
+ ],
1470
+ // Smaller
1471
+ lg: [
1472
+ "clamp(1.0625rem, 0.95rem + 0.5vw, 1.125rem)",
1473
+ { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
1474
+ ],
1475
+ // Smaller
1476
+ xl: [
1477
+ "clamp(1.1875rem, 1rem + 0.75vw, 1.375rem)",
1478
+ { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
1479
+ ]
1480
+ // Smaller
1481
+ }
1482
+ },
1483
+ // Spacing overrides - compact spacing for tight layout
1484
+ spacing: {
1485
+ semanticSpacing: {
1486
+ xs: "0.125rem",
1487
+ // 2px (was 4px)
1488
+ sm: "0.25rem",
1489
+ // 4px (was 8px)
1490
+ md: "0.5rem",
1491
+ // 8px (was 16px)
1492
+ lg: "0.75rem",
1493
+ // 12px (was 24px)
1494
+ xl: "1rem",
1495
+ // 16px (was 32px)
1496
+ "2xl": "1.5rem"
1497
+ // 24px (was 48px)
1498
+ }
1499
+ },
1500
+ // Shadow overrides - subtle and minimal
1501
+ shadows: {
1502
+ elevationShadows: {
1503
+ xs: "0 1px 1px 0 rgb(0 0 0 / 0.03)",
1504
+ sm: "0 1px 2px 0 rgb(0 0 0 / 0.05), 0 1px 1px -1px rgb(0 0 0 / 0.05)",
1505
+ md: "0 2px 4px -1px rgb(0 0 0 / 0.05), 0 1px 2px -2px rgb(0 0 0 / 0.05)",
1506
+ lg: "0 4px 8px -2px rgb(0 0 0 / 0.05), 0 2px 4px -3px rgb(0 0 0 / 0.05)",
1507
+ xl: "0 8px 12px -3px rgb(0 0 0 / 0.05), 0 4px 6px -4px rgb(0 0 0 / 0.05)"
1508
+ },
1509
+ glowEffects: {
1510
+ "glow-primary": "0 0 8px 0 hsl(0 0% 50% / 0.2)",
1511
+ "glow-primary-subtle": "0 0 4px 0 hsl(0 0% 50% / 0.15)",
1512
+ "glow-primary-medium": "0 0 8px 0 hsl(0 0% 50% / 0.25)",
1513
+ "glow-primary-strong": "0 0 12px 0 hsl(0 0% 50% / 0.3)"
1514
+ }
1515
+ },
1516
+ // Radius overrides - smaller, sharper corners
1517
+ radius: {
1518
+ borderRadius: {
1519
+ xs: "0.0625rem",
1520
+ // 1px
1521
+ sm: "0.125rem",
1522
+ // 2px (was 4px)
1523
+ md: "0.1875rem",
1524
+ // 3px (was 6px)
1525
+ lg: "0.25rem",
1526
+ // 4px (was 8px)
1527
+ xl: "0.375rem",
1528
+ // 6px (was 12px)
1529
+ "2xl": "0.5rem"
1530
+ // 8px (was 16px)
1531
+ },
1532
+ componentRadius: {
1533
+ button: {
1534
+ sm: "0.125rem",
1535
+ // 2px
1536
+ md: "0.1875rem",
1537
+ // 3px
1538
+ lg: "0.25rem"
1539
+ // 4px
1540
+ },
1541
+ card: {
1542
+ sm: "0.1875rem",
1543
+ // 3px
1544
+ md: "0.25rem",
1545
+ // 4px
1546
+ lg: "0.375rem",
1547
+ // 6px
1548
+ xl: "0.5rem"
1549
+ // 8px
1550
+ },
1551
+ input: {
1552
+ sm: "0.125rem",
1553
+ // 2px
1554
+ md: "0.1875rem",
1555
+ // 3px
1556
+ lg: "0.25rem"
1557
+ // 4px
1558
+ },
1559
+ badge: {
1560
+ sm: "0.0625rem",
1561
+ // 1px
1562
+ md: "0.125rem",
1563
+ // 2px
1564
+ lg: "0.1875rem"
1565
+ // 3px
1566
+ }
1567
+ }
1568
+ }
1569
+ }
1570
+ },
1571
+ {
1572
+ id: "minimal-night",
1573
+ name: "Minimal Night",
1574
+ description: "Dark minimal theme with muted grayscale colors",
1575
+ mode: "night",
1576
+ overrides: {
1577
+ name: "minimal-night",
1578
+ description: "Dark minimal theme for night mode",
1579
+ // Muted colors for night mode (slightly lighter than day for contrast)
1580
+ primaryColors: {
1581
+ 400: "0 0% 65%",
1582
+ // Lighter gray for night
1583
+ 500: "0 0% 55%",
1584
+ // Neutral gray
1585
+ 600: "0 0% 45%",
1586
+ 700: "0 0% 35%"
1587
+ },
1588
+ accentColors: {
1589
+ 400: "210 20% 75%",
1590
+ // Lighter blue-gray
1591
+ 500: "210 20% 65%",
1592
+ // Subtle blue-gray
1593
+ 600: "210 20% 55%",
1594
+ 700: "210 20% 45%"
1595
+ },
1596
+ secondaryColors: {
1597
+ 400: "0 0% 75%",
1598
+ // Light gray
1599
+ 500: "0 0% 70%",
1600
+ // Neutral light gray
1601
+ 600: "0 0% 60%",
1602
+ 700: "0 0% 50%"
1603
+ },
1604
+ // Darker base colors for night mode
1605
+ baseColorsNight: {
1606
+ background: "240 10% 8%",
1607
+ // Dark gray background
1608
+ foreground: "0 0% 95%",
1609
+ card: "240 10% 10%",
1610
+ cardForeground: "0 0% 95%"
1611
+ },
1612
+ surfaceColorsNight: {
1613
+ base: "240 10% 8%",
1614
+ elevated1: "240 10% 10%",
1615
+ elevated2: "240 10% 12%",
1616
+ elevated3: "240 10% 14%"
1617
+ },
1618
+ // Subtle semantic colors for night
1619
+ semanticColorsNight: {
1620
+ success: "140 30% 50%",
1621
+ // Muted green
1622
+ info: "210 30% 55%",
1623
+ // Muted blue
1624
+ warning: "40 30% 55%",
1625
+ // Muted orange
1626
+ error: "0 40% 60%"
1627
+ // Muted red
1628
+ },
1629
+ // Typography overrides - same as day
1630
+ typography: {
1631
+ fontWeight: {
1632
+ normal: "400",
1633
+ medium: "500",
1634
+ semibold: "600",
1635
+ bold: "700"
1636
+ },
1637
+ fontSize: {
1638
+ xs: [
1639
+ "clamp(0.6875rem, 0.65rem + 0.125vw, 0.75rem)",
1640
+ { lineHeight: "1rem", letterSpacing: "0.05em" }
1641
+ ],
1642
+ sm: [
1643
+ "clamp(0.8125rem, 0.75rem + 0.25vw, 0.875rem)",
1644
+ { lineHeight: "1.25rem", letterSpacing: "0.025em" }
1645
+ ],
1646
+ base: [
1647
+ "clamp(0.9375rem, 0.875rem + 0.25vw, 1rem)",
1648
+ { lineHeight: "1.5rem", letterSpacing: "0em" }
1649
+ ],
1650
+ lg: [
1651
+ "clamp(1.0625rem, 0.95rem + 0.5vw, 1.125rem)",
1652
+ { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
1653
+ ],
1654
+ xl: [
1655
+ "clamp(1.1875rem, 1rem + 0.75vw, 1.375rem)",
1656
+ { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
1657
+ ]
1658
+ }
1659
+ },
1660
+ // Spacing overrides - same as day
1661
+ spacing: {
1662
+ semanticSpacing: {
1663
+ xs: "0.125rem",
1664
+ sm: "0.25rem",
1665
+ md: "0.5rem",
1666
+ lg: "0.75rem",
1667
+ xl: "1rem",
1668
+ "2xl": "1.5rem"
1669
+ }
1670
+ },
1671
+ // Shadow overrides - subtle for night
1672
+ shadows: {
1673
+ elevationShadows: {
1674
+ xs: "0 1px 2px 0 rgb(0 0 0 / 0.15)",
1675
+ sm: "0 1px 3px 0 rgb(0 0 0 / 0.2), 0 1px 2px -1px rgb(0 0 0 / 0.2)",
1676
+ md: "0 2px 5px -1px rgb(0 0 0 / 0.2), 0 1px 3px -2px rgb(0 0 0 / 0.2)",
1677
+ lg: "0 4px 10px -2px rgb(0 0 0 / 0.2), 0 2px 5px -3px rgb(0 0 0 / 0.2)",
1678
+ xl: "0 8px 15px -3px rgb(0 0 0 / 0.2), 0 4px 8px -4px rgb(0 0 0 / 0.2)"
1679
+ },
1680
+ glowEffects: {
1681
+ "glow-primary": "0 0 8px 0 hsl(0 0% 55% / 0.25)",
1682
+ "glow-primary-subtle": "0 0 4px 0 hsl(0 0% 55% / 0.2)",
1683
+ "glow-primary-medium": "0 0 8px 0 hsl(0 0% 55% / 0.3)",
1684
+ "glow-primary-strong": "0 0 12px 0 hsl(0 0% 55% / 0.35)"
1685
+ }
1686
+ },
1687
+ // Radius overrides - same as day
1688
+ radius: {
1689
+ borderRadius: {
1690
+ xs: "0.0625rem",
1691
+ sm: "0.125rem",
1692
+ md: "0.1875rem",
1693
+ lg: "0.25rem",
1694
+ xl: "0.375rem",
1695
+ "2xl": "0.5rem"
1696
+ },
1697
+ componentRadius: {
1698
+ button: {
1699
+ sm: "0.125rem",
1700
+ md: "0.1875rem",
1701
+ lg: "0.25rem"
1702
+ },
1703
+ card: {
1704
+ sm: "0.1875rem",
1705
+ md: "0.25rem",
1706
+ lg: "0.375rem",
1707
+ xl: "0.5rem"
1708
+ },
1709
+ input: {
1710
+ sm: "0.125rem",
1711
+ md: "0.1875rem",
1712
+ lg: "0.25rem"
1713
+ },
1714
+ badge: {
1715
+ sm: "0.0625rem",
1716
+ md: "0.125rem",
1717
+ lg: "0.1875rem"
1718
+ }
1719
+ }
1720
+ }
1721
+ }
1722
+ }
1723
+ ]
1724
+ };
1725
+
1726
+ // src/themes/neon.ts
1727
+ var neonBrand = {
1728
+ id: "neon",
1729
+ name: "Neon",
1730
+ description: "Vibrant brand theme with high-saturation neon colors, bold typography, and enhanced visual effects",
1731
+ namespace: "neon",
1732
+ version: "1.0.0",
1733
+ author: "Tenerife UI",
1734
+ themes: [
1735
+ {
1736
+ id: "neon-day",
1737
+ name: "Neon Day",
1738
+ description: "Bright neon theme for day mode with vibrant cyan, magenta, and yellow accents",
1739
+ mode: "day",
1740
+ overrides: {
1741
+ name: "neon-day",
1742
+ description: "Bright neon theme for day mode",
1743
+ // Vibrant neon color overrides
1744
+ primaryColors: {
1745
+ 400: "180 100% 50%",
1746
+ // Bright cyan
1747
+ 500: "180 100% 45%",
1748
+ // Vibrant cyan (#00e6ff)
1749
+ 600: "180 95% 40%",
1750
+ 700: "180 90% 35%"
1751
+ },
1752
+ accentColors: {
1753
+ 400: "320 100% 60%",
1754
+ // Bright magenta
1755
+ 500: "320 100% 55%",
1756
+ // Vibrant magenta (#ff00cc)
1757
+ 600: "320 95% 50%",
1758
+ 700: "320 90% 45%"
1759
+ },
1760
+ secondaryColors: {
1761
+ 400: "60 100% 60%",
1762
+ // Bright yellow
1763
+ 500: "60 100% 55%",
1764
+ // Vibrant yellow (#ffff00)
1765
+ 600: "60 95% 50%",
1766
+ 700: "60 90% 45%"
1767
+ },
1768
+ // Enhanced base colors for day mode
1769
+ baseColorsDay: {
1770
+ primary: "180 100% 45%",
1771
+ // Neon cyan
1772
+ primaryForeground: "0 0% 100%",
1773
+ accent: "320 100% 55%",
1774
+ // Neon magenta
1775
+ accentForeground: "0 0% 100%"
1776
+ },
1777
+ // Semantic colors with neon accents
1778
+ semanticColorsDay: {
1779
+ success: "145 80% 45%",
1780
+ // Neon green
1781
+ info: "180 100% 45%",
1782
+ // Neon cyan
1783
+ warning: "60 100% 55%",
1784
+ // Neon yellow
1785
+ error: "0 100% 60%"
1786
+ // Bright red
1787
+ },
1788
+ // Typography overrides - bolder and larger
1789
+ typography: {
1790
+ fontWeight: {
1791
+ normal: "500",
1792
+ // Heavier than default (400)
1793
+ medium: "600",
1794
+ // Heavier
1795
+ semibold: "700",
1796
+ // Bold
1797
+ bold: "800"
1798
+ // Extra bold
1799
+ },
1800
+ fontSize: {
1801
+ xs: [
1802
+ "clamp(0.875rem, 0.8rem + 0.25vw, 1rem)",
1803
+ { lineHeight: "1.25rem", letterSpacing: "0.025em" }
1804
+ ],
1805
+ // Larger than default
1806
+ sm: [
1807
+ "clamp(1rem, 0.95rem + 0.25vw, 1.125rem)",
1808
+ { lineHeight: "1.5rem", letterSpacing: "0em" }
1809
+ ],
1810
+ // Larger
1811
+ base: [
1812
+ "clamp(1.125rem, 1rem + 0.5vw, 1.25rem)",
1813
+ { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
1814
+ ],
1815
+ // Larger
1816
+ lg: [
1817
+ "clamp(1.25rem, 1.1rem + 0.75vw, 1.5rem)",
1818
+ { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
1819
+ ],
1820
+ // Larger
1821
+ xl: [
1822
+ "clamp(1.5rem, 1.25rem + 1.25vw, 2rem)",
1823
+ { lineHeight: "2rem", letterSpacing: "-0.05em" }
1824
+ ]
1825
+ // Larger
1826
+ }
1827
+ },
1828
+ // Spacing overrides - larger spacing for breathing room
1829
+ spacing: {
1830
+ semanticSpacing: {
1831
+ xs: "0.5rem",
1832
+ // 8px (was 4px)
1833
+ sm: "1rem",
1834
+ // 16px (was 8px)
1835
+ md: "1.5rem",
1836
+ // 24px (was 16px)
1837
+ lg: "2rem",
1838
+ // 32px (was 24px)
1839
+ xl: "3rem",
1840
+ // 48px (was 32px)
1841
+ "2xl": "4rem"
1842
+ // 64px (was 48px)
1843
+ }
1844
+ },
1845
+ // Shadow overrides - stronger and more prominent
1846
+ shadows: {
1847
+ elevationShadows: {
1848
+ xs: "0 2px 4px 0 rgb(0 0 0 / 0.1)",
1849
+ sm: "0 2px 6px 0 rgb(0 0 0 / 0.15), 0 2px 4px -1px rgb(0 0 0 / 0.15)",
1850
+ md: "0 6px 10px -1px rgb(0 0 0 / 0.15), 0 4px 6px -2px rgb(0 0 0 / 0.15)",
1851
+ lg: "0 12px 20px -3px rgb(0 0 0 / 0.15), 0 6px 10px -4px rgb(0 0 0 / 0.15)",
1852
+ xl: "0 24px 32px -5px rgb(0 0 0 / 0.15), 0 10px 14px -6px rgb(0 0 0 / 0.15)"
1853
+ },
1854
+ glowEffects: {
1855
+ "glow-primary": "0 0 30px 0 hsl(180 100% 45% / 0.7), 0 0 60px 0 hsl(180 100% 45% / 0.4)",
1856
+ "glow-primary-subtle": "0 0 12px 0 hsl(180 100% 45% / 0.5)",
1857
+ "glow-primary-medium": "0 0 24px 0 hsl(180 100% 45% / 0.7)",
1858
+ "glow-primary-strong": "0 0 36px 0 hsl(180 100% 45% / 0.8)",
1859
+ "glow-accent": "0 0 30px 0 hsl(320 100% 55% / 0.7), 0 0 60px 0 hsl(320 100% 55% / 0.4)",
1860
+ "glow-accent-subtle": "0 0 12px 0 hsl(320 100% 55% / 0.5)",
1861
+ "glow-accent-medium": "0 0 24px 0 hsl(320 100% 55% / 0.7)",
1862
+ "glow-accent-strong": "0 0 36px 0 hsl(320 100% 55% / 0.8)"
1863
+ }
1864
+ },
1865
+ // Radius overrides - more rounded corners
1866
+ radius: {
1867
+ borderRadius: {
1868
+ sm: "0.375rem",
1869
+ // 6px (was 4px)
1870
+ md: "0.5rem",
1871
+ // 8px (was 6px)
1872
+ lg: "0.75rem",
1873
+ // 12px (was 8px)
1874
+ xl: "1rem",
1875
+ // 16px (was 12px)
1876
+ "2xl": "1.5rem",
1877
+ // 24px (was 16px)
1878
+ "3xl": "2rem"
1879
+ // 32px (was 24px)
1880
+ },
1881
+ componentRadius: {
1882
+ button: {
1883
+ sm: "0.5rem",
1884
+ // 8px
1885
+ md: "0.75rem",
1886
+ // 12px
1887
+ lg: "1rem"
1888
+ // 16px
1889
+ },
1890
+ card: {
1891
+ sm: "0.75rem",
1892
+ // 12px
1893
+ md: "1rem",
1894
+ // 16px
1895
+ lg: "1.25rem",
1896
+ // 20px
1897
+ xl: "1.5rem"
1898
+ // 24px
1899
+ },
1900
+ input: {
1901
+ sm: "0.5rem",
1902
+ // 8px
1903
+ md: "0.75rem",
1904
+ // 12px
1905
+ lg: "1rem"
1906
+ // 16px
1907
+ },
1908
+ badge: {
1909
+ sm: "0.375rem",
1910
+ // 6px
1911
+ md: "0.5rem",
1912
+ // 8px
1913
+ lg: "0.75rem"
1914
+ // 12px
1915
+ }
1916
+ }
1917
+ }
1918
+ }
1919
+ },
1920
+ {
1921
+ id: "neon-night",
1922
+ name: "Neon Night",
1923
+ description: "Dark neon theme for night mode with glowing neon accents on dark backgrounds",
1924
+ mode: "night",
1925
+ overrides: {
1926
+ name: "neon-night",
1927
+ description: "Dark neon theme for night mode",
1928
+ // Vibrant neon color overrides (same as day but with different base)
1929
+ primaryColors: {
1930
+ 400: "180 100% 55%",
1931
+ // Brighter cyan for night
1932
+ 500: "180 100% 50%",
1933
+ // Vibrant cyan
1934
+ 600: "180 95% 45%",
1935
+ 700: "180 90% 40%"
1936
+ },
1937
+ accentColors: {
1938
+ 400: "320 100% 65%",
1939
+ // Brighter magenta for night
1940
+ 500: "320 100% 60%",
1941
+ // Vibrant magenta
1942
+ 600: "320 95% 55%",
1943
+ 700: "320 90% 50%"
1944
+ },
1945
+ secondaryColors: {
1946
+ 400: "60 100% 65%",
1947
+ // Brighter yellow for night
1948
+ 500: "60 100% 60%",
1949
+ // Vibrant yellow
1950
+ 600: "60 95% 55%",
1951
+ 700: "60 90% 50%"
1952
+ },
1953
+ // Darker base colors for night mode
1954
+ baseColorsNight: {
1955
+ background: "240 10% 5%",
1956
+ // Very dark background
1957
+ foreground: "0 0% 98%",
1958
+ card: "240 10% 6%",
1959
+ cardForeground: "0 0% 98%"
1960
+ },
1961
+ surfaceColorsNight: {
1962
+ base: "240 10% 5%",
1963
+ // Very dark
1964
+ elevated1: "240 10% 7%",
1965
+ elevated2: "240 10% 9%",
1966
+ elevated3: "240 10% 11%"
1967
+ },
1968
+ // Semantic colors with neon accents for night
1969
+ semanticColorsNight: {
1970
+ success: "145 75% 50%",
1971
+ // Neon green
1972
+ info: "180 100% 50%",
1973
+ // Neon cyan
1974
+ warning: "60 100% 60%",
1975
+ // Neon yellow
1976
+ error: "0 100% 65%"
1977
+ // Bright red
1978
+ },
1979
+ // Typography overrides - same as day
1980
+ typography: {
1981
+ fontWeight: {
1982
+ normal: "500",
1983
+ medium: "600",
1984
+ semibold: "700",
1985
+ bold: "800"
1986
+ },
1987
+ fontSize: {
1988
+ xs: [
1989
+ "clamp(0.875rem, 0.8rem + 0.25vw, 1rem)",
1990
+ { lineHeight: "1.25rem", letterSpacing: "0.025em" }
1991
+ ],
1992
+ sm: [
1993
+ "clamp(1rem, 0.95rem + 0.25vw, 1.125rem)",
1994
+ { lineHeight: "1.5rem", letterSpacing: "0em" }
1995
+ ],
1996
+ base: [
1997
+ "clamp(1.125rem, 1rem + 0.5vw, 1.25rem)",
1998
+ { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
1999
+ ],
2000
+ lg: [
2001
+ "clamp(1.25rem, 1.1rem + 0.75vw, 1.5rem)",
2002
+ { lineHeight: "1.75rem", letterSpacing: "-0.025em" }
2003
+ ],
2004
+ xl: [
2005
+ "clamp(1.5rem, 1.25rem + 1.25vw, 2rem)",
2006
+ { lineHeight: "2rem", letterSpacing: "-0.05em" }
2007
+ ]
2008
+ }
2009
+ },
2010
+ // Spacing overrides - same as day
2011
+ spacing: {
2012
+ semanticSpacing: {
2013
+ xs: "0.5rem",
2014
+ sm: "1rem",
2015
+ md: "1.5rem",
2016
+ lg: "2rem",
2017
+ xl: "3rem",
2018
+ "2xl": "4rem"
2019
+ }
2020
+ },
2021
+ // Shadow overrides - even stronger glow for night
2022
+ shadows: {
2023
+ elevationShadows: {
2024
+ xs: "0 2px 4px 0 rgb(0 0 0 / 0.2)",
2025
+ sm: "0 2px 6px 0 rgb(0 0 0 / 0.25), 0 2px 4px -1px rgb(0 0 0 / 0.25)",
2026
+ md: "0 6px 10px -1px rgb(0 0 0 / 0.25), 0 4px 6px -2px rgb(0 0 0 / 0.25)",
2027
+ lg: "0 12px 20px -3px rgb(0 0 0 / 0.25), 0 6px 10px -4px rgb(0 0 0 / 0.25)",
2028
+ xl: "0 24px 32px -5px rgb(0 0 0 / 0.25), 0 10px 14px -6px rgb(0 0 0 / 0.25)"
2029
+ },
2030
+ glowEffects: {
2031
+ "glow-primary": "0 0 40px 0 hsl(180 100% 50% / 0.8), 0 0 80px 0 hsl(180 100% 50% / 0.5)",
2032
+ "glow-primary-subtle": "0 0 16px 0 hsl(180 100% 50% / 0.6)",
2033
+ "glow-primary-medium": "0 0 32px 0 hsl(180 100% 50% / 0.8)",
2034
+ "glow-primary-strong": "0 0 48px 0 hsl(180 100% 50% / 0.9)",
2035
+ "glow-accent": "0 0 40px 0 hsl(320 100% 60% / 0.8), 0 0 80px 0 hsl(320 100% 60% / 0.5)",
2036
+ "glow-accent-subtle": "0 0 16px 0 hsl(320 100% 60% / 0.6)",
2037
+ "glow-accent-medium": "0 0 32px 0 hsl(320 100% 60% / 0.8)",
2038
+ "glow-accent-strong": "0 0 48px 0 hsl(320 100% 60% / 0.9)"
2039
+ }
2040
+ },
2041
+ // Radius overrides - same as day
2042
+ radius: {
2043
+ borderRadius: {
2044
+ sm: "0.375rem",
2045
+ md: "0.5rem",
2046
+ lg: "0.75rem",
2047
+ xl: "1rem",
2048
+ "2xl": "1.5rem",
2049
+ "3xl": "2rem"
2050
+ },
2051
+ componentRadius: {
2052
+ button: {
2053
+ sm: "0.5rem",
2054
+ md: "0.75rem",
2055
+ lg: "1rem"
2056
+ },
2057
+ card: {
2058
+ sm: "0.75rem",
2059
+ md: "1rem",
2060
+ lg: "1.25rem",
2061
+ xl: "1.5rem"
2062
+ },
2063
+ input: {
2064
+ sm: "0.5rem",
2065
+ md: "0.75rem",
2066
+ lg: "1rem"
2067
+ },
2068
+ badge: {
2069
+ sm: "0.375rem",
2070
+ md: "0.5rem",
2071
+ lg: "0.75rem"
2072
+ }
2073
+ }
2074
+ }
2075
+ }
2076
+ }
2077
+ ]
2325
2078
  };
2326
- ({
2327
- // Display styles (for hero sections)
2328
- display: {
2329
- fontSize: fontSize["6xl"][0]},
2330
- // Heading styles
2331
- h1: {
2332
- fontSize: fontSize["5xl"][0]},
2333
- h2: {
2334
- fontSize: fontSize["4xl"][0]},
2335
- h3: {
2336
- fontSize: fontSize["3xl"][0]},
2337
- h4: {
2338
- fontSize: fontSize["2xl"][0]},
2339
- h5: {
2340
- fontSize: fontSize.xl[0]},
2341
- h6: {
2342
- fontSize: fontSize.lg[0]},
2343
- // Body text styles
2344
- body: {
2345
- fontSize: fontSize.base[0]},
2346
- "body-sm": {
2347
- fontSize: fontSize.sm[0]},
2348
- "body-xs": {
2349
- fontSize: fontSize.xs[0]},
2350
- // Label styles
2351
- label: {
2352
- fontSize: fontSize.sm[0]},
2353
- "label-sm": {
2354
- fontSize: fontSize.xs[0]},
2355
- // Caption styles
2356
- caption: {
2357
- fontSize: fontSize.xs[0]}
2358
- });
2359
- ({
2360
- fontSize: {
2361
- xs: [
2362
- fontSize.xs[0],
2363
- { lineHeight: fontSize.xs[1].lineHeight, letterSpacing: fontSize.xs[1].letterSpacing }
2364
- ],
2365
- sm: [
2366
- fontSize.sm[0],
2367
- { lineHeight: fontSize.sm[1].lineHeight, letterSpacing: fontSize.sm[1].letterSpacing }
2368
- ],
2369
- md: [
2370
- fontSize.base[0],
2371
- { lineHeight: fontSize.base[1].lineHeight, letterSpacing: fontSize.base[1].letterSpacing }
2372
- ],
2373
- base: [
2374
- fontSize.base[0],
2375
- { lineHeight: fontSize.base[1].lineHeight, letterSpacing: fontSize.base[1].letterSpacing }
2376
- ],
2377
- lg: [
2378
- fontSize.lg[0],
2379
- { lineHeight: fontSize.lg[1].lineHeight, letterSpacing: fontSize.lg[1].letterSpacing }
2380
- ],
2381
- xl: [
2382
- fontSize.xl[0],
2383
- { lineHeight: fontSize.xl[1].lineHeight, letterSpacing: fontSize.xl[1].letterSpacing }
2384
- ],
2385
- "2xl": [
2386
- fontSize["2xl"][0],
2387
- {
2388
- lineHeight: fontSize["2xl"][1].lineHeight,
2389
- letterSpacing: fontSize["2xl"][1].letterSpacing
2079
+
2080
+ // src/themes/brand_engine.ts
2081
+ var brandRegistry = /* @__PURE__ */ new Map();
2082
+ var activeBrand = null;
2083
+ var activeNamespace = null;
2084
+ var brandCache = /* @__PURE__ */ new Map();
2085
+ function validateBrand(brand) {
2086
+ const errors = [];
2087
+ const warnings = [];
2088
+ if (!brand || typeof brand !== "object") {
2089
+ return {
2090
+ valid: false,
2091
+ errors: ["Brand must be an object"],
2092
+ warnings: []
2093
+ };
2094
+ }
2095
+ const brandObj = brand;
2096
+ const requiredFields = ["id", "name", "namespace"];
2097
+ for (const field of requiredFields) {
2098
+ if (!(field in brandObj) || !brandObj[field]) {
2099
+ errors.push(`Missing required field: ${field}`);
2100
+ }
2101
+ }
2102
+ if (brandObj.id && typeof brandObj.id === "string") {
2103
+ const idRegex = /^[a-z0-9]+(?:-[a-z0-9]+)*$/;
2104
+ if (!idRegex.test(brandObj.id)) {
2105
+ errors.push(
2106
+ `Invalid brand ID format: "${brandObj.id}". Must be kebab-case (e.g., "neon-brand")`
2107
+ );
2108
+ }
2109
+ }
2110
+ if (brandObj.namespace && typeof brandObj.namespace === "string") {
2111
+ const namespaceRegex = /^[a-z0-9]+(?:-[a-z0-9]+)*$/;
2112
+ if (!namespaceRegex.test(brandObj.namespace)) {
2113
+ errors.push(
2114
+ `Invalid namespace format: "${brandObj.namespace}". Must be kebab-case (e.g., "neon")`
2115
+ );
2116
+ }
2117
+ }
2118
+ if (brandObj.themes) {
2119
+ if (!Array.isArray(brandObj.themes)) {
2120
+ errors.push("Brand themes must be an array");
2121
+ } else {
2122
+ const themes2 = brandObj.themes;
2123
+ if (themes2.length === 0) {
2124
+ warnings.push("Brand has no themes defined");
2125
+ }
2126
+ themes2.forEach((theme, index) => {
2127
+ if (!theme || typeof theme !== "object") {
2128
+ errors.push(`Theme at index ${index} must be an object`);
2129
+ return;
2130
+ }
2131
+ const themeObj = theme;
2132
+ if (!themeObj.id || typeof themeObj.id !== "string") {
2133
+ errors.push(`Theme at index ${index} is missing required field: id`);
2134
+ }
2135
+ if (!themeObj.name || typeof themeObj.name !== "string") {
2136
+ errors.push(`Theme at index ${index} is missing required field: name`);
2137
+ }
2138
+ if (!themeObj.mode || !["day", "night"].includes(themeObj.mode)) {
2139
+ errors.push(`Theme at index ${index} must have mode set to "day" or "night"`);
2140
+ }
2141
+ if (!themeObj.overrides || typeof themeObj.overrides !== "object") {
2142
+ errors.push(`Theme at index ${index} is missing required field: overrides`);
2143
+ }
2144
+ });
2145
+ }
2146
+ } else {
2147
+ errors.push("Brand must have at least one theme");
2148
+ }
2149
+ if (brandObj.version && typeof brandObj.version === "string") {
2150
+ const semverRegex = /^\d+\.\d+\.\d+$/;
2151
+ if (!semverRegex.test(brandObj.version)) {
2152
+ warnings.push(
2153
+ `Invalid version format: "${brandObj.version}". Should be semver (e.g., "1.0.0")`
2154
+ );
2155
+ }
2156
+ }
2157
+ if (brandObj.themes && Array.isArray(brandObj.themes)) {
2158
+ const themeIds = brandObj.themes.map(
2159
+ (theme) => theme?.id
2160
+ );
2161
+ const uniqueIds = new Set(themeIds);
2162
+ if (themeIds.length !== uniqueIds.size) {
2163
+ errors.push("Brand contains duplicate theme IDs");
2164
+ }
2165
+ }
2166
+ return {
2167
+ valid: errors.length === 0,
2168
+ errors,
2169
+ warnings
2170
+ };
2171
+ }
2172
+ function registerBrand(brand, options) {
2173
+ const validation = validateBrand(brand);
2174
+ if (!validation.valid) {
2175
+ throw new Error(`Invalid brand "${brand.id}": ${validation.errors.join(", ")}`);
2176
+ }
2177
+ if (validation.warnings.length > 0) {
2178
+ console.warn(`Brand "${brand.id}" validation warnings:`, validation.warnings.join(", "));
2179
+ }
2180
+ const existingEntry = brandRegistry.get(brand.id);
2181
+ if (existingEntry && existingEntry.brand.namespace === brand.namespace) {
2182
+ return;
2183
+ }
2184
+ if (brandRegistry.has(brand.id)) {
2185
+ throw new Error(`Brand "${brand.id}" is already registered`);
2186
+ }
2187
+ const existingBrand = Array.from(brandRegistry.values()).find(
2188
+ (entry) => entry.brand.namespace === brand.namespace
2189
+ );
2190
+ if (existingBrand) {
2191
+ throw new Error(
2192
+ `Brand namespace "${brand.namespace}" is already used by brand "${existingBrand.brand.id}"`
2193
+ );
2194
+ }
2195
+ brandRegistry.set(brand.id, {
2196
+ brand,
2197
+ enabled: options?.enabled !== false,
2198
+ loader: options?.loader
2199
+ });
2200
+ }
2201
+ async function loadBrand(brandId) {
2202
+ if (brandCache.has(brandId)) {
2203
+ return brandCache.get(brandId);
2204
+ }
2205
+ const entry = brandRegistry.get(brandId);
2206
+ if (!entry) {
2207
+ throw new Error(`Brand "${brandId}" not found in registry`);
2208
+ }
2209
+ if (entry.enabled === false) {
2210
+ throw new Error(`Brand "${brandId}" is disabled`);
2211
+ }
2212
+ if (entry.loader) {
2213
+ try {
2214
+ const module = await entry.loader();
2215
+ const loadedBrand = module.default;
2216
+ const validation = validateBrand(loadedBrand);
2217
+ if (!validation.valid) {
2218
+ throw new Error(`Invalid loaded brand "${brandId}": ${validation.errors.join(", ")}`);
2219
+ }
2220
+ brandCache.set(brandId, loadedBrand);
2221
+ return loadedBrand;
2222
+ } catch (error) {
2223
+ throw new Error(
2224
+ `Failed to load brand "${brandId}": ${error instanceof Error ? error.message : String(error)}`
2225
+ );
2226
+ }
2227
+ }
2228
+ brandCache.set(brandId, entry.brand);
2229
+ return entry.brand;
2230
+ }
2231
+ function getActiveBrand() {
2232
+ return activeBrand;
2233
+ }
2234
+ function setActiveBrand(brand) {
2235
+ activeBrand = brand;
2236
+ activeNamespace = brand?.namespace || null;
2237
+ }
2238
+ function clearActiveBrand() {
2239
+ activeBrand = null;
2240
+ activeNamespace = null;
2241
+ }
2242
+ function getBrandTheme(brand, mode) {
2243
+ return brand.themes.find((theme) => theme.mode === mode);
2244
+ }
2245
+ function applyBrandOverrides(brand, mode) {
2246
+ if (typeof document === "undefined") return;
2247
+ const theme = getBrandTheme(brand, mode);
2248
+ if (!theme) {
2249
+ console.warn(`Brand "${brand.id}" has no theme for mode "${mode}"`);
2250
+ return;
2251
+ }
2252
+ const root = document.documentElement;
2253
+ const { namespace } = brand;
2254
+ const { overrides } = theme;
2255
+ if (overrides.primaryColors) {
2256
+ Object.entries(overrides.primaryColors).forEach(([key, value]) => {
2257
+ root.style.setProperty(`--brand-${namespace}-primary-${key}`, value);
2258
+ });
2259
+ }
2260
+ if (overrides.accentColors) {
2261
+ Object.entries(overrides.accentColors).forEach(([key, value]) => {
2262
+ root.style.setProperty(`--brand-${namespace}-accent-${key}`, value);
2263
+ });
2264
+ }
2265
+ if (overrides.secondaryColors) {
2266
+ Object.entries(overrides.secondaryColors).forEach(([key, value]) => {
2267
+ root.style.setProperty(`--brand-${namespace}-secondary-${key}`, value);
2268
+ });
2269
+ }
2270
+ const modeColors = mode === "day" ? overrides.baseColorsDay : overrides.baseColorsNight;
2271
+ if (modeColors) {
2272
+ Object.entries(modeColors).forEach(([key, value]) => {
2273
+ root.style.setProperty(`--brand-${namespace}-${key}`, value);
2274
+ });
2275
+ }
2276
+ if (overrides.typography) {
2277
+ if (overrides.typography.fontFamily) {
2278
+ Object.entries(overrides.typography.fontFamily).forEach(([key, value]) => {
2279
+ root.style.setProperty(
2280
+ `--brand-${namespace}-font-${key}`,
2281
+ Array.isArray(value) ? value.join(", ") : value
2282
+ );
2283
+ });
2284
+ }
2285
+ if (overrides.typography.fontSize) {
2286
+ Object.entries(overrides.typography.fontSize).forEach(([key, value]) => {
2287
+ const fontSizeValue = typeof value === "string" ? value : value[0];
2288
+ root.style.setProperty(`--brand-${namespace}-font-size-${key}`, fontSizeValue);
2289
+ });
2290
+ }
2291
+ if (overrides.typography.fontWeight) {
2292
+ Object.entries(overrides.typography.fontWeight).forEach(([key, value]) => {
2293
+ root.style.setProperty(`--brand-${namespace}-font-weight-${key}`, value);
2294
+ });
2295
+ }
2296
+ if (overrides.typography.lineHeight) {
2297
+ Object.entries(overrides.typography.lineHeight).forEach(([key, value]) => {
2298
+ root.style.setProperty(`--brand-${namespace}-line-height-${key}`, value);
2299
+ });
2300
+ }
2301
+ if (overrides.typography.letterSpacing) {
2302
+ Object.entries(overrides.typography.letterSpacing).forEach(([key, value]) => {
2303
+ root.style.setProperty(`--brand-${namespace}-letter-spacing-${key}`, value);
2304
+ });
2305
+ }
2306
+ }
2307
+ if (overrides.spacing) {
2308
+ if (overrides.spacing.semanticSpacing) {
2309
+ Object.entries(overrides.spacing.semanticSpacing).forEach(([key, value]) => {
2310
+ root.style.setProperty(`--brand-${namespace}-spacing-${key}`, value);
2311
+ });
2312
+ }
2313
+ if (overrides.spacing.layoutSpacing) {
2314
+ const layout = overrides.spacing.layoutSpacing;
2315
+ if (layout.section) {
2316
+ Object.entries(layout.section).forEach(([key, value]) => {
2317
+ if (typeof value === "string") {
2318
+ root.style.setProperty(`--brand-${namespace}-layout-section-${key}`, value);
2319
+ }
2320
+ });
2390
2321
  }
2391
- ],
2392
- "3xl": [
2393
- fontSize["3xl"][0],
2394
- {
2395
- lineHeight: fontSize["3xl"][1].lineHeight,
2396
- letterSpacing: fontSize["3xl"][1].letterSpacing
2322
+ if (layout.container) {
2323
+ Object.entries(layout.container).forEach(([key, value]) => {
2324
+ if (typeof value === "string") {
2325
+ root.style.setProperty(`--brand-${namespace}-layout-container-${key}`, value);
2326
+ }
2327
+ });
2397
2328
  }
2398
- ],
2399
- "4xl": [
2400
- fontSize["4xl"][0],
2401
- {
2402
- lineHeight: fontSize["4xl"][1].lineHeight,
2403
- letterSpacing: fontSize["4xl"][1].letterSpacing
2329
+ if (layout.grid) {
2330
+ Object.entries(layout.grid).forEach(([key, value]) => {
2331
+ if (typeof value === "string") {
2332
+ root.style.setProperty(`--brand-${namespace}-layout-grid-${key}`, value);
2333
+ }
2334
+ });
2404
2335
  }
2405
- ],
2406
- "5xl": [
2407
- fontSize["5xl"][0],
2408
- {
2409
- lineHeight: fontSize["5xl"][1].lineHeight,
2410
- letterSpacing: fontSize["5xl"][1].letterSpacing
2336
+ if (layout.stack) {
2337
+ Object.entries(layout.stack).forEach(([key, value]) => {
2338
+ if (typeof value === "string") {
2339
+ root.style.setProperty(`--brand-${namespace}-layout-stack-${key}`, value);
2340
+ }
2341
+ });
2411
2342
  }
2412
- ],
2413
- "6xl": [
2414
- fontSize["6xl"][0],
2415
- {
2416
- lineHeight: fontSize["6xl"][1].lineHeight,
2417
- letterSpacing: fontSize["6xl"][1].letterSpacing
2343
+ if (layout.component) {
2344
+ Object.entries(layout.component).forEach(([key, value]) => {
2345
+ if (typeof value === "string") {
2346
+ root.style.setProperty(`--brand-${namespace}-layout-component-${key}`, value);
2347
+ }
2348
+ });
2418
2349
  }
2419
- ],
2420
- "7xl": [
2421
- fontSize["7xl"][0],
2422
- {
2423
- lineHeight: fontSize["7xl"][1].lineHeight,
2424
- letterSpacing: fontSize["7xl"][1].letterSpacing
2350
+ }
2351
+ }
2352
+ if (overrides.shadows) {
2353
+ if (overrides.shadows.elevationShadows) {
2354
+ Object.entries(overrides.shadows.elevationShadows).forEach(([key, value]) => {
2355
+ root.style.setProperty(`--brand-${namespace}-shadow-${key}`, value);
2356
+ });
2357
+ }
2358
+ if (overrides.shadows.primaryColoredShadows) {
2359
+ Object.entries(overrides.shadows.primaryColoredShadows).forEach(([key, value]) => {
2360
+ root.style.setProperty(`--brand-${namespace}-shadow-primary-${key}`, value);
2361
+ });
2362
+ }
2363
+ if (overrides.shadows.accentColoredShadows) {
2364
+ Object.entries(overrides.shadows.accentColoredShadows).forEach(([key, value]) => {
2365
+ root.style.setProperty(`--brand-${namespace}-shadow-accent-${key}`, value);
2366
+ });
2367
+ }
2368
+ if (overrides.shadows.glowEffects) {
2369
+ Object.entries(overrides.shadows.glowEffects).forEach(([key, value]) => {
2370
+ root.style.setProperty(`--brand-${namespace}-glow-${key}`, value);
2371
+ });
2372
+ }
2373
+ if (overrides.shadows.focusRings) {
2374
+ Object.entries(overrides.shadows.focusRings).forEach(([key, value]) => {
2375
+ root.style.setProperty(`--brand-${namespace}-focus-ring-${key}`, value);
2376
+ });
2377
+ }
2378
+ }
2379
+ if (overrides.radius) {
2380
+ if (overrides.radius.borderRadius) {
2381
+ Object.entries(overrides.radius.borderRadius).forEach(([key, value]) => {
2382
+ root.style.setProperty(`--brand-${namespace}-radius-${key}`, value);
2383
+ });
2384
+ }
2385
+ if (overrides.radius.componentRadius) {
2386
+ const { componentRadius: componentRadius2 } = overrides.radius;
2387
+ if (componentRadius2.button) {
2388
+ Object.entries(componentRadius2.button).forEach(([key, value]) => {
2389
+ root.style.setProperty(`--brand-${namespace}-radius-button-${key}`, value);
2390
+ });
2425
2391
  }
2426
- ],
2427
- "8xl": [
2428
- fontSize["8xl"][0],
2429
- {
2430
- lineHeight: fontSize["8xl"][1].lineHeight,
2431
- letterSpacing: fontSize["8xl"][1].letterSpacing
2392
+ if (componentRadius2.card) {
2393
+ Object.entries(componentRadius2.card).forEach(([key, value]) => {
2394
+ root.style.setProperty(`--brand-${namespace}-radius-card-${key}`, value);
2395
+ });
2432
2396
  }
2433
- ],
2434
- "9xl": [
2435
- fontSize["9xl"][0],
2436
- {
2437
- lineHeight: fontSize["9xl"][1].lineHeight,
2438
- letterSpacing: fontSize["9xl"][1].letterSpacing
2397
+ if (componentRadius2.input) {
2398
+ Object.entries(componentRadius2.input).forEach(([key, value]) => {
2399
+ root.style.setProperty(`--brand-${namespace}-radius-input-${key}`, value);
2400
+ });
2439
2401
  }
2440
- ]
2441
- }});
2402
+ }
2403
+ }
2404
+ setActiveBrand(brand);
2405
+ root.setAttribute("data-brand", brand.id);
2406
+ root.setAttribute("data-brand-namespace", namespace);
2407
+ }
2408
+ function removeBrandOverrides(namespace) {
2409
+ if (typeof document === "undefined") return;
2410
+ const root = document.documentElement;
2411
+ const { style } = root;
2412
+ const propsToRemove = [];
2413
+ for (let i = 0; i < style.length; i++) {
2414
+ const prop = style.item(i);
2415
+ if (prop && prop.startsWith(`--brand-${namespace}-`)) {
2416
+ propsToRemove.push(prop);
2417
+ }
2418
+ }
2419
+ propsToRemove.forEach((prop) => {
2420
+ style.removeProperty(prop);
2421
+ });
2422
+ root.removeAttribute("data-brand");
2423
+ root.removeAttribute("data-brand-namespace");
2424
+ if (activeNamespace === namespace) {
2425
+ clearActiveBrand();
2426
+ }
2427
+ }
2428
+
2429
+ // src/themes/index.ts
2430
+ var themes = {
2431
+ default: () => Promise.resolve().then(() => (init_default(), default_exports)).then((m) => m.defaultTheme),
2432
+ dark: () => Promise.resolve().then(() => (init_dark(), dark_exports)).then((m) => m.darkTheme),
2433
+ brand: () => Promise.resolve().then(() => (init_brand(), brand_exports)).then((m) => m.brandTheme)
2434
+ };
2435
+ async function getTheme(name) {
2436
+ const themeLoader = themes[name];
2437
+ if (!themeLoader) {
2438
+ throw new Error(`Theme "${name}" not found`);
2439
+ }
2440
+ return await themeLoader();
2441
+ }
2442
2442
 
2443
- // src/tokens/state-matrix.ts
2443
+ // src/FOUNDATION/tokens/state-matrix.ts
2444
2444
  function getStateVariableName(component, variant, state, property) {
2445
2445
  const propertyMap = {
2446
2446
  background: "bg",
@@ -2476,7 +2476,7 @@ function flattenStateMatrix(stateMatrix) {
2476
2476
  return variables;
2477
2477
  }
2478
2478
 
2479
- // src/tokens/states.ts
2479
+ // src/FOUNDATION/tokens/states.ts
2480
2480
  function getButtonStateMatrix(mode, baseColors2, surfaceColors2) {
2481
2481
  const primaryBase = primaryColors[600];
2482
2482
  const primaryHover = primaryColors[700];
@@ -2606,7 +2606,7 @@ function getButtonStateMatrix(mode, baseColors2, surfaceColors2) {
2606
2606
  };
2607
2607
  }
2608
2608
 
2609
- // src/theme/applyStateMatrix.ts
2609
+ // src/FOUNDATION/theme/applyStateMatrix.ts
2610
2610
  function getMergedBaseTokens(_mode) {
2611
2611
  return {
2612
2612
  baseColors,
@@ -2677,7 +2677,7 @@ function updateStateMatrixFromTokens(mode) {
2677
2677
  }
2678
2678
  }
2679
2679
 
2680
- // src/theme/applyMode.ts
2680
+ // src/FOUNDATION/theme/applyMode.ts
2681
2681
  var MODE_ATTRIBUTE = "data-mode";
2682
2682
  var THEME_ATTRIBUTE = "data-theme-name";
2683
2683
  var MODE_THEME_ATTRIBUTE = "data-theme";
@@ -3090,7 +3090,7 @@ function persistBrand(brandId, storageKey = "tm_brand") {
3090
3090
  }
3091
3091
  }
3092
3092
 
3093
- // src/theme/registry.ts
3093
+ // src/FOUNDATION/theme/registry.ts
3094
3094
  var themeRegistry = /* @__PURE__ */ new Map();
3095
3095
  function registerTheme(entry) {
3096
3096
  themeRegistry.set(entry.metadata.id, entry);
@@ -3170,7 +3170,7 @@ function initializeDefaultThemes() {
3170
3170
  }
3171
3171
  initializeDefaultThemes();
3172
3172
 
3173
- // src/theme/schema.ts
3173
+ // src/FOUNDATION/theme/schema.ts
3174
3174
  var REQUIRED_FIELDS = ["id", "name"];
3175
3175
  function validateThemeSchema(theme) {
3176
3176
  const errors = [];
@@ -3264,7 +3264,7 @@ function createMinimalThemeSchema(id, name) {
3264
3264
  };
3265
3265
  }
3266
3266
 
3267
- // src/theme/loader.ts
3267
+ // src/FOUNDATION/theme/loader.ts
3268
3268
  var DEFAULT_OPTIONS = {
3269
3269
  fallbackThemeId: "default",
3270
3270
  validate: true,
@@ -3341,7 +3341,7 @@ async function canLoadTheme(themeId) {
3341
3341
  }
3342
3342
  }
3343
3343
 
3344
- // src/theme/spacing.ts
3344
+ // src/FOUNDATION/theme/spacing.ts
3345
3345
  var spacing2 = {
3346
3346
  none: "0",
3347
3347
  xs: "0.25rem",
@@ -3697,7 +3697,7 @@ function useTheme() {
3697
3697
  return context;
3698
3698
  }
3699
3699
 
3700
- // src/theme/typography.ts
3700
+ // src/FOUNDATION/theme/typography.ts
3701
3701
  var fontFamilies = {
3702
3702
  sans: [
3703
3703
  "ui-sans-serif",