@editora/ui-core 0.2.1 → 0.3.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 (365) hide show
  1. package/dist/{ElementBase-DxbvhLJs.js → ElementBase-CbUsP3D6.js} +1 -1
  2. package/dist/{ElementBase-BeZT54Hj.mjs → ElementBase-D5QsC5Vw.mjs} +10 -1
  3. package/dist/ElementBase.d.ts +7 -0
  4. package/dist/ElementBase.d.ts.map +1 -1
  5. package/dist/accordion.cjs.js +1 -1
  6. package/dist/accordion.esm.js +1 -1
  7. package/dist/add-icons-CVeHOsWl.js +1 -0
  8. package/dist/add-icons-DBUZJ0g7.mjs +14 -0
  9. package/dist/add-icons.cjs.js +1 -0
  10. package/dist/add-icons.d.ts +16 -0
  11. package/dist/add-icons.d.ts.map +1 -0
  12. package/dist/add-icons.esm.js +4 -0
  13. package/dist/alert-dialog.cjs.js +24 -24
  14. package/dist/alert-dialog.esm.js +112 -107
  15. package/dist/alert.cjs.js +8 -8
  16. package/dist/alert.esm.js +22 -22
  17. package/dist/animated-beam.cjs.js +1 -1
  18. package/dist/animated-beam.esm.js +1 -1
  19. package/dist/animated-list.cjs.js +1 -1
  20. package/dist/animated-list.esm.js +1 -1
  21. package/dist/animated-text.cjs.js +1 -1
  22. package/dist/animated-text.esm.js +1 -1
  23. package/dist/app-header.cjs.js +15 -3
  24. package/dist/app-header.esm.js +31 -4
  25. package/dist/aspect-ratio.cjs.js +1 -1
  26. package/dist/aspect-ratio.esm.js +1 -1
  27. package/dist/avatar.cjs.js +1 -1
  28. package/dist/avatar.esm.js +1 -1
  29. package/dist/badge.cjs.js +1 -1
  30. package/dist/badge.esm.js +1 -1
  31. package/dist/block-controls.cjs.js +1 -1
  32. package/dist/block-controls.esm.js +1 -1
  33. package/dist/box.cjs.js +1 -1
  34. package/dist/box.esm.js +1 -1
  35. package/dist/breadcrumb.cjs.js +4 -4
  36. package/dist/breadcrumb.esm.js +93 -84
  37. package/dist/button.cjs.js +520 -1
  38. package/dist/button.esm.js +682 -2
  39. package/dist/{calendar-CzpWDxLc.js → calendar-BsVqtpjM.js} +6 -6
  40. package/dist/{calendar-DkSDFg33.mjs → calendar-CFafqZVA.mjs} +6 -6
  41. package/dist/calendar.cjs.js +1 -1
  42. package/dist/calendar.esm.js +1 -1
  43. package/dist/card.cjs.js +6 -5
  44. package/dist/card.esm.js +52 -39
  45. package/dist/chart.cjs.js +2 -2
  46. package/dist/chart.esm.js +2 -2
  47. package/dist/checkbox.cjs.js +4 -4
  48. package/dist/checkbox.esm.js +36 -15
  49. package/dist/clone-source-BxK2pEVw.mjs +11 -0
  50. package/dist/clone-source-C7E_ri5f.js +1 -0
  51. package/dist/collapsible.cjs.js +1 -1
  52. package/dist/collapsible.esm.js +1 -1
  53. package/dist/color-picker.cjs.js +2 -2
  54. package/dist/color-picker.esm.js +3 -3
  55. package/dist/combobox.cjs.js +4 -4
  56. package/dist/combobox.esm.js +22 -19
  57. package/dist/command-palette.cjs.js +1 -1
  58. package/dist/command-palette.esm.js +1 -1
  59. package/dist/command.cjs.js +1 -1
  60. package/dist/command.esm.js +1 -1
  61. package/dist/components/ui-alert-dialog.d.ts.map +1 -1
  62. package/dist/components/ui-alert.d.ts.map +1 -1
  63. package/dist/components/ui-app-header.d.ts +1 -0
  64. package/dist/components/ui-app-header.d.ts.map +1 -1
  65. package/dist/components/ui-breadcrumb.d.ts.map +1 -1
  66. package/dist/components/ui-card.d.ts +7 -0
  67. package/dist/components/ui-card.d.ts.map +1 -1
  68. package/dist/components/ui-checkbox.d.ts +6 -0
  69. package/dist/components/ui-checkbox.d.ts.map +1 -1
  70. package/dist/components/ui-combobox.d.ts.map +1 -1
  71. package/dist/components/ui-date-time-picker.d.ts.map +1 -1
  72. package/dist/components/ui-dialog.d.ts +1 -0
  73. package/dist/components/ui-dialog.d.ts.map +1 -1
  74. package/dist/components/ui-drawer.d.ts.map +1 -1
  75. package/dist/components/ui-dropdown.d.ts.map +1 -1
  76. package/dist/components/ui-empty-state.d.ts.map +1 -1
  77. package/dist/components/ui-hover-card.d.ts.map +1 -1
  78. package/dist/components/ui-icon.d.ts +1 -0
  79. package/dist/components/ui-icon.d.ts.map +1 -1
  80. package/dist/components/ui-input.d.ts +16 -0
  81. package/dist/components/ui-input.d.ts.map +1 -1
  82. package/dist/components/ui-layout.d.ts +20 -0
  83. package/dist/components/ui-layout.d.ts.map +1 -1
  84. package/dist/components/ui-menu.d.ts +1 -0
  85. package/dist/components/ui-menu.d.ts.map +1 -1
  86. package/dist/components/ui-menubar.d.ts.map +1 -1
  87. package/dist/components/ui-multi-select.d.ts +6 -0
  88. package/dist/components/ui-multi-select.d.ts.map +1 -1
  89. package/dist/components/ui-number-field.d.ts +6 -0
  90. package/dist/components/ui-number-field.d.ts.map +1 -1
  91. package/dist/components/ui-pagination.d.ts.map +1 -1
  92. package/dist/components/ui-password-field.d.ts +11 -0
  93. package/dist/components/ui-password-field.d.ts.map +1 -1
  94. package/dist/components/ui-popover.d.ts.map +1 -1
  95. package/dist/components/ui-positioner.d.ts.map +1 -1
  96. package/dist/components/ui-radio-group.d.ts +6 -0
  97. package/dist/components/ui-radio-group.d.ts.map +1 -1
  98. package/dist/components/ui-rating.d.ts +1 -0
  99. package/dist/components/ui-rating.d.ts.map +1 -1
  100. package/dist/components/ui-select.d.ts +7 -0
  101. package/dist/components/ui-select.d.ts.map +1 -1
  102. package/dist/components/ui-sidebar.d.ts +1 -0
  103. package/dist/components/ui-sidebar.d.ts.map +1 -1
  104. package/dist/components/ui-slider.d.ts +6 -0
  105. package/dist/components/ui-slider.d.ts.map +1 -1
  106. package/dist/components/ui-sortable.d.ts +1 -0
  107. package/dist/components/ui-sortable.d.ts.map +1 -1
  108. package/dist/components/ui-switch.d.ts +6 -0
  109. package/dist/components/ui-switch.d.ts.map +1 -1
  110. package/dist/components/ui-tabs.d.ts +2 -0
  111. package/dist/components/ui-tabs.d.ts.map +1 -1
  112. package/dist/components/ui-textarea.d.ts +6 -0
  113. package/dist/components/ui-textarea.d.ts.map +1 -1
  114. package/dist/components/ui-toast.d.ts.map +1 -1
  115. package/dist/components/ui-tooltip.d.ts.map +1 -1
  116. package/dist/container.cjs.js +1 -1
  117. package/dist/container.esm.js +1 -1
  118. package/dist/context-menu.cjs.js +2 -2
  119. package/dist/context-menu.esm.js +2 -2
  120. package/dist/control-group.cjs.js +1 -1
  121. package/dist/control-group.esm.js +1 -1
  122. package/dist/data-table.cjs.js +5 -5
  123. package/dist/data-table.esm.js +7 -7
  124. package/dist/date-field.cjs.js +1 -1
  125. package/dist/date-field.esm.js +3 -3
  126. package/dist/date-picker.cjs.js +2 -2
  127. package/dist/date-picker.esm.js +17 -17
  128. package/dist/date-range-picker.cjs.js +2 -2
  129. package/dist/date-range-picker.esm.js +4 -4
  130. package/dist/date-range-time-picker.cjs.js +3 -3
  131. package/dist/date-range-time-picker.esm.js +16 -16
  132. package/dist/date-time-picker.cjs.js +26 -23
  133. package/dist/date-time-picker.esm.js +49 -46
  134. package/dist/{date-time-utils-zAx4ghvC.mjs → date-time-utils-CJUksWj3.mjs} +1 -1
  135. package/dist/{date-time-utils-C-4eHTyy.js → date-time-utils-D3hQQ5Om.js} +1 -1
  136. package/dist/description.cjs.js +1 -1
  137. package/dist/description.esm.js +1 -1
  138. package/dist/dialog.cjs.js +7 -7
  139. package/dist/dialog.esm.js +51 -47
  140. package/dist/direction-provider.cjs.js +1 -1
  141. package/dist/direction-provider.esm.js +1 -1
  142. package/dist/dismissable-layer.cjs.js +1 -1
  143. package/dist/dismissable-layer.esm.js +1 -1
  144. package/dist/dock.cjs.js +1 -1
  145. package/dist/dock.esm.js +1 -1
  146. package/dist/drawer.cjs.js +5 -5
  147. package/dist/drawer.esm.js +18 -17
  148. package/dist/dropdown.cjs.js +7 -7
  149. package/dist/dropdown.esm.js +39 -38
  150. package/dist/empty-state.cjs.js +12 -2
  151. package/dist/empty-state.esm.js +17 -7
  152. package/dist/field-error.cjs.js +1 -1
  153. package/dist/field-error.esm.js +1 -1
  154. package/dist/field.cjs.js +2 -2
  155. package/dist/field.esm.js +2 -2
  156. package/dist/fieldset.cjs.js +1 -1
  157. package/dist/fieldset.esm.js +1 -1
  158. package/dist/file-upload.cjs.js +1 -1
  159. package/dist/file-upload.esm.js +1 -1
  160. package/dist/flex.cjs.js +1 -1
  161. package/dist/flex.esm.js +1 -1
  162. package/dist/floating-toolbar.cjs.js +2 -2
  163. package/dist/floating-toolbar.esm.js +2 -2
  164. package/dist/focus-scope-Dl0qk5GP.mjs +177 -0
  165. package/dist/focus-scope-Doz0bnE1.js +1 -0
  166. package/dist/focus-scope.cjs.js +1 -1
  167. package/dist/focus-scope.esm.js +2 -2
  168. package/dist/form-control-B90_3kYN.js +1 -0
  169. package/dist/form-control-D9wWUMBl.mjs +86 -0
  170. package/dist/form.cjs.js +2 -2
  171. package/dist/form.esm.js +2 -2
  172. package/dist/gantt.cjs.js +2 -2
  173. package/dist/gantt.esm.js +2 -2
  174. package/dist/grid.cjs.js +1 -1
  175. package/dist/grid.esm.js +1 -1
  176. package/dist/hover-card.cjs.js +5 -5
  177. package/dist/hover-card.esm.js +19 -18
  178. package/dist/icon-cloud.cjs.js +1 -1
  179. package/dist/icon-cloud.esm.js +1 -1
  180. package/dist/icon.cjs.js +207 -1
  181. package/dist/icon.esm.js +294 -2
  182. package/dist/icons-CpCpPXV5.js +1 -0
  183. package/dist/icons-DWYbbhb0.mjs +115 -0
  184. package/dist/icons.d.ts +11 -1
  185. package/dist/icons.d.ts.map +1 -1
  186. package/dist/implicit-submit-B6M5Uc56.js +1 -0
  187. package/dist/implicit-submit-Lr0-q2LR.mjs +44 -0
  188. package/dist/index.cjs.js +1 -1
  189. package/dist/index.d.ts +1 -0
  190. package/dist/index.d.ts.map +1 -1
  191. package/dist/index.esm.js +309 -299
  192. package/dist/inline-edit.cjs.js +1 -1
  193. package/dist/inline-edit.esm.js +1 -1
  194. package/dist/input.cjs.js +62 -20
  195. package/dist/input.esm.js +164 -58
  196. package/dist/label.cjs.js +1 -1
  197. package/dist/label.esm.js +1 -1
  198. package/dist/layout.cjs.js +145 -4
  199. package/dist/layout.esm.js +278 -40
  200. package/dist/marquee.cjs.js +1 -1
  201. package/dist/marquee.esm.js +1 -1
  202. package/dist/masonry-grid.cjs.js +1 -1
  203. package/dist/masonry-grid.esm.js +1 -1
  204. package/dist/menu.cjs.js +8 -8
  205. package/dist/menu.esm.js +51 -47
  206. package/dist/menubar.cjs.js +9 -9
  207. package/dist/menubar.esm.js +41 -40
  208. package/dist/meter.cjs.js +1 -1
  209. package/dist/meter.esm.js +1 -1
  210. package/dist/multi-select.cjs.js +7 -7
  211. package/dist/multi-select.esm.js +55 -34
  212. package/dist/navigate-CXebafwF.mjs +18 -0
  213. package/dist/navigate-ChJVIIuS.js +1 -0
  214. package/dist/navigation-menu.cjs.js +1 -1
  215. package/dist/navigation-menu.esm.js +1 -1
  216. package/dist/number-attribute-BAF07JrU.mjs +8 -0
  217. package/dist/number-attribute-C4Rrl7d3.js +1 -0
  218. package/dist/number-field.cjs.js +8 -8
  219. package/dist/number-field.esm.js +90 -69
  220. package/dist/number-ticker.cjs.js +1 -1
  221. package/dist/number-ticker.esm.js +1 -1
  222. package/dist/odometer.cjs.js +1 -1
  223. package/dist/odometer.esm.js +1 -1
  224. package/dist/orbiter.cjs.js +1 -1
  225. package/dist/orbiter.esm.js +1 -1
  226. package/dist/pagination.cjs.js +24 -23
  227. package/dist/pagination.esm.js +61 -46
  228. package/dist/{panel-group-BVHJEdfx.js → panel-group-BIzzpQ5i.js} +1 -1
  229. package/dist/{panel-group-BxO_eNW6.mjs → panel-group-CFLjzRWI.mjs} +1 -1
  230. package/dist/panel-group.cjs.js +1 -1
  231. package/dist/panel-group.esm.js +1 -1
  232. package/dist/panel.cjs.js +1 -1
  233. package/dist/panel.esm.js +1 -1
  234. package/dist/password-field.cjs.js +36 -16
  235. package/dist/password-field.esm.js +113 -44
  236. package/dist/pin-input.cjs.js +1 -1
  237. package/dist/pin-input.esm.js +1 -1
  238. package/dist/placement-grid.cjs.js +1 -1
  239. package/dist/placement-grid.esm.js +1 -1
  240. package/dist/plugin-panel.cjs.js +1 -1
  241. package/dist/plugin-panel.esm.js +1 -1
  242. package/dist/popover.cjs.js +2 -2
  243. package/dist/popover.esm.js +28 -26
  244. package/dist/portal.cjs.js +1 -1
  245. package/dist/portal.esm.js +1 -1
  246. package/dist/positioner.cjs.js +2 -2
  247. package/dist/positioner.esm.js +35 -38
  248. package/dist/preload.cjs.js +221 -0
  249. package/dist/preload.css +220 -0
  250. package/dist/preload.d.ts +17 -0
  251. package/dist/preload.d.ts.map +1 -0
  252. package/dist/preload.esm.js +224 -0
  253. package/dist/presence.cjs.js +1 -1
  254. package/dist/presence.esm.js +1 -1
  255. package/dist/primitives/clone-source.d.ts +3 -0
  256. package/dist/primitives/clone-source.d.ts.map +1 -0
  257. package/dist/primitives/focus-scope.d.ts +6 -0
  258. package/dist/primitives/focus-scope.d.ts.map +1 -1
  259. package/dist/primitives/form-control.d.ts +68 -0
  260. package/dist/primitives/form-control.d.ts.map +1 -0
  261. package/dist/primitives/implicit-submit.d.ts +17 -0
  262. package/dist/primitives/implicit-submit.d.ts.map +1 -0
  263. package/dist/primitives/navigate.d.ts +27 -0
  264. package/dist/primitives/navigate.d.ts.map +1 -0
  265. package/dist/primitives/number-attribute.d.ts +7 -0
  266. package/dist/primitives/number-attribute.d.ts.map +1 -0
  267. package/dist/primitives/slotted-input.d.ts +19 -0
  268. package/dist/primitives/slotted-input.d.ts.map +1 -0
  269. package/dist/progress.cjs.js +3 -3
  270. package/dist/progress.esm.js +3 -3
  271. package/dist/quick-actions.cjs.js +5 -5
  272. package/dist/quick-actions.esm.js +3 -3
  273. package/dist/radio-group.cjs.js +9 -9
  274. package/dist/radio-group.esm.js +47 -24
  275. package/dist/radio.cjs.js +1 -1
  276. package/dist/radio.esm.js +1 -1
  277. package/dist/rating.cjs.js +6 -6
  278. package/dist/rating.esm.js +21 -10
  279. package/dist/{runtime-BRT7E4A8.mjs → runtime-CORXjP7e.mjs} +379 -357
  280. package/dist/runtime-uCly3ECd.js +5 -0
  281. package/dist/runtime.cjs.js +1 -1
  282. package/dist/runtime.esm.js +1 -1
  283. package/dist/scroll-area.cjs.js +1 -1
  284. package/dist/scroll-area.esm.js +1 -1
  285. package/dist/section.cjs.js +1 -1
  286. package/dist/section.esm.js +1 -1
  287. package/dist/select.cjs.js +21 -21
  288. package/dist/select.esm.js +111 -71
  289. package/dist/selection-popup.cjs.js +2 -2
  290. package/dist/selection-popup.esm.js +2 -2
  291. package/dist/semantic-tokens.d.ts.map +1 -1
  292. package/dist/separator.cjs.js +1 -1
  293. package/dist/separator.esm.js +1 -1
  294. package/dist/sidebar.cjs.js +15 -15
  295. package/dist/sidebar.esm.js +48 -42
  296. package/dist/skeleton.cjs.js +1 -1
  297. package/dist/skeleton.esm.js +1 -1
  298. package/dist/slider.cjs.js +11 -11
  299. package/dist/slider.esm.js +40 -23
  300. package/dist/slot.cjs.js +1 -1
  301. package/dist/slot.esm.js +1 -1
  302. package/dist/slotted-input-BVq2QQg2.js +1 -0
  303. package/dist/slotted-input-atWznLfm.mjs +13 -0
  304. package/dist/sortable.cjs.js +25 -25
  305. package/dist/sortable.esm.js +29 -21
  306. package/dist/spinning-text.cjs.js +1 -1
  307. package/dist/spinning-text.esm.js +1 -1
  308. package/dist/split-button.cjs.js +1 -1
  309. package/dist/split-button.esm.js +1 -1
  310. package/dist/splitter.cjs.js +1 -1
  311. package/dist/splitter.esm.js +1 -1
  312. package/dist/standalone/add-icons.d.ts +2 -0
  313. package/dist/standalone/add-icons.d.ts.map +1 -0
  314. package/dist/standalone/preload.d.ts +2 -0
  315. package/dist/standalone/preload.d.ts.map +1 -0
  316. package/dist/stepper.cjs.js +3 -3
  317. package/dist/stepper.esm.js +3 -3
  318. package/dist/switch.cjs.js +9 -9
  319. package/dist/switch.esm.js +56 -35
  320. package/dist/table.cjs.js +1 -1
  321. package/dist/table.esm.js +1 -1
  322. package/dist/tabs.cjs.js +14 -14
  323. package/dist/tabs.esm.js +129 -115
  324. package/dist/tags-input.cjs.js +1 -1
  325. package/dist/tags-input.esm.js +1 -1
  326. package/dist/textarea.cjs.js +33 -11
  327. package/dist/textarea.esm.js +74 -35
  328. package/dist/theme.d.ts +6 -0
  329. package/dist/theme.d.ts.map +1 -1
  330. package/dist/time-field.cjs.js +1 -1
  331. package/dist/time-field.esm.js +2 -2
  332. package/dist/time-picker.cjs.js +1 -1
  333. package/dist/time-picker.esm.js +3 -3
  334. package/dist/timeline.cjs.js +2 -2
  335. package/dist/timeline.esm.js +2 -2
  336. package/dist/toast.cjs.js +4 -4
  337. package/dist/toast.esm.js +17 -16
  338. package/dist/toggle-group.cjs.js +1 -1
  339. package/dist/toggle-group.esm.js +1 -1
  340. package/dist/toggle.cjs.js +3 -3
  341. package/dist/toggle.esm.js +9 -9
  342. package/dist/toolbar.cjs.js +1 -1
  343. package/dist/toolbar.esm.js +1 -1
  344. package/dist/tooltip.cjs.js +2 -2
  345. package/dist/tooltip.esm.js +12 -14
  346. package/dist/transfer-list.cjs.js +1 -1
  347. package/dist/transfer-list.esm.js +1 -1
  348. package/dist/{tree-33fVNnaf.mjs → tree-CD2k2lIC.mjs} +1 -1
  349. package/dist/{tree-Dc02MChE.js → tree-ChQfhxya.js} +1 -1
  350. package/dist/tree-item.cjs.js +1 -1
  351. package/dist/tree-item.esm.js +1 -1
  352. package/dist/tree.cjs.js +1 -1
  353. package/dist/tree.esm.js +1 -1
  354. package/dist/visually-hidden.cjs.js +1 -1
  355. package/dist/visually-hidden.esm.js +1 -1
  356. package/dist/wizard.cjs.js +4 -4
  357. package/dist/wizard.esm.js +4 -4
  358. package/package.json +3 -2
  359. package/dist/focus-scope-Bwug2gDv.js +0 -1
  360. package/dist/focus-scope-CmEsG5UZ.mjs +0 -138
  361. package/dist/runtime-CXw4SGV9.js +0 -5
  362. package/dist/ui-button-C3OmI7Sn.mjs +0 -684
  363. package/dist/ui-button-CnLwXBnx.js +0 -520
  364. package/dist/ui-icon-D3avtxX_.js +0 -207
  365. package/dist/ui-icon-DLhB08Fo.mjs +0 -361
@@ -3,58 +3,58 @@ import "./positioner-BE8Nbho2.mjs";
3
3
  function A() {
4
4
  return typeof window < "u" && typeof document < "u";
5
5
  }
6
- function B(n) {
7
- return n ? typeof n == "string" ? n : n instanceof Error && n.message ? n.message : "Something went wrong. Please try again." : "Something went wrong. Please try again.";
6
+ function V(t) {
7
+ return t ? typeof t == "string" ? t : t instanceof Error && t.message ? t.message : "Something went wrong. Please try again." : "Something went wrong. Please try again.";
8
8
  }
9
- function N(n) {
10
- return n === "replace" || n === "stack" ? n : "queue";
9
+ function Z(t) {
10
+ return t === "replace" || t === "stack" ? t : "queue";
11
11
  }
12
- function L(n) {
13
- return `ui-alert-dialog-${n}`;
12
+ function L(t) {
13
+ return `ui-alert-dialog-${t}`;
14
14
  }
15
- function V(n, a) {
16
- const e = n.kind === "alert" && a.action === "cancel" ? "dismiss" : a.action, t = n.dialog?.getChecked();
17
- if (n.kind === "prompt") {
18
- const i = n.dialog?.getInputValue() ?? n.value ?? "";
15
+ function U(t, a) {
16
+ const e = t.kind === "alert" && a.action === "cancel" ? "dismiss" : a.action, n = t.dialog?.getChecked();
17
+ if (t.kind === "prompt") {
18
+ const i = t.dialog?.getInputValue() ?? t.value ?? "";
19
19
  return {
20
- id: n.id,
20
+ id: t.id,
21
21
  action: e,
22
22
  value: i,
23
- checked: t,
23
+ checked: n,
24
24
  source: a.source,
25
25
  reason: a.reason
26
26
  };
27
27
  }
28
28
  return {
29
- id: n.id,
29
+ id: t.id,
30
30
  action: e,
31
- value: n.value,
32
- checked: t,
31
+ value: t.value,
32
+ checked: n,
33
33
  source: a.source,
34
34
  reason: a.reason
35
35
  };
36
36
  }
37
- function y(n, a, e) {
38
- return n.kind === "prompt" ? {
39
- id: n.id,
37
+ function y(t, a, e) {
38
+ return t.kind === "prompt" ? {
39
+ id: t.id,
40
40
  action: "dismiss",
41
- value: n.dialog?.getInputValue() ?? n.value ?? "",
42
- checked: n.dialog?.getChecked(),
41
+ value: t.dialog?.getInputValue() ?? t.value ?? "",
42
+ checked: t.dialog?.getChecked(),
43
43
  source: a,
44
44
  reason: e
45
45
  } : {
46
- id: n.id,
46
+ id: t.id,
47
47
  action: "dismiss",
48
- value: n.value,
49
- checked: n.dialog?.getChecked(),
48
+ value: t.value,
49
+ checked: t.dialog?.getChecked(),
50
50
  source: a,
51
51
  reason: e
52
52
  };
53
53
  }
54
- function Z(n) {
55
- return n === "esc" || n === "backdrop" || n === "close-icon" || n === "abort" || n === "unmount" || n === "replace" || n === "programmatic" ? n : "abort";
54
+ function G(t) {
55
+ return t === "esc" || t === "backdrop" || t === "close-icon" || t === "abort" || t === "unmount" || t === "replace" || t === "programmatic" ? t : "abort";
56
56
  }
57
- class U {
57
+ class Q {
58
58
  constructor(a) {
59
59
  this._container = null, this._ownsContainer = !1, this._queue = [], this._active = [], this._disposed = !1, this._seed = 0, this._defaults = {}, this._container = a ?? null;
60
60
  }
@@ -77,39 +77,39 @@ class U {
77
77
  this._disposed = !0;
78
78
  const e = [...this._active, ...this._queue];
79
79
  this._queue = [];
80
- for (const t of e)
81
- this._settle(t, y(t, a), !1);
80
+ for (const n of e)
81
+ this._settle(n, y(n, a), !1);
82
82
  this._active = [], this._ownsContainer && this._container && this._container.parentElement && this._container.parentElement.removeChild(this._container), this._container = null, this._ownsContainer = !1;
83
83
  }
84
84
  _enqueue(a, e) {
85
- const t = this._mergeOptions(e);
85
+ const n = this._mergeOptions(e);
86
86
  if (!A() || this._disposed) {
87
87
  const s = {
88
- id: t.id || L(++this._seed),
88
+ id: n.id || L(++this._seed),
89
89
  action: "dismiss",
90
90
  source: "unmount"
91
91
  };
92
92
  return Promise.resolve(s);
93
93
  }
94
- const i = t.id || L(++this._seed), r = N(t.mode);
94
+ const i = n.id || L(++this._seed), r = Z(n.mode);
95
95
  return new Promise((s) => {
96
96
  const c = {
97
97
  id: i,
98
98
  kind: a,
99
99
  mode: r,
100
- options: t,
100
+ options: n,
101
101
  settled: !1,
102
102
  processing: !1,
103
103
  resolve: s,
104
104
  cleanup: []
105
105
  };
106
- if (t.signal?.aborted) {
106
+ if (n.signal?.aborted) {
107
107
  this._settle(c, y(c, "abort"), !1);
108
108
  return;
109
109
  }
110
110
  if (r === "replace") {
111
- const d = this._active[this._active.length - 1];
112
- d && this._settle(d, y(d, "replace", "replace"), !1, !1), this._open(c);
111
+ const l = this._active[this._active.length - 1];
112
+ l && this._settle(l, y(l, "replace", "replace"), !1, !1), this._open(c);
113
113
  return;
114
114
  }
115
115
  if (r === "stack") {
@@ -129,62 +129,62 @@ class U {
129
129
  this._settle(a, y(a, "unmount"), !1);
130
130
  return;
131
131
  }
132
- const t = document.createElement("ui-alert-dialog");
133
- a.dialog = t, a.checked = !!a.options.checkbox?.defaultChecked;
132
+ const n = document.createElement("ui-alert-dialog");
133
+ a.dialog = n, a.checked = !!a.options.checkbox?.defaultChecked;
134
134
  const i = this._buildConfig(a);
135
- t.dialogId = a.id, t.config = i;
136
- const r = (d) => {
135
+ n.dialogId = a.id, n.config = i;
136
+ const r = (l) => {
137
137
  if (a.settled) return;
138
- const f = d.detail;
138
+ const f = l.detail;
139
139
  a.value = f?.inputValue, a.checked = f?.checked;
140
- const g = this._validatePrompt(a);
141
- if (g) {
142
- d.preventDefault(), t.setError(g);
140
+ const u = this._validatePrompt(a);
141
+ if (u) {
142
+ l.preventDefault(), n.setError(u);
143
143
  return;
144
144
  }
145
145
  if (!a.options.onConfirm) {
146
- t.clearError();
146
+ n.clearError();
147
147
  return;
148
148
  }
149
- d.preventDefault(), a.processing = !0, t.state = "loading", t.clearError(), Promise.resolve(
149
+ l.preventDefault(), a.processing = !0, n.state = "loading", n.clearError(), Promise.resolve(
150
150
  a.options.onConfirm({
151
151
  id: a.id,
152
152
  value: a.value,
153
153
  checked: a.checked,
154
- dialog: t,
154
+ dialog: n,
155
155
  signal: a.options.signal
156
156
  })
157
157
  ).then(() => {
158
- a.processing = !1, t.state = "idle", t.clearError(), a.settled || t.close("confirm");
159
- }).catch((m) => {
160
- a.processing = !1, t.state = "error", t.setError(B(m));
158
+ a.processing = !1, n.state = "idle", n.clearError(), a.settled || n.close("confirm");
159
+ }).catch((x) => {
160
+ a.processing = !1, n.state = "error", n.setError(V(x));
161
161
  });
162
162
  }, s = () => {
163
- a.settled || (a.value = t.getInputValue(), a.checked = t.getChecked(), t.state === "error" && t.clearError());
164
- }, c = (d) => {
163
+ a.settled || (a.value = n.getInputValue(), a.checked = n.getChecked(), n.state === "error" && n.clearError());
164
+ }, c = (l) => {
165
165
  if (a.settled) return;
166
- const f = d.detail;
166
+ const f = l.detail;
167
167
  this._handleClose(a, f);
168
168
  };
169
- if (t.addEventListener("ui-confirm", r), t.addEventListener("ui-change", s), t.addEventListener("ui-close", c), a.cleanup.push(() => t.removeEventListener("ui-confirm", r)), a.cleanup.push(() => t.removeEventListener("ui-change", s)), a.cleanup.push(() => t.removeEventListener("ui-close", c)), a.options.signal) {
170
- const d = () => {
169
+ if (n.addEventListener("ui-confirm", r), n.addEventListener("ui-change", s), n.addEventListener("ui-close", c), a.cleanup.push(() => n.removeEventListener("ui-confirm", r)), a.cleanup.push(() => n.removeEventListener("ui-change", s)), a.cleanup.push(() => n.removeEventListener("ui-close", c)), a.options.signal) {
170
+ const l = () => {
171
171
  a.settled || this._settle(a, y(a, "abort"), !1);
172
172
  };
173
- a.options.signal.addEventListener("abort", d, { once: !0 }), a.cleanup.push(() => a.options.signal?.removeEventListener("abort", d));
173
+ a.options.signal.addEventListener("abort", l, { once: !0 }), a.cleanup.push(() => a.options.signal?.removeEventListener("abort", l));
174
174
  }
175
- this._active.push(a), e.appendChild(t), t.open = !0, this._updateStackZIndex();
175
+ this._active.push(a), e.appendChild(n), n.open = !0, this._updateStackZIndex();
176
176
  }
177
177
  _validatePrompt(a) {
178
178
  if (a.kind !== "prompt") return null;
179
- const t = a.options.input, i = a.dialog?.getInputValue() ?? a.value ?? "";
180
- return t?.required && !i.trim() ? "Please enter a value." : t?.validate ? t.validate(i) : null;
179
+ const n = a.options.input, i = a.dialog?.getInputValue() ?? a.value ?? "";
180
+ return n?.required && !i.trim() ? "Please enter a value." : n?.validate ? n.validate(i) : null;
181
181
  }
182
- _settle(a, e, t, i = !0) {
182
+ _settle(a, e, n, i = !0) {
183
183
  if (!a.settled) {
184
184
  if (a.settled = !0, this._cleanupRequest(a), this._active = this._active.filter((r) => r !== a), this._queue = this._queue.filter((r) => r !== a), a.dialog) {
185
185
  const r = a.dialog;
186
- if (!t && r.open) {
187
- const s = Z(e.source);
186
+ if (!n && r.open) {
187
+ const s = G(e.source);
188
188
  r.close("dismiss", s, e.reason);
189
189
  }
190
190
  r.parentElement && r.parentElement.removeChild(r);
@@ -205,7 +205,7 @@ class U {
205
205
  a && this._open(a);
206
206
  }
207
207
  _buildConfig(a) {
208
- const e = a.options, t = a.kind === "prompt", i = a.kind === "alert", r = t ? e.input : void 0;
208
+ const e = a.options, n = a.kind === "prompt", i = a.kind === "alert", r = n ? e.input : void 0;
209
209
  return {
210
210
  id: a.id,
211
211
  title: e.title,
@@ -219,7 +219,7 @@ class U {
219
219
  closeOnBackdrop: e.closeOnBackdrop,
220
220
  lockWhileLoading: e.lockWhileLoading ?? !0,
221
221
  role: e.role || "alertdialog",
222
- tone: e.tone || (i ? "info" : t ? "neutral" : "warning"),
222
+ tone: e.tone || (i ? "info" : n ? "neutral" : "warning"),
223
223
  size: e.size || "md",
224
224
  variant: e.variant || "surface",
225
225
  radius: e.radius,
@@ -233,7 +233,7 @@ class U {
233
233
  showCancel: !i,
234
234
  showClose: e.dismissible ?? !0,
235
235
  input: {
236
- enabled: t,
236
+ enabled: n,
237
237
  label: r?.label,
238
238
  placeholder: r?.placeholder,
239
239
  value: r?.defaultValue || "",
@@ -256,10 +256,10 @@ class U {
256
256
  };
257
257
  }
258
258
  _handleClose(a, e) {
259
- const t = V(a, e);
259
+ const n = U(a, e);
260
260
  if (e.action === "cancel" && a.options.onCancel) {
261
261
  Promise.resolve(a.options.onCancel(this._buildLifecycleContext(a))).finally(() => {
262
- this._settle(a, t, !0);
262
+ this._settle(a, n, !0);
263
263
  });
264
264
  return;
265
265
  }
@@ -271,11 +271,11 @@ class U {
271
271
  reason: e.reason
272
272
  })
273
273
  ).finally(() => {
274
- this._settle(a, t, !0);
274
+ this._settle(a, n, !0);
275
275
  });
276
276
  return;
277
277
  }
278
- this._settle(a, t, !0);
278
+ this._settle(a, n, !0);
279
279
  }
280
280
  _mergeOptions(a) {
281
281
  const e = this._defaults;
@@ -302,37 +302,37 @@ class U {
302
302
  }
303
303
  }
304
304
  let h = null;
305
- function Q(n = {}) {
306
- return new U(n.container ?? null);
305
+ function W(t = {}) {
306
+ return new Q(t.container ?? null);
307
307
  }
308
308
  function T() {
309
- return h || (h = Q()), h;
309
+ return h || (h = W()), h;
310
310
  }
311
- function ma(n = {}) {
312
- return T().alert(n);
311
+ function ha(t = {}) {
312
+ return T().alert(t);
313
313
  }
314
- function xa(n = {}) {
315
- return T().confirm(n);
314
+ function ba(t = {}) {
315
+ return T().confirm(t);
316
316
  }
317
- function ha(n = {}) {
318
- return T().prompt(n);
317
+ function va(t = {}) {
318
+ return T().prompt(t);
319
319
  }
320
- function ba(n = "programmatic") {
321
- h && (h.destroy(n), h = null);
320
+ function ya(t = "programmatic") {
321
+ h && (h.destroy(t), h = null);
322
322
  }
323
323
  function I() {
324
324
  return typeof window < "u" && typeof document < "u";
325
325
  }
326
- function W(n) {
327
- return n === "replace" || n === "stack" ? n : "queue";
326
+ function X(t) {
327
+ return t === "replace" || t === "stack" ? t : "queue";
328
328
  }
329
- function O(n) {
330
- return `ui-dialog-${n}`;
329
+ function O(t) {
330
+ return `ui-dialog-${t}`;
331
331
  }
332
- function G(n) {
333
- return n ? typeof n == "string" ? n : n instanceof Error && n.message ? n.message : "Something went wrong. Please try again." : "Something went wrong. Please try again.";
332
+ function K(t) {
333
+ return t ? typeof t == "string" ? t : t instanceof Error && t.message ? t.message : "Something went wrong. Please try again." : "Something went wrong. Please try again.";
334
334
  }
335
- class X {
335
+ class Y {
336
336
  constructor(a) {
337
337
  this._container = null, this._ownsContainer = !1, this._queue = [], this._active = [], this._disposed = !1, this._seed = 0, this._container = a ?? null;
338
338
  }
@@ -349,9 +349,9 @@ class X {
349
349
  this._disposed = !0;
350
350
  const e = [...this._active, ...this._queue];
351
351
  this._queue = [];
352
- for (const t of e)
353
- this._settle(t, {
354
- id: t.id,
352
+ for (const n of e)
353
+ this._settle(n, {
354
+ id: n.id,
355
355
  action: "dismiss",
356
356
  source: a,
357
357
  reason: a
@@ -365,11 +365,11 @@ class X {
365
365
  action: "dismiss",
366
366
  source: "unmount"
367
367
  });
368
- const e = a.id || O(++this._seed), t = W(a.mode);
368
+ const e = a.id || O(++this._seed), n = X(a.mode);
369
369
  return new Promise((i) => {
370
370
  const r = {
371
371
  id: e,
372
- mode: t,
372
+ mode: n,
373
373
  options: a,
374
374
  settled: !1,
375
375
  resolve: i,
@@ -379,12 +379,12 @@ class X {
379
379
  this._settle(r, { id: e, action: "dismiss", source: "abort" }, !1);
380
380
  return;
381
381
  }
382
- if (t === "replace") {
382
+ if (n === "replace") {
383
383
  const s = this._active[this._active.length - 1];
384
384
  s && this._settle(s, { id: s.id, action: "dismiss", source: "replace", reason: "replace" }, !1, !1), this._open(r);
385
385
  return;
386
386
  }
387
- if (t === "stack") {
387
+ if (n === "stack") {
388
388
  this._open(r);
389
389
  return;
390
390
  }
@@ -405,41 +405,41 @@ class X {
405
405
  }, !1);
406
406
  return;
407
407
  }
408
- const t = document.createElement("ui-dialog");
409
- a.dialog = t;
408
+ const n = document.createElement("ui-dialog");
409
+ a.dialog = n;
410
410
  const i = this._buildConfig(a.options, a.id);
411
- t.dialogId = a.id, t.config = i;
411
+ n.dialogId = a.id, n.config = i;
412
412
  const r = (c) => {
413
413
  if (a.settled) return;
414
- const d = c.detail;
415
- if (a.resultFormData = d?.formData, !a.options.onSubmit) {
416
- t.clearError();
414
+ const l = c.detail;
415
+ if (a.resultFormData = l?.formData, !a.options.onSubmit) {
416
+ n.clearError();
417
417
  return;
418
418
  }
419
- c.preventDefault(), t.state = "loading", t.clearError(), Promise.resolve(
419
+ c.preventDefault(), n.state = "loading", n.clearError(), Promise.resolve(
420
420
  a.options.onSubmit({
421
421
  id: a.id,
422
- dialog: t,
422
+ dialog: n,
423
423
  signal: a.options.signal,
424
- formData: d?.formData
424
+ formData: l?.formData
425
425
  })
426
426
  ).then(() => {
427
- a.settled || (t.state = "idle", t.clearError(), t.close("submit"));
427
+ a.settled || (n.state = "idle", n.clearError(), n.close("submit"));
428
428
  }).catch((f) => {
429
- t.state = "error", t.setError(G(f));
429
+ n.state = "error", n.setError(K(f));
430
430
  });
431
431
  }, s = (c) => {
432
432
  if (a.settled) return;
433
- const d = c.detail;
433
+ const l = c.detail;
434
434
  this._settle(a, {
435
435
  id: a.id,
436
- action: d.action,
437
- source: d.source,
438
- reason: d.reason,
436
+ action: l.action,
437
+ source: l.source,
438
+ reason: l.reason,
439
439
  formData: a.resultFormData
440
440
  }, !0);
441
441
  };
442
- if (t.addEventListener("ui-submit", r), t.addEventListener("ui-close", s), a.cleanup.push(() => t.removeEventListener("ui-submit", r)), a.cleanup.push(() => t.removeEventListener("ui-close", s)), a.options.signal) {
442
+ if (n.addEventListener("ui-submit", r), n.addEventListener("ui-close", s), a.cleanup.push(() => n.removeEventListener("ui-submit", r)), a.cleanup.push(() => n.removeEventListener("ui-close", s)), a.options.signal) {
443
443
  const c = () => {
444
444
  a.settled || this._settle(a, {
445
445
  id: a.id,
@@ -449,13 +449,13 @@ class X {
449
449
  };
450
450
  a.options.signal.addEventListener("abort", c, { once: !0 }), a.cleanup.push(() => a.options.signal?.removeEventListener("abort", c));
451
451
  }
452
- this._active.push(a), e.appendChild(t), t.openDialog(), this._updateStackZIndex();
452
+ this._active.push(a), e.appendChild(n), n.openDialog(), this._updateStackZIndex();
453
453
  }
454
- _settle(a, e, t, i = !0) {
454
+ _settle(a, e, n, i = !0) {
455
455
  if (!a.settled) {
456
456
  if (a.settled = !0, this._cleanupRequest(a), this._active = this._active.filter((r) => r !== a), this._queue = this._queue.filter((r) => r !== a), a.dialog) {
457
457
  const r = a.dialog;
458
- !t && r.open && r.close("dismiss", e.source || "abort", e.reason), r.parentElement && r.parentElement.removeChild(r);
458
+ !n && r.open && r.close("dismiss", e.source || "abort", e.reason), r.parentElement && r.parentElement.removeChild(r);
459
459
  }
460
460
  a.resolve(e), this._updateStackZIndex(), !this._disposed && i && this._drainQueue();
461
461
  }
@@ -510,35 +510,49 @@ class X {
510
510
  }
511
511
  }
512
512
  let b = null;
513
- function K(n = {}) {
514
- return new X(n.container ?? null);
513
+ function J(t = {}) {
514
+ return new Y(t.container ?? null);
515
515
  }
516
- function D() {
517
- return b || (b = K()), b;
516
+ function R() {
517
+ return b || (b = J()), b;
518
518
  }
519
- function va(n = {}) {
520
- return D().open(n);
519
+ function wa(t = {}) {
520
+ return R().open(t);
521
521
  }
522
- function ya(n = {}) {
523
- return D().confirm(n);
522
+ function ka(t = {}) {
523
+ return R().confirm(t);
524
524
  }
525
- function wa(n = "programmatic") {
526
- b && (b.destroy(n), b = null);
525
+ function _a(t = "programmatic") {
526
+ b && (b.destroy(t), b = null);
527
527
  }
528
- const J = ["1", "2", "3", "4"], Y = { 1: "24px", 2: "32px", 3: "40px", 4: "48px" }, q = { 1: "12px", 2: "14px", 3: "16px", 4: "18px" }, aa = { 1: "8px", 2: "12px", 3: "16px", 4: "20px" }, ea = { 1: 0, 2: 0, 3: 2, 4: 4 };
529
- function na(n) {
530
- const a = n.palette?.gray || {}, e = n.palette?.accent || {}, t = n.radiusScale || {}, i = n.colors, r = {}, s = (c, d) => {
531
- d && (r[c] = d);
528
+ const q = ["1", "2", "3", "4"], aa = {
529
+ compact: { 1: "20px", 2: "28px", 3: "36px", 4: "44px" },
530
+ default: { 1: "24px", 2: "32px", 3: "40px", 4: "48px" },
531
+ comfortable: { 1: "28px", 2: "36px", 3: "44px", 4: "52px" }
532
+ }, ea = {
533
+ compact: { 1: "12px", 2: "13px", 3: "15px", 4: "17px" },
534
+ default: { 1: "12px", 2: "14px", 3: "16px", 4: "18px" },
535
+ comfortable: { 1: "13px", 2: "15px", 3: "16px", 4: "18px" }
536
+ }, ta = {
537
+ compact: { 1: "6px", 2: "10px", 3: "14px", 4: "18px" },
538
+ default: { 1: "8px", 2: "12px", 3: "16px", 4: "20px" },
539
+ comfortable: { 1: "10px", 2: "14px", 3: "18px", 4: "22px" }
540
+ }, P = { compact: "6px", default: "8px", comfortable: "12px" }, na = { 1: 0, 2: 0, 3: 2, 4: 4 };
541
+ function ra(t) {
542
+ const a = t.palette?.gray || {}, e = t.palette?.accent || {}, n = t.radiusScale || {}, i = t.colors, r = {}, s = (l, f) => {
543
+ f && (r[l] = f);
532
544
  };
533
- s("--ui-color-surface-subtle", a[2]), s("--ui-color-fill", a[3]), s("--ui-color-fill-hover", a[4]), s("--ui-color-fill-active", a[5]), s("--ui-color-line-subtle", a[6]), s("--ui-color-line", a[7]), s("--ui-color-line-strong", a[8]), s("--ui-color-text-secondary", a[11] || i.muted), s("--ui-color-text-strong", a[12] || i.text), s("--ui-color-accent-subtle", e[2]), s("--ui-color-accent-fill", e[3]), s("--ui-color-accent-fill-hover", e[4]), s("--ui-color-accent-fill-active", e[5]), s("--ui-color-accent-line", e[7]), s("--ui-color-accent-solid", e[9] || i.primary), s("--ui-color-accent-solid-hover", e[10] || i.primaryHover || i.primary), s("--ui-color-accent-text", e[11]), s("--ui-color-surface-elevated", n.surfaces?.panelSolid || i.surfaceAlt || i.surface), s("--ui-color-info", i.info), s("--ui-color-placeholder", i.text ? `color-mix(in srgb, ${i.text} 62%, transparent)` : void 0), s("--ui-ring-color", i.focusRing || i.primary), r["--ui-ring-width"] = "2px", r["--ui-ring-offset"] = "2px";
534
- for (const c of J) {
535
- r[`--ui-control-height-${c}`] = Y[c], r[`--ui-control-font-size-${c}`] = q[c], r[`--ui-control-padding-inline-${c}`] = aa[c];
536
- const d = ea[c], f = n.radius || t[2] || "6px";
537
- r[`--ui-control-radius-${c}`] = d ? `calc(${f} + ${d}px)` : f;
545
+ s("--ui-color-surface-subtle", a[2]), s("--ui-color-fill", a[3]), s("--ui-color-fill-hover", a[4]), s("--ui-color-fill-active", a[5]), s("--ui-color-line-subtle", a[6]), s("--ui-color-line", a[7]), s("--ui-color-line-strong", a[8]), s("--ui-color-text-secondary", a[11] || i.muted), s("--ui-color-text-strong", a[12] || i.text), s("--ui-color-accent-subtle", e[2]), s("--ui-color-accent-fill", e[3]), s("--ui-color-accent-fill-hover", e[4]), s("--ui-color-accent-fill-active", e[5]), s("--ui-color-accent-line", e[7]), s("--ui-color-accent-solid", e[9] || i.primary), s("--ui-color-accent-solid-hover", e[10] || i.primaryHover || i.primary), s("--ui-color-accent-text", e[11]), s("--ui-color-accent-on-dark", i.primary ? `color-mix(in srgb, ${i.primary} 45%, #ffffff)` : void 0), s("--ui-color-surface-elevated", t.surfaces?.panelSolid || i.surfaceAlt || i.surface), s("--ui-color-info", i.info), s("--ui-color-placeholder", i.text ? `color-mix(in srgb, ${i.text} 62%, transparent)` : void 0), s("--ui-ring-color", i.focusRing || i.primary), r["--ui-ring-width"] = "2px", r["--ui-ring-offset"] = "2px";
546
+ const c = t.density === "compact" || t.density === "comfortable" ? t.density : "default";
547
+ r["--ui-density"] = c, r["--ui-density-gap"] = P[c], r["--ui-default-gap"] = P[c];
548
+ for (const l of q) {
549
+ r[`--ui-control-height-${l}`] = aa[c][l], r[`--ui-control-font-size-${l}`] = ea[c][l], r[`--ui-control-padding-inline-${l}`] = ta[c][l];
550
+ const f = na[l], u = t.radius || n[2] || "6px";
551
+ r[`--ui-control-radius-${l}`] = f ? `calc(${u} + ${f}px)` : u;
538
552
  }
539
- return r["--ui-motion-enter-easing"] = "cubic-bezier(0.16, 1, 0.3, 1)", r["--ui-motion-exit-easing"] = "cubic-bezier(0.4, 0, 1, 1)", s("--ui-font-family-mono", n.typography?.codeFamily || "monospace"), s("--font-mono", n.typography?.codeFamily || "monospace"), s("--ui-breakpoint-xl", n.breakpoints?.xl || "1280px"), r;
553
+ return r["--ui-motion-enter-easing"] = "cubic-bezier(0.16, 1, 0.3, 1)", r["--ui-motion-exit-easing"] = "cubic-bezier(0.4, 0, 1, 1)", s("--ui-font-family-mono", t.typography?.codeFamily || "monospace"), s("--font-mono", t.typography?.codeFamily || "monospace"), s("--ui-breakpoint-xl", t.breakpoints?.xl || "1280px"), r;
540
554
  }
541
- const M = {
555
+ const $ = {
542
556
  1: "#0000000d",
543
557
  2: "#0000001a",
544
558
  3: "#00000026",
@@ -551,7 +565,7 @@ const M = {
551
565
  10: "#000c",
552
566
  11: "#000000e6",
553
567
  12: "#000000f2"
554
- }, R = {
568
+ }, H = {
555
569
  1: "#ffffff0d",
556
570
  2: "#ffffff1a",
557
571
  3: "#ffffff26",
@@ -564,7 +578,7 @@ const M = {
564
578
  10: "#fffc",
565
579
  11: "#ffffffe6",
566
580
  12: "#fffffff2"
567
- }, u = {
581
+ }, g = {
568
582
  amber: {
569
583
  light: {
570
584
  scale: {
@@ -915,7 +929,7 @@ const M = {
915
929
  track: "#7b7b7b"
916
930
  }
917
931
  }
918
- }, ta = {
932
+ }, ia = {
919
933
  button: {
920
934
  "classic-after-inset": "2px",
921
935
  "classic-box-shadow-top": "inset 0 0 0 1px var(--gray-a5), inset 0 1px 1px var(--white-a10)",
@@ -1164,7 +1178,7 @@ const M = {
1164
1178
  input: {
1165
1179
  bg: "var(--color-panel-solid)"
1166
1180
  }
1167
- }, ra = {
1181
+ }, oa = {
1168
1182
  button: {
1169
1183
  "classic-after-inset": "1px",
1170
1184
  "classic-box-shadow-top": "inset 0 0 0 1px var(--white-a2), inset 0 4px 2px -2px var(--white-a3), inset 0 1px 1px var(--white-a6), inset 0 -1px 1px var(--black-a6)",
@@ -1414,38 +1428,38 @@ const M = {
1414
1428
  bg: "var(--color-panel-solid)"
1415
1429
  }
1416
1430
  };
1417
- function w(n) {
1418
- const a = /^#([0-9a-f]{3}|[0-9a-f]{6}|[0-9a-f]{8})$/i.exec(n.trim())?.[1];
1431
+ function w(t) {
1432
+ const a = /^#([0-9a-f]{3}|[0-9a-f]{6}|[0-9a-f]{8})$/i.exec(t.trim())?.[1];
1419
1433
  if (!a) return null;
1420
- const e = a.length === 3 ? a.replace(/./g, (i) => i + i) : a.slice(0, 6), t = (i) => {
1434
+ const e = a.length === 3 ? a.replace(/./g, (i) => i + i) : a.slice(0, 6), n = (i) => {
1421
1435
  const r = parseInt(e.slice(i, i + 2), 16) / 255;
1422
1436
  return r <= 0.03928 ? r / 12.92 : ((r + 0.055) / 1.055) ** 2.4;
1423
1437
  };
1424
- return 0.2126 * t(0) + 0.7152 * t(2) + 0.0722 * t(4);
1438
+ return 0.2126 * n(0) + 0.7152 * n(2) + 0.0722 * n(4);
1425
1439
  }
1426
- function v(n, a) {
1427
- const e = w(n), t = w(a);
1428
- return e === null || t === null ? null : (Math.max(e, t) + 0.05) / (Math.min(e, t) + 0.05);
1440
+ function v(t, a) {
1441
+ const e = w(t), n = w(a);
1442
+ return e === null || n === null ? null : (Math.max(e, n) + 0.05) / (Math.min(e, n) + 0.05);
1429
1443
  }
1430
- function ia(n, a) {
1431
- const e = n?.colors;
1444
+ function sa(t, a) {
1445
+ const e = t?.colors;
1432
1446
  if (!e?.primary) return {};
1433
- const t = e.foregroundOnPrimary;
1434
- return a ? e.primary === a.colors?.primary ? {} : t && t !== a.colors?.foregroundOnPrimary ? {} : { foregroundOnPrimary: k(e.primary, a.colors?.foregroundOnPrimary || "#ffffff") } : t ? {} : { foregroundOnPrimary: k(e.primary, "#ffffff") };
1447
+ const n = e.foregroundOnPrimary;
1448
+ return a ? e.primary === a.colors?.primary ? {} : n && n !== a.colors?.foregroundOnPrimary ? {} : { foregroundOnPrimary: k(e.primary, a.colors?.foregroundOnPrimary || "#ffffff") } : n ? {} : { foregroundOnPrimary: k(e.primary, "#ffffff") };
1435
1449
  }
1436
- function k(n, a) {
1437
- const e = v(a, n);
1450
+ function k(t, a) {
1451
+ const e = v(a, t);
1438
1452
  if (e === null || e >= 4.5) return a;
1439
- const t = v("#ffffff", n) ?? 0;
1440
- return (v("#111111", n) ?? 0) > t ? "#111111" : "#ffffff";
1453
+ const n = v("#ffffff", t) ?? 0;
1454
+ return (v("#111111", t) ?? 0) > n ? "#111111" : "#ffffff";
1441
1455
  }
1442
- function $(n) {
1456
+ function F(t) {
1443
1457
  return {
1444
- primary: n.scale[9],
1445
- primaryHover: n.scale[10] || n.scale[9],
1446
- foregroundOnPrimary: k(n.scale[9], n.contrast),
1447
- focusRing: n.scale[8] || n.scale[9],
1448
- warning: n.scale[9]
1458
+ primary: t.scale[9],
1459
+ primaryHover: t.scale[10] || t.scale[9],
1460
+ foregroundOnPrimary: k(t.scale[9], t.contrast),
1461
+ focusRing: t.scale[8] || t.scale[9],
1462
+ warning: t.scale[9]
1449
1463
  };
1450
1464
  }
1451
1465
  const _ = {
@@ -1494,18 +1508,18 @@ const _ = {
1494
1508
  11: "#0000009b",
1495
1509
  12: "#000000df"
1496
1510
  },
1497
- blackAlpha: M,
1498
- whiteAlpha: R,
1511
+ blackAlpha: $,
1512
+ whiteAlpha: H,
1499
1513
  accent: {
1500
- ...u.amber.light.scale
1514
+ ...g.amber.light.scale
1501
1515
  },
1502
1516
  accentAlpha: {
1503
- ...u.amber.light.alphaScale
1517
+ ...g.amber.light.alphaScale
1504
1518
  },
1505
- accentContrast: u.amber.light.contrast,
1506
- accentSurface: u.amber.light.surface,
1507
- accentIndicator: u.amber.light.indicator,
1508
- accentTrack: u.amber.light.track
1519
+ accentContrast: g.amber.light.contrast,
1520
+ accentSurface: g.amber.light.surface,
1521
+ accentIndicator: g.amber.light.indicator,
1522
+ accentTrack: g.amber.light.track
1509
1523
  },
1510
1524
  surfaces: {
1511
1525
  background: "#ffffff",
@@ -1603,10 +1617,10 @@ const _ = {
1603
1617
  effects: {
1604
1618
  backdropFilterPanel: "blur(64px)"
1605
1619
  },
1606
- components: ta,
1620
+ components: ia,
1607
1621
  zIndex: { modal: 1e3, overlay: 900, toast: 1100 },
1608
1622
  breakpoints: { sm: "640px", md: "768px", lg: "1024px" }
1609
- }, oa = {
1623
+ }, ca = {
1610
1624
  ..._,
1611
1625
  colors: {
1612
1626
  primary: "#ffc53d",
@@ -1654,18 +1668,18 @@ const _ = {
1654
1668
  11: "#ffffffaf",
1655
1669
  12: "#ffffffed"
1656
1670
  },
1657
- blackAlpha: M,
1658
- whiteAlpha: R,
1671
+ blackAlpha: $,
1672
+ whiteAlpha: H,
1659
1673
  accent: {
1660
- ...u.amber.dark.scale
1674
+ ...g.amber.dark.scale
1661
1675
  },
1662
1676
  accentAlpha: {
1663
- ...u.amber.dark.alphaScale
1677
+ ...g.amber.dark.alphaScale
1664
1678
  },
1665
- accentContrast: u.amber.dark.contrast,
1666
- accentSurface: u.amber.dark.surface,
1667
- accentIndicator: u.amber.dark.indicator,
1668
- accentTrack: u.amber.dark.track
1679
+ accentContrast: g.amber.dark.contrast,
1680
+ accentSurface: g.amber.dark.surface,
1681
+ accentIndicator: g.amber.dark.indicator,
1682
+ accentTrack: g.amber.dark.track
1669
1683
  },
1670
1684
  surfaces: {
1671
1685
  background: "#111111",
@@ -1687,25 +1701,25 @@ const _ = {
1687
1701
  5: "0 0 0 1px var(--gray-a6),0 12px 60px var(--black-a5),0 12px 32px -16px var(--black-a7)",
1688
1702
  6: "0 0 0 1px var(--gray-a6),0 12px 60px var(--black-a4),0 16px 64px var(--black-a6),0 16px 36px -20px var(--black-a11)"
1689
1703
  },
1690
- components: ra
1691
- }, ka = _, H = /* @__PURE__ */ new Set();
1692
- function p(n, a) {
1693
- if (!(!n && !a))
1694
- return { ...n || {}, ...a || {} };
1704
+ components: oa
1705
+ }, Sa = _, j = /* @__PURE__ */ new Set();
1706
+ function d(t, a) {
1707
+ if (!(!t && !a))
1708
+ return { ...t || {}, ...a || {} };
1695
1709
  }
1696
- function sa(n) {
1697
- const a = n?.colors, e = n?.surfaces || {}, t = {};
1698
- if (!a) return t;
1699
- if (a.background && !e.background && (t.background = a.background), a.surface) {
1710
+ function la(t) {
1711
+ const a = t?.colors, e = t?.surfaces || {}, n = {};
1712
+ if (!a) return n;
1713
+ if (a.background && !e.background && (n.background = a.background), a.surface) {
1700
1714
  const i = `color-mix(in srgb, ${a.surface} 80%, transparent)`;
1701
- e.surface || (t.surface = a.surface), e.panelSolid || (t.panelSolid = a.surface), e.panel || (t.panel = i), e.panelTranslucent || (t.panelTranslucent = i);
1715
+ e.surface || (n.surface = a.surface), e.panelSolid || (n.panelSolid = a.surface), e.panel || (n.panel = i), e.panelTranslucent || (n.panelTranslucent = i);
1702
1716
  }
1703
- return t;
1717
+ return n;
1704
1718
  }
1705
- function S(n, a) {
1706
- const e = a?.mode || "light", t = e === "dark" ? oa : _, i = a?.accentPalette, r = i ? u[i][e] : null, s = r ? {
1719
+ function S(t, a) {
1720
+ const e = a?.mode || "light", n = e === "dark" ? ca : _, i = a?.accentPalette, r = i ? g[i][e] : null, s = r ? {
1707
1721
  colors: {
1708
- ...$(r)
1722
+ ...F(r)
1709
1723
  },
1710
1724
  palette: {
1711
1725
  accent: r.scale,
@@ -1717,147 +1731,147 @@ function S(n, a) {
1717
1731
  }
1718
1732
  } : null;
1719
1733
  return {
1720
- ...t,
1721
1734
  ...n,
1735
+ ...t,
1722
1736
  colors: {
1723
- ...t.colors,
1737
+ ...n.colors,
1724
1738
  ...s?.colors || {},
1725
- ...n?.colors || {},
1726
- ...ia(n)
1739
+ ...t?.colors || {},
1740
+ ...sa(t)
1727
1741
  },
1728
1742
  palette: {
1729
- ...t.palette || {},
1743
+ ...n.palette || {},
1730
1744
  ...s?.palette || {},
1731
- ...n?.palette || {},
1732
- gray: p(t.palette?.gray, n?.palette?.gray),
1733
- grayAlpha: p(t.palette?.grayAlpha, n?.palette?.grayAlpha),
1734
- blackAlpha: p(t.palette?.blackAlpha, n?.palette?.blackAlpha),
1735
- whiteAlpha: p(t.palette?.whiteAlpha, n?.palette?.whiteAlpha),
1736
- accent: p(r?.scale || t.palette?.accent, n?.palette?.accent),
1737
- accentAlpha: p(r?.alphaScale || t.palette?.accentAlpha, n?.palette?.accentAlpha)
1745
+ ...t?.palette || {},
1746
+ gray: d(n.palette?.gray, t?.palette?.gray),
1747
+ grayAlpha: d(n.palette?.grayAlpha, t?.palette?.grayAlpha),
1748
+ blackAlpha: d(n.palette?.blackAlpha, t?.palette?.blackAlpha),
1749
+ whiteAlpha: d(n.palette?.whiteAlpha, t?.palette?.whiteAlpha),
1750
+ accent: d(r?.scale || n.palette?.accent, t?.palette?.accent),
1751
+ accentAlpha: d(r?.alphaScale || n.palette?.accentAlpha, t?.palette?.accentAlpha)
1738
1752
  },
1739
1753
  surfaces: {
1740
- ...t.surfaces || {},
1741
- ...sa(n),
1742
- ...n?.surfaces || {}
1754
+ ...n.surfaces || {},
1755
+ ...la(t),
1756
+ ...t?.surfaces || {}
1743
1757
  },
1744
1758
  shadows: {
1745
- ...t.shadows || {},
1746
- ...n?.shadows || {}
1759
+ ...n.shadows || {},
1760
+ ...t?.shadows || {}
1747
1761
  },
1748
1762
  spacing: {
1749
- ...t.spacing || {},
1750
- ...n?.spacing || {}
1763
+ ...n.spacing || {},
1764
+ ...t?.spacing || {}
1751
1765
  },
1752
- spaceScale: p(t.spaceScale, n?.spaceScale),
1753
- radiusScale: p(t.radiusScale, n?.radiusScale),
1766
+ spaceScale: d(n.spaceScale, t?.spaceScale),
1767
+ radiusScale: d(n.radiusScale, t?.radiusScale),
1754
1768
  typography: {
1755
- ...t.typography || {},
1756
- ...n?.typography || {},
1769
+ ...n.typography || {},
1770
+ ...t?.typography || {},
1757
1771
  size: {
1758
- ...t.typography?.size || {},
1759
- ...n?.typography?.size || {}
1772
+ ...n.typography?.size || {},
1773
+ ...t?.typography?.size || {}
1760
1774
  },
1761
- fontScale: p(t.typography?.fontScale, n?.typography?.fontScale),
1762
- lineHeight: p(t.typography?.lineHeight, n?.typography?.lineHeight),
1763
- letterSpacing: p(t.typography?.letterSpacing, n?.typography?.letterSpacing)
1775
+ fontScale: d(n.typography?.fontScale, t?.typography?.fontScale),
1776
+ lineHeight: d(n.typography?.lineHeight, t?.typography?.lineHeight),
1777
+ letterSpacing: d(n.typography?.letterSpacing, t?.typography?.letterSpacing)
1764
1778
  },
1765
1779
  motion: {
1766
- ...t.motion || {},
1767
- ...n?.motion || {}
1780
+ ...n.motion || {},
1781
+ ...t?.motion || {}
1768
1782
  },
1769
1783
  effects: {
1770
- ...t.effects || {},
1771
- ...n?.effects || {}
1784
+ ...n.effects || {},
1785
+ ...t?.effects || {}
1772
1786
  },
1773
1787
  components: {
1774
- ...t.components || {},
1775
- ...n?.components || {},
1776
- button: p(t.components?.button, n?.components?.button),
1777
- badge: p(t.components?.badge, n?.components?.badge),
1778
- dropdown: p(t.components?.dropdown, n?.components?.dropdown),
1779
- select: p(t.components?.select, n?.components?.select),
1780
- sidebar: p(t.components?.sidebar, n?.components?.sidebar),
1781
- card: p(t.components?.card, n?.components?.card),
1782
- navigationMenu: p(t.components?.navigationMenu, n?.components?.navigationMenu),
1783
- blockControls: p(t.components?.blockControls, n?.components?.blockControls),
1784
- box: p(t.components?.box, n?.components?.box),
1785
- breadcrumb: p(t.components?.breadcrumb, n?.components?.breadcrumb),
1786
- contextMenu: p(t.components?.contextMenu, n?.components?.contextMenu),
1787
- menubar: p(t.components?.menubar, n?.components?.menubar),
1788
- alert: p(t.components?.alert, n?.components?.alert),
1789
- alertDialog: p(t.components?.alertDialog, n?.components?.alertDialog),
1790
- appHeader: p(t.components?.appHeader, n?.components?.appHeader),
1791
- aspectRatio: p(t.components?.aspectRatio, n?.components?.aspectRatio),
1792
- avatar: p(t.components?.avatar, n?.components?.avatar),
1793
- menu: p(t.components?.menu, n?.components?.menu),
1794
- multiSelect: p(t.components?.multiSelect, n?.components?.multiSelect),
1795
- panel: p(t.components?.panel, n?.components?.panel),
1796
- input: p(t.components?.input, n?.components?.input)
1788
+ ...n.components || {},
1789
+ ...t?.components || {},
1790
+ button: d(n.components?.button, t?.components?.button),
1791
+ badge: d(n.components?.badge, t?.components?.badge),
1792
+ dropdown: d(n.components?.dropdown, t?.components?.dropdown),
1793
+ select: d(n.components?.select, t?.components?.select),
1794
+ sidebar: d(n.components?.sidebar, t?.components?.sidebar),
1795
+ card: d(n.components?.card, t?.components?.card),
1796
+ navigationMenu: d(n.components?.navigationMenu, t?.components?.navigationMenu),
1797
+ blockControls: d(n.components?.blockControls, t?.components?.blockControls),
1798
+ box: d(n.components?.box, t?.components?.box),
1799
+ breadcrumb: d(n.components?.breadcrumb, t?.components?.breadcrumb),
1800
+ contextMenu: d(n.components?.contextMenu, t?.components?.contextMenu),
1801
+ menubar: d(n.components?.menubar, t?.components?.menubar),
1802
+ alert: d(n.components?.alert, t?.components?.alert),
1803
+ alertDialog: d(n.components?.alertDialog, t?.components?.alertDialog),
1804
+ appHeader: d(n.components?.appHeader, t?.components?.appHeader),
1805
+ aspectRatio: d(n.components?.aspectRatio, t?.components?.aspectRatio),
1806
+ avatar: d(n.components?.avatar, t?.components?.avatar),
1807
+ menu: d(n.components?.menu, t?.components?.menu),
1808
+ multiSelect: d(n.components?.multiSelect, t?.components?.multiSelect),
1809
+ panel: d(n.components?.panel, t?.components?.panel),
1810
+ input: d(n.components?.input, t?.components?.input)
1797
1811
  },
1798
1812
  zIndex: {
1799
- ...t.zIndex || {},
1800
- ...n?.zIndex || {}
1813
+ ...n.zIndex || {},
1814
+ ...t?.zIndex || {}
1801
1815
  },
1802
1816
  breakpoints: {
1803
- ...t.breakpoints || {},
1804
- ...n?.breakpoints || {}
1817
+ ...n.breakpoints || {},
1818
+ ...t?.breakpoints || {}
1805
1819
  }
1806
1820
  };
1807
1821
  }
1808
- function _a(n, a, e = "light") {
1809
- const t = u[a][e], i = n;
1822
+ function Ca(t, a, e = "light") {
1823
+ const n = g[a][e], i = t;
1810
1824
  return S(
1811
1825
  {
1812
1826
  ...i,
1813
1827
  colors: {
1814
1828
  ...i.colors || {},
1815
- ...$(t)
1829
+ ...F(n)
1816
1830
  },
1817
1831
  palette: {
1818
1832
  ...i.palette || {},
1819
- accent: t.scale,
1820
- accentAlpha: t.alphaScale,
1821
- accentContrast: t.contrast,
1822
- accentSurface: t.surface,
1823
- accentIndicator: t.indicator,
1824
- accentTrack: t.track
1833
+ accent: n.scale,
1834
+ accentAlpha: n.alphaScale,
1835
+ accentContrast: n.contrast,
1836
+ accentSurface: n.surface,
1837
+ accentIndicator: n.indicator,
1838
+ accentTrack: n.track
1825
1839
  }
1826
1840
  },
1827
1841
  { mode: e }
1828
1842
  );
1829
1843
  }
1830
- function o(n, a, e) {
1831
- n[a] = e;
1844
+ function o(t, a, e) {
1845
+ t[a] = e;
1832
1846
  }
1833
- function l(n, a, e) {
1834
- e && Object.entries(e).forEach(([t, i]) => {
1835
- typeof i == "string" && i && (n[`${a}${t}`] = i);
1847
+ function p(t, a, e) {
1848
+ e && Object.entries(e).forEach(([n, i]) => {
1849
+ typeof i == "string" && i && (t[`${a}${n}`] = i);
1836
1850
  });
1837
1851
  }
1838
- function Sa(n) {
1839
- n && H.add(n);
1852
+ function za(t) {
1853
+ t && j.add(t);
1840
1854
  }
1841
- function ca(n) {
1842
- return F(S(n));
1855
+ function pa(t) {
1856
+ return N(S(t));
1843
1857
  }
1844
- const la = /^#([0-9a-f]{3}|[0-9a-f]{6})$/i;
1845
- function E(n) {
1846
- const a = la.exec(n.trim());
1858
+ const da = /^#([0-9a-f]{3}|[0-9a-f]{6})$/i;
1859
+ function E(t) {
1860
+ const a = da.exec(t.trim());
1847
1861
  if (!a) return null;
1848
- const e = a[1].length === 3 ? a[1].replace(/./g, (t) => t + t) : a[1];
1862
+ const e = a[1].length === 3 ? a[1].replace(/./g, (n) => n + n) : a[1];
1849
1863
  return [parseInt(e.slice(0, 2), 16), parseInt(e.slice(2, 4), 16), parseInt(e.slice(4, 6), 16)];
1850
1864
  }
1851
- function z(n, a, e) {
1852
- const t = E(n), i = E(a);
1853
- return !t || !i ? null : "#" + t.map((s, c) => Math.round(s + (i[c] - s) * e)).map((s) => s.toString(16).padStart(2, "0")).join("");
1865
+ function z(t, a, e) {
1866
+ const n = E(t), i = E(a);
1867
+ return !n || !i ? null : "#" + n.map((s, c) => Math.round(s + (i[c] - s) * e)).map((s) => s.toString(16).padStart(2, "0")).join("");
1854
1868
  }
1855
- function pa(n) {
1856
- const a = {}, e = n.colors, t = e.surface || e.background, i = e.text;
1857
- if (!t || !i) return a;
1869
+ function fa(t) {
1870
+ const a = {}, e = t.colors, n = e.surface || e.background, i = e.text;
1871
+ if (!n || !i) return a;
1858
1872
  const r = [
1859
1873
  // the accent's text step (Radix step 11) can sit just under 4.5:1 (amber is 4.49:1 on near-white)
1860
- ["accent", n.palette?.accent?.["11"] || e.primary],
1874
+ ["accent", t.palette?.accent?.["11"] || e.primary],
1861
1875
  ["danger", e.danger],
1862
1876
  ["success", e.success],
1863
1877
  ["warning", e.warning],
@@ -1869,130 +1883,138 @@ function pa(n) {
1869
1883
  a[`--ui-color-${s}-text`] = `color-mix(in srgb, ${c} 62%, ${i})`;
1870
1884
  continue;
1871
1885
  }
1872
- const d = z(c, t, 0.86);
1886
+ const l = z(c, n, 0.86);
1873
1887
  let f = c;
1874
- for (let g = 0; g <= 18; g += 1) {
1875
- const m = z(c, i, g * 0.05);
1876
- if (!m) break;
1877
- f = m;
1878
- const x = v(m, t) ?? 0, C = d ? v(m, d) ?? 0 : x;
1879
- if (x >= 5.5 && C >= 5) break;
1888
+ for (let u = 0; u <= 18; u += 1) {
1889
+ const x = z(c, i, u * 0.05);
1890
+ if (!x) break;
1891
+ f = x;
1892
+ const m = v(x, n) ?? 0, C = l ? v(x, l) ?? 0 : m;
1893
+ if (m >= 5.5 && C >= 5) break;
1880
1894
  }
1881
1895
  if (a[`--ui-color-${s}-text`] = f, s === "danger" || s === "success") {
1882
- let g = c;
1883
- for (let m = 0; m <= 12; m += 1) {
1884
- const x = z(c, "#000000", m * 0.05);
1885
- if (!x || (g = x, (v("#ffffff", x) ?? 0) >= 4.6)) break;
1896
+ let u = c;
1897
+ for (let x = 0; x <= 12; x += 1) {
1898
+ const m = z(c, "#000000", x * 0.05);
1899
+ if (!m || (u = m, (v("#ffffff", m) ?? 0) >= 4.6)) break;
1886
1900
  }
1887
- a[`--ui-color-${s}-solid`] = g, a[`--ui-color-foreground-on-${s}`] = "#ffffff";
1901
+ a[`--ui-color-${s}-solid`] = u, a[`--ui-color-foreground-on-${s}`] = "#ffffff";
1888
1902
  }
1889
1903
  }
1890
1904
  return a;
1891
1905
  }
1892
- function da(n) {
1893
- const a = n.colors, e = n.palette;
1894
- if (!e || !a) return n;
1895
- const t = (m, x, C) => `color-mix(in srgb, ${m} ${x}%, ${C})`, i = a.surface || a.background, r = a.text;
1906
+ function ua(t) {
1907
+ const a = t.colors, e = t.palette;
1908
+ if (!e || !a) return t;
1909
+ const n = (x, m, C) => `color-mix(in srgb, ${x} ${m}%, ${C})`, i = a.surface || a.background, r = a.text;
1896
1910
  let s = e.gray, c = e.accent;
1897
- const d = a.background ? w(a.background) : null, f = s?.["1"] ? w(s[1]) : null;
1898
- i && r && d !== null && f !== null && d < 0.4 != f < 0.4 && (s = {
1911
+ const l = a.background ? w(a.background) : null, f = s?.["1"] ? w(s[1]) : null;
1912
+ i && r && l !== null && f !== null && l < 0.4 != f < 0.4 && (s = {
1899
1913
  ...s,
1900
- 2: t(r, 4, i),
1901
- 3: t(r, 8, i),
1902
- 4: t(r, 12, i),
1903
- 5: t(r, 16, i),
1904
- 6: t(r, 20, i),
1905
- 7: t(r, 28, i),
1906
- 8: t(r, 40, i),
1914
+ 2: n(r, 4, i),
1915
+ 3: n(r, 8, i),
1916
+ 4: n(r, 12, i),
1917
+ 5: n(r, 16, i),
1918
+ 6: n(r, 20, i),
1919
+ 7: n(r, 28, i),
1920
+ 8: n(r, 40, i),
1907
1921
  11: a.muted || r,
1908
1922
  12: r
1909
1923
  });
1910
- const g = c?.["9"];
1911
- return i && r && a.primary && g && g.trim().toLowerCase() !== a.primary.trim().toLowerCase() && (c = {
1924
+ const u = c?.["9"];
1925
+ return i && r && a.primary && u && u.trim().toLowerCase() !== a.primary.trim().toLowerCase() && (c = {
1912
1926
  ...c,
1913
- 2: t(a.primary, 6, i),
1914
- 3: t(a.primary, 14, i),
1915
- 4: t(a.primary, 20, i),
1916
- 5: t(a.primary, 26, i),
1917
- 7: t(a.primary, 42, i),
1927
+ 2: n(a.primary, 6, i),
1928
+ 3: n(a.primary, 14, i),
1929
+ 4: n(a.primary, 20, i),
1930
+ 5: n(a.primary, 26, i),
1931
+ 7: n(a.primary, 42, i),
1918
1932
  9: a.primary,
1919
1933
  10: a.primaryHover || a.primary,
1920
- 11: t(a.primary, 60, r)
1921
- }), s === e.gray && c === e.accent ? n : { ...n, palette: { ...e, gray: s, accent: c } };
1934
+ 11: n(a.primary, 60, r)
1935
+ }), s === e.gray && c === e.accent ? t : { ...t, palette: { ...e, gray: s, accent: c } };
1922
1936
  }
1923
- function F(n) {
1924
- const a = da(n), e = {};
1925
- return o(e, "--ui-color-primary", a.colors.primary), o(e, "--ui-color-primary-hover", a.colors.primaryHover || a.colors.primary), o(e, "--ui-color-foreground-on-primary", a.colors.foregroundOnPrimary || "#ffffff"), o(e, "--ui-color-background", a.colors.background || "#ffffff"), o(e, "--ui-color-surface", a.colors.surface || a.colors.background || "#ffffff"), o(e, "--ui-color-surface-alt", a.colors.surfaceAlt || a.colors.surface || "#f9f9f9"), o(e, "--ui-color-text", a.colors.text || "#202020"), o(e, "--ui-color-muted", a.colors.muted || "#646464"), o(e, "--ui-color-border", a.colors.border || "#0000001f"), o(e, "--ui-color-focus-ring", a.colors.focusRing || a.colors.primary), o(e, "--ui-color-success", a.colors.success || "#30a46c"), o(e, "--ui-color-danger", a.colors.danger || "#e5484d"), o(e, "--ui-color-warning", a.colors.warning || a.colors.primary), o(e, "--ui-primary", a.colors.primary), o(e, "--ui-primary-hover", a.colors.primaryHover || a.colors.primary), o(e, "--ui-foreground", a.colors.foregroundOnPrimary || "#ffffff"), o(e, "--ui-background", a.colors.background || "#ffffff"), o(e, "--ui-surface", a.colors.surface || a.colors.background || "#ffffff"), o(e, "--ui-surface-alt", a.colors.surfaceAlt || a.colors.surface || "#f9f9f9"), o(e, "--ui-text", a.colors.text || "#202020"), o(e, "--ui-muted", a.colors.muted || "#646464"), o(e, "--ui-border", a.colors.border || "#0000001f"), o(e, "--ui-focus-ring", a.colors.focusRing || a.colors.primary), o(e, "--ui-success", a.colors.success || "#30a46c"), o(e, "--ui-error", a.colors.danger || "#e5484d"), o(e, "--ui-warning", a.colors.warning || a.colors.primary), o(e, "--ui-radius", a.radius || "6px"), o(e, "--ui-space-xs", a.spacing?.xs || "4px"), o(e, "--ui-space-sm", a.spacing?.sm || "8px"), o(e, "--ui-space-md", a.spacing?.md || "12px"), o(e, "--ui-space-lg", a.spacing?.lg || "24px"), o(e, "--ui-space-xl", a.spacing?.xl || "32px"), o(e, "--ui-space-xxl", a.spacing?.xxl || "48px"), o(e, "--ui-default-gap", a.spacing?.sm || a.spaceScale?.["2"] || "8px"), o(e, "--ui-shadow-sm", a.shadows?.sm || a.shadows?.["2"] || "none"), o(e, "--ui-shadow-md", a.shadows?.md || a.shadows?.["3"] || "none"), o(e, "--ui-shadow-lg", a.shadows?.lg || a.shadows?.["4"] || "none"), o(e, "--ui-font-family", a.typography?.family || "system-ui, sans-serif"), o(e, "--ui-font-family-heading", a.typography?.headingFamily || a.typography?.family || "system-ui, sans-serif"), o(e, "--ui-font-family-code", a.typography?.codeFamily || "monospace"), o(e, "--ui-font-size-sm", a.typography?.size?.sm || "12px"), o(e, "--ui-font-size-md", a.typography?.size?.md || "14px"), o(e, "--ui-font-size-lg", a.typography?.size?.lg || "16px"), o(e, "--ui-default-font-size", a.typography?.size?.md || a.typography?.fontScale?.["2"] || "14px"), o(e, "--ui-default-line-height", a.typography?.lineHeight?.["2"] || "20px"), o(e, "--ui-default-letter-spacing", a.typography?.letterSpacing?.["2"] || "0em"), o(e, "--ui-motion-short", a.motion?.durationShort || "120ms"), o(e, "--ui-motion-base", a.motion?.durationBase || "180ms"), o(e, "--ui-motion-long", a.motion?.durationLong || "260ms"), o(e, "--ui-motion-easing", a.motion?.easing || "cubic-bezier(0.2, 0.8, 0.2, 1)"), o(e, "--ui-z-modal", String(a.zIndex?.modal ?? 1e3)), o(e, "--ui-z-overlay", String(a.zIndex?.overlay ?? 900)), o(e, "--ui-z-toast", String(a.zIndex?.toast ?? 1100)), o(e, "--ui-breakpoint-sm", a.breakpoints?.sm || "640px"), o(e, "--ui-breakpoint-md", a.breakpoints?.md || "768px"), o(e, "--ui-breakpoint-lg", a.breakpoints?.lg || "1024px"), o(e, "--color-background", a.surfaces?.background || a.colors.background || "#ffffff"), o(e, "--color-surface", a.surfaces?.surface || a.colors.surface || "#fcfcfc"), o(e, "--color-panel", a.surfaces?.panel || a.surfaces?.panelTranslucent || "#ffffffcc"), o(e, "--color-panel-solid", a.surfaces?.panelSolid || a.colors.surface || "#ffffff"), o(e, "--color-panel-translucent", a.surfaces?.panelTranslucent || "#ffffffcc"), o(e, "--color-overlay", a.surfaces?.overlay || "rgba(2, 6, 23, 0.52)"), o(e, "--color-transparent", a.surfaces?.transparent || "transparent"), o(e, "--backdrop-filter-panel", a.effects?.backdropFilterPanel || "blur(64px)"), a.palette?.accentContrast && o(e, "--accent-contrast", a.palette.accentContrast), a.palette?.accentSurface && o(e, "--accent-surface", a.palette.accentSurface), a.palette?.accentIndicator && o(e, "--accent-indicator", a.palette.accentIndicator), a.palette?.accentTrack && o(e, "--accent-track", a.palette.accentTrack), l(e, "--gray-", a.palette?.gray), l(e, "--gray-a", a.palette?.grayAlpha), l(e, "--black-a", a.palette?.blackAlpha), l(e, "--white-a", a.palette?.whiteAlpha), l(e, "--accent-", a.palette?.accent), l(e, "--accent-a", a.palette?.accentAlpha), l(e, "--space-", a.spaceScale), l(e, "--radius-", a.radiusScale), l(e, "--font-size-", a.typography?.fontScale), l(e, "--line-height-", a.typography?.lineHeight), l(e, "--letter-spacing-", a.typography?.letterSpacing), l(e, "--shadow-", a.shadows), l(e, "--base-button-", a.components?.button), l(e, "--base-badge-", a.components?.badge), l(e, "--base-dropdown-", a.components?.dropdown), l(e, "--base-select-", a.components?.select), l(e, "--base-sidebar-", a.components?.sidebar), l(e, "--base-block-controls-", a.components?.blockControls), l(e, "--base-box-", a.components?.box), l(e, "--base-breadcrumb-", a.components?.breadcrumb), l(e, "--base-card-", a.components?.card), l(e, "--base-multi-select-", a.components?.multiSelect), l(e, "--base-navigation-menu-", a.components?.navigationMenu), l(e, "--base-menubar-", a.components?.menubar), l(e, "--base-context-menu-", a.components?.contextMenu), l(e, "--base-alert-", a.components?.alert), l(e, "--base-alert-dialog-", a.components?.alertDialog), l(e, "--base-app-header-", a.components?.appHeader), l(e, "--base-aspect-ratio-", a.components?.aspectRatio), l(e, "--base-avatar-", a.components?.avatar), l(e, "--base-menu-", a.components?.menu), l(e, "--base-panel-", a.components?.panel), l(e, "--base-input-", a.components?.input), Object.assign(e, na(a)), Object.assign(e, pa(a)), o(e, "--ui-color-foreground-on-warning", k(a.colors.warning || a.colors.primary, "#ffffff")), e;
1937
+ function N(t) {
1938
+ const a = ua(t), e = {};
1939
+ return o(e, "--ui-color-primary", a.colors.primary), o(e, "--ui-color-primary-hover", a.colors.primaryHover || a.colors.primary), o(e, "--ui-color-foreground-on-primary", a.colors.foregroundOnPrimary || "#ffffff"), o(e, "--ui-color-background", a.colors.background || "#ffffff"), o(e, "--ui-color-surface", a.colors.surface || a.colors.background || "#ffffff"), o(e, "--ui-color-surface-alt", a.colors.surfaceAlt || a.colors.surface || "#f9f9f9"), o(e, "--ui-color-text", a.colors.text || "#202020"), o(e, "--ui-color-muted", a.colors.muted || "#646464"), o(e, "--ui-color-border", a.colors.border || "#0000001f"), o(e, "--ui-color-focus-ring", a.colors.focusRing || a.colors.primary), o(e, "--ui-color-success", a.colors.success || "#30a46c"), o(e, "--ui-color-danger", a.colors.danger || "#e5484d"), o(e, "--ui-color-warning", a.colors.warning || a.colors.primary), o(e, "--ui-primary", a.colors.primary), o(e, "--ui-primary-hover", a.colors.primaryHover || a.colors.primary), o(e, "--ui-foreground", a.colors.foregroundOnPrimary || "#ffffff"), o(e, "--ui-background", a.colors.background || "#ffffff"), o(e, "--ui-surface", a.colors.surface || a.colors.background || "#ffffff"), o(e, "--ui-surface-alt", a.colors.surfaceAlt || a.colors.surface || "#f9f9f9"), o(e, "--ui-text", a.colors.text || "#202020"), o(e, "--ui-muted", a.colors.muted || "#646464"), o(e, "--ui-border", a.colors.border || "#0000001f"), o(e, "--ui-focus-ring", a.colors.focusRing || a.colors.primary), o(e, "--ui-success", a.colors.success || "#30a46c"), o(e, "--ui-error", a.colors.danger || "#e5484d"), o(e, "--ui-warning", a.colors.warning || a.colors.primary), o(e, "--ui-radius", a.radius || "6px"), o(e, "--ui-space-xs", a.spacing?.xs || "4px"), o(e, "--ui-space-sm", a.spacing?.sm || "8px"), o(e, "--ui-space-md", a.spacing?.md || "12px"), o(e, "--ui-space-lg", a.spacing?.lg || "24px"), o(e, "--ui-space-xl", a.spacing?.xl || "32px"), o(e, "--ui-space-xxl", a.spacing?.xxl || "48px"), o(e, "--ui-default-gap", a.spacing?.sm || a.spaceScale?.["2"] || "8px"), o(e, "--ui-shadow-sm", a.shadows?.sm || a.shadows?.["2"] || "none"), o(e, "--ui-shadow-md", a.shadows?.md || a.shadows?.["3"] || "none"), o(e, "--ui-shadow-lg", a.shadows?.lg || a.shadows?.["4"] || "none"), o(e, "--ui-font-family", a.typography?.family || "system-ui, sans-serif"), o(e, "--ui-font-family-heading", a.typography?.headingFamily || a.typography?.family || "system-ui, sans-serif"), o(e, "--ui-font-family-code", a.typography?.codeFamily || "monospace"), o(e, "--ui-font-size-sm", a.typography?.size?.sm || "12px"), o(e, "--ui-font-size-md", a.typography?.size?.md || "14px"), o(e, "--ui-font-size-lg", a.typography?.size?.lg || "16px"), o(e, "--ui-default-font-size", a.typography?.size?.md || a.typography?.fontScale?.["2"] || "14px"), o(e, "--ui-default-line-height", a.typography?.lineHeight?.["2"] || "20px"), o(e, "--ui-default-letter-spacing", a.typography?.letterSpacing?.["2"] || "0em"), o(e, "--ui-motion-short", a.motion?.durationShort || "120ms"), o(e, "--ui-motion-base", a.motion?.durationBase || "180ms"), o(e, "--ui-motion-long", a.motion?.durationLong || "260ms"), o(e, "--ui-motion-easing", a.motion?.easing || "cubic-bezier(0.2, 0.8, 0.2, 1)"), o(e, "--ui-z-modal", String(a.zIndex?.modal ?? 1e3)), o(e, "--ui-z-overlay", String(a.zIndex?.overlay ?? 900)), o(e, "--ui-z-toast", String(a.zIndex?.toast ?? 1100)), o(e, "--ui-breakpoint-sm", a.breakpoints?.sm || "640px"), o(e, "--ui-breakpoint-md", a.breakpoints?.md || "768px"), o(e, "--ui-breakpoint-lg", a.breakpoints?.lg || "1024px"), o(e, "--color-background", a.surfaces?.background || a.colors.background || "#ffffff"), o(e, "--color-surface", a.surfaces?.surface || a.colors.surface || "#fcfcfc"), o(e, "--color-panel", a.surfaces?.panel || a.surfaces?.panelTranslucent || "#ffffffcc"), o(e, "--color-panel-solid", a.surfaces?.panelSolid || a.colors.surface || "#ffffff"), o(e, "--color-panel-translucent", a.surfaces?.panelTranslucent || "#ffffffcc"), o(e, "--color-overlay", a.surfaces?.overlay || "rgba(2, 6, 23, 0.52)"), o(e, "--color-transparent", a.surfaces?.transparent || "transparent"), o(e, "--backdrop-filter-panel", a.effects?.backdropFilterPanel || "blur(64px)"), a.palette?.accentContrast && o(e, "--accent-contrast", a.palette.accentContrast), a.palette?.accentSurface && o(e, "--accent-surface", a.palette.accentSurface), a.palette?.accentIndicator && o(e, "--accent-indicator", a.palette.accentIndicator), a.palette?.accentTrack && o(e, "--accent-track", a.palette.accentTrack), p(e, "--gray-", a.palette?.gray), p(e, "--gray-a", a.palette?.grayAlpha), p(e, "--black-a", a.palette?.blackAlpha), p(e, "--white-a", a.palette?.whiteAlpha), p(e, "--accent-", a.palette?.accent), p(e, "--accent-a", a.palette?.accentAlpha), p(e, "--space-", a.spaceScale), p(e, "--radius-", a.radiusScale), p(e, "--font-size-", a.typography?.fontScale), p(e, "--line-height-", a.typography?.lineHeight), p(e, "--letter-spacing-", a.typography?.letterSpacing), p(e, "--shadow-", a.shadows), p(e, "--base-button-", a.components?.button), p(e, "--base-badge-", a.components?.badge), p(e, "--base-dropdown-", a.components?.dropdown), p(e, "--base-select-", a.components?.select), p(e, "--base-sidebar-", a.components?.sidebar), p(e, "--base-block-controls-", a.components?.blockControls), p(e, "--base-box-", a.components?.box), p(e, "--base-breadcrumb-", a.components?.breadcrumb), p(e, "--base-card-", a.components?.card), p(e, "--base-multi-select-", a.components?.multiSelect), p(e, "--base-navigation-menu-", a.components?.navigationMenu), p(e, "--base-menubar-", a.components?.menubar), p(e, "--base-context-menu-", a.components?.contextMenu), p(e, "--base-alert-", a.components?.alert), p(e, "--base-alert-dialog-", a.components?.alertDialog), p(e, "--base-app-header-", a.components?.appHeader), p(e, "--base-aspect-ratio-", a.components?.aspectRatio), p(e, "--base-avatar-", a.components?.avatar), p(e, "--base-menu-", a.components?.menu), p(e, "--base-panel-", a.components?.panel), p(e, "--base-input-", a.components?.input), Object.assign(e, ra(a)), Object.assign(e, fa(a)), o(e, "--ui-color-foreground-on-warning", k(a.colors.warning || a.colors.primary, "#ffffff")), e;
1926
1940
  }
1927
- function P(n, a) {
1928
- Object.entries(a).forEach(([e, t]) => {
1941
+ function D(t, a) {
1942
+ Object.entries(a).forEach(([e, n]) => {
1929
1943
  try {
1930
- n.style.setProperty(e, t);
1944
+ t.style.setProperty(e, n);
1931
1945
  } catch {
1932
1946
  }
1933
1947
  });
1934
1948
  }
1935
- function Ca(n, a = ":root") {
1936
- const e = Object.entries(ca(n)).map(([t, i]) => ` ${t}: ${i};`).join(`
1949
+ function Ea(t, a = ":root") {
1950
+ const e = Object.entries(pa(t)).map(([n, i]) => ` ${n}: ${i};`).join(`
1937
1951
  `);
1938
1952
  return `${a} {
1939
1953
  ${e}
1940
1954
  }
1941
1955
  `;
1942
1956
  }
1943
- function j(n) {
1944
- return n === document ? document.documentElement : n instanceof ShadowRoot ? n.host : n;
1957
+ function B(t) {
1958
+ return t === document ? document.documentElement : t instanceof ShadowRoot ? t.host : t;
1945
1959
  }
1946
- function fa(n, a = typeof document < "u" ? document : null) {
1960
+ function ga(t, a = typeof document < "u" ? document : null) {
1947
1961
  if (!a) return;
1948
- const e = F(S(n)), t = a === document || a instanceof ShadowRoot, i = j(a);
1949
- if (P(i, e), t)
1950
- for (const r of H)
1962
+ const e = N(S(t)), n = a === document || a instanceof ShadowRoot, i = B(a);
1963
+ if (D(i, e), M(i, e["--ui-color-background"]), n)
1964
+ for (const r of j)
1951
1965
  try {
1952
- P(r, e);
1966
+ D(r, e), M(r, e["--ui-color-background"]);
1953
1967
  } catch {
1954
1968
  }
1955
1969
  }
1956
- function za(n = {}) {
1957
- const a = n.root === void 0 ? typeof document < "u" ? document : null : n.root;
1970
+ function M(t, a) {
1971
+ const e = a ? w(a) : null;
1972
+ if (e !== null)
1973
+ try {
1974
+ t.style.setProperty("color-scheme", e < 0.179 ? "dark" : "light");
1975
+ } catch {
1976
+ }
1977
+ }
1978
+ function Ta(t = {}) {
1979
+ const a = t.root === void 0 ? typeof document < "u" ? document : null : t.root;
1958
1980
  if (!a) return () => {
1959
1981
  };
1960
- const e = typeof window < "u" && typeof window.matchMedia == "function" ? window.matchMedia("(prefers-color-scheme: dark)") : null, t = (r) => {
1982
+ const e = typeof window < "u" && typeof window.matchMedia == "function" ? window.matchMedia("(prefers-color-scheme: dark)") : null, n = (r) => {
1961
1983
  const s = r ? "dark" : "light";
1962
- fa(S(r ? n.dark : n.light, { accentPalette: n.accentPalette, mode: s }), a);
1963
- const c = j(a);
1984
+ ga(S(r ? t.dark : t.light, { accentPalette: t.accentPalette, mode: s }), a);
1985
+ const c = B(a);
1964
1986
  c.setAttribute("data-ui-mode", s), c.style.setProperty("color-scheme", s);
1965
1987
  };
1966
- if (t(!!e?.matches), !e) return () => {
1988
+ if (n(!!e?.matches), !e) return () => {
1967
1989
  };
1968
- const i = (r) => t(r.matches);
1990
+ const i = (r) => n(r.matches);
1969
1991
  return typeof e.addEventListener == "function" ? (e.addEventListener("change", i), () => e.removeEventListener("change", i)) : (e.addListener(i), () => e.removeListener(i));
1970
1992
  }
1971
1993
  export {
1972
- U as A,
1973
- X as D,
1974
- ma as a,
1975
- za as b,
1976
- fa as c,
1977
- u as d,
1978
- oa as e,
1994
+ Q as A,
1995
+ Y as D,
1996
+ ha as a,
1997
+ Ta as b,
1998
+ ga as c,
1999
+ g as d,
2000
+ ca as e,
1979
2001
  _ as f,
1980
- xa as g,
1981
- ya as h,
1982
- Q as i,
1983
- K as j,
2002
+ ba as g,
2003
+ ka as h,
2004
+ W as i,
2005
+ J as j,
1984
2006
  S as k,
1985
- ka as l,
1986
- ia as m,
1987
- na as n,
1988
- sa as o,
1989
- ba as p,
1990
- wa as q,
1991
- ha as r,
2007
+ Sa as l,
2008
+ sa as m,
2009
+ ra as n,
2010
+ la as o,
2011
+ ya as p,
2012
+ _a as q,
2013
+ va as r,
1992
2014
  k as s,
1993
- Sa as t,
1994
- va as u,
1995
- Ca as v,
1996
- ca as w,
1997
- _a as x
2015
+ za as t,
2016
+ wa as u,
2017
+ Ea as v,
2018
+ pa as w,
2019
+ Ca as x
1998
2020
  };