@yahoo/uds 3.156.2 → 3.157.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (180) hide show
  1. package/dist/automated-config/dist/generated/autoVariants.cjs +9 -4
  2. package/dist/automated-config/dist/generated/autoVariants.d.cts +2 -1
  3. package/dist/automated-config/dist/generated/autoVariants.d.ts +2 -1
  4. package/dist/automated-config/dist/generated/autoVariants.js +9 -4
  5. package/dist/automated-config/dist/generated/generatedConfigs.cjs +3078 -3089
  6. package/dist/automated-config/dist/generated/generatedConfigs.d.cts +158 -141
  7. package/dist/automated-config/dist/generated/generatedConfigs.d.ts +158 -141
  8. package/dist/automated-config/dist/generated/generatedConfigs.js +3078 -3089
  9. package/dist/automated-config/dist/generated/universalTokensConfigAuto.cjs +1217 -491
  10. package/dist/automated-config/dist/generated/universalTokensConfigAuto.d.cts +4 -1
  11. package/dist/automated-config/dist/generated/universalTokensConfigAuto.d.ts +4 -1
  12. package/dist/automated-config/dist/generated/universalTokensConfigAuto.js +1217 -491
  13. package/dist/automated-config/dist/properties.cjs +9 -2
  14. package/dist/automated-config/dist/properties.d.cts +23 -0
  15. package/dist/automated-config/dist/properties.d.ts +23 -0
  16. package/dist/automated-config/dist/properties.js +9 -2
  17. package/dist/automated-config/dist/types/ComponentConfig.d.cts +77 -4
  18. package/dist/automated-config/dist/types/ComponentConfig.d.ts +77 -4
  19. package/dist/automated-config/dist/types/ConfigSchema.d.cts +14 -2
  20. package/dist/automated-config/dist/types/ConfigSchema.d.ts +14 -2
  21. package/dist/automated-config/dist/types/StateAxis.cjs +90 -0
  22. package/dist/automated-config/dist/types/StateAxis.d.cts +70 -0
  23. package/dist/automated-config/dist/types/StateAxis.d.ts +70 -0
  24. package/dist/automated-config/dist/types/StateAxis.js +84 -0
  25. package/dist/automated-config/dist/utils/buildConfigSchema.cjs +105 -82
  26. package/dist/automated-config/dist/utils/buildConfigSchema.d.cts +41 -12
  27. package/dist/automated-config/dist/utils/buildConfigSchema.d.ts +41 -12
  28. package/dist/automated-config/dist/utils/buildConfigSchema.js +106 -83
  29. package/dist/automated-config/dist/utils/canonicalizeStateKey.cjs +32 -0
  30. package/dist/automated-config/dist/utils/canonicalizeStateKey.d.cts +48 -0
  31. package/dist/automated-config/dist/utils/canonicalizeStateKey.d.ts +48 -0
  32. package/dist/automated-config/dist/utils/canonicalizeStateKey.js +31 -0
  33. package/dist/automated-config/dist/utils/getButtonControlHeight.cjs +129 -0
  34. package/dist/automated-config/dist/utils/getButtonControlHeight.d.cts +133 -0
  35. package/dist/automated-config/dist/utils/getButtonControlHeight.d.ts +133 -0
  36. package/dist/automated-config/dist/utils/getButtonControlHeight.js +122 -0
  37. package/dist/automated-config/dist/utils/getButtonControlHeightPx.cjs +114 -0
  38. package/dist/automated-config/dist/utils/getButtonControlHeightPx.d.cts +78 -0
  39. package/dist/automated-config/dist/utils/getButtonControlHeightPx.d.ts +78 -0
  40. package/dist/automated-config/dist/utils/getButtonControlHeightPx.js +108 -0
  41. package/dist/automated-config/dist/utils/getConfigComponentVariant.d.cts +8 -0
  42. package/dist/automated-config/dist/utils/getConfigComponentVariant.d.ts +8 -0
  43. package/dist/automated-config/dist/utils/getConfigVariantProperties.d.cts +3 -3
  44. package/dist/automated-config/dist/utils/getConfigVariantProperties.d.ts +3 -3
  45. package/dist/automated-config/dist/utils/getConfigVariantPseudoStates.cjs +12 -5
  46. package/dist/automated-config/dist/utils/getConfigVariantPseudoStates.d.cts +8 -1
  47. package/dist/automated-config/dist/utils/getConfigVariantPseudoStates.d.ts +8 -1
  48. package/dist/automated-config/dist/utils/getConfigVariantPseudoStates.js +12 -5
  49. package/dist/automated-config/dist/utils/iconButtonMatchButtonHeight.cjs +110 -0
  50. package/dist/automated-config/dist/utils/iconButtonMatchButtonHeight.d.cts +19 -0
  51. package/dist/automated-config/dist/utils/iconButtonMatchButtonHeight.d.ts +19 -0
  52. package/dist/automated-config/dist/utils/iconButtonMatchButtonHeight.js +108 -0
  53. package/dist/automated-config/dist/utils/index.cjs +478 -111
  54. package/dist/automated-config/dist/utils/index.d.cts +76 -15
  55. package/dist/automated-config/dist/utils/index.d.ts +76 -15
  56. package/dist/automated-config/dist/utils/index.js +479 -113
  57. package/dist/automated-config/dist/utils/isConfiguratorPropertyVisible.cjs +15 -0
  58. package/dist/automated-config/dist/utils/isConfiguratorPropertyVisible.d.cts +20 -0
  59. package/dist/automated-config/dist/utils/isConfiguratorPropertyVisible.d.ts +20 -0
  60. package/dist/automated-config/dist/utils/isConfiguratorPropertyVisible.js +15 -0
  61. package/dist/automated-config/dist/utils/pseudoStateSelectors.cjs +122 -0
  62. package/dist/automated-config/dist/utils/pseudoStateSelectors.d.cts +80 -0
  63. package/dist/automated-config/dist/utils/pseudoStateSelectors.d.ts +80 -0
  64. package/dist/automated-config/dist/utils/pseudoStateSelectors.js +120 -0
  65. package/dist/automated-config/dist/utils/resolvePropertyStates.cjs +131 -0
  66. package/dist/automated-config/dist/utils/resolvePropertyStates.d.cts +49 -0
  67. package/dist/automated-config/dist/utils/resolvePropertyStates.d.ts +49 -0
  68. package/dist/automated-config/dist/utils/resolvePropertyStates.js +130 -0
  69. package/dist/automated-config/dist/utils/resolveSlotByCascade.cjs +118 -0
  70. package/dist/automated-config/dist/utils/resolveSlotByCascade.d.cts +68 -0
  71. package/dist/automated-config/dist/utils/resolveSlotByCascade.d.ts +68 -0
  72. package/dist/automated-config/dist/utils/resolveSlotByCascade.js +117 -0
  73. package/dist/automated-config/dist/utils/variantConfigGuards.d.cts +13 -0
  74. package/dist/automated-config/dist/utils/variantConfigGuards.d.ts +13 -0
  75. package/dist/components/client/Button.cjs +3 -3
  76. package/dist/components/client/Button.js +3 -3
  77. package/dist/components/client/Input/Input.cjs +42 -6
  78. package/dist/components/client/Input/Input.d.cts +13 -0
  79. package/dist/components/client/Input/Input.d.ts +13 -0
  80. package/dist/components/client/Input/Input.js +42 -6
  81. package/dist/components/client/Menu/Menu.ItemCheckbox.d.cts +1 -1
  82. package/dist/components/client/Menu/Menu.ItemCheckbox.d.ts +1 -1
  83. package/dist/config/dist/index.cjs +224 -553
  84. package/dist/config/dist/index.js +224 -553
  85. package/dist/css/dist/commands/css.cjs +1 -0
  86. package/dist/css/dist/commands/css.helpers.cjs +6 -0
  87. package/dist/css/dist/commands/css.helpers.js +6 -0
  88. package/dist/css/dist/commands/css.js +1 -0
  89. package/dist/css/dist/css/generate.cjs +4 -2
  90. package/dist/css/dist/css/generate.d.cts +28 -0
  91. package/dist/css/dist/css/generate.d.ts +28 -0
  92. package/dist/css/dist/css/generate.helpers.cjs +5 -1
  93. package/dist/css/dist/css/generate.helpers.js +6 -2
  94. package/dist/css/dist/css/generate.js +4 -2
  95. package/dist/css/dist/css/postcss.cjs +81 -0
  96. package/dist/css/dist/css/postcss.helpers.cjs +60 -0
  97. package/dist/css/dist/css/postcss.helpers.js +59 -1
  98. package/dist/css/dist/css/postcss.js +82 -2
  99. package/dist/css/dist/css/runner.cjs +12 -2
  100. package/dist/css/dist/css/runner.js +12 -2
  101. package/dist/css/dist/css/theme.d.cts +6 -0
  102. package/dist/css/dist/css/theme.d.ts +6 -0
  103. package/dist/css/dist/packages/automated-config/dist/properties.cjs +9 -2
  104. package/dist/css/dist/packages/automated-config/dist/properties.js +9 -2
  105. package/dist/css/dist/packages/automated-config/dist/utils/index.d.cts +6 -0
  106. package/dist/css/dist/packages/automated-config/dist/utils/index.d.ts +6 -0
  107. package/dist/css/dist/packages/config/dist/index.cjs +224 -553
  108. package/dist/css/dist/packages/config/dist/index.js +224 -553
  109. package/dist/css/dist/utils/optimizeCSS.cjs +59 -0
  110. package/dist/css/dist/utils/optimizeCSS.js +59 -0
  111. package/dist/css-tokens/dist/index.cjs +2 -0
  112. package/dist/css-tokens/dist/index.d.cts +2 -1
  113. package/dist/css-tokens/dist/index.d.ts +2 -1
  114. package/dist/css-tokens/dist/index.js +2 -1
  115. package/dist/index.cjs +48 -0
  116. package/dist/index.d.cts +15 -4
  117. package/dist/index.d.ts +15 -4
  118. package/dist/index.js +14 -3
  119. package/dist/styles/styler.d.cts +8 -7
  120. package/dist/styles/styler.d.ts +8 -7
  121. package/dist/styles/variants.d.cts +9 -4
  122. package/dist/styles/variants.d.ts +9 -4
  123. package/dist/tailwind-internal/dist/packages/automated-config/dist/generated/generatedConfigs.cjs +3078 -3089
  124. package/dist/tailwind-internal/dist/packages/automated-config/dist/generated/generatedConfigs.js +3078 -3089
  125. package/dist/tailwind-internal/dist/packages/automated-config/dist/properties.cjs +9 -2
  126. package/dist/tailwind-internal/dist/packages/automated-config/dist/properties.js +9 -2
  127. package/dist/tailwind-internal/dist/packages/automated-config/dist/types/StateAxis.cjs +81 -0
  128. package/dist/tailwind-internal/dist/packages/automated-config/dist/types/StateAxis.js +76 -0
  129. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/canonicalizeStateKey.cjs +33 -0
  130. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/canonicalizeStateKey.js +32 -0
  131. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/componentStatePseudoStates.cjs +0 -7
  132. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/componentStatePseudoStates.js +1 -7
  133. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/getButtonControlHeight.cjs +126 -0
  134. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/getButtonControlHeight.js +123 -0
  135. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/iconButtonMatchButtonHeight.cjs +20 -0
  136. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/iconButtonMatchButtonHeight.js +20 -0
  137. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/index.cjs +422 -111
  138. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/index.d.cts +6 -0
  139. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/index.d.ts +6 -0
  140. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/index.js +423 -112
  141. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/pseudoStateSelectors.cjs +122 -0
  142. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/pseudoStateSelectors.js +121 -0
  143. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/resolvePropertyStates.cjs +132 -0
  144. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/resolvePropertyStates.js +131 -0
  145. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/resolveSlotByCascade.cjs +95 -0
  146. package/dist/tailwind-internal/dist/packages/automated-config/dist/utils/resolveSlotByCascade.js +95 -0
  147. package/dist/tailwind-internal/dist/packages/config/dist/index.cjs +224 -553
  148. package/dist/tailwind-internal/dist/packages/config/dist/index.js +224 -553
  149. package/dist/tailwind-internal/dist/packages/css-tokens/dist/index.cjs +2 -0
  150. package/dist/tailwind-internal/dist/packages/css-tokens/dist/index.js +2 -1
  151. package/dist/tailwind-internal/dist/plugins/components.cjs +28 -24
  152. package/dist/tailwind-internal/dist/plugins/components.js +28 -24
  153. package/dist/tailwind-internal/dist/utils/composeTailwindPlugins.d.cts +3 -0
  154. package/dist/tailwind-internal/dist/utils/composeTailwindPlugins.d.ts +3 -0
  155. package/dist/tailwind-internal/dist/utils/getShadowStyles.d.cts +2 -2
  156. package/dist/tailwind-internal/dist/utils/getShadowStyles.d.ts +2 -2
  157. package/dist/tokens/automation/index.cjs +47 -0
  158. package/dist/tokens/automation/index.d.cts +13 -2
  159. package/dist/tokens/automation/index.d.ts +13 -2
  160. package/dist/tokens/automation/index.js +13 -2
  161. package/dist/tokens/consts/cssTokens.cjs +1 -0
  162. package/dist/tokens/consts/cssTokens.d.cts +2 -2
  163. package/dist/tokens/consts/cssTokens.d.ts +2 -2
  164. package/dist/tokens/consts/cssTokens.js +2 -2
  165. package/dist/tokens/index.cjs +48 -0
  166. package/dist/tokens/index.d.cts +15 -4
  167. package/dist/tokens/index.d.ts +15 -4
  168. package/dist/tokens/index.js +14 -3
  169. package/dist/tokens/types.d.cts +1 -1
  170. package/dist/tokens/types.d.ts +1 -1
  171. package/dist/uds/generated/componentData.cjs +2177 -2172
  172. package/dist/uds/generated/componentData.js +2177 -2172
  173. package/dist/uds/generated/migrationSchemaVersion.cjs +1 -1
  174. package/dist/uds/generated/migrationSchemaVersion.js +1 -1
  175. package/dist/uds/generated/tailwindPurge.cjs +79 -78
  176. package/dist/uds/generated/tailwindPurge.js +79 -78
  177. package/generated/componentData.json +2718 -2713
  178. package/generated/migrationSchemaVersion.ts +1 -1
  179. package/generated/tailwindPurge.ts +2 -2
  180. package/package.json +1 -1
@@ -8,7 +8,7 @@ const require_index$1 = require("../../motion-tokens/dist/index.cjs");
8
8
  /*! © 2026 Yahoo, Inc. UDS Tailwind Internal v0.0.0-development */
9
9
  /*! © 2026 Yahoo, Inc. UDS Default Config v0.0.0-development */
10
10
  const isInputWrapperCtx = (context) => {
11
- return context.componentName === "input" && context.layer === "inputWrapper";
11
+ return context.componentName === "input" && (context.layer === "inputWrapper" || context.layer === "inputWrapperDynamic");
12
12
  };
13
13
  const hexToRgb = (hex) => {
14
14
  hex = hex.replace("#", "");
@@ -434,6 +434,12 @@ const paginationWidthVar = {
434
434
  possibleFixtures: ["positiveIntegers"],
435
435
  twThemePath: (_, value) => `${value}px`
436
436
  };
437
+ const controlHeight = {
438
+ name: "controlHeight",
439
+ cssProperties: [],
440
+ possibleFixtures: ["positiveIntegers"],
441
+ twThemePath: (_, value) => `${value}px`
442
+ };
437
443
  const publicProperties = {
438
444
  backgroundColor,
439
445
  borderWidth,
@@ -530,7 +536,8 @@ const publicProperties = {
530
536
  twThemePath: () => "",
531
537
  customValueRenderer: ({ value }) => `${String(value)}%`
532
538
  },
533
- paginationWidthVar
539
+ paginationWidthVar,
540
+ controlHeight
534
541
  };
535
542
  const internalProperties = {
536
543
  outlineWidth,
@@ -8,7 +8,7 @@ import { SCALE_EFFECTS } from "../../motion-tokens/dist/index.js";
8
8
  /*! © 2026 Yahoo, Inc. UDS Tailwind Internal v0.0.0-development */
9
9
  /*! © 2026 Yahoo, Inc. UDS Default Config v0.0.0-development */
10
10
  const isInputWrapperCtx = (context) => {
11
- return context.componentName === "input" && context.layer === "inputWrapper";
11
+ return context.componentName === "input" && (context.layer === "inputWrapper" || context.layer === "inputWrapperDynamic");
12
12
  };
13
13
  const hexToRgb = (hex) => {
14
14
  hex = hex.replace("#", "");
@@ -434,6 +434,12 @@ const paginationWidthVar = {
434
434
  possibleFixtures: ["positiveIntegers"],
435
435
  twThemePath: (_, value) => `${value}px`
436
436
  };
437
+ const controlHeight = {
438
+ name: "controlHeight",
439
+ cssProperties: [],
440
+ possibleFixtures: ["positiveIntegers"],
441
+ twThemePath: (_, value) => `${value}px`
442
+ };
437
443
  const publicProperties = {
438
444
  backgroundColor,
439
445
  borderWidth,
@@ -530,7 +536,8 @@ const publicProperties = {
530
536
  twThemePath: () => "",
531
537
  customValueRenderer: ({ value }) => `${String(value)}%`
532
538
  },
533
- paginationWidthVar
539
+ paginationWidthVar,
540
+ controlHeight
534
541
  };
535
542
  const internalProperties = {
536
543
  outlineWidth,
@@ -0,0 +1,81 @@
1
+ /*! © 2026 Yahoo, Inc. UDS v0.0.0-development */
2
+ //#region ../tailwind-internal/dist/packages/automated-config/dist/types/StateAxis.js
3
+ /*! © 2026 Yahoo, Inc. UDS Tailwind Internal v0.0.0-development */
4
+ /*! © 2026 Yahoo, Inc. UDS Default Config v0.0.0-development */
5
+ /**
6
+ * Atomic-state taxonomy.
7
+ *
8
+ * Every interactive component reacts to a fixed set of "atomic" states, each
9
+ * belonging to one axis:
10
+ *
11
+ * - `interactive` — pointer/keyboard focus signals. At runtime at most one of
12
+ * these is meaningfully "active" at a time on a given element (you can't
13
+ * simultaneously hover and press distinctly enough to style separately, etc.).
14
+ *
15
+ * - `modifier` — semantic flags that can stack independently of each other and
16
+ * of the interactive state. An input can be `invalid` AND `readonly` at the
17
+ * same time, optionally also `hover`ed.
18
+ *
19
+ * Compound states (`'invalid&hover'`, `'invalid&readonly&hover'`, etc.) are
20
+ * built by listing 0..N modifiers followed by 0..1 interactive. The
21
+ * `canonicalizeStateKey` helper enforces this ordering so that, e.g.,
22
+ * `['hover', 'invalid']` and `['invalid', 'hover']` resolve to the same key.
23
+ */
24
+ /**
25
+ * Interactive atomics:
26
+ *
27
+ * - `hover`/`pressed` for pointer interaction.
28
+ * - `focus-within` for containers that wrap a focusable child (e.g. an input
29
+ * wrapper).
30
+ * - `focus-visible` for keyboard-only focus rings on focusable elements.
31
+ */
32
+ const INTERACTIVE_ATOMICS = [
33
+ "hover",
34
+ "pressed",
35
+ "focus-within",
36
+ "focus-visible"
37
+ ];
38
+ const MODIFIER_ATOMICS = [
39
+ "invalid",
40
+ "readonly",
41
+ "placeholder-shown",
42
+ "autofill",
43
+ "visited"
44
+ ];
45
+ const INTERACTIVE_ATOMIC_SET = new Set(INTERACTIVE_ATOMICS);
46
+ const MODIFIER_ATOMIC_SET = new Set(MODIFIER_ATOMICS);
47
+ function isInteractiveAtomic(state) {
48
+ return INTERACTIVE_ATOMIC_SET.has(state);
49
+ }
50
+ function isModifierAtomic(state) {
51
+ return MODIFIER_ATOMIC_SET.has(state);
52
+ }
53
+ function isAtomicState(state) {
54
+ return isInteractiveAtomic(state) || isModifierAtomic(state);
55
+ }
56
+ const STATE_PRIORITY_INDEX = new Map([
57
+ "visited",
58
+ "placeholder-shown",
59
+ "autofill",
60
+ "focus-within",
61
+ "focus-visible",
62
+ "hover",
63
+ "pressed",
64
+ "invalid",
65
+ "readonly"
66
+ ].map((atom, i) => [atom, i]));
67
+ /**
68
+ * Comparator usable with `Array.prototype.sort`. Atoms not in `STATE_PRIORITY`
69
+ * sort to the front (weakest) — this only triggers for unknown strings; every
70
+ * known `AtomicState` is in the priority array.
71
+ */
72
+ function comparePriority(a, b) {
73
+ return (STATE_PRIORITY_INDEX.get(a) ?? -1) - (STATE_PRIORITY_INDEX.get(b) ?? -1);
74
+ }
75
+ //#endregion
76
+ exports.INTERACTIVE_ATOMICS = INTERACTIVE_ATOMICS;
77
+ exports.MODIFIER_ATOMICS = MODIFIER_ATOMICS;
78
+ exports.comparePriority = comparePriority;
79
+ exports.isAtomicState = isAtomicState;
80
+ exports.isInteractiveAtomic = isInteractiveAtomic;
81
+ exports.isModifierAtomic = isModifierAtomic;
@@ -0,0 +1,76 @@
1
+ /*! © 2026 Yahoo, Inc. UDS v0.0.0-development */
2
+ //#region ../tailwind-internal/dist/packages/automated-config/dist/types/StateAxis.js
3
+ /*! © 2026 Yahoo, Inc. UDS Tailwind Internal v0.0.0-development */
4
+ /*! © 2026 Yahoo, Inc. UDS Default Config v0.0.0-development */
5
+ /**
6
+ * Atomic-state taxonomy.
7
+ *
8
+ * Every interactive component reacts to a fixed set of "atomic" states, each
9
+ * belonging to one axis:
10
+ *
11
+ * - `interactive` — pointer/keyboard focus signals. At runtime at most one of
12
+ * these is meaningfully "active" at a time on a given element (you can't
13
+ * simultaneously hover and press distinctly enough to style separately, etc.).
14
+ *
15
+ * - `modifier` — semantic flags that can stack independently of each other and
16
+ * of the interactive state. An input can be `invalid` AND `readonly` at the
17
+ * same time, optionally also `hover`ed.
18
+ *
19
+ * Compound states (`'invalid&hover'`, `'invalid&readonly&hover'`, etc.) are
20
+ * built by listing 0..N modifiers followed by 0..1 interactive. The
21
+ * `canonicalizeStateKey` helper enforces this ordering so that, e.g.,
22
+ * `['hover', 'invalid']` and `['invalid', 'hover']` resolve to the same key.
23
+ */
24
+ /**
25
+ * Interactive atomics:
26
+ *
27
+ * - `hover`/`pressed` for pointer interaction.
28
+ * - `focus-within` for containers that wrap a focusable child (e.g. an input
29
+ * wrapper).
30
+ * - `focus-visible` for keyboard-only focus rings on focusable elements.
31
+ */
32
+ const INTERACTIVE_ATOMICS = [
33
+ "hover",
34
+ "pressed",
35
+ "focus-within",
36
+ "focus-visible"
37
+ ];
38
+ const MODIFIER_ATOMICS = [
39
+ "invalid",
40
+ "readonly",
41
+ "placeholder-shown",
42
+ "autofill",
43
+ "visited"
44
+ ];
45
+ const INTERACTIVE_ATOMIC_SET = new Set(INTERACTIVE_ATOMICS);
46
+ const MODIFIER_ATOMIC_SET = new Set(MODIFIER_ATOMICS);
47
+ function isInteractiveAtomic(state) {
48
+ return INTERACTIVE_ATOMIC_SET.has(state);
49
+ }
50
+ function isModifierAtomic(state) {
51
+ return MODIFIER_ATOMIC_SET.has(state);
52
+ }
53
+ function isAtomicState(state) {
54
+ return isInteractiveAtomic(state) || isModifierAtomic(state);
55
+ }
56
+ const STATE_PRIORITY_INDEX = new Map([
57
+ "visited",
58
+ "placeholder-shown",
59
+ "autofill",
60
+ "focus-within",
61
+ "focus-visible",
62
+ "hover",
63
+ "pressed",
64
+ "invalid",
65
+ "readonly"
66
+ ].map((atom, i) => [atom, i]));
67
+ /**
68
+ * Comparator usable with `Array.prototype.sort`. Atoms not in `STATE_PRIORITY`
69
+ * sort to the front (weakest) — this only triggers for unknown strings; every
70
+ * known `AtomicState` is in the priority array.
71
+ */
72
+ function comparePriority(a, b) {
73
+ return (STATE_PRIORITY_INDEX.get(a) ?? -1) - (STATE_PRIORITY_INDEX.get(b) ?? -1);
74
+ }
75
+ //#endregion
76
+ export { INTERACTIVE_ATOMICS, MODIFIER_ATOMICS, comparePriority, isAtomicState, isInteractiveAtomic, isModifierAtomic };
@@ -0,0 +1,33 @@
1
+ /*! © 2026 Yahoo, Inc. UDS v0.0.0-development */
2
+ const require_StateAxis = require("../types/StateAxis.cjs");
3
+ //#region ../tailwind-internal/dist/packages/automated-config/dist/utils/canonicalizeStateKey.js
4
+ /*! © 2026 Yahoo, Inc. UDS Tailwind Internal v0.0.0-development */
5
+ /*! © 2026 Yahoo, Inc. UDS Default Config v0.0.0-development */
6
+ function canonicalizeStateKey(atoms) {
7
+ if (atoms.length === 0) return "rest";
8
+ const seen = /* @__PURE__ */ new Set();
9
+ const modifiers = [];
10
+ const interactives = [];
11
+ for (const atom of atoms) {
12
+ if (seen.has(atom)) continue;
13
+ seen.add(atom);
14
+ if (require_StateAxis.isModifierAtomic(atom)) modifiers.push(atom);
15
+ else if (require_StateAxis.isInteractiveAtomic(atom)) interactives.push(atom);
16
+ else throw new Error(`canonicalizeStateKey received an unrecognized atom "${atom}". Atoms must be in MODIFIER_ATOMICS or INTERACTIVE_ATOMICS — see StateAxis.`);
17
+ }
18
+ modifiers.sort(require_StateAxis.comparePriority);
19
+ interactives.sort(require_StateAxis.comparePriority);
20
+ const ordered = [...modifiers, ...interactives];
21
+ return ordered.length === 0 ? "rest" : ordered.join("&");
22
+ }
23
+ /**
24
+ * Splits a canonical (or legacy) state key into its atomic parts.
25
+ * `'rest'` and `''` produce an empty array.
26
+ */
27
+ function splitStateKey(stateKey) {
28
+ if (!stateKey || stateKey === "rest") return [];
29
+ return stateKey.split("&");
30
+ }
31
+ //#endregion
32
+ exports.canonicalizeStateKey = canonicalizeStateKey;
33
+ exports.splitStateKey = splitStateKey;
@@ -0,0 +1,32 @@
1
+ /*! © 2026 Yahoo, Inc. UDS v0.0.0-development */
2
+ import { comparePriority, isInteractiveAtomic, isModifierAtomic } from "../types/StateAxis.js";
3
+ //#region ../tailwind-internal/dist/packages/automated-config/dist/utils/canonicalizeStateKey.js
4
+ /*! © 2026 Yahoo, Inc. UDS Tailwind Internal v0.0.0-development */
5
+ /*! © 2026 Yahoo, Inc. UDS Default Config v0.0.0-development */
6
+ function canonicalizeStateKey(atoms) {
7
+ if (atoms.length === 0) return "rest";
8
+ const seen = /* @__PURE__ */ new Set();
9
+ const modifiers = [];
10
+ const interactives = [];
11
+ for (const atom of atoms) {
12
+ if (seen.has(atom)) continue;
13
+ seen.add(atom);
14
+ if (isModifierAtomic(atom)) modifiers.push(atom);
15
+ else if (isInteractiveAtomic(atom)) interactives.push(atom);
16
+ else throw new Error(`canonicalizeStateKey received an unrecognized atom "${atom}". Atoms must be in MODIFIER_ATOMICS or INTERACTIVE_ATOMICS — see StateAxis.`);
17
+ }
18
+ modifiers.sort(comparePriority);
19
+ interactives.sort(comparePriority);
20
+ const ordered = [...modifiers, ...interactives];
21
+ return ordered.length === 0 ? "rest" : ordered.join("&");
22
+ }
23
+ /**
24
+ * Splits a canonical (or legacy) state key into its atomic parts.
25
+ * `'rest'` and `''` produce an empty array.
26
+ */
27
+ function splitStateKey(stateKey) {
28
+ if (!stateKey || stateKey === "rest") return [];
29
+ return stateKey.split("&");
30
+ }
31
+ //#endregion
32
+ export { canonicalizeStateKey, splitStateKey };
@@ -5,12 +5,5 @@
5
5
  function getExcludedPseudoStatesForComponentStateOption(componentState, componentStateOption) {
6
6
  return componentState.excludePseudoStatesForOptions?.[componentStateOption] ?? [];
7
7
  }
8
- function filterPseudoStatesByExclusion(pseudoStates, excludedPseudoStates) {
9
- if (!pseudoStates) return [];
10
- if (excludedPseudoStates.length === 0) return [...pseudoStates];
11
- const excluded = new Set(excludedPseudoStates);
12
- return pseudoStates.filter((pseudoState) => !excluded.has(pseudoState));
13
- }
14
8
  //#endregion
15
- exports.filterPseudoStatesByExclusion = filterPseudoStatesByExclusion;
16
9
  exports.getExcludedPseudoStatesForComponentStateOption = getExcludedPseudoStatesForComponentStateOption;
@@ -5,11 +5,5 @@
5
5
  function getExcludedPseudoStatesForComponentStateOption(componentState, componentStateOption) {
6
6
  return componentState.excludePseudoStatesForOptions?.[componentStateOption] ?? [];
7
7
  }
8
- function filterPseudoStatesByExclusion(pseudoStates, excludedPseudoStates) {
9
- if (!pseudoStates) return [];
10
- if (excludedPseudoStates.length === 0) return [...pseudoStates];
11
- const excluded = new Set(excludedPseudoStates);
12
- return pseudoStates.filter((pseudoState) => !excluded.has(pseudoState));
13
- }
14
8
  //#endregion
15
- export { filterPseudoStatesByExclusion, getExcludedPseudoStatesForComponentStateOption };
9
+ export { getExcludedPseudoStatesForComponentStateOption };
@@ -0,0 +1,126 @@
1
+ /*! © 2026 Yahoo, Inc. UDS v0.0.0-development */
2
+ const require_index = require("../../../css-tokens/dist/index.cjs");
3
+ const require_mapTextVariantFixtureToValue = require("../mapTextVariantFixtureToValue.cjs");
4
+ const require_properties = require("../properties.cjs");
5
+ const require_iconButtonMatchButtonHeight = require("./iconButtonMatchButtonHeight.cjs");
6
+ //#region ../tailwind-internal/dist/packages/automated-config/dist/utils/getButtonControlHeight.js
7
+ /*! © 2026 Yahoo, Inc. UDS Tailwind Internal v0.0.0-development */
8
+ /*! © 2026 Yahoo, Inc. UDS Default Config v0.0.0-development */
9
+ /** Sizes where IconButton control height should match Button. */
10
+ const SHARED_BUTTON_ICONBUTTON_SIZES = new Set([
11
+ "xs",
12
+ "sm",
13
+ "md",
14
+ "lg"
15
+ ]);
16
+ function getButtonIconSizeVar({ schema, iconLayerKey, state, theme }) {
17
+ const iconSizeValue = schema.variables?.[iconLayerKey]?.size?.[state]?.value;
18
+ if (typeof iconSizeValue === "string" && iconSizeValue) return theme(require_properties.configurableProperties.iconSize.twThemePath("iconSizes", iconSizeValue));
19
+ }
20
+ /**
21
+ * Button content box: max(icon size, text line-height).
22
+ * Matches Figma auto-layout and keeps IconButton height aligned with Button.
23
+ */
24
+ function getButtonControlContentSize({ schema, rootLayerKey, iconLayerKey, state, theme }) {
25
+ const iconSizeVar = getButtonIconSizeVar({
26
+ schema,
27
+ iconLayerKey,
28
+ state,
29
+ theme
30
+ });
31
+ const textVariantValue = schema.variables?.[rootLayerKey]?.textVariant?.[state]?.value;
32
+ if (iconSizeVar && typeof textVariantValue === "string" && textVariantValue) return `max(${iconSizeVar}, ${theme(require_mapTextVariantFixtureToValue.mapTextVariantFixtureToValue("lineHeight")("textVariants", textVariantValue))})`;
33
+ if (iconSizeVar) return iconSizeVar;
34
+ }
35
+ /** `round(up, …, 1px)` matches Math.ceil in getButtonControlHeightPx and Figma hug height. */
36
+ function formatControlHeightCalc(calcExpression) {
37
+ return `round(up, ${calcExpression}, 1px)`;
38
+ }
39
+ /**
40
+ * Button control height: vertical padding on both sides plus max(icon size, text line-height).
41
+ */
42
+ function getButtonControlHeight({ paddingVertical, schema, rootLayerKey, iconLayerKey, state, theme }) {
43
+ const contentSize = getButtonControlContentSize({
44
+ schema,
45
+ rootLayerKey,
46
+ iconLayerKey,
47
+ state,
48
+ theme
49
+ });
50
+ if (!contentSize) return;
51
+ return formatControlHeightCalc(`calc(2 * ${paddingVertical} + ${contentSize})`);
52
+ }
53
+ /**
54
+ * IconButton control height: uniform padding plus icon size only (no typography).
55
+ */
56
+ function getIconButtonControlHeight({ paddingVertical, schema, iconLayerKey, state, theme }) {
57
+ const iconSizeVar = getButtonIconSizeVar({
58
+ schema,
59
+ iconLayerKey,
60
+ state,
61
+ theme
62
+ });
63
+ if (!iconSizeVar) return;
64
+ return formatControlHeightCalc(`calc(2 * ${paddingVertical} + ${iconSizeVar})`);
65
+ }
66
+ /**
67
+ * Layout line-height for button root: max(icon size, text line-height).
68
+ */
69
+ function getButtonContentLineHeight({ schema, rootLayerKey, iconLayerKey, state, theme }) {
70
+ return getButtonControlContentSize({
71
+ schema,
72
+ rootLayerKey,
73
+ iconLayerKey,
74
+ state,
75
+ theme
76
+ }) ?? "1em";
77
+ }
78
+ function applyButtonControlHeightDeclarations({ cssDeclarations, paddingVertical, schema, rootLayerKey, iconLayerKey, state, theme }) {
79
+ const controlHeight = rootLayerKey ? getButtonControlHeight({
80
+ paddingVertical,
81
+ schema,
82
+ rootLayerKey,
83
+ iconLayerKey,
84
+ state,
85
+ theme
86
+ }) : getIconButtonControlHeight({
87
+ paddingVertical,
88
+ schema,
89
+ iconLayerKey,
90
+ state,
91
+ theme
92
+ });
93
+ if (controlHeight) {
94
+ cssDeclarations[require_index.BUTTON_CONTROL_HEIGHT_VAR] = controlHeight;
95
+ cssDeclarations.height = `var(${require_index.BUTTON_CONTROL_HEIGHT_VAR})`;
96
+ }
97
+ }
98
+ function applyIconButtonSquareDimensions(cssDeclarations) {
99
+ if (cssDeclarations[require_index.BUTTON_CONTROL_HEIGHT_VAR]) cssDeclarations.width = `var(${require_index.BUTTON_CONTROL_HEIGHT_VAR})`;
100
+ }
101
+ /**
102
+ * IconButton height for xs–lg mirrors Button (padding + max(icon, line-height)).
103
+ * xl uses icon-only height from IconButton tokens.
104
+ */
105
+ function applyIconButtonControlHeightDeclarations({ cssDeclarations, paddingVertical, iconButtonSchema, buttonHeightReferenceSchema, variantValue, iconLayerKey: _iconLayerKey, state, theme }) {
106
+ if (buttonHeightReferenceSchema && SHARED_BUTTON_ICONBUTTON_SIZES.has(variantValue) && require_iconButtonMatchButtonHeight.isIconButtonMatchButtonHeightEnabled(iconButtonSchema, variantValue)) {
107
+ const buttonRootLayerKey = `size/${variantValue}/root`;
108
+ const buttonIconLayerKey = `size/${variantValue}/icon`;
109
+ const buttonSpacingValue = buttonHeightReferenceSchema.variables?.[buttonRootLayerKey]?.spacingVertical?.[state]?.value;
110
+ applyButtonControlHeightDeclarations({
111
+ cssDeclarations,
112
+ paddingVertical: typeof buttonSpacingValue === "string" && buttonSpacingValue ? theme(require_properties.configurableProperties.spacingVertical.twThemePath("spacingAliases", buttonSpacingValue)) : paddingVertical,
113
+ schema: buttonHeightReferenceSchema,
114
+ rootLayerKey: buttonRootLayerKey,
115
+ iconLayerKey: buttonIconLayerKey,
116
+ state,
117
+ theme
118
+ });
119
+ applyIconButtonSquareDimensions(cssDeclarations);
120
+ }
121
+ }
122
+ //#endregion
123
+ exports.SHARED_BUTTON_ICONBUTTON_SIZES = SHARED_BUTTON_ICONBUTTON_SIZES;
124
+ exports.applyButtonControlHeightDeclarations = applyButtonControlHeightDeclarations;
125
+ exports.applyIconButtonControlHeightDeclarations = applyIconButtonControlHeightDeclarations;
126
+ exports.getButtonContentLineHeight = getButtonContentLineHeight;
@@ -0,0 +1,123 @@
1
+ /*! © 2026 Yahoo, Inc. UDS v0.0.0-development */
2
+ import { BUTTON_CONTROL_HEIGHT_VAR } from "../../../css-tokens/dist/index.js";
3
+ import { mapTextVariantFixtureToValue } from "../mapTextVariantFixtureToValue.js";
4
+ import { configurableProperties } from "../properties.js";
5
+ import { isIconButtonMatchButtonHeightEnabled } from "./iconButtonMatchButtonHeight.js";
6
+ //#region ../tailwind-internal/dist/packages/automated-config/dist/utils/getButtonControlHeight.js
7
+ /*! © 2026 Yahoo, Inc. UDS Tailwind Internal v0.0.0-development */
8
+ /*! © 2026 Yahoo, Inc. UDS Default Config v0.0.0-development */
9
+ /** Sizes where IconButton control height should match Button. */
10
+ const SHARED_BUTTON_ICONBUTTON_SIZES = new Set([
11
+ "xs",
12
+ "sm",
13
+ "md",
14
+ "lg"
15
+ ]);
16
+ function getButtonIconSizeVar({ schema, iconLayerKey, state, theme }) {
17
+ const iconSizeValue = schema.variables?.[iconLayerKey]?.size?.[state]?.value;
18
+ if (typeof iconSizeValue === "string" && iconSizeValue) return theme(configurableProperties.iconSize.twThemePath("iconSizes", iconSizeValue));
19
+ }
20
+ /**
21
+ * Button content box: max(icon size, text line-height).
22
+ * Matches Figma auto-layout and keeps IconButton height aligned with Button.
23
+ */
24
+ function getButtonControlContentSize({ schema, rootLayerKey, iconLayerKey, state, theme }) {
25
+ const iconSizeVar = getButtonIconSizeVar({
26
+ schema,
27
+ iconLayerKey,
28
+ state,
29
+ theme
30
+ });
31
+ const textVariantValue = schema.variables?.[rootLayerKey]?.textVariant?.[state]?.value;
32
+ if (iconSizeVar && typeof textVariantValue === "string" && textVariantValue) return `max(${iconSizeVar}, ${theme(mapTextVariantFixtureToValue("lineHeight")("textVariants", textVariantValue))})`;
33
+ if (iconSizeVar) return iconSizeVar;
34
+ }
35
+ /** `round(up, …, 1px)` matches Math.ceil in getButtonControlHeightPx and Figma hug height. */
36
+ function formatControlHeightCalc(calcExpression) {
37
+ return `round(up, ${calcExpression}, 1px)`;
38
+ }
39
+ /**
40
+ * Button control height: vertical padding on both sides plus max(icon size, text line-height).
41
+ */
42
+ function getButtonControlHeight({ paddingVertical, schema, rootLayerKey, iconLayerKey, state, theme }) {
43
+ const contentSize = getButtonControlContentSize({
44
+ schema,
45
+ rootLayerKey,
46
+ iconLayerKey,
47
+ state,
48
+ theme
49
+ });
50
+ if (!contentSize) return;
51
+ return formatControlHeightCalc(`calc(2 * ${paddingVertical} + ${contentSize})`);
52
+ }
53
+ /**
54
+ * IconButton control height: uniform padding plus icon size only (no typography).
55
+ */
56
+ function getIconButtonControlHeight({ paddingVertical, schema, iconLayerKey, state, theme }) {
57
+ const iconSizeVar = getButtonIconSizeVar({
58
+ schema,
59
+ iconLayerKey,
60
+ state,
61
+ theme
62
+ });
63
+ if (!iconSizeVar) return;
64
+ return formatControlHeightCalc(`calc(2 * ${paddingVertical} + ${iconSizeVar})`);
65
+ }
66
+ /**
67
+ * Layout line-height for button root: max(icon size, text line-height).
68
+ */
69
+ function getButtonContentLineHeight({ schema, rootLayerKey, iconLayerKey, state, theme }) {
70
+ return getButtonControlContentSize({
71
+ schema,
72
+ rootLayerKey,
73
+ iconLayerKey,
74
+ state,
75
+ theme
76
+ }) ?? "1em";
77
+ }
78
+ function applyButtonControlHeightDeclarations({ cssDeclarations, paddingVertical, schema, rootLayerKey, iconLayerKey, state, theme }) {
79
+ const controlHeight = rootLayerKey ? getButtonControlHeight({
80
+ paddingVertical,
81
+ schema,
82
+ rootLayerKey,
83
+ iconLayerKey,
84
+ state,
85
+ theme
86
+ }) : getIconButtonControlHeight({
87
+ paddingVertical,
88
+ schema,
89
+ iconLayerKey,
90
+ state,
91
+ theme
92
+ });
93
+ if (controlHeight) {
94
+ cssDeclarations[BUTTON_CONTROL_HEIGHT_VAR] = controlHeight;
95
+ cssDeclarations.height = `var(${BUTTON_CONTROL_HEIGHT_VAR})`;
96
+ }
97
+ }
98
+ function applyIconButtonSquareDimensions(cssDeclarations) {
99
+ if (cssDeclarations[BUTTON_CONTROL_HEIGHT_VAR]) cssDeclarations.width = `var(${BUTTON_CONTROL_HEIGHT_VAR})`;
100
+ }
101
+ /**
102
+ * IconButton height for xs–lg mirrors Button (padding + max(icon, line-height)).
103
+ * xl uses icon-only height from IconButton tokens.
104
+ */
105
+ function applyIconButtonControlHeightDeclarations({ cssDeclarations, paddingVertical, iconButtonSchema, buttonHeightReferenceSchema, variantValue, iconLayerKey: _iconLayerKey, state, theme }) {
106
+ if (buttonHeightReferenceSchema && SHARED_BUTTON_ICONBUTTON_SIZES.has(variantValue) && isIconButtonMatchButtonHeightEnabled(iconButtonSchema, variantValue)) {
107
+ const buttonRootLayerKey = `size/${variantValue}/root`;
108
+ const buttonIconLayerKey = `size/${variantValue}/icon`;
109
+ const buttonSpacingValue = buttonHeightReferenceSchema.variables?.[buttonRootLayerKey]?.spacingVertical?.[state]?.value;
110
+ applyButtonControlHeightDeclarations({
111
+ cssDeclarations,
112
+ paddingVertical: typeof buttonSpacingValue === "string" && buttonSpacingValue ? theme(configurableProperties.spacingVertical.twThemePath("spacingAliases", buttonSpacingValue)) : paddingVertical,
113
+ schema: buttonHeightReferenceSchema,
114
+ rootLayerKey: buttonRootLayerKey,
115
+ iconLayerKey: buttonIconLayerKey,
116
+ state,
117
+ theme
118
+ });
119
+ applyIconButtonSquareDimensions(cssDeclarations);
120
+ }
121
+ }
122
+ //#endregion
123
+ export { SHARED_BUTTON_ICONBUTTON_SIZES, applyButtonControlHeightDeclarations, applyIconButtonControlHeightDeclarations, getButtonContentLineHeight };
@@ -0,0 +1,20 @@
1
+ /*! © 2026 Yahoo, Inc. UDS v0.0.0-development */
2
+ const require_getButtonControlHeight = require("./getButtonControlHeight.cjs");
3
+ //#region ../tailwind-internal/dist/packages/automated-config/dist/utils/iconButtonMatchButtonHeight.js
4
+ /*! © 2026 Yahoo, Inc. UDS Tailwind Internal v0.0.0-development */
5
+ /*! © 2026 Yahoo, Inc. UDS Default Config v0.0.0-development */
6
+ function asMatchButtonHeightConfig(config) {
7
+ return config;
8
+ }
9
+ function getMatchButtonHeightMap(config) {
10
+ return config.iconButton?.matchButtonHeight ?? config.matchButtonHeight;
11
+ }
12
+ function isMatchButtonHeightSize(size) {
13
+ return require_getButtonControlHeight.SHARED_BUTTON_ICONBUTTON_SIZES.has(size);
14
+ }
15
+ function isIconButtonMatchButtonHeightEnabled(config, size) {
16
+ if (!isMatchButtonHeightSize(size)) return false;
17
+ return getMatchButtonHeightMap(asMatchButtonHeightConfig(config))?.[size] === true;
18
+ }
19
+ //#endregion
20
+ exports.isIconButtonMatchButtonHeightEnabled = isIconButtonMatchButtonHeightEnabled;
@@ -0,0 +1,20 @@
1
+ /*! © 2026 Yahoo, Inc. UDS v0.0.0-development */
2
+ import { SHARED_BUTTON_ICONBUTTON_SIZES } from "./getButtonControlHeight.js";
3
+ //#region ../tailwind-internal/dist/packages/automated-config/dist/utils/iconButtonMatchButtonHeight.js
4
+ /*! © 2026 Yahoo, Inc. UDS Tailwind Internal v0.0.0-development */
5
+ /*! © 2026 Yahoo, Inc. UDS Default Config v0.0.0-development */
6
+ function asMatchButtonHeightConfig(config) {
7
+ return config;
8
+ }
9
+ function getMatchButtonHeightMap(config) {
10
+ return config.iconButton?.matchButtonHeight ?? config.matchButtonHeight;
11
+ }
12
+ function isMatchButtonHeightSize(size) {
13
+ return SHARED_BUTTON_ICONBUTTON_SIZES.has(size);
14
+ }
15
+ function isIconButtonMatchButtonHeightEnabled(config, size) {
16
+ if (!isMatchButtonHeightSize(size)) return false;
17
+ return getMatchButtonHeightMap(asMatchButtonHeightConfig(config))?.[size] === true;
18
+ }
19
+ //#endregion
20
+ export { isIconButtonMatchButtonHeightEnabled };