themelia-react-ui 1.0.1 → 2.0.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (640) hide show
  1. package/CHANGELOG.md +417 -0
  2. package/README.md +67 -16
  3. package/dist/{accordion-B-5Focs8.js → accordion-CQXVcd7Q.js} +15 -15
  4. package/dist/accordion-CQXVcd7Q.js.map +1 -0
  5. package/dist/action-menu-BTpyPWJ2.js +264 -0
  6. package/dist/action-menu-BTpyPWJ2.js.map +1 -0
  7. package/dist/affordance-geometry.generated-CCIXb2A1.js +68 -0
  8. package/dist/affordance-geometry.generated-CCIXb2A1.js.map +1 -0
  9. package/dist/{ai-artifact-B5tPpXnS.js → ai-artifact-2PQ2fItc.js} +206 -215
  10. package/dist/ai-artifact-2PQ2fItc.js.map +1 -0
  11. package/dist/{app-shell-at8Kt4l_.js → app-shell-BE_j8-AT.js} +11 -10
  12. package/dist/app-shell-BE_j8-AT.js.map +1 -0
  13. package/dist/{attachment-BO2R47wn.js → attachment-q69dlt5Y.js} +14 -14
  14. package/dist/attachment-q69dlt5Y.js.map +1 -0
  15. package/dist/auth-M3vGMgDR.js +723 -0
  16. package/dist/auth-M3vGMgDR.js.map +1 -0
  17. package/dist/{avatar-Bpzty83c.js → avatar-djdaaQ_s.js} +15 -13
  18. package/dist/avatar-djdaaQ_s.js.map +1 -0
  19. package/dist/{badge-BZXZT9wd.js → badge-0tATj-tW.js} +9 -9
  20. package/dist/badge-0tATj-tW.js.map +1 -0
  21. package/dist/base/accordion.js +1 -1
  22. package/dist/base/action-menu.js +1 -1
  23. package/dist/base/attachment.js +1 -1
  24. package/dist/base/avatar.js +1 -1
  25. package/dist/base/badge.js +1 -1
  26. package/dist/base/buttons.js +3 -2
  27. package/dist/base/cards.js +3 -3
  28. package/dist/base/carousel.js +33 -35
  29. package/dist/base/carousel.js.map +1 -1
  30. package/dist/base/cascader.js +246 -222
  31. package/dist/base/cascader.js.map +1 -1
  32. package/dist/base/chart.js +1 -1
  33. package/dist/base/choice-inputs.js +2 -2
  34. package/dist/base/code-block.js +1 -1
  35. package/dist/base/combobox.js +1 -1
  36. package/dist/base/command.js +1 -1
  37. package/dist/base/copyable.js +1 -1
  38. package/dist/base/date-pickers.js +3 -3
  39. package/dist/base/display.js +7 -7
  40. package/dist/base/feedback.js +4 -4
  41. package/dist/base/forms-numeric.js +1 -1
  42. package/dist/base/forms.js +2 -2
  43. package/dist/base/inline-edit.js +94 -92
  44. package/dist/base/inline-edit.js.map +1 -1
  45. package/dist/base/item.js +1 -1
  46. package/dist/base/media-gallery.js +1 -1
  47. package/dist/base/navigation.js +6 -6
  48. package/dist/base/popover-menu.js +1 -1
  49. package/dist/base/popover.js +1 -1
  50. package/dist/base/qr-code.js +7 -4
  51. package/dist/base/qr-code.js.map +1 -1
  52. package/dist/base/repeaters.js +53 -53
  53. package/dist/base/repeaters.js.map +1 -1
  54. package/dist/base/sheet.js +1 -1
  55. package/dist/base/sidebar.js +1 -1
  56. package/dist/base/signature-pad.js +84 -82
  57. package/dist/base/signature-pad.js.map +1 -1
  58. package/dist/base/skeleton.js +1 -1
  59. package/dist/base/spinner.js +1 -1
  60. package/dist/base/structure.js +1 -1
  61. package/dist/base/table.js +1 -1
  62. package/dist/base/text-inputs.js +2 -2
  63. package/dist/base/toaster.js +7 -7
  64. package/dist/base/toaster.js.map +1 -1
  65. package/dist/base/tree.js +1 -1
  66. package/dist/base/upload-queue.js +1 -1
  67. package/dist/base/upload.js +3 -3
  68. package/dist/base/value-inputs.js +1 -1
  69. package/dist/blocks/admin.js +228 -219
  70. package/dist/blocks/admin.js.map +1 -1
  71. package/dist/blocks/ai.js +182 -212
  72. package/dist/blocks/ai.js.map +1 -1
  73. package/dist/blocks/analytics/usage-card.js +1 -1
  74. package/dist/blocks/analytics.js +665 -620
  75. package/dist/blocks/analytics.js.map +1 -1
  76. package/dist/blocks/collaboration.js +2 -2
  77. package/dist/blocks/commerce/receipt.js +1 -1
  78. package/dist/blocks/commerce.js +1439 -1553
  79. package/dist/blocks/commerce.js.map +1 -1
  80. package/dist/blocks/data-display.js +1 -1
  81. package/dist/blocks/onboarding.js +6 -6
  82. package/dist/blocks/onboarding.js.map +1 -1
  83. package/dist/blocks/planning.js +88 -97
  84. package/dist/blocks/planning.js.map +1 -1
  85. package/dist/blocks/timelines.js +1 -1
  86. package/dist/{breadcrumbs-DdQ_I5ra.js → breadcrumbs-BG_FfMK4.js} +10 -9
  87. package/dist/breadcrumbs-BG_FfMK4.js.map +1 -0
  88. package/dist/button-BS3KDg00.js +674 -0
  89. package/dist/button-BS3KDg00.js.map +1 -0
  90. package/dist/{button-BS6l5JUw.js → button-R9CCoH7A.js} +3 -3
  91. package/dist/button-R9CCoH7A.js.map +1 -0
  92. package/dist/buttons-DS0ZIwJ_.js +99 -0
  93. package/dist/buttons-DS0ZIwJ_.js.map +1 -0
  94. package/dist/{cards-Cum56XOF.js → cards-QoJ4syG9.js} +12 -12
  95. package/dist/{cards-Cum56XOF.js.map → cards-QoJ4syG9.js.map} +1 -1
  96. package/dist/chart-DwYRKKc-.js +152 -0
  97. package/dist/chart-DwYRKKc-.js.map +1 -0
  98. package/dist/checkbox-B7ygNTYp.js +35 -0
  99. package/dist/checkbox-B7ygNTYp.js.map +1 -0
  100. package/dist/choice-inputs-DrJ17tpL.js +752 -0
  101. package/dist/choice-inputs-DrJ17tpL.js.map +1 -0
  102. package/dist/{code-block-xHKbAJDj.js → code-block-CD0B7M93.js} +27 -27
  103. package/dist/code-block-CD0B7M93.js.map +1 -0
  104. package/dist/{collapsible-DsnktFNv.js → collapsible-oMUGM4tr.js} +3 -3
  105. package/dist/{collapsible-DsnktFNv.js.map → collapsible-oMUGM4tr.js.map} +1 -1
  106. package/dist/{collection-content-C4fthJV_.js → collection-content-Ys-OZOkY.js} +3 -3
  107. package/dist/{collection-content-C4fthJV_.js.map → collection-content-Ys-OZOkY.js.map} +1 -1
  108. package/dist/combobox-6dvVny2q.js +272 -0
  109. package/dist/combobox-6dvVny2q.js.map +1 -0
  110. package/dist/combobox-CB7039j7.js +865 -0
  111. package/dist/combobox-CB7039j7.js.map +1 -0
  112. package/dist/{command-C0xe7u9B.js → command-kPMPjIxJ.js} +35 -31
  113. package/dist/command-kPMPjIxJ.js.map +1 -0
  114. package/dist/{comments-DviPLnwy.js → comments-You0Bzbr.js} +434 -409
  115. package/dist/comments-You0Bzbr.js.map +1 -0
  116. package/dist/components/base/accordion/accordion-variants.d.ts +3 -3
  117. package/dist/components/base/action-menu/action-menu.d.ts +7 -2
  118. package/dist/components/base/avatar/stacked-avatars.d.ts +5 -4
  119. package/dist/components/base/badge/badge.d.ts +1 -1
  120. package/dist/components/base/badge/badge.recipes.d.ts +4 -4
  121. package/dist/components/base/buttons/base-button.d.ts +7 -0
  122. package/dist/components/base/buttons/button-group.recipes.d.ts +2 -2
  123. package/dist/components/base/buttons/button.recipes.d.ts +10 -19
  124. package/dist/components/base/buttons/button.variants.d.ts +1 -0
  125. package/dist/components/base/buttons/loader-button.d.ts +3 -1
  126. package/dist/components/base/buttons/text-button.d.ts +2 -2
  127. package/dist/components/base/buttons/use-pending-button-focus.d.ts +3 -0
  128. package/dist/components/base/cards/card.recipes.d.ts +13 -5
  129. package/dist/components/base/cards/partials/card-primitives.d.ts +9 -4
  130. package/dist/components/base/cards/smart-card.types.d.ts +1 -1
  131. package/dist/components/base/carousel/carousel.d.ts +3 -1
  132. package/dist/components/base/chart/chart.d.ts +7 -7
  133. package/dist/components/base/choice-inputs/checkbox.d.ts +6 -7
  134. package/dist/components/base/choice-inputs/choice-types.d.ts +10 -1
  135. package/dist/components/base/choice-inputs/pill-radio-group.d.ts +9 -0
  136. package/dist/components/base/choice-inputs/select-popup.d.ts +9 -1
  137. package/dist/components/base/choice-inputs/switch-card.d.ts +1 -1
  138. package/dist/components/base/date-pickers/date-picker-field.d.ts +23 -0
  139. package/dist/components/base/date-pickers/date-picker.recipes.d.ts +5 -18
  140. package/dist/components/base/date-pickers/datepicker.types.d.ts +16 -3
  141. package/dist/components/base/display/alert-dialog.d.ts +8 -2
  142. package/dist/components/base/display/content-block.d.ts +4 -2
  143. package/dist/components/base/display/date-block.d.ts +1 -1
  144. package/dist/components/base/display/dialog.d.ts +12 -5
  145. package/dist/components/base/display/surface-title.d.ts +6 -1
  146. package/dist/components/base/feedback/alert.d.ts +1 -1
  147. package/dist/components/base/feedback/state-display.d.ts +5 -4
  148. package/dist/components/base/forms/form-field.d.ts +1 -0
  149. package/dist/components/base/forms/form-sizing.d.ts +35 -3
  150. package/dist/components/base/forms/workflow.d.ts +2 -0
  151. package/dist/components/base/forms-numeric/coordinates-input.d.ts +3 -0
  152. package/dist/components/base/forms-numeric/rounding-mode-select.d.ts +4 -1
  153. package/dist/components/base/navigation/dropdown-menu.d.ts +2 -2
  154. package/dist/components/base/navigation/language-switcher.d.ts +4 -1
  155. package/dist/components/base/navigation/overflow-tab-bar.d.ts +7 -0
  156. package/dist/components/base/navigation/page-header/page-header.d.ts +4 -1
  157. package/dist/components/base/navigation/tabs.d.ts +3 -5
  158. package/dist/components/base/popover/popover.recipes.d.ts +3 -3
  159. package/dist/components/base/qr-code/qr-code.d.ts +2 -0
  160. package/dist/components/base/sheet/index.d.ts +29 -1
  161. package/dist/components/base/sheet/sheet.d.ts +14 -5
  162. package/dist/components/base/spinner/spinner.d.ts +3 -2
  163. package/dist/components/base/structure/structure.types.d.ts +1 -1
  164. package/dist/components/base/table/index.d.ts +1 -1
  165. package/dist/components/base/text-inputs/clear-native-field.d.ts +2 -0
  166. package/dist/components/base/text-inputs/input-group.d.ts +2 -2
  167. package/dist/components/base/text-inputs/input-trailing-action.d.ts +3 -0
  168. package/dist/components/base/upload/upload.recipes.d.ts +11 -0
  169. package/dist/components/base/value-inputs/date-time-input.d.ts +4 -2
  170. package/dist/components/base/value-inputs/tags-input.d.ts +2 -0
  171. package/dist/components/blocks/admin/api-key-list/api-key-list.types.d.ts +1 -1
  172. package/dist/components/blocks/analytics/format-metric-value.d.ts +11 -1
  173. package/dist/components/blocks/analytics/index.d.ts +1 -1
  174. package/dist/components/blocks/analytics/types.d.ts +1 -1
  175. package/dist/components/blocks/analytics/use-metric-format-options.d.ts +3 -0
  176. package/dist/components/blocks/collaboration/message/message.recipes.d.ts +12 -0
  177. package/dist/components/blocks/commerce/address-card/address-card.d.ts +1 -1
  178. package/dist/components/blocks/commerce/address-card/types.d.ts +3 -1
  179. package/dist/components/blocks/commerce/booking-calendar-event-card/booking-calendar-event-card.d.ts +4 -0
  180. package/dist/components/blocks/commerce/booking-calendar-event-card/booking-calendar-event-card.types.d.ts +2 -2
  181. package/dist/components/blocks/commerce/discount-stack/types.d.ts +1 -1
  182. package/dist/components/blocks/commerce/inventory-section/types.d.ts +4 -1
  183. package/dist/components/blocks/commerce/loyalty-points/types.d.ts +1 -1
  184. package/dist/components/blocks/commerce/order-status/types.d.ts +4 -0
  185. package/dist/components/blocks/commerce/payment-method/payment-method.d.ts +1 -1
  186. package/dist/components/blocks/commerce/payment-method/types.d.ts +3 -1
  187. package/dist/components/blocks/commerce/seo-listing/seo-listing-card.d.ts +1 -1
  188. package/dist/components/blocks/commerce/seo-listing/types.d.ts +3 -1
  189. package/dist/components/blocks/commerce/vendor-profile/types.d.ts +4 -1
  190. package/dist/components/blocks/data-display/dense-info-card/dense-info.strings.d.ts +4 -1
  191. package/dist/components/blocks/data-display/empty-state/partials/illustrations/document-stack.d.ts +1 -4
  192. package/dist/components/blocks/data-display/empty-state/partials/illustrations/inbox-clean.d.ts +1 -4
  193. package/dist/components/blocks/data-display/empty-state/partials/illustrations/index.d.ts +3 -3
  194. package/dist/components/blocks/data-display/empty-state/partials/illustrations/stacked-cards.d.ts +1 -6
  195. package/dist/components/blocks/data-display/inline-stat/inline-stat.d.ts +4 -1
  196. package/dist/components/features/combobox/components/error-message.d.ts +1 -1
  197. package/dist/components/features/comments/hooks/use-attachment-upload.d.ts +5 -0
  198. package/dist/components/features/filters/facets/search-facet.d.ts +0 -12
  199. package/dist/components/features/filters/facets/tags-facet.d.ts +1 -1
  200. package/dist/components/features/global-search/partials/global-search-idle-state.d.ts +1 -1
  201. package/dist/components/features/media-library/media-library.d.ts +1 -1
  202. package/dist/components/features/media-library/media-library.types.d.ts +9 -1
  203. package/dist/components/features/media-library/partials/media-library-partials.d.ts +1 -1
  204. package/dist/components/features/overlays/alert-dialog.d.ts +1 -1
  205. package/dist/components/features/overlays/drawer.d.ts +1 -1
  206. package/dist/components/features/overlays/hooks/use-overlay-actions.d.ts +2 -2
  207. package/dist/components/features/overlays/hooks/use-overlay-visibility.d.ts +11 -4
  208. package/dist/components/features/overlays/hooks/use-pending-overlay-focus.d.ts +2 -0
  209. package/dist/components/features/overlays/overlay-tone-icon.d.ts +37 -0
  210. package/dist/components/features/overlays/overlays.types.d.ts +46 -22
  211. package/dist/components/features/products/components/product-variants-manager.d.ts +1 -1
  212. package/dist/components/features/products/partials/index.d.ts +1 -1
  213. package/dist/components/features/products/partials/product-metric-tile.d.ts +6 -0
  214. package/dist/components/features/products/partials/product-tone.d.ts +11 -1
  215. package/dist/components/features/products/products.types.d.ts +2 -1
  216. package/dist/components/features/rich-text-editor/rich-text-editor.recipes.d.ts +2 -1
  217. package/dist/components/features/table/data-table.d.ts +1 -1
  218. package/dist/components/features/table/partials/cell-renderers.d.ts +1 -1
  219. package/dist/components/features/table/table.types.d.ts +1 -1
  220. package/dist/components/features/theme-tweaker/theme-provider-settings.d.ts +3 -1
  221. package/dist/components/layout/auth/auth.types.d.ts +1 -0
  222. package/dist/components/layout/page/index.d.ts +1 -1
  223. package/dist/components/layout/page/page.d.ts +0 -1
  224. package/dist/components/layout/page/page.types.d.ts +62 -6
  225. package/dist/components/layout/page/partials/page-header-commands.d.ts +13 -0
  226. package/dist/components/layout/page/partials/page-header.d.ts +1 -1
  227. package/dist/components/layout/sidebar/sidebar.context.d.ts +1 -1
  228. package/dist/components/layout/sidebar/sidebar.types.d.ts +4 -0
  229. package/dist/components/layout/workspace/workspace.types.d.ts +3 -0
  230. package/dist/components/primitives/date.d.ts +16 -3
  231. package/dist/components/primitives/dimensions.d.ts +6 -0
  232. package/dist/components/primitives/duration.d.ts +6 -0
  233. package/dist/components/primitives/file-size.d.ts +6 -0
  234. package/dist/components/primitives/index.d.ts +1 -1
  235. package/dist/components/primitives/initials.d.ts +11 -2
  236. package/dist/components/primitives/link.d.ts +7 -0
  237. package/dist/components/primitives/money.d.ts +29 -7
  238. package/dist/components/primitives/number.d.ts +17 -0
  239. package/dist/components/primitives/value-typography.d.ts +54 -0
  240. package/dist/components/primitives/value.d.ts +31 -6
  241. package/dist/components/typography/heading.d.ts +13 -2
  242. package/dist/components/typography/index.d.ts +1 -1
  243. package/dist/components/typography/label.d.ts +3 -0
  244. package/dist/components/typography/running-text.d.ts +12 -0
  245. package/dist/components/typography/text-link.d.ts +23 -1
  246. package/dist/components/typography/text.d.ts +12 -0
  247. package/dist/components/typography/text.styles.d.ts +37 -5
  248. package/dist/components/ui/button.d.ts +1 -1
  249. package/dist/components/ui/checkbox.d.ts +5 -0
  250. package/dist/components/ui/overlay.recipes.d.ts +15 -2
  251. package/dist/components/ui/popover.d.ts +1 -1
  252. package/dist/components/ui/select.d.ts +3 -1
  253. package/dist/components/ui/sidebar.d.ts +1 -1
  254. package/dist/components/ui/switch.d.ts +5 -0
  255. package/dist/components/ui/table.d.ts +2 -1
  256. package/dist/container.recipes-D9t8MHR3.js +27 -0
  257. package/dist/container.recipes-D9t8MHR3.js.map +1 -0
  258. package/dist/{containers-6s-ucRQQ.js → containers-D_L4mTVb.js} +34 -57
  259. package/dist/containers-D_L4mTVb.js.map +1 -0
  260. package/dist/control-group-recipes-DBXmfh2E.js +21 -0
  261. package/dist/control-group-recipes-DBXmfh2E.js.map +1 -0
  262. package/dist/{copyable-B7SBXJMr.js → copyable-DDjTeW_j.js} +6 -6
  263. package/dist/{copyable-B7SBXJMr.js.map → copyable-DDjTeW_j.js.map} +1 -1
  264. package/dist/data-display-3xWQUnMA.js +1335 -0
  265. package/dist/data-display-3xWQUnMA.js.map +1 -0
  266. package/dist/date-picker-DrDFj8Lo.js +1527 -0
  267. package/dist/date-picker-DrDFj8Lo.js.map +1 -0
  268. package/dist/date-pickers-CnFCb0n2.js +174 -0
  269. package/dist/date-pickers-CnFCb0n2.js.map +1 -0
  270. package/dist/date-uf3z37Nm.js +144 -0
  271. package/dist/date-uf3z37Nm.js.map +1 -0
  272. package/dist/{display-CFM5myut.js → display-DrdvPwF0.js} +25 -25
  273. package/dist/display-DrdvPwF0.js.map +1 -0
  274. package/dist/{dropdown-menu-BlnyHr-9.js → dropdown-menu-CURh59jb.js} +22 -15
  275. package/dist/dropdown-menu-CURh59jb.js.map +1 -0
  276. package/dist/features/activities.js +177 -163
  277. package/dist/features/activities.js.map +1 -1
  278. package/dist/features/ai-chat.js +187 -183
  279. package/dist/features/ai-chat.js.map +1 -1
  280. package/dist/features/async-preview.js +9 -9
  281. package/dist/features/async-preview.js.map +1 -1
  282. package/dist/features/combobox.js +1 -1
  283. package/dist/features/comments.js +1 -1
  284. package/dist/features/data-view.js +25 -23
  285. package/dist/features/data-view.js.map +1 -1
  286. package/dist/features/email-composer/engine.js +1 -1
  287. package/dist/features/email-composer.js +353 -355
  288. package/dist/features/email-composer.js.map +1 -1
  289. package/dist/features/event-calendar.js +346 -354
  290. package/dist/features/event-calendar.js.map +1 -1
  291. package/dist/features/filters.js +1 -1
  292. package/dist/features/global-search.js +225 -227
  293. package/dist/features/global-search.js.map +1 -1
  294. package/dist/features/kanban.js +29 -29
  295. package/dist/features/kanban.js.map +1 -1
  296. package/dist/features/map.js +59 -58
  297. package/dist/features/map.js.map +1 -1
  298. package/dist/features/media-library.js +898 -900
  299. package/dist/features/media-library.js.map +1 -1
  300. package/dist/features/mentions.js +1 -1
  301. package/dist/features/overlays.js +1 -1
  302. package/dist/features/products.js +1412 -1444
  303. package/dist/features/products.js.map +1 -1
  304. package/dist/features/questionnaire.js +51 -49
  305. package/dist/features/questionnaire.js.map +1 -1
  306. package/dist/features/resource-assignment.js +103 -97
  307. package/dist/features/resource-assignment.js.map +1 -1
  308. package/dist/features/resource.js +13 -13
  309. package/dist/features/resource.js.map +1 -1
  310. package/dist/features/rich-text-editor.js +2 -2
  311. package/dist/features/schema-form.js +187 -183
  312. package/dist/features/schema-form.js.map +1 -1
  313. package/dist/features/suggestions.js +3 -3
  314. package/dist/features/sync.js +7 -7
  315. package/dist/features/sync.js.map +1 -1
  316. package/dist/features/table.js +1 -1
  317. package/dist/features/theme-tweaker.js +508 -503
  318. package/dist/features/theme-tweaker.js.map +1 -1
  319. package/dist/{feedback-DWUkgEjR.js → feedback-C7nR0UtT.js} +30 -31
  320. package/dist/feedback-C7nR0UtT.js.map +1 -0
  321. package/dist/field-affordance-recipes-CkOCdE2y.js +46 -0
  322. package/dist/field-affordance-recipes-CkOCdE2y.js.map +1 -0
  323. package/dist/{field-state-recipes-CBTRt9Bt.js → field-state-recipes-C-MFBX_8.js} +5 -5
  324. package/dist/field-state-recipes-C-MFBX_8.js.map +1 -0
  325. package/dist/{filters-BhsUtsxW.js → filters-Da-gNPsE.js} +760 -765
  326. package/dist/filters-Da-gNPsE.js.map +1 -0
  327. package/dist/{form-field-Bn7ZH1rA.js → form-field-VZRULhUK.js} +20 -12
  328. package/dist/form-field-VZRULhUK.js.map +1 -0
  329. package/dist/form-sizing-uWP4lzVh.js +126 -0
  330. package/dist/form-sizing-uWP4lzVh.js.map +1 -0
  331. package/dist/{forms-B7pzS25o.js → forms-DDeEnXSY.js} +38 -38
  332. package/dist/forms-DDeEnXSY.js.map +1 -0
  333. package/dist/forms-numeric-D3CO60IF.js +905 -0
  334. package/dist/forms-numeric-D3CO60IF.js.map +1 -0
  335. package/dist/{header-C59QZyxV.js → header-2ycNqGOR.js} +42 -37
  336. package/dist/header-2ycNqGOR.js.map +1 -0
  337. package/dist/{hooks-CM1Vp9Pe.js → hooks-DQ5SPwZw.js} +2 -2
  338. package/dist/{hooks-CM1Vp9Pe.js.map → hooks-DQ5SPwZw.js.map} +1 -1
  339. package/dist/{http-CLTVJc5I.js → http-CdEIHyQf.js} +2 -2
  340. package/dist/http-CdEIHyQf.js.map +1 -0
  341. package/dist/{icon-badge-Dv0RYQwj.js → icon-badge-DKlaKXoo.js} +4 -4
  342. package/dist/{icon-badge-Dv0RYQwj.js.map → icon-badge-DKlaKXoo.js.map} +1 -1
  343. package/dist/index.js +2 -2
  344. package/dist/input-BoLm9Hks.js +20 -0
  345. package/dist/input-BoLm9Hks.js.map +1 -0
  346. package/dist/input-DhQdBnV3.js +255 -0
  347. package/dist/input-DhQdBnV3.js.map +1 -0
  348. package/dist/item-xzh8Df65.js +264 -0
  349. package/dist/item-xzh8Df65.js.map +1 -0
  350. package/dist/layout/app-shell.js +1 -1
  351. package/dist/layout/auth.js +1 -1
  352. package/dist/layout/containers.js +1 -1
  353. package/dist/layout/header.js +1 -1
  354. package/dist/layout/hooks.js +1 -1
  355. package/dist/layout/navigation.js +1 -1
  356. package/dist/layout/page.js +1 -1
  357. package/dist/layout/settings.js +1 -1
  358. package/dist/layout/sidebar.js +2 -2
  359. package/dist/layout/workspace.js +1 -1
  360. package/dist/layout.js +10 -10
  361. package/dist/lib/affordance-geometry.generated.d.ts +46 -10
  362. package/dist/lib/control-group-recipes.d.ts +22 -0
  363. package/dist/lib/field-affordance-recipes.d.ts +70 -2
  364. package/dist/lib/field-state-recipes.d.ts +6 -4
  365. package/dist/lib/format.d.ts +9 -0
  366. package/dist/lib/money-format.d.ts +30 -0
  367. package/dist/lib/navigation-row-recipes.d.ts +3 -2
  368. package/dist/lib/overlay-anatomy-recipes.d.ts +2 -2
  369. package/dist/lib/surface-recipes.d.ts +13 -8
  370. package/dist/lib/token-merge.generated.d.ts +144 -2
  371. package/dist/lib/track-recipes.d.ts +1 -1
  372. package/dist/lib/ui-provider/provider.d.ts +7 -2
  373. package/dist/lib/ui-provider/store.d.ts +6 -2
  374. package/dist/lib/ui-provider/types.d.ts +9 -4
  375. package/dist/lib/use-prefers-reduced-motion.d.ts +2 -0
  376. package/dist/lib/utils.js +1 -1
  377. package/dist/media-gallery-DQUQ0m3O.js +201 -0
  378. package/dist/media-gallery-DQUQ0m3O.js.map +1 -0
  379. package/dist/{mentions-B8Ko-fhS.js → mentions-DwnO1hh4.js} +40 -39
  380. package/dist/{mentions-B8Ko-fhS.js.map → mentions-DwnO1hh4.js.map} +1 -1
  381. package/dist/message-YfFmbXNP.js +127 -0
  382. package/dist/message-YfFmbXNP.js.map +1 -0
  383. package/dist/{navigation-BUIn2Qxx.js → navigation-Cbp5V8gG.js} +27 -28
  384. package/dist/navigation-Cbp5V8gG.js.map +1 -0
  385. package/dist/navigation-Cs1npsPm.js +300 -0
  386. package/dist/navigation-Cs1npsPm.js.map +1 -0
  387. package/dist/{navigation-row-recipes-GVh11KiT.js → navigation-row-recipes-DlU-4QYO.js} +3 -3
  388. package/dist/navigation-row-recipes-DlU-4QYO.js.map +1 -0
  389. package/dist/number-CKRBYmZK.js +352 -0
  390. package/dist/number-CKRBYmZK.js.map +1 -0
  391. package/dist/overlay.recipes-CNO2S9V6.js +34 -0
  392. package/dist/overlay.recipes-CNO2S9V6.js.map +1 -0
  393. package/dist/overlays-DhZO7N-I.js +994 -0
  394. package/dist/overlays-DhZO7N-I.js.map +1 -0
  395. package/dist/page-C6R_8jFt.js +325 -0
  396. package/dist/page-C6R_8jFt.js.map +1 -0
  397. package/dist/{page-header-DQRa0jug.js → page-header-hUTzcRZX.js} +12 -12
  398. package/dist/page-header-hUTzcRZX.js.map +1 -0
  399. package/dist/{pagination-C29vvt3I.js → pagination-Cm0jqa3I.js} +21 -21
  400. package/dist/pagination-Cm0jqa3I.js.map +1 -0
  401. package/dist/{popover-CoLDEg19.js → popover-Dcv_9jxr.js} +23 -22
  402. package/dist/popover-Dcv_9jxr.js.map +1 -0
  403. package/dist/{popover-menu-GLIQTJTx.js → popover-menu-DnRFKnHP.js} +6 -6
  404. package/dist/{popover-menu-GLIQTJTx.js.map → popover-menu-DnRFKnHP.js.map} +1 -1
  405. package/dist/{popover.recipes-zgBhMlUu.js → popover.recipes-wmbvL8Ah.js} +5 -5
  406. package/dist/popover.recipes-wmbvL8Ah.js.map +1 -0
  407. package/dist/primitives-BHrwQXFC.js +379 -0
  408. package/dist/primitives-BHrwQXFC.js.map +1 -0
  409. package/dist/primitives.js +5 -5
  410. package/dist/{progress-BOe8l_FZ.js → progress-Br9WTFya.js} +12 -11
  411. package/dist/progress-Br9WTFya.js.map +1 -0
  412. package/dist/{receipt-BM8xsGFy.js → receipt-CV89q1fs.js} +8 -8
  413. package/dist/{receipt-BM8xsGFy.js.map → receipt-CV89q1fs.js.map} +1 -1
  414. package/dist/rich-text-editor-CF8QYt5p.js +574 -0
  415. package/dist/rich-text-editor-CF8QYt5p.js.map +1 -0
  416. package/dist/{rich-text-editor.recipes-DxvOE0Lp.js → rich-text-editor.recipes-CnrbmTS1.js} +35 -26
  417. package/dist/rich-text-editor.recipes-CnrbmTS1.js.map +1 -0
  418. package/dist/{rich-text-B7sBAdDG.js → rich-text-j-FGAeZW.js} +4 -4
  419. package/dist/{rich-text-B7sBAdDG.js.map → rich-text-j-FGAeZW.js.map} +1 -1
  420. package/dist/{scroll-area-BheMQ270.js → scroll-area-DRdr16Pt.js} +3 -3
  421. package/dist/scroll-area-DRdr16Pt.js.map +1 -0
  422. package/dist/{separator-DO0EbCEm.js → separator-BMEvwnSX.js} +2 -2
  423. package/dist/{separator-DO0EbCEm.js.map → separator-BMEvwnSX.js.map} +1 -1
  424. package/dist/{separator-Gk_WXH-l.js → separator-Do5GWDYi.js} +4 -4
  425. package/dist/separator-Do5GWDYi.js.map +1 -0
  426. package/dist/services/actions/action-adapters.d.ts +4 -0
  427. package/dist/services/actions.js +8 -3
  428. package/dist/services/actions.js.map +1 -1
  429. package/dist/{settings-BnCyyPOJ.js → settings-DHk0L2MF.js} +20 -19
  430. package/dist/settings-DHk0L2MF.js.map +1 -0
  431. package/dist/sheet-DRFNY1_D.js +207 -0
  432. package/dist/sheet-DRFNY1_D.js.map +1 -0
  433. package/dist/sidebar-Cb8WzOvE.js +511 -0
  434. package/dist/sidebar-Cb8WzOvE.js.map +1 -0
  435. package/dist/{sidebar-DPR7fmqN.js → sidebar-Crc9M9JV.js} +220 -201
  436. package/dist/sidebar-Crc9M9JV.js.map +1 -0
  437. package/dist/{skeleton-CmT1ppqb.js → skeleton-DVMXr15h.js} +5 -5
  438. package/dist/{skeleton-CmT1ppqb.js.map → skeleton-DVMXr15h.js.map} +1 -1
  439. package/dist/smart-card-Bek-TwUp.js +599 -0
  440. package/dist/smart-card-Bek-TwUp.js.map +1 -0
  441. package/dist/{spinner-BY9HbUEh.js → spinner-CmTAbEp0.js} +8 -6
  442. package/dist/spinner-CmTAbEp0.js.map +1 -0
  443. package/dist/{structure-MvKVq-oL.js → structure-hzCW-XsV.js} +3 -3
  444. package/dist/{structure-MvKVq-oL.js.map → structure-hzCW-XsV.js.map} +1 -1
  445. package/dist/{structure.recipes-Bqhf9oIh.js → structure.recipes-EPz60cU8.js} +37 -19
  446. package/dist/structure.recipes-EPz60cU8.js.map +1 -0
  447. package/dist/style.css +1 -1
  448. package/dist/surface-recipes-DOdoBXGm.js +28 -0
  449. package/dist/surface-recipes-DOdoBXGm.js.map +1 -0
  450. package/dist/table-D6zKeYQX.js +162 -0
  451. package/dist/table-D6zKeYQX.js.map +1 -0
  452. package/dist/table-Dn4XSrSB.js +1444 -0
  453. package/dist/table-Dn4XSrSB.js.map +1 -0
  454. package/dist/tabs-Dk8E_knt.js +189 -0
  455. package/dist/tabs-Dk8E_knt.js.map +1 -0
  456. package/dist/text-inputs-BFpku0Qd.js +331 -0
  457. package/dist/text-inputs-BFpku0Qd.js.map +1 -0
  458. package/dist/{text.styles-BwB7vAF2.js → text.styles-g4He6UIW.js} +26 -15
  459. package/dist/text.styles-g4He6UIW.js.map +1 -0
  460. package/dist/theme.css +90 -124
  461. package/dist/themes/green.css +24 -0
  462. package/dist/{timelines-B9ICkQcV.js → timelines-CxuAFIc2.js} +97 -104
  463. package/dist/timelines-CxuAFIc2.js.map +1 -0
  464. package/dist/track-recipes-CDcKmndW.js +10 -0
  465. package/dist/track-recipes-CDcKmndW.js.map +1 -0
  466. package/dist/{tree-BdWSaoFT.js → tree-BotPlyiD.js} +13 -13
  467. package/dist/{tree-BdWSaoFT.js.map → tree-BotPlyiD.js.map} +1 -1
  468. package/dist/typography/rich-text.js +1 -1
  469. package/dist/typography-CAr3dQhX.js +116 -0
  470. package/dist/typography-CAr3dQhX.js.map +1 -0
  471. package/dist/typography.js +2 -2
  472. package/dist/{ui-provider-CftIB6TY.js → ui-provider-D2_TeLqw.js} +22 -22
  473. package/dist/ui-provider-D2_TeLqw.js.map +1 -0
  474. package/dist/ui-provider.js +1 -1
  475. package/dist/{upload-D8Za5x_c.js → upload-B0WHW7ak.js} +278 -274
  476. package/dist/upload-B0WHW7ak.js.map +1 -0
  477. package/dist/{upload-queue-hIIYBLS7.js → upload-queue-BHZ_wBfd.js} +72 -75
  478. package/dist/upload-queue-BHZ_wBfd.js.map +1 -0
  479. package/dist/{usage-card-DnmnJ58D.js → usage-card-U0YBLTNT.js} +31 -33
  480. package/dist/usage-card-U0YBLTNT.js.map +1 -0
  481. package/dist/utils-Cospvlj1.js +4445 -0
  482. package/dist/utils-Cospvlj1.js.map +1 -0
  483. package/dist/value-inputs-CjfzGMsN.js +854 -0
  484. package/dist/value-inputs-CjfzGMsN.js.map +1 -0
  485. package/dist/value-typography-Deb3yQZg.js +116 -0
  486. package/dist/value-typography-Deb3yQZg.js.map +1 -0
  487. package/dist/{workspace-C1PZmk8L.js → workspace-YoFjXi6i.js} +97 -105
  488. package/dist/workspace-YoFjXi6i.js.map +1 -0
  489. package/docs/consumer-skill/SKILL.md +123 -119
  490. package/docs/consumer-skill/examples/analytics.tsx +34 -0
  491. package/docs/consumer-skill/examples/app-layout.tsx +42 -14
  492. package/docs/consumer-skill/examples/detail.tsx +20 -5
  493. package/docs/consumer-skill/examples/edit.tsx +1 -1
  494. package/docs/consumer-skill/examples/layout-blocks.tsx +20 -0
  495. package/docs/consumer-skill/examples/manifest.json +37 -3
  496. package/docs/consumer-skill/examples/scoped-directory.tsx +2 -2
  497. package/docs/consumer-skill/examples/website.tsx +56 -0
  498. package/docs/consumer-skill/references/analytics.md +70 -0
  499. package/docs/consumer-skill/references/composition.md +195 -9
  500. package/docs/consumer-skill/references/design-contract.md +33 -7
  501. package/docs/consumer-skill/references/discovery.md +80 -5
  502. package/docs/consumer-skill/references/installation.md +22 -0
  503. package/docs/consumer-skill/references/integration.md +46 -1
  504. package/docs/consumer-skill/references/public-api.json +2083 -237
  505. package/docs/consumer-skill/references/review.md +74 -6
  506. package/docs/consumer-skill/references/theming.md +59 -8
  507. package/docs/consumer-skill/references/tokens.json +180 -9
  508. package/docs/consumer-skill/references/workflows.md +34 -0
  509. package/docs/consumer-skill/scripts/check-composition.mjs +1 -1
  510. package/docs/consumer-skill/scripts/composition-policy.mjs +271 -18
  511. package/docs/consumer-skill/scripts/discovery.mjs +69 -9
  512. package/docs/consumer-skill/scripts/pin-button-defaults.mjs +95 -0
  513. package/docs/consumer-skill/scripts/surface-policy.mjs +44 -0
  514. package/package.json +11 -6
  515. package/dist/accordion-B-5Focs8.js.map +0 -1
  516. package/dist/action-menu-Cx3SdfbN.js +0 -265
  517. package/dist/action-menu-Cx3SdfbN.js.map +0 -1
  518. package/dist/affordance-geometry.generated-D8Jcfb0G.js +0 -32
  519. package/dist/affordance-geometry.generated-D8Jcfb0G.js.map +0 -1
  520. package/dist/ai-artifact-B5tPpXnS.js.map +0 -1
  521. package/dist/app-shell-at8Kt4l_.js.map +0 -1
  522. package/dist/attachment-BO2R47wn.js.map +0 -1
  523. package/dist/auth-OFwWSAap.js +0 -704
  524. package/dist/auth-OFwWSAap.js.map +0 -1
  525. package/dist/avatar-Bpzty83c.js.map +0 -1
  526. package/dist/badge-BZXZT9wd.js.map +0 -1
  527. package/dist/breadcrumbs-DdQ_I5ra.js.map +0 -1
  528. package/dist/button-BS6l5JUw.js.map +0 -1
  529. package/dist/buttons-Co6GavvM.js +0 -674
  530. package/dist/buttons-Co6GavvM.js.map +0 -1
  531. package/dist/chart-DVfcwQu6.js +0 -149
  532. package/dist/chart-DVfcwQu6.js.map +0 -1
  533. package/dist/checkbox-BavDRjF7.js +0 -34
  534. package/dist/checkbox-BavDRjF7.js.map +0 -1
  535. package/dist/choice-inputs-CC7XqPQO.js +0 -619
  536. package/dist/choice-inputs-CC7XqPQO.js.map +0 -1
  537. package/dist/code-block-xHKbAJDj.js.map +0 -1
  538. package/dist/combobox-DEbdr-3u.js +0 -273
  539. package/dist/combobox-DEbdr-3u.js.map +0 -1
  540. package/dist/combobox-xv3yJbzl.js +0 -850
  541. package/dist/combobox-xv3yJbzl.js.map +0 -1
  542. package/dist/command-C0xe7u9B.js.map +0 -1
  543. package/dist/comments-DviPLnwy.js.map +0 -1
  544. package/dist/containers-6s-ucRQQ.js.map +0 -1
  545. package/dist/data-display-cWIRdeaf.js +0 -1129
  546. package/dist/data-display-cWIRdeaf.js.map +0 -1
  547. package/dist/date-BFNMnrS5.js +0 -140
  548. package/dist/date-BFNMnrS5.js.map +0 -1
  549. package/dist/date-picker-CA6ogMQB.js +0 -1521
  550. package/dist/date-picker-CA6ogMQB.js.map +0 -1
  551. package/dist/date-pickers-BPIKLdsD.js +0 -224
  552. package/dist/date-pickers-BPIKLdsD.js.map +0 -1
  553. package/dist/display-CFM5myut.js.map +0 -1
  554. package/dist/dropdown-menu-BlnyHr-9.js.map +0 -1
  555. package/dist/feedback-DWUkgEjR.js.map +0 -1
  556. package/dist/field-affordance-recipes-IjzPrCTw.js +0 -17
  557. package/dist/field-affordance-recipes-IjzPrCTw.js.map +0 -1
  558. package/dist/field-state-recipes-CBTRt9Bt.js.map +0 -1
  559. package/dist/filters-BhsUtsxW.js.map +0 -1
  560. package/dist/form-field-Bn7ZH1rA.js.map +0 -1
  561. package/dist/form-sizing-BWs70_a2.js +0 -100
  562. package/dist/form-sizing-BWs70_a2.js.map +0 -1
  563. package/dist/format-iamDSqs2.js +0 -110
  564. package/dist/format-iamDSqs2.js.map +0 -1
  565. package/dist/forms-B7pzS25o.js.map +0 -1
  566. package/dist/forms-numeric-BUBxELBv.js +0 -867
  567. package/dist/forms-numeric-BUBxELBv.js.map +0 -1
  568. package/dist/header-C59QZyxV.js.map +0 -1
  569. package/dist/http-CLTVJc5I.js.map +0 -1
  570. package/dist/input-WwYQZJzG.js +0 -202
  571. package/dist/input-WwYQZJzG.js.map +0 -1
  572. package/dist/input-ci9fIgFH.js +0 -20
  573. package/dist/input-ci9fIgFH.js.map +0 -1
  574. package/dist/item-pJ0GsOiJ.js +0 -257
  575. package/dist/item-pJ0GsOiJ.js.map +0 -1
  576. package/dist/media-gallery-DhDRgnVZ.js +0 -200
  577. package/dist/media-gallery-DhDRgnVZ.js.map +0 -1
  578. package/dist/message-COsdEvXT.js +0 -108
  579. package/dist/message-COsdEvXT.js.map +0 -1
  580. package/dist/navigation-BUIn2Qxx.js.map +0 -1
  581. package/dist/navigation-DBEu4POU.js +0 -267
  582. package/dist/navigation-DBEu4POU.js.map +0 -1
  583. package/dist/navigation-row-recipes-GVh11KiT.js.map +0 -1
  584. package/dist/number-BNT_BIzJ.js +0 -269
  585. package/dist/number-BNT_BIzJ.js.map +0 -1
  586. package/dist/overlay.recipes-BxW5FIfK.js +0 -6
  587. package/dist/overlay.recipes-BxW5FIfK.js.map +0 -1
  588. package/dist/overlays-B11wZka6.js +0 -982
  589. package/dist/overlays-B11wZka6.js.map +0 -1
  590. package/dist/page-BV6ioQg3.js +0 -202
  591. package/dist/page-BV6ioQg3.js.map +0 -1
  592. package/dist/page-header-DQRa0jug.js.map +0 -1
  593. package/dist/pagination-C29vvt3I.js.map +0 -1
  594. package/dist/popover-CoLDEg19.js.map +0 -1
  595. package/dist/popover.recipes-zgBhMlUu.js.map +0 -1
  596. package/dist/primitives-DKPOGVpj.js +0 -330
  597. package/dist/primitives-DKPOGVpj.js.map +0 -1
  598. package/dist/progress-BOe8l_FZ.js.map +0 -1
  599. package/dist/rich-text-editor-CoVrTiSv.js +0 -575
  600. package/dist/rich-text-editor-CoVrTiSv.js.map +0 -1
  601. package/dist/rich-text-editor.recipes-DxvOE0Lp.js.map +0 -1
  602. package/dist/scroll-area-BheMQ270.js.map +0 -1
  603. package/dist/select-B2mb-qN2.js +0 -108
  604. package/dist/select-B2mb-qN2.js.map +0 -1
  605. package/dist/separator-Gk_WXH-l.js.map +0 -1
  606. package/dist/settings-BnCyyPOJ.js.map +0 -1
  607. package/dist/sheet-B-q914Ad.js +0 -205
  608. package/dist/sheet-B-q914Ad.js.map +0 -1
  609. package/dist/sidebar-C_2p3Tfj.js +0 -501
  610. package/dist/sidebar-C_2p3Tfj.js.map +0 -1
  611. package/dist/sidebar-DPR7fmqN.js.map +0 -1
  612. package/dist/smart-card-CYLn46e6.js +0 -578
  613. package/dist/smart-card-CYLn46e6.js.map +0 -1
  614. package/dist/spinner-BY9HbUEh.js.map +0 -1
  615. package/dist/structure.recipes-Bqhf9oIh.js.map +0 -1
  616. package/dist/surface-recipes-CQfRr-VL.js +0 -27
  617. package/dist/surface-recipes-CQfRr-VL.js.map +0 -1
  618. package/dist/table-BS39xnlq.js +0 -1424
  619. package/dist/table-BS39xnlq.js.map +0 -1
  620. package/dist/table-DnlAJ-xR.js +0 -146
  621. package/dist/table-DnlAJ-xR.js.map +0 -1
  622. package/dist/tabs-B5cNMWiP.js +0 -187
  623. package/dist/tabs-B5cNMWiP.js.map +0 -1
  624. package/dist/text-inputs-Dh9XGyiS.js +0 -331
  625. package/dist/text-inputs-Dh9XGyiS.js.map +0 -1
  626. package/dist/text.styles-BwB7vAF2.js.map +0 -1
  627. package/dist/timelines-B9ICkQcV.js.map +0 -1
  628. package/dist/track-recipes-LLPNVwFg.js +0 -10
  629. package/dist/track-recipes-LLPNVwFg.js.map +0 -1
  630. package/dist/typography-Cv8MT-82.js +0 -96
  631. package/dist/typography-Cv8MT-82.js.map +0 -1
  632. package/dist/ui-provider-CftIB6TY.js.map +0 -1
  633. package/dist/upload-D8Za5x_c.js.map +0 -1
  634. package/dist/upload-queue-hIIYBLS7.js.map +0 -1
  635. package/dist/usage-card-DnmnJ58D.js.map +0 -1
  636. package/dist/utils-C2EKeIw3.js +0 -72
  637. package/dist/utils-C2EKeIw3.js.map +0 -1
  638. package/dist/value-inputs-DX2dbxjj.js +0 -824
  639. package/dist/value-inputs-DX2dbxjj.js.map +0 -1
  640. package/dist/workspace-C1PZmk8L.js.map +0 -1
@@ -1,28 +1,32 @@
1
1
  "use client";
2
- import { useStrings as e } from "./lib/strings.js";
3
- import { t } from "./utils-C2EKeIw3.js";
4
- import { n } from "./buttons-Co6GavvM.js";
5
- import { a as r, n as i, r as a } from "./typography-Cv8MT-82.js";
6
- import { r as o, t as s } from "./structure-MvKVq-oL.js";
7
- import { n as c, t as l } from "./feedback-DWUkgEjR.js";
8
- import { _ as u, g as d, m as f } from "./primitives-DKPOGVpj.js";
9
- import { t as p } from "./number-BNT_BIzJ.js";
10
- import { n as m, t as h } from "./date-BFNMnrS5.js";
11
- import { t as g } from "./badge-BZXZT9wd.js";
12
- import { a as _, i as v, n as y, o as b, r as x, s as S, t as C } from "./command-C0xe7u9B.js";
13
- import { t as w } from "./input-WwYQZJzG.js";
14
- import { t as T } from "./date-picker-CA6ogMQB.js";
15
- import { a as E, c as D, i as O, o as k, r as A, t as j } from "./popover-CoLDEg19.js";
16
- import { i as M, r as N, t as P } from "./tabs-B5cNMWiP.js";
17
- import { t as F } from "./popover-menu-GLIQTJTx.js";
18
- import { t as I } from "./use-debounced-callback-Cx1h-hdv.js";
19
- import { t as L } from "./use-debounce-DZ_1ZBPa.js";
20
- import R, { Component as ee, createContext as te, useCallback as z, useContext as ne, useEffect as B, useId as re, useMemo as V, useRef as H, useState as U } from "react";
21
- import { Fragment as W, jsx as G, jsxs as K } from "react/jsx-runtime";
22
- import { CalendarIcon as ie, Check as ae, ChevronDown as oe, ChevronLeft as se, ChevronsUpDown as ce, Filter as le, Loader2 as ue, Plus as de, X as q } from "lucide-react";
23
- import { format as fe, isValid as J, parse as pe } from "date-fns";
2
+ import { _ as e, s as t } from "./ui-provider-D2_TeLqw.js";
3
+ import { useStrings as n } from "./lib/strings.js";
4
+ import { t as r } from "./utils-Cospvlj1.js";
5
+ import { a as i, i as a, s as o } from "./typography-CAr3dQhX.js";
6
+ import { t as s } from "./button-BS3KDg00.js";
7
+ import { r as c, t as l } from "./structure-hzCW-XsV.js";
8
+ import { n as u, t as d } from "./feedback-C7nR0UtT.js";
9
+ import { _ as f, g as p, m } from "./primitives-BHrwQXFC.js";
10
+ import { t as h } from "./number-CKRBYmZK.js";
11
+ import { n as g, t as _ } from "./date-uf3z37Nm.js";
12
+ import { t as v } from "./badge-0tATj-tW.js";
13
+ import { t as y } from "./field-affordance-recipes-CkOCdE2y.js";
14
+ import { a as b, i as x, n as S, o as C, r as w, s as T, t as E } from "./command-kPMPjIxJ.js";
15
+ import { d as D, g as O, u as k } from "./form-sizing-uWP4lzVh.js";
16
+ import { t as A } from "./input-DhQdBnV3.js";
17
+ import { t as j } from "./date-picker-DrDFj8Lo.js";
18
+ import { a as M, c as N, i as P, o as F, r as I, t as ee } from "./popover-Dcv_9jxr.js";
19
+ import { n as L, r as R, t as te } from "./control-group-recipes-DBXmfh2E.js";
20
+ import { i as z, r as B, t as ne } from "./tabs-Dk8E_knt.js";
21
+ import { t as re } from "./popover-menu-DnRFKnHP.js";
22
+ import { t as ie } from "./use-debounced-callback-Cx1h-hdv.js";
23
+ import { t as ae } from "./use-debounce-DZ_1ZBPa.js";
24
+ import V, { Component as oe, createContext as se, useCallback as H, useContext as ce, useEffect as U, useId as le, useMemo as W, useRef as G, useState as K } from "react";
25
+ import { Fragment as q, jsx as J, jsxs as Y } from "react/jsx-runtime";
26
+ import { CalendarIcon as ue, Check as de, ChevronDown as fe, ChevronLeft as pe, ChevronsUpDown as me, Filter as he, Loader2 as ge, Plus as _e, X as ve } from "lucide-react";
27
+ import { format as ye, isValid as be, parse as xe } from "date-fns";
24
28
  //#region src/components/features/filters/filters.strings.ts
25
- var me = {
29
+ var Se = {
26
30
  loading: "Loading",
27
31
  loadingOptions: "Loading {filterLabel} options...",
28
32
  addFilter: "Add filter",
@@ -101,20 +105,20 @@ var me = {
101
105
  invalidFormat: "Invalid format"
102
106
  }
103
107
  };
104
- function Y(e, t) {
108
+ function X(e, t) {
105
109
  return e.replace(/{(\w+)}/g, (e, n) => String(t[n] ?? e)).replace(/:(\w+)/g, (e, n) => t[n] === void 0 ? e : String(t[n]));
106
110
  }
107
- function he(e, t, n) {
111
+ function Ce(e, t, n) {
108
112
  let r = t.split("."), i = e;
109
113
  for (let e of r) {
110
114
  if (typeof i != "object" || !i) return t;
111
115
  i = i[e];
112
116
  }
113
- return typeof i == "string" ? n ? Y(i, n) : i : t;
117
+ return typeof i == "string" ? n ? X(i, n) : i : t;
114
118
  }
115
119
  //#endregion
116
120
  //#region src/components/features/filters/filters.types.ts
117
- var ge = "h-control", X = {
121
+ var Z = {
118
122
  SELECT: "select",
119
123
  MULTI_SELECT: "multi_select",
120
124
  ASYNC_SELECT: "async_select",
@@ -122,7 +126,7 @@ var ge = "h-control", X = {
122
126
  RANGE: "range",
123
127
  DATE: "date",
124
128
  TAGS: "tags"
125
- }, Z = {
129
+ }, Q = {
126
130
  EQUALS: "equals",
127
131
  CONTAINS: "contains",
128
132
  IN: "in",
@@ -139,112 +143,112 @@ var ge = "h-control", X = {
139
143
  HAS_ANY: "has_any",
140
144
  HAS_ALL: "has_all"
141
145
  };
142
- function _e(e) {
146
+ function we(e) {
143
147
  return e;
144
148
  }
145
149
  //#endregion
146
150
  //#region src/components/features/filters/operator-options.ts
147
- function ve(e) {
151
+ function Te(e) {
148
152
  return [
149
153
  {
150
154
  label: e.contains,
151
- value: Z.CONTAINS
155
+ value: Q.CONTAINS
152
156
  },
153
157
  {
154
158
  label: e.equals,
155
- value: Z.EQUALS
159
+ value: Q.EQUALS
156
160
  },
157
161
  {
158
162
  label: e.notContains,
159
- value: Z.NOT
163
+ value: Q.NOT
160
164
  }
161
165
  ];
162
166
  }
163
- function ye(e) {
167
+ function Ee(e) {
164
168
  return [{
165
169
  label: e.is,
166
- value: Z.EQUALS
170
+ value: Q.EQUALS
167
171
  }, {
168
172
  label: e.isNot,
169
- value: Z.NOT
173
+ value: Q.NOT
170
174
  }];
171
175
  }
172
- function be(e) {
176
+ function De(e) {
173
177
  return [
174
178
  {
175
179
  label: e.equals,
176
- value: Z.EQUALS
180
+ value: Q.EQUALS
177
181
  },
178
182
  {
179
183
  label: e.greaterThan,
180
- value: Z.GT
184
+ value: Q.GT
181
185
  },
182
186
  {
183
187
  label: e.lessThan,
184
- value: Z.LT
188
+ value: Q.LT
185
189
  }
186
190
  ];
187
191
  }
188
- function xe(e) {
192
+ function Oe(e) {
189
193
  return [
190
194
  {
191
195
  label: e.before,
192
- value: Z.BEFORE
196
+ value: Q.BEFORE
193
197
  },
194
198
  {
195
199
  label: e.after,
196
- value: Z.AFTER
200
+ value: Q.AFTER
197
201
  },
198
202
  {
199
203
  label: e.between,
200
- value: Z.BETWEEN
204
+ value: Q.BETWEEN
201
205
  }
202
206
  ];
203
207
  }
204
- function Se(e) {
208
+ function ke(e) {
205
209
  return [{
206
210
  label: e.equals,
207
- value: Z.EQUALS
211
+ value: Q.EQUALS
208
212
  }];
209
213
  }
210
- function Ce(e, t) {
214
+ function Ae(e, t) {
211
215
  switch (e) {
212
- case X.SEARCH: return ve(t);
213
- case X.TAGS: return [
216
+ case Z.SEARCH: return Te(t);
217
+ case Z.TAGS: return [
214
218
  {
215
219
  label: t.has,
216
- value: Z.HAS
220
+ value: Q.HAS
217
221
  },
218
222
  {
219
223
  label: t.hasAny,
220
- value: Z.HAS_ANY
224
+ value: Q.HAS_ANY
221
225
  },
222
226
  {
223
227
  label: t.hasAll,
224
- value: Z.HAS_ALL
228
+ value: Q.HAS_ALL
225
229
  }
226
230
  ];
227
- case X.SELECT:
228
- case X.ASYNC_SELECT: return ye(t);
229
- case X.RANGE: return be(t);
230
- case X.DATE: return xe(t);
231
- default: return ve(t);
231
+ case Z.SELECT:
232
+ case Z.ASYNC_SELECT: return Ee(t);
233
+ case Z.RANGE: return De(t);
234
+ case Z.DATE: return Oe(t);
235
+ default: return Te(t);
232
236
  }
233
237
  }
234
- function we(e) {
238
+ function je(e) {
235
239
  switch (e) {
236
- case X.SEARCH: return Z.CONTAINS;
237
- case X.TAGS: return Z.HAS;
238
- case X.SELECT:
239
- case X.ASYNC_SELECT: return Z.EQUALS;
240
- case X.RANGE: return Z.EQUALS;
241
- case X.DATE: return Z.BEFORE;
242
- default: return Z.EQUALS;
240
+ case Z.SEARCH: return Q.CONTAINS;
241
+ case Z.TAGS: return Q.HAS;
242
+ case Z.SELECT:
243
+ case Z.ASYNC_SELECT: return Q.EQUALS;
244
+ case Z.RANGE: return Q.EQUALS;
245
+ case Z.DATE: return Q.BEFORE;
246
+ default: return Q.EQUALS;
243
247
  }
244
248
  }
245
249
  //#endregion
246
250
  //#region src/components/features/filters/utils/filter-utils.ts
247
- function Te(e, t, n) {
251
+ function Me(e, t, n) {
248
252
  if (e.type === "date" && Array.isArray(t) && t.every((e) => typeof e == "string")) return !0;
249
253
  if (e.validation?.required && (!t || Array.isArray(t) && t.length === 0)) return n("validation.required");
250
254
  if (typeof t == "number") {
@@ -260,51 +264,51 @@ function Te(e, t, n) {
260
264
  }
261
265
  //#endregion
262
266
  //#region src/components/features/filters/filter-context.tsx
263
- var Ee = te(void 0);
264
- function De({ children: t, filters: n, activeFilters: r, onFilterChange: i, navigating: a = !1, strings: o, onError: s }) {
265
- let c = H(n), l = H(i), u = H(s);
267
+ var Ne = se(void 0);
268
+ function Pe({ children: e, filters: t, activeFilters: r, onFilterChange: i, navigating: a = !1, strings: o, onError: s }) {
269
+ let c = G(t), l = G(i), u = G(s);
266
270
  u.current = s;
267
- let [d, f] = U(0), p = H(/* @__PURE__ */ new Map()), m = V(() => {
271
+ let [d, f] = K(0), p = G(/* @__PURE__ */ new Map()), m = W(() => {
268
272
  let e = /* @__PURE__ */ new Map();
269
- for (let t of n) {
270
- if (t.type !== X.ASYNC_SELECT) continue;
271
- let n = t.asyncConfig?.fetcher, r = t.asyncConfig?.mapToOption, i = t.asyncConfig?.limit ?? 10, a = p.current.get(t.key), o = a && a.fetcher === n && a.mapToOption === r;
272
- e.set(t.key, o && a.limit === i ? a : {
273
- fetcher: n,
273
+ for (let n of t) {
274
+ if (n.type !== Z.ASYNC_SELECT) continue;
275
+ let t = n.asyncConfig?.fetcher, r = n.asyncConfig?.mapToOption, i = n.asyncConfig?.limit ?? 10, a = p.current.get(n.key), o = a && a.fetcher === t && a.mapToOption === r;
276
+ e.set(n.key, o && a.limit === i ? a : {
277
+ fetcher: t,
274
278
  mapToOption: r,
275
279
  limit: i,
276
280
  options: o ? a.options : /* @__PURE__ */ new Map()
277
281
  });
278
282
  }
279
283
  return e.size === p.current.size && [...e].every(([e, t]) => p.current.get(e) === t) ? p.current : (p.current = e, e);
280
- }, [n]), h = JSON.stringify(r.filter((e) => m.has(e.key)).map(({ key: e, value: t }) => [e, t])), g = e(me, o);
281
- B(() => {
282
- c.current = n;
283
- }, [n]), B(() => {
284
+ }, [t]), h = JSON.stringify(r.filter((e) => m.has(e.key)).map(({ key: e, value: t }) => [e, t])), g = n(Se, o);
285
+ U(() => {
286
+ c.current = t;
287
+ }, [t]), U(() => {
284
288
  l.current = i;
285
289
  }, [i]);
286
- let _ = z((e) => {
290
+ let _ = H((e) => {
287
291
  let t = [...r, e];
288
292
  l.current(t);
289
- }, [r]), v = z((e) => {
293
+ }, [r]), v = H((e) => {
290
294
  let t = r.filter((t) => t.id !== e && t.key !== e);
291
295
  l.current(t);
292
- }, [r]), y = z((e, t) => {
296
+ }, [r]), y = H((e, t) => {
293
297
  let n = r.map((n) => n.id === e || n.key === e ? {
294
298
  ...n,
295
299
  ...t
296
300
  } : n);
297
301
  l.current(n);
298
- }, [r]), b = z(() => {
302
+ }, [r]), b = H(() => {
299
303
  l.current([]);
300
- }, []), x = z((e) => {
304
+ }, []), x = H((e) => {
301
305
  l.current(e);
302
- }, []), S = z((e) => c.current.find((t) => t.key === e), []), C = z((e) => r.find((t) => t.key === e)?.value || [], [r]), w = z((e, t) => {
306
+ }, []), S = H((e) => c.current.find((t) => t.key === e), []), C = H((e) => r.find((t) => t.key === e)?.value || [], [r]), w = H((e, t) => {
303
307
  let n = r.find((t) => t.key === e);
304
308
  if (t.length === 0) n && v(e);
305
309
  else if (n) y(e, { value: t });
306
310
  else {
307
- let n = c.current.find((t) => t.key === e), r = n?.operator ?? n?.operators?.[0]?.value ?? (n ? we(n.type) : "equals");
311
+ let n = c.current.find((t) => t.key === e), r = n?.operator ?? n?.operators?.[0]?.value ?? (n ? je(n.type) : "equals");
308
312
  _({
309
313
  id: e,
310
314
  key: e,
@@ -317,21 +321,21 @@ function De({ children: t, filters: n, activeFilters: r, onFilterChange: i, navi
317
321
  _,
318
322
  v,
319
323
  y
320
- ]), T = z((e) => r.some((t) => t.key === e && t.value.length > 0), [r]), E = z((e) => r.find((t) => t.key === e)?.operator || "equals", [r]), D = z((e, t) => {
324
+ ]), T = H((e) => r.some((t) => t.key === e && t.value.length > 0), [r]), E = H((e) => r.find((t) => t.key === e)?.operator || "equals", [r]), D = H((e, t) => {
321
325
  r.find((t) => t.key === e) && y(e, { operator: t });
322
- }, [r, y]), O = z((e, t) => {
326
+ }, [r, y]), O = H((e, t) => {
323
327
  let n = c.current.find((t) => t.key === e);
324
- return n ? Te(n, t, (e) => he(g, e)) : !1;
325
- }, [g]), k = z((e) => c.current.filter((t) => t.dependencies?.some((t) => t.key === e)), []), A = z((e, t) => {
328
+ return n ? Me(n, t, (e) => Ce(g, e)) : !1;
329
+ }, [g]), k = H((e) => c.current.filter((t) => t.dependencies?.some((t) => t.key === e)), []), A = H((e, t) => {
326
330
  let n = m.get(e)?.options;
327
331
  if (!n) return;
328
332
  let r = !1;
329
333
  for (let e of t) n.get(e.value)?.label !== e.label && (r = !0), n.set(e.value, e);
330
334
  r && f((e) => e + 1);
331
- }, [m]), j = z((e, t) => m.get(e)?.options.get(t)?.label, [m, d]), M = z((e, t) => {
335
+ }, [m]), j = H((e, t) => m.get(e)?.options.get(t)?.label, [m, d]), M = H((e, t) => {
332
336
  u.current?.(e, t);
333
337
  }, []);
334
- B(() => {
338
+ U(() => {
335
339
  let e = new AbortController(), t = (t, n) => {
336
340
  e.signal.aborted || t && t.name === "AbortError" || u.current?.(t, {
337
341
  phase: "fetch-options",
@@ -356,9 +360,9 @@ function De({ children: t, filters: n, activeFilters: r, onFilterChange: i, navi
356
360
  m,
357
361
  A
358
362
  ]);
359
- let N = V(() => ({
363
+ let N = W(() => ({
360
364
  activeFilters: r,
361
- filters: n,
365
+ filters: t,
362
366
  addFilter: _,
363
367
  removeFilter: v,
364
368
  updateFilter: y,
@@ -379,7 +383,7 @@ function De({ children: t, filters: n, activeFilters: r, onFilterChange: i, navi
379
383
  reportError: M
380
384
  }), [
381
385
  r,
382
- n,
386
+ t,
383
387
  _,
384
388
  v,
385
389
  y,
@@ -399,28 +403,28 @@ function De({ children: t, filters: n, activeFilters: r, onFilterChange: i, navi
399
403
  j,
400
404
  M
401
405
  ]);
402
- return /* @__PURE__ */ G(Ee.Provider, {
406
+ return /* @__PURE__ */ J(Ne.Provider, {
403
407
  value: N,
404
- children: t
408
+ children: e
405
409
  });
406
410
  }
407
- function Q() {
408
- let e = ne(Ee);
411
+ function $() {
412
+ let e = ce(Ne);
409
413
  if (!e) throw Error("useFilters must be used within a FilterProvider");
410
414
  return e;
411
415
  }
412
416
  //#endregion
413
417
  //#region src/components/features/filters/hooks/use-filter-groups.ts
414
- function Oe(e = {}) {
415
- let { dynamicFilterOptions: t } = e, { filters: n, isFilterActive: r } = Q(), i = V(() => t ? n.map((e) => {
418
+ function Fe(e = {}) {
419
+ let { dynamicFilterOptions: t } = e, { filters: n, isFilterActive: r } = $(), i = W(() => t ? n.map((e) => {
416
420
  let n = t[e.key];
417
421
  return Array.isArray(n) ? {
418
422
  ...e,
419
423
  options: n
420
424
  } : e;
421
425
  }) : n, [n, t]);
422
- return V(() => {
423
- let e = i.filter((e) => e.type === X.SEARCH), t = i.filter((e) => !e.displayConfig?.hidden && e.displayConfig?.display !== "hidden"), n = i.filter((e) => e.type !== X.SEARCH && !e.displayConfig?.hidden && e.displayConfig?.display !== "hidden" && r(e.key)), a = t.filter((e) => e.type !== X.SEARCH && !r(e.key) && e.displayConfig?.display === "always"), o = t.filter((e) => e.type !== X.SEARCH && !r(e.key) && e.displayConfig?.display !== "always"), s = n.map((e) => e.key);
426
+ return W(() => {
427
+ let e = i.filter((e) => e.type === Z.SEARCH), t = i.filter((e) => !e.displayConfig?.hidden && e.displayConfig?.display !== "hidden"), n = i.filter((e) => e.type !== Z.SEARCH && !e.displayConfig?.hidden && e.displayConfig?.display !== "hidden" && r(e.key)), a = t.filter((e) => e.type !== Z.SEARCH && !r(e.key) && e.displayConfig?.display === "always"), o = t.filter((e) => e.type !== Z.SEARCH && !r(e.key) && e.displayConfig?.display !== "always"), s = n.map((e) => e.key);
424
428
  return {
425
429
  processedFilters: i,
426
430
  searchFilters: e,
@@ -434,233 +438,233 @@ function Oe(e = {}) {
434
438
  }
435
439
  //#endregion
436
440
  //#region src/components/features/filters/partials/filter-operator-select.tsx
437
- function ke({ operator: e, operators: i, onOperatorChange: o, segmentResetClass: s }) {
438
- let [c, l] = U(!1), { strings: u } = Q(), d = i.find((t) => t.value === e)?.label || e;
439
- return /* @__PURE__ */ G(F, {
441
+ function Ie({ operator: e, operators: t, onOperatorChange: n, segmentResetClass: a }) {
442
+ let [c, l] = K(!1), { strings: u } = $(), d = t.find((t) => t.value === e)?.label || e;
443
+ return /* @__PURE__ */ J(re, {
440
444
  open: c,
441
445
  onOpenChange: l,
442
446
  search: !1,
443
447
  contentLabel: u.operator,
444
- trigger: /* @__PURE__ */ G(n, {
448
+ trigger: /* @__PURE__ */ J(s, {
445
449
  tone: "secondary",
446
450
  buttonStyle: "ghost",
447
- className: t("filter-operator-select--component", s, "h-full px-control text-muted-foreground hover:bg-accent hover:text-accent-foreground focus-visible:bg-accent focus-visible:text-accent-foreground"),
451
+ className: r("filter-operator-select--component", a, "h-full min-h-0 px-control text-muted-foreground hover:bg-accent hover:text-accent-foreground focus-visible:bg-accent focus-visible:text-accent-foreground"),
448
452
  onClick: (e) => {
449
453
  e.stopPropagation();
450
454
  },
451
455
  type: "button",
452
- children: /* @__PURE__ */ G(r, {
456
+ children: /* @__PURE__ */ J(o, {
453
457
  tag: "span",
454
458
  type: "secondary",
455
459
  children: d
456
460
  })
457
461
  }),
458
- header: /* @__PURE__ */ G(a, {
462
+ header: /* @__PURE__ */ J(i, {
459
463
  tag: "span",
460
464
  children: u.operator
461
465
  }),
462
466
  contentClassName: "w-48",
463
- items: i.map((t) => ({
467
+ items: t.map((t) => ({
464
468
  value: t.value,
465
469
  label: t.label,
466
470
  selected: t.value === e
467
471
  })),
468
472
  onSelect: (e) => {
469
- o(e.value), l(!1);
473
+ n(e.value), l(!1);
470
474
  }
471
475
  });
472
476
  }
473
477
  //#endregion
474
478
  //#region src/components/features/filters/partials/filter-value-display.tsx
475
- function Ae({ filter: e, value: t }) {
476
- let { strings: n } = Q();
477
- return t.length === 0 && e.type !== X.DATE ? /* @__PURE__ */ G(r, {
479
+ function Le({ filter: e, value: t }) {
480
+ let { strings: n } = $();
481
+ return t.length === 0 && e.type !== Z.DATE ? /* @__PURE__ */ J(o, {
478
482
  tag: "span",
479
483
  type: "secondary",
480
484
  className: "filter-value-display--component leading-none",
481
485
  children: n.nothingSelected
482
- }) : e.type === X.ASYNC_SELECT && !e.options?.length ? /* @__PURE__ */ G(r, {
486
+ }) : e.type === Z.ASYNC_SELECT && !e.options?.length ? /* @__PURE__ */ J(o, {
483
487
  tag: "span",
484
488
  weight: "semibold",
485
489
  className: "filter-value-display--component leading-none",
486
- children: Me(e, t, n)
487
- }) : e.options && e.type !== X.DATE ? /* @__PURE__ */ K(s, {
490
+ children: ze(e, t, n)
491
+ }) : e.options && e.type !== Z.DATE ? /* @__PURE__ */ Y(l, {
488
492
  direction: "horizontal",
489
493
  gap: "xs",
490
494
  wrap: !1,
491
495
  className: "filter-value-display--component",
492
- children: [/* @__PURE__ */ K("div", {
496
+ children: [/* @__PURE__ */ Y("div", {
493
497
  className: "relative flex",
494
498
  children: [t.slice(0, 2).map((t, n) => {
495
499
  let r = e.options?.find((e) => e.value === t);
496
- return r?.icon ? /* @__PURE__ */ G("div", {
500
+ return r?.icon ? /* @__PURE__ */ J("div", {
497
501
  className: `${n > 0 ? "-ml-space-sm" : ""} border-background bg-background relative rounded-full border`,
498
502
  style: { zIndex: 10 - n },
499
503
  children: r.icon
500
504
  }, t) : null;
501
- }), t.length > 2 && /* @__PURE__ */ G("div", {
505
+ }), t.length > 2 && /* @__PURE__ */ J("div", {
502
506
  className: "bg-muted border-background relative -ml-space-sm flex size-icon items-center justify-center rounded-full border",
503
- children: /* @__PURE__ */ K(r, {
507
+ children: /* @__PURE__ */ Y(o, {
504
508
  tag: "span",
505
509
  size: "xs",
506
510
  weight: "medium",
507
- children: ["+", /* @__PURE__ */ G(p, {
511
+ children: ["+", /* @__PURE__ */ J(h, {
508
512
  value: t.length - 2,
509
513
  size: "inherit",
510
514
  align: "center"
511
515
  })]
512
516
  })
513
517
  })]
514
- }), /* @__PURE__ */ G(r, {
518
+ }), /* @__PURE__ */ J(o, {
515
519
  tag: "span",
516
520
  weight: "semibold",
517
521
  className: "truncate leading-none",
518
- children: Ne(e, t, n)
522
+ children: Be(e, t, n)
519
523
  })]
520
- }) : e.type === X.DATE ? /* @__PURE__ */ K(s, {
524
+ }) : e.type === Z.DATE ? /* @__PURE__ */ Y(l, {
521
525
  direction: "horizontal",
522
526
  gap: "xs",
523
527
  wrap: !1,
524
528
  className: "filter-value-display--component",
525
- children: [/* @__PURE__ */ G(ie, { className: "text-muted-foreground size-icon-sm" }), je(e, t, n)]
526
- }) : /* @__PURE__ */ G(r, {
529
+ children: [/* @__PURE__ */ J(ue, { className: "text-muted-foreground size-icon-sm" }), Re(e, t, n)]
530
+ }) : /* @__PURE__ */ J(o, {
527
531
  tag: "span",
528
532
  weight: "semibold",
529
533
  className: "filter-value-display--component truncate leading-none",
530
- children: Ne(e, t, n)
534
+ children: Be(e, t, n)
531
535
  });
532
536
  }
533
- function je(e, t, n) {
534
- return e.operator === "between" && t.length === 2 ? Ie(t[0], t[1], e.dateFormat?.display) : t.length === 1 ? Fe(t[0], e.dateFormat?.display) : t.length === 2 ? Ie(t[0], t[1], e.dateFormat?.display) : /* @__PURE__ */ G(u, {
537
+ function Re(e, t, n) {
538
+ return e.operator === "between" && t.length === 2 ? Ue(t[0], t[1], e.dateFormat?.display) : t.length === 1 ? He(t[0], e.dateFormat?.display) : t.length === 2 ? Ue(t[0], t[1], e.dateFormat?.display) : /* @__PURE__ */ J(f, {
535
539
  weight: "semibold",
536
540
  className: "truncate leading-none",
537
541
  children: e.datePickerConfig?.noDatePlaceholder || n.calendar.notDateSelected
538
542
  });
539
543
  }
540
- function Me(e, t, n) {
541
- return t.length === 0 ? "" : Y(n.selected, {
544
+ function ze(e, t, n) {
545
+ return t.length === 0 ? "" : X(n.selected, {
542
546
  count: t.length,
543
547
  filterLabel: (t.length > 1 ? e.pluralLabel : e.label) ?? e.label
544
548
  });
545
549
  }
546
- function Ne(e, t, n) {
547
- return t.length > 1 ? Y(n.selected, {
550
+ function Be(e, t, n) {
551
+ return t.length > 1 ? X(n.selected, {
548
552
  count: t.length,
549
553
  filterLabel: e.pluralLabel ?? e.label
550
554
  }) : t.map((t) => e.options?.find((e) => e.value === t)?.label || t).join(", ");
551
555
  }
552
- function Pe(e) {
556
+ function Ve(e) {
553
557
  let t = new Date(e);
554
558
  return !Number.isNaN(t.getTime());
555
559
  }
556
- function Fe(e, t) {
557
- return Pe(e) ? /* @__PURE__ */ G(h, {
560
+ function He(e, t) {
561
+ return Ve(e) ? /* @__PURE__ */ J(_, {
558
562
  value: e,
559
563
  format: t,
560
564
  weight: "semibold",
561
565
  className: "truncate leading-none"
562
- }) : /* @__PURE__ */ G(u, {
566
+ }) : /* @__PURE__ */ J(f, {
563
567
  weight: "semibold",
564
568
  className: "truncate leading-none",
565
569
  children: e
566
570
  });
567
571
  }
568
- function Ie(e, t, n) {
569
- return Pe(e) && Pe(t) ? /* @__PURE__ */ G(m, {
572
+ function Ue(e, t, n) {
573
+ return Ve(e) && Ve(t) ? /* @__PURE__ */ J(g, {
570
574
  from: e,
571
575
  to: t,
572
576
  format: n,
573
577
  weight: "semibold",
574
578
  className: "truncate leading-none"
575
- }) : /* @__PURE__ */ K("span", {
579
+ }) : /* @__PURE__ */ Y("span", {
576
580
  className: "inline-flex min-w-0 items-center gap-space-xs truncate leading-none",
577
581
  children: [
578
- Fe(e, n),
579
- /* @__PURE__ */ G(u, {
582
+ He(e, n),
583
+ /* @__PURE__ */ J(f, {
580
584
  weight: "semibold",
581
585
  children: "–"
582
586
  }),
583
- Fe(t, n)
587
+ He(t, n)
584
588
  ]
585
589
  });
586
590
  }
587
591
  //#endregion
588
592
  //#region src/components/features/filters/partials/active-filter-item.tsx
589
- function Le({ filter: e, value: i, active: a, popoverOpen: o, triggerRef: s, operators: c, operator: l, onOperatorChange: u, onFilterClear: d, onFilterClick: f }) {
590
- let { strings: p } = Q(), m = R.useId(), h = R.useId(), g = "!border-0 !rounded-none !shadow-none focus-visible:!ring-0 focus-visible:!border-transparent", _ = () => /* @__PURE__ */ G("div", {
593
+ function We({ filter: n, value: i, active: a, popoverOpen: c, triggerRef: l, operators: u, operator: d, onOperatorChange: f, onFilterClear: p, onFilterClick: m }) {
594
+ let { defaultScale: h } = t(), g = e(void 0, h), { strings: _ } = $(), v = V.useId(), y = V.useId(), b = `${R.joinedItem} !border-0 !rounded-none !shadow-none focus-visible:!ring-0 focus-visible:!border-transparent`, x = () => /* @__PURE__ */ J("div", {
591
595
  "aria-hidden": !0,
592
596
  className: "w-px self-stretch bg-border"
593
597
  });
594
- return /* @__PURE__ */ K("div", {
598
+ return /* @__PURE__ */ Y("div", {
595
599
  role: "group",
596
- "aria-label": e.label,
600
+ "aria-label": n.label,
597
601
  "data-active": a || void 0,
598
- className: t("active-filter-item--component", `border-input bg-background flex ${ge} items-center overflow-hidden rounded-radius border`, e.displayConfig?.className),
602
+ className: r("active-filter-item--component", R.joinedFrame, te[g], "bg-background", n.displayConfig?.className),
599
603
  children: [
600
- /* @__PURE__ */ K(n, {
604
+ /* @__PURE__ */ Y(s, {
601
605
  type: "button",
602
606
  tone: "secondary",
603
607
  buttonStyle: "ghost",
604
- className: t(g, "flex h-full items-center gap-space-sm px-control hover:bg-accent hover:text-accent-foreground focus-visible:bg-accent focus-visible:text-accent-foreground"),
605
- ref: s,
608
+ className: r(b, "flex h-full min-h-0 items-center gap-space-sm px-control hover:bg-accent hover:text-accent-foreground focus-visible:bg-accent focus-visible:text-accent-foreground"),
609
+ ref: l,
606
610
  "aria-haspopup": "dialog",
607
- "aria-expanded": o,
608
- onClick: f,
611
+ "aria-expanded": c,
612
+ onClick: m,
609
613
  children: [
610
- !!e.icon && /* @__PURE__ */ G("span", {
614
+ !!n.icon && /* @__PURE__ */ J("span", {
611
615
  className: "flex items-center text-muted-foreground",
612
- children: e.icon
616
+ children: n.icon
613
617
  }),
614
- /* @__PURE__ */ G(r, {
615
- id: m,
618
+ /* @__PURE__ */ J(o, {
619
+ id: v,
616
620
  tag: "span",
617
621
  weight: "semibold",
618
- children: e.label
622
+ children: n.label
619
623
  }),
620
- /* @__PURE__ */ G(oe, { className: "size-icon-sm" })
624
+ /* @__PURE__ */ J(fe, { className: "size-icon-sm" })
621
625
  ]
622
626
  }),
623
- /* @__PURE__ */ G(_, {}),
624
- /* @__PURE__ */ G(ke, {
625
- operator: l,
626
- operators: c,
627
- onOperatorChange: u,
628
- segmentResetClass: g
627
+ /* @__PURE__ */ J(x, {}),
628
+ /* @__PURE__ */ J(Ie, {
629
+ operator: d,
630
+ operators: u,
631
+ onOperatorChange: f,
632
+ segmentResetClass: b
629
633
  }),
630
- /* @__PURE__ */ G(_, {}),
631
- /* @__PURE__ */ G(n, {
634
+ /* @__PURE__ */ J(x, {}),
635
+ /* @__PURE__ */ J(s, {
632
636
  type: "button",
633
637
  tone: "secondary",
634
638
  buttonStyle: "ghost",
635
- "aria-labelledby": `${m} ${h}`,
639
+ "aria-labelledby": `${v} ${y}`,
636
640
  "aria-haspopup": "dialog",
637
- "aria-expanded": o,
638
- onClick: f,
639
- className: t(g, "flex h-full min-w-0 flex-1 items-center justify-start px-control hover:bg-accent hover:text-accent-foreground focus-visible:bg-accent focus-visible:text-accent-foreground"),
640
- children: /* @__PURE__ */ G("span", {
641
- id: h,
641
+ "aria-expanded": c,
642
+ onClick: m,
643
+ className: r(b, "flex h-full min-h-0 min-w-0 flex-1 items-center justify-start px-control hover:bg-accent hover:text-accent-foreground focus-visible:bg-accent focus-visible:text-accent-foreground"),
644
+ children: /* @__PURE__ */ J("span", {
645
+ id: y,
642
646
  className: "min-w-0",
643
- children: /* @__PURE__ */ G(Ae, {
644
- filter: e,
647
+ children: /* @__PURE__ */ J(Le, {
648
+ filter: n,
645
649
  value: i
646
650
  })
647
651
  })
648
652
  }),
649
- !!a && /* @__PURE__ */ K(W, { children: [/* @__PURE__ */ G(_, {}), /* @__PURE__ */ K(n, {
653
+ !!a && /* @__PURE__ */ Y(q, { children: [/* @__PURE__ */ J(x, {}), /* @__PURE__ */ Y(s, {
650
654
  type: "button",
651
655
  tone: "secondary",
652
656
  buttonStyle: "ghost",
653
- className: t(g, "flex h-full shrink-0 items-center justify-center px-space-sm text-muted-foreground hover:bg-accent hover:text-foreground"),
657
+ className: r(b, "flex h-full min-h-0 shrink-0 items-center justify-center px-space-sm text-muted-foreground hover:bg-accent hover:text-foreground focus-visible:bg-accent focus-visible:text-accent-foreground"),
654
658
  onClick: (e) => {
655
- e.stopPropagation(), e.preventDefault(), d();
659
+ e.stopPropagation(), e.preventDefault(), p();
656
660
  },
657
- children: [/* @__PURE__ */ G(q, {
661
+ children: [/* @__PURE__ */ J(ve, {
658
662
  "aria-hidden": "true",
659
663
  className: "size-icon"
660
- }), /* @__PURE__ */ G(r, {
664
+ }), /* @__PURE__ */ J(o, {
661
665
  tag: "span",
662
666
  className: "sr-only",
663
- children: p.clear
667
+ children: _.clear
664
668
  })]
665
669
  })] })
666
670
  ]
@@ -668,18 +672,18 @@ function Le({ filter: e, value: i, active: a, popoverOpen: o, triggerRef: s, ope
668
672
  }
669
673
  //#endregion
670
674
  //#region src/components/features/filters/hooks/use-async-options.ts
671
- function Re(e, t, n) {
675
+ function Ge(e, t, n) {
672
676
  for (let [t, r] of e) Date.now() - r.timestamp > n && e.delete(t);
673
677
  return e.get(t);
674
678
  }
675
- function ze(e, t, n, r = {}) {
676
- let { asyncConfig: i } = e, a = i?.fetcher, o = i?.mapToOption, s = V(() => /* @__PURE__ */ new Map(), [
679
+ function Ke(e, t, n, r = {}) {
680
+ let { asyncConfig: i } = e, a = i?.fetcher, o = i?.mapToOption, s = W(() => /* @__PURE__ */ new Map(), [
677
681
  e.key,
678
682
  a,
679
683
  o
680
- ]), c = H(r.onError);
684
+ ]), c = G(r.onError);
681
685
  c.current = r.onError;
682
- let l = i?.debounceMs ?? e.delay ?? 300, u = (L(t, l) ?? "").trim(), d = i?.limit ?? 10, f = i?.minQueryLength ?? 0, p = i?.preload ?? !0, m = i?.staleTime ?? 6e4, h = i?.gcTime ?? 3e5, g = u.length === 0 && p, _ = u.length >= f, v = !!i?.fetcher && n && (g || u.length > 0 && _), y = n && !g && u.length > 0 && u.length < f, b = V(() => i?.queryKey ? JSON.stringify(i.queryKey({
686
+ let l = i?.debounceMs ?? e.delay ?? 300, u = (ae(t, l) ?? "").trim(), d = i?.limit ?? 10, f = i?.minQueryLength ?? 0, p = i?.preload ?? !0, m = i?.staleTime ?? 6e4, h = i?.gcTime ?? 3e5, g = u.length === 0 && p, _ = u.length >= f, v = !!i?.fetcher && n && (g || u.length > 0 && _), y = n && !g && u.length > 0 && u.length < f, b = W(() => i?.queryKey ? JSON.stringify(i.queryKey({
683
687
  query: u,
684
688
  limit: d
685
689
  })) : JSON.stringify([
@@ -692,7 +696,7 @@ function ze(e, t, n, r = {}) {
692
696
  e.key,
693
697
  u,
694
698
  d
695
- ]), x = z(async (e) => a && o ? (await a({
699
+ ]), x = H(async (e) => a && o ? (await a({
696
700
  query: u,
697
701
  limit: d,
698
702
  signal: e
@@ -701,8 +705,8 @@ function ze(e, t, n, r = {}) {
701
705
  o,
702
706
  u,
703
707
  d
704
- ]), [S, C] = U(() => {
705
- let e = Re(s, b, h);
708
+ ]), [S, C] = K(() => {
709
+ let e = Ge(s, b, h);
706
710
  return {
707
711
  cache: s,
708
712
  data: e?.data ?? [],
@@ -710,11 +714,11 @@ function ze(e, t, n, r = {}) {
710
714
  fetching: !1,
711
715
  error: !1
712
716
  };
713
- }), [w, T] = U(0), E = z(() => T((e) => e + 1), []), D = H(0);
714
- return B(() => {
717
+ }), [w, T] = K(0), E = H(() => T((e) => e + 1), []), D = G(0);
718
+ return U(() => {
715
719
  let t = D.current !== w;
716
720
  if (D.current = w, !v) return;
717
- let n = Re(s, b, h), r = n !== void 0 && Date.now() - n.timestamp < m, i = new AbortController();
721
+ let n = Ge(s, b, h), r = n !== void 0 && Date.now() - n.timestamp < m, i = new AbortController();
718
722
  if (r && !t) return C({
719
723
  cache: s,
720
724
  data: n.data,
@@ -776,23 +780,23 @@ function ze(e, t, n, r = {}) {
776
780
  }
777
781
  //#endregion
778
782
  //#region src/components/features/filters/partials/async-filter-content.tsx
779
- function Be({ filter: e, value: t, onFilterChange: i, onBackToFilterList: a, onClose: o, triggerSource: u = "chip" }) {
780
- let { strings: d, cacheAsyncOptions: f, getAsyncOptionLabel: p, reportError: m } = Q(), [h, g] = U(""), [S, w] = U(t ?? []), T = H(t);
781
- if (t !== T.current) {
782
- let e = T.current ?? [], n = t ?? [];
783
- T.current = t, (n.length !== e.length || n.some((t, n) => t !== e[n])) && w(n);
783
+ function qe({ filter: e, value: t, onFilterChange: n, onBackToFilterList: r, onClose: i, triggerSource: a = "chip" }) {
784
+ let { strings: c, cacheAsyncOptions: f, getAsyncOptionLabel: p, reportError: m } = $(), [h, g] = K(""), [_, v] = K(t ?? []), y = G(t);
785
+ if (t !== y.current) {
786
+ let e = y.current ?? [], n = t ?? [];
787
+ y.current = t, (n.length !== e.length || n.some((t, n) => t !== e[n])) && v(n);
784
788
  }
785
- let { options: E, isLoading: D, isFetching: k, isError: j, refetch: M, isBelowMinQuery: N, minQueryLength: P } = ze(e, h, !0, { onError: m });
786
- B(() => {
787
- E.length > 0 && f(e.key, E);
789
+ let { options: T, isLoading: D, isFetching: O, isError: k, refetch: A, isBelowMinQuery: j, minQueryLength: M } = Ke(e, h, !0, { onError: m });
790
+ U(() => {
791
+ T.length > 0 && f(e.key, T);
788
792
  }, [
789
793
  f,
790
794
  e.key,
791
- E
795
+ T
792
796
  ]);
793
- let F = e.multiple !== !1, I = e.maxSelected, L = u === "toolbar", R = S.length !== t.length || S.some((e) => !t.includes(e)), ee = V(() => {
794
- let t = new Set(S), n = new Set(E.map((e) => e.value)), r = [];
795
- for (let t of S) if (!n.has(t)) {
797
+ let N = e.multiple !== !1, F = e.maxSelected, ee = a === "toolbar", L = _.length !== t.length || _.some((e) => !t.includes(e)), R = W(() => {
798
+ let t = new Set(_), n = new Set(T.map((e) => e.value)), r = [];
799
+ for (let t of _) if (!n.has(t)) {
796
800
  let n = p(e.key, t);
797
801
  n && r.push({
798
802
  value: t,
@@ -800,156 +804,156 @@ function Be({ filter: e, value: t, onFilterChange: i, onBackToFilterList: a, onC
800
804
  icon: e.icon
801
805
  });
802
806
  }
803
- return [...r, ...E].sort((e, n) => +!t.has(e.value) - !t.has(n.value));
807
+ return [...r, ...T].sort((e, n) => +!t.has(e.value) - !t.has(n.value));
804
808
  }, [
805
- E,
806
- S,
809
+ T,
810
+ _,
807
811
  e.key,
808
812
  e.icon,
809
813
  p
810
814
  ]), te = (t) => {
811
- if (F) {
812
- if (S.includes(t)) w(S.filter((e) => e !== t));
815
+ if (N) {
816
+ if (_.includes(t)) v(_.filter((e) => e !== t));
813
817
  else {
814
- if (I && S.length >= I) return;
815
- w([...S, t]);
818
+ if (F && _.length >= F) return;
819
+ v([..._, t]);
816
820
  }
817
- } else w([t]), e.closeOnSelect === !0 && (i([t]), o());
821
+ } else v([t]), e.closeOnSelect === !0 && (n([t]), i());
818
822
  }, z = () => {
819
- i(S), o();
820
- }, ne = V(() => D || k ? /* @__PURE__ */ G(c, { label: d.searching }) : j ? /* @__PURE__ */ G(l, {
823
+ n(_), i();
824
+ }, B = W(() => D || O ? /* @__PURE__ */ J(u, { label: c.searching }) : k ? /* @__PURE__ */ J(d, {
821
825
  variant: "inline",
822
- title: d.fetchError,
823
- action: /* @__PURE__ */ G(n, {
826
+ title: c.fetchError,
827
+ action: /* @__PURE__ */ J(s, {
824
828
  tone: "secondary",
825
829
  buttonStyle: "outline",
826
830
  size: "sm",
827
831
  onClick: (e) => {
828
- e.stopPropagation(), M();
832
+ e.stopPropagation(), A();
829
833
  },
830
- children: d.retryFetch
834
+ children: c.retryFetch
831
835
  })
832
- }) : N ? /* @__PURE__ */ G("div", {
836
+ }) : j ? /* @__PURE__ */ J("div", {
833
837
  className: "text-muted-foreground flex items-center justify-center py-space-xl",
834
- children: /* @__PURE__ */ G(r, {
838
+ children: /* @__PURE__ */ J(o, {
835
839
  tag: "span",
836
840
  size: "xs",
837
841
  type: "secondary",
838
- children: Y(d.minQueryHint, { min: P })
842
+ children: X(c.minQueryHint, { min: M })
839
843
  })
840
- }) : d.noOptionsFound, [
844
+ }) : c.noOptionsFound, [
841
845
  D,
846
+ O,
842
847
  k,
843
848
  j,
844
- N,
845
- P,
846
- d,
847
- M
849
+ M,
850
+ c,
851
+ A
848
852
  ]);
849
- return /* @__PURE__ */ K(W, { children: [
850
- /* @__PURE__ */ K(O, {
851
- start: L ? /* @__PURE__ */ G(n, {
853
+ return /* @__PURE__ */ Y(q, { children: [
854
+ /* @__PURE__ */ Y(P, {
855
+ start: ee ? /* @__PURE__ */ J(s, {
852
856
  tone: "secondary",
853
857
  buttonStyle: "ghost",
854
858
  size: "sm",
855
859
  iconOnly: !0,
856
860
  className: "shrink-0",
857
- onClick: a,
858
- "aria-label": d.backToFilters,
859
- children: /* @__PURE__ */ G(se, {
861
+ onClick: r,
862
+ "aria-label": c.backToFilters,
863
+ children: /* @__PURE__ */ J(pe, {
860
864
  "aria-hidden": "true",
861
865
  className: "size-icon-sm rtl:rotate-180"
862
866
  })
863
867
  }) : void 0,
864
- children: [/* @__PURE__ */ G(r, {
868
+ children: [/* @__PURE__ */ J(o, {
865
869
  tag: "span",
866
870
  weight: "semibold",
867
871
  children: e.label
868
- }), /* @__PURE__ */ G(r, {
872
+ }), /* @__PURE__ */ J(o, {
869
873
  tag: "span",
870
874
  size: "xs",
871
875
  type: "secondary",
872
- children: d.selectValues
876
+ children: c.selectValues
873
877
  })]
874
878
  }),
875
- /* @__PURE__ */ K(C, {
879
+ /* @__PURE__ */ Y(E, {
876
880
  shouldFilter: !1,
877
881
  inset: "flush",
878
882
  className: "rounded-none",
879
- children: [/* @__PURE__ */ G(v, {
880
- placeholder: Y(d.searchPlaceholder, { filterLabel: e.label.toLowerCase() }),
883
+ children: [/* @__PURE__ */ J(x, {
884
+ placeholder: X(c.searchPlaceholder, { filterLabel: e.label.toLowerCase() }),
881
885
  value: h,
882
886
  onValueChange: g
883
- }), /* @__PURE__ */ G(b, { children: ee.length === 0 ? /* @__PURE__ */ G(y, { children: ne }) : /* @__PURE__ */ K(x, { children: [!(!k || D) && /* @__PURE__ */ K(s, {
887
+ }), /* @__PURE__ */ J(C, { children: R.length === 0 ? /* @__PURE__ */ J(S, { children: B }) : /* @__PURE__ */ Y(w, { children: [!(!O || D) && /* @__PURE__ */ Y(l, {
884
888
  direction: "horizontal",
885
889
  gap: "sm",
886
890
  wrap: !1,
887
891
  className: "px-control-sm py-space-xs",
888
- children: [/* @__PURE__ */ G(ue, { className: "text-muted-foreground size-icon-sm animate-spin" }), /* @__PURE__ */ G(r, {
892
+ children: [/* @__PURE__ */ J(ge, { className: "text-muted-foreground size-icon-sm animate-spin" }), /* @__PURE__ */ J(o, {
889
893
  tag: "span",
890
894
  size: "xs",
891
895
  type: "secondary",
892
- children: d.searching
896
+ children: c.searching
893
897
  })]
894
- }), ee.map((e) => /* @__PURE__ */ K(_, {
898
+ }), R.map((e) => /* @__PURE__ */ Y(b, {
895
899
  onSelect: () => te(e.value),
896
- "data-checked": S.includes(e.value) || void 0,
897
- disabled: e.disabled || !!I && S.length >= I && !S.includes(e.value),
900
+ "data-checked": _.includes(e.value) || void 0,
901
+ disabled: e.disabled || !!F && _.length >= F && !_.includes(e.value),
898
902
  className: "flex items-center gap-space-sm",
899
- children: [e.icon, /* @__PURE__ */ G(r, {
903
+ children: [e.icon, /* @__PURE__ */ J(o, {
900
904
  tag: "span",
901
905
  lineHeight: "tight",
902
906
  children: e.label
903
907
  })]
904
908
  }, e.value))] }) })]
905
909
  }),
906
- R && /* @__PURE__ */ G(A, {
907
- caption: Y(d.selected, {
908
- count: S.length,
909
- filterLabel: (S.length > 1 ? e.pluralLabel : e.label) ?? e.label
910
+ L && /* @__PURE__ */ J(I, {
911
+ caption: X(c.selected, {
912
+ count: _.length,
913
+ filterLabel: (_.length > 1 ? e.pluralLabel : e.label) ?? e.label
910
914
  }),
911
- children: /* @__PURE__ */ G(n, {
915
+ children: /* @__PURE__ */ J(s, {
912
916
  tone: "primary",
913
917
  size: "sm",
914
918
  onClick: z,
915
- children: d.confirm
919
+ children: c.confirm
916
920
  })
917
921
  })
918
922
  ] });
919
923
  }
920
924
  //#endregion
921
925
  //#region src/components/features/filters/facets/date-facet.tsx
922
- var Ve = [];
923
- function He({ filter: e, value: n, onValueChange: r, className: i }) {
924
- let { strings: a } = Q(), o = e.operators?.some((e) => e.value === "between") || e.operator === "between" || e.key.toLowerCase().includes("range") || e.key.toLowerCase().includes("between"), s = e.dateFormat?.param ?? "yyyy-MM-dd", c = e.dateFormat?.display ?? "PPP", l = o ? e.datePickerConfig?.noRangePlaceholder ?? e.placeholder ?? a.calendar.notDateRangeSelected : e.datePickerConfig?.noDatePlaceholder ?? e.placeholder ?? a.calendar.notDateSelected, u = !!e.datePickerConfig?.showConfirmButton, d = e.datePickerConfig?.autoApply ?? !u, f = e.datePickerConfig?.showShortcuts ?? !0, p = o && (n.start || n.end) ? {
925
- from: n.start,
926
- to: n.end
927
- } : void 0, m = !o && n.start && J(n.start) ? n.start : void 0, h = {
926
+ var Je = [];
927
+ function Ye({ filter: e, value: t, onValueChange: n, className: i }) {
928
+ let { strings: a } = $(), o = e.operators?.some((e) => e.value === "between") || e.operator === "between" || e.key.toLowerCase().includes("range") || e.key.toLowerCase().includes("between"), s = e.dateFormat?.param ?? "yyyy-MM-dd", c = e.dateFormat?.display ?? "PPP", l = o ? e.datePickerConfig?.noRangePlaceholder ?? e.placeholder ?? a.calendar.notDateRangeSelected : e.datePickerConfig?.noDatePlaceholder ?? e.placeholder ?? a.calendar.notDateSelected, u = !!e.datePickerConfig?.showConfirmButton, d = e.datePickerConfig?.autoApply ?? !u, f = e.datePickerConfig?.showShortcuts ?? !0, p = o && (t.start || t.end) ? {
929
+ from: t.start,
930
+ to: t.end
931
+ } : void 0, m = !o && t.start && be(t.start) ? t.start : void 0, h = {
928
932
  format: s,
929
933
  readableFormat: c,
930
934
  placeholder: l,
931
935
  disablePortal: !0,
932
936
  numberOfMonths: 1,
933
- className: t("date-facet--component", "w-full", i)
937
+ className: r("date-facet--component", "w-full", i)
934
938
  };
935
- return o ? /* @__PURE__ */ G(T, {
939
+ return o ? /* @__PURE__ */ J(j, {
936
940
  mode: "range",
937
941
  value: p,
938
942
  onValueChange: (e) => {
939
- r({
943
+ n({
940
944
  start: e.range?.from ?? void 0,
941
945
  end: e.range?.to ?? void 0
942
946
  });
943
947
  },
944
948
  withConfirm: u,
945
949
  closeOnSelect: d,
946
- presets: f ? void 0 : Ve,
950
+ presets: f ? void 0 : Je,
947
951
  ...h
948
- }) : /* @__PURE__ */ G(T, {
952
+ }) : /* @__PURE__ */ J(j, {
949
953
  mode: "single",
950
954
  value: m,
951
955
  onValueChange: (e) => {
952
- r({
956
+ n({
953
957
  start: e.date ?? void 0,
954
958
  end: void 0
955
959
  });
@@ -960,45 +964,45 @@ function He({ filter: e, value: n, onValueChange: r, className: i }) {
960
964
  }
961
965
  //#endregion
962
966
  //#region src/components/features/filters/partials/date-filter-content.tsx
963
- function Ue({ filter: e, value: t, onFilterChange: r, onBackToFilterList: i, triggerSource: a = "chip" }) {
964
- let { strings: o } = Q(), s = (t) => {
967
+ function Xe({ filter: e, value: t, onFilterChange: n, onBackToFilterList: r, triggerSource: i = "chip" }) {
968
+ let { strings: a } = $(), o = (t) => {
965
969
  if (!t) return;
966
970
  if (e.dateFormat?.param) {
967
- let n = pe(t, e.dateFormat.param, /* @__PURE__ */ new Date());
968
- return J(n) ? n : void 0;
971
+ let n = xe(t, e.dateFormat.param, /* @__PURE__ */ new Date());
972
+ return be(n) ? n : void 0;
969
973
  }
970
974
  let n = new Date(t);
971
- return J(n) ? n : void 0;
972
- }, c = s(t[0]), l = s(t[1]), u = (t) => {
973
- if (t && J(t)) return fe(t, e.dateFormat?.param ?? "yyyy-MM-dd");
975
+ return be(n) ? n : void 0;
976
+ }, c = o(t[0]), l = o(t[1]), u = (t) => {
977
+ if (t && be(t)) return ye(t, e.dateFormat?.param ?? "yyyy-MM-dd");
974
978
  }, d = ({ start: e, end: t }) => {
975
- let n = [], i = u(e), a = u(t);
976
- i && n.push(i), a && n.push(a), r(n);
977
- }, f = a === "toolbar", p = {
979
+ let r = [], i = u(e), a = u(t);
980
+ i && r.push(i), a && r.push(a), n(r);
981
+ }, f = i === "toolbar", p = {
978
982
  start: c,
979
983
  end: l
980
984
  };
981
- return /* @__PURE__ */ K("div", {
985
+ return /* @__PURE__ */ Y("div", {
982
986
  className: "flex flex-col",
983
- children: [/* @__PURE__ */ G(O, {
984
- start: f ? /* @__PURE__ */ G(n, {
987
+ children: [/* @__PURE__ */ J(P, {
988
+ start: f ? /* @__PURE__ */ J(s, {
985
989
  type: "button",
986
990
  tone: "secondary",
987
991
  buttonStyle: "ghost",
988
992
  size: "sm",
989
993
  iconOnly: !0,
990
- onClick: i,
994
+ onClick: r,
991
995
  className: "shrink-0",
992
- "aria-label": o.backToFilters,
993
- children: /* @__PURE__ */ G(se, {
996
+ "aria-label": a.backToFilters,
997
+ children: /* @__PURE__ */ J(pe, {
994
998
  "aria-hidden": "true",
995
999
  className: "size-icon-sm rtl:rotate-180"
996
1000
  })
997
1001
  }) : void 0,
998
- children: /* @__PURE__ */ G(E, { children: e.label })
999
- }), /* @__PURE__ */ G("div", {
1002
+ children: /* @__PURE__ */ J(M, { children: e.label })
1003
+ }), /* @__PURE__ */ J("div", {
1000
1004
  className: "p-surface",
1001
- children: /* @__PURE__ */ G(He, {
1005
+ children: /* @__PURE__ */ J(Ye, {
1002
1006
  filter: e,
1003
1007
  value: p,
1004
1008
  onValueChange: d
@@ -1008,7 +1012,7 @@ function Ue({ filter: e, value: t, onFilterChange: r, onBackToFilterList: i, tri
1008
1012
  }
1009
1013
  //#endregion
1010
1014
  //#region src/components/features/filters/partials/filter-error-boundary.tsx
1011
- var We = class extends ee {
1015
+ var Ze = class extends oe {
1012
1016
  state = {
1013
1017
  hasError: !1,
1014
1018
  error: null
@@ -1033,54 +1037,53 @@ var We = class extends ee {
1033
1037
  };
1034
1038
  render() {
1035
1039
  if (this.state.hasError) {
1036
- let { fallback: e, filterKey: t, labels: i } = this.props;
1037
- return e ? /* @__PURE__ */ G("div", {
1040
+ let { fallback: e, filterKey: t, labels: n } = this.props;
1041
+ return e ? /* @__PURE__ */ J("div", {
1038
1042
  className: "filter-error-boundary--component contents",
1039
1043
  children: e
1040
- }) : /* @__PURE__ */ K("div", {
1041
- className: "filter-error-boundary--component rounded-radius-md border border-destructive/30 bg-destructive/10 p-surface-xs text-destructive",
1044
+ }) : /* @__PURE__ */ Y("div", {
1045
+ className: "filter-error-boundary--component rounded-radius border border-destructive/30 bg-destructive/10 p-surface-xs text-destructive",
1042
1046
  children: [
1043
- /* @__PURE__ */ K("div", {
1047
+ /* @__PURE__ */ Y("div", {
1044
1048
  className: "mb-space-xs flex items-center justify-between",
1045
- children: [/* @__PURE__ */ G(r, {
1049
+ children: [/* @__PURE__ */ J(o, {
1046
1050
  tag: "span",
1047
1051
  weight: "semibold",
1048
- children: i.title
1049
- }), /* @__PURE__ */ G(n, {
1052
+ children: n.title
1053
+ }), /* @__PURE__ */ J(s, {
1050
1054
  type: "button",
1051
1055
  tone: "destructive",
1052
1056
  buttonStyle: "ghost",
1053
1057
  size: "sm",
1054
1058
  iconOnly: !0,
1055
1059
  onClick: this.handleReset,
1056
- className: "rounded-full p-0",
1057
- "aria-label": i.reset,
1058
- children: /* @__PURE__ */ G(q, { className: "size-icon-sm" })
1060
+ "aria-label": n.reset,
1061
+ children: /* @__PURE__ */ J(ve, { className: "size-icon-sm" })
1059
1062
  })]
1060
1063
  }),
1061
- /* @__PURE__ */ G(r, { children: i.getDescription(t) }),
1062
- /* @__PURE__ */ G(f, {
1064
+ /* @__PURE__ */ J(o, { children: n.getDescription(t) }),
1065
+ /* @__PURE__ */ J(m, {
1063
1066
  size: "xs",
1064
1067
  className: "mt-space-xs text-destructive",
1065
- children: this.state.error?.message || i.unknownError
1068
+ children: this.state.error?.message || n.unknownError
1066
1069
  })
1067
1070
  ]
1068
1071
  });
1069
1072
  }
1070
- return /* @__PURE__ */ G("div", {
1073
+ return /* @__PURE__ */ J("div", {
1071
1074
  className: "filter-error-boundary--component contents",
1072
1075
  children: this.props.children
1073
1076
  });
1074
1077
  }
1075
1078
  };
1076
- function $(e) {
1077
- let { strings: t, reportError: n } = Q(), r = V(() => ({
1079
+ function Qe(e) {
1080
+ let { strings: t, reportError: n } = $(), r = W(() => ({
1078
1081
  title: t.error.title,
1079
1082
  reset: t.clear,
1080
- getDescription: (e) => e ? Y(t.error.descriptionWithKey, { filterKey: e }) : t.error.generic,
1083
+ getDescription: (e) => e ? X(t.error.descriptionWithKey, { filterKey: e }) : t.error.generic,
1081
1084
  unknownError: t.error.unknown
1082
1085
  }), [t]);
1083
- return /* @__PURE__ */ G(We, {
1086
+ return /* @__PURE__ */ J(Ze, {
1084
1087
  ...e,
1085
1088
  labels: r,
1086
1089
  onError: n
@@ -1088,53 +1091,53 @@ function $(e) {
1088
1091
  }
1089
1092
  //#endregion
1090
1093
  //#region src/components/features/filters/partials/filter-list-item.tsx
1091
- function Ge({ filter: e, onSelect: t }) {
1092
- let { strings: n } = Q(), i = e.type === X.DATE ? e.operator === "between" ? n?.selectDateRange : n?.selectDate : e.options ? `${e.options.length} ${n?.options ?? ""}`.trim() : null;
1093
- return /* @__PURE__ */ K(_, {
1094
+ function $e({ filter: e, onSelect: t }) {
1095
+ let { strings: n } = $(), r = e.type === Z.DATE ? e.operator === "between" ? n?.selectDateRange : n?.selectDate : e.options ? `${e.options.length} ${n?.options ?? ""}`.trim() : null;
1096
+ return /* @__PURE__ */ Y(b, {
1094
1097
  onSelect: t,
1095
- children: [!!e.icon && /* @__PURE__ */ G("span", {
1098
+ children: [!!e.icon && /* @__PURE__ */ J("span", {
1096
1099
  className: "shrink-0 text-muted-foreground [&_svg]:size-icon",
1097
1100
  children: e.icon
1098
- }), /* @__PURE__ */ K("div", {
1101
+ }), /* @__PURE__ */ Y("div", {
1099
1102
  className: "flex min-w-0 flex-col gap-dense leading-tight",
1100
- children: [/* @__PURE__ */ G(r, {
1103
+ children: [/* @__PURE__ */ J(o, {
1101
1104
  tag: "span",
1102
1105
  lineHeight: "tight",
1103
1106
  weight: "medium",
1104
1107
  className: "truncate",
1105
1108
  children: e.label
1106
- }), !!i && /* @__PURE__ */ G(r, {
1109
+ }), !!r && /* @__PURE__ */ J(o, {
1107
1110
  tag: "span",
1108
1111
  lineHeight: "tight",
1109
1112
  size: "xs",
1110
1113
  type: "secondary",
1111
1114
  className: "truncate",
1112
- children: i
1115
+ children: r
1113
1116
  })]
1114
1117
  })]
1115
1118
  }, e.key);
1116
1119
  }
1117
1120
  //#endregion
1118
1121
  //#region src/components/features/filters/partials/filter-list-content.tsx
1119
- function Ke({ availableFilters: e, activeFilters: t, onFilterSelect: n }) {
1120
- let { strings: r } = Q(), i = (e) => {
1122
+ function et({ availableFilters: e, activeFilters: t, onFilterSelect: n }) {
1123
+ let { strings: r } = $(), i = (e) => {
1121
1124
  n(e);
1122
1125
  };
1123
- return /* @__PURE__ */ K(C, {
1126
+ return /* @__PURE__ */ Y(E, {
1124
1127
  inset: "compact",
1125
1128
  className: "rounded-none",
1126
- children: [/* @__PURE__ */ G(v, { placeholder: r.searchFilters }), /* @__PURE__ */ K(b, { children: [
1127
- /* @__PURE__ */ G(y, { children: r.noFiltersAvailable }),
1128
- e.length > 0 && /* @__PURE__ */ G(x, {
1129
+ children: [/* @__PURE__ */ J(x, { placeholder: r.searchFilters }), /* @__PURE__ */ Y(C, { children: [
1130
+ /* @__PURE__ */ J(S, { children: r.noFiltersAvailable }),
1131
+ e.length > 0 && /* @__PURE__ */ J(w, {
1129
1132
  heading: r.availableFilters,
1130
- children: e.map((e) => /* @__PURE__ */ G(Ge, {
1133
+ children: e.map((e) => /* @__PURE__ */ J($e, {
1131
1134
  filter: e,
1132
1135
  onSelect: () => i(e)
1133
1136
  }, e.key))
1134
1137
  }),
1135
- t.length > 0 && /* @__PURE__ */ K(W, { children: [/* @__PURE__ */ G(S, {}), /* @__PURE__ */ G(x, {
1138
+ t.length > 0 && /* @__PURE__ */ Y(q, { children: [/* @__PURE__ */ J(T, {}), /* @__PURE__ */ J(w, {
1136
1139
  heading: r.activeFilters,
1137
- children: t.map((e) => /* @__PURE__ */ G(Ge, {
1140
+ children: t.map((e) => /* @__PURE__ */ J($e, {
1138
1141
  filter: e,
1139
1142
  onSelect: () => i(e)
1140
1143
  }, e.key))
@@ -1144,84 +1147,85 @@ function Ke({ availableFilters: e, activeFilters: t, onFilterSelect: n }) {
1144
1147
  }
1145
1148
  //#endregion
1146
1149
  //#region src/components/features/filters/partials/regular-filter-content.tsx
1147
- function qe({ filter: e, value: t, onFilterChange: i, onBackToFilterList: a, onClose: o, triggerSource: s = "chip" }) {
1148
- let { strings: c, reportError: l } = Q(), u = e.multiple === !0 || e.type === X.MULTI_SELECT, d = s === "toolbar", [f, p] = U(t || []);
1149
- B(() => {
1150
- p(t || []);
1150
+ function tt({ filter: e, value: t, onFilterChange: n, onBackToFilterList: r, onClose: i, triggerSource: a = "chip" }) {
1151
+ let { strings: c, reportError: u } = $(), d = e.multiple === !0 || e.type === Z.MULTI_SELECT, f = a === "toolbar", [p, m] = K(t || []);
1152
+ U(() => {
1153
+ m(t || []);
1151
1154
  }, [t]);
1152
- let m = (t) => {
1153
- if (u) {
1154
- let e = f.includes(t) ? f.filter((e) => e !== t) : [...f, t];
1155
- p(e);
1156
- } else p([t]), e.closeOnSelect === !0 && (i([t]), o());
1157
- }, h = () => {
1155
+ let h = (t) => {
1156
+ if (d) {
1157
+ let e = p.includes(t) ? p.filter((e) => e !== t) : [...p, t];
1158
+ m(e);
1159
+ } else m([t]), e.closeOnSelect === !0 && (n([t]), i());
1160
+ }, g = () => {
1158
1161
  try {
1159
- i(f), o();
1162
+ n(p), i();
1160
1163
  } catch (t) {
1161
- l(t, {
1164
+ u(t, {
1162
1165
  phase: "apply",
1163
1166
  filterKey: e.key
1164
1167
  });
1165
1168
  }
1166
- }, g = JSON.stringify(f.slice().sort()) !== JSON.stringify((t ?? []).slice().sort());
1167
- return /* @__PURE__ */ K("div", {
1169
+ }, _ = JSON.stringify(p.slice().sort()) !== JSON.stringify((t ?? []).slice().sort());
1170
+ return /* @__PURE__ */ Y("div", {
1168
1171
  className: "flex flex-col",
1169
1172
  children: [
1170
- /* @__PURE__ */ G(O, {
1171
- start: d ? /* @__PURE__ */ G(n, {
1173
+ /* @__PURE__ */ J(P, {
1174
+ start: f ? /* @__PURE__ */ J(s, {
1172
1175
  type: "button",
1173
1176
  tone: "secondary",
1174
1177
  buttonStyle: "ghost",
1175
1178
  size: "sm",
1176
1179
  iconOnly: !0,
1177
- onClick: a,
1180
+ onClick: r,
1178
1181
  className: "shrink-0",
1179
1182
  "aria-label": c.backToFilters,
1180
- children: /* @__PURE__ */ G(se, {
1183
+ children: /* @__PURE__ */ J(pe, {
1181
1184
  "aria-hidden": "true",
1182
1185
  className: "size-icon-sm rtl:rotate-180"
1183
1186
  })
1184
1187
  }) : void 0,
1185
- children: /* @__PURE__ */ G(r, {
1188
+ children: /* @__PURE__ */ J(o, {
1186
1189
  tag: "span",
1187
1190
  weight: "semibold",
1188
1191
  children: e.label
1189
1192
  })
1190
1193
  }),
1191
- /* @__PURE__ */ K(C, {
1194
+ /* @__PURE__ */ Y(E, {
1192
1195
  inset: "flush",
1193
1196
  className: "rounded-none",
1194
- children: [/* @__PURE__ */ G(v, { placeholder: Y(c.searchPlaceholder, { filterLabel: e.label.toLowerCase() }) }), /* @__PURE__ */ K(b, {
1197
+ children: [/* @__PURE__ */ J(x, { placeholder: X(c.searchPlaceholder, { filterLabel: e.label.toLowerCase() }) }), /* @__PURE__ */ Y(C, {
1195
1198
  className: "max-h-64",
1196
- children: [/* @__PURE__ */ G(y, { children: /* @__PURE__ */ G(r, {
1199
+ children: [/* @__PURE__ */ J(S, { children: /* @__PURE__ */ J(o, {
1197
1200
  type: "secondary",
1198
1201
  align: "center",
1199
1202
  className: "py-space-xl",
1200
1203
  children: c.noOptionsFound
1201
- }) }), /* @__PURE__ */ G(x, { children: e.options?.map((e) => {
1202
- let t = f.includes(e.value);
1203
- return /* @__PURE__ */ K(_, {
1204
- onSelect: () => m(e.value),
1204
+ }) }), /* @__PURE__ */ J(w, { children: e.options?.map((e) => {
1205
+ let t = p.includes(e.value);
1206
+ return /* @__PURE__ */ Y(b, {
1207
+ onSelect: () => h(e.value),
1205
1208
  "data-checked": t || void 0,
1206
1209
  disabled: e.disabled,
1207
1210
  className: "data-[checked=true]:**:[svg]:text-primary-accent",
1208
- children: [!!e.icon && /* @__PURE__ */ G("span", {
1211
+ children: [!!e.icon && /* @__PURE__ */ J("span", {
1209
1212
  className: "shrink-0 text-muted-foreground [&_svg]:size-icon",
1210
1213
  children: e.icon
1211
- }), /* @__PURE__ */ K("div", {
1214
+ }), /* @__PURE__ */ Y(l, {
1215
+ gap: "dense",
1212
1216
  className: "flex min-w-0 flex-1 flex-col leading-tight",
1213
- children: [/* @__PURE__ */ G(r, {
1217
+ children: [/* @__PURE__ */ J(o, {
1214
1218
  tag: "span",
1215
1219
  lineHeight: "tight",
1216
1220
  weight: t ? "medium" : "regular",
1217
1221
  className: "truncate",
1218
1222
  children: e.label
1219
- }), !!e.description && /* @__PURE__ */ G(r, {
1223
+ }), !!e.description && /* @__PURE__ */ J(o, {
1220
1224
  tag: "span",
1221
1225
  size: "xs",
1222
1226
  lineHeight: "tight",
1223
1227
  type: "secondary",
1224
- className: "truncate mt-space-2xs",
1228
+ className: "truncate",
1225
1229
  children: e.description
1226
1230
  })]
1227
1231
  })]
@@ -1229,15 +1233,15 @@ function qe({ filter: e, value: t, onFilterChange: i, onBackToFilterList: a, onC
1229
1233
  }) })]
1230
1234
  })]
1231
1235
  }),
1232
- !!g && /* @__PURE__ */ G(A, {
1233
- caption: Y(c.selected, {
1234
- count: f.length,
1235
- filterLabel: (f.length > 1 ? e.pluralLabel : e.label) ?? e.label
1236
+ !!_ && /* @__PURE__ */ J(I, {
1237
+ caption: X(c.selected, {
1238
+ count: p.length,
1239
+ filterLabel: (p.length > 1 ? e.pluralLabel : e.label) ?? e.label
1236
1240
  }),
1237
- children: /* @__PURE__ */ G(n, {
1241
+ children: /* @__PURE__ */ J(s, {
1238
1242
  tone: "primary",
1239
1243
  size: "sm",
1240
- onClick: h,
1244
+ onClick: g,
1241
1245
  children: c.confirm
1242
1246
  })
1243
1247
  })
@@ -1246,116 +1250,116 @@ function qe({ filter: e, value: t, onFilterChange: i, onBackToFilterList: a, onC
1246
1250
  }
1247
1251
  //#endregion
1248
1252
  //#region src/components/features/filters/facets/tags-facet.tsx
1249
- function Je({ filter: e, value: i, onValueChange: a, className: o }) {
1250
- let { strings: c } = Q(), [l, u] = U(""), d = z(() => {
1251
- let e = l.trim();
1252
- e && !i.includes(e) && (a([...i, e]), u(""));
1253
+ function nt({ filter: e, value: n, onValueChange: i, className: a }) {
1254
+ let { defaultScale: c } = t(), u = O(void 0, c), { strings: d } = $(), [f, p] = K(""), m = H(() => {
1255
+ let e = f.trim();
1256
+ e && !n.includes(e) && (i([...n, e]), p(""));
1253
1257
  }, [
1254
- l,
1255
- i,
1256
- a
1257
- ]), f = z((e) => {
1258
- a(i.filter((t) => t !== e));
1259
- }, [i, a]), p = (e) => {
1260
- e.key === "Enter" && (e.preventDefault(), d());
1261
- }, m = z(() => {
1262
- a([]), u("");
1263
- }, [a]), h = i.length > 0, _ = i.length === 1 ? c.tag : c.tags, v = h ? /* @__PURE__ */ K(s, {
1258
+ f,
1259
+ n,
1260
+ i
1261
+ ]), h = H((e) => {
1262
+ i(n.filter((t) => t !== e));
1263
+ }, [n, i]), g = (e) => {
1264
+ e.key === "Enter" && (e.preventDefault(), m());
1265
+ }, _ = H(() => {
1266
+ i([]), p("");
1267
+ }, [i]), b = n.length > 0, x = n.length === 1 ? d.tag : d.tags, S = b ? /* @__PURE__ */ Y(l, {
1264
1268
  gap: "md",
1265
1269
  className: "tags-facet--summary",
1266
- children: [/* @__PURE__ */ K(s, {
1270
+ children: [/* @__PURE__ */ Y(l, {
1267
1271
  direction: "horizontal",
1268
1272
  gap: "sm",
1269
1273
  justify: "between",
1270
1274
  wrap: !1,
1271
- children: [/* @__PURE__ */ K(r, {
1275
+ children: [/* @__PURE__ */ Y(o, {
1272
1276
  tag: "span",
1273
1277
  size: "xs",
1274
1278
  type: "secondary",
1275
1279
  children: [
1276
- i.length,
1280
+ n.length,
1277
1281
  " ",
1278
- _
1282
+ x
1279
1283
  ]
1280
- }), /* @__PURE__ */ G(n, {
1281
- onClick: m,
1284
+ }), /* @__PURE__ */ J(s, {
1285
+ onClick: _,
1282
1286
  tone: "secondary",
1283
1287
  buttonStyle: "ghost",
1284
1288
  size: "sm",
1285
- className: "h-auto px-space-sm py-0 text-muted-foreground hover:text-foreground",
1289
+ className: "text-muted-foreground hover:text-foreground",
1286
1290
  type: "button",
1287
- "aria-label": c.clearAll,
1288
- children: c.clearAll
1291
+ "aria-label": d.clearAll,
1292
+ children: d.clearAll
1289
1293
  })]
1290
- }), /* @__PURE__ */ G(s, {
1294
+ }), /* @__PURE__ */ J(l, {
1291
1295
  direction: "horizontal",
1292
1296
  gap: "md",
1293
- children: i.map((e) => /* @__PURE__ */ K(g, {
1297
+ children: n.map((e) => /* @__PURE__ */ Y(v, {
1294
1298
  tone: "secondary",
1295
1299
  className: "flex items-center gap-space-sm py-space-2xs pl-space-md pr-space-sm",
1296
- children: [/* @__PURE__ */ G(r, {
1300
+ children: [/* @__PURE__ */ J(o, {
1297
1301
  tag: "span",
1298
1302
  size: "xs",
1299
1303
  children: e
1300
- }), /* @__PURE__ */ G(n, {
1301
- onClick: () => f(e),
1302
- tone: "secondary",
1303
- buttonStyle: "ghost",
1304
- size: "sm",
1305
- iconOnly: !0,
1306
- className: "ml-space-sm size-icon rounded-full p-0 hover:bg-muted-foreground/20",
1304
+ }), /* @__PURE__ */ J("button", {
1305
+ onClick: () => h(e),
1306
+ className: r(y.target, y.focus, y.toggle),
1307
1307
  type: "button",
1308
- "aria-label": `${c.removeTag} ${e}`,
1309
- children: /* @__PURE__ */ G(q, { className: "size-icon-sm" })
1308
+ "aria-label": `${d.removeTag} ${e}`,
1309
+ children: /* @__PURE__ */ J(ve, {
1310
+ className: y.icon,
1311
+ "aria-hidden": "true"
1312
+ })
1310
1313
  })]
1311
1314
  }, e))
1312
1315
  })]
1313
1316
  }) : null;
1314
- return /* @__PURE__ */ K(s, {
1317
+ return /* @__PURE__ */ Y(l, {
1315
1318
  gap: "lg",
1316
- className: t("tags-facet--component", o),
1317
- children: [/* @__PURE__ */ K(s, {
1319
+ className: r("tags-facet--component", a),
1320
+ children: [/* @__PURE__ */ Y(l, {
1318
1321
  direction: "horizontal",
1319
1322
  gap: "md",
1320
1323
  wrap: !1,
1321
- children: [/* @__PURE__ */ G("div", {
1324
+ children: [/* @__PURE__ */ J("div", {
1322
1325
  className: "relative flex-1",
1323
- children: /* @__PURE__ */ G(w, {
1326
+ children: /* @__PURE__ */ J(A, {
1324
1327
  type: "text",
1325
- value: l,
1326
- onChange: (e) => u(e.target.value),
1327
- onKeyDown: p,
1328
- placeholder: e.placeholder ?? c.enterTag,
1329
- className: ge
1328
+ value: f,
1329
+ onChange: (e) => p(e.target.value),
1330
+ onKeyDown: g,
1331
+ placeholder: e.placeholder ?? d.enterTag
1330
1332
  })
1331
- }), /* @__PURE__ */ K(n, {
1332
- onClick: d,
1333
- disabled: !l.trim(),
1334
- size: "md",
1335
- className: ge,
1333
+ }), /* @__PURE__ */ Y(s, {
1334
+ tone: "primary",
1335
+ onClick: m,
1336
+ disabled: !f.trim(),
1337
+ size: u,
1338
+ iconOnly: !0,
1339
+ className: r(k[u], L[u]),
1336
1340
  type: "button",
1337
- children: [/* @__PURE__ */ G(de, { className: "size-icon" }), /* @__PURE__ */ G(r, {
1341
+ children: [/* @__PURE__ */ J(_e, { className: "size-icon" }), /* @__PURE__ */ J(o, {
1338
1342
  tag: "span",
1339
1343
  size: "pxs",
1340
1344
  className: "sr-only",
1341
- children: c.addTag
1345
+ children: d.addTag
1342
1346
  })]
1343
1347
  })]
1344
- }), v]
1348
+ }), S]
1345
1349
  });
1346
1350
  }
1347
- var Ye = R.memo(Je);
1348
- Ye.displayName = "TagsFacet";
1351
+ var rt = V.memo(nt);
1352
+ rt.displayName = "TagsFacet";
1349
1353
  //#endregion
1350
1354
  //#region src/components/features/filters/partials/tags-filter-content.tsx
1351
- function Xe({ filter: e, value: t, onFilterChange: r, onBackToFilterList: i, onClose: a, triggerSource: o = "chip" }) {
1352
- let { strings: s, reportError: c } = Q(), [l, u] = U(t || []), f = o === "toolbar", p = l.length === 1 ? s.tag : s.tags;
1353
- B(() => {
1355
+ function it({ filter: e, value: t, onFilterChange: n, onBackToFilterList: r, onClose: i, triggerSource: a = "chip" }) {
1356
+ let { strings: o, reportError: c } = $(), [l, u] = K(t || []), d = a === "toolbar", f = l.length === 1 ? o.tag : o.tags;
1357
+ U(() => {
1354
1358
  u(t || []);
1355
1359
  }, [t]);
1356
1360
  let m = () => {
1357
1361
  try {
1358
- r(l), a();
1362
+ n(l), i();
1359
1363
  } catch (t) {
1360
1364
  c(t, {
1361
1365
  phase: "apply",
@@ -1363,49 +1367,49 @@ function Xe({ filter: e, value: t, onFilterChange: r, onBackToFilterList: i, onC
1363
1367
  });
1364
1368
  }
1365
1369
  }, h = JSON.stringify(l.slice().sort()) !== JSON.stringify((t ?? []).slice().sort());
1366
- return /* @__PURE__ */ K("div", {
1370
+ return /* @__PURE__ */ Y("div", {
1367
1371
  className: "flex flex-col",
1368
1372
  children: [
1369
- /* @__PURE__ */ G(O, {
1370
- start: f ? /* @__PURE__ */ G(n, {
1373
+ /* @__PURE__ */ J(P, {
1374
+ start: d ? /* @__PURE__ */ J(s, {
1371
1375
  type: "button",
1372
1376
  tone: "secondary",
1373
1377
  buttonStyle: "ghost",
1374
1378
  size: "sm",
1375
1379
  iconOnly: !0,
1376
- onClick: i,
1380
+ onClick: r,
1377
1381
  className: "shrink-0",
1378
- "aria-label": s.backToFilters,
1379
- children: /* @__PURE__ */ G(se, {
1382
+ "aria-label": o.backToFilters,
1383
+ children: /* @__PURE__ */ J(pe, {
1380
1384
  "aria-hidden": "true",
1381
1385
  className: "size-icon-sm rtl:rotate-180"
1382
1386
  })
1383
1387
  }) : void 0,
1384
- children: /* @__PURE__ */ G(E, { children: e.label })
1388
+ children: /* @__PURE__ */ J(M, { children: e.label })
1385
1389
  }),
1386
- /* @__PURE__ */ G("div", {
1390
+ /* @__PURE__ */ J("div", {
1387
1391
  className: "p-surface",
1388
- children: /* @__PURE__ */ G(Ye, {
1392
+ children: /* @__PURE__ */ J(rt, {
1389
1393
  filter: e,
1390
1394
  value: l,
1391
1395
  onValueChange: u
1392
1396
  })
1393
1397
  }),
1394
- !!h && /* @__PURE__ */ G(A, {
1395
- caption: /* @__PURE__ */ K(d, {
1398
+ !!h && /* @__PURE__ */ J(I, {
1399
+ caption: /* @__PURE__ */ Y(p, {
1396
1400
  size: "xs",
1397
1401
  className: "tabular-nums",
1398
1402
  children: [
1399
1403
  l.length,
1400
1404
  " ",
1401
- p
1405
+ f
1402
1406
  ]
1403
1407
  }),
1404
- children: /* @__PURE__ */ G(n, {
1408
+ children: /* @__PURE__ */ J(s, {
1405
1409
  tone: "primary",
1406
1410
  size: "sm",
1407
1411
  onClick: m,
1408
- children: s.confirm
1412
+ children: o.confirm
1409
1413
  })
1410
1414
  })
1411
1415
  ]
@@ -1413,71 +1417,71 @@ function Xe({ filter: e, value: t, onFilterChange: r, onBackToFilterList: i, onC
1413
1417
  }
1414
1418
  //#endregion
1415
1419
  //#region src/components/features/filters/partials/filter-popover-content.tsx
1416
- function Ze({ activeFilterInPopover: e, availableFilters: n, activeFilters: r, getFilterValue: i, setFilterValue: a, onFilterSelect: o, onBackToFilterList: s, onClose: c, triggerSource: l = "chip", finalFocus: u }) {
1417
- let { strings: d } = Q(), f = e?.type === X.DATE || e?.type === X.TAGS ? "w-auto min-w-80 gap-0 overflow-hidden" : e?.type === X.ASYNC_SELECT ? "w-72 gap-0 overflow-hidden" : "w-64 gap-0 overflow-hidden", p = (e, t) => {
1420
+ function at({ activeFilterInPopover: e, availableFilters: t, activeFilters: n, getFilterValue: i, setFilterValue: a, onFilterSelect: o, onBackToFilterList: s, onClose: c, triggerSource: l = "chip", finalFocus: u }) {
1421
+ let { strings: d } = $(), f = e?.type === Z.DATE || e?.type === Z.TAGS ? "w-auto min-w-80 gap-0 overflow-hidden" : e?.type === Z.ASYNC_SELECT ? "w-72 gap-0 overflow-hidden" : "w-64 gap-0 overflow-hidden", p = (e, t) => {
1418
1422
  a(e, t);
1419
1423
  };
1420
- return /* @__PURE__ */ G(j, {
1424
+ return /* @__PURE__ */ J(ee, {
1421
1425
  finalFocus: u,
1422
- type: e?.type === X.DATE || e?.type === X.TAGS ? "display" : "menu",
1426
+ type: e?.type === Z.DATE || e?.type === Z.TAGS ? "display" : "menu",
1423
1427
  "aria-label": e?.label ?? d.addFilter,
1424
1428
  inset: "flush",
1425
- className: t("filter-popover-content--component", f),
1429
+ className: r("filter-popover-content--component", f),
1426
1430
  align: "start",
1427
- children: e ? e.type === X.DATE ? /* @__PURE__ */ G(Ue, {
1431
+ children: e ? e.type === Z.DATE ? /* @__PURE__ */ J(Xe, {
1428
1432
  filter: e,
1429
1433
  value: i(e.key),
1430
1434
  onFilterChange: (t) => p(e.key, t),
1431
1435
  onBackToFilterList: s,
1432
1436
  triggerSource: l
1433
- }) : e.type === X.TAGS ? /* @__PURE__ */ G(Xe, {
1437
+ }) : e.type === Z.TAGS ? /* @__PURE__ */ J(it, {
1434
1438
  filter: e,
1435
1439
  value: i(e.key),
1436
1440
  onFilterChange: (t) => p(e.key, t),
1437
1441
  onBackToFilterList: s,
1438
1442
  onClose: c,
1439
1443
  triggerSource: l
1440
- }) : e.type === X.ASYNC_SELECT ? /* @__PURE__ */ G(Be, {
1444
+ }) : e.type === Z.ASYNC_SELECT ? /* @__PURE__ */ J(qe, {
1441
1445
  filter: e,
1442
1446
  value: i(e.key),
1443
1447
  onFilterChange: (t) => p(e.key, t),
1444
1448
  onBackToFilterList: s,
1445
1449
  onClose: c,
1446
1450
  triggerSource: l
1447
- }) : /* @__PURE__ */ G(qe, {
1451
+ }) : /* @__PURE__ */ J(tt, {
1448
1452
  filter: e,
1449
1453
  value: i(e.key),
1450
1454
  onFilterChange: (t) => p(e.key, t),
1451
1455
  onBackToFilterList: s,
1452
1456
  onClose: c,
1453
1457
  triggerSource: l
1454
- }) : /* @__PURE__ */ G(Ke, {
1455
- availableFilters: n,
1456
- activeFilters: r,
1458
+ }) : /* @__PURE__ */ J(et, {
1459
+ availableFilters: t,
1460
+ activeFilters: n,
1457
1461
  onFilterSelect: o
1458
1462
  })
1459
1463
  });
1460
1464
  }
1461
1465
  //#endregion
1462
1466
  //#region src/components/features/filters/partials/filter-pill.tsx
1463
- function Qe({ filter: e, value: t, active: n, operator: r, operators: i, onOperatorChange: a, onValueChange: o, onClear: s, availableFilters: c, activeFilters: l, operatorChangeRef: u }) {
1464
- let d = H(!1), f = u ?? d, [p, m] = U(!1), h = H(null), g = H(null);
1465
- return /* @__PURE__ */ G($, {
1467
+ function ot({ filter: e, value: t, active: n, operator: r, operators: i, onOperatorChange: a, onValueChange: o, onClear: s, availableFilters: c, activeFilters: l, operatorChangeRef: u }) {
1468
+ let d = G(!1), f = u ?? d, [p, m] = K(!1), h = G(null), g = G(null);
1469
+ return /* @__PURE__ */ J(Qe, {
1466
1470
  filterKey: e.key,
1467
- children: /* @__PURE__ */ K(k, {
1471
+ children: /* @__PURE__ */ Y(F, {
1468
1472
  open: p,
1469
1473
  onOpenChange: (e) => {
1470
1474
  e && f.current || m(e);
1471
1475
  },
1472
- children: [/* @__PURE__ */ K("div", {
1476
+ children: [/* @__PURE__ */ Y("div", {
1473
1477
  className: "filter-pill--component filter-pill--anchor relative",
1474
- children: [/* @__PURE__ */ G(D, {
1475
- render: /* @__PURE__ */ G("span", {}),
1478
+ children: [/* @__PURE__ */ J(N, {
1479
+ render: /* @__PURE__ */ J("span", {}),
1476
1480
  nativeButton: !1,
1477
1481
  tabIndex: -1,
1478
1482
  "aria-hidden": "true",
1479
1483
  className: "pointer-events-none absolute inset-0"
1480
- }), /* @__PURE__ */ G(Le, {
1484
+ }), /* @__PURE__ */ J(We, {
1481
1485
  filter: e,
1482
1486
  popoverOpen: p,
1483
1487
  triggerRef: h,
@@ -1497,7 +1501,7 @@ function Qe({ filter: e, value: t, active: n, operator: r, operators: i, onOpera
1497
1501
  f.current || (g.current = e?.currentTarget ?? h.current, m(!0));
1498
1502
  }
1499
1503
  })]
1500
- }), /* @__PURE__ */ G(Ze, {
1504
+ }), /* @__PURE__ */ J(at, {
1501
1505
  finalFocus: g,
1502
1506
  activeFilterInPopover: e,
1503
1507
  availableFilters: c,
@@ -1512,42 +1516,42 @@ function Qe({ filter: e, value: t, active: n, operator: r, operators: i, onOpera
1512
1516
  })
1513
1517
  });
1514
1518
  }
1515
- Qe.displayName = "FilterPill";
1519
+ ot.displayName = "FilterPill";
1516
1520
  //#endregion
1517
1521
  //#region src/components/features/filters/partials/filters-button.tsx
1518
- function $e({ triggerRef: e, availableFilters: t, activeFilters: r, activeFilterInPopover: i, getFilterValue: a, setFilterValue: o, setActiveFilterInPopover: s }) {
1519
- let [c, l] = U(!1), { strings: u } = Q();
1520
- return B(() => {
1521
- c || s(null);
1522
- }, [c, s]), /* @__PURE__ */ K(k, {
1523
- open: c,
1524
- onOpenChange: l,
1525
- children: [/* @__PURE__ */ G(D, {
1522
+ function st({ triggerRef: e, availableFilters: n, activeFilters: i, activeFilterInPopover: a, getFilterValue: o, setFilterValue: c, setActiveFilterInPopover: l }) {
1523
+ let { defaultScale: u } = t(), d = O(void 0, u), [f, p] = K(!1), { strings: m } = $();
1524
+ return U(() => {
1525
+ f || l(null);
1526
+ }, [f, l]), /* @__PURE__ */ Y(F, {
1527
+ open: f,
1528
+ onOpenChange: p,
1529
+ children: [/* @__PURE__ */ J(N, {
1526
1530
  asChild: !0,
1527
- children: /* @__PURE__ */ G(n, {
1531
+ children: /* @__PURE__ */ J(s, {
1528
1532
  ref: e,
1529
1533
  tone: "secondary",
1530
1534
  buttonStyle: "outline",
1531
- size: "md",
1535
+ size: d,
1532
1536
  iconOnly: !0,
1533
- "aria-label": u.addFilter,
1534
- className: "filters-button--component shrink-0",
1535
- children: /* @__PURE__ */ G(le, { className: "size-icon-sm" })
1537
+ "aria-label": m.addFilter,
1538
+ className: r("filters-button--component shrink-0", k[d], L[d]),
1539
+ children: /* @__PURE__ */ J(he, { className: "size-icon-sm" })
1536
1540
  })
1537
- }), /* @__PURE__ */ G(Ze, {
1538
- activeFilterInPopover: i,
1539
- availableFilters: t,
1540
- activeFilters: r,
1541
- getFilterValue: a,
1542
- setFilterValue: o,
1541
+ }), /* @__PURE__ */ J(at, {
1542
+ activeFilterInPopover: a,
1543
+ availableFilters: n,
1544
+ activeFilters: i,
1545
+ getFilterValue: o,
1546
+ setFilterValue: c,
1543
1547
  onFilterSelect: (e) => {
1544
- s(e);
1548
+ l(e);
1545
1549
  },
1546
1550
  onBackToFilterList: () => {
1547
- s(null);
1551
+ l(null);
1548
1552
  },
1549
1553
  onClose: () => {
1550
- s(null), l(!1);
1554
+ l(null), p(!1);
1551
1555
  },
1552
1556
  triggerSource: "toolbar"
1553
1557
  })]
@@ -1555,73 +1559,72 @@ function $e({ triggerRef: e, availableFilters: t, activeFilters: r, activeFilter
1555
1559
  }
1556
1560
  //#endregion
1557
1561
  //#region src/components/features/filters/partials/filter-tabs.tsx
1558
- function et({ tabs: e }) {
1559
- let { activeFilters: n, filters: i, replaceFilters: a } = Q(), o = V(() => n.filter((e) => i.find((t) => t.key === e.key)?.type !== X.SEARCH), [n, i]), s = V(() => n.filter((e) => i.find((t) => t.key === e.key)?.type === X.SEARCH), [n, i]), c = V(() => {
1562
+ function ct({ tabs: e }) {
1563
+ let { activeFilters: t, filters: n, replaceFilters: i } = $(), a = W(() => t.filter((e) => n.find((t) => t.key === e.key)?.type !== Z.SEARCH), [t, n]), s = W(() => t.filter((e) => n.find((t) => t.key === e.key)?.type === Z.SEARCH), [t, n]), c = W(() => {
1560
1564
  for (let t of e) {
1561
1565
  if (t.presets.length === 0) {
1562
- if (o.length === 0) return t.id;
1566
+ if (a.length === 0) return t.id;
1563
1567
  continue;
1564
1568
  }
1565
- if (t.presets.length === o.length && t.presets.every((e) => {
1566
- let t = o.find((t) => t.key === e.key);
1569
+ if (t.presets.length === a.length && t.presets.every((e) => {
1570
+ let t = a.find((t) => t.key === e.key);
1567
1571
  if (!t) return !1;
1568
1572
  let n = [...e.value].sort(), r = [...t.value].sort();
1569
1573
  return !(n.length !== r.length || n.some((e, t) => e !== r[t]) || e.operator && t.operator !== e.operator);
1570
1574
  })) return t.id;
1571
1575
  }
1572
1576
  return null;
1573
- }, [e, o]), l = z((e) => {
1577
+ }, [e, a]), l = H((e) => {
1574
1578
  if (e.presets.length === 0) {
1575
- a([...s]);
1579
+ i([...s]);
1576
1580
  return;
1577
1581
  }
1578
1582
  let t = e.presets.map((e) => {
1579
- let t = i.find((t) => t.key === e.key), n = e.operator ?? t?.operator ?? (t ? we(t.type) : "equals");
1583
+ let t = n.find((t) => t.key === e.key), r = e.operator ?? t?.operator ?? (t ? je(t.type) : "equals");
1580
1584
  return {
1581
1585
  id: e.key,
1582
1586
  key: e.key,
1583
1587
  value: e.value,
1584
- operator: n
1588
+ operator: r
1585
1589
  };
1586
1590
  });
1587
- a([...s, ...t]);
1591
+ i([...s, ...t]);
1588
1592
  }, [
1589
- i,
1593
+ n,
1590
1594
  s,
1591
- a
1595
+ i
1592
1596
  ]);
1593
- return e.length === 0 ? null : /* @__PURE__ */ G(P, {
1597
+ return e.length === 0 ? null : /* @__PURE__ */ J(ne, {
1594
1598
  value: c,
1595
1599
  onValueChange: (t) => {
1596
1600
  let n = e.find((e) => e.id === t);
1597
1601
  n && l(n);
1598
1602
  },
1599
1603
  className: "filter-tabs--component",
1600
- children: /* @__PURE__ */ G(N, {
1604
+ children: /* @__PURE__ */ J(B, {
1601
1605
  role: "group",
1602
1606
  "aria-orientation": void 0,
1603
1607
  activateOnFocus: !0,
1604
1608
  className: "h-auto! flex-wrap justify-start gap-space-md bg-transparent p-0",
1605
1609
  children: e.map((e) => {
1606
- let n = c === e.id;
1607
- return /* @__PURE__ */ K(M, {
1610
+ let t = c === e.id;
1611
+ return /* @__PURE__ */ Y(z, {
1608
1612
  value: e.id,
1609
1613
  role: "button",
1610
1614
  "aria-selected": void 0,
1611
1615
  "aria-controls": void 0,
1612
- "aria-pressed": n,
1613
- className: t("h-action-sm flex-none rounded-radius-md px-control-sm py-0 transition-colors after:hidden data-active:bg-foreground data-active:text-background data-active:hover:bg-foreground data-active:hover:text-background", n ? "bg-foreground text-background" : "bg-muted text-muted-foreground hover:bg-accent hover:text-accent-foreground"),
1614
- children: [/* @__PURE__ */ G(r, {
1616
+ "aria-pressed": t,
1617
+ className: r("h-action-sm flex-none gap-space-sm rounded-inner px-control-sm py-0 transition-colors after:hidden data-active:bg-secondary data-active:text-secondary-foreground data-active:hover:bg-secondary data-active:hover:text-secondary-foreground", t ? "bg-secondary text-secondary-foreground" : "text-muted-foreground hover:bg-accent hover:text-accent-foreground"),
1618
+ children: [/* @__PURE__ */ J(o, {
1615
1619
  tag: "span",
1616
- weight: "semibold",
1620
+ weight: "medium",
1617
1621
  className: "text-inherit",
1618
1622
  children: e.label
1619
- }), e.count !== void 0 && /* @__PURE__ */ G(r, {
1623
+ }), e.count !== void 0 && /* @__PURE__ */ J(o, {
1620
1624
  tag: "span",
1621
1625
  size: "xs",
1622
- weight: "semibold",
1623
- numeric: !0,
1624
- className: t("ml-space-sm text-inherit", n ? "text-background" : "text-muted-foreground"),
1626
+ type: "secondary",
1627
+ className: "tabular-nums",
1625
1628
  children: e.count
1626
1629
  })]
1627
1630
  }, e.id);
@@ -1631,83 +1634,75 @@ function et({ tabs: e }) {
1631
1634
  }
1632
1635
  //#endregion
1633
1636
  //#region src/components/features/filters/facets/search-facet.tsx
1634
- function tt({ filter: e, value: r, onValueChange: i, className: a }) {
1635
- let { strings: o, isNavigating: s } = Q(), [c, l] = U(r[0] || ""), u = H(c);
1636
- u.current = c;
1637
- let d = H(r[0] || null), f = H(!1);
1638
- B(() => {
1639
- if (f.current || s) return;
1640
- let e = u.current;
1641
- if (!r.length || r[0] === "") {
1642
- e !== "" && (l(""), d.current = "");
1637
+ var lt = V.forwardRef(function(e, t) {
1638
+ return /* @__PURE__ */ J(ge, {
1639
+ ...e,
1640
+ ref: t,
1641
+ className: r("animate-spin", e.className)
1642
+ });
1643
+ });
1644
+ function ut({ filter: e, value: t, onValueChange: n, className: i }) {
1645
+ let { strings: a, isNavigating: o } = $(), [s, c] = K(t[0] || ""), l = G(s);
1646
+ U(() => {
1647
+ l.current = s;
1648
+ }, [s]);
1649
+ let u = G(t[0] || null), d = G(!1);
1650
+ U(() => {
1651
+ if (d.current || o) return;
1652
+ let e = l.current;
1653
+ if (!t.length || t[0] === "") {
1654
+ e !== "" && (c(""), u.current = "");
1643
1655
  return;
1644
1656
  }
1645
- r[0] !== void 0 && r[0] !== e && r[0] !== d.current && (l(r[0]), d.current = r[0]);
1646
- }, [r, s]);
1647
- let p = I((e) => {
1648
- d.current = e, f.current = !1, i([e]);
1649
- }, e.delay ?? 300), m = (e) => {
1650
- d.current !== e && p(e);
1657
+ t[0] !== void 0 && t[0] !== e && t[0] !== u.current && (c(t[0]), u.current = t[0]);
1658
+ }, [t, o]);
1659
+ let f = ie((e) => {
1660
+ u.current = e, d.current = !1, n([e]);
1661
+ }, e.delay ?? 300), p = (e) => {
1662
+ u.current !== e && f(e);
1651
1663
  };
1652
- return /* @__PURE__ */ K("div", {
1653
- className: t("search-facet--component", "search-facet relative w-full min-w-0 rounded-radius bg-background", a),
1654
- children: [
1655
- /* @__PURE__ */ G(w, {
1656
- type: "text",
1657
- "aria-label": e.label,
1658
- value: c,
1659
- onChange: (e) => {
1660
- f.current = !0;
1661
- let t = e.target.value;
1662
- l(t), m(t);
1663
- },
1664
- onFocus: () => {
1665
- f.current = !0;
1666
- },
1667
- onBlur: () => {
1668
- setTimeout(() => {
1669
- f.current = !1;
1670
- }, 100);
1671
- },
1672
- placeholder: e.placeholder ?? (() => {
1673
- let t = e.label.trim().toLowerCase();
1674
- return !t || t === "search" ? Y(o.searchPlaceholder, { filterLabel: "" }).replace(/\s+([….?!])/g, "$1").replace(/\s{2,}/g, " ").trim() : Y(o.searchPlaceholder, { filterLabel: t });
1675
- })(),
1676
- className: "w-full pr-9"
1677
- }),
1678
- c.trim() !== "" && !s && /* @__PURE__ */ G(n, {
1679
- type: "button",
1680
- tone: "secondary",
1681
- buttonStyle: "ghost",
1682
- size: "sm",
1683
- iconOnly: !0,
1684
- onClick: () => {
1685
- f.current = !0, l(""), m("");
1686
- },
1687
- className: "absolute right-control-gap-small top-1/2 -translate-y-1/2",
1688
- "aria-label": o.clearSearch,
1689
- children: /* @__PURE__ */ G(q, { className: "size-icon-sm" })
1690
- }),
1691
- !!s && /* @__PURE__ */ G("span", {
1692
- className: "text-muted-foreground absolute right-control-px top-1/2 -translate-y-1/2",
1693
- children: /* @__PURE__ */ G(ue, { className: "size-icon animate-spin" })
1694
- })
1695
- ]
1664
+ return /* @__PURE__ */ J("div", {
1665
+ className: r("search-facet--component", "search-facet relative w-full min-w-0 rounded-inner bg-background", i),
1666
+ children: /* @__PURE__ */ J(A, {
1667
+ type: "text",
1668
+ "aria-label": e.label,
1669
+ value: s,
1670
+ onChange: (e) => {
1671
+ d.current = !0;
1672
+ let t = e.target.value;
1673
+ c(t), p(t);
1674
+ },
1675
+ onFocus: () => {
1676
+ d.current = !0;
1677
+ },
1678
+ onBlur: () => {
1679
+ setTimeout(() => {
1680
+ d.current = !1;
1681
+ }, 100);
1682
+ },
1683
+ placeholder: e.placeholder ?? (() => {
1684
+ let t = e.label.trim().toLowerCase();
1685
+ return !t || t === "search" ? X(a.searchPlaceholder, { filterLabel: "" }).replace(/\s+([….?!])/g, "$1").replace(/\s{2,}/g, " ").trim() : X(a.searchPlaceholder, { filterLabel: t });
1686
+ })(),
1687
+ clearable: s.trim() !== "" && !o,
1688
+ endIcon: o ? lt : void 0,
1689
+ strings: { clear: a.clearSearch }
1690
+ })
1696
1691
  });
1697
1692
  }
1698
- var nt = R.memo(tt);
1699
- nt.displayName = "SearchFacet";
1693
+ var dt = V.memo(ut);
1694
+ dt.displayName = "SearchFacet";
1700
1695
  //#endregion
1701
1696
  //#region src/components/features/filters/partials/search-filters-list.tsx
1702
- function rt({ filters: e, getFilterValue: n, setFilterValue: i, className: a }) {
1703
- return /* @__PURE__ */ G(W, { children: e.map((e) => /* @__PURE__ */ K(s, {
1697
+ function ft({ filters: e, getFilterValue: t, setFilterValue: n, className: i }) {
1698
+ return /* @__PURE__ */ J(q, { children: e.map((e) => /* @__PURE__ */ Y(l, {
1704
1699
  gap: "lg",
1705
- className: t("search-filters-list--component", "w-full min-w-0 sm:w-64 sm:flex-none", e.displayConfig.className, a),
1706
- children: [/* @__PURE__ */ G(nt, {
1700
+ className: r("search-filters-list--component", "w-full min-w-0 sm:w-64 sm:flex-none", e.displayConfig.className, i),
1701
+ children: [/* @__PURE__ */ J(dt, {
1707
1702
  filter: e,
1708
- value: n(e.key),
1709
- onValueChange: (t) => i(e.key, t)
1710
- }), !!e.description && /* @__PURE__ */ G(r, {
1703
+ value: t(e.key),
1704
+ onValueChange: (t) => n(e.key, t)
1705
+ }), !!e.description && /* @__PURE__ */ J(o, {
1711
1706
  size: "xs",
1712
1707
  type: "secondary",
1713
1708
  children: e.description
@@ -1716,65 +1711,66 @@ function rt({ filters: e, getFilterValue: n, setFilterValue: i, className: a })
1716
1711
  }
1717
1712
  //#endregion
1718
1713
  //#region src/components/features/filters/filter-layout.tsx
1719
- var it = {
1714
+ var pt = {
1720
1715
  compact: "lg",
1721
1716
  default: "xl"
1722
- }, at = {
1717
+ }, mt = {
1723
1718
  compact: "sm",
1724
1719
  default: "md"
1725
1720
  };
1726
- function ot({ className: e, dynamicFilterOptions: i = {}, loadingFilters: a = {}, variant: o = "default", showClearFilters: c = !1, tabs: l }) {
1727
- let { getFilterValue: u, setFilterValue: d, isFilterActive: f, clearFilters: p, getFilterOperator: m, setFilterOperator: h, isNavigating: g, strings: _ } = Q(), { processedFilters: v, searchFilters: y, alwaysVisibleFilters: b, activeRegularFilters: x, popoverFilters: S, hasActive: C } = Oe({ dynamicFilterOptions: i }), [w, T] = U(null), E = v.find((e) => e.key === w) ?? null, D = z((e) => {
1721
+ function ht({ className: e, dynamicFilterOptions: t = {}, loadingFilters: n = {}, variant: i = "default", showClearFilters: a = !1, tabs: c }) {
1722
+ let { getFilterValue: u, setFilterValue: d, isFilterActive: f, clearFilters: p, getFilterOperator: m, setFilterOperator: h, isNavigating: g, strings: _ } = $(), { processedFilters: v, searchFilters: y, alwaysVisibleFilters: b, activeRegularFilters: x, popoverFilters: S, hasActive: C } = Fe({ dynamicFilterOptions: t }), [w, T] = K(null), E = v.find((e) => e.key === w) ?? null, D = H((e) => {
1728
1723
  T(e?.key ?? null);
1729
1724
  }, []);
1730
- B(() => {
1725
+ U(() => {
1731
1726
  w !== null && E === null && T(null);
1732
1727
  }, [w, E]);
1733
- let O = H(null), k = H(null);
1728
+ let O = G(null), k = G(null);
1734
1729
  function A(e, t) {
1735
1730
  t.length === 0 && e.displayConfig?.display !== "always" && (k.current = e.key), d(e.key, t);
1736
1731
  }
1737
- B(() => {
1732
+ U(() => {
1738
1733
  let e = k.current;
1739
1734
  e !== null && !f(e) && (O.current?.focus(), k.current = null);
1740
1735
  }, [f]);
1741
1736
  function j(e) {
1742
- return e.operators && e.operators.length > 0 ? e.operators : Ce(e.type, _.operators);
1737
+ return e.operators && e.operators.length > 0 ? e.operators : Ae(e.type, _.operators);
1743
1738
  }
1744
1739
  function M(e, t) {
1745
1740
  h(e, t);
1746
1741
  }
1747
- return /* @__PURE__ */ K(s, {
1748
- gap: it[o],
1749
- className: t("filter-layout--component", e),
1750
- children: [!!l && l.length > 0 && /* @__PURE__ */ G(et, { tabs: l }), /* @__PURE__ */ K(s, {
1742
+ return /* @__PURE__ */ Y(l, {
1743
+ gap: pt[i],
1744
+ className: r("filter-layout--component", e),
1745
+ children: [!!c && c.length > 0 && /* @__PURE__ */ J(ct, { tabs: c }), /* @__PURE__ */ Y(l, {
1751
1746
  direction: "horizontal",
1752
- gap: at[o],
1753
- children: [/* @__PURE__ */ G($, {
1747
+ align: "center",
1748
+ gap: mt[i],
1749
+ children: [/* @__PURE__ */ J(Qe, {
1754
1750
  filterKey: "search-filters",
1755
- children: /* @__PURE__ */ G(rt, {
1751
+ children: /* @__PURE__ */ J(ft, {
1756
1752
  filters: y,
1757
1753
  getFilterValue: u,
1758
1754
  setFilterValue: d
1759
1755
  })
1760
- }), /* @__PURE__ */ K("div", {
1761
- className: t("contents", g && "pointer-events-none opacity-60"),
1756
+ }), /* @__PURE__ */ Y("div", {
1757
+ className: r("contents", g && "pointer-events-none opacity-60"),
1762
1758
  children: [
1763
- Object.entries(a).filter(([, e]) => e).map(([e]) => {
1759
+ Object.entries(n).filter(([, e]) => e).map(([e]) => {
1764
1760
  let t = v.find((t) => t.key === e)?.label || e;
1765
- return /* @__PURE__ */ K(s, {
1761
+ return /* @__PURE__ */ Y(l, {
1766
1762
  direction: "horizontal",
1767
1763
  gap: "sm",
1768
1764
  wrap: !1,
1769
- className: "rounded-radius-md bg-muted/50 px-control-sm py-space-xs",
1770
- children: [/* @__PURE__ */ G("div", { className: "border-muted-foreground/30 border-t-primary size-icon-sm animate-spin rounded-full border-2" }), /* @__PURE__ */ G(r, {
1765
+ className: "rounded-radius bg-muted/50 px-control-sm py-space-xs",
1766
+ children: [/* @__PURE__ */ J("div", { className: "border-muted-foreground/30 border-t-primary size-icon-sm animate-spin rounded-full border-2" }), /* @__PURE__ */ J(o, {
1771
1767
  tag: "span",
1772
1768
  type: "secondary",
1773
- children: Y(_.loadingOptions, { filterLabel: t })
1769
+ children: X(_.loadingOptions, { filterLabel: t })
1774
1770
  })]
1775
1771
  }, `loading-${e}`);
1776
1772
  }),
1777
- [...b, ...x].map((e) => /* @__PURE__ */ G(Qe, {
1773
+ [...b, ...x].map((e) => /* @__PURE__ */ J(ot, {
1778
1774
  filter: e,
1779
1775
  value: u(e.key) ?? [],
1780
1776
  active: f(e.key),
@@ -1786,9 +1782,9 @@ function ot({ className: e, dynamicFilterOptions: i = {}, loadingFilters: a = {}
1786
1782
  availableFilters: S,
1787
1783
  activeFilters: [...x, ...b]
1788
1784
  }, e.key)),
1789
- S.length > 0 && /* @__PURE__ */ G($, {
1785
+ S.length > 0 && /* @__PURE__ */ J(Qe, {
1790
1786
  filterKey: "filters-button",
1791
- children: /* @__PURE__ */ G($e, {
1787
+ children: /* @__PURE__ */ J(st, {
1792
1788
  triggerRef: O,
1793
1789
  availableFilters: S,
1794
1790
  activeFilters: x,
@@ -1798,10 +1794,9 @@ function ot({ className: e, dynamicFilterOptions: i = {}, loadingFilters: a = {}
1798
1794
  setActiveFilterInPopover: D
1799
1795
  })
1800
1796
  }),
1801
- !!c && C && /* @__PURE__ */ G(n, {
1797
+ !!a && C && /* @__PURE__ */ J(s, {
1802
1798
  tone: "secondary",
1803
1799
  buttonStyle: "ghost",
1804
- size: "md",
1805
1800
  onClick: p,
1806
1801
  className: "text-muted-foreground ml-auto",
1807
1802
  children: _.clearFilters
@@ -1813,8 +1808,8 @@ function ot({ className: e, dynamicFilterOptions: i = {}, loadingFilters: a = {}
1813
1808
  }
1814
1809
  //#endregion
1815
1810
  //#region src/components/features/filters/filter-query.ts
1816
- var st = "__op", ct = ["page"], lt = new Set(Object.values(Z));
1817
- function ut(e) {
1811
+ var gt = "__op", _t = ["page"], vt = new Set(Object.values(Q));
1812
+ function yt(e) {
1818
1813
  let t = {};
1819
1814
  if (!e) return t;
1820
1815
  if (e instanceof URLSearchParams) return e.forEach((e, n) => {
@@ -1826,297 +1821,297 @@ function ut(e) {
1826
1821
  }
1827
1822
  return t;
1828
1823
  }
1829
- function dt(e) {
1824
+ function bt(e) {
1830
1825
  let t = {};
1831
1826
  for (let [n, r] of Object.entries(e)) r.length !== 0 && (t[n] = r.length === 1 ? r[0] : r);
1832
1827
  return t;
1833
1828
  }
1834
- function ft(e, t, n) {
1829
+ function xt(e, t, n) {
1835
1830
  let r = e[t] ?? [];
1836
1831
  return n === "comma" ? r.flatMap((e) => e.split(",")) : r;
1837
1832
  }
1838
- function pt(e, t) {
1833
+ function St(e, t) {
1839
1834
  return t.map((e) => e.trim()).filter((e) => e.length > 0).map((t) => {
1840
1835
  if (!e.parse) return t;
1841
1836
  let n = e.parse(t);
1842
1837
  return n == null ? "" : String(n);
1843
1838
  }).filter((e) => e.length > 0);
1844
1839
  }
1845
- function mt(e, t) {
1840
+ function Ct(e, t) {
1846
1841
  return t.map((t) => {
1847
1842
  let n = e.transform ? e.transform(t) : t, r = e.format ? e.format(n) : n;
1848
1843
  return r == null ? "" : String(r);
1849
1844
  }).filter((e) => e.length > 0);
1850
1845
  }
1851
- function ht(e) {
1852
- return e.operator ?? e.operators?.[0]?.value ?? we(e.type);
1846
+ function wt(e) {
1847
+ return e.operator ?? e.operators?.[0]?.value ?? je(e.type);
1853
1848
  }
1854
- function gt(e, t, n) {
1849
+ function Tt(e, t, n) {
1855
1850
  let [r] = t[`${e.key}${n}`] ?? [];
1856
- return r && lt.has(r) ? r : ht(e);
1851
+ return r && vt.has(r) ? r : wt(e);
1857
1852
  }
1858
- function _t(e, t, n) {
1853
+ function Et(e, t, n) {
1859
1854
  return e === "always" || e !== "never" && t !== n;
1860
1855
  }
1861
- function vt(e) {
1862
- return e.type === X.MULTI_SELECT || e.type === X.TAGS || e.multiple === !0;
1856
+ function Dt(e) {
1857
+ return e.type === Z.MULTI_SELECT || e.type === Z.TAGS || e.multiple === !0;
1863
1858
  }
1864
- function yt(e, t, n = {}) {
1865
- let r = n.operatorSuffix ?? st, i = n.arrayFormat ?? "repeat", a = ut(t);
1859
+ function Ot(e, t, n = {}) {
1860
+ let r = n.operatorSuffix ?? gt, i = n.arrayFormat ?? "repeat", a = yt(t);
1866
1861
  return e.flatMap((e) => {
1867
- let t = pt(e, ft(a, e.key, i));
1862
+ let t = St(e, xt(a, e.key, i));
1868
1863
  return t.length === 0 ? [] : [{
1869
1864
  id: e.key,
1870
1865
  key: e.key,
1871
- operator: gt(e, a, r),
1872
- value: vt(e) ? t : [t[0]]
1866
+ operator: Tt(e, a, r),
1867
+ value: Dt(e) ? t : [t[0]]
1873
1868
  }];
1874
1869
  });
1875
1870
  }
1876
- function bt(e, t, n, r = {}) {
1877
- let i = r.operatorSuffix ?? st, a = r.arrayFormat ?? "repeat", o = r.preserveUnrelated ?? !0, s = r.includeOperators ?? "changed", c = r.resetPageKeys ?? ct, l = o ? ut(n) : {}, u = new Map(e.map((e) => [e.key, e]));
1871
+ function kt(e, t, n, r = {}) {
1872
+ let i = r.operatorSuffix ?? gt, a = r.arrayFormat ?? "repeat", o = r.preserveUnrelated ?? !0, s = r.includeOperators ?? "changed", c = r.resetPageKeys ?? _t, l = o ? yt(n) : {}, u = new Map(e.map((e) => [e.key, e]));
1878
1873
  for (let t of e) delete l[t.key], delete l[`${t.key}${i}`];
1879
1874
  for (let e of c) delete l[e];
1880
1875
  for (let e of t) {
1881
1876
  let t = u.get(e.key);
1882
1877
  if (!t) continue;
1883
- let n = mt(t, e.value);
1878
+ let n = Ct(t, e.value);
1884
1879
  if (n.length === 0) continue;
1885
1880
  l[e.key] = a === "comma" ? [n.join(",")] : n;
1886
- let r = ht(t);
1887
- _t(s, e.operator, r) && (l[`${e.key}${i}`] = [e.operator]);
1881
+ let r = wt(t);
1882
+ Et(s, e.operator, r) && (l[`${e.key}${i}`] = [e.operator]);
1888
1883
  }
1889
- return dt(l);
1884
+ return bt(l);
1890
1885
  }
1891
- function xt(e, t, n = {}) {
1892
- let r = n.preserveUnrelated ?? !0, i = n.resetPageKeys ?? ct, a = r ? ut(e) : {}, o = ut(t);
1886
+ function At(e, t, n = {}) {
1887
+ let r = n.preserveUnrelated ?? !0, i = n.resetPageKeys ?? _t, a = r ? yt(e) : {}, o = yt(t);
1893
1888
  for (let e of i) delete a[e];
1894
1889
  for (let [e, t] of Object.entries(o)) t.length === 0 ? delete a[e] : a[e] = t;
1895
- return dt(a);
1890
+ return bt(a);
1896
1891
  }
1897
1892
  //#endregion
1898
1893
  //#region src/components/features/filters/facets/select-facet.tsx
1899
- function St({ filter: e, value: i, onValueChange: a, className: o }) {
1900
- let { strings: s } = Q(), [c, l] = U(!1), [u, d] = U(""), f = i.length > 0, p = e.options, m = (t) => {
1901
- e.multiple ? i.includes(t) ? a(i.filter((e) => e !== t)) : a([...i, t]) : (a([t]), e.closeOnSelect !== !1 && l(!1));
1902
- }, h = (e) => p?.find((t) => t.value === e)?.label ?? e, g = V(() => (p ?? []).map((e) => ({
1894
+ function jt({ filter: e, value: n, onValueChange: i, className: a }) {
1895
+ let { defaultScale: c } = t(), l = O(void 0, c), { strings: u } = $(), [d, f] = K(!1), [p, m] = K(""), h = n.length > 0, g = e.options, _ = (t) => {
1896
+ e.multiple ? n.includes(t) ? i(n.filter((e) => e !== t)) : i([...n, t]) : (i([t]), e.closeOnSelect !== !1 && f(!1));
1897
+ }, v = (e) => g?.find((t) => t.value === e)?.label ?? e, y = W(() => (g ?? []).map((e) => ({
1903
1898
  value: e.value,
1904
1899
  label: e.label,
1905
1900
  description: e.description,
1906
1901
  icon: e.icon,
1907
- selected: i.includes(e.value),
1902
+ selected: n.includes(e.value),
1908
1903
  disabled: e.disabled
1909
- })), [p, i]), _ = Y(s.searchPlaceholder, { filterLabel: e.label.toLowerCase() });
1910
- return /* @__PURE__ */ G("div", {
1911
- className: t("select-facet--component", "relative", o),
1912
- children: /* @__PURE__ */ G(F, {
1913
- open: c,
1914
- onOpenChange: l,
1904
+ })), [g, n]), b = X(u.searchPlaceholder, { filterLabel: e.label.toLowerCase() });
1905
+ return /* @__PURE__ */ J("div", {
1906
+ className: r("select-facet--component", "relative", a),
1907
+ children: /* @__PURE__ */ J(re, {
1908
+ open: d,
1909
+ onOpenChange: f,
1915
1910
  search: !0,
1916
- searchValue: u,
1917
- onSearchChange: d,
1911
+ searchValue: p,
1912
+ onSearchChange: m,
1918
1913
  strings: {
1919
- searchPlaceholder: _,
1920
- empty: s.noOptionsFound
1914
+ searchPlaceholder: b,
1915
+ empty: u.noOptionsFound
1921
1916
  },
1922
1917
  contentClassName: "w-(--anchor-width) min-w-56",
1923
- trigger: /* @__PURE__ */ K(n, {
1918
+ trigger: /* @__PURE__ */ Y(s, {
1924
1919
  tone: "secondary",
1925
1920
  buttonStyle: "outline",
1926
- size: "md",
1921
+ size: l,
1927
1922
  role: "combobox",
1928
- "aria-expanded": c,
1929
- className: "w-full justify-between",
1930
- children: [f ? i.length === 1 ? /* @__PURE__ */ G(r, {
1923
+ "aria-expanded": d,
1924
+ className: D(l),
1925
+ children: [h ? n.length === 1 ? /* @__PURE__ */ J(o, {
1931
1926
  tag: "span",
1932
1927
  weight: "semibold",
1933
1928
  className: "truncate",
1934
- children: h(i[0])
1935
- }) : /* @__PURE__ */ G(r, {
1929
+ children: v(n[0])
1930
+ }) : /* @__PURE__ */ J(o, {
1936
1931
  tag: "span",
1937
1932
  weight: "semibold",
1938
- children: Y(s.selected, {
1939
- count: i.length,
1940
- filterLabel: (i.length > 1 ? e.pluralLabel : e.label) ?? e.label
1933
+ children: X(u.selected, {
1934
+ count: n.length,
1935
+ filterLabel: (n.length > 1 ? e.pluralLabel : e.label) ?? e.label
1941
1936
  })
1942
- }) : /* @__PURE__ */ G(r, {
1937
+ }) : /* @__PURE__ */ J(o, {
1943
1938
  tag: "span",
1944
1939
  type: "secondary",
1945
- children: e.placeholder ?? s.select
1946
- }), /* @__PURE__ */ G(ce, { className: "ml-control-gap-small size-icon-sm shrink-0 opacity-50" })]
1940
+ children: e.placeholder ?? u.select
1941
+ }), /* @__PURE__ */ J(me, { className: "ml-control-gap-small size-icon-sm shrink-0 opacity-50" })]
1947
1942
  }),
1948
- items: g,
1949
- onSelect: (e) => m(e.value)
1943
+ items: y,
1944
+ onSelect: (e) => _(e.value)
1950
1945
  })
1951
1946
  });
1952
1947
  }
1953
1948
  //#endregion
1954
1949
  //#region src/components/features/filters/facets/async-select-facet.tsx
1955
- function Ct({ filter: e, value: i, onValueChange: a, className: o }) {
1956
- let { strings: u, cacheAsyncOptions: d, getAsyncOptionLabel: f, reportError: p } = Q(), [m, h] = U(!1), [g, S] = U(""), w = V(() => /* @__PURE__ */ new Map(), [
1950
+ function Mt({ filter: e, value: n, onValueChange: i, className: a }) {
1951
+ let { defaultScale: c } = t(), f = O(void 0, c), { strings: p, cacheAsyncOptions: m, getAsyncOptionLabel: h, reportError: g } = $(), [_, v] = K(!1), [y, T] = K(""), k = W(() => /* @__PURE__ */ new Map(), [
1957
1952
  e.key,
1958
1953
  e.asyncConfig?.fetcher,
1959
1954
  e.asyncConfig?.mapToOption
1960
- ]), { options: T, isLoading: E, isFetching: O, isError: A, refetch: M, isBelowMinQuery: N, minQueryLength: P } = ze(e, g, m, { onError: p });
1961
- B(() => {
1962
- if (T.length !== 0) {
1963
- for (let e of T) w.set(e.value, e);
1964
- d(e.key, T);
1955
+ ]), { options: A, isLoading: j, isFetching: M, isError: P, refetch: I, isBelowMinQuery: L, minQueryLength: R } = Ke(e, y, _, { onError: g });
1956
+ U(() => {
1957
+ if (A.length !== 0) {
1958
+ for (let e of A) k.set(e.value, e);
1959
+ m(e.key, A);
1965
1960
  }
1966
1961
  }, [
1967
- d,
1962
+ m,
1968
1963
  e.key,
1969
- w,
1970
- T
1964
+ k,
1965
+ A
1971
1966
  ]);
1972
- let F = e.multiple !== !1, I = e.maxSelected, L = V(() => e.options ?? [], [e.options]), R = V(() => {
1973
- let t = new Set(i), n = new Set([...L, ...T].map((e) => e.value)), r = [];
1974
- for (let t of i) if (!n.has(t)) {
1975
- let n = w.get(t);
1976
- if (n) r.push(n);
1967
+ let te = e.multiple !== !1, z = e.maxSelected, B = W(() => e.options ?? [], [e.options]), ne = W(() => {
1968
+ let t = new Set(n), r = new Set([...B, ...A].map((e) => e.value)), i = [];
1969
+ for (let t of n) if (!r.has(t)) {
1970
+ let n = k.get(t);
1971
+ if (n) i.push(n);
1977
1972
  else {
1978
- let n = L.find((e) => e.value === t);
1973
+ let n = B.find((e) => e.value === t);
1979
1974
  if (n) {
1980
- r.push(n);
1975
+ i.push(n);
1981
1976
  continue;
1982
1977
  }
1983
- let i = f(e.key, t);
1984
- i && r.push({
1978
+ let r = h(e.key, t);
1979
+ r && i.push({
1985
1980
  value: t,
1986
- label: i,
1981
+ label: r,
1987
1982
  icon: e.icon
1988
1983
  });
1989
1984
  }
1990
1985
  }
1991
1986
  return [
1992
- ...r,
1993
- ...L,
1994
- ...T
1987
+ ...i,
1988
+ ...B,
1989
+ ...A
1995
1990
  ].sort((e, n) => +!t.has(e.value) - !t.has(n.value));
1996
1991
  }, [
1997
- L,
1998
- T,
1999
- i,
1992
+ B,
1993
+ A,
1994
+ n,
2000
1995
  e.key,
2001
1996
  e.icon,
2002
- w,
2003
- f
2004
- ]), ee = (t) => {
2005
- if (F) {
2006
- if (i.includes(t)) a(i.filter((e) => e !== t));
1997
+ k,
1998
+ h
1999
+ ]), re = (t) => {
2000
+ if (te) {
2001
+ if (n.includes(t)) i(n.filter((e) => e !== t));
2007
2002
  else {
2008
- if (I && i.length >= I) return;
2009
- a([...i, t]);
2003
+ if (z && n.length >= z) return;
2004
+ i([...n, t]);
2010
2005
  }
2011
- } else a([t]), e.closeOnSelect !== !1 && h(!1);
2012
- }, te = (t) => {
2013
- let n = T.find((e) => e.value === t);
2006
+ } else i([t]), e.closeOnSelect !== !1 && v(!1);
2007
+ }, ie = (t) => {
2008
+ let n = A.find((e) => e.value === t);
2014
2009
  if (n) return n.label;
2015
- let r = L.find((e) => e.value === t);
2010
+ let r = B.find((e) => e.value === t);
2016
2011
  if (r) return r.label;
2017
- let i = w.get(t);
2018
- return i ? i.label : f(e.key, t) ?? t;
2019
- }, z = i.length > 0, ne = V(() => E || O ? /* @__PURE__ */ G(c, {
2012
+ let i = k.get(t);
2013
+ return i ? i.label : h(e.key, t) ?? t;
2014
+ }, ae = n.length > 0, V = W(() => j || M ? /* @__PURE__ */ J(u, {
2020
2015
  className: "async-select-facet--component",
2021
- label: u.searching
2022
- }) : A ? /* @__PURE__ */ G(l, {
2016
+ label: p.searching
2017
+ }) : P ? /* @__PURE__ */ J(d, {
2023
2018
  variant: "inline",
2024
- title: u.fetchError,
2025
- action: /* @__PURE__ */ G(n, {
2019
+ title: p.fetchError,
2020
+ action: /* @__PURE__ */ J(s, {
2026
2021
  tone: "secondary",
2027
2022
  buttonStyle: "outline",
2028
2023
  size: "sm",
2029
2024
  onClick: (e) => {
2030
- e.stopPropagation(), M();
2025
+ e.stopPropagation(), I();
2031
2026
  },
2032
- children: u.retryFetch
2027
+ children: p.retryFetch
2033
2028
  })
2034
- }) : N ? /* @__PURE__ */ G("div", {
2029
+ }) : L ? /* @__PURE__ */ J("div", {
2035
2030
  className: "text-muted-foreground flex items-center justify-center py-space-xl",
2036
- children: /* @__PURE__ */ G(r, {
2031
+ children: /* @__PURE__ */ J(o, {
2037
2032
  tag: "span",
2038
2033
  size: "xs",
2039
2034
  type: "secondary",
2040
- children: Y(u.minQueryHint, { min: P })
2035
+ children: X(p.minQueryHint, { min: R })
2041
2036
  })
2042
- }) : /* @__PURE__ */ G(r, {
2037
+ }) : /* @__PURE__ */ J(o, {
2043
2038
  tag: "span",
2044
2039
  type: "secondary",
2045
- children: u.noOptionsFound
2040
+ children: p.noOptionsFound
2046
2041
  }), [
2047
- E,
2048
- O,
2049
- A,
2050
- N,
2042
+ j,
2043
+ M,
2051
2044
  P,
2052
- u,
2053
- M
2045
+ L,
2046
+ R,
2047
+ p,
2048
+ I
2054
2049
  ]);
2055
- return /* @__PURE__ */ G("div", {
2056
- className: t("async-select-facet--component relative", o),
2057
- children: /* @__PURE__ */ K(k, {
2058
- open: m,
2050
+ return /* @__PURE__ */ J("div", {
2051
+ className: r("async-select-facet--component relative", a),
2052
+ children: /* @__PURE__ */ Y(F, {
2053
+ open: _,
2059
2054
  onOpenChange: (e) => {
2060
- h(e), e || S("");
2055
+ v(e), e || T("");
2061
2056
  },
2062
- children: [/* @__PURE__ */ G(D, { render: /* @__PURE__ */ K(n, {
2057
+ children: [/* @__PURE__ */ J(N, { render: /* @__PURE__ */ Y(s, {
2063
2058
  tone: "secondary",
2064
2059
  buttonStyle: "outline",
2065
- size: "md",
2060
+ size: f,
2066
2061
  role: "combobox",
2067
- "aria-expanded": m,
2068
- className: "w-full justify-between",
2069
- children: [z ? i.length === 1 ? /* @__PURE__ */ G(r, {
2062
+ "aria-expanded": _,
2063
+ className: D(f),
2064
+ children: [ae ? n.length === 1 ? /* @__PURE__ */ J(o, {
2070
2065
  tag: "span",
2071
2066
  weight: "semibold",
2072
2067
  className: "truncate",
2073
- children: te(i[0])
2074
- }) : /* @__PURE__ */ G(r, {
2068
+ children: ie(n[0])
2069
+ }) : /* @__PURE__ */ J(o, {
2075
2070
  tag: "span",
2076
2071
  weight: "semibold",
2077
- children: Y(u.selected, {
2078
- count: i.length,
2079
- filterLabel: (i.length > 1 ? e.pluralLabel : e.label) ?? e.label
2072
+ children: X(p.selected, {
2073
+ count: n.length,
2074
+ filterLabel: (n.length > 1 ? e.pluralLabel : e.label) ?? e.label
2080
2075
  })
2081
- }) : /* @__PURE__ */ G(r, {
2076
+ }) : /* @__PURE__ */ J(o, {
2082
2077
  tag: "span",
2083
2078
  type: "secondary",
2084
- children: e.placeholder ?? u.select
2085
- }), /* @__PURE__ */ G(ce, { className: "ml-control-gap-small size-icon-sm shrink-0 opacity-50" })]
2086
- }) }), /* @__PURE__ */ G(j, {
2079
+ children: e.placeholder ?? p.select
2080
+ }), /* @__PURE__ */ J(me, { className: "ml-control-gap-small size-icon-sm shrink-0 opacity-50" })]
2081
+ }) }), /* @__PURE__ */ J(ee, {
2087
2082
  type: "menu",
2088
2083
  inset: "flush",
2089
2084
  className: "w-full min-w-70 gap-0",
2090
- children: /* @__PURE__ */ K(C, {
2085
+ children: /* @__PURE__ */ Y(E, {
2091
2086
  shouldFilter: !1,
2092
2087
  inset: "flush",
2093
2088
  className: "rounded-none",
2094
- children: [/* @__PURE__ */ G(v, {
2095
- placeholder: Y(u.searchPlaceholder, { filterLabel: e.label }),
2096
- value: g,
2097
- onValueChange: S
2098
- }), /* @__PURE__ */ G(b, { children: R.length === 0 ? /* @__PURE__ */ G(y, { children: ne }) : /* @__PURE__ */ K(x, { children: [!(!O || E) && /* @__PURE__ */ K(s, {
2089
+ children: [/* @__PURE__ */ J(x, {
2090
+ placeholder: X(p.searchPlaceholder, { filterLabel: e.label }),
2091
+ value: y,
2092
+ onValueChange: T
2093
+ }), /* @__PURE__ */ J(C, { children: ne.length === 0 ? /* @__PURE__ */ J(S, { children: V }) : /* @__PURE__ */ Y(w, { children: [!(!M || j) && /* @__PURE__ */ Y(l, {
2099
2094
  direction: "horizontal",
2100
2095
  gap: "sm",
2101
2096
  wrap: !1,
2102
2097
  className: "px-control-sm py-space-xs",
2103
- children: [/* @__PURE__ */ G(ue, { className: "text-muted-foreground size-icon-sm animate-spin" }), /* @__PURE__ */ G(r, {
2098
+ children: [/* @__PURE__ */ J(ge, { className: "text-muted-foreground size-icon-sm animate-spin" }), /* @__PURE__ */ J(o, {
2104
2099
  tag: "span",
2105
2100
  size: "xs",
2106
2101
  type: "secondary",
2107
- children: u.searching
2102
+ children: p.searching
2108
2103
  })]
2109
- }), R.map((e) => /* @__PURE__ */ K(_, {
2104
+ }), ne.map((e) => /* @__PURE__ */ Y(b, {
2110
2105
  value: e.value,
2111
- onSelect: () => ee(e.value),
2112
- disabled: e.disabled || !!I && i.length >= I && !i.includes(e.value),
2106
+ onSelect: () => re(e.value),
2107
+ disabled: e.disabled || !!z && n.length >= z && !n.includes(e.value),
2113
2108
  children: [
2114
- /* @__PURE__ */ G(ae, { className: t("mr-control-gap size-icon-sm", i.includes(e.value) ? "opacity-100" : "opacity-0") }),
2115
- !!e.icon && /* @__PURE__ */ G("span", {
2109
+ /* @__PURE__ */ J(de, { className: r("mr-control-gap size-icon-sm", n.includes(e.value) ? "opacity-100" : "opacity-0") }),
2110
+ !!e.icon && /* @__PURE__ */ J("span", {
2116
2111
  className: "mr-1.5",
2117
2112
  children: e.icon
2118
2113
  }),
2119
- /* @__PURE__ */ G(r, {
2114
+ /* @__PURE__ */ J(o, {
2120
2115
  tag: "span",
2121
2116
  children: e.label
2122
2117
  })
@@ -2129,48 +2124,48 @@ function Ct({ filter: e, value: i, onValueChange: a, className: o }) {
2129
2124
  }
2130
2125
  //#endregion
2131
2126
  //#region src/components/features/filters/facets/range-facet.tsx
2132
- function wt({ filter: e, value: n, onValueChange: r, className: a }) {
2133
- let { strings: c } = Q(), [l, u] = U(n.min?.toString() ?? ""), [d, f] = U(n.max?.toString() ?? ""), p = re(), m = I((e) => {
2134
- (e.min !== n.min || e.max !== n.max) && r(e);
2127
+ function Nt({ filter: e, value: t, onValueChange: n, className: i }) {
2128
+ let { strings: o } = $(), [s, u] = K(t.min?.toString() ?? ""), [d, f] = K(t.max?.toString() ?? ""), p = le(), m = ie((e) => {
2129
+ (e.min !== t.min || e.max !== t.max) && n(e);
2135
2130
  }, e.delay ?? 300);
2136
- return B(() => (m({
2137
- min: l ? Number(l) : void 0,
2131
+ return U(() => (m({
2132
+ min: s ? Number(s) : void 0,
2138
2133
  max: d ? Number(d) : void 0
2139
2134
  }), m.cancel), [
2140
- l,
2135
+ s,
2141
2136
  d,
2142
2137
  m
2143
- ]), /* @__PURE__ */ G(s, {
2138
+ ]), /* @__PURE__ */ J(l, {
2144
2139
  gap: "md",
2145
- className: t("range-facet--component", a),
2146
- children: /* @__PURE__ */ K(o, {
2140
+ className: r("range-facet--component", i),
2141
+ children: /* @__PURE__ */ Y(c, {
2147
2142
  columns: {
2148
2143
  base: 1,
2149
2144
  sm: 2
2150
2145
  },
2151
2146
  gap: "md",
2152
- children: [/* @__PURE__ */ K(s, {
2147
+ children: [/* @__PURE__ */ Y(l, {
2153
2148
  gap: "xs",
2154
- children: [/* @__PURE__ */ G(i, {
2149
+ children: [/* @__PURE__ */ J(a, {
2155
2150
  htmlFor: `${p}-min`,
2156
- children: c.min
2157
- }), /* @__PURE__ */ G(w, {
2151
+ children: o.min
2152
+ }), /* @__PURE__ */ J(A, {
2158
2153
  id: `${p}-min`,
2159
2154
  type: "text",
2160
- value: l,
2155
+ value: s,
2161
2156
  onChange: (e) => {
2162
2157
  let t = e.target.value;
2163
2158
  (t === "" || /^\d*\.?\d*$/.test(t)) && u(t);
2164
2159
  },
2165
- placeholder: c.min,
2160
+ placeholder: o.min,
2166
2161
  className: "w-full"
2167
2162
  })]
2168
- }), /* @__PURE__ */ K(s, {
2163
+ }), /* @__PURE__ */ Y(l, {
2169
2164
  gap: "xs",
2170
- children: [/* @__PURE__ */ G(i, {
2165
+ children: [/* @__PURE__ */ J(a, {
2171
2166
  htmlFor: `${p}-max`,
2172
- children: c.max
2173
- }), /* @__PURE__ */ G(w, {
2167
+ children: o.max
2168
+ }), /* @__PURE__ */ J(A, {
2174
2169
  id: `${p}-max`,
2175
2170
  type: "text",
2176
2171
  value: d,
@@ -2178,7 +2173,7 @@ function wt({ filter: e, value: n, onValueChange: r, className: a }) {
2178
2173
  let t = e.target.value;
2179
2174
  (t === "" || /^\d*\.?\d*$/.test(t)) && f(t);
2180
2175
  },
2181
- placeholder: c.max,
2176
+ placeholder: o.max,
2182
2177
  className: "w-full"
2183
2178
  })]
2184
2179
  })]
@@ -2187,17 +2182,17 @@ function wt({ filter: e, value: n, onValueChange: r, className: a }) {
2187
2182
  }
2188
2183
  //#endregion
2189
2184
  //#region src/components/features/filters/validators.ts
2190
- function Tt(e) {
2185
+ function Pt(e) {
2191
2186
  return (t) => {
2192
2187
  if (t == null || typeof t == "string" && t.length === 0) return !0;
2193
2188
  let n = e.safeParse(t);
2194
2189
  return n.success ? !0 : n.error?.issues?.[0]?.message ?? n.error?.message ?? !1;
2195
2190
  };
2196
2191
  }
2197
- function Et(e, t) {
2192
+ function Ft(e, t) {
2198
2193
  return (n) => e(n) ? !0 : t;
2199
2194
  }
2200
2195
  //#endregion
2201
- export { Ce as A, Oe as C, xe as D, Se as E, _e as F, me as I, he as L, ve as M, Z as N, we as O, X as P, Y as R, ke as S, Q as T, $ as _, St as a, Le as b, bt as c, nt as d, et as f, Ye as g, Ze as h, Ct as i, ye as j, be as k, ot as l, Qe as m, Tt as n, xt as o, $e as p, wt as r, yt as s, Et as t, rt as u, He as v, De as w, Ae as x, ze as y };
2196
+ export { Ae as A, Fe as C, Oe as D, ke as E, we as F, Se as I, Ce as L, Te as M, Q as N, je as O, Z as P, X as R, Ie as S, $ as T, Qe as _, jt as a, We as b, kt as c, dt as d, ct as f, rt as g, at as h, Mt as i, Ee as j, De as k, ht as l, ot as m, Pt as n, At as o, st as p, Nt as r, Ot as s, Ft as t, ft as u, Ye as v, Pe as w, Le as x, Ke as y };
2202
2197
 
2203
- //# sourceMappingURL=filters-BhsUtsxW.js.map
2198
+ //# sourceMappingURL=filters-Da-gNPsE.js.map