@sanity/ui 3.0.0-static.9 → 3.0.0

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 (1062) hide show
  1. package/dist/_chunks-cjs/_visual-editing.js +3550 -1279
  2. package/dist/_chunks-cjs/_visual-editing.js.map +1 -1
  3. package/dist/_chunks-cjs/refractor.js +3 -7
  4. package/dist/_chunks-cjs/refractor.js.map +1 -1
  5. package/dist/_chunks-es/_visual-editing.mjs +3562 -1292
  6. package/dist/_chunks-es/_visual-editing.mjs.map +1 -1
  7. package/dist/_chunks-es/refractor.mjs +2 -2
  8. package/dist/_chunks-es/refractor.mjs.map +1 -1
  9. package/dist/_visual-editing.d.mts +439 -239
  10. package/dist/_visual-editing.d.ts +439 -239
  11. package/dist/index.d.mts +638 -544
  12. package/dist/index.d.ts +638 -544
  13. package/dist/index.js +501 -315
  14. package/dist/index.js.map +1 -1
  15. package/dist/index.mjs +504 -309
  16. package/dist/index.mjs.map +1 -1
  17. package/dist/theme.d.mts +76 -425
  18. package/dist/theme.d.ts +76 -425
  19. package/dist/theme.js +2237 -1325
  20. package/dist/theme.js.map +1 -1
  21. package/dist/theme.mjs +2284 -1372
  22. package/dist/theme.mjs.map +1 -1
  23. package/exports/_visual-editing.ts +27 -27
  24. package/exports/index.ts +1 -1
  25. package/package.json +91 -97
  26. package/src/core/__workshop__/constants.ts +293 -0
  27. package/src/core/_compat.ts +264 -0
  28. package/src/core/components/autocomplete/__workshop__/async.tsx +156 -0
  29. package/src/core/components/autocomplete/__workshop__/constrainedHeight.tsx +137 -0
  30. package/src/core/components/autocomplete/__workshop__/custom.tsx +89 -0
  31. package/src/core/components/autocomplete/__workshop__/example.tsx +79 -0
  32. package/src/core/components/autocomplete/__workshop__/fullscreen.tsx +294 -0
  33. package/src/core/components/autocomplete/autocomplete.styles.tsx +39 -0
  34. package/src/core/components/autocomplete/autocomplete.tsx +729 -0
  35. package/src/core/components/autocomplete/autocompleteOption.tsx +45 -0
  36. package/src/core/components/autocomplete/types.ts +108 -0
  37. package/src/core/components/breadcrumbs/breadcrumbs.styles.ts +18 -0
  38. package/src/core/components/breadcrumbs/breadcrumbs.tsx +99 -0
  39. package/src/core/components/dialog/__workshop__/nested.tsx +72 -0
  40. package/src/core/components/dialog/__workshop__/onScroll.tsx +39 -0
  41. package/src/core/components/dialog/__workshop__/position.tsx +30 -0
  42. package/src/core/components/dialog/__workshop__/props.tsx +75 -0
  43. package/src/core/components/dialog/dialog.tsx +434 -0
  44. package/src/core/components/dialog/dialogProvider.tsx +35 -0
  45. package/src/core/components/dialog/styles.ts +77 -0
  46. package/src/core/components/hotkeys/hotkeys.tsx +62 -0
  47. package/src/core/components/menu/__workshop__/menuButton.tsx +80 -0
  48. package/src/core/components/menu/__workshop__/tones.tsx +25 -0
  49. package/src/core/components/menu/menu.test.tsx +128 -0
  50. package/src/core/components/menu/menu.tsx +177 -0
  51. package/src/core/components/menu/menuButton.tsx +268 -0
  52. package/src/core/components/menu/menuContext.ts +29 -0
  53. package/src/core/components/menu/menuDivider.ts +12 -0
  54. package/src/core/components/menu/menuGroup.tsx +217 -0
  55. package/src/core/components/menu/menuItem.tsx +180 -0
  56. package/src/core/components/menu/useMenuController.ts +231 -0
  57. package/src/core/components/skeleton/__workshop__/delay.tsx +70 -0
  58. package/src/core/components/skeleton/__workshop__/skeleton.tsx +64 -0
  59. package/src/core/components/skeleton/skeleton.tsx +57 -0
  60. package/src/core/components/skeleton/styles.ts +50 -0
  61. package/src/core/components/skeleton/textSkeleton.tsx +123 -0
  62. package/src/core/components/tab/tab.tsx +101 -0
  63. package/src/core/components/tab/tabList.tsx +70 -0
  64. package/src/core/components/tab/tabPanel.tsx +39 -0
  65. package/src/core/components/toast/__workshop__/toast.tsx +26 -0
  66. package/src/core/components/toast/styles.ts +77 -0
  67. package/src/core/components/toast/toast.tsx +198 -0
  68. package/src/core/components/toast/toastLayer.tsx +51 -0
  69. package/src/core/components/toast/types.ts +26 -0
  70. package/src/core/components/tree/style.ts +105 -0
  71. package/src/core/components/tree/tree.tsx +237 -0
  72. package/src/core/components/tree/treeGroup.tsx +30 -0
  73. package/src/core/components/tree/treeItem.tsx +205 -0
  74. package/src/core/components/tree/types.ts +21 -0
  75. package/src/core/constants.ts +79 -0
  76. package/src/core/helpers/index.ts +4 -0
  77. package/src/core/hooks/useArrayProp.ts +31 -0
  78. package/src/core/hooks/useClickOutside.test.tsx +482 -0
  79. package/src/core/hooks/useForwardedRef.ts +19 -0
  80. package/src/core/hooks/useMatchMedia.ts +28 -0
  81. package/src/core/hooks/useMediaIndex/useMediaIndex.test.tsx +36 -0
  82. package/src/core/hooks/useMediaIndex/useMediaIndex.ts +102 -0
  83. package/src/core/hooks/usePrefersDark.ts +16 -0
  84. package/src/core/hooks/usePrefersReducedMotion.ts +16 -0
  85. package/src/core/index.ts +10 -0
  86. package/src/core/primitives/_selectable/selectable.tsx +15 -0
  87. package/src/core/primitives/_selectable/style.ts +115 -0
  88. package/src/core/primitives/avatar/__workshop__/asButton.tsx +14 -0
  89. package/src/core/primitives/avatar/__workshop__/stack.tsx +25 -0
  90. package/src/core/primitives/avatar/__workshop__/withinButton.tsx +63 -0
  91. package/src/core/primitives/avatar/__workshop__/withinMenuItem.tsx +70 -0
  92. package/src/core/primitives/avatar/avatar.tsx +192 -0
  93. package/src/core/primitives/avatar/avatarCounter.tsx +94 -0
  94. package/src/core/primitives/avatar/avatarStack.tsx +101 -0
  95. package/src/core/primitives/avatar/styles.ts +167 -0
  96. package/src/core/primitives/badge/__workshop__/props.tsx +30 -0
  97. package/src/core/primitives/badge/__workshop__/tones.tsx +21 -0
  98. package/src/core/primitives/badge/badge.tsx +62 -0
  99. package/src/core/primitives/badge/styles.ts +20 -0
  100. package/src/core/primitives/box/__workshop__/props.tsx +20 -0
  101. package/src/core/primitives/box/box.tsx +131 -0
  102. package/src/core/primitives/button/__workshop__/custom.tsx +51 -0
  103. package/src/core/primitives/button/__workshop__/props.tsx +55 -0
  104. package/src/core/primitives/button/__workshop__/stacked.tsx +58 -0
  105. package/src/core/primitives/button/button.tsx +187 -0
  106. package/src/core/primitives/button/styles.ts +117 -0
  107. package/src/core/primitives/card/__workshop__/allTones.tsx +25 -0
  108. package/src/core/primitives/card/__workshop__/asButton.tsx +107 -0
  109. package/src/core/primitives/card/__workshop__/props.tsx +53 -0
  110. package/src/core/primitives/card/__workshop__/selected.tsx +94 -0
  111. package/src/core/primitives/card/card.tsx +116 -0
  112. package/src/core/primitives/card/styles.ts +147 -0
  113. package/src/core/primitives/card/types.ts +11 -0
  114. package/src/core/primitives/checkbox/checkbox.tsx +73 -0
  115. package/src/core/primitives/checkbox/styles.ts +128 -0
  116. package/src/core/primitives/code/__workshop__/props.tsx +21 -0
  117. package/src/core/primitives/code/code.tsx +40 -0
  118. package/src/core/primitives/code/refractor.tsx +20 -0
  119. package/src/core/primitives/code/styles.ts +77 -0
  120. package/src/core/primitives/container/__workshop__/example.tsx +20 -0
  121. package/src/core/primitives/container/container.tsx +41 -0
  122. package/src/core/primitives/container/styles.ts +23 -0
  123. package/src/core/primitives/flex/__workshop__/example.tsx +34 -0
  124. package/src/core/primitives/flex/__workshop__/gap.tsx +25 -0
  125. package/src/core/primitives/flex/flex.tsx +54 -0
  126. package/src/core/primitives/grid/grid.tsx +48 -0
  127. package/src/core/primitives/heading/__workshop__/plain.tsx +32 -0
  128. package/src/core/primitives/heading/heading.tsx +80 -0
  129. package/src/core/primitives/heading/styles.ts +64 -0
  130. package/src/core/primitives/heading/types.ts +7 -0
  131. package/src/core/primitives/inline/__workshop__/plain.tsx +27 -0
  132. package/src/core/primitives/inline/inline.tsx +47 -0
  133. package/src/core/primitives/inline/styles.ts +32 -0
  134. package/src/core/primitives/kbd/kbd.tsx +61 -0
  135. package/src/core/primitives/label/__workshop__/opticalAlignment.tsx +48 -0
  136. package/src/core/primitives/label/__workshop__/plain.tsx +24 -0
  137. package/src/core/primitives/label/label.tsx +79 -0
  138. package/src/core/primitives/label/styles.ts +45 -0
  139. package/src/core/primitives/popover/__workshop__/AlignedStory.tsx +77 -0
  140. package/src/core/primitives/popover/__workshop__/MatchReferenceWidthStory.tsx +32 -0
  141. package/src/core/primitives/popover/__workshop__/OpenOnMountStory.tsx +11 -0
  142. package/src/core/primitives/popover/__workshop__/PlainStory.tsx +71 -0
  143. package/src/core/primitives/popover/__workshop__/RecursiveStory.tsx +71 -0
  144. package/src/core/primitives/popover/__workshop__/SidePanelStory.tsx +89 -0
  145. package/src/core/primitives/popover/__workshop__/TestStory.tsx +97 -0
  146. package/src/core/primitives/popover/helpers.ts +31 -0
  147. package/src/core/primitives/popover/popover.tsx +484 -0
  148. package/src/core/primitives/popover/popoverCard.tsx +168 -0
  149. package/src/core/primitives/radio/radio.tsx +51 -0
  150. package/src/core/primitives/radio/styles.ts +117 -0
  151. package/src/core/primitives/select/__workshop__/plain.tsx +27 -0
  152. package/src/core/primitives/select/select.tsx +87 -0
  153. package/src/core/primitives/select/styles.ts +166 -0
  154. package/src/core/primitives/spinner/__workshop__/Props.tsx +15 -0
  155. package/src/core/primitives/spinner/spinner.tsx +46 -0
  156. package/src/core/primitives/stack/__workshop__/plain.tsx +32 -0
  157. package/src/core/primitives/stack/stack.tsx +43 -0
  158. package/src/core/primitives/stack/styles.ts +32 -0
  159. package/src/core/primitives/switch/styles.ts +173 -0
  160. package/src/core/primitives/switch/switch.tsx +68 -0
  161. package/src/core/primitives/text/__workshop__/colored.tsx +30 -0
  162. package/src/core/primitives/text/__workshop__/example.tsx +39 -0
  163. package/src/core/primitives/text/styles.ts +74 -0
  164. package/src/core/primitives/text/text.tsx +81 -0
  165. package/src/core/primitives/textArea/__workshop__/plain.tsx +50 -0
  166. package/src/core/primitives/textArea/textArea.tsx +119 -0
  167. package/src/core/primitives/textInput/__workshop__/plain.tsx +98 -0
  168. package/src/core/primitives/textInput/__workshop__/typed.tsx +23 -0
  169. package/src/core/primitives/textInput/textInput.tsx +389 -0
  170. package/src/core/primitives/tooltip/__workshop__/customPortal.tsx +102 -0
  171. package/src/core/primitives/tooltip/__workshop__/overflowingBoundary.tsx +74 -0
  172. package/src/core/primitives/tooltip/__workshop__/props.tsx +107 -0
  173. package/src/core/primitives/tooltip/__workshop__/resizableBoundary.tsx +86 -0
  174. package/src/core/primitives/tooltip/tooltip.test.tsx +452 -0
  175. package/src/core/primitives/tooltip/tooltip.tsx +465 -0
  176. package/src/core/primitives/tooltip/tooltipCard.tsx +111 -0
  177. package/src/core/primitives/tooltip/tooltipDelayGroup/tooltipDelayGroupProvider.tsx +57 -0
  178. package/src/core/primitives/types.ts +146 -0
  179. package/src/core/styles/border/borderStyle.ts +56 -0
  180. package/src/core/styles/border/index.ts +2 -0
  181. package/src/core/styles/border/types.ts +10 -0
  182. package/src/core/styles/box/boxStyle.ts +69 -0
  183. package/src/core/styles/box/index.ts +2 -0
  184. package/src/core/styles/box/types.ts +11 -0
  185. package/src/core/styles/card/_cardColorStyle.ts +108 -0
  186. package/src/core/styles/card/index.ts +1 -0
  187. package/src/core/styles/flex/flexItemStyle.ts +27 -0
  188. package/src/core/styles/flex/flexStyle.ts +70 -0
  189. package/src/core/styles/flex/index.ts +3 -0
  190. package/src/core/styles/flex/types.ts +25 -0
  191. package/src/core/styles/focusRing/index.ts +25 -0
  192. package/src/core/styles/font/codeFontStyle.ts +13 -0
  193. package/src/core/styles/font/headingFontStyle.ts +13 -0
  194. package/src/core/styles/font/index.ts +6 -0
  195. package/src/core/styles/font/labelFontStyle.ts +13 -0
  196. package/src/core/styles/font/responsiveFont.ts +101 -0
  197. package/src/core/styles/font/textAlignStyle.ts +19 -0
  198. package/src/core/styles/font/textFontStyle.ts +13 -0
  199. package/src/core/styles/font/types.ts +35 -0
  200. package/src/core/styles/grid/gridItemStyle.ts +82 -0
  201. package/src/core/styles/grid/gridStyle.ts +108 -0
  202. package/src/core/styles/grid/index.ts +3 -0
  203. package/src/core/styles/grid/types.ts +37 -0
  204. package/src/core/styles/helpers.ts +72 -0
  205. package/src/core/styles/index.ts +5 -0
  206. package/src/core/styles/input/index.ts +2 -0
  207. package/src/core/styles/input/responsiveInputPaddingStyle.ts +78 -0
  208. package/src/core/styles/input/textInputStyle.ts +263 -0
  209. package/src/core/styles/internal.ts +12 -0
  210. package/src/core/styles/margin/index.ts +2 -0
  211. package/src/core/styles/margin/marginStyle.ts +21 -0
  212. package/src/core/styles/margin/marginsStyle.test.ts +33 -0
  213. package/src/core/styles/margin/types.ts +9 -0
  214. package/src/core/styles/padding/index.ts +2 -0
  215. package/src/core/styles/padding/paddingStyle.test.ts +33 -0
  216. package/src/core/styles/padding/paddingStyle.ts +21 -0
  217. package/src/core/styles/padding/types.ts +12 -0
  218. package/src/core/styles/radius/index.ts +2 -0
  219. package/src/core/styles/radius/radiusStyle.ts +23 -0
  220. package/src/core/styles/radius/types.ts +8 -0
  221. package/src/core/styles/shadow/index.ts +2 -0
  222. package/src/core/styles/shadow/shadowStyle.ts +29 -0
  223. package/src/core/styles/shadow/types.ts +6 -0
  224. package/src/core/styles/types.ts +8 -0
  225. package/src/core/theme/__workshop__/build/Root.tsx +367 -0
  226. package/src/core/theme/__workshop__/build/helpers.ts +46 -0
  227. package/src/core/theme/__workshop__/build/story.tsx +465 -0
  228. package/src/core/theme/__workshop__/canvas.tsx +351 -0
  229. package/src/core/theme/__workshop__/color.tsx +62 -0
  230. package/src/core/theme/__workshop__/debug/story.tsx +408 -0
  231. package/src/core/theme/__workshop__/index.ts +39 -0
  232. package/src/core/theme/__workshop__/layer.tsx +78 -0
  233. package/src/core/theme/__workshop__/nestedProvider.tsx +15 -0
  234. package/src/core/theme/theme.test.tsx +73 -0
  235. package/src/core/theme/themeColorProvider.tsx +29 -0
  236. package/src/core/theme/themeContext.ts +10 -0
  237. package/src/core/theme/themeProvider.tsx +62 -0
  238. package/src/core/types/avatar.ts +14 -0
  239. package/src/core/types/box.ts +19 -0
  240. package/src/core/types/button.ts +21 -0
  241. package/src/core/types/flex.ts +30 -0
  242. package/src/core/types/grid.ts +14 -0
  243. package/src/core/types/gridItem.ts +29 -0
  244. package/src/core/types/index.ts +14 -0
  245. package/src/core/types/radius.ts +4 -0
  246. package/src/core/types/selectable.ts +6 -0
  247. package/src/core/types/text.ts +4 -0
  248. package/src/core/utils/arrow/arrow.tsx +123 -0
  249. package/src/core/utils/boundaryElement/boundaryElementProvider.tsx +24 -0
  250. package/src/core/utils/conditionalWrapper/conditionalWrapper.tsx +21 -0
  251. package/src/core/utils/elementQuery/elementQuery.tsx +53 -0
  252. package/src/core/utils/errorBoundary.tsx +48 -0
  253. package/src/core/utils/layer/layer.tsx +98 -0
  254. package/src/core/utils/layer/layerProvider.tsx +110 -0
  255. package/src/core/utils/portal/portal.ts +32 -0
  256. package/src/core/utils/portal/portalProvider.tsx +79 -0
  257. package/src/core/utils/srOnly/srOnly.tsx +36 -0
  258. package/src/core/utils/virtualList/virtualList.tsx +174 -0
  259. package/src/theme/build/_deprecated/color/_selectable/createSelectableTones.ts +1 -1
  260. package/src/theme/build/_deprecated/color/_solid/createSolidTones.ts +1 -1
  261. package/src/theme/build/_deprecated/color/button/createButtonModes.ts +6 -1
  262. package/src/theme/build/_deprecated/color/button/createButtonTones.ts +2 -2
  263. package/src/theme/build/_deprecated/color/card/createCardStates.ts +1 -1
  264. package/src/theme/build/_deprecated/color/factory.ts +3 -2
  265. package/src/theme/build/_deprecated/color/input/createInputModes.ts +1 -1
  266. package/src/theme/build/_deprecated/color/muted/createMuted.ts +1 -1
  267. package/src/theme/build/_deprecated/color/spot/createSpot.ts +1 -1
  268. package/src/theme/build/buildColorTheme.ts +1 -1
  269. package/src/theme/build/buildTheme.ts +32 -8
  270. package/src/theme/build/lib/color-fns/rgba.ts +0 -4
  271. package/src/theme/build/renderColorTheme.ts +4 -4
  272. package/src/theme/build/renderColorValue.ts +1 -1
  273. package/src/theme/build/resolveColorTokens.ts +1 -1
  274. package/src/theme/config/system.ts +1 -1
  275. package/src/theme/config/tokens/color/types.ts +1 -1
  276. package/src/theme/config/tokens/parseTokenKey.ts +1 -1
  277. package/src/theme/config/tokens/parseTokenValue.ts +1 -1
  278. package/src/theme/config/tokens/types.ts +1 -1
  279. package/src/theme/config/types.ts +3 -2
  280. package/src/theme/defaults/config.ts +2 -2
  281. package/src/theme/defaults/fonts.ts +16 -17
  282. package/src/theme/getScopedTheme.ts +9 -6
  283. package/src/theme/index.ts +1 -7
  284. package/src/theme/system/avatar.ts +14 -0
  285. package/src/theme/system/font.ts +52 -0
  286. package/src/theme/system/index.ts +11 -0
  287. package/src/theme/system/input.ts +33 -0
  288. package/src/theme/system/theme.ts +138 -0
  289. package/src/theme/system/v0/color/_generic.ts +35 -0
  290. package/src/theme/system/v0/color/color.ts +40 -0
  291. package/src/theme/system/v0/color/input.ts +34 -0
  292. package/src/theme/system/v0/color/spot.ts +13 -0
  293. package/src/theme/system/v0/index.ts +3 -0
  294. package/src/theme/versioning/getTheme_v2.ts +1 -2
  295. package/src/theme/versioning/index.ts +4 -0
  296. package/src/theme/versioning/is_v0.ts +1 -2
  297. package/src/theme/versioning/is_v2.ts +1 -2
  298. package/src/theme/versioning/themeColor_v0_v2.ts +4 -6
  299. package/src/theme/versioning/themeColor_v2_v2_9.ts +1 -1
  300. package/src/theme/versioning/v0_v2.ts +1 -2
  301. package/src/theme/versioning/v2_v0.ts +6 -6
  302. package/bin/ui.js +0 -5
  303. package/dist/_chunks-cjs/buildCommand.js +0 -32
  304. package/dist/_chunks-cjs/buildCommand.js.map +0 -1
  305. package/dist/cli.d.ts +0 -1
  306. package/dist/cli.js +0 -357
  307. package/dist/cli.js.map +0 -1
  308. package/dist/css.d.mts +0 -1471
  309. package/dist/css.d.ts +0 -1471
  310. package/dist/css.js +0 -4830
  311. package/dist/css.js.map +0 -1
  312. package/dist/css.mjs +0 -4831
  313. package/dist/css.mjs.map +0 -1
  314. package/dist/sanity-palette.css +0 -1
  315. package/dist/sanity-theme.css +0 -1
  316. package/dist/system.css +0 -23238
  317. package/exports/css.ts +0 -1
  318. package/src/cli/buildCommand.ts +0 -48
  319. package/src/cli/index.ts +0 -38
  320. package/src/css/_comp.test.ts +0 -7
  321. package/src/css/_comp.ts +0 -11
  322. package/src/css/_mergeStyles.ts +0 -31
  323. package/src/css/_resp.ts +0 -38
  324. package/src/css/_responsiveRule.ts +0 -38
  325. package/src/css/aspects/border/border.style.ts +0 -13
  326. package/src/css/aspects/border/border.ts +0 -14
  327. package/src/css/aspects/border/index.ts +0 -2
  328. package/src/css/aspects/border/types.ts +0 -10
  329. package/src/css/aspects/display/display.style.ts +0 -34
  330. package/src/css/aspects/display/display.ts +0 -7
  331. package/src/css/aspects/display/index.ts +0 -2
  332. package/src/css/aspects/display/types.ts +0 -17
  333. package/src/css/aspects/flex/flex.style.ts +0 -30
  334. package/src/css/aspects/flex/flex.ts +0 -13
  335. package/src/css/aspects/flex/flexAlign.style.ts +0 -12
  336. package/src/css/aspects/flex/flexDirection.style.ts +0 -11
  337. package/src/css/aspects/flex/flexJustify.style.ts +0 -13
  338. package/src/css/aspects/flex/flexWrap.style.ts +0 -10
  339. package/src/css/aspects/flex/index.ts +0 -2
  340. package/src/css/aspects/flex/types.ts +0 -35
  341. package/src/css/aspects/flexItem/flex.style.ts +0 -22
  342. package/src/css/aspects/flexItem/flexItem.ts +0 -8
  343. package/src/css/aspects/flexItem/index.ts +0 -2
  344. package/src/css/aspects/flexItem/types.ts +0 -27
  345. package/src/css/aspects/font/font.style.ts +0 -151
  346. package/src/css/aspects/font/font.ts +0 -12
  347. package/src/css/aspects/font/index.ts +0 -2
  348. package/src/css/aspects/font/types.ts +0 -12
  349. package/src/css/aspects/gap/gap.style.ts +0 -21
  350. package/src/css/aspects/gap/gap.ts +0 -8
  351. package/src/css/aspects/gap/index.ts +0 -2
  352. package/src/css/aspects/gap/types.ts +0 -10
  353. package/src/css/aspects/grid/grid.ts +0 -13
  354. package/src/css/aspects/grid/gridAutoColumns.style.ts +0 -11
  355. package/src/css/aspects/grid/gridAutoFlow.style.ts +0 -11
  356. package/src/css/aspects/grid/gridAutoRows.style.ts +0 -11
  357. package/src/css/aspects/grid/gridColumns.style.ts +0 -18
  358. package/src/css/aspects/grid/gridRows.style.ts +0 -18
  359. package/src/css/aspects/grid/index.ts +0 -2
  360. package/src/css/aspects/grid/types.ts +0 -29
  361. package/src/css/aspects/gridItem/gridColumn.style.ts +0 -20
  362. package/src/css/aspects/gridItem/gridColumnEnd.style.ts +0 -20
  363. package/src/css/aspects/gridItem/gridColumnStart.style.ts +0 -20
  364. package/src/css/aspects/gridItem/gridItem.ts +0 -15
  365. package/src/css/aspects/gridItem/gridRow.style.ts +0 -20
  366. package/src/css/aspects/gridItem/gridRowEnd.style.ts +0 -20
  367. package/src/css/aspects/gridItem/gridRowStart.style.ts +0 -20
  368. package/src/css/aspects/gridItem/index.ts +0 -2
  369. package/src/css/aspects/gridItem/types.ts +0 -41
  370. package/src/css/aspects/height/height.style.ts +0 -9
  371. package/src/css/aspects/height/height.ts +0 -17
  372. package/src/css/aspects/height/index.ts +0 -1
  373. package/src/css/aspects/height/rules.ts +0 -7
  374. package/src/css/aspects/index.ts +0 -21
  375. package/src/css/aspects/inset/index.ts +0 -2
  376. package/src/css/aspects/inset/inset.style.ts +0 -12
  377. package/src/css/aspects/inset/inset.ts +0 -13
  378. package/src/css/aspects/inset/types.ts +0 -13
  379. package/src/css/aspects/margin/index.ts +0 -2
  380. package/src/css/aspects/margin/margin.style.ts +0 -46
  381. package/src/css/aspects/margin/margin.ts +0 -15
  382. package/src/css/aspects/margin/types.ts +0 -11
  383. package/src/css/aspects/maxWidth/index.ts +0 -2
  384. package/src/css/aspects/maxWidth/maxWidth.style.ts +0 -16
  385. package/src/css/aspects/maxWidth/maxWidth.ts +0 -6
  386. package/src/css/aspects/maxWidth/types.ts +0 -7
  387. package/src/css/aspects/minWidth/index.ts +0 -2
  388. package/src/css/aspects/minWidth/minWidth.style.ts +0 -13
  389. package/src/css/aspects/minWidth/minWidth.ts +0 -6
  390. package/src/css/aspects/minWidth/types.ts +0 -7
  391. package/src/css/aspects/outline/outline.style.ts +0 -9
  392. package/src/css/aspects/overflow/index.ts +0 -2
  393. package/src/css/aspects/overflow/overflow.style.ts +0 -11
  394. package/src/css/aspects/overflow/overflow.ts +0 -11
  395. package/src/css/aspects/overflow/types.ts +0 -11
  396. package/src/css/aspects/padding/index.ts +0 -2
  397. package/src/css/aspects/padding/padding.style.ts +0 -46
  398. package/src/css/aspects/padding/padding.ts +0 -15
  399. package/src/css/aspects/padding/types.ts +0 -14
  400. package/src/css/aspects/pointerEvents/index.ts +0 -2
  401. package/src/css/aspects/pointerEvents/pointerEvents.style.ts +0 -13
  402. package/src/css/aspects/pointerEvents/pointerEvents.ts +0 -6
  403. package/src/css/aspects/pointerEvents/types.ts +0 -7
  404. package/src/css/aspects/position/index.ts +0 -2
  405. package/src/css/aspects/position/position.style.ts +0 -12
  406. package/src/css/aspects/position/position.ts +0 -7
  407. package/src/css/aspects/position/types.ts +0 -9
  408. package/src/css/aspects/radius/index.ts +0 -2
  409. package/src/css/aspects/radius/radius.style.ts +0 -16
  410. package/src/css/aspects/radius/radius.ts +0 -8
  411. package/src/css/aspects/radius/types.ts +0 -8
  412. package/src/css/aspects/shadow/index.ts +0 -2
  413. package/src/css/aspects/shadow/shadow.style.ts +0 -49
  414. package/src/css/aspects/shadow/shadow.ts +0 -7
  415. package/src/css/aspects/shadow/types.ts +0 -8
  416. package/src/css/aspects/textOverflow/index.ts +0 -2
  417. package/src/css/aspects/textOverflow/textOverflow.style.ts +0 -21
  418. package/src/css/aspects/textOverflow/textOverflow.ts +0 -6
  419. package/src/css/aspects/textOverflow/types.ts +0 -8
  420. package/src/css/aspects/width/index.ts +0 -2
  421. package/src/css/aspects/width/rules.ts +0 -8
  422. package/src/css/aspects/width/types.ts +0 -9
  423. package/src/css/aspects/width/width.style.ts +0 -11
  424. package/src/css/aspects/width/width.ts +0 -6
  425. package/src/css/compile/compilePalette.ts +0 -27
  426. package/src/css/compile/compileRule.ts +0 -97
  427. package/src/css/compile/compileRules.test.ts +0 -36
  428. package/src/css/compile/compileRules.ts +0 -43
  429. package/src/css/compile/compileStyle.ts +0 -148
  430. package/src/css/compile/compileSystem.ts +0 -10
  431. package/src/css/compile/compileTheme.ts +0 -15
  432. package/src/css/compile/compileTheme_v3.ts +0 -401
  433. package/src/css/compile/types.ts +0 -6
  434. package/src/css/components/breadcrumbs/breadcrumbs.style.ts +0 -9
  435. package/src/css/components/breadcrumbs/breadcrumbs.ts +0 -5
  436. package/src/css/components/breadcrumbs/rules.ts +0 -25
  437. package/src/css/components/dialog/dialog.style.ts +0 -79
  438. package/src/css/components/dialog/dialog.ts +0 -30
  439. package/src/css/components/dialog/index.ts +0 -1
  440. package/src/css/components/dialog/rules.ts +0 -78
  441. package/src/css/components/menu/index.ts +0 -1
  442. package/src/css/components/menu/menu.style.ts +0 -17
  443. package/src/css/components/menu/menu.ts +0 -9
  444. package/src/css/components/menu/rules.ts +0 -15
  445. package/src/css/components/skeleton/index.ts +0 -2
  446. package/src/css/components/skeleton/rules.ts +0 -113
  447. package/src/css/components/skeleton/skeleton.style.ts +0 -96
  448. package/src/css/components/skeleton/skeleton.ts +0 -31
  449. package/src/css/components/skeleton/types.ts +0 -26
  450. package/src/css/components/toast/index.ts +0 -1
  451. package/src/css/components/toast/rules.ts +0 -18
  452. package/src/css/components/toast/toast.style.ts +0 -20
  453. package/src/css/components/toast/toast.ts +0 -21
  454. package/src/css/components/tree/index.ts +0 -1
  455. package/src/css/components/tree/rules.ts +0 -168
  456. package/src/css/components/tree/tree.style.ts +0 -55
  457. package/src/css/components/tree/tree.ts +0 -5
  458. package/src/css/composeClassNames.ts +0 -17
  459. package/src/css/constants.ts +0 -1
  460. package/src/css/index.ts +0 -41
  461. package/src/css/primitives/_arrow/_arrow.style.ts +0 -73
  462. package/src/css/primitives/_arrow/_arrow.ts +0 -14
  463. package/src/css/primitives/_arrow/index.ts +0 -1
  464. package/src/css/primitives/_input/__workshop__/customInput.tsx +0 -16
  465. package/src/css/primitives/_input/__workshop__/index.ts +0 -14
  466. package/src/css/primitives/_input/_input.style.ts +0 -162
  467. package/src/css/primitives/_input/index.ts +0 -2
  468. package/src/css/primitives/_input/input.ts +0 -25
  469. package/src/css/primitives/_input/types.ts +0 -12
  470. package/src/css/primitives/_selectable/__style.ts +0 -117
  471. package/src/css/primitives/_selectable/_contants.ts +0 -11
  472. package/src/css/primitives/_selectable/_selectable.style.ts +0 -132
  473. package/src/css/primitives/_selectable/index.ts +0 -2
  474. package/src/css/primitives/_selectable/selectable.ts +0 -9
  475. package/src/css/primitives/_selectable/types.ts +0 -8
  476. package/src/css/primitives/avatar/avatar.style.ts +0 -175
  477. package/src/css/primitives/avatar/avatar.ts +0 -27
  478. package/src/css/primitives/avatar/index.ts +0 -2
  479. package/src/css/primitives/avatar/rules.ts +0 -176
  480. package/src/css/primitives/avatar/types.ts +0 -8
  481. package/src/css/primitives/badge/badge.style.ts +0 -22
  482. package/src/css/primitives/badge/badge.ts +0 -8
  483. package/src/css/primitives/badge/index.ts +0 -2
  484. package/src/css/primitives/badge/types.ts +0 -8
  485. package/src/css/primitives/box/box.style.ts +0 -31
  486. package/src/css/primitives/box/box.ts +0 -52
  487. package/src/css/primitives/box/index.ts +0 -2
  488. package/src/css/primitives/box/types.ts +0 -51
  489. package/src/css/primitives/button/_constants.ts +0 -17
  490. package/src/css/primitives/button/button.style.ts +0 -201
  491. package/src/css/primitives/button/button.ts +0 -41
  492. package/src/css/primitives/button/rules.ts +0 -302
  493. package/src/css/primitives/card/_constants.ts +0 -13
  494. package/src/css/primitives/card/card.style.ts +0 -270
  495. package/src/css/primitives/card/card.ts +0 -14
  496. package/src/css/primitives/card/types.ts +0 -10
  497. package/src/css/primitives/checkbox/__styles.ts +0 -129
  498. package/src/css/primitives/checkbox/checkbox.style.ts +0 -154
  499. package/src/css/primitives/checkbox/checkbox.ts +0 -9
  500. package/src/css/primitives/checkbox/rules.ts +0 -152
  501. package/src/css/primitives/code/code.style.ts +0 -62
  502. package/src/css/primitives/code/code.ts +0 -9
  503. package/src/css/primitives/code/index.ts +0 -2
  504. package/src/css/primitives/code/rules.ts +0 -96
  505. package/src/css/primitives/code/types.ts +0 -10
  506. package/src/css/primitives/container/container.style.ts +0 -10
  507. package/src/css/primitives/container/container.ts +0 -7
  508. package/src/css/primitives/container/rules.ts +0 -8
  509. package/src/css/primitives/container/types.ts +0 -7
  510. package/src/css/primitives/heading/heading.style.ts +0 -47
  511. package/src/css/primitives/heading/heading.ts +0 -17
  512. package/src/css/primitives/heading/index.ts +0 -2
  513. package/src/css/primitives/heading/rules.ts +0 -155
  514. package/src/css/primitives/heading/types.ts +0 -12
  515. package/src/css/primitives/kbd/index.ts +0 -2
  516. package/src/css/primitives/kbd/kbd.style.ts +0 -22
  517. package/src/css/primitives/kbd/kbd.ts +0 -7
  518. package/src/css/primitives/kbd/rules.ts +0 -20
  519. package/src/css/primitives/kbd/types.ts +0 -7
  520. package/src/css/primitives/label/index.ts +0 -2
  521. package/src/css/primitives/label/label.style.ts +0 -48
  522. package/src/css/primitives/label/label.ts +0 -16
  523. package/src/css/primitives/label/rules.ts +0 -137
  524. package/src/css/primitives/label/types.ts +0 -12
  525. package/src/css/primitives/popover/index.ts +0 -1
  526. package/src/css/primitives/popover/popover.style.ts +0 -5
  527. package/src/css/primitives/popover/popover.ts +0 -9
  528. package/src/css/primitives/popover/rules.ts +0 -5
  529. package/src/css/primitives/radio/radio.style.ts +0 -123
  530. package/src/css/primitives/radio/radio.ts +0 -5
  531. package/src/css/primitives/radio/rules.ts +0 -121
  532. package/src/css/primitives/select/index.ts +0 -2
  533. package/src/css/primitives/select/rules.ts +0 -22
  534. package/src/css/primitives/select/select.style.ts +0 -24
  535. package/src/css/primitives/select/select.ts +0 -12
  536. package/src/css/primitives/select/types.ts +0 -5
  537. package/src/css/primitives/spinner/rules.ts +0 -21
  538. package/src/css/primitives/spinner/spinner.style.ts +0 -22
  539. package/src/css/primitives/spinner/spinner.ts +0 -9
  540. package/src/css/primitives/stack/stack.style.ts +0 -9
  541. package/src/css/primitives/stack/stack.ts +0 -6
  542. package/src/css/primitives/switch/rules.ts +0 -340
  543. package/src/css/primitives/switch/switch.style.ts +0 -94
  544. package/src/css/primitives/switch/switch.ts +0 -21
  545. package/src/css/primitives/text/index.ts +0 -2
  546. package/src/css/primitives/text/rules.ts +0 -164
  547. package/src/css/primitives/text/text.style.ts +0 -64
  548. package/src/css/primitives/text/text.ts +0 -17
  549. package/src/css/primitives/text/types.ts +0 -11
  550. package/src/css/primitives/textArea/index.ts +0 -2
  551. package/src/css/primitives/textArea/rules.ts +0 -7
  552. package/src/css/primitives/textArea/textArea.style.ts +0 -9
  553. package/src/css/primitives/textArea/textArea.ts +0 -8
  554. package/src/css/primitives/textArea/types.ts +0 -5
  555. package/src/css/primitives/textInput/index.ts +0 -2
  556. package/src/css/primitives/textInput/rules.ts +0 -224
  557. package/src/css/primitives/textInput/textInput.style.ts +0 -167
  558. package/src/css/primitives/textInput/textInput.ts +0 -8
  559. package/src/css/primitives/textInput/types.ts +0 -11
  560. package/src/css/primitives/token/rules.ts +0 -45
  561. package/src/css/primitives/token/token.style.ts +0 -49
  562. package/src/css/primitives/tooltip/index.ts +0 -1
  563. package/src/css/primitives/tooltip/rules.ts +0 -19
  564. package/src/css/primitives/tooltip/tooltip.style.ts +0 -21
  565. package/src/css/primitives/tooltip/tooltip.ts +0 -9
  566. package/src/css/responsiveRules.ts +0 -25
  567. package/src/css/scopeClassName.ts +0 -6
  568. package/src/css/system.style.ts +0 -158
  569. package/src/css/types.ts +0 -850
  570. package/src/css/util.ts +0 -27
  571. package/src/css/utils/srOnly/srOnly.style.ts +0 -14
  572. package/src/css/utils/srOnly/srOnly.ts +0 -5
  573. package/src/css/varNames.ts +0 -496
  574. package/src/css/vars.ts +0 -465
  575. package/src/theme/_constants.ts +0 -26
  576. package/src/theme/_types.ts +0 -41
  577. package/src/theme/palette/constants.ts +0 -13
  578. package/src/theme/palette/index.ts +0 -2
  579. package/src/theme/palette/types.ts +0 -4
  580. package/src/theme/types.ts +0 -32
  581. package/src/theme/v0/color/_generic.ts +0 -35
  582. package/src/theme/v0/color/color.ts +0 -40
  583. package/src/theme/v0/color/input.ts +0 -34
  584. package/src/theme/v0/color/spot.ts +0 -13
  585. package/src/theme/v0/font.ts +0 -53
  586. package/src/theme/v0/index.ts +0 -10
  587. package/src/theme/v0/theme.ts +0 -72
  588. package/src/theme/v2/avatar.ts +0 -14
  589. package/src/theme/v2/index.ts +0 -4
  590. package/src/theme/v2/input.ts +0 -33
  591. package/src/theme/v2/theme.ts +0 -49
  592. package/src/theme/v3/buildTheme_v3.test.ts +0 -40
  593. package/src/theme/v3/buildTheme_v3.ts +0 -29
  594. package/src/theme/v3/color/buildColor_v3.ts +0 -198
  595. package/src/theme/v3/color/card.ts +0 -121
  596. package/src/theme/v3/color/color.ts +0 -98
  597. package/src/theme/v3/color/element.ts +0 -19
  598. package/src/theme/v3/color/index.ts +0 -7
  599. package/src/theme/v3/color/parseColor.test.ts +0 -79
  600. package/src/theme/v3/color/parseColor.ts +0 -167
  601. package/src/theme/v3/color/renderColor.test.ts +0 -19
  602. package/src/theme/v3/color/renderColor.ts +0 -33
  603. package/src/theme/v3/color/token.ts +0 -17
  604. package/src/theme/v3/color/tokens.ts +0 -5
  605. package/src/theme/v3/defaults.ts +0 -202
  606. package/src/theme/v3/index.ts +0 -6
  607. package/src/theme/v3/merge.ts +0 -22
  608. package/src/theme/v3/resolveTokens.ts +0 -204
  609. package/src/theme/v3/tokens.ts +0 -16
  610. package/src/theme/v3/types.ts +0 -45
  611. package/src/theme/versioning/themeColor_v3_v2.ts +0 -206
  612. package/src/theme/versioning/v3_v2.ts +0 -108
  613. package/src/ui/StyleTags.tsx +0 -24
  614. package/src/ui/_compat/index.ts +0 -9
  615. package/src/ui/_compat/styles/_responsive.ts +0 -19
  616. package/src/ui/_compat/styles/index.ts +0 -1
  617. package/src/ui/_compat/theme/theme.test.tsx +0 -73
  618. package/src/ui/_compat/theme/themeColorProvider.tsx +0 -30
  619. package/src/ui/_compat/theme/themeContext.ts +0 -10
  620. package/src/ui/_compat/theme/themeProvider.tsx +0 -74
  621. package/src/ui/_compat/types.ts +0 -274
  622. package/src/ui/components/autocomplete/__workshop__/async.tsx +0 -156
  623. package/src/ui/components/autocomplete/__workshop__/constrainedHeight.tsx +0 -131
  624. package/src/ui/components/autocomplete/__workshop__/custom.tsx +0 -90
  625. package/src/ui/components/autocomplete/__workshop__/example.tsx +0 -80
  626. package/src/ui/components/autocomplete/__workshop__/fullscreen.tsx +0 -293
  627. package/src/ui/components/autocomplete/autocomplete.tsx +0 -722
  628. package/src/ui/components/autocomplete/autocompleteOption.tsx +0 -45
  629. package/src/ui/components/autocomplete/types.ts +0 -108
  630. package/src/ui/components/breadcrumbs/breadcrumbs.tsx +0 -127
  631. package/src/ui/components/breadcrumbs/index.ts +0 -1
  632. package/src/ui/components/dialog/__workshop__/nested.tsx +0 -72
  633. package/src/ui/components/dialog/__workshop__/onScroll.tsx +0 -39
  634. package/src/ui/components/dialog/__workshop__/position.tsx +0 -30
  635. package/src/ui/components/dialog/__workshop__/props.tsx +0 -77
  636. package/src/ui/components/dialog/dialog.tsx +0 -432
  637. package/src/ui/components/dialog/dialogProvider.tsx +0 -35
  638. package/src/ui/components/hotkeys/hotkeys.tsx +0 -54
  639. package/src/ui/components/menu/__workshop__/menuButton.tsx +0 -80
  640. package/src/ui/components/menu/__workshop__/tones.tsx +0 -25
  641. package/src/ui/components/menu/menu.test.tsx +0 -128
  642. package/src/ui/components/menu/menu.tsx +0 -200
  643. package/src/ui/components/menu/menuButton.tsx +0 -275
  644. package/src/ui/components/menu/menuContext.ts +0 -31
  645. package/src/ui/components/menu/menuDivider.tsx +0 -22
  646. package/src/ui/components/menu/menuGroup.tsx +0 -228
  647. package/src/ui/components/menu/menuItem.tsx +0 -180
  648. package/src/ui/components/menu/useMenuController.ts +0 -241
  649. package/src/ui/components/skeleton/__workshop__/delay.tsx +0 -70
  650. package/src/ui/components/skeleton/__workshop__/skeleton.tsx +0 -64
  651. package/src/ui/components/skeleton/skeleton.tsx +0 -53
  652. package/src/ui/components/skeleton/textSkeleton.tsx +0 -132
  653. package/src/ui/components/tab/tab.tsx +0 -105
  654. package/src/ui/components/tab/tabList.tsx +0 -74
  655. package/src/ui/components/tab/tabPanel.tsx +0 -40
  656. package/src/ui/components/toast/__workshop__/toast.tsx +0 -26
  657. package/src/ui/components/toast/toast.tsx +0 -211
  658. package/src/ui/components/toast/toastLayer.tsx +0 -38
  659. package/src/ui/components/toast/types.ts +0 -28
  660. package/src/ui/components/tree/tree.tsx +0 -244
  661. package/src/ui/components/tree/treeGroup.tsx +0 -30
  662. package/src/ui/components/tree/treeItem.tsx +0 -220
  663. package/src/ui/components/tree/types.ts +0 -25
  664. package/src/ui/constants.ts +0 -85
  665. package/src/ui/helpers/index.ts +0 -5
  666. package/src/ui/helpers/props.ts +0 -10
  667. package/src/ui/hooks/useArrayProp.ts +0 -29
  668. package/src/ui/hooks/useClickOutside.test.tsx +0 -482
  669. package/src/ui/hooks/useForwardedRef.ts +0 -19
  670. package/src/ui/hooks/useMatchMedia.ts +0 -28
  671. package/src/ui/hooks/useMediaIndex/useMediaIndex.test.tsx +0 -36
  672. package/src/ui/hooks/useMediaIndex/useMediaIndex.ts +0 -102
  673. package/src/ui/hooks/usePrefersDark.ts +0 -16
  674. package/src/ui/hooks/usePrefersReducedMotion.ts +0 -16
  675. package/src/ui/index.ts +0 -9
  676. package/src/ui/primitives/_selectable/selectable.tsx +0 -31
  677. package/src/ui/primitives/avatar/__workshop__/asButton.tsx +0 -14
  678. package/src/ui/primitives/avatar/__workshop__/stack.tsx +0 -25
  679. package/src/ui/primitives/avatar/__workshop__/withinButton.tsx +0 -63
  680. package/src/ui/primitives/avatar/__workshop__/withinMenuItem.tsx +0 -72
  681. package/src/ui/primitives/avatar/avatar.tsx +0 -158
  682. package/src/ui/primitives/avatar/avatarCounter.tsx +0 -62
  683. package/src/ui/primitives/avatar/avatarStack.tsx +0 -82
  684. package/src/ui/primitives/badge/__workshop__/props.tsx +0 -30
  685. package/src/ui/primitives/badge/__workshop__/tones.tsx +0 -21
  686. package/src/ui/primitives/badge/badge.tsx +0 -64
  687. package/src/ui/primitives/box/__workshop__/props.tsx +0 -20
  688. package/src/ui/primitives/box/box.tsx +0 -162
  689. package/src/ui/primitives/button/__workshop__/custom.tsx +0 -50
  690. package/src/ui/primitives/button/__workshop__/props.tsx +0 -58
  691. package/src/ui/primitives/button/__workshop__/stacked.tsx +0 -59
  692. package/src/ui/primitives/button/button.tsx +0 -207
  693. package/src/ui/primitives/button/index.ts +0 -1
  694. package/src/ui/primitives/card/__workshop__/allTones.tsx +0 -27
  695. package/src/ui/primitives/card/__workshop__/asButton.tsx +0 -107
  696. package/src/ui/primitives/card/__workshop__/props.tsx +0 -55
  697. package/src/ui/primitives/card/__workshop__/selected.tsx +0 -93
  698. package/src/ui/primitives/card/card.tsx +0 -118
  699. package/src/ui/primitives/card/cardContext.ts +0 -10
  700. package/src/ui/primitives/card/cardProvider.tsx +0 -19
  701. package/src/ui/primitives/card/index.ts +0 -4
  702. package/src/ui/primitives/card/types.ts +0 -27
  703. package/src/ui/primitives/card/useCard.ts +0 -7
  704. package/src/ui/primitives/checkbox/checkbox.tsx +0 -74
  705. package/src/ui/primitives/checkbox/index.ts +0 -1
  706. package/src/ui/primitives/code/__workshop__/props.tsx +0 -21
  707. package/src/ui/primitives/code/code.tsx +0 -49
  708. package/src/ui/primitives/code/refractor.tsx +0 -20
  709. package/src/ui/primitives/container/__workshop__/example.tsx +0 -20
  710. package/src/ui/primitives/container/container.tsx +0 -35
  711. package/src/ui/primitives/container/index.ts +0 -2
  712. package/src/ui/primitives/flex/__workshop__/example.tsx +0 -34
  713. package/src/ui/primitives/flex/__workshop__/gap.tsx +0 -25
  714. package/src/ui/primitives/flex/flex.tsx +0 -29
  715. package/src/ui/primitives/grid/grid.tsx +0 -30
  716. package/src/ui/primitives/heading/__workshop__/plain.tsx +0 -32
  717. package/src/ui/primitives/heading/heading.tsx +0 -62
  718. package/src/ui/primitives/inline/__workshop__/plain.tsx +0 -27
  719. package/src/ui/primitives/inline/inline.tsx +0 -50
  720. package/src/ui/primitives/kbd/kbd.tsx +0 -55
  721. package/src/ui/primitives/label/__workshop__/opticalAlignment.tsx +0 -54
  722. package/src/ui/primitives/label/__workshop__/plain.tsx +0 -37
  723. package/src/ui/primitives/label/label.tsx +0 -67
  724. package/src/ui/primitives/popover/__workshop__/AlignedStory.tsx +0 -77
  725. package/src/ui/primitives/popover/__workshop__/MatchReferenceWidthStory.tsx +0 -32
  726. package/src/ui/primitives/popover/__workshop__/OpenOnMountStory.tsx +0 -11
  727. package/src/ui/primitives/popover/__workshop__/PlainStory.tsx +0 -71
  728. package/src/ui/primitives/popover/__workshop__/RecursiveStory.tsx +0 -70
  729. package/src/ui/primitives/popover/__workshop__/SidePanelStory.tsx +0 -93
  730. package/src/ui/primitives/popover/__workshop__/TestStory.tsx +0 -98
  731. package/src/ui/primitives/popover/helpers.ts +0 -32
  732. package/src/ui/primitives/popover/popover.tsx +0 -422
  733. package/src/ui/primitives/popover/popoverCard.tsx +0 -161
  734. package/src/ui/primitives/radio/index.ts +0 -1
  735. package/src/ui/primitives/radio/radio.tsx +0 -49
  736. package/src/ui/primitives/select/__workshop__/plain.tsx +0 -30
  737. package/src/ui/primitives/select/select.tsx +0 -85
  738. package/src/ui/primitives/spinner/__workshop__/Props.tsx +0 -16
  739. package/src/ui/primitives/spinner/animatedSpinnerIcon.tsx +0 -16
  740. package/src/ui/primitives/spinner/index.ts +0 -1
  741. package/src/ui/primitives/spinner/spinner.tsx +0 -33
  742. package/src/ui/primitives/stack/__workshop__/plain.tsx +0 -32
  743. package/src/ui/primitives/stack/index.ts +0 -1
  744. package/src/ui/primitives/stack/stack.tsx +0 -45
  745. package/src/ui/primitives/switch/index.ts +0 -1
  746. package/src/ui/primitives/switch/switch.tsx +0 -75
  747. package/src/ui/primitives/text/__workshop__/colored.tsx +0 -23
  748. package/src/ui/primitives/text/__workshop__/example.tsx +0 -39
  749. package/src/ui/primitives/text/text.tsx +0 -64
  750. package/src/ui/primitives/textArea/__workshop__/plain.tsx +0 -50
  751. package/src/ui/primitives/textArea/textArea.tsx +0 -71
  752. package/src/ui/primitives/textInput/__workshop__/plain.tsx +0 -104
  753. package/src/ui/primitives/textInput/__workshop__/typed.tsx +0 -23
  754. package/src/ui/primitives/textInput/textInput.tsx +0 -286
  755. package/src/ui/primitives/tooltip/__workshop__/customPortal.tsx +0 -102
  756. package/src/ui/primitives/tooltip/__workshop__/overflowingBoundary.tsx +0 -74
  757. package/src/ui/primitives/tooltip/__workshop__/props.tsx +0 -111
  758. package/src/ui/primitives/tooltip/__workshop__/resizableBoundary.tsx +0 -86
  759. package/src/ui/primitives/tooltip/tooltip.test.tsx +0 -453
  760. package/src/ui/primitives/tooltip/tooltip.tsx +0 -466
  761. package/src/ui/primitives/tooltip/tooltipCard.tsx +0 -115
  762. package/src/ui/primitives/tooltip/tooltipDelayGroup/tooltipDelayGroupProvider.tsx +0 -55
  763. package/src/ui/primitives/types.ts +0 -166
  764. package/src/ui/types/avatar.ts +0 -19
  765. package/src/ui/types/box.ts +0 -22
  766. package/src/ui/types/button.ts +0 -24
  767. package/src/ui/types/flex.ts +0 -27
  768. package/src/ui/types/grid.ts +0 -17
  769. package/src/ui/types/gridItem.ts +0 -32
  770. package/src/ui/types/index.ts +0 -15
  771. package/src/ui/types/props.ts +0 -18
  772. package/src/ui/types/radius.ts +0 -7
  773. package/src/ui/types/selectable.ts +0 -7
  774. package/src/ui/types/text.ts +0 -7
  775. package/src/ui/utils/arrow/arrow.tsx +0 -59
  776. package/src/ui/utils/boundaryElement/boundaryElementProvider.tsx +0 -24
  777. package/src/ui/utils/conditionalWrapper/conditionalWrapper.tsx +0 -23
  778. package/src/ui/utils/elementQuery/elementQuery.tsx +0 -53
  779. package/src/ui/utils/errorBoundary.tsx +0 -48
  780. package/src/ui/utils/layer/layer.tsx +0 -112
  781. package/src/ui/utils/layer/layerProvider.tsx +0 -110
  782. package/src/ui/utils/portal/portal.ts +0 -46
  783. package/src/ui/utils/portal/portalProvider.tsx +0 -79
  784. package/src/ui/utils/srOnly/index.ts +0 -1
  785. package/src/ui/utils/srOnly/srOnly.tsx +0 -35
  786. package/src/ui/utils/virtualList/virtualList.tsx +0 -189
  787. /package/src/{ui → core}/components/autocomplete/__mocks__/apiStore.ts +0 -0
  788. /package/src/{ui → core}/components/autocomplete/__mocks__/countries.ts +0 -0
  789. /package/src/{ui → core}/components/autocomplete/__workshop__/focusAndBlur.tsx +0 -0
  790. /package/src/{ui → core}/components/autocomplete/__workshop__/index.ts +0 -0
  791. /package/src/{ui → core}/components/autocomplete/__workshop__/types.ts +0 -0
  792. /package/src/{ui → core}/components/autocomplete/autocompleteReducer.ts +0 -0
  793. /package/src/{ui → core}/components/autocomplete/constants.ts +0 -0
  794. /package/src/{ui → core}/components/autocomplete/index.ts +0 -0
  795. /package/src/{ui → core}/components/breadcrumbs/__workshop__/example.tsx +0 -0
  796. /package/src/{ui → core}/components/breadcrumbs/__workshop__/index.ts +0 -0
  797. /package/src/{css → core}/components/breadcrumbs/index.ts +0 -0
  798. /package/src/{ui → core}/components/dialog/__workshop__/activate.tsx +0 -0
  799. /package/src/{ui → core}/components/dialog/__workshop__/autoFocus.tsx +0 -0
  800. /package/src/{ui → core}/components/dialog/__workshop__/index.ts +0 -0
  801. /package/src/{ui → core}/components/dialog/__workshop__/layering.tsx +0 -0
  802. /package/src/{ui → core}/components/dialog/__workshop__/panes.tsx +0 -0
  803. /package/src/{ui → core}/components/dialog/__workshop__/provider.tsx +0 -0
  804. /package/src/{ui → core}/components/dialog/__workshop__/wrapped.tsx +0 -0
  805. /package/src/{ui → core}/components/dialog/dialogContext.ts +0 -0
  806. /package/src/{ui → core}/components/dialog/index.ts +0 -0
  807. /package/src/{ui → core}/components/dialog/useDialog.ts +0 -0
  808. /package/src/{ui → core}/components/hotkeys/__workshop__/index.ts +0 -0
  809. /package/src/{ui → core}/components/hotkeys/__workshop__/plain.tsx +0 -0
  810. /package/src/{ui → core}/components/hotkeys/index.ts +0 -0
  811. /package/src/{ui → core}/components/index.ts +0 -0
  812. /package/src/{ui → core}/components/menu/__workshop__/asComponent.tsx +0 -0
  813. /package/src/{ui → core}/components/menu/__workshop__/avatarMenu.tsx +0 -0
  814. /package/src/{ui → core}/components/menu/__workshop__/closableMenuButton.tsx +0 -0
  815. /package/src/{ui → core}/components/menu/__workshop__/constrainedInBoundary.tsx +0 -0
  816. /package/src/{ui → core}/components/menu/__workshop__/customMenuItem.tsx +0 -0
  817. /package/src/{ui → core}/components/menu/__workshop__/customSelectedState.tsx +0 -0
  818. /package/src/{ui → core}/components/menu/__workshop__/disableFocusOnClose.tsx +0 -0
  819. /package/src/{ui → core}/components/menu/__workshop__/groups.tsx +0 -0
  820. /package/src/{ui → core}/components/menu/__workshop__/index.ts +0 -0
  821. /package/src/{ui → core}/components/menu/__workshop__/menuGroupRight.tsx +0 -0
  822. /package/src/{ui → core}/components/menu/__workshop__/nestedMenu.tsx +0 -0
  823. /package/src/{ui → core}/components/menu/__workshop__/onCloseMenuButton.tsx +0 -0
  824. /package/src/{ui → core}/components/menu/__workshop__/selectedItem.tsx +0 -0
  825. /package/src/{ui → core}/components/menu/__workshop__/shouldFocus.tsx +0 -0
  826. /package/src/{ui → core}/components/menu/__workshop__/withoutArrow.tsx +0 -0
  827. /package/src/{ui → core}/components/menu/helpers.ts +0 -0
  828. /package/src/{ui → core}/components/menu/index.ts +0 -0
  829. /package/src/{ui → core}/components/menu/useMenu.ts +0 -0
  830. /package/src/{ui → core}/components/skeleton/__workshop__/index.ts +0 -0
  831. /package/src/{ui → core}/components/skeleton/index.ts +0 -0
  832. /package/src/{ui → core}/components/tab/__workshop__/example.tsx +0 -0
  833. /package/src/{ui → core}/components/tab/__workshop__/index.ts +0 -0
  834. /package/src/{ui → core}/components/tab/index.ts +0 -0
  835. /package/src/{ui → core}/components/toast/__workshop__/hook.tsx +0 -0
  836. /package/src/{ui → core}/components/toast/__workshop__/index.ts +0 -0
  837. /package/src/{ui → core}/components/toast/index.ts +0 -0
  838. /package/src/{ui → core}/components/toast/toast.test.tsx +0 -0
  839. /package/src/{ui → core}/components/toast/toastContext.ts +0 -0
  840. /package/src/{ui → core}/components/toast/toastProvider.tsx +0 -0
  841. /package/src/{ui → core}/components/toast/toastState.ts +0 -0
  842. /package/src/{ui → core}/components/toast/useToast.ts +0 -0
  843. /package/src/{ui → core}/components/tree/__workshop__/basic.perf.ts +0 -0
  844. /package/src/{ui → core}/components/tree/__workshop__/basic.tsx +0 -0
  845. /package/src/{ui → core}/components/tree/__workshop__/index.ts +0 -0
  846. /package/src/{ui → core}/components/tree/__workshop__/tabFromElement.tsx +0 -0
  847. /package/src/{ui → core}/components/tree/helpers.ts +0 -0
  848. /package/src/{ui → core}/components/tree/index.ts +0 -0
  849. /package/src/{ui → core}/components/tree/treeContext.ts +0 -0
  850. /package/src/{ui → core}/components/tree/useTree.ts +0 -0
  851. /package/src/{ui → core}/global.ts +0 -0
  852. /package/src/{ui → core}/helpers/animation.ts +0 -0
  853. /package/src/{ui → core}/helpers/element.ts +0 -0
  854. /package/src/{ui → core}/helpers/focus.ts +0 -0
  855. /package/src/{ui → core}/helpers/scroll.ts +0 -0
  856. /package/src/{ui → core}/hooks/index.ts +0 -0
  857. /package/src/{ui → core}/hooks/useClickOutside.ts +0 -0
  858. /package/src/{ui → core}/hooks/useClickOutsideEvent.test.tsx +0 -0
  859. /package/src/{ui → core}/hooks/useClickOutsideEvent.ts +0 -0
  860. /package/src/{ui → core}/hooks/useCustomValidity.ts +0 -0
  861. /package/src/{ui → core}/hooks/useDelayed.test.ts +0 -0
  862. /package/src/{ui → core}/hooks/useDelayedState.ts +0 -0
  863. /package/src/{ui → core}/hooks/useElementRect/__workshop__/example.tsx +0 -0
  864. /package/src/{ui → core}/hooks/useElementRect/__workshop__/index.ts +0 -0
  865. /package/src/{ui → core}/hooks/useElementRect/index.ts +0 -0
  866. /package/src/{ui → core}/hooks/useElementRect/useElementRect.ts +0 -0
  867. /package/src/{ui → core}/hooks/useElementSize.ts +0 -0
  868. /package/src/{ui → core}/hooks/useGlobalKeyDown.ts +0 -0
  869. /package/src/{ui → core}/hooks/useIsomorphicEffect.ts +0 -0
  870. /package/src/{ui → core}/hooks/useMediaIndex/__workshop__/index.ts +0 -0
  871. /package/src/{ui → core}/hooks/useMediaIndex/__workshop__/test.tsx +0 -0
  872. /package/src/{ui → core}/hooks/useMediaIndex/index.ts +0 -0
  873. /package/src/{ui → core}/hooks/useMounted.ts +0 -0
  874. /package/src/{ui → core}/hooks/usePrefersDark.hydration.test.tsx +0 -0
  875. /package/src/{ui → core}/hooks/usePrefersDark.test.tsx +0 -0
  876. /package/src/{ui → core}/hooks/usePrefersReducedMotion.hydration.test.tsx +0 -0
  877. /package/src/{ui → core}/hooks/usePrefersReducedMotion.test.tsx +0 -0
  878. /package/src/{ui → core}/lib/createGlobalScopedContext.ts +0 -0
  879. /package/src/{ui → core}/lib/globalScope.ts +0 -0
  880. /package/src/{ui → core}/lib/isRecord.ts +0 -0
  881. /package/src/{ui → core}/middleware/origin.ts +0 -0
  882. /package/src/{ui → core}/observers/elementSizeObserver.ts +0 -0
  883. /package/src/{ui → core}/observers/index.ts +0 -0
  884. /package/src/{ui → core}/observers/resizeObserver.ts +0 -0
  885. /package/src/{ui → core}/primitives/_selectable/index.ts +0 -0
  886. /package/src/{ui → core}/primitives/avatar/__workshop__/index.ts +0 -0
  887. /package/src/{ui → core}/primitives/avatar/index.ts +0 -0
  888. /package/src/{ui → core}/primitives/avatar/types.ts +0 -0
  889. /package/src/{ui → core}/primitives/badge/__workshop__/index.ts +0 -0
  890. /package/src/{ui → core}/primitives/badge/badge.test.tsx +0 -0
  891. /package/src/{ui → core}/primitives/badge/index.ts +0 -0
  892. /package/src/{ui → core}/primitives/badge/types.ts +0 -0
  893. /package/src/{ui → core}/primitives/box/__workshop__/index.ts +0 -0
  894. /package/src/{ui → core}/primitives/box/__workshop__/responsive.tsx +0 -0
  895. /package/src/{ui → core}/primitives/box/index.ts +0 -0
  896. /package/src/{ui → core}/primitives/button/__workshop__/customIcons.tsx +0 -0
  897. /package/src/{ui → core}/primitives/button/__workshop__/disabled.tsx +0 -0
  898. /package/src/{ui → core}/primitives/button/__workshop__/index.ts +0 -0
  899. /package/src/{ui → core}/primitives/button/__workshop__/mixedChildren.tsx +0 -0
  900. /package/src/{ui → core}/primitives/button/__workshop__/sanityUploadButton.tsx +0 -0
  901. /package/src/{ui → core}/primitives/button/__workshop__/styled1.tsx +0 -0
  902. /package/src/{ui → core}/primitives/button/__workshop__/styled2.tsx +0 -0
  903. /package/src/{ui → core}/primitives/button/__workshop__/uploadButton.tsx +0 -0
  904. /package/src/{ui → core}/primitives/button/button.test.tsx +0 -0
  905. /package/src/{css → core}/primitives/button/index.ts +0 -0
  906. /package/src/{ui → core}/primitives/card/__workshop__/asComponent.tsx +0 -0
  907. /package/src/{ui → core}/primitives/card/__workshop__/checkered.tsx +0 -0
  908. /package/src/{ui → core}/primitives/card/__workshop__/index.ts +0 -0
  909. /package/src/{ui → core}/primitives/card/__workshop__/interactive.tsx +0 -0
  910. /package/src/{ui → core}/primitives/card/__workshop__/listNavigation.tsx +0 -0
  911. /package/src/{ui → core}/primitives/card/__workshop__/styled.tsx +0 -0
  912. /package/src/{css → core}/primitives/card/index.ts +0 -0
  913. /package/src/{ui → core}/primitives/checkbox/__workshop__/example.tsx +0 -0
  914. /package/src/{ui → core}/primitives/checkbox/__workshop__/index.ts +0 -0
  915. /package/src/{ui → core}/primitives/checkbox/__workshop__/props.tsx +0 -0
  916. /package/src/{ui → core}/primitives/checkbox/__workshop__/readOnly.tsx +0 -0
  917. /package/src/{ui → core}/primitives/checkbox/__workshop__/tones.tsx +0 -0
  918. /package/src/{css → core}/primitives/checkbox/index.ts +0 -0
  919. /package/src/{ui → core}/primitives/code/__workshop__/index.ts +0 -0
  920. /package/src/{ui → core}/primitives/code/__workshop__/opticalAlignment.tsx +0 -0
  921. /package/src/{ui → core}/primitives/code/index.ts +0 -0
  922. /package/src/{ui → core}/primitives/container/__workshop__/index.ts +0 -0
  923. /package/src/{css → core}/primitives/container/index.ts +0 -0
  924. /package/src/{ui → core}/primitives/container/types.ts +0 -0
  925. /package/src/{ui → core}/primitives/flex/__workshop__/index.ts +0 -0
  926. /package/src/{ui → core}/primitives/flex/index.ts +0 -0
  927. /package/src/{ui → core}/primitives/grid/__workshop__/index.ts +0 -0
  928. /package/src/{ui → core}/primitives/grid/__workshop__/responsive.tsx +0 -0
  929. /package/src/{ui → core}/primitives/grid/index.ts +0 -0
  930. /package/src/{ui → core}/primitives/heading/__workshop__/index.ts +0 -0
  931. /package/src/{ui → core}/primitives/heading/__workshop__/opticalAlignment.tsx +0 -0
  932. /package/src/{ui → core}/primitives/heading/index.ts +0 -0
  933. /package/src/{ui → core}/primitives/index.ts +0 -0
  934. /package/src/{ui → core}/primitives/inline/__workshop__/index.ts +0 -0
  935. /package/src/{ui → core}/primitives/inline/index.ts +0 -0
  936. /package/src/{ui → core}/primitives/inline/types.ts +0 -0
  937. /package/src/{ui → core}/primitives/kbd/__workshop__/index.ts +0 -0
  938. /package/src/{ui → core}/primitives/kbd/__workshop__/plain.tsx +0 -0
  939. /package/src/{ui → core}/primitives/kbd/index.ts +0 -0
  940. /package/src/{ui → core}/primitives/label/__workshop__/index.ts +0 -0
  941. /package/src/{ui → core}/primitives/label/index.ts +0 -0
  942. /package/src/{ui → core}/primitives/popover/__workshop__/MarginsStory.tsx +0 -0
  943. /package/src/{ui → core}/primitives/popover/__workshop__/index.ts +0 -0
  944. /package/src/{ui → core}/primitives/popover/constants.ts +0 -0
  945. /package/src/{ui → core}/primitives/popover/floating-ui/size.ts +0 -0
  946. /package/src/{ui → core}/primitives/popover/index.ts +0 -0
  947. /package/src/{ui → core}/primitives/popover/types.ts +0 -0
  948. /package/src/{ui → core}/primitives/radio/__workshop__/example.tsx +0 -0
  949. /package/src/{ui → core}/primitives/radio/__workshop__/index.ts +0 -0
  950. /package/src/{ui → core}/primitives/radio/__workshop__/plain.tsx +0 -0
  951. /package/src/{css → core}/primitives/radio/index.ts +0 -0
  952. /package/src/{ui → core}/primitives/select/__workshop__/index.ts +0 -0
  953. /package/src/{ui → core}/primitives/select/__workshop__/readOnly.tsx +0 -0
  954. /package/src/{ui → core}/primitives/select/index.ts +0 -0
  955. /package/src/{ui → core}/primitives/spinner/__workshop__/index.ts +0 -0
  956. /package/src/{css → core}/primitives/spinner/index.ts +0 -0
  957. /package/src/{ui → core}/primitives/stack/__workshop__/index.ts +0 -0
  958. /package/src/{css → core}/primitives/stack/index.ts +0 -0
  959. /package/src/{ui → core}/primitives/switch/__workshop__/example.tsx +0 -0
  960. /package/src/{ui → core}/primitives/switch/__workshop__/index.ts +0 -0
  961. /package/src/{ui → core}/primitives/switch/__workshop__/props.tsx +0 -0
  962. /package/src/{css → core}/primitives/switch/index.ts +0 -0
  963. /package/src/{ui → core}/primitives/text/__workshop__/index.ts +0 -0
  964. /package/src/{ui → core}/primitives/text/__workshop__/opticalAlignment.tsx +0 -0
  965. /package/src/{ui → core}/primitives/text/index.ts +0 -0
  966. /package/src/{ui → core}/primitives/textArea/__workshop__/index.ts +0 -0
  967. /package/src/{ui → core}/primitives/textArea/index.ts +0 -0
  968. /package/src/{ui → core}/primitives/textInput/__workshop__/clearButton.tsx +0 -0
  969. /package/src/{ui → core}/primitives/textInput/__workshop__/customValidity.tsx +0 -0
  970. /package/src/{ui → core}/primitives/textInput/__workshop__/index.ts +0 -0
  971. /package/src/{ui → core}/primitives/textInput/__workshop__/readOnly.tsx +0 -0
  972. /package/src/{ui → core}/primitives/textInput/__workshop__/states.tsx +0 -0
  973. /package/src/{ui → core}/primitives/textInput/__workshop__/tones.tsx +0 -0
  974. /package/src/{ui → core}/primitives/textInput/index.ts +0 -0
  975. /package/src/{ui → core}/primitives/tooltip/__workshop__/index.ts +0 -0
  976. /package/src/{ui → core}/primitives/tooltip/constants.ts +0 -0
  977. /package/src/{ui → core}/primitives/tooltip/index.ts +0 -0
  978. /package/src/{ui → core}/primitives/tooltip/tooltipDelayGroup/index.ts +0 -0
  979. /package/src/{ui → core}/primitives/tooltip/tooltipDelayGroup/tooltipDelayGroupContext.tsx +0 -0
  980. /package/src/{ui → core}/primitives/tooltip/tooltipDelayGroup/types.ts +0 -0
  981. /package/src/{ui → core}/primitives/tooltip/tooltipDelayGroup/useTooltipDelayGroup.ts +0 -0
  982. /package/src/{ui/_compat → core}/theme/index.ts +0 -0
  983. /package/src/{ui/_compat → core}/theme/types.ts +0 -0
  984. /package/src/{ui/_compat → core}/theme/useRootTheme.ts +0 -0
  985. /package/src/{ui/_compat → core}/theme/useTheme.ts +0 -0
  986. /package/src/{ui → core}/types/badge.ts +0 -0
  987. /package/src/{ui → core}/types/card.ts +0 -0
  988. /package/src/{ui → core}/types/dialog.ts +0 -0
  989. /package/src/{ui → core}/types/placement.ts +0 -0
  990. /package/src/{ui → core}/types/popover.ts +0 -0
  991. /package/src/{ui → core}/utils/arrow/cmds.ts +0 -0
  992. /package/src/{ui → core}/utils/arrow/index.ts +0 -0
  993. /package/src/{ui → core}/utils/boundaryElement/__workshop__/index.ts +0 -0
  994. /package/src/{ui → core}/utils/boundaryElement/__workshop__/plain.tsx +0 -0
  995. /package/src/{ui → core}/utils/boundaryElement/boundaryElement.test.tsx +0 -0
  996. /package/src/{ui → core}/utils/boundaryElement/boundaryElementContext.ts +0 -0
  997. /package/src/{ui → core}/utils/boundaryElement/index.ts +0 -0
  998. /package/src/{ui → core}/utils/boundaryElement/types.ts +0 -0
  999. /package/src/{ui → core}/utils/boundaryElement/useBoundaryElement.ts +0 -0
  1000. /package/src/{ui → core}/utils/conditionalWrapper/index.ts +0 -0
  1001. /package/src/{ui → core}/utils/elementQuery/__workshop__/customMedia.tsx +0 -0
  1002. /package/src/{ui → core}/utils/elementQuery/__workshop__/index.ts +0 -0
  1003. /package/src/{ui → core}/utils/elementQuery/helpers.ts +0 -0
  1004. /package/src/{ui → core}/utils/elementQuery/index.ts +0 -0
  1005. /package/src/{ui → core}/utils/getElementRef.ts +0 -0
  1006. /package/src/{ui → core}/utils/index.ts +0 -0
  1007. /package/src/{ui → core}/utils/layer/__workshop__/_debug.tsx +0 -0
  1008. /package/src/{ui → core}/utils/layer/__workshop__/index.ts +0 -0
  1009. /package/src/{ui → core}/utils/layer/__workshop__/multipleRoots.tsx +0 -0
  1010. /package/src/{ui → core}/utils/layer/__workshop__/nested.tsx +0 -0
  1011. /package/src/{ui → core}/utils/layer/__workshop__/responsiveZOffset.tsx +0 -0
  1012. /package/src/{ui → core}/utils/layer/getLayerContext.test.ts +0 -0
  1013. /package/src/{ui → core}/utils/layer/getLayerContext.ts +0 -0
  1014. /package/src/{ui → core}/utils/layer/index.ts +0 -0
  1015. /package/src/{ui → core}/utils/layer/layer.test.tsx +0 -0
  1016. /package/src/{ui → core}/utils/layer/layerContext.ts +0 -0
  1017. /package/src/{ui → core}/utils/layer/types.ts +0 -0
  1018. /package/src/{ui → core}/utils/layer/useLayer.ts +0 -0
  1019. /package/src/{ui → core}/utils/portal/__workshop__/index.ts +0 -0
  1020. /package/src/{ui → core}/utils/portal/__workshop__/named.tsx +0 -0
  1021. /package/src/{ui → core}/utils/portal/index.ts +0 -0
  1022. /package/src/{ui → core}/utils/portal/portal.test.tsx +0 -0
  1023. /package/src/{ui → core}/utils/portal/portalContext.ts +0 -0
  1024. /package/src/{ui → core}/utils/portal/types.ts +0 -0
  1025. /package/src/{ui → core}/utils/portal/usePortal.ts +0 -0
  1026. /package/src/{ui → core}/utils/spanWithTextOverflow.tsx +0 -0
  1027. /package/src/{css → core}/utils/srOnly/index.ts +0 -0
  1028. /package/src/{ui → core}/utils/virtualList/__workshop__/changingProps.tsx +0 -0
  1029. /package/src/{ui → core}/utils/virtualList/__workshop__/elementScroll.tsx +0 -0
  1030. /package/src/{ui → core}/utils/virtualList/__workshop__/index.ts +0 -0
  1031. /package/src/{ui → core}/utils/virtualList/__workshop__/infiniteList.tsx +0 -0
  1032. /package/src/{ui → core}/utils/virtualList/__workshop__/windowScrolll.tsx +0 -0
  1033. /package/src/{ui → core}/utils/virtualList/index.ts +0 -0
  1034. /package/src/theme/{v2 → system}/color/_constants.ts +0 -0
  1035. /package/src/theme/{v2 → system}/color/_helpers.ts +0 -0
  1036. /package/src/theme/{v2 → system}/color/_system.ts +0 -0
  1037. /package/src/theme/{v2 → system}/color/avatar.ts +0 -0
  1038. /package/src/theme/{v2 → system}/color/badge.ts +0 -0
  1039. /package/src/theme/{v2 → system}/color/button.ts +0 -0
  1040. /package/src/theme/{v2 → system}/color/color.ts +0 -0
  1041. /package/src/theme/{v2 → system}/color/index.ts +0 -0
  1042. /package/src/theme/{v2 → system}/color/input.ts +0 -0
  1043. /package/src/theme/{v2 → system}/color/kbd.ts +0 -0
  1044. /package/src/theme/{v2 → system}/color/selectable.ts +0 -0
  1045. /package/src/theme/{v2 → system}/color/shadow.ts +0 -0
  1046. /package/src/theme/{v2 → system}/color/state.ts +0 -0
  1047. /package/src/theme/{v2 → system}/color/syntax.ts +0 -0
  1048. /package/src/theme/{v0 → system}/css.ts +0 -0
  1049. /package/src/theme/{v0 → system}/focusRing.ts +0 -0
  1050. /package/src/theme/{v0 → system}/layer.ts +0 -0
  1051. /package/src/theme/{v0 → system}/shadow.ts +0 -0
  1052. /package/src/theme/{v0 → system}/styles.ts +0 -0
  1053. /package/src/theme/{v0 → system/v0}/avatar.ts +0 -0
  1054. /package/src/theme/{v0 → system/v0}/color/_system.ts +0 -0
  1055. /package/src/theme/{v0 → system/v0}/color/base.ts +0 -0
  1056. /package/src/theme/{v0 → system/v0}/color/button.ts +0 -0
  1057. /package/src/theme/{v0 → system/v0}/color/card.ts +0 -0
  1058. /package/src/theme/{v0 → system/v0}/color/index.ts +0 -0
  1059. /package/src/theme/{v0 → system/v0}/color/muted.ts +0 -0
  1060. /package/src/theme/{v0 → system/v0}/color/selectable.ts +0 -0
  1061. /package/src/theme/{v0 → system/v0}/color/solid.ts +0 -0
  1062. /package/src/theme/{v0 → system/v0}/input.ts +0 -0
package/dist/index.mjs CHANGED
@@ -1,18 +1,12 @@
1
- import { isHTMLElement, isHTMLAnchorElement, isHTMLInputElement, isHTMLButtonElement, isHTMLSelectElement, isHTMLTextAreaElement, EMPTY_ARRAY, useElementSize, Code, _isEnterToClickElement, Card, Text, useArrayProp, EMPTY_RECORD, Box, Button, Stack, Popover, TextInput, AnimatedSpinnerIcon, useClickOutsideEvent, Flex, createGlobalScopedContext, usePortal, useBoundaryElement, useLayer, useGlobalKeyDown, Container, usePrefersReducedMotion, Z_OFFSETS, Portal, Layer, containsOrEqualsElement, Grid, LayerProvider, isRecord, Selectable } from "./_chunks-es/_visual-editing.mjs";
2
- import { Arrow, Avatar, AvatarCounter, AvatarStack, Badge, BoundaryElementProvider, CardProvider, Checkbox, ConditionalWrapper, ElementQuery, Heading, Hotkeys, Inline, KBD, Label, Menu, MenuDivider, MenuGroup, MenuItem, PortalProvider, Radio, Select, Spinner, SrOnly, Switch, Tab, TabList, TextArea, ThemeColorProvider, ThemeProvider, Tooltip, TooltipDelayGroupContext, TooltipDelayGroupProvider, VirtualList, _ResizeObserver, _elementSizeObserver, _getArrayProp, _isScrollable, createColorTheme, hexToRgb, hslToRgb, multiply, parseColor, rgbToHex, rgbToHsl, rgba, screen, studioTheme, useCard, useCustomValidity, useMatchMedia, useMediaIndex, usePrefersDark, useRootTheme, useTheme, useTheme_v2, useTooltipDelayGroup } from "./_chunks-es/_visual-editing.mjs";
3
- import { composeClassNames, breadcrumbs, dialogContainer, dialogCardRoot, dialogLayout, dialogHeader, dialogContent, dialogFooter, dialog, skeleton, textSkeleton, labelSkeleton, headingSkeleton, codeSkeleton, toast, toastLoadingBar, toastLoadingBarMask, toastLoadingBarProgress, toastLayer, treeItem, compilePalette, compileTheme, compileSystem } from "@sanity/ui/css";
4
- import { px, rem } from "@sanity/ui/css";
1
+ import { isHTMLElement, isHTMLAnchorElement, isHTMLInputElement, isHTMLButtonElement, isHTMLSelectElement, isHTMLTextAreaElement, EMPTY_ARRAY, useElementSize, Code, Box, _isEnterToClickElement, Card, Text, useArrayProp, EMPTY_RECORD, Button, Stack, Popover, TextInput, useClickOutsideEvent, _responsive, createGlobalScopedContext, Container, Flex, usePortal, useBoundaryElement, useLayer, useGlobalKeyDown, useTheme_v2, usePrefersReducedMotion, Portal, containsOrEqualsElement, Layer, responsivePaddingStyle, responsiveRadiusStyle, Grid, LayerProvider, isRecord, _cardColorStyle, rem } from "./_chunks-es/_visual-editing.mjs";
2
+ import { Arrow, Avatar, AvatarCounter, AvatarStack, Badge, BoundaryElementProvider, Checkbox, ConditionalWrapper, ElementQuery, Heading, Hotkeys, Inline, KBD, Label, Menu, MenuDivider, MenuGroup, MenuItem, PortalProvider, Radio, Select, Spinner, SrOnly, Switch, Tab, TabList, TextArea, ThemeColorProvider, ThemeProvider, Tooltip, TooltipDelayGroupContext, TooltipDelayGroupProvider, VirtualList, _ResizeObserver, _elementSizeObserver, _fillCSSObject, _getArrayProp, _getResponsiveSpace, _isScrollable, createColorTheme, hexToRgb, hslToRgb, multiply, parseColor, responsiveCodeFontStyle, responsiveHeadingFont, responsiveLabelFont, responsiveTextAlignStyle, responsiveTextFont, rgbToHex, rgbToHsl, rgba, screen, studioTheme, useCustomValidity, useMatchMedia, useMediaIndex, usePrefersDark, useRootTheme, useTheme, useTooltipDelayGroup } from "./_chunks-es/_visual-editing.mjs";
5
3
  import { jsx, jsxs, Fragment as Fragment$1 } from "react/jsx-runtime";
6
- import { ChevronDownIcon, CloseIcon, ToggleArrowRightIcon } from "@sanity/icons";
4
+ import { SpinnerIcon, ChevronDownIcon, CloseIcon, ToggleArrowRightIcon } from "@sanity/icons";
7
5
  import { useState, useRef, useEffect, useImperativeHandle, Component, forwardRef, useReducer, useCallback, useMemo, cloneElement, Children, isValidElement, Fragment, useContext, useSyncExternalStore, startTransition, memo, useId } from "react";
6
+ import { styled, keyframes, css } from "styled-components";
8
7
  import { c } from "react-compiler-runtime";
8
+ import { getTheme_v2 } from "@sanity/ui/theme";
9
9
  import { motion, AnimatePresence } from "framer-motion";
10
- import { buildTheme_v3 } from "@sanity/ui/theme";
11
- function _responsive(media, values, callback) {
12
- return (values?.map(callback) || []).map((statement, mediaIndex) => mediaIndex === 0 ? statement : {
13
- [`@media screen and (min-width: ${media[mediaIndex - 1]}px)`]: statement
14
- });
15
- }
16
10
  function _raf(fn) {
17
11
  const frameId = requestAnimationFrame(fn);
18
12
  return () => {
@@ -140,6 +134,24 @@ class ErrorBoundary extends Component {
140
134
  return this.props.children;
141
135
  }
142
136
  }
137
+ const StyledAutocomplete = styled.div.withConfig({
138
+ displayName: "StyledAutocomplete",
139
+ componentId: "sc-1igauft-0"
140
+ })`line-height:0;`, ListBox = styled(Box).withConfig({
141
+ displayName: "ListBox",
142
+ componentId: "sc-1igauft-1"
143
+ })`& > ul{list-style:none;padding:0;margin:0;}`, rotate = keyframes`
144
+ from {
145
+ transform: rotate(0deg);
146
+ }
147
+
148
+ to {
149
+ transform: rotate(360deg);
150
+ }
151
+ `, AnimatedSpinnerIcon = styled(SpinnerIcon).withConfig({
152
+ displayName: "AnimatedSpinnerIcon",
153
+ componentId: "sc-1igauft-2"
154
+ })`animation:${rotate} 500ms linear infinite;`;
143
155
  function AutocompleteOption(props) {
144
156
  const $ = c(11), {
145
157
  children,
@@ -247,7 +259,7 @@ const AUTOCOMPLETE_LISTBOX_IGNORE_KEYS = ["Control", "Shift", "Alt", "Enter", "H
247
259
  value
248
260
  } = state, defaultRenderOption = useCallback(({
249
261
  value: value_0
250
- }) => /* @__PURE__ */ jsx(Card, { as: "button", padding: paddingProp, radius: 2, tone: "inherit", children: /* @__PURE__ */ jsx(Text, { size: fontSize, textOverflow: "ellipsis", children: value_0 }) }), [fontSize, paddingProp]), renderOption = typeof renderOptionProp == "function" ? renderOptionProp : defaultRenderOption, filterOption = typeof filterOptionProp == "function" ? filterOptionProp : DEFAULT_FILTER_OPTION, rootElementRef = useRef(null), resultsPopoverElementRef = useRef(null), inputElementRef = useRef(null), listBoxElementRef = useRef(null), listFocusedRef = useRef(!1), valueRef = useRef(value), valuePropRef = useRef(valueProp), popoverMouseWithinRef = useRef(!1);
262
+ }) => /* @__PURE__ */ jsx(Card, { "data-as": "button", padding: paddingProp, radius: 2, tone: "inherit", children: /* @__PURE__ */ jsx(Text, { size: fontSize, textOverflow: "ellipsis", children: value_0 }) }), [fontSize, paddingProp]), renderOption = typeof renderOptionProp == "function" ? renderOptionProp : defaultRenderOption, filterOption = typeof filterOptionProp == "function" ? filterOptionProp : DEFAULT_FILTER_OPTION, rootElementRef = useRef(null), resultsPopoverElementRef = useRef(null), inputElementRef = useRef(null), listBoxElementRef = useRef(null), listFocusedRef = useRef(!1), valueRef = useRef(value), valuePropRef = useRef(valueProp), popoverMouseWithinRef = useRef(!1);
251
263
  useImperativeHandle(forwardedRef, () => inputElementRef.current);
252
264
  const listBoxId = `${id}-listbox`, options = Array.isArray(optionsProp) ? optionsProp : EMPTY_ARRAY, padding = useArrayProp(paddingProp), currentOption = useMemo(() => value !== null ? options.find((o) => o.value === value) : void 0, [options, value]), filteredOptions = useMemo(() => options.filter((option) => query ? filterOption(query, option) : !0), [filterOption, options, query]), filteredOptionsLen = filteredOptions.length, activeItemId = activeValue ? `${id}-option-${activeValue}` : void 0, expanded = query !== null && loading || focused && query !== null, handleRootBlur = useCallback((event) => {
253
265
  setTimeout(() => {
@@ -375,9 +387,9 @@ const AUTOCOMPLETE_LISTBOX_IGNORE_KEYS = ["Control", "Shift", "Alt", "Enter", "H
375
387
  };
376
388
  }, [disabled, handleClearButtonFocus, loading, value]), openButtonBoxPadding = useMemo(() => padding.map((v_0) => v_0 === 0 ? 0 : v_0 === 1 || v_0 === 2 ? 1 : v_0 - 2), [padding]), openButtonPadding = useMemo(() => padding.map((v_1) => Math.max(v_1 - 1, 0)), [padding]), openButtonProps = useMemo(() => typeof openButton == "object" ? openButton : EMPTY_RECORD, [openButton]), handleOpenClick = useCallback((event_4) => {
377
389
  dispatchOpen(), openButtonProps.onClick && openButtonProps.onClick(event_4), _raf(() => inputElementRef.current?.focus());
378
- }, [openButtonProps, dispatchOpen]), openButtonNode = useMemo(() => !disabled && !readOnly && openButton ? /* @__PURE__ */ jsx(Box, { "aria-hidden": expanded, padding: openButtonBoxPadding, children: /* @__PURE__ */ jsx(Button, { "aria-label": "Open", disabled: expanded, display: "block", fontSize, icon: ChevronDownIcon, mode: "bleed", padding: openButtonPadding, ...openButtonProps, onClick: handleOpenClick }) }) : void 0, [disabled, expanded, fontSize, handleOpenClick, openButton, openButtonBoxPadding, openButtonPadding, openButtonProps, readOnly]), inputValue = useMemo(() => query === null ? value !== null ? renderValue(value, currentOption) : "" : query, [currentOption, query, renderValue, value]), input = /* @__PURE__ */ jsx(TextInput, { ...restProps, "aria-activedescendant": activeItemId, "aria-autocomplete": "list", "aria-expanded": expanded, "aria-owns": listBoxId, autoCapitalize: "off", autoComplete: "off", autoCorrect: "off", border, clearButton, customValidity, disabled, fontSize, icon, iconRight: loading && AnimatedSpinnerIcon, id, inputMode: "search", onChange: handleInputChange, onClear: handleClearButtonClick, onFocus: handleInputFocus, padding, prefix, radius, readOnly, ref: inputElementRef, role: "combobox", spellCheck: !1, suffix: suffix || openButtonNode, value: inputValue }), handleListBoxKeyDown = useCallback((event_5) => {
390
+ }, [openButtonProps, dispatchOpen]), openButtonNode = useMemo(() => !disabled && !readOnly && openButton ? /* @__PURE__ */ jsx(Box, { "aria-hidden": expanded, padding: openButtonBoxPadding, children: /* @__PURE__ */ jsx(Button, { "aria-label": "Open", disabled: expanded, fontSize, icon: ChevronDownIcon, mode: "bleed", padding: openButtonPadding, ...openButtonProps, onClick: handleOpenClick }) }) : void 0, [disabled, expanded, fontSize, handleOpenClick, openButton, openButtonBoxPadding, openButtonPadding, openButtonProps, readOnly]), inputValue = useMemo(() => query === null ? value !== null ? renderValue(value, currentOption) : "" : query, [currentOption, query, renderValue, value]), input = /* @__PURE__ */ jsx(TextInput, { ...restProps, "aria-activedescendant": activeItemId, "aria-autocomplete": "list", "aria-expanded": expanded, "aria-owns": listBoxId, autoCapitalize: "off", autoComplete: "off", autoCorrect: "off", border, clearButton, customValidity, disabled, fontSize, icon, iconRight: loading && AnimatedSpinnerIcon, id, inputMode: "search", onChange: handleInputChange, onClear: handleClearButtonClick, onFocus: handleInputFocus, padding, prefix, radius, readOnly, ref: inputElementRef, role: "combobox", spellCheck: !1, suffix: suffix || openButtonNode, value: inputValue }), handleListBoxKeyDown = useCallback((event_5) => {
379
391
  event_5.key === "Tab" && listFocused && inputElementRef.current?.focus();
380
- }, [listFocused]), content2 = useMemo(() => filteredOptions.length === 0 ? null : /* @__PURE__ */ jsx(Box, { "data-ui": "AutoComplete__results", onKeyDown: handleListBoxKeyDown, padding: 1, ...listBox, tabIndex: -1, children: /* @__PURE__ */ jsx(Stack, { as: "ul", "aria-multiselectable": !1, "data-ui": "AutoComplete__resultsList", id: listBoxId, ref: listBoxElementRef, role: "listbox", space: 1, children: filteredOptions.map((option_0) => {
392
+ }, [listFocused]), content2 = useMemo(() => filteredOptions.length === 0 ? null : /* @__PURE__ */ jsx(ListBox, { "data-ui": "AutoComplete__results", onKeyDown: handleListBoxKeyDown, padding: 1, ...listBox, tabIndex: -1, children: /* @__PURE__ */ jsx(Stack, { as: "ul", "aria-multiselectable": !1, "data-ui": "AutoComplete__resultsList", id: listBoxId, ref: listBoxElementRef, role: "listbox", space: 1, children: filteredOptions.map((option_0) => {
381
393
  const active = activeValue !== null ? option_0.value === activeValue : currentOption === option_0;
382
394
  return /* @__PURE__ */ jsx(AutocompleteOption, { id: `${id}-option-${option_0.value}`, onSelect: handleOptionSelect, selected: active, value: option_0.value, children: cloneElement(renderOption(option_0), {
383
395
  disabled: loading,
@@ -390,46 +402,100 @@ const AUTOCOMPLETE_LISTBOX_IGNORE_KEYS = ["Control", "Shift", "Alt", "Enter", "H
390
402
  inputElement: inputElementRef.current,
391
403
  onMouseEnter: handlePopoverMouseEnter,
392
404
  onMouseLeave: handlePopoverMouseLeave
393
- }, resultsPopoverElementRef) : filteredOptionsLen === 0 ? null : /* @__PURE__ */ jsx(Popover, { arrow: !1, constrainSize: !0, content: content2, fallbackPlacements: AUTOCOMPLETE_POPOVER_FALLBACK_PLACEMENTS, matchReferenceWidth: !0, onMouseEnter: handlePopoverMouseEnter, onMouseLeave: handlePopoverMouseLeave, open: expanded, overflow: "auto", placement: AUTOCOMPLETE_POPOVER_PLACEMENT, portal: !0, radius: 3, ref: resultsPopoverElementRef, referenceElement: inputElementRef.current, ...popover }), [content2, expanded, filteredOptionsLen, handlePopoverMouseEnter, handlePopoverMouseLeave, popover, renderPopover]);
394
- return (
395
- // eslint-disable-next-line jsx-a11y/no-static-element-interactions
396
- /* @__PURE__ */ jsxs("div", { "data-ui": "Autocomplete", onBlur: handleRootBlur, onFocus: handleRootFocus, onKeyDown: handleRootKeyDown, ref: rootElementRef, children: [
397
- input,
398
- results
399
- ] })
400
- );
405
+ }, resultsPopoverElementRef) : filteredOptionsLen === 0 ? null : /* @__PURE__ */ jsx(Popover, { arrow: !1, constrainSize: !0, content: content2, fallbackPlacements: AUTOCOMPLETE_POPOVER_FALLBACK_PLACEMENTS, matchReferenceWidth: !0, onMouseEnter: handlePopoverMouseEnter, onMouseLeave: handlePopoverMouseLeave, open: expanded, overflow: "auto", placement: AUTOCOMPLETE_POPOVER_PLACEMENT, portal: !0, radius, ref: resultsPopoverElementRef, referenceElement: inputElementRef.current, ...popover }), [content2, expanded, filteredOptionsLen, handlePopoverMouseEnter, handlePopoverMouseLeave, popover, radius, renderPopover]);
406
+ return /* @__PURE__ */ jsxs(StyledAutocomplete, { "data-ui": "Autocomplete", onBlur: handleRootBlur, onFocus: handleRootFocus, onKeyDown: handleRootKeyDown, ref: rootElementRef, children: [
407
+ input,
408
+ results
409
+ ] });
401
410
  });
402
411
  InnerAutocomplete.displayName = "ForwardRef(Autocomplete)";
403
- const Autocomplete = InnerAutocomplete, Breadcrumbs = forwardRef(function(props, ref) {
412
+ const Autocomplete = InnerAutocomplete, StyledBreadcrumbs = styled.ol.withConfig({
413
+ displayName: "StyledBreadcrumbs",
414
+ componentId: "sc-1es8h8q-0"
415
+ })`margin:0;padding:0;display:flex;list-style:none;align-items:center;white-space:nowrap;line-height:0;`, ExpandButton = styled(Button).withConfig({
416
+ displayName: "ExpandButton",
417
+ componentId: "sc-1es8h8q-1"
418
+ })`appearance:none;margin:-4px;`, Breadcrumbs = forwardRef(function(props, ref) {
404
419
  const {
405
420
  children,
406
- className,
407
- expandButton: expandButtonProps,
408
- // eslint-disable-next-line @typescript-eslint/no-unused-vars
409
- gap: _gapProp,
410
- gapX = props.gap ?? props.space ?? 2,
411
- gapY = props.gap ?? props.space ?? 2,
412
421
  maxLength,
413
422
  separator,
414
- // eslint-disable-next-line @typescript-eslint/no-unused-vars
415
- space: _spaceProp,
423
+ space: spaceRaw = 2,
416
424
  ...restProps
417
- } = props, [open, setOpen] = useState(!1), expandElementRef = useRef(null), popoverElementRef = useRef(null), collapse = useCallback(() => setOpen(!1), []), expand = useCallback(() => setOpen(!0), []);
425
+ } = props, space = useArrayProp(spaceRaw), [open, setOpen] = useState(!1), expandElementRef = useRef(null), popoverElementRef = useRef(null), collapse = useCallback(() => setOpen(!1), []), expand = useCallback(() => setOpen(!0), []);
418
426
  useClickOutsideEvent(collapse, () => [expandElementRef.current, popoverElementRef.current]);
419
427
  const rawItems = useMemo(() => Children.toArray(children).filter(isValidElement), [children]), items = useMemo(() => {
420
428
  const len = rawItems.length;
421
429
  if (maxLength && len > maxLength) {
422
430
  const beforeLength = Math.ceil(maxLength / 2), afterLength = Math.floor(maxLength / 2);
423
- return [...rawItems.slice(0, beforeLength - 1), /* @__PURE__ */ jsx(Popover, { constrainSize: !0, content: /* @__PURE__ */ jsx(Stack, { as: "ol", overflow: "auto", space: gapY, children: rawItems.slice(beforeLength - 1, len - afterLength) }), open, padding: 2, placement: "top", portal: !0, ref: popoverElementRef, children: /* @__PURE__ */ jsx(Button, { mode: "bleed", padding: 0, text: "\u2026", ...expandButtonProps, onClick: open ? collapse : expand, ref: expandElementRef, selected: open }) }, "button"), ...rawItems.slice(len - afterLength)];
431
+ return [...rawItems.slice(0, beforeLength - 1), /* @__PURE__ */ jsx(Popover, { constrainSize: !0, content: /* @__PURE__ */ jsx(Stack, { as: "ol", overflow: "auto", padding: space, space, children: rawItems.slice(beforeLength - 1, len - afterLength) }), open, placement: "top", portal: !0, ref: popoverElementRef, children: /* @__PURE__ */ jsx(ExpandButton, { fontSize: 1, mode: "bleed", onClick: open ? collapse : expand, padding: 1, ref: expandElementRef, selected: open, text: "\u2026" }) }, "button"), ...rawItems.slice(len - afterLength)];
424
432
  }
425
433
  return rawItems;
426
- }, [collapse, expand, expandButtonProps, gapY, maxLength, open, rawItems]);
427
- return /* @__PURE__ */ jsx(Flex, { as: "nav", "data-ui": "Breadcrumbs", ...restProps, className: composeClassNames(className, breadcrumbs()), gapX, gapY, ref, children: items.map((item, itemIndex) => /* @__PURE__ */ jsxs(Fragment, { children: [
428
- itemIndex > 0 && /* @__PURE__ */ jsx(Box, { "aria-hidden": !0, as: "li", children: separator || /* @__PURE__ */ jsx(Text, { muted: !0, children: "/" }) }),
434
+ }, [collapse, expand, maxLength, open, rawItems, space]);
435
+ return /* @__PURE__ */ jsx(StyledBreadcrumbs, { "data-ui": "Breadcrumbs", ...restProps, ref, children: items.map((item, itemIndex) => /* @__PURE__ */ jsxs(Fragment, { children: [
436
+ itemIndex > 0 && /* @__PURE__ */ jsx(Box, { "aria-hidden": !0, as: "li", paddingX: space, children: separator || /* @__PURE__ */ jsx(Text, { muted: !0, children: "/" }) }),
429
437
  /* @__PURE__ */ jsx(Box, { as: "li", children: item })
430
438
  ] }, itemIndex)) });
431
439
  });
432
440
  Breadcrumbs.displayName = "ForwardRef(Breadcrumbs)";
441
+ function dialogStyle({
442
+ theme
443
+ }) {
444
+ const {
445
+ color
446
+ } = getTheme_v2(theme);
447
+ return {
448
+ "&:not([hidden])": {
449
+ display: "flex"
450
+ },
451
+ top: 0,
452
+ left: 0,
453
+ right: 0,
454
+ bottom: 0,
455
+ alignItems: "center",
456
+ justifyContent: "center",
457
+ outline: "none",
458
+ background: color.backdrop
459
+ };
460
+ }
461
+ function responsiveDialogPositionStyle(props) {
462
+ const {
463
+ media
464
+ } = getTheme_v2(props.theme);
465
+ return _responsive(media, props.$position, (position) => ({
466
+ "&&": {
467
+ position
468
+ }
469
+ }));
470
+ }
471
+ function animationDialogStyle(props) {
472
+ return props.$animate ? css`
473
+ @keyframes zoomIn {
474
+ from {
475
+ opacity: 0;
476
+ transform: scale(0.95);
477
+ }
478
+ to {
479
+ opacity: 1;
480
+ transform: scale(1);
481
+ }
482
+ }
483
+ @keyframes fadeIn {
484
+ from {
485
+ opacity: 0;
486
+ }
487
+ to {
488
+ opacity: 1;
489
+ }
490
+ }
491
+
492
+ animation: fadeIn 200ms ease-out;
493
+ // Animates the dialog card.
494
+ & > [data-ui='DialogCard'] {
495
+ animation: zoomIn 200ms ease-out;
496
+ }
497
+ ` : css``;
498
+ }
433
499
  const DialogContext = createGlobalScopedContext("@sanity/ui/context/dialog", {
434
500
  version: 0
435
501
  });
@@ -439,8 +505,29 @@ function useDialog() {
439
505
  function isTargetWithinScope(boundaryElement, portalElement, target) {
440
506
  return !boundaryElement || !portalElement ? !0 : containsOrEqualsElement(boundaryElement, target) || containsOrEqualsElement(portalElement, target);
441
507
  }
442
- const DialogCard = forwardRef(function(props, forwardedRef) {
443
- const $ = c(43), {
508
+ const StyledDialog = /* @__PURE__ */ styled(Layer).withConfig({
509
+ displayName: "StyledDialog",
510
+ componentId: "sc-4n4xb3-0"
511
+ })(responsivePaddingStyle, dialogStyle, responsiveDialogPositionStyle, animationDialogStyle), DialogContainer = styled(Container).withConfig({
512
+ displayName: "DialogContainer",
513
+ componentId: "sc-4n4xb3-1"
514
+ })`&:not([hidden]){display:flex;}width:100%;height:100%;flex-direction:column;align-items:center;justify-content:center;`, DialogCardRoot = styled(Card).withConfig({
515
+ displayName: "DialogCardRoot",
516
+ componentId: "sc-4n4xb3-2"
517
+ })`&:not([hidden]){display:flex;}width:100%;min-height:0;max-height:100%;overflow:hidden;overflow:clip;`, DialogLayout = styled(Flex).withConfig({
518
+ displayName: "DialogLayout",
519
+ componentId: "sc-4n4xb3-3"
520
+ })`flex:1;min-height:0;width:100%;`, DialogHeader = styled(Box).withConfig({
521
+ displayName: "DialogHeader",
522
+ componentId: "sc-4n4xb3-4"
523
+ })`position:relative;z-index:2;`, DialogContent = styled(Box).withConfig({
524
+ displayName: "DialogContent",
525
+ componentId: "sc-4n4xb3-5"
526
+ })`position:relative;z-index:1;overflow:auto;outline:none;`, DialogFooter = styled(Box).withConfig({
527
+ displayName: "DialogFooter",
528
+ componentId: "sc-4n4xb3-6"
529
+ })`position:relative;z-index:3;`, DialogCard = forwardRef(function(props, forwardedRef) {
530
+ const $ = c(38), {
444
531
  __unstable_autoFocus: autoFocus,
445
532
  __unstable_hideCloseButton: hideCloseButton,
446
533
  children,
@@ -453,73 +540,65 @@ const DialogCard = forwardRef(function(props, forwardedRef) {
453
540
  portal: portalProp,
454
541
  radius: radiusProp,
455
542
  scheme,
456
- shadow: t0,
457
- tone,
543
+ shadow: shadowProp,
458
544
  width: widthProp
459
- } = props, shadowProp = t0 === void 0 ? 4 : t0, portal = usePortal(), portalElement = portalProp ? portal.elements?.[portalProp] || null : portal.element, boundaryElement = useBoundaryElement().element, radius = useArrayProp(radiusProp), shadow = useArrayProp(shadowProp), width = useArrayProp(widthProp), ref = useRef(null), contentRef = useRef(null), layer = useLayer(), {
545
+ } = props, portal = usePortal(), portalElement = portalProp ? portal.elements?.[portalProp] || null : portal.element, boundaryElement = useBoundaryElement().element, radius = useArrayProp(radiusProp), shadow = useArrayProp(shadowProp), width = useArrayProp(widthProp), ref = useRef(null), contentRef = useRef(null), layer = useLayer(), {
460
546
  isTopLayer
461
547
  } = layer, labelId = `${id}_label`, showCloseButton = !!onClose && hideCloseButton === !1, showHeader = !!header || showCloseButton;
548
+ let t0;
549
+ $[0] === Symbol.for("react.memo_cache_sentinel") ? (t0 = () => ref.current, $[0] = t0) : t0 = $[0], useImperativeHandle(forwardedRef, t0);
462
550
  let t1;
463
- $[0] === Symbol.for("react.memo_cache_sentinel") ? (t1 = () => ref.current, $[0] = t1) : t1 = $[0], useImperativeHandle(forwardedRef, t1);
464
- let t2;
465
- $[1] === Symbol.for("react.memo_cache_sentinel") ? (t2 = () => contentRef.current, $[1] = t2) : t2 = $[1], useImperativeHandle(forwardedContentRef, t2);
466
- let t3, t4;
467
- $[2] !== autoFocus ? (t3 = () => {
551
+ $[1] === Symbol.for("react.memo_cache_sentinel") ? (t1 = () => contentRef.current, $[1] = t1) : t1 = $[1], useImperativeHandle(forwardedContentRef, t1);
552
+ let t2, t3;
553
+ $[2] !== autoFocus ? (t2 = () => {
468
554
  autoFocus && ref.current && focusFirstDescendant(ref.current);
469
- }, t4 = [autoFocus, ref], $[2] = autoFocus, $[3] = t3, $[4] = t4) : (t3 = $[3], t4 = $[4]), useEffect(t3, t4);
470
- let t5;
471
- $[5] !== boundaryElement || $[6] !== isTopLayer || $[7] !== onClose || $[8] !== portalElement ? (t5 = (event) => {
555
+ }, t3 = [autoFocus, ref], $[2] = autoFocus, $[3] = t2, $[4] = t3) : (t2 = $[3], t3 = $[4]), useEffect(t2, t3);
556
+ let t4;
557
+ $[5] !== boundaryElement || $[6] !== isTopLayer || $[7] !== onClose || $[8] !== portalElement ? (t4 = (event) => {
472
558
  if (!isTopLayer || !onClose)
473
559
  return;
474
560
  const target = document.activeElement;
475
561
  target && !isTargetWithinScope(boundaryElement, portalElement, target) || event.key === "Escape" && (event.preventDefault(), event.stopPropagation(), onClose());
476
- }, $[5] = boundaryElement, $[6] = isTopLayer, $[7] = onClose, $[8] = portalElement, $[9] = t5) : t5 = $[9], useGlobalKeyDown(t5);
477
- let t6;
478
- $[10] !== boundaryElement || $[11] !== isTopLayer || $[12] !== onClickOutside || $[13] !== portalElement ? (t6 = isTopLayer && onClickOutside && ((event_0) => {
562
+ }, $[5] = boundaryElement, $[6] = isTopLayer, $[7] = onClose, $[8] = portalElement, $[9] = t4) : t4 = $[9], useGlobalKeyDown(t4);
563
+ let t5;
564
+ $[10] !== boundaryElement || $[11] !== isTopLayer || $[12] !== onClickOutside || $[13] !== portalElement ? (t5 = isTopLayer && onClickOutside && ((event_0) => {
479
565
  const target_0 = event_0.target;
480
566
  target_0 && !isTargetWithinScope(boundaryElement, portalElement, target_0) || onClickOutside();
481
- }), $[10] = boundaryElement, $[11] = isTopLayer, $[12] = onClickOutside, $[13] = portalElement, $[14] = t6) : t6 = $[14];
567
+ }), $[10] = boundaryElement, $[11] = isTopLayer, $[12] = onClickOutside, $[13] = portalElement, $[14] = t5) : t5 = $[14];
568
+ let t6;
569
+ $[15] === Symbol.for("react.memo_cache_sentinel") ? (t6 = () => [ref.current], $[15] = t6) : t6 = $[15], useClickOutsideEvent(t5, t6);
482
570
  let t7;
483
- $[15] === Symbol.for("react.memo_cache_sentinel") ? (t7 = () => [ref.current], $[15] = t7) : t7 = $[15], useClickOutsideEvent(t6, t7);
571
+ $[16] !== header || $[17] !== labelId || $[18] !== onClose || $[19] !== showCloseButton || $[20] !== showHeader ? (t7 = showHeader && /* @__PURE__ */ jsx(DialogHeader, { children: /* @__PURE__ */ jsxs(Flex, { align: "flex-start", padding: 3, children: [
572
+ /* @__PURE__ */ jsx(Box, { flex: 1, padding: 2, children: header && /* @__PURE__ */ jsx(Text, { id: labelId, size: 1, weight: "semibold", children: header }) }),
573
+ showCloseButton && /* @__PURE__ */ jsx(Box, { flex: "none", children: /* @__PURE__ */ jsx(Button, { "aria-label": "Close dialog", disabled: !onClose, icon: CloseIcon, mode: "bleed", onClick: onClose, padding: 2 }) })
574
+ ] }) }), $[16] = header, $[17] = labelId, $[18] = onClose, $[19] = showCloseButton, $[20] = showHeader, $[21] = t7) : t7 = $[21];
484
575
  let t8;
485
- $[16] === Symbol.for("react.memo_cache_sentinel") ? (t8 = dialogContainer(), $[16] = t8) : t8 = $[16];
576
+ $[22] !== children ? (t8 = /* @__PURE__ */ jsx(DialogContent, { flex: 1, ref: contentRef, tabIndex: -1, children }), $[22] = children, $[23] = t8) : t8 = $[23];
486
577
  let t9;
487
- $[17] === Symbol.for("react.memo_cache_sentinel") ? (t9 = dialogCardRoot(), $[17] = t9) : t9 = $[17];
578
+ $[24] !== footer ? (t9 = footer && /* @__PURE__ */ jsx(DialogFooter, { children: footer }), $[24] = footer, $[25] = t9) : t9 = $[25];
488
579
  let t10;
489
- $[18] === Symbol.for("react.memo_cache_sentinel") ? (t10 = dialogLayout(), $[18] = t10) : t10 = $[18];
580
+ $[26] !== t7 || $[27] !== t8 || $[28] !== t9 ? (t10 = /* @__PURE__ */ jsxs(DialogLayout, { direction: "column", children: [
581
+ t7,
582
+ t8,
583
+ t9
584
+ ] }), $[26] = t7, $[27] = t8, $[28] = t9, $[29] = t10) : t10 = $[29];
490
585
  let t11;
491
- $[19] !== header || $[20] !== labelId || $[21] !== onClose || $[22] !== showCloseButton || $[23] !== showHeader ? (t11 = showHeader && /* @__PURE__ */ jsx(Box, { className: dialogHeader(), position: "relative", children: /* @__PURE__ */ jsxs(Flex, { align: "flex-start", padding: 3, children: [
492
- /* @__PURE__ */ jsx(Box, { flex: 1, padding: 2, children: header && /* @__PURE__ */ jsx(Text, { id: labelId, size: 1, weight: "semibold", children: header }) }),
493
- showCloseButton && /* @__PURE__ */ jsx(Box, { flex: "none", children: /* @__PURE__ */ jsx(Button, { "aria-label": "Close dialog", disabled: !onClose, icon: CloseIcon, mode: "bleed", onClick: onClose, padding: 2 }) })
494
- ] }) }), $[19] = header, $[20] = labelId, $[21] = onClose, $[22] = showCloseButton, $[23] = showHeader, $[24] = t11) : t11 = $[24];
586
+ $[30] !== radius || $[31] !== scheme || $[32] !== shadow || $[33] !== t10 ? (t11 = /* @__PURE__ */ jsx(DialogCardRoot, { radius, ref, scheme, shadow, children: t10 }), $[30] = radius, $[31] = scheme, $[32] = shadow, $[33] = t10, $[34] = t11) : t11 = $[34];
495
587
  let t12;
496
- $[25] === Symbol.for("react.memo_cache_sentinel") ? (t12 = dialogContent(), $[25] = t12) : t12 = $[25];
497
- let t13;
498
- $[26] !== children ? (t13 = /* @__PURE__ */ jsx(Box, { className: t12, flex: 1, overflow: "auto", position: "relative", ref: contentRef, tabIndex: -1, children }), $[26] = children, $[27] = t13) : t13 = $[27];
499
- let t14;
500
- $[28] !== footer ? (t14 = footer && /* @__PURE__ */ jsx(Box, { className: dialogFooter(), position: "relative", children: footer }), $[28] = footer, $[29] = t14) : t14 = $[29];
501
- let t15;
502
- $[30] !== t11 || $[31] !== t13 || $[32] !== t14 ? (t15 = /* @__PURE__ */ jsxs(Flex, { className: t10, direction: "column", flex: 1, children: [
503
- t11,
504
- t13,
505
- t14
506
- ] }), $[30] = t11, $[31] = t13, $[32] = t14, $[33] = t15) : t15 = $[33];
507
- let t16;
508
- $[34] !== radius || $[35] !== scheme || $[36] !== shadow || $[37] !== t15 || $[38] !== tone ? (t16 = /* @__PURE__ */ jsx(Card, { className: t9, display: "flex", radius, ref, scheme, shadow, tone, children: t15 }), $[34] = radius, $[35] = scheme, $[36] = shadow, $[37] = t15, $[38] = tone, $[39] = t16) : t16 = $[39];
509
- let t17;
510
- return $[40] !== t16 || $[41] !== width ? (t17 = /* @__PURE__ */ jsx(Container, { align: "center", className: t8, "data-ui": "DialogCard", direction: "column", display: "flex", justify: "center", width, children: t16 }), $[40] = t16, $[41] = width, $[42] = t17) : t17 = $[42], t17;
588
+ return $[35] !== t11 || $[36] !== width ? (t12 = /* @__PURE__ */ jsx(DialogContainer, { "data-ui": "DialogCard", width, children: t11 }), $[35] = t11, $[36] = width, $[37] = t12) : t12 = $[37], t12;
511
589
  });
512
590
  DialogCard.displayName = "ForwardRef(DialogCard)";
513
591
  const Dialog = forwardRef(function(props, ref) {
514
- const $ = c(66), context = useDialog();
515
- let _positionProp, _zOffsetProp, cardShadow, children, className, contentRef, footer, header, id, onActivate, onClickOutside, onClose, onFocus, portalProp, restProps, scheme, t0, t1, t2, t3, t4, t5, tone;
592
+ const $ = c(60), dialog = useDialog(), {
593
+ layer
594
+ } = useTheme_v2();
595
+ let _positionProp, _zOffsetProp, children, contentRef, footer, header, id, onActivate, onClickOutside, onClose, onFocus, portalProp, restProps, scheme, t0, t1, t2, t3, t4, t5, t6;
516
596
  $[0] !== props ? ({
517
597
  __unstable_autoFocus: t0,
518
598
  __unstable_hideCloseButton: t1,
519
- animate: t2,
520
- cardRadius: t3,
599
+ cardRadius: t2,
600
+ cardShadow: t3,
521
601
  children,
522
- className,
523
602
  contentRef,
524
603
  footer,
525
604
  header,
@@ -532,15 +611,14 @@ const Dialog = forwardRef(function(props, ref) {
532
611
  portal: portalProp,
533
612
  position: _positionProp,
534
613
  scheme,
535
- shadow: cardShadow,
536
614
  width: t5,
537
615
  zOffset: _zOffsetProp,
538
- tone,
616
+ animate: t6,
539
617
  ...restProps
540
- } = props, $[0] = props, $[1] = _positionProp, $[2] = _zOffsetProp, $[3] = cardShadow, $[4] = children, $[5] = className, $[6] = contentRef, $[7] = footer, $[8] = header, $[9] = id, $[10] = onActivate, $[11] = onClickOutside, $[12] = onClose, $[13] = onFocus, $[14] = portalProp, $[15] = restProps, $[16] = scheme, $[17] = t0, $[18] = t1, $[19] = t2, $[20] = t3, $[21] = t4, $[22] = t5, $[23] = tone) : (_positionProp = $[1], _zOffsetProp = $[2], cardShadow = $[3], children = $[4], className = $[5], contentRef = $[6], footer = $[7], header = $[8], id = $[9], onActivate = $[10], onClickOutside = $[11], onClose = $[12], onFocus = $[13], portalProp = $[14], restProps = $[15], scheme = $[16], t0 = $[17], t1 = $[18], t2 = $[19], t3 = $[20], t4 = $[21], t5 = $[22], tone = $[23]);
541
- const autoFocus = t0 === void 0 ? !0 : t0, hideCloseButton = t1 === void 0 ? !1 : t1, _animate = t2 === void 0 ? !1 : t2, cardRadiusProp = t3 === void 0 ? 4 : t3, padding = t4 === void 0 ? 3 : t4, widthProp = t5 === void 0 ? 0 : t5, positionProp = _positionProp ?? context.position ?? "fixed", zOffsetProp = _zOffsetProp ?? context.zOffset ?? Z_OFFSETS.dialog, animate = usePrefersReducedMotion() ? !1 : _animate, portal = usePortal(), portalElement = portalProp ? portal.elements?.[portalProp] || null : portal.element, boundaryElement = useBoundaryElement().element, cardRadius = useArrayProp(cardRadiusProp), position = useArrayProp(positionProp), width = useArrayProp(widthProp), zOffset = useArrayProp(zOffsetProp), preDivRef = useRef(null), postDivRef = useRef(null), cardRef = useRef(null), focusedElementRef = useRef(null);
542
- let t6;
543
- $[24] !== onFocus ? (t6 = (event) => {
618
+ } = props, $[0] = props, $[1] = _positionProp, $[2] = _zOffsetProp, $[3] = children, $[4] = contentRef, $[5] = footer, $[6] = header, $[7] = id, $[8] = onActivate, $[9] = onClickOutside, $[10] = onClose, $[11] = onFocus, $[12] = portalProp, $[13] = restProps, $[14] = scheme, $[15] = t0, $[16] = t1, $[17] = t2, $[18] = t3, $[19] = t4, $[20] = t5, $[21] = t6) : (_positionProp = $[1], _zOffsetProp = $[2], children = $[3], contentRef = $[4], footer = $[5], header = $[6], id = $[7], onActivate = $[8], onClickOutside = $[9], onClose = $[10], onFocus = $[11], portalProp = $[12], restProps = $[13], scheme = $[14], t0 = $[15], t1 = $[16], t2 = $[17], t3 = $[18], t4 = $[19], t5 = $[20], t6 = $[21]);
619
+ const autoFocus = t0 === void 0 ? !0 : t0, hideCloseButton = t1 === void 0 ? !1 : t1, cardRadiusProp = t2 === void 0 ? 4 : t2, cardShadow = t3 === void 0 ? 3 : t3, paddingProp = t4 === void 0 ? 3 : t4, widthProp = t5 === void 0 ? 0 : t5, _animate = t6 === void 0 ? !1 : t6, positionProp = _positionProp ?? (dialog.position || "fixed"), zOffsetProp = _zOffsetProp ?? (dialog.zOffset || layer.dialog.zOffset), animate = usePrefersReducedMotion() ? !1 : _animate, portal = usePortal(), portalElement = portalProp ? portal.elements?.[portalProp] || null : portal.element, boundaryElement = useBoundaryElement().element, cardRadius = useArrayProp(cardRadiusProp), padding = useArrayProp(paddingProp), position = useArrayProp(positionProp), width = useArrayProp(widthProp), zOffset = useArrayProp(zOffsetProp), preDivRef = useRef(null), postDivRef = useRef(null), cardRef = useRef(null), focusedElementRef = useRef(null);
620
+ let t7;
621
+ $[22] !== onFocus ? (t7 = (event) => {
544
622
  onFocus?.(event);
545
623
  const target = event.target, cardElement = cardRef.current;
546
624
  if (cardElement && target === preDivRef.current) {
@@ -552,10 +630,10 @@ const Dialog = forwardRef(function(props, ref) {
552
630
  return;
553
631
  }
554
632
  isHTMLElement(event.target) && (focusedElementRef.current = event.target);
555
- }, $[24] = onFocus, $[25] = t6) : t6 = $[25];
556
- const handleFocus = t6, labelId = `${id}_label`, rootClickTimeoutRef = useRef(void 0);
557
- let t7;
558
- $[26] !== boundaryElement || $[27] !== portalElement ? (t7 = () => {
633
+ }, $[22] = onFocus, $[23] = t7) : t7 = $[23];
634
+ const handleFocus = t7, labelId = `${id}_label`, rootClickTimeoutRef = useRef(void 0);
635
+ let t8;
636
+ $[24] !== boundaryElement || $[25] !== portalElement ? (t8 = () => {
559
637
  rootClickTimeoutRef.current && clearTimeout(rootClickTimeoutRef.current), rootClickTimeoutRef.current = setTimeout(() => {
560
638
  const activeElement = document.activeElement;
561
639
  if (activeElement && !isTargetWithinScope(boundaryElement, portalElement, activeElement)) {
@@ -568,25 +646,22 @@ const Dialog = forwardRef(function(props, ref) {
568
646
  target_0.focus();
569
647
  }
570
648
  }, 0);
571
- }, $[26] = boundaryElement, $[27] = portalElement, $[28] = t7) : t7 = $[28];
572
- const handleRootClick = t7;
573
- let t8;
574
- $[29] !== className ? (t8 = composeClassNames(className, dialog()), $[29] = className, $[30] = t8) : t8 = $[30];
575
- const t9 = animate ? "" : void 0;
649
+ }, $[24] = boundaryElement, $[25] = portalElement, $[26] = t8) : t8 = $[26];
650
+ const handleRootClick = t8;
651
+ let t9;
652
+ $[27] === Symbol.for("react.memo_cache_sentinel") ? (t9 = /* @__PURE__ */ jsx("div", { ref: preDivRef, tabIndex: 0 }), $[27] = t9) : t9 = $[27];
576
653
  let t10;
577
- $[31] === Symbol.for("react.memo_cache_sentinel") ? (t10 = /* @__PURE__ */ jsx("div", { ref: preDivRef, tabIndex: 0 }), $[31] = t10) : t10 = $[31];
654
+ $[28] !== autoFocus || $[29] !== cardRadius || $[30] !== cardShadow || $[31] !== children || $[32] !== contentRef || $[33] !== footer || $[34] !== header || $[35] !== hideCloseButton || $[36] !== id || $[37] !== onClickOutside || $[38] !== onClose || $[39] !== portalProp || $[40] !== scheme || $[41] !== width ? (t10 = /* @__PURE__ */ jsx(DialogCard, { __unstable_autoFocus: autoFocus, __unstable_hideCloseButton: hideCloseButton, contentRef, footer, header, id, onClickOutside, onClose, portal: portalProp, radius: cardRadius, ref: cardRef, scheme, shadow: cardShadow, width, children }), $[28] = autoFocus, $[29] = cardRadius, $[30] = cardShadow, $[31] = children, $[32] = contentRef, $[33] = footer, $[34] = header, $[35] = hideCloseButton, $[36] = id, $[37] = onClickOutside, $[38] = onClose, $[39] = portalProp, $[40] = scheme, $[41] = width, $[42] = t10) : t10 = $[42];
578
655
  let t11;
579
- $[32] !== autoFocus || $[33] !== cardRadius || $[34] !== cardShadow || $[35] !== children || $[36] !== contentRef || $[37] !== footer || $[38] !== header || $[39] !== hideCloseButton || $[40] !== id || $[41] !== onClickOutside || $[42] !== onClose || $[43] !== portalProp || $[44] !== scheme || $[45] !== tone || $[46] !== width ? (t11 = /* @__PURE__ */ jsx(DialogCard, { __unstable_autoFocus: autoFocus, __unstable_hideCloseButton: hideCloseButton, contentRef, footer, header, id, onClickOutside, onClose, portal: portalProp, radius: cardRadius, ref: cardRef, scheme, shadow: cardShadow, tone, width, children }), $[32] = autoFocus, $[33] = cardRadius, $[34] = cardShadow, $[35] = children, $[36] = contentRef, $[37] = footer, $[38] = header, $[39] = hideCloseButton, $[40] = id, $[41] = onClickOutside, $[42] = onClose, $[43] = portalProp, $[44] = scheme, $[45] = tone, $[46] = width, $[47] = t11) : t11 = $[47];
656
+ $[43] === Symbol.for("react.memo_cache_sentinel") ? (t11 = /* @__PURE__ */ jsx("div", { ref: postDivRef, tabIndex: 0 }), $[43] = t11) : t11 = $[43];
580
657
  let t12;
581
- $[48] === Symbol.for("react.memo_cache_sentinel") ? (t12 = /* @__PURE__ */ jsx("div", { ref: postDivRef, tabIndex: 0 }), $[48] = t12) : t12 = $[48];
582
- let t13;
583
- $[49] !== handleFocus || $[50] !== handleRootClick || $[51] !== id || $[52] !== labelId || $[53] !== onActivate || $[54] !== padding || $[55] !== position || $[56] !== ref || $[57] !== restProps || $[58] !== t11 || $[59] !== t8 || $[60] !== t9 || $[61] !== zOffset ? (t13 = /* @__PURE__ */ jsxs(Layer, { ...restProps, "aria-labelledby": labelId, "aria-modal": !0, className: t8, "data-animate": t9, "data-ui": "Dialog", display: "flex", id, onActivate, onClick: handleRootClick, onFocus: handleFocus, padding, position, ref, role: "dialog", zOffset, children: [
658
+ $[44] !== animate || $[45] !== handleFocus || $[46] !== handleRootClick || $[47] !== id || $[48] !== labelId || $[49] !== onActivate || $[50] !== padding || $[51] !== position || $[52] !== ref || $[53] !== restProps || $[54] !== t10 || $[55] !== zOffset ? (t12 = /* @__PURE__ */ jsxs(StyledDialog, { ...restProps, $animate: animate, $padding: padding, $position: position, "aria-labelledby": labelId, "aria-modal": !0, "data-ui": "Dialog", id, onActivate, onClick: handleRootClick, onFocus: handleFocus, ref, role: "dialog", zOffset, children: [
659
+ t9,
584
660
  t10,
585
- t11,
586
- t12
587
- ] }), $[49] = handleFocus, $[50] = handleRootClick, $[51] = id, $[52] = labelId, $[53] = onActivate, $[54] = padding, $[55] = position, $[56] = ref, $[57] = restProps, $[58] = t11, $[59] = t8, $[60] = t9, $[61] = zOffset, $[62] = t13) : t13 = $[62];
588
- let t14;
589
- return $[63] !== portalProp || $[64] !== t13 ? (t14 = /* @__PURE__ */ jsx(Portal, { __unstable_name: portalProp, children: t13 }), $[63] = portalProp, $[64] = t13, $[65] = t14) : t14 = $[65], t14;
661
+ t11
662
+ ] }), $[44] = animate, $[45] = handleFocus, $[46] = handleRootClick, $[47] = id, $[48] = labelId, $[49] = onActivate, $[50] = padding, $[51] = position, $[52] = ref, $[53] = restProps, $[54] = t10, $[55] = zOffset, $[56] = t12) : t12 = $[56];
663
+ let t13;
664
+ return $[57] !== portalProp || $[58] !== t12 ? (t13 = /* @__PURE__ */ jsx(Portal, { __unstable_name: portalProp, children: t12 }), $[57] = portalProp, $[58] = t12, $[59] = t13) : t13 = $[59], t13;
590
665
  });
591
666
  Dialog.displayName = "ForwardRef(Dialog)";
592
667
  function DialogProvider(props) {
@@ -607,7 +682,7 @@ function DialogProvider(props) {
607
682
  }
608
683
  DialogProvider.displayName = "DialogProvider";
609
684
  const MenuButton = forwardRef(function(props, forwardedRef) {
610
- const $ = c(63), {
685
+ const $ = c(62), {
611
686
  __unstable_disableRestoreFocusOnClose: t0,
612
687
  boundaryElement: deprecated_boundaryElement,
613
688
  button: buttonProp,
@@ -706,33 +781,25 @@ const MenuButton = forwardRef(function(props, forwardedRef) {
706
781
  shouldFocus
707
782
  }), $[28] = buttonElement, $[29] = handleBlur, $[30] = handleItemClick, $[31] = handleMenuClickOutside, $[32] = handleMenuEscape, $[33] = id, $[34] = menuProp, $[35] = shouldFocus, $[36] = t17) : t17 = $[36];
708
783
  const menu = t17;
709
- let t18;
710
- bb0: {
711
- if (!buttonProp) {
712
- t18 = null;
713
- break bb0;
714
- }
715
- const t192 = buttonProp.props.selected ?? open;
716
- let t202;
717
- $[37] !== buttonProp || $[38] !== handleMouseDown || $[39] !== id || $[40] !== open || $[41] !== t192 ? (t202 = cloneElement(buttonProp, {
718
- "data-ui": "MenuButton",
719
- id,
720
- onClick: handleButtonClick,
721
- onKeyDown: handleButtonKeyDown,
722
- onMouseDown: handleMouseDown,
723
- "aria-haspopup": !0,
724
- "aria-expanded": open,
725
- ref: setButtonElement,
726
- selected: t192
727
- }), $[37] = buttonProp, $[38] = handleMouseDown, $[39] = id, $[40] = open, $[41] = t192, $[42] = t202) : t202 = $[42], t18 = t202;
728
- }
784
+ let t18, t19;
785
+ $[37] !== buttonProp || $[38] !== handleMouseDown || $[39] !== id || $[40] !== open ? (t19 = buttonProp && cloneElement(buttonProp, {
786
+ "data-ui": "MenuButton",
787
+ id,
788
+ onClick: handleButtonClick,
789
+ onKeyDown: handleButtonKeyDown,
790
+ onMouseDown: handleMouseDown,
791
+ "aria-haspopup": !0,
792
+ "aria-expanded": open,
793
+ ref: setButtonElement,
794
+ selected: buttonProp.props.selected ?? open
795
+ }), $[37] = buttonProp, $[38] = handleMouseDown, $[39] = id, $[40] = open, $[41] = t19) : t19 = $[41], t18 = t19;
729
796
  const button = t18;
730
- let t19, t20;
731
- $[43] !== buttonElement ? (t19 = () => buttonElement, t20 = [buttonElement], $[43] = buttonElement, $[44] = t19, $[45] = t20) : (t19 = $[44], t20 = $[45]), useImperativeHandle(forwardedRef, t19, t20);
732
- let t21, t22;
733
- $[46] !== popover ? (t22 = popover || {}, $[46] = popover, $[47] = t22) : t22 = $[47];
734
- let t23;
735
- $[48] !== deprecated_boundaryElement || $[49] !== deprecated_placement || $[50] !== deprecated_popoverRadius || $[51] !== deprecated_popoverScheme || $[52] !== deprecated_portal || $[53] !== deprecated_preventOverflow || $[54] !== t22 ? (t23 = {
797
+ let t20, t21;
798
+ $[42] !== buttonElement ? (t20 = () => buttonElement, t21 = [buttonElement], $[42] = buttonElement, $[43] = t20, $[44] = t21) : (t20 = $[43], t21 = $[44]), useImperativeHandle(forwardedRef, t20, t21);
799
+ let t22, t23;
800
+ $[45] !== popover ? (t23 = popover || {}, $[45] = popover, $[46] = t23) : t23 = $[46];
801
+ let t24;
802
+ $[47] !== deprecated_boundaryElement || $[48] !== deprecated_placement || $[49] !== deprecated_popoverRadius || $[50] !== deprecated_popoverScheme || $[51] !== deprecated_portal || $[52] !== deprecated_preventOverflow || $[53] !== t23 ? (t24 = {
736
803
  boundaryElement: deprecated_boundaryElement,
737
804
  overflow: "auto",
738
805
  placement: deprecated_placement,
@@ -740,31 +807,73 @@ const MenuButton = forwardRef(function(props, forwardedRef) {
740
807
  preventOverflow: deprecated_preventOverflow,
741
808
  radius: deprecated_popoverRadius,
742
809
  scheme: deprecated_popoverScheme,
743
- ...t22
744
- }, $[48] = deprecated_boundaryElement, $[49] = deprecated_placement, $[50] = deprecated_popoverRadius, $[51] = deprecated_popoverScheme, $[52] = deprecated_portal, $[53] = deprecated_preventOverflow, $[54] = t22, $[55] = t23) : t23 = $[55], t21 = t23;
745
- const popoverProps = t21;
746
- let t24;
747
- $[56] !== button ? (t24 = button || /* @__PURE__ */ jsx(Fragment$1, {}), $[56] = button, $[57] = t24) : t24 = $[57];
810
+ ...t23
811
+ }, $[47] = deprecated_boundaryElement, $[48] = deprecated_placement, $[49] = deprecated_popoverRadius, $[50] = deprecated_popoverScheme, $[51] = deprecated_portal, $[52] = deprecated_preventOverflow, $[53] = t23, $[54] = t24) : t24 = $[54], t22 = t24;
812
+ const popoverProps = t22;
748
813
  let t25;
749
- return $[58] !== menu || $[59] !== open || $[60] !== popoverProps || $[61] !== t24 ? (t25 = /* @__PURE__ */ jsx(Popover, { "data-ui": "MenuButton__popover", ...popoverProps, content: menu, open, children: t24 }), $[58] = menu, $[59] = open, $[60] = popoverProps, $[61] = t24, $[62] = t25) : t25 = $[62], t25;
814
+ $[55] !== button ? (t25 = button || /* @__PURE__ */ jsx(Fragment$1, {}), $[55] = button, $[56] = t25) : t25 = $[56];
815
+ let t26;
816
+ return $[57] !== menu || $[58] !== open || $[59] !== popoverProps || $[60] !== t25 ? (t26 = /* @__PURE__ */ jsx(Popover, { "data-ui": "MenuButton__popover", ...popoverProps, content: menu, open, children: t25 }), $[57] = menu, $[58] = open, $[59] = popoverProps, $[60] = t25, $[61] = t26) : t26 = $[61], t26;
750
817
  });
751
818
  MenuButton.displayName = "ForwardRef(MenuButton)";
752
819
  function _temp$2(v) {
753
820
  return !v;
754
821
  }
755
- const Skeleton = forwardRef(function(props, ref) {
756
- const $ = c(18);
757
- let className, delay, radius, restProps, t0;
822
+ const keyframe = keyframes`
823
+ 0% {
824
+ background-position: 100%;
825
+ }
826
+ 100% {
827
+ background-position: -100%;
828
+ }
829
+ `, animation = css`
830
+ background-image: linear-gradient(
831
+ to right,
832
+ var(--card-skeleton-color-from),
833
+ var(--card-skeleton-color-to),
834
+ var(--card-skeleton-color-from),
835
+ var(--card-skeleton-color-from),
836
+ var(--card-skeleton-color-from)
837
+ );
838
+ background-position: 100%;
839
+ background-size: 200% 100%;
840
+ background-attachment: fixed;
841
+ animation-name: ${keyframe};
842
+ animation-timing-function: ease-in-out;
843
+ animation-iteration-count: infinite;
844
+ animation-duration: 2000ms;
845
+ `, skeletonStyle = css`
846
+ opacity: ${({
847
+ $visible
848
+ }) => $visible ? 1 : 0};
849
+ transition: opacity 200ms ease-in;
850
+
851
+ @media screen and (prefers-reduced-motion: no-preference) {
852
+ ${({
853
+ $animated
854
+ }) => $animated ? animation : css`
855
+ background-color: var(--card-skeleton-color-from);
856
+ `}
857
+ }
858
+
859
+ @media screen and (prefers-reduced-motion: reduce) {
860
+ background-color: var(--card-skeleton-color-from);
861
+ }
862
+ `, StyledSkeleton$1 = /* @__PURE__ */ styled(Box).withConfig({
863
+ displayName: "StyledSkeleton",
864
+ componentId: "sc-ebtpni-0"
865
+ })(responsiveRadiusStyle, skeletonStyle), Skeleton = forwardRef(function(props, ref) {
866
+ const $ = c(14);
867
+ let delay, radius, restProps, t0;
758
868
  $[0] !== props ? ({
759
869
  animated: t0,
760
- className,
761
870
  delay,
762
871
  radius,
763
872
  ...restProps
764
- } = props, $[0] = props, $[1] = className, $[2] = delay, $[3] = radius, $[4] = restProps, $[5] = t0) : (className = $[1], delay = $[2], radius = $[3], restProps = $[4], t0 = $[5]);
873
+ } = props, $[0] = props, $[1] = delay, $[2] = radius, $[3] = restProps, $[4] = t0) : (delay = $[1], radius = $[2], restProps = $[3], t0 = $[4]);
765
874
  const animated = t0 === void 0 ? !1 : t0, [visible, setVisible] = useState(!delay);
766
875
  let t1, t2;
767
- $[6] !== delay ? (t1 = () => {
876
+ $[5] !== delay ? (t1 = () => {
768
877
  if (!delay)
769
878
  return setVisible(!0);
770
879
  const timeout = setTimeout(() => {
@@ -773,82 +882,75 @@ const Skeleton = forwardRef(function(props, ref) {
773
882
  return () => {
774
883
  clearTimeout(timeout);
775
884
  };
776
- }, t2 = [delay], $[6] = delay, $[7] = t1, $[8] = t2) : (t1 = $[7], t2 = $[8]), useEffect(t1, t2);
777
- let t3;
778
- $[9] !== className || $[10] !== radius ? (t3 = composeClassNames(className, skeleton({
779
- radius
780
- })), $[9] = className, $[10] = radius, $[11] = t3) : t3 = $[11];
781
- const t4 = animated ? "" : void 0, t5 = visible ? "" : void 0;
782
- let t6;
783
- return $[12] !== ref || $[13] !== restProps || $[14] !== t3 || $[15] !== t4 || $[16] !== t5 ? (t6 = /* @__PURE__ */ jsx(Box, { "data-ui": "Skeleton", ...restProps, className: t3, "data-animated": t4, "data-visible": t5, ref }), $[12] = ref, $[13] = restProps, $[14] = t3, $[15] = t4, $[16] = t5, $[17] = t6) : t6 = $[17], t6;
885
+ }, t2 = [delay], $[5] = delay, $[6] = t1, $[7] = t2) : (t1 = $[6], t2 = $[7]), useEffect(t1, t2);
886
+ const t3 = useArrayProp(radius);
887
+ let t4;
888
+ return $[8] !== animated || $[9] !== ref || $[10] !== restProps || $[11] !== t3 || $[12] !== visible ? (t4 = /* @__PURE__ */ jsx(StyledSkeleton$1, { ...restProps, $animated: animated, $radius: t3, $visible: visible, ref }), $[8] = animated, $[9] = ref, $[10] = restProps, $[11] = t3, $[12] = visible, $[13] = t4) : t4 = $[13], t4;
784
889
  });
785
890
  Skeleton.displayName = "ForwardRef(Skeleton)";
786
- const TextSkeleton = forwardRef(function(props, ref) {
787
- const $ = c(11);
788
- let className, restProps, t0;
891
+ const StyledSkeleton = /* @__PURE__ */ styled(Skeleton).withConfig({
892
+ displayName: "StyledSkeleton",
893
+ componentId: "sc-2p7a1v-0"
894
+ })((props) => {
895
+ const {
896
+ $size,
897
+ $style
898
+ } = props, {
899
+ font,
900
+ media
901
+ } = getTheme_v2(props.theme), fontStyle = font[$style];
902
+ return _responsive(media, $size, (sizeIndex) => {
903
+ const fontSize = fontStyle.sizes[sizeIndex];
904
+ return {
905
+ height: fontSize.lineHeight - fontSize.ascenderHeight - fontSize.descenderHeight
906
+ };
907
+ });
908
+ }), TextSkeleton = forwardRef(function(props, ref) {
909
+ const $ = c(7);
910
+ let restProps, t0;
789
911
  $[0] !== props ? ({
790
- className,
791
912
  size: t0,
792
913
  ...restProps
793
- } = props, $[0] = props, $[1] = className, $[2] = restProps, $[3] = t0) : (className = $[1], restProps = $[2], t0 = $[3]);
794
- const size = t0 === void 0 ? 2 : t0;
914
+ } = props, $[0] = props, $[1] = restProps, $[2] = t0) : (restProps = $[1], t0 = $[2]);
915
+ const $size = useArrayProp(t0 === void 0 ? 2 : t0);
795
916
  let t1;
796
- $[4] !== className || $[5] !== size ? (t1 = composeClassNames(className, textSkeleton({
797
- size
798
- })), $[4] = className, $[5] = size, $[6] = t1) : t1 = $[6];
799
- let t2;
800
- return $[7] !== ref || $[8] !== restProps || $[9] !== t1 ? (t2 = /* @__PURE__ */ jsx(Skeleton, { "data-ui": "TextSkeleton", ...restProps, className: t1, ref }), $[7] = ref, $[8] = restProps, $[9] = t1, $[10] = t2) : t2 = $[10], t2;
917
+ return $[3] !== $size || $[4] !== ref || $[5] !== restProps ? (t1 = /* @__PURE__ */ jsx(StyledSkeleton, { ...restProps, $size, ref, $style: "text" }), $[3] = $size, $[4] = ref, $[5] = restProps, $[6] = t1) : t1 = $[6], t1;
801
918
  });
802
919
  TextSkeleton.displayName = "ForwardRef(TextSkeleton)";
803
920
  const LabelSkeleton = forwardRef(function(props, ref) {
804
- const $ = c(11);
805
- let className, restProps, t0;
921
+ const $ = c(7);
922
+ let restProps, t0;
806
923
  $[0] !== props ? ({
807
- className,
808
924
  size: t0,
809
925
  ...restProps
810
- } = props, $[0] = props, $[1] = className, $[2] = restProps, $[3] = t0) : (className = $[1], restProps = $[2], t0 = $[3]);
811
- const size = t0 === void 0 ? 2 : t0;
926
+ } = props, $[0] = props, $[1] = restProps, $[2] = t0) : (restProps = $[1], t0 = $[2]);
927
+ const $size = useArrayProp(t0 === void 0 ? 2 : t0);
812
928
  let t1;
813
- $[4] !== className || $[5] !== size ? (t1 = composeClassNames(className, labelSkeleton({
814
- size
815
- })), $[4] = className, $[5] = size, $[6] = t1) : t1 = $[6];
816
- let t2;
817
- return $[7] !== ref || $[8] !== restProps || $[9] !== t1 ? (t2 = /* @__PURE__ */ jsx(Skeleton, { "data-ui": "LabelSkeleton", ...restProps, className: t1, ref }), $[7] = ref, $[8] = restProps, $[9] = t1, $[10] = t2) : t2 = $[10], t2;
929
+ return $[3] !== $size || $[4] !== ref || $[5] !== restProps ? (t1 = /* @__PURE__ */ jsx(StyledSkeleton, { ...restProps, $size, ref, $style: "label" }), $[3] = $size, $[4] = ref, $[5] = restProps, $[6] = t1) : t1 = $[6], t1;
818
930
  });
819
931
  LabelSkeleton.displayName = "ForwardRef(LabelSkeleton)";
820
932
  const HeadingSkeleton = forwardRef(function(props, ref) {
821
- const $ = c(11);
822
- let className, restProps, t0;
933
+ const $ = c(7);
934
+ let restProps, t0;
823
935
  $[0] !== props ? ({
824
- className,
825
936
  size: t0,
826
937
  ...restProps
827
- } = props, $[0] = props, $[1] = className, $[2] = restProps, $[3] = t0) : (className = $[1], restProps = $[2], t0 = $[3]);
828
- const size = t0 === void 0 ? 2 : t0;
938
+ } = props, $[0] = props, $[1] = restProps, $[2] = t0) : (restProps = $[1], t0 = $[2]);
939
+ const $size = useArrayProp(t0 === void 0 ? 2 : t0);
829
940
  let t1;
830
- $[4] !== className || $[5] !== size ? (t1 = composeClassNames(className, headingSkeleton({
831
- size
832
- })), $[4] = className, $[5] = size, $[6] = t1) : t1 = $[6];
833
- let t2;
834
- return $[7] !== ref || $[8] !== restProps || $[9] !== t1 ? (t2 = /* @__PURE__ */ jsx(Skeleton, { ...restProps, className: t1, ref }), $[7] = ref, $[8] = restProps, $[9] = t1, $[10] = t2) : t2 = $[10], t2;
941
+ return $[3] !== $size || $[4] !== ref || $[5] !== restProps ? (t1 = /* @__PURE__ */ jsx(StyledSkeleton, { ...restProps, $size, ref, $style: "heading" }), $[3] = $size, $[4] = ref, $[5] = restProps, $[6] = t1) : t1 = $[6], t1;
835
942
  });
836
943
  HeadingSkeleton.displayName = "ForwardRef(HeadingSkeleton)";
837
944
  const CodeSkeleton = forwardRef(function(props, ref) {
838
- const $ = c(11);
839
- let className, restProps, t0;
945
+ const $ = c(7);
946
+ let restProps, t0;
840
947
  $[0] !== props ? ({
841
- className,
842
948
  size: t0,
843
949
  ...restProps
844
- } = props, $[0] = props, $[1] = className, $[2] = restProps, $[3] = t0) : (className = $[1], restProps = $[2], t0 = $[3]);
845
- const size = t0 === void 0 ? 2 : t0;
950
+ } = props, $[0] = props, $[1] = restProps, $[2] = t0) : (restProps = $[1], t0 = $[2]);
951
+ const $size = useArrayProp(t0 === void 0 ? 2 : t0);
846
952
  let t1;
847
- $[4] !== className || $[5] !== size ? (t1 = composeClassNames(className, codeSkeleton({
848
- size
849
- })), $[4] = className, $[5] = size, $[6] = t1) : t1 = $[6];
850
- let t2;
851
- return $[7] !== ref || $[8] !== restProps || $[9] !== t1 ? (t2 = /* @__PURE__ */ jsx(Skeleton, { ...restProps, className: t1, ref }), $[7] = ref, $[8] = restProps, $[9] = t1, $[10] = t2) : t2 = $[10], t2;
953
+ return $[3] !== $size || $[4] !== ref || $[5] !== restProps ? (t1 = /* @__PURE__ */ jsx(StyledSkeleton, { ...restProps, $size, ref, $style: "code" }), $[3] = $size, $[4] = ref, $[5] = restProps, $[6] = t1) : t1 = $[6], t1;
852
954
  });
853
955
  CodeSkeleton.displayName = "ForwardRef(CodeSkeleton)";
854
956
  const TabPanel = forwardRef(function(props, ref) {
@@ -863,12 +965,7 @@ const TabPanel = forwardRef(function(props, ref) {
863
965
  return $[3] !== flex || $[4] !== props.children || $[5] !== ref || $[6] !== restProps || $[7] !== t0 ? (t1 = /* @__PURE__ */ jsx(Box, { "data-ui": "TabPanel", ...restProps, flex, ref, role: "tabpanel", tabIndex: t0, children: props.children }), $[3] = flex, $[4] = props.children, $[5] = ref, $[6] = restProps, $[7] = t0, $[8] = t1) : t1 = $[8], t1;
864
966
  });
865
967
  TabPanel.displayName = "ForwardRef(TabPanel)";
866
- const ROLES = {
867
- error: "alert",
868
- warning: "alert",
869
- success: "alert",
870
- info: "alert"
871
- }, STATUS_CARD_TONE = {
968
+ const LOADING_BAR_HEIGHT = 2, STATUS_CARD_TONE = {
872
969
  error: "critical",
873
970
  warning: "caution",
874
971
  success: "positive",
@@ -878,9 +975,34 @@ const ROLES = {
878
975
  warning: "caution",
879
976
  success: "positive",
880
977
  info: "neutral"
978
+ }, TextBox = styled(Flex).withConfig({
979
+ displayName: "TextBox",
980
+ componentId: "sc-1rr7rxo-0"
981
+ })`overflow-x:auto;`, StyledToast = styled(Card).withConfig({
982
+ displayName: "StyledToast",
983
+ componentId: "sc-1rr7rxo-1"
984
+ })`pointer-events:all;width:100%;position:relative;overflow:hidden;overflow:clip;&[data-has-duration]{padding-bottom:calc(${LOADING_BAR_HEIGHT}px / 2);}`, LoadingBar = styled.div.withConfig({
985
+ displayName: "LoadingBar",
986
+ componentId: "sc-1rr7rxo-2"
987
+ })`display:flex;position:absolute;bottom:0px;top:0px;left:0px;right:0px;pointer-events:none;z-index:-1;overflow:hidden;overflow:clip;background:transparent;align-items:flex-end;will-change:opacity;`, LoadingBarMask = styled(Card).withConfig({
988
+ displayName: "LoadingBarMask",
989
+ componentId: "sc-1rr7rxo-3"
990
+ })`position:absolute;top:0;left:-${LOADING_BAR_HEIGHT}px;right:-${LOADING_BAR_HEIGHT}px;bottom:${LOADING_BAR_HEIGHT}px;z-index:1;`, LoadingBarProgress = styled(Card).withConfig({
991
+ displayName: "LoadingBarProgress",
992
+ componentId: "sc-1rr7rxo-4"
993
+ })`display:block;height:100%;width:100%;transform-origin:0% 50%;background-color:${(props) => {
994
+ const {
995
+ color
996
+ } = getTheme_v2(props.theme);
997
+ return color.button.default[props.tone].enabled.bg;
998
+ }};`, ROLES = {
999
+ error: "alert",
1000
+ warning: "alert",
1001
+ success: "alert",
1002
+ info: "alert"
881
1003
  }, LONG_ENOUGH_BUT_NOT_TOO_LONG = 1e3 * 60 * 60 * 24 * 24;
882
1004
  function Toast(props) {
883
- const $ = c(51);
1005
+ const $ = c(50);
884
1006
  let closable, description, duration, onClose, restProps, status, t0, title, updatedAt;
885
1007
  $[0] !== props ? ({
886
1008
  closable,
@@ -911,32 +1033,29 @@ function Toast(props) {
911
1033
  const animate = t3;
912
1034
  let t4;
913
1035
  $[14] === Symbol.for("react.memo_cache_sentinel") ? (t4 = ["hidden", "slideOut"], $[14] = t4) : t4 = $[14];
914
- const exit = t4;
915
- let t5;
916
- $[15] === Symbol.for("react.memo_cache_sentinel") ? (t5 = toast(), $[15] = t5) : t5 = $[15];
917
- const t6 = hasDuration ? "" : void 0;
1036
+ const exit = t4, t5 = hasDuration ? "" : void 0;
1037
+ let t6;
1038
+ $[15] !== title ? (t6 = title && /* @__PURE__ */ jsx(Text, { size: 1, weight: "medium", children: title }), $[15] = title, $[16] = t6) : t6 = $[16];
918
1039
  let t7;
919
- $[16] !== title ? (t7 = title && /* @__PURE__ */ jsx(Text, { size: 1, weight: "medium", children: title }), $[16] = title, $[17] = t7) : t7 = $[17];
1040
+ $[17] !== description || $[18] !== transition ? (t7 = description && /* @__PURE__ */ jsx(MotionText, { muted: !0, size: 1, variants: content, transition, children: description }), $[17] = description, $[18] = transition, $[19] = t7) : t7 = $[19];
920
1041
  let t8;
921
- $[18] !== description || $[19] !== transition ? (t8 = description && /* @__PURE__ */ jsx(MotionText, { muted: !0, size: 1, variants: content, transition, children: description }), $[18] = description, $[19] = transition, $[20] = t8) : t8 = $[20];
1042
+ $[20] !== t6 || $[21] !== t7 ? (t8 = /* @__PURE__ */ jsx(TextBox, { flex: 1, padding: 3, children: /* @__PURE__ */ jsxs(Stack, { space: 3, children: [
1043
+ t6,
1044
+ t7
1045
+ ] }) }), $[20] = t6, $[21] = t7, $[22] = t8) : t8 = $[22];
922
1046
  let t9;
923
- $[21] !== t7 || $[22] !== t8 ? (t9 = /* @__PURE__ */ jsx(Flex, { flex: 1, overflowX: "auto", padding: 3, children: /* @__PURE__ */ jsxs(Stack, { space: 3, children: [
924
- t7,
925
- t8
926
- ] }) }), $[21] = t7, $[22] = t8, $[23] = t9) : t9 = $[23];
927
- let t10;
928
- $[24] !== buttonTone || $[25] !== closable || $[26] !== onClose ? (t10 = closable && /* @__PURE__ */ jsx(Box, { padding: 1, children: /* @__PURE__ */ jsx(Button, { as: "button", icon: CloseIcon, mode: "bleed", padding: 2, tone: buttonTone, onClick: onClose, style: {
1047
+ $[23] !== buttonTone || $[24] !== closable || $[25] !== onClose ? (t9 = closable && /* @__PURE__ */ jsx(Box, { padding: 1, children: /* @__PURE__ */ jsx(Button, { as: "button", icon: CloseIcon, mode: "bleed", padding: 2, tone: buttonTone, onClick: onClose, style: {
929
1048
  verticalAlign: "top"
930
- } }) }), $[24] = buttonTone, $[25] = closable, $[26] = onClose, $[27] = t10) : t10 = $[27];
1049
+ } }) }), $[23] = buttonTone, $[24] = closable, $[25] = onClose, $[26] = t9) : t9 = $[26];
1050
+ let t10;
1051
+ $[27] !== t8 || $[28] !== t9 || $[29] !== transition ? (t10 = /* @__PURE__ */ jsxs(MotionFlex, { align: "flex-start", variants: content, transition, children: [
1052
+ t8,
1053
+ t9
1054
+ ] }), $[27] = t8, $[28] = t9, $[29] = transition, $[30] = t10) : t10 = $[30];
931
1055
  let t11;
932
- $[28] !== t10 || $[29] !== t9 || $[30] !== transition ? (t11 = /* @__PURE__ */ jsxs(MotionFlex, { align: "flex-start", variants: content, transition, children: [
933
- t9,
934
- t10
935
- ] }), $[28] = t10, $[29] = t9, $[30] = transition, $[31] = t11) : t11 = $[31];
936
- let t12;
937
- $[32] !== cardTone || $[33] !== duration || $[34] !== hasDuration || $[35] !== onClose || $[36] !== radius || $[37] !== transition || $[38] !== updatedAt || $[39] !== visualDuration ? (t12 = hasDuration && /* @__PURE__ */ jsxs(MotionBox, { className: toastLoadingBar(), variants: content, transition, children: [
938
- /* @__PURE__ */ jsx(Card, { className: toastLoadingBarMask(), tone: cardTone, radius }),
939
- /* @__PURE__ */ jsx(MotionCard, { className: toastLoadingBarProgress(), tone: cardTone, initial: {
1056
+ $[31] !== cardTone || $[32] !== duration || $[33] !== hasDuration || $[34] !== onClose || $[35] !== radius || $[36] !== transition || $[37] !== updatedAt || $[38] !== visualDuration ? (t11 = hasDuration && /* @__PURE__ */ jsxs(MotionLoadingBar, { variants: content, transition, children: [
1057
+ /* @__PURE__ */ jsx(LoadingBarMask, { tone: cardTone, radius }),
1058
+ /* @__PURE__ */ jsx(MotionLoadingBarProgress, { tone: cardTone, initial: {
940
1059
  scaleX: 0
941
1060
  }, animate: {
942
1061
  scaleX: 1
@@ -945,12 +1064,12 @@ function Toast(props) {
945
1064
  duration: duration / 1e3,
946
1065
  ease: "linear"
947
1066
  }, onAnimationComplete: onClose }, `progress-${updatedAt}`)
948
- ] }), $[32] = cardTone, $[33] = duration, $[34] = hasDuration, $[35] = onClose, $[36] = radius, $[37] = transition, $[38] = updatedAt, $[39] = visualDuration, $[40] = t12) : t12 = $[40];
949
- let t13;
950
- return $[41] !== cardTone || $[42] !== radius || $[43] !== restProps || $[44] !== role || $[45] !== t11 || $[46] !== t12 || $[47] !== t6 || $[48] !== transition || $[49] !== visualDuration ? (t13 = /* @__PURE__ */ jsxs(MotionCard, { as: "li", className: t5, "data-ui": "Toast", role, ...restProps, "data-has-duration": t6, custom: visualDuration, radius, shadow: 2, tone: cardTone, layout: "position", variants: container, initial, animate, exit, transition, position: "relative", children: [
951
- t11,
952
- t12
953
- ] }), $[41] = cardTone, $[42] = radius, $[43] = restProps, $[44] = role, $[45] = t11, $[46] = t12, $[47] = t6, $[48] = transition, $[49] = visualDuration, $[50] = t13) : t13 = $[50], t13;
1067
+ ] }), $[31] = cardTone, $[32] = duration, $[33] = hasDuration, $[34] = onClose, $[35] = radius, $[36] = transition, $[37] = updatedAt, $[38] = visualDuration, $[39] = t11) : t11 = $[39];
1068
+ let t12;
1069
+ return $[40] !== cardTone || $[41] !== radius || $[42] !== restProps || $[43] !== role || $[44] !== t10 || $[45] !== t11 || $[46] !== t5 || $[47] !== transition || $[48] !== visualDuration ? (t12 = /* @__PURE__ */ jsxs(MotionToast, { "data-ui": "Toast", role, ...restProps, "data-has-duration": t5, custom: visualDuration, radius, shadow: 2, tone: cardTone, forwardedAs: "li", layout: "position", variants: container, initial, animate, exit, transition, children: [
1070
+ t10,
1071
+ t11
1072
+ ] }), $[40] = cardTone, $[41] = radius, $[42] = restProps, $[43] = role, $[44] = t10, $[45] = t11, $[46] = t5, $[47] = transition, $[48] = visualDuration, $[49] = t12) : t12 = $[49], t12;
954
1073
  }
955
1074
  Toast.displayName = "Toast";
956
1075
  const container = {
@@ -990,7 +1109,7 @@ const container = {
990
1109
  visible: {
991
1110
  opacity: 1
992
1111
  }
993
- }, MotionCard = motion.create(Card), MotionFlex = motion.create(Flex), MotionText = motion.create(Text), MotionBox = motion.create(Box);
1112
+ }, MotionToast = motion.create(StyledToast), MotionFlex = motion.create(Flex), MotionText = motion.create(Text), MotionLoadingBar = motion.create(LoadingBar), MotionLoadingBarProgress = motion.create(LoadingBarProgress);
994
1113
  function useMounted() {
995
1114
  return useSyncExternalStore(subscribe, _temp$1, _temp2);
996
1115
  }
@@ -1003,7 +1122,7 @@ function _temp$1() {
1003
1122
  const subscribe = () => () => {
1004
1123
  }, ToastContext = createGlobalScopedContext("@sanity/ui/context/toast", null);
1005
1124
  function ToastLayer(props) {
1006
- const $ = c(10), {
1125
+ const $ = c(9), {
1007
1126
  children,
1008
1127
  padding: t0,
1009
1128
  paddingX,
@@ -1013,15 +1132,17 @@ function ToastLayer(props) {
1013
1132
  zIndex
1014
1133
  } = useLayer();
1015
1134
  let t2;
1016
- $[0] === Symbol.for("react.memo_cache_sentinel") ? (t2 = toastLayer(), $[0] = t2) : t2 = $[0];
1017
- let t3;
1018
- $[1] !== zIndex ? (t3 = {
1135
+ $[0] !== zIndex ? (t2 = {
1019
1136
  zIndex
1020
- }, $[1] = zIndex, $[2] = t3) : t3 = $[2];
1021
- let t4;
1022
- return $[3] !== children || $[4] !== gap || $[5] !== padding || $[6] !== paddingX || $[7] !== paddingY || $[8] !== t3 ? (t4 = /* @__PURE__ */ jsx(Grid, { as: "ul", className: t2, "data-ui": "ToastProvider", padding, paddingX, paddingY, gap, columns: 1, style: t3, children }), $[3] = children, $[4] = gap, $[5] = padding, $[6] = paddingX, $[7] = paddingY, $[8] = t3, $[9] = t4) : t4 = $[9], t4;
1137
+ }, $[0] = zIndex, $[1] = t2) : t2 = $[1];
1138
+ let t3;
1139
+ return $[2] !== children || $[3] !== gap || $[4] !== padding || $[5] !== paddingX || $[6] !== paddingY || $[7] !== t2 ? (t3 = /* @__PURE__ */ jsx(StyledLayer, { forwardedAs: "ul", "data-ui": "ToastProvider", padding, paddingX, paddingY, gap, columns: 1, style: t2, children }), $[2] = children, $[3] = gap, $[4] = padding, $[5] = paddingX, $[6] = paddingY, $[7] = t2, $[8] = t3) : t3 = $[8], t3;
1023
1140
  }
1024
1141
  ToastLayer.displayName = "ToastLayer";
1142
+ const StyledLayer = styled(Grid).withConfig({
1143
+ displayName: "StyledLayer",
1144
+ componentId: "sc-1tbwn58-0"
1145
+ })`box-sizing:border-box;position:fixed;right:0;bottom:0;list-style:none;pointer-events:none;max-width:420px;width:100%;`;
1025
1146
  let toastId = 0;
1026
1147
  function generateToastId() {
1027
1148
  return String(toastId++);
@@ -1046,7 +1167,7 @@ function ToastProvider(props) {
1046
1167
  return startTransition(() => {
1047
1168
  setState((prevState) => {
1048
1169
  if (duration === 0.01)
1049
- return prevState.filter((toast2) => toast2.id !== id);
1170
+ return prevState.filter((toast) => toast.id !== id);
1050
1171
  const dismiss = () => startTransition(() => setState((currentState) => currentState.filter((toast_0) => toast_0.id !== id)));
1051
1172
  return [...prevState.filter((toast_1) => toast_1.id !== id), {
1052
1173
  dismiss,
@@ -1143,37 +1264,36 @@ function _focusItemElement(el) {
1143
1264
  }
1144
1265
  }
1145
1266
  const TreeContext = createGlobalScopedContext("@sanity/ui/context/tree", null), Tree = memo(forwardRef(function(props, forwardedRef) {
1146
- const $ = c(38);
1147
- let children, gap, onFocus, restProps, t0;
1267
+ const $ = c(37);
1268
+ let children, onFocus, restProps, t0;
1148
1269
  $[0] !== props ? ({
1149
1270
  children,
1150
- gap,
1151
1271
  space: t0,
1152
1272
  onFocus,
1153
1273
  ...restProps
1154
- } = props, $[0] = props, $[1] = children, $[2] = gap, $[3] = onFocus, $[4] = restProps, $[5] = t0) : (children = $[1], gap = $[2], onFocus = $[3], restProps = $[4], t0 = $[5]);
1274
+ } = props, $[0] = props, $[1] = children, $[2] = onFocus, $[3] = restProps, $[4] = t0) : (children = $[1], onFocus = $[2], restProps = $[3], t0 = $[4]);
1155
1275
  const space = t0 === void 0 ? 1 : t0, ref = useRef(null), [focusedElement, setFocusedElement] = useState(null), focusedElementRef = useRef(focusedElement);
1156
1276
  let t1, t2;
1157
- $[6] === Symbol.for("react.memo_cache_sentinel") ? (t2 = [], $[6] = t2) : t2 = $[6], t1 = t2;
1277
+ $[5] === Symbol.for("react.memo_cache_sentinel") ? (t2 = [], $[5] = t2) : t2 = $[5], t1 = t2;
1158
1278
  const path = t1;
1159
1279
  let t3;
1160
- $[7] === Symbol.for("react.memo_cache_sentinel") ? (t3 = [], $[7] = t3) : t3 = $[7];
1280
+ $[6] === Symbol.for("react.memo_cache_sentinel") ? (t3 = [], $[6] = t3) : t3 = $[6];
1161
1281
  const [itemElements, setItemElements] = useState(t3);
1162
1282
  let t4;
1163
- $[8] === Symbol.for("react.memo_cache_sentinel") ? (t4 = {}, $[8] = t4) : t4 = $[8];
1283
+ $[7] === Symbol.for("react.memo_cache_sentinel") ? (t4 = {}, $[7] = t4) : t4 = $[7];
1164
1284
  const [state, setState] = useState(t4), stateRef = useRef(state);
1165
1285
  let t5;
1166
- $[9] === Symbol.for("react.memo_cache_sentinel") ? (t5 = () => ref.current, $[9] = t5) : t5 = $[9], useImperativeHandle(forwardedRef, t5);
1286
+ $[8] === Symbol.for("react.memo_cache_sentinel") ? (t5 = () => ref.current, $[8] = t5) : t5 = $[8], useImperativeHandle(forwardedRef, t5);
1167
1287
  let t6, t7;
1168
- $[10] !== focusedElement ? (t6 = () => {
1288
+ $[9] !== focusedElement ? (t6 = () => {
1169
1289
  focusedElementRef.current = focusedElement;
1170
- }, t7 = [focusedElement], $[10] = focusedElement, $[11] = t6, $[12] = t7) : (t6 = $[11], t7 = $[12]), useEffect(t6, t7);
1290
+ }, t7 = [focusedElement], $[9] = focusedElement, $[10] = t6, $[11] = t7) : (t6 = $[10], t7 = $[11]), useEffect(t6, t7);
1171
1291
  let t8, t9;
1172
- $[13] !== state ? (t8 = () => {
1292
+ $[12] !== state ? (t8 = () => {
1173
1293
  stateRef.current = state;
1174
- }, t9 = [state], $[13] = state, $[14] = t8, $[15] = t9) : (t8 = $[14], t9 = $[15]), useEffect(t8, t9);
1294
+ }, t9 = [state], $[12] = state, $[13] = t8, $[14] = t9) : (t8 = $[13], t9 = $[14]), useEffect(t8, t9);
1175
1295
  let t10;
1176
- $[16] === Symbol.for("react.memo_cache_sentinel") ? (t10 = (element, path_0, expanded, selected) => (setState((s) => ({
1296
+ $[15] === Symbol.for("react.memo_cache_sentinel") ? (t10 = (element, path_0, expanded, selected) => (setState((s) => ({
1177
1297
  ...s,
1178
1298
  [path_0]: {
1179
1299
  element,
@@ -1186,10 +1306,10 @@ const TreeContext = createGlobalScopedContext("@sanity/ui/context/tree", null),
1186
1306
  };
1187
1307
  return delete newState[path_0], newState;
1188
1308
  });
1189
- }), $[16] = t10) : t10 = $[16];
1309
+ }), $[15] = t10) : t10 = $[15];
1190
1310
  const registerItem = t10;
1191
1311
  let t11;
1192
- $[17] === Symbol.for("react.memo_cache_sentinel") ? (t11 = (path_1, expanded_0) => {
1312
+ $[16] === Symbol.for("react.memo_cache_sentinel") ? (t11 = (path_1, expanded_0) => {
1193
1313
  setState((s_1) => {
1194
1314
  const itemState = s_1[path_1];
1195
1315
  return itemState ? {
@@ -1200,12 +1320,12 @@ const TreeContext = createGlobalScopedContext("@sanity/ui/context/tree", null),
1200
1320
  }
1201
1321
  } : s_1;
1202
1322
  });
1203
- }, $[17] = t11) : t11 = $[17];
1323
+ }, $[16] = t11) : t11 = $[16];
1204
1324
  const setExpanded = t11;
1205
1325
  let t12;
1206
1326
  const t13 = focusedElement || itemElements[0] || null;
1207
1327
  let t14;
1208
- $[18] !== space || $[19] !== state || $[20] !== t13 ? (t14 = {
1328
+ $[17] !== space || $[18] !== state || $[19] !== t13 ? (t14 = {
1209
1329
  version: 0,
1210
1330
  focusedElement: t13,
1211
1331
  level: 0,
@@ -1215,10 +1335,10 @@ const TreeContext = createGlobalScopedContext("@sanity/ui/context/tree", null),
1215
1335
  setFocusedElement,
1216
1336
  space,
1217
1337
  state
1218
- }, $[18] = space, $[19] = state, $[20] = t13, $[21] = t14) : t14 = $[21], t12 = t14;
1338
+ }, $[17] = space, $[18] = state, $[19] = t13, $[20] = t14) : t14 = $[20], t12 = t14;
1219
1339
  const contextValue = t12;
1220
1340
  let t15;
1221
- $[22] !== itemElements ? (t15 = (event) => {
1341
+ $[21] !== itemElements ? (t15 = (event) => {
1222
1342
  if (focusedElementRef.current) {
1223
1343
  if (event.key === "ArrowDown") {
1224
1344
  event.preventDefault();
@@ -1277,29 +1397,120 @@ const TreeContext = createGlobalScopedContext("@sanity/ui/context/tree", null),
1277
1397
  return;
1278
1398
  }
1279
1399
  }
1280
- }, $[22] = itemElements, $[23] = t15) : t15 = $[23];
1400
+ }, $[21] = itemElements, $[22] = t15) : t15 = $[22];
1281
1401
  const handleKeyDown = t15;
1282
1402
  let t16;
1283
- $[24] !== onFocus ? (t16 = (event_0) => {
1403
+ $[23] !== onFocus ? (t16 = (event_0) => {
1284
1404
  setFocusedElement(event_0.target), onFocus?.(event_0);
1285
- }, $[24] = onFocus, $[25] = t16) : t16 = $[25];
1405
+ }, $[23] = onFocus, $[24] = t16) : t16 = $[24];
1286
1406
  const handleFocus = t16;
1287
1407
  let t17;
1288
- $[26] === Symbol.for("react.memo_cache_sentinel") ? (t17 = () => {
1408
+ $[25] === Symbol.for("react.memo_cache_sentinel") ? (t17 = () => {
1289
1409
  if (!ref.current)
1290
1410
  return;
1291
1411
  const _itemElements = Array.from(ref.current.querySelectorAll('[data-ui="TreeItem"]'));
1292
1412
  setItemElements(_itemElements);
1293
- }, $[26] = t17) : t17 = $[26];
1413
+ }, $[25] = t17) : t17 = $[25];
1294
1414
  let t18;
1295
- $[27] !== children ? (t18 = [children], $[27] = children, $[28] = t18) : t18 = $[28], useEffect(t17, t18);
1296
- const t19 = gap ?? space;
1415
+ $[26] !== children ? (t18 = [children], $[26] = children, $[27] = t18) : t18 = $[27], useEffect(t17, t18);
1416
+ let t19;
1417
+ $[28] !== children || $[29] !== handleFocus || $[30] !== handleKeyDown || $[31] !== restProps || $[32] !== space ? (t19 = /* @__PURE__ */ jsx(Stack, { as: "ul", "data-ui": "Tree", ...restProps, onFocus: handleFocus, onKeyDown: handleKeyDown, ref, role: "tree", space, children }), $[28] = children, $[29] = handleFocus, $[30] = handleKeyDown, $[31] = restProps, $[32] = space, $[33] = t19) : t19 = $[33];
1297
1418
  let t20;
1298
- $[29] !== children || $[30] !== handleFocus || $[31] !== handleKeyDown || $[32] !== restProps || $[33] !== t19 ? (t20 = /* @__PURE__ */ jsx(Stack, { as: "ul", "data-ui": "Tree", ...restProps, gap: t19, onFocus: handleFocus, onKeyDown: handleKeyDown, ref, role: "tree", children }), $[29] = children, $[30] = handleFocus, $[31] = handleKeyDown, $[32] = restProps, $[33] = t19, $[34] = t20) : t20 = $[34];
1299
- let t21;
1300
- return $[35] !== contextValue || $[36] !== t20 ? (t21 = /* @__PURE__ */ jsx(TreeContext.Provider, { value: contextValue, children: t20 }), $[35] = contextValue, $[36] = t20, $[37] = t21) : t21 = $[37], t21;
1419
+ return $[34] !== contextValue || $[35] !== t19 ? (t20 = /* @__PURE__ */ jsx(TreeContext.Provider, { value: contextValue, children: t19 }), $[34] = contextValue, $[35] = t19, $[36] = t20) : t20 = $[36], t20;
1301
1420
  }));
1302
1421
  Tree.displayName = "Memo(ForwardRef(Tree))";
1422
+ function treeItemRootStyle() {
1423
+ return css`
1424
+ &[role='none'] > [role='treeitem'] {
1425
+ outline: none;
1426
+ cursor: default;
1427
+ border-radius: 3px;
1428
+
1429
+ background-color: var(--card-bg-color);
1430
+ color: var(--treeitem-fg-color);
1431
+
1432
+ &:focus {
1433
+ position: relative;
1434
+ }
1435
+ }
1436
+
1437
+ &[role='treeitem'] {
1438
+ outline: none;
1439
+
1440
+ & > div {
1441
+ cursor: default;
1442
+ border-radius: 3px;
1443
+
1444
+ background-color: var(--card-bg-color);
1445
+ color: var(--treeitem-fg-color);
1446
+ }
1447
+
1448
+ &:focus > div {
1449
+ position: relative;
1450
+ }
1451
+ }
1452
+ `;
1453
+ }
1454
+ function treeItemRootColorStyle(props) {
1455
+ const $tone = "default", {
1456
+ color
1457
+ } = getTheme_v2(props.theme), tone = color.selectable[$tone];
1458
+ return css`
1459
+ &[role='none'] {
1460
+ & > [role='treeitem'] {
1461
+ ${_cardColorStyle(color, tone.enabled)}
1462
+ }
1463
+
1464
+ &[data-selected] > [role='treeitem'] {
1465
+ ${_cardColorStyle(color, tone.pressed)}
1466
+ }
1467
+
1468
+ @media (hover: hover) {
1469
+ &:not([data-selected]) > [role='treeitem']:not(:focus):hover {
1470
+ ${_cardColorStyle(color, tone.hovered)}
1471
+ }
1472
+
1473
+ & > [role='treeitem']:focus {
1474
+ ${_cardColorStyle(color, tone.selected)}
1475
+ }
1476
+ }
1477
+ }
1478
+
1479
+ &[role='treeitem'] {
1480
+ & > [data-ui='TreeItem__box'] {
1481
+ ${_cardColorStyle(color, tone.enabled)}
1482
+ }
1483
+
1484
+ &[data-selected] > [data-ui='TreeItem__box'] {
1485
+ ${_cardColorStyle(color, tone.pressed)}
1486
+ }
1487
+
1488
+ @media (hover: hover) {
1489
+ &:not([data-selected]):not(:focus) > [data-ui='TreeItem__box']:hover {
1490
+ ${_cardColorStyle(color, tone.hovered)}
1491
+ }
1492
+
1493
+ &:focus > [data-ui='TreeItem__box'] {
1494
+ ${_cardColorStyle(color, tone.selected)}
1495
+ }
1496
+ }
1497
+ }
1498
+ `;
1499
+ }
1500
+ function treeItemBoxStyle(props) {
1501
+ const {
1502
+ $level
1503
+ } = props, {
1504
+ space
1505
+ } = getTheme_v2(props.theme);
1506
+ return css`
1507
+ padding-left: ${rem(space[2] * $level)};
1508
+
1509
+ &[data-as='a'] {
1510
+ text-decoration: none;
1511
+ }
1512
+ `;
1513
+ }
1303
1514
  function useTree() {
1304
1515
  const tree = useContext(TreeContext);
1305
1516
  if (!tree)
@@ -1317,20 +1528,29 @@ const TreeGroup = memo(function(props) {
1317
1528
  const expanded = t0 === void 0 ? !1 : t0, tree = useTree(), t1 = !expanded;
1318
1529
  let t2;
1319
1530
  return $[4] !== children || $[5] !== restProps || $[6] !== t1 || $[7] !== tree.space ? (t2 = /* @__PURE__ */ jsx(Stack, { as: "ul", "data-ui": "TreeGroup", ...restProps, hidden: t1, marginTop: tree.space, role: "group", space: tree.space, children }), $[4] = children, $[5] = restProps, $[6] = t1, $[7] = tree.space, $[8] = t2) : t2 = $[8], t2;
1320
- }), TreeItem = memo(function(props) {
1531
+ }), StyledTreeItem = memo(styled.li.withConfig({
1532
+ displayName: "StyledTreeItem",
1533
+ componentId: "sc-iiskig-0"
1534
+ })(treeItemRootStyle, treeItemRootColorStyle)), TreeItemBox = /* @__PURE__ */ styled(Box).attrs({
1535
+ forwardedAs: "a"
1536
+ }).withConfig({
1537
+ displayName: "TreeItemBox",
1538
+ componentId: "sc-iiskig-1"
1539
+ })(treeItemBoxStyle), ToggleArrowText = styled(Text).withConfig({
1540
+ displayName: "ToggleArrowText",
1541
+ componentId: "sc-iiskig-2"
1542
+ })`& > svg{transition:transform 100ms;}`, TreeItem = memo(function(props) {
1321
1543
  const {
1322
1544
  children,
1323
- className,
1324
1545
  expanded: expandedProp = !1,
1325
1546
  fontSize = 1,
1326
1547
  href,
1327
1548
  icon: IconComponent,
1328
1549
  id: idProp,
1329
- linkAs = "a",
1550
+ linkAs,
1330
1551
  muted,
1331
1552
  onClick,
1332
1553
  padding = 2,
1333
- radius = 2,
1334
1554
  selected = !1,
1335
1555
  space = 2,
1336
1556
  text,
@@ -1356,55 +1576,27 @@ const TreeGroup = memo(function(props) {
1356
1576
  if (rootRef.current)
1357
1577
  return registerItem(rootRef.current, itemPath.join("/"), expanded, selected);
1358
1578
  }, [expanded, itemPath, registerItem, selected]);
1359
- const content2 = /* @__PURE__ */ jsxs(Flex, { gap: space, padding, children: [
1360
- /* @__PURE__ */ jsxs(Box, { style: {
1579
+ const content2 = /* @__PURE__ */ jsxs(Flex, { padding, children: [
1580
+ /* @__PURE__ */ jsxs(Box, { marginRight: space, style: {
1361
1581
  visibility: IconComponent || children ? "visible" : "hidden",
1362
1582
  pointerEvents: "none"
1363
1583
  }, children: [
1364
1584
  IconComponent && /* @__PURE__ */ jsx(Text, { muted, size: fontSize, weight, children: /* @__PURE__ */ jsx(IconComponent, {}) }),
1365
- !IconComponent && /* @__PURE__ */ jsx(Text, { muted, size: fontSize, weight, children: /* @__PURE__ */ jsx(ToggleArrowRightIcon, { style: {
1585
+ !IconComponent && /* @__PURE__ */ jsx(ToggleArrowText, { muted, size: fontSize, weight, children: /* @__PURE__ */ jsx(ToggleArrowRightIcon, { style: {
1366
1586
  transform: expanded ? "rotate(90deg)" : void 0
1367
1587
  } }) })
1368
1588
  ] }),
1369
1589
  /* @__PURE__ */ jsx(Box, { flex: 1, children: /* @__PURE__ */ jsx(Text, { muted, size: fontSize, textOverflow: "ellipsis", weight, children: text }) })
1370
1590
  ] });
1371
- return href ? /* @__PURE__ */ jsxs(Box, { "data-selected": selected ? "" : void 0, "data-tree-id": id, "data-tree-key": itemKey, "data-ui": "TreeItem", ...restProps, as: "li", className: composeClassNames(className, treeItem()), onClick: handleClick, ref: rootRef, role: "none", children: [
1372
- /* @__PURE__ */ jsx(Selectable, { "aria-expanded": expanded, as: linkAs, "data-pressed": selected ? "" : void 0, "data-ui": "TreeItem__box", href, radius, ref: treeitemRef, role: "treeitem", tabIndex, style: {
1373
- paddingLeft: `calc(var(--space-2) * ${tree.level})`
1374
- }, children: content2 }),
1591
+ return href ? /* @__PURE__ */ jsxs(StyledTreeItem, { "data-selected": selected ? "" : void 0, "data-tree-id": id, "data-tree-key": itemKey, "data-ui": "TreeItem", ...restProps, onClick: handleClick, ref: rootRef, role: "none", children: [
1592
+ /* @__PURE__ */ jsx(TreeItemBox, { $level: tree.level, "aria-expanded": expanded, as: linkAs, "data-ui": "TreeItem__box", href, ref: treeitemRef, role: "treeitem", tabIndex, children: content2 }),
1375
1593
  /* @__PURE__ */ jsx(TreeContext.Provider, { value: contextValue, children: children && /* @__PURE__ */ jsx(TreeGroup, { hidden: !expanded, children }) })
1376
- ] }) : /* @__PURE__ */ jsxs(Box, { "data-selected": selected ? "" : void 0, "data-ui": "TreeItem", "data-tree-id": id, "data-tree-key": itemKey, ...restProps, "aria-expanded": expanded, className: composeClassNames(className, treeItem()), onClick: handleClick, onKeyDown: handleKeyDown, ref: rootRef, role: "treeitem", tabIndex, children: [
1377
- /* @__PURE__ */ jsx(Selectable, { as: "button", "data-pressed": selected ? "" : void 0, "data-ui": "TreeItem__box", radius, style: {
1378
- paddingLeft: `calc(var(--space-2) * ${tree.level})`
1379
- }, children: content2 }),
1594
+ ] }) : /* @__PURE__ */ jsxs(StyledTreeItem, { "data-selected": selected ? "" : void 0, "data-ui": "TreeItem", "data-tree-id": id, "data-tree-key": itemKey, ...restProps, "aria-expanded": expanded, onClick: handleClick, onKeyDown: handleKeyDown, ref: rootRef, role: "treeitem", tabIndex, children: [
1595
+ /* @__PURE__ */ jsx(TreeItemBox, { $level: tree.level, as: "div", "data-ui": "TreeItem__box", children: content2 }),
1380
1596
  /* @__PURE__ */ jsx(TreeContext.Provider, { value: contextValue, children: children && /* @__PURE__ */ jsx(TreeGroup, { expanded, children }) })
1381
1597
  ] });
1382
1598
  });
1383
1599
  TreeItem.displayName = "Memo(TreeItem)";
1384
- function StyleTags(props) {
1385
- const $ = c(10), {
1386
- theme: themeProp
1387
- } = props;
1388
- let t0;
1389
- $[0] !== themeProp ? (t0 = themeProp ?? buildTheme_v3(), $[0] = themeProp, $[1] = t0) : t0 = $[1];
1390
- const theme = t0;
1391
- let t1;
1392
- $[2] === Symbol.for("react.memo_cache_sentinel") ? (t1 = /* @__PURE__ */ jsx("style", { href: "sanity-palette", precedence: "palette", children: compilePalette() }), $[2] = t1) : t1 = $[2];
1393
- let t2;
1394
- $[3] !== theme ? (t2 = compileTheme({
1395
- v3: theme
1396
- }), $[3] = theme, $[4] = t2) : t2 = $[4];
1397
- let t3;
1398
- $[5] !== t2 ? (t3 = /* @__PURE__ */ jsx("style", { href: "sanity-theme", precedence: "theme", children: t2 }), $[5] = t2, $[6] = t3) : t3 = $[6];
1399
- let t4;
1400
- $[7] === Symbol.for("react.memo_cache_sentinel") ? (t4 = /* @__PURE__ */ jsx("style", { href: "sanity-system", precedence: "system", children: compileSystem() }), $[7] = t4) : t4 = $[7];
1401
- let t5;
1402
- return $[8] !== t3 ? (t5 = /* @__PURE__ */ jsxs(Fragment$1, { children: [
1403
- t1,
1404
- t3,
1405
- t4
1406
- ] }), $[8] = t3, $[9] = t5) : t5 = $[9], t5;
1407
- }
1408
1600
  export {
1409
1601
  Arrow,
1410
1602
  Autocomplete,
@@ -1417,7 +1609,6 @@ export {
1417
1609
  Breadcrumbs,
1418
1610
  Button,
1419
1611
  Card,
1420
- CardProvider,
1421
1612
  Checkbox,
1422
1613
  Code,
1423
1614
  CodeSkeleton,
@@ -1453,7 +1644,6 @@ export {
1453
1644
  Spinner,
1454
1645
  SrOnly,
1455
1646
  Stack,
1456
- StyleTags,
1457
1647
  Switch,
1458
1648
  Tab,
1459
1649
  TabList,
@@ -1474,7 +1664,9 @@ export {
1474
1664
  VirtualList,
1475
1665
  _ResizeObserver,
1476
1666
  _elementSizeObserver,
1667
+ _fillCSSObject,
1477
1668
  _getArrayProp,
1669
+ _getResponsiveSpace,
1478
1670
  _hasFocus,
1479
1671
  _isEnterToClickElement,
1480
1672
  _isScrollable,
@@ -1497,8 +1689,12 @@ export {
1497
1689
  isHTMLTextAreaElement,
1498
1690
  multiply,
1499
1691
  parseColor,
1500
- px,
1501
1692
  rem,
1693
+ responsiveCodeFontStyle,
1694
+ responsiveHeadingFont,
1695
+ responsiveLabelFont,
1696
+ responsiveTextAlignStyle,
1697
+ responsiveTextFont,
1502
1698
  rgbToHex,
1503
1699
  rgbToHsl,
1504
1700
  rgba,
@@ -1506,7 +1702,6 @@ export {
1506
1702
  studioTheme,
1507
1703
  useArrayProp,
1508
1704
  useBoundaryElement,
1509
- useCard,
1510
1705
  useClickOutside,
1511
1706
  useClickOutsideEvent,
1512
1707
  useCustomValidity,