@webmate-studio/builder 0.2.152 → 0.2.156

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@webmate-studio/builder",
3
- "version": "0.2.152",
3
+ "version": "0.2.156",
4
4
  "type": "module",
5
5
  "description": "Webmate Studio Component Builder",
6
6
  "keywords": [
@@ -14,7 +14,8 @@ import {
14
14
  BUTTON_SIZES,
15
15
  calculateOnColor,
16
16
  DEFAULT_SURFACE_TOKENS,
17
- defaultDesignTokensV2
17
+ defaultDesignTokensV2,
18
+ normalizeShadowValue
18
19
  } from './design-tokens-v2.js';
19
20
 
20
21
 
@@ -536,6 +537,11 @@ function generateButtonVariables(t, lines) {
536
537
  lines.push(` --btn-${size}-padding-x: ${s.paddingX};`);
537
538
  lines.push(` --btn-${size}-padding-y: ${s.paddingY};`);
538
539
  lines.push(` --btn-${size}-font-size: ${s.fontSize};`);
540
+ if (s.fontFamily) {
541
+ const fontDef = t.typography?.fonts?.find(f => f.name === s.fontFamily);
542
+ const fallback = fontDef?.fallback || 'sans-serif';
543
+ lines.push(` --btn-${size}-font-family: "${s.fontFamily}", ${fallback};`);
544
+ }
539
545
  lines.push(` --btn-${size}-font-weight: ${s.fontWeight};`);
540
546
  lines.push(` --btn-${size}-line-height: ${s.lineHeight};`);
541
547
  lines.push(` --btn-${size}-letter-spacing: ${s.letterSpacing};`);
@@ -567,16 +573,58 @@ function generateButtonVariables(t, lines) {
567
573
  }
568
574
  }
569
575
 
576
+ /**
577
+ * Prüft ob ein Shadow-Wert echte Daten enthält.
578
+ */
579
+ function hasShadow(val) {
580
+ if (!val || val === 'none') return false;
581
+ if (Array.isArray(val)) return val.length > 0;
582
+ return true;
583
+ }
584
+
585
+ /**
586
+ * Konvertiert strukturierte Shadow-Layer zu einem CSS box-shadow String.
587
+ */
588
+ function resolveShadowToCSS(shadowValue, t) {
589
+ const normalized = normalizeShadowValue(shadowValue);
590
+ if (normalized === 'none' || !Array.isArray(normalized) || normalized.length === 0) return 'none';
591
+
592
+ return normalized.map(layer => {
593
+ const insetStr = layer.inset ? 'inset ' : '';
594
+ const colorResolved = resolveColorRef(layer.color, t);
595
+ const colorCSS = (layer.opacity != null && layer.opacity < 100)
596
+ ? `color-mix(in srgb, ${colorResolved} ${layer.opacity}%, transparent)`
597
+ : colorResolved;
598
+ return `${insetStr}${layer.offsetX || 0}px ${layer.offsetY || 0}px ${layer.blur || 0}px ${layer.spread || 0}px ${colorCSS}`;
599
+ }).join(', ');
600
+ }
601
+
570
602
  function addButtonVariantVars(lines, prefix, variant, t) {
571
603
  if (variant.bg) lines.push(` --${prefix}-bg: ${resolveColorRef(variant.bg, t)};`);
572
604
  if (variant.bgHover) lines.push(` --${prefix}-bg-hover: ${resolveColorRef(variant.bgHover, t)};`);
605
+ if (variant.bgActive) lines.push(` --${prefix}-bg-active: ${resolveColorRef(variant.bgActive, t)};`);
573
606
  if (variant.text) lines.push(` --${prefix}-text: ${resolveColorRef(variant.text, t)};`);
574
607
  if (variant.textHover) lines.push(` --${prefix}-text-hover: ${resolveColorRef(variant.textHover, t)};`);
608
+ if (variant.textActive) lines.push(` --${prefix}-text-active: ${resolveColorRef(variant.textActive, t)};`);
575
609
  if (variant.border && variant.border !== 'none') lines.push(` --${prefix}-border: 1px solid ${resolveColorRef(variant.border, t)};`);
576
610
  if (variant.borderHover && variant.borderHover !== 'none') lines.push(` --${prefix}-border-hover: 1px solid ${resolveColorRef(variant.borderHover, t)};`);
577
- if (variant.shadow && variant.shadow !== 'none') lines.push(` --${prefix}-shadow: ${variant.shadow};`);
578
- if (variant.shadowHover && variant.shadowHover !== 'none') lines.push(` --${prefix}-shadow-hover: ${variant.shadowHover};`);
611
+ if (variant.borderActive && variant.borderActive !== 'none') lines.push(` --${prefix}-border-active: 1px solid ${resolveColorRef(variant.borderActive, t)};`);
612
+ const shadowCSS = resolveShadowToCSS(variant.shadow, t);
613
+ if (shadowCSS !== 'none') lines.push(` --${prefix}-shadow: ${shadowCSS};`);
614
+ const shadowHoverCSS = resolveShadowToCSS(variant.shadowHover, t);
615
+ if (shadowHoverCSS !== 'none') lines.push(` --${prefix}-shadow-hover: ${shadowHoverCSS};`);
616
+ const shadowActiveCSS = resolveShadowToCSS(variant.shadowActive, t);
617
+ if (shadowActiveCSS !== 'none') lines.push(` --${prefix}-shadow-active: ${shadowActiveCSS};`);
579
618
  if (variant.focusRingColor) lines.push(` --${prefix}-focus-ring: ${resolveColorRef(variant.focusRingColor, t)};`);
619
+ if (variant.fontFamily) {
620
+ const fontDef = t.typography?.fonts?.find(f => f.name === variant.fontFamily);
621
+ const fallback = fontDef?.fallback || 'sans-serif';
622
+ lines.push(` --${prefix}-font-family: "${variant.fontFamily}", ${fallback};`);
623
+ }
624
+ if (variant.fontSizeScale != null && variant.fontSizeScale !== 1) lines.push(` --${prefix}-font-scale: ${variant.fontSizeScale};`);
625
+ if (variant.fontWeight) lines.push(` --${prefix}-font-weight: ${variant.fontWeight};`);
626
+ if (variant.letterSpacing && variant.letterSpacing !== 'normal') lines.push(` --${prefix}-letter-spacing: ${variant.letterSpacing};`);
627
+ if (variant.textTransform && variant.textTransform !== 'none') lines.push(` --${prefix}-text-transform: ${variant.textTransform};`);
580
628
  }
581
629
 
582
630
  /**
@@ -621,6 +669,7 @@ function generateButtonClasses(t) {
621
669
  white-space: nowrap;
622
670
  transition: var(--btn-transition);
623
671
  border: none;
672
+ --btn-font-scale: 1;
624
673
  }`;
625
674
 
626
675
  // Disabled
@@ -632,17 +681,21 @@ function generateButtonClasses(t) {
632
681
 
633
682
  // Size classes
634
683
  for (const size of BUTTON_SIZES) {
635
- if (!t.buttons.sizes?.[size]) continue;
684
+ const s = t.buttons.sizes?.[size];
685
+ if (!s) continue;
636
686
  css += `\n.btn-${size} {
637
687
  padding: var(--btn-${size}-padding-y) var(--btn-${size}-padding-x);
638
- font-size: var(--btn-${size}-font-size);
688
+ font-size: calc(var(--btn-${size}-font-size) * var(--btn-font-scale, 1));
639
689
  font-weight: var(--btn-${size}-font-weight);
640
690
  line-height: var(--btn-${size}-line-height);
641
691
  letter-spacing: var(--btn-${size}-letter-spacing);
642
692
  border-radius: var(--btn-${size}-border-radius);
643
693
  min-height: var(--btn-${size}-min-height);
644
- gap: var(--btn-${size}-gap);
645
- }`;
694
+ gap: var(--btn-${size}-gap);`;
695
+ if (s.fontFamily) {
696
+ css += `\n font-family: var(--btn-${size}-font-family);`;
697
+ }
698
+ css += '\n}';
646
699
  css += `\n.btn-${size} iconify-icon { font-size: var(--btn-${size}-icon-size); }`;
647
700
  }
648
701
 
@@ -656,7 +709,7 @@ function generateButtonClasses(t) {
656
709
  // customCSS Escape-Hatch
657
710
  css += generateCustomCSSBlock(`btn-${variant}`, v.normal.customCSS);
658
711
  } else if (v.normal) {
659
- css += generateVariantNormalCSS(variant, v);
712
+ css += generateVariantNormalCSS(variant, v, t);
660
713
  }
661
714
 
662
715
  // On-surface mode
@@ -671,7 +724,7 @@ function generateButtonClasses(t) {
671
724
  return css;
672
725
  }
673
726
 
674
- function generateVariantNormalCSS(variant, v) {
727
+ function generateVariantNormalCSS(variant, v, t) {
675
728
  const p = `btn-${variant}`;
676
729
  let css = `\n.${p} {
677
730
  background: var(--${p}-bg);
@@ -680,12 +733,28 @@ function generateVariantNormalCSS(variant, v) {
680
733
  if (v.normal.border && v.normal.border !== 'none') {
681
734
  css += `\n border: var(--${p}-border);`;
682
735
  }
683
- if (v.normal.shadow && v.normal.shadow !== 'none') {
736
+ if (hasShadow(v.normal.shadow)) {
684
737
  css += `\n box-shadow: var(--${p}-shadow);`;
685
738
  }
686
739
  if (v.normal.textDecoration) {
687
740
  css += `\n text-decoration: ${v.normal.textDecoration};`;
688
741
  }
742
+ // Typography overrides
743
+ if (v.normal.fontFamily) {
744
+ css += `\n font-family: var(--${p}-font-family);`;
745
+ }
746
+ if (v.normal.fontSizeScale != null && v.normal.fontSizeScale !== 1) {
747
+ css += `\n --btn-font-scale: var(--${p}-font-scale, 1);`;
748
+ }
749
+ if (v.normal.fontWeight) {
750
+ css += `\n font-weight: var(--${p}-font-weight);`;
751
+ }
752
+ if (v.normal.letterSpacing && v.normal.letterSpacing !== 'normal') {
753
+ css += `\n letter-spacing: var(--${p}-letter-spacing);`;
754
+ }
755
+ if (v.normal.textTransform && v.normal.textTransform !== 'none') {
756
+ css += `\n text-transform: var(--${p}-text-transform);`;
757
+ }
689
758
 
690
759
  css += '\n}';
691
760
 
@@ -697,20 +766,63 @@ function generateVariantNormalCSS(variant, v) {
697
766
  if (v.normal.borderHover && v.normal.borderHover !== 'none') {
698
767
  css += `\n border: var(--${p}-border-hover);`;
699
768
  }
700
- if (v.normal.shadowHover && v.normal.shadowHover !== 'none') {
769
+ if (hasShadow(v.normal.shadowHover)) {
701
770
  css += `\n box-shadow: var(--${p}-shadow-hover);`;
702
771
  }
703
772
  if (v.normal.textDecorationHover) {
704
773
  css += `\n text-decoration: ${v.normal.textDecorationHover};`;
705
774
  }
775
+ // Transform (scale + translateY)
776
+ {
777
+ const scale = v.normal.hoverScale ?? 1;
778
+ const y = v.normal.hoverY ?? 0;
779
+ const parts = [];
780
+ if (scale !== 1) parts.push(`scale(${scale})`);
781
+ if (y !== 0) parts.push(`translateY(${y}px)`);
782
+ if (parts.length > 0) {
783
+ css += `\n transform: ${parts.join(' ')};`;
784
+ }
785
+ }
786
+
787
+ css += '\n}';
788
+
789
+ // Active
790
+ css += `\n.${p}:active {
791
+ background: var(--${p}-bg-active);
792
+ color: var(--${p}-text-active);`;
793
+
794
+ if (v.normal.borderActive && v.normal.borderActive !== 'none') {
795
+ css += `\n border: var(--${p}-border-active);`;
796
+ }
797
+ if (hasShadow(v.normal.shadowActive)) {
798
+ css += `\n box-shadow: var(--${p}-shadow-active);`;
799
+ }
800
+ // Transform (scale + translateY)
801
+ {
802
+ const scale = v.normal.activeScale ?? 1;
803
+ const y = v.normal.activeY ?? 0;
804
+ const parts = [];
805
+ if (scale !== 1) parts.push(`scale(${scale})`);
806
+ if (y !== 0) parts.push(`translateY(${y}px)`);
807
+ if (parts.length > 0) {
808
+ css += `\n transform: ${parts.join(' ')};`;
809
+ }
810
+ }
706
811
 
707
812
  css += '\n}';
708
813
 
709
814
  // Focus
710
815
  if (v.normal.focusRingColor) {
816
+ const g = t.buttons?.global || {};
817
+ const ringWidth = g.focusRingWidth || '2px';
818
+ const ringOffset = g.focusRingOffset || '2px';
819
+ const ringOpacity = g.focusRingOpacity;
820
+ const ringColor = (ringOpacity != null && ringOpacity < 1)
821
+ ? `color-mix(in srgb, var(--${p}-focus-ring) ${Math.round(ringOpacity * 100)}%, transparent)`
822
+ : `var(--${p}-focus-ring)`;
711
823
  css += `\n.${p}:focus-visible {
712
- outline: 2px solid var(--${p}-focus-ring);
713
- outline-offset: 2px;
824
+ outline: ${ringWidth} solid ${ringColor};
825
+ outline-offset: ${ringOffset};
714
826
  }`;
715
827
  }
716
828
 
@@ -727,9 +839,28 @@ function generateVariantOnSurfaceCSS(variant, v, t) {
727
839
  if (v.onSurface.border && v.onSurface.border !== 'none') {
728
840
  css += `\n border: var(--${osp}-border);`;
729
841
  }
842
+ if (hasShadow(v.onSurface.shadow)) {
843
+ css += `\n box-shadow: var(--${osp}-shadow);`;
844
+ }
730
845
  if (v.onSurface.textDecoration) {
731
846
  css += `\n text-decoration: ${v.onSurface.textDecoration};`;
732
847
  }
848
+ // Typography overrides
849
+ if (v.onSurface.fontFamily) {
850
+ css += `\n font-family: var(--${osp}-font-family);`;
851
+ }
852
+ if (v.onSurface.fontSizeScale != null && v.onSurface.fontSizeScale !== 1) {
853
+ css += `\n --btn-font-scale: var(--${osp}-font-scale, 1);`;
854
+ }
855
+ if (v.onSurface.fontWeight) {
856
+ css += `\n font-weight: var(--${osp}-font-weight);`;
857
+ }
858
+ if (v.onSurface.letterSpacing && v.onSurface.letterSpacing !== 'normal') {
859
+ css += `\n letter-spacing: var(--${osp}-letter-spacing);`;
860
+ }
861
+ if (v.onSurface.textTransform && v.onSurface.textTransform !== 'none') {
862
+ css += `\n text-transform: var(--${osp}-text-transform);`;
863
+ }
733
864
 
734
865
  css += '\n}';
735
866
 
@@ -741,18 +872,65 @@ function generateVariantOnSurfaceCSS(variant, v, t) {
741
872
  if (v.onSurface.borderHover && v.onSurface.borderHover !== 'none') {
742
873
  css += `\n border: var(--${osp}-border-hover);`;
743
874
  }
875
+ if (hasShadow(v.onSurface.shadowHover)) {
876
+ css += `\n box-shadow: var(--${osp}-shadow-hover);`;
877
+ }
744
878
  if (v.onSurface.textDecorationHover) {
745
879
  css += `\n text-decoration: ${v.onSurface.textDecorationHover};`;
746
880
  }
881
+ // Transform (scale + translateY)
882
+ {
883
+ const scale = v.onSurface.hoverScale ?? 1;
884
+ const y = v.onSurface.hoverY ?? 0;
885
+ const parts = [];
886
+ if (scale !== 1) parts.push(`scale(${scale})`);
887
+ if (y !== 0) parts.push(`translateY(${y}px)`);
888
+ if (parts.length > 0) {
889
+ css += `\n transform: ${parts.join(' ')};`;
890
+ }
891
+ }
892
+
893
+ css += '\n}';
894
+
895
+ // Active
896
+ css += `\n.btn-on-surface.${p}:active {
897
+ background: var(--${osp}-bg-active);
898
+ color: var(--${osp}-text-active);`;
899
+
900
+ if (v.onSurface.borderActive && v.onSurface.borderActive !== 'none') {
901
+ css += `\n border: var(--${osp}-border-active);`;
902
+ }
903
+ if (hasShadow(v.onSurface.shadowActive)) {
904
+ css += `\n box-shadow: var(--${osp}-shadow-active);`;
905
+ }
906
+ // Transform (scale + translateY)
907
+ {
908
+ const scale = v.onSurface.activeScale ?? 1;
909
+ const y = v.onSurface.activeY ?? 0;
910
+ const parts = [];
911
+ if (scale !== 1) parts.push(`scale(${scale})`);
912
+ if (y !== 0) parts.push(`translateY(${y}px)`);
913
+ if (parts.length > 0) {
914
+ css += `\n transform: ${parts.join(' ')};`;
915
+ }
916
+ }
747
917
 
748
918
  css += '\n}';
749
919
 
750
920
  // Focus (on-surface)
751
921
  const focusColor = t.buttons.global?.onSurfaceFocusRingColor;
752
922
  if (focusColor) {
923
+ const g = t.buttons?.global || {};
924
+ const ringWidth = g.focusRingWidth || '2px';
925
+ const ringOffset = g.focusRingOffset || '2px';
926
+ const ringOpacity = g.focusRingOpacity;
927
+ const resolvedFocus = resolveColorRef(focusColor, t);
928
+ const ringColor = (ringOpacity != null && ringOpacity < 1)
929
+ ? `color-mix(in srgb, ${resolvedFocus} ${Math.round(ringOpacity * 100)}%, transparent)`
930
+ : resolvedFocus;
753
931
  css += `\n.btn-on-surface.${p}:focus-visible {
754
- outline: 2px solid ${resolveColorRef(focusColor, t)};
755
- outline-offset: 2px;
932
+ outline: ${ringWidth} solid ${ringColor};
933
+ outline-offset: ${ringOffset};
756
934
  }`;
757
935
  }
758
936
 
@@ -679,6 +679,44 @@ export const BUTTON_VARIANTS = ['filled', 'tonal', 'outline', 'ghost', 'text', '
679
679
  */
680
680
  export const BUTTON_SIZES = ['sm', 'md', 'lg'];
681
681
 
682
+ /**
683
+ * Shadow-Presets als strukturierte Layer-Arrays (Tailwind-orientiert).
684
+ */
685
+ export const SHADOW_PRESETS = {
686
+ none: 'none',
687
+ sm: [
688
+ { offsetX: 0, offsetY: 1, blur: 2, spread: 0, color: 'neutral-12', opacity: 5, inset: false }
689
+ ],
690
+ md: [
691
+ { offsetX: 0, offsetY: 4, blur: 6, spread: -1, color: 'neutral-12', opacity: 10, inset: false },
692
+ { offsetX: 0, offsetY: 2, blur: 4, spread: -2, color: 'neutral-12', opacity: 10, inset: false }
693
+ ],
694
+ lg: [
695
+ { offsetX: 0, offsetY: 10, blur: 15, spread: -3, color: 'neutral-12', opacity: 20, inset: false },
696
+ { offsetX: 0, offsetY: 4, blur: 6, spread: -4, color: 'neutral-12', opacity: 10, inset: false }
697
+ ]
698
+ };
699
+
700
+ /**
701
+ * Erzeugt eine Standard-Schattenebene.
702
+ */
703
+ export function createDefaultShadowLayer() {
704
+ return { offsetX: 0, offsetY: 4, blur: 6, spread: 0, color: 'neutral-12', opacity: 10, inset: false };
705
+ }
706
+
707
+ /**
708
+ * Normalisiert einen Shadow-Wert zu 'none' oder einem Array von Layer-Objekten.
709
+ * Akzeptiert: 'none', 'sm', 'md', 'lg', Array, null/undefined.
710
+ */
711
+ export function normalizeShadowValue(val) {
712
+ if (!val || val === 'none') return 'none';
713
+ if (Array.isArray(val)) return val;
714
+ if (typeof val === 'string' && SHADOW_PRESETS[val] && SHADOW_PRESETS[val] !== 'none') {
715
+ return structuredClone(SHADOW_PRESETS[val]);
716
+ }
717
+ return 'none';
718
+ }
719
+
682
720
 
683
721
  // ─── Default Token-Objekt ───────────────────────────────────────────────────
684
722
 
@@ -946,6 +984,7 @@ export const defaultDesignTokensV2 = {
946
984
  paddingX: '0.75rem',
947
985
  paddingY: '0.375rem',
948
986
  fontSize: '0.8125rem',
987
+ fontFamily: null,
949
988
  fontWeight: 500,
950
989
  lineHeight: '1.4',
951
990
  letterSpacing: '0.01em',
@@ -958,6 +997,7 @@ export const defaultDesignTokensV2 = {
958
997
  paddingX: '1.25rem',
959
998
  paddingY: '0.625rem',
960
999
  fontSize: '0.875rem',
1000
+ fontFamily: null,
961
1001
  fontWeight: 500,
962
1002
  lineHeight: '1.4',
963
1003
  letterSpacing: '0em',
@@ -970,6 +1010,7 @@ export const defaultDesignTokensV2 = {
970
1010
  paddingX: '1.75rem',
971
1011
  paddingY: '0.875rem',
972
1012
  fontSize: '1rem',
1013
+ fontFamily: null,
973
1014
  fontWeight: 600,
974
1015
  lineHeight: '1.4',
975
1016
  letterSpacing: '0em',
@@ -984,22 +1025,50 @@ export const defaultDesignTokensV2 = {
984
1025
  normal: {
985
1026
  bg: 'primary-9',
986
1027
  bgHover: 'primary-10',
1028
+ bgActive: 'primary-11',
987
1029
  text: 'on-primary',
988
1030
  textHover: 'on-primary',
1031
+ textActive: 'on-primary',
989
1032
  border: 'none',
990
1033
  borderHover: 'none',
1034
+ borderActive: 'none',
991
1035
  shadow: 'none',
992
1036
  shadowHover: 'none',
1037
+ shadowActive: 'none',
1038
+ hoverScale: 1,
1039
+ hoverY: 0,
1040
+ activeScale: 0.97,
1041
+ activeY: 0,
1042
+ fontFamily: null,
1043
+ fontSizeScale: 1,
1044
+ fontWeight: null,
1045
+ letterSpacing: 'normal',
1046
+ textTransform: 'none',
993
1047
  focusRingColor: 'primary-8',
994
1048
  customCSS: null
995
1049
  },
996
1050
  onSurface: {
997
1051
  bg: 'neutral-1',
998
1052
  bgHover: 'neutral-2',
1053
+ bgActive: 'neutral-3',
999
1054
  text: 'neutral-12',
1000
1055
  textHover: 'neutral-12',
1056
+ textActive: 'neutral-12',
1001
1057
  border: 'none',
1002
1058
  borderHover: 'none',
1059
+ borderActive: 'none',
1060
+ shadow: 'none',
1061
+ shadowHover: 'none',
1062
+ shadowActive: 'none',
1063
+ hoverScale: 1,
1064
+ hoverY: 0,
1065
+ activeScale: 0.97,
1066
+ activeY: 0,
1067
+ fontFamily: null,
1068
+ fontSizeScale: 1,
1069
+ fontWeight: null,
1070
+ letterSpacing: 'normal',
1071
+ textTransform: 'none',
1003
1072
  customCSS: null
1004
1073
  }
1005
1074
  },
@@ -1007,22 +1076,50 @@ export const defaultDesignTokensV2 = {
1007
1076
  normal: {
1008
1077
  bg: 'primary-3',
1009
1078
  bgHover: 'primary-4',
1079
+ bgActive: 'primary-5',
1010
1080
  text: 'primary-11',
1011
1081
  textHover: 'primary-12',
1082
+ textActive: 'primary-12',
1012
1083
  border: 'none',
1013
1084
  borderHover: 'none',
1085
+ borderActive: 'none',
1014
1086
  shadow: 'none',
1015
1087
  shadowHover: 'none',
1088
+ shadowActive: 'none',
1089
+ hoverScale: 1,
1090
+ hoverY: 0,
1091
+ activeScale: 0.97,
1092
+ activeY: 0,
1093
+ fontFamily: null,
1094
+ fontSizeScale: 1,
1095
+ fontWeight: null,
1096
+ letterSpacing: 'normal',
1097
+ textTransform: 'none',
1016
1098
  focusRingColor: 'primary-8',
1017
1099
  customCSS: null
1018
1100
  },
1019
1101
  onSurface: {
1020
1102
  bg: 'neutral-1/15',
1021
1103
  bgHover: 'neutral-1/25',
1104
+ bgActive: 'neutral-1/35',
1022
1105
  text: 'on-primary',
1023
1106
  textHover: 'on-primary',
1107
+ textActive: 'on-primary',
1024
1108
  border: 'none',
1025
1109
  borderHover: 'none',
1110
+ borderActive: 'none',
1111
+ shadow: 'none',
1112
+ shadowHover: 'none',
1113
+ shadowActive: 'none',
1114
+ hoverScale: 1,
1115
+ hoverY: 0,
1116
+ activeScale: 0.97,
1117
+ activeY: 0,
1118
+ fontFamily: null,
1119
+ fontSizeScale: 1,
1120
+ fontWeight: null,
1121
+ letterSpacing: 'normal',
1122
+ textTransform: 'none',
1026
1123
  customCSS: null
1027
1124
  }
1028
1125
  },
@@ -1030,22 +1127,50 @@ export const defaultDesignTokensV2 = {
1030
1127
  normal: {
1031
1128
  bg: 'transparent',
1032
1129
  bgHover: 'primary-3',
1130
+ bgActive: 'primary-4',
1033
1131
  text: 'primary-11',
1034
1132
  textHover: 'primary-12',
1133
+ textActive: 'primary-12',
1035
1134
  border: 'primary-7',
1036
1135
  borderHover: 'primary-8',
1136
+ borderActive: 'primary-9',
1037
1137
  shadow: 'none',
1038
1138
  shadowHover: 'none',
1139
+ shadowActive: 'none',
1140
+ hoverScale: 1,
1141
+ hoverY: 0,
1142
+ activeScale: 0.97,
1143
+ activeY: 0,
1144
+ fontFamily: null,
1145
+ fontSizeScale: 1,
1146
+ fontWeight: null,
1147
+ letterSpacing: 'normal',
1148
+ textTransform: 'none',
1039
1149
  focusRingColor: 'primary-8',
1040
1150
  customCSS: null
1041
1151
  },
1042
1152
  onSurface: {
1043
1153
  bg: 'transparent',
1044
1154
  bgHover: 'neutral-1/15',
1155
+ bgActive: 'neutral-1/25',
1045
1156
  text: 'on-primary',
1046
1157
  textHover: 'on-primary',
1158
+ textActive: 'on-primary',
1047
1159
  border: 'on-primary/40',
1048
1160
  borderHover: 'on-primary/70',
1161
+ borderActive: 'on-primary/90',
1162
+ shadow: 'none',
1163
+ shadowHover: 'none',
1164
+ shadowActive: 'none',
1165
+ hoverScale: 1,
1166
+ hoverY: 0,
1167
+ activeScale: 0.97,
1168
+ activeY: 0,
1169
+ fontFamily: null,
1170
+ fontSizeScale: 1,
1171
+ fontWeight: null,
1172
+ letterSpacing: 'normal',
1173
+ textTransform: 'none',
1049
1174
  customCSS: null
1050
1175
  }
1051
1176
  },
@@ -1053,22 +1178,50 @@ export const defaultDesignTokensV2 = {
1053
1178
  normal: {
1054
1179
  bg: 'transparent',
1055
1180
  bgHover: 'neutral-3',
1181
+ bgActive: 'neutral-4',
1056
1182
  text: 'primary-11',
1057
1183
  textHover: 'primary-12',
1184
+ textActive: 'primary-12',
1058
1185
  border: 'none',
1059
1186
  borderHover: 'none',
1187
+ borderActive: 'none',
1060
1188
  shadow: 'none',
1061
1189
  shadowHover: 'none',
1190
+ shadowActive: 'none',
1191
+ hoverScale: 1,
1192
+ hoverY: 0,
1193
+ activeScale: 0.97,
1194
+ activeY: 0,
1195
+ fontFamily: null,
1196
+ fontSizeScale: 1,
1197
+ fontWeight: null,
1198
+ letterSpacing: 'normal',
1199
+ textTransform: 'none',
1062
1200
  focusRingColor: 'primary-8',
1063
1201
  customCSS: null
1064
1202
  },
1065
1203
  onSurface: {
1066
1204
  bg: 'transparent',
1067
1205
  bgHover: 'neutral-1/15',
1206
+ bgActive: 'neutral-1/25',
1068
1207
  text: 'on-primary',
1069
1208
  textHover: 'on-primary',
1209
+ textActive: 'on-primary',
1070
1210
  border: 'none',
1071
1211
  borderHover: 'none',
1212
+ borderActive: 'none',
1213
+ shadow: 'none',
1214
+ shadowHover: 'none',
1215
+ shadowActive: 'none',
1216
+ hoverScale: 1,
1217
+ hoverY: 0,
1218
+ activeScale: 0.97,
1219
+ activeY: 0,
1220
+ fontFamily: null,
1221
+ fontSizeScale: 1,
1222
+ fontWeight: null,
1223
+ letterSpacing: 'normal',
1224
+ textTransform: 'none',
1072
1225
  customCSS: null
1073
1226
  }
1074
1227
  },
@@ -1076,12 +1229,25 @@ export const defaultDesignTokensV2 = {
1076
1229
  normal: {
1077
1230
  bg: 'transparent',
1078
1231
  bgHover: 'transparent',
1232
+ bgActive: 'transparent',
1079
1233
  text: 'primary-11',
1080
1234
  textHover: 'primary-12',
1235
+ textActive: 'primary-12',
1081
1236
  border: 'none',
1082
1237
  borderHover: 'none',
1238
+ borderActive: 'none',
1083
1239
  shadow: 'none',
1084
1240
  shadowHover: 'none',
1241
+ shadowActive: 'none',
1242
+ hoverScale: 1,
1243
+ hoverY: 0,
1244
+ activeScale: 0.97,
1245
+ activeY: 0,
1246
+ fontFamily: null,
1247
+ fontSizeScale: 1,
1248
+ fontWeight: null,
1249
+ letterSpacing: 'normal',
1250
+ textTransform: 'none',
1085
1251
  textDecoration: 'none',
1086
1252
  textDecorationHover: 'underline',
1087
1253
  focusRingColor: 'primary-8',
@@ -1090,8 +1256,25 @@ export const defaultDesignTokensV2 = {
1090
1256
  onSurface: {
1091
1257
  bg: 'transparent',
1092
1258
  bgHover: 'transparent',
1259
+ bgActive: 'transparent',
1093
1260
  text: 'on-primary',
1094
1261
  textHover: 'on-primary',
1262
+ textActive: 'on-primary',
1263
+ border: 'none',
1264
+ borderHover: 'none',
1265
+ borderActive: 'none',
1266
+ shadow: 'none',
1267
+ shadowHover: 'none',
1268
+ shadowActive: 'none',
1269
+ hoverScale: 1,
1270
+ hoverY: 0,
1271
+ activeScale: 0.97,
1272
+ activeY: 0,
1273
+ fontFamily: null,
1274
+ fontSizeScale: 1,
1275
+ fontWeight: null,
1276
+ letterSpacing: 'normal',
1277
+ textTransform: 'none',
1095
1278
  textDecoration: 'none',
1096
1279
  textDecorationHover: 'underline',
1097
1280
  customCSS: null
@@ -1101,22 +1284,50 @@ export const defaultDesignTokensV2 = {
1101
1284
  normal: {
1102
1285
  bg: 'error-9',
1103
1286
  bgHover: 'error-10',
1287
+ bgActive: 'error-11',
1104
1288
  text: 'on-error',
1105
1289
  textHover: 'on-error',
1290
+ textActive: 'on-error',
1106
1291
  border: 'none',
1107
1292
  borderHover: 'none',
1293
+ borderActive: 'none',
1108
1294
  shadow: 'none',
1109
1295
  shadowHover: 'none',
1296
+ shadowActive: 'none',
1297
+ hoverScale: 1,
1298
+ hoverY: 0,
1299
+ activeScale: 0.97,
1300
+ activeY: 0,
1301
+ fontFamily: null,
1302
+ fontSizeScale: 1,
1303
+ fontWeight: null,
1304
+ letterSpacing: 'normal',
1305
+ textTransform: 'none',
1110
1306
  focusRingColor: 'error-8',
1111
1307
  customCSS: null
1112
1308
  },
1113
1309
  onSurface: {
1114
1310
  bg: 'error-9',
1115
1311
  bgHover: 'error-10',
1312
+ bgActive: 'error-11',
1116
1313
  text: 'on-error',
1117
1314
  textHover: 'on-error',
1315
+ textActive: 'on-error',
1118
1316
  border: 'none',
1119
1317
  borderHover: 'none',
1318
+ borderActive: 'none',
1319
+ shadow: 'none',
1320
+ shadowHover: 'none',
1321
+ shadowActive: 'none',
1322
+ hoverScale: 1,
1323
+ hoverY: 0,
1324
+ activeScale: 0.97,
1325
+ activeY: 0,
1326
+ fontFamily: null,
1327
+ fontSizeScale: 1,
1328
+ fontWeight: null,
1329
+ letterSpacing: 'normal',
1330
+ textTransform: 'none',
1120
1331
  customCSS: null
1121
1332
  }
1122
1333
  }