@caspeco/casper-ui-library 10.4.0 → 10.5.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 (781) hide show
  1. package/dist/_virtual/_rolldown/runtime.js +11 -0
  2. package/dist/_virtual/builtin_esm-external-require-react.js +9 -0
  3. package/dist/components/accordion/accordion-context.js +5 -6
  4. package/dist/components/accordion/accordion-item.js +28 -40
  5. package/dist/components/accordion/accordion-panel.js +17 -14
  6. package/dist/components/accordion/accordion-recipe.js +85 -120
  7. package/dist/components/accordion/accordion.js +23 -20
  8. package/dist/components/alert/alert.js +80 -59
  9. package/dist/components/alert/helper.js +30 -42
  10. package/dist/components/alert/types.d.ts.map +1 -1
  11. package/dist/components/badge/badge-recipe.js +57 -49
  12. package/dist/components/badge/badge.js +66 -71
  13. package/dist/components/badge/helper.js +8 -9
  14. package/dist/components/box/box.js +14 -11
  15. package/dist/components/breadcrumbs/breadcrumb-item.js +21 -17
  16. package/dist/components/breadcrumbs/breadcrumb-link.js +21 -20
  17. package/dist/components/breadcrumbs/breadcrumbs.js +123 -90
  18. package/dist/components/button/button-recipe.js +280 -315
  19. package/dist/components/button/button.js +39 -40
  20. package/dist/components/checkbox/checkbox-icon.js +38 -46
  21. package/dist/components/checkbox/checkbox-recipe.js +176 -204
  22. package/dist/components/checkbox/checkbox.js +43 -36
  23. package/dist/components/checkbox/icons/check.js +5 -5
  24. package/dist/components/checkbox/icons/minus.js +5 -5
  25. package/dist/components/checkbox/icons/plus.js +5 -5
  26. package/dist/components/checkbox-group/checkbox-group.js +17 -16
  27. package/dist/components/collapsible/collapsible.js +117 -101
  28. package/dist/components/collapsible/translations.js +29 -29
  29. package/dist/components/combobox/combobox-button.js +173 -143
  30. package/dist/components/combobox/combobox-item.js +45 -23
  31. package/dist/components/combobox/combobox-menu.js +240 -190
  32. package/dist/components/combobox/combobox-recipe.js +69 -103
  33. package/dist/components/combobox/combobox.js +243 -273
  34. package/dist/components/combobox/translations.js +49 -50
  35. package/dist/components/date-picker/base-date-picker.js +238 -248
  36. package/dist/components/date-picker/date-cell-recipe.js +149 -179
  37. package/dist/components/date-picker/date-multi-picker.js +35 -29
  38. package/dist/components/date-picker/date-picker-date-cell.js +109 -114
  39. package/dist/components/date-picker/date-picker-header.js +152 -170
  40. package/dist/components/date-picker/date-picker-week-cell.js +41 -43
  41. package/dist/components/date-picker/date-picker.js +32 -29
  42. package/dist/components/date-picker/date-range-picker.js +29 -24
  43. package/dist/components/date-picker/date-week-picker.js +29 -22
  44. package/dist/components/date-picker/datepicker-week-recipe.js +75 -91
  45. package/dist/components/date-picker/helper.js +11 -16
  46. package/dist/components/divider/divider-recipe.js +9 -11
  47. package/dist/components/divider/divider.js +19 -18
  48. package/dist/components/drawer/drawer-recipe.js +21 -50
  49. package/dist/components/drawer/drawer.js +45 -41
  50. package/dist/components/drawer/inline-drawer.js +69 -66
  51. package/dist/components/drawer/use-drawer-key-down.js +20 -20
  52. package/dist/components/fieldset/fieldset-error-text.js +15 -15
  53. package/dist/components/fieldset/fieldset-helper-text.js +15 -15
  54. package/dist/components/fieldset/fieldset-legend.js +15 -15
  55. package/dist/components/fieldset/fieldset-recipe.js +14 -24
  56. package/dist/components/fieldset/fieldset.js +17 -17
  57. package/dist/components/flex/flex.js +15 -15
  58. package/dist/components/form-control/form-control-recipe.js +42 -46
  59. package/dist/components/form-control/form-control.js +19 -19
  60. package/dist/components/form-control/form-error-message.js +15 -15
  61. package/dist/components/form-control/form-helper-text.js +15 -15
  62. package/dist/components/form-control/form-label.js +24 -26
  63. package/dist/components/grid/grid-item.js +15 -15
  64. package/dist/components/grid/grid.js +15 -15
  65. package/dist/components/heading/heading.js +24 -23
  66. package/dist/components/highlight/highlight.js +22 -21
  67. package/dist/components/icon/create-icon.js +27 -26
  68. package/dist/components/icon/icons/absence-icon.js +5 -5
  69. package/dist/components/icon/icons/accessibility-icon.js +5 -5
  70. package/dist/components/icon/icons/add-absence-icon.js +5 -5
  71. package/dist/components/icon/icons/add-emoji-icon.js +5 -5
  72. package/dist/components/icon/icons/add-icon.js +5 -5
  73. package/dist/components/icon/icons/apple-icon.js +5 -5
  74. package/dist/components/icon/icons/apps-icon.js +5 -5
  75. package/dist/components/icon/icons/archive-icon.js +6 -6
  76. package/dist/components/icon/icons/area-icon.js +5 -5
  77. package/dist/components/icon/icons/at-icon.js +5 -5
  78. package/dist/components/icon/icons/attachment-icon.js +5 -5
  79. package/dist/components/icon/icons/baby-icon.js +5 -5
  80. package/dist/components/icon/icons/back-icon.js +5 -5
  81. package/dist/components/icon/icons/backspace-icon.js +5 -5
  82. package/dist/components/icon/icons/bank-icon.js +5 -5
  83. package/dist/components/icon/icons/bank-id-icon.js +5 -5
  84. package/dist/components/icon/icons/barcode-icon.js +5 -5
  85. package/dist/components/icon/icons/bell-icon.js +5 -5
  86. package/dist/components/icon/icons/bolt-icon.js +7 -7
  87. package/dist/components/icon/icons/calendar-icon.js +5 -5
  88. package/dist/components/icon/icons/camera-icon.js +5 -5
  89. package/dist/components/icon/icons/cancel-icon.js +5 -5
  90. package/dist/components/icon/icons/card-icon.js +5 -5
  91. package/dist/components/icon/icons/cart-icon.js +5 -5
  92. package/dist/components/icon/icons/caspeco-icon.js +7 -7
  93. package/dist/components/icon/icons/channels-icon.js +5 -5
  94. package/dist/components/icon/icons/chart-icon.js +5 -5
  95. package/dist/components/icon/icons/chart-line-icon.js +5 -5
  96. package/dist/components/icon/icons/chart-mixed-icon.js +5 -5
  97. package/dist/components/icon/icons/chart-pie-icon.js +5 -5
  98. package/dist/components/icon/icons/chart-scatter-icon.js +5 -5
  99. package/dist/components/icon/icons/check-icon.js +5 -5
  100. package/dist/components/icon/icons/checkbox-icon.js +5 -5
  101. package/dist/components/icon/icons/chevron-left-icon.js +5 -5
  102. package/dist/components/icon/icons/chevron-right-icon.js +5 -5
  103. package/dist/components/icon/icons/child-icon.js +5 -5
  104. package/dist/components/icon/icons/circle-info-icon.js +5 -5
  105. package/dist/components/icon/icons/circle-parking-icon.js +5 -5
  106. package/dist/components/icon/icons/circle-question-icon.js +5 -5
  107. package/dist/components/icon/icons/circle-select-icon.js +5 -5
  108. package/dist/components/icon/icons/circle-success-icon.js +5 -5
  109. package/dist/components/icon/icons/circle-user-icon.js +5 -5
  110. package/dist/components/icon/icons/clear-icon.js +5 -5
  111. package/dist/components/icon/icons/close-icon.js +5 -5
  112. package/dist/components/icon/icons/closed-icon.js +5 -5
  113. package/dist/components/icon/icons/collapse-icon.js +5 -5
  114. package/dist/components/icon/icons/color-icon.js +5 -5
  115. package/dist/components/icon/icons/columns-icon.js +5 -5
  116. package/dist/components/icon/icons/comment-add-icon.js +5 -5
  117. package/dist/components/icon/icons/comment-icon.js +5 -5
  118. package/dist/components/icon/icons/cookies-icon.js +5 -5
  119. package/dist/components/icon/icons/copy-icon.js +5 -5
  120. package/dist/components/icon/icons/date-icon.js +5 -5
  121. package/dist/components/icon/icons/decrease-icon.js +4 -4
  122. package/dist/components/icon/icons/delete-icon.js +5 -5
  123. package/dist/components/icon/icons/deliverect-icon.js +5 -5
  124. package/dist/components/icon/icons/delivery-icon.js +5 -5
  125. package/dist/components/icon/icons/description-icon.js +5 -5
  126. package/dist/components/icon/icons/discount-icon.js +5 -5
  127. package/dist/components/icon/icons/distribute-evenly-icon.js +5 -5
  128. package/dist/components/icon/icons/door-closed-icon.js +5 -5
  129. package/dist/components/icon/icons/door-open-icon.js +5 -5
  130. package/dist/components/icon/icons/down-icon.js +5 -5
  131. package/dist/components/icon/icons/eat-in-icon.js +5 -5
  132. package/dist/components/icon/icons/edit-icon.js +5 -5
  133. package/dist/components/icon/icons/email-icon.js +5 -5
  134. package/dist/components/icon/icons/error-icon.js +5 -5
  135. package/dist/components/icon/icons/expand-icon.js +5 -5
  136. package/dist/components/icon/icons/export-icon.js +5 -5
  137. package/dist/components/icon/icons/extract-icon.js +5 -5
  138. package/dist/components/icon/icons/facebook-icon.js +5 -5
  139. package/dist/components/icon/icons/failed-print-icon.js +5 -5
  140. package/dist/components/icon/icons/file-icon.js +5 -5
  141. package/dist/components/icon/icons/filter-icon.js +5 -5
  142. package/dist/components/icon/icons/folder-icon.js +5 -5
  143. package/dist/components/icon/icons/foodora-icon.js +5 -5
  144. package/dist/components/icon/icons/forward-icon.js +5 -5
  145. package/dist/components/icon/icons/glovo-icon.js +7 -7
  146. package/dist/components/icon/icons/goal-icon.js +5 -5
  147. package/dist/components/icon/icons/google-icon.js +5 -5
  148. package/dist/components/icon/icons/grip-more-icon.js +5 -5
  149. package/dist/components/icon/icons/hash-icon.js +5 -5
  150. package/dist/components/icon/icons/hexagon-error-icon.js +5 -5
  151. package/dist/components/icon/icons/hide-icon.js +5 -5
  152. package/dist/components/icon/icons/history-icon.js +5 -5
  153. package/dist/components/icon/icons/icon-picker-anchor-icon.js +5 -5
  154. package/dist/components/icon/icons/icon-picker-asterisk-icon.js +5 -5
  155. package/dist/components/icon/icons/icon-picker-beer-icon.js +5 -5
  156. package/dist/components/icon/icons/icon-picker-bicycle-icon.js +5 -5
  157. package/dist/components/icon/icons/icon-picker-binoculars-icon.js +5 -5
  158. package/dist/components/icon/icons/icon-picker-bomb-icon.js +5 -5
  159. package/dist/components/icon/icons/icon-picker-car-icon.js +5 -5
  160. package/dist/components/icon/icons/icon-picker-cocktail-icon.js +5 -5
  161. package/dist/components/icon/icons/icon-picker-gem-icon.js +5 -5
  162. package/dist/components/icon/icons/icon-picker-heart-full-icon.js +5 -5
  163. package/dist/components/icon/icons/icon-picker-heart-icon.js +5 -5
  164. package/dist/components/icon/icons/icon-picker-magnet-icon.js +5 -5
  165. package/dist/components/icon/icons/icon-picker-money-icon.js +5 -5
  166. package/dist/components/icon/icons/icon-picker-moon-icon.js +5 -5
  167. package/dist/components/icon/icons/icon-picker-music-icon.js +5 -5
  168. package/dist/components/icon/icons/icon-picker-star-full-icon.js +5 -5
  169. package/dist/components/icon/icons/icon-picker-star-half-icon.js +5 -5
  170. package/dist/components/icon/icons/icon-picker-star-icon.js +5 -5
  171. package/dist/components/icon/icons/icon-picker-tint-icon.js +5 -5
  172. package/dist/components/icon/icons/icon-picker-tree-icon.js +5 -5
  173. package/dist/components/icon/icons/icon-picker-utensils-icon.js +5 -5
  174. package/dist/components/icon/icons/icon-picker-wheelchair-icon.js +5 -5
  175. package/dist/components/icon/icons/image-icon.js +5 -5
  176. package/dist/components/icon/icons/import-icon.js +5 -5
  177. package/dist/components/icon/icons/inbox-icon.js +5 -5
  178. package/dist/components/icon/icons/increase-icon.js +5 -5
  179. package/dist/components/icon/icons/indeterminate-icon.js +4 -4
  180. package/dist/components/icon/icons/info-icon.js +5 -5
  181. package/dist/components/icon/icons/inheritance-icon.js +5 -5
  182. package/dist/components/icon/icons/just-eat-icon.js +5 -5
  183. package/dist/components/icon/icons/karma-icon.js +5 -5
  184. package/dist/components/icon/icons/key-command-icon.js +5 -5
  185. package/dist/components/icon/icons/key-enter-icon.js +5 -5
  186. package/dist/components/icon/icons/key-icon.js +5 -5
  187. package/dist/components/icon/icons/key-option-icon.js +5 -5
  188. package/dist/components/icon/icons/language-icon.js +5 -5
  189. package/dist/components/icon/icons/link-broken-icon.js +5 -5
  190. package/dist/components/icon/icons/link-external-icon.js +5 -5
  191. package/dist/components/icon/icons/link-icon.js +5 -5
  192. package/dist/components/icon/icons/list-ol-icon.js +5 -5
  193. package/dist/components/icon/icons/list-ul-icon.js +5 -5
  194. package/dist/components/icon/icons/loading-icon.js +5 -5
  195. package/dist/components/icon/icons/location-icon.js +5 -5
  196. package/dist/components/icon/icons/lock-icon.js +5 -5
  197. package/dist/components/icon/icons/log-in-icon.js +5 -5
  198. package/dist/components/icon/icons/log-out-icon.js +5 -5
  199. package/dist/components/icon/icons/map-icon.js +5 -5
  200. package/dist/components/icon/icons/maximize-icon.js +5 -5
  201. package/dist/components/icon/icons/members-icon.js +5 -5
  202. package/dist/components/icon/icons/menu-hide-icon.js +5 -5
  203. package/dist/components/icon/icons/menu-icon.js +5 -5
  204. package/dist/components/icon/icons/menu-show-icon.js +5 -5
  205. package/dist/components/icon/icons/message-add-icon.js +5 -5
  206. package/dist/components/icon/icons/message-icon.js +5 -5
  207. package/dist/components/icon/icons/message-lines-icon.js +5 -5
  208. package/dist/components/icon/icons/minimize-icon.js +5 -5
  209. package/dist/components/icon/icons/minimize-window-icon.js +5 -5
  210. package/dist/components/icon/icons/mobile-rotate-icon.js +5 -5
  211. package/dist/components/icon/icons/module-accounting-icon.js +5 -5
  212. package/dist/components/icon/icons/module-ai-forecast-icon.js +5 -5
  213. package/dist/components/icon/icons/module-app-icon.js +5 -5
  214. package/dist/components/icon/icons/module-articles-icon.js +5 -5
  215. package/dist/components/icon/icons/module-benchmark-icon.js +5 -5
  216. package/dist/components/icon/icons/module-booking-icon.js +5 -5
  217. package/dist/components/icon/icons/module-cai-icon.js +5 -5
  218. package/dist/components/icon/icons/module-campaigns-icon.js +5 -5
  219. package/dist/components/icon/icons/module-cashier-icon.js +5 -5
  220. package/dist/components/icon/icons/module-communication-icon.js +5 -5
  221. package/dist/components/icon/icons/module-copilot-icon.js +5 -5
  222. package/dist/components/icon/icons/module-dashboard-icon.js +5 -5
  223. package/dist/components/icon/icons/module-document-icon.js +5 -5
  224. package/dist/components/icon/icons/module-employees-icon.js +5 -5
  225. package/dist/components/icon/icons/module-feed-icon.js +5 -5
  226. package/dist/components/icon/icons/module-history-icon.js +5 -5
  227. package/dist/components/icon/icons/module-home-icon.js +5 -5
  228. package/dist/components/icon/icons/module-insights-icon.js +5 -5
  229. package/dist/components/icon/icons/module-kds-icon.js +5 -5
  230. package/dist/components/icon/icons/module-members-icon.js +5 -5
  231. package/dist/components/icon/icons/module-menus-icon.js +5 -5
  232. package/dist/components/icon/icons/module-my-city-icon.js +5 -5
  233. package/dist/components/icon/icons/module-notification-center-icon.js +5 -5
  234. package/dist/components/icon/icons/module-online-order-icon.js +5 -5
  235. package/dist/components/icon/icons/module-organisation-icon.js +5 -5
  236. package/dist/components/icon/icons/module-pos-icon.js +5 -5
  237. package/dist/components/icon/icons/module-pulse-icon.js +5 -5
  238. package/dist/components/icon/icons/module-result-icon.js +5 -5
  239. package/dist/components/icon/icons/module-salary-icon.js +5 -5
  240. package/dist/components/icon/icons/module-schedule-icon.js +5 -5
  241. package/dist/components/icon/icons/module-settings-alt-icon.js +5 -5
  242. package/dist/components/icon/icons/module-settings-icon.js +5 -5
  243. package/dist/components/icon/icons/module-support-icon.js +5 -5
  244. package/dist/components/icon/icons/module-survey-icon.js +5 -5
  245. package/dist/components/icon/icons/module-table-map-icon.js +6 -6
  246. package/dist/components/icon/icons/module-tablet-icon.js +5 -5
  247. package/dist/components/icon/icons/module-time-icon.js +5 -5
  248. package/dist/components/icon/icons/module-timeline-icon.js +5 -5
  249. package/dist/components/icon/icons/module-tip-icon.js +5 -5
  250. package/dist/components/icon/icons/module-to-do-icon.js +5 -5
  251. package/dist/components/icon/icons/module-tools-icon.js +5 -5
  252. package/dist/components/icon/icons/module-top-list-icon.js +5 -5
  253. package/dist/components/icon/icons/module-web-charts-icon.js +5 -5
  254. package/dist/components/icon/icons/module-web-icon.js +5 -5
  255. package/dist/components/icon/icons/more-horizontal-icon.js +5 -5
  256. package/dist/components/icon/icons/more-vertical-icon.js +5 -5
  257. package/dist/components/icon/icons/nfc-icon.js +5 -5
  258. package/dist/components/icon/icons/no-cart-icon.js +5 -5
  259. package/dist/components/icon/icons/note-icon.js +5 -5
  260. package/dist/components/icon/icons/number-icon.js +6 -6
  261. package/dist/components/icon/icons/open-modal-icon.js +5 -5
  262. package/dist/components/icon/icons/parking-icon.js +5 -5
  263. package/dist/components/icon/icons/party-horn-icon.js +5 -5
  264. package/dist/components/icon/icons/paste-icon.js +5 -5
  265. package/dist/components/icon/icons/pause-icon.js +5 -5
  266. package/dist/components/icon/icons/payment-card-icon.js +5 -5
  267. package/dist/components/icon/icons/payment-cash-icon.js +5 -5
  268. package/dist/components/icon/icons/payment-generic-icon.js +5 -5
  269. package/dist/components/icon/icons/payment-giftcard-icon.js +5 -5
  270. package/dist/components/icon/icons/payment-hotel-icon.js +5 -5
  271. package/dist/components/icon/icons/payment-invoice-icon.js +5 -5
  272. package/dist/components/icon/icons/percentage-icon.js +5 -5
  273. package/dist/components/icon/icons/phone-icon.js +5 -5
  274. package/dist/components/icon/icons/pin-icon.js +5 -5
  275. package/dist/components/icon/icons/pin-map-icon.js +5 -5
  276. package/dist/components/icon/icons/play-icon.js +5 -5
  277. package/dist/components/icon/icons/preview-icon.js +5 -5
  278. package/dist/components/icon/icons/print-icon.js +5 -5
  279. package/dist/components/icon/icons/privacy-icon.js +5 -5
  280. package/dist/components/icon/icons/product-admin-icon.js +5 -5
  281. package/dist/components/icon/icons/product-analytics-icon.js +5 -5
  282. package/dist/components/icon/icons/product-booking-icon.js +5 -5
  283. package/dist/components/icon/icons/product-checkout-icon.js +5 -5
  284. package/dist/components/icon/icons/product-my-pages-icon.js +5 -5
  285. package/dist/components/icon/icons/product-staff-icon.js +5 -5
  286. package/dist/components/icon/icons/puck-icon.js +5 -5
  287. package/dist/components/icon/icons/qr-code-icon.js +5 -5
  288. package/dist/components/icon/icons/question-icon.js +5 -5
  289. package/dist/components/icon/icons/radio-icon.js +5 -5
  290. package/dist/components/icon/icons/receipt-icon.js +5 -5
  291. package/dist/components/icon/icons/redo-icon.js +5 -5
  292. package/dist/components/icon/icons/refund-icon.js +5 -5
  293. package/dist/components/icon/icons/remove-icon.js +5 -5
  294. package/dist/components/icon/icons/replace-icon.js +5 -5
  295. package/dist/components/icon/icons/schedule-icon.js +5 -5
  296. package/dist/components/icon/icons/search-icon.js +5 -5
  297. package/dist/components/icon/icons/select-icon.js +4 -4
  298. package/dist/components/icon/icons/send-icon.js +5 -5
  299. package/dist/components/icon/icons/share-icon.js +5 -5
  300. package/dist/components/icon/icons/show-icon.js +5 -5
  301. package/dist/components/icon/icons/shuffle-icon.js +5 -5
  302. package/dist/components/icon/icons/sidebar-hide-icon.js +4 -4
  303. package/dist/components/icon/icons/sidebar-left-icon.js +4 -4
  304. package/dist/components/icon/icons/sidebar-right-icon.js +5 -5
  305. package/dist/components/icon/icons/sidebar-show-icon.js +5 -5
  306. package/dist/components/icon/icons/sliders-icon.js +5 -5
  307. package/dist/components/icon/icons/slightly-sad-icon.js +5 -5
  308. package/dist/components/icon/icons/smile-icon.js +5 -5
  309. package/dist/components/icon/icons/sort-asc-icon.js +5 -5
  310. package/dist/components/icon/icons/sort-desc-icon.js +5 -5
  311. package/dist/components/icon/icons/split-icon.js +5 -5
  312. package/dist/components/icon/icons/status-icon.js +5 -5
  313. package/dist/components/icon/icons/stop-icon.js +5 -5
  314. package/dist/components/icon/icons/submenu-icon.js +5 -5
  315. package/dist/components/icon/icons/success-icon.js +5 -5
  316. package/dist/components/icon/icons/swap-icon.js +5 -5
  317. package/dist/components/icon/icons/swatch-icon.js +5 -5
  318. package/dist/components/icon/icons/sweat-icon.js +5 -5
  319. package/dist/components/icon/icons/table-icon.js +5 -5
  320. package/dist/components/icon/icons/table-map-icon.js +5 -5
  321. package/dist/components/icon/icons/take-away-dot-com-icon.js +5 -5
  322. package/dist/components/icon/icons/take-away-icon.js +5 -5
  323. package/dist/components/icon/icons/talk-icon.js +5 -5
  324. package/dist/components/icon/icons/thumbtack-icon.js +5 -5
  325. package/dist/components/icon/icons/time-icon.js +5 -5
  326. package/dist/components/icon/icons/timeline-icon.js +5 -5
  327. package/dist/components/icon/icons/tip-icon.js +5 -5
  328. package/dist/components/icon/icons/title-icon.js +5 -5
  329. package/dist/components/icon/icons/translate-icon.js +5 -5
  330. package/dist/components/icon/icons/tree-view-collapse-icon.js +4 -4
  331. package/dist/components/icon/icons/tree-view-expand-icon.js +4 -4
  332. package/dist/components/icon/icons/tree-view-last-icon.js +4 -4
  333. package/dist/components/icon/icons/trend-down-icon.js +5 -5
  334. package/dist/components/icon/icons/trend-up-icon.js +5 -5
  335. package/dist/components/icon/icons/triangle-warning-icon.js +5 -5
  336. package/dist/components/icon/icons/trivec-icon.js +6 -6
  337. package/dist/components/icon/icons/uber-eats-icon.js +5 -5
  338. package/dist/components/icon/icons/undo-icon.js +5 -5
  339. package/dist/components/icon/icons/unlock-icon.js +5 -5
  340. package/dist/components/icon/icons/unwrap-content-icon.js +5 -5
  341. package/dist/components/icon/icons/up-icon.js +5 -5
  342. package/dist/components/icon/icons/user-group-icon.js +5 -5
  343. package/dist/components/icon/icons/user-icon.js +5 -5
  344. package/dist/components/icon/icons/user-permissions-icon.js +5 -5
  345. package/dist/components/icon/icons/user-wait-icon.js +5 -5
  346. package/dist/components/icon/icons/users-icon.js +5 -5
  347. package/dist/components/icon/icons/version-control-icon.js +5 -5
  348. package/dist/components/icon/icons/volume-high-icon.js +5 -5
  349. package/dist/components/icon/icons/volume-icon.js +5 -5
  350. package/dist/components/icon/icons/volume-low-icon.js +5 -5
  351. package/dist/components/icon/icons/volume-off-icon.js +5 -5
  352. package/dist/components/icon/icons/warning-icon.js +5 -5
  353. package/dist/components/icon/icons/waste-icon.js +5 -5
  354. package/dist/components/icon/icons/wifi-icon.js +5 -5
  355. package/dist/components/icon/icons/wifi-off-icon.js +5 -5
  356. package/dist/components/icon/icons/wolt-icon.js +5 -5
  357. package/dist/components/icon/icons/wrap-content-icon.js +5 -5
  358. package/dist/components/icon-button/icon-button.js +37 -39
  359. package/dist/components/image/image.js +12 -14
  360. package/dist/components/image-upload/image-cropper.helper.js +74 -82
  361. package/dist/components/image-upload/image-cropper.js +156 -183
  362. package/dist/components/image-upload/image-upload-dropzone.js +134 -112
  363. package/dist/components/image-upload/image-upload-helper.js +15 -19
  364. package/dist/components/image-upload/image-upload-icons.js +52 -20
  365. package/dist/components/image-upload/image-upload-modal.js +131 -106
  366. package/dist/components/image-upload/image-upload.js +96 -86
  367. package/dist/components/image-upload/translations.js +65 -65
  368. package/dist/components/image-upload/types.js +6 -4
  369. package/dist/components/input/helper.js +18 -29
  370. package/dist/components/input/input-addon-recipe.js +37 -43
  371. package/dist/components/input/input-recipe.js +124 -133
  372. package/dist/components/input/input.js +78 -83
  373. package/dist/components/link/link-recipe.js +18 -22
  374. package/dist/components/link/link.js +14 -14
  375. package/dist/components/list/list-item.js +15 -15
  376. package/dist/components/list/list.js +19 -20
  377. package/dist/components/menu/helper.js +12 -16
  378. package/dist/components/menu/menu-box-button.js +22 -18
  379. package/dist/components/menu/menu-button.js +18 -16
  380. package/dist/components/menu/menu-divider.js +31 -28
  381. package/dist/components/menu/menu-group.js +138 -142
  382. package/dist/components/menu/menu-icon-button.js +13 -11
  383. package/dist/components/menu/menu-item.js +44 -45
  384. package/dist/components/menu/menu-list.js +14 -15
  385. package/dist/components/menu/menu-recipe.js +67 -81
  386. package/dist/components/menu/menu.js +34 -41
  387. package/dist/components/message/message.js +52 -38
  388. package/dist/components/modal/modal-body-context.js +6 -7
  389. package/dist/components/modal/modal-body.js +17 -17
  390. package/dist/components/modal/modal-close-button.js +23 -18
  391. package/dist/components/modal/modal-footer.js +29 -32
  392. package/dist/components/modal/modal-header.js +17 -17
  393. package/dist/components/modal/modal-recipe.js +110 -141
  394. package/dist/components/modal/modal.js +54 -58
  395. package/dist/components/navigation-list/navigation-list-item.js +76 -88
  396. package/dist/components/navigation-list/navigation-list.js +23 -17
  397. package/dist/components/paginator/paginator-recipe.js +34 -40
  398. package/dist/components/paginator/paginator.js +65 -70
  399. package/dist/components/paginator/translations.js +35 -35
  400. package/dist/components/phone-input/country-data.js +31 -36
  401. package/dist/components/phone-input/country-list.js +45 -25
  402. package/dist/components/phone-input/country-selector.js +167 -115
  403. package/dist/components/phone-input/phone-input-helpers.js +91 -119
  404. package/dist/components/phone-input/phone-input.js +47 -42
  405. package/dist/components/phone-input/translations.js +53 -53
  406. package/dist/components/phone-input/use-phone-input.js +110 -137
  407. package/dist/components/quantity-button/minus-button.js +18 -16
  408. package/dist/components/quantity-button/plus-button.js +18 -16
  409. package/dist/components/quantity-button/quantity-button.js +72 -40
  410. package/dist/components/radio/check-icon.js +5 -5
  411. package/dist/components/radio/hover-styles.js +21 -36
  412. package/dist/components/radio/radio-group-context.js +5 -6
  413. package/dist/components/radio/radio-group-recipe.js +124 -142
  414. package/dist/components/radio/radio-group.js +30 -28
  415. package/dist/components/radio/radio.js +72 -55
  416. package/dist/components/radio-card/hover-styles.js +21 -36
  417. package/dist/components/radio-card/radio-card-group.js +24 -25
  418. package/dist/components/radio-card/radio-card.js +87 -67
  419. package/dist/components/rich-text-editor/boolean-control.js +51 -54
  420. package/dist/components/rich-text-editor/extensions.js +39 -34
  421. package/dist/components/rich-text-editor/index.js +26 -22
  422. package/dist/components/rich-text-editor/rich-text-editor-context.js +9 -11
  423. package/dist/components/rich-text-editor/rich-text-editor-control.js +290 -284
  424. package/dist/components/rich-text-editor/rich-text-editor-recipe.js +71 -83
  425. package/dist/components/rich-text-editor/rich-text-editor.js +72 -69
  426. package/dist/components/rich-text-editor/rich-text-renderer.js +32 -32
  427. package/dist/components/rich-text-editor/translations.js +119 -119
  428. package/dist/components/rich-text-editor/use-rich-text-editor.js +22 -29
  429. package/dist/components/segmented-control/segmented-control-item.js +24 -25
  430. package/dist/components/segmented-control/segmented-control.js +49 -40
  431. package/dist/components/select/select-recipe.js +91 -106
  432. package/dist/components/select/select.js +27 -29
  433. package/dist/components/skeleton/skeleton-text.js +18 -19
  434. package/dist/components/skeleton/skeleton.js +19 -20
  435. package/dist/components/spinner/spinner.js +44 -28
  436. package/dist/components/stack/stack.js +18 -18
  437. package/dist/components/stepper/check-icon.js +5 -5
  438. package/dist/components/stepper/step-context.js +5 -5
  439. package/dist/components/stepper/step.js +111 -106
  440. package/dist/components/stepper/stepper.js +42 -43
  441. package/dist/components/stepper/times-icon.js +5 -5
  442. package/dist/components/switch/hover-styles.js +30 -44
  443. package/dist/components/switch/switch-recipe.js +76 -84
  444. package/dist/components/switch/switch.d.ts +3 -3
  445. package/dist/components/switch/switch.d.ts.map +1 -1
  446. package/dist/components/switch/switch.js +30 -31
  447. package/dist/components/switch/types.d.ts +4 -2
  448. package/dist/components/switch/types.d.ts.map +1 -1
  449. package/dist/components/table/helper.d.ts +6 -0
  450. package/dist/components/table/helper.d.ts.map +1 -1
  451. package/dist/components/table/helper.js +29 -9
  452. package/dist/components/table/index.d.ts +1 -1
  453. package/dist/components/table/index.d.ts.map +1 -1
  454. package/dist/components/table/table-cell.d.ts.map +1 -1
  455. package/dist/components/table/table-cell.js +136 -122
  456. package/dist/components/table/table-column-resize-handle.d.ts +12 -0
  457. package/dist/components/table/table-column-resize-handle.d.ts.map +1 -0
  458. package/dist/components/table/table-column-resize-handle.js +69 -0
  459. package/dist/components/table/table-content.d.ts.map +1 -1
  460. package/dist/components/table/table-content.js +174 -98
  461. package/dist/components/table/table-context-provider.d.ts +7 -2
  462. package/dist/components/table/table-context-provider.d.ts.map +1 -1
  463. package/dist/components/table/table-context-provider.js +203 -151
  464. package/dist/components/table/table-context.d.ts +24 -0
  465. package/dist/components/table/table-context.d.ts.map +1 -1
  466. package/dist/components/table/table-context.js +18 -11
  467. package/dist/components/table/table-filter.js +170 -118
  468. package/dist/components/table/table-header-dropdown.js +131 -89
  469. package/dist/components/table/table-header-row.d.ts.map +1 -1
  470. package/dist/components/table/table-header-row.js +202 -140
  471. package/dist/components/table/table-recipe.d.ts.map +1 -1
  472. package/dist/components/table/table-recipe.js +75 -96
  473. package/dist/components/table/table-row-expand-toggle-button.js +28 -35
  474. package/dist/components/table/table-row.d.ts.map +1 -1
  475. package/dist/components/table/table-row.js +51 -41
  476. package/dist/components/table/table-toolbar-actions.js +19 -19
  477. package/dist/components/table/table-toolbar-add-button.js +18 -13
  478. package/dist/components/table/table-toolbar-search.js +17 -12
  479. package/dist/components/table/table-toolbar-settings.js +180 -133
  480. package/dist/components/table/table-toolbar.js +72 -51
  481. package/dist/components/table/table.composition.d.ts +1 -0
  482. package/dist/components/table/table.composition.d.ts.map +1 -1
  483. package/dist/components/table/table.constants.d.ts +4 -0
  484. package/dist/components/table/table.constants.d.ts.map +1 -1
  485. package/dist/components/table/table.constants.js +9 -4
  486. package/dist/components/table/table.d.ts +1 -1
  487. package/dist/components/table/table.d.ts.map +1 -1
  488. package/dist/components/table/table.js +41 -37
  489. package/dist/components/table/translations.d.ts +7 -0
  490. package/dist/components/table/translations.d.ts.map +1 -1
  491. package/dist/components/table/translations.js +199 -194
  492. package/dist/components/table/types.d.ts +33 -2
  493. package/dist/components/table/types.d.ts.map +1 -1
  494. package/dist/components/tabs/tab-list.js +16 -17
  495. package/dist/components/tabs/tab-panel.js +14 -14
  496. package/dist/components/tabs/tab-panels.js +15 -15
  497. package/dist/components/tabs/tab-with-image.js +60 -53
  498. package/dist/components/tabs/tab.js +26 -22
  499. package/dist/components/tabs/tabs-recipe.js +96 -116
  500. package/dist/components/tabs/tabs.js +25 -24
  501. package/dist/components/tag/tag-recipe.js +225 -252
  502. package/dist/components/tag/tag.js +121 -62
  503. package/dist/components/text/text-recipe.js +3 -8
  504. package/dist/components/text/text.js +26 -27
  505. package/dist/components/textarea/textarea-recipe.js +90 -96
  506. package/dist/components/textarea/textarea.js +19 -19
  507. package/dist/components/toaster/toast-store.d.ts +2 -2
  508. package/dist/components/toaster/toast-store.d.ts.map +1 -1
  509. package/dist/components/toaster/toast-store.js +25 -32
  510. package/dist/components/toaster/toaster.js +39 -34
  511. package/dist/components/toggle-button/toggle-button.js +23 -25
  512. package/dist/components/toggle-button/use-button-children.js +36 -35
  513. package/dist/components/tooltip/tooltip.js +43 -47
  514. package/dist/hooks/use-color-mode.js +17 -22
  515. package/dist/hooks/use-disclosure.js +10 -13
  516. package/dist/hooks/use-measured-width.js +21 -21
  517. package/dist/hooks/use-remove-attributes.js +25 -24
  518. package/dist/index.js +396 -802
  519. package/dist/node_modules/@dnd-kit/abstract/index.js +658 -1185
  520. package/dist/node_modules/@dnd-kit/collision/dist/index.js +51 -90
  521. package/dist/node_modules/@dnd-kit/dom/index.js +1256 -1518
  522. package/dist/node_modules/@dnd-kit/dom/sortable.js +529 -654
  523. package/dist/node_modules/@dnd-kit/dom/utilities.js +772 -940
  524. package/dist/node_modules/@dnd-kit/geometry/dist/index.js +228 -196
  525. package/dist/node_modules/@dnd-kit/react/hooks.js +51 -63
  526. package/dist/node_modules/@dnd-kit/react/index.js +175 -235
  527. package/dist/node_modules/@dnd-kit/react/sortable.js +67 -142
  528. package/dist/node_modules/@dnd-kit/react/utilities.js +7 -9
  529. package/dist/node_modules/@dnd-kit/state/dist/index.js +157 -172
  530. package/dist/node_modules/@floating-ui/core/dist/floating-ui.core.js +154 -243
  531. package/dist/node_modules/@floating-ui/dom/dist/floating-ui.dom.js +294 -369
  532. package/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.dom.js +95 -133
  533. package/dist/node_modules/@floating-ui/utils/dist/floating-ui.utils.js +96 -122
  534. package/dist/node_modules/@preact/signals-core/dist/signals-core.module.js +249 -264
  535. package/dist/node_modules/@tanstack/react-table/build/lib/index.js +34 -88
  536. package/dist/node_modules/@tanstack/react-virtual/dist/esm/index.js +74 -88
  537. package/dist/node_modules/@tanstack/table-core/build/lib/index.js +1463 -1822
  538. package/dist/node_modules/@tanstack/virtual-core/dist/esm/index.js +633 -768
  539. package/dist/node_modules/@tanstack/virtual-core/dist/esm/lazy-measurements.js +30 -32
  540. package/dist/node_modules/@tanstack/virtual-core/dist/esm/utils.js +35 -48
  541. package/dist/node_modules/@tiptap/core/dist/index.js +3433 -3946
  542. package/dist/node_modules/@tiptap/core/dist/jsx-runtime/jsx-runtime.js +19 -19
  543. package/dist/node_modules/@tiptap/extension-blockquote/dist/index.js +73 -1498
  544. package/dist/node_modules/@tiptap/extension-bold/dist/index.js +71 -84
  545. package/dist/node_modules/@tiptap/extension-code/dist/index.js +65 -70
  546. package/dist/node_modules/@tiptap/extension-code-block/dist/index.js +155 -216
  547. package/dist/node_modules/@tiptap/extension-document/dist/index.js +9 -11
  548. package/dist/node_modules/@tiptap/extension-hard-break/dist/index.js +48 -60
  549. package/dist/node_modules/@tiptap/extension-heading/dist/index.js +65 -66
  550. package/dist/node_modules/@tiptap/extension-horizontal-rule/dist/index.js +47 -55
  551. package/dist/node_modules/@tiptap/extension-italic/dist/index.js +68 -82
  552. package/dist/node_modules/@tiptap/extension-link/dist/index.js +365 -334
  553. package/dist/node_modules/@tiptap/extension-list/dist/index.js +936 -1105
  554. package/dist/node_modules/@tiptap/extension-paragraph/dist/index.js +43 -48
  555. package/dist/node_modules/@tiptap/extension-strike/dist/index.js +53 -65
  556. package/dist/node_modules/@tiptap/extension-text/dist/index.js +12 -12
  557. package/dist/node_modules/@tiptap/extension-underline/dist/index.js +60 -64
  558. package/dist/node_modules/@tiptap/extensions/dist/index.js +439 -462
  559. package/dist/node_modules/@tiptap/react/dist/index.js +314 -0
  560. package/dist/node_modules/@tiptap/starter-kit/dist/index.js +23 -24
  561. package/dist/node_modules/country-flag-icons/modules/countries.json.js +4 -4
  562. package/dist/node_modules/country-flag-icons/modules/hasFlag.js +6 -6
  563. package/dist/node_modules/country-flag-icons/modules/react/3x2/index.js +5469 -6298
  564. package/dist/node_modules/country-flag-icons/react/3x2/index.js +273 -269
  565. package/dist/node_modules/date-fns/_lib/addLeadingZeros.js +5 -6
  566. package/dist/node_modules/date-fns/_lib/defaultOptions.js +6 -6
  567. package/dist/node_modules/date-fns/_lib/format/formatters.js +385 -544
  568. package/dist/node_modules/date-fns/_lib/format/lightFormatters.js +42 -57
  569. package/dist/node_modules/date-fns/_lib/format/longFormatters.js +37 -48
  570. package/dist/node_modules/date-fns/_lib/getTimezoneOffsetInMilliseconds.js +7 -17
  571. package/dist/node_modules/date-fns/_lib/normalizeDates.js +6 -9
  572. package/dist/node_modules/date-fns/_lib/protectedTokens.js +19 -16
  573. package/dist/node_modules/date-fns/addDays.js +8 -8
  574. package/dist/node_modules/date-fns/addMonths.js +11 -18
  575. package/dist/node_modules/date-fns/addWeeks.js +6 -6
  576. package/dist/node_modules/date-fns/constants.js +10 -6
  577. package/dist/node_modules/date-fns/constructFrom.js +6 -6
  578. package/dist/node_modules/date-fns/constructNow.js +6 -6
  579. package/dist/node_modules/date-fns/differenceInCalendarDays.js +10 -14
  580. package/dist/node_modules/date-fns/endOfDay.js +7 -7
  581. package/dist/node_modules/date-fns/endOfMonth.js +7 -7
  582. package/dist/node_modules/date-fns/format.js +57 -55
  583. package/dist/node_modules/date-fns/getDayOfYear.js +9 -9
  584. package/dist/node_modules/date-fns/getISOWeek.js +10 -10
  585. package/dist/node_modules/date-fns/getISOWeekYear.js +13 -13
  586. package/dist/node_modules/date-fns/getWeek.js +10 -10
  587. package/dist/node_modules/date-fns/getWeekYear.js +14 -14
  588. package/dist/node_modules/date-fns/isBefore.js +6 -6
  589. package/dist/node_modules/date-fns/isDate.js +5 -5
  590. package/dist/node_modules/date-fns/isPast.js +6 -6
  591. package/dist/node_modules/date-fns/isSameDay.js +8 -12
  592. package/dist/node_modules/date-fns/isSameMonth.js +7 -11
  593. package/dist/node_modules/date-fns/isSameWeek.js +8 -12
  594. package/dist/node_modules/date-fns/isSameYear.js +7 -11
  595. package/dist/node_modules/date-fns/isToday.js +7 -10
  596. package/dist/node_modules/date-fns/isValid.js +7 -7
  597. package/dist/node_modules/date-fns/locale/_lib/buildFormatLongFn.js +8 -8
  598. package/dist/node_modules/date-fns/locale/_lib/buildLocalizeFn.js +16 -17
  599. package/dist/node_modules/date-fns/locale/_lib/buildMatchFn.js +19 -28
  600. package/dist/node_modules/date-fns/locale/_lib/buildMatchPatternFn.js +17 -14
  601. package/dist/node_modules/date-fns/locale/da/_lib/formatDistance.js +68 -69
  602. package/dist/node_modules/date-fns/locale/da/_lib/formatLong.js +31 -32
  603. package/dist/node_modules/date-fns/locale/da/_lib/formatRelative.js +11 -11
  604. package/dist/node_modules/date-fns/locale/da/_lib/localize.js +193 -142
  605. package/dist/node_modules/date-fns/locale/da/_lib/match.js +123 -109
  606. package/dist/node_modules/date-fns/locale/da.js +17 -17
  607. package/dist/node_modules/date-fns/locale/en-GB/_lib/formatLong.js +31 -32
  608. package/dist/node_modules/date-fns/locale/en-GB.js +18 -18
  609. package/dist/node_modules/date-fns/locale/en-US/_lib/formatDistance.js +68 -69
  610. package/dist/node_modules/date-fns/locale/en-US/_lib/formatLong.js +31 -32
  611. package/dist/node_modules/date-fns/locale/en-US/_lib/formatRelative.js +11 -11
  612. package/dist/node_modules/date-fns/locale/en-US/_lib/localize.js +200 -153
  613. package/dist/node_modules/date-fns/locale/en-US/_lib/match.js +123 -109
  614. package/dist/node_modules/date-fns/locale/en-US.js +18 -18
  615. package/dist/node_modules/date-fns/locale/es/_lib/formatDistance.js +68 -69
  616. package/dist/node_modules/date-fns/locale/es/_lib/formatLong.js +31 -32
  617. package/dist/node_modules/date-fns/locale/es/_lib/formatRelative.js +18 -18
  618. package/dist/node_modules/date-fns/locale/es/_lib/localize.js +192 -141
  619. package/dist/node_modules/date-fns/locale/es/_lib/match.js +127 -114
  620. package/dist/node_modules/date-fns/locale/es.js +18 -18
  621. package/dist/node_modules/date-fns/locale/et/_lib/formatDistance.js +161 -162
  622. package/dist/node_modules/date-fns/locale/et/_lib/formatLong.js +31 -32
  623. package/dist/node_modules/date-fns/locale/et/_lib/formatRelative.js +11 -11
  624. package/dist/node_modules/date-fns/locale/et/_lib/localize.js +196 -152
  625. package/dist/node_modules/date-fns/locale/et/_lib/match.js +109 -107
  626. package/dist/node_modules/date-fns/locale/et.js +19 -19
  627. package/dist/node_modules/date-fns/locale/fi/_lib/formatDistance.js +101 -101
  628. package/dist/node_modules/date-fns/locale/fi/_lib/formatLong.js +31 -32
  629. package/dist/node_modules/date-fns/locale/fi/_lib/formatRelative.js +11 -11
  630. package/dist/node_modules/date-fns/locale/fi/_lib/localize.js +192 -140
  631. package/dist/node_modules/date-fns/locale/fi/_lib/match.js +122 -108
  632. package/dist/node_modules/date-fns/locale/fi.js +18 -18
  633. package/dist/node_modules/date-fns/locale/fr/_lib/formatDistance.js +68 -69
  634. package/dist/node_modules/date-fns/locale/fr/_lib/formatLong.js +31 -32
  635. package/dist/node_modules/date-fns/locale/fr/_lib/formatRelative.js +11 -11
  636. package/dist/node_modules/date-fns/locale/fr/_lib/localize.js +176 -120
  637. package/dist/node_modules/date-fns/locale/fr/_lib/match.js +122 -108
  638. package/dist/node_modules/date-fns/locale/fr.js +18 -18
  639. package/dist/node_modules/date-fns/locale/lt/_lib/formatDistance.js +93 -109
  640. package/dist/node_modules/date-fns/locale/lt/_lib/formatLong.js +31 -32
  641. package/dist/node_modules/date-fns/locale/lt/_lib/formatRelative.js +11 -11
  642. package/dist/node_modules/date-fns/locale/lt/_lib/localize.js +298 -195
  643. package/dist/node_modules/date-fns/locale/lt/_lib/match.js +154 -121
  644. package/dist/node_modules/date-fns/locale/lt.js +19 -19
  645. package/dist/node_modules/date-fns/locale/lv/_lib/formatDistance.js +226 -120
  646. package/dist/node_modules/date-fns/locale/lv/_lib/formatLong.js +31 -32
  647. package/dist/node_modules/date-fns/locale/lv/_lib/formatRelative.js +22 -22
  648. package/dist/node_modules/date-fns/locale/lv/_lib/localize.js +298 -221
  649. package/dist/node_modules/date-fns/locale/lv/_lib/match.js +138 -112
  650. package/dist/node_modules/date-fns/locale/lv.js +18 -18
  651. package/dist/node_modules/date-fns/locale/nb/_lib/formatDistance.js +68 -69
  652. package/dist/node_modules/date-fns/locale/nb/_lib/formatLong.js +31 -32
  653. package/dist/node_modules/date-fns/locale/nb/_lib/formatRelative.js +11 -11
  654. package/dist/node_modules/date-fns/locale/nb/_lib/localize.js +159 -108
  655. package/dist/node_modules/date-fns/locale/nb/_lib/match.js +112 -108
  656. package/dist/node_modules/date-fns/locale/nb.js +18 -18
  657. package/dist/node_modules/date-fns/locale/nl/_lib/formatDistance.js +68 -69
  658. package/dist/node_modules/date-fns/locale/nl/_lib/formatLong.js +31 -32
  659. package/dist/node_modules/date-fns/locale/nl/_lib/formatRelative.js +11 -11
  660. package/dist/node_modules/date-fns/locale/nl/_lib/localize.js +160 -109
  661. package/dist/node_modules/date-fns/locale/nl/_lib/match.js +120 -108
  662. package/dist/node_modules/date-fns/locale/nl-BE/_lib/formatDistance.js +68 -69
  663. package/dist/node_modules/date-fns/locale/nl-BE/_lib/formatLong.js +31 -32
  664. package/dist/node_modules/date-fns/locale/nl-BE/_lib/formatRelative.js +11 -11
  665. package/dist/node_modules/date-fns/locale/nl-BE/_lib/localize.js +160 -109
  666. package/dist/node_modules/date-fns/locale/nl-BE/_lib/match.js +120 -108
  667. package/dist/node_modules/date-fns/locale/nl-BE.js +18 -18
  668. package/dist/node_modules/date-fns/locale/nl.js +18 -18
  669. package/dist/node_modules/date-fns/locale/sv/_lib/formatDistance.js +82 -86
  670. package/dist/node_modules/date-fns/locale/sv/_lib/formatLong.js +31 -32
  671. package/dist/node_modules/date-fns/locale/sv/_lib/formatRelative.js +11 -11
  672. package/dist/node_modules/date-fns/locale/sv/_lib/localize.js +199 -142
  673. package/dist/node_modules/date-fns/locale/sv/_lib/match.js +109 -107
  674. package/dist/node_modules/date-fns/locale/sv.js +18 -18
  675. package/dist/node_modules/date-fns/startOfDay.js +7 -7
  676. package/dist/node_modules/date-fns/startOfISOWeek.js +9 -6
  677. package/dist/node_modules/date-fns/startOfISOWeekYear.js +9 -9
  678. package/dist/node_modules/date-fns/startOfMonth.js +7 -7
  679. package/dist/node_modules/date-fns/startOfWeek.js +8 -8
  680. package/dist/node_modules/date-fns/startOfWeekYear.js +10 -10
  681. package/dist/node_modules/date-fns/startOfYear.js +7 -7
  682. package/dist/node_modules/date-fns/subDays.js +6 -6
  683. package/dist/node_modules/date-fns/subMonths.js +6 -6
  684. package/dist/node_modules/date-fns/subWeeks.js +6 -6
  685. package/dist/node_modules/date-fns/toDate.js +6 -6
  686. package/dist/node_modules/fast-equals/dist/es/index.js +239 -298
  687. package/dist/node_modules/libphonenumber-js/es6/ParseError.js +116 -89
  688. package/dist/node_modules/libphonenumber-js/es6/PhoneNumber.js +155 -183
  689. package/dist/node_modules/libphonenumber-js/es6/constants.js +4 -10
  690. package/dist/node_modules/libphonenumber-js/es6/format.js +70 -91
  691. package/dist/node_modules/libphonenumber-js/es6/getCountries.js +5 -5
  692. package/dist/node_modules/libphonenumber-js/es6/helpers/RFC3966.js +8 -10
  693. package/dist/node_modules/libphonenumber-js/es6/helpers/applyInternationalSeparatorStyle.js +5 -5
  694. package/dist/node_modules/libphonenumber-js/es6/helpers/checkNumberLength.js +19 -14
  695. package/dist/node_modules/libphonenumber-js/es6/helpers/extension/createExtensionPattern.js +9 -9
  696. package/dist/node_modules/libphonenumber-js/es6/helpers/extension/extractExtension.js +15 -17
  697. package/dist/node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCode.js +35 -45
  698. package/dist/node_modules/libphonenumber-js/es6/helpers/extractCountryCallingCodeFromInternationalNumberWithoutPlusSign.js +20 -26
  699. package/dist/node_modules/libphonenumber-js/es6/helpers/extractFormattedPhoneNumberFromPossibleRfc3966NumberUri.js +17 -22
  700. package/dist/node_modules/libphonenumber-js/es6/helpers/extractNationalNumber.js +24 -36
  701. package/dist/node_modules/libphonenumber-js/es6/helpers/extractNationalNumberFromPossiblyIncompleteNumber.js +26 -30
  702. package/dist/node_modules/libphonenumber-js/es6/helpers/extractPhoneContext.js +13 -21
  703. package/dist/node_modules/libphonenumber-js/es6/helpers/formatNationalNumberUsingFormat.js +10 -24
  704. package/dist/node_modules/libphonenumber-js/es6/helpers/getCountryAndCallingCodeFromOneOfThem.js +10 -11
  705. package/dist/node_modules/libphonenumber-js/es6/helpers/getCountryByCallingCode.js +6 -8
  706. package/dist/node_modules/libphonenumber-js/es6/helpers/getCountryByNationalNumber.js +39 -39
  707. package/dist/node_modules/libphonenumber-js/es6/helpers/getIddPrefix.js +9 -11
  708. package/dist/node_modules/libphonenumber-js/es6/helpers/getNumberType.js +56 -47
  709. package/dist/node_modules/libphonenumber-js/es6/helpers/getPossibleCountriesForNumber.js +12 -12
  710. package/dist/node_modules/libphonenumber-js/es6/helpers/isCallingCode.js +5 -5
  711. package/dist/node_modules/libphonenumber-js/es6/helpers/isCountryCode.js +5 -5
  712. package/dist/node_modules/libphonenumber-js/es6/helpers/isObject.js +6 -6
  713. package/dist/node_modules/libphonenumber-js/es6/helpers/isViablePhoneNumber.js +9 -17
  714. package/dist/node_modules/libphonenumber-js/es6/helpers/matchesEntirely.js +5 -5
  715. package/dist/node_modules/libphonenumber-js/es6/helpers/mergeArrays.js +39 -0
  716. package/dist/node_modules/libphonenumber-js/es6/helpers/parseDigits.js +46 -77
  717. package/dist/node_modules/libphonenumber-js/es6/helpers/stripIddPrefix.js +17 -18
  718. package/dist/node_modules/libphonenumber-js/es6/isPossible.js +29 -32
  719. package/dist/node_modules/libphonenumber-js/es6/isValid.js +12 -13
  720. package/dist/node_modules/libphonenumber-js/es6/isValidPhoneNumber.js +55 -52
  721. package/dist/node_modules/libphonenumber-js/es6/metadata.js +462 -482
  722. package/dist/node_modules/libphonenumber-js/es6/normalizeArguments.js +97 -95
  723. package/dist/node_modules/libphonenumber-js/es6/parse.js +98 -133
  724. package/dist/node_modules/libphonenumber-js/es6/parseIncompletePhoneNumber.js +43 -35
  725. package/dist/node_modules/libphonenumber-js/es6/parsePhoneNumber.js +8 -8
  726. package/dist/node_modules/libphonenumber-js/es6/parsePhoneNumberWithError_.js +51 -48
  727. package/dist/node_modules/libphonenumber-js/es6/parsePhoneNumber_.js +59 -55
  728. package/dist/node_modules/libphonenumber-js/es6/tools/semver-compare.js +13 -13
  729. package/dist/node_modules/libphonenumber-js/metadata.min.json.js +7437 -3
  730. package/dist/node_modules/libphonenumber-js/min/exports/getCountries.js +6 -6
  731. package/dist/node_modules/libphonenumber-js/min/exports/getCountryCallingCode.js +6 -6
  732. package/dist/node_modules/libphonenumber-js/min/exports/isSupportedCountry.js +7 -7
  733. package/dist/node_modules/libphonenumber-js/min/exports/isValidPhoneNumber.js +6 -6
  734. package/dist/node_modules/libphonenumber-js/min/exports/parsePhoneNumber.js +7 -7
  735. package/dist/node_modules/libphonenumber-js/min/exports/withMetadataArgument.js +6 -6
  736. package/dist/node_modules/linkifyjs/dist/linkify.js +486 -679
  737. package/dist/node_modules/next-themes/dist/index.js +120 -85
  738. package/dist/node_modules/orderedmap/dist/index.js +64 -100
  739. package/dist/node_modules/prosemirror-commands/dist/index.js +313 -368
  740. package/dist/node_modules/prosemirror-dropcursor/dist/index.js +109 -84
  741. package/dist/node_modules/prosemirror-gapcursor/dist/index.js +162 -195
  742. package/dist/node_modules/prosemirror-history/dist/index.js +203 -239
  743. package/dist/node_modules/prosemirror-keymap/dist/index.js +45 -57
  744. package/dist/node_modules/prosemirror-model/dist/index.js +1783 -2735
  745. package/dist/node_modules/prosemirror-schema-list/dist/index.js +66 -81
  746. package/dist/node_modules/prosemirror-state/dist/index.js +517 -814
  747. package/dist/node_modules/prosemirror-transform/dist/index.js +1104 -1505
  748. package/dist/node_modules/prosemirror-view/dist/index.js +3274 -3782
  749. package/dist/node_modules/react/cjs/react-compiler-runtime.development.js +15 -21
  750. package/dist/node_modules/react/cjs/react-compiler-runtime.production.js +12 -14
  751. package/dist/node_modules/react/compiler-runtime.js +10 -10
  752. package/dist/node_modules/rope-sequence/dist/index.js +82 -99
  753. package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.development.js +55 -58
  754. package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim/with-selector.production.js +53 -57
  755. package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.development.js +53 -58
  756. package/dist/node_modules/use-sync-external-store/cjs/use-sync-external-store-shim.production.js +45 -46
  757. package/dist/node_modules/use-sync-external-store/shim/index.js +10 -10
  758. package/dist/node_modules/use-sync-external-store/shim/with-selector.js +10 -10
  759. package/dist/node_modules/w3c-keyname/index.js +87 -92
  760. package/dist/theme/component-recipes.js +52 -53
  761. package/dist/theme/theme-casper-ui.js +179 -420
  762. package/dist/theme/theme-helper.js +4 -4
  763. package/dist/theme/theme-provider.js +33 -34
  764. package/dist/theme/theme-style-props.d.ts.map +1 -1
  765. package/dist/theme/theme-tokens.js +22 -12
  766. package/dist/theme/theme-types.js +22 -12
  767. package/dist/theme/theme.js +213 -268
  768. package/package.json +30 -29
  769. package/dist/_virtual/compiler-runtime.js +0 -5
  770. package/dist/_virtual/compiler-runtime2.js +0 -4
  771. package/dist/_virtual/index.js +0 -5
  772. package/dist/_virtual/index2.js +0 -4
  773. package/dist/_virtual/react-compiler-runtime.development.js +0 -4
  774. package/dist/_virtual/react-compiler-runtime.production.js +0 -4
  775. package/dist/_virtual/use-sync-external-store-shim.development.js +0 -4
  776. package/dist/_virtual/use-sync-external-store-shim.production.js +0 -4
  777. package/dist/_virtual/with-selector.development.js +0 -4
  778. package/dist/_virtual/with-selector.js +0 -5
  779. package/dist/_virtual/with-selector.production.js +0 -4
  780. package/dist/_virtual/with-selector2.js +0 -4
  781. package/dist/packages/casper-ui-library/node_modules/@tiptap/react/dist/index.js +0 -506
@@ -1,345 +1,289 @@
1
- import { DragDropManager as xr, resolveCustomizable as it, Plugin as fe, Sensor as ze, ActivationController as kr, CorePlugin as St, descriptor as Ar, Droppable as Dr, Draggable as Or, configurator as Pe, ActivationConstraint as wn } from "../abstract/index.js";
2
- import { generateUniqueId as ct, isSafari as Cr, scheduler as Ne, Listeners as Sn, isElement as ce, isHTMLElement as En, getFrameTransform as je, getEventCoordinates as de, getDocuments as Pr, getDocument as Et, scrollIntoViewIfNeeded as Tr, DOMRectangle as V, getRoot as Xe, canScroll as $r, detectScrollIntent as Ir, isKeyboardEvent as xt, getInteractiveElement as Mr, isTextInput as Rr, ScrollDirection as F, getScrollableAncestors as an, PositionObserver as Lr, isDocument as Wr, isShadowRoot as Fr, getComputedStyles as xn, parseTransform as zr, parseTranslate as kn, getFixedPositionOffset as An, Styles as Nr, supportsPopover as ln, showPopover as le, getWindow as Dn, prefersReducedMotion as On, getElementFromPoint as jr, isPointerEvent as Xr, getFrameElement as cn, cloneElement as Kr, supportsStyle as dn, getFinalKeyframe as Ur, animateTransform as Yr, ProxiedElements as un } from "./utilities.js";
3
- import { computed as hn, deepEqual as Br, effects as Vr, reactive as j, derived as st } from "../state/dist/index.js";
4
- import { Axes as Cn, Point as Hr, Rectangle as kt, exceedsDistance as dt } from "../geometry/dist/index.js";
5
- import { defaultCollisionDetection as qr } from "../collision/dist/index.js";
6
- import { effect as pe, untracked as W, signal as Pn, batch as Gr } from "../../@preact/signals-core/dist/signals-core.module.js";
7
- var Jr = Object.create, At = Object.defineProperty, Qr = Object.defineProperties, Zr = Object.getOwnPropertyDescriptor, ei = Object.getOwnPropertyDescriptors, Ke = Object.getOwnPropertySymbols, Tn = Object.prototype.hasOwnProperty, $n = Object.prototype.propertyIsEnumerable, In = (e, t) => (t = Symbol[e]) ? t : /* @__PURE__ */ Symbol.for("Symbol." + e), ve = (e) => {
8
- throw TypeError(e);
9
- }, ut = (e, t, n) => t in e ? At(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n, Ae = (e, t) => {
10
- for (var n in t || (t = {}))
11
- Tn.call(t, n) && ut(e, n, t[n]);
12
- if (Ke)
13
- for (var n of Ke(t))
14
- $n.call(t, n) && ut(e, n, t[n]);
15
- return e;
16
- }, Dt = (e, t) => Qr(e, ei(t)), fn = (e, t) => At(e, "name", { value: t, configurable: !0 }), Mn = (e, t) => {
17
- var n = {};
18
- for (var r in e)
19
- Tn.call(e, r) && t.indexOf(r) < 0 && (n[r] = e[r]);
20
- if (e != null && Ke)
21
- for (var r of Ke(e))
22
- t.indexOf(r) < 0 && $n.call(e, r) && (n[r] = e[r]);
23
- return n;
24
- }, me = (e) => {
25
- var t;
26
- return [, , , Jr((t = e?.[In("metadata")]) != null ? t : null)];
27
- }, Rn = ["class", "method", "getter", "setter", "accessor", "field", "value", "get", "set"], we = (e) => e !== void 0 && typeof e != "function" ? ve("Function expected") : e, ti = (e, t, n, r, i) => ({ kind: Rn[e], name: t, metadata: r, addInitializer: (s) => n._ ? ve("Already initialized") : i.push(we(s || null)) }), ee = (e, t) => ut(t, In("metadata"), e[3]), A = (e, t, n, r) => {
28
- for (var i = 0, s = e[t >> 1], a = s && s.length; i < a; i++) t & 1 ? s[i].call(n) : r = s[i].call(n, r);
29
- return r;
30
- }, R = (e, t, n, r, i, s) => {
31
- var a, o, d, c, u, l = t & 7, h = !!(t & 8), m = !!(t & 16), g = l > 3 ? e.length + 1 : l ? h ? 1 : 2 : 0, w = Rn[l + 5], D = l > 3 && (e[g - 1] = []), k = e[g] || (e[g] = []), f = l && (!m && !h && (i = i.prototype), l < 5 && (l > 3 || !m) && Zr(l < 4 ? i : { get [n]() {
32
- return _(this, s);
33
- }, set [n](p) {
34
- return $(this, s, p);
35
- } }, n));
36
- l ? m && l < 4 && fn(s, (l > 2 ? "set " : l > 1 ? "get " : "") + n) : fn(i, n);
37
- for (var v = r.length - 1; v >= 0; v--)
38
- c = ti(l, n, d = {}, e[3], k), l && (c.static = h, c.private = m, u = c.access = { has: m ? (p) => ni(i, p) : (p) => n in p }, l ^ 3 && (u.get = m ? (p) => (l ^ 1 ? _ : Z)(p, i, l ^ 4 ? s : f.get) : (p) => p[n]), l > 2 && (u.set = m ? (p, y) => $(p, i, y, l ^ 4 ? s : f.set) : (p, y) => p[n] = y)), o = (0, r[v])(l ? l < 4 ? m ? s : f[w] : l > 4 ? void 0 : { get: f.get, set: f.set } : i, c), d._ = 1, l ^ 4 || o === void 0 ? we(o) && (l > 4 ? D.unshift(o) : l ? m ? s = o : f[w] = o : i = o) : typeof o != "object" || o === null ? ve("Object expected") : (we(a = o.get) && (f.get = a), we(a = o.set) && (f.set = a), we(a = o.init) && D.unshift(a));
39
- return l || ee(e, i), f && At(i, n, f), m ? l ^ 4 ? s : f : i;
40
- }, Ot = (e, t, n) => t.has(e) || ve("Cannot " + n), ni = (e, t) => Object(t) !== t ? ve('Cannot use the "in" operator on this value') : e.has(t), _ = (e, t, n) => (Ot(e, t, "read from private field"), n ? n.call(e) : t.get(e)), S = (e, t, n) => t.has(e) ? ve("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), $ = (e, t, n, r) => (Ot(e, t, "write to private field"), r ? r.call(e, n) : t.set(e, n), n), Z = (e, t, n) => (Ot(e, t, "access private method"), n), pn = {
41
- role: "button",
42
- roleDescription: "draggable"
43
- }, ri = "dnd-kit-description", ii = "dnd-kit-announcement", si = {
44
- draggable: "To pick up a draggable item, press the space bar. While dragging, use the arrow keys to move the item in a given direction. Press space again to drop the item in its new position, or press escape to cancel."
45
- }, oi = {
46
- dragstart({ operation: { source: e } }) {
47
- if (e)
48
- return `Picked up draggable item ${e.id}.`;
49
- },
50
- dragover({ operation: { source: e, target: t } }) {
51
- if (!(!e || e.id === t?.id))
52
- return t ? `Draggable item ${e.id} was moved over droppable target ${t.id}.` : `Draggable item ${e.id} is no longer over a droppable target.`;
53
- },
54
- dragend({ operation: { source: e, target: t }, canceled: n }) {
55
- if (e)
56
- return n ? `Dragging was cancelled. Draggable item ${e.id} was dropped.` : t ? `Draggable item ${e.id} was dropped over droppable target ${t.id}` : `Draggable item ${e.id} was dropped.`;
57
- }
1
+ import { batch as e, effect as t, signal as n, untracked as r } from "../../@preact/signals-core/dist/signals-core.module.js";
2
+ import { computed as i, deepEqual as a, derived as o, effects as s, reactive as c } from "../state/dist/index.js";
3
+ import { Axes as l, Point as u, Rectangle as d, exceedsDistance as f } from "../geometry/dist/index.js";
4
+ import { ActivationConstraint as p, ActivationController as m, CorePlugin as h, DragDropManager as g, Draggable as _, Droppable as v, Plugin as y, Sensor as ee, configurator as b, descriptor as x, resolveCustomizable as S } from "../abstract/index.js";
5
+ import { DOMRectangle as C, Listeners as te, PositionObserver as ne, ProxiedElements as w, ScrollDirection as T, Styles as re, animateTransform as ie, canScroll as ae, cloneElement as oe, detectScrollIntent as se, generateUniqueId as ce, getComputedStyles as le, getDocument as ue, getDocuments as de, getElementFromPoint as fe, getEventCoordinates as E, getFinalKeyframe as pe, getFixedPositionOffset as me, getFrameElement as he, getFrameTransform as ge, getInteractiveElement as _e, getRoot as D, getScrollableAncestors as ve, getWindow as ye, isDocument as be, isElement as O, isHTMLElement as xe, isKeyboardEvent as Se, isPointerEvent as Ce, isSafari as we, isShadowRoot as k, isTextInput as Te, parseTransform as Ee, parseTranslate as De, prefersReducedMotion as Oe, scheduler as A, scrollIntoViewIfNeeded as ke, showPopover as Ae, supportsPopover as je, supportsStyle as Me } from "./utilities.js";
6
+ import { defaultCollisionDetection as Ne } from "../collision/dist/index.js";
7
+ //#region ../../node_modules/@dnd-kit/dom/index.js
8
+ var Pe = Object.create, Fe = Object.defineProperty, Ie = Object.defineProperties, Le = Object.getOwnPropertyDescriptor, Re = Object.getOwnPropertyDescriptors, ze = Object.getOwnPropertySymbols, Be = Object.prototype.hasOwnProperty, Ve = Object.prototype.propertyIsEnumerable, j = (e, t) => (t = Symbol[e]) ? t : Symbol.for("Symbol." + e), M = (e) => {
9
+ throw TypeError(e);
10
+ }, N = (e, t, n) => t in e ? Fe(e, t, {
11
+ enumerable: !0,
12
+ configurable: !0,
13
+ writable: !0,
14
+ value: n
15
+ }) : e[t] = n, P = (e, t) => {
16
+ for (var n in t ||= {}) Be.call(t, n) && N(e, n, t[n]);
17
+ if (ze) for (var n of ze(t)) Ve.call(t, n) && N(e, n, t[n]);
18
+ return e;
19
+ }, He = (e, t) => Ie(e, Re(t)), Ue = (e, t) => Fe(e, "name", {
20
+ value: t,
21
+ configurable: !0
22
+ }), We = (e, t) => {
23
+ var n = {};
24
+ for (var r in e) Be.call(e, r) && t.indexOf(r) < 0 && (n[r] = e[r]);
25
+ if (e != null && ze) for (var r of ze(e)) t.indexOf(r) < 0 && Ve.call(e, r) && (n[r] = e[r]);
26
+ return n;
27
+ }, F = (e) => [
28
+ ,
29
+ ,
30
+ ,
31
+ Pe(e?.[j("metadata")] ?? null)
32
+ ], Ge = [
33
+ "class",
34
+ "method",
35
+ "getter",
36
+ "setter",
37
+ "accessor",
38
+ "field",
39
+ "value",
40
+ "get",
41
+ "set"
42
+ ], Ke = (e) => e !== void 0 && typeof e != "function" ? M("Function expected") : e, qe = (e, t, n, r, i) => ({
43
+ kind: Ge[e],
44
+ name: t,
45
+ metadata: r,
46
+ addInitializer: (e) => n._ ? M("Already initialized") : i.push(Ke(e || null))
47
+ }), I = (e, t) => N(t, j("metadata"), e[3]), L = (e, t, n, r) => {
48
+ for (var i = 0, a = e[t >> 1], o = a && a.length; i < o; i++) t & 1 ? a[i].call(n) : r = a[i].call(n, r);
49
+ return r;
50
+ }, R = (e, t, n, r, i, a) => {
51
+ var o, s, c, l, u, d = t & 7, f = !!(t & 8), p = !!(t & 16), m = d > 3 ? e.length + 1 : d ? f ? 1 : 2 : 0, h = Ge[d + 5], g = d > 3 && (e[m - 1] = []), _ = e[m] || (e[m] = []), v = d && (!p && !f && (i = i.prototype), d < 5 && (d > 3 || !p) && Le(d < 4 ? i : {
52
+ get [n]() {
53
+ return z(this, a);
54
+ },
55
+ set [n](e) {
56
+ return V(this, a, e);
57
+ }
58
+ }, n));
59
+ d ? p && d < 4 && Ue(a, (d > 2 ? "set " : d > 1 ? "get " : "") + n) : Ue(i, n);
60
+ for (var y = r.length - 1; y >= 0; y--) l = qe(d, n, c = {}, e[3], _), d && (l.static = f, l.private = p, u = l.access = { has: p ? (e) => Ye(i, e) : (e) => n in e }, d ^ 3 && (u.get = p ? (e) => (d ^ 1 ? z : H)(e, i, d ^ 4 ? a : v.get) : (e) => e[n]), d > 2 && (u.set = p ? (e, t) => V(e, i, t, d ^ 4 ? a : v.set) : (e, t) => e[n] = t)), s = (0, r[y])(d ? d < 4 ? p ? a : v[h] : d > 4 ? void 0 : {
61
+ get: v.get,
62
+ set: v.set
63
+ } : i, l), c._ = 1, d ^ 4 || s === void 0 ? Ke(s) && (d > 4 ? g.unshift(s) : d ? p ? a = s : v[h] = s : i = s) : typeof s != "object" || !s ? M("Object expected") : (Ke(o = s.get) && (v.get = o), Ke(o = s.set) && (v.set = o), Ke(o = s.init) && g.unshift(o));
64
+ return d || I(e, i), v && Fe(i, n, v), p ? d ^ 4 ? a : v : i;
65
+ }, Je = (e, t, n) => t.has(e) || M("Cannot " + n), Ye = (e, t) => Object(t) === t ? e.has(t) : M("Cannot use the \"in\" operator on this value"), z = (e, t, n) => (Je(e, t, "read from private field"), n ? n.call(e) : t.get(e)), B = (e, t, n) => t.has(e) ? M("Cannot add the same private member more than once") : t instanceof WeakSet ? t.add(e) : t.set(e, n), V = (e, t, n, r) => (Je(e, t, "write to private field"), r ? r.call(e, n) : t.set(e, n), n), H = (e, t, n) => (Je(e, t, "access private method"), n), Xe = {
66
+ role: "button",
67
+ roleDescription: "draggable"
68
+ }, Ze = "dnd-kit-description", Qe = "dnd-kit-announcement", $e = { draggable: "To pick up a draggable item, press the space bar. While dragging, use the arrow keys to move the item in a given direction. Press space again to drop the item in its new position, or press escape to cancel." }, et = {
69
+ dragstart({ operation: { source: e } }) {
70
+ if (e) return `Picked up draggable item ${e.id}.`;
71
+ },
72
+ dragover({ operation: { source: e, target: t } }) {
73
+ if (!(!e || e.id === t?.id)) return t ? `Draggable item ${e.id} was moved over droppable target ${t.id}.` : `Draggable item ${e.id} is no longer over a droppable target.`;
74
+ },
75
+ dragend({ operation: { source: e, target: t }, canceled: n }) {
76
+ if (e) return n ? `Dragging was cancelled. Draggable item ${e.id} was dropped.` : t ? `Draggable item ${e.id} was dropped over droppable target ${t.id}` : `Draggable item ${e.id} was dropped.`;
77
+ }
58
78
  };
59
- function ai(e) {
60
- const t = e.tagName.toLowerCase();
61
- return ["input", "select", "textarea", "a", "button"].includes(t);
79
+ function tt(e) {
80
+ let t = e.tagName.toLowerCase();
81
+ return [
82
+ "input",
83
+ "select",
84
+ "textarea",
85
+ "a",
86
+ "button"
87
+ ].includes(t);
62
88
  }
63
- function li(e, t) {
64
- const n = document.createElement("div");
65
- return n.id = e, n.style.setProperty("display", "none"), n.textContent = t, n;
89
+ function nt(e, t) {
90
+ let n = document.createElement("div");
91
+ return n.id = e, n.style.setProperty("display", "none"), n.textContent = t, n;
66
92
  }
67
- function ci(e) {
68
- const t = document.createElement("div");
69
- return t.id = e, t.setAttribute("role", "status"), t.setAttribute("aria-live", "polite"), t.setAttribute("aria-atomic", "true"), t.style.setProperty("position", "fixed"), t.style.setProperty("width", "1px"), t.style.setProperty("height", "1px"), t.style.setProperty("margin", "-1px"), t.style.setProperty("border", "0"), t.style.setProperty("padding", "0"), t.style.setProperty("overflow", "hidden"), t.style.setProperty("clip", "rect(0 0 0 0)"), t.style.setProperty("clip-path", "inset(100%)"), t.style.setProperty("white-space", "nowrap"), t;
93
+ function rt(e) {
94
+ let t = document.createElement("div");
95
+ return t.id = e, t.setAttribute("role", "status"), t.setAttribute("aria-live", "polite"), t.setAttribute("aria-atomic", "true"), t.style.setProperty("position", "fixed"), t.style.setProperty("width", "1px"), t.style.setProperty("height", "1px"), t.style.setProperty("margin", "-1px"), t.style.setProperty("border", "0"), t.style.setProperty("padding", "0"), t.style.setProperty("overflow", "hidden"), t.style.setProperty("clip", "rect(0 0 0 0)"), t.style.setProperty("clip-path", "inset(100%)"), t.style.setProperty("white-space", "nowrap"), t;
70
96
  }
71
- var di = ["dragover", "dragmove"], ui = class extends fe {
72
- constructor(e, t) {
73
- super(e);
74
- const {
75
- id: n,
76
- idPrefix: {
77
- description: r = ri,
78
- announcement: i = ii
79
- } = {},
80
- announcements: s = oi,
81
- screenReaderInstructions: a = si,
82
- debounce: o = 500
83
- } = t ?? {}, d = n ? `${r}-${n}` : ct(r), c = n ? `${i}-${n}` : ct(i);
84
- let u, l, h, m;
85
- const g = (y = m) => {
86
- !h || !y || h?.nodeValue !== y && (h.nodeValue = y);
87
- }, w = () => Ne.schedule(g), D = hi(
88
- w,
89
- o
90
- ), k = Object.entries(s).map(
91
- ([y, C]) => this.manager.monitor.addEventListener(
92
- y,
93
- (E, L) => {
94
- const T = h;
95
- if (!T) return;
96
- const P = C?.(E, L);
97
- P && T.nodeValue !== P && (m = P, di.includes(y) ? D() : (w(), D.cancel()));
98
- }
99
- )
100
- ), f = () => {
101
- let y = [];
102
- u?.isConnected || (u = li(
103
- d,
104
- a.draggable
105
- ), y.push(u)), l?.isConnected || (l = ci(c), h = document.createTextNode(""), l.appendChild(h), y.push(l)), y.length > 0 && document.body.append(...y);
106
- }, v = /* @__PURE__ */ new Set();
107
- function p() {
108
- for (const y of v)
109
- y();
110
- }
111
- this.registerEffect(() => {
112
- var y;
113
- v.clear();
114
- for (const C of this.manager.registry.draggables.value) {
115
- const E = (y = C.handle) != null ? y : C.element;
116
- if (E) {
117
- (!u || !l) && v.add(f), (!ai(E) || Cr()) && !E.hasAttribute("tabindex") && v.add(() => E.setAttribute("tabindex", "0")), !E.hasAttribute("role") && E.tagName.toLowerCase() !== "button" && v.add(
118
- () => E.setAttribute("role", pn.role)
119
- ), E.hasAttribute("aria-roledescription") || v.add(
120
- () => E.setAttribute(
121
- "aria-roledescription",
122
- pn.roleDescription
123
- )
124
- ), E.hasAttribute("aria-describedby") || v.add(
125
- () => E.setAttribute("aria-describedby", d)
126
- );
127
- for (const T of ["aria-pressed", "aria-grabbed"]) {
128
- const P = String(C.isDragging);
129
- E.getAttribute(T) !== P && v.add(() => E.setAttribute(T, P));
130
- }
131
- const L = String(C.disabled);
132
- E.getAttribute("aria-disabled") !== L && v.add(
133
- () => E.setAttribute("aria-disabled", L)
134
- );
135
- }
136
- }
137
- v.size > 0 && Ne.schedule(p);
138
- }), this.destroy = () => {
139
- super.destroy(), u?.remove(), l?.remove(), k.forEach((y) => y());
140
- };
141
- }
97
+ var it = ["dragover", "dragmove"], at = class extends y {
98
+ constructor(e, t) {
99
+ super(e);
100
+ let { id: n, idPrefix: { description: r = Ze, announcement: i = Qe } = {}, announcements: a = et, screenReaderInstructions: o = $e, debounce: s = 500 } = t ?? {}, c = n ? `${r}-${n}` : ce(r), l = n ? `${i}-${n}` : ce(i), u, d, f, p, m = (e = p) => {
101
+ !f || !e || f?.nodeValue !== e && (f.nodeValue = e);
102
+ }, h = () => A.schedule(m), g = ot(h, s), _ = Object.entries(a).map(([e, t]) => this.manager.monitor.addEventListener(e, (n, r) => {
103
+ let i = f;
104
+ if (!i) return;
105
+ let a = t?.(n, r);
106
+ a && i.nodeValue !== a && (p = a, it.includes(e) ? g() : (h(), g.cancel()));
107
+ })), v = () => {
108
+ let e = [];
109
+ u?.isConnected || (u = nt(c, o.draggable), e.push(u)), d?.isConnected || (d = rt(l), f = document.createTextNode(""), d.appendChild(f), e.push(d)), e.length > 0 && document.body.append(...e);
110
+ }, y = /* @__PURE__ */ new Set();
111
+ function ee() {
112
+ for (let e of y) e();
113
+ }
114
+ this.registerEffect(() => {
115
+ y.clear();
116
+ for (let e of this.manager.registry.draggables.value) {
117
+ let t = e.handle ?? e.element;
118
+ if (t) {
119
+ (!u || !d) && y.add(v), (!tt(t) || we()) && !t.hasAttribute("tabindex") && y.add(() => t.setAttribute("tabindex", "0")), !t.hasAttribute("role") && t.tagName.toLowerCase() !== "button" && y.add(() => t.setAttribute("role", Xe.role)), t.hasAttribute("aria-roledescription") || y.add(() => t.setAttribute("aria-roledescription", Xe.roleDescription)), t.hasAttribute("aria-describedby") || y.add(() => t.setAttribute("aria-describedby", c));
120
+ for (let n of ["aria-pressed", "aria-grabbed"]) {
121
+ let r = String(e.isDragging);
122
+ t.getAttribute(n) !== r && y.add(() => t.setAttribute(n, r));
123
+ }
124
+ let n = String(e.disabled);
125
+ t.getAttribute("aria-disabled") !== n && y.add(() => t.setAttribute("aria-disabled", n));
126
+ }
127
+ }
128
+ y.size > 0 && A.schedule(ee);
129
+ }), this.destroy = () => {
130
+ super.destroy(), u?.remove(), d?.remove(), _.forEach((e) => e());
131
+ };
132
+ }
142
133
  };
143
- function hi(e, t) {
144
- let n;
145
- const r = () => {
146
- clearTimeout(n), n = setTimeout(e, t);
147
- };
148
- return r.cancel = () => clearTimeout(n), r;
134
+ function ot(e, t) {
135
+ let n, r = () => {
136
+ clearTimeout(n), n = setTimeout(e, t);
137
+ };
138
+ return r.cancel = () => clearTimeout(n), r;
149
139
  }
150
- var Ue = /* @__PURE__ */ new Map(), Ln, Wn, Fn, zn, ht, xe, N, Ct, ue, Nn, jn, Xn, Kn, H = class extends (ht = St, zn = [j], Fn = [st], Wn = [st], Ln = [st], ht) {
151
- constructor(t, n) {
152
- super(t, n), A(N, 5, this), S(this, ue), S(this, xe, /* @__PURE__ */ new Set()), S(this, Ct, A(N, 8, this, /* @__PURE__ */ new Set())), A(N, 11, this), this.registerEffect(Z(this, ue, Nn));
153
- }
154
- /**
155
- * Registers CSS rules to be injected into the active drag operation's
156
- * document and shadow roots. The StyleInjector handles tracking
157
- * which roots need the styles and cleaning up when they're no longer needed.
158
- *
159
- * Returns a cleanup function that unregisters the rules.
160
- */
161
- register(t) {
162
- return _(this, xe).add(t), () => {
163
- _(this, xe).delete(t);
164
- };
165
- }
166
- /**
167
- * Adds an additional root to track for style injection.
168
- * Returns a cleanup function that removes the root.
169
- */
170
- addRoot(t) {
171
- return W(() => {
172
- const n = new Set(this.additionalRoots);
173
- n.add(t), this.additionalRoots = n;
174
- }), () => {
175
- W(() => {
176
- const n = new Set(this.additionalRoots);
177
- n.delete(t), this.additionalRoots = n;
178
- });
179
- };
180
- }
181
- get sourceRoot() {
182
- var t;
183
- const { source: n } = this.manager.dragOperation;
184
- return Xe((t = n?.element) != null ? t : null);
185
- }
186
- get targetRoot() {
187
- var t;
188
- const { target: n } = this.manager.dragOperation;
189
- return Xe((t = n?.element) != null ? t : null);
190
- }
191
- get roots() {
192
- const { status: t } = this.manager.dragOperation;
193
- if (t.initializing || t.initialized) {
194
- const n = [this.sourceRoot, this.targetRoot].filter(
195
- (r) => r != null
196
- );
197
- return /* @__PURE__ */ new Set([...n, ...this.additionalRoots]);
198
- }
199
- return /* @__PURE__ */ new Set();
200
- }
201
- };
202
- N = me(ht);
203
- xe = /* @__PURE__ */ new WeakMap();
204
- Ct = /* @__PURE__ */ new WeakMap();
205
- ue = /* @__PURE__ */ new WeakSet();
206
- Nn = function() {
207
- const { roots: e } = this, t = [];
208
- for (const n of e)
209
- for (const r of _(this, xe))
210
- t.push(Z(this, ue, jn).call(this, n, r));
211
- return () => {
212
- for (const n of t)
213
- n();
214
- };
215
- };
216
- jn = function(e, t) {
217
- let n = Ue.get(e);
218
- n || (n = /* @__PURE__ */ new Map(), Ue.set(e, n));
219
- let r = n.get(t);
220
- if (!r) {
221
- const s = Wr(e) ? Z(this, ue, Xn).call(this, e, n, t) : Z(this, ue, Kn).call(this, e, n, t);
222
- if (!s)
223
- return () => {
224
- };
225
- r = s, n.set(t, r);
226
- }
227
- r.refCount++;
228
- let i = !1;
229
- return () => {
230
- i || (i = !0, r.refCount--, r.refCount === 0 && r.cleanup());
231
- };
140
+ var st = /* @__PURE__ */ new Map(), ct, lt, ut, dt, ft, pt, U, mt, ht, gt, _t, vt, yt, W = class extends (ft = h, dt = [c], ut = [o], lt = [o], ct = [o], ft) {
141
+ constructor(e, t) {
142
+ super(e, t), L(U, 5, this), B(this, ht), B(this, pt, /* @__PURE__ */ new Set()), B(this, mt, L(U, 8, this, /* @__PURE__ */ new Set())), L(U, 11, this), this.registerEffect(H(this, ht, gt));
143
+ }
144
+ register(e) {
145
+ return z(this, pt).add(e), () => {
146
+ z(this, pt).delete(e);
147
+ };
148
+ }
149
+ addRoot(e) {
150
+ return r(() => {
151
+ let t = new Set(this.additionalRoots);
152
+ t.add(e), this.additionalRoots = t;
153
+ }), () => {
154
+ r(() => {
155
+ let t = new Set(this.additionalRoots);
156
+ t.delete(e), this.additionalRoots = t;
157
+ });
158
+ };
159
+ }
160
+ get sourceRoot() {
161
+ let { source: e } = this.manager.dragOperation;
162
+ return D(e?.element ?? null);
163
+ }
164
+ get targetRoot() {
165
+ let { target: e } = this.manager.dragOperation;
166
+ return D(e?.element ?? null);
167
+ }
168
+ get roots() {
169
+ let { status: e } = this.manager.dragOperation;
170
+ if (e.initializing || e.initialized) {
171
+ let e = [this.sourceRoot, this.targetRoot].filter((e) => e != null);
172
+ return /* @__PURE__ */ new Set([...e, ...this.additionalRoots]);
173
+ }
174
+ return /* @__PURE__ */ new Set();
175
+ }
232
176
  };
233
- Xn = function(e, t, n) {
234
- var r;
235
- const i = e.createElement("style"), { nonce: s } = (r = this.options) != null ? r : {};
236
- s && i.setAttribute("nonce", s), i.textContent = n, e.head.prepend(i);
237
- const a = new MutationObserver((o) => {
238
- for (const d of o)
239
- for (const c of Array.from(d.removedNodes))
240
- if (c === i) {
241
- e.head.prepend(i);
242
- return;
243
- }
244
- });
245
- return a.observe(e.head, { childList: !0 }), {
246
- refCount: 0,
247
- cleanup: () => {
248
- a.disconnect(), i.remove(), t.delete(n), t.size === 0 && Ue.delete(e);
249
- }
250
- };
251
- };
252
- Kn = function(e, t, n) {
253
- !("adoptedStyleSheets" in e && Array.isArray(e.adoptedStyleSheets)) && process.env.NODE_ENV !== "production" && console.error(
254
- "Cannot inject styles: This browser doesn't support adoptedStyleSheets"
255
- );
256
- const r = e.ownerDocument.defaultView, { CSSStyleSheet: i } = r ?? {};
257
- if (!i)
258
- return process.env.NODE_ENV !== "production" && console.error(
259
- "Cannot inject styles: CSSStyleSheet constructor not available"
260
- ), null;
261
- const s = new i();
262
- return s.replaceSync(n), e.adoptedStyleSheets.push(s), {
263
- refCount: 0,
264
- cleanup: () => {
265
- var a;
266
- if (Fr(e) && ((a = e.host) != null && a.isConnected)) {
267
- const o = e.adoptedStyleSheets.indexOf(s);
268
- o !== -1 && e.adoptedStyleSheets.splice(o, 1);
269
- }
270
- t.delete(n), t.size === 0 && Ue.delete(e);
271
- }
272
- };
273
- };
274
- R(N, 4, "additionalRoots", zn, H, Ct);
275
- R(N, 2, "sourceRoot", Fn, H);
276
- R(N, 2, "targetRoot", Wn, H);
277
- R(N, 2, "roots", Ln, H);
278
- ee(N, H);
279
- H.configure = Pe(H);
280
- var He = H, fi = class extends fe {
281
- constructor(e, t) {
282
- super(e, t), this.manager = e;
283
- const { cursor: n = "grabbing" } = t ?? {}, r = e.registry.plugins.get(
284
- He
285
- ), i = r?.register(
286
- `* { cursor: ${n} !important; }`
287
- );
288
- if (i) {
289
- const s = this.destroy.bind(this);
290
- this.destroy = () => {
291
- i(), s();
292
- };
293
- }
294
- }
295
- }, Te = "data-dnd-", ft = `${Te}dropping`, O = "--dnd-", z = `${Te}dragging`, Ye = `${Te}placeholder`, pi = [
296
- z,
297
- Ye,
298
- "popover",
299
- "aria-pressed",
300
- "aria-grabbing"
301
- ], vi = ["view-transition-name"], mi = `
302
- :is(:root,:host) [${z}] {
177
+ U = F(ft), pt = /* @__PURE__ */ new WeakMap(), mt = /* @__PURE__ */ new WeakMap(), ht = /* @__PURE__ */ new WeakSet(), gt = function() {
178
+ let { roots: e } = this, t = [];
179
+ for (let n of e) for (let e of z(this, pt)) t.push(H(this, ht, _t).call(this, n, e));
180
+ return () => {
181
+ for (let e of t) e();
182
+ };
183
+ }, _t = function(e, t) {
184
+ let n = st.get(e);
185
+ n || (n = /* @__PURE__ */ new Map(), st.set(e, n));
186
+ let r = n.get(t);
187
+ if (!r) {
188
+ let i = be(e) ? H(this, ht, vt).call(this, e, n, t) : H(this, ht, yt).call(this, e, n, t);
189
+ if (!i) return () => {};
190
+ r = i, n.set(t, r);
191
+ }
192
+ r.refCount++;
193
+ let i = !1;
194
+ return () => {
195
+ i || (i = !0, r.refCount--, r.refCount === 0 && r.cleanup());
196
+ };
197
+ }, vt = function(e, t, n) {
198
+ let r = e.createElement("style"), { nonce: i } = this.options ?? {};
199
+ i && r.setAttribute("nonce", i), r.textContent = n, e.head.prepend(r);
200
+ let a = new MutationObserver((t) => {
201
+ for (let n of t) for (let t of Array.from(n.removedNodes)) if (t === r) {
202
+ e.head.prepend(r);
203
+ return;
204
+ }
205
+ });
206
+ return a.observe(e.head, { childList: !0 }), {
207
+ refCount: 0,
208
+ cleanup: () => {
209
+ a.disconnect(), r.remove(), t.delete(n), t.size === 0 && st.delete(e);
210
+ }
211
+ };
212
+ }, yt = function(e, t, n) {
213
+ !("adoptedStyleSheets" in e && Array.isArray(e.adoptedStyleSheets)) && process.env.NODE_ENV !== "production" && console.error("Cannot inject styles: This browser doesn't support adoptedStyleSheets");
214
+ let { CSSStyleSheet: r } = e.ownerDocument.defaultView ?? {};
215
+ if (!r) return process.env.NODE_ENV !== "production" && console.error("Cannot inject styles: CSSStyleSheet constructor not available"), null;
216
+ let i = new r();
217
+ return i.replaceSync(n), e.adoptedStyleSheets.push(i), {
218
+ refCount: 0,
219
+ cleanup: () => {
220
+ if (k(e) && e.host?.isConnected) {
221
+ let t = e.adoptedStyleSheets.indexOf(i);
222
+ t !== -1 && e.adoptedStyleSheets.splice(t, 1);
223
+ }
224
+ t.delete(n), t.size === 0 && st.delete(e);
225
+ }
226
+ };
227
+ }, R(U, 4, "additionalRoots", dt, W, mt), R(U, 2, "sourceRoot", ut, W), R(U, 2, "targetRoot", lt, W), R(U, 2, "roots", ct, W), I(U, W), W.configure = b(W);
228
+ var bt = W, xt = class extends y {
229
+ constructor(e, t) {
230
+ super(e, t), this.manager = e;
231
+ let { cursor: n = "grabbing" } = t ?? {}, r = e.registry.plugins.get(bt)?.register(`* { cursor: ${n} !important; }`);
232
+ if (r) {
233
+ let e = this.destroy.bind(this);
234
+ this.destroy = () => {
235
+ r(), e();
236
+ };
237
+ }
238
+ }
239
+ }, St = "data-dnd-", Ct = `${St}dropping`, G = "--dnd-", K = `${St}dragging`, wt = `${St}placeholder`, Tt = [
240
+ K,
241
+ wt,
242
+ "popover",
243
+ "aria-pressed",
244
+ "aria-grabbing"
245
+ ], Et = ["view-transition-name"], Dt = `
246
+ :is(:root,:host) [${K}] {
303
247
  position: fixed !important;
304
248
  pointer-events: none !important;
305
249
  touch-action: none;
306
250
  z-index: calc(infinity);
307
251
  will-change: translate;
308
- top: var(${O}top, 0px) !important;
309
- left: var(${O}left, 0px) !important;
252
+ top: var(${G}top, 0px) !important;
253
+ left: var(${G}left, 0px) !important;
310
254
  right: unset !important;
311
255
  bottom: unset !important;
312
- width: var(${O}width, auto);
313
- max-width: var(${O}width, auto);
314
- height: var(${O}height, auto);
315
- max-height: var(${O}height, auto);
316
- transform: var(${O}transform, none) !important;
317
- transition: var(${O}transition) !important;
256
+ width: var(${G}width, auto);
257
+ max-width: var(${G}width, auto);
258
+ height: var(${G}height, auto);
259
+ max-height: var(${G}height, auto);
260
+ transform: var(${G}transform, none) !important;
261
+ transition: var(${G}transition) !important;
318
262
  }
319
263
 
320
- :is(:root,:host) [${Ye}] {
264
+ :is(:root,:host) [${wt}] {
321
265
  transition: none;
322
266
  }
323
267
 
324
- :is(:root,:host) [${Ye}='hidden'] {
268
+ :is(:root,:host) [${wt}='hidden'] {
325
269
  visibility: hidden;
326
270
  }
327
271
 
328
- [${z}] * {
272
+ [${K}] * {
329
273
  pointer-events: none !important;
330
274
  }
331
275
 
332
- [${z}]:not([${ft}]) {
333
- translate: var(${O}translate) !important;
276
+ [${K}]:not([${Ct}]) {
277
+ translate: var(${G}translate) !important;
334
278
  }
335
279
 
336
- [${z}][style*='${O}scale'] {
337
- scale: var(${O}scale) !important;
338
- transform-origin: var(${O}transform-origin) !important;
280
+ [${K}][style*='${G}scale'] {
281
+ scale: var(${G}scale) !important;
282
+ transform-origin: var(${G}transform-origin) !important;
339
283
  }
340
284
 
341
285
  @layer dnd-kit {
342
- :where([${z}][popover]) {
286
+ :where([${K}][popover]) {
343
287
  overflow: visible;
344
288
  background: unset;
345
289
  border: unset;
@@ -353,1244 +297,1038 @@ var He = H, fi = class extends fe {
353
297
  }
354
298
  }
355
299
  }
356
- [${z}]::backdrop, [${Te}overlay]:not([${z}]) {
300
+ [${K}]::backdrop, [${St}overlay]:not([${K}]) {
357
301
  display: none;
358
302
  visibility: hidden;
359
303
  }
360
304
  `.replace(/\n+/g, " ").replace(/\s+/g, " ").trim();
361
- function gi(e, t = "hidden") {
362
- return W(() => {
363
- const { element: n, manager: r } = e;
364
- if (!n || !r) return;
365
- const i = yi(
366
- n,
367
- r.registry.droppables
368
- ), s = [], a = Kr(n), { remove: o } = a;
369
- return bi(i, a, s), _i(a, t), a.remove = () => {
370
- s.forEach((d) => d()), o.call(a);
371
- }, a;
372
- });
305
+ function Ot(e, t = "hidden") {
306
+ return r(() => {
307
+ let { element: n, manager: r } = e;
308
+ if (!n || !r) return;
309
+ let i = kt(n, r.registry.droppables), a = [], o = oe(n), { remove: s } = o;
310
+ return At(i, o, a), jt(o, t), o.remove = () => {
311
+ a.forEach((e) => e()), s.call(o);
312
+ }, o;
313
+ });
373
314
  }
374
- function yi(e, t) {
375
- const n = /* @__PURE__ */ new Map();
376
- for (const r of t)
377
- if (r.element && (e === r.element || e.contains(r.element))) {
378
- const i = `${Te}${ct("dom-id")}`;
379
- r.element.setAttribute(i, ""), n.set(r, i);
380
- }
381
- return n;
315
+ function kt(e, t) {
316
+ let n = /* @__PURE__ */ new Map();
317
+ for (let r of t) if (r.element && (e === r.element || e.contains(r.element))) {
318
+ let e = `${St}${ce("dom-id")}`;
319
+ r.element.setAttribute(e, ""), n.set(r, e);
320
+ }
321
+ return n;
382
322
  }
383
- function bi(e, t, n) {
384
- for (const [r, i] of e) {
385
- if (!r.element) continue;
386
- const s = `[${i}]`, a = t.matches(s) ? t : t.querySelector(s);
387
- if (r.element.removeAttribute(i), !a) continue;
388
- const o = r.element;
389
- r.proxy = a, a.removeAttribute(i), un.set(o, a), n.push(() => {
390
- un.delete(o), r.proxy = void 0;
391
- });
392
- }
323
+ function At(e, t, n) {
324
+ for (let [r, i] of e) {
325
+ if (!r.element) continue;
326
+ let e = `[${i}]`, a = t.matches(e) ? t : t.querySelector(e);
327
+ if (r.element.removeAttribute(i), !a) continue;
328
+ let o = r.element;
329
+ r.proxy = a, a.removeAttribute(i), w.set(o, a), n.push(() => {
330
+ w.delete(o), r.proxy = void 0;
331
+ });
332
+ }
393
333
  }
394
- function _i(e, t = "hidden") {
395
- e.setAttribute("inert", "true"), e.setAttribute("tab-index", "-1"), e.setAttribute("aria-hidden", "true"), e.setAttribute(Ye, t);
334
+ function jt(e, t = "hidden") {
335
+ e.setAttribute("inert", "true"), e.setAttribute("tab-index", "-1"), e.setAttribute("aria-hidden", "true"), e.setAttribute(wt, t);
396
336
  }
397
- function Un(e, t) {
398
- return e === t ? !0 : cn(e) === cn(t);
337
+ function Mt(e, t) {
338
+ return e === t || he(e) === he(t);
399
339
  }
400
- function vn(e) {
401
- const { target: t } = e;
402
- "newState" in e && e.newState === "closed" && ce(t) && t.hasAttribute("popover") && requestAnimationFrame(() => le(t));
340
+ function Nt(e) {
341
+ let { target: t } = e;
342
+ "newState" in e && e.newState === "closed" && O(t) && t.hasAttribute("popover") && requestAnimationFrame(() => Ae(t));
403
343
  }
404
- function pt(e) {
405
- return e.tagName === "TR";
344
+ function Pt(e) {
345
+ return e.tagName === "TR";
406
346
  }
407
- function wi(e, t, n) {
408
- const r = new MutationObserver((i) => {
409
- let s = !1;
410
- for (const a of i) {
411
- if (a.target !== e) {
412
- s = !0;
413
- continue;
414
- }
415
- if (a.type !== "attributes")
416
- continue;
417
- const o = a.attributeName;
418
- if (o.startsWith("aria-") || pi.includes(o))
419
- continue;
420
- const d = e.getAttribute(o);
421
- if (o === "style") {
422
- if (dn(e) && dn(t)) {
423
- const c = e.style;
424
- for (const u of Array.from(t.style))
425
- c.getPropertyValue(u) === "" && t.style.removeProperty(u);
426
- for (const u of Array.from(c)) {
427
- if (vi.includes(u) || u.startsWith(O))
428
- continue;
429
- const l = c.getPropertyValue(u);
430
- t.style.setProperty(u, l);
431
- }
432
- }
433
- } else d !== null ? t.setAttribute(o, d) : t.removeAttribute(o);
434
- }
435
- s && n && t.replaceChildren(...e.cloneNode(!0).childNodes);
436
- });
437
- return r.observe(e, {
438
- attributes: !0,
439
- subtree: !0,
440
- childList: !0
441
- }), r;
347
+ function Ft(e, t, n) {
348
+ let r = new MutationObserver((r) => {
349
+ let i = !1;
350
+ for (let n of r) {
351
+ if (n.target !== e) {
352
+ i = !0;
353
+ continue;
354
+ }
355
+ if (n.type !== "attributes") continue;
356
+ let r = n.attributeName;
357
+ if (r.startsWith("aria-") || Tt.includes(r)) continue;
358
+ let a = e.getAttribute(r);
359
+ if (r === "style") {
360
+ if (Me(e) && Me(t)) {
361
+ let n = e.style;
362
+ for (let e of Array.from(t.style)) n.getPropertyValue(e) === "" && t.style.removeProperty(e);
363
+ for (let e of Array.from(n)) {
364
+ if (Et.includes(e) || e.startsWith(G)) continue;
365
+ let r = n.getPropertyValue(e);
366
+ t.style.setProperty(e, r);
367
+ }
368
+ }
369
+ } else a === null ? t.removeAttribute(r) : t.setAttribute(r, a);
370
+ }
371
+ i && n && t.replaceChildren(...e.cloneNode(!0).childNodes);
372
+ });
373
+ return r.observe(e, {
374
+ attributes: !0,
375
+ subtree: !0,
376
+ childList: !0
377
+ }), r;
442
378
  }
443
- function Si(e, t, n) {
444
- const r = new MutationObserver((i) => {
445
- for (const s of i)
446
- if (s.addedNodes.length !== 0)
447
- for (const a of Array.from(s.addedNodes)) {
448
- if (a.contains(e) && e.nextElementSibling !== t) {
449
- e.insertAdjacentElement("afterend", t), le(n);
450
- return;
451
- }
452
- if (a.contains(t) && t.previousElementSibling !== e) {
453
- t.insertAdjacentElement("beforebegin", e), le(n);
454
- return;
455
- }
456
- }
457
- e.isConnected && t.isConnected && e.nextElementSibling !== t && (e.insertAdjacentElement("afterend", t), le(n));
458
- });
459
- return r.observe(e.ownerDocument.body, {
460
- childList: !0,
461
- subtree: !0
462
- }), r;
379
+ function It(e, t, n) {
380
+ let r = new MutationObserver((r) => {
381
+ for (let i of r) if (i.addedNodes.length !== 0) for (let r of Array.from(i.addedNodes)) {
382
+ if (r.contains(e) && e.nextElementSibling !== t) {
383
+ e.insertAdjacentElement("afterend", t), Ae(n);
384
+ return;
385
+ }
386
+ if (r.contains(t) && t.previousElementSibling !== e) {
387
+ t.insertAdjacentElement("beforebegin", e), Ae(n);
388
+ return;
389
+ }
390
+ }
391
+ e.isConnected && t.isConnected && e.nextElementSibling !== t && (e.insertAdjacentElement("afterend", t), Ae(n));
392
+ });
393
+ return r.observe(e.ownerDocument.body, {
394
+ childList: !0,
395
+ subtree: !0
396
+ }), r;
463
397
  }
464
- function Ei(e) {
465
- return new ResizeObserver(() => {
466
- var t, n, r;
467
- const i = new V(e.placeholder, {
468
- frameTransform: e.frameTransform,
469
- ignoreTransforms: !0
470
- }), s = (t = e.transformOrigin) != null ? t : { x: 1, y: 1 }, a = (e.width - i.width) * s.x + e.delta.x, o = (e.height - i.height) * s.y + e.delta.y, d = An();
471
- if (e.styles.set(
472
- {
473
- width: i.width - e.widthOffset,
474
- height: i.height - e.heightOffset,
475
- top: e.top + o + d.y,
476
- left: e.left + a + d.x
477
- },
478
- O
479
- ), (n = e.getElementMutationObserver()) == null || n.takeRecords(), pt(e.element) && pt(e.placeholder)) {
480
- const w = Array.from(e.element.cells), D = Array.from(e.placeholder.cells);
481
- e.getSavedCellWidths() || e.setSavedCellWidths(w.map((k) => k.style.width));
482
- for (const [k, f] of w.entries()) {
483
- const v = D[k];
484
- f.style.width = `${v.getBoundingClientRect().width}px`;
485
- }
486
- }
487
- const c = (r = e.getTranslate()) != null ? r : { x: 0, y: 0 }, u = e.left + a + d.x + c.x, l = e.top + o + d.y + c.y, h = i.width - e.widthOffset, m = i.height - e.heightOffset, g = e.frameTransform;
488
- e.dragOperation.shape = new kt(
489
- u * g.scaleX + g.x,
490
- l * g.scaleY + g.y,
491
- h * g.scaleX,
492
- m * g.scaleY
493
- );
494
- });
398
+ function Lt(e) {
399
+ return new ResizeObserver(() => {
400
+ var t;
401
+ let n = new C(e.placeholder, {
402
+ frameTransform: e.frameTransform,
403
+ ignoreTransforms: !0
404
+ }), r = e.transformOrigin ?? {
405
+ x: 1,
406
+ y: 1
407
+ }, i = (e.width - n.width) * r.x + e.delta.x, a = (e.height - n.height) * r.y + e.delta.y, o = me();
408
+ if (e.styles.set({
409
+ width: n.width - e.widthOffset,
410
+ height: n.height - e.heightOffset,
411
+ top: e.top + a + o.y,
412
+ left: e.left + i + o.x
413
+ }, G), (t = e.getElementMutationObserver()) == null || t.takeRecords(), Pt(e.element) && Pt(e.placeholder)) {
414
+ let t = Array.from(e.element.cells), n = Array.from(e.placeholder.cells);
415
+ e.getSavedCellWidths() || e.setSavedCellWidths(t.map((e) => e.style.width));
416
+ for (let [e, r] of t.entries()) {
417
+ let t = n[e];
418
+ r.style.width = `${t.getBoundingClientRect().width}px`;
419
+ }
420
+ }
421
+ let s = e.getTranslate() ?? {
422
+ x: 0,
423
+ y: 0
424
+ }, c = e.left + i + o.x + s.x, l = e.top + a + o.y + s.y, u = n.width - e.widthOffset, f = n.height - e.heightOffset, p = e.frameTransform;
425
+ e.dragOperation.shape = new d(c * p.scaleX + p.x, l * p.scaleY + p.y, u * p.scaleX, f * p.scaleY);
426
+ });
495
427
  }
496
- var xi = 250, ki = "ease";
497
- function Ai(e) {
498
- var t, n, r, i;
499
- const { animation: s } = e;
500
- if (typeof s == "function") {
501
- const f = s({
502
- source: e.source,
503
- element: e.element,
504
- feedbackElement: e.feedbackElement,
505
- placeholder: e.placeholder,
506
- translate: e.translate,
507
- moved: e.moved
508
- });
509
- Promise.resolve(f).then(() => {
510
- e.cleanup(), requestAnimationFrame(e.restoreFocus);
511
- });
512
- return;
513
- }
514
- const {
515
- duration: a = xi,
516
- easing: o = ki
517
- } = s ?? {};
518
- le(e.feedbackElement);
519
- const [, d] = (t = Ur(
520
- e.feedbackElement,
521
- (f) => "translate" in f
522
- )) != null ? t : [];
523
- d?.pause();
524
- const c = (n = e.placeholder) != null ? n : e.element, u = {
525
- frameTransform: Un(e.feedbackElement, c) ? null : void 0
526
- }, l = new V(e.feedbackElement, u), h = (r = kn(xn(e.feedbackElement).translate)) != null ? r : e.translate, m = new V(c, u), g = kt.delta(l, m, e.alignment), w = {
527
- x: h.x - g.x,
528
- y: h.y - g.y
529
- }, D = Math.round(l.intrinsicHeight) !== Math.round(m.intrinsicHeight) ? {
530
- minHeight: [
531
- `${l.intrinsicHeight}px`,
532
- `${m.intrinsicHeight}px`
533
- ],
534
- maxHeight: [
535
- `${l.intrinsicHeight}px`,
536
- `${m.intrinsicHeight}px`
537
- ]
538
- } : {}, k = Math.round(l.intrinsicWidth) !== Math.round(m.intrinsicWidth) ? {
539
- minWidth: [
540
- `${l.intrinsicWidth}px`,
541
- `${m.intrinsicWidth}px`
542
- ],
543
- maxWidth: [
544
- `${l.intrinsicWidth}px`,
545
- `${m.intrinsicWidth}px`
546
- ]
547
- } : {};
548
- e.styles.set({ transition: e.transition }, O), e.feedbackElement.setAttribute(ft, ""), (i = e.getElementMutationObserver()) == null || i.takeRecords(), Yr({
549
- element: e.feedbackElement,
550
- keyframes: Dt(Ae(Ae({}, D), k), {
551
- translate: [
552
- `${h.x}px ${h.y}px 0`,
553
- `${w.x}px ${w.y}px 0`
554
- ]
555
- }),
556
- options: {
557
- duration: On(Dn(e.feedbackElement)) ? 0 : e.moved || e.feedbackElement !== e.element ? a : 0,
558
- easing: o
559
- }
560
- }).then(() => {
561
- e.feedbackElement.removeAttribute(ft), d?.finish(), e.cleanup(), requestAnimationFrame(e.restoreFocus);
562
- });
428
+ var Rt = 250, zt = "ease";
429
+ function Bt(e) {
430
+ var t;
431
+ let { animation: n } = e;
432
+ if (typeof n == "function") {
433
+ let t = n({
434
+ source: e.source,
435
+ element: e.element,
436
+ feedbackElement: e.feedbackElement,
437
+ placeholder: e.placeholder,
438
+ translate: e.translate,
439
+ moved: e.moved
440
+ });
441
+ Promise.resolve(t).then(() => {
442
+ e.cleanup(), requestAnimationFrame(e.restoreFocus);
443
+ });
444
+ return;
445
+ }
446
+ let { duration: r = Rt, easing: i = zt } = n ?? {};
447
+ Ae(e.feedbackElement);
448
+ let [, a] = pe(e.feedbackElement, (e) => "translate" in e) ?? [];
449
+ a?.pause();
450
+ let o = e.placeholder ?? e.element, s = { frameTransform: Mt(e.feedbackElement, o) ? null : void 0 }, c = new C(e.feedbackElement, s), l = De(le(e.feedbackElement).translate) ?? e.translate, u = new C(o, s), f = d.delta(c, u, e.alignment), p = {
451
+ x: l.x - f.x,
452
+ y: l.y - f.y
453
+ }, m = Math.round(c.intrinsicHeight) === Math.round(u.intrinsicHeight) ? {} : {
454
+ minHeight: [`${c.intrinsicHeight}px`, `${u.intrinsicHeight}px`],
455
+ maxHeight: [`${c.intrinsicHeight}px`, `${u.intrinsicHeight}px`]
456
+ }, h = Math.round(c.intrinsicWidth) === Math.round(u.intrinsicWidth) ? {} : {
457
+ minWidth: [`${c.intrinsicWidth}px`, `${u.intrinsicWidth}px`],
458
+ maxWidth: [`${c.intrinsicWidth}px`, `${u.intrinsicWidth}px`]
459
+ };
460
+ e.styles.set({ transition: e.transition }, G), e.feedbackElement.setAttribute(Ct, ""), (t = e.getElementMutationObserver()) == null || t.takeRecords(), ie({
461
+ element: e.feedbackElement,
462
+ keyframes: He(P(P({}, m), h), { translate: [`${l.x}px ${l.y}px 0`, `${p.x}px ${p.y}px 0`] }),
463
+ options: {
464
+ duration: Oe(ye(e.feedbackElement)) ? 0 : e.moved || e.feedbackElement !== e.element ? r : 0,
465
+ easing: i
466
+ }
467
+ }).then(() => {
468
+ e.feedbackElement.removeAttribute(Ct), a?.finish(), e.cleanup(), requestAnimationFrame(e.restoreFocus);
469
+ });
563
470
  }
564
- var Yn, vt, De, Pt, Fe, Bn, Vn, he = class extends (vt = fe, Yn = [j], vt) {
565
- constructor(t, n) {
566
- super(t, n), S(this, Fe), S(this, Pt, A(De, 8, this)), A(De, 11, this), this.state = {
567
- initial: {},
568
- current: {}
569
- };
570
- const r = t.registry.plugins.get(He), i = r?.register(mi);
571
- if (i) {
572
- const s = this.destroy.bind(this);
573
- this.destroy = () => {
574
- i(), s();
575
- };
576
- }
577
- this.registerEffect(Z(this, Fe, Bn).bind(this, r)), this.registerEffect(Z(this, Fe, Vn));
578
- }
579
- };
580
- De = me(vt);
581
- Pt = /* @__PURE__ */ new WeakMap();
582
- Fe = /* @__PURE__ */ new WeakSet();
583
- Bn = function(e) {
584
- const { overlay: t } = this;
585
- if (!t || !e) return;
586
- const n = Xe(t);
587
- if (n)
588
- return e.addRoot(n);
589
- };
590
- Vn = function() {
591
- var e, t, n, r, i, s, a;
592
- const { state: o, manager: d, options: c } = this, { dragOperation: u } = d, { position: l, source: h, status: m } = u;
593
- if (m.idle) {
594
- o.current = {}, o.initial = {};
595
- return;
596
- }
597
- if (!h) return;
598
- const { element: g } = h, w = h.pluginConfig(he), D = (t = (e = w?.feedback) != null ? e : c?.feedback) != null ? t : "default", k = typeof D == "function" ? D(h, d) : D;
599
- if (!g || k === "none" || !m.initialized || m.initializing)
600
- return;
601
- const { initial: f } = o, v = (n = this.overlay) != null ? n : g, p = je(v), y = je(g), C = !Un(g, v), E = new V(g, {
602
- frameTransform: C ? y : null,
603
- ignoreTransforms: !C
604
- }), L = {
605
- x: y.scaleX / p.scaleX,
606
- y: y.scaleY / p.scaleY
607
- };
608
- let { width: T, height: P, top: $e, left: Ie } = E;
609
- C && (T = T / L.x, P = P / L.y);
610
- const ge = new Nr(v), Ge = xn(g), {
611
- transition: zt,
612
- translate: Nt,
613
- boxSizing: ar,
614
- paddingBlockStart: lr,
615
- paddingBlockEnd: cr,
616
- paddingInlineStart: dr,
617
- paddingInlineEnd: ur,
618
- borderInlineStartWidth: hr,
619
- borderInlineEndWidth: fr,
620
- borderBlockStartWidth: pr,
621
- borderBlockEndWidth: vr
622
- } = Ge, Me = zt.split(",").filter((b) => !/^\s*(transform|translate|scale)\b/.test(b)).join(","), q = zr(Ge), mr = Ge.transform, jt = k === "clone", Xt = ar === "content-box", Kt = Xt ? parseInt(dr) + parseInt(ur) + parseInt(hr) + parseInt(fr) : 0, Ut = Xt ? parseInt(lr) + parseInt(cr) + parseInt(pr) + parseInt(vr) : 0, I = k !== "move" && !this.overlay ? gi(h, jt ? "clone" : "hidden") : null, Je = W(
623
- () => xt(d.dragOperation.activatorEvent)
624
- );
625
- if (!f.translate) {
626
- if (this.overlay && q)
627
- f.translate = { x: q.x, y: q.y };
628
- else if (Nt !== "none") {
629
- const b = kn(Nt);
630
- b && (f.translate = b);
631
- }
632
- }
633
- if (!f.transformOrigin) {
634
- const b = W(() => l.current), x = Ie + ((r = q?.x) != null ? r : 0), M = $e + ((i = q?.y) != null ? i : 0);
635
- f.transformOrigin = {
636
- x: (b.x - x * p.scaleX - p.x) / (T * p.scaleX),
637
- y: (b.y - M * p.scaleY - p.y) / (P * p.scaleY)
638
- };
639
- }
640
- const { transformOrigin: te } = f, Yt = $e * p.scaleY + p.y, Bt = Ie * p.scaleX + p.x;
641
- if (!f.coordinates && (f.coordinates = {
642
- x: Bt,
643
- y: Yt
644
- }, L.x !== 1 || L.y !== 1)) {
645
- const { scaleX: b, scaleY: x } = y, { x: M, y: X } = te;
646
- f.coordinates.x += (T * b - T) * M, f.coordinates.y += (P * x - P) * X;
647
- }
648
- f.dimensions || (f.dimensions = { width: T, height: P }), f.frameTransform || (f.frameTransform = p);
649
- const Vt = {
650
- x: f.coordinates.x - Bt,
651
- y: f.coordinates.y - Yt
652
- }, Ht = {
653
- width: (f.dimensions.width * f.frameTransform.scaleX - T * p.scaleX) * te.x,
654
- height: (f.dimensions.height * f.frameTransform.scaleY - P * p.scaleY) * te.y
655
- }, Qe = {
656
- x: Vt.x / p.scaleX + Ht.width,
657
- y: Vt.y / p.scaleY + Ht.height
658
- }, qt = {
659
- left: Ie + Qe.x,
660
- top: $e + Qe.y
661
- };
662
- v.setAttribute(z, "true");
663
- const Gt = W(() => u.transform), Jt = (s = f.translate) != null ? s : { x: 0, y: 0 }, gr = Gt.x * p.scaleX + Jt.x, yr = Gt.y * p.scaleY + Jt.y, Qt = An();
664
- ge.set(
665
- {
666
- width: T - Kt,
667
- height: P - Ut,
668
- top: qt.top + Qt.y,
669
- left: qt.left + Qt.x,
670
- translate: `${gr}px ${yr}px 0`,
671
- transform: this.overlay ? "none" : mr,
672
- transition: Me ? `${Me}, translate 0ms linear` : "translate 0ms linear",
673
- scale: C ? `${L.x} ${L.y}` : "",
674
- "transform-origin": `${te.x * 100}% ${te.y * 100}%`
675
- },
676
- O
677
- ), I && (g.insertAdjacentElement("afterend", I), c?.rootElement && (typeof c.rootElement == "function" ? c.rootElement(h) : c.rootElement).appendChild(g)), ln(v) && (v.hasAttribute("popover") || v.setAttribute("popover", "manual"), le(v), v.addEventListener("beforetoggle", vn));
678
- let G, Ze, Re;
679
- const Zt = Ei({
680
- placeholder: I,
681
- element: g,
682
- feedbackElement: v,
683
- frameTransform: p,
684
- transformOrigin: te,
685
- width: T,
686
- height: P,
687
- top: $e,
688
- left: Ie,
689
- widthOffset: Kt,
690
- heightOffset: Ut,
691
- delta: Qe,
692
- styles: ge,
693
- dragOperation: u,
694
- getTranslate: () => o.current.translate,
695
- getElementMutationObserver: () => G,
696
- getSavedCellWidths: () => Re,
697
- setSavedCellWidths: (b) => {
698
- Re = b;
699
- }
700
- }), en = new V(v);
701
- W(() => u.shape = en);
702
- const et = Dn(v), tn = (b) => {
703
- this.manager.actions.stop({ event: b });
704
- }, br = On(et);
705
- Je && et.addEventListener("resize", tn), W(() => h.status) === "idle" && requestAnimationFrame(() => h.status = "dragging"), I && (Zt.observe(I), G = wi(
706
- g,
707
- I,
708
- jt
709
- ), Ze = Si(
710
- g,
711
- I,
712
- v
713
- ));
714
- const nn = (a = d.dragOperation.source) == null ? void 0 : a.id, _r = () => {
715
- var b;
716
- if (!Je || nn == null) return;
717
- const x = d.registry.draggables.get(nn), M = (b = x?.handle) != null ? b : x?.element;
718
- En(M) && M.focus();
719
- }, tt = () => {
720
- G?.disconnect(), Ze?.disconnect(), Zt.disconnect(), et.removeEventListener("resize", tn), ln(v) && (v.removeEventListener(
721
- "beforetoggle",
722
- vn
723
- ), v.removeAttribute("popover")), v.removeAttribute(z), ge.reset();
724
- const b = () => {
725
- var x;
726
- if (Re && pt(g)) {
727
- const nt = Array.from(g.cells);
728
- for (const [Le, ne] of nt.entries())
729
- ne.style.width = (x = Re[Le]) != null ? x : "";
730
- }
731
- h.status = "idle";
732
- const M = o.current.translate != null, X = u.status.dragging;
733
- I && (!X && M || I.parentElement !== v.parentElement) && v.isConnected && I.replaceWith(v), I?.remove();
734
- };
735
- v === this.overlay ? setTimeout(b, 0) : b();
736
- }, wr = c?.dropAnimation, rn = this, Sr = Vr(
737
- // Update transform on move
738
- () => {
739
- var b, x, M;
740
- const { transform: X, status: nt } = u;
741
- if (!(!X.x && !X.y && !o.current.translate) && nt.dragging) {
742
- const Le = (b = f.translate) != null ? b : { x: 0, y: 0 }, ne = {
743
- x: X.x / p.scaleX + Le.x,
744
- y: X.y / p.scaleY + Le.y
745
- }, sn = o.current.translate, Er = W(() => u.modifiers), rt = W(() => {
746
- var be;
747
- return (be = u.shape) == null ? void 0 : be.current;
748
- }), ye = c?.keyboardTransition, on = Je && !br && ye !== null ? `${(x = ye?.duration) != null ? x : 250}ms ${(M = ye?.easing) != null ? M : "cubic-bezier(0.25, 1, 0.5, 1)"}` : "0ms linear";
749
- if (ge.set(
750
- {
751
- transition: Me ? `${Me}, translate ${on}` : `translate ${on}`,
752
- translate: `${ne.x}px ${ne.y}px 0`
753
- },
754
- O
755
- ), G?.takeRecords(), rt && rt !== en && sn && !Er.length) {
756
- const be = Hr.delta(ne, sn);
757
- u.shape = kt.from(
758
- rt.boundingRectangle
759
- ).translate(
760
- be.x * p.scaleX,
761
- be.y * p.scaleY
762
- );
763
- } else
764
- u.shape = new V(v);
765
- o.current.translate = ne;
766
- }
767
- },
768
- // Drop animation
769
- function() {
770
- if (u.status.dropped) {
771
- this.dispose(), h.status = "dropping";
772
- const b = w?.dropAnimation !== void 0 ? w.dropAnimation : rn.dropAnimation !== void 0 ? rn.dropAnimation : wr;
773
- let x = o.current.translate;
774
- const M = x != null;
775
- if (!x && g !== v && (x = { x: 0, y: 0 }), !x || b === null) {
776
- tt();
777
- return;
778
- }
779
- d.renderer.rendering.then(() => {
780
- Ai({
781
- source: h,
782
- element: g,
783
- feedbackElement: v,
784
- placeholder: I,
785
- translate: x,
786
- moved: M,
787
- transition: zt,
788
- alignment: h.alignment,
789
- styles: ge,
790
- animation: b ?? void 0,
791
- getElementMutationObserver: () => G,
792
- cleanup: tt,
793
- restoreFocus: _r
794
- });
795
- });
796
- }
797
- }
798
- );
799
- return () => {
800
- tt(), Sr();
801
- };
471
+ var Vt, Ht, Ut, Wt, Gt, Kt, qt, Jt = class extends (Ht = y, Vt = [c], Ht) {
472
+ constructor(e, t) {
473
+ super(e, t), B(this, Gt), B(this, Wt, L(Ut, 8, this)), L(Ut, 11, this), this.state = {
474
+ initial: {},
475
+ current: {}
476
+ };
477
+ let n = e.registry.plugins.get(bt), r = n?.register(Dt);
478
+ if (r) {
479
+ let e = this.destroy.bind(this);
480
+ this.destroy = () => {
481
+ r(), e();
482
+ };
483
+ }
484
+ this.registerEffect(H(this, Gt, Kt).bind(this, n)), this.registerEffect(H(this, Gt, qt));
485
+ }
802
486
  };
803
- R(De, 4, "overlay", Yn, he, Pt);
804
- ee(De, he);
805
- he.configure = Pe(he);
806
- var Di = he, _e = !0, Oi = !1, Hn, qn, Gn, Jn, U, Tt, $t;
807
- Jn = (Gn = [j], F.Forward), qn = (Hn = [j], F.Reverse);
808
- var Oe = class {
809
- constructor() {
810
- S(this, Tt, A(U, 8, this, _e)), A(U, 11, this), S(this, $t, A(U, 12, this, _e)), A(U, 15, this);
811
- }
812
- isLocked(e) {
813
- return e === F.Idle ? !1 : e == null ? this[F.Forward] === _e && this[F.Reverse] === _e : this[e] === _e;
814
- }
815
- unlock(e) {
816
- e !== F.Idle && (this[e] = Oi);
817
- }
487
+ Ut = F(Ht), Wt = /* @__PURE__ */ new WeakMap(), Gt = /* @__PURE__ */ new WeakSet(), Kt = function(e) {
488
+ let { overlay: t } = this;
489
+ if (!t || !e) return;
490
+ let n = D(t);
491
+ if (n) return e.addRoot(n);
492
+ }, qt = function() {
493
+ let { state: e, manager: t, options: n } = this, { dragOperation: i } = t, { position: a, source: o, status: c } = i;
494
+ if (c.idle) {
495
+ e.current = {}, e.initial = {};
496
+ return;
497
+ }
498
+ if (!o) return;
499
+ let { element: l } = o, f = o.pluginConfig(Jt), p = f?.feedback ?? n?.feedback ?? "default", m = typeof p == "function" ? p(o, t) : p;
500
+ if (!l || m === "none" || !c.initialized || c.initializing) return;
501
+ let { initial: h } = e, g = this.overlay ?? l, _ = ge(g), v = ge(l), y = !Mt(l, g), ee = new C(l, {
502
+ frameTransform: y ? v : null,
503
+ ignoreTransforms: !y
504
+ }), b = {
505
+ x: v.scaleX / _.scaleX,
506
+ y: v.scaleY / _.scaleY
507
+ }, { width: x, height: S, top: te, left: ne } = ee;
508
+ y && (x /= b.x, S /= b.y);
509
+ let w = new re(g), T = le(l), { transition: ie, translate: ae, boxSizing: oe, paddingBlockStart: se, paddingBlockEnd: ce, paddingInlineStart: ue, paddingInlineEnd: de, borderInlineStartWidth: fe, borderInlineEndWidth: E, borderBlockStartWidth: pe, borderBlockEndWidth: he } = T, _e = ie.split(",").filter((e) => !/^\s*(transform|translate|scale)\b/.test(e)).join(","), D = Ee(T), ve = T.transform, be = m === "clone", O = oe === "content-box", Ce = O ? parseInt(ue) + parseInt(de) + parseInt(fe) + parseInt(E) : 0, we = O ? parseInt(se) + parseInt(ce) + parseInt(pe) + parseInt(he) : 0, k = m !== "move" && !this.overlay ? Ot(o, be ? "clone" : "hidden") : null, Te = r(() => Se(t.dragOperation.activatorEvent));
510
+ if (!h.translate) {
511
+ if (this.overlay && D) h.translate = {
512
+ x: D.x,
513
+ y: D.y
514
+ };
515
+ else if (ae !== "none") {
516
+ let e = De(ae);
517
+ e && (h.translate = e);
518
+ }
519
+ }
520
+ if (!h.transformOrigin) {
521
+ let e = r(() => a.current), t = ne + (D?.x ?? 0), n = te + (D?.y ?? 0);
522
+ h.transformOrigin = {
523
+ x: (e.x - t * _.scaleX - _.x) / (x * _.scaleX),
524
+ y: (e.y - n * _.scaleY - _.y) / (S * _.scaleY)
525
+ };
526
+ }
527
+ let { transformOrigin: A } = h, ke = te * _.scaleY + _.y, Me = ne * _.scaleX + _.x;
528
+ if (!h.coordinates && (h.coordinates = {
529
+ x: Me,
530
+ y: ke
531
+ }, b.x !== 1 || b.y !== 1)) {
532
+ let { scaleX: e, scaleY: t } = v, { x: n, y: r } = A;
533
+ h.coordinates.x += (x * e - x) * n, h.coordinates.y += (S * t - S) * r;
534
+ }
535
+ h.dimensions ||= {
536
+ width: x,
537
+ height: S
538
+ }, h.frameTransform ||= _;
539
+ let Ne = {
540
+ x: h.coordinates.x - Me,
541
+ y: h.coordinates.y - ke
542
+ }, Pe = {
543
+ width: (h.dimensions.width * h.frameTransform.scaleX - x * _.scaleX) * A.x,
544
+ height: (h.dimensions.height * h.frameTransform.scaleY - S * _.scaleY) * A.y
545
+ }, Fe = {
546
+ x: Ne.x / _.scaleX + Pe.width,
547
+ y: Ne.y / _.scaleY + Pe.height
548
+ }, Ie = {
549
+ left: ne + Fe.x,
550
+ top: te + Fe.y
551
+ };
552
+ g.setAttribute(K, "true");
553
+ let Le = r(() => i.transform), Re = h.translate ?? {
554
+ x: 0,
555
+ y: 0
556
+ }, ze = Le.x * _.scaleX + Re.x, Be = Le.y * _.scaleY + Re.y, Ve = me();
557
+ w.set({
558
+ width: x - Ce,
559
+ height: S - we,
560
+ top: Ie.top + Ve.y,
561
+ left: Ie.left + Ve.x,
562
+ translate: `${ze}px ${Be}px 0`,
563
+ transform: this.overlay ? "none" : ve,
564
+ transition: _e ? `${_e}, translate 0ms linear` : "translate 0ms linear",
565
+ scale: y ? `${b.x} ${b.y}` : "",
566
+ "transform-origin": `${A.x * 100}% ${A.y * 100}%`
567
+ }, G), k && (l.insertAdjacentElement("afterend", k), n?.rootElement && (typeof n.rootElement == "function" ? n.rootElement(o) : n.rootElement).appendChild(l)), je(g) && (g.hasAttribute("popover") || g.setAttribute("popover", "manual"), Ae(g), g.addEventListener("beforetoggle", Nt));
568
+ let j, M, N, P = Lt({
569
+ placeholder: k,
570
+ element: l,
571
+ feedbackElement: g,
572
+ frameTransform: _,
573
+ transformOrigin: A,
574
+ width: x,
575
+ height: S,
576
+ top: te,
577
+ left: ne,
578
+ widthOffset: Ce,
579
+ heightOffset: we,
580
+ delta: Fe,
581
+ styles: w,
582
+ dragOperation: i,
583
+ getTranslate: () => e.current.translate,
584
+ getElementMutationObserver: () => j,
585
+ getSavedCellWidths: () => N,
586
+ setSavedCellWidths: (e) => {
587
+ N = e;
588
+ }
589
+ }), He = new C(g);
590
+ r(() => i.shape = He);
591
+ let Ue = ye(g), We = (e) => {
592
+ this.manager.actions.stop({ event: e });
593
+ }, F = Oe(Ue);
594
+ Te && Ue.addEventListener("resize", We), r(() => o.status) === "idle" && requestAnimationFrame(() => o.status = "dragging"), k && (P.observe(k), j = Ft(l, k, be), M = It(l, k, g));
595
+ let Ge = t.dragOperation.source?.id, Ke = () => {
596
+ if (!Te || Ge == null) return;
597
+ let e = t.registry.draggables.get(Ge), n = e?.handle ?? e?.element;
598
+ xe(n) && n.focus();
599
+ }, qe = () => {
600
+ j?.disconnect(), M?.disconnect(), P.disconnect(), Ue.removeEventListener("resize", We), je(g) && (g.removeEventListener("beforetoggle", Nt), g.removeAttribute("popover")), g.removeAttribute(K), w.reset();
601
+ let t = () => {
602
+ if (N && Pt(l)) {
603
+ let e = Array.from(l.cells);
604
+ for (let [t, n] of e.entries()) n.style.width = N[t] ?? "";
605
+ }
606
+ o.status = "idle";
607
+ let t = e.current.translate != null, n = i.status.dragging;
608
+ k && (!n && t || k.parentElement !== g.parentElement) && g.isConnected && k.replaceWith(g), k?.remove();
609
+ };
610
+ g === this.overlay ? setTimeout(t, 0) : t();
611
+ }, I = n?.dropAnimation, L = this, R = s(() => {
612
+ let { transform: t, status: a } = i;
613
+ if (!(!t.x && !t.y && !e.current.translate) && a.dragging) {
614
+ let a = h.translate ?? {
615
+ x: 0,
616
+ y: 0
617
+ }, o = {
618
+ x: t.x / _.scaleX + a.x,
619
+ y: t.y / _.scaleY + a.y
620
+ }, s = e.current.translate, c = r(() => i.modifiers), l = r(() => i.shape?.current), f = n?.keyboardTransition, p = Te && !F && f !== null ? `${f?.duration ?? 250}ms ${f?.easing ?? "cubic-bezier(0.25, 1, 0.5, 1)"}` : "0ms linear";
621
+ if (w.set({
622
+ transition: _e ? `${_e}, translate ${p}` : `translate ${p}`,
623
+ translate: `${o.x}px ${o.y}px 0`
624
+ }, G), j?.takeRecords(), l && l !== He && s && !c.length) {
625
+ let e = u.delta(o, s);
626
+ i.shape = d.from(l.boundingRectangle).translate(e.x * _.scaleX, e.y * _.scaleY);
627
+ } else i.shape = new C(g);
628
+ e.current.translate = o;
629
+ }
630
+ }, function() {
631
+ if (i.status.dropped) {
632
+ this.dispose(), o.status = "dropping";
633
+ let n = f?.dropAnimation === void 0 ? L.dropAnimation === void 0 ? I : L.dropAnimation : f.dropAnimation, r = e.current.translate, i = r != null;
634
+ if (!r && l !== g && (r = {
635
+ x: 0,
636
+ y: 0
637
+ }), !r || n === null) {
638
+ qe();
639
+ return;
640
+ }
641
+ t.renderer.rendering.then(() => {
642
+ Bt({
643
+ source: o,
644
+ element: l,
645
+ feedbackElement: g,
646
+ placeholder: k,
647
+ translate: r,
648
+ moved: i,
649
+ transition: ie,
650
+ alignment: o.alignment,
651
+ styles: w,
652
+ animation: n ?? void 0,
653
+ getElementMutationObserver: () => j,
654
+ cleanup: qe,
655
+ restoreFocus: Ke
656
+ });
657
+ });
658
+ }
659
+ });
660
+ return () => {
661
+ qe(), R();
662
+ };
663
+ }, R(Ut, 4, "overlay", Vt, Jt, Wt), I(Ut, Jt), Jt.configure = b(Jt);
664
+ var Yt = Jt, Xt = !0, Zt = !1, Qt, $t, en, tn = (en = [c], T.Forward), q, nn, rn;
665
+ $t = (Qt = [c], T.Reverse);
666
+ var an = class {
667
+ constructor() {
668
+ B(this, nn, L(q, 8, this, Xt)), L(q, 11, this), B(this, rn, L(q, 12, this, Xt)), L(q, 15, this);
669
+ }
670
+ isLocked(e) {
671
+ return e === T.Idle ? !1 : e == null ? this[T.Forward] === Xt && this[T.Reverse] === Xt : this[e] === Xt;
672
+ }
673
+ unlock(e) {
674
+ e !== T.Idle && (this[e] = Zt);
675
+ }
818
676
  };
819
- U = me(null);
820
- Tt = /* @__PURE__ */ new WeakMap();
821
- $t = /* @__PURE__ */ new WeakMap();
822
- R(U, 4, Jn, Gn, Oe, Tt);
823
- R(U, 4, qn, Hn, Oe, $t);
824
- ee(U, Oe);
825
- var Ci = [F.Forward, F.Reverse], mn = class {
826
- constructor() {
827
- this.x = new Oe(), this.y = new Oe();
828
- }
829
- isLocked() {
830
- return this.x.isLocked() && this.y.isLocked();
831
- }
832
- }, Pi = class extends fe {
833
- constructor(e) {
834
- super(e);
835
- const t = Pn(new mn());
836
- let n = null;
837
- this.signal = t, pe(() => {
838
- const { status: r } = e.dragOperation;
839
- if (!r.initialized) {
840
- n = null, t.value = new mn();
841
- return;
842
- }
843
- const { delta: i } = e.dragOperation.position;
844
- if (n) {
845
- const s = {
846
- x: gn(i.x, n.x),
847
- y: gn(i.y, n.y)
848
- }, a = t.peek();
849
- Gr(() => {
850
- for (const o of Cn)
851
- for (const d of Ci)
852
- s[o] === d && a[o].unlock(d);
853
- t.value = a;
854
- });
855
- }
856
- n = i;
857
- });
858
- }
859
- get current() {
860
- return this.signal.peek();
861
- }
677
+ q = F(null), nn = /* @__PURE__ */ new WeakMap(), rn = /* @__PURE__ */ new WeakMap(), R(q, 4, tn, en, an, nn), R(q, 4, $t, Qt, an, rn), I(q, an);
678
+ var on = [T.Forward, T.Reverse], sn = class {
679
+ constructor() {
680
+ this.x = new an(), this.y = new an();
681
+ }
682
+ isLocked() {
683
+ return this.x.isLocked() && this.y.isLocked();
684
+ }
685
+ }, cn = class extends y {
686
+ constructor(r) {
687
+ super(r);
688
+ let i = n(new sn()), a = null;
689
+ this.signal = i, t(() => {
690
+ let { status: t } = r.dragOperation;
691
+ if (!t.initialized) {
692
+ a = null, i.value = new sn();
693
+ return;
694
+ }
695
+ let { delta: n } = r.dragOperation.position;
696
+ if (a) {
697
+ let t = {
698
+ x: ln(n.x, a.x),
699
+ y: ln(n.y, a.y)
700
+ }, r = i.peek();
701
+ e(() => {
702
+ for (let e of l) for (let n of on) t[e] === n && r[e].unlock(n);
703
+ i.value = r;
704
+ });
705
+ }
706
+ a = n;
707
+ });
708
+ }
709
+ get current() {
710
+ return this.signal.peek();
711
+ }
862
712
  };
863
- function gn(e, t) {
864
- return Math.sign(e - t);
713
+ function ln(e, t) {
714
+ return Math.sign(e - t);
865
715
  }
866
- var Qn, mt, Ce, It, K, gt, qe = class extends (mt = St, Qn = [j], mt) {
867
- constructor(e) {
868
- super(e), S(this, It, A(Ce, 8, this, !1)), A(Ce, 11, this), S(this, K), S(this, gt, () => {
869
- if (!_(this, K))
870
- return;
871
- const { element: s, by: a } = _(this, K);
872
- a.y && (s.scrollTop += a.y), a.x && (s.scrollLeft += a.x);
873
- }), this.scroll = (s, a) => {
874
- var o;
875
- if (this.disabled)
876
- return !1;
877
- const d = this.getScrollableElements();
878
- if (!d)
879
- return $(this, K, void 0), !1;
880
- const { position: c } = this.manager.dragOperation, u = c?.current;
881
- if (u) {
882
- const { by: l } = s ?? {}, h = l ? {
883
- x: yn(l.x),
884
- y: yn(l.y)
885
- } : void 0, m = h ? void 0 : this.scrollIntentTracker.current;
886
- if (m?.isLocked())
887
- return !1;
888
- for (const g of d) {
889
- const w = $r(g, l);
890
- if (w.x || w.y) {
891
- const { speed: D, direction: k } = Ir(
892
- g,
893
- u,
894
- h,
895
- a?.acceleration,
896
- a?.threshold
897
- );
898
- if (m)
899
- for (const f of Cn)
900
- m[f].isLocked(k[f]) && (D[f] = 0, k[f] = 0);
901
- if (k.x || k.y) {
902
- const { x: f, y: v } = l ?? k, p = f * D.x, y = v * D.y;
903
- if (p || y) {
904
- const C = (o = _(this, K)) == null ? void 0 : o.by;
905
- if (this.autoScrolling && C && (C.x && !p || C.y && !y))
906
- continue;
907
- return $(this, K, {
908
- element: g,
909
- by: {
910
- x: p,
911
- y
912
- }
913
- }), Ne.schedule(_(this, gt)), !0;
914
- }
915
- }
916
- }
917
- }
918
- }
919
- return $(this, K, void 0), !1;
920
- };
921
- let t = null, n = null;
922
- const r = hn(() => {
923
- const { position: s, source: a } = e.dragOperation;
924
- if (!s)
925
- return null;
926
- const o = jr(
927
- Xe(a?.element),
928
- s.current
929
- );
930
- return o && (t = o), o ?? t;
931
- }), i = hn(() => {
932
- const s = r.value, { documentElement: a } = Et(s);
933
- if (!s || s === a) {
934
- const { target: o } = e.dragOperation, d = o?.element;
935
- if (d) {
936
- const c = an(d, {
937
- excludeElement: !1
938
- });
939
- return n = c, c;
940
- }
941
- }
942
- if (s) {
943
- const o = an(s, {
944
- excludeElement: !1
945
- });
946
- return this.autoScrolling && n && o.size < n?.size ? n : (n = o, o);
947
- }
948
- return n = null, null;
949
- }, Br);
950
- this.getScrollableElements = () => i.value, this.scrollIntentTracker = new Pi(e), this.destroy = e.monitor.addEventListener("dragmove", (s) => {
951
- this.disabled || s.defaultPrevented || !xt(e.dragOperation.activatorEvent) || !s.by || this.scroll({ by: s.by }) && s.preventDefault();
952
- });
953
- }
716
+ var un, dn, fn, pn, J, mn, hn = class extends (dn = h, un = [c], dn) {
717
+ constructor(e) {
718
+ super(e), B(this, pn, L(fn, 8, this, !1)), L(fn, 11, this), B(this, J), B(this, mn, () => {
719
+ if (!z(this, J)) return;
720
+ let { element: e, by: t } = z(this, J);
721
+ t.y && (e.scrollTop += t.y), t.x && (e.scrollLeft += t.x);
722
+ }), this.scroll = (e, t) => {
723
+ if (this.disabled) return !1;
724
+ let n = this.getScrollableElements();
725
+ if (!n) return V(this, J, void 0), !1;
726
+ let { position: r } = this.manager.dragOperation, i = r?.current;
727
+ if (i) {
728
+ let { by: r } = e ?? {}, a = r ? {
729
+ x: gn(r.x),
730
+ y: gn(r.y)
731
+ } : void 0, o = a ? void 0 : this.scrollIntentTracker.current;
732
+ if (o?.isLocked()) return !1;
733
+ for (let e of n) {
734
+ let n = ae(e, r);
735
+ if (n.x || n.y) {
736
+ let { speed: n, direction: s } = se(e, i, a, t?.acceleration, t?.threshold);
737
+ if (o) for (let e of l) o[e].isLocked(s[e]) && (n[e] = 0, s[e] = 0);
738
+ if (s.x || s.y) {
739
+ let { x: t, y: i } = r ?? s, a = t * n.x, o = i * n.y;
740
+ if (a || o) {
741
+ let t = z(this, J)?.by;
742
+ if (this.autoScrolling && t && (t.x && !a || t.y && !o)) continue;
743
+ return V(this, J, {
744
+ element: e,
745
+ by: {
746
+ x: a,
747
+ y: o
748
+ }
749
+ }), A.schedule(z(this, mn)), !0;
750
+ }
751
+ }
752
+ }
753
+ }
754
+ }
755
+ return V(this, J, void 0), !1;
756
+ };
757
+ let t = null, n = null, r = i(() => {
758
+ let { position: n, source: r } = e.dragOperation;
759
+ if (!n) return null;
760
+ let i = fe(D(r?.element), n.current);
761
+ return i && (t = i), i ?? t;
762
+ }), o = i(() => {
763
+ let t = r.value, { documentElement: i } = ue(t);
764
+ if (!t || t === i) {
765
+ let { target: t } = e.dragOperation, r = t?.element;
766
+ if (r) {
767
+ let e = ve(r, { excludeElement: !1 });
768
+ return n = e, e;
769
+ }
770
+ }
771
+ if (t) {
772
+ let e = ve(t, { excludeElement: !1 });
773
+ return this.autoScrolling && n && e.size < n?.size ? n : (n = e, e);
774
+ }
775
+ return n = null, null;
776
+ }, a);
777
+ this.getScrollableElements = () => o.value, this.scrollIntentTracker = new cn(e), this.destroy = e.monitor.addEventListener("dragmove", (t) => {
778
+ this.disabled || t.defaultPrevented || !Se(e.dragOperation.activatorEvent) || !t.by || this.scroll({ by: t.by }) && t.preventDefault();
779
+ });
780
+ }
954
781
  };
955
- Ce = me(mt);
956
- It = /* @__PURE__ */ new WeakMap();
957
- K = /* @__PURE__ */ new WeakMap();
958
- gt = /* @__PURE__ */ new WeakMap();
959
- R(Ce, 4, "autoScrolling", Qn, qe, It);
960
- ee(Ce, qe);
961
- function yn(e) {
962
- return e > 0 ? F.Forward : e < 0 ? F.Reverse : F.Idle;
782
+ fn = F(dn), pn = /* @__PURE__ */ new WeakMap(), J = /* @__PURE__ */ new WeakMap(), mn = /* @__PURE__ */ new WeakMap(), R(fn, 4, "autoScrolling", un, hn, pn), I(fn, hn);
783
+ function gn(e) {
784
+ return e > 0 ? T.Forward : e < 0 ? T.Reverse : T.Idle;
963
785
  }
964
- var Ti = class {
965
- constructor(e) {
966
- this.scheduler = e, this.pending = !1, this.tasks = /* @__PURE__ */ new Set(), this.resolvers = /* @__PURE__ */ new Set(), this.flush = () => {
967
- const { tasks: t, resolvers: n } = this;
968
- this.pending = !1, this.tasks = /* @__PURE__ */ new Set(), this.resolvers = /* @__PURE__ */ new Set();
969
- for (const r of t)
970
- r();
971
- for (const r of n)
972
- r();
973
- };
974
- }
975
- schedule(e) {
976
- return this.tasks.add(e), this.pending || (this.pending = !0, this.scheduler(this.flush)), new Promise((t) => this.resolvers.add(t));
977
- }
978
- }, $i = new Ti((e) => {
979
- typeof requestAnimationFrame == "function" ? requestAnimationFrame(e) : e();
980
- }), Ii = 10, yt = class extends fe {
981
- constructor(t, n) {
982
- super(t, n);
983
- const r = t.registry.plugins.get(qe);
984
- if (!r)
985
- throw new Error("AutoScroller plugin depends on Scroller plugin");
986
- this.destroy = pe(() => {
987
- var i, s, a;
988
- if (this.disabled)
989
- return;
990
- const { position: o, status: d } = t.dragOperation;
991
- if (d.dragging) {
992
- const c = {
993
- acceleration: (i = this.options) == null ? void 0 : i.acceleration,
994
- threshold: typeof ((s = this.options) == null ? void 0 : s.threshold) == "number" ? { x: this.options.threshold, y: this.options.threshold } : (a = this.options) == null ? void 0 : a.threshold
995
- };
996
- if (r.scroll(void 0, c)) {
997
- r.autoScrolling = !0;
998
- const l = setInterval(
999
- () => $i.schedule(
1000
- () => r.scroll(void 0, c)
1001
- ),
1002
- Ii
1003
- );
1004
- return () => {
1005
- clearInterval(l);
1006
- };
1007
- } else
1008
- r.autoScrolling = !1;
1009
- }
1010
- });
1011
- }
786
+ var _n = new class {
787
+ constructor(e) {
788
+ this.scheduler = e, this.pending = !1, this.tasks = /* @__PURE__ */ new Set(), this.resolvers = /* @__PURE__ */ new Set(), this.flush = () => {
789
+ let { tasks: e, resolvers: t } = this;
790
+ this.pending = !1, this.tasks = /* @__PURE__ */ new Set(), this.resolvers = /* @__PURE__ */ new Set();
791
+ for (let t of e) t();
792
+ for (let e of t) e();
793
+ };
794
+ }
795
+ schedule(e) {
796
+ return this.tasks.add(e), this.pending || (this.pending = !0, this.scheduler(this.flush)), new Promise((e) => this.resolvers.add(e));
797
+ }
798
+ }((e) => {
799
+ typeof requestAnimationFrame == "function" ? requestAnimationFrame(e) : e();
800
+ }), vn = 10, yn = class extends y {
801
+ constructor(e, n) {
802
+ super(e, n);
803
+ let r = e.registry.plugins.get(hn);
804
+ if (!r) throw Error("AutoScroller plugin depends on Scroller plugin");
805
+ this.destroy = t(() => {
806
+ if (this.disabled) return;
807
+ let { position: t, status: n } = e.dragOperation;
808
+ if (n.dragging) {
809
+ let e = {
810
+ acceleration: this.options?.acceleration,
811
+ threshold: typeof this.options?.threshold == "number" ? {
812
+ x: this.options.threshold,
813
+ y: this.options.threshold
814
+ } : this.options?.threshold
815
+ };
816
+ if (r.scroll(void 0, e)) {
817
+ r.autoScrolling = !0;
818
+ let t = setInterval(() => _n.schedule(() => r.scroll(void 0, e)), vn);
819
+ return () => {
820
+ clearInterval(t);
821
+ };
822
+ }
823
+ r.autoScrolling = !1;
824
+ }
825
+ });
826
+ }
1012
827
  };
1013
- yt.configure = Pe(yt);
1014
- var Zn = yt, bn = {
1015
- capture: !0,
1016
- passive: !0
1017
- }, Se, Mi = class extends St {
1018
- constructor(e) {
1019
- super(e), S(this, Se), this.handleScroll = () => {
1020
- _(this, Se) == null && $(this, Se, setTimeout(() => {
1021
- this.manager.collisionObserver.forceUpdate(!1), $(this, Se, void 0);
1022
- }, 50));
1023
- };
1024
- const { dragOperation: t } = this.manager;
1025
- this.destroy = pe(() => {
1026
- var n, r, i;
1027
- if (t.status.dragging) {
1028
- const a = (i = (r = (n = t.source) == null ? void 0 : n.element) == null ? void 0 : r.ownerDocument) != null ? i : document;
1029
- return a.addEventListener("scroll", this.handleScroll, bn), () => {
1030
- a.removeEventListener(
1031
- "scroll",
1032
- this.handleScroll,
1033
- bn
1034
- );
1035
- };
1036
- }
1037
- });
1038
- }
828
+ yn.configure = b(yn);
829
+ var bn = yn, xn = {
830
+ capture: !0,
831
+ passive: !0
832
+ }, Sn, Cn = class extends h {
833
+ constructor(e) {
834
+ super(e), B(this, Sn), this.handleScroll = () => {
835
+ z(this, Sn) ?? V(this, Sn, setTimeout(() => {
836
+ this.manager.collisionObserver.forceUpdate(!1), V(this, Sn, void 0);
837
+ }, 50));
838
+ };
839
+ let { dragOperation: n } = this.manager;
840
+ this.destroy = t(() => {
841
+ if (n.status.dragging) {
842
+ let e = n.source?.element?.ownerDocument ?? document;
843
+ return e.addEventListener("scroll", this.handleScroll, xn), () => {
844
+ e.removeEventListener("scroll", this.handleScroll, xn);
845
+ };
846
+ }
847
+ });
848
+ }
1039
849
  };
1040
- Se = /* @__PURE__ */ new WeakMap();
1041
- var Ri = "* { user-select: none !important; -webkit-user-select: none !important; }", Li = class extends fe {
1042
- constructor(e) {
1043
- super(e), this.manager = e;
1044
- const t = e.registry.plugins.get(
1045
- He
1046
- ), n = t?.register(Ri);
1047
- if (this.destroy = pe(() => {
1048
- const { dragOperation: r } = this.manager;
1049
- if (r.status.initialized)
1050
- return ot(), document.addEventListener("selectionchange", ot, {
1051
- capture: !0
1052
- }), () => {
1053
- document.removeEventListener("selectionchange", ot, {
1054
- capture: !0
1055
- });
1056
- };
1057
- }), n) {
1058
- const r = this.destroy.bind(this);
1059
- this.destroy = () => {
1060
- n(), r();
1061
- };
1062
- }
1063
- }
850
+ Sn = /* @__PURE__ */ new WeakMap();
851
+ var wn = "* { user-select: none !important; -webkit-user-select: none !important; }", Tn = class extends y {
852
+ constructor(e) {
853
+ super(e), this.manager = e;
854
+ let n = e.registry.plugins.get(bt)?.register(wn);
855
+ if (this.destroy = t(() => {
856
+ let { dragOperation: e } = this.manager;
857
+ if (e.status.initialized) return En(), document.addEventListener("selectionchange", En, { capture: !0 }), () => {
858
+ document.removeEventListener("selectionchange", En, { capture: !0 });
859
+ };
860
+ }), n) {
861
+ let e = this.destroy.bind(this);
862
+ this.destroy = () => {
863
+ n(), e();
864
+ };
865
+ }
866
+ }
1064
867
  };
1065
- function ot() {
1066
- var e;
1067
- (e = document.getSelection()) == null || e.removeAllRanges();
868
+ function En() {
869
+ var e;
870
+ (e = document.getSelection()) == null || e.removeAllRanges();
1068
871
  }
1069
- var Ee = Object.freeze({
1070
- offset: 10,
1071
- keyboardCodes: {
1072
- start: ["Space", "Enter"],
1073
- cancel: ["Escape"],
1074
- end: ["Space", "Enter", "Tab"],
1075
- up: ["ArrowUp"],
1076
- down: ["ArrowDown"],
1077
- left: ["ArrowLeft"],
1078
- right: ["ArrowRight"]
1079
- },
1080
- preventActivation(e, t) {
1081
- var n;
1082
- const r = (n = t.handle) != null ? n : t.element;
1083
- return e.target !== r;
1084
- }
1085
- }), ie, Be = class extends ze {
1086
- constructor(t, n) {
1087
- super(t), this.manager = t, this.options = n, S(this, ie, []), this.listeners = new Sn(), this.handleSourceKeyDown = (r, i, s) => {
1088
- if (this.disabled || r.defaultPrevented || !ce(r.target) || i.disabled)
1089
- return;
1090
- const {
1091
- keyboardCodes: a = Ee.keyboardCodes,
1092
- preventActivation: o = Ee.preventActivation
1093
- } = s ?? {};
1094
- a.start.includes(r.code) && this.manager.dragOperation.status.idle && (o?.(r, i) || this.handleStart(r, i, s));
1095
- };
1096
- }
1097
- bind(t, n = this.options) {
1098
- return pe(() => {
1099
- var i;
1100
- const s = (i = t.handle) != null ? i : t.element, a = (o) => {
1101
- xt(o) && this.handleSourceKeyDown(o, t, n);
1102
- };
1103
- if (s)
1104
- return s.addEventListener("keydown", a), () => {
1105
- s.removeEventListener("keydown", a);
1106
- };
1107
- });
1108
- }
1109
- handleStart(t, n, r) {
1110
- const { element: i } = n;
1111
- if (!i)
1112
- throw new Error("Source draggable does not have an associated element");
1113
- t.preventDefault(), t.stopImmediatePropagation(), Tr(i);
1114
- const { center: s } = new V(i);
1115
- if (this.manager.actions.start({
1116
- event: t,
1117
- coordinates: {
1118
- x: s.x,
1119
- y: s.y
1120
- },
1121
- source: n
1122
- }).signal.aborted) return this.cleanup();
1123
- this.sideEffects();
1124
- const o = Et(i), d = [
1125
- this.listeners.bind(o, [
1126
- {
1127
- type: "keydown",
1128
- listener: (c) => this.handleKeyDown(c, n, r),
1129
- options: { capture: !0 }
1130
- }
1131
- ])
1132
- ];
1133
- _(this, ie).push(...d);
1134
- }
1135
- handleKeyDown(t, n, r) {
1136
- const { keyboardCodes: i = Ee.keyboardCodes } = r ?? {};
1137
- if (re(t, [...i.end, ...i.cancel])) {
1138
- t.preventDefault();
1139
- const s = re(t, i.cancel);
1140
- this.handleEnd(t, s);
1141
- return;
1142
- }
1143
- re(t, i.up) ? this.handleMove("up", t) : re(t, i.down) && this.handleMove("down", t), re(t, i.left) ? this.handleMove("left", t) : re(t, i.right) && this.handleMove("right", t);
1144
- }
1145
- handleEnd(t, n) {
1146
- this.manager.actions.stop({
1147
- event: t,
1148
- canceled: n
1149
- }), this.cleanup();
1150
- }
1151
- handleMove(t, n) {
1152
- var r, i;
1153
- const { shape: s } = this.manager.dragOperation, a = n.shiftKey ? 5 : 1;
1154
- let o = {
1155
- x: 0,
1156
- y: 0
1157
- }, d = (i = (r = this.options) == null ? void 0 : r.offset) != null ? i : Ee.offset;
1158
- if (typeof d == "number" && (d = { x: d, y: d }), !!s) {
1159
- switch (t) {
1160
- case "up":
1161
- o = { x: 0, y: -d.y * a };
1162
- break;
1163
- case "down":
1164
- o = { x: 0, y: d.y * a };
1165
- break;
1166
- case "left":
1167
- o = { x: -d.x * a, y: 0 };
1168
- break;
1169
- case "right":
1170
- o = { x: d.x * a, y: 0 };
1171
- break;
1172
- }
1173
- (o.x || o.y) && (n.preventDefault(), this.manager.actions.move({
1174
- event: n,
1175
- by: o
1176
- }));
1177
- }
1178
- }
1179
- sideEffects() {
1180
- const t = this.manager.registry.plugins.get(Zn);
1181
- t?.disabled === !1 && (t.disable(), _(this, ie).push(() => {
1182
- t.enable();
1183
- }));
1184
- }
1185
- cleanup() {
1186
- _(this, ie).forEach((t) => t()), $(this, ie, []);
1187
- }
1188
- destroy() {
1189
- this.cleanup(), this.listeners.clear();
1190
- }
872
+ var Dn = Object.freeze({
873
+ offset: 10,
874
+ keyboardCodes: {
875
+ start: ["Space", "Enter"],
876
+ cancel: ["Escape"],
877
+ end: [
878
+ "Space",
879
+ "Enter",
880
+ "Tab"
881
+ ],
882
+ up: ["ArrowUp"],
883
+ down: ["ArrowDown"],
884
+ left: ["ArrowLeft"],
885
+ right: ["ArrowRight"]
886
+ },
887
+ preventActivation(e, t) {
888
+ let n = t.handle ?? t.element;
889
+ return e.target !== n;
890
+ }
891
+ }), On, kn = class extends ee {
892
+ constructor(e, t) {
893
+ super(e), this.manager = e, this.options = t, B(this, On, []), this.listeners = new te(), this.handleSourceKeyDown = (e, t, n) => {
894
+ if (this.disabled || e.defaultPrevented || !O(e.target) || t.disabled) return;
895
+ let { keyboardCodes: r = Dn.keyboardCodes, preventActivation: i = Dn.preventActivation } = n ?? {};
896
+ r.start.includes(e.code) && this.manager.dragOperation.status.idle && (i?.(e, t) || this.handleStart(e, t, n));
897
+ };
898
+ }
899
+ bind(e, n = this.options) {
900
+ return t(() => {
901
+ let t = e.handle ?? e.element, r = (t) => {
902
+ Se(t) && this.handleSourceKeyDown(t, e, n);
903
+ };
904
+ if (t) return t.addEventListener("keydown", r), () => {
905
+ t.removeEventListener("keydown", r);
906
+ };
907
+ });
908
+ }
909
+ handleStart(e, t, n) {
910
+ let { element: r } = t;
911
+ if (!r) throw Error("Source draggable does not have an associated element");
912
+ e.preventDefault(), e.stopImmediatePropagation(), ke(r);
913
+ let { center: i } = new C(r);
914
+ if (this.manager.actions.start({
915
+ event: e,
916
+ coordinates: {
917
+ x: i.x,
918
+ y: i.y
919
+ },
920
+ source: t
921
+ }).signal.aborted) return this.cleanup();
922
+ this.sideEffects();
923
+ let a = ue(r), o = [this.listeners.bind(a, [{
924
+ type: "keydown",
925
+ listener: (e) => this.handleKeyDown(e, t, n),
926
+ options: { capture: !0 }
927
+ }])];
928
+ z(this, On).push(...o);
929
+ }
930
+ handleKeyDown(e, t, n) {
931
+ let { keyboardCodes: r = Dn.keyboardCodes } = n ?? {};
932
+ if (jn(e, [...r.end, ...r.cancel])) {
933
+ e.preventDefault();
934
+ let t = jn(e, r.cancel);
935
+ this.handleEnd(e, t);
936
+ return;
937
+ }
938
+ jn(e, r.up) ? this.handleMove("up", e) : jn(e, r.down) && this.handleMove("down", e), jn(e, r.left) ? this.handleMove("left", e) : jn(e, r.right) && this.handleMove("right", e);
939
+ }
940
+ handleEnd(e, t) {
941
+ this.manager.actions.stop({
942
+ event: e,
943
+ canceled: t
944
+ }), this.cleanup();
945
+ }
946
+ handleMove(e, t) {
947
+ let { shape: n } = this.manager.dragOperation, r = t.shiftKey ? 5 : 1, i = {
948
+ x: 0,
949
+ y: 0
950
+ }, a = this.options?.offset ?? Dn.offset;
951
+ if (typeof a == "number" && (a = {
952
+ x: a,
953
+ y: a
954
+ }), n) {
955
+ switch (e) {
956
+ case "up":
957
+ i = {
958
+ x: 0,
959
+ y: -a.y * r
960
+ };
961
+ break;
962
+ case "down":
963
+ i = {
964
+ x: 0,
965
+ y: a.y * r
966
+ };
967
+ break;
968
+ case "left":
969
+ i = {
970
+ x: -a.x * r,
971
+ y: 0
972
+ };
973
+ break;
974
+ case "right": i = {
975
+ x: a.x * r,
976
+ y: 0
977
+ };
978
+ }
979
+ (i.x || i.y) && (t.preventDefault(), this.manager.actions.move({
980
+ event: t,
981
+ by: i
982
+ }));
983
+ }
984
+ }
985
+ sideEffects() {
986
+ let e = this.manager.registry.plugins.get(bn);
987
+ e?.disabled === !1 && (e.disable(), z(this, On).push(() => {
988
+ e.enable();
989
+ }));
990
+ }
991
+ cleanup() {
992
+ z(this, On).forEach((e) => e()), V(this, On, []);
993
+ }
994
+ destroy() {
995
+ this.cleanup(), this.listeners.clear();
996
+ }
1191
997
  };
1192
- ie = /* @__PURE__ */ new WeakMap();
1193
- Be.configure = Pe(Be);
1194
- Be.defaults = Ee;
1195
- var Wi = Be;
1196
- function re(e, t) {
1197
- return t.includes(e.code);
998
+ On = /* @__PURE__ */ new WeakMap(), kn.configure = b(kn), kn.defaults = Dn;
999
+ var An = kn;
1000
+ function jn(e, t) {
1001
+ return t.includes(e.code);
1198
1002
  }
1199
- var J, Fi = class extends wn {
1200
- constructor() {
1201
- super(...arguments), S(this, J);
1202
- }
1203
- onEvent(e) {
1204
- switch (e.type) {
1205
- case "pointerdown":
1206
- $(this, J, de(e));
1207
- break;
1208
- case "pointermove":
1209
- if (!_(this, J)) return;
1210
- const { x: t, y: n } = de(e), r = {
1211
- x: t - _(this, J).x,
1212
- y: n - _(this, J).y
1213
- }, { tolerance: i } = this.options;
1214
- if (i && dt(r, i)) {
1215
- this.abort();
1216
- return;
1217
- }
1218
- dt(r, this.options.value) && this.activate(e);
1219
- break;
1220
- case "pointerup":
1221
- this.abort();
1222
- break;
1223
- }
1224
- }
1225
- abort() {
1226
- $(this, J, void 0);
1227
- }
1228
- };
1229
- J = /* @__PURE__ */ new WeakMap();
1230
- var se, Q, zi = class extends wn {
1231
- constructor() {
1232
- super(...arguments), S(this, se), S(this, Q);
1233
- }
1234
- onEvent(e) {
1235
- switch (e.type) {
1236
- case "pointerdown":
1237
- $(this, Q, de(e)), $(this, se, setTimeout(
1238
- () => this.activate(e),
1239
- this.options.value
1240
- ));
1241
- break;
1242
- case "pointermove":
1243
- if (!_(this, Q)) return;
1244
- const { x: t, y: n } = de(e), r = {
1245
- x: t - _(this, Q).x,
1246
- y: n - _(this, Q).y
1247
- };
1248
- dt(r, this.options.tolerance) && this.abort();
1249
- break;
1250
- case "pointerup":
1251
- this.abort();
1252
- break;
1253
- }
1254
- }
1255
- abort() {
1256
- _(this, se) && (clearTimeout(_(this, se)), $(this, Q, void 0), $(this, se, void 0));
1257
- }
1003
+ var Y, Mn = class extends p {
1004
+ constructor() {
1005
+ super(...arguments), B(this, Y);
1006
+ }
1007
+ onEvent(e) {
1008
+ switch (e.type) {
1009
+ case "pointerdown":
1010
+ V(this, Y, E(e));
1011
+ break;
1012
+ case "pointermove":
1013
+ if (!z(this, Y)) return;
1014
+ let { x: t, y: n } = E(e), r = {
1015
+ x: t - z(this, Y).x,
1016
+ y: n - z(this, Y).y
1017
+ }, { tolerance: i } = this.options;
1018
+ if (i && f(r, i)) {
1019
+ this.abort();
1020
+ return;
1021
+ }
1022
+ f(r, this.options.value) && this.activate(e);
1023
+ break;
1024
+ case "pointerup": this.abort();
1025
+ }
1026
+ }
1027
+ abort() {
1028
+ V(this, Y, void 0);
1029
+ }
1258
1030
  };
1259
- se = /* @__PURE__ */ new WeakMap();
1260
- Q = /* @__PURE__ */ new WeakMap();
1261
- var ae = class {
1031
+ Y = /* @__PURE__ */ new WeakMap();
1032
+ var Nn, X, Pn = class extends p {
1033
+ constructor() {
1034
+ super(...arguments), B(this, Nn), B(this, X);
1035
+ }
1036
+ onEvent(e) {
1037
+ switch (e.type) {
1038
+ case "pointerdown":
1039
+ V(this, X, E(e)), V(this, Nn, setTimeout(() => this.activate(e), this.options.value));
1040
+ break;
1041
+ case "pointermove":
1042
+ if (!z(this, X)) return;
1043
+ let { x: t, y: n } = E(e), r = {
1044
+ x: t - z(this, X).x,
1045
+ y: n - z(this, X).y
1046
+ };
1047
+ f(r, this.options.tolerance) && this.abort();
1048
+ break;
1049
+ case "pointerup": this.abort();
1050
+ }
1051
+ }
1052
+ abort() {
1053
+ z(this, Nn) && (clearTimeout(z(this, Nn)), V(this, X, void 0), V(this, Nn, void 0));
1054
+ }
1262
1055
  };
1263
- ae.Delay = zi;
1264
- ae.Distance = Fi;
1265
- var bt = Object.freeze({
1266
- activationConstraints(e, t) {
1267
- var n;
1268
- const { pointerType: r, target: i } = e;
1269
- if (!(r === "mouse" && ce(i) && (t.handle === i || (n = t.handle) != null && n.contains(i))))
1270
- return r === "touch" ? [
1271
- new ae.Delay({ value: 250, tolerance: 5 })
1272
- ] : Rr(i) && !e.defaultPrevented ? [
1273
- new ae.Delay({ value: 200, tolerance: 0 })
1274
- ] : [
1275
- new ae.Delay({ value: 200, tolerance: 10 }),
1276
- new ae.Distance({ value: 5 })
1277
- ];
1278
- },
1279
- preventActivation(e, t) {
1280
- var n;
1281
- const { target: r } = e;
1282
- if (r === t.element || r === t.handle || !ce(r) || (n = t.handle) != null && n.contains(r)) return !1;
1283
- const i = Mr(r);
1284
- return i === t.element ? !1 : !!i;
1285
- }
1286
- }), oe, Ve = class extends ze {
1287
- constructor(t, n) {
1288
- super(t), this.manager = t, this.options = n, S(this, oe, /* @__PURE__ */ new Set()), this.listeners = new Sn(), this.latest = {
1289
- event: void 0,
1290
- coordinates: void 0
1291
- }, this.handleMove = () => {
1292
- const { event: r, coordinates: i } = this.latest;
1293
- !r || !i || this.manager.actions.move({ event: r, to: i });
1294
- }, this.handleCancel = this.handleCancel.bind(this), this.handlePointerUp = this.handlePointerUp.bind(this), this.handleKeyDown = this.handleKeyDown.bind(this);
1295
- }
1296
- activationConstraints(t, n, r = this.options) {
1297
- const { activationConstraints: i = bt.activationConstraints } = r ?? {};
1298
- return typeof i == "function" ? i(t, n) : i;
1299
- }
1300
- bind(t, n = this.options) {
1301
- return pe(() => {
1302
- var i;
1303
- const s = new AbortController(), { signal: a } = s, o = (c) => {
1304
- Xr(c) && this.handlePointerDown(c, t, n);
1305
- };
1306
- let d = [(i = t.handle) != null ? i : t.element];
1307
- n?.activatorElements && (Array.isArray(n.activatorElements) ? d = n.activatorElements : d = n.activatorElements(t));
1308
- for (const c of d)
1309
- c && (Ki(c.ownerDocument.defaultView), c.addEventListener("pointerdown", o, { signal: a }));
1310
- return () => s.abort();
1311
- });
1312
- }
1313
- handlePointerDown(t, n, r) {
1314
- if (this.disabled || !t.isPrimary || t.button !== 0 || !ce(t.target) || n.disabled || ji(t) || !this.manager.dragOperation.status.idle)
1315
- return;
1316
- const { preventActivation: i = bt.preventActivation } = r ?? {};
1317
- if (i?.(t, n))
1318
- return;
1319
- const { target: s } = t, a = En(s) && s.draggable && s.getAttribute("draggable") === "true", o = je(n.element), { x: d, y: c } = de(t);
1320
- this.initialCoordinates = {
1321
- x: d * o.scaleX + o.x,
1322
- y: c * o.scaleY + o.y
1323
- };
1324
- const u = this.activationConstraints(t, n, r);
1325
- t.sensor = this;
1326
- const l = new kr(
1327
- u,
1328
- (w) => this.handleStart(n, w)
1329
- );
1330
- l.signal.onabort = () => this.handleCancel(t), l.onEvent(t), this.controller = l;
1331
- const h = Pr(), m = this.listeners.bind(h, [
1332
- {
1333
- type: "pointermove",
1334
- listener: (w) => this.handlePointerMove(w, n)
1335
- },
1336
- {
1337
- type: "pointerup",
1338
- listener: this.handlePointerUp,
1339
- options: {
1340
- capture: !0
1341
- }
1342
- },
1343
- {
1344
- type: "pointercancel",
1345
- listener: this.handleCancel
1346
- },
1347
- {
1348
- // Cancel activation if there is a competing Drag and Drop interaction
1349
- type: "dragstart",
1350
- listener: a ? this.handleCancel : We,
1351
- options: {
1352
- capture: !0
1353
- }
1354
- }
1355
- ]), g = () => {
1356
- m(), this.initialCoordinates = void 0;
1357
- };
1358
- _(this, oe).add(g);
1359
- }
1360
- handlePointerMove(t, n) {
1361
- var r, i;
1362
- if (((r = this.controller) == null ? void 0 : r.activated) === !1) {
1363
- (i = this.controller) == null || i.onEvent(t);
1364
- return;
1365
- }
1366
- if (this.manager.dragOperation.status.dragging) {
1367
- const s = de(t), a = je(n.element);
1368
- s.x = s.x * a.scaleX + a.x, s.y = s.y * a.scaleY + a.y, t.preventDefault(), t.stopPropagation(), this.latest.event = t, this.latest.coordinates = s, Ne.schedule(this.handleMove);
1369
- }
1370
- }
1371
- handlePointerUp(t) {
1372
- const { status: n } = this.manager.dragOperation;
1373
- if (!n.idle) {
1374
- t.preventDefault(), t.stopPropagation();
1375
- const r = !n.initialized;
1376
- this.manager.actions.stop({ event: t, canceled: r });
1377
- }
1378
- this.cleanup();
1379
- }
1380
- handleKeyDown(t) {
1381
- t.key === "Escape" && (t.preventDefault(), this.handleCancel(t));
1382
- }
1383
- handleStart(t, n) {
1384
- const { manager: r, initialCoordinates: i } = this;
1385
- if (!i || !r.dragOperation.status.idle || n.defaultPrevented)
1386
- return;
1387
- if (r.actions.start({
1388
- coordinates: i,
1389
- event: n,
1390
- source: t
1391
- }).signal.aborted) return this.cleanup();
1392
- n.preventDefault();
1393
- const o = Et(n.target).body;
1394
- try {
1395
- o.setPointerCapture(n.pointerId);
1396
- } catch {
1397
- this.handleCancel(n);
1398
- return;
1399
- }
1400
- const d = ce(n.target) ? [n.target, o] : o, c = this.listeners.bind(d, [
1401
- {
1402
- // Prevent scrolling on touch devices
1403
- type: "touchmove",
1404
- listener: We,
1405
- options: {
1406
- passive: !1
1407
- }
1408
- },
1409
- {
1410
- // Prevent click events
1411
- type: "click",
1412
- listener: We
1413
- },
1414
- {
1415
- type: "contextmenu",
1416
- listener: We
1417
- },
1418
- {
1419
- type: "keydown",
1420
- listener: this.handleKeyDown
1421
- }
1422
- ]);
1423
- _(this, oe).add(c);
1424
- }
1425
- handleCancel(t) {
1426
- const { dragOperation: n } = this.manager;
1427
- n.status.initialized && this.manager.actions.stop({ event: t, canceled: !0 }), this.cleanup();
1428
- }
1429
- cleanup() {
1430
- const { controller: t } = this;
1431
- this.controller = void 0, t && !t.signal.aborted && t.abort(), this.latest = {
1432
- event: void 0,
1433
- coordinates: void 0
1434
- }, _(this, oe).forEach((n) => n()), _(this, oe).clear();
1435
- }
1436
- destroy() {
1437
- this.cleanup(), this.listeners.clear();
1438
- }
1056
+ Nn = /* @__PURE__ */ new WeakMap(), X = /* @__PURE__ */ new WeakMap();
1057
+ var Z = class {};
1058
+ Z.Delay = Pn, Z.Distance = Mn;
1059
+ var Fn = Object.freeze({
1060
+ activationConstraints(e, t) {
1061
+ let { pointerType: n, target: r } = e;
1062
+ if (!(n === "mouse" && O(r) && (t.handle === r || t.handle?.contains(r)))) return n === "touch" ? [new Z.Delay({
1063
+ value: 250,
1064
+ tolerance: 5
1065
+ })] : Te(r) && !e.defaultPrevented ? [new Z.Delay({
1066
+ value: 200,
1067
+ tolerance: 0
1068
+ })] : [new Z.Delay({
1069
+ value: 200,
1070
+ tolerance: 10
1071
+ }), new Z.Distance({ value: 5 })];
1072
+ },
1073
+ preventActivation(e, t) {
1074
+ let { target: n } = e;
1075
+ if (n === t.element || n === t.handle || !O(n) || t.handle?.contains(n)) return !1;
1076
+ let r = _e(n);
1077
+ return r !== t.element && !!r;
1078
+ }
1079
+ }), In, Ln = class extends ee {
1080
+ constructor(e, t) {
1081
+ super(e), this.manager = e, this.options = t, B(this, In, /* @__PURE__ */ new Set()), this.listeners = new te(), this.latest = {
1082
+ event: void 0,
1083
+ coordinates: void 0
1084
+ }, this.handleMove = () => {
1085
+ let { event: e, coordinates: t } = this.latest;
1086
+ !e || !t || this.manager.actions.move({
1087
+ event: e,
1088
+ to: t
1089
+ });
1090
+ }, this.handleCancel = this.handleCancel.bind(this), this.handlePointerUp = this.handlePointerUp.bind(this), this.handleKeyDown = this.handleKeyDown.bind(this);
1091
+ }
1092
+ activationConstraints(e, t, n = this.options) {
1093
+ let { activationConstraints: r = Fn.activationConstraints } = n ?? {};
1094
+ return typeof r == "function" ? r(e, t) : r;
1095
+ }
1096
+ bind(e, n = this.options) {
1097
+ return t(() => {
1098
+ let t = new AbortController(), { signal: r } = t, i = (t) => {
1099
+ Ce(t) && this.handlePointerDown(t, e, n);
1100
+ }, a = [e.handle ?? e.element];
1101
+ n?.activatorElements && (a = Array.isArray(n.activatorElements) ? n.activatorElements : n.activatorElements(e));
1102
+ for (let e of a) e && (Un(e.ownerDocument.defaultView), e.addEventListener("pointerdown", i, { signal: r }));
1103
+ return () => t.abort();
1104
+ });
1105
+ }
1106
+ handlePointerDown(e, t, n) {
1107
+ if (this.disabled || !e.isPrimary || e.button !== 0 || !O(e.target) || t.disabled || zn(e) || !this.manager.dragOperation.status.idle) return;
1108
+ let { preventActivation: r = Fn.preventActivation } = n ?? {};
1109
+ if (r?.(e, t)) return;
1110
+ let { target: i } = e, a = xe(i) && i.draggable && i.getAttribute("draggable") === "true", o = ge(t.element), { x: s, y: c } = E(e);
1111
+ this.initialCoordinates = {
1112
+ x: s * o.scaleX + o.x,
1113
+ y: c * o.scaleY + o.y
1114
+ };
1115
+ let l = this.activationConstraints(e, t, n);
1116
+ e.sensor = this;
1117
+ let u = new m(l, (e) => this.handleStart(t, e));
1118
+ u.signal.onabort = () => this.handleCancel(e), u.onEvent(e), this.controller = u;
1119
+ let d = de(), f = this.listeners.bind(d, [
1120
+ {
1121
+ type: "pointermove",
1122
+ listener: (e) => this.handlePointerMove(e, t)
1123
+ },
1124
+ {
1125
+ type: "pointerup",
1126
+ listener: this.handlePointerUp,
1127
+ options: { capture: !0 }
1128
+ },
1129
+ {
1130
+ type: "pointercancel",
1131
+ listener: this.handleCancel
1132
+ },
1133
+ {
1134
+ type: "dragstart",
1135
+ listener: a ? this.handleCancel : Bn,
1136
+ options: { capture: !0 }
1137
+ }
1138
+ ]);
1139
+ z(this, In).add(() => {
1140
+ f(), this.initialCoordinates = void 0;
1141
+ });
1142
+ }
1143
+ handlePointerMove(e, t) {
1144
+ var n;
1145
+ if (this.controller?.activated === !1) {
1146
+ (n = this.controller) == null || n.onEvent(e);
1147
+ return;
1148
+ }
1149
+ if (this.manager.dragOperation.status.dragging) {
1150
+ let n = E(e), r = ge(t.element);
1151
+ n.x = n.x * r.scaleX + r.x, n.y = n.y * r.scaleY + r.y, e.preventDefault(), e.stopPropagation(), this.latest.event = e, this.latest.coordinates = n, A.schedule(this.handleMove);
1152
+ }
1153
+ }
1154
+ handlePointerUp(e) {
1155
+ let { status: t } = this.manager.dragOperation;
1156
+ if (!t.idle) {
1157
+ e.preventDefault(), e.stopPropagation();
1158
+ let n = !t.initialized;
1159
+ this.manager.actions.stop({
1160
+ event: e,
1161
+ canceled: n
1162
+ });
1163
+ }
1164
+ this.cleanup();
1165
+ }
1166
+ handleKeyDown(e) {
1167
+ e.key === "Escape" && (e.preventDefault(), this.handleCancel(e));
1168
+ }
1169
+ handleStart(e, t) {
1170
+ let { manager: n, initialCoordinates: r } = this;
1171
+ if (!r || !n.dragOperation.status.idle || t.defaultPrevented) return;
1172
+ if (n.actions.start({
1173
+ coordinates: r,
1174
+ event: t,
1175
+ source: e
1176
+ }).signal.aborted) return this.cleanup();
1177
+ t.preventDefault();
1178
+ let i = ue(t.target).body;
1179
+ try {
1180
+ i.setPointerCapture(t.pointerId);
1181
+ } catch {
1182
+ this.handleCancel(t);
1183
+ return;
1184
+ }
1185
+ let a = O(t.target) ? [t.target, i] : i, o = this.listeners.bind(a, [
1186
+ {
1187
+ type: "touchmove",
1188
+ listener: Bn,
1189
+ options: { passive: !1 }
1190
+ },
1191
+ {
1192
+ type: "click",
1193
+ listener: Bn
1194
+ },
1195
+ {
1196
+ type: "contextmenu",
1197
+ listener: Bn
1198
+ },
1199
+ {
1200
+ type: "keydown",
1201
+ listener: this.handleKeyDown
1202
+ }
1203
+ ]);
1204
+ z(this, In).add(o);
1205
+ }
1206
+ handleCancel(e) {
1207
+ let { dragOperation: t } = this.manager;
1208
+ t.status.initialized && this.manager.actions.stop({
1209
+ event: e,
1210
+ canceled: !0
1211
+ }), this.cleanup();
1212
+ }
1213
+ cleanup() {
1214
+ let { controller: e } = this;
1215
+ this.controller = void 0, e && !e.signal.aborted && e.abort(), this.latest = {
1216
+ event: void 0,
1217
+ coordinates: void 0
1218
+ }, z(this, In).forEach((e) => e()), z(this, In).clear();
1219
+ }
1220
+ destroy() {
1221
+ this.cleanup(), this.listeners.clear();
1222
+ }
1439
1223
  };
1440
- oe = /* @__PURE__ */ new WeakMap();
1441
- Ve.configure = Pe(Ve);
1442
- Ve.defaults = bt;
1443
- var Ni = Ve;
1444
- function ji(e) {
1445
- return "sensor" in e;
1446
- }
1447
- function We(e) {
1448
- e.preventDefault();
1224
+ In = /* @__PURE__ */ new WeakMap(), Ln.configure = b(Ln), Ln.defaults = Fn;
1225
+ var Rn = Ln;
1226
+ function zn(e) {
1227
+ return "sensor" in e;
1449
1228
  }
1450
- function Xi() {
1229
+ function Bn(e) {
1230
+ e.preventDefault();
1451
1231
  }
1452
- var _n = /* @__PURE__ */ new WeakSet();
1453
- function Ki(e) {
1454
- !e || _n.has(e) || (e.addEventListener("touchmove", Xi, {
1455
- capture: !1,
1456
- passive: !1
1457
- }), _n.add(e));
1232
+ function Vn() {}
1233
+ var Hn = /* @__PURE__ */ new WeakSet();
1234
+ function Un(e) {
1235
+ !e || Hn.has(e) || (e.addEventListener("touchmove", Vn, {
1236
+ capture: !1,
1237
+ passive: !1
1238
+ }), Hn.add(e));
1458
1239
  }
1459
- var at = {
1460
- modifiers: [],
1461
- plugins: [ui, Zn, fi, Di, Li],
1462
- sensors: [Ni, Wi]
1463
- }, ts = class extends xr {
1464
- constructor(e = {}) {
1465
- const t = it(e.plugins, at.plugins), n = it(e.sensors, at.sensors), r = it(
1466
- e.modifiers,
1467
- at.modifiers
1468
- );
1469
- super(Dt(Ae({}, e), {
1470
- plugins: [Mi, qe, He, ...t],
1471
- sensors: n,
1472
- modifiers: r
1473
- }));
1474
- }
1475
- }, er, tr, _t, Y, Mt, Rt, Lt = class extends (_t = Or, tr = [j], er = [j], _t) {
1476
- constructor(e, t) {
1477
- var n = e, {
1478
- element: r,
1479
- effects: i = () => [],
1480
- handle: s
1481
- } = n, a = Mn(n, [
1482
- "element",
1483
- "effects",
1484
- "handle"
1485
- ]);
1486
- super(
1487
- Ae({
1488
- effects: () => [
1489
- ...i(),
1490
- () => {
1491
- var o, d;
1492
- const { manager: c } = this;
1493
- if (!c) return;
1494
- const l = ((d = (o = this.sensors) == null ? void 0 : o.map(Ar)) != null ? d : [
1495
- ...c.sensors
1496
- ]).map((h) => {
1497
- const m = h instanceof ze ? h : c.registry.register(h.plugin), g = h instanceof ze ? void 0 : h.options;
1498
- return m.bind(this, g);
1499
- });
1500
- return function() {
1501
- l.forEach((m) => m());
1502
- };
1503
- }
1504
- ]
1505
- }, a),
1506
- t
1507
- ), S(this, Mt, A(Y, 8, this)), A(Y, 11, this), S(this, Rt, A(Y, 12, this)), A(Y, 15, this), this.element = r, this.handle = s;
1508
- }
1509
- };
1510
- Y = me(_t);
1511
- Mt = /* @__PURE__ */ new WeakMap();
1512
- Rt = /* @__PURE__ */ new WeakMap();
1513
- R(Y, 4, "handle", tr, Lt, Mt);
1514
- R(Y, 4, "element", er, Lt, Rt);
1515
- ee(Y, Lt);
1516
- var nr, rr, wt, B, Wt, lt, ir, sr, ke, Ft, or = class extends (wt = Dr, rr = [j], nr = [j], wt) {
1517
- constructor(e, t) {
1518
- var n = e, { element: r, effects: i = () => [] } = n, s = Mn(n, ["element", "effects"]);
1519
- const { collisionDetector: a = qr } = s, o = (c) => {
1520
- const { manager: u, element: l } = this;
1521
- if (!l || c === null) {
1522
- this.shape = void 0;
1523
- return;
1524
- }
1525
- if (!u) return;
1526
- const h = new V(l), m = W(() => this.shape);
1527
- return h && m?.equals(h) ? m : (this.shape = h, h);
1528
- }, d = Pn(!1);
1529
- super(
1530
- Dt(Ae({}, s), {
1531
- collisionDetector: a,
1532
- effects: () => [
1533
- ...i(),
1534
- () => {
1535
- const { element: c, manager: u } = this;
1536
- if (!u) return;
1537
- const { dragOperation: l } = u, { source: h } = l;
1538
- d.value = !!(h && l.status.initialized && c && !this.disabled && this.accepts(h));
1539
- },
1540
- () => {
1541
- const { element: c } = this;
1542
- if (d.value && c) {
1543
- const u = new Lr(
1544
- c,
1545
- o
1546
- );
1547
- return () => {
1548
- u.disconnect(), this.shape = void 0;
1549
- };
1550
- }
1551
- },
1552
- () => {
1553
- var c;
1554
- if ((c = this.manager) != null && c.dragOperation.status.initialized)
1555
- return () => {
1556
- this.shape = void 0;
1557
- };
1558
- }
1559
- ]
1560
- }),
1561
- t
1562
- ), S(this, ke), S(this, Wt, A(B, 8, this)), A(B, 11, this), S(this, Ft, A(B, 12, this)), A(B, 15, this), this.element = r, this.refreshShape = () => o();
1563
- }
1564
- set element(e) {
1565
- $(this, ke, e, sr);
1566
- }
1567
- get element() {
1568
- var e;
1569
- return (e = this.proxy) != null ? e : _(this, ke, ir);
1570
- }
1240
+ var Wn = {
1241
+ modifiers: [],
1242
+ plugins: [
1243
+ at,
1244
+ bn,
1245
+ xt,
1246
+ Yt,
1247
+ Tn
1248
+ ],
1249
+ sensors: [Rn, An]
1250
+ }, Gn = class extends g {
1251
+ constructor(e = {}) {
1252
+ let t = S(e.plugins, Wn.plugins), n = S(e.sensors, Wn.sensors), r = S(e.modifiers, Wn.modifiers);
1253
+ super(He(P({}, e), {
1254
+ plugins: [
1255
+ Cn,
1256
+ hn,
1257
+ bt,
1258
+ ...t
1259
+ ],
1260
+ sensors: n,
1261
+ modifiers: r
1262
+ }));
1263
+ }
1264
+ }, Kn, qn, Jn, Q, Yn, Xn, Zn = class extends (Jn = _, qn = [c], Kn = [c], Jn) {
1265
+ constructor(e, t) {
1266
+ var n = e, { element: r, effects: i = () => [], handle: a } = n, o = We(n, [
1267
+ "element",
1268
+ "effects",
1269
+ "handle"
1270
+ ]);
1271
+ super(P({ effects: () => [...i(), () => {
1272
+ let { manager: e } = this;
1273
+ if (!e) return;
1274
+ let t = (this.sensors?.map(x) ?? [...e.sensors]).map((t) => {
1275
+ let n = t instanceof ee ? t : e.registry.register(t.plugin), r = t instanceof ee ? void 0 : t.options;
1276
+ return n.bind(this, r);
1277
+ });
1278
+ return function() {
1279
+ t.forEach((e) => e());
1280
+ };
1281
+ }] }, o), t), B(this, Yn, L(Q, 8, this)), L(Q, 11, this), B(this, Xn, L(Q, 12, this)), L(Q, 15, this), this.element = r, this.handle = a;
1282
+ }
1571
1283
  };
1572
- B = me(wt);
1573
- Wt = /* @__PURE__ */ new WeakMap();
1574
- ke = /* @__PURE__ */ new WeakSet();
1575
- Ft = /* @__PURE__ */ new WeakMap();
1576
- lt = R(B, 20, "#element", rr, ke, Wt), ir = lt.get, sr = lt.set;
1577
- R(B, 4, "proxy", nr, or, Ft);
1578
- ee(B, or);
1579
- export {
1580
- ui as Accessibility,
1581
- Zn as AutoScroller,
1582
- fi as Cursor,
1583
- ts as DragDropManager,
1584
- Lt as Draggable,
1585
- or as Droppable,
1586
- Di as Feedback,
1587
- Wi as KeyboardSensor,
1588
- ae as PointerActivationConstraints,
1589
- Ni as PointerSensor,
1590
- Li as PreventSelection,
1591
- Mi as ScrollListener,
1592
- qe as Scroller,
1593
- He as StyleInjector,
1594
- at as defaultPreset,
1595
- it as resolveCustomizable
1284
+ Q = F(Jn), Yn = /* @__PURE__ */ new WeakMap(), Xn = /* @__PURE__ */ new WeakMap(), R(Q, 4, "handle", qn, Zn, Yn), R(Q, 4, "element", Kn, Zn, Xn), I(Q, Zn);
1285
+ var Qn, $n, er, $, tr, nr, rr, ir, ar, or, sr = class extends (er = v, $n = [c], Qn = [c], er) {
1286
+ constructor(e, t) {
1287
+ var i = e, { element: a, effects: o = () => [] } = i, s = We(i, ["element", "effects"]);
1288
+ let { collisionDetector: c = Ne } = s, l = (e) => {
1289
+ let { manager: t, element: n } = this;
1290
+ if (!n || e === null) {
1291
+ this.shape = void 0;
1292
+ return;
1293
+ }
1294
+ if (!t) return;
1295
+ let i = new C(n), a = r(() => this.shape);
1296
+ return i && a?.equals(i) ? a : (this.shape = i, i);
1297
+ }, u = n(!1);
1298
+ super(He(P({}, s), {
1299
+ collisionDetector: c,
1300
+ effects: () => [
1301
+ ...o(),
1302
+ () => {
1303
+ let { element: e, manager: t } = this;
1304
+ if (!t) return;
1305
+ let { dragOperation: n } = t, { source: r } = n;
1306
+ u.value = !!(r && n.status.initialized && e && !this.disabled && this.accepts(r));
1307
+ },
1308
+ () => {
1309
+ let { element: e } = this;
1310
+ if (u.value && e) {
1311
+ let t = new ne(e, l);
1312
+ return () => {
1313
+ t.disconnect(), this.shape = void 0;
1314
+ };
1315
+ }
1316
+ },
1317
+ () => {
1318
+ if (this.manager?.dragOperation.status.initialized) return () => {
1319
+ this.shape = void 0;
1320
+ };
1321
+ }
1322
+ ]
1323
+ }), t), B(this, ar), B(this, tr, L($, 8, this)), L($, 11, this), B(this, or, L($, 12, this)), L($, 15, this), this.element = a, this.refreshShape = () => l();
1324
+ }
1325
+ set element(e) {
1326
+ V(this, ar, e, ir);
1327
+ }
1328
+ get element() {
1329
+ return this.proxy ?? z(this, ar, rr);
1330
+ }
1596
1331
  };
1332
+ $ = F(er), tr = /* @__PURE__ */ new WeakMap(), ar = /* @__PURE__ */ new WeakSet(), or = /* @__PURE__ */ new WeakMap(), nr = R($, 20, "#element", $n, ar, tr), rr = nr.get, ir = nr.set, R($, 4, "proxy", Qn, sr, or), I($, sr);
1333
+ //#endregion
1334
+ export { at as Accessibility, bn as AutoScroller, xt as Cursor, Gn as DragDropManager, Zn as Draggable, sr as Droppable, Yt as Feedback, An as KeyboardSensor, Z as PointerActivationConstraints, Rn as PointerSensor, Tn as PreventSelection, Cn as ScrollListener, hn as Scroller, bt as StyleInjector, Wn as defaultPreset, S as resolveCustomizable };