@adyen/bento-vue2 1.83.0 → 1.84.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 (408) hide show
  1. package/README.md +5 -5
  2. package/dist/@types/index.d.ts +1299 -1235
  3. package/dist/action-bar.js +1 -1
  4. package/dist/alert.js +1 -1
  5. package/dist/assets/accordion-item.css +1 -1
  6. package/dist/assets/action-bar.css +1 -1
  7. package/dist/assets/ai-button.css +1 -1
  8. package/dist/assets/alert.css +1 -1
  9. package/dist/assets/avatar.css +1 -1
  10. package/dist/assets/base-modal.css +1 -1
  11. package/dist/assets/button-actions-with-menu.css +1 -1
  12. package/dist/assets/button-actions.css +1 -1
  13. package/dist/assets/button.css +1 -1
  14. package/dist/assets/calendar.css +1 -1
  15. package/dist/assets/card.css +1 -1
  16. package/dist/assets/checkbox-group.css +1 -1
  17. package/dist/assets/checkbox-input.css +1 -1
  18. package/dist/assets/checkbox.css +1 -1
  19. package/dist/assets/chip.css +1 -1
  20. package/dist/assets/code-snippet.css +1 -1
  21. package/dist/assets/controls-group.css +1 -1
  22. package/dist/assets/country.css +1 -1
  23. package/dist/assets/currency.css +1 -1
  24. package/dist/assets/dashboard-section.css +1 -1
  25. package/dist/assets/dashed-underline.css +1 -1
  26. package/dist/assets/data-grid-template.css +1 -1
  27. package/dist/assets/data-grid.css +1 -1
  28. package/dist/assets/date-picker.css +1 -1
  29. package/dist/assets/date-range-picker.css +1 -1
  30. package/dist/assets/date.css +1 -1
  31. package/dist/assets/dialog-page.css +1 -1
  32. package/dist/assets/divider.css +1 -1
  33. package/dist/assets/dropdown-default-textbox.css +1 -1
  34. package/dist/assets/dropdown-tag.css +1 -1
  35. package/dist/assets/dropdown.css +1 -1
  36. package/dist/assets/empty-state.css +1 -1
  37. package/dist/assets/field-label.css +1 -1
  38. package/dist/assets/file-uploader.css +1 -1
  39. package/dist/assets/filter-bar.css +1 -1
  40. package/dist/assets/fixed-scroller.css +1 -1
  41. package/dist/assets/footer-actions.css +1 -1
  42. package/dist/assets/form-layout-title.css +1 -1
  43. package/dist/assets/grid-layout.css +1 -1
  44. package/dist/assets/header-meta.css +1 -1
  45. package/dist/assets/header-with-views.css +1 -1
  46. package/dist/assets/header.css +1 -1
  47. package/dist/assets/index.css +1 -1
  48. package/dist/assets/info-icon.css +1 -1
  49. package/dist/assets/input-field-password.css +1 -1
  50. package/dist/assets/input-field.css +1 -1
  51. package/dist/assets/inspector.css +1 -1
  52. package/dist/assets/layout-row.css +1 -1
  53. package/dist/assets/link.css +1 -1
  54. package/dist/assets/listbox-option-tag.css +1 -1
  55. package/dist/assets/loading-indicator.css +1 -1
  56. package/dist/assets/modal-fullscreen.css +1 -1
  57. package/dist/assets/pagination.css +1 -1
  58. package/dist/assets/payment-method.css +1 -1
  59. package/dist/assets/popper-container.css +1 -1
  60. package/dist/assets/promo-banner.css +1 -1
  61. package/dist/assets/radio-group.css +1 -1
  62. package/dist/assets/radio-input.css +1 -1
  63. package/dist/assets/rich-text-editor.css +1 -1
  64. package/dist/assets/secondary-nav.css +1 -1
  65. package/dist/assets/segmented-control.css +1 -1
  66. package/dist/assets/selection-card-group.css +1 -1
  67. package/dist/assets/sidepanel.css +1 -1
  68. package/dist/assets/status.css +1 -1
  69. package/dist/assets/step.css +1 -1
  70. package/dist/assets/structured-list-item.css +1 -1
  71. package/dist/assets/summary-grid.css +1 -1
  72. package/dist/assets/tab.css +1 -1
  73. package/dist/assets/tag.css +1 -1
  74. package/dist/assets/textarea.css +1 -1
  75. package/dist/assets/timeline-item.css +1 -1
  76. package/dist/assets/toast.css +1 -1
  77. package/dist/assets/toggle.css +1 -1
  78. package/dist/assets/tooltip.css +1 -1
  79. package/dist/assets/tutorial.css +1 -1
  80. package/dist/assets/use-cached-selected-values.css +1 -1
  81. package/dist/button.js +3 -3
  82. package/dist/card.js +1 -1
  83. package/dist/checkbox.js +2 -2
  84. package/dist/chunks/1-generic-use.CZhwP2Yc.js.map +1 -1
  85. package/dist/chunks/1-generic-use.R6x8PEGA.js.map +1 -1
  86. package/dist/chunks/2-generic-use.CNKjB4B7.js.map +1 -1
  87. package/dist/chunks/2-generic-use.w0fUhovx.js.map +1 -1
  88. package/dist/chunks/3-generic-use.BLEzR04g.js.map +1 -1
  89. package/dist/chunks/3-generic-use.D3NFHgI4.js.map +1 -1
  90. package/dist/chunks/4-generic-use.CULEpvgj.js.map +1 -1
  91. package/dist/chunks/4-generic-use.D82y3n39.js.map +1 -1
  92. package/dist/chunks/accordion-item.DeV8s0oW.js.map +1 -1
  93. package/dist/chunks/{action-bar.C2GnRugW.js → action-bar.y4tcdk7R.js} +8 -6
  94. package/dist/chunks/{action-bar.C2GnRugW.js.map → action-bar.y4tcdk7R.js.map} +1 -1
  95. package/dist/chunks/adding-payment-methods.BJZLPxtM.js.map +1 -1
  96. package/dist/chunks/adding-payment-methods.Dle8zt43.js.map +1 -1
  97. package/dist/chunks/adyen-giving.Ffw_DlJK.js.map +1 -1
  98. package/dist/chunks/adyen-giving.LiKHj_jY.js.map +1 -1
  99. package/dist/chunks/{ai-button.C9Uc6vBY.js → ai-button.BEy4Gly-.js} +2 -2
  100. package/dist/chunks/{ai-button.C9Uc6vBY.js.map → ai-button.BEy4Gly-.js.map} +1 -1
  101. package/dist/chunks/{alert.BlJBrD8c.js → alert.B3Pdp02a.js} +29 -21
  102. package/dist/chunks/{alert.BlJBrD8c.js.map → alert.B3Pdp02a.js.map} +1 -1
  103. package/dist/chunks/aria-label.CaUURpnB.js.map +1 -1
  104. package/dist/chunks/avatar.CUCH3CTc.js.map +1 -1
  105. package/dist/chunks/base-button.IN4bpcds.js.map +1 -1
  106. package/dist/chunks/{base-modal.L39wmqVD.js → base-modal.KYkLKswF.js} +20 -18
  107. package/dist/chunks/{base-modal.L39wmqVD.js.map → base-modal.KYkLKswF.js.map} +1 -1
  108. package/dist/chunks/{button-actions-with-menu.CQlsQa_f.js → button-actions-with-menu.B5mKwc-F.js} +2 -2
  109. package/dist/chunks/{button-actions-with-menu.CQlsQa_f.js.map → button-actions-with-menu.B5mKwc-F.js.map} +1 -1
  110. package/dist/chunks/{button-actions.BWVq6OZQ.js → button-actions.D9n7MxWe.js} +270 -239
  111. package/dist/chunks/{button-actions.BWVq6OZQ.js.map → button-actions.D9n7MxWe.js.map} +1 -1
  112. package/dist/chunks/button-actions.types.BptAXjD8.js.map +1 -1
  113. package/dist/chunks/{button.C5GvPqe5.js → button.DIU6m9wD.js} +2 -2
  114. package/dist/chunks/{button.C5GvPqe5.js.map → button.DIU6m9wD.js.map} +1 -1
  115. package/dist/chunks/calendar.C8DpZ4Sr.js +1101 -0
  116. package/dist/chunks/calendar.C8DpZ4Sr.js.map +1 -0
  117. package/dist/chunks/{card.CktheSva.js → card.CLX0RGG6.js} +2 -2
  118. package/dist/chunks/{card.CktheSva.js.map → card.CLX0RGG6.js.map} +1 -1
  119. package/dist/chunks/{checkbox-group.DKkaWwMI.js → checkbox-group.BCnhjQie.js} +4 -4
  120. package/dist/chunks/{checkbox-group.DKkaWwMI.js.map → checkbox-group.BCnhjQie.js.map} +1 -1
  121. package/dist/chunks/{checkbox-input.B0NsfSNR.js → checkbox-input.08E9BNeF.js} +45 -40
  122. package/dist/chunks/checkbox-input.08E9BNeF.js.map +1 -0
  123. package/dist/chunks/{checkbox.B_W1TGP2.js → checkbox.CU5ierOq.js} +16 -16
  124. package/dist/chunks/{checkbox.B_W1TGP2.js.map → checkbox.CU5ierOq.js.map} +1 -1
  125. package/dist/chunks/click-outside.C1Ud8AA2.js.map +1 -1
  126. package/dist/chunks/{code-snippet.1_edHDaZ.js → code-snippet.9MwDHp50.js} +62 -60
  127. package/dist/chunks/code-snippet.9MwDHp50.js.map +1 -0
  128. package/dist/chunks/codemirror.Cy7iSLbd.js.map +1 -1
  129. package/dist/chunks/constructNow.DuaJst0D.js +8 -0
  130. package/dist/chunks/{constructNow.BhymNmy5.js.map → constructNow.DuaJst0D.js.map} +1 -1
  131. package/dist/chunks/{controls-group.BqPxnEl3.js → controls-group.D4eW9DtP.js} +2 -2
  132. package/dist/chunks/{controls-group.BqPxnEl3.js.map → controls-group.D4eW9DtP.js.map} +1 -1
  133. package/dist/chunks/{copy.I2GvwCvt.js → copy.C0q7xgXs.js} +19 -17
  134. package/dist/chunks/{copy.I2GvwCvt.js.map → copy.C0q7xgXs.js.map} +1 -1
  135. package/dist/chunks/{country.BPrh4fXO.js → country.DyrDj95W.js} +2 -2
  136. package/dist/chunks/{country.BPrh4fXO.js.map → country.DyrDj95W.js.map} +1 -1
  137. package/dist/chunks/country.types.DaVCMxk-.js +773 -0
  138. package/dist/chunks/{country.types.C0Q_hhgJ.js.map → country.types.DaVCMxk-.js.map} +1 -1
  139. package/dist/chunks/currency.DYZr_RDk.js.map +1 -1
  140. package/dist/chunks/{dashboard-section.B4bHrFIl.js → dashboard-section.B83FdC0Z.js} +3 -3
  141. package/dist/chunks/{dashboard-section.B4bHrFIl.js.map → dashboard-section.B83FdC0Z.js.map} +1 -1
  142. package/dist/chunks/{dashed-underline.ByK3QxFJ.js → dashed-underline.DQGVy5T2.js} +2 -2
  143. package/dist/chunks/{dashed-underline.ByK3QxFJ.js.map → dashed-underline.DQGVy5T2.js.map} +1 -1
  144. package/dist/chunks/{data-grid-template.CvZbOkih.js → data-grid-template.BTEFoEwf.js} +4 -4
  145. package/dist/chunks/{data-grid-template.CvZbOkih.js.map → data-grid-template.BTEFoEwf.js.map} +1 -1
  146. package/dist/chunks/data-grid-template.keys.VezYtHtM.js.map +1 -1
  147. package/dist/chunks/{data-grid.CVjZ1tKw.js → data-grid.BPG1GPIl.js} +922 -838
  148. package/dist/chunks/{data-grid.CVjZ1tKw.js.map → data-grid.BPG1GPIl.js.map} +1 -1
  149. package/dist/chunks/date-input.BbZqj10S.js +15 -0
  150. package/dist/chunks/date-input.BbZqj10S.js.map +1 -0
  151. package/dist/chunks/{date-picker.-a_TXwjx.js → date-picker.CnsC_UMG.js} +78 -74
  152. package/dist/chunks/date-picker.CnsC_UMG.js.map +1 -0
  153. package/dist/chunks/date-picker.types.Ckt7zxGy.js.map +1 -1
  154. package/dist/chunks/date-range-picker.B6GSRjjK.js +1693 -0
  155. package/dist/chunks/date-range-picker.B6GSRjjK.js.map +1 -0
  156. package/dist/chunks/date-range-picker.types.Ckt7zxGy.js.map +1 -1
  157. package/dist/chunks/date.DBWzp0So.js.map +1 -1
  158. package/dist/chunks/de.DvtL0g75.js +478 -0
  159. package/dist/chunks/de.DvtL0g75.js.map +1 -0
  160. package/dist/chunks/debounce.DUTu11PS.js.map +1 -1
  161. package/dist/chunks/delight.CDBAFnwC.js.map +1 -1
  162. package/dist/chunks/delight.xKDCvvaS.js.map +1 -1
  163. package/dist/chunks/{dialog-page.Dn-WbcxU.js → dialog-page.QpRiNPyx.js} +29 -23
  164. package/dist/chunks/{dialog-page.Dn-WbcxU.js.map → dialog-page.QpRiNPyx.js.map} +1 -1
  165. package/dist/chunks/differenceInMonths.DcFDl4eH.js +43 -0
  166. package/dist/chunks/differenceInMonths.DcFDl4eH.js.map +1 -0
  167. package/dist/chunks/directive.Cbdox5VL.js.map +1 -1
  168. package/dist/chunks/divider.DX5gwN7p.js.map +1 -1
  169. package/dist/chunks/dropdown-default-textbox.Cq68tN9F.js.map +1 -1
  170. package/dist/chunks/{dropdown-tag.AYIB0ec5.js → dropdown-tag.HBM0wrEV.js} +4 -4
  171. package/dist/chunks/{dropdown-tag.AYIB0ec5.js.map → dropdown-tag.HBM0wrEV.js.map} +1 -1
  172. package/dist/chunks/{dropdown.Dt0_ZUBn.js → dropdown.C2pXf8Li.js} +85 -81
  173. package/dist/chunks/{dropdown.Dt0_ZUBn.js.map → dropdown.C2pXf8Li.js.map} +1 -1
  174. package/dist/chunks/{empty-state.jVTWhJW7.js → empty-state.DpBnqAxu.js} +2 -2
  175. package/dist/chunks/{empty-state.jVTWhJW7.js.map → empty-state.DpBnqAxu.js.map} +1 -1
  176. package/dist/chunks/en-GB.DCGuCmAv.js +46 -0
  177. package/dist/chunks/en-GB.DCGuCmAv.js.map +1 -0
  178. package/dist/chunks/{getTimezoneOffsetInMilliseconds.B7sxiukN.js → en-US.BZii9jNW.js} +160 -196
  179. package/dist/chunks/en-US.BZii9jNW.js.map +1 -0
  180. package/dist/chunks/es.bz0mzkMq.js +374 -0
  181. package/dist/chunks/es.bz0mzkMq.js.map +1 -0
  182. package/dist/chunks/es6.C1DXQV6f.js +12 -0
  183. package/dist/chunks/es6.C1DXQV6f.js.map +1 -0
  184. package/dist/chunks/events.BQOQSSb7.js.map +1 -1
  185. package/dist/chunks/{field-label.BpeaR4Qc.js → field-label.CEkJnsiL.js} +5 -5
  186. package/dist/chunks/{field-label.BpeaR4Qc.js.map → field-label.CEkJnsiL.js.map} +1 -1
  187. package/dist/chunks/{file-uploader.G6mr6RuA.js → file-uploader.CnOqfuI-.js} +299 -253
  188. package/dist/chunks/{file-uploader.G6mr6RuA.js.map → file-uploader.CnOqfuI-.js.map} +1 -1
  189. package/dist/chunks/filter-bar.CnJAxz9B.js +2559 -0
  190. package/dist/chunks/filter-bar.CnJAxz9B.js.map +1 -0
  191. package/dist/chunks/fixed-scroller.Bp4-iO80.js +114 -0
  192. package/dist/chunks/{fixed-scroller.Ca1ujamx.js.map → fixed-scroller.Bp4-iO80.js.map} +1 -1
  193. package/dist/chunks/focus-trap.CNIU5jOz.js.map +1 -1
  194. package/dist/chunks/{footer-actions.3JdT8b0p.js → footer-actions.BOiN47Xd.js} +3 -3
  195. package/dist/chunks/{footer-actions.3JdT8b0p.js.map → footer-actions.BOiN47Xd.js.map} +1 -1
  196. package/dist/chunks/form-field.D_2g7vaP.js.map +1 -1
  197. package/dist/chunks/{form-layout-title.D9GJQfF9.js → form-layout-title.CdC1T4gs.js} +2 -2
  198. package/dist/chunks/{form-layout-title.D9GJQfF9.js.map → form-layout-title.CdC1T4gs.js.map} +1 -1
  199. package/dist/chunks/form-layout.types.bZW9iR6_.js.map +1 -1
  200. package/dist/chunks/fr-CA.B1aPU8fp.js +48 -0
  201. package/dist/chunks/fr-CA.B1aPU8fp.js.map +1 -0
  202. package/dist/chunks/fr.Dj7wEToe.js +47 -0
  203. package/dist/chunks/fr.Dj7wEToe.js.map +1 -0
  204. package/dist/chunks/generate-uid.NJ8tVoha.js.map +1 -1
  205. package/dist/chunks/getRoundingMethod.C3eaeGLR.js.map +1 -1
  206. package/dist/chunks/getTimezoneOffsetInMilliseconds.C-aIpRfB.js +51 -0
  207. package/dist/chunks/getTimezoneOffsetInMilliseconds.C-aIpRfB.js.map +1 -0
  208. package/dist/chunks/grid-layout.1aIiz2N_.js.map +1 -1
  209. package/dist/chunks/header-meta.D_oAu2S9.js +212 -0
  210. package/dist/chunks/header-meta.D_oAu2S9.js.map +1 -0
  211. package/dist/chunks/{header-with-views.3fF_V6F9.js → header-with-views.Dc9LUYNY.js} +379 -315
  212. package/dist/chunks/{header-with-views.3fF_V6F9.js.map → header-with-views.Dc9LUYNY.js.map} +1 -1
  213. package/dist/chunks/{header.D76MKCdS.js → header.BmtlQmPs.js} +3 -3
  214. package/dist/chunks/{header.D76MKCdS.js.map → header.BmtlQmPs.js.map} +1 -1
  215. package/dist/chunks/image.C2D2hKat.js.map +1 -1
  216. package/dist/chunks/index.B6WW_F-J.js.map +1 -1
  217. package/dist/chunks/index.BDK4hwK_.js.map +1 -1
  218. package/dist/chunks/{input-field-password.C7zjyp7f.js → input-field-password.D23H_RvO.js} +48 -42
  219. package/dist/chunks/{input-field-password.C7zjyp7f.js.map → input-field-password.D23H_RvO.js.map} +1 -1
  220. package/dist/chunks/{input-field-phone-number.DwuTziSU.js → input-field-phone-number.Bvk2Pvec.js} +9 -3
  221. package/dist/chunks/{input-field-phone-number.DwuTziSU.js.map → input-field-phone-number.Bvk2Pvec.js.map} +1 -1
  222. package/dist/chunks/{input-field.DsT4AWXC.js → input-field.hf0_ALq0.js} +37 -29
  223. package/dist/chunks/{input-field.DsT4AWXC.js.map → input-field.hf0_ALq0.js.map} +1 -1
  224. package/dist/chunks/{inspector.2A5vWUou.js → inspector.C0iAxxoz.js} +40 -34
  225. package/dist/chunks/{inspector.2A5vWUou.js.map → inspector.C0iAxxoz.js.map} +1 -1
  226. package/dist/chunks/inspector.types.DyHwE18g.js.map +1 -1
  227. package/dist/chunks/internal-error.BLZodVBE.js.map +1 -1
  228. package/dist/chunks/internal-error.BmrwJFpR.js.map +1 -1
  229. package/dist/chunks/isSameWeek.CUD7czUN.js +14 -0
  230. package/dist/chunks/isSameWeek.CUD7czUN.js.map +1 -0
  231. package/dist/chunks/it.Oaj6BklL.js +392 -0
  232. package/dist/chunks/it.Oaj6BklL.js.map +1 -0
  233. package/dist/chunks/ja.Cm9tJMi2.js +367 -0
  234. package/dist/chunks/ja.Cm9tJMi2.js.map +1 -0
  235. package/dist/chunks/keyboard-navigation.DWmhelVv.js.map +1 -1
  236. package/dist/chunks/ko.Ceaof6EP.js +348 -0
  237. package/dist/chunks/ko.Ceaof6EP.js.map +1 -0
  238. package/dist/chunks/layout-row.BPX00mio.js.map +1 -1
  239. package/dist/chunks/{link.BoDUCYmM.js → link.PsTSQjK3.js} +27 -21
  240. package/dist/chunks/{link.BoDUCYmM.js.map → link.PsTSQjK3.js.map} +1 -1
  241. package/dist/chunks/loading-indicator.PxbRzshH.js.map +1 -1
  242. package/dist/chunks/match.CMBZxEs9.js +302 -0
  243. package/dist/chunks/match.CMBZxEs9.js.map +1 -0
  244. package/dist/chunks/minus-small.DJacLGTw.js.map +1 -1
  245. package/dist/chunks/{modal-fullscreen.CcvZBUoF.js → modal-fullscreen.B1gltlxA.js} +5 -5
  246. package/dist/chunks/{modal-fullscreen.CcvZBUoF.js.map → modal-fullscreen.B1gltlxA.js.map} +1 -1
  247. package/dist/chunks/{modal.6hFEbnZM.js → modal.e3EQ6Kex.js} +5 -5
  248. package/dist/chunks/{modal.6hFEbnZM.js.map → modal.e3EQ6Kex.js.map} +1 -1
  249. package/dist/chunks/nl.B6vCf2B9.js +327 -0
  250. package/dist/chunks/nl.B6vCf2B9.js.map +1 -0
  251. package/dist/chunks/no-results-found.Bg_ZcEid.js.map +1 -1
  252. package/dist/chunks/no-results-found.BqvYsBR6.js.map +1 -1
  253. package/dist/chunks/notifications-cleared.BMZk37uf.js.map +1 -1
  254. package/dist/chunks/notifications-cleared.C7W9ZXY7.js.map +1 -1
  255. package/dist/chunks/on-click-outside.D9aY9g8G.js.map +1 -1
  256. package/dist/chunks/page-not-found.COJLPVaU.js.map +1 -1
  257. package/dist/chunks/page-not-found.DWW6W-PZ.js.map +1 -1
  258. package/dist/chunks/{pagination.BSyshRGH.js → pagination.BcFt2FqK.js} +6 -6
  259. package/dist/chunks/{pagination.BSyshRGH.js.map → pagination.BcFt2FqK.js.map} +1 -1
  260. package/dist/chunks/payment-method.BKXLPDC9.js.map +1 -1
  261. package/dist/chunks/payment-method.types.BqtH7RM2.js.map +1 -1
  262. package/dist/chunks/planned-maintenance.C61sWB9h.js.map +1 -1
  263. package/dist/chunks/planned-maintenance.jmWYTdet.js.map +1 -1
  264. package/dist/chunks/popover.types.WDh5ggr3.js.map +1 -1
  265. package/dist/chunks/popper-container.Cdokz_NE.js.map +1 -1
  266. package/dist/chunks/{promo-banner.D3aG5wnp.js → promo-banner.yfBorKj7.js} +2 -2
  267. package/dist/chunks/{promo-banner.D3aG5wnp.js.map → promo-banner.yfBorKj7.js.map} +1 -1
  268. package/dist/chunks/pt-BR.CiGdfP45.js +380 -0
  269. package/dist/chunks/pt-BR.CiGdfP45.js.map +1 -0
  270. package/dist/chunks/{radio-group.DTZwsfwW.js → radio-group.CtTnfkYg.js} +3 -3
  271. package/dist/chunks/{radio-group.DTZwsfwW.js.map → radio-group.CtTnfkYg.js.map} +1 -1
  272. package/dist/chunks/radio-input.kzb4gxLW.js.map +1 -1
  273. package/dist/chunks/referrals.BvtT-kQS.js.map +1 -1
  274. package/dist/chunks/referrals.aX8WZigH.js.map +1 -1
  275. package/dist/chunks/resize.Bqks3WUm.js.map +1 -1
  276. package/dist/chunks/{rich-text-editor.BbvfrqHl.js → rich-text-editor.Dq2CFGOu.js} +5 -5
  277. package/dist/chunks/{rich-text-editor.BbvfrqHl.js.map → rich-text-editor.Dq2CFGOu.js.map} +1 -1
  278. package/dist/chunks/{search-bar.Bpk-PuYT.js → search-bar.B0SdQBnY.js} +3 -3
  279. package/dist/chunks/{search-bar.Bpk-PuYT.js.map → search-bar.B0SdQBnY.js.map} +1 -1
  280. package/dist/chunks/{secondary-nav.BGOYJrsB.js → secondary-nav.BPGpxd0p.js} +35 -29
  281. package/dist/chunks/{secondary-nav.BGOYJrsB.js.map → secondary-nav.BPGpxd0p.js.map} +1 -1
  282. package/dist/chunks/segmented-control.types.BHRLV8KU.js.map +1 -1
  283. package/dist/chunks/{selection-card-group.BWLjFcea.js → selection-card-group.BryV14qP.js} +13 -13
  284. package/dist/chunks/{selection-card-group.BWLjFcea.js.map → selection-card-group.BryV14qP.js.map} +1 -1
  285. package/dist/chunks/{sidepanel.C5SvJNMR.js → sidepanel.NFyZGE57.js} +5 -5
  286. package/dist/chunks/{sidepanel.C5SvJNMR.js.map → sidepanel.NFyZGE57.js.map} +1 -1
  287. package/dist/chunks/startOfWeek.Dxw2MhGp.js +10 -0
  288. package/dist/chunks/startOfWeek.Dxw2MhGp.js.map +1 -0
  289. package/dist/chunks/status.types.Cv5XN4zL.js.map +1 -1
  290. package/dist/chunks/step.BLFXvHL6.js +223 -0
  291. package/dist/chunks/step.BLFXvHL6.js.map +1 -0
  292. package/dist/chunks/{structured-list-item.CbXDKwsF.js → structured-list-item.CptOCpHP.js} +3 -3
  293. package/dist/chunks/{structured-list-item.CbXDKwsF.js.map → structured-list-item.CptOCpHP.js.map} +1 -1
  294. package/dist/chunks/success.DhioLvPD.js.map +1 -1
  295. package/dist/chunks/success.nNwxJRBS.js.map +1 -1
  296. package/dist/chunks/summary-grid.keys.Xx-W5a2w.js.map +1 -1
  297. package/dist/chunks/{summary-grid.types.haWi7oaf.js → summary-grid.types.B1T8_k1m.js} +3 -3
  298. package/dist/chunks/{summary-grid.types.haWi7oaf.js.map → summary-grid.types.B1T8_k1m.js.map} +1 -1
  299. package/dist/chunks/sv.f8EfZjMZ.js +377 -0
  300. package/dist/chunks/sv.f8EfZjMZ.js.map +1 -0
  301. package/dist/chunks/{tab.ZQfGp_FP.js → tab.FUMpPsBP.js} +2 -2
  302. package/dist/chunks/{tab.ZQfGp_FP.js.map → tab.FUMpPsBP.js.map} +1 -1
  303. package/dist/chunks/tabs.keys.B4qGhjp2.js.map +1 -1
  304. package/dist/chunks/tag.B1Ywhgvc.js.map +1 -1
  305. package/dist/chunks/{textarea.DfR2o1lz.js → textarea.riUt0BiI.js} +31 -31
  306. package/dist/chunks/textarea.riUt0BiI.js.map +1 -0
  307. package/dist/chunks/{timeline-item.rLqeBsyz.js → timeline-item.CFfW1DoD.js} +16 -15
  308. package/dist/chunks/{timeline-item.rLqeBsyz.js.map → timeline-item.CFfW1DoD.js.map} +1 -1
  309. package/dist/chunks/{toast.C7lu_NsX.js → toast.Csv6tMyT.js} +2 -2
  310. package/dist/chunks/{toast.C7lu_NsX.js.map → toast.Csv6tMyT.js.map} +1 -1
  311. package/dist/chunks/toggle.227XgEc7.js.map +1 -1
  312. package/dist/chunks/tooltip.C6YCavPw.js.map +1 -1
  313. package/dist/chunks/truncate.BfIl_-71.js.map +1 -1
  314. package/dist/chunks/{tutorial.DdRGxTC5.js → tutorial.D18LwXVy.js} +5 -5
  315. package/dist/chunks/{tutorial.DdRGxTC5.js.map → tutorial.D18LwXVy.js.map} +1 -1
  316. package/dist/chunks/typography.Bq-EGj9y.js.map +1 -1
  317. package/dist/chunks/upload-files.5wQwbfkp.js.map +1 -1
  318. package/dist/chunks/upload-files.jTQY6y2X.js.map +1 -1
  319. package/dist/chunks/use-bento-toast-controller.MmyZXtME.js.map +1 -1
  320. package/dist/chunks/{use-cached-selected-values.DIKJ8yNE.js → use-cached-selected-values.gDWGi5Nk.js} +240 -231
  321. package/dist/chunks/{use-cached-selected-values.DIKJ8yNE.js.map → use-cached-selected-values.gDWGi5Nk.js.map} +1 -1
  322. package/dist/chunks/{use-country-items.B3Cd3Tdo.js → use-country-items.ClS_So5N.js} +2 -2
  323. package/dist/chunks/{use-country-items.B3Cd3Tdo.js.map → use-country-items.ClS_So5N.js.map} +1 -1
  324. package/dist/chunks/use-country-phon-code.Bui3zD6W.js.map +1 -1
  325. package/dist/chunks/use-default-slot-validator.BDn0wkYP.js.map +1 -1
  326. package/dist/chunks/use-expandable-content-height.GkjjbmPy.js.map +1 -1
  327. package/dist/chunks/use-form-layout-loading.CWbjZiwP.js.map +1 -1
  328. package/dist/chunks/wrong-environment.BOsyKdRI.js.map +1 -1
  329. package/dist/chunks/wrong-environment.BiHTPtbJ.js.map +1 -1
  330. package/dist/chunks/zh-CN.BzH0fIXr.js +389 -0
  331. package/dist/chunks/zh-CN.BzH0fIXr.js.map +1 -0
  332. package/dist/code-snippet.js +1 -1
  333. package/dist/country.js +2 -2
  334. package/dist/dashboard-template.js +1 -1
  335. package/dist/dashed-underline.js +1 -1
  336. package/dist/data-grid-template.js +1 -1
  337. package/dist/data-grid.js +1 -1
  338. package/dist/date-picker.js +2 -2
  339. package/dist/date-range-picker.js +2 -2
  340. package/dist/dropdown.js +3 -3
  341. package/dist/empty-state.js +1 -1
  342. package/dist/file-uploader.js +1 -1
  343. package/dist/filter-bar.js +1 -1
  344. package/dist/form-layout.js +1 -1
  345. package/dist/header-with-views.js +1 -1
  346. package/dist/header.js +1 -1
  347. package/dist/index.js +250 -251
  348. package/dist/index.js.map +1 -1
  349. package/dist/input-field-password.js +1 -1
  350. package/dist/input-field-phone-number.js +1 -1
  351. package/dist/input-field.js +1 -1
  352. package/dist/inspector.js +1 -1
  353. package/dist/internal.js +10 -10
  354. package/dist/link.js +1 -1
  355. package/dist/menu.js +1 -1
  356. package/dist/modal-fullscreen.js +1 -1
  357. package/dist/modal.js +2 -2
  358. package/dist/pagination.js +1 -1
  359. package/dist/popover.js +1 -1
  360. package/dist/promo-banner.js +1 -1
  361. package/dist/radio-group.js +1 -1
  362. package/dist/rich-text-editor.js +1 -1
  363. package/dist/search-bar.js +2 -2
  364. package/dist/secondary-nav.js +1 -1
  365. package/dist/selection-card.js +1 -1
  366. package/dist/sidepanel.js +1 -1
  367. package/dist/stepper.js +1 -1
  368. package/dist/structured-list.js +1 -1
  369. package/dist/styles/bento-dark.css +0 -1829
  370. package/dist/styles/bento-light.css +0 -1829
  371. package/dist/styles/bento.css +0 -1829
  372. package/dist/styles/legacy.css +0 -1829
  373. package/dist/styles/styleguide.css +0 -1829
  374. package/dist/summary-grid.js +1 -1
  375. package/dist/tabs.js +1 -1
  376. package/dist/textarea.js +1 -1
  377. package/dist/timeline.js +1 -1
  378. package/dist/toast.js +1 -1
  379. package/dist/tutorial.js +1 -1
  380. package/dist/use-form-v4.js.map +1 -1
  381. package/package.json +15 -26
  382. package/dist/@types/components.d.ts +0 -196
  383. package/dist/@types/use-form-v4.d.ts +0 -86
  384. package/dist/chunks/calendar.DCLyThOl.js +0 -1832
  385. package/dist/chunks/calendar.DCLyThOl.js.map +0 -1
  386. package/dist/chunks/checkbox-input.B0NsfSNR.js.map +0 -1
  387. package/dist/chunks/code-snippet.1_edHDaZ.js.map +0 -1
  388. package/dist/chunks/constructNow.BhymNmy5.js +0 -8
  389. package/dist/chunks/country.types.C0Q_hhgJ.js +0 -269
  390. package/dist/chunks/date-format.B8RU7D42.js +0 -17
  391. package/dist/chunks/date-format.B8RU7D42.js.map +0 -1
  392. package/dist/chunks/date-picker.-a_TXwjx.js.map +0 -1
  393. package/dist/chunks/date-range-picker.Bw1yPTu-.js +0 -906
  394. package/dist/chunks/date-range-picker.Bw1yPTu-.js.map +0 -1
  395. package/dist/chunks/differenceInMonths.Cab3nOsb.js +0 -1590
  396. package/dist/chunks/differenceInMonths.Cab3nOsb.js.map +0 -1
  397. package/dist/chunks/es6.MoTTyETW.js +0 -12
  398. package/dist/chunks/es6.MoTTyETW.js.map +0 -1
  399. package/dist/chunks/filter-bar.CgJA4tIt.js +0 -2472
  400. package/dist/chunks/filter-bar.CgJA4tIt.js.map +0 -1
  401. package/dist/chunks/fixed-scroller.Ca1ujamx.js +0 -106
  402. package/dist/chunks/getTimezoneOffsetInMilliseconds.B7sxiukN.js.map +0 -1
  403. package/dist/chunks/header-meta.C8_W0j_p.js +0 -170
  404. package/dist/chunks/header-meta.C8_W0j_p.js.map +0 -1
  405. package/dist/chunks/step.mqn8E6dm.js +0 -217
  406. package/dist/chunks/step.mqn8E6dm.js.map +0 -1
  407. package/dist/chunks/textarea.DfR2o1lz.js.map +0 -1
  408. package/dist/web-types.json +0 -17280
@@ -1,1832 +0,0 @@
1
- import { defineComponent as ue, computed as N, ref as V, watch as p, nextTick as ze, toRef as B, reactive as Ce } from "vue";
2
- import { B as Re } from "./button.C5GvPqe5.js";
3
- import { B as Fe } from "./typography.Bq-EGj9y.js";
4
- import { u as Ae } from "./index.B6WW_F-J.js";
5
- import { d as Me, g as pe, a as De } from "./differenceInMonths.Cab3nOsb.js";
6
- import { g as Be } from "./generate-uid.NJ8tVoha.js";
7
- import { a as et } from "./index.BDK4hwK_.js";
8
- import { b as ee, t as O, c as C, n as me, g as Ee, o as tt, p as We, e as nt } from "./getTimezoneOffsetInMilliseconds.B7sxiukN.js";
9
- import { C as Ge, a as He } from "./chevron-left.BS24hEFa.js";
10
- import { a as Ue } from "./keyboard-navigation.DWmhelVv.js";
11
- import { B as $e, a as qe } from "./date.DBWzp0So.js";
12
- import { n as oe } from "./_plugin-vue2_normalizer.CeySl7Fu.js";
13
- import "../assets/calendar.css";
14
- var F = /* @__PURE__ */ ((t) => (t.SINGLE = "single", t.MIDDLE = "middle", t.BEGINNING = "beginning", t.END = "end", t))(F || {}), H = /* @__PURE__ */ ((t) => (t.SINGLE = "single", t.MIDDLE = "middle", t.BEGINNING = "beginning", t.END = "end", t.SELECTED = "selected", t.UNSELECTED = "unselected", t.CURRENT_DAY = "current-day", t.DISABLED = "disabled", t))(H || {}), ae = /* @__PURE__ */ ((t) => (t.CLICK = "click", t.MOUSE_OVER = "mouseover", t))(ae || {});
15
- const at = {
16
- /**
17
- * Date to be displayed as the calendar day. From 1st to 31st (or end of the month defined in the date)
18
- */
19
- day: { type: Date, required: !0 },
20
- /**
21
- * Indicate if a date should be disabled or not
22
- */
23
- disabled: { type: Boolean, default: !1 },
24
- /**
25
- * Changes the state of the calendar day to selected.
26
- */
27
- selected: { type: Boolean, default: !1 },
28
- /**
29
- * When the day is selected, this indicates if the selection is a single date or part of a range.
30
- * If it's a range it can be at the beginning, middle or end of the selection.
31
- */
32
- variant: {
33
- type: String,
34
- default: F.SINGLE,
35
- validator: (t) => Object.values(F).includes(t)
36
- }
37
- }, rt = ue({
38
- name: "calendar-month-day",
39
- components: { BentoDate: $e },
40
- inheritAttrs: !0,
41
- props: at,
42
- emits: [ae.CLICK, ae.MOUSE_OVER],
43
- setup(t, { emit: e }) {
44
- const n = N(() => {
45
- const s = /* @__PURE__ */ new Date();
46
- return t.day.getDate() === s.getDate() && t.day.getMonth() === s.getMonth() && t.day.getFullYear() === s.getFullYear();
47
- });
48
- return {
49
- // Values
50
- conditionalClasses: N(() => ({
51
- // Variants
52
- [`b-calendar-month-day--${H.BEGINNING}`]: t.variant === F.BEGINNING,
53
- [`b-calendar-month-day--${H.MIDDLE}`]: t.variant === F.MIDDLE,
54
- [`b-calendar-month-day--${H.END}`]: t.variant === F.END,
55
- [`b-calendar-month-day--${H.SINGLE}`]: t.variant === F.SINGLE,
56
- // Selected
57
- [`b-calendar-month-day--${H.UNSELECTED}`]: !t.selected,
58
- [`b-calendar-month-day--${H.SELECTED}`]: t.selected,
59
- // Current Day
60
- [`b-calendar-month-day--${H.CURRENT_DAY}`]: n.value,
61
- // Disabled
62
- [`b-calendar-month-day--${H.DISABLED}`]: t.disabled
63
- })),
64
- isCurrentDay: n,
65
- // Enums
66
- BentoDateFormat: qe,
67
- CalendarMonthDayEvent: ae,
68
- // Events
69
- onClick: (s, u) => {
70
- t.disabled ? (s.preventDefault(), s.stopPropagation()) : e(ae.CLICK, u, t.day);
71
- }
72
- };
73
- }
74
- });
75
- var st = function() {
76
- var e = this, n = e._self._c;
77
- return e._self._setupProxy, n("td", { staticClass: "b-calendar-month-day", class: e.conditionalClasses, attrs: { tabindex: e.selected ? "0" : "-1", "aria-selected": e.selected ? e.selected : void 0, "aria-disabled": e.disabled, "aria-current": e.isCurrentDay ? "date" : void 0, "data-date": e.day.toDateString() }, on: { click: (a) => e.onClick(a, e.day), mouseover: function(a) {
78
- return e.$emit(e.CalendarMonthDayEvent.MOUSE_OVER);
79
- }, keydown: function(a) {
80
- return !a.type.indexOf("key") && e._k(a.keyCode, "space", 32, a.key, [" ", "Spacebar"]) && e._k(a.keyCode, "enter", 13, a.key, "Enter") ? null : ((r) => e.onClick(r, e.day)).apply(null, arguments);
81
- } } }, [n("div", { staticClass: "b-calendar-month-day__wrapper" }, [n("bento-date", { staticClass: "b-calendar-month-day__label", attrs: { date: e.day, format: e.BentoDateFormat.DAY_OF_MONTH } })], 1)]);
82
- }, ut = [], ot = /* @__PURE__ */ oe(
83
- rt,
84
- st,
85
- ut,
86
- !1,
87
- null,
88
- "1ff0b36f"
89
- );
90
- const ct = ot.exports;
91
- function $(t, e) {
92
- var l, D, d, h;
93
- const n = ee(), a = (e == null ? void 0 : e.weekStartsOn) ?? ((D = (l = e == null ? void 0 : e.locale) == null ? void 0 : l.options) == null ? void 0 : D.weekStartsOn) ?? n.weekStartsOn ?? ((h = (d = n.locale) == null ? void 0 : d.options) == null ? void 0 : h.weekStartsOn) ?? 0, r = O(t, e == null ? void 0 : e.in), s = r.getDay(), u = (s < a ? 7 : 0) + s - a;
94
- return r.setDate(r.getDate() - u), r.setHours(0, 0, 0, 0), r;
95
- }
96
- var R = /* @__PURE__ */ ((t) => (t.INPUT = "input", t.MOUSE_OVER = "mouseover", t.CHANGE_DAY = "changeDay", t.NEXT_MONTH = "nextMonth", t.PREVIOUS_MONTH = "previousMonth", t))(R || {}), X = /* @__PURE__ */ ((t) => (t[t.MONDAY = 1] = "MONDAY", t[t.SATURDAY = 6] = "SATURDAY", t[t.SUNDAY = 0] = "SUNDAY", t))(X || {}), z = /* @__PURE__ */ ((t) => (t.FIRST = "first", t.LAST = "last", t.MIDDLE = "middle", t.UNIQUE = "unique", t))(z || {}), j = /* @__PURE__ */ ((t) => (t.INPUT = "input", t.START_DATE_SELECTED = "start-date-selected", t.END_DATE_SELECTED = "end-date-selected", t))(j || {}), ge = /* @__PURE__ */ ((t) => (t.DAY = "day", t.MONTH = "month", t))(ge || {});
97
- function se(t, e, n) {
98
- const a = O(t, n == null ? void 0 : n.in);
99
- return isNaN(e) ? C(t, NaN) : (e && a.setDate(a.getDate() + e), a);
100
- }
101
- function K(t, e, n) {
102
- const a = O(t, n == null ? void 0 : n.in);
103
- if (isNaN(e)) return C(t, NaN);
104
- if (!e)
105
- return a;
106
- const r = a.getDate(), s = C(t, a.getTime());
107
- s.setMonth(a.getMonth() + e + 1, 0);
108
- const u = s.getDate();
109
- return r >= u ? s : (a.setFullYear(
110
- s.getFullYear(),
111
- s.getMonth(),
112
- r
113
- ), a);
114
- }
115
- function le(t, e) {
116
- var l, D, d, h;
117
- const n = ee(), a = (e == null ? void 0 : e.weekStartsOn) ?? ((D = (l = e == null ? void 0 : e.locale) == null ? void 0 : l.options) == null ? void 0 : D.weekStartsOn) ?? n.weekStartsOn ?? ((h = (d = n.locale) == null ? void 0 : d.options) == null ? void 0 : h.weekStartsOn) ?? 0, r = O(t, e == null ? void 0 : e.in), s = r.getDay(), u = (s < a ? -7 : 0) + 6 - (s - a);
118
- return r.setDate(r.getDate() + u), r.setHours(23, 59, 59, 999), r;
119
- }
120
- function it(t, e) {
121
- const n = O(t, e == null ? void 0 : e.in), a = n.getFullYear(), r = n.getMonth(), s = C(n, 0);
122
- return s.setFullYear(a, r + 1, 0), s.setHours(0, 0, 0, 0), s.getDate();
123
- }
124
- function lt(t, e, n) {
125
- const a = O(t, n == null ? void 0 : n.in), r = a.getFullYear(), s = a.getDate(), u = C(t, 0);
126
- u.setFullYear(r, e, 15), u.setHours(0, 0, 0, 0);
127
- const l = it(u);
128
- return a.setMonth(e, Math.min(s, l)), a;
129
- }
130
- function dt(t, e, n) {
131
- let a = O(t, n == null ? void 0 : n.in);
132
- return isNaN(+a) ? C(t, NaN) : (e.year != null && a.setFullYear(e.year), e.month != null && (a = lt(a, e.month)), e.date != null && a.setDate(e.date), e.hours != null && a.setHours(e.hours), e.minutes != null && a.setMinutes(e.minutes), e.seconds != null && a.setSeconds(e.seconds), e.milliseconds != null && a.setMilliseconds(e.milliseconds), a);
133
- }
134
- function we(t, e) {
135
- const n = O(t, e == null ? void 0 : e.in);
136
- return n.setFullYear(n.getFullYear(), 0, 1), n.setHours(0, 0, 0, 0), n;
137
- }
138
- function _e(t, e, n) {
139
- return se(t, -e, n);
140
- }
141
- function re(t, e, n) {
142
- return K(t, -e, n);
143
- }
144
- const je = ({ currentSelectedDate: t, month: e, isDateDisabled: n, firstDayOfWeek: a }, r) => {
145
- const s = V(new Date(e.value));
146
- p(
147
- e,
148
- () => {
149
- s.value = e.value;
150
- },
151
- { immediate: !0 }
152
- );
153
- const u = V(new Date(t.value));
154
- p(t, () => {
155
- u.value = new Date(t.value);
156
- });
157
- const l = et(), D = V(u.value);
158
- p(l, (i) => {
159
- const k = i.getAttribute("data-date");
160
- D.value = k ? new Date(k) : u.value;
161
- });
162
- const d = V({}), h = (i) => (k) => {
163
- d.value[i.toDateString()] = k;
164
- }, v = () => {
165
- d.value = {};
166
- }, y = (i = 1) => {
167
- s.value = K(s.value, i), r(R.NEXT_MONTH, i), v();
168
- }, f = (i = 1) => {
169
- s.value = re(s.value, i), r(R.PREVIOUS_MONTH, i), v();
170
- }, o = (i, k) => {
171
- const x = !!d.value[i == null ? void 0 : i.toDateString()];
172
- return !i || !x ? null : k ? d.value[i.toDateString()].$el : (d.value[i.toDateString()].$el.focus(), null);
173
- }, c = (i) => {
174
- i.preventDefault(), i.stopImmediatePropagation(), i.stopPropagation();
175
- }, w = ({ nextDate: i, isIncreasingDays: k, amountOfMonths: x, isCalendarButtonsNav: G }) => {
176
- if (!G && n && n(i))
177
- return;
178
- i.getMonth() === u.value.getMonth() && i.getFullYear() === u.value.getFullYear() ? (u.value = i, o(i)) : (k ? y(x) : f(x), ze(() => {
179
- const M = i.getMonth() === s.value.getMonth() && i.getFullYear() === s.value.getFullYear();
180
- n && n(i) || !M || G || (u.value = i, o(i));
181
- }));
182
- };
183
- return {
184
- // Calendar days ref
185
- calendarRef: d,
186
- addDayRef: h,
187
- /**
188
- * Month navigation
189
- */
190
- showNextMonth: y,
191
- showPreviousMonth: f,
192
- /**
193
- * Focus method
194
- */
195
- focusOnDate: o,
196
- /**
197
- * Day navigation
198
- */
199
- // ArrowRight
200
- moveToNextDay: (i) => {
201
- c(i), w({ nextDate: se(D.value, 1), isIncreasingDays: !0 });
202
- },
203
- // ArrowLeft
204
- moveToPreviousDay: (i) => {
205
- c(i), w({ nextDate: _e(D.value, 1), isIncreasingDays: !1 });
206
- },
207
- // ArrowUp
208
- moveToPreviousWeek: (i) => {
209
- c(i), w({ nextDate: _e(D.value, 7), isIncreasingDays: !1 });
210
- },
211
- // ArrowDown
212
- moveToNextWeek: (i) => {
213
- c(i), w({ nextDate: se(D.value, 7), isIncreasingDays: !0 });
214
- },
215
- // Home
216
- moveToFirstDayOfWeek: (i) => {
217
- c(i), w({
218
- nextDate: $(D.value, { weekStartsOn: a }),
219
- isIncreasingDays: !1
220
- });
221
- },
222
- moveToFirstMonthOfYear: (i) => {
223
- c(i);
224
- const k = Me(u.value, we(u.value));
225
- w({
226
- nextDate: we(u.value),
227
- isIncreasingDays: !1,
228
- amountOfMonths: k
229
- });
230
- },
231
- // End
232
- moveToLastDayOfWeek: (i) => {
233
- c(i), w({
234
- nextDate: le(D.value, { weekStartsOn: a }),
235
- isIncreasingDays: !0
236
- });
237
- },
238
- moveToLastMonthOfYear: (i) => {
239
- c(i);
240
- const k = dt(u.value, { month: 11, date: 1 }), x = Me(k, u.value);
241
- w({
242
- nextDate: k,
243
- isIncreasingDays: !0,
244
- amountOfMonths: x
245
- });
246
- },
247
- // PageUp
248
- moveToPreviousMonth: (i, k = !1, x = 1) => {
249
- c(i);
250
- const G = x;
251
- w({
252
- nextDate: re(D.value, G),
253
- isIncreasingDays: !1,
254
- amountOfMonths: G,
255
- isCalendarButtonsNav: k
256
- });
257
- },
258
- // Shift+PageUp
259
- moveToPreviousYear: (i, k = !1) => {
260
- c(i);
261
- const x = 12;
262
- w({
263
- nextDate: re(D.value, x),
264
- isIncreasingDays: !1,
265
- amountOfMonths: x,
266
- isCalendarButtonsNav: k
267
- });
268
- },
269
- // PageDown
270
- moveToNextMonth: (i, k = !1, x = 1) => {
271
- c(i);
272
- const G = x;
273
- w({
274
- nextDate: K(D.value, G),
275
- isIncreasingDays: !0,
276
- amountOfMonths: G,
277
- isCalendarButtonsNav: k
278
- });
279
- },
280
- // Shift-PageDown
281
- moveToNextYear: (i, k = !1) => {
282
- c(i);
283
- const x = 12;
284
- w({
285
- nextDate: K(D.value, x),
286
- isIncreasingDays: !0,
287
- amountOfMonths: x,
288
- isCalendarButtonsNav: k
289
- });
290
- },
291
- // Values
292
- internalDate: u,
293
- baseDate: s
294
- };
295
- };
296
- function ft(t, e, n) {
297
- var v, y;
298
- const a = ee(), r = a.weekStartsOn ?? ((y = (v = a.locale) == null ? void 0 : v.options) == null ? void 0 : y.weekStartsOn) ?? 0, s = O(t, n == null ? void 0 : n.in), u = s.getDay(), D = (e % 7 + 7) % 7, d = 7 - r, h = e < 0 || e > 6 ? e - (u + d) % 7 : (D + d) % 7 - (u + d) % 7;
299
- return se(s, h, n);
300
- }
301
- function de(t, e) {
302
- const n = O(t, e == null ? void 0 : e.in);
303
- return n.setDate(1), n.setHours(0, 0, 0, 0), n;
304
- }
305
- function J(t, e) {
306
- const n = O(t, e == null ? void 0 : e.in);
307
- return n.setHours(0, 0, 0, 0), n;
308
- }
309
- function Qe(t, e, n) {
310
- const [a, r] = me(
311
- n == null ? void 0 : n.in,
312
- t,
313
- e
314
- ), s = J(a), u = J(r), l = +s - Ee(s), D = +u - Ee(u);
315
- return Math.round((l - D) / tt);
316
- }
317
- function ht(t, e) {
318
- const n = O(t, e == null ? void 0 : e.in);
319
- return Qe(n, we(n)) + 1;
320
- }
321
- function fe(t, e) {
322
- return $(t, { ...e, weekStartsOn: 1 });
323
- }
324
- function Ve(t, e) {
325
- const n = O(t, e == null ? void 0 : e.in), a = n.getFullYear(), r = C(n, 0);
326
- r.setFullYear(a + 1, 0, 4), r.setHours(0, 0, 0, 0);
327
- const s = fe(r), u = C(n, 0);
328
- u.setFullYear(a, 0, 4), u.setHours(0, 0, 0, 0);
329
- const l = fe(u);
330
- return n.getTime() >= s.getTime() ? a + 1 : n.getTime() >= l.getTime() ? a : a - 1;
331
- }
332
- function mt(t, e) {
333
- const n = Ve(t, e), a = C(t, 0);
334
- return a.setFullYear(n, 0, 4), a.setHours(0, 0, 0, 0), fe(a);
335
- }
336
- function Dt(t, e) {
337
- const n = O(t, e == null ? void 0 : e.in), a = +fe(n) - +mt(n);
338
- return Math.round(a / We) + 1;
339
- }
340
- function Xe(t, e) {
341
- var h, v, y, f;
342
- const n = O(t, e == null ? void 0 : e.in), a = n.getFullYear(), r = ee(), s = (e == null ? void 0 : e.firstWeekContainsDate) ?? ((v = (h = e == null ? void 0 : e.locale) == null ? void 0 : h.options) == null ? void 0 : v.firstWeekContainsDate) ?? r.firstWeekContainsDate ?? ((f = (y = r.locale) == null ? void 0 : y.options) == null ? void 0 : f.firstWeekContainsDate) ?? 1, u = C((e == null ? void 0 : e.in) || t, 0);
343
- u.setFullYear(a + 1, 0, s), u.setHours(0, 0, 0, 0);
344
- const l = $(u, e), D = C((e == null ? void 0 : e.in) || t, 0);
345
- D.setFullYear(a, 0, s), D.setHours(0, 0, 0, 0);
346
- const d = $(D, e);
347
- return +n >= +l ? a + 1 : +n >= +d ? a : a - 1;
348
- }
349
- function yt(t, e) {
350
- var l, D, d, h;
351
- const n = ee(), a = (e == null ? void 0 : e.firstWeekContainsDate) ?? ((D = (l = e == null ? void 0 : e.locale) == null ? void 0 : l.options) == null ? void 0 : D.firstWeekContainsDate) ?? n.firstWeekContainsDate ?? ((h = (d = n.locale) == null ? void 0 : d.options) == null ? void 0 : h.firstWeekContainsDate) ?? 1, r = Xe(t, e), s = C((e == null ? void 0 : e.in) || t, 0);
352
- return s.setFullYear(r, 0, a), s.setHours(0, 0, 0, 0), $(s, e);
353
- }
354
- function vt(t, e) {
355
- const n = O(t, e == null ? void 0 : e.in), a = +$(n, e) - +yt(n, e);
356
- return Math.round(a / We) + 1;
357
- }
358
- function b(t, e) {
359
- const n = t < 0 ? "-" : "", a = Math.abs(t).toString().padStart(e, "0");
360
- return n + a;
361
- }
362
- const q = {
363
- // Year
364
- y(t, e) {
365
- const n = t.getFullYear(), a = n > 0 ? n : 1 - n;
366
- return b(e === "yy" ? a % 100 : a, e.length);
367
- },
368
- // Month
369
- M(t, e) {
370
- const n = t.getMonth();
371
- return e === "M" ? String(n + 1) : b(n + 1, 2);
372
- },
373
- // Day of the month
374
- d(t, e) {
375
- return b(t.getDate(), e.length);
376
- },
377
- // AM or PM
378
- a(t, e) {
379
- const n = t.getHours() / 12 >= 1 ? "pm" : "am";
380
- switch (e) {
381
- case "a":
382
- case "aa":
383
- return n.toUpperCase();
384
- case "aaa":
385
- return n;
386
- case "aaaaa":
387
- return n[0];
388
- default:
389
- return n === "am" ? "a.m." : "p.m.";
390
- }
391
- },
392
- // Hour [1-12]
393
- h(t, e) {
394
- return b(t.getHours() % 12 || 12, e.length);
395
- },
396
- // Hour [0-23]
397
- H(t, e) {
398
- return b(t.getHours(), e.length);
399
- },
400
- // Minute
401
- m(t, e) {
402
- return b(t.getMinutes(), e.length);
403
- },
404
- // Second
405
- s(t, e) {
406
- return b(t.getSeconds(), e.length);
407
- },
408
- // Fraction of second
409
- S(t, e) {
410
- const n = e.length, a = t.getMilliseconds(), r = Math.trunc(
411
- a * Math.pow(10, n - 3)
412
- );
413
- return b(r, e.length);
414
- }
415
- }, Z = {
416
- midnight: "midnight",
417
- noon: "noon",
418
- morning: "morning",
419
- afternoon: "afternoon",
420
- evening: "evening",
421
- night: "night"
422
- }, Ne = {
423
- // Era
424
- G: function(t, e, n) {
425
- const a = t.getFullYear() > 0 ? 1 : 0;
426
- switch (e) {
427
- // AD, BC
428
- case "G":
429
- case "GG":
430
- case "GGG":
431
- return n.era(a, { width: "abbreviated" });
432
- // A, B
433
- case "GGGGG":
434
- return n.era(a, { width: "narrow" });
435
- default:
436
- return n.era(a, { width: "wide" });
437
- }
438
- },
439
- // Year
440
- y: function(t, e, n) {
441
- if (e === "yo") {
442
- const a = t.getFullYear(), r = a > 0 ? a : 1 - a;
443
- return n.ordinalNumber(r, { unit: "year" });
444
- }
445
- return q.y(t, e);
446
- },
447
- // Local week-numbering year
448
- Y: function(t, e, n, a) {
449
- const r = Xe(t, a), s = r > 0 ? r : 1 - r;
450
- if (e === "YY") {
451
- const u = s % 100;
452
- return b(u, 2);
453
- }
454
- return e === "Yo" ? n.ordinalNumber(s, { unit: "year" }) : b(s, e.length);
455
- },
456
- // ISO week-numbering year
457
- R: function(t, e) {
458
- const n = Ve(t);
459
- return b(n, e.length);
460
- },
461
- // Extended year. This is a single number designating the year of this calendar system.
462
- // The main difference between `y` and `u` localizers are B.C. years:
463
- // | Year | `y` | `u` |
464
- // |------|-----|-----|
465
- // | AC 1 | 1 | 1 |
466
- // | BC 1 | 1 | 0 |
467
- // | BC 2 | 2 | -1 |
468
- // Also `yy` always returns the last two digits of a year,
469
- // while `uu` pads single digit years to 2 characters and returns other years unchanged.
470
- u: function(t, e) {
471
- const n = t.getFullYear();
472
- return b(n, e.length);
473
- },
474
- // Quarter
475
- Q: function(t, e, n) {
476
- const a = Math.ceil((t.getMonth() + 1) / 3);
477
- switch (e) {
478
- // 1, 2, 3, 4
479
- case "Q":
480
- return String(a);
481
- // 01, 02, 03, 04
482
- case "QQ":
483
- return b(a, 2);
484
- // 1st, 2nd, 3rd, 4th
485
- case "Qo":
486
- return n.ordinalNumber(a, { unit: "quarter" });
487
- // Q1, Q2, Q3, Q4
488
- case "QQQ":
489
- return n.quarter(a, {
490
- width: "abbreviated",
491
- context: "formatting"
492
- });
493
- // 1, 2, 3, 4 (narrow quarter; could be not numerical)
494
- case "QQQQQ":
495
- return n.quarter(a, {
496
- width: "narrow",
497
- context: "formatting"
498
- });
499
- default:
500
- return n.quarter(a, {
501
- width: "wide",
502
- context: "formatting"
503
- });
504
- }
505
- },
506
- // Stand-alone quarter
507
- q: function(t, e, n) {
508
- const a = Math.ceil((t.getMonth() + 1) / 3);
509
- switch (e) {
510
- // 1, 2, 3, 4
511
- case "q":
512
- return String(a);
513
- // 01, 02, 03, 04
514
- case "qq":
515
- return b(a, 2);
516
- // 1st, 2nd, 3rd, 4th
517
- case "qo":
518
- return n.ordinalNumber(a, { unit: "quarter" });
519
- // Q1, Q2, Q3, Q4
520
- case "qqq":
521
- return n.quarter(a, {
522
- width: "abbreviated",
523
- context: "standalone"
524
- });
525
- // 1, 2, 3, 4 (narrow quarter; could be not numerical)
526
- case "qqqqq":
527
- return n.quarter(a, {
528
- width: "narrow",
529
- context: "standalone"
530
- });
531
- default:
532
- return n.quarter(a, {
533
- width: "wide",
534
- context: "standalone"
535
- });
536
- }
537
- },
538
- // Month
539
- M: function(t, e, n) {
540
- const a = t.getMonth();
541
- switch (e) {
542
- case "M":
543
- case "MM":
544
- return q.M(t, e);
545
- // 1st, 2nd, ..., 12th
546
- case "Mo":
547
- return n.ordinalNumber(a + 1, { unit: "month" });
548
- // Jan, Feb, ..., Dec
549
- case "MMM":
550
- return n.month(a, {
551
- width: "abbreviated",
552
- context: "formatting"
553
- });
554
- // J, F, ..., D
555
- case "MMMMM":
556
- return n.month(a, {
557
- width: "narrow",
558
- context: "formatting"
559
- });
560
- default:
561
- return n.month(a, { width: "wide", context: "formatting" });
562
- }
563
- },
564
- // Stand-alone month
565
- L: function(t, e, n) {
566
- const a = t.getMonth();
567
- switch (e) {
568
- // 1, 2, ..., 12
569
- case "L":
570
- return String(a + 1);
571
- // 01, 02, ..., 12
572
- case "LL":
573
- return b(a + 1, 2);
574
- // 1st, 2nd, ..., 12th
575
- case "Lo":
576
- return n.ordinalNumber(a + 1, { unit: "month" });
577
- // Jan, Feb, ..., Dec
578
- case "LLL":
579
- return n.month(a, {
580
- width: "abbreviated",
581
- context: "standalone"
582
- });
583
- // J, F, ..., D
584
- case "LLLLL":
585
- return n.month(a, {
586
- width: "narrow",
587
- context: "standalone"
588
- });
589
- default:
590
- return n.month(a, { width: "wide", context: "standalone" });
591
- }
592
- },
593
- // Local week of year
594
- w: function(t, e, n, a) {
595
- const r = vt(t, a);
596
- return e === "wo" ? n.ordinalNumber(r, { unit: "week" }) : b(r, e.length);
597
- },
598
- // ISO week of year
599
- I: function(t, e, n) {
600
- const a = Dt(t);
601
- return e === "Io" ? n.ordinalNumber(a, { unit: "week" }) : b(a, e.length);
602
- },
603
- // Day of the month
604
- d: function(t, e, n) {
605
- return e === "do" ? n.ordinalNumber(t.getDate(), { unit: "date" }) : q.d(t, e);
606
- },
607
- // Day of year
608
- D: function(t, e, n) {
609
- const a = ht(t);
610
- return e === "Do" ? n.ordinalNumber(a, { unit: "dayOfYear" }) : b(a, e.length);
611
- },
612
- // Day of week
613
- E: function(t, e, n) {
614
- const a = t.getDay();
615
- switch (e) {
616
- // Tue
617
- case "E":
618
- case "EE":
619
- case "EEE":
620
- return n.day(a, {
621
- width: "abbreviated",
622
- context: "formatting"
623
- });
624
- // T
625
- case "EEEEE":
626
- return n.day(a, {
627
- width: "narrow",
628
- context: "formatting"
629
- });
630
- // Tu
631
- case "EEEEEE":
632
- return n.day(a, {
633
- width: "short",
634
- context: "formatting"
635
- });
636
- default:
637
- return n.day(a, {
638
- width: "wide",
639
- context: "formatting"
640
- });
641
- }
642
- },
643
- // Local day of week
644
- e: function(t, e, n, a) {
645
- const r = t.getDay(), s = (r - a.weekStartsOn + 8) % 7 || 7;
646
- switch (e) {
647
- // Numerical value (Nth day of week with current locale or weekStartsOn)
648
- case "e":
649
- return String(s);
650
- // Padded numerical value
651
- case "ee":
652
- return b(s, 2);
653
- // 1st, 2nd, ..., 7th
654
- case "eo":
655
- return n.ordinalNumber(s, { unit: "day" });
656
- case "eee":
657
- return n.day(r, {
658
- width: "abbreviated",
659
- context: "formatting"
660
- });
661
- // T
662
- case "eeeee":
663
- return n.day(r, {
664
- width: "narrow",
665
- context: "formatting"
666
- });
667
- // Tu
668
- case "eeeeee":
669
- return n.day(r, {
670
- width: "short",
671
- context: "formatting"
672
- });
673
- default:
674
- return n.day(r, {
675
- width: "wide",
676
- context: "formatting"
677
- });
678
- }
679
- },
680
- // Stand-alone local day of week
681
- c: function(t, e, n, a) {
682
- const r = t.getDay(), s = (r - a.weekStartsOn + 8) % 7 || 7;
683
- switch (e) {
684
- // Numerical value (same as in `e`)
685
- case "c":
686
- return String(s);
687
- // Padded numerical value
688
- case "cc":
689
- return b(s, e.length);
690
- // 1st, 2nd, ..., 7th
691
- case "co":
692
- return n.ordinalNumber(s, { unit: "day" });
693
- case "ccc":
694
- return n.day(r, {
695
- width: "abbreviated",
696
- context: "standalone"
697
- });
698
- // T
699
- case "ccccc":
700
- return n.day(r, {
701
- width: "narrow",
702
- context: "standalone"
703
- });
704
- // Tu
705
- case "cccccc":
706
- return n.day(r, {
707
- width: "short",
708
- context: "standalone"
709
- });
710
- default:
711
- return n.day(r, {
712
- width: "wide",
713
- context: "standalone"
714
- });
715
- }
716
- },
717
- // ISO day of week
718
- i: function(t, e, n) {
719
- const a = t.getDay(), r = a === 0 ? 7 : a;
720
- switch (e) {
721
- // 2
722
- case "i":
723
- return String(r);
724
- // 02
725
- case "ii":
726
- return b(r, e.length);
727
- // 2nd
728
- case "io":
729
- return n.ordinalNumber(r, { unit: "day" });
730
- // Tue
731
- case "iii":
732
- return n.day(a, {
733
- width: "abbreviated",
734
- context: "formatting"
735
- });
736
- // T
737
- case "iiiii":
738
- return n.day(a, {
739
- width: "narrow",
740
- context: "formatting"
741
- });
742
- // Tu
743
- case "iiiiii":
744
- return n.day(a, {
745
- width: "short",
746
- context: "formatting"
747
- });
748
- default:
749
- return n.day(a, {
750
- width: "wide",
751
- context: "formatting"
752
- });
753
- }
754
- },
755
- // AM or PM
756
- a: function(t, e, n) {
757
- const r = t.getHours() / 12 >= 1 ? "pm" : "am";
758
- switch (e) {
759
- case "a":
760
- case "aa":
761
- return n.dayPeriod(r, {
762
- width: "abbreviated",
763
- context: "formatting"
764
- });
765
- case "aaa":
766
- return n.dayPeriod(r, {
767
- width: "abbreviated",
768
- context: "formatting"
769
- }).toLowerCase();
770
- case "aaaaa":
771
- return n.dayPeriod(r, {
772
- width: "narrow",
773
- context: "formatting"
774
- });
775
- default:
776
- return n.dayPeriod(r, {
777
- width: "wide",
778
- context: "formatting"
779
- });
780
- }
781
- },
782
- // AM, PM, midnight, noon
783
- b: function(t, e, n) {
784
- const a = t.getHours();
785
- let r;
786
- switch (a === 12 ? r = Z.noon : a === 0 ? r = Z.midnight : r = a / 12 >= 1 ? "pm" : "am", e) {
787
- case "b":
788
- case "bb":
789
- return n.dayPeriod(r, {
790
- width: "abbreviated",
791
- context: "formatting"
792
- });
793
- case "bbb":
794
- return n.dayPeriod(r, {
795
- width: "abbreviated",
796
- context: "formatting"
797
- }).toLowerCase();
798
- case "bbbbb":
799
- return n.dayPeriod(r, {
800
- width: "narrow",
801
- context: "formatting"
802
- });
803
- default:
804
- return n.dayPeriod(r, {
805
- width: "wide",
806
- context: "formatting"
807
- });
808
- }
809
- },
810
- // in the morning, in the afternoon, in the evening, at night
811
- B: function(t, e, n) {
812
- const a = t.getHours();
813
- let r;
814
- switch (a >= 17 ? r = Z.evening : a >= 12 ? r = Z.afternoon : a >= 4 ? r = Z.morning : r = Z.night, e) {
815
- case "B":
816
- case "BB":
817
- case "BBB":
818
- return n.dayPeriod(r, {
819
- width: "abbreviated",
820
- context: "formatting"
821
- });
822
- case "BBBBB":
823
- return n.dayPeriod(r, {
824
- width: "narrow",
825
- context: "formatting"
826
- });
827
- default:
828
- return n.dayPeriod(r, {
829
- width: "wide",
830
- context: "formatting"
831
- });
832
- }
833
- },
834
- // Hour [1-12]
835
- h: function(t, e, n) {
836
- if (e === "ho") {
837
- let a = t.getHours() % 12;
838
- return a === 0 && (a = 12), n.ordinalNumber(a, { unit: "hour" });
839
- }
840
- return q.h(t, e);
841
- },
842
- // Hour [0-23]
843
- H: function(t, e, n) {
844
- return e === "Ho" ? n.ordinalNumber(t.getHours(), { unit: "hour" }) : q.H(t, e);
845
- },
846
- // Hour [0-11]
847
- K: function(t, e, n) {
848
- const a = t.getHours() % 12;
849
- return e === "Ko" ? n.ordinalNumber(a, { unit: "hour" }) : b(a, e.length);
850
- },
851
- // Hour [1-24]
852
- k: function(t, e, n) {
853
- let a = t.getHours();
854
- return a === 0 && (a = 24), e === "ko" ? n.ordinalNumber(a, { unit: "hour" }) : b(a, e.length);
855
- },
856
- // Minute
857
- m: function(t, e, n) {
858
- return e === "mo" ? n.ordinalNumber(t.getMinutes(), { unit: "minute" }) : q.m(t, e);
859
- },
860
- // Second
861
- s: function(t, e, n) {
862
- return e === "so" ? n.ordinalNumber(t.getSeconds(), { unit: "second" }) : q.s(t, e);
863
- },
864
- // Fraction of second
865
- S: function(t, e) {
866
- return q.S(t, e);
867
- },
868
- // Timezone (ISO-8601. If offset is 0, output is always `'Z'`)
869
- X: function(t, e, n) {
870
- const a = t.getTimezoneOffset();
871
- if (a === 0)
872
- return "Z";
873
- switch (e) {
874
- // Hours and optional minutes
875
- case "X":
876
- return Te(a);
877
- // Hours, minutes and optional seconds without `:` delimiter
878
- // Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
879
- // so this token always has the same output as `XX`
880
- case "XXXX":
881
- case "XX":
882
- return Q(a);
883
- // Hours and minutes with `:` delimiter
884
- default:
885
- return Q(a, ":");
886
- }
887
- },
888
- // Timezone (ISO-8601. If offset is 0, output is `'+00:00'` or equivalent)
889
- x: function(t, e, n) {
890
- const a = t.getTimezoneOffset();
891
- switch (e) {
892
- // Hours and optional minutes
893
- case "x":
894
- return Te(a);
895
- // Hours, minutes and optional seconds without `:` delimiter
896
- // Note: neither ISO-8601 nor JavaScript supports seconds in timezone offsets
897
- // so this token always has the same output as `xx`
898
- case "xxxx":
899
- case "xx":
900
- return Q(a);
901
- // Hours and minutes with `:` delimiter
902
- default:
903
- return Q(a, ":");
904
- }
905
- },
906
- // Timezone (GMT)
907
- O: function(t, e, n) {
908
- const a = t.getTimezoneOffset();
909
- switch (e) {
910
- // Short
911
- case "O":
912
- case "OO":
913
- case "OOO":
914
- return "GMT" + Se(a, ":");
915
- default:
916
- return "GMT" + Q(a, ":");
917
- }
918
- },
919
- // Timezone (specific non-location)
920
- z: function(t, e, n) {
921
- const a = t.getTimezoneOffset();
922
- switch (e) {
923
- // Short
924
- case "z":
925
- case "zz":
926
- case "zzz":
927
- return "GMT" + Se(a, ":");
928
- default:
929
- return "GMT" + Q(a, ":");
930
- }
931
- },
932
- // Seconds timestamp
933
- t: function(t, e, n) {
934
- const a = Math.trunc(+t / 1e3);
935
- return b(a, e.length);
936
- },
937
- // Milliseconds timestamp
938
- T: function(t, e, n) {
939
- return b(+t, e.length);
940
- }
941
- };
942
- function Se(t, e = "") {
943
- const n = t > 0 ? "-" : "+", a = Math.abs(t), r = Math.trunc(a / 60), s = a % 60;
944
- return s === 0 ? n + String(r) : n + String(r) + e + b(s, 2);
945
- }
946
- function Te(t, e) {
947
- return t % 60 === 0 ? (t > 0 ? "-" : "+") + b(Math.abs(t) / 60, 2) : Q(t, e);
948
- }
949
- function Q(t, e = "") {
950
- const n = t > 0 ? "-" : "+", a = Math.abs(t), r = b(Math.trunc(a / 60), 2), s = b(a % 60, 2);
951
- return n + r + e + s;
952
- }
953
- const Ie = (t, e) => {
954
- switch (t) {
955
- case "P":
956
- return e.date({ width: "short" });
957
- case "PP":
958
- return e.date({ width: "medium" });
959
- case "PPP":
960
- return e.date({ width: "long" });
961
- default:
962
- return e.date({ width: "full" });
963
- }
964
- }, Ke = (t, e) => {
965
- switch (t) {
966
- case "p":
967
- return e.time({ width: "short" });
968
- case "pp":
969
- return e.time({ width: "medium" });
970
- case "ppp":
971
- return e.time({ width: "long" });
972
- default:
973
- return e.time({ width: "full" });
974
- }
975
- }, gt = (t, e) => {
976
- const n = t.match(/(P+)(p+)?/) || [], a = n[1], r = n[2];
977
- if (!r)
978
- return Ie(t, e);
979
- let s;
980
- switch (a) {
981
- case "P":
982
- s = e.dateTime({ width: "short" });
983
- break;
984
- case "PP":
985
- s = e.dateTime({ width: "medium" });
986
- break;
987
- case "PPP":
988
- s = e.dateTime({ width: "long" });
989
- break;
990
- default:
991
- s = e.dateTime({ width: "full" });
992
- break;
993
- }
994
- return s.replace("{{date}}", Ie(a, e)).replace("{{time}}", Ke(r, e));
995
- }, wt = {
996
- p: Ke,
997
- P: gt
998
- }, _t = /^D+$/, bt = /^Y+$/, Ot = ["D", "DD", "YY", "YYYY"];
999
- function kt(t) {
1000
- return _t.test(t);
1001
- }
1002
- function Mt(t) {
1003
- return bt.test(t);
1004
- }
1005
- function Et(t, e, n) {
1006
- const a = Nt(t, e, n);
1007
- if (console.warn(a), Ot.includes(t)) throw new RangeError(a);
1008
- }
1009
- function Nt(t, e, n) {
1010
- const a = t[0] === "Y" ? "years" : "days of the month";
1011
- return `Use \`${t.toLowerCase()}\` instead of \`${t}\` (in \`${e}\`) for formatting ${a} to the input \`${n}\`; see: https://github.com/date-fns/date-fns/blob/master/docs/unicodeTokens.md`;
1012
- }
1013
- function St(t) {
1014
- return t instanceof Date || typeof t == "object" && Object.prototype.toString.call(t) === "[object Date]";
1015
- }
1016
- function Tt(t) {
1017
- return !(!St(t) && typeof t != "number" || isNaN(+O(t)));
1018
- }
1019
- const It = /[yYQqMLwIdDecihHKkms]o|(\w)\1*|''|'(''|[^'])+('|$)|./g, xt = /P+p+|P+|p+|''|'(''|[^'])+('|$)|./g, Yt = /^'([^]*?)'?$/, Pt = /''/g, Lt = /[a-zA-Z]/;
1020
- function xe(t, e, n) {
1021
- var h, v, y, f, o, c, w, E;
1022
- const a = ee(), r = (n == null ? void 0 : n.locale) ?? a.locale ?? nt, s = (n == null ? void 0 : n.firstWeekContainsDate) ?? ((v = (h = n == null ? void 0 : n.locale) == null ? void 0 : h.options) == null ? void 0 : v.firstWeekContainsDate) ?? a.firstWeekContainsDate ?? ((f = (y = a.locale) == null ? void 0 : y.options) == null ? void 0 : f.firstWeekContainsDate) ?? 1, u = (n == null ? void 0 : n.weekStartsOn) ?? ((c = (o = n == null ? void 0 : n.locale) == null ? void 0 : o.options) == null ? void 0 : c.weekStartsOn) ?? a.weekStartsOn ?? ((E = (w = a.locale) == null ? void 0 : w.options) == null ? void 0 : E.weekStartsOn) ?? 0, l = O(t, n == null ? void 0 : n.in);
1023
- if (!Tt(l))
1024
- throw new RangeError("Invalid time value");
1025
- let D = e.match(xt).map((m) => {
1026
- const g = m[0];
1027
- if (g === "p" || g === "P") {
1028
- const S = wt[g];
1029
- return S(m, r.formatLong);
1030
- }
1031
- return m;
1032
- }).join("").match(It).map((m) => {
1033
- if (m === "''")
1034
- return { isToken: !1, value: "'" };
1035
- const g = m[0];
1036
- if (g === "'")
1037
- return { isToken: !1, value: Ct(m) };
1038
- if (Ne[g])
1039
- return { isToken: !0, value: m };
1040
- if (g.match(Lt))
1041
- throw new RangeError(
1042
- "Format string contains an unescaped latin alphabet character `" + g + "`"
1043
- );
1044
- return { isToken: !1, value: m };
1045
- });
1046
- r.localize.preprocessor && (D = r.localize.preprocessor(l, D));
1047
- const d = {
1048
- firstWeekContainsDate: s,
1049
- weekStartsOn: u,
1050
- locale: r
1051
- };
1052
- return D.map((m) => {
1053
- if (!m.isToken) return m.value;
1054
- const g = m.value;
1055
- (!(n != null && n.useAdditionalWeekYearTokens) && Mt(g) || !(n != null && n.useAdditionalDayOfYearTokens) && kt(g)) && Et(g, e, String(t));
1056
- const S = Ne[g[0]];
1057
- return S(l, g, r.localize, d);
1058
- }).join("");
1059
- }
1060
- function Ct(t) {
1061
- const e = t.match(Yt);
1062
- return e ? e[1].replace(Pt, "'") : t;
1063
- }
1064
- function ce(t, e, n) {
1065
- const [a, r] = me(
1066
- n == null ? void 0 : n.in,
1067
- t,
1068
- e
1069
- );
1070
- return +J(a) == +J(r);
1071
- }
1072
- function he(t, e, n) {
1073
- const a = +O(t, n == null ? void 0 : n.in), [r, s] = [
1074
- +O(e.start, n == null ? void 0 : n.in),
1075
- +O(e.end, n == null ? void 0 : n.in)
1076
- ].sort((u, l) => u - l);
1077
- return a >= r && a <= s;
1078
- }
1079
- const Rt = {
1080
- "en-US": {
1081
- nextMonth: "Next month",
1082
- previousMonth: "Previous month"
1083
- }
1084
- }, Ft = ue({
1085
- i18n: { messages: Rt },
1086
- name: "calendar-month",
1087
- components: {
1088
- BentoButton: Re,
1089
- BentoTypography: Fe,
1090
- CalendarMonthDay: ct,
1091
- ChevronLeftIcon: He,
1092
- ChevronRightIcon: Ge
1093
- },
1094
- directives: { BentoKeyboardNavigationDirective: Ue },
1095
- props: {
1096
- /**
1097
- * end of the selected range
1098
- */
1099
- endDate: { type: Date, default: null },
1100
- /**
1101
- * Allows you to set the first day of the week. 0 is sunday, 1 is monday, 6 is saturday
1102
- */
1103
- firstDayOfWeek: {
1104
- type: Number,
1105
- default: X.MONDAY,
1106
- validator: (t) => Object.values(X).includes(t)
1107
- },
1108
- /**
1109
- * Indicate if a date should be disabled or not
1110
- */
1111
- isDateDisabled: { type: Function, default: void 0 },
1112
- /**
1113
- * Indicates if the calendar is part of a range date picker or a sigle date picker
1114
- */
1115
- isRange: { type: Boolean, default: !1 },
1116
- /**
1117
- * Sets a minimum limit for selectable dates - dates before `min` will not be selectable
1118
- */
1119
- min: { type: Date, default: null },
1120
- /**
1121
- * Sets a maximum limit for selectable dates - dates after `max` will not be selectable
1122
- */
1123
- max: { type: Date, default: null },
1124
- /**
1125
- * Month of the year to be displayed in the calendar
1126
- */
1127
- month: { type: Date, required: !0 },
1128
- /**
1129
- * When rendering multiple calendars, this property allows to render the
1130
- * Next and Previous calendar buttons to the right, left or not at all
1131
- * depending on the position: Unique (only 1), First, Middle or Last
1132
- */
1133
- position: {
1134
- type: String,
1135
- default: "unique",
1136
- validator: (t) => Object.values(z).includes(t)
1137
- },
1138
- /**
1139
- * start of the selected range
1140
- */
1141
- startDate: { type: Date, default: null }
1142
- // can be undefined, eslint complains without default
1143
- },
1144
- emits: [
1145
- R.CHANGE_DAY,
1146
- R.INPUT,
1147
- R.NEXT_MONTH,
1148
- R.PREVIOUS_MONTH,
1149
- R.MOUSE_OVER
1150
- ],
1151
- setup(t, { emit: e }) {
1152
- const { locale: n, t: a } = Ae(), r = pe(), s = Be("bento-date-picker-month-label"), u = N(
1153
- () => (M) => {
1154
- var A;
1155
- return t.min && M < t.min || t.max && M > t.max || ((A = t.isDateDisabled) == null ? void 0 : A.call(t, M));
1156
- }
1157
- ), {
1158
- internalDate: l,
1159
- baseDate: D,
1160
- // Calendar refs
1161
- addDayRef: d,
1162
- // Month navigation
1163
- showNextMonth: h,
1164
- showPreviousMonth: v,
1165
- // Day navigation
1166
- moveToNextDay: y,
1167
- moveToPreviousDay: f,
1168
- moveToPreviousWeek: o,
1169
- moveToNextWeek: c,
1170
- moveToFirstDayOfWeek: w,
1171
- moveToLastDayOfWeek: E,
1172
- moveToPreviousMonth: m,
1173
- moveToPreviousYear: g,
1174
- moveToNextMonth: S,
1175
- moveToNextYear: L,
1176
- focusOnDate: Y
1177
- } = je(
1178
- {
1179
- currentSelectedDate: B(t, "startDate"),
1180
- month: B(t, "month"),
1181
- isDateDisabled: u.value,
1182
- firstDayOfWeek: t.firstDayOfWeek
1183
- },
1184
- e
1185
- ), _ = N(
1186
- () => Object.values(X).includes(t.firstDayOfWeek) ? t.firstDayOfWeek : X.MONDAY
1187
- ), P = N(() => ["first", "unique"].includes(t.position)), T = N(() => ["last", "unique"].includes(t.position)), I = N(
1188
- () => {
1189
- var M;
1190
- return xe(D.value, "MMMM yyyy", {
1191
- locale: r[(M = n.value) == null ? void 0 : M.substring(0, 2)] || r.enUS
1192
- });
1193
- }
1194
- ), te = N(
1195
- () => new Array(7).fill(/* @__PURE__ */ new Date()).map((M, A) => {
1196
- var ke;
1197
- const ne = ft(M, _.value + A);
1198
- return xe(ne, "EEE", {
1199
- locale: r[(ke = n.value) == null ? void 0 : ke.substring(0, 2)] || r.enUS
1200
- });
1201
- })
1202
- ), Oe = N(() => {
1203
- const M = [], A = de(t.month);
1204
- let ne = M[M.push([]) - 1];
1205
- for (; A.getMonth() === t.month.getMonth(); )
1206
- A.getDay() - _.value === 0 && ne.length > 0 && (ne = M[M.push([]) - 1]), ne.push(J(A)), A.setDate(A.getDate() + 1);
1207
- return M;
1208
- });
1209
- return {
1210
- // Refs
1211
- addDayRef: d,
1212
- // Values
1213
- computedIsDateDisabled: u,
1214
- daysOfWeek: te,
1215
- weeksOfMonth: Oe,
1216
- formattedMonthDate: I,
1217
- shouldShowNextMonthButton: T,
1218
- shouldShowPreviousMonthButton: P,
1219
- monthLabelId: s,
1220
- // Enums
1221
- CalendarMonthEvent: R,
1222
- // Functions
1223
- isSelectedDate: (M) => l.value && ce(l.value, M) && !t.endDate ? !0 : t.startDate && t.endDate && he(M, { start: t.startDate, end: t.endDate }),
1224
- showNextMonth: h,
1225
- showPreviousMonth: v,
1226
- dayVariant: (M) => {
1227
- if (!t.isRange || ce(t.startDate, t.endDate))
1228
- return F.SINGLE;
1229
- if (t.startDate && ce(t.startDate, M))
1230
- return F.BEGINNING;
1231
- if (t.endDate && ce(t.endDate, M))
1232
- return F.END;
1233
- if (t.startDate && t.endDate && he(M, { start: t.startDate, end: t.endDate }))
1234
- return F.MIDDLE;
1235
- },
1236
- confirmNavigationDate: () => {
1237
- e(R.INPUT, l);
1238
- },
1239
- // Events
1240
- onDayClicked: (M) => {
1241
- e(R.INPUT, M);
1242
- },
1243
- listeners: {
1244
- "keydown:arrow-right": y,
1245
- "keydown:arrow-left": f,
1246
- "keydown:arrow-up": o,
1247
- "keydown:arrow-down": c,
1248
- "keydown:home": w,
1249
- "keydown:end": E,
1250
- "keydown:page-up": m,
1251
- "keydown:shift-page-up": g,
1252
- "keydown:page-down": S,
1253
- "keydown:shift-page-down": L
1254
- },
1255
- // Exposed methods
1256
- focusOnDate: Y,
1257
- moveToNextDay: y,
1258
- moveToPreviousDay: f,
1259
- moveToPreviousWeek: o,
1260
- moveToNextWeek: c,
1261
- moveToFirstDayOfWeek: w,
1262
- moveToLastDayOfWeek: E,
1263
- moveToPreviousMonth: m,
1264
- moveToPreviousYear: g,
1265
- moveToNextMonth: S,
1266
- moveToNextYear: L,
1267
- // Translations
1268
- t: a
1269
- };
1270
- }
1271
- });
1272
- var At = function() {
1273
- var a, r;
1274
- var e = this, n = e._self._c;
1275
- return e._self._setupProxy, n("div", e._g({ directives: [{ name: "bento-keyboard-navigation-directive", rawName: "v-bento-keyboard-navigation-directive" }], staticClass: "b-calendar-month" }, e.listeners), [n("div", { staticClass: "b-calendar-month__month-selector" }, [n("div", { staticClass: "b-calendar-month__previous" }, [e.shouldShowPreviousMonthButton ? n("bento-button", { attrs: { variant: "tertiary" }, on: { click: function(s) {
1276
- return e.moveToPreviousMonth(s, !0);
1277
- } }, scopedSlots: e._u([{ key: "iconLeft", fn: function() {
1278
- return [n("chevron-left-icon", { attrs: { "svg-title": e.t("previousMonth") } })];
1279
- }, proxy: !0 }], null, !1, 1806090420) }) : e._e()], 1), n("bento-typography", { attrs: { id: e.monthLabelId, el: "h2", variant: "title", "aria-live": "polite" } }, [e._v(" " + e._s(e.formattedMonthDate) + " ")]), n("div", { staticClass: "b-calendar-month__next" }, [e.shouldShowNextMonthButton ? n("bento-button", { attrs: { variant: "tertiary" }, on: { click: function(s) {
1280
- return e.moveToNextMonth(s, !0);
1281
- } }, scopedSlots: e._u([{ key: "iconLeft", fn: function() {
1282
- return [n("chevron-right-icon", { attrs: { "svg-title": e.t("nextMonth") } })];
1283
- }, proxy: !0 }], null, !1, 1041540377) }) : e._e()], 1)], 1), n("table", { staticClass: "b-calendar-month__month-container", attrs: { role: "grid", "aria-labelledby": e.monthLabelId } }, [n("thead", [n("tr", { staticClass: "b-calendar-month__week-header" }, e._l(e.daysOfWeek, function(s, u) {
1284
- return n("th", { key: u, staticClass: "b-calendar-month__day-of-week", attrs: { scope: "col" } }, [n("bento-typography", { staticClass: "b-calendar-month__day-of-week-font", attrs: { el: "span", variant: "caption" } }, [e._v(" " + e._s(s) + " ")])], 1);
1285
- }), 0)]), n("tbody", [e._l(e.weeksOfMonth, function(s, u) {
1286
- return n("tr", { key: u }, [u === 0 && s.length < 7 ? n("td", { attrs: { colspan: 7 - s.length } }) : e._e(), e._l(s, function(l, D) {
1287
- return n("calendar-month-day", { key: `calendar-day-${D}`, ref: e.addDayRef(l), refInFor: !0, attrs: { day: l, disabled: e.computedIsDateDisabled(l), selected: e.isSelectedDate(l), variant: e.dayVariant(l) }, on: { click: e.onDayClicked, mouseover: function(d) {
1288
- return e.$emit(e.CalendarMonthEvent.MOUSE_OVER, l);
1289
- } }, nativeOn: { keyup: [function(d) {
1290
- return !d.type.indexOf("key") && e._k(d.keyCode, "up", 38, d.key, ["Up", "ArrowUp"]) ? null : e.$emit(e.CalendarMonthEvent.CHANGE_DAY, l);
1291
- }, function(d) {
1292
- return !d.type.indexOf("key") && e._k(d.keyCode, "down", 40, d.key, ["Down", "ArrowDown"]) ? null : e.$emit(e.CalendarMonthEvent.CHANGE_DAY, l);
1293
- }, function(d) {
1294
- return !d.type.indexOf("key") && e._k(d.keyCode, "left", 37, d.key, ["Left", "ArrowLeft"]) || "button" in d && d.button !== 0 ? null : e.$emit(e.CalendarMonthEvent.CHANGE_DAY, l);
1295
- }, function(d) {
1296
- return !d.type.indexOf("key") && e._k(d.keyCode, "right", 39, d.key, ["Right", "ArrowRight"]) || "button" in d && d.button !== 2 ? null : e.$emit(e.CalendarMonthEvent.CHANGE_DAY, l);
1297
- }] } });
1298
- })], 2);
1299
- }), ((a = e.weeksOfMonth) == null ? void 0 : a.length) < 6 ? e._l(6 - ((r = e.weeksOfMonth) == null ? void 0 : r.length), function(s) {
1300
- return n("tr", { key: `calendar month filler row ${s}` }, [n("td", { staticClass: "b-calendar-month__empty-cell-filler", attrs: { "aria-hidden": "true", colspan: 7 } })]);
1301
- }) : e._e()], 2)])]);
1302
- }, Bt = [], Wt = /* @__PURE__ */ oe(
1303
- Ft,
1304
- At,
1305
- Bt,
1306
- !1,
1307
- null,
1308
- "0ea8064e"
1309
- );
1310
- const Ye = Wt.exports;
1311
- function ie(t, e, n) {
1312
- const [a, r] = me(
1313
- n == null ? void 0 : n.in,
1314
- t,
1315
- e
1316
- );
1317
- return a.getFullYear() === r.getFullYear() && a.getMonth() === r.getMonth();
1318
- }
1319
- var W = /* @__PURE__ */ ((t) => (t.SINGLE = "single", t.MIDDLE = "middle", t.BEGINNING = "beginning", t.END = "end", t))(W || {}), U = /* @__PURE__ */ ((t) => (t.SINGLE = "single", t.MIDDLE = "middle", t.BEGINNING = "beginning", t.END = "end", t.SELECTED = "selected", t.UNSELECTED = "unselected", t.CURRENT_MONTH = "current-month", t.DISABLED = "disabled", t))(U || {}), be = /* @__PURE__ */ ((t) => (t.CLICK = "click", t.MOUSE_OVER = "mouseover", t))(be || {});
1320
- const Gt = {}, Ht = /* @__PURE__ */ ue({
1321
- ...Gt,
1322
- __name: "calendar-year-month",
1323
- props: {
1324
- month: null,
1325
- disabled: { type: Boolean, default: !1 },
1326
- selected: { type: Boolean, default: !1 },
1327
- variant: { default: W.SINGLE }
1328
- },
1329
- emits: ["click", "mouseover"],
1330
- setup(t, { emit: e }) {
1331
- const n = t, a = N(() => {
1332
- const u = /* @__PURE__ */ new Date();
1333
- return n.month.getMonth() === u.getMonth() && n.month.getFullYear() === u.getFullYear();
1334
- }), r = N(() => ({
1335
- // Variants
1336
- [`b-calendar-year-month--${U.BEGINNING}`]: n.variant === W.BEGINNING,
1337
- [`b-calendar-year-month--${U.MIDDLE}`]: n.variant === W.MIDDLE,
1338
- [`b-calendar-year-month--${U.END}`]: n.variant === W.END,
1339
- [`b-calendar-year-month--${U.SINGLE}`]: n.variant === W.SINGLE,
1340
- // Selected
1341
- [`b-calendar-year-month--${U.UNSELECTED}`]: !n.selected,
1342
- [`b-calendar-year-month--${U.SELECTED}`]: n.selected,
1343
- // Current month
1344
- [`b-calendar-year-month--${U.CURRENT_MONTH}`]: a.value,
1345
- // Disabled
1346
- [`b-calendar-year-month--${U.DISABLED}`]: n.disabled
1347
- }));
1348
- return { __sfc: !0, props: n, emit: e, isCurrentMonth: a, conditionalClasses: r, onClick: (u, l) => {
1349
- n.disabled ? (u.preventDefault(), u.stopPropagation()) : e(be.CLICK, l, n.month);
1350
- }, BentoDate: $e, BentoDateFormat: qe, CalendarYearMonthEvent: be };
1351
- }
1352
- });
1353
- var Ut = function() {
1354
- var e = this, n = e._self._c, a = e._self._setupProxy;
1355
- return n("td", { staticClass: "b-calendar-year-month", class: a.conditionalClasses, attrs: { tabindex: e.selected ? "0" : "-1", "aria-selected": e.selected ? e.selected : void 0 }, on: { click: (r) => a.onClick(r, e.month), mouseover: function(r) {
1356
- return a.emit(a.CalendarYearMonthEvent.MOUSE_OVER);
1357
- }, keydown: function(r) {
1358
- return !r.type.indexOf("key") && e._k(r.keyCode, "space", 32, r.key, [" ", "Spacebar"]) && e._k(r.keyCode, "enter", 13, r.key, "Enter") ? null : ((s) => a.onClick(s, e.month)).apply(null, arguments);
1359
- } } }, [n("div", { staticClass: "b-calendar-year-month__wrapper" }, [n(a.BentoDate, { staticClass: "b-calendar-year-month__label", attrs: { date: e.month, format: a.BentoDateFormat.SHORT_MONTH } })], 1)]);
1360
- }, $t = [], qt = /* @__PURE__ */ oe(
1361
- Ht,
1362
- Ut,
1363
- $t,
1364
- !1,
1365
- null,
1366
- "14764460"
1367
- );
1368
- const jt = qt.exports, Qt = {
1369
- "en-US": {
1370
- nextYear: "Next year",
1371
- previousYear: "Previous year"
1372
- },
1373
- "ja-JP": {
1374
- nextYear: "来年",
1375
- previousYear: "前年"
1376
- },
1377
- "pt-BR": {
1378
- nextYear: "Ano seguinte",
1379
- previousYear: "Ano anterior"
1380
- }
1381
- }, Vt = {
1382
- i18n: { messages: Qt }
1383
- }, Xt = /* @__PURE__ */ ue({
1384
- ...Vt,
1385
- __name: "calendar-year",
1386
- props: {
1387
- endDate: { default: null },
1388
- isDateDisabled: { type: Function, default: void 0 },
1389
- isRange: { type: Boolean, default: !1 },
1390
- min: { default: null },
1391
- max: { default: null },
1392
- position: { default: "unique" },
1393
- startDate: { default: null },
1394
- year: null
1395
- },
1396
- emits: ["input", "mouseover", "nextMonth", "previousMonth"],
1397
- setup(t, { expose: e, emit: n }) {
1398
- const a = t, r = Be("bento-date-picker-year-label"), { t: s } = Ae(), u = (_) => {
1399
- var P;
1400
- return a.min && _ < a.min || a.max && _ > a.max || ((P = a.isDateDisabled) == null ? void 0 : P.call(a, _));
1401
- }, l = N(() => ["first", "unique"].includes(a.position)), D = N(() => ["last", "unique"].includes(a.position)), {
1402
- internalDate: d,
1403
- // Calendar refs
1404
- addDayRef: h,
1405
- // Day navigation
1406
- moveToPreviousMonth: v,
1407
- moveToPreviousYear: y,
1408
- moveToNextMonth: f,
1409
- moveToNextYear: o,
1410
- moveToFirstMonthOfYear: c,
1411
- moveToLastMonthOfYear: w,
1412
- focusOnDate: E
1413
- } = je(
1414
- {
1415
- currentSelectedDate: B(a, "startDate"),
1416
- month: B(a, "year"),
1417
- isDateDisabled: u
1418
- },
1419
- n
1420
- );
1421
- e({ focusOnDate: E });
1422
- const m = N(() => {
1423
- const _ = [];
1424
- let P = 0;
1425
- for (let T = 0; T < 3; T++) {
1426
- const I = [];
1427
- for (let te = 0; te < 4; te++)
1428
- I.push(new Date(a.year.getFullYear(), P++, 1));
1429
- _.push(I);
1430
- }
1431
- return _;
1432
- }), g = (_) => !a.isRange || ie(a.startDate, a.endDate) ? W.SINGLE : a.startDate && ie(a.startDate, _) ? W.BEGINNING : a.endDate && ie(a.endDate, _) ? W.END : a.startDate && a.endDate && he(_, { start: a.startDate, end: a.endDate }) ? W.MIDDLE : null, S = (_) => d.value && ie(d.value, _) ? !0 : a.startDate && a.endDate && he(_, { start: a.startDate, end: a.endDate }), L = (_) => {
1433
- n("input", _);
1434
- }, Y = a.isRange ? {} : {
1435
- "keydown:arrow-right": f,
1436
- "keydown:arrow-left": v,
1437
- "keydown:arrow-up": (_) => v(_, !1, 4),
1438
- "keydown:arrow-down": (_) => f(_, !1, 4),
1439
- "keydown:home": c,
1440
- "keydown:end": w,
1441
- "keydown:page-up": y,
1442
- "keydown:page-down": o
1443
- };
1444
- return { __sfc: !0, yearLabelId: r, props: a, emit: n, t: s, isDateDisabled: u, shouldShowPreviousYearButton: l, shouldShowNextYearButton: D, internalDate: d, addDayRef: h, moveToPreviousMonth: v, moveToPreviousYear: y, moveToNextMonth: f, moveToNextYear: o, moveToFirstMonthOfYear: c, moveToLastMonthOfYear: w, focusOnDate: E, monthRows: m, monthVariant: g, isSelectedDate: S, onMonthClicked: L, listeners: Y, BentoButton: Re, BentoTypography: Fe, CalendarYearMonth: jt, ChevronLeftIcon: He, ChevronRightIcon: Ge, vBentoKeyboardNavigationDirective: Ue };
1445
- }
1446
- });
1447
- var Kt = function() {
1448
- var e = this, n = e._self._c, a = e._self._setupProxy;
1449
- return n("div", e._g({ directives: [{ name: "bento-keyboard-navigation-directive", rawName: "v-bento-keyboard-navigation-directive" }], staticClass: "b-calendar-year" }, a.listeners), [n("div", { staticClass: "b-calendar-year__year-selector" }, [n("div", { staticClass: "b-calendar-year__previous" }, [a.shouldShowPreviousYearButton ? n(a.BentoButton, { attrs: { variant: "tertiary" }, on: { click: function(r) {
1450
- return a.moveToPreviousYear(r, !0);
1451
- } }, scopedSlots: e._u([{ key: "iconLeft", fn: function() {
1452
- return [n(a.ChevronLeftIcon, { attrs: { "svg-title": a.t("previousYear") } })];
1453
- }, proxy: !0 }], null, !1, 3347270443) }) : e._e()], 1), n(a.BentoTypography, { attrs: { id: a.yearLabelId, el: "h2", variant: "title", "aria-live": "polite" } }, [e._v(" " + e._s(e.year.getFullYear()) + " ")]), n("div", { staticClass: "b-calendar-year__next" }, [a.shouldShowNextYearButton ? n(a.BentoButton, { attrs: { variant: "tertiary" }, on: { click: function(r) {
1454
- return a.moveToNextYear(r, !0);
1455
- } }, scopedSlots: e._u([{ key: "iconLeft", fn: function() {
1456
- return [n(a.ChevronRightIcon, { attrs: { "svg-title": a.t("nextYear") } })];
1457
- }, proxy: !0 }], null, !1, 3324005926) }) : e._e()], 1)], 1), n("table", { staticClass: "b-calendar-year__year-container", attrs: { role: "grid", "aria-labelledby": a.yearLabelId } }, [n("tbody", e._l(a.monthRows, function(r, s) {
1458
- return n("tr", { key: s }, e._l(r, function(u, l) {
1459
- return n(a.CalendarYearMonth, { key: `calendar-month-${l}`, ref: a.addDayRef(u), refInFor: !0, attrs: { month: u, disabled: a.isDateDisabled(u), selected: a.isSelectedDate(u), variant: a.monthVariant(u) }, on: { click: a.onMonthClicked, mouseover: function(D) {
1460
- return a.emit("mouseover", u);
1461
- } } });
1462
- }), 1);
1463
- }), 0)])]);
1464
- }, Jt = [], Zt = /* @__PURE__ */ oe(
1465
- Xt,
1466
- Kt,
1467
- Jt,
1468
- !1,
1469
- null,
1470
- "4ac72508"
1471
- );
1472
- const Pe = Zt.exports, zt = ({ selectedDate: t }, e) => {
1473
- const n = Ce({
1474
- startDate: null,
1475
- endDate: null
1476
- });
1477
- return p(
1478
- () => t.value,
1479
- () => {
1480
- n.startDate = t.value, n.endDate = void 0;
1481
- },
1482
- { immediate: !0 }
1483
- ), {
1484
- internalValue: n,
1485
- onDateInput: (r) => {
1486
- e(j.INPUT, r);
1487
- },
1488
- // Empty function to prevent the listeners from throwing a warning
1489
- // eslint-disable-next-line @typescript-eslint/no-empty-function
1490
- onMouseOver: () => {
1491
- }
1492
- };
1493
- };
1494
- function pt(t, e) {
1495
- return +O(t) < +O(e);
1496
- }
1497
- function en(t, e) {
1498
- return +O(t) > +O(e);
1499
- }
1500
- function tn(t, e, n) {
1501
- const [a, r] = me(
1502
- n == null ? void 0 : n.in,
1503
- t,
1504
- e
1505
- ), s = Le(a, r), u = Math.abs(
1506
- Qe(a, r)
1507
- );
1508
- a.setDate(a.getDate() - s * u);
1509
- const l = +(Le(a, r) === -s), D = s * (u - l);
1510
- return D === 0 ? 0 : D;
1511
- }
1512
- function Le(t, e) {
1513
- const n = t.getFullYear() - e.getFullYear() || t.getMonth() - e.getMonth() || t.getDate() - e.getDate() || t.getHours() - e.getHours() || t.getMinutes() - e.getMinutes() || t.getSeconds() - e.getSeconds() || t.getMilliseconds() - e.getMilliseconds();
1514
- return n < 0 ? -1 : n > 0 ? 1 : n;
1515
- }
1516
- function ye(t, e) {
1517
- const n = O(t, e == null ? void 0 : e.in), a = n.getMonth(), r = a - a % 3 + 3;
1518
- return n.setMonth(r, 0), n.setHours(23, 59, 59, 999), n;
1519
- }
1520
- function ve(t, e) {
1521
- const n = O(t, e == null ? void 0 : e.in), a = n.getMonth(), r = a - a % 3;
1522
- return n.setMonth(r, 1), n.setHours(0, 0, 0, 0), n;
1523
- }
1524
- const nn = (t) => {
1525
- const e = (h, v, y, f) => {
1526
- let o = $(h, { weekStartsOn: t }), c = le(v || h, { weekStartsOn: t });
1527
- const w = y && o < y, E = f && c > f;
1528
- return w && (o = $(y, { weekStartsOn: t })), E && (c = le(f, { weekStartsOn: t })), o > c && (w ? c = le(o, { weekStartsOn: t }) : o = $(c, { weekStartsOn: t })), { startDate: o, endDate: c };
1529
- }, n = (h, v, y, f) => {
1530
- let o = de(h), c = De(v || h);
1531
- const w = y && o < y, E = f && c > f;
1532
- return w && (o = de(y)), E && (c = De(f)), o > c && (w ? c = De(o) : o = de(c)), { startDate: o, endDate: c };
1533
- }, a = (h, v, y, f) => {
1534
- let o = ve(h), c = ye(v || h);
1535
- const w = y instanceof Date && o < y, E = f instanceof Date && c > f;
1536
- return w && (o = ve(y)), E && (c = ye(f)), o > c && (w ? c = ye(o) : o = ve(c)), { startDate: o, endDate: c };
1537
- };
1538
- return {
1539
- adjustDateForWeekly: e,
1540
- adjustDateForMonthly: n,
1541
- adjustDateForQuarterly: a,
1542
- adjustStartDateInputForWeekly: (h, v, y, f) => {
1543
- const { startDate: o } = e(new Date(h), null, y, f);
1544
- return v(o);
1545
- },
1546
- adjustEndDateInputForWeekly: (h, v, y, f) => {
1547
- const { endDate: o } = e(new Date(h), null, y, f);
1548
- return v(o);
1549
- },
1550
- adjustStartDateInputForMonthly: (h, v, y, f) => {
1551
- const { startDate: o } = n(new Date(h), null, y, f);
1552
- return v(o);
1553
- },
1554
- adjustEndDateInputForMonthly: (h, v, y, f) => {
1555
- const { endDate: o } = n(new Date(h), null, y, f);
1556
- return v(o);
1557
- },
1558
- adjustStartDateInputForQuarterly: (h, v, y, f) => {
1559
- const { startDate: o } = a(new Date(h), null, y, f);
1560
- return v(o);
1561
- },
1562
- adjustEndDateInputForQuarterly: (h, v, y, f) => {
1563
- const { endDate: o } = a(new Date(h), null, y, f);
1564
- return v(o);
1565
- }
1566
- };
1567
- }, an = ({ selectedDate: t, isDateDisabled: e, maxRange: n, granularity: a, firstDayOfWeek: r, min: s, max: u }, l) => {
1568
- const { adjustDateForWeekly: h, adjustDateForMonthly: v, adjustDateForQuarterly: y } = nn(r), f = Ce({
1569
- startDate: null,
1570
- endDate: null
1571
- }), o = V(null);
1572
- p(
1573
- () => t.value,
1574
- () => {
1575
- let { startDate: m = null, endDate: g = null } = t.value || {};
1576
- m && (m = J(m)), g && (g = J(g)), !(m && e && e(m) || g && e && e(g) || m && g && en(m, g)) && (f.startDate = m, f.endDate = g);
1577
- },
1578
- { immediate: !0, deep: !0 }
1579
- );
1580
- const c = (m, g, S) => {
1581
- if (f.startDate = m, f.endDate = g, n.value) {
1582
- const L = tn(g, m) - n.value;
1583
- L > 0 && (S < 1 ? (f.startDate = m, f.endDate = _e(g, L)) : (f.startDate = se(m, L), f.endDate = g));
1584
- }
1585
- l(j.START_DATE_SELECTED, f.startDate), l(j.END_DATE_SELECTED, f.endDate);
1586
- }, w = (m) => {
1587
- var g, S, L, Y, _, P;
1588
- if (!(!o.value || e && e(m)))
1589
- if (pt(m, o.value)) {
1590
- if (((g = a == null ? void 0 : a.value) == null ? void 0 : g.type) === "weekly") {
1591
- const { startDate: T, endDate: I } = h(m, o.value, s.value, u.value);
1592
- c(T, I, -1);
1593
- return;
1594
- }
1595
- if (((S = a == null ? void 0 : a.value) == null ? void 0 : S.type) === "monthly") {
1596
- const { startDate: T, endDate: I } = v(m, o.value, s.value, u.value);
1597
- c(T, I, -1);
1598
- return;
1599
- }
1600
- if (((L = a == null ? void 0 : a.value) == null ? void 0 : L.type) === "quarterly") {
1601
- const { startDate: T, endDate: I } = y(m, o.value, s.value, u.value);
1602
- c(T, I, -1);
1603
- return;
1604
- }
1605
- c(m, o.value, -1);
1606
- } else {
1607
- if (((Y = a == null ? void 0 : a.value) == null ? void 0 : Y.type) === "weekly") {
1608
- const { startDate: T, endDate: I } = h(o.value, m, s.value, u.value);
1609
- c(T, I, 1);
1610
- return;
1611
- }
1612
- if (((_ = a == null ? void 0 : a.value) == null ? void 0 : _.type) === "monthly") {
1613
- const { startDate: T, endDate: I } = v(o.value, m, s.value, u.value);
1614
- c(T, I, 1);
1615
- return;
1616
- }
1617
- if (((P = a == null ? void 0 : a.value) == null ? void 0 : P.type) === "quarterly") {
1618
- const { startDate: T, endDate: I } = y(o.value, m, s.value, u.value);
1619
- c(T, I, 1);
1620
- return;
1621
- }
1622
- c(o.value, m, 1);
1623
- }
1624
- };
1625
- return {
1626
- internalValue: f,
1627
- onDateInput: (m) => {
1628
- var g, S, L;
1629
- if (o.value)
1630
- o.value = null, l(j.INPUT, f);
1631
- else {
1632
- let Y = m;
1633
- if (((g = a == null ? void 0 : a.value) == null ? void 0 : g.type) === "weekly") {
1634
- const { startDate: _, endDate: P } = h(m);
1635
- Y = _, c(Y, P);
1636
- }
1637
- if (((S = a == null ? void 0 : a.value) == null ? void 0 : S.type) === "monthly") {
1638
- const { startDate: _, endDate: P } = v(m);
1639
- Y = _, c(Y, P);
1640
- }
1641
- if (((L = a == null ? void 0 : a.value) == null ? void 0 : L.type) === "quarterly") {
1642
- const { startDate: _, endDate: P } = y(m);
1643
- Y = _, c(Y, P);
1644
- }
1645
- o.value = Y, w(Y);
1646
- }
1647
- },
1648
- onMouseOver: w
1649
- };
1650
- };
1651
- function Je(t, e, n) {
1652
- return K(t, e * 12, n);
1653
- }
1654
- function rn(t, e, n) {
1655
- return Je(t, -e, n);
1656
- }
1657
- const sn = ue({
1658
- name: "calendar",
1659
- components: { CalendarMonth: Ye, CalendarYear: Pe },
1660
- props: {
1661
- /**
1662
- * Allows you to set the first day of the week. 0 is sunday, 1 is monday, 6 is saturday
1663
- */
1664
- firstDayOfWeek: {
1665
- type: Number,
1666
- default: X.MONDAY,
1667
- validator: (t) => Object.values(X).includes(t)
1668
- },
1669
- /**
1670
- * The selected granularity configuration
1671
- */
1672
- granularity: {
1673
- type: Object,
1674
- default: null
1675
- },
1676
- /**
1677
- * Indicate if a date should be disabled or not
1678
- */
1679
- isDateDisabled: { type: Function, default: void 0 },
1680
- /**
1681
- * Enables the Date Range calendar
1682
- */
1683
- isRange: { type: Boolean, default: !1 },
1684
- /**
1685
- * Set a maximum number of dates to be selectable by the range.
1686
- */
1687
- maxRange: { type: Number, default: null, validator: (t) => !t || t > 0 },
1688
- /**
1689
- * Sets a minimum limit for selectable dates - dates before `min` will not be selectable
1690
- */
1691
- min: { type: Date, default: null },
1692
- /**
1693
- * Sets a maximum limit for selectable dates - dates after `max` will not be selectable
1694
- */
1695
- max: { type: Date, default: null },
1696
- /**
1697
- * Number of months rendered on pane
1698
- */
1699
- numberOfMonths: {
1700
- type: Number,
1701
- default: 3,
1702
- validator: (t) => t >= 1
1703
- },
1704
- /**
1705
- * Upon opening date range picker, end date's month will be pre-selected.
1706
- */
1707
- showEndDateOnOpen: { type: Boolean, default: !1 },
1708
- /**
1709
- * Selected date. Can be a single Date or a CalendarRangeDate
1710
- * instance that contains startDate and endDate attributes.
1711
- */
1712
- value: { type: [Date, Object], default: void 0 },
1713
- /**
1714
- * Default start date for the calendar pane
1715
- */
1716
- defaultDisplayMonth: {
1717
- type: String,
1718
- default: null,
1719
- validator: (t) => /^\d{4}-(0?[1-9]|1[012])(-(0?[1-9]|[12][0-9]|3[01]))?$/.test(t)
1720
- },
1721
- /**
1722
- * The type of calendar to display. Defaults to showing days.
1723
- */
1724
- variant: {
1725
- type: String,
1726
- default: "day",
1727
- validator: (t) => Object.values(ge).includes(t)
1728
- }
1729
- },
1730
- emit: [j.INPUT, j.START_DATE_SELECTED, j.END_DATE_SELECTED],
1731
- setup(t, { emit: e }) {
1732
- const n = V(null), a = V();
1733
- p(
1734
- () => t.value,
1735
- () => {
1736
- var o, c, w;
1737
- if (t.isRange)
1738
- a.value = t != null && t.showEndDateOnOpen && ((o = t.value) != null && o.endDate) ? (c = t.value) == null ? void 0 : c.endDate : ((w = t.value) == null ? void 0 : w.startDate) || /* @__PURE__ */ new Date();
1739
- else {
1740
- const E = t.defaultDisplayMonth && new Date(t.defaultDisplayMonth).getTime() ? new Date(t.defaultDisplayMonth) : /* @__PURE__ */ new Date();
1741
- a.value = t.value || E;
1742
- }
1743
- },
1744
- { immediate: !0, deep: !0 }
1745
- );
1746
- const r = N(
1747
- () => t.variant === ge.MONTH ? Pe : Ye
1748
- ), s = N(() => ({
1749
- "b-calendar__range": t.isRange
1750
- })), { internalValue: u, onDateInput: l, onMouseOver: D } = t.isRange ? an(
1751
- {
1752
- selectedDate: B(t, "value"),
1753
- isDateDisabled: t.isDateDisabled,
1754
- maxRange: B(t, "maxRange"),
1755
- granularity: B(t, "granularity"),
1756
- firstDayOfWeek: t.firstDayOfWeek,
1757
- min: B(t, "min"),
1758
- max: B(t, "max")
1759
- },
1760
- e
1761
- ) : zt(
1762
- {
1763
- selectedDate: B(t, "value"),
1764
- firstDayOfWeek: t.firstDayOfWeek
1765
- },
1766
- e
1767
- ), d = (o) => t.numberOfMonths === 1 ? z.UNIQUE : o === 0 ? z.FIRST : o === t.numberOfMonths - 1 ? z.LAST : z.MIDDLE, h = N(() => (o) => {
1768
- const c = t != null && t.showEndDateOnOpen && t.isRange ? re(a.value, t.numberOfMonths - 1) : a.value;
1769
- return K(c, o);
1770
- }), v = N(() => (o) => {
1771
- const c = t != null && t.showEndDateOnOpen ? rn(a.value, t.numberOfMonths - 1) : a.value;
1772
- return Je(c, o);
1773
- });
1774
- return {
1775
- // Refs
1776
- calendarRef: n,
1777
- // Values
1778
- baseDate: a,
1779
- calendarComponent: r,
1780
- conditionalClasses: s,
1781
- internalValue: u,
1782
- // Methods
1783
- calculateOffsetMonth: h,
1784
- calculateOffsetYear: v,
1785
- calendarPosition: d,
1786
- // Events
1787
- onDateInput: l,
1788
- onMouseOver: D,
1789
- calculateNextMonths: (o = 1) => {
1790
- a.value = K(a.value, o);
1791
- },
1792
- calculatePreviousMonths: (o = 1) => {
1793
- a.value = re(a.value, o);
1794
- }
1795
- };
1796
- }
1797
- });
1798
- var un = function() {
1799
- var e = this, n = e._self._c;
1800
- return e._self._setupProxy, n("div", { staticClass: "b-calendar", class: e.conditionalClasses }, e._l(e.numberOfMonths, function(a, r) {
1801
- return n(e.calendarComponent, { key: `calendar-${r}`, ref: e.numberOfMonths === 1 ? "calendarRef" : null, refInFor: !0, tag: "component", attrs: { "first-day-of-week": e.firstDayOfWeek, "is-date-disabled": e.isDateDisabled, month: e.calculateOffsetMonth(r), year: e.calculateOffsetYear(r), position: e.calendarPosition(r), min: e.min, max: e.max, "is-range": e.isRange, "start-date": e.internalValue.startDate, "end-date": e.internalValue.endDate, granularity: e.granularity }, on: { input: e.onDateInput, mouseover: e.onMouseOver, changeDay: e.onMouseOver, nextMonth: e.calculateNextMonths, previousMonth: e.calculatePreviousMonths } });
1802
- }), 1);
1803
- }, on = [], cn = /* @__PURE__ */ oe(
1804
- sn,
1805
- un,
1806
- on,
1807
- !1,
1808
- null,
1809
- "7b26a1ab"
1810
- );
1811
- const On = cn.exports;
1812
- export {
1813
- X as C,
1814
- ge as a,
1815
- On as b,
1816
- j as c,
1817
- z as d,
1818
- J as e,
1819
- xe as f,
1820
- K as g,
1821
- $ as h,
1822
- ce as i,
1823
- se as j,
1824
- le as k,
1825
- _e as l,
1826
- re as m,
1827
- ve as n,
1828
- ye as o,
1829
- de as s,
1830
- nn as u
1831
- };
1832
- //# sourceMappingURL=calendar.DCLyThOl.js.map