@sanity/ui 2.16.22 → 2.16.23

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 (325) hide show
  1. package/dist/_chunks-cjs/_visual-editing.js +115 -1040
  2. package/dist/_chunks-cjs/_visual-editing.js.map +1 -1
  3. package/dist/_chunks-cjs/refractor.js.map +1 -1
  4. package/dist/_chunks-es/_visual-editing.mjs +115 -1040
  5. package/dist/_chunks-es/_visual-editing.mjs.map +1 -1
  6. package/dist/_chunks-es/refractor.mjs.map +1 -1
  7. package/dist/_visual-editing.d.mts +411 -351
  8. package/dist/_visual-editing.d.ts +411 -351
  9. package/dist/index.d.mts +1107 -930
  10. package/dist/index.d.ts +1107 -930
  11. package/dist/index.js +64 -155
  12. package/dist/index.js.map +1 -1
  13. package/dist/index.mjs +64 -155
  14. package/dist/index.mjs.map +1 -1
  15. package/dist/theme.d.mts +769 -681
  16. package/dist/theme.d.ts +769 -681
  17. package/dist/theme.js +47 -0
  18. package/dist/theme.js.map +1 -1
  19. package/dist/theme.mjs +47 -0
  20. package/dist/theme.mjs.map +1 -1
  21. package/exports/_visual-editing.ts +1 -0
  22. package/package.json +49 -162
  23. package/src/core/_compat.ts +30 -0
  24. package/src/core/components/autocomplete/autocomplete.tsx +11 -4
  25. package/src/core/components/autocomplete/autocompleteOption.tsx +1 -0
  26. package/src/core/components/breadcrumbs/breadcrumbs.tsx +1 -0
  27. package/src/core/components/dialog/dialog.tsx +3 -0
  28. package/src/core/components/hotkeys/hotkeys.tsx +1 -0
  29. package/src/core/components/menu/menu.test.tsx +6 -4
  30. package/src/core/components/menu/menu.tsx +3 -2
  31. package/src/core/components/menu/menuButton.tsx +8 -0
  32. package/src/core/components/menu/menuGroup.tsx +5 -2
  33. package/src/core/components/menu/menuItem.tsx +4 -0
  34. package/src/core/components/menu/useMenuController.ts +6 -4
  35. package/src/core/components/skeleton/skeleton.tsx +2 -1
  36. package/src/core/components/tab/tab.tsx +1 -0
  37. package/src/core/components/tab/tabList.tsx +1 -0
  38. package/src/core/components/toast/toast.test.tsx +9 -4
  39. package/src/core/components/tree/tree.tsx +1 -0
  40. package/src/core/components/tree/treeGroup.tsx +1 -0
  41. package/src/core/components/tree/treeItem.tsx +2 -2
  42. package/src/core/hooks/useClickOutside.test.tsx +43 -15
  43. package/src/core/hooks/useClickOutside.ts +1 -1
  44. package/src/core/hooks/useClickOutsideEvent.test.tsx +8 -4
  45. package/src/core/hooks/useDelayed.test.ts +7 -6
  46. package/src/core/hooks/useElementRect/useElementRect.ts +1 -0
  47. package/src/core/hooks/useForwardedRef.ts +1 -0
  48. package/src/core/hooks/useMediaIndex/useMediaIndex.test.tsx +2 -1
  49. package/src/core/hooks/usePrefersDark.hydration.test.tsx +7 -5
  50. package/src/core/hooks/usePrefersDark.test.tsx +3 -1
  51. package/src/core/hooks/usePrefersReducedMotion.hydration.test.tsx +7 -5
  52. package/src/core/hooks/usePrefersReducedMotion.test.tsx +3 -1
  53. package/src/core/lib/createGlobalScopedContext.ts +1 -0
  54. package/src/core/lib/globalScope.ts +1 -0
  55. package/src/core/observers/elementSizeObserver.ts +1 -0
  56. package/src/core/primitives/avatar/avatar.tsx +1 -2
  57. package/src/core/primitives/avatar/avatarStack.tsx +1 -0
  58. package/src/core/primitives/badge/badge.test.tsx +3 -2
  59. package/src/core/primitives/badge/badge.tsx +2 -1
  60. package/src/core/primitives/box/box.tsx +2 -1
  61. package/src/core/primitives/button/button.test.tsx +3 -2
  62. package/src/core/primitives/button/button.tsx +2 -0
  63. package/src/core/primitives/button/styles.ts +1 -0
  64. package/src/core/primitives/card/card.tsx +1 -5
  65. package/src/core/primitives/card/types.ts +1 -0
  66. package/src/core/primitives/code/refractor.tsx +2 -0
  67. package/src/core/primitives/flex/flex.tsx +1 -3
  68. package/src/core/primitives/inline/inline.tsx +1 -0
  69. package/src/core/primitives/popover/popover.tsx +12 -3
  70. package/src/core/primitives/popover/popoverCard.tsx +1 -0
  71. package/src/core/primitives/popover/types.ts +0 -1
  72. package/src/core/primitives/stack/styles.ts +1 -0
  73. package/src/core/primitives/textInput/textInput.tsx +2 -0
  74. package/src/core/primitives/tooltip/tooltip.test.tsx +82 -49
  75. package/src/core/primitives/tooltip/tooltip.tsx +5 -0
  76. package/src/core/primitives/tooltip/tooltipCard.tsx +1 -0
  77. package/src/core/primitives/tooltip/tooltipDelayGroup/types.ts +2 -0
  78. package/src/core/styles/flex/types.ts +0 -1
  79. package/src/core/styles/font/responsiveFont.ts +0 -3
  80. package/src/core/styles/font/types.ts +1 -3
  81. package/src/core/styles/grid/gridStyle.ts +1 -0
  82. package/src/core/styles/margin/marginStyle.ts +1 -0
  83. package/src/core/styles/margin/marginsStyle.test.ts +2 -1
  84. package/src/core/styles/padding/paddingStyle.test.ts +2 -1
  85. package/src/core/styles/padding/paddingStyle.ts +1 -0
  86. package/src/core/theme/theme.test.tsx +7 -3
  87. package/src/core/theme/useRootTheme.ts +1 -0
  88. package/src/core/theme/useTheme.ts +2 -0
  89. package/src/core/utils/arrow/arrow.tsx +1 -0
  90. package/src/core/utils/boundaryElement/boundaryElement.test.tsx +9 -4
  91. package/src/core/utils/conditionalWrapper/conditionalWrapper.tsx +1 -0
  92. package/src/core/utils/getElementRef.ts +5 -0
  93. package/src/core/utils/layer/getLayerContext.test.ts +2 -0
  94. package/src/core/utils/layer/layer.test.tsx +9 -4
  95. package/src/core/utils/layer/layer.tsx +1 -0
  96. package/src/core/utils/layer/useLayer.ts +2 -0
  97. package/src/core/utils/portal/portal.test.tsx +9 -4
  98. package/src/core/utils/portal/portalProvider.tsx +4 -3
  99. package/src/core/utils/virtualList/virtualList.tsx +2 -1
  100. package/src/theme/build/_deprecated/color/_selectable/createSelectableTones.ts +10 -0
  101. package/src/theme/build/_deprecated/color/_solid/createSolidTones.ts +4 -0
  102. package/src/theme/build/_deprecated/color/button/createButtonModes.ts +5 -0
  103. package/src/theme/build/_deprecated/color/button/createButtonTones.ts +5 -0
  104. package/src/theme/build/_deprecated/color/card/createCardStates.ts +6 -0
  105. package/src/theme/build/_deprecated/color/color.test.ts +5 -1
  106. package/src/theme/build/_deprecated/color/defaults.ts +1 -0
  107. package/src/theme/build/_deprecated/color/factory.ts +36 -0
  108. package/src/theme/build/_deprecated/color/input/createInputModes.ts +5 -0
  109. package/src/theme/build/_deprecated/color/muted/createMuted.ts +4 -0
  110. package/src/theme/build/_deprecated/color/spot/createSpot.ts +3 -0
  111. package/src/theme/build/buildColorTheme.test.ts +2 -0
  112. package/src/theme/build/buildColorTheme.ts +7 -0
  113. package/src/theme/build/buildTheme.test.ts +2 -0
  114. package/src/theme/build/lib/color-fns/color-fns.test.ts +3 -1
  115. package/src/theme/build/merge.ts +5 -0
  116. package/src/theme/build/mixThemeColor.test.ts +2 -0
  117. package/src/theme/build/renderColorTheme.ts +6 -0
  118. package/src/theme/build/renderColorValue.ts +0 -2
  119. package/src/theme/build/resolveColorTokens.ts +6 -0
  120. package/src/theme/build/theme.test.ts +2 -0
  121. package/src/theme/config/helpers.ts +5 -0
  122. package/src/theme/config/system.ts +2 -0
  123. package/src/theme/config/tokens/color/types.ts +6 -4
  124. package/src/theme/config/tokens/parseTokenKey.test.ts +2 -0
  125. package/src/theme/config/tokens/parseTokenValue.test.ts +2 -0
  126. package/src/theme/config/tokens/parseTokenValue.ts +1 -0
  127. package/src/theme/getScopedTheme.ts +5 -0
  128. package/src/theme/system/color/_helpers.ts +4 -0
  129. package/src/theme/system/theme.ts +4 -0
  130. package/src/theme/system/v0/color/_system.ts +1 -0
  131. package/src/theme/system/v0/color/button.ts +14 -0
  132. package/src/theme/system/v0/color/card.ts +6 -0
  133. package/src/theme/system/v0/color/color.ts +11 -0
  134. package/src/theme/system/v0/color/input.ts +6 -0
  135. package/src/theme/system/v0/color/muted.ts +11 -0
  136. package/src/theme/system/v0/color/selectable.ts +11 -0
  137. package/src/theme/system/v0/color/solid.ts +11 -0
  138. package/src/theme/system/v0/color/spot.ts +1 -0
  139. package/src/theme/versioning/getTheme_v2.ts +15 -0
  140. package/src/theme/versioning/themeColor_v0_v2.ts +7 -0
  141. package/src/theme/versioning/themeColor_v2_v2_9.ts +1 -0
  142. package/src/theme/versioning/v0_v2.ts +13 -1
  143. package/src/theme/versioning/v2_v0.ts +15 -0
  144. package/src/core/__workshop__/constants.ts +0 -293
  145. package/src/core/components/autocomplete/__mocks__/apiStore.ts +0 -49
  146. package/src/core/components/autocomplete/__mocks__/countries.ts +0 -245
  147. package/src/core/components/autocomplete/__workshop__/async.tsx +0 -156
  148. package/src/core/components/autocomplete/__workshop__/constrainedHeight.tsx +0 -137
  149. package/src/core/components/autocomplete/__workshop__/custom.tsx +0 -89
  150. package/src/core/components/autocomplete/__workshop__/example.tsx +0 -79
  151. package/src/core/components/autocomplete/__workshop__/focusAndBlur.tsx +0 -36
  152. package/src/core/components/autocomplete/__workshop__/fullscreen.tsx +0 -294
  153. package/src/core/components/autocomplete/__workshop__/index.ts +0 -39
  154. package/src/core/components/autocomplete/__workshop__/types.ts +0 -4
  155. package/src/core/components/breadcrumbs/__workshop__/example.tsx +0 -62
  156. package/src/core/components/breadcrumbs/__workshop__/index.ts +0 -14
  157. package/src/core/components/dialog/__workshop__/activate.tsx +0 -134
  158. package/src/core/components/dialog/__workshop__/autoFocus.tsx +0 -29
  159. package/src/core/components/dialog/__workshop__/index.ts +0 -19
  160. package/src/core/components/dialog/__workshop__/layering.tsx +0 -41
  161. package/src/core/components/dialog/__workshop__/nested.tsx +0 -72
  162. package/src/core/components/dialog/__workshop__/onScroll.tsx +0 -39
  163. package/src/core/components/dialog/__workshop__/panes.tsx +0 -82
  164. package/src/core/components/dialog/__workshop__/position.tsx +0 -30
  165. package/src/core/components/dialog/__workshop__/props.tsx +0 -75
  166. package/src/core/components/dialog/__workshop__/provider.tsx +0 -11
  167. package/src/core/components/dialog/__workshop__/wrapped.tsx +0 -76
  168. package/src/core/components/hotkeys/__workshop__/index.ts +0 -14
  169. package/src/core/components/hotkeys/__workshop__/plain.tsx +0 -9
  170. package/src/core/components/menu/__workshop__/asComponent.tsx +0 -45
  171. package/src/core/components/menu/__workshop__/avatarMenu.tsx +0 -51
  172. package/src/core/components/menu/__workshop__/closableMenuButton.tsx +0 -46
  173. package/src/core/components/menu/__workshop__/constrainedInBoundary.tsx +0 -134
  174. package/src/core/components/menu/__workshop__/customMenuItem.tsx +0 -45
  175. package/src/core/components/menu/__workshop__/customSelectedState.tsx +0 -39
  176. package/src/core/components/menu/__workshop__/disableFocusOnClose.tsx +0 -40
  177. package/src/core/components/menu/__workshop__/groups.tsx +0 -156
  178. package/src/core/components/menu/__workshop__/index.ts +0 -89
  179. package/src/core/components/menu/__workshop__/menuButton.tsx +0 -80
  180. package/src/core/components/menu/__workshop__/menuGroupRight.tsx +0 -65
  181. package/src/core/components/menu/__workshop__/nestedMenu.tsx +0 -22
  182. package/src/core/components/menu/__workshop__/onCloseMenuButton.tsx +0 -41
  183. package/src/core/components/menu/__workshop__/selectedItem.tsx +0 -69
  184. package/src/core/components/menu/__workshop__/shouldFocus.tsx +0 -47
  185. package/src/core/components/menu/__workshop__/tones.tsx +0 -25
  186. package/src/core/components/menu/__workshop__/withoutArrow.tsx +0 -32
  187. package/src/core/components/skeleton/__workshop__/delay.tsx +0 -70
  188. package/src/core/components/skeleton/__workshop__/index.ts +0 -11
  189. package/src/core/components/skeleton/__workshop__/skeleton.tsx +0 -64
  190. package/src/core/components/tab/__workshop__/example.tsx +0 -79
  191. package/src/core/components/tab/__workshop__/index.ts +0 -14
  192. package/src/core/components/toast/__workshop__/hook.tsx +0 -71
  193. package/src/core/components/toast/__workshop__/index.ts +0 -19
  194. package/src/core/components/toast/__workshop__/toast.tsx +0 -26
  195. package/src/core/components/tree/__workshop__/basic.perf.ts +0 -19
  196. package/src/core/components/tree/__workshop__/basic.tsx +0 -105
  197. package/src/core/components/tree/__workshop__/index.ts +0 -21
  198. package/src/core/components/tree/__workshop__/tabFromElement.tsx +0 -84
  199. package/src/core/hooks/useElementRect/__workshop__/example.tsx +0 -32
  200. package/src/core/hooks/useElementRect/__workshop__/index.ts +0 -14
  201. package/src/core/hooks/useMediaIndex/__workshop__/index.ts +0 -14
  202. package/src/core/hooks/useMediaIndex/__workshop__/test.tsx +0 -14
  203. package/src/core/primitives/avatar/__workshop__/asButton.tsx +0 -14
  204. package/src/core/primitives/avatar/__workshop__/index.ts +0 -29
  205. package/src/core/primitives/avatar/__workshop__/stack.tsx +0 -25
  206. package/src/core/primitives/avatar/__workshop__/withinButton.tsx +0 -63
  207. package/src/core/primitives/avatar/__workshop__/withinMenuItem.tsx +0 -70
  208. package/src/core/primitives/badge/__workshop__/index.ts +0 -19
  209. package/src/core/primitives/badge/__workshop__/props.tsx +0 -30
  210. package/src/core/primitives/badge/__workshop__/tones.tsx +0 -21
  211. package/src/core/primitives/box/__workshop__/index.ts +0 -19
  212. package/src/core/primitives/box/__workshop__/props.tsx +0 -20
  213. package/src/core/primitives/box/__workshop__/responsive.tsx +0 -20
  214. package/src/core/primitives/button/__workshop__/custom.tsx +0 -51
  215. package/src/core/primitives/button/__workshop__/customIcons.tsx +0 -30
  216. package/src/core/primitives/button/__workshop__/disabled.tsx +0 -74
  217. package/src/core/primitives/button/__workshop__/index.ts +0 -59
  218. package/src/core/primitives/button/__workshop__/mixedChildren.tsx +0 -12
  219. package/src/core/primitives/button/__workshop__/props.tsx +0 -55
  220. package/src/core/primitives/button/__workshop__/sanityUploadButton.tsx +0 -36
  221. package/src/core/primitives/button/__workshop__/stacked.tsx +0 -58
  222. package/src/core/primitives/button/__workshop__/styled1.tsx +0 -17
  223. package/src/core/primitives/button/__workshop__/styled2.tsx +0 -19
  224. package/src/core/primitives/button/__workshop__/uploadButton.tsx +0 -28
  225. package/src/core/primitives/card/__workshop__/allTones.tsx +0 -25
  226. package/src/core/primitives/card/__workshop__/asButton.tsx +0 -107
  227. package/src/core/primitives/card/__workshop__/asComponent.tsx +0 -27
  228. package/src/core/primitives/card/__workshop__/checkered.tsx +0 -26
  229. package/src/core/primitives/card/__workshop__/index.ts +0 -18
  230. package/src/core/primitives/card/__workshop__/interactive.tsx +0 -30
  231. package/src/core/primitives/card/__workshop__/listNavigation.tsx +0 -80
  232. package/src/core/primitives/card/__workshop__/props.tsx +0 -53
  233. package/src/core/primitives/card/__workshop__/selected.tsx +0 -94
  234. package/src/core/primitives/card/__workshop__/styled.tsx +0 -14
  235. package/src/core/primitives/checkbox/__workshop__/example.tsx +0 -25
  236. package/src/core/primitives/checkbox/__workshop__/index.ts +0 -13
  237. package/src/core/primitives/checkbox/__workshop__/props.tsx +0 -33
  238. package/src/core/primitives/checkbox/__workshop__/readOnly.tsx +0 -16
  239. package/src/core/primitives/checkbox/__workshop__/tones.tsx +0 -28
  240. package/src/core/primitives/code/__workshop__/index.ts +0 -19
  241. package/src/core/primitives/code/__workshop__/opticalAlignment.tsx +0 -48
  242. package/src/core/primitives/code/__workshop__/props.tsx +0 -21
  243. package/src/core/primitives/container/__workshop__/example.tsx +0 -20
  244. package/src/core/primitives/container/__workshop__/index.ts +0 -8
  245. package/src/core/primitives/flex/__workshop__/example.tsx +0 -34
  246. package/src/core/primitives/flex/__workshop__/gap.tsx +0 -25
  247. package/src/core/primitives/flex/__workshop__/index.ts +0 -11
  248. package/src/core/primitives/grid/__workshop__/index.ts +0 -10
  249. package/src/core/primitives/grid/__workshop__/responsive.tsx +0 -54
  250. package/src/core/primitives/heading/__workshop__/index.ts +0 -19
  251. package/src/core/primitives/heading/__workshop__/opticalAlignment.tsx +0 -54
  252. package/src/core/primitives/heading/__workshop__/plain.tsx +0 -32
  253. package/src/core/primitives/inline/__workshop__/index.ts +0 -8
  254. package/src/core/primitives/inline/__workshop__/plain.tsx +0 -27
  255. package/src/core/primitives/kbd/__workshop__/index.ts +0 -8
  256. package/src/core/primitives/kbd/__workshop__/plain.tsx +0 -9
  257. package/src/core/primitives/label/__workshop__/index.ts +0 -19
  258. package/src/core/primitives/label/__workshop__/opticalAlignment.tsx +0 -48
  259. package/src/core/primitives/label/__workshop__/plain.tsx +0 -24
  260. package/src/core/primitives/popover/__workshop__/AlignedStory.tsx +0 -77
  261. package/src/core/primitives/popover/__workshop__/MarginsStory.tsx +0 -31
  262. package/src/core/primitives/popover/__workshop__/MatchReferenceWidthStory.tsx +0 -32
  263. package/src/core/primitives/popover/__workshop__/OpenOnMountStory.tsx +0 -11
  264. package/src/core/primitives/popover/__workshop__/PlainStory.tsx +0 -71
  265. package/src/core/primitives/popover/__workshop__/RecursiveStory.tsx +0 -71
  266. package/src/core/primitives/popover/__workshop__/SidePanelStory.tsx +0 -89
  267. package/src/core/primitives/popover/__workshop__/TestStory.tsx +0 -97
  268. package/src/core/primitives/popover/__workshop__/index.ts +0 -49
  269. package/src/core/primitives/radio/__workshop__/example.tsx +0 -63
  270. package/src/core/primitives/radio/__workshop__/index.ts +0 -11
  271. package/src/core/primitives/radio/__workshop__/plain.tsx +0 -28
  272. package/src/core/primitives/select/__workshop__/index.ts +0 -11
  273. package/src/core/primitives/select/__workshop__/plain.tsx +0 -27
  274. package/src/core/primitives/select/__workshop__/readOnly.tsx +0 -23
  275. package/src/core/primitives/spinner/__workshop__/Props.tsx +0 -15
  276. package/src/core/primitives/spinner/__workshop__/index.ts +0 -14
  277. package/src/core/primitives/stack/__workshop__/index.ts +0 -14
  278. package/src/core/primitives/stack/__workshop__/plain.tsx +0 -32
  279. package/src/core/primitives/switch/__workshop__/example.tsx +0 -23
  280. package/src/core/primitives/switch/__workshop__/index.ts +0 -11
  281. package/src/core/primitives/switch/__workshop__/props.tsx +0 -21
  282. package/src/core/primitives/text/__workshop__/colored.tsx +0 -30
  283. package/src/core/primitives/text/__workshop__/example.tsx +0 -39
  284. package/src/core/primitives/text/__workshop__/index.ts +0 -24
  285. package/src/core/primitives/text/__workshop__/opticalAlignment.tsx +0 -48
  286. package/src/core/primitives/textArea/__workshop__/index.ts +0 -14
  287. package/src/core/primitives/textArea/__workshop__/plain.tsx +0 -50
  288. package/src/core/primitives/textInput/__workshop__/clearButton.tsx +0 -30
  289. package/src/core/primitives/textInput/__workshop__/customValidity.tsx +0 -17
  290. package/src/core/primitives/textInput/__workshop__/index.ts +0 -44
  291. package/src/core/primitives/textInput/__workshop__/plain.tsx +0 -98
  292. package/src/core/primitives/textInput/__workshop__/readOnly.tsx +0 -9
  293. package/src/core/primitives/textInput/__workshop__/states.tsx +0 -53
  294. package/src/core/primitives/textInput/__workshop__/tones.tsx +0 -277
  295. package/src/core/primitives/textInput/__workshop__/typed.tsx +0 -23
  296. package/src/core/primitives/tooltip/__workshop__/customPortal.tsx +0 -102
  297. package/src/core/primitives/tooltip/__workshop__/index.ts +0 -29
  298. package/src/core/primitives/tooltip/__workshop__/overflowingBoundary.tsx +0 -74
  299. package/src/core/primitives/tooltip/__workshop__/props.tsx +0 -107
  300. package/src/core/primitives/tooltip/__workshop__/resizableBoundary.tsx +0 -86
  301. package/src/core/theme/__workshop__/build/Root.tsx +0 -367
  302. package/src/core/theme/__workshop__/build/helpers.ts +0 -46
  303. package/src/core/theme/__workshop__/build/story.tsx +0 -465
  304. package/src/core/theme/__workshop__/canvas.tsx +0 -352
  305. package/src/core/theme/__workshop__/color.tsx +0 -62
  306. package/src/core/theme/__workshop__/debug/story.tsx +0 -408
  307. package/src/core/theme/__workshop__/index.ts +0 -39
  308. package/src/core/theme/__workshop__/layer.tsx +0 -78
  309. package/src/core/theme/__workshop__/nestedProvider.tsx +0 -15
  310. package/src/core/utils/boundaryElement/__workshop__/index.ts +0 -14
  311. package/src/core/utils/boundaryElement/__workshop__/plain.tsx +0 -19
  312. package/src/core/utils/elementQuery/__workshop__/customMedia.tsx +0 -30
  313. package/src/core/utils/elementQuery/__workshop__/index.ts +0 -14
  314. package/src/core/utils/layer/__workshop__/_debug.tsx +0 -17
  315. package/src/core/utils/layer/__workshop__/index.ts +0 -24
  316. package/src/core/utils/layer/__workshop__/multipleRoots.tsx +0 -49
  317. package/src/core/utils/layer/__workshop__/nested.tsx +0 -98
  318. package/src/core/utils/layer/__workshop__/responsiveZOffset.tsx +0 -13
  319. package/src/core/utils/portal/__workshop__/index.ts +0 -14
  320. package/src/core/utils/portal/__workshop__/named.tsx +0 -63
  321. package/src/core/utils/virtualList/__workshop__/changingProps.tsx +0 -36
  322. package/src/core/utils/virtualList/__workshop__/elementScroll.tsx +0 -24
  323. package/src/core/utils/virtualList/__workshop__/index.ts +0 -29
  324. package/src/core/utils/virtualList/__workshop__/infiniteList.tsx +0 -48
  325. package/src/core/utils/virtualList/__workshop__/windowScrolll.tsx +0 -22
@@ -249,6 +249,7 @@ function _createElementRectValueListener() {
249
249
  subscribe(element, subscriber) {
250
250
  const resizeObserver = new _ResizeObserver(([entry]) => {
251
251
  subscriber({
252
+ // oxlint-disable-next-line no-deprecated
252
253
  _contentRect: entry.contentRect,
253
254
  border: {
254
255
  width: entry.borderBoxSize[0].inlineSize,
@@ -386,7 +387,7 @@ function useTheme() {
386
387
  return useTheme$1();
387
388
  }
388
389
  function useTheme_v2() {
389
- const $ = c(2), t0 = useTheme$1();
390
+ const $ = c(2), t0 = /* @__PURE__ */ useTheme$1();
390
391
  let t1;
391
392
  return $[0] !== t0 ? (t1 = getTheme_v2(t0), $[0] = t0, $[1] = t1) : t1 = $[1], t1;
392
393
  }
@@ -792,6 +793,7 @@ function responsiveGridGapStyle(props) {
792
793
  space
793
794
  } = getTheme_v2(props.theme);
794
795
  return _responsive(media, props.$gap, (gap) => ({
796
+ // oxlint-disable-next-line no-deprecated
795
797
  gridGap: gap ? rem(space[gap]) : void 0
796
798
  }));
797
799
  }
@@ -843,13 +845,7 @@ function responsiveInputPaddingIconRightStyle(props) {
843
845
  $iconRight: !0
844
846
  });
845
847
  }
846
- const ROOT_STYLE = css`
847
- &:not([hidden]) {
848
- display: flex;
849
- }
850
-
851
- align-items: center;
852
- `;
848
+ const ROOT_STYLE = css`&:not([hidden]){display:flex;}align-items:center;`;
853
849
  function textInputRootStyle() {
854
850
  return ROOT_STYLE;
855
851
  }
@@ -862,71 +858,7 @@ function textInputBaseStyle(props) {
862
858
  color,
863
859
  font
864
860
  } = getTheme_v2(props.theme);
865
- return css`
866
- appearance: none;
867
- background: none;
868
- border: 0;
869
- border-radius: 0;
870
- outline: none;
871
- width: 100%;
872
- box-sizing: border-box;
873
- font-family: ${font.text.family};
874
- font-weight: ${$weight && font.text.weights[$weight] || font.text.weights.regular};
875
- margin: 0;
876
- position: relative;
877
- z-index: 1;
878
- display: block;
879
-
880
- /* NOTE: This is a hack to disable Chrome’s autofill styles */
881
- &:-webkit-autofill,
882
- &:-webkit-autofill:hover,
883
- &:-webkit-autofill:focus,
884
- &:-webkit-autofill:active {
885
- -webkit-text-fill-color: var(--input-fg-color) !important;
886
- transition: background-color 5000s;
887
- transition-delay: 86400s /* 24h */;
888
- }
889
-
890
- /* &:is(textarea) */
891
- &[data-as='textarea'] {
892
- resize: none;
893
- }
894
-
895
- color: var(--input-fg-color);
896
-
897
- &::placeholder {
898
- color: var(--input-placeholder-color);
899
- }
900
-
901
- &[data-scheme='${$scheme}'][data-tone='${$tone}'] {
902
- --input-fg-color: ${color.input.default.enabled.fg};
903
- --input-placeholder-color: ${color.input.default.enabled.placeholder};
904
-
905
- /* enabled */
906
- &:not(:invalid):not(:disabled):not(:read-only) {
907
- --input-fg-color: ${color.input.default.enabled.fg};
908
- --input-placeholder-color: ${color.input.default.enabled.placeholder};
909
- }
910
-
911
- /* disabled */
912
- &:not(:invalid):disabled {
913
- --input-fg-color: ${color.input.default.disabled.fg};
914
- --input-placeholder-color: ${color.input.default.disabled.placeholder};
915
- }
916
-
917
- /* invalid */
918
- &:invalid {
919
- --input-fg-color: ${color.input.invalid.enabled.fg};
920
- --input-placeholder-color: ${color.input.invalid.enabled.placeholder};
921
- }
922
-
923
- /* readOnly */
924
- &:read-only {
925
- --input-fg-color: ${color.input.default.readOnly.fg};
926
- --input-placeholder-color: ${color.input.default.readOnly.placeholder};
927
- }
928
- }
929
- `;
861
+ return css`appearance:none;background:none;border:0;border-radius:0;outline:none;width:100%;box-sizing:border-box;font-family:${font.text.family};font-weight:${$weight && font.text.weights[$weight] || font.text.weights.regular};margin:0;position:relative;z-index:1;display:block;&:-webkit-autofill,&:-webkit-autofill:hover,&:-webkit-autofill:focus,&:-webkit-autofill:active{-webkit-text-fill-color:var(--input-fg-color) !important;transition:background-color 5000s;transition-delay:86400s;}&[data-as='textarea']{resize:none;}color:var(--input-fg-color);&::placeholder{color:var(--input-placeholder-color);}&[data-scheme='${$scheme}'][data-tone='${$tone}']{--input-fg-color:${color.input.default.enabled.fg};--input-placeholder-color:${color.input.default.enabled.placeholder};&:not(:invalid):not(:disabled):not(:read-only){--input-fg-color:${color.input.default.enabled.fg};--input-placeholder-color:${color.input.default.enabled.placeholder};}&:not(:invalid):disabled{--input-fg-color:${color.input.default.disabled.fg};--input-placeholder-color:${color.input.default.disabled.placeholder};}&:invalid{--input-fg-color:${color.input.invalid.enabled.fg};--input-placeholder-color:${color.input.invalid.enabled.placeholder};}&:read-only{--input-fg-color:${color.input.default.readOnly.fg};--input-placeholder-color:${color.input.default.readOnly.placeholder};}}`;
930
862
  }
931
863
  function textInputFontSizeStyle(props) {
932
864
  const {
@@ -952,136 +884,33 @@ function textInputRepresentationStyle(props) {
952
884
  color,
953
885
  input
954
886
  } = getTheme_v2(props.theme);
955
- return css`
956
- --input-box-shadow: none;
957
-
958
- position: absolute;
959
- top: 0;
960
- left: 0;
961
- right: 0;
962
- bottom: 0;
963
- display: block;
964
- pointer-events: none;
965
- z-index: 0;
966
-
967
- background-color: var(--card-bg-color);
968
- box-shadow: var(--input-box-shadow);
969
-
970
- border-top-left-radius: ${$hasPrefix ? 0 : void 0};
971
- border-bottom-left-radius: ${$hasPrefix ? 0 : void 0};
972
- border-top-right-radius: ${$hasSuffix ? 0 : void 0};
973
- border-bottom-right-radius: ${$hasSuffix ? 0 : void 0};
974
-
975
- &[data-scheme='${$scheme}'][data-tone='${$tone}'] {
976
- --card-bg-color: ${color.input.default.enabled.bg};
977
- --card-fg-color: ${color.input.default.enabled.fg};
978
-
979
- /* enabled */
980
- *:not(:disabled) + &[data-border] {
981
- --input-box-shadow: ${focusRingBorderStyle({
887
+ return css`--input-box-shadow:none;position:absolute;top:0;left:0;right:0;bottom:0;display:block;pointer-events:none;z-index:0;background-color:var(--card-bg-color);box-shadow:var(--input-box-shadow);border-top-left-radius:${$hasPrefix ? 0 : void 0};border-bottom-left-radius:${$hasPrefix ? 0 : void 0};border-top-right-radius:${$hasSuffix ? 0 : void 0};border-bottom-right-radius:${$hasSuffix ? 0 : void 0};&[data-scheme='${$scheme}'][data-tone='${$tone}']{--card-bg-color:${color.input.default.enabled.bg};--card-fg-color:${color.input.default.enabled.fg};*:not(:disabled) + &[data-border]{--input-box-shadow:${focusRingBorderStyle({
982
888
  color: color.input.default.enabled.border,
983
889
  width: input.border.width
984
- })};
985
- }
986
-
987
- /* invalid */
988
- *:not(:disabled):invalid + & {
989
- --card-bg-color: ${color.input.invalid.enabled.bg};
990
- --card-fg-color: ${color.input.invalid.enabled.fg};
991
-
992
- &[data-border] {
993
- --input-box-shadow: ${focusRingBorderStyle({
890
+ })};}*:not(:disabled):invalid + &{--card-bg-color:${color.input.invalid.enabled.bg};--card-fg-color:${color.input.invalid.enabled.fg};&[data-border]{--input-box-shadow:${focusRingBorderStyle({
994
891
  color: color.input.invalid.enabled.border,
995
892
  width: input.border.width
996
- })};
997
- }
998
- }
999
-
1000
- /* focused */
1001
- *:not(:disabled):focus + & {
1002
- &[data-border] {
1003
- --input-box-shadow: ${$unstableDisableFocusRing ? void 0 : focusRingStyle({
893
+ })};}}*:not(:disabled):focus + &{&[data-border]{--input-box-shadow:${$unstableDisableFocusRing ? void 0 : focusRingStyle({
1004
894
  border: {
1005
895
  color: color.input.default.enabled.border,
1006
896
  width: input.border.width
1007
897
  },
1008
898
  focusRing: input.text.focusRing
1009
- })};
1010
- }
1011
-
1012
- &:not([data-border]) {
1013
- --input-box-shadow: ${$unstableDisableFocusRing ? void 0 : focusRingStyle({
899
+ })};}&:not([data-border]){--input-box-shadow:${$unstableDisableFocusRing ? void 0 : focusRingStyle({
1014
900
  focusRing: input.text.focusRing
1015
- })};
1016
- }
1017
- }
1018
-
1019
- /* disabled */
1020
- *:not(:invalid):disabled + & {
1021
- --card-bg-color: ${color.input.default.disabled.bg} !important;
1022
- --card-fg-color: ${color.input.default.disabled.fg} !important;
1023
- --card-icon-color: ${color.input.default.disabled.fg} !important;
1024
-
1025
- &[data-border] {
1026
- --input-box-shadow: ${focusRingBorderStyle({
901
+ })};}}*:not(:invalid):disabled + &{--card-bg-color:${color.input.default.disabled.bg} !important;--card-fg-color:${color.input.default.disabled.fg} !important;--card-icon-color:${color.input.default.disabled.fg} !important;&[data-border]{--input-box-shadow:${focusRingBorderStyle({
1027
902
  color: color.input.default.disabled.border,
1028
903
  width: input.border.width
1029
- })};
1030
- }
1031
- }
1032
-
1033
- *:invalid:disabled + & {
1034
- --card-bg-color: ${color.input.invalid.disabled.bg} !important;
1035
- --card-fg-color: ${color.input.invalid.disabled.fg} !important;
1036
- --card-icon-color: ${color.input.invalid.disabled.fg} !important;
1037
-
1038
- &[data-border] {
1039
- --input-box-shadow: ${focusRingBorderStyle({
904
+ })};}}*:invalid:disabled + &{--card-bg-color:${color.input.invalid.disabled.bg} !important;--card-fg-color:${color.input.invalid.disabled.fg} !important;--card-icon-color:${color.input.invalid.disabled.fg} !important;&[data-border]{--input-box-shadow:${focusRingBorderStyle({
1040
905
  color: color.input.invalid.disabled.border,
1041
906
  width: input.border.width
1042
- })};
1043
- }
1044
- }
1045
-
1046
- /* readOnly */
1047
- *:not(:invalid):read-only + & {
1048
- --card-bg-color: ${color.input.default.readOnly.bg} !important;
1049
- --card-fg-color: ${color.input.default.readOnly.fg} !important;
1050
- }
1051
-
1052
- *:invalid:read-only + & {
1053
- --card-bg-color: ${color.input.invalid.readOnly.bg} !important;
1054
- --card-fg-color: ${color.input.invalid.readOnly.fg} !important;
1055
- }
1056
-
1057
- /* hovered */
1058
- @media (hover: hover) {
1059
- *:not(:disabled):not(:read-only):not(:invalid):hover + & {
1060
- --card-bg-color: ${color.input.default.hovered.bg};
1061
- --card-fg-color: ${color.input.default.hovered.fg};
1062
- }
1063
-
1064
- *:invalid:not(:disabled):not(:read-only):hover + & {
1065
- --card-bg-color: ${color.input.invalid.hovered.bg};
1066
- --card-fg-color: ${color.input.invalid.hovered.fg};
1067
- }
1068
-
1069
- *:not(:disabled):not(:read-only):not(:invalid):not(:focus):hover + &[data-border] {
1070
- --input-box-shadow: ${focusRingBorderStyle({
907
+ })};}}*:not(:invalid):read-only + &{--card-bg-color:${color.input.default.readOnly.bg} !important;--card-fg-color:${color.input.default.readOnly.fg} !important;}*:invalid:read-only + &{--card-bg-color:${color.input.invalid.readOnly.bg} !important;--card-fg-color:${color.input.invalid.readOnly.fg} !important;}@media (hover:hover){*:not(:disabled):not(:read-only):not(:invalid):hover + &{--card-bg-color:${color.input.default.hovered.bg};--card-fg-color:${color.input.default.hovered.fg};}*:invalid:not(:disabled):not(:read-only):hover + &{--card-bg-color:${color.input.invalid.hovered.bg};--card-fg-color:${color.input.invalid.hovered.fg};}*:not(:disabled):not(:read-only):not(:invalid):not(:focus):hover + &[data-border]{--input-box-shadow:${focusRingBorderStyle({
1071
908
  color: color.input.default.hovered.border,
1072
909
  width: input.border.width
1073
- })};
1074
- }
1075
-
1076
- *:invalid:not(:disabled):not(:read-only):not(:focus):hover + &[data-border] {
1077
- --input-box-shadow: ${focusRingBorderStyle({
910
+ })};}*:invalid:not(:disabled):not(:read-only):not(:focus):hover + &[data-border]{--input-box-shadow:${focusRingBorderStyle({
1078
911
  color: color.input.invalid.hovered.border,
1079
912
  width: input.border.width
1080
- })};
1081
- }
1082
- }
1083
- }
1084
- `;
913
+ })};}}}`;
1085
914
  }
1086
915
  function responsiveMarginStyle(props) {
1087
916
  const {
@@ -1136,37 +965,7 @@ function labelBaseStyle(props) {
1136
965
  } = props, {
1137
966
  font
1138
967
  } = getTheme_v2(props.theme);
1139
- return css`
1140
- text-transform: uppercase;
1141
-
1142
- ${$accent && css`
1143
- color: var(--card-accent-fg-color);
1144
- `}
1145
-
1146
- ${$muted && css`
1147
- color: var(--card-muted-fg-color);
1148
- `}
1149
-
1150
- & code {
1151
- font-family: ${font.code.family};
1152
- border-radius: 1px;
1153
- }
1154
-
1155
- & a {
1156
- text-decoration: none;
1157
- border-radius: 1px;
1158
- }
1159
-
1160
- & svg {
1161
- /* Certain popular CSS libraries changes the defaults for SVG display */
1162
- /* Make sure SVGs are rendered as inline elements */
1163
- display: inline;
1164
- }
1165
-
1166
- & [data-sanity-icon] {
1167
- vertical-align: baseline;
1168
- }
1169
- `;
968
+ return css`text-transform:uppercase;${$accent && css`color:var(--card-accent-fg-color);`} ${$muted && css`color:var(--card-muted-fg-color);`} & code{font-family:${font.code.family};border-radius:1px;}& a{text-decoration:none;border-radius:1px;}& svg{display:inline;}& [data-sanity-icon]{vertical-align:baseline;}`;
1170
969
  }
1171
970
  const StyledLabel = /* @__PURE__ */ styled.div.withConfig({
1172
971
  displayName: "StyledLabel",
@@ -1586,66 +1385,7 @@ function textBaseStyle(props) {
1586
1385
  } = props, {
1587
1386
  font
1588
1387
  } = getTheme_v2(props.theme);
1589
- return css`
1590
- color: var(--card-fg-color);
1591
-
1592
- ${$accent && css`
1593
- color: var(--card-accent-fg-color);
1594
- `}
1595
-
1596
- ${$muted && css`
1597
- color: var(--card-muted-fg-color);
1598
- `}
1599
-
1600
- & code {
1601
- font-family: ${font.code.family};
1602
- border-radius: 1px;
1603
- background-color: var(--card-code-bg-color);
1604
- color: var(--card-code-fg-color);
1605
- }
1606
-
1607
- & a {
1608
- text-decoration: none;
1609
- border-radius: 1px;
1610
- color: var(--card-link-color);
1611
- outline: none;
1612
-
1613
- @media (hover: hover) {
1614
- &:hover {
1615
- text-decoration: underline;
1616
- }
1617
- }
1618
-
1619
- &:focus {
1620
- box-shadow:
1621
- 0 0 0 1px var(--card-bg-color),
1622
- 0 0 0 3px var(--card-focus-ring-color);
1623
- }
1624
-
1625
- &:focus:not(:focus-visible) {
1626
- box-shadow: none;
1627
- }
1628
- }
1629
-
1630
- & strong {
1631
- font-weight: ${font.text.weights.bold};
1632
- }
1633
-
1634
- & svg {
1635
- /* Certain popular CSS libraries changes the defaults for SVG display */
1636
- /* Make sure SVGs are rendered as inline elements */
1637
- display: inline;
1638
- }
1639
-
1640
- & [data-sanity-icon] {
1641
- vertical-align: baseline;
1642
- color: var(--card-icon-color);
1643
-
1644
- & path {
1645
- vector-effect: non-scaling-stroke !important;
1646
- }
1647
- }
1648
- `;
1388
+ return css`color:var(--card-fg-color);${$accent && css`color:var(--card-accent-fg-color);`} ${$muted && css`color:var(--card-muted-fg-color);`} & code{font-family:${font.code.family};border-radius:1px;background-color:var(--card-code-bg-color);color:var(--card-code-fg-color);}& a{text-decoration:none;border-radius:1px;color:var(--card-link-color);outline:none;@media (hover:hover){&:hover{text-decoration:underline;}}&:focus{box-shadow:0 0 0 1px var(--card-bg-color),0 0 0 3px var(--card-focus-ring-color);}&:focus:not(:focus-visible){box-shadow:none;}}& strong{font-weight:${font.text.weights.bold};}& svg{display:inline;}& [data-sanity-icon]{vertical-align:baseline;color:var(--card-icon-color);& path{vector-effect:non-scaling-stroke !important;}}`;
1649
1389
  }
1650
1390
  const StyledText = /* @__PURE__ */ styled.div.withConfig({
1651
1391
  displayName: "StyledText",
@@ -1841,45 +1581,7 @@ function buttonBaseStyles(props) {
1841
1581
  } = props, {
1842
1582
  style
1843
1583
  } = getTheme_v2(props.theme);
1844
- return css`
1845
- ${style?.button};
1846
-
1847
- -webkit-font-smoothing: inherit;
1848
- appearance: none;
1849
- display: inline-flex;
1850
- align-items: center;
1851
- font: inherit;
1852
- border: 0;
1853
- outline: none;
1854
- user-select: none;
1855
- text-decoration: none;
1856
- border: 0;
1857
- box-sizing: border-box;
1858
- padding: 0;
1859
- margin: 0;
1860
- white-space: nowrap;
1861
- text-align: left;
1862
- position: relative;
1863
- vertical-align: top;
1864
-
1865
- ${$width === "fill" && css`
1866
- width: -moz-available;
1867
- width: -webkit-fill-available;
1868
- width: stretch;
1869
- `}
1870
-
1871
- & > span {
1872
- display: block;
1873
- flex: 1;
1874
- min-width: 0;
1875
- border-radius: inherit;
1876
- }
1877
-
1878
- &::-moz-focus-inner {
1879
- border: 0;
1880
- padding: 0;
1881
- }
1882
- `;
1584
+ return css`${style?.button};-webkit-font-smoothing:inherit;appearance:none;display:inline-flex;align-items:center;font:inherit;border:0;outline:none;user-select:none;text-decoration:none;border:0;box-sizing:border-box;padding:0;margin:0;white-space:nowrap;text-align:left;position:relative;vertical-align:top;${$width === "fill" && css`width:-moz-available;width:-webkit-fill-available;width:stretch;`} & > span{display:block;flex:1;min-width:0;border-radius:inherit;}&::-moz-focus-inner{border:0;padding:0;}`;
1883
1585
  }
1884
1586
  function combineBoxShadow(...boxShadows) {
1885
1587
  return boxShadows.filter(Boolean).join(",");
@@ -2008,36 +1710,7 @@ function cardBaseStyle(props) {
2008
1710
  } = props, {
2009
1711
  space
2010
1712
  } = getTheme_v2(props.theme);
2011
- return css`
2012
- ${$checkered && css`
2013
- background-size: ${space[3]}px ${space[3]}px;
2014
- background-position: 50% 50%;
2015
- background-image: var(--card-bg-image);
2016
- `}
2017
-
2018
- &[data-as='button'] {
2019
- -webkit-font-smoothing: inherit;
2020
- appearance: none;
2021
- outline: none;
2022
- font: inherit;
2023
- text-align: inherit;
2024
- border: 0;
2025
- width: -moz-available;
2026
- width: -webkit-fill-available;
2027
- width: stretch;
2028
- }
2029
-
2030
- /* &:is(a) */
2031
- &[data-as='a'] {
2032
- outline: none;
2033
- text-decoration: none;
2034
- }
2035
-
2036
- /* &:is(pre) */
2037
- &[data-as='pre'] {
2038
- font: inherit;
2039
- }
2040
- `;
1713
+ return css`${$checkered && css`background-size:${space[3]}px ${space[3]}px;background-position:50% 50%;background-image:var(--card-bg-image);`} &[data-as='button']{-webkit-font-smoothing:inherit;appearance:none;outline:none;font:inherit;text-align:inherit;border:0;width:-moz-available;width:-webkit-fill-available;width:stretch;}&[data-as='a']{outline:none;text-decoration:none;}&[data-as='pre']{font:inherit;}`;
2041
1714
  }
2042
1715
  function cardColorStyle(props) {
2043
1716
  const {
@@ -2052,100 +1725,15 @@ function cardColorStyle(props) {
2052
1725
  width: card.border.width,
2053
1726
  color: "var(--card-border-color)"
2054
1727
  };
2055
- return css`
2056
- color-scheme: ${color._dark ? "dark" : "light"};
2057
-
2058
- ${_cardColorStyle(color, color, $checkered)}
2059
-
2060
- background-color: ${$muted ? "var(--card-muted-bg-color)" : "var(--card-bg-color)"};
2061
- color: var(--card-fg-color);
2062
-
2063
- /* &:is(button) */
2064
- &[data-as='button'] {
2065
- --card-focus-ring-box-shadow: none;
2066
-
2067
- cursor: default;
2068
- box-shadow: var(--card-focus-ring-box-shadow);
2069
-
2070
- &:disabled {
2071
- ${_cardColorStyle(color, color.selectable.default.disabled, $checkered)}
2072
- }
2073
-
2074
- &:not(:disabled) {
2075
- &[data-pressed] {
2076
- ${_cardColorStyle(color, color.selectable.default.pressed, $checkered)}
2077
- }
2078
-
2079
- &[data-selected] {
2080
- ${_cardColorStyle(color, color.selectable.default.selected, $checkered)}
2081
- }
2082
-
2083
- @media (hover: hover) {
2084
- &:not([data-pressed]):not([data-selected]) {
2085
- &[data-hovered],
2086
- &:hover {
2087
- ${_cardColorStyle(color, color.selectable.default.hovered, $checkered)}
2088
- }
2089
-
2090
- &:active {
2091
- ${_cardColorStyle(color, color.selectable.default.pressed, $checkered)}
2092
- }
2093
- }
2094
- }
2095
-
2096
- &:focus-visible {
2097
- --card-focus-ring-box-shadow: ${$focusRing ? focusRingStyle({
1728
+ return css`color-scheme:${color._dark ? "dark" : "light"};${_cardColorStyle(color, color, $checkered)} background-color:${$muted ? "var(--card-muted-bg-color)" : "var(--card-bg-color)"};color:var(--card-fg-color);&[data-as='button']{--card-focus-ring-box-shadow:none;cursor:default;box-shadow:var(--card-focus-ring-box-shadow);&:disabled{${_cardColorStyle(color, color.selectable.default.disabled, $checkered)}}&:not(:disabled){&[data-pressed]{${_cardColorStyle(color, color.selectable.default.pressed, $checkered)}}&[data-selected]{${_cardColorStyle(color, color.selectable.default.selected, $checkered)}}@media (hover:hover){&:not([data-pressed]):not([data-selected]){&[data-hovered],&:hover{${_cardColorStyle(color, color.selectable.default.hovered, $checkered)}}&:active{${_cardColorStyle(color, color.selectable.default.pressed, $checkered)}}}}&:focus-visible{--card-focus-ring-box-shadow:${$focusRing ? focusRingStyle({
2098
1729
  base: color,
2099
1730
  border: border2,
2100
1731
  focusRing: card.focusRing
2101
- }) : void 0};
2102
- }
2103
- }
2104
- }
2105
-
2106
- /* &:is(a) */
2107
- &[data-as='a'] {
2108
- cursor: pointer;
2109
- box-shadow: var(--card-focus-ring-box-shadow);
2110
-
2111
- &[data-disabled] {
2112
- ${_cardColorStyle(color, color.selectable.default.disabled, $checkered)}
2113
- }
2114
-
2115
- &:not([data-disabled]) {
2116
- &[data-pressed] {
2117
- ${_cardColorStyle(color, color.selectable.default.pressed, $checkered)}
2118
- }
2119
-
2120
- &[data-selected] {
2121
- ${_cardColorStyle(color, color.selectable.default.selected, $checkered)}
2122
- }
2123
-
2124
- @media (hover: hover) {
2125
- &:not([data-pressed]):not([data-selected]) {
2126
- &[data-hovered],
2127
- &:hover {
2128
- ${_cardColorStyle(color, color.selectable.default.hovered, $checkered)}
2129
- }
2130
-
2131
- &:active {
2132
- ${_cardColorStyle(color, color.selectable.default.pressed, $checkered)}
2133
- }
2134
- }
2135
- }
2136
-
2137
- &:focus-visible {
2138
- --card-focus-ring-box-shadow: ${$focusRing ? focusRingStyle({
1732
+ }) : void 0};}}}&[data-as='a']{cursor:pointer;box-shadow:var(--card-focus-ring-box-shadow);&[data-disabled]{${_cardColorStyle(color, color.selectable.default.disabled, $checkered)}}&:not([data-disabled]){&[data-pressed]{${_cardColorStyle(color, color.selectable.default.pressed, $checkered)}}&[data-selected]{${_cardColorStyle(color, color.selectable.default.selected, $checkered)}}@media (hover:hover){&:not([data-pressed]):not([data-selected]){&[data-hovered],&:hover{${_cardColorStyle(color, color.selectable.default.hovered, $checkered)}}&:active{${_cardColorStyle(color, color.selectable.default.pressed, $checkered)}}}}&:focus-visible{--card-focus-ring-box-shadow:${$focusRing ? focusRingStyle({
2139
1733
  base: color,
2140
1734
  border: border2,
2141
1735
  focusRing: card.focusRing
2142
- }) : void 0};
2143
- }
2144
- }
2145
- }
2146
-
2147
- ${style?.card?.root}
2148
- `;
1736
+ }) : void 0};}}}${style?.card?.root}`;
2149
1737
  }
2150
1738
  const StyledCard = /* @__PURE__ */ styled(Box).withConfig({
2151
1739
  displayName: "StyledCard",
@@ -2179,10 +1767,7 @@ const StyledCard = /* @__PURE__ */ styled(Box).withConfig({
2179
1767
  });
2180
1768
  Card.displayName = "ForwardRef(Card)";
2181
1769
  function checkboxBaseStyles() {
2182
- return css`
2183
- position: relative;
2184
- display: inline-block;
2185
- `;
1770
+ return css`position:relative;display:inline-block;`;
2186
1771
  }
2187
1772
  function inputElementStyles(props) {
2188
1773
  const {
@@ -2192,86 +1777,23 @@ function inputElementStyles(props) {
2192
1777
  } = getTheme_v2(props.theme), {
2193
1778
  focusRing
2194
1779
  } = input.checkbox;
2195
- return css`
2196
- position: absolute;
2197
- top: 0;
2198
- left: 0;
2199
- width: 100%;
2200
- height: 100%;
2201
- outline: none;
2202
- opacity: 0;
2203
- z-index: 1;
2204
- padding: 0;
2205
- margin: 0;
2206
-
2207
- & + span {
2208
- position: relative;
2209
- display: block;
2210
- height: ${rem(input.checkbox.size)};
2211
- width: ${rem(input.checkbox.size)};
2212
- box-sizing: border-box;
2213
- box-shadow: ${focusRingBorderStyle({
1780
+ return css`position:absolute;top:0;left:0;width:100%;height:100%;outline:none;opacity:0;z-index:1;padding:0;margin:0;& + span{position:relative;display:block;height:${rem(input.checkbox.size)};width:${rem(input.checkbox.size)};box-sizing:border-box;box-shadow:${focusRingBorderStyle({
2214
1781
  color: color.input.default.enabled.border,
2215
1782
  width: input.border.width
2216
- })};
2217
- border-radius: ${rem(radius[2])};
2218
- line-height: 1;
2219
- background-color: ${color.input.default.enabled.bg};
2220
-
2221
- & > svg {
2222
- display: block;
2223
- position: absolute;
2224
- opacity: 0;
2225
- height: 100%;
2226
- width: 100%;
2227
-
2228
- & > path {
2229
- vector-effect: non-scaling-stroke;
2230
- stroke-width: 1.5px !important;
2231
- }
2232
- }
2233
- }
2234
-
2235
- &:checked + span {
2236
- background: ${color.input.default.enabled.fg};
2237
- box-shadow: ${focusRingBorderStyle({
1783
+ })};border-radius:${rem(radius[2])};line-height:1;background-color:${color.input.default.enabled.bg};& > svg{display:block;position:absolute;opacity:0;height:100%;width:100%;& > path{vector-effect:non-scaling-stroke;stroke-width:1.5px !important;}}}&:checked + span{background:${color.input.default.enabled.fg};box-shadow:${focusRingBorderStyle({
2238
1784
  color: color.input.default.enabled.fg,
2239
1785
  width: input.border.width
2240
- })};
2241
- color: ${color.input.default.enabled.bg};
2242
- }
2243
-
2244
- /* focus */
2245
- &:not(:disabled):focus:focus-visible + span {
2246
- box-shadow: ${focusRingStyle({
1786
+ })};color:${color.input.default.enabled.bg};}&:not(:disabled):focus:focus-visible + span{box-shadow:${focusRingStyle({
2247
1787
  focusRing
2248
- })};
2249
- }
2250
-
2251
- /* focus when checked - uses a different offset */
2252
- &:not(:disabled):focus:focus-visible&:checked + span {
2253
- box-shadow: ${focusRingStyle({
1788
+ })};}&:not(:disabled):focus:focus-visible&:checked + span{box-shadow:${focusRingStyle({
2254
1789
  focusRing: {
2255
1790
  width: 1,
2256
1791
  offset: 1
2257
1792
  }
2258
- })};
2259
- }
2260
-
2261
- &[data-error] + span {
2262
- background-color: ${color.input.invalid.enabled.border};
2263
- box-shadow: ${focusRingBorderStyle({
1793
+ })};}&[data-error] + span{background-color:${color.input.invalid.enabled.border};box-shadow:${focusRingBorderStyle({
2264
1794
  width: input.border.width,
2265
1795
  color: color.input.invalid.enabled.muted.bg
2266
- })};
2267
- color: ${color.input.default.disabled.fg};
2268
- }
2269
- &[data-error]&:checked + span {
2270
- background-color: ${color.input.invalid.enabled.muted.bg};
2271
- color: ${color.input.default.enabled.bg};
2272
- }
2273
- &[data-error]&:checked&:not(:disabled):focus:focus-visible + span {
2274
- box-shadow: ${focusRingStyle({
1796
+ })};color:${color.input.default.disabled.fg};}&[data-error]&:checked + span{background-color:${color.input.invalid.enabled.muted.bg};color:${color.input.default.enabled.bg};}&[data-error]&:checked&:not(:disabled):focus:focus-visible + span{box-shadow:${focusRingStyle({
2275
1797
  border: {
2276
1798
  width: input.border.width,
2277
1799
  color: color.input.invalid.readOnly.muted.bg
@@ -2280,41 +1802,13 @@ function inputElementStyles(props) {
2280
1802
  width: 1,
2281
1803
  offset: 1
2282
1804
  }
2283
- })};
2284
- }
2285
-
2286
- &:disabled + span {
2287
- background-color: ${color.input.default.disabled.bg};
2288
- box-shadow: ${focusRingBorderStyle({
1805
+ })};}&:disabled + span{background-color:${color.input.default.disabled.bg};box-shadow:${focusRingBorderStyle({
2289
1806
  width: input.border.width,
2290
1807
  color: color.input.default.disabled.border
2291
- })};
2292
- color: ${color.input.default.disabled.fg};
2293
- }
2294
- &:disabled&:checked + span {
2295
- background-color: ${color.input.default.disabled.muted.bg};
2296
- }
2297
-
2298
- &[data-read-only] + span {
2299
- background-color: ${color.input.default.readOnly.bg};
2300
- box-shadow: ${focusRingBorderStyle({
1808
+ })};color:${color.input.default.disabled.fg};}&:disabled&:checked + span{background-color:${color.input.default.disabled.muted.bg};}&[data-read-only] + span{background-color:${color.input.default.readOnly.bg};box-shadow:${focusRingBorderStyle({
2301
1809
  width: input.border.width,
2302
1810
  color: color.input.default.readOnly.border
2303
- })};
2304
- color: ${color.input.default.readOnly.fg};
2305
- }
2306
-
2307
- &[data-read-only]&:checked + span {
2308
- background-color: ${color.input.default.readOnly.muted.bg};
2309
- }
2310
-
2311
- &:checked + span > svg:first-child {
2312
- opacity: 1;
2313
- }
2314
- &:indeterminate + span > svg:last-child {
2315
- opacity: 1;
2316
- }
2317
- `;
1811
+ })};color:${color.input.default.readOnly.fg};}&[data-read-only]&:checked + span{background-color:${color.input.default.readOnly.muted.bg};}&:checked + span > svg:first-child{opacity:1;}&:indeterminate + span > svg:last-child{opacity:1;}`;
2318
1812
  }
2319
1813
  const StyledCheckbox = /* @__PURE__ */ styled.div.withConfig({
2320
1814
  displayName: "StyledCheckbox",
@@ -2477,33 +1971,7 @@ function codeSyntaxHighlightingStyle({
2477
1971
  };
2478
1972
  }
2479
1973
  function codeBaseStyle() {
2480
- return css`
2481
- color: var(--card-code-fg-color);
2482
-
2483
- & code {
2484
- font-family: inherit;
2485
-
2486
- &.refractor .token {
2487
- ${codeSyntaxHighlightingStyle}
2488
- }
2489
- }
2490
-
2491
- & a {
2492
- color: inherit;
2493
- text-decoration: underline;
2494
- border-radius: 1px;
2495
- }
2496
-
2497
- & svg {
2498
- /* Certain popular CSS libraries changes the defaults for SVG display */
2499
- /* Make sure SVGs are rendered as inline elements */
2500
- display: inline;
2501
- }
2502
-
2503
- & [data-sanity-icon] {
2504
- vertical-align: baseline;
2505
- }
2506
- `;
1974
+ return css`color:var(--card-code-fg-color);& code{font-family:inherit;&.refractor .token{${codeSyntaxHighlightingStyle}}}& a{color:inherit;text-decoration:underline;border-radius:1px;}& svg{display:inline;}& [data-sanity-icon]{vertical-align:baseline;}`;
2507
1975
  }
2508
1976
  const LazyRefractor = lazy(() => import("./refractor.mjs")), StyledCode = /* @__PURE__ */ styled.pre.withConfig({
2509
1977
  displayName: "StyledCode",
@@ -2592,57 +2060,7 @@ function headingBaseStyle(props) {
2592
2060
  } = props, {
2593
2061
  font
2594
2062
  } = getTheme_v2(props.theme);
2595
- return css`
2596
- ${$accent && css`
2597
- color: var(--card-accent-fg-color);
2598
- `}
2599
-
2600
- ${$muted && css`
2601
- color: var(--card-muted-fg-color);
2602
- `}
2603
-
2604
- & code {
2605
- font-family: ${font.code.family};
2606
- border-radius: 1px;
2607
- }
2608
-
2609
- & a {
2610
- text-decoration: none;
2611
- border-radius: 1px;
2612
- color: var(--card-link-color);
2613
- outline: none;
2614
-
2615
- @media (hover: hover) {
2616
- &:hover {
2617
- text-decoration: underline;
2618
- }
2619
- }
2620
-
2621
- &:focus {
2622
- box-shadow:
2623
- 0 0 0 1px var(--card-bg-color),
2624
- 0 0 0 3px var(--card-focus-ring-color);
2625
- }
2626
-
2627
- &:focus:not(:focus-visible) {
2628
- box-shadow: none;
2629
- }
2630
- }
2631
-
2632
- & strong {
2633
- font-weight: ${font.heading.weights.bold};
2634
- }
2635
-
2636
- & svg {
2637
- /* Certain popular CSS libraries changes the defaults for SVG display */
2638
- /* Make sure SVGs are rendered as inline elements */
2639
- display: inline;
2640
- }
2641
-
2642
- & [data-sanity-icon] {
2643
- vertical-align: baseline;
2644
- }
2645
- `;
2063
+ return css`${$accent && css`color:var(--card-accent-fg-color);`} ${$muted && css`color:var(--card-muted-fg-color);`} & code{font-family:${font.code.family};border-radius:1px;}& a{text-decoration:none;border-radius:1px;color:var(--card-link-color);outline:none;@media (hover:hover){&:hover{text-decoration:underline;}}&:focus{box-shadow:0 0 0 1px var(--card-bg-color),0 0 0 3px var(--card-focus-ring-color);}&:focus:not(:focus-visible){box-shadow:none;}}& strong{font-weight:${font.heading.weights.bold};}& svg{display:inline;}& [data-sanity-icon]{vertical-align:baseline;}`;
2646
2064
  }
2647
2065
  const StyledHeading = /* @__PURE__ */ styled.div.withConfig({
2648
2066
  displayName: "StyledHeading",
@@ -3518,6 +2936,7 @@ const ViewportOverlay = () => {
3518
2936
  __unstable_margins: margins = DEFAULT_POPOVER_MARGINS,
3519
2937
  animate: _animate = !1,
3520
2938
  arrow: arrowProp = !1,
2939
+ // oxlint-disable-next-line no-deprecated
3521
2940
  boundaryElement = boundaryElementContext.element,
3522
2941
  children: childProp,
3523
2942
  constrainSize = !1,
@@ -3525,6 +2944,7 @@ const ViewportOverlay = () => {
3525
2944
  disabled,
3526
2945
  fallbackPlacements = props.fallbackPlacements ?? DEFAULT_FALLBACK_PLACEMENTS$1[props.placement ?? "bottom"],
3527
2946
  matchReferenceWidth,
2947
+ // oxlint-disable-next-line no-deprecated
3528
2948
  floatingBoundary = props.boundaryElement ?? boundaryElementContext.element,
3529
2949
  modal,
3530
2950
  // eslint-disable-next-line @typescript-eslint/no-unused-vars
@@ -3537,6 +2957,7 @@ const ViewportOverlay = () => {
3537
2957
  portal,
3538
2958
  preventOverflow = !0,
3539
2959
  radius: radiusProp = 3,
2960
+ // oxlint-disable-next-line no-deprecated
3540
2961
  referenceBoundary = props.boundaryElement ?? boundaryElementContext.element,
3541
2962
  referenceElement,
3542
2963
  scheme,
@@ -3581,28 +3002,35 @@ const ViewportOverlay = () => {
3581
3002
  rootBoundary
3582
3003
  }))), ret.push(offset({
3583
3004
  mainAxis: DEFAULT_POPOVER_DISTANCE
3584
- })), (constrainSize || matchReferenceWidth) && ret.push(size({
3585
- apply({
3586
- availableWidth,
3587
- availableHeight,
3588
- elements,
3589
- referenceWidth: referenceWidth_0
3590
- }) {
3591
- referenceWidthRef.current = referenceWidth_0;
3592
- const _currentWidth = widthRef.current, _maxWidth = maxWidthRef.current;
3593
- matchReferenceWidth ? elements.floating.style.width = `${referenceWidth_0}px` : _currentWidth !== void 0 && (elements.floating.style.width = `${_currentWidth}px`), constrainSize && (elements.floating.style.maxWidth = `${Math.min(availableWidth, _maxWidth ?? 1 / 0)}px`, elements.floating.style.maxHeight = `${availableHeight}px`);
3594
- },
3595
- boundaryElement: floatingBoundary || void 0,
3596
- margins,
3597
- padding: DEFAULT_POPOVER_PADDING
3598
- })), preventOverflow && ret.push(shift({
3005
+ })), (constrainSize || matchReferenceWidth) && ret.push(
3006
+ // oxlint-disable-next-line react-compiler
3007
+ size({
3008
+ apply({
3009
+ availableWidth,
3010
+ availableHeight,
3011
+ elements,
3012
+ referenceWidth: referenceWidth_0
3013
+ }) {
3014
+ referenceWidthRef.current = referenceWidth_0;
3015
+ const _currentWidth = widthRef.current, _maxWidth = maxWidthRef.current;
3016
+ matchReferenceWidth ? elements.floating.style.width = `${referenceWidth_0}px` : _currentWidth !== void 0 && (elements.floating.style.width = `${_currentWidth}px`), constrainSize && (elements.floating.style.maxWidth = `${Math.min(availableWidth, _maxWidth ?? 1 / 0)}px`, elements.floating.style.maxHeight = `${availableHeight}px`);
3017
+ },
3018
+ boundaryElement: floatingBoundary || void 0,
3019
+ margins,
3020
+ padding: DEFAULT_POPOVER_PADDING
3021
+ })
3022
+ ), preventOverflow && ret.push(shift({
3599
3023
  boundary: floatingBoundary || void 0,
3600
3024
  rootBoundary,
3601
3025
  padding: DEFAULT_POPOVER_PADDING
3602
- })), arrowProp && ret.push(arrow({
3603
- element: arrowRef,
3604
- padding: DEFAULT_POPOVER_PADDING
3605
- })), animate && ret.push(origin), ret.push(hide({
3026
+ })), arrowProp && ret.push(
3027
+ // oxlint-disable-next-line react-compiler
3028
+ arrow({
3029
+ // oxlint-disable-next-line react-compiler
3030
+ element: arrowRef,
3031
+ padding: DEFAULT_POPOVER_PADDING
3032
+ })
3033
+ ), animate && ret.push(origin), ret.push(hide({
3606
3034
  boundary: referenceBoundary || void 0,
3607
3035
  padding: DEFAULT_POPOVER_PADDING,
3608
3036
  strategy: "referenceHidden"
@@ -3639,7 +3067,34 @@ const ViewportOverlay = () => {
3639
3067
  return childProp || /* @__PURE__ */ jsx(Fragment, {});
3640
3068
  const popover = /* @__PURE__ */ jsxs(LayerProvider, { zOffset, children: [
3641
3069
  modal && /* @__PURE__ */ jsx(ViewportOverlay, {}),
3642
- /* @__PURE__ */ jsx(PopoverCard, { ...restProps, __unstable_margins: margins, animate, arrow: arrowProp, arrowRef: setArrow, arrowX, arrowY, hidden: referenceHidden, overflow, padding, placement, radius, ref: setFloating, scheme, shadow, originX, originY, strategy, tone, width: matchReferenceWidth ? referenceWidthRef.current : width, x, y, children: content })
3070
+ /* @__PURE__ */ jsx(
3071
+ PopoverCard,
3072
+ {
3073
+ ...restProps,
3074
+ __unstable_margins: margins,
3075
+ animate,
3076
+ arrow: arrowProp,
3077
+ arrowRef: setArrow,
3078
+ arrowX,
3079
+ arrowY,
3080
+ hidden: referenceHidden,
3081
+ overflow,
3082
+ padding,
3083
+ placement,
3084
+ radius,
3085
+ ref: setFloating,
3086
+ scheme,
3087
+ shadow,
3088
+ originX,
3089
+ originY,
3090
+ strategy,
3091
+ tone,
3092
+ width: matchReferenceWidth ? referenceWidthRef.current : width,
3093
+ x,
3094
+ y,
3095
+ children: content
3096
+ }
3097
+ )
3643
3098
  ] }), children = open && (portal ? /* @__PURE__ */ jsx(Portal, { __unstable_name: typeof portal == "string" ? portal : void 0, children: popover }) : popover);
3644
3099
  return /* @__PURE__ */ jsxs(Fragment, { children: [
3645
3100
  animate ? /* @__PURE__ */ jsx(AnimatePresence, { children }) : children,
@@ -3648,118 +3103,29 @@ const ViewportOverlay = () => {
3648
3103
  }));
3649
3104
  Popover.displayName = "Memo(ForwardRef(Popover))";
3650
3105
  function radioBaseStyle() {
3651
- return css`
3652
- position: relative;
3653
-
3654
- &:not([hidden]) {
3655
- display: inline-block;
3656
- }
3657
-
3658
- &[data-read-only] {
3659
- outline: 1px solid red;
3660
- }
3661
- `;
3106
+ return css`position:relative;&:not([hidden]){display:inline-block;}&[data-read-only]{outline:1px solid red;}`;
3662
3107
  }
3663
3108
  function inputElementStyle(props) {
3664
3109
  const {
3665
3110
  color,
3666
3111
  input
3667
3112
  } = getTheme_v2(props.theme), dist = (input.radio.size - input.radio.markSize) / 2;
3668
- return css`
3669
- appearance: none;
3670
- position: absolute;
3671
- top: 0;
3672
- left: 0;
3673
- opacity: 0;
3674
- height: 100%;
3675
- width: 100%;
3676
- outline: none;
3677
- z-index: 1;
3678
- padding: 0;
3679
- margin: 0;
3680
- border-radius: ${rem(input.radio.size / 2)};
3681
- border: none;
3682
-
3683
- /* enabled */
3684
- & + span {
3685
- display: block;
3686
- position: relative;
3687
- height: ${rem(input.radio.size)};
3688
- width: ${rem(input.radio.size)};
3689
- border-radius: ${rem(input.radio.size / 2)};
3690
- background: ${color.input.default.enabled.bg};
3691
- box-shadow: ${focusRingBorderStyle({
3113
+ return css`appearance:none;position:absolute;top:0;left:0;opacity:0;height:100%;width:100%;outline:none;z-index:1;padding:0;margin:0;border-radius:${rem(input.radio.size / 2)};border:none;& + span{display:block;position:relative;height:${rem(input.radio.size)};width:${rem(input.radio.size)};border-radius:${rem(input.radio.size / 2)};background:${color.input.default.enabled.bg};box-shadow:${focusRingBorderStyle({
3692
3114
  color: color.input.default.enabled.border,
3693
3115
  width: input.border.width
3694
- })};
3695
-
3696
- &::after {
3697
- content: '';
3698
- position: absolute;
3699
- top: ${rem(dist)};
3700
- left: ${rem(dist)};
3701
- height: ${rem(input.radio.markSize)};
3702
- width: ${rem(input.radio.markSize)};
3703
- border-radius: ${rem(input.radio.markSize / 2)};
3704
- background: ${color.input.default.enabled.fg};
3705
- opacity: 0;
3706
- }
3707
- }
3708
-
3709
- /* focused */
3710
- &:not(:disabled):focus + span {
3711
- box-shadow: ${focusRingStyle({
3116
+ })};&::after{content:'';position:absolute;top:${rem(dist)};left:${rem(dist)};height:${rem(input.radio.markSize)};width:${rem(input.radio.markSize)};border-radius:${rem(input.radio.markSize / 2)};background:${color.input.default.enabled.fg};opacity:0;}}&:not(:disabled):focus + span{box-shadow:${focusRingStyle({
3712
3117
  border: {
3713
3118
  width: input.border.width,
3714
3119
  color: color.input.default.enabled.border
3715
3120
  },
3716
3121
  focusRing: input.radio.focusRing
3717
- })};
3718
- }
3719
-
3720
- &:not(:disabled):focus:not(:focus-visible) + span {
3721
- box-shadow: ${focusRingBorderStyle({
3122
+ })};}&:not(:disabled):focus:not(:focus-visible) + span{box-shadow:${focusRingBorderStyle({
3722
3123
  color: color.input.default.enabled.border,
3723
3124
  width: input.border.width
3724
- })};
3725
- }
3726
-
3727
- &:checked + span::after {
3728
- opacity: 1;
3729
- }
3730
-
3731
- /* customValidity */
3732
- &[data-error] + span {
3733
- background-color: ${color.input.invalid.enabled.border};
3734
- box-shadow: ${focusRingBorderStyle({
3125
+ })};}&:checked + span::after{opacity:1;}&[data-error] + span{background-color:${color.input.invalid.enabled.border};box-shadow:${focusRingBorderStyle({
3735
3126
  width: input.border.width,
3736
3127
  color: color.input.invalid.enabled.muted.bg
3737
- })};
3738
- &::after {
3739
- background: ${color.input.invalid.enabled.muted.bg};
3740
- }
3741
- }
3742
-
3743
- /* read only */
3744
- &[data-read-only] + span {
3745
- box-shadow: 0 0 0 1px ${color.input.default.readOnly.border};
3746
- background: ${color.input.default.readOnly.bg};
3747
-
3748
- &::after {
3749
- background: ${color.input.default.readOnly.border};
3750
- }
3751
- }
3752
-
3753
- /* disabled */
3754
- &:not([data-read-only]):disabled + span {
3755
- box-shadow: 0 0 0 1px ${color.input.default.disabled.border};
3756
- background: ${color.input.default.disabled.bg};
3757
-
3758
- &::after {
3759
- background: ${color.input.default.disabled.border};
3760
- }
3761
- }
3762
- `;
3128
+ })};&::after{background:${color.input.invalid.enabled.muted.bg};}}&[data-read-only] + span{box-shadow:0 0 0 1px ${color.input.default.readOnly.border};background:${color.input.default.readOnly.bg};&::after{background:${color.input.default.readOnly.border};}}&:not([data-read-only]):disabled + span{box-shadow:0 0 0 1px ${color.input.default.disabled.border};background:${color.input.default.disabled.bg};&::after{background:${color.input.default.disabled.border};}}`;
3763
3129
  }
3764
3130
  const StyledRadio = /* @__PURE__ */ styled.div.withConfig({
3765
3131
  displayName: "StyledRadio",
@@ -3794,93 +3160,38 @@ const StyledRadio = /* @__PURE__ */ styled.div.withConfig({
3794
3160
  });
3795
3161
  Radio.displayName = "ForwardRef(Radio)";
3796
3162
  function rootStyle() {
3797
- return css`
3798
- position: relative;
3799
- width: -moz-available;
3800
- width: -webkit-fill-available;
3801
- width: stretch;
3802
-
3803
- &:not([hidden]) {
3804
- display: inline-block;
3805
- }
3806
- `;
3163
+ return css`position:relative;width:-moz-available;width:-webkit-fill-available;width:stretch;&:not([hidden]){display:inline-block;}`;
3807
3164
  }
3808
3165
  function inputBaseStyle(props) {
3809
3166
  const {
3810
3167
  font
3811
3168
  } = getTheme_v2(props.theme);
3812
- return css`
3813
- -webkit-font-smoothing: antialiased;
3814
- appearance: none;
3815
- border: 0;
3816
- font-family: ${font.text.family};
3817
- color: inherit;
3818
- width: 100%;
3819
- outline: none;
3820
- margin: 0;
3821
-
3822
- &:disabled {
3823
- opacity: 1;
3824
- }
3825
- `;
3169
+ return css`-webkit-font-smoothing:antialiased;appearance:none;border:0;font-family:${font.text.family};color:inherit;width:100%;outline:none;margin:0;&:disabled{opacity:1;}`;
3826
3170
  }
3827
3171
  function inputColorStyle(props) {
3828
3172
  const {
3829
3173
  color,
3830
3174
  input
3831
3175
  } = getTheme_v2(props.theme);
3832
- return css`
3833
- /* enabled */
3834
- background-color: ${color.input.default.enabled.bg};
3835
- color: ${color.input.default.enabled.fg};
3836
- box-shadow: ${focusRingBorderStyle({
3176
+ return css`background-color:${color.input.default.enabled.bg};color:${color.input.default.enabled.fg};box-shadow:${focusRingBorderStyle({
3837
3177
  color: color.input.default.enabled.border,
3838
3178
  width: input.border.width
3839
- })};
3840
-
3841
- /* hovered */
3842
- @media (hover: hover) {
3843
- &:not(:disabled):hover {
3844
- background-color: ${color.input.default.hovered.bg};
3845
- color: ${color.input.default.hovered.fg};
3846
- box-shadow: ${focusRingBorderStyle({
3179
+ })};@media (hover:hover){&:not(:disabled):hover{background-color:${color.input.default.hovered.bg};color:${color.input.default.hovered.fg};box-shadow:${focusRingBorderStyle({
3847
3180
  color: color.input.default.hovered.border,
3848
3181
  width: input.border.width
3849
- })};
3850
- }
3851
- }
3852
-
3853
- /* focused */
3854
- &:not(:disabled):focus {
3855
- box-shadow: ${focusRingStyle({
3182
+ })};}}&:not(:disabled):focus{box-shadow:${focusRingStyle({
3856
3183
  border: {
3857
3184
  width: input.border.width,
3858
3185
  color: color.input.default.enabled.border
3859
3186
  },
3860
3187
  focusRing: input.select.focusRing
3861
- })};
3862
- }
3863
-
3864
- /* read-only */
3865
- &[data-read-only] {
3866
- background-color: ${color.input.default.readOnly.bg};
3867
- color: ${color.input.default.readOnly.fg};
3868
- box-shadow: ${focusRingBorderStyle({
3188
+ })};}&[data-read-only]{background-color:${color.input.default.readOnly.bg};color:${color.input.default.readOnly.fg};box-shadow:${focusRingBorderStyle({
3869
3189
  color: color.input.default.readOnly.border,
3870
3190
  width: input.border.width
3871
- })};
3872
- }
3873
-
3874
- /* disabled */
3875
- &:not([data-read-only]):disabled {
3876
- background-color: ${color.input.default.disabled.bg};
3877
- color: ${color.input.default.disabled.fg};
3878
- box-shadow: ${focusRingBorderStyle({
3191
+ })};}&:not([data-read-only]):disabled{background-color:${color.input.default.disabled.bg};color:${color.input.default.disabled.fg};box-shadow:${focusRingBorderStyle({
3879
3192
  color: color.input.default.disabled.border,
3880
3193
  width: input.border.width
3881
- })};
3882
- }
3883
- `;
3194
+ })};}`;
3884
3195
  }
3885
3196
  function textSize(size2) {
3886
3197
  return {
@@ -3904,32 +3215,7 @@ function iconBoxStyle(props) {
3904
3215
  const {
3905
3216
  color
3906
3217
  } = getTheme_v2(props.theme);
3907
- return css`
3908
- pointer-events: none;
3909
- position: absolute;
3910
- top: 0;
3911
- right: 0;
3912
-
3913
- /* enabled */
3914
- --card-fg-color: ${color.input.default.enabled.fg};
3915
-
3916
- /* hover */
3917
- @media (hover: hover) {
3918
- select:not(disabled):not(:read-only):hover + && {
3919
- --card-fg-color: ${color.input.default.hovered.fg};
3920
- }
3921
- }
3922
-
3923
- /* disabled */
3924
- select:disabled + && {
3925
- --card-fg-color: ${color.input.default.disabled.fg};
3926
- }
3927
-
3928
- /* read-only */
3929
- select[data-read-only] + && {
3930
- --card-fg-color: ${color.input.default.readOnly.fg};
3931
- }
3932
- `;
3218
+ return css`pointer-events:none;position:absolute;top:0;right:0;--card-fg-color:${color.input.default.enabled.fg};@media (hover:hover){select:not(disabled):not(:read-only):hover + &&{--card-fg-color:${color.input.default.hovered.fg};}}select:disabled + &&{--card-fg-color:${color.input.default.disabled.fg};}select[data-read-only] + &&{--card-fg-color:${color.input.default.readOnly.fg};}`;
3933
3219
  }
3934
3220
  const selectStyle = {
3935
3221
  root: rootStyle,
@@ -3996,6 +3282,7 @@ function responsiveStackSpaceStyle(props) {
3996
3282
  space
3997
3283
  } = getTheme_v2(props.theme);
3998
3284
  return _responsive(media, props.$space, (spaceIndex) => ({
3285
+ // oxlint-disable-next-line no-deprecated
3999
3286
  gridGap: rem(space[spaceIndex])
4000
3287
  }));
4001
3288
  }
@@ -4016,125 +3303,25 @@ const StyledStack = /* @__PURE__ */ styled(Box).withConfig({
4016
3303
  });
4017
3304
  Stack.displayName = "ForwardRef(Stack)";
4018
3305
  function switchBaseStyles() {
4019
- return css`
4020
- position: relative;
4021
- &:not([hidden]) {
4022
- display: inline-block;
4023
- }
4024
- `;
3306
+ return css`position:relative;&:not([hidden]){display:inline-block;}`;
4025
3307
  }
4026
3308
  function switchInputStyles() {
4027
- return css`
4028
- position: absolute;
4029
- top: 0;
4030
- right: 0;
4031
- bottom: 0;
4032
- left: 0;
4033
- opacity: 0;
4034
- height: 100%;
4035
- width: 100%;
4036
- outline: none;
4037
- padding: 0;
4038
- margin: 0;
4039
-
4040
- /* Place the input element above the representation element */
4041
- z-index: 1;
4042
- `;
3309
+ return css`position:absolute;top:0;right:0;bottom:0;left:0;opacity:0;height:100%;width:100%;outline:none;padding:0;margin:0;z-index:1;`;
4043
3310
  }
4044
3311
  function switchRepresentationStyles(props) {
4045
3312
  const {
4046
3313
  color,
4047
3314
  input
4048
3315
  } = getTheme_v2(props.theme);
4049
- return css`
4050
- --switch-bg-color: ${color.input.default.enabled.border};
4051
- --switch-fg-color: ${color.input.default.enabled.bg};
4052
- --switch-box-shadow: none;
4053
-
4054
- &:not([hidden]) {
4055
- display: block;
4056
- }
4057
- position: relative;
4058
- width: ${rem(input.switch.width)};
4059
- height: ${rem(input.switch.height)};
4060
- border-radius: ${rem(input.switch.height / 2)};
4061
-
4062
- /* Make sure it’s not possible to interact with the wrapper element */
4063
- pointer-events: none;
4064
-
4065
- &:after {
4066
- content: '';
4067
- display: block;
4068
- position: absolute;
4069
- top: 0;
4070
- left: 0;
4071
- right: 0;
4072
- bottom: 0;
4073
- z-index: 1;
4074
- box-shadow: var(--switch-box-shadow);
4075
- border-radius: inherit;
4076
- }
4077
-
4078
- /* Focus styles */
4079
- input:focus + && {
4080
- --switch-box-shadow: ${focusRingStyle({
3316
+ return css`--switch-bg-color:${color.input.default.enabled.border};--switch-fg-color:${color.input.default.enabled.bg};--switch-box-shadow:none;&:not([hidden]){display:block;}position:relative;width:${rem(input.switch.width)};height:${rem(input.switch.height)};border-radius:${rem(input.switch.height / 2)};pointer-events:none;&:after{content:'';display:block;position:absolute;top:0;left:0;right:0;bottom:0;z-index:1;box-shadow:var(--switch-box-shadow);border-radius:inherit;}input:focus + &&{--switch-box-shadow:${focusRingStyle({
4081
3317
  focusRing: input.switch.focusRing
4082
- })};
4083
- }
4084
-
4085
- input:focus:not(:focus-visible) + && {
4086
- --switch-box-shadow: none;
4087
- }
4088
-
4089
- input:checked + && {
4090
- --switch-bg-color: ${color.input.default.enabled.fg};
4091
- --switch-fg-color: ${color.input.default.enabled.bg};
4092
- }
4093
-
4094
- @media (hover: hover) {
4095
- input:not(:disabled):hover + && {
4096
- --switch-bg-color: ${color.input.default.hovered.border};
4097
- --switch-fg-color: ${color.input.default.hovered.bg};
4098
- }
4099
-
4100
- input:not(:disabled):checked:hover + && {
4101
- --switch-bg-color: ${color.input.default.enabled.fg};
4102
- --switch-fg-color: ${color.input.default.enabled.bg};
4103
- }
4104
- }
4105
-
4106
- input:not([data-read-only]):disabled + && {
4107
- --switch-bg-color: ${color.input.default.disabled.border};
4108
- --switch-fg-color: ${color.input.default.disabled.bg};
4109
- }
4110
-
4111
- input[data-read-only]:disabled + && {
4112
- --switch-bg-color: ${color.input.default.readOnly.border};
4113
- --switch-fg-color: ${color.input.default.readOnly.bg};
4114
- }
4115
-
4116
- input:checked[data-read-only]:disabled + && {
4117
- --switch-bg-color: ${color.input.default.readOnly.fg};
4118
- --switch-fg-color: ${color.input.default.readOnly.bg};
4119
- }
4120
- `;
3318
+ })};}input:focus:not(:focus-visible) + &&{--switch-box-shadow:none;}input:checked + &&{--switch-bg-color:${color.input.default.enabled.fg};--switch-fg-color:${color.input.default.enabled.bg};}@media (hover:hover){input:not(:disabled):hover + &&{--switch-bg-color:${color.input.default.hovered.border};--switch-fg-color:${color.input.default.hovered.bg};}input:not(:disabled):checked:hover + &&{--switch-bg-color:${color.input.default.enabled.fg};--switch-fg-color:${color.input.default.enabled.bg};}}input:not([data-read-only]):disabled + &&{--switch-bg-color:${color.input.default.disabled.border};--switch-fg-color:${color.input.default.disabled.bg};}input[data-read-only]:disabled + &&{--switch-bg-color:${color.input.default.readOnly.border};--switch-fg-color:${color.input.default.readOnly.bg};}input:checked[data-read-only]:disabled + &&{--switch-bg-color:${color.input.default.readOnly.fg};--switch-fg-color:${color.input.default.readOnly.bg};}`;
4121
3319
  }
4122
3320
  function switchTrackStyles(props) {
4123
3321
  const {
4124
3322
  input
4125
3323
  } = getTheme_v2(props.theme);
4126
- return css`
4127
- &:not([hidden]) {
4128
- display: block;
4129
- }
4130
- background-color: var(--switch-bg-color);
4131
- position: absolute;
4132
- left: 0;
4133
- top: 0;
4134
- width: ${rem(input.switch.width)};
4135
- height: ${rem(input.switch.height)};
4136
- border-radius: ${rem(input.switch.height / 2)};
4137
- `;
3324
+ return css`&:not([hidden]){display:block;}background-color:var(--switch-bg-color);position:absolute;left:0;top:0;width:${rem(input.switch.width)};height:${rem(input.switch.height)};border-radius:${rem(input.switch.height / 2)};`;
4138
3325
  }
4139
3326
  function switchThumbStyles(props) {
4140
3327
  const {
@@ -4142,31 +3329,7 @@ function switchThumbStyles(props) {
4142
3329
  } = props, {
4143
3330
  input
4144
3331
  } = getTheme_v2(props.theme), trackWidth = input.switch.width, trackHeight = input.switch.height, trackPadding = input.switch.padding, size2 = trackHeight - input.switch.padding * 2, checkedOffset = trackWidth - trackPadding * 2 - size2, indeterminateOffset = trackWidth / 2 - size2 / 2 - trackPadding, checked = $indeterminate !== !0 && props.$checked === !0;
4145
- return css`
4146
- &:not([hidden]) {
4147
- display: block;
4148
- }
4149
- position: absolute;
4150
- left: ${rem(trackPadding)};
4151
- top: ${rem(trackPadding)};
4152
- height: ${rem(size2)};
4153
- width: ${rem(size2)};
4154
- border-radius: ${rem(size2 / 2)};
4155
- transition-property: transform;
4156
- transition-duration: ${input.switch.transitionDurationMs}ms;
4157
- transition-timing-function: ${input.switch.transitionTimingFunction};
4158
- background: var(--switch-fg-color);
4159
- transform: translate3d(0, 0, 0);
4160
- box-shadow: 0px 1px 0px 0px rgba(0, 0, 0, 0.05);
4161
-
4162
- ${checked && css`
4163
- transform: translate3d(${checkedOffset}px, 0, 0);
4164
- `}
4165
-
4166
- ${$indeterminate && css`
4167
- transform: translate3d(${indeterminateOffset}px, 0, 0);
4168
- `}
4169
- `;
3332
+ return css`&:not([hidden]){display:block;}position:absolute;left:${rem(trackPadding)};top:${rem(trackPadding)};height:${rem(size2)};width:${rem(size2)};border-radius:${rem(size2 / 2)};transition-property:transform;transition-duration:${input.switch.transitionDurationMs}ms;transition-timing-function:${input.switch.transitionTimingFunction};background:var(--switch-fg-color);transform:translate3d(0,0,0);box-shadow:0px 1px 0px 0px rgba(0,0,0,0.05);${checked && css`transform:translate3d(${checkedOffset}px,0,0);`} ${$indeterminate && css`transform:translate3d(${indeterminateOffset}px,0,0);`}`;
4170
3333
  }
4171
3334
  const StyledSwitch = /* @__PURE__ */ styled.span.withConfig({
4172
3335
  displayName: "StyledSwitch",
@@ -4812,7 +3975,7 @@ function useMenuController(props) {
4812
3975
  });
4813
3976
  return () => cancelAnimationFrame(rafId);
4814
3977
  }, [activeIndex, mounted, setActiveIndex, shouldFocus]), {
4815
- // eslint-disable-next-line react-hooks/refs
3978
+ // oxlint-disable-next-line react-compiler
4816
3979
  activeElement,
4817
3980
  activeIndex,
4818
3981
  handleItemMouseEnter,
@@ -4913,27 +4076,7 @@ const MenuDivider = styled.hr.withConfig({
4913
4076
  })`height:1px;border:0;background:var(--card-hairline-soft-color);margin:0;`;
4914
4077
  MenuDivider.displayName = "MenuDivider";
4915
4078
  function selectableBaseStyle() {
4916
- return css`
4917
- background-color: inherit;
4918
- color: inherit;
4919
-
4920
- &[data-as='button'] {
4921
- -webkit-font-smoothing: inherit;
4922
- appearance: none;
4923
- outline: none;
4924
- font: inherit;
4925
- text-align: inherit;
4926
- border: 0;
4927
- width: -moz-available;
4928
- width: -webkit-fill-available;
4929
- width: stretch;
4930
- }
4931
-
4932
- /* &:is(a) */
4933
- &[data-as='a'] {
4934
- text-decoration: none;
4935
- }
4936
- `;
4079
+ return css`background-color:inherit;color:inherit;&[data-as='button']{-webkit-font-smoothing:inherit;appearance:none;outline:none;font:inherit;text-align:inherit;border:0;width:-moz-available;width:-webkit-fill-available;width:stretch;}&[data-as='a']{text-decoration:none;}`;
4937
4080
  }
4938
4081
  function selectableColorStyle(props) {
4939
4082
  const {
@@ -4942,75 +4085,7 @@ function selectableColorStyle(props) {
4942
4085
  color,
4943
4086
  style
4944
4087
  } = getTheme_v2(props.theme), tone = color.selectable[$tone];
4945
- return css`
4946
- ${_cardColorStyle(color, tone.enabled)}
4947
-
4948
- background-color: var(--card-bg-color);
4949
- color: var(--card-fg-color);
4950
- outline: none;
4951
-
4952
- /* &:is(button) */
4953
- &[data-as='button'] {
4954
- &:disabled {
4955
- ${_cardColorStyle(color, tone.disabled)}
4956
- }
4957
-
4958
- &:not(:disabled) {
4959
- &[aria-pressed='true'] {
4960
- ${_cardColorStyle(color, tone.pressed)}
4961
- }
4962
-
4963
- &[data-selected],
4964
- &[aria-selected='true'] > & {
4965
- ${_cardColorStyle(color, tone.selected)}
4966
- }
4967
-
4968
- @media (hover: hover) {
4969
- &:not([data-selected]) {
4970
- &[data-hovered],
4971
- &:hover {
4972
- ${_cardColorStyle(color, tone.hovered)}
4973
- }
4974
-
4975
- &:active {
4976
- ${_cardColorStyle(color, tone.pressed)}
4977
- }
4978
- }
4979
- }
4980
- }
4981
- }
4982
-
4983
- /* &:is(a) */
4984
- &[data-as='a'] {
4985
- &[data-disabled] {
4986
- ${_cardColorStyle(color, tone.disabled)}
4987
- }
4988
-
4989
- &:not([data-disabled]) {
4990
- &[data-pressed] {
4991
- ${_cardColorStyle(color, tone.pressed)}
4992
- }
4993
-
4994
- &[data-selected] {
4995
- ${_cardColorStyle(color, tone.selected)}
4996
- }
4997
-
4998
- @media (hover: hover) {
4999
- &:not([data-selected]) {
5000
- &[data-hovered],
5001
- &:hover {
5002
- ${_cardColorStyle(color, tone.hovered)}
5003
- }
5004
- &:active {
5005
- ${_cardColorStyle(color, tone.pressed)}
5006
- }
5007
- }
5008
- }
5009
- }
5010
- }
5011
-
5012
- ${style?.card?.root}
5013
- `;
4088
+ return css`${_cardColorStyle(color, tone.enabled)} background-color:var(--card-bg-color);color:var(--card-fg-color);outline:none;&[data-as='button']{&:disabled{${_cardColorStyle(color, tone.disabled)}}&:not(:disabled){&[aria-pressed='true']{${_cardColorStyle(color, tone.pressed)}}&[data-selected],&[aria-selected='true'] > &{${_cardColorStyle(color, tone.selected)}}@media (hover:hover){&:not([data-selected]){&[data-hovered],&:hover{${_cardColorStyle(color, tone.hovered)}}&:active{${_cardColorStyle(color, tone.pressed)}}}}}}&[data-as='a']{&[data-disabled]{${_cardColorStyle(color, tone.disabled)}}&:not([data-disabled]){&[data-pressed]{${_cardColorStyle(color, tone.pressed)}}&[data-selected]{${_cardColorStyle(color, tone.selected)}}@media (hover:hover){&:not([data-selected]){&[data-hovered],&:hover{${_cardColorStyle(color, tone.hovered)}}&:active{${_cardColorStyle(color, tone.pressed)}}}}}}${style?.card?.root}`;
5014
4089
  }
5015
4090
  const Selectable = /* @__PURE__ */ styled(Box).withConfig({
5016
4091
  displayName: "Selectable",