@matteoaliano/forest-ui 0.2.0 → 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -1,5 +1,6 @@
1
1
  'use strict';
2
2
 
3
+ var react = require('react');
3
4
  var styles = require('@mui/material/styles');
4
5
  var CssBaseline = require('@mui/material/CssBaseline');
5
6
  var jsxRuntime = require('react/jsx-runtime');
@@ -290,1094 +291,1176 @@ var widths = {
290
291
  };
291
292
 
292
293
  // src/theme/palette.ts
293
- var palette = {
294
- primary: {
295
- main: colors.brand[600],
296
- light: colors.brand[400],
297
- dark: colors.brand[700],
298
- contrastText: colors.base.white
299
- },
300
- secondary: {
301
- main: colors.gray[600],
302
- light: colors.gray[400],
303
- dark: colors.gray[700],
304
- contrastText: colors.base.white
305
- },
306
- error: {
307
- main: colors.error[600],
308
- light: colors.error[300],
309
- dark: colors.error[700],
310
- contrastText: colors.base.white
311
- },
312
- warning: {
313
- main: colors.warning[600],
314
- light: colors.warning[300],
315
- dark: colors.warning[700],
316
- contrastText: colors.base.white
317
- },
318
- success: {
319
- main: colors.success[600],
320
- light: colors.success[300],
321
- dark: colors.success[700],
322
- contrastText: colors.base.white
323
- },
324
- info: {
325
- main: colors.blue[600],
326
- light: colors.blue[300],
327
- dark: colors.blue[700],
328
- contrastText: colors.base.white
329
- },
330
- background: {
331
- default: colors.base.white,
332
- paper: colors.base.white
333
- },
334
- text: {
335
- primary: colors.gray[900],
336
- secondary: colors.gray[700],
337
- disabled: colors.gray[500]
338
- },
339
- divider: colors.gray[200],
340
- action: {
341
- active: colors.gray[600],
342
- hover: colors.gray[50],
343
- selected: colors.brand[50],
344
- disabled: colors.gray[400],
345
- disabledBackground: colors.gray[100]
346
- }
347
- };
294
+ function buildPalette(tokens) {
295
+ const { colors: colors2 } = tokens;
296
+ return {
297
+ primary: {
298
+ main: colors2.brand[600],
299
+ light: colors2.brand[400],
300
+ dark: colors2.brand[700],
301
+ contrastText: colors2.base.white
302
+ },
303
+ secondary: {
304
+ main: colors2.gray[600],
305
+ light: colors2.gray[400],
306
+ dark: colors2.gray[700],
307
+ contrastText: colors2.base.white
308
+ },
309
+ error: {
310
+ main: colors2.error[600],
311
+ light: colors2.error[300],
312
+ dark: colors2.error[700],
313
+ contrastText: colors2.base.white
314
+ },
315
+ warning: {
316
+ main: colors2.warning[600],
317
+ light: colors2.warning[300],
318
+ dark: colors2.warning[700],
319
+ contrastText: colors2.base.white
320
+ },
321
+ success: {
322
+ main: colors2.success[600],
323
+ light: colors2.success[300],
324
+ dark: colors2.success[700],
325
+ contrastText: colors2.base.white
326
+ },
327
+ info: {
328
+ main: colors2.blue[600],
329
+ light: colors2.blue[300],
330
+ dark: colors2.blue[700],
331
+ contrastText: colors2.base.white
332
+ },
333
+ background: {
334
+ default: colors2.base.white,
335
+ paper: colors2.base.white
336
+ },
337
+ text: {
338
+ primary: colors2.gray[900],
339
+ secondary: colors2.gray[700],
340
+ disabled: colors2.gray[500]
341
+ },
342
+ divider: colors2.gray[200],
343
+ action: {
344
+ active: colors2.gray[600],
345
+ hover: colors2.gray[50],
346
+ selected: colors2.brand[50],
347
+ disabled: colors2.gray[400],
348
+ disabledBackground: colors2.gray[100]
349
+ }
350
+ };
351
+ }
352
+ var palette = buildPalette({
353
+ colors
354
+ });
348
355
 
349
356
  // src/theme/typography.ts
350
- var typography = {
357
+ function buildTypography(tokens) {
358
+ const { fontFamily: fontFamily2, display: display2, fontSize: fontSize2, lineHeight: lineHeight2, fontWeight: fontWeight2 } = tokens;
359
+ return {
360
+ fontFamily: fontFamily2,
361
+ fontWeightRegular: fontWeight2.regular,
362
+ fontWeightMedium: fontWeight2.medium,
363
+ fontWeightBold: fontWeight2.bold,
364
+ // Display styles → MUI headings
365
+ h1: {
366
+ fontSize: display2.xl.fontSize,
367
+ lineHeight: display2.xl.lineHeight,
368
+ letterSpacing: display2.xl.letterSpacing,
369
+ fontWeight: fontWeight2.semibold
370
+ },
371
+ h2: {
372
+ fontSize: display2.lg.fontSize,
373
+ lineHeight: display2.lg.lineHeight,
374
+ letterSpacing: display2.lg.letterSpacing,
375
+ fontWeight: fontWeight2.semibold
376
+ },
377
+ h3: {
378
+ fontSize: display2.md.fontSize,
379
+ lineHeight: display2.md.lineHeight,
380
+ letterSpacing: display2.md.letterSpacing,
381
+ fontWeight: fontWeight2.semibold
382
+ },
383
+ h4: {
384
+ fontSize: display2.sm.fontSize,
385
+ lineHeight: display2.sm.lineHeight,
386
+ fontWeight: fontWeight2.semibold
387
+ },
388
+ h5: {
389
+ fontSize: display2.xs.fontSize,
390
+ lineHeight: display2.xs.lineHeight,
391
+ fontWeight: fontWeight2.semibold
392
+ },
393
+ h6: {
394
+ fontSize: fontSize2.xl,
395
+ lineHeight: lineHeight2.xl,
396
+ fontWeight: fontWeight2.semibold
397
+ },
398
+ subtitle1: {
399
+ fontSize: fontSize2.lg,
400
+ lineHeight: lineHeight2.lg,
401
+ fontWeight: fontWeight2.medium
402
+ },
403
+ subtitle2: {
404
+ fontSize: fontSize2.md,
405
+ lineHeight: lineHeight2.md,
406
+ fontWeight: fontWeight2.medium
407
+ },
408
+ body1: {
409
+ fontSize: fontSize2.md,
410
+ lineHeight: lineHeight2.md,
411
+ fontWeight: fontWeight2.regular
412
+ },
413
+ body2: {
414
+ fontSize: fontSize2.sm,
415
+ lineHeight: lineHeight2.sm,
416
+ fontWeight: fontWeight2.regular
417
+ },
418
+ caption: {
419
+ fontSize: fontSize2.xs,
420
+ lineHeight: lineHeight2.xs,
421
+ fontWeight: fontWeight2.regular
422
+ },
423
+ overline: {
424
+ fontSize: fontSize2.xxs,
425
+ lineHeight: lineHeight2.xxs,
426
+ fontWeight: fontWeight2.medium,
427
+ textTransform: "uppercase",
428
+ letterSpacing: "0.08em"
429
+ },
430
+ button: {
431
+ fontSize: fontSize2.sm,
432
+ lineHeight: lineHeight2.sm,
433
+ fontWeight: fontWeight2.semibold,
434
+ textTransform: "none"
435
+ }
436
+ };
437
+ }
438
+ var typography = buildTypography({
351
439
  fontFamily,
352
- fontWeightRegular: fontWeight.regular,
353
- fontWeightMedium: fontWeight.medium,
354
- fontWeightBold: fontWeight.bold,
355
- // Display styles → MUI headings
356
- h1: {
357
- fontSize: display.xl.fontSize,
358
- lineHeight: display.xl.lineHeight,
359
- letterSpacing: display.xl.letterSpacing,
360
- fontWeight: fontWeight.semibold
361
- },
362
- h2: {
363
- fontSize: display.lg.fontSize,
364
- lineHeight: display.lg.lineHeight,
365
- letterSpacing: display.lg.letterSpacing,
366
- fontWeight: fontWeight.semibold
367
- },
368
- h3: {
369
- fontSize: display.md.fontSize,
370
- lineHeight: display.md.lineHeight,
371
- letterSpacing: display.md.letterSpacing,
372
- fontWeight: fontWeight.semibold
373
- },
374
- h4: {
375
- fontSize: display.sm.fontSize,
376
- lineHeight: display.sm.lineHeight,
377
- fontWeight: fontWeight.semibold
378
- },
379
- h5: {
380
- fontSize: display.xs.fontSize,
381
- lineHeight: display.xs.lineHeight,
382
- fontWeight: fontWeight.semibold
383
- },
384
- h6: {
385
- fontSize: fontSize.xl,
386
- lineHeight: lineHeight.xl,
387
- fontWeight: fontWeight.semibold
388
- },
389
- subtitle1: {
390
- fontSize: fontSize.lg,
391
- lineHeight: lineHeight.lg,
392
- fontWeight: fontWeight.medium
393
- },
394
- subtitle2: {
395
- fontSize: fontSize.md,
396
- lineHeight: lineHeight.md,
397
- fontWeight: fontWeight.medium
398
- },
399
- body1: {
400
- fontSize: fontSize.md,
401
- lineHeight: lineHeight.md,
402
- fontWeight: fontWeight.regular
403
- },
404
- body2: {
405
- fontSize: fontSize.sm,
406
- lineHeight: lineHeight.sm,
407
- fontWeight: fontWeight.regular
408
- },
409
- caption: {
410
- fontSize: fontSize.xs,
411
- lineHeight: lineHeight.xs,
412
- fontWeight: fontWeight.regular
413
- },
414
- overline: {
415
- fontSize: fontSize.xxs,
416
- lineHeight: lineHeight.xxs,
417
- fontWeight: fontWeight.medium,
418
- textTransform: "uppercase",
419
- letterSpacing: "0.08em"
420
- },
421
- button: {
422
- fontSize: fontSize.sm,
423
- lineHeight: lineHeight.sm,
424
- fontWeight: fontWeight.semibold,
425
- textTransform: "none"
426
- }
427
- };
440
+ display,
441
+ fontSize,
442
+ lineHeight,
443
+ fontWeight
444
+ });
428
445
 
429
446
  // src/theme/components.ts
430
- var components = {
431
- // ─── Button ─────────────────────────────────────────────────────
432
- MuiButton: {
433
- defaultProps: {
434
- disableElevation: true
435
- },
436
- styleOverrides: {
437
- root: {
438
- borderRadius: radius.md,
439
- fontWeight: 600,
440
- "&:focus-visible": {
441
- boxShadow: focusRings.brandShadowXs
442
- }
443
- },
444
- sizeLarge: {
445
- padding: "12px 20px",
446
- fontSize: 16,
447
- lineHeight: "24px"
448
- },
449
- sizeMedium: {
450
- padding: "10px 16px",
451
- fontSize: 14,
452
- lineHeight: "20px"
447
+ function buildComponents(tokens) {
448
+ const { colors: colors2, radius: radius2, focusRings: focusRings2, shadows: tokenShadows } = tokens;
449
+ return {
450
+ // ─── Button ─────────────────────────────────────────────────────
451
+ MuiButton: {
452
+ defaultProps: {
453
+ disableElevation: true
453
454
  },
454
- sizeSmall: {
455
- padding: "8px 14px",
456
- fontSize: 14,
457
- lineHeight: "20px"
458
- },
459
- containedPrimary: {
460
- backgroundColor: colors.brand[600],
461
- "&:hover": {
462
- backgroundColor: colors.brand[700]
463
- }
464
- },
465
- outlinedPrimary: {
466
- borderColor: colors.brand[300],
467
- color: colors.brand[700],
468
- "&:hover": {
469
- backgroundColor: colors.brand[50],
470
- borderColor: colors.brand[300]
471
- }
472
- },
473
- textPrimary: {
474
- color: colors.brand[700],
475
- "&:hover": {
476
- backgroundColor: colors.brand[50]
455
+ styleOverrides: {
456
+ root: {
457
+ borderRadius: radius2.md,
458
+ fontWeight: 600,
459
+ "&:focus-visible": {
460
+ boxShadow: focusRings2.brandShadowXs
461
+ }
462
+ },
463
+ sizeLarge: {
464
+ padding: "12px 20px",
465
+ fontSize: 16,
466
+ lineHeight: "24px"
467
+ },
468
+ sizeMedium: {
469
+ padding: "10px 16px",
470
+ fontSize: 14,
471
+ lineHeight: "20px"
472
+ },
473
+ sizeSmall: {
474
+ padding: "8px 14px",
475
+ fontSize: 14,
476
+ lineHeight: "20px"
477
+ },
478
+ containedPrimary: {
479
+ backgroundColor: colors2.brand[600],
480
+ "&:hover": {
481
+ backgroundColor: colors2.brand[700]
482
+ }
483
+ },
484
+ outlinedPrimary: {
485
+ borderColor: colors2.brand[300],
486
+ color: colors2.brand[700],
487
+ "&:hover": {
488
+ backgroundColor: colors2.brand[50],
489
+ borderColor: colors2.brand[300]
490
+ }
491
+ },
492
+ textPrimary: {
493
+ color: colors2.brand[700],
494
+ "&:hover": {
495
+ backgroundColor: colors2.brand[50]
496
+ }
477
497
  }
478
498
  }
479
- }
480
- },
481
- // ─── Button Group ───────────────────────────────────────────────
482
- MuiButtonGroup: {
483
- defaultProps: {
484
- disableElevation: true
485
- },
486
- styleOverrides: {
487
- root: {
488
- borderRadius: radius.md
499
+ },
500
+ // ─── Button Group ───────────────────────────────────────────────
501
+ MuiButtonGroup: {
502
+ defaultProps: {
503
+ disableElevation: true
489
504
  },
490
- grouped: {
491
- "&:not(:last-of-type)": {
492
- borderRight: `1px solid ${colors.brand[700]}`
505
+ styleOverrides: {
506
+ root: {
507
+ borderRadius: radius2.md
508
+ },
509
+ grouped: {
510
+ "&:not(:last-of-type)": {
511
+ borderRight: `1px solid ${colors2.brand[700]}`
512
+ }
493
513
  }
494
514
  }
495
- }
496
- },
497
- // ─── FAB ────────────────────────────────────────────────────────
498
- MuiFab: {
499
- styleOverrides: {
500
- root: {
501
- boxShadow: shadows.md,
502
- "&:hover": {
503
- boxShadow: shadows.lg
515
+ },
516
+ // ─── FAB ────────────────────────────────────────────────────────
517
+ MuiFab: {
518
+ styleOverrides: {
519
+ root: {
520
+ boxShadow: tokenShadows.md,
521
+ "&:hover": {
522
+ boxShadow: tokenShadows.lg
523
+ },
524
+ "&:focus-visible": {
525
+ boxShadow: focusRings2.brandShadowSm
526
+ }
504
527
  },
505
- "&:focus-visible": {
506
- boxShadow: focusRings.brandShadowSm
507
- }
508
- },
509
- primary: {
510
- backgroundColor: colors.brand[600],
511
- "&:hover": {
512
- backgroundColor: colors.brand[700]
528
+ primary: {
529
+ backgroundColor: colors2.brand[600],
530
+ "&:hover": {
531
+ backgroundColor: colors2.brand[700]
532
+ }
513
533
  }
514
534
  }
515
- }
516
- },
517
- // ─── TextField / Input ──────────────────────────────────────────
518
- MuiTextField: {
519
- defaultProps: {
520
- variant: "outlined",
521
- size: "small"
522
- }
523
- },
524
- MuiOutlinedInput: {
525
- styleOverrides: {
526
- root: {
527
- borderRadius: radius.md,
528
- "&:hover .MuiOutlinedInput-notchedOutline": {
529
- borderColor: colors.brand[300]
535
+ },
536
+ // ─── TextField / Input ──────────────────────────────────────────
537
+ MuiTextField: {
538
+ defaultProps: {
539
+ variant: "outlined",
540
+ size: "small"
541
+ }
542
+ },
543
+ MuiOutlinedInput: {
544
+ styleOverrides: {
545
+ root: {
546
+ borderRadius: radius2.md,
547
+ "&:hover .MuiOutlinedInput-notchedOutline": {
548
+ borderColor: colors2.brand[300]
549
+ },
550
+ "&.Mui-focused .MuiOutlinedInput-notchedOutline": {
551
+ borderColor: colors2.brand[600],
552
+ borderWidth: 1,
553
+ boxShadow: "none"
554
+ },
555
+ "&.Mui-error .MuiOutlinedInput-notchedOutline": {
556
+ borderColor: colors2.error[300]
557
+ },
558
+ "&.Mui-error.Mui-focused .MuiOutlinedInput-notchedOutline": {
559
+ borderColor: colors2.error[600],
560
+ boxShadow: "none"
561
+ }
530
562
  },
531
- "&.Mui-focused .MuiOutlinedInput-notchedOutline": {
532
- borderColor: colors.brand[600],
533
- borderWidth: 1,
534
- boxShadow: focusRings.brand
563
+ notchedOutline: {
564
+ borderColor: colors2.gray[300]
535
565
  },
536
- "&.Mui-error .MuiOutlinedInput-notchedOutline": {
537
- borderColor: colors.error[300]
566
+ input: {
567
+ padding: "10px 14px",
568
+ fontSize: 16,
569
+ lineHeight: "24px",
570
+ "&::placeholder": {
571
+ color: colors2.gray[500],
572
+ opacity: 1
573
+ }
538
574
  },
539
- "&.Mui-error.Mui-focused .MuiOutlinedInput-notchedOutline": {
540
- borderColor: colors.error[600],
541
- boxShadow: focusRings.error
575
+ inputSizeSmall: {
576
+ padding: "8px 12px",
577
+ fontSize: 14,
578
+ lineHeight: "20px"
542
579
  }
543
- },
544
- notchedOutline: {
545
- borderColor: colors.gray[300]
546
- },
547
- input: {
548
- padding: "10px 14px",
549
- fontSize: 16,
550
- lineHeight: "24px",
551
- "&::placeholder": {
552
- color: colors.gray[500],
553
- opacity: 1
554
- }
555
- },
556
- inputSizeSmall: {
557
- padding: "8px 12px",
558
- fontSize: 14,
559
- lineHeight: "20px"
560
580
  }
561
- }
562
- },
563
- MuiInputLabel: {
564
- styleOverrides: {
565
- root: {
566
- fontSize: 14,
567
- fontWeight: 500,
568
- color: colors.gray[700],
569
- "&.Mui-focused": {
570
- color: colors.gray[700]
571
- },
572
- "&.Mui-error": {
573
- color: colors.error[600]
581
+ },
582
+ MuiInputLabel: {
583
+ styleOverrides: {
584
+ root: {
585
+ fontSize: 14,
586
+ fontWeight: 500,
587
+ color: colors2.gray[700],
588
+ "&.Mui-focused": {
589
+ color: colors2.gray[700]
590
+ },
591
+ "&.Mui-error": {
592
+ color: colors2.error[600]
593
+ }
574
594
  }
575
595
  }
576
- }
577
- },
578
- MuiFormHelperText: {
579
- styleOverrides: {
580
- root: {
581
- fontSize: 14,
582
- lineHeight: "20px",
583
- marginTop: 6,
584
- marginLeft: 0,
585
- "&.Mui-error": {
586
- color: colors.error[600]
596
+ },
597
+ MuiFormHelperText: {
598
+ styleOverrides: {
599
+ root: {
600
+ fontSize: 14,
601
+ lineHeight: "20px",
602
+ marginTop: 6,
603
+ marginLeft: 0,
604
+ "&.Mui-error": {
605
+ color: colors2.error[600]
606
+ }
587
607
  }
588
608
  }
589
- }
590
- },
591
- // ─── Select ─────────────────────────────────────────────────────
592
- MuiSelect: {
593
- defaultProps: {
594
- size: "small"
595
- },
596
- styleOverrides: {
597
- icon: {
598
- color: colors.gray[500]
599
- }
600
- }
601
- },
602
- // ─── Autocomplete ───────────────────────────────────────────────
603
- MuiAutocomplete: {
604
- styleOverrides: {
605
- paper: {
606
- borderRadius: radius.md,
607
- boxShadow: shadows.lg,
608
- border: `1px solid ${colors.gray[200]}`,
609
- marginTop: 4
609
+ },
610
+ // ─── Select ─────────────────────────────────────────────────────
611
+ MuiSelect: {
612
+ defaultProps: {
613
+ size: "small"
610
614
  },
611
- option: {
612
- fontSize: 16,
613
- lineHeight: "24px",
614
- padding: "10px 14px",
615
- "&.Mui-focused": {
616
- backgroundColor: colors.gray[50]
617
- },
618
- '&[aria-selected="true"]': {
619
- backgroundColor: colors.brand[50]
615
+ styleOverrides: {
616
+ icon: {
617
+ color: colors2.gray[500]
620
618
  }
621
- },
622
- listbox: {
623
- padding: 4
624
619
  }
625
- }
626
- },
627
- // ─── Checkbox ───────────────────────────────────────────────────
628
- MuiCheckbox: {
629
- defaultProps: {
630
- disableRipple: true
631
- },
632
- styleOverrides: {
633
- root: {
634
- color: colors.gray[300],
635
- borderRadius: radius.xs,
636
- padding: 0,
637
- width: 20,
638
- height: 20,
639
- "&:hover": {
640
- backgroundColor: "transparent",
641
- color: colors.brand[600]
642
- },
643
- "&.Mui-checked": {
644
- color: colors.brand[600]
645
- },
646
- "&.Mui-checked:hover": {
647
- color: colors.brand[700]
620
+ },
621
+ // ─── Autocomplete ───────────────────────────────────────────────
622
+ MuiAutocomplete: {
623
+ styleOverrides: {
624
+ paper: {
625
+ borderRadius: radius2.md,
626
+ boxShadow: tokenShadows.lg,
627
+ border: `1px solid ${colors2.gray[200]}`,
628
+ marginTop: 4
648
629
  },
649
- "&.Mui-focusVisible": {
650
- outline: "none",
651
- boxShadow: focusRings.brand,
652
- borderRadius: radius.xs
630
+ option: {
631
+ fontSize: 16,
632
+ lineHeight: "24px",
633
+ padding: "10px 14px",
634
+ "&.Mui-focused": {
635
+ backgroundColor: colors2.gray[50]
636
+ },
637
+ '&[aria-selected="true"]': {
638
+ backgroundColor: colors2.brand[50]
639
+ }
653
640
  },
654
- "&.Mui-disabled": {
655
- color: colors.gray[300]
641
+ listbox: {
642
+ padding: 4
656
643
  }
657
644
  }
658
- }
659
- },
660
- // ─── Radio ──────────────────────────────────────────────────────
661
- MuiRadio: {
662
- defaultProps: {
663
- disableRipple: true
664
- },
665
- styleOverrides: {
666
- root: {
667
- color: colors.gray[300],
668
- padding: 0,
669
- "&:hover": {
670
- backgroundColor: "transparent",
671
- color: colors.brand[600]
672
- },
673
- "&.Mui-checked": {
674
- color: colors.brand[600]
675
- },
676
- "&.Mui-checked:hover": {
677
- color: colors.brand[700]
678
- },
679
- "&.Mui-focusVisible": {
680
- outline: "none",
681
- boxShadow: focusRings.brand,
682
- borderRadius: radius.full
683
- },
684
- "&.Mui-disabled": {
685
- color: colors.gray[300]
645
+ },
646
+ // ─── Checkbox ───────────────────────────────────────────────────
647
+ MuiCheckbox: {
648
+ defaultProps: {
649
+ disableRipple: true
650
+ },
651
+ styleOverrides: {
652
+ root: {
653
+ color: colors2.gray[300],
654
+ borderRadius: radius2.xs,
655
+ padding: 0,
656
+ width: 20,
657
+ height: 20,
658
+ "&:hover": {
659
+ backgroundColor: "transparent",
660
+ color: colors2.brand[600]
661
+ },
662
+ "&.Mui-checked": {
663
+ color: colors2.brand[600]
664
+ },
665
+ "&.Mui-checked:hover": {
666
+ color: colors2.brand[700]
667
+ },
668
+ "&.Mui-focusVisible": {
669
+ outline: "none",
670
+ boxShadow: focusRings2.brand,
671
+ borderRadius: radius2.xs
672
+ },
673
+ "&.Mui-disabled": {
674
+ color: colors2.gray[300]
675
+ }
686
676
  }
687
677
  }
688
- }
689
- },
690
- // ─── Switch ─────────────────────────────────────────────────────
691
- MuiSwitch: {
692
- defaultProps: {
693
- disableRipple: true
694
- },
695
- styleOverrides: {
696
- root: {
697
- width: 44,
698
- height: 24,
699
- padding: 0
678
+ },
679
+ // ─── Radio ──────────────────────────────────────────────────────
680
+ MuiRadio: {
681
+ defaultProps: {
682
+ disableRipple: true
700
683
  },
701
- switchBase: {
702
- padding: 2,
703
- "&.Mui-checked": {
704
- transform: "translateX(20px)",
705
- color: colors.base.white,
706
- "& + .MuiSwitch-track": {
707
- backgroundColor: colors.brand[600],
708
- opacity: 1
684
+ styleOverrides: {
685
+ root: {
686
+ color: colors2.gray[300],
687
+ padding: 0,
688
+ "&:hover": {
689
+ backgroundColor: "transparent",
690
+ color: colors2.brand[600]
691
+ },
692
+ "&.Mui-checked": {
693
+ color: colors2.brand[600]
694
+ },
695
+ "&.Mui-checked:hover": {
696
+ color: colors2.brand[700]
697
+ },
698
+ "&.Mui-focusVisible": {
699
+ outline: "none",
700
+ boxShadow: focusRings2.brand,
701
+ borderRadius: radius2.full
702
+ },
703
+ "&.Mui-disabled": {
704
+ color: colors2.gray[300]
709
705
  }
706
+ }
707
+ }
708
+ },
709
+ // ─── Switch ─────────────────────────────────────────────────────
710
+ MuiSwitch: {
711
+ defaultProps: {
712
+ disableRipple: true
713
+ },
714
+ styleOverrides: {
715
+ root: {
716
+ width: 44,
717
+ height: 24,
718
+ padding: 0
710
719
  },
711
- "&.Mui-checked:hover + .MuiSwitch-track": {
712
- backgroundColor: colors.brand[700]
713
- },
714
- "&.Mui-focusVisible .MuiSwitch-thumb": {
715
- boxShadow: focusRings.brand
720
+ switchBase: {
721
+ padding: 2,
722
+ "&.Mui-checked": {
723
+ transform: "translateX(20px)",
724
+ color: colors2.base.white,
725
+ "& + .MuiSwitch-track": {
726
+ backgroundColor: colors2.brand[600],
727
+ opacity: 1
728
+ }
729
+ },
730
+ "&.Mui-checked:hover + .MuiSwitch-track": {
731
+ backgroundColor: colors2.brand[700]
732
+ },
733
+ "&.Mui-focusVisible .MuiSwitch-thumb": {
734
+ boxShadow: focusRings2.brand
735
+ },
736
+ "&.Mui-disabled .MuiSwitch-thumb": {
737
+ color: colors2.gray[100]
738
+ },
739
+ "&.Mui-disabled + .MuiSwitch-track": {
740
+ opacity: 0.5
741
+ }
716
742
  },
717
- "&.Mui-disabled .MuiSwitch-thumb": {
718
- color: colors.gray[100]
743
+ thumb: {
744
+ width: 20,
745
+ height: 20,
746
+ boxShadow: "0px 1px 2px 0px #1018280d"
719
747
  },
720
- "&.Mui-disabled + .MuiSwitch-track": {
721
- opacity: 0.5
748
+ track: {
749
+ borderRadius: radius2.full,
750
+ backgroundColor: colors2.gray[200],
751
+ opacity: 1
722
752
  }
723
- },
724
- thumb: {
725
- width: 20,
726
- height: 20,
727
- boxShadow: "0px 1px 2px 0px #1018280d"
728
- },
729
- track: {
730
- borderRadius: radius.full,
731
- backgroundColor: colors.gray[200],
732
- opacity: 1
733
753
  }
734
- }
735
- },
736
- // ─── Toggle Button ─────────────────────────────────────────────
737
- MuiToggleButton: {
738
- styleOverrides: {
739
- root: {
740
- borderRadius: radius.md,
741
- borderColor: colors.gray[300],
742
- color: colors.gray[700],
743
- fontSize: 14,
744
- fontWeight: 600,
745
- lineHeight: "20px",
746
- padding: "8px 14px",
747
- textTransform: "none",
748
- "&:hover": {
749
- backgroundColor: colors.gray[50]
750
- },
751
- "&.Mui-selected": {
752
- backgroundColor: colors.brand[50],
753
- color: colors.brand[700],
754
- borderColor: colors.brand[300],
754
+ },
755
+ // ─── Toggle Button ─────────────────────────────────────────────
756
+ MuiToggleButton: {
757
+ styleOverrides: {
758
+ root: {
759
+ borderRadius: radius2.md,
760
+ borderColor: colors2.gray[300],
761
+ color: colors2.gray[700],
762
+ fontSize: 14,
763
+ fontWeight: 600,
764
+ lineHeight: "20px",
765
+ padding: "8px 14px",
766
+ textTransform: "none",
755
767
  "&:hover": {
756
- backgroundColor: colors.brand[100]
768
+ backgroundColor: colors2.gray[50]
769
+ },
770
+ "&.Mui-selected": {
771
+ backgroundColor: colors2.brand[50],
772
+ color: colors2.brand[700],
773
+ borderColor: colors2.brand[300],
774
+ "&:hover": {
775
+ backgroundColor: colors2.brand[100]
776
+ }
777
+ },
778
+ "&:focus-visible": {
779
+ boxShadow: focusRings2.brandShadowXs
757
780
  }
758
- },
759
- "&:focus-visible": {
760
- boxShadow: focusRings.brandShadowXs
761
781
  }
762
782
  }
763
- }
764
- },
765
- MuiToggleButtonGroup: {
766
- styleOverrides: {
767
- root: {
768
- borderRadius: radius.md
769
- },
770
- grouped: {
771
- "&:not(:first-of-type)": {
772
- borderRadius: radius.md,
773
- marginLeft: -1
783
+ },
784
+ MuiToggleButtonGroup: {
785
+ styleOverrides: {
786
+ root: {
787
+ borderRadius: radius2.md
774
788
  },
775
- "&:first-of-type": {
776
- borderRadius: radius.md
789
+ grouped: {
790
+ "&:not(:first-of-type)": {
791
+ borderRadius: radius2.md,
792
+ marginLeft: -1
793
+ },
794
+ "&:first-of-type": {
795
+ borderRadius: radius2.md
796
+ }
777
797
  }
778
798
  }
779
- }
780
- },
781
- // ─── Card ───────────────────────────────────────────────────────
782
- MuiCard: {
783
- defaultProps: {
784
- elevation: 0
785
- },
786
- styleOverrides: {
787
- root: {
788
- borderRadius: radius.xl,
789
- border: `1px solid ${colors.gray[200]}`,
790
- backgroundColor: colors.base.white,
791
- overflow: "hidden"
799
+ },
800
+ // ─── Card ───────────────────────────────────────────────────────
801
+ MuiCard: {
802
+ defaultProps: {
803
+ elevation: 0
804
+ },
805
+ styleOverrides: {
806
+ root: {
807
+ borderRadius: radius2.xl,
808
+ border: `1px solid ${colors2.gray[200]}`,
809
+ backgroundColor: colors2.base.white,
810
+ overflow: "hidden"
811
+ }
792
812
  }
793
- }
794
- },
795
- MuiCardContent: {
796
- styleOverrides: {
797
- root: {
798
- padding: "24px",
799
- "&:last-child": {
800
- paddingBottom: "24px"
813
+ },
814
+ MuiCardContent: {
815
+ styleOverrides: {
816
+ root: {
817
+ padding: "24px",
818
+ "&:last-child": {
819
+ paddingBottom: "24px"
820
+ }
801
821
  }
802
822
  }
803
- }
804
- },
805
- MuiCardHeader: {
806
- styleOverrides: {
807
- root: {
808
- padding: "24px 24px 0 24px"
809
- },
810
- title: {
811
- fontSize: 18,
812
- fontWeight: 600,
813
- lineHeight: "28px"
814
- },
815
- subheader: {
816
- fontSize: 14,
817
- lineHeight: "20px",
818
- marginTop: 4
819
- },
820
- action: {
821
- marginTop: -4,
822
- marginRight: -4
823
+ },
824
+ MuiCardHeader: {
825
+ styleOverrides: {
826
+ root: {
827
+ padding: "24px 24px 0 24px"
828
+ },
829
+ title: {
830
+ fontSize: 18,
831
+ fontWeight: 600,
832
+ lineHeight: "28px"
833
+ },
834
+ subheader: {
835
+ fontSize: 14,
836
+ lineHeight: "20px",
837
+ marginTop: 4
838
+ },
839
+ action: {
840
+ marginTop: -4,
841
+ marginRight: -4
842
+ }
823
843
  }
824
- }
825
- },
826
- // ─── Paper ──────────────────────────────────────────────────────
827
- MuiPaper: {
828
- defaultProps: {
829
- elevation: 0
830
- },
831
- styleOverrides: {
832
- root: {
833
- backgroundImage: "none"
834
- },
835
- rounded: {
836
- borderRadius: radius.lg
837
- },
838
- elevation1: {
839
- boxShadow: shadows.xs,
840
- border: `1px solid ${colors.gray[200]}`
841
- },
842
- elevation2: {
843
- boxShadow: shadows.sm,
844
- border: `1px solid ${colors.gray[200]}`
845
- },
846
- elevation3: {
847
- boxShadow: shadows.md,
848
- border: `1px solid ${colors.gray[200]}`
849
- },
850
- elevation4: {
851
- boxShadow: shadows.lg,
852
- border: `1px solid ${colors.gray[200]}`
853
- },
854
- elevation8: {
855
- boxShadow: shadows.xl,
856
- border: `1px solid ${colors.gray[200]}`
857
- },
858
- elevation16: {
859
- boxShadow: shadows["2xl"],
860
- border: `1px solid ${colors.gray[200]}`
844
+ },
845
+ // ─── Paper ──────────────────────────────────────────────────────
846
+ MuiPaper: {
847
+ defaultProps: {
848
+ elevation: 0
861
849
  },
862
- elevation24: {
863
- boxShadow: shadows["3xl"],
864
- border: `1px solid ${colors.gray[200]}`
865
- }
866
- }
867
- },
868
- // ─── Accordion ──────────────────────────────────────────────────
869
- MuiAccordion: {
870
- defaultProps: {
871
- disableGutters: true,
872
- elevation: 0
873
- },
874
- styleOverrides: {
875
- root: {
876
- border: `1px solid ${colors.gray[200]}`,
877
- borderRadius: radius.lg,
878
- "&:not(:last-child)": {
879
- marginBottom: 8
850
+ styleOverrides: {
851
+ root: {
852
+ backgroundImage: "none"
853
+ },
854
+ rounded: {
855
+ borderRadius: radius2.lg
880
856
  },
881
- "&:before": {
882
- display: "none"
857
+ elevation1: {
858
+ boxShadow: tokenShadows.xs,
859
+ border: `1px solid ${colors2.gray[200]}`
883
860
  },
884
- "&.Mui-expanded": {
885
- margin: 0,
886
- marginBottom: 8,
887
- borderRadius: radius.lg
861
+ elevation2: {
862
+ boxShadow: tokenShadows.sm,
863
+ border: `1px solid ${colors2.gray[200]}`
864
+ },
865
+ elevation3: {
866
+ boxShadow: tokenShadows.md,
867
+ border: `1px solid ${colors2.gray[200]}`
868
+ },
869
+ elevation4: {
870
+ boxShadow: tokenShadows.lg,
871
+ border: `1px solid ${colors2.gray[200]}`
872
+ },
873
+ elevation8: {
874
+ boxShadow: tokenShadows.xl,
875
+ border: `1px solid ${colors2.gray[200]}`
876
+ },
877
+ elevation16: {
878
+ boxShadow: tokenShadows["2xl"],
879
+ border: `1px solid ${colors2.gray[200]}`
880
+ },
881
+ elevation24: {
882
+ boxShadow: tokenShadows["3xl"],
883
+ border: `1px solid ${colors2.gray[200]}`
888
884
  }
889
885
  }
890
- }
891
- },
892
- MuiAccordionSummary: {
893
- styleOverrides: {
894
- root: {
895
- padding: "0 24px",
896
- minHeight: 56,
897
- "&.Mui-expanded": {
898
- minHeight: 56,
899
- borderBottom: `1px solid ${colors.gray[200]}`
900
- }
886
+ },
887
+ // ─── Accordion ──────────────────────────────────────────────────
888
+ MuiAccordion: {
889
+ defaultProps: {
890
+ disableGutters: true,
891
+ elevation: 0
901
892
  },
902
- content: {
903
- margin: "12px 0",
904
- "&.Mui-expanded": {
905
- margin: "12px 0"
893
+ styleOverrides: {
894
+ root: {
895
+ border: `1px solid ${colors2.gray[200]}`,
896
+ borderRadius: radius2.lg,
897
+ "&:not(:last-child)": {
898
+ marginBottom: 8
899
+ },
900
+ "&:before": {
901
+ display: "none"
902
+ },
903
+ "&.Mui-expanded": {
904
+ margin: 0,
905
+ marginBottom: 8,
906
+ borderRadius: radius2.lg
907
+ }
906
908
  }
907
909
  }
908
- }
909
- },
910
- MuiAccordionDetails: {
911
- styleOverrides: {
912
- root: {
913
- padding: "24px"
914
- }
915
- }
916
- },
917
- // ─── AppBar ─────────────────────────────────────────────────────
918
- MuiAppBar: {
919
- defaultProps: {
920
- elevation: 0,
921
- color: "transparent"
922
- },
923
- styleOverrides: {
924
- root: {
925
- borderBottom: `1px solid ${colors.gray[200]}`,
926
- backgroundColor: colors.base.white
910
+ },
911
+ MuiAccordionSummary: {
912
+ styleOverrides: {
913
+ root: {
914
+ padding: "0 24px",
915
+ minHeight: 56,
916
+ "&.Mui-expanded": {
917
+ minHeight: 56,
918
+ borderBottom: `1px solid ${colors2.gray[200]}`
919
+ }
920
+ },
921
+ content: {
922
+ margin: "12px 0",
923
+ "&.Mui-expanded": {
924
+ margin: "12px 0"
925
+ }
926
+ }
927
927
  }
928
- }
929
- },
930
- MuiToolbar: {
931
- styleOverrides: {
932
- root: {
933
- minHeight: 64,
934
- "@media (min-width: 600px)": {
935
- minHeight: 64
928
+ },
929
+ MuiAccordionDetails: {
930
+ styleOverrides: {
931
+ root: {
932
+ padding: "24px"
936
933
  }
934
+ }
935
+ },
936
+ // ─── AppBar ─────────────────────────────────────────────────────
937
+ MuiAppBar: {
938
+ defaultProps: {
939
+ elevation: 0,
940
+ color: "transparent"
937
941
  },
938
- dense: {
939
- minHeight: 48,
940
- "@media (min-width: 600px)": {
941
- minHeight: 48
942
+ styleOverrides: {
943
+ root: {
944
+ borderBottom: `1px solid ${colors2.gray[200]}`,
945
+ backgroundColor: colors2.base.white
942
946
  }
943
947
  }
944
- }
945
- },
946
- // ─── Chip ───────────────────────────────────────────────────────
947
- MuiChip: {
948
- styleOverrides: {
949
- root: {
950
- borderRadius: radius.md,
951
- fontWeight: 500,
952
- fontSize: 14
953
- }
954
- }
955
- },
956
- // ─── Form Control / Label ───────────────────────────────────────
957
- MuiFormControlLabel: {
958
- styleOverrides: {
959
- root: {
960
- marginLeft: 0,
961
- gap: 8
962
- },
963
- label: {
964
- fontSize: 14,
965
- lineHeight: "20px",
966
- fontWeight: 500,
967
- color: colors.gray[700]
948
+ },
949
+ MuiToolbar: {
950
+ styleOverrides: {
951
+ root: {
952
+ minHeight: 64,
953
+ "@media (min-width: 600px)": {
954
+ minHeight: 64
955
+ }
956
+ },
957
+ dense: {
958
+ minHeight: 48,
959
+ "@media (min-width: 600px)": {
960
+ minHeight: 48
961
+ }
962
+ }
968
963
  }
969
- }
970
- },
971
- // ─── Table ───────────────────────────────────────────────────────
972
- MuiTable: {
973
- styleOverrides: {
974
- root: {
975
- borderCollapse: "separate",
976
- borderSpacing: 0
964
+ },
965
+ // ─── Chip ───────────────────────────────────────────────────────
966
+ MuiChip: {
967
+ styleOverrides: {
968
+ root: {
969
+ borderRadius: radius2.md,
970
+ fontWeight: 500,
971
+ fontSize: 14
972
+ }
977
973
  }
978
- }
979
- },
980
- MuiTableCell: {
981
- styleOverrides: {
982
- root: {
983
- borderBottom: `1px solid ${colors.gray[200]}`,
984
- padding: "16px 24px",
985
- fontSize: 14,
986
- lineHeight: "20px",
987
- color: colors.gray[600]
988
- },
989
- head: {
990
- backgroundColor: colors.gray[50],
991
- color: colors.gray[600],
992
- fontWeight: 500,
993
- fontSize: 12,
994
- lineHeight: "18px"
995
- },
996
- body: {
997
- color: colors.gray[600]
974
+ },
975
+ // ─── Form Control / Label ───────────────────────────────────────
976
+ MuiFormControlLabel: {
977
+ styleOverrides: {
978
+ root: {
979
+ marginLeft: 0,
980
+ gap: 8
981
+ },
982
+ label: {
983
+ fontSize: 14,
984
+ lineHeight: "20px",
985
+ fontWeight: 500,
986
+ color: colors2.gray[700]
987
+ }
998
988
  }
999
- }
1000
- },
1001
- MuiTableHead: {
1002
- styleOverrides: {
1003
- root: {
1004
- backgroundColor: colors.gray[50],
1005
- borderBottom: `1px solid ${colors.gray[200]}`
989
+ },
990
+ // ─── Table ───────────────────────────────────────────────────────
991
+ MuiTable: {
992
+ styleOverrides: {
993
+ root: {
994
+ borderCollapse: "separate",
995
+ borderSpacing: 0
996
+ }
1006
997
  }
1007
- }
1008
- },
1009
- MuiTableRow: {
1010
- styleOverrides: {
1011
- root: {
1012
- "&:last-child td, &:last-child th": {
1013
- border: 0
998
+ },
999
+ MuiTableCell: {
1000
+ styleOverrides: {
1001
+ root: {
1002
+ borderBottom: `1px solid ${colors2.gray[200]}`,
1003
+ padding: "16px 24px",
1004
+ fontSize: 14,
1005
+ lineHeight: "20px",
1006
+ color: colors2.gray[600]
1014
1007
  },
1015
- "&:hover": {
1016
- backgroundColor: colors.gray[50]
1008
+ head: {
1009
+ backgroundColor: colors2.gray[50],
1010
+ color: colors2.gray[600],
1011
+ fontWeight: 500,
1012
+ fontSize: 12,
1013
+ lineHeight: "18px"
1017
1014
  },
1018
- "&.Mui-selected": {
1019
- backgroundColor: colors.brand[50],
1015
+ body: {
1016
+ color: colors2.gray[600]
1017
+ }
1018
+ }
1019
+ },
1020
+ MuiTableHead: {
1021
+ styleOverrides: {
1022
+ root: {
1023
+ backgroundColor: colors2.gray[50],
1024
+ borderBottom: `1px solid ${colors2.gray[200]}`
1025
+ }
1026
+ }
1027
+ },
1028
+ MuiTableRow: {
1029
+ styleOverrides: {
1030
+ root: {
1031
+ "&:last-child td, &:last-child th": {
1032
+ border: 0
1033
+ },
1020
1034
  "&:hover": {
1021
- backgroundColor: colors.brand[50]
1035
+ backgroundColor: colors2.gray[50]
1036
+ },
1037
+ "&.Mui-selected": {
1038
+ backgroundColor: colors2.brand[50],
1039
+ "&:hover": {
1040
+ backgroundColor: colors2.brand[50]
1041
+ }
1022
1042
  }
1023
1043
  }
1024
1044
  }
1025
- }
1026
- },
1027
- MuiTableContainer: {
1028
- styleOverrides: {
1029
- root: {
1030
- borderRadius: radius.xl,
1031
- border: `1px solid ${colors.gray[200]}`,
1032
- boxShadow: "none"
1045
+ },
1046
+ MuiTableContainer: {
1047
+ styleOverrides: {
1048
+ root: {
1049
+ borderRadius: radius2.xl,
1050
+ border: `1px solid ${colors2.gray[200]}`,
1051
+ boxShadow: "none"
1052
+ }
1033
1053
  }
1034
- }
1035
- },
1036
- // ─── Badge ──────────────────────────────────────────────────────
1037
- MuiBadge: {
1038
- styleOverrides: {
1039
- standard: {
1040
- fontWeight: 500,
1041
- fontSize: 12,
1042
- lineHeight: "18px",
1043
- minWidth: 20,
1044
- height: 20,
1045
- borderRadius: radius.full
1046
- },
1047
- colorPrimary: {
1048
- backgroundColor: colors.brand[600]
1049
- },
1050
- colorError: {
1051
- backgroundColor: colors.error[600]
1052
- },
1053
- colorSuccess: {
1054
- backgroundColor: colors.success[600]
1055
- },
1056
- colorWarning: {
1057
- backgroundColor: colors.warning[600]
1058
- },
1059
- dot: {
1060
- minWidth: 8,
1061
- height: 8,
1062
- borderRadius: radius.full
1054
+ },
1055
+ // ─── Badge ──────────────────────────────────────────────────────
1056
+ MuiBadge: {
1057
+ styleOverrides: {
1058
+ standard: {
1059
+ fontWeight: 500,
1060
+ fontSize: 12,
1061
+ lineHeight: "18px",
1062
+ minWidth: 20,
1063
+ height: 20,
1064
+ borderRadius: radius2.full
1065
+ },
1066
+ colorPrimary: {
1067
+ backgroundColor: colors2.brand[600]
1068
+ },
1069
+ colorError: {
1070
+ backgroundColor: colors2.error[600]
1071
+ },
1072
+ colorSuccess: {
1073
+ backgroundColor: colors2.success[600]
1074
+ },
1075
+ colorWarning: {
1076
+ backgroundColor: colors2.warning[600]
1077
+ },
1078
+ dot: {
1079
+ minWidth: 8,
1080
+ height: 8,
1081
+ borderRadius: radius2.full
1082
+ }
1063
1083
  }
1064
- }
1065
- },
1066
- // ─── Divider ────────────────────────────────────────────────────
1067
- MuiDivider: {
1068
- styleOverrides: {
1069
- root: {
1070
- borderColor: colors.gray[200]
1084
+ },
1085
+ // ─── Divider ────────────────────────────────────────────────────
1086
+ MuiDivider: {
1087
+ styleOverrides: {
1088
+ root: {
1089
+ borderColor: colors2.gray[200]
1090
+ }
1071
1091
  }
1072
- }
1073
- },
1074
- // ─── List ───────────────────────────────────────────────────────
1075
- MuiList: {
1076
- styleOverrides: {
1077
- root: {
1078
- padding: 4
1092
+ },
1093
+ // ─── List ───────────────────────────────────────────────────────
1094
+ MuiList: {
1095
+ styleOverrides: {
1096
+ root: {
1097
+ padding: 4
1098
+ }
1079
1099
  }
1080
- }
1081
- },
1082
- MuiListItemButton: {
1083
- styleOverrides: {
1084
- root: {
1085
- borderRadius: radius.sm,
1086
- padding: "8px 12px",
1087
- "&:hover": {
1088
- backgroundColor: colors.gray[50]
1089
- },
1090
- "&.Mui-selected": {
1091
- backgroundColor: colors.brand[50],
1092
- color: colors.brand[700],
1100
+ },
1101
+ MuiListItemButton: {
1102
+ styleOverrides: {
1103
+ root: {
1104
+ borderRadius: radius2.sm,
1105
+ padding: "8px 12px",
1093
1106
  "&:hover": {
1094
- backgroundColor: colors.brand[100]
1107
+ backgroundColor: colors2.gray[50]
1108
+ },
1109
+ "&.Mui-selected": {
1110
+ backgroundColor: colors2.brand[50],
1111
+ color: colors2.brand[700],
1112
+ "&:hover": {
1113
+ backgroundColor: colors2.brand[100]
1114
+ }
1095
1115
  }
1096
1116
  }
1097
1117
  }
1098
- }
1099
- },
1100
- MuiListItemIcon: {
1101
- styleOverrides: {
1102
- root: {
1103
- minWidth: 36,
1104
- color: colors.gray[500]
1105
- }
1106
- }
1107
- },
1108
- MuiListItemText: {
1109
- styleOverrides: {
1110
- primary: {
1111
- fontSize: 14,
1112
- lineHeight: "20px",
1113
- fontWeight: 500,
1114
- color: colors.gray[700]
1115
- },
1116
- secondary: {
1117
- fontSize: 14,
1118
- lineHeight: "20px",
1119
- color: colors.gray[500]
1118
+ },
1119
+ MuiListItemIcon: {
1120
+ styleOverrides: {
1121
+ root: {
1122
+ minWidth: 36,
1123
+ color: colors2.gray[500]
1124
+ }
1120
1125
  }
1121
- }
1122
- },
1123
- // ─── Tooltip ────────────────────────────────────────────────────
1124
- MuiTooltip: {
1125
- styleOverrides: {
1126
- tooltip: {
1127
- backgroundColor: colors.gray[900],
1128
- color: colors.base.white,
1129
- fontSize: 12,
1130
- lineHeight: "18px",
1131
- fontWeight: 600,
1132
- padding: "8px 12px",
1133
- borderRadius: radius.md,
1134
- boxShadow: shadows.lg
1135
- },
1136
- arrow: {
1137
- color: colors.gray[900]
1126
+ },
1127
+ MuiListItemText: {
1128
+ styleOverrides: {
1129
+ primary: {
1130
+ fontSize: 14,
1131
+ lineHeight: "20px",
1132
+ fontWeight: 500,
1133
+ color: colors2.gray[700]
1134
+ },
1135
+ secondary: {
1136
+ fontSize: 14,
1137
+ lineHeight: "20px",
1138
+ color: colors2.gray[500]
1139
+ }
1138
1140
  }
1139
- }
1140
- },
1141
- // ─── Alert ──────────────────────────────────────────────────────
1142
- MuiAlert: {
1143
- defaultProps: {
1144
- variant: "standard"
1145
- },
1146
- styleOverrides: {
1147
- root: {
1148
- borderRadius: radius.xl,
1149
- fontSize: 14,
1150
- lineHeight: "20px",
1151
- padding: "12px 16px"
1152
- },
1153
- standardError: {
1154
- backgroundColor: colors.error[50],
1155
- color: colors.error[700],
1156
- border: `1px solid ${colors.error[300]}`,
1157
- "& .MuiAlert-icon": {
1158
- color: colors.error[600]
1141
+ },
1142
+ // ─── Tooltip ────────────────────────────────────────────────────
1143
+ MuiTooltip: {
1144
+ styleOverrides: {
1145
+ tooltip: {
1146
+ backgroundColor: colors2.gray[900],
1147
+ color: colors2.base.white,
1148
+ fontSize: 12,
1149
+ lineHeight: "18px",
1150
+ fontWeight: 600,
1151
+ padding: "8px 12px",
1152
+ borderRadius: radius2.md,
1153
+ boxShadow: tokenShadows.lg
1154
+ },
1155
+ arrow: {
1156
+ color: colors2.gray[900]
1159
1157
  }
1158
+ }
1159
+ },
1160
+ // ─── Alert ──────────────────────────────────────────────────────
1161
+ MuiAlert: {
1162
+ defaultProps: {
1163
+ variant: "standard"
1160
1164
  },
1161
- standardWarning: {
1162
- backgroundColor: colors.warning[50],
1163
- color: colors.warning[700],
1164
- border: `1px solid ${colors.warning[300]}`,
1165
- "& .MuiAlert-icon": {
1166
- color: colors.warning[600]
1165
+ styleOverrides: {
1166
+ root: {
1167
+ borderRadius: radius2.xl,
1168
+ fontSize: 14,
1169
+ lineHeight: "20px",
1170
+ padding: "12px 16px"
1171
+ },
1172
+ standardError: {
1173
+ backgroundColor: colors2.error[50],
1174
+ color: colors2.error[700],
1175
+ border: `1px solid ${colors2.error[300]}`,
1176
+ "& .MuiAlert-icon": {
1177
+ color: colors2.error[600]
1178
+ }
1179
+ },
1180
+ standardWarning: {
1181
+ backgroundColor: colors2.warning[50],
1182
+ color: colors2.warning[700],
1183
+ border: `1px solid ${colors2.warning[300]}`,
1184
+ "& .MuiAlert-icon": {
1185
+ color: colors2.warning[600]
1186
+ }
1187
+ },
1188
+ standardSuccess: {
1189
+ backgroundColor: colors2.success[50],
1190
+ color: colors2.success[700],
1191
+ border: `1px solid ${colors2.success[300]}`,
1192
+ "& .MuiAlert-icon": {
1193
+ color: colors2.success[600]
1194
+ }
1195
+ },
1196
+ standardInfo: {
1197
+ backgroundColor: colors2.blue[50],
1198
+ color: colors2.blue[700],
1199
+ border: `1px solid ${colors2.blue[300]}`,
1200
+ "& .MuiAlert-icon": {
1201
+ color: colors2.blue[600]
1202
+ }
1203
+ },
1204
+ icon: {
1205
+ padding: "2px 0"
1167
1206
  }
1168
- },
1169
- standardSuccess: {
1170
- backgroundColor: colors.success[50],
1171
- color: colors.success[700],
1172
- border: `1px solid ${colors.success[300]}`,
1173
- "& .MuiAlert-icon": {
1174
- color: colors.success[600]
1207
+ }
1208
+ },
1209
+ MuiAlertTitle: {
1210
+ styleOverrides: {
1211
+ root: {
1212
+ fontWeight: 600,
1213
+ fontSize: 14,
1214
+ lineHeight: "20px",
1215
+ marginBottom: 4
1175
1216
  }
1176
- },
1177
- standardInfo: {
1178
- backgroundColor: colors.blue[50],
1179
- color: colors.blue[700],
1180
- border: `1px solid ${colors.blue[300]}`,
1181
- "& .MuiAlert-icon": {
1182
- color: colors.blue[600]
1217
+ }
1218
+ },
1219
+ // ─── Backdrop ───────────────────────────────────────────────────
1220
+ MuiBackdrop: {
1221
+ styleOverrides: {
1222
+ root: {
1223
+ backgroundColor: "rgba(16, 24, 40, 0.7)"
1183
1224
  }
1184
- },
1185
- icon: {
1186
- padding: "2px 0"
1187
1225
  }
1188
- }
1189
- },
1190
- MuiAlertTitle: {
1191
- styleOverrides: {
1192
- root: {
1193
- fontWeight: 600,
1194
- fontSize: 14,
1195
- lineHeight: "20px",
1196
- marginBottom: 4
1226
+ },
1227
+ // ─── Dialog ─────────────────────────────────────────────────────
1228
+ MuiDialog: {
1229
+ styleOverrides: {
1230
+ paper: {
1231
+ borderRadius: radius2.xl,
1232
+ boxShadow: tokenShadows.xl,
1233
+ padding: 0
1234
+ }
1197
1235
  }
1198
- }
1199
- },
1200
- // ─── Backdrop ───────────────────────────────────────────────────
1201
- MuiBackdrop: {
1202
- styleOverrides: {
1203
- root: {
1204
- backgroundColor: "rgba(16, 24, 40, 0.7)"
1236
+ },
1237
+ MuiDialogTitle: {
1238
+ styleOverrides: {
1239
+ root: {
1240
+ fontSize: 18,
1241
+ lineHeight: "28px",
1242
+ fontWeight: 600,
1243
+ color: colors2.gray[900],
1244
+ padding: "24px 24px 0"
1245
+ }
1205
1246
  }
1206
- }
1207
- },
1208
- // ─── Dialog ─────────────────────────────────────────────────────
1209
- MuiDialog: {
1210
- styleOverrides: {
1211
- paper: {
1212
- borderRadius: radius.xl,
1213
- boxShadow: shadows.xl,
1214
- padding: 0
1247
+ },
1248
+ MuiDialogContent: {
1249
+ styleOverrides: {
1250
+ root: {
1251
+ padding: "20px 24px",
1252
+ fontSize: 14,
1253
+ lineHeight: "20px",
1254
+ color: colors2.gray[600]
1255
+ }
1215
1256
  }
1216
- }
1217
- },
1218
- MuiDialogTitle: {
1219
- styleOverrides: {
1220
- root: {
1221
- fontSize: 18,
1222
- lineHeight: "28px",
1223
- fontWeight: 600,
1224
- color: colors.gray[900],
1225
- padding: "24px 24px 0"
1257
+ },
1258
+ MuiDialogActions: {
1259
+ styleOverrides: {
1260
+ root: {
1261
+ padding: "0 24px 24px",
1262
+ gap: 12
1263
+ }
1226
1264
  }
1227
- }
1228
- },
1229
- MuiDialogContent: {
1230
- styleOverrides: {
1231
- root: {
1232
- padding: "20px 24px",
1233
- fontSize: 14,
1234
- lineHeight: "20px",
1235
- color: colors.gray[600]
1265
+ },
1266
+ // ─── Progress ───────────────────────────────────────────────────
1267
+ MuiLinearProgress: {
1268
+ styleOverrides: {
1269
+ root: {
1270
+ borderRadius: radius2.full,
1271
+ height: 8,
1272
+ backgroundColor: colors2.gray[200]
1273
+ },
1274
+ barColorPrimary: {
1275
+ backgroundColor: colors2.brand[600],
1276
+ borderRadius: radius2.full
1277
+ },
1278
+ barColorSecondary: {
1279
+ backgroundColor: colors2.gray[600],
1280
+ borderRadius: radius2.full
1281
+ }
1236
1282
  }
1237
- }
1238
- },
1239
- MuiDialogActions: {
1240
- styleOverrides: {
1241
- root: {
1242
- padding: "0 24px 24px",
1243
- gap: 12
1283
+ },
1284
+ MuiCircularProgress: {
1285
+ styleOverrides: {
1286
+ colorPrimary: {
1287
+ color: colors2.brand[600]
1288
+ },
1289
+ colorSecondary: {
1290
+ color: colors2.gray[600]
1291
+ }
1244
1292
  }
1245
- }
1246
- },
1247
- // ─── Progress ───────────────────────────────────────────────────
1248
- MuiLinearProgress: {
1249
- styleOverrides: {
1250
- root: {
1251
- borderRadius: radius.full,
1252
- height: 8,
1253
- backgroundColor: colors.gray[200]
1254
- },
1255
- barColorPrimary: {
1256
- backgroundColor: colors.brand[600],
1257
- borderRadius: radius.full
1293
+ },
1294
+ // ─── Skeleton ───────────────────────────────────────────────────
1295
+ MuiSkeleton: {
1296
+ defaultProps: {
1297
+ animation: "wave"
1258
1298
  },
1259
- barColorSecondary: {
1260
- backgroundColor: colors.gray[600],
1261
- borderRadius: radius.full
1299
+ styleOverrides: {
1300
+ root: {
1301
+ backgroundColor: colors2.gray[100]
1302
+ },
1303
+ rounded: {
1304
+ borderRadius: radius2.md
1305
+ },
1306
+ circular: {
1307
+ borderRadius: radius2.full
1308
+ }
1262
1309
  }
1263
- }
1264
- },
1265
- MuiCircularProgress: {
1266
- styleOverrides: {
1267
- colorPrimary: {
1268
- color: colors.brand[600]
1269
- },
1270
- colorSecondary: {
1271
- color: colors.gray[600]
1310
+ },
1311
+ // ─── Snackbar ───────────────────────────────────────────────────
1312
+ MuiSnackbarContent: {
1313
+ styleOverrides: {
1314
+ root: {
1315
+ backgroundColor: colors2.gray[900],
1316
+ color: colors2.base.white,
1317
+ borderRadius: radius2.xl,
1318
+ boxShadow: tokenShadows.lg,
1319
+ fontSize: 14,
1320
+ lineHeight: "20px",
1321
+ fontWeight: 500,
1322
+ padding: "6px 16px"
1323
+ }
1272
1324
  }
1273
- }
1274
- },
1275
- // ─── Skeleton ───────────────────────────────────────────────────
1276
- MuiSkeleton: {
1277
- defaultProps: {
1278
- animation: "wave"
1279
- },
1280
- styleOverrides: {
1281
- root: {
1282
- backgroundColor: colors.gray[100]
1283
- },
1284
- rounded: {
1285
- borderRadius: radius.md
1286
- },
1287
- circular: {
1288
- borderRadius: radius.full
1325
+ },
1326
+ // ─── Typography ─────────────────────────────────────────────────
1327
+ MuiTypography: {
1328
+ defaultProps: {
1329
+ variantMapping: {
1330
+ h1: "h1",
1331
+ h2: "h2",
1332
+ h3: "h3",
1333
+ h4: "h4",
1334
+ h5: "h5",
1335
+ h6: "h6",
1336
+ subtitle1: "p",
1337
+ subtitle2: "p",
1338
+ body1: "p",
1339
+ body2: "p",
1340
+ caption: "span",
1341
+ overline: "span"
1342
+ }
1289
1343
  }
1290
1344
  }
1291
- },
1292
- // ─── Snackbar ───────────────────────────────────────────────────
1293
- MuiSnackbarContent: {
1294
- styleOverrides: {
1295
- root: {
1296
- backgroundColor: colors.gray[900],
1297
- color: colors.base.white,
1298
- borderRadius: radius.xl,
1299
- boxShadow: shadows.lg,
1300
- fontSize: 14,
1301
- lineHeight: "20px",
1302
- fontWeight: 500,
1303
- padding: "6px 16px"
1304
- }
1345
+ };
1346
+ }
1347
+ var components = buildComponents({
1348
+ colors,
1349
+ radius,
1350
+ focusRings,
1351
+ shadows
1352
+ });
1353
+
1354
+ // src/theme/shadows.ts
1355
+ function buildShadows(tokens) {
1356
+ const tokenShadows = tokens.shadows;
1357
+ return [
1358
+ "none",
1359
+ // 0
1360
+ tokenShadows.xs,
1361
+ // 1
1362
+ tokenShadows.sm,
1363
+ // 2
1364
+ tokenShadows.sm,
1365
+ // 3
1366
+ tokenShadows.md,
1367
+ // 4
1368
+ tokenShadows.md,
1369
+ // 5
1370
+ tokenShadows.md,
1371
+ // 6
1372
+ tokenShadows.lg,
1373
+ // 7
1374
+ tokenShadows.lg,
1375
+ // 8
1376
+ tokenShadows.lg,
1377
+ // 9
1378
+ tokenShadows.xl,
1379
+ // 10
1380
+ tokenShadows.xl,
1381
+ // 11
1382
+ tokenShadows.xl,
1383
+ // 12
1384
+ tokenShadows["2xl"],
1385
+ // 13
1386
+ tokenShadows["2xl"],
1387
+ // 14
1388
+ tokenShadows["2xl"],
1389
+ // 15
1390
+ tokenShadows["3xl"],
1391
+ // 16
1392
+ tokenShadows["3xl"],
1393
+ // 17
1394
+ tokenShadows["3xl"],
1395
+ // 18
1396
+ tokenShadows["3xl"],
1397
+ // 19
1398
+ tokenShadows["3xl"],
1399
+ // 20
1400
+ tokenShadows["3xl"],
1401
+ // 21
1402
+ tokenShadows["3xl"],
1403
+ // 22
1404
+ tokenShadows["3xl"],
1405
+ // 23
1406
+ tokenShadows["3xl"]
1407
+ // 24
1408
+ ];
1409
+ }
1410
+ var shadows2 = buildShadows({
1411
+ shadows
1412
+ });
1413
+ function buildThemeOptions(tokens) {
1414
+ return {
1415
+ palette: buildPalette(tokens),
1416
+ typography: buildTypography(tokens),
1417
+ components: buildComponents(tokens),
1418
+ shadows: buildShadows(tokens),
1419
+ shape: {
1420
+ borderRadius: tokens.radius.md
1305
1421
  }
1306
- },
1307
- // ─── Typography ─────────────────────────────────────────────────
1308
- MuiTypography: {
1309
- defaultProps: {
1310
- variantMapping: {
1311
- h1: "h1",
1312
- h2: "h2",
1313
- h3: "h3",
1314
- h4: "h4",
1315
- h5: "h5",
1316
- h6: "h6",
1317
- subtitle1: "p",
1318
- subtitle2: "p",
1319
- body1: "p",
1320
- body2: "p",
1321
- caption: "span",
1322
- overline: "span"
1422
+ };
1423
+ }
1424
+ function buildTheme(tokens) {
1425
+ return styles.createTheme(buildThemeOptions(tokens));
1426
+ }
1427
+
1428
+ // src/theme/presets/forest.ts
1429
+ var forestPreset = {
1430
+ name: "forest",
1431
+ defaultVariant: "light",
1432
+ variants: {
1433
+ light: {
1434
+ tokens: {
1435
+ colors,
1436
+ spacing,
1437
+ radius,
1438
+ shadows,
1439
+ focusRings,
1440
+ fontFamily,
1441
+ fontSize,
1442
+ lineHeight,
1443
+ fontWeight,
1444
+ display,
1445
+ container,
1446
+ widths
1323
1447
  }
1324
1448
  }
1325
1449
  }
1326
1450
  };
1327
1451
 
1328
- // src/theme/shadows.ts
1329
- var shadows2 = [
1330
- "none",
1331
- // 0
1332
- shadows.xs,
1333
- // 1
1334
- shadows.sm,
1335
- // 2
1336
- shadows.sm,
1337
- // 3
1338
- shadows.md,
1339
- // 4
1340
- shadows.md,
1341
- // 5
1342
- shadows.md,
1343
- // 6
1344
- shadows.lg,
1345
- // 7
1346
- shadows.lg,
1347
- // 8
1348
- shadows.lg,
1349
- // 9
1350
- shadows.xl,
1351
- // 10
1352
- shadows.xl,
1353
- // 11
1354
- shadows.xl,
1355
- // 12
1356
- shadows["2xl"],
1357
- // 13
1358
- shadows["2xl"],
1359
- // 14
1360
- shadows["2xl"],
1361
- // 15
1362
- shadows["3xl"],
1363
- // 16
1364
- shadows["3xl"],
1365
- // 17
1366
- shadows["3xl"],
1367
- // 18
1368
- shadows["3xl"],
1369
- // 19
1370
- shadows["3xl"],
1371
- // 20
1372
- shadows["3xl"],
1373
- // 21
1374
- shadows["3xl"],
1375
- // 22
1376
- shadows["3xl"],
1377
- // 23
1378
- shadows["3xl"]
1379
- // 24
1380
- ];
1452
+ // src/theme/presets/index.ts
1453
+ var presetRegistry = /* @__PURE__ */ new Map();
1454
+ presetRegistry.set(forestPreset.name, forestPreset);
1455
+ function getPreset(name) {
1456
+ return presetRegistry.get(name);
1457
+ }
1458
+ function registerPreset(preset) {
1459
+ presetRegistry.set(preset.name, preset);
1460
+ }
1461
+ function getAvailablePresets() {
1462
+ return Array.from(presetRegistry.keys());
1463
+ }
1381
1464
 
1382
1465
  // src/theme/index.ts
1383
1466
  var forestThemeOptions = {
@@ -1392,10 +1475,30 @@ var forestThemeOptions = {
1392
1475
  var forestTheme = styles.createTheme(forestThemeOptions);
1393
1476
  function ForestProvider({
1394
1477
  children,
1395
- theme = forestTheme,
1478
+ theme,
1479
+ preset,
1480
+ variant,
1396
1481
  disableCssBaseline = false
1397
1482
  }) {
1398
- return /* @__PURE__ */ jsxRuntime.jsxs(styles.ThemeProvider, { theme, children: [
1483
+ const resolvedTheme = react.useMemo(() => {
1484
+ if (theme) return theme;
1485
+ if (!preset) return forestTheme;
1486
+ const presetConfig = getPreset(preset);
1487
+ if (!presetConfig) {
1488
+ throw new Error(
1489
+ `[ForestProvider] Unknown preset "${preset}". Available presets: use getAvailablePresets() to see registered presets.`
1490
+ );
1491
+ }
1492
+ const variantName = variant != null ? variant : presetConfig.defaultVariant;
1493
+ const variantConfig = presetConfig.variants[variantName];
1494
+ if (!variantConfig) {
1495
+ throw new Error(
1496
+ `[ForestProvider] Unknown variant "${variantName}" for preset "${preset}". Available variants: ${Object.keys(presetConfig.variants).join(", ")}.`
1497
+ );
1498
+ }
1499
+ return buildTheme(variantConfig.tokens);
1500
+ }, [theme, preset, variant]);
1501
+ return /* @__PURE__ */ jsxRuntime.jsxs(styles.ThemeProvider, { theme: resolvedTheme, children: [
1399
1502
  !disableCssBaseline && /* @__PURE__ */ jsxRuntime.jsx(CssBaseline__default.default, {}),
1400
1503
  children
1401
1504
  ] });
@@ -1574,6 +1677,8 @@ exports.ToggleButton = ToggleButton;
1574
1677
  exports.ToggleButtonGroup = ToggleButtonGroup;
1575
1678
  exports.Tooltip = Tooltip;
1576
1679
  exports.Typography = Typography;
1680
+ exports.buildTheme = buildTheme;
1681
+ exports.buildThemeOptions = buildThemeOptions;
1577
1682
  exports.colors = colors;
1578
1683
  exports.container = container;
1579
1684
  exports.display = display;
@@ -1581,10 +1686,14 @@ exports.focusRings = focusRings;
1581
1686
  exports.fontFamily = fontFamily;
1582
1687
  exports.fontSize = fontSize;
1583
1688
  exports.fontWeight = fontWeight;
1689
+ exports.forestPreset = forestPreset;
1584
1690
  exports.forestTheme = forestTheme;
1585
1691
  exports.forestThemeOptions = forestThemeOptions;
1692
+ exports.getAvailablePresets = getAvailablePresets;
1693
+ exports.getPreset = getPreset;
1586
1694
  exports.lineHeight = lineHeight;
1587
1695
  exports.radius = radius;
1696
+ exports.registerPreset = registerPreset;
1588
1697
  exports.spacing = spacing;
1589
1698
  exports.tokenShadows = shadows;
1590
1699
  exports.widths = widths;