@editora/ui-core 0.1.25 → 0.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (349) hide show
  1. package/README.md +132 -0
  2. package/dist/accordion.cjs.js +13 -12
  3. package/dist/accordion.esm.js +13 -12
  4. package/dist/alert-dialog.cjs.js +92 -53
  5. package/dist/alert-dialog.esm.js +211 -159
  6. package/dist/alert.cjs.js +42 -33
  7. package/dist/alert.esm.js +80 -71
  8. package/dist/animated-beam.cjs.js +42 -50
  9. package/dist/animated-beam.esm.js +47 -55
  10. package/dist/animated-list.cjs.js +11 -27
  11. package/dist/animated-list.esm.js +12 -28
  12. package/dist/animated-text.cjs.js +9 -9
  13. package/dist/animated-text.esm.js +9 -9
  14. package/dist/app-header.cjs.js +17 -12
  15. package/dist/app-header.esm.js +18 -13
  16. package/dist/aspect-ratio.cjs.js +10 -12
  17. package/dist/aspect-ratio.esm.js +11 -13
  18. package/dist/avatar.cjs.js +16 -20
  19. package/dist/avatar.esm.js +16 -20
  20. package/dist/badge.cjs.js +27 -22
  21. package/dist/badge.esm.js +32 -27
  22. package/dist/block-controls.cjs.js +11 -12
  23. package/dist/block-controls.esm.js +8 -9
  24. package/dist/box.cjs.js +2 -3
  25. package/dist/box.esm.js +2 -3
  26. package/dist/breadcrumb.cjs.js +12 -18
  27. package/dist/breadcrumb.esm.js +11 -17
  28. package/dist/button.cjs.js +1 -1
  29. package/dist/button.esm.js +1 -1
  30. package/dist/{calendar-D-mXMgqc.js → calendar-CzpWDxLc.js} +56 -46
  31. package/dist/{calendar-B3PUKHQm.mjs → calendar-DkSDFg33.mjs} +127 -117
  32. package/dist/calendar.cjs.js +1 -1
  33. package/dist/calendar.esm.js +1 -1
  34. package/dist/card.cjs.js +6 -7
  35. package/dist/card.esm.js +5 -6
  36. package/dist/chart.cjs.js +58 -52
  37. package/dist/chart.esm.js +101 -95
  38. package/dist/checkbox.cjs.js +19 -15
  39. package/dist/checkbox.esm.js +19 -15
  40. package/dist/collapsible.cjs.js +9 -13
  41. package/dist/collapsible.esm.js +9 -13
  42. package/dist/color-picker.cjs.js +38 -19
  43. package/dist/color-picker.esm.js +134 -115
  44. package/dist/combobox.cjs.js +60 -57
  45. package/dist/combobox.esm.js +96 -92
  46. package/dist/command-palette.cjs.js +1 -0
  47. package/dist/command-palette.esm.js +1 -0
  48. package/dist/command.cjs.js +32 -14
  49. package/dist/command.esm.js +46 -28
  50. package/dist/components/date-time-utils.d.ts.map +1 -1
  51. package/dist/components/ui-accordion.d.ts.map +1 -1
  52. package/dist/components/ui-alert-dialog.d.ts +2 -0
  53. package/dist/components/ui-alert-dialog.d.ts.map +1 -1
  54. package/dist/components/ui-alert.d.ts.map +1 -1
  55. package/dist/components/ui-animated-beam.d.ts.map +1 -1
  56. package/dist/components/ui-animated-list.d.ts.map +1 -1
  57. package/dist/components/ui-app-header.d.ts.map +1 -1
  58. package/dist/components/ui-aspect-ratio.d.ts.map +1 -1
  59. package/dist/components/ui-avatar.d.ts.map +1 -1
  60. package/dist/components/ui-badge.d.ts.map +1 -1
  61. package/dist/components/ui-block-controls.d.ts.map +1 -1
  62. package/dist/components/ui-box.d.ts.map +1 -1
  63. package/dist/components/ui-breadcrumb.d.ts.map +1 -1
  64. package/dist/components/ui-button.d.ts.map +1 -1
  65. package/dist/components/ui-calendar.d.ts.map +1 -1
  66. package/dist/components/ui-card.d.ts.map +1 -1
  67. package/dist/components/ui-chart.d.ts.map +1 -1
  68. package/dist/components/ui-checkbox.d.ts.map +1 -1
  69. package/dist/components/ui-collapsible.d.ts.map +1 -1
  70. package/dist/components/ui-color-picker.d.ts.map +1 -1
  71. package/dist/components/ui-combobox.d.ts.map +1 -1
  72. package/dist/components/ui-command-palette.d.ts.map +1 -1
  73. package/dist/components/ui-command.d.ts.map +1 -1
  74. package/dist/components/ui-container.d.ts.map +1 -1
  75. package/dist/components/ui-context-menu.d.ts.map +1 -1
  76. package/dist/components/ui-data-table.d.ts +7 -0
  77. package/dist/components/ui-data-table.d.ts.map +1 -1
  78. package/dist/components/ui-date-picker.d.ts.map +1 -1
  79. package/dist/components/ui-date-range-picker.d.ts.map +1 -1
  80. package/dist/components/ui-date-range-time-picker.d.ts.map +1 -1
  81. package/dist/components/ui-date-time-picker.d.ts.map +1 -1
  82. package/dist/components/ui-dialog.d.ts +2 -0
  83. package/dist/components/ui-dialog.d.ts.map +1 -1
  84. package/dist/components/ui-dock.d.ts.map +1 -1
  85. package/dist/components/ui-drawer.d.ts.map +1 -1
  86. package/dist/components/ui-dropdown.d.ts.map +1 -1
  87. package/dist/components/ui-empty-state.d.ts.map +1 -1
  88. package/dist/components/ui-field.d.ts.map +1 -1
  89. package/dist/components/ui-fieldset.d.ts.map +1 -1
  90. package/dist/components/ui-file-upload.d.ts.map +1 -1
  91. package/dist/components/ui-floating-toolbar.d.ts.map +1 -1
  92. package/dist/components/ui-form.d.ts.map +1 -1
  93. package/dist/components/ui-gantt.d.ts.map +1 -1
  94. package/dist/components/ui-hover-card.d.ts.map +1 -1
  95. package/dist/components/ui-icon-cloud.d.ts.map +1 -1
  96. package/dist/components/ui-inline-edit.d.ts.map +1 -1
  97. package/dist/components/ui-input.d.ts.map +1 -1
  98. package/dist/components/ui-marquee.d.ts.map +1 -1
  99. package/dist/components/ui-menu.d.ts.map +1 -1
  100. package/dist/components/ui-menubar.d.ts.map +1 -1
  101. package/dist/components/ui-meter.d.ts.map +1 -1
  102. package/dist/components/ui-multi-select.d.ts.map +1 -1
  103. package/dist/components/ui-number-field.d.ts.map +1 -1
  104. package/dist/components/ui-orbiter.d.ts.map +1 -1
  105. package/dist/components/ui-pagination.d.ts.map +1 -1
  106. package/dist/components/ui-password-field.d.ts.map +1 -1
  107. package/dist/components/ui-pin-input.d.ts.map +1 -1
  108. package/dist/components/ui-popover.d.ts.map +1 -1
  109. package/dist/components/ui-progress.d.ts.map +1 -1
  110. package/dist/components/ui-radio-group.d.ts.map +1 -1
  111. package/dist/components/ui-radio.d.ts.map +1 -1
  112. package/dist/components/ui-rating.d.ts +1 -0
  113. package/dist/components/ui-rating.d.ts.map +1 -1
  114. package/dist/components/ui-scroll-area.d.ts.map +1 -1
  115. package/dist/components/ui-section.d.ts.map +1 -1
  116. package/dist/components/ui-select.d.ts.map +1 -1
  117. package/dist/components/ui-selection-popup.d.ts.map +1 -1
  118. package/dist/components/ui-sidebar.d.ts.map +1 -1
  119. package/dist/components/ui-slider.d.ts.map +1 -1
  120. package/dist/components/ui-sortable.d.ts.map +1 -1
  121. package/dist/components/ui-spinning-text.d.ts.map +1 -1
  122. package/dist/components/ui-split-button.d.ts.map +1 -1
  123. package/dist/components/ui-splitter.d.ts.map +1 -1
  124. package/dist/components/ui-stepper.d.ts.map +1 -1
  125. package/dist/components/ui-switch.d.ts.map +1 -1
  126. package/dist/components/ui-tabs.d.ts.map +1 -1
  127. package/dist/components/ui-tags-input.d.ts.map +1 -1
  128. package/dist/components/ui-textarea.d.ts.map +1 -1
  129. package/dist/components/ui-time-picker.d.ts.map +1 -1
  130. package/dist/components/ui-toggle-group.d.ts +2 -0
  131. package/dist/components/ui-toggle-group.d.ts.map +1 -1
  132. package/dist/components/ui-toggle.d.ts.map +1 -1
  133. package/dist/components/ui-toolbar.d.ts +2 -0
  134. package/dist/components/ui-toolbar.d.ts.map +1 -1
  135. package/dist/components/ui-tooltip.d.ts.map +1 -1
  136. package/dist/components/ui-transfer-list.d.ts.map +1 -1
  137. package/dist/components/ui-tree-item.d.ts.map +1 -1
  138. package/dist/components/ui-tree.d.ts.map +1 -1
  139. package/dist/components/ui-wizard.d.ts.map +1 -1
  140. package/dist/container.cjs.js +6 -12
  141. package/dist/container.esm.js +8 -14
  142. package/dist/context-menu.cjs.js +8 -8
  143. package/dist/context-menu.esm.js +42 -41
  144. package/dist/data-table.cjs.js +21 -18
  145. package/dist/data-table.esm.js +210 -190
  146. package/dist/date-field.cjs.js +9 -9
  147. package/dist/date-field.esm.js +19 -19
  148. package/dist/date-picker.cjs.js +29 -20
  149. package/dist/date-picker.esm.js +59 -50
  150. package/dist/date-range-picker.cjs.js +24 -19
  151. package/dist/date-range-picker.esm.js +86 -81
  152. package/dist/date-range-time-picker.cjs.js +27 -20
  153. package/dist/date-range-time-picker.esm.js +24 -17
  154. package/dist/date-time-picker.cjs.js +24 -17
  155. package/dist/date-time-picker.esm.js +89 -82
  156. package/dist/date-time-utils-C-4eHTyy.js +1 -0
  157. package/dist/{date-time-utils-BTlxnz5j.mjs → date-time-utils-zAx4ghvC.mjs} +75 -68
  158. package/dist/description.cjs.js +4 -4
  159. package/dist/description.esm.js +4 -4
  160. package/dist/dialog.cjs.js +59 -43
  161. package/dist/dialog.esm.js +86 -53
  162. package/dist/direction-provider.cjs.js +1 -1
  163. package/dist/direction-provider.esm.js +1 -1
  164. package/dist/dock.cjs.js +16 -30
  165. package/dist/dock.esm.js +26 -40
  166. package/dist/drawer.cjs.js +8 -12
  167. package/dist/drawer.esm.js +6 -10
  168. package/dist/dropdown.cjs.js +8 -6
  169. package/dist/dropdown.esm.js +33 -30
  170. package/dist/empty-state.cjs.js +17 -15
  171. package/dist/empty-state.esm.js +13 -11
  172. package/dist/field-error.cjs.js +1 -1
  173. package/dist/field-error.esm.js +7 -7
  174. package/dist/field.cjs.js +23 -14
  175. package/dist/field.esm.js +30 -21
  176. package/dist/fieldset.cjs.js +16 -9
  177. package/dist/fieldset.esm.js +19 -12
  178. package/dist/file-upload.cjs.js +79 -37
  179. package/dist/file-upload.esm.js +154 -112
  180. package/dist/flex.cjs.js +2 -2
  181. package/dist/flex.esm.js +8 -8
  182. package/dist/floating-toolbar.cjs.js +6 -7
  183. package/dist/floating-toolbar.esm.js +8 -9
  184. package/dist/form.cjs.js +24 -27
  185. package/dist/form.esm.js +24 -27
  186. package/dist/gantt.cjs.js +13 -11
  187. package/dist/gantt.esm.js +13 -11
  188. package/dist/grid.cjs.js +1 -1
  189. package/dist/grid.esm.js +1 -1
  190. package/dist/hover-card.cjs.js +8 -8
  191. package/dist/hover-card.esm.js +18 -15
  192. package/dist/icon-cloud.cjs.js +19 -36
  193. package/dist/icon-cloud.esm.js +41 -58
  194. package/dist/index.cjs.js +1 -1
  195. package/dist/index.d.ts +2 -0
  196. package/dist/index.d.ts.map +1 -1
  197. package/dist/index.esm.js +108 -104
  198. package/dist/inline-edit.cjs.js +50 -22
  199. package/dist/inline-edit.esm.js +77 -49
  200. package/dist/input.cjs.js +45 -38
  201. package/dist/input.esm.js +60 -53
  202. package/dist/label.cjs.js +6 -6
  203. package/dist/label.esm.js +6 -6
  204. package/dist/layout.cjs.js +3 -3
  205. package/dist/layout.esm.js +3 -3
  206. package/dist/marquee.cjs.js +7 -10
  207. package/dist/marquee.esm.js +7 -10
  208. package/dist/masonry-grid.cjs.js +2 -2
  209. package/dist/masonry-grid.esm.js +11 -11
  210. package/dist/{menu-item-styles-IGSFLAHu.mjs → menu-item-styles-CdqxPUuw.mjs} +15 -15
  211. package/dist/{menu-item-styles-B4onAr4C.js → menu-item-styles-DUdyjQ7i.js} +10 -10
  212. package/dist/menu.cjs.js +8 -24
  213. package/dist/menu.esm.js +52 -72
  214. package/dist/menubar.cjs.js +9 -31
  215. package/dist/menubar.esm.js +127 -153
  216. package/dist/meter.cjs.js +4 -9
  217. package/dist/meter.esm.js +6 -11
  218. package/dist/multi-select.cjs.js +53 -40
  219. package/dist/multi-select.esm.js +87 -73
  220. package/dist/navigation-menu.cjs.js +10 -10
  221. package/dist/navigation-menu.esm.js +33 -33
  222. package/dist/number-field.cjs.js +28 -17
  223. package/dist/number-field.esm.js +37 -26
  224. package/dist/number-ticker.cjs.js +4 -4
  225. package/dist/number-ticker.esm.js +10 -10
  226. package/dist/odometer.cjs.js +9 -9
  227. package/dist/odometer.esm.js +17 -17
  228. package/dist/orbiter.cjs.js +11 -28
  229. package/dist/orbiter.esm.js +28 -45
  230. package/dist/overlay-motion-B56x1GoY.js +49 -0
  231. package/dist/overlay-motion-BX3dPLay.mjs +120 -0
  232. package/dist/pagination.cjs.js +28 -25
  233. package/dist/pagination.esm.js +54 -51
  234. package/dist/password-field.cjs.js +39 -34
  235. package/dist/password-field.esm.js +63 -58
  236. package/dist/pin-input.cjs.js +18 -14
  237. package/dist/pin-input.esm.js +24 -20
  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 +16 -28
  243. package/dist/popover.esm.js +29 -45
  244. package/dist/portal-DeaM1tYY.mjs +121 -0
  245. package/dist/portal-XbYR3m_q.js +1 -0
  246. package/dist/portal.cjs.js +1 -1
  247. package/dist/portal.d.ts +3 -1
  248. package/dist/portal.d.ts.map +1 -1
  249. package/dist/portal.esm.js +1 -1
  250. package/dist/{positioner-D0VGxtYU.mjs → positioner-BE8Nbho2.mjs} +5 -3
  251. package/dist/{positioner-D_fqyx_j.js → positioner-DZ1FW6A9.js} +1 -1
  252. package/dist/positioner.cjs.js +1 -1
  253. package/dist/positioner.esm.js +1 -1
  254. package/dist/presence.cjs.js +1 -1
  255. package/dist/presence.esm.js +1 -1
  256. package/dist/primitives/overlay-motion.d.ts +47 -0
  257. package/dist/primitives/overlay-motion.d.ts.map +1 -0
  258. package/dist/primitives/positioner.d.ts.map +1 -1
  259. package/dist/progress.cjs.js +11 -16
  260. package/dist/progress.esm.js +37 -42
  261. package/dist/quick-actions.cjs.js +14 -14
  262. package/dist/quick-actions.esm.js +12 -12
  263. package/dist/radio-group.cjs.js +50 -26
  264. package/dist/radio-group.esm.js +53 -29
  265. package/dist/radio.cjs.js +16 -13
  266. package/dist/radio.esm.js +16 -13
  267. package/dist/rating.cjs.js +11 -15
  268. package/dist/rating.esm.js +48 -50
  269. package/dist/{runtime-CFnK53iC.mjs → runtime-BRT7E4A8.mjs} +563 -531
  270. package/dist/runtime-CXw4SGV9.js +5 -0
  271. package/dist/runtime.cjs.js +1 -1
  272. package/dist/runtime.d.ts +3 -2
  273. package/dist/runtime.d.ts.map +1 -1
  274. package/dist/runtime.esm.js +36 -32
  275. package/dist/scroll-area.cjs.js +3 -4
  276. package/dist/scroll-area.esm.js +3 -4
  277. package/dist/section.cjs.js +2 -4
  278. package/dist/section.esm.js +2 -4
  279. package/dist/select.cjs.js +42 -75
  280. package/dist/select.esm.js +57 -89
  281. package/dist/selection-popup.cjs.js +3 -4
  282. package/dist/selection-popup.esm.js +3 -4
  283. package/dist/semantic-tokens.d.ts +17 -0
  284. package/dist/semantic-tokens.d.ts.map +1 -0
  285. package/dist/separator.cjs.js +6 -6
  286. package/dist/separator.esm.js +7 -7
  287. package/dist/sidebar.cjs.js +29 -28
  288. package/dist/sidebar.esm.js +32 -31
  289. package/dist/skeleton.cjs.js +2 -2
  290. package/dist/skeleton.esm.js +2 -2
  291. package/dist/slider.cjs.js +22 -26
  292. package/dist/slider.esm.js +25 -29
  293. package/dist/slot.cjs.js +1 -1
  294. package/dist/slot.esm.js +1 -1
  295. package/dist/sortable.cjs.js +10 -11
  296. package/dist/sortable.esm.js +10 -11
  297. package/dist/spinning-text.cjs.js +4 -13
  298. package/dist/spinning-text.esm.js +4 -13
  299. package/dist/split-button.cjs.js +7 -7
  300. package/dist/split-button.esm.js +17 -16
  301. package/dist/splitter.cjs.js +52 -10
  302. package/dist/splitter.esm.js +55 -13
  303. package/dist/stepper.cjs.js +31 -65
  304. package/dist/stepper.esm.js +32 -66
  305. package/dist/switch.cjs.js +20 -22
  306. package/dist/switch.esm.js +20 -22
  307. package/dist/table.cjs.js +5 -5
  308. package/dist/table.esm.js +20 -20
  309. package/dist/tabs.cjs.js +101 -26
  310. package/dist/tabs.esm.js +187 -112
  311. package/dist/tags-input.cjs.js +43 -17
  312. package/dist/tags-input.esm.js +75 -49
  313. package/dist/textarea.cjs.js +34 -35
  314. package/dist/textarea.esm.js +50 -51
  315. package/dist/theme.d.ts +25 -1
  316. package/dist/theme.d.ts.map +1 -1
  317. package/dist/time-field.cjs.js +8 -8
  318. package/dist/time-field.esm.js +29 -29
  319. package/dist/time-picker.cjs.js +17 -14
  320. package/dist/time-picker.esm.js +28 -25
  321. package/dist/timeline.cjs.js +10 -10
  322. package/dist/timeline.esm.js +7 -7
  323. package/dist/toast.cjs.js +2 -2
  324. package/dist/toast.esm.js +2 -2
  325. package/dist/toggle-group.cjs.js +13 -13
  326. package/dist/toggle-group.esm.js +66 -61
  327. package/dist/toggle.cjs.js +52 -34
  328. package/dist/toggle.esm.js +80 -62
  329. package/dist/toolbar.cjs.js +14 -14
  330. package/dist/toolbar.esm.js +41 -33
  331. package/dist/tooltip.cjs.js +3 -3
  332. package/dist/tooltip.esm.js +39 -33
  333. package/dist/transfer-list.cjs.js +37 -38
  334. package/dist/transfer-list.esm.js +32 -33
  335. package/dist/{tree-B_oQput6.mjs → tree-33fVNnaf.mjs} +6 -5
  336. package/dist/{tree-SivHxcAy.js → tree-Dc02MChE.js} +6 -5
  337. package/dist/tree-item.cjs.js +9 -8
  338. package/dist/tree-item.esm.js +13 -12
  339. package/dist/tree.cjs.js +1 -1
  340. package/dist/tree.esm.js +1 -1
  341. package/dist/{ui-button-Co8Sid6t.mjs → ui-button-C3OmI7Sn.mjs} +152 -154
  342. package/dist/{ui-button-BPrzJScZ.js → ui-button-CnLwXBnx.js} +107 -109
  343. package/dist/wizard.cjs.js +51 -39
  344. package/dist/wizard.esm.js +51 -39
  345. package/package.json +1 -1
  346. package/dist/date-time-utils-y3AvNvGe.js +0 -1
  347. package/dist/portal-DgpQ3Jo1.js +0 -1
  348. package/dist/portal-bR42gHvG.mjs +0 -118
  349. package/dist/runtime-DwE-tizc.js +0 -1
@@ -170,37 +170,38 @@ function Le(r, e) {
170
170
  function Be(r, e) {
171
171
  const t = Pe(r), n = `${t}::${e || ""}`, a = se.get(n);
172
172
  if (a) return a;
173
- const i = Ee[t], s = Le(e, t), d = { ...i, ...s };
174
- return se.set(n, d), d;
173
+ const i = Ee[t], s = Le(e, t), l = { ...i, ...s };
174
+ return se.set(n, l), l;
175
175
  }
176
176
  const Fe = `
177
177
  :host {
178
- --ui-calendar-bg: color-mix(in srgb, var(--ui-color-surface, #ffffff) 95%, transparent);
179
- --ui-calendar-border: color-mix(in srgb, var(--ui-color-border, #cbd5e1) 74%, transparent);
178
+ --ui-calendar-bg: var(--color-panel-solid, var(--ui-color-surface, #ffffff));
179
+ --ui-calendar-border: var(--ui-color-line-subtle, color-mix(in srgb, var(--ui-color-border, #cbd5e1) 74%, transparent));
180
180
  --ui-calendar-text: var(--ui-color-text, #0f172a);
181
181
  --ui-calendar-muted: var(--ui-color-muted, #526175);
182
182
  --ui-calendar-accent: var(--ui-color-primary, #2563eb);
183
183
 
184
- --ui-calendar-radius: 14px;
184
+ --ui-calendar-radius: calc(var(--ui-radius, 6px) + 4px);
185
185
  --ui-calendar-shadow: none;
186
186
  --ui-calendar-gap: 10px;
187
- --ui-calendar-day-radius: 10px;
188
- --ui-calendar-day-hover-bg: color-mix(in srgb, var(--ui-calendar-accent) 10%, transparent);
189
- --ui-calendar-selected-bg: color-mix(in srgb, var(--ui-calendar-accent) 14%, transparent);
190
- --ui-calendar-selected-border: color-mix(in srgb, var(--ui-calendar-accent) 44%, transparent);
187
+ --ui-calendar-day-radius: var(--ui-control-radius-2, var(--ui-radius, 6px));
188
+ --ui-calendar-day-hover-bg: var(--ui-color-fill, color-mix(in srgb, var(--ui-calendar-accent) 10%, transparent));
189
+ --ui-calendar-selected-bg: var(--ui-calendar-accent);
190
+ --ui-calendar-selected-color: var(--ui-color-foreground-on-primary, #ffffff);
191
+ --ui-calendar-selected-border: var(--ui-calendar-accent);
191
192
  --ui-calendar-today-ring: color-mix(in srgb, var(--ui-calendar-accent) 56%, transparent);
192
193
  --ui-calendar-range-bg: color-mix(in srgb, var(--ui-calendar-accent) 9%, transparent);
193
194
  --ui-calendar-range-edge: color-mix(in srgb, var(--ui-calendar-accent) 20%, transparent);
194
195
  --ui-calendar-disabled-opacity: 0.45;
195
196
 
196
- --ui-calendar-day-height: 52px;
197
+ --ui-calendar-day-height: 40px;
197
198
  --ui-calendar-day-font-size: 12px;
198
199
  --ui-calendar-weekday-font-size: 11px;
199
200
  --ui-calendar-title-font-size: 14px;
200
201
  --ui-calendar-day-padding-block: 6px;
201
202
  --ui-calendar-day-padding-inline: 6px;
202
203
  --ui-calendar-frame-padding: 12px;
203
- --ui-calendar-week-gap: 6px;
204
+ --ui-calendar-week-gap: 2px;
204
205
  --ui-calendar-control-height: 30px;
205
206
 
206
207
  display: block;
@@ -439,7 +440,7 @@ const Fe = `
439
440
  border: 1px solid color-mix(in srgb, var(--ui-calendar-border) 84%, transparent);
440
441
  border-radius: 12px;
441
442
  background: color-mix(in srgb, var(--ui-calendar-bg) 96%, transparent);
442
- box-shadow: 0 10px 24px rgba(15, 23, 42, 0.1);
443
+ box-shadow: var(--shadow-5, 0 8px 24px rgba(15, 23, 42, 0.1));
443
444
  padding: 10px;
444
445
  display: grid;
445
446
  gap: 8px;
@@ -476,6 +477,7 @@ const Fe = `
476
477
  .picker-month[data-active="true"] {
477
478
  border-color: var(--ui-calendar-selected-border);
478
479
  background: var(--ui-calendar-selected-bg);
480
+ color: var(--ui-calendar-selected-color);
479
481
  }
480
482
 
481
483
  .grid-wrap {
@@ -526,11 +528,11 @@ const Fe = `
526
528
  }
527
529
 
528
530
  .day {
529
- border: 1px solid color-mix(in srgb, var(--ui-calendar-border) 78%, transparent);
531
+ border: 1px solid transparent;
530
532
  border-radius: var(--ui-calendar-day-radius);
531
533
  min-block-size: var(--ui-calendar-day-height);
532
534
  padding: var(--ui-calendar-day-padding-block) var(--ui-calendar-day-padding-inline);
533
- background: color-mix(in srgb, var(--ui-calendar-bg) 98%, transparent);
535
+ background: transparent;
534
536
  color: var(--ui-calendar-text);
535
537
  display: grid;
536
538
  align-content: center;
@@ -544,13 +546,11 @@ const Fe = `
544
546
  }
545
547
 
546
548
  .day:hover {
547
- border-color: color-mix(in srgb, var(--ui-calendar-accent) 34%, var(--ui-calendar-border));
548
549
  background: var(--ui-calendar-day-hover-bg);
549
550
  }
550
551
 
551
552
  .day[data-outside="true"] {
552
- color: color-mix(in srgb, var(--ui-calendar-muted) 88%, transparent);
553
- background: color-mix(in srgb, var(--ui-calendar-bg) 92%, transparent);
553
+ color: var(--ui-calendar-muted);
554
554
  }
555
555
 
556
556
  .day[data-today="true"] {
@@ -560,17 +560,19 @@ const Fe = `
560
560
  .day[data-selected="true"] {
561
561
  border-color: var(--ui-calendar-selected-border);
562
562
  background: var(--ui-calendar-selected-bg);
563
+ color: var(--ui-calendar-selected-color);
563
564
  }
564
565
 
565
566
  .day[data-range="true"] {
566
567
  background: var(--ui-calendar-range-bg);
567
- border-color: color-mix(in srgb, var(--ui-calendar-accent) 26%, var(--ui-calendar-border));
568
+ border-color: transparent;
568
569
  border-radius: 0;
569
570
  }
570
571
 
571
572
  .day[data-range-start="true"],
572
573
  .day[data-range-end="true"] {
573
- background: var(--ui-calendar-range-edge);
574
+ background: var(--ui-calendar-selected-bg);
575
+ color: var(--ui-calendar-selected-color);
574
576
  border-color: var(--ui-calendar-selected-border);
575
577
  border-radius: var(--ui-calendar-day-radius);
576
578
  }
@@ -601,7 +603,7 @@ const Fe = `
601
603
 
602
604
  .day-number {
603
605
  font-size: var(--ui-calendar-day-font-size);
604
- font-weight: 650;
606
+ font-weight: 500;
605
607
  line-height: 1;
606
608
  justify-self: center;
607
609
  }
@@ -639,6 +641,14 @@ const Fe = `
639
641
  text-overflow: ellipsis;
640
642
  }
641
643
 
644
+ /* Events are drawn over the day button: on a selected (solid) day they follow its text colour. */
645
+ .day-cell[data-selected="true"] .event-badge,
646
+ .day-cell[data-selected="true"] .event-count {
647
+ background: transparent;
648
+ box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--ui-calendar-selected-color) 60%, transparent);
649
+ color: var(--ui-calendar-selected-color);
650
+ }
651
+
642
652
  .event-count {
643
653
  inline-size: 16px;
644
654
  block-size: 16px;
@@ -667,7 +677,7 @@ const Fe = `
667
677
  border-radius: 8px;
668
678
  border: 1px solid color-mix(in srgb, var(--ui-calendar-border) 80%, transparent);
669
679
  background: color-mix(in srgb, var(--ui-calendar-bg) 98%, #ffffff 2%);
670
- box-shadow: 0 10px 24px rgba(15, 23, 42, 0.14);
680
+ box-shadow: var(--shadow-5, 0 8px 24px rgba(15, 23, 42, 0.14));
671
681
  color: var(--ui-calendar-text);
672
682
  font: 500 11px/1.35 -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
673
683
  /* Not drawn at all until its day is hovered or focused, so a hidden tooltip near an edge cannot widen the page. */
@@ -852,7 +862,7 @@ const Fe = `
852
862
  from { background-position: 120% 0; }
853
863
  to { background-position: -120% 0; }
854
864
  }
855
- `, q = {
865
+ `, K = {
856
866
  default: "var(--ui-color-primary, #2563eb)",
857
867
  info: "var(--ui-color-info, #0e7490)",
858
868
  success: "var(--ui-color-success, #15803d)",
@@ -909,23 +919,23 @@ function He(r, e) {
909
919
  const t = c(r);
910
920
  return t ? b(P(t, e)) : r;
911
921
  }
912
- function de(r, e) {
922
+ function le(r, e) {
913
923
  return { y: r, m: e, d: 1 };
914
924
  }
915
925
  function Ne(r, e) {
916
926
  return { y: r, m: e, d: F(r, e) };
917
927
  }
918
- function le(r) {
928
+ function de(r) {
919
929
  const e = c(r);
920
930
  return e ? B(e).getUTCDay() : 0;
921
931
  }
922
- function W(r, e) {
932
+ function J(r, e) {
923
933
  if (r == null || r === "") return e;
924
934
  const t = Number(r);
925
935
  return Number.isFinite(t) ? Math.trunc(t) : e;
926
936
  }
927
937
  function ce(r, e) {
928
- const t = W(r, e);
938
+ const t = J(r, e);
929
939
  return t < 1 ? e : t;
930
940
  }
931
941
  function Ye(r, e) {
@@ -936,7 +946,7 @@ function Ye(r, e) {
936
946
  function m(r) {
937
947
  return r.replace(/&/g, "&amp;").replace(/</g, "&lt;").replace(/>/g, "&gt;").replace(/"/g, "&quot;").replace(/'/g, "&#39;");
938
948
  }
939
- function K(r, e, t) {
949
+ function W(r, e, t) {
940
950
  return w(r, e) >= 0 && w(r, t) <= 0;
941
951
  }
942
952
  function $(r, e) {
@@ -1038,16 +1048,16 @@ class Je extends Te {
1038
1048
  i -= 12, a += 1;
1039
1049
  let s = !1;
1040
1050
  if (String(a) !== (this.getAttribute("year") || "") && (this.setAttribute("year", String(a)), s = !0), String(i) !== (this.getAttribute("month") || "") && (this.setAttribute("month", String(i)), s = !0), s) {
1041
- const d = { year: a, month: i, source: n };
1051
+ const l = { year: a, month: i, source: n };
1042
1052
  this.dispatchEvent(
1043
1053
  new CustomEvent("month-change", {
1044
- detail: d,
1054
+ detail: l,
1045
1055
  bubbles: !0,
1046
1056
  composed: !0
1047
1057
  })
1048
1058
  ), this.dispatchEvent(
1049
1059
  new CustomEvent("ui-month-change", {
1050
- detail: d,
1060
+ detail: l,
1051
1061
  bubbles: !0,
1052
1062
  composed: !0
1053
1063
  })
@@ -1075,7 +1085,7 @@ class Je extends Te {
1075
1085
  }
1076
1086
  }
1077
1087
  _resolvedView() {
1078
- const e = /* @__PURE__ */ new Date(), t = W(this.getAttribute("year"), e.getFullYear()), n = W(this.getAttribute("month"), e.getMonth() + 1);
1088
+ const e = /* @__PURE__ */ new Date(), t = J(this.getAttribute("year"), e.getFullYear()), n = J(this.getAttribute("month"), e.getMonth() + 1);
1079
1089
  return {
1080
1090
  year: t,
1081
1091
  month: O(n, 1, 12)
@@ -1094,7 +1104,7 @@ class Je extends Te {
1094
1104
  return e ? b(e) : null;
1095
1105
  }
1096
1106
  _monthHasAllowedDay(e, t, n, a) {
1097
- const i = b(de(e, t)), s = b(Ne(e, t));
1107
+ const i = b(le(e, t)), s = b(Ne(e, t));
1098
1108
  return !(n && w(s, n) < 0 || a && w(i, a) > 0);
1099
1109
  }
1100
1110
  _resolveSelectionMode() {
@@ -1174,7 +1184,7 @@ class Je extends Te {
1174
1184
  if (!Array.isArray(i))
1175
1185
  n = { mode: e, values: [] };
1176
1186
  else {
1177
- const s = pe(i.map((d) => String(d || "")));
1187
+ const s = pe(i.map((l) => String(l || "")));
1178
1188
  n = { mode: e, values: s };
1179
1189
  }
1180
1190
  } catch {
@@ -1184,7 +1194,7 @@ class Je extends Te {
1184
1194
  }
1185
1195
  if (e === "range") {
1186
1196
  try {
1187
- const i = JSON.parse(t), s = i && typeof i == "object" ? String(i.start || "") : "", d = i && typeof i == "object" ? String(i.end || "") : "", o = c(s), p = c(d), u = o ? b(o) : null, h = p ? b(p) : null;
1197
+ const i = JSON.parse(t), s = i && typeof i == "object" ? String(i.start || "") : "", l = i && typeof i == "object" ? String(i.end || "") : "", o = c(s), p = c(l), u = o ? b(o) : null, h = p ? b(p) : null;
1188
1198
  if (u && h) {
1189
1199
  const f = $(u, h);
1190
1200
  n = { mode: e, start: f.start, end: f.end };
@@ -1247,8 +1257,8 @@ class Je extends Te {
1247
1257
  if (!c(e)) return;
1248
1258
  const a = this._resolveSelectionMode(), { minIso: i, maxIso: s } = this._resolveBounds();
1249
1259
  if (this._isDateOutOfBounds(e, i, s)) return;
1250
- const d = this._isReadonly();
1251
- if (this._isInteractionDisabled() || d) return;
1260
+ const l = this._isReadonly();
1261
+ if (this._isInteractionDisabled() || l) return;
1252
1262
  let o = this._normalizeValueForMode(a);
1253
1263
  if (a === "single")
1254
1264
  o = { mode: a, value: e };
@@ -1258,18 +1268,18 @@ class Je extends Te {
1258
1268
  } else {
1259
1269
  const h = this._normalizeValueForMode("range"), f = h.start, _ = h.end;
1260
1270
  if (t) {
1261
- const l = this._rangeKeyboardAnchor || f || this._focusedIso || e;
1262
- if (!c(l))
1271
+ const d = this._rangeKeyboardAnchor || f || this._focusedIso || e;
1272
+ if (!c(d))
1263
1273
  this._rangeKeyboardAnchor = e, o = { mode: a, start: e, end: null };
1264
1274
  else {
1265
- const v = $(l, e);
1266
- o = { mode: a, start: v.start, end: v.end };
1275
+ const g = $(d, e);
1276
+ o = { mode: a, start: g.start, end: g.end };
1267
1277
  }
1268
1278
  } else if (!f || f && _)
1269
1279
  this._rangeKeyboardAnchor = e, o = { mode: a, start: e, end: null };
1270
1280
  else if (f && !_) {
1271
- const l = $(f, e);
1272
- o = { mode: a, start: l.start, end: l.end };
1281
+ const d = $(f, e);
1282
+ o = { mode: a, start: d.start, end: d.end };
1273
1283
  }
1274
1284
  }
1275
1285
  const p = this.getAttribute("value"), u = this._serializeSelection(o);
@@ -1300,8 +1310,8 @@ class Je extends Te {
1300
1310
  _weekdayLabels(e, t) {
1301
1311
  const n = [], a = new Intl.DateTimeFormat(e, { weekday: "short", timeZone: "UTC" });
1302
1312
  for (let i = 0; i < 7; i += 1) {
1303
- const s = (t + i) % 7, d = new Date(Date.UTC(2024, 0, 7 + s));
1304
- n.push(a.format(d));
1313
+ const s = (t + i) % 7, l = new Date(Date.UTC(2024, 0, 7 + s));
1314
+ n.push(a.format(l));
1305
1315
  }
1306
1316
  return n;
1307
1317
  }
@@ -1329,10 +1339,10 @@ class Je extends Te {
1329
1339
  const n = [];
1330
1340
  t.forEach((a) => {
1331
1341
  if (!a || typeof a != "object") return;
1332
- const i = String(a.date || "").trim(), s = c(i), d = s ? b(s) : "";
1333
- if (!d) return;
1342
+ const i = String(a.date || "").trim(), s = c(i), l = s ? b(s) : "";
1343
+ if (!l) return;
1334
1344
  const o = String(a.tone || "default"), p = o === "success" || o === "warning" || o === "danger" || o === "info" ? o : "default", u = a.title != null ? String(a.title) : void 0;
1335
- n.push({ date: d, title: u, tone: p });
1345
+ n.push({ date: l, title: u, tone: p });
1336
1346
  }), this._eventsParsedCache = n, n.forEach((a) => {
1337
1347
  this._eventsByDateCache.has(a.date) || this._eventsByDateCache.set(a.date, []), this._eventsByDateCache.get(a.date).push(a);
1338
1348
  });
@@ -1340,20 +1350,20 @@ class Je extends Te {
1340
1350
  }
1341
1351
  }
1342
1352
  _buildCells(e, t, n, a, i, s) {
1343
- const d = b(de(e, t)), p = (le(d) - n + 7) % 7, u = c(d);
1353
+ const l = b(le(e, t)), p = (de(l) - n + 7) % 7, u = c(l);
1344
1354
  if (!u) return [];
1345
1355
  const h = B(u);
1346
1356
  h.setUTCDate(h.getUTCDate() - p);
1347
1357
  const f = [];
1348
1358
  for (let _ = 0; _ < 42; _ += 1) {
1349
1359
  _ > 0 && h.setUTCDate(h.getUTCDate() + 1);
1350
- const l = fe(h), v = b(l), D = l.y !== e || l.m !== t, y = this._isDateBlocked(v, D, a, i);
1360
+ const d = fe(h), g = b(d), D = d.y !== e || d.m !== t, y = this._isDateBlocked(g, D, a, i);
1351
1361
  f.push({
1352
- iso: v,
1353
- parts: l,
1362
+ iso: g,
1363
+ parts: d,
1354
1364
  outside: D,
1355
1365
  disabled: y,
1356
- today: v === s
1366
+ today: g === s
1357
1367
  });
1358
1368
  }
1359
1369
  return f;
@@ -1368,8 +1378,8 @@ class Je extends Te {
1368
1378
  };
1369
1379
  let s = i(this._focusedIso);
1370
1380
  if (s || (t.mode === "single" && (s = i(t.value)), !s && t.mode === "range" && (s = i(t.end || t.start)), !s && t.mode === "multiple" && (s = i(t.values[0])), s || (s = i(n)), s)) return s;
1371
- const d = e.find((o) => !o.disabled);
1372
- return d ? d.iso : e[0]?.iso || "";
1381
+ const l = e.find((o) => !o.disabled);
1382
+ return l ? l.iso : e[0]?.iso || "";
1373
1383
  }
1374
1384
  _focusDateButton(e) {
1375
1385
  if (!e || this.root.activeElement?.getAttribute("data-date") === e) return;
@@ -1390,7 +1400,7 @@ class Je extends Te {
1390
1400
  a && (this.goToMonth(a.y, a.m, "keyboard"), this._focusedIso = n, this._shouldRefocus = !0, this.requestRender());
1391
1401
  }
1392
1402
  _focusWeekBoundary(e, t, n) {
1393
- const i = (le(e) - n + 7) % 7, s = t === "start" ? -i : 6 - i;
1403
+ const i = (de(e) - n + 7) % 7, s = t === "start" ? -i : 6 - i;
1394
1404
  this._moveFocusByDays(e, s, !1);
1395
1405
  }
1396
1406
  _onPointerOver(e) {
@@ -1401,8 +1411,8 @@ class Je extends Te {
1401
1411
  if (!a) return;
1402
1412
  const i = a.getAttribute("data-date") || "";
1403
1413
  if (!c(i)) return;
1404
- const s = a.getAttribute("data-outside") === "true", { minIso: d, maxIso: o } = this._resolveBounds();
1405
- this._isDateBlocked(i, s, d, o) || this._hoverIso !== i && (this._hoverIso = i, this.requestRender());
1414
+ const s = a.getAttribute("data-outside") === "true", { minIso: l, maxIso: o } = this._resolveBounds();
1415
+ this._isDateBlocked(i, s, l, o) || this._hoverIso !== i && (this._hoverIso = i, this.requestRender());
1406
1416
  }
1407
1417
  _onMouseLeave() {
1408
1418
  this._hoverIso != null && (this._hoverIso = null, this.requestRender());
@@ -1422,16 +1432,16 @@ class Je extends Te {
1422
1432
  _onClick(e) {
1423
1433
  const t = e.target;
1424
1434
  if (!t) return;
1425
- const n = t.closest("[data-action]"), a = n?.getAttribute("data-action") || "", { year: i, month: s } = this._resolvedView(), d = this._todayIso(), o = c(d);
1435
+ const n = t.closest("[data-action]"), a = n?.getAttribute("data-action") || "", { year: i, month: s } = this._resolvedView(), l = this._todayIso(), o = c(l);
1426
1436
  if (a === "prev-month" || a === "next-month") {
1427
1437
  if (this._isInteractionDisabled()) return;
1428
- const l = a === "prev-month" ? -1 : 1, D = (this._focusedIso ? c(this._focusedIso) : null) || { y: i, m: s, d: 1 }, y = P(D, l);
1438
+ const d = a === "prev-month" ? -1 : 1, D = (this._focusedIso ? c(this._focusedIso) : null) || { y: i, m: s, d: 1 }, y = P(D, d);
1429
1439
  this.goToMonth(y.y, y.m, "pointer"), this._focusedIso = b({ y: y.y, m: y.m, d: O(D.d, 1, F(y.y, y.m)) }), this._shouldRefocus = !0, this.requestRender();
1430
1440
  return;
1431
1441
  }
1432
1442
  if (a === "today") {
1433
1443
  if (this._isInteractionDisabled()) return;
1434
- this.goToMonth(o.y, o.m, "pointer"), this._focusedIso = d, this._shouldRefocus = !0, this._isReadonly() ? this.requestRender() : this._applySelection(d, !1, "pointer");
1444
+ this.goToMonth(o.y, o.m, "pointer"), this._focusedIso = l, this._shouldRefocus = !0, this._isReadonly() ? this.requestRender() : this._applySelection(l, !1, "pointer");
1435
1445
  return;
1436
1446
  }
1437
1447
  if (a === "toggle-monthyear") {
@@ -1440,15 +1450,15 @@ class Je extends Te {
1440
1450
  }
1441
1451
  if (a === "picker-prev-year" || a === "picker-next-year") {
1442
1452
  if (this._isInteractionDisabled()) return;
1443
- const l = a === "picker-prev-year" ? -1 : 1;
1444
- this.goToMonth(i + l, s, "pointer"), this._pickerOpen = !0, this._shouldRefocus = !0, this.requestRender();
1453
+ const d = a === "picker-prev-year" ? -1 : 1;
1454
+ this.goToMonth(i + d, s, "pointer"), this._pickerOpen = !0, this._shouldRefocus = !0, this.requestRender();
1445
1455
  return;
1446
1456
  }
1447
1457
  if (a === "pick-month") {
1448
1458
  if (this._isInteractionDisabled()) return;
1449
- const l = Number(n?.getAttribute("data-month") || "");
1450
- if (!Number.isInteger(l) || l < 1 || l > 12) return;
1451
- this.goToMonth(i, l, "pointer"), this._pickerOpen = !1, this._shouldRefocus = !0, this.requestRender();
1459
+ const d = Number(n?.getAttribute("data-month") || "");
1460
+ if (!Number.isInteger(d) || d < 1 || d > 12) return;
1461
+ this.goToMonth(i, d, "pointer"), this._pickerOpen = !1, this._shouldRefocus = !0, this.requestRender();
1452
1462
  return;
1453
1463
  }
1454
1464
  const p = t.closest(".day");
@@ -1458,11 +1468,11 @@ class Je extends Te {
1458
1468
  const h = p.getAttribute("data-outside") === "true", { minIso: f, maxIso: _ } = this._resolveBounds();
1459
1469
  if (!this._isDateBlocked(u, h, f, _)) {
1460
1470
  if (h) {
1461
- const l = this._resolveOutsideClickMode();
1462
- if (l === "none") return;
1463
- if (l === "navigate") {
1464
- const v = c(u);
1465
- this.goToMonth(v.y, v.m, "pointer");
1471
+ const d = this._resolveOutsideClickMode();
1472
+ if (d === "none") return;
1473
+ if (d === "navigate") {
1474
+ const g = c(u);
1475
+ this.goToMonth(g.y, g.m, "pointer");
1466
1476
  }
1467
1477
  }
1468
1478
  if (this._isReadonly()) {
@@ -1481,21 +1491,21 @@ class Je extends Te {
1481
1491
  if (!n) return;
1482
1492
  const a = n.getAttribute("data-date") || "";
1483
1493
  if (!c(a)) return;
1484
- const i = ue(this.getAttribute("week-start"), this._resolveLocale()), s = this._direction() === "rtl", d = e.shiftKey;
1494
+ const i = ue(this.getAttribute("week-start"), this._resolveLocale()), s = this._direction() === "rtl", l = e.shiftKey;
1485
1495
  if (e.key === "ArrowRight") {
1486
- e.preventDefault(), this._moveFocusByDays(a, s ? -1 : 1, d);
1496
+ e.preventDefault(), this._moveFocusByDays(a, s ? -1 : 1, l);
1487
1497
  return;
1488
1498
  }
1489
1499
  if (e.key === "ArrowLeft") {
1490
- e.preventDefault(), this._moveFocusByDays(a, s ? 1 : -1, d);
1500
+ e.preventDefault(), this._moveFocusByDays(a, s ? 1 : -1, l);
1491
1501
  return;
1492
1502
  }
1493
1503
  if (e.key === "ArrowDown") {
1494
- e.preventDefault(), this._moveFocusByDays(a, 7, d);
1504
+ e.preventDefault(), this._moveFocusByDays(a, 7, l);
1495
1505
  return;
1496
1506
  }
1497
1507
  if (e.key === "ArrowUp") {
1498
- e.preventDefault(), this._moveFocusByDays(a, -7, d);
1508
+ e.preventDefault(), this._moveFocusByDays(a, -7, l);
1499
1509
  return;
1500
1510
  }
1501
1511
  if (e.key === "Home") {
@@ -1526,63 +1536,63 @@ class Je extends Te {
1526
1536
  }
1527
1537
  }
1528
1538
  render() {
1529
- const e = this._resolveLocale(), t = this._translations(), n = ue(this.getAttribute("week-start"), e), { year: a, month: i } = this._resolvedView(), s = this._resolveSelectionMode(), { minIso: d, maxIso: o } = this._resolveBounds(), p = this._todayIso(), u = this._resolveEventsDisplay(), h = this._eventsMax(), f = this._resolveCalendarSize(), _ = this._resolveTone(), l = this._resolveState(), v = this._isInteractionDisabled(), D = this._resolveLabel();
1530
- _ ? this.setAttribute("tone", _) : this.removeAttribute("tone"), l !== "idle" ? this.setAttribute("state", l) : this.removeAttribute("state"), l === "loading" ? this.setAttribute("aria-busy", "true") : this.removeAttribute("aria-busy"), this._ensureEventsCache();
1531
- const y = this._normalizeValueForMode(s), J = this._buildCells(a, i, n, d, o, p);
1532
- this._focusedIso = this._resolveFocusIso(J, y, p);
1533
- const U = this._monthLabel(a, i, e), Z = P({ y: a, m: i, d: 1 }, -1), X = P({ y: a, m: i, d: 1 }, 1), ge = this._monthHasAllowedDay(Z.y, Z.m, d, o), ve = this._monthHasAllowedDay(X.y, X.m, d, o), be = this._weekdayLabels(e, n), G = s === "range" ? y : null, S = G?.start || null, M = G?.end || null, me = s === "multiple" ? new Set(y.values) : null;
1539
+ const e = this._resolveLocale(), t = this._translations(), n = ue(this.getAttribute("week-start"), e), { year: a, month: i } = this._resolvedView(), s = this._resolveSelectionMode(), { minIso: l, maxIso: o } = this._resolveBounds(), p = this._todayIso(), u = this._resolveEventsDisplay(), h = this._eventsMax(), f = this._resolveCalendarSize(), _ = this._resolveTone(), d = this._resolveState(), g = this._isInteractionDisabled(), D = this._resolveLabel();
1540
+ _ ? this.setAttribute("tone", _) : this.removeAttribute("tone"), d !== "idle" ? this.setAttribute("state", d) : this.removeAttribute("state"), d === "loading" ? this.setAttribute("aria-busy", "true") : this.removeAttribute("aria-busy"), this._ensureEventsCache();
1541
+ const y = this._normalizeValueForMode(s), Z = this._buildCells(a, i, n, l, o, p);
1542
+ this._focusedIso = this._resolveFocusIso(Z, y, p);
1543
+ const U = this._monthLabel(a, i, e), X = P({ y: a, m: i, d: 1 }, -1), G = P({ y: a, m: i, d: 1 }, 1), ve = this._monthHasAllowedDay(X.y, X.m, l, o), ge = this._monthHasAllowedDay(G.y, G.m, l, o), be = this._weekdayLabels(e, n), Q = s === "range" ? y : null, S = Q?.start || null, M = Q?.end || null, me = s === "multiple" ? new Set(y.values) : null;
1534
1544
  let H = null, N = null;
1535
1545
  if (s === "range" && S && !M && this._hoverIso && c(this._hoverIso)) {
1536
1546
  const x = $(S, this._hoverIso);
1537
1547
  H = x.start, N = x.end;
1538
1548
  }
1539
- const Q = [];
1549
+ const ee = [];
1540
1550
  for (let x = 0; x < 6; x += 1) {
1541
- const I = J.slice(x * 7, x * 7 + 7).map((g) => {
1542
- const k = this._eventsByDateCache.get(g.iso) || [], De = this._dayAriaLabel(g.iso, e);
1551
+ const I = Z.slice(x * 7, x * 7 + 7).map((v) => {
1552
+ const k = this._eventsByDateCache.get(v.iso) || [], De = this._dayAriaLabel(v.iso, e);
1543
1553
  let A = !1;
1544
- s === "single" ? A = y.value === g.iso : s === "multiple" ? A = me?.has(g.iso) || !1 : S && M && (A = K(g.iso, S, M));
1545
- const T = !!(S && M && K(g.iso, S, M)), Y = !!(S && g.iso === S), j = !!(M && g.iso === M), Se = !!(H && N && K(g.iso, H, N)), Me = !g.disabled && g.iso === this._focusedIso ? 0 : -1;
1554
+ s === "single" ? A = y.value === v.iso : s === "multiple" ? A = me?.has(v.iso) || !1 : S && M && (A = W(v.iso, S, M));
1555
+ const T = !!(S && M && W(v.iso, S, M)), Y = !!(S && v.iso === S), j = !!(M && v.iso === M), Se = !!(H && N && W(v.iso, H, N)), Me = !v.disabled && v.iso === this._focusedIso ? 0 : -1;
1546
1556
  let C = "";
1547
- k.length > 0 && (u === "count" ? C = `<span class="event-count" part="event-more" style="--event-tone:${q[k[0].tone || "default"]}">${k.length}</span>` : u === "badges" ? C = k.slice(0, h).map((z) => {
1548
- const V = m(z.title || t.event);
1549
- return `<span class="event-badge" part="event-dot" style="--event-tone:${q[z.tone || "default"]}" title="${V}">${V}</span>`;
1550
- }).join("") : C = k.slice(0, h).map((z) => `<span class="event-dot" part="event-dot" style="--event-tone:${q[z.tone || "default"]}"></span>`).join(""), k.length > h && u !== "count" && (C += `<span class="event-more" part="event-more">+${k.length - h}</span>`));
1551
- const ae = `ui-calendar-tip-${g.iso}`, ne = k.length ? k.map((R) => m(R.title || t.event)).join("<br/>") : "", re = ne.length > 0, Ce = C ? `<span class="events" part="events" aria-hidden="true">${C}</span>` : "", Ie = re ? `<span class="tooltip" part="tooltip" id="${ae}">${ne}</span>` : "", ie = A || T || Y || j, Ae = T || Y || j ? "day range" : "day";
1557
+ k.length > 0 && (u === "count" ? C = `<span class="event-count" part="event-more" style="--event-tone:${K[k[0].tone || "default"]}">${k.length}</span>` : u === "badges" ? C = k.slice(0, h).map((z) => {
1558
+ const q = m(z.title || t.event);
1559
+ return `<span class="event-badge" part="event-dot" style="--event-tone:${K[z.tone || "default"]}" title="${q}">${q}</span>`;
1560
+ }).join("") : C = k.slice(0, h).map((z) => `<span class="event-dot" part="event-dot" style="--event-tone:${K[z.tone || "default"]}"></span>`).join(""), k.length > h && u !== "count" && (C += `<span class="event-more" part="event-more">+${k.length - h}</span>`));
1561
+ const ne = `ui-calendar-tip-${v.iso}`, re = k.length ? k.map((R) => m(R.title || t.event)).join("<br/>") : "", ie = re.length > 0, Ce = C ? `<span class="events" part="events" aria-hidden="true">${C}</span>` : "", Ie = ie ? `<span class="tooltip" part="tooltip" id="${ne}">${re}</span>` : "", V = A || T || Y || j, Ae = T || Y || j ? "day range" : "day";
1552
1562
  return `
1553
- <div class="day-cell" part="day-cell"${C ? ` data-events="${u}"` : ""}>
1563
+ <div class="day-cell" part="day-cell"${C ? ` data-events="${u}"` : ""}${V ? ' data-selected="true"' : ""}>
1554
1564
  <button
1555
1565
  type="button"
1556
1566
  class="day"
1557
1567
  part="${Ae}"
1558
1568
  role="gridcell"
1559
- data-date="${g.iso}"
1560
- data-outside="${g.outside ? "true" : "false"}"
1561
- data-disabled="${g.disabled ? "true" : "false"}"
1562
- data-today="${g.today ? "true" : "false"}"
1563
- data-selected="${ie ? "true" : "false"}"
1569
+ data-date="${v.iso}"
1570
+ data-outside="${v.outside ? "true" : "false"}"
1571
+ data-disabled="${v.disabled ? "true" : "false"}"
1572
+ data-today="${v.today ? "true" : "false"}"
1573
+ data-selected="${V ? "true" : "false"}"
1564
1574
  data-range="${T ? "true" : "false"}"
1565
1575
  data-range-start="${Y ? "true" : "false"}"
1566
1576
  data-range-end="${j ? "true" : "false"}"
1567
1577
  data-range-preview="${!T && Se ? "true" : "false"}"
1568
- aria-selected="${ie ? "true" : "false"}"
1569
- aria-disabled="${g.disabled ? "true" : "false"}"
1570
- ${g.today ? 'aria-current="date"' : ""}
1578
+ aria-selected="${V ? "true" : "false"}"
1579
+ aria-disabled="${v.disabled ? "true" : "false"}"
1580
+ ${v.today ? 'aria-current="date"' : ""}
1571
1581
  aria-label="${m(De)}"
1572
- ${re ? `aria-describedby="${ae}"` : ""}
1582
+ ${ie ? `aria-describedby="${ne}"` : ""}
1573
1583
  tabindex="${Me}"
1574
1584
  >
1575
- <span class="day-number" part="day-number">${g.parts.d}</span>
1585
+ <span class="day-number" part="day-number">${v.parts.d}</span>
1576
1586
  </button>
1577
1587
  ${Ce}
1578
1588
  ${Ie}
1579
1589
  </div>
1580
1590
  `;
1581
1591
  }).join("");
1582
- Q.push(`<div class="week" role="row">${I}</div>`);
1592
+ ee.push(`<div class="week" role="row">${I}</div>`);
1583
1593
  }
1584
- const ye = this._monthPickerLabels(e).map((x, te) => {
1585
- const I = te + 1;
1594
+ const ye = this._monthPickerLabels(e).map((x, ae) => {
1595
+ const I = ae + 1;
1586
1596
  return `
1587
1597
  <button
1588
1598
  type="button"
@@ -1591,30 +1601,30 @@ class Je extends Te {
1591
1601
  data-action="pick-month"
1592
1602
  data-month="${I}"
1593
1603
  data-active="${I === i ? "true" : "false"}"
1594
- ${v ? "disabled" : ""}
1604
+ ${g ? "disabled" : ""}
1595
1605
  >
1596
1606
  ${x}
1597
1607
  </button>
1598
1608
  `;
1599
- }).join(""), _e = be.map((x) => `<span class="weekday" part="weekday" role="columnheader">${m(x)}</span>`).join(""), xe = this._showTodayButton() ? `<button type="button" class="today-btn" part="today" data-action="today" ${v ? "disabled" : ""}>${m(t.today)}</button>` : "", ee = l === "loading" ? t.syncingSchedule : l === "error" ? t.unableToSyncEvents : l === "success" ? t.scheduleSynced : "";
1609
+ }).join(""), _e = be.map((x) => `<span class="weekday" part="weekday" role="columnheader">${m(x)}</span>`).join(""), xe = this._showTodayButton() ? `<button type="button" class="today-btn" part="today" data-action="today" ${g ? "disabled" : ""}>${m(t.today)}</button>` : "", te = d === "loading" ? t.syncingSchedule : d === "error" ? t.unableToSyncEvents : d === "success" ? t.scheduleSynced : "";
1600
1610
  this.setContent(`
1601
1611
  <style>${Fe}</style>
1602
1612
  <section
1603
1613
  class="frame"
1604
1614
  part="frame"
1605
1615
  data-size="${f}"
1606
- data-state="${l}"
1607
- aria-disabled="${v ? "true" : "false"}"
1616
+ data-state="${d}"
1617
+ aria-disabled="${g ? "true" : "false"}"
1608
1618
  aria-label="${m(D)}"
1609
1619
  >
1610
1620
  <div class="live-region" aria-live="polite" aria-atomic="true">${m(U)}</div>
1611
1621
 
1612
1622
  <header class="header" part="header">
1613
1623
  <div class="nav" part="nav">
1614
- <button type="button" class="nav-btn" part="prev" data-action="prev-month" ${!ge || v ? "disabled" : ""} aria-label="${m(t.previousMonth)}">
1624
+ <button type="button" class="nav-btn" part="prev" data-action="prev-month" ${!ve || g ? "disabled" : ""} aria-label="${m(t.previousMonth)}">
1615
1625
  <svg viewBox="0 0 24 24" width="14" height="14" aria-hidden="true" focusable="false"><path d="M14.7 6.3a1 1 0 0 1 0 1.4L10.41 12l4.29 4.3a1 1 0 1 1-1.42 1.4l-5-5a1 1 0 0 1 0-1.4l5-5a1 1 0 0 1 1.42 0Z" fill="currentColor"/></svg>
1616
1626
  </button>
1617
- <button type="button" class="nav-btn" part="next" data-action="next-month" ${!ve || v ? "disabled" : ""} aria-label="${m(t.nextMonth)}">
1627
+ <button type="button" class="nav-btn" part="next" data-action="next-month" ${!ge || g ? "disabled" : ""} aria-label="${m(t.nextMonth)}">
1618
1628
  <svg viewBox="0 0 24 24" width="14" height="14" aria-hidden="true" focusable="false"><path d="M9.3 17.7a1 1 0 0 1 0-1.4L13.59 12 9.3 7.7a1 1 0 0 1 1.4-1.4l5 5a1 1 0 0 1 0 1.4l-5 5a1 1 0 0 1-1.4 0Z" fill="currentColor"/></svg>
1619
1629
  </button>
1620
1630
  </div>
@@ -1625,7 +1635,7 @@ class Je extends Te {
1625
1635
  class="title-btn"
1626
1636
  part="title monthyear"
1627
1637
  data-action="toggle-monthyear"
1628
- ${v ? "disabled" : ""}
1638
+ ${g ? "disabled" : ""}
1629
1639
  aria-expanded="${this._pickerOpen ? "true" : "false"}"
1630
1640
  aria-label="${m(`${U}, ${t.chooseMonthYear}`)}"
1631
1641
  >
@@ -1634,9 +1644,9 @@ class Je extends Te {
1634
1644
  </button>
1635
1645
  <section class="monthyear-pop" part="monthyear" ${this._pickerOpen ? "" : "hidden"}>
1636
1646
  <div class="picker-header">
1637
- <button type="button" class="picker-year-btn" part="prev" data-action="picker-prev-year" ${v ? "disabled" : ""} aria-label="${m(t.previousYear)}">-</button>
1647
+ <button type="button" class="picker-year-btn" part="prev" data-action="picker-prev-year" ${g ? "disabled" : ""} aria-label="${m(t.previousYear)}">-</button>
1638
1648
  <span class="picker-year">${a}</span>
1639
- <button type="button" class="picker-year-btn" part="next" data-action="picker-next-year" ${v ? "disabled" : ""} aria-label="${m(t.nextYear)}">+</button>
1649
+ <button type="button" class="picker-year-btn" part="next" data-action="picker-next-year" ${g ? "disabled" : ""} aria-label="${m(t.nextYear)}">+</button>
1640
1650
  </div>
1641
1651
  <div class="picker-months">${ye}</div>
1642
1652
  </section>
@@ -1647,14 +1657,14 @@ class Je extends Te {
1647
1657
  </div>
1648
1658
  </header>
1649
1659
 
1650
- <div class="status" part="status" ${ee ? "" : "hidden"}>
1660
+ <div class="status" part="status" ${te ? "" : "hidden"}>
1651
1661
  <span class="status-dot" aria-hidden="true"></span>
1652
- <span>${m(ee)}</span>
1662
+ <span>${m(te)}</span>
1653
1663
  </div>
1654
1664
 
1655
1665
  <div class="grid-wrap" part="grid" role="grid" aria-label="${m(D)}">
1656
1666
  <div class="weekdays" role="row">${_e}</div>
1657
- ${Q.join("")}
1667
+ ${ee.join("")}
1658
1668
  </div>
1659
1669
  </section>
1660
1670
  `);
@@ -1676,5 +1686,5 @@ export {
1676
1686
  Ne as e,
1677
1687
  c as p,
1678
1688
  Be as r,
1679
- de as s
1689
+ le as s
1680
1690
  };
@@ -1 +1 @@
1
- "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./calendar-D-mXMgqc.js");exports.UICalendar=e.UICalendar;exports.addDaysISO=e.addDaysISO;exports.addMonthsISO=e.addMonthsISO;exports.compareISO=e.compareISO;exports.endOfMonth=e.endOfMonth;exports.parseISO=e.parseISO;exports.startOfMonth=e.startOfMonth;
1
+ "use strict";Object.defineProperties(exports,{__esModule:{value:!0},[Symbol.toStringTag]:{value:"Module"}});const e=require("./calendar-CzpWDxLc.js");exports.UICalendar=e.UICalendar;exports.addDaysISO=e.addDaysISO;exports.addMonthsISO=e.addMonthsISO;exports.compareISO=e.compareISO;exports.endOfMonth=e.endOfMonth;exports.parseISO=e.parseISO;exports.startOfMonth=e.startOfMonth;
@@ -1,4 +1,4 @@
1
- import { U as d, a as e, b as o, c as r, e as t, p as O, s as n } from "./calendar-B3PUKHQm.mjs";
1
+ import { U as d, a as e, b as o, c as r, e as t, p as O, s as n } from "./calendar-DkSDFg33.mjs";
2
2
  export {
3
3
  d as UICalendar,
4
4
  e as addDaysISO,