@react-spectrum/s2 0.11.1 → 0.11.2

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 (256) hide show
  1. package/dist/Accordion.cjs +2 -2
  2. package/dist/Accordion.css +2 -2
  3. package/dist/Accordion.mjs +2 -2
  4. package/dist/ActionBar.cjs +62 -62
  5. package/dist/ActionBar.css +61 -61
  6. package/dist/ActionBar.mjs +62 -62
  7. package/dist/ActionButton.cjs +202 -202
  8. package/dist/ActionButton.css +138 -138
  9. package/dist/ActionButton.mjs +202 -202
  10. package/dist/ActionButtonGroup.cjs +15 -15
  11. package/dist/ActionButtonGroup.css +9 -9
  12. package/dist/ActionButtonGroup.mjs +15 -15
  13. package/dist/Add.cjs +10 -10
  14. package/dist/Add.css +6 -6
  15. package/dist/Add.mjs +10 -10
  16. package/dist/AlertDialog.cjs +3 -3
  17. package/dist/AlertDialog.css +3 -3
  18. package/dist/AlertDialog.mjs +3 -3
  19. package/dist/Asterisk.cjs +6 -6
  20. package/dist/Asterisk.css +4 -4
  21. package/dist/Asterisk.mjs +6 -6
  22. package/dist/Avatar.cjs +14 -14
  23. package/dist/Avatar.css +14 -14
  24. package/dist/Avatar.mjs +14 -14
  25. package/dist/AvatarGroup.cjs +134 -134
  26. package/dist/AvatarGroup.css +33 -33
  27. package/dist/AvatarGroup.mjs +134 -134
  28. package/dist/Badge.cjs +206 -206
  29. package/dist/Badge.css +127 -127
  30. package/dist/Badge.mjs +206 -206
  31. package/dist/Breadcrumbs.cjs +254 -254
  32. package/dist/Breadcrumbs.css +109 -109
  33. package/dist/Breadcrumbs.mjs +254 -254
  34. package/dist/Button.cjs +341 -341
  35. package/dist/Button.css +177 -177
  36. package/dist/Button.mjs +341 -341
  37. package/dist/ButtonGroup.cjs +20 -20
  38. package/dist/ButtonGroup.css +15 -15
  39. package/dist/ButtonGroup.mjs +20 -20
  40. package/dist/Calendar.cjs +126 -126
  41. package/dist/Calendar.css +134 -134
  42. package/dist/Calendar.mjs +126 -126
  43. package/dist/Card.cjs +304 -304
  44. package/dist/Card.css +209 -209
  45. package/dist/Card.mjs +304 -304
  46. package/dist/CardView.cjs +16 -16
  47. package/dist/CardView.css +16 -16
  48. package/dist/CardView.mjs +16 -16
  49. package/dist/CenterBaseline.cjs +1 -1
  50. package/dist/CenterBaseline.css +2 -2
  51. package/dist/CenterBaseline.mjs +1 -1
  52. package/dist/Checkbox.cjs +170 -170
  53. package/dist/Checkbox.css +92 -92
  54. package/dist/Checkbox.mjs +170 -170
  55. package/dist/CheckboxGroup.cjs +45 -45
  56. package/dist/CheckboxGroup.css +38 -38
  57. package/dist/CheckboxGroup.mjs +45 -45
  58. package/dist/Checkmark.cjs +12 -12
  59. package/dist/Checkmark.css +8 -8
  60. package/dist/Checkmark.mjs +12 -12
  61. package/dist/Chevron.cjs +12 -12
  62. package/dist/Chevron.css +10 -10
  63. package/dist/Chevron.mjs +12 -12
  64. package/dist/ClearButton.cjs +29 -29
  65. package/dist/ClearButton.css +29 -29
  66. package/dist/ClearButton.mjs +29 -29
  67. package/dist/CloseButton.cjs +54 -54
  68. package/dist/CloseButton.css +46 -46
  69. package/dist/CloseButton.mjs +54 -54
  70. package/dist/ColorArea.cjs +16 -16
  71. package/dist/ColorArea.css +16 -16
  72. package/dist/ColorArea.mjs +16 -16
  73. package/dist/ColorField.cjs +32 -32
  74. package/dist/ColorField.css +28 -28
  75. package/dist/ColorField.mjs +32 -32
  76. package/dist/ColorHandle.cjs +27 -27
  77. package/dist/ColorHandle.css +42 -42
  78. package/dist/ColorHandle.mjs +27 -27
  79. package/dist/ColorSlider.cjs +118 -118
  80. package/dist/ColorSlider.css +54 -54
  81. package/dist/ColorSlider.mjs +118 -118
  82. package/dist/ColorSwatch.cjs +29 -29
  83. package/dist/ColorSwatch.css +29 -29
  84. package/dist/ColorSwatch.mjs +29 -29
  85. package/dist/ColorSwatchPicker.cjs +27 -27
  86. package/dist/ColorSwatchPicker.css +46 -46
  87. package/dist/ColorSwatchPicker.mjs +27 -27
  88. package/dist/ColorWheel.cjs +26 -26
  89. package/dist/ColorWheel.css +17 -17
  90. package/dist/ColorWheel.mjs +26 -26
  91. package/dist/ComboBox.cjs +397 -397
  92. package/dist/ComboBox.css +181 -181
  93. package/dist/ComboBox.mjs +397 -397
  94. package/dist/ContextualHelp.cjs +5 -5
  95. package/dist/ContextualHelp.css +60 -60
  96. package/dist/ContextualHelp.mjs +5 -5
  97. package/dist/Cross.cjs +14 -14
  98. package/dist/Cross.css +10 -10
  99. package/dist/Cross.mjs +14 -14
  100. package/dist/CustomDialog.cjs +25 -25
  101. package/dist/CustomDialog.css +25 -25
  102. package/dist/CustomDialog.mjs +25 -25
  103. package/dist/Dash.cjs +10 -10
  104. package/dist/Dash.css +6 -6
  105. package/dist/Dash.mjs +10 -10
  106. package/dist/DateField.cjs +73 -73
  107. package/dist/DateField.css +77 -77
  108. package/dist/DateField.mjs +73 -73
  109. package/dist/DatePicker.cjs +180 -180
  110. package/dist/DatePicker.css +126 -126
  111. package/dist/DatePicker.mjs +180 -180
  112. package/dist/DateRangePicker.cjs +56 -56
  113. package/dist/DateRangePicker.css +60 -60
  114. package/dist/DateRangePicker.mjs +56 -56
  115. package/dist/Dialog.cjs +17 -17
  116. package/dist/Dialog.css +82 -82
  117. package/dist/Dialog.mjs +17 -17
  118. package/dist/Disclosure.cjs +135 -135
  119. package/dist/Disclosure.css +106 -106
  120. package/dist/Disclosure.mjs +135 -135
  121. package/dist/Divider.cjs +25 -25
  122. package/dist/Divider.css +25 -25
  123. package/dist/Divider.mjs +25 -25
  124. package/dist/DropZone.cjs +62 -62
  125. package/dist/DropZone.css +58 -58
  126. package/dist/DropZone.mjs +62 -62
  127. package/dist/Field.cjs +370 -370
  128. package/dist/Field.cjs.map +1 -1
  129. package/dist/Field.css +142 -142
  130. package/dist/Field.mjs +370 -370
  131. package/dist/Field.mjs.map +1 -1
  132. package/dist/Form.cjs +9 -9
  133. package/dist/Form.css +9 -9
  134. package/dist/Form.mjs +9 -9
  135. package/dist/FullscreenDialog.cjs +5 -5
  136. package/dist/FullscreenDialog.css +91 -91
  137. package/dist/FullscreenDialog.mjs +5 -5
  138. package/dist/IllustratedMessage.cjs +256 -256
  139. package/dist/IllustratedMessage.css +78 -78
  140. package/dist/IllustratedMessage.mjs +256 -256
  141. package/dist/Image.cjs +13 -13
  142. package/dist/Image.css +14 -14
  143. package/dist/Image.mjs +13 -13
  144. package/dist/InlineAlert.cjs +117 -117
  145. package/dist/InlineAlert.css +98 -98
  146. package/dist/InlineAlert.mjs +117 -117
  147. package/dist/Link.cjs +54 -54
  148. package/dist/Link.css +46 -46
  149. package/dist/Link.mjs +54 -54
  150. package/dist/LinkOut.cjs +8 -8
  151. package/dist/LinkOut.css +8 -8
  152. package/dist/LinkOut.mjs +8 -8
  153. package/dist/Menu.cjs +459 -459
  154. package/dist/Menu.css +185 -185
  155. package/dist/Menu.mjs +459 -459
  156. package/dist/Meter.cjs +163 -163
  157. package/dist/Meter.css +93 -93
  158. package/dist/Meter.mjs +163 -163
  159. package/dist/Modal.cjs +58 -58
  160. package/dist/Modal.css +50 -50
  161. package/dist/Modal.mjs +58 -58
  162. package/dist/NotificationBadge.cjs +58 -58
  163. package/dist/NotificationBadge.css +51 -51
  164. package/dist/NotificationBadge.mjs +58 -58
  165. package/dist/NumberField.cjs +115 -115
  166. package/dist/NumberField.css +100 -100
  167. package/dist/NumberField.mjs +115 -115
  168. package/dist/Picker.cjs +283 -283
  169. package/dist/Picker.css +169 -169
  170. package/dist/Picker.mjs +283 -283
  171. package/dist/Popover.cjs +86 -86
  172. package/dist/Popover.css +66 -66
  173. package/dist/Popover.mjs +86 -86
  174. package/dist/ProgressBar.cjs +173 -173
  175. package/dist/ProgressBar.css +101 -101
  176. package/dist/ProgressBar.mjs +173 -173
  177. package/dist/ProgressCircle.cjs +31 -31
  178. package/dist/ProgressCircle.css +24 -24
  179. package/dist/ProgressCircle.mjs +31 -31
  180. package/dist/Provider.cjs +11 -11
  181. package/dist/Provider.css +10 -10
  182. package/dist/Provider.mjs +11 -11
  183. package/dist/Radio.cjs +154 -154
  184. package/dist/Radio.css +79 -79
  185. package/dist/Radio.mjs +154 -154
  186. package/dist/RadioGroup.cjs +42 -42
  187. package/dist/RadioGroup.css +38 -38
  188. package/dist/RadioGroup.mjs +42 -42
  189. package/dist/RangeCalendar.cjs +7 -7
  190. package/dist/RangeCalendar.css +10 -10
  191. package/dist/RangeCalendar.mjs +7 -7
  192. package/dist/SearchField.cjs +42 -42
  193. package/dist/SearchField.css +46 -46
  194. package/dist/SearchField.mjs +42 -42
  195. package/dist/SegmentedControl.cjs +181 -181
  196. package/dist/SegmentedControl.css +118 -118
  197. package/dist/SegmentedControl.mjs +181 -181
  198. package/dist/SelectBoxGroup.cjs +142 -142
  199. package/dist/SelectBoxGroup.css +120 -120
  200. package/dist/SelectBoxGroup.mjs +142 -142
  201. package/dist/Slider.cjs +299 -299
  202. package/dist/Slider.css +151 -151
  203. package/dist/Slider.mjs +299 -299
  204. package/dist/StatusLight.cjs +125 -125
  205. package/dist/StatusLight.css +61 -61
  206. package/dist/StatusLight.mjs +125 -125
  207. package/dist/Switch.cjs +162 -162
  208. package/dist/Switch.css +74 -74
  209. package/dist/Switch.mjs +162 -162
  210. package/dist/TableView.cjs +319 -319
  211. package/dist/TableView.css +172 -172
  212. package/dist/TableView.mjs +319 -319
  213. package/dist/Tabs.cjs +115 -115
  214. package/dist/Tabs.css +100 -100
  215. package/dist/Tabs.mjs +115 -115
  216. package/dist/TabsPicker.cjs +127 -127
  217. package/dist/TabsPicker.css +111 -111
  218. package/dist/TabsPicker.mjs +127 -127
  219. package/dist/TagGroup.cjs +213 -213
  220. package/dist/TagGroup.css +147 -147
  221. package/dist/TagGroup.mjs +213 -213
  222. package/dist/TextField.cjs +59 -59
  223. package/dist/TextField.css +54 -54
  224. package/dist/TextField.mjs +59 -59
  225. package/dist/TimeField.cjs +52 -52
  226. package/dist/TimeField.css +48 -48
  227. package/dist/TimeField.mjs +52 -52
  228. package/dist/Toast.cjs +120 -120
  229. package/dist/Toast.css +107 -107
  230. package/dist/Toast.mjs +120 -120
  231. package/dist/ToggleButton.cjs +3 -3
  232. package/dist/ToggleButton.css +12 -12
  233. package/dist/ToggleButton.mjs +3 -3
  234. package/dist/Tooltip.cjs +83 -83
  235. package/dist/Tooltip.css +70 -70
  236. package/dist/Tooltip.mjs +83 -83
  237. package/dist/TreeView.cjs +146 -146
  238. package/dist/TreeView.css +147 -147
  239. package/dist/TreeView.mjs +146 -146
  240. package/icons/Icon.cjs +10 -10
  241. package/icons/Icon.css +9 -9
  242. package/icons/Icon.mjs +10 -10
  243. package/icons/Skeleton.cjs +2 -2
  244. package/icons/Skeleton.cjs.map +1 -1
  245. package/icons/Skeleton.css +6 -6
  246. package/icons/Skeleton.mjs +2 -2
  247. package/icons/Skeleton.mjs.map +1 -1
  248. package/package.json +5 -5
  249. package/style/__tests__/style-macro.test.js +56 -56
  250. package/style/dist/main.cjs +24 -24
  251. package/style/dist/module.mjs +13 -13
  252. package/style/dist/properties.mjs +3 -3
  253. package/style/dist/spectrum-theme.cjs +219 -219
  254. package/style/dist/spectrum-theme.mjs +210 -210
  255. package/style/dist/style-macro.cjs +80 -80
  256. package/style/dist/style-macro.mjs +75 -75
@@ -1,6 +1,6 @@
1
- var $438b0917ac1d1d15$exports = require("./properties.cjs");
2
- var $3vv3L$path = require("path");
3
- var $3vv3L$fs = require("fs");
1
+ var $3afa9c98bb7e1054$exports = require("./properties.cjs");
2
+ var $1oGEq$path = require("path");
3
+ var $1oGEq$fs = require("fs");
4
4
 
5
5
 
6
6
  function $parcel$interopDefault(a) {
@@ -11,13 +11,13 @@ function $parcel$export(e, n, v, s) {
11
11
  Object.defineProperty(e, n, {get: v, set: s, enumerable: true, configurable: true});
12
12
  }
13
13
 
14
- $parcel$export(module.exports, "ArbitraryProperty", () => $39b83c690be83e1d$export$d03475ad9df06cd2);
15
- $parcel$export(module.exports, "MappedProperty", () => $39b83c690be83e1d$export$965169194d2485f7);
16
- $parcel$export(module.exports, "PercentageProperty", () => $39b83c690be83e1d$export$6bff0717a72a8669);
17
- $parcel$export(module.exports, "SizingProperty", () => $39b83c690be83e1d$export$8c6b4dc3755476bb);
18
- $parcel$export(module.exports, "ExpandedProperty", () => $39b83c690be83e1d$export$1b6028cfca42adca);
19
- $parcel$export(module.exports, "parseArbitraryValue", () => $39b83c690be83e1d$export$22a8270399010c94);
20
- $parcel$export(module.exports, "createTheme", () => $39b83c690be83e1d$export$25d302a5b900a763);
14
+ $parcel$export(module.exports, "ArbitraryProperty", () => $1382b9520f7f9773$export$d03475ad9df06cd2);
15
+ $parcel$export(module.exports, "MappedProperty", () => $1382b9520f7f9773$export$965169194d2485f7);
16
+ $parcel$export(module.exports, "PercentageProperty", () => $1382b9520f7f9773$export$6bff0717a72a8669);
17
+ $parcel$export(module.exports, "SizingProperty", () => $1382b9520f7f9773$export$8c6b4dc3755476bb);
18
+ $parcel$export(module.exports, "ExpandedProperty", () => $1382b9520f7f9773$export$1b6028cfca42adca);
19
+ $parcel$export(module.exports, "parseArbitraryValue", () => $1382b9520f7f9773$export$22a8270399010c94);
20
+ $parcel$export(module.exports, "createTheme", () => $1382b9520f7f9773$export$25d302a5b900a763);
21
21
  /*
22
22
  * Copyright 2024 Adobe. All rights reserved.
23
23
  * This file is licensed to you under the Apache License, Version 2.0 (the "License");
@@ -31,11 +31,11 @@ $parcel$export(module.exports, "createTheme", () => $39b83c690be83e1d$export$25d
31
31
  */
32
32
 
33
33
 
34
- var $39b83c690be83e1d$var$$parcel$__dirname = $3vv3L$path.resolve(__dirname, "..");
34
+ var $1382b9520f7f9773$var$$parcel$__dirname = $1oGEq$path.resolve(__dirname, "..");
35
35
  // Postfix all class names with version for now.
36
- const $39b83c690be83e1d$var$json = JSON.parse((0, ($parcel$interopDefault($3vv3L$fs))).readFileSync($39b83c690be83e1d$var$$parcel$__dirname + '/../package.json', 'utf8'));
37
- const $39b83c690be83e1d$var$POSTFIX = $39b83c690be83e1d$var$json.version.includes('nightly') ? $39b83c690be83e1d$var$json.version.match(/-nightly-(.*)/)[1] : $39b83c690be83e1d$var$json.version.replace(/[0.]/g, '');
38
- class $39b83c690be83e1d$export$d03475ad9df06cd2 {
36
+ const $1382b9520f7f9773$var$json = JSON.parse((0, ($parcel$interopDefault($1oGEq$fs))).readFileSync($1382b9520f7f9773$var$$parcel$__dirname + '/../package.json', 'utf8'));
37
+ const $1382b9520f7f9773$var$POSTFIX = $1382b9520f7f9773$var$json.version.includes('nightly') ? $1382b9520f7f9773$var$json.version.match(/-nightly-(.*)/)[1] : $1382b9520f7f9773$var$json.version.replace(/[0.]/g, '');
38
+ class $1382b9520f7f9773$export$d03475ad9df06cd2 {
39
39
  constructor(property, toCSS){
40
40
  this.property = property;
41
41
  this.toCSS = toCSS || ((value)=>String(value));
@@ -49,14 +49,14 @@ class $39b83c690be83e1d$export$d03475ad9df06cd2 {
49
49
  return this.toCSS(value);
50
50
  }
51
51
  toCSSProperties(customProperty, value) {
52
- return $39b83c690be83e1d$var$mapConditionalValue(value, (value)=>[
52
+ return $1382b9520f7f9773$var$mapConditionalValue(value, (value)=>[
53
53
  {
54
54
  [customProperty || this.property]: String(value)
55
55
  }
56
56
  ]);
57
57
  }
58
58
  }
59
- class $39b83c690be83e1d$export$965169194d2485f7 extends $39b83c690be83e1d$export$d03475ad9df06cd2 {
59
+ class $1382b9520f7f9773$export$965169194d2485f7 extends $1382b9520f7f9773$export$d03475ad9df06cd2 {
60
60
  constructor(property, mapping){
61
61
  super(property);
62
62
  this.mapping = mapping;
@@ -72,15 +72,15 @@ class $39b83c690be83e1d$export$965169194d2485f7 extends $39b83c690be83e1d$export
72
72
  }
73
73
  }
74
74
  }
75
- class $39b83c690be83e1d$export$40ae678e65d951f2 extends $39b83c690be83e1d$export$965169194d2485f7 {
75
+ class $1382b9520f7f9773$export$40ae678e65d951f2 extends $1382b9520f7f9773$export$965169194d2485f7 {
76
76
  toCSSValue(value) {
77
77
  let [color, opacity] = value.split('/');
78
- return $39b83c690be83e1d$var$mapConditionalValue(this.mapping[color], (value)=>{
78
+ return $1382b9520f7f9773$var$mapConditionalValue(this.mapping[color], (value)=>{
79
79
  return opacity ? `rgb(from ${value} r g b / ${opacity}%)` : value;
80
80
  });
81
81
  }
82
82
  }
83
- class $39b83c690be83e1d$export$6bff0717a72a8669 extends $39b83c690be83e1d$export$965169194d2485f7 {
83
+ class $1382b9520f7f9773$export$6bff0717a72a8669 extends $1382b9520f7f9773$export$965169194d2485f7 {
84
84
  constructor(property, mapping){
85
85
  super(property, mapping);
86
86
  }
@@ -89,7 +89,7 @@ class $39b83c690be83e1d$export$6bff0717a72a8669 extends $39b83c690be83e1d$export
89
89
  return super.toCSSValue(value);
90
90
  }
91
91
  }
92
- class $39b83c690be83e1d$export$8c6b4dc3755476bb extends $39b83c690be83e1d$export$6bff0717a72a8669 {
92
+ class $1382b9520f7f9773$export$8c6b4dc3755476bb extends $1382b9520f7f9773$export$6bff0717a72a8669 {
93
93
  constructor(property, mapping, numberToCSS){
94
94
  super(property, mapping);
95
95
  this.numberToCSS = numberToCSS;
@@ -99,12 +99,12 @@ class $39b83c690be83e1d$export$8c6b4dc3755476bb extends $39b83c690be83e1d$export
99
99
  return super.toCSSValue(value);
100
100
  }
101
101
  }
102
- class $39b83c690be83e1d$export$1b6028cfca42adca {
102
+ class $1382b9520f7f9773$export$1b6028cfca42adca {
103
103
  constructor(properties, expand, mapping){
104
104
  this.cssProperties = properties;
105
105
  this.expand = expand;
106
- if (mapping instanceof $39b83c690be83e1d$export$965169194d2485f7) this.mapping = mapping;
107
- else if (mapping) this.mapping = new $39b83c690be83e1d$export$965169194d2485f7(properties[0], mapping);
106
+ if (mapping instanceof $1382b9520f7f9773$export$965169194d2485f7) this.mapping = mapping;
107
+ else if (mapping) this.mapping = new $1382b9520f7f9773$export$965169194d2485f7(properties[0], mapping);
108
108
  else this.mapping = null;
109
109
  }
110
110
  toCSSValue(value) {
@@ -113,23 +113,23 @@ class $39b83c690be83e1d$export$1b6028cfca42adca {
113
113
  }
114
114
  toCSSProperties(customProperty, value) {
115
115
  if (customProperty) throw new Error('Style properties that expand into multiple CSS properties cannot be set as CSS variables.');
116
- return $39b83c690be83e1d$var$mapConditionalValue(value, (value)=>[
116
+ return $1382b9520f7f9773$var$mapConditionalValue(value, (value)=>[
117
117
  this.expand(value)
118
118
  ]);
119
119
  }
120
120
  }
121
- function $39b83c690be83e1d$var$mapConditionalValue(value, fn) {
121
+ function $1382b9520f7f9773$var$mapConditionalValue(value, fn) {
122
122
  if (typeof value === 'object' && !Array.isArray(value)) {
123
123
  let res = {};
124
- for(let condition in value)res[condition] = $39b83c690be83e1d$var$mapConditionalValue(value[condition], fn);
124
+ for(let condition in value)res[condition] = $1382b9520f7f9773$var$mapConditionalValue(value[condition], fn);
125
125
  return res;
126
126
  } else return fn(value);
127
127
  }
128
- function $39b83c690be83e1d$var$mapConditionalShorthand(value, fn) {
128
+ function $1382b9520f7f9773$var$mapConditionalShorthand(value, fn) {
129
129
  if (typeof value === 'object') {
130
130
  let res = {};
131
131
  for(let condition in value){
132
- let properties = $39b83c690be83e1d$var$mapConditionalShorthand(value[condition], fn);
132
+ let properties = $1382b9520f7f9773$var$mapConditionalShorthand(value[condition], fn);
133
133
  for(let property in properties){
134
134
  res[property] ??= {};
135
135
  res[property][condition] = properties[property];
@@ -138,21 +138,21 @@ function $39b83c690be83e1d$var$mapConditionalShorthand(value, fn) {
138
138
  return res;
139
139
  } else return fn(value);
140
140
  }
141
- function $39b83c690be83e1d$export$22a8270399010c94(value) {
141
+ function $1382b9520f7f9773$export$22a8270399010c94(value) {
142
142
  if (typeof value === 'string' && value.startsWith('--')) return `var(${value})`;
143
143
  else if (typeof value === 'string' && value[0] === '[' && value[value.length - 1] === ']') return value.slice(1, -1);
144
144
  else if (typeof value === 'string' && (/^(var|calc|min|max|clamp|round|mod|rem|sin|cos|tan|asin|acos|atan|atan2|pow|sqrt|hypot|log|exp|abs|sign)\(.+\)$/.test(value) || /^(inherit|initial|unset)$/.test(value))) return value;
145
145
  }
146
- function $39b83c690be83e1d$var$shortCSSPropertyName(property) {
147
- return $438b0917ac1d1d15$exports.properties[property] ?? $39b83c690be83e1d$var$generateArbitraryValueSelector(property, true);
146
+ function $1382b9520f7f9773$var$shortCSSPropertyName(property) {
147
+ return $3afa9c98bb7e1054$exports.properties[property] ?? $1382b9520f7f9773$var$generateArbitraryValueSelector(property, true);
148
148
  }
149
- function $39b83c690be83e1d$var$classNamePrefix(property, cssProperty) {
150
- let className = $438b0917ac1d1d15$exports.properties[cssProperty];
149
+ function $1382b9520f7f9773$var$classNamePrefix(property, cssProperty) {
150
+ let className = $3afa9c98bb7e1054$exports.properties[cssProperty];
151
151
  if (className && property === '--' + className) return '-' + className + '_-';
152
152
  if (className && !property.startsWith('--')) return className;
153
- return '-' + $39b83c690be83e1d$var$generateArbitraryValueSelector(property, true) + '-';
153
+ return '-' + $1382b9520f7f9773$var$generateArbitraryValueSelector(property, true) + '-';
154
154
  }
155
- function $39b83c690be83e1d$export$25d302a5b900a763(theme) {
155
+ function $1382b9520f7f9773$export$25d302a5b900a763(theme) {
156
156
  let properties = new Map(Object.entries(theme.properties).map(([k, v])=>{
157
157
  if (!Array.isArray(v) && v.cssProperties) return [
158
158
  k,
@@ -160,7 +160,7 @@ function $39b83c690be83e1d$export$25d302a5b900a763(theme) {
160
160
  ];
161
161
  return [
162
162
  k,
163
- new $39b83c690be83e1d$export$965169194d2485f7(k, v)
163
+ new $1382b9520f7f9773$export$965169194d2485f7(k, v)
164
164
  ];
165
165
  }));
166
166
  let dependencies = new Set();
@@ -179,7 +179,7 @@ function $39b83c690be83e1d$export$25d302a5b900a763(theme) {
179
179
  let usedPriorities = 0;
180
180
  let setRules = (key, value)=>{
181
181
  usedPriorities = Math.max(usedPriorities, value[0]);
182
- rules.set(key, new $39b83c690be83e1d$var$GroupRule(value[1]));
182
+ rules.set(key, new $1382b9520f7f9773$var$GroupRule(value[1]));
183
183
  };
184
184
  hasConditions = false;
185
185
  for(let key in style){
@@ -195,7 +195,7 @@ function $39b83c690be83e1d$export$25d302a5b900a763(theme) {
195
195
  if (theme.shorthands[key]) {
196
196
  let shorthand = theme.shorthands[key];
197
197
  if (typeof shorthand === 'function') {
198
- let expanded = $39b83c690be83e1d$var$mapConditionalShorthand(value, shorthand);
198
+ let expanded = $1382b9520f7f9773$var$mapConditionalShorthand(value, shorthand);
199
199
  for(let k in expanded){
200
200
  let v = expanded[k];
201
201
  values.set(k, v);
@@ -214,7 +214,7 @@ function $39b83c690be83e1d$export$25d302a5b900a763(theme) {
214
214
  if (value != null) {
215
215
  if (!(dep in theme.properties)) throw new Error(`Unknown dependency ${dep}`);
216
216
  let prop = properties.get(dep);
217
- let name = `--${$39b83c690be83e1d$var$shortCSSPropertyName(prop.cssProperties[0])}`;
217
+ let name = `--${$1382b9520f7f9773$var$shortCSSPropertyName(prop.cssProperties[0])}`;
218
218
  // Could potentially use @property to prevent the var from inheriting in children.
219
219
  setRules(name, compileValue(name, dep, value));
220
220
  setRules(dep, compileValue(dep, dep, name));
@@ -228,7 +228,7 @@ function $39b83c690be83e1d$export$25d302a5b900a763(theme) {
228
228
  for(let i = 0; i <= usedPriorities; i++){
229
229
  if (first) first = false;
230
230
  else css += ', ';
231
- css += $39b83c690be83e1d$var$layerName($39b83c690be83e1d$var$generateName(i, true));
231
+ css += $1382b9520f7f9773$var$layerName($1382b9520f7f9773$var$generateName(i, true));
232
232
  }
233
233
  css += ';\n\n';
234
234
  // If allowed overrides are provided, generate code to match the input override string and include only allowed classes.
@@ -257,13 +257,13 @@ function $39b83c690be83e1d$export$25d302a5b900a763(theme) {
257
257
  let prop = properties.get(property);
258
258
  if (prop) {
259
259
  for (let property of prop.cssProperties)if (property && allowedOverridesSet.has(property)) {
260
- let selector = $39b83c690be83e1d$var$classNamePrefix(property, property);
260
+ let selector = $1382b9520f7f9773$var$classNamePrefix(property, property);
261
261
  let p = property.replace('--', '__');
262
262
  js += `let ${p} = false;\n`;
263
263
  loop += ` if (p[1] === ${JSON.stringify(selector)}) ${p} = true;\n`;
264
264
  }
265
265
  } else if (property.startsWith('--') && allowedOverridesSet.has(property)) {
266
- let selector = $39b83c690be83e1d$var$classNamePrefix(property, property);
266
+ let selector = $1382b9520f7f9773$var$classNamePrefix(property, property);
267
267
  let p = property.replace('--', '__');
268
268
  js += `let ${p} = false;\n`;
269
269
  loop += ` if (p[1] === ${JSON.stringify(selector)}) ${p} = true;\n`;
@@ -271,7 +271,7 @@ function $39b83c690be83e1d$export$25d302a5b900a763(theme) {
271
271
  }
272
272
  let regex = `/(?:^|\\s)(${[
273
273
  ...allowedOverridesSet
274
- ].map((p)=>$39b83c690be83e1d$var$classNamePrefix(p, p)).join('|')})[^\\s]+/g`;
274
+ ].map((p)=>$1382b9520f7f9773$var$classNamePrefix(p, p)).join('|')})[^\\s]+/g`;
275
275
  if (loop) {
276
276
  js += `let matches = (overrides || '').matchAll(${regex});\n`;
277
277
  js += 'for (let p of matches) {\n';
@@ -284,14 +284,14 @@ function $39b83c690be83e1d$export$25d302a5b900a763(theme) {
284
284
  let isStatic = !(hasConditions || allowedOverrides);
285
285
  let className = '';
286
286
  let rulesByLayer = new Map();
287
- let rootRule = new $39b83c690be83e1d$var$GroupRule([
287
+ let rootRule = new $1382b9520f7f9773$var$GroupRule([
288
288
  ...rules.values()
289
289
  ]);
290
290
  if (isStatic) className += rootRule.getStaticClassName();
291
291
  else js += rootRule.toJS(allowedOverridesSet) + '\n';
292
292
  rootRule.toCSS(rulesByLayer);
293
293
  for (let [layer, rules] of rulesByLayer){
294
- css += `@layer ${$39b83c690be83e1d$var$layerName(layer)} {\n`;
294
+ css += `@layer ${$1382b9520f7f9773$var$layerName(layer)} {\n`;
295
295
  css += rules.join('\n\n');
296
296
  css += '}\n\n';
297
297
  }
@@ -331,7 +331,7 @@ function $39b83c690be83e1d$export$25d302a5b900a763(theme) {
331
331
  // The @layer order in the generated CSS will ensure that it overrides classes applied by runtime conditions.
332
332
  let isCSSCondition = condition in theme.conditions || /^[@:]/.test(condition);
333
333
  if (!wasCSSCondition && isCSSCondition && rules.length) rules = [
334
- new $39b83c690be83e1d$var$GroupRule(rules)
334
+ new $1382b9520f7f9773$var$GroupRule(rules)
335
335
  ];
336
336
  wasCSSCondition = isCSSCondition;
337
337
  // Increment the current priority whenever we see a new CSS condition.
@@ -363,7 +363,7 @@ function $39b83c690be83e1d$export$25d302a5b900a763(theme) {
363
363
  }
364
364
  function compileCondition(conditions, condition, priority, rules) {
365
365
  if (condition === 'default' || conditions.has(condition)) return [
366
- new $39b83c690be83e1d$var$GroupRule(rules)
366
+ new $1382b9520f7f9773$var$GroupRule(rules)
367
367
  ];
368
368
  if (condition in theme.conditions || /^[@:]/.test(condition)) {
369
369
  // Conditions starting with : are CSS pseudo classes. Nest them inside the parent rule.
@@ -371,27 +371,27 @@ function $39b83c690be83e1d$export$25d302a5b900a763(theme) {
371
371
  if (prelude.startsWith(':')) {
372
372
  for (let rule of rules)rule.addPseudo(prelude);
373
373
  return [
374
- new $39b83c690be83e1d$var$GroupRule(rules, $39b83c690be83e1d$var$generateName(priority, true))
374
+ new $1382b9520f7f9773$var$GroupRule(rules, $1382b9520f7f9773$var$generateName(priority, true))
375
375
  ];
376
376
  }
377
377
  // Otherwise, wrap the rule in the condition (e.g. @media).
378
378
  // Top level layer is based on the priority of the rule, not the condition.
379
379
  // Also group in a sub-layer based on the condition so that lightningcss can more effectively deduplicate rules.
380
- let layer = `${$39b83c690be83e1d$var$generateName(priority, true)}.${$438b0917ac1d1d15$exports.conditions[theme.conditions[condition] || condition] || $39b83c690be83e1d$var$generateArbitraryValueSelector(condition, true)}`;
380
+ let layer = `${$1382b9520f7f9773$var$generateName(priority, true)}.${$3afa9c98bb7e1054$exports.conditions[theme.conditions[condition] || condition] || $1382b9520f7f9773$var$generateArbitraryValueSelector(condition, true)}`;
381
381
  return [
382
- new $39b83c690be83e1d$var$AtRule(rules, prelude, layer)
382
+ new $1382b9520f7f9773$var$AtRule(rules, prelude, layer)
383
383
  ];
384
384
  }
385
385
  hasConditions = true;
386
386
  return [
387
- new $39b83c690be83e1d$var$ConditionalRule(rules, condition)
387
+ new $1382b9520f7f9773$var$ConditionalRule(rules, condition)
388
388
  ];
389
389
  }
390
390
  function compileRule(property, themeProperty, value, priority, conditions, skipConditions) {
391
391
  let propertyFunction = properties.get(themeProperty);
392
392
  if (propertyFunction) {
393
393
  // Expand value to conditional CSS values, and then to rules.
394
- let arbitrary = $39b83c690be83e1d$export$22a8270399010c94(value);
394
+ let arbitrary = $1382b9520f7f9773$export$22a8270399010c94(value);
395
395
  let cssValue = arbitrary ? arbitrary : propertyFunction.toCSSValue(value);
396
396
  let cssProperties = propertyFunction.toCSSProperties(property.startsWith('--') ? property : null, cssValue);
397
397
  return conditionalToRules(cssProperties, priority, conditions, skipConditions, (value, priority, conditions)=>{
@@ -408,17 +408,17 @@ function $39b83c690be83e1d$export$25d302a5b900a763(theme) {
408
408
  let cssProperties = prop.cssProperties;
409
409
  if (cssProperties.length !== 1) throw new Error(`self(${v}) is not supported. ${v} expands to multiple CSS properties.`);
410
410
  dependencies.add(v);
411
- return `var(--${$39b83c690be83e1d$var$shortCSSPropertyName(cssProperties[0])}`;
411
+ return `var(--${$1382b9520f7f9773$var$shortCSSPropertyName(cssProperties[0])}`;
412
412
  });
413
413
  // Generate selector. This consists of three parts: property, conditions, value.
414
414
  let cssProperty = key;
415
415
  if (property.startsWith('--')) cssProperty = propertyFunction.cssProperties[0];
416
- let className = $39b83c690be83e1d$var$classNamePrefix(key, cssProperty);
417
- if (conditions.size > 0) for (let condition of conditions)className += $438b0917ac1d1d15$exports.conditions[theme.conditions[condition] || condition] || $39b83c690be83e1d$var$generateArbitraryValueSelector(condition);
418
- if (cssProperty !== key) className += $39b83c690be83e1d$var$shortCSSPropertyName(cssProperty);
419
- className += $438b0917ac1d1d15$exports.values[cssProperty]?.[String(value)] ?? $39b83c690be83e1d$var$generateArbitraryValueSelector(String(value));
420
- className += $39b83c690be83e1d$var$POSTFIX;
421
- rules.push(new $39b83c690be83e1d$var$StyleRule(className, key, String(value)));
416
+ let className = $1382b9520f7f9773$var$classNamePrefix(key, cssProperty);
417
+ if (conditions.size > 0) for (let condition of conditions)className += $3afa9c98bb7e1054$exports.conditions[theme.conditions[condition] || condition] || $1382b9520f7f9773$var$generateArbitraryValueSelector(condition);
418
+ if (cssProperty !== key) className += $1382b9520f7f9773$var$shortCSSPropertyName(cssProperty);
419
+ className += $3afa9c98bb7e1054$exports.values[cssProperty]?.[String(value)] ?? $1382b9520f7f9773$var$generateArbitraryValueSelector(String(value));
420
+ className += $1382b9520f7f9773$var$POSTFIX;
421
+ rules.push(new $1382b9520f7f9773$var$StyleRule(className, key, String(value)));
422
422
  }
423
423
  return [
424
424
  0,
@@ -428,7 +428,7 @@ function $39b83c690be83e1d$export$25d302a5b900a763(theme) {
428
428
  } else throw new Error('Unknown property ' + themeProperty);
429
429
  }
430
430
  }
431
- function $39b83c690be83e1d$var$kebab(property) {
431
+ function $1382b9520f7f9773$var$kebab(property) {
432
432
  if (property.startsWith('--')) return property;
433
433
  return property.replace(/([a-z])([A-Z])/g, (_, a, b)=>`${a}-${b.toLowerCase()}`);
434
434
  }
@@ -436,44 +436,44 @@ function $39b83c690be83e1d$var$kebab(property) {
436
436
  // This maps to an alphabet containing lower case letters, upper case letters, and numbers.
437
437
  // For numbers larger than 62, an underscore is prepended.
438
438
  // This encoding allows easy parsing to enable runtime merging by property.
439
- function $39b83c690be83e1d$var$generateName(index, atStart = false) {
439
+ function $1382b9520f7f9773$var$generateName(index, atStart = false) {
440
440
  if (index < 26) // lower case letters
441
441
  return String.fromCharCode(index + 97);
442
442
  if (index < 52) // upper case letters
443
443
  return String.fromCharCode(index - 26 + 65);
444
444
  if (index < 62 && !atStart) // numbers
445
445
  return String.fromCharCode(index - 52 + 48);
446
- return '_' + $39b83c690be83e1d$var$generateName(index - (atStart ? 52 : 62));
446
+ return '_' + $1382b9520f7f9773$var$generateName(index - (atStart ? 52 : 62));
447
447
  }
448
448
  // For arbitrary values, we use a hash of the string to generate the class name.
449
- function $39b83c690be83e1d$var$generateArbitraryValueSelector(v, atStart = false) {
450
- let c = $39b83c690be83e1d$var$toBase62($39b83c690be83e1d$var$hash(v));
449
+ function $1382b9520f7f9773$var$generateArbitraryValueSelector(v, atStart = false) {
450
+ let c = $1382b9520f7f9773$var$toBase62($1382b9520f7f9773$var$hash(v));
451
451
  if (atStart && /^[0-9]/.test(c)) c = `_${c}`;
452
452
  return c;
453
453
  }
454
- function $39b83c690be83e1d$var$toBase62(value) {
455
- if (value === 0) return $39b83c690be83e1d$var$generateName(value);
454
+ function $1382b9520f7f9773$var$toBase62(value) {
455
+ if (value === 0) return $1382b9520f7f9773$var$generateName(value);
456
456
  let res = '';
457
457
  while(value){
458
458
  let remainder = value % 62;
459
- res += $39b83c690be83e1d$var$generateName(remainder);
459
+ res += $1382b9520f7f9773$var$generateName(remainder);
460
460
  value = Math.floor((value - remainder) / 62);
461
461
  }
462
462
  return res;
463
463
  }
464
464
  // djb2 hash function.
465
465
  // http://www.cse.yorku.ca/~oz/hash.html
466
- function $39b83c690be83e1d$var$hash(v) {
466
+ function $1382b9520f7f9773$var$hash(v) {
467
467
  let hash = 5381;
468
468
  for(let i = 0; i < v.length; i++)hash = (hash << 5) + hash + v.charCodeAt(i) >>> 0;
469
469
  return hash;
470
470
  }
471
- function $39b83c690be83e1d$var$layerName(name) {
471
+ function $1382b9520f7f9773$var$layerName(name) {
472
472
  // All of our layers should be sub-layers of a single parent layer, so that
473
473
  // the unsafe overrides layer always comes after.
474
474
  return `_.${name}`;
475
475
  }
476
- /** A CSS style rule. */ class $39b83c690be83e1d$var$StyleRule {
476
+ /** A CSS style rule. */ class $1382b9520f7f9773$var$StyleRule {
477
477
  constructor(className, property, value){
478
478
  this.className = className;
479
479
  this.pseudos = '';
@@ -494,7 +494,7 @@ function $39b83c690be83e1d$var$layerName(name) {
494
494
  preludes.forEach((p, i)=>{
495
495
  content += `${p} {\n${' '.repeat((i + 2) * 2)}`;
496
496
  });
497
- content += `${$39b83c690be83e1d$var$kebab(this.property)}: ${this.value};\n`;
497
+ content += `${$1382b9520f7f9773$var$kebab(this.property)}: ${this.value};\n`;
498
498
  preludes.map((_, i)=>{
499
499
  content += `${' '.repeat((preludes.length - i) * 2)}}\n`;
500
500
  });
@@ -514,7 +514,7 @@ function $39b83c690be83e1d$var$layerName(name) {
514
514
  return res;
515
515
  }
516
516
  }
517
- /** Base class for rules that contain other rules. */ class $39b83c690be83e1d$var$GroupRule {
517
+ /** Base class for rules that contain other rules. */ class $1382b9520f7f9773$var$GroupRule {
518
518
  constructor(rules, layer){
519
519
  this.rules = rules;
520
520
  this.layer = layer ?? null;
@@ -530,16 +530,16 @@ function $39b83c690be83e1d$var$layerName(name) {
530
530
  }
531
531
  toJS(allowedOverridesSet, indent = '') {
532
532
  let rules = this.rules.slice();
533
- let conditional = rules.filter((rule)=>rule instanceof $39b83c690be83e1d$var$ConditionalRule).reverse().map((rule, i)=>{
533
+ let conditional = rules.filter((rule)=>rule instanceof $1382b9520f7f9773$var$ConditionalRule).reverse().map((rule, i)=>{
534
534
  return `${i > 0 ? ' else ' : ''}${rule.toJS(allowedOverridesSet, indent)}`;
535
535
  });
536
- let elseCases = rules.filter((rule)=>!(rule instanceof $39b83c690be83e1d$var$ConditionalRule)).map((rule)=>rule.toJS(allowedOverridesSet, indent));
536
+ let elseCases = rules.filter((rule)=>!(rule instanceof $1382b9520f7f9773$var$ConditionalRule)).map((rule)=>rule.toJS(allowedOverridesSet, indent));
537
537
  if (conditional.length && elseCases.length) return `${conditional.join('')} else {\n${indent} ${elseCases.join('\n' + indent + ' ')}\n${indent}}`;
538
538
  if (conditional.length) return conditional.join('');
539
539
  return elseCases.join('\n' + indent);
540
540
  }
541
541
  }
542
- /** A rule that applies conditionally in CSS (e.g. @media). */ class $39b83c690be83e1d$var$AtRule extends $39b83c690be83e1d$var$GroupRule {
542
+ /** A rule that applies conditionally in CSS (e.g. @media). */ class $1382b9520f7f9773$var$AtRule extends $1382b9520f7f9773$var$GroupRule {
543
543
  constructor(rules, prelude, layer){
544
544
  super(rules, layer);
545
545
  this.prelude = prelude;
@@ -550,7 +550,7 @@ function $39b83c690be83e1d$var$layerName(name) {
550
550
  preludes?.pop();
551
551
  }
552
552
  }
553
- /** A rule that applies conditionally at runtime. */ class $39b83c690be83e1d$var$ConditionalRule extends $39b83c690be83e1d$var$GroupRule {
553
+ /** A rule that applies conditionally at runtime. */ class $1382b9520f7f9773$var$ConditionalRule extends $1382b9520f7f9773$var$GroupRule {
554
554
  constructor(rules, condition){
555
555
  super(rules);
556
556
  this.condition = condition;
@@ -562,14 +562,14 @@ function $39b83c690be83e1d$var$layerName(name) {
562
562
  return `${indent}if (props.${this.condition}) {\n${super.toJS(allowedOverridesSet, indent + ' ')}\n${indent}}`;
563
563
  }
564
564
  }
565
- function $39b83c690be83e1d$export$1776c186c69df29e(css, layer = '_.a') {
565
+ function $1382b9520f7f9773$export$1776c186c69df29e(css, layer = '_.a') {
566
566
  // Check if `this` is undefined, which means style was not called as a macro but as a normal function.
567
567
  // We also check if this is globalThis, which happens in non-strict mode bundles.
568
568
  // Also allow style to be called as a normal function in tests.
569
569
  // @ts-ignore
570
570
  // eslint-disable-next-line
571
571
  if ((this == null || this === globalThis) && process.env.NODE_ENV !== 'test') throw new Error('The raw macro must be imported with {type: "macro"}.');
572
- let className = $39b83c690be83e1d$var$generateArbitraryValueSelector(css, true);
572
+ let className = $1382b9520f7f9773$var$generateArbitraryValueSelector(css, true);
573
573
  css = `@layer ${layer} {
574
574
  .${className} {
575
575
  ${css}
@@ -583,14 +583,14 @@ function $39b83c690be83e1d$export$1776c186c69df29e(css, layer = '_.a') {
583
583
  });
584
584
  return className;
585
585
  }
586
- function $39b83c690be83e1d$export$d25ddfdf17c3ad3e(css) {
586
+ function $1382b9520f7f9773$export$d25ddfdf17c3ad3e(css) {
587
587
  // Check if `this` is undefined, which means style was not called as a macro but as a normal function.
588
588
  // We also check if this is globalThis, which happens in non-strict mode bundles.
589
589
  // Also allow style to be called as a normal function in tests.
590
590
  // @ts-ignore
591
591
  // eslint-disable-next-line
592
592
  if ((this == null || this === globalThis) && process.env.NODE_ENV !== 'test') throw new Error('The keyframes macro must be imported with {type: "macro"}.');
593
- let name = $39b83c690be83e1d$var$generateArbitraryValueSelector(css, true);
593
+ let name = $1382b9520f7f9773$var$generateArbitraryValueSelector(css, true);
594
594
  css = `@keyframes ${name} {
595
595
  ${css}
596
596
  }`;