@adyen/bento-vue2 2.0.0 → 2.0.1-rc.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 (229) hide show
  1. package/dist/action-bar.js +1 -1
  2. package/dist/ai-tag.js +1 -1
  3. package/dist/alert.js +1 -1
  4. package/dist/assets/accordion-item.css +1 -1
  5. package/dist/assets/action-bar.css +1 -1
  6. package/dist/assets/base-modal.css +1 -1
  7. package/dist/assets/button-actions.css +1 -1
  8. package/dist/assets/card.css +1 -1
  9. package/dist/assets/data-grid.css +1 -1
  10. package/dist/assets/date-filter.css +1 -0
  11. package/dist/assets/date-range-filter.css +1 -0
  12. package/dist/assets/dialog-page.css +1 -1
  13. package/dist/assets/file-uploader.css +1 -1
  14. package/dist/assets/filter-bar.css +1 -1
  15. package/dist/assets/input-with-dropdown-filter.css +1 -0
  16. package/dist/assets/inspector.css +1 -1
  17. package/dist/assets/modal-fullscreen.css +1 -1
  18. package/dist/assets/navigation-menu-group.css +1 -1
  19. package/dist/assets/secondary-nav.css +1 -1
  20. package/dist/assets/sidepanel.css +1 -1
  21. package/dist/button.js +1 -1
  22. package/dist/card.js +1 -1
  23. package/dist/checkbox.js +2 -2
  24. package/dist/chunks/{action-bar.BsXW7BI2.js → action-bar.KJSfr89B.js} +3 -3
  25. package/dist/chunks/{action-bar.BsXW7BI2.js.map → action-bar.KJSfr89B.js.map} +1 -1
  26. package/dist/chunks/{ai-tag.D2Q0xhFK.js → ai-tag.TLrUno9t.js} +2 -2
  27. package/dist/chunks/{ai-tag.D2Q0xhFK.js.map → ai-tag.TLrUno9t.js.map} +1 -1
  28. package/dist/chunks/{alert.DJDHwVeR.js → alert.DT6T5Uxb.js} +52 -70
  29. package/dist/chunks/alert.DT6T5Uxb.js.map +1 -0
  30. package/dist/chunks/{base-modal.CcmoTJdc.js → base-modal.CGHkdr9t.js} +4 -4
  31. package/dist/chunks/{base-modal.CcmoTJdc.js.map → base-modal.CGHkdr9t.js.map} +1 -1
  32. package/dist/chunks/{button-actions-with-menu.BY394ars.js → button-actions-with-menu.CjTaZoYW.js} +2 -2
  33. package/dist/chunks/{button-actions-with-menu.BY394ars.js.map → button-actions-with-menu.CjTaZoYW.js.map} +1 -1
  34. package/dist/chunks/{button-actions.bkcLUE1G.js → button-actions.sLmpjWGK.js} +2 -2
  35. package/dist/chunks/{button-actions.bkcLUE1G.js.map → button-actions.sLmpjWGK.js.map} +1 -1
  36. package/dist/chunks/{calendar.CXdLEeN4.js → calendar.BNRImpE_.js} +18 -18
  37. package/dist/chunks/{calendar.CXdLEeN4.js.map → calendar.BNRImpE_.js.map} +1 -1
  38. package/dist/chunks/{card.b9PEJ7hm.js → card.DmnYYMmv.js} +3 -3
  39. package/dist/chunks/{card.b9PEJ7hm.js.map → card.DmnYYMmv.js.map} +1 -1
  40. package/dist/chunks/{checkbox-group.UYN1ljai.js → checkbox-group.D1SE-hz6.js} +3 -3
  41. package/dist/chunks/{checkbox-group.UYN1ljai.js.map → checkbox-group.D1SE-hz6.js.map} +1 -1
  42. package/dist/chunks/{checkbox.Co4HoHKF.js → checkbox.CyGdeEdp.js} +14 -14
  43. package/dist/chunks/{checkbox.Co4HoHKF.js.map → checkbox.CyGdeEdp.js.map} +1 -1
  44. package/dist/chunks/{code-snippet.CnThWqVb.js → code-snippet.BwswvtkY.js} +4 -4
  45. package/dist/chunks/{code-snippet.CnThWqVb.js.map → code-snippet.BwswvtkY.js.map} +1 -1
  46. package/dist/chunks/{controls-group.fdGc6epa.js → controls-group.DUNvd6DZ.js} +2 -2
  47. package/dist/chunks/{controls-group.fdGc6epa.js.map → controls-group.DUNvd6DZ.js.map} +1 -1
  48. package/dist/chunks/{copy.CSk1rCRo.js → copy.DSnfQU_F.js} +3 -3
  49. package/dist/chunks/{copy.CSk1rCRo.js.map → copy.DSnfQU_F.js.map} +1 -1
  50. package/dist/chunks/{dashboard-section.CYEoNH9Q.js → dashboard-section.CowwqnVA.js} +3 -3
  51. package/dist/chunks/{dashboard-section.CYEoNH9Q.js.map → dashboard-section.CowwqnVA.js.map} +1 -1
  52. package/dist/chunks/{dashed-underline.CzKc-fJW.js → dashed-underline.dNu0qaf7.js} +3 -3
  53. package/dist/chunks/{dashed-underline.CzKc-fJW.js.map → dashed-underline.dNu0qaf7.js.map} +1 -1
  54. package/dist/chunks/{data-grid-template.DCwzh2G7.js → data-grid-template.D5699UWb.js} +4 -4
  55. package/dist/chunks/{data-grid-template.DCwzh2G7.js.map → data-grid-template.D5699UWb.js.map} +1 -1
  56. package/dist/chunks/{data-grid.B1lI07ze.js → data-grid.CN25cWaQ.js} +18 -18
  57. package/dist/chunks/{data-grid.B1lI07ze.js.map → data-grid.CN25cWaQ.js.map} +1 -1
  58. package/dist/chunks/date-filter.BZVe74cH.js +117 -0
  59. package/dist/chunks/date-filter.BZVe74cH.js.map +1 -0
  60. package/dist/chunks/{date-picker.gDsw8bn1.js → date-picker.DhIMx1wH.js} +7 -7
  61. package/dist/chunks/{date-picker.gDsw8bn1.js.map → date-picker.DhIMx1wH.js.map} +1 -1
  62. package/dist/chunks/date-range-filter.CDrrP22U.js +868 -0
  63. package/dist/chunks/date-range-filter.CDrrP22U.js.map +1 -0
  64. package/dist/chunks/{date-range-picker.CqixIJxG.js → date-range-picker.Cz6ijJAa.js} +39 -39
  65. package/dist/chunks/{date-range-picker.CqixIJxG.js.map → date-range-picker.Cz6ijJAa.js.map} +1 -1
  66. package/dist/chunks/{date-time-picker.Bktntun4.js → date-time-picker.CHELyYSN.js} +5 -5
  67. package/dist/chunks/{date-time-picker.Bktntun4.js.map → date-time-picker.CHELyYSN.js.map} +1 -1
  68. package/dist/chunks/{draggable-handle.DgVdGC1V.js → draggable-handle.C75v14oN.js} +2 -2
  69. package/dist/chunks/{draggable-handle.DgVdGC1V.js.map → draggable-handle.C75v14oN.js.map} +1 -1
  70. package/dist/chunks/{draggable.DYKdXdbj.js → draggable.COHEAPF5.js} +2 -2
  71. package/dist/chunks/{draggable.DYKdXdbj.js.map → draggable.COHEAPF5.js.map} +1 -1
  72. package/dist/chunks/{dropdown-tag.Dk7SooVv.js → dropdown-tag.DKGloEzh.js} +3 -3
  73. package/dist/chunks/{dropdown-tag.Dk7SooVv.js.map → dropdown-tag.DKGloEzh.js.map} +1 -1
  74. package/dist/chunks/{dropdown.Bnq4kP7k.js → dropdown.QLkWJ9zk.js} +5 -5
  75. package/dist/chunks/{dropdown.Bnq4kP7k.js.map → dropdown.QLkWJ9zk.js.map} +1 -1
  76. package/dist/chunks/{empty-state.C2wjdE3y.js → empty-state.CRdHhJLl.js} +2 -2
  77. package/dist/chunks/{empty-state.C2wjdE3y.js.map → empty-state.CRdHhJLl.js.map} +1 -1
  78. package/dist/chunks/{field-label.C7BCsofY.js → field-label.CEp7WMYe.js} +2 -2
  79. package/dist/chunks/{field-label.C7BCsofY.js.map → field-label.CEp7WMYe.js.map} +1 -1
  80. package/dist/chunks/{file-uploader.DllKBmP8.js → file-uploader.2MeaNIlv.js} +7 -6
  81. package/dist/chunks/{file-uploader.DllKBmP8.js.map → file-uploader.2MeaNIlv.js.map} +1 -1
  82. package/dist/chunks/filter-bar.DUw139BE.js +1867 -0
  83. package/dist/chunks/filter-bar.DUw139BE.js.map +1 -0
  84. package/dist/chunks/{focus-trap.fd6_d2EW.js → focus-trap.BDpcWIxI.js} +1 -2
  85. package/dist/chunks/{focus-trap.fd6_d2EW.js.map → focus-trap.BDpcWIxI.js.map} +1 -1
  86. package/dist/chunks/{footer-actions.C9STwwcv.js → footer-actions.B5YZ95jM.js} +2 -2
  87. package/dist/chunks/{footer-actions.C9STwwcv.js.map → footer-actions.B5YZ95jM.js.map} +1 -1
  88. package/dist/chunks/{form-layout-title.C0lwzPZz.js → form-layout-title.BStxZj9d.js} +2 -2
  89. package/dist/chunks/{form-layout-title.C0lwzPZz.js.map → form-layout-title.BStxZj9d.js.map} +1 -1
  90. package/dist/chunks/{header-with-views.HwbE278X.js → header-with-views.DQh7mz0T.js} +10 -10
  91. package/dist/chunks/{header-with-views.HwbE278X.js.map → header-with-views.DQh7mz0T.js.map} +1 -1
  92. package/dist/chunks/{header.CmyqVXuG.js → header.DeRBttdY.js} +4 -4
  93. package/dist/chunks/{header.CmyqVXuG.js.map → header.DeRBttdY.js.map} +1 -1
  94. package/dist/chunks/{info-icon-with-popover.BvYyGm4D.js → info-icon-with-popover.8pL3B3m3.js} +3 -3
  95. package/dist/chunks/{info-icon-with-popover.BvYyGm4D.js.map → info-icon-with-popover.8pL3B3m3.js.map} +1 -1
  96. package/dist/chunks/{info-icon.B-FAeceD.js → info-icon.CmWiZXvc.js} +3 -3
  97. package/dist/chunks/{info-icon.B-FAeceD.js.map → info-icon.CmWiZXvc.js.map} +1 -1
  98. package/dist/chunks/{input-field-password.9bWhLud0.js → input-field-password.BiPMXS1j.js} +4 -4
  99. package/dist/chunks/{input-field-password.9bWhLud0.js.map → input-field-password.BiPMXS1j.js.map} +1 -1
  100. package/dist/chunks/{input-field-phone-number.CCn1N9St.js → input-field-phone-number.GK1UAt7-.js} +2 -2
  101. package/dist/chunks/{input-field-phone-number.CCn1N9St.js.map → input-field-phone-number.GK1UAt7-.js.map} +1 -1
  102. package/dist/chunks/{input-field.D912rZS_.js → input-field.BT5tx_DM.js} +3 -3
  103. package/dist/chunks/{input-field.D912rZS_.js.map → input-field.BT5tx_DM.js.map} +1 -1
  104. package/dist/chunks/{input-time.CXMuvF9N.js → input-time.DGaMMWxj.js} +3 -3
  105. package/dist/chunks/{input-time.CXMuvF9N.js.map → input-time.DGaMMWxj.js.map} +1 -1
  106. package/dist/chunks/input-with-dropdown-filter.axFutymM.js +80 -0
  107. package/dist/chunks/input-with-dropdown-filter.axFutymM.js.map +1 -0
  108. package/dist/chunks/{inspector-page.BRC_7uro.js → inspector-page.C5VCiyLD.js} +2 -2
  109. package/dist/chunks/{inspector-page.BRC_7uro.js.map → inspector-page.C5VCiyLD.js.map} +1 -1
  110. package/dist/chunks/{inspector.IOtNex1r.js → inspector.BoZBD8_z.js} +2 -2
  111. package/dist/chunks/{inspector.IOtNex1r.js.map → inspector.BoZBD8_z.js.map} +1 -1
  112. package/dist/chunks/{list-item.HjabBEb8.js → list-item.Bh5Z1f0K.js} +3 -3
  113. package/dist/chunks/{list-item.HjabBEb8.js.map → list-item.Bh5Z1f0K.js.map} +1 -1
  114. package/dist/chunks/{listbox-option-tag.DhNxvqRO.js → listbox-option-tag.BY6i9YgP.js} +2 -2
  115. package/dist/chunks/{listbox-option-tag.DhNxvqRO.js.map → listbox-option-tag.BY6i9YgP.js.map} +1 -1
  116. package/dist/chunks/{modal-fullscreen.Bi1bQs4Z.js → modal-fullscreen.Bteroyik.js} +3 -3
  117. package/dist/chunks/{modal-fullscreen.Bi1bQs4Z.js.map → modal-fullscreen.Bteroyik.js.map} +1 -1
  118. package/dist/chunks/{modal.B3-pmL5s.js → modal.C6OJMJ_D.js} +4 -4
  119. package/dist/chunks/{modal.B3-pmL5s.js.map → modal.C6OJMJ_D.js.map} +1 -1
  120. package/dist/chunks/{navigation-menu-group.B-AV49Bn.js → navigation-menu-group.uqIv5yZG.js} +2 -2
  121. package/dist/chunks/{navigation-menu-group.B-AV49Bn.js.map → navigation-menu-group.uqIv5yZG.js.map} +1 -1
  122. package/dist/chunks/{pagination.cI_pc6oE.js → pagination.CGiu-kog.js} +2 -2
  123. package/dist/chunks/{pagination.cI_pc6oE.js.map → pagination.CGiu-kog.js.map} +1 -1
  124. package/dist/chunks/popover.types.CoDfZgDc.js +6 -0
  125. package/dist/chunks/{popover.types.DvIwSAAp.js.map → popover.types.CoDfZgDc.js.map} +1 -1
  126. package/dist/chunks/{popper-container.Cj3AWXSd.js → popper-container.Co4j6qME.js} +2 -2
  127. package/dist/chunks/{popper-container.Cj3AWXSd.js.map → popper-container.Co4j6qME.js.map} +1 -1
  128. package/dist/chunks/{progress-bar.RlF3a0Gb.js → progress-bar.CJ6j8lIr.js} +2 -2
  129. package/dist/chunks/{progress-bar.RlF3a0Gb.js.map → progress-bar.CJ6j8lIr.js.map} +1 -1
  130. package/dist/chunks/{radio-group.CvsQDlHi.js → radio-group.CQfxWRbM.js} +3 -3
  131. package/dist/chunks/{radio-group.CvsQDlHi.js.map → radio-group.CQfxWRbM.js.map} +1 -1
  132. package/dist/chunks/{rich-text-editor.DNmVJilP.js → rich-text-editor.CDrX-0g1.js} +5 -5
  133. package/dist/chunks/{rich-text-editor.DNmVJilP.js.map → rich-text-editor.CDrX-0g1.js.map} +1 -1
  134. package/dist/chunks/{search-bar.--4KVNkf.js → search-bar.CFscAHEn.js} +3 -3
  135. package/dist/chunks/{search-bar.--4KVNkf.js.map → search-bar.CFscAHEn.js.map} +1 -1
  136. package/dist/chunks/{secondary-nav.CXtDQAay.js → secondary-nav.Ba7pNe_-.js} +3 -3
  137. package/dist/chunks/{secondary-nav.CXtDQAay.js.map → secondary-nav.Ba7pNe_-.js.map} +1 -1
  138. package/dist/chunks/{segmented-control.nYpRQTGc.js → segmented-control.Dp7Xd5Oa.js} +2 -2
  139. package/dist/chunks/{segmented-control.nYpRQTGc.js.map → segmented-control.Dp7Xd5Oa.js.map} +1 -1
  140. package/dist/chunks/select-avatar-filter.EG4IpfbR.js +51 -0
  141. package/dist/chunks/select-avatar-filter.EG4IpfbR.js.map +1 -0
  142. package/dist/chunks/select-country-filter.BtUlbnFP.js +55 -0
  143. package/dist/chunks/select-country-filter.BtUlbnFP.js.map +1 -0
  144. package/dist/chunks/select-currency-filter.B__ByL7N.js +89 -0
  145. package/dist/chunks/select-currency-filter.B__ByL7N.js.map +1 -0
  146. package/dist/chunks/select-payment-method-filter.DndRc65T.js +51 -0
  147. package/dist/chunks/select-payment-method-filter.DndRc65T.js.map +1 -0
  148. package/dist/chunks/select-tag-filter.DiWow_m7.js +59 -0
  149. package/dist/chunks/select-tag-filter.DiWow_m7.js.map +1 -0
  150. package/dist/chunks/{selection-card-group.DjFWMqVZ.js → selection-card-group.B2IEfuke.js} +9 -9
  151. package/dist/chunks/{selection-card-group.DjFWMqVZ.js.map → selection-card-group.B2IEfuke.js.map} +1 -1
  152. package/dist/chunks/{sidepanel.CntIcmx-.js → sidepanel.B9QGoXGV.js} +4 -4
  153. package/dist/chunks/{sidepanel.CntIcmx-.js.map → sidepanel.B9QGoXGV.js.map} +1 -1
  154. package/dist/chunks/{structured-list-item.Bhe0CH1M.js → structured-list-item.Cp1OuRJJ.js} +4 -4
  155. package/dist/chunks/{structured-list-item.Bhe0CH1M.js.map → structured-list-item.Cp1OuRJJ.js.map} +1 -1
  156. package/dist/chunks/{summary-grid.types.C70ED6WD.js → summary-grid.types.Ddf7FShu.js} +5 -5
  157. package/dist/chunks/{summary-grid.types.C70ED6WD.js.map → summary-grid.types.Ddf7FShu.js.map} +1 -1
  158. package/dist/chunks/{tab.BK1sIJAJ.js → tab.DavwEprr.js} +2 -2
  159. package/dist/chunks/{tab.BK1sIJAJ.js.map → tab.DavwEprr.js.map} +1 -1
  160. package/dist/chunks/{tag.Dz1FQSZb.js → tag.HGmLa47S.js} +2 -2
  161. package/dist/chunks/{tag.Dz1FQSZb.js.map → tag.HGmLa47S.js.map} +1 -1
  162. package/dist/chunks/{textarea.CcV9U3I7.js → textarea.CFCNYWVT.js} +2 -2
  163. package/dist/chunks/{textarea.CcV9U3I7.js.map → textarea.CFCNYWVT.js.map} +1 -1
  164. package/dist/chunks/{timeline-item.BG2by0xf.js → timeline-item.BIDEQCUw.js} +6 -6
  165. package/dist/chunks/{timeline-item.BG2by0xf.js.map → timeline-item.BIDEQCUw.js.map} +1 -1
  166. package/dist/chunks/{title-details.ChwPP7C5.js → title-details.kDWlIY1W.js} +2 -2
  167. package/dist/chunks/{title-details.ChwPP7C5.js.map → title-details.kDWlIY1W.js.map} +1 -1
  168. package/dist/chunks/{tooltip.DFYc5NKM.js → tooltip.D9Nqxoyp.js} +3 -3
  169. package/dist/chunks/{tooltip.DFYc5NKM.js.map → tooltip.D9Nqxoyp.js.map} +1 -1
  170. package/dist/chunks/{tutorial.K0aOQWIg.js → tutorial.dS_oywbu.js} +4 -4
  171. package/dist/chunks/{tutorial.K0aOQWIg.js.map → tutorial.dS_oywbu.js.map} +1 -1
  172. package/dist/chunks/{use-date-input-formatter.MgbFwUqJ.js → use-date-input-formatter.5r7srQZU.js} +2 -2
  173. package/dist/chunks/{use-date-input-formatter.MgbFwUqJ.js.map → use-date-input-formatter.5r7srQZU.js.map} +1 -1
  174. package/dist/chunks/warning-filled.DI6aB6vH.js +26 -0
  175. package/dist/chunks/warning-filled.DI6aB6vH.js.map +1 -0
  176. package/dist/code-snippet.js +1 -1
  177. package/dist/dashboard-template.js +1 -1
  178. package/dist/dashed-underline.js +1 -1
  179. package/dist/data-grid-template.js +1 -1
  180. package/dist/data-grid.js +1 -1
  181. package/dist/date-picker.js +2 -2
  182. package/dist/date-range-picker.js +2 -2
  183. package/dist/date-time-picker.js +1 -1
  184. package/dist/draggable.js +2 -2
  185. package/dist/dropdown.js +2 -2
  186. package/dist/empty-state.js +1 -1
  187. package/dist/file-uploader.js +1 -1
  188. package/dist/filter-bar.js +1 -1
  189. package/dist/focus-trap.js +1 -1
  190. package/dist/form-layout.js +1 -1
  191. package/dist/header-with-views.js +1 -1
  192. package/dist/header.js +1 -1
  193. package/dist/index.js +56 -56
  194. package/dist/info-icon.js +1 -1
  195. package/dist/input-field-password.js +1 -1
  196. package/dist/input-field-phone-number.js +1 -1
  197. package/dist/input-field.js +1 -1
  198. package/dist/input-time.js +1 -1
  199. package/dist/inspector.js +2 -2
  200. package/dist/internal.js +11 -11
  201. package/dist/list.js +1 -1
  202. package/dist/menu.js +1 -1
  203. package/dist/modal-fullscreen.js +1 -1
  204. package/dist/modal.js +2 -2
  205. package/dist/navigation-menu.js +1 -1
  206. package/dist/pagination.js +1 -1
  207. package/dist/popover.js +2 -2
  208. package/dist/popper-container.js +1 -1
  209. package/dist/progress-bar.js +1 -1
  210. package/dist/radio-group.js +1 -1
  211. package/dist/rich-text-editor.js +1 -1
  212. package/dist/search-bar.js +2 -2
  213. package/dist/secondary-nav.js +1 -1
  214. package/dist/segmented-control.js +1 -1
  215. package/dist/selection-card.js +1 -1
  216. package/dist/sidepanel.js +1 -1
  217. package/dist/structured-list.js +1 -1
  218. package/dist/summary-grid.js +1 -1
  219. package/dist/tabs.js +1 -1
  220. package/dist/tag.js +1 -1
  221. package/dist/textarea.js +1 -1
  222. package/dist/timeline.js +1 -1
  223. package/dist/tutorial.js +1 -1
  224. package/dist/web-types.json +9 -1
  225. package/package.json +6 -6
  226. package/dist/chunks/alert.DJDHwVeR.js.map +0 -1
  227. package/dist/chunks/filter-bar.DXpLhnxG.js +0 -3131
  228. package/dist/chunks/filter-bar.DXpLhnxG.js.map +0 -1
  229. package/dist/chunks/popover.types.DvIwSAAp.js +0 -6
@@ -0,0 +1,868 @@
1
+ import { defineComponent as U, toRef as q, ref as k, computed as S, reactive as j, watch as $ } from "vue";
2
+ import { c as g, B as Z, u as K } from "./filter-bar.DUw139BE.js";
3
+ import { D as J, B as z, i as T, a as V } from "./date-range-picker.Cz6ijJAa.js";
4
+ import { B as ee } from "./divider.KxXy6nzJ.js";
5
+ import { B as te } from "./typography.D1OZJbEa.js";
6
+ import { u as ae } from "./index.CPOlyau9.js";
7
+ import { j as ne, k as re, e as D, l as oe } from "./calendar.BNRImpE_.js";
8
+ import { t as E, k as ie, g as se } from "./en-US.C412g-7U.js";
9
+ import { g as ce, b as ue, c as le, d as de, i as fe, e as me, w as ge, l as he, u as ye } from "./use-date-input-formatter.5r7srQZU.js";
10
+ import "./index.Cl4_42j5.js";
11
+ import { B as be } from "./button-actions.sLmpjWGK.js";
12
+ import { u as pe } from "./use-dynamic-date-fns-locale.Bpb2DeYR.js";
13
+ import { n as we } from "./_plugin-vue2_normalizer.CeySl7Fu.js";
14
+ import "../assets/date-range-filter.css";
15
+ function De(t) {
16
+ return t instanceof Date || typeof t == "object" && Object.prototype.toString.call(t) === "[object Date]";
17
+ }
18
+ function ve(t) {
19
+ return !(!De(t) && typeof t != "number" || isNaN(+E(t)));
20
+ }
21
+ function xe(t, e) {
22
+ const a = E(t, e?.in);
23
+ return ne(a, re(a)) + 1;
24
+ }
25
+ function s(t, e) {
26
+ const a = t < 0 ? "-" : "", n = Math.abs(t).toString().padStart(e, "0");
27
+ return a + n;
28
+ }
29
+ const m = {
30
+ // Year
31
+ y(t, e) {
32
+ const a = t.getFullYear(), n = a > 0 ? a : 1 - a;
33
+ return s(e === "yy" ? n % 100 : n, e.length);
34
+ },
35
+ // Month
36
+ M(t, e) {
37
+ const a = t.getMonth();
38
+ return e === "M" ? String(a + 1) : s(a + 1, 2);
39
+ },
40
+ // Day of the month
41
+ d(t, e) {
42
+ return s(t.getDate(), e.length);
43
+ },
44
+ // AM or PM
45
+ a(t, e) {
46
+ const a = t.getHours() / 12 >= 1 ? "pm" : "am";
47
+ switch (e) {
48
+ case "a":
49
+ case "aa":
50
+ return a.toUpperCase();
51
+ case "aaa":
52
+ return a;
53
+ case "aaaaa":
54
+ return a[0];
55
+ default:
56
+ return a === "am" ? "a.m." : "p.m.";
57
+ }
58
+ },
59
+ // Hour [1-12]
60
+ h(t, e) {
61
+ return s(t.getHours() % 12 || 12, e.length);
62
+ },
63
+ // Hour [0-23]
64
+ H(t, e) {
65
+ return s(t.getHours(), e.length);
66
+ },
67
+ // Minute
68
+ m(t, e) {
69
+ return s(t.getMinutes(), e.length);
70
+ },
71
+ // Second
72
+ s(t, e) {
73
+ return s(t.getSeconds(), e.length);
74
+ },
75
+ // Fraction of second
76
+ S(t, e) {
77
+ const a = e.length, n = t.getMilliseconds(), r = Math.trunc(
78
+ n * Math.pow(10, a - 3)
79
+ );
80
+ return s(r, e.length);
81
+ }
82
+ }, v = {
83
+ midnight: "midnight",
84
+ noon: "noon",
85
+ morning: "morning",
86
+ afternoon: "afternoon",
87
+ evening: "evening",
88
+ night: "night"
89
+ }, L = {
90
+ // Era
91
+ G: function(t, e, a) {
92
+ const n = t.getFullYear() > 0 ? 1 : 0;
93
+ switch (e) {
94
+ // AD, BC
95
+ case "G":
96
+ case "GG":
97
+ case "GGG":
98
+ return a.era(n, { width: "abbreviated" });
99
+ // A, B
100
+ case "GGGGG":
101
+ return a.era(n, { width: "narrow" });
102
+ default:
103
+ return a.era(n, { width: "wide" });
104
+ }
105
+ },
106
+ // Year
107
+ y: function(t, e, a) {
108
+ if (e === "yo") {
109
+ const n = t.getFullYear(), r = n > 0 ? n : 1 - n;
110
+ return a.ordinalNumber(r, { unit: "year" });
111
+ }
112
+ return m.y(t, e);
113
+ },
114
+ // Local week-numbering year
115
+ Y: function(t, e, a, n) {
116
+ const r = de(t, n), i = r > 0 ? r : 1 - r;
117
+ if (e === "YY") {
118
+ const c = i % 100;
119
+ return s(c, 2);
120
+ }
121
+ return e === "Yo" ? a.ordinalNumber(i, { unit: "year" }) : s(i, e.length);
122
+ },
123
+ // ISO week-numbering year
124
+ R: function(t, e) {
125
+ const a = le(t);
126
+ return s(a, e.length);
127
+ },
128
+ // Extended year. This is a single number designating the year of this calendar system.
129
+ // The main difference between `y` and `u` localizers are B.C. years:
130
+ // | Year | `y` | `u` |
131
+ // |------|-----|-----|
132
+ // | AC 1 | 1 | 1 |
133
+ // | BC 1 | 1 | 0 |
134
+ // | BC 2 | 2 | -1 |
135
+ // Also `yy` always returns the last two digits of a year,
136
+ // while `uu` pads single digit years to 2 characters and returns other years unchanged.
137
+ u: function(t, e) {
138
+ const a = t.getFullYear();
139
+ return s(a, e.length);
140
+ },
141
+ // Quarter
142
+ Q: function(t, e, a) {
143
+ const n = Math.ceil((t.getMonth() + 1) / 3);
144
+ switch (e) {
145
+ // 1, 2, 3, 4
146
+ case "Q":
147
+ return String(n);
148
+ // 01, 02, 03, 04
149
+ case "QQ":
150
+ return s(n, 2);
151
+ // 1st, 2nd, 3rd, 4th
152
+ case "Qo":
153
+ return a.ordinalNumber(n, { unit: "quarter" });
154
+ // Q1, Q2, Q3, Q4
155
+ case "QQQ":
156
+ return a.quarter(n, {
157
+ width: "abbreviated",
158
+ context: "formatting"
159
+ });
160
+ // 1, 2, 3, 4 (narrow quarter; could be not numerical)
161
+ case "QQQQQ":
162
+ return a.quarter(n, {
163
+ width: "narrow",
164
+ context: "formatting"
165
+ });
166
+ default:
167
+ return a.quarter(n, {
168
+ width: "wide",
169
+ context: "formatting"
170
+ });
171
+ }
172
+ },
173
+ // Stand-alone quarter
174
+ q: function(t, e, a) {
175
+ const n = Math.ceil((t.getMonth() + 1) / 3);
176
+ switch (e) {
177
+ // 1, 2, 3, 4
178
+ case "q":
179
+ return String(n);
180
+ // 01, 02, 03, 04
181
+ case "qq":
182
+ return s(n, 2);
183
+ // 1st, 2nd, 3rd, 4th
184
+ case "qo":
185
+ return a.ordinalNumber(n, { unit: "quarter" });
186
+ // Q1, Q2, Q3, Q4
187
+ case "qqq":
188
+ return a.quarter(n, {
189
+ width: "abbreviated",
190
+ context: "standalone"
191
+ });
192
+ // 1, 2, 3, 4 (narrow quarter; could be not numerical)
193
+ case "qqqqq":
194
+ return a.quarter(n, {
195
+ width: "narrow",
196
+ context: "standalone"
197
+ });
198
+ default:
199
+ return a.quarter(n, {
200
+ width: "wide",
201
+ context: "standalone"
202
+ });
203
+ }
204
+ },
205
+ // Month
206
+ M: function(t, e, a) {
207
+ const n = t.getMonth();
208
+ switch (e) {
209
+ case "M":
210
+ case "MM":
211
+ return m.M(t, e);
212
+ // 1st, 2nd, ..., 12th
213
+ case "Mo":
214
+ return a.ordinalNumber(n + 1, { unit: "month" });
215
+ // Jan, Feb, ..., Dec
216
+ case "MMM":
217
+ return a.month(n, {
218
+ width: "abbreviated",
219
+ context: "formatting"
220
+ });
221
+ // J, F, ..., D
222
+ case "MMMMM":
223
+ return a.month(n, {
224
+ width: "narrow",
225
+ context: "formatting"
226
+ });
227
+ default:
228
+ return a.month(n, { width: "wide", context: "formatting" });
229
+ }
230
+ },
231
+ // Stand-alone month
232
+ L: function(t, e, a) {
233
+ const n = t.getMonth();
234
+ switch (e) {
235
+ // 1, 2, ..., 12
236
+ case "L":
237
+ return String(n + 1);
238
+ // 01, 02, ..., 12
239
+ case "LL":
240
+ return s(n + 1, 2);
241
+ // 1st, 2nd, ..., 12th
242
+ case "Lo":
243
+ return a.ordinalNumber(n + 1, { unit: "month" });
244
+ // Jan, Feb, ..., Dec
245
+ case "LLL":
246
+ return a.month(n, {
247
+ width: "abbreviated",
248
+ context: "standalone"
249
+ });
250
+ // J, F, ..., D
251
+ case "LLLLL":
252
+ return a.month(n, {
253
+ width: "narrow",
254
+ context: "standalone"
255
+ });
256
+ default:
257
+ return a.month(n, { width: "wide", context: "standalone" });
258
+ }
259
+ },
260
+ // Local week of year
261
+ w: function(t, e, a, n) {
262
+ const r = ue(t, n);
263
+ return e === "wo" ? a.ordinalNumber(r, { unit: "week" }) : s(r, e.length);
264
+ },
265
+ // ISO week of year
266
+ I: function(t, e, a) {
267
+ const n = ce(t);
268
+ return e === "Io" ? a.ordinalNumber(n, { unit: "week" }) : s(n, e.length);
269
+ },
270
+ // Day of the month
271
+ d: function(t, e, a) {
272
+ return e === "do" ? a.ordinalNumber(t.getDate(), { unit: "date" }) : m.d(t, e);
273
+ },
274
+ // Day of year
275
+ D: function(t, e, a) {
276
+ const n = xe(t);
277
+ return e === "Do" ? a.ordinalNumber(n, { unit: "dayOfYear" }) : s(n, e.length);
278
+ },
279
+ // Day of week
280
+ E: function(t, e, a) {
281
+ const n = t.getDay();
282
+ switch (e) {
283
+ // Tue
284
+ case "E":
285
+ case "EE":
286
+ case "EEE":
287
+ return a.day(n, {
288
+ width: "abbreviated",
289
+ context: "formatting"
290
+ });
291
+ // T
292
+ case "EEEEE":
293
+ return a.day(n, {
294
+ width: "narrow",
295
+ context: "formatting"
296
+ });
297
+ // Tu
298
+ case "EEEEEE":
299
+ return a.day(n, {
300
+ width: "short",
301
+ context: "formatting"
302
+ });
303
+ default:
304
+ return a.day(n, {
305
+ width: "wide",
306
+ context: "formatting"
307
+ });
308
+ }
309
+ },
310
+ // Local day of week
311
+ e: function(t, e, a, n) {
312
+ const r = t.getDay(), i = (r - n.weekStartsOn + 8) % 7 || 7;
313
+ switch (e) {
314
+ // Numerical value (Nth day of week with current locale or weekStartsOn)
315
+ case "e":
316
+ return String(i);
317
+ // Padded numerical value
318
+ case "ee":
319
+ return s(i, 2);
320
+ // 1st, 2nd, ..., 7th
321
+ case "eo":
322
+ return a.ordinalNumber(i, { unit: "day" });
323
+ case "eee":
324
+ return a.day(r, {
325
+ width: "abbreviated",
326
+ context: "formatting"
327
+ });
328
+ // T
329
+ case "eeeee":
330
+ return a.day(r, {
331
+ width: "narrow",
332
+ context: "formatting"
333
+ });
334
+ // Tu
335
+ case "eeeeee":
336
+ return a.day(r, {
337
+ width: "short",
338
+ context: "formatting"
339
+ });
340
+ default:
341
+ return a.day(r, {
342
+ width: "wide",
343
+ context: "formatting"
344
+ });
345
+ }
346
+ },
347
+ // Stand-alone local day of week
348
+ c: function(t, e, a, n) {
349
+ const r = t.getDay(), i = (r - n.weekStartsOn + 8) % 7 || 7;
350
+ switch (e) {
351
+ // Numerical value (same as in `e`)
352
+ case "c":
353
+ return String(i);
354
+ // Padded numerical value
355
+ case "cc":
356
+ return s(i, e.length);
357
+ // 1st, 2nd, ..., 7th
358
+ case "co":
359
+ return a.ordinalNumber(i, { unit: "day" });
360
+ case "ccc":
361
+ return a.day(r, {
362
+ width: "abbreviated",
363
+ context: "standalone"
364
+ });
365
+ // T
366
+ case "ccccc":
367
+ return a.day(r, {
368
+ width: "narrow",
369
+ context: "standalone"
370
+ });
371
+ // Tu
372
+ case "cccccc":
373
+ return a.day(r, {
374
+ width: "short",
375
+ context: "standalone"
376
+ });
377
+ default:
378
+ return a.day(r, {
379
+ width: "wide",
380
+ context: "standalone"
381
+ });
382
+ }
383
+ },
384
+ // ISO day of week
385
+ i: function(t, e, a) {
386
+ const n = t.getDay(), r = n === 0 ? 7 : n;
387
+ switch (e) {
388
+ // 2
389
+ case "i":
390
+ return String(r);
391
+ // 02
392
+ case "ii":
393
+ return s(r, e.length);
394
+ // 2nd
395
+ case "io":
396
+ return a.ordinalNumber(r, { unit: "day" });
397
+ // Tue
398
+ case "iii":
399
+ return a.day(n, {
400
+ width: "abbreviated",
401
+ context: "formatting"
402
+ });
403
+ // T
404
+ case "iiiii":
405
+ return a.day(n, {
406
+ width: "narrow",
407
+ context: "formatting"
408
+ });
409
+ // Tu
410
+ case "iiiiii":
411
+ return a.day(n, {
412
+ width: "short",
413
+ context: "formatting"
414
+ });
415
+ default:
416
+ return a.day(n, {
417
+ width: "wide",
418
+ context: "formatting"
419
+ });
420
+ }
421
+ },
422
+ // AM or PM
423
+ a: function(t, e, a) {
424
+ const r = t.getHours() / 12 >= 1 ? "pm" : "am";
425
+ switch (e) {
426
+ case "a":
427
+ case "aa":
428
+ return a.dayPeriod(r, {
429
+ width: "abbreviated",
430
+ context: "formatting"
431
+ });
432
+ case "aaa":
433
+ return a.dayPeriod(r, {
434
+ width: "abbreviated",
435
+ context: "formatting"
436
+ }).toLowerCase();
437
+ case "aaaaa":
438
+ return a.dayPeriod(r, {
439
+ width: "narrow",
440
+ context: "formatting"
441
+ });
442
+ default:
443
+ return a.dayPeriod(r, {
444
+ width: "wide",
445
+ context: "formatting"
446
+ });
447
+ }
448
+ },
449
+ // AM, PM, midnight, noon
450
+ b: function(t, e, a) {
451
+ const n = t.getHours();
452
+ let r;
453
+ switch (n === 12 ? r = v.noon : n === 0 ? r = v.midnight : r = n / 12 >= 1 ? "pm" : "am", e) {
454
+ case "b":
455
+ case "bb":
456
+ return a.dayPeriod(r, {
457
+ width: "abbreviated",
458
+ context: "formatting"
459
+ });
460
+ case "bbb":
461
+ return a.dayPeriod(r, {
462
+ width: "abbreviated",
463
+ context: "formatting"
464
+ }).toLowerCase();
465
+ case "bbbbb":
466
+ return a.dayPeriod(r, {
467
+ width: "narrow",
468
+ context: "formatting"
469
+ });
470
+ default:
471
+ return a.dayPeriod(r, {
472
+ width: "wide",
473
+ context: "formatting"
474
+ });
475
+ }
476
+ },
477
+ // in the morning, in the afternoon, in the evening, at night
478
+ B: function(t, e, a) {
479
+ const n = t.getHours();
480
+ let r;
481
+ switch (n >= 17 ? r = v.evening : n >= 12 ? r = v.afternoon : n >= 4 ? r = v.morning : r = v.night, e) {
482
+ case "B":
483
+ case "BB":
484
+ case "BBB":
485
+ return a.dayPeriod(r, {
486
+ width: "abbreviated",
487
+ context: "formatting"
488
+ });
489
+ case "BBBBB":
490
+ return a.dayPeriod(r, {
491
+ width: "narrow",
492
+ context: "formatting"
493
+ });
494
+ default:
495
+ return a.dayPeriod(r, {
496
+ width: "wide",
497
+ context: "formatting"
498
+ });
499
+ }
500
+ },
501
+ // Hour [1-12]
502
+ h: function(t, e, a) {
503
+ if (e === "ho") {
504
+ let n = t.getHours() % 12;
505
+ return n === 0 && (n = 12), a.ordinalNumber(n, { unit: "hour" });
506
+ }
507
+ return m.h(t, e);
508
+ },
509
+ // Hour [0-23]
510
+ H: function(t, e, a) {
511
+ return e === "Ho" ? a.ordinalNumber(t.getHours(), { unit: "hour" }) : m.H(t, e);
512
+ },
513
+ // Hour [0-11]
514
+ K: function(t, e, a) {
515
+ const n = t.getHours() % 12;
516
+ return e === "Ko" ? a.ordinalNumber(n, { unit: "hour" }) : s(n, e.length);
517
+ },
518
+ // Hour [1-24]
519
+ k: function(t, e, a) {
520
+ let n = t.getHours();
521
+ return n === 0 && (n = 24), e === "ko" ? a.ordinalNumber(n, { unit: "hour" }) : s(n, e.length);
522
+ },
523
+ // Minute
524
+ m: function(t, e, a) {
525
+ return e === "mo" ? a.ordinalNumber(t.getMinutes(), { unit: "minute" }) : m.m(t, e);
526
+ },
527
+ // Second
528
+ s: function(t, e, a) {
529
+ return e === "so" ? a.ordinalNumber(t.getSeconds(), { unit: "second" }) : m.s(t, e);
530
+ },
531
+ // Fraction of second
532
+ S: function(t, e) {
533
+ return m.S(t, e);
534
+ },
535
+ // Timezone (ISO-8601. If offset is 0, output is always `'Z'`)
536
+ X: function(t, e, a) {
537
+ const n = t.getTimezoneOffset();
538
+ if (n === 0)
539
+ return "Z";
540
+ switch (e) {
541
+ // Hours and optional minutes
542
+ case "X":
543
+ return F(n);
544
+ // Hours, minutes and optional seconds without `:` delimiter
545
+ // Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
546
+ // so this token always has the same output as `XX`
547
+ case "XXXX":
548
+ case "XX":
549
+ return h(n);
550
+ // Hours and minutes with `:` delimiter
551
+ default:
552
+ return h(n, ":");
553
+ }
554
+ },
555
+ // Timezone (ISO-8601. If offset is 0, output is `'+00:00'` or equivalent)
556
+ x: function(t, e, a) {
557
+ const n = t.getTimezoneOffset();
558
+ switch (e) {
559
+ // Hours and optional minutes
560
+ case "x":
561
+ return F(n);
562
+ // Hours, minutes and optional seconds without `:` delimiter
563
+ // Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
564
+ // so this token always has the same output as `xx`
565
+ case "xxxx":
566
+ case "xx":
567
+ return h(n);
568
+ // Hours and minutes with `:` delimiter
569
+ default:
570
+ return h(n, ":");
571
+ }
572
+ },
573
+ // Timezone (GMT)
574
+ O: function(t, e, a) {
575
+ const n = t.getTimezoneOffset();
576
+ switch (e) {
577
+ // Short
578
+ case "O":
579
+ case "OO":
580
+ case "OOO":
581
+ return "GMT" + _(n, ":");
582
+ default:
583
+ return "GMT" + h(n, ":");
584
+ }
585
+ },
586
+ // Timezone (specific non-location)
587
+ z: function(t, e, a) {
588
+ const n = t.getTimezoneOffset();
589
+ switch (e) {
590
+ // Short
591
+ case "z":
592
+ case "zz":
593
+ case "zzz":
594
+ return "GMT" + _(n, ":");
595
+ default:
596
+ return "GMT" + h(n, ":");
597
+ }
598
+ },
599
+ // Seconds timestamp
600
+ t: function(t, e, a) {
601
+ const n = Math.trunc(+t / 1e3);
602
+ return s(n, e.length);
603
+ },
604
+ // Milliseconds timestamp
605
+ T: function(t, e, a) {
606
+ return s(+t, e.length);
607
+ }
608
+ };
609
+ function _(t, e = "") {
610
+ const a = t > 0 ? "-" : "+", n = Math.abs(t), r = Math.trunc(n / 60), i = n % 60;
611
+ return i === 0 ? a + String(r) : a + String(r) + e + s(i, 2);
612
+ }
613
+ function F(t, e) {
614
+ return t % 60 === 0 ? (t > 0 ? "-" : "+") + s(Math.abs(t) / 60, 2) : h(t, e);
615
+ }
616
+ function h(t, e = "") {
617
+ const a = t > 0 ? "-" : "+", n = Math.abs(t), r = s(Math.trunc(n / 60), 2), i = s(n % 60, 2);
618
+ return a + r + e + i;
619
+ }
620
+ const Oe = /[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g, Se = /P+p+|P+|p+|''|'(''|[^'])+('|$)|./g, Me = /^'([^]*?)'?$/, ke = /''/g, Te = /[a-zA-Z]/;
621
+ function M(t, e, a) {
622
+ const n = se(), r = a?.locale ?? n.locale ?? ie, i = a?.firstWeekContainsDate ?? a?.locale?.options?.firstWeekContainsDate ?? n.firstWeekContainsDate ?? n.locale?.options?.firstWeekContainsDate ?? 1, c = a?.weekStartsOn ?? a?.locale?.options?.weekStartsOn ?? n.weekStartsOn ?? n.locale?.options?.weekStartsOn ?? 0, y = E(t, a?.in);
623
+ if (!ve(y))
624
+ throw new RangeError("Invalid time value");
625
+ let b = e.match(Se).map((l) => {
626
+ const u = l[0];
627
+ if (u === "p" || u === "P") {
628
+ const f = he[u];
629
+ return f(l, r.formatLong);
630
+ }
631
+ return l;
632
+ }).join("").match(Oe).map((l) => {
633
+ if (l === "''")
634
+ return { isToken: !1, value: "'" };
635
+ const u = l[0];
636
+ if (u === "'")
637
+ return { isToken: !1, value: Ee(l) };
638
+ if (L[u])
639
+ return { isToken: !0, value: l };
640
+ if (u.match(Te))
641
+ throw new RangeError(
642
+ "Format string contains an unescaped latin alphabet character `" + u + "`"
643
+ );
644
+ return { isToken: !1, value: l };
645
+ });
646
+ r.localize.preprocessor && (b = r.localize.preprocessor(y, b));
647
+ const p = {
648
+ firstWeekContainsDate: i,
649
+ weekStartsOn: c,
650
+ locale: r
651
+ };
652
+ return b.map((l) => {
653
+ if (!l.isToken) return l.value;
654
+ const u = l.value;
655
+ (!a?.useAdditionalWeekYearTokens && fe(u) || !a?.useAdditionalDayOfYearTokens && me(u)) && ge(u, e, String(t));
656
+ const f = L[u[0]];
657
+ return f(y, u, r.localize, p);
658
+ }).join("");
659
+ }
660
+ function Ee(t) {
661
+ const e = t.match(Me);
662
+ return e ? e[1].replace(ke, "'") : t;
663
+ }
664
+ const Pe = {
665
+ "de-DE": { apply: "Anwenden", clear: "Löschen", reset: "Zurücksetzen" },
666
+ "en-GB": { apply: "Apply", clear: "Clear", reset: "Reset" },
667
+ "en-US": { apply: "Apply", clear: "Clear", reset: "Reset" },
668
+ "es-419": { apply: "Aplicar", clear: "Borrar", reset: "Restablecer" },
669
+ "es-ES": { apply: "Aplicar", clear: "Borrar", reset: "Reiniciar" },
670
+ "es-MX": { apply: "Aplicar", clear: "Limpiar", reset: "Restablecer" },
671
+ "fr-FR": { apply: "Appliquer", clear: "Clair", reset: "Réinitialiser" },
672
+ "it-IT": { apply: "Applica", clear: "Cancella", reset: "Resetta" },
673
+ "ja-JP": { apply: "適用", clear: "クリア", reset: "リセット" },
674
+ "pt-BR": { apply: "Aplicar", clear: "Limpar", reset: "Limpar" },
675
+ "zh-CN": { apply: "应用", clear: "清除", reset: "重置" }
676
+ }, Be = U({
677
+ i18n: { messages: Pe },
678
+ name: "bento-date-range-filter",
679
+ components: {
680
+ BentoBaseFilter: Z,
681
+ BentoButtonActions: be,
682
+ BentoDateRangePicker: z,
683
+ BentoTypography: te,
684
+ BentoDivider: ee,
685
+ DateRangePickerCalendar: J
686
+ },
687
+ props: {
688
+ /**
689
+ * Disables the filter from being interacted with.
690
+ */
691
+ disabled: { type: Boolean, default: !1 },
692
+ /**
693
+ * Default value of the filter to reset to.
694
+ */
695
+ defaultValue: { type: Object, default: null },
696
+ /**
697
+ * Filter name/key referencing the actual property name in the data set.
698
+ * Should be unique per filter bar.
699
+ */
700
+ field: { type: String, required: !0 },
701
+ /**
702
+ * Label text to be displayed
703
+ */
704
+ label: { type: String, required: !0 },
705
+ /**
706
+ * Renders the base filter's slot content only - leaving out the button and the popover.
707
+ * Used for the allFiltersModal component.
708
+ */
709
+ onlySlot: { type: Boolean, default: !1 },
710
+ /**
711
+ * List of options that are needed to setup the filter
712
+ * Available options:
713
+ * - allowTimeInput: Allows user to enter time values in the form
714
+ * - firstDayOfWeek: Allows user to set the first day of the week. 0 is sunday, 1 is monday, 6 is saturday
715
+ * - isDateDisabled: Indicate if a date should be disabled or not
716
+ * - maxRange: Set a maximum number of dates to be selectable by the range
717
+ * - numberOfMonths: Number of months rendered on pane
718
+ * - quickSelectRanges: An array that sets the custom range dropdown items. @see BentoDateRangePicker
719
+ * - showEndDateOnOpen: Upon opening date range picker, end date's month will be pre-selected.
720
+ * - granularities: A list of available granularities.
721
+ * - variant: The type of calendar to display. Defaults to showing days.
722
+ * - tooltipPosition: The position of the tooltip attached to the filter button
723
+ * - tooltipText: The content of the tooltip attached to the filter button
724
+ */
725
+ options: {
726
+ type: Object,
727
+ default: void 0
728
+ },
729
+ /**
730
+ * Current value of the filter
731
+ */
732
+ value: {
733
+ type: Object,
734
+ default: () => ({ startDate: void 0, endDate: void 0 })
735
+ }
736
+ },
737
+ emits: [g.INPUT, g.UPDATE],
738
+ setup(t, { emit: e }) {
739
+ const { locale: a, t: n } = ae(), r = pe(a), { dateToInputDateString: i } = ye(), { internalFilterValue: c, isSecondaryButtonDisabled: y, isApplyButtonDisabled: b } = K(
740
+ q(t, "value"),
741
+ q(t, "defaultValue")
742
+ ), p = k(!1), l = S(() => t?.options?.quickSelectRanges && t.options.quickSelectRanges.map((o) => {
743
+ const w = o.data.endDate ? void 0 : new Date(Date.now()).getTime() - o.data.startDate.getTime();
744
+ return {
745
+ ...o,
746
+ data: {
747
+ ...o.data,
748
+ // Adding timeDifference to calculate an up-to-date endDate on range selection
749
+ timeDifference: w
750
+ }
751
+ };
752
+ })), u = k(null), f = k(!1), d = j({
753
+ startDate: i(t.value?.startDate),
754
+ endDate: i(t.value?.endDate),
755
+ startTime: D(t.value?.startDate),
756
+ endTime: D(t.value?.endDate)
757
+ });
758
+ $(
759
+ () => t.value,
760
+ () => {
761
+ d.startDate = i(t.value?.startDate), d.endDate = i(t.value?.endDate), d.startTime = D(t.value?.startDate), d.endTime = D(t.value?.endDate);
762
+ }
763
+ );
764
+ function I(o) {
765
+ return o?.length !== void 0;
766
+ }
767
+ const N = (o) => {
768
+ if (!o || !o?.startDate && !o.endDate)
769
+ return null;
770
+ if (I(t.options?.quickSelectRanges) && t.options?.quickSelectRanges?.length > 0) {
771
+ const w = t.options?.quickSelectRanges?.find(({ value: X, data: O }) => o ? o.range ? X === o.range : !o.startDate || !o.endDate ? !1 : O?.endDate ? T(O?.startDate, o.startDate) && T(O?.endDate, o.endDate) : T(O?.startDate, o.startDate) && V(o.endDate) : !1);
772
+ if (w)
773
+ return w.label;
774
+ }
775
+ return !o.startDate || !o.endDate ? null : oe(o.startDate, o.endDate) && t?.options?.allowTimeInput ? `${M(o.startDate, "dd MMM, yyyy HH:mm:ss", {
776
+ locale: r.value
777
+ })} - ${M(o.endDate, "HH:mm:ss", {
778
+ locale: r.value
779
+ })}` : `${M(o.startDate, "dd MMM, yyyy", {
780
+ locale: r.value
781
+ })} - ${M(o.endDate, "dd MMM, yyyy", {
782
+ locale: r.value
783
+ })}`;
784
+ }, Y = S(() => N(t.value)), C = S(() => t.label), x = () => {
785
+ u.value.closePopover();
786
+ const { onlySlot: o, ...w } = t;
787
+ e(g.UPDATE, { ...w, value: c.value });
788
+ }, P = () => {
789
+ c.value = void 0, x();
790
+ }, B = () => {
791
+ c.value = t.defaultValue, x();
792
+ }, W = () => {
793
+ c.value = t.value;
794
+ }, Q = () => {
795
+ c.value = t.value, p.value = !1, d.startDate = i(t.value?.startDate), d.endDate = i(t.value?.endDate), d.startTime = D(t.value?.startDate), d.endTime = D(t.value?.endDate);
796
+ }, R = (o) => {
797
+ p.value = !1, c.value = o, d.startDate = i(o.startDate), d.endDate = i(o.endDate), e(g.INPUT, { ...t, value: c.value });
798
+ }, G = (o) => {
799
+ o?.startDate && o?.endDate && (c.value = o, d.startDate = i(o.startDate), d.endDate = i(o.endDate), e(g.INPUT, { ...t, value: c.value }));
800
+ }, A = (o) => {
801
+ R(o), e(g.INPUT, { ...t, value: c.value });
802
+ }, H = S(
803
+ () => [
804
+ {
805
+ title: n("apply"),
806
+ event: x,
807
+ disabled: p.value || f.value || b.value
808
+ },
809
+ {
810
+ title: t.defaultValue ? n("reset") : n("clear"),
811
+ event: t.defaultValue ? B : P,
812
+ disabled: f.value && y.value
813
+ }
814
+ ]
815
+ );
816
+ return {
817
+ // Refs
818
+ baseFilter: u,
819
+ // Values
820
+ actions: H,
821
+ formData: d,
822
+ internalFilterValue: c,
823
+ isApplyButtonDisabled: b,
824
+ isSecondaryButtonDisabled: y,
825
+ isSelectingDate: p,
826
+ buttonLabel: C,
827
+ buttonSecondaryLabel: Y,
828
+ adjustedQuickSelectRanges: l,
829
+ // Events
830
+ onCancel: Q,
831
+ onDateSelected: R,
832
+ openFilter: W,
833
+ clearFilter: P,
834
+ resetFilter: B,
835
+ updateFilter: x,
836
+ onDatePickerRangeError: () => {
837
+ f.value = !0, c.value = { startDate: void 0, endDate: void 0 }, e(g.INPUT, { ...t, value: c.value });
838
+ },
839
+ onDatePickerRangeFormDateInputUpdate: (o) => {
840
+ f.value = !1, o.startTime && (d.startTime = o.startTime), o.endTime && (d.endTime = o.endTime);
841
+ },
842
+ onDateInputSelected: A,
843
+ onRangeSelectorInput: G
844
+ };
845
+ }
846
+ });
847
+ var Re = function() {
848
+ var e = this, a = e._self._c;
849
+ return e._self._setupProxy, a("bento-base-filter", { ref: "baseFilter", staticClass: "b-base-filter-date-range-filter", attrs: { "button-label": e.buttonLabel, "button-secondary-label": e.buttonSecondaryLabel, controlled: !e.onlySlot, disabled: e.disabled, "disable-apply-button": e.isApplyButtonDisabled, "disable-secondary-button": e.isSecondaryButtonDisabled, "default-value": e.defaultValue, field: e.field, label: e.label, "only-slot": e.onlySlot, "tooltip-position": e.options?.tooltipPosition, "tooltip-text": e.options?.tooltipText, value: e.value, "fit-content": "" }, on: { open: e.openFilter, clear: e.clearFilter, reset: e.resetFilter, cancel: e.onCancel } }, [e.onlySlot ? a("bento-date-range-picker", { attrs: { "allow-time-input": e.options?.allowTimeInput, "model-value": e.internalFilterValue, "first-day-of-week": e.options?.firstDayOfWeek, "is-date-disabled": e.options?.isDateDisabled, "number-of-months": e.options?.numberOfMonths, "quick-select-ranges": e.options?.quickSelectRanges, variant: e.options?.variant, "year-range": e.options?.yearRange, disabled: e.disabled, granularities: e.options?.granularities, "max-range": e.options?.maxRange, min: e.options?.min, max: e.options?.max, "date-form-data": e.formData, "show-end-date-on-open": e.options?.showEndDateOnOpen, "aria-labelledby": e.$attrs?.["aria-labelledby"] }, on: { "update:model-value": e.onDateInputSelected } }) : [a("div", { staticClass: "b-date-range-filter" }, [a("date-range-picker-calendar", { attrs: { "allow-time-input": e.options?.allowTimeInput, "first-day-of-week": e.options?.firstDayOfWeek, "is-date-disabled": e.options?.isDateDisabled, granularities: e.options?.granularities, "max-range": e.options?.maxRange, min: e.options?.min, max: e.options?.max, "number-of-months": e.options?.numberOfMonths, "quick-select-ranges": e.adjustedQuickSelectRanges, value: e.internalFilterValue, "date-form-data": e.formData, "show-end-date-on-open": e.options?.showEndDateOnOpen, variant: e.options?.variant, "year-range": e.options?.yearRange }, on: { input: e.onDateSelected, "custom-range": e.onRangeSelectorInput, error: e.onDatePickerRangeError, "form-date": e.onDatePickerRangeFormDateInputUpdate, "start-date-selected": function(n) {
850
+ e.isSelectingDate = !0;
851
+ } }, scopedSlots: e._u([{ key: "title", fn: function() {
852
+ return [a("bento-typography", { attrs: { strongest: "", variant: "body", el: "span" } }, [e._v(" " + e._s(e.label) + " ")])];
853
+ }, proxy: !0 }, { key: "actions", fn: function() {
854
+ return [a("bento-divider", { staticClass: "b-date-range-filter__divider" }), a("bento-button-actions", { staticClass: "b-date-range-filter__actions", attrs: { actions: e.actions, layout: "space-between" } })];
855
+ }, proxy: !0 }]) })], 1)]], 2);
856
+ }, qe = [], Le = /* @__PURE__ */ we(
857
+ Be,
858
+ Re,
859
+ qe,
860
+ !1,
861
+ null,
862
+ "5b7bef98"
863
+ );
864
+ const Ze = Le.exports;
865
+ export {
866
+ Ze as default
867
+ };
868
+ //# sourceMappingURL=date-range-filter.CDrrP22U.js.map