@adyen/bento-vue2 1.26.0 → 1.28.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.
- package/dist/@types/components.d.ts +8 -0
- package/dist/@types/index.d.ts +967 -374
- package/dist/accordion.js +3 -101
- package/dist/accordion.js.map +1 -1
- package/dist/action-bar.js +2 -231
- package/dist/action-bar.js.map +1 -1
- package/dist/alert.js +5 -116
- package/dist/alert.js.map +1 -1
- package/dist/assets/{index2.css → accordion-item.css} +1 -1
- package/dist/assets/{index3.css → action-bar.css} +1 -1
- package/dist/assets/alert.css +1 -0
- package/dist/assets/base-modal.css +1 -1
- package/dist/assets/button-actions.css +1 -1
- package/dist/assets/button.css +1 -1
- package/dist/assets/{index7.css → card.css} +1 -1
- package/dist/assets/checkbox-input.css +1 -1
- package/dist/assets/{index9.css → code-snippet.css} +1 -1
- package/dist/assets/dashboard-section.css +1 -0
- package/dist/assets/dashed-underline.css +1 -0
- package/dist/assets/data-grid-template.css +1 -0
- package/dist/assets/data-grid.css +1 -0
- package/dist/assets/dialog-page.css +1 -1
- package/dist/assets/dropdown-default-textbox.css +1 -1
- package/dist/assets/dropdown.css +1 -1
- package/dist/assets/filter-bar.css +1 -0
- package/dist/assets/{index15.css → form-layout-title.css} +1 -1
- package/dist/assets/{index25.css → input-field.css} +1 -1
- package/dist/assets/listbox-option-tag.css +1 -1
- package/dist/assets/{index26.css → menu.css} +1 -1
- package/dist/assets/{index22.css → modal-fullscreen.css} +1 -1
- package/dist/assets/{index28.css → popover.css} +1 -1
- package/dist/assets/radio-input.css +1 -1
- package/dist/assets/segmented-control.css +1 -0
- package/dist/assets/selection-card-group.css +1 -0
- package/dist/assets/{index37.css → sidepanel.css} +1 -1
- package/dist/assets/status.css +1 -0
- package/dist/assets/structured-list-item.css +1 -0
- package/dist/assets/{index43.css → tabs.css} +1 -1
- package/dist/assets/toggle.css +1 -0
- package/dist/assets/tutorial.css +1 -0
- package/dist/assets/use-cached-selected-values.css +1 -1
- package/dist/avatar-image.js +1 -1
- package/dist/badge.js +22 -24
- package/dist/badge.js.map +1 -1
- package/dist/button.js +14 -94
- package/dist/button.js.map +1 -1
- package/dist/card.js +4 -114
- package/dist/card.js.map +1 -1
- package/dist/checkbox.js +8 -155
- package/dist/checkbox.js.map +1 -1
- package/dist/chunks/1-generic-use.CZhwP2Yc.js +5 -0
- package/dist/chunks/1-generic-use.CZhwP2Yc.js.map +1 -0
- package/dist/chunks/1-generic-use.R6x8PEGA.js +5 -0
- package/dist/chunks/1-generic-use.R6x8PEGA.js.map +1 -0
- package/dist/chunks/2-generic-use.CNKjB4B7.js +5 -0
- package/dist/chunks/2-generic-use.CNKjB4B7.js.map +1 -0
- package/dist/chunks/2-generic-use.w0fUhovx.js +5 -0
- package/dist/chunks/2-generic-use.w0fUhovx.js.map +1 -0
- package/dist/chunks/3-generic-use.BLEzR04g.js +5 -0
- package/dist/chunks/3-generic-use.BLEzR04g.js.map +1 -0
- package/dist/chunks/3-generic-use.D3NFHgI4.js +5 -0
- package/dist/chunks/3-generic-use.D3NFHgI4.js.map +1 -0
- package/dist/chunks/4-generic-use.CULEpvgj.js +5 -0
- package/dist/chunks/4-generic-use.CULEpvgj.js.map +1 -0
- package/dist/chunks/4-generic-use.D82y3n39.js +5 -0
- package/dist/chunks/4-generic-use.D82y3n39.js.map +1 -0
- package/dist/chunks/_plugin-vue2_normalizer.CeySl7Fu.js +11 -0
- package/dist/chunks/_plugin-vue2_normalizer.CeySl7Fu.js.map +1 -0
- package/dist/chunks/accordion-item.DmnrjNzw.js +100 -0
- package/dist/chunks/accordion-item.DmnrjNzw.js.map +1 -0
- package/dist/chunks/action-bar.Bebh6PHI.js +147 -0
- package/dist/chunks/action-bar.Bebh6PHI.js.map +1 -0
- package/dist/chunks/adding-payment-methods.BJZLPxtM.js +5 -0
- package/dist/chunks/adding-payment-methods.BJZLPxtM.js.map +1 -0
- package/dist/chunks/adding-payment-methods.Dle8zt43.js +5 -0
- package/dist/chunks/adding-payment-methods.Dle8zt43.js.map +1 -0
- package/dist/chunks/adyen-giving.Ffw_DlJK.js +5 -0
- package/dist/chunks/adyen-giving.Ffw_DlJK.js.map +1 -0
- package/dist/chunks/adyen-giving.LiKHj_jY.js +5 -0
- package/dist/chunks/adyen-giving.LiKHj_jY.js.map +1 -0
- package/dist/chunks/alert.CJyTM4Az.js +96 -0
- package/dist/chunks/alert.CJyTM4Az.js.map +1 -0
- package/dist/chunks/{aria-label.ac9651a5.js → aria-label.CaUURpnB.js} +1 -1
- package/dist/chunks/{aria-label.ac9651a5.js.map → aria-label.CaUURpnB.js.map} +1 -1
- package/dist/chunks/{index.7eefc59c.js → avatar-image.DhlR-7Yg.js} +22 -24
- package/dist/chunks/avatar-image.DhlR-7Yg.js.map +1 -0
- package/dist/chunks/base-button.DER7_IsF.js +86 -0
- package/dist/chunks/{base-button.ad74b6f8.js.map → base-button.DER7_IsF.js.map} +1 -1
- package/dist/chunks/{base-modal.1fff7abe.js → base-modal.C5I7bR0d.js} +42 -46
- package/dist/chunks/{base-modal.1fff7abe.js.map → base-modal.C5I7bR0d.js.map} +1 -1
- package/dist/chunks/{base-modal.keys.b08a6bdf.js → base-modal.keys.C2PQXcE2.js} +1 -1
- package/dist/chunks/{base-modal.keys.b08a6bdf.js.map → base-modal.keys.C2PQXcE2.js.map} +1 -1
- package/dist/chunks/{button-actions-with-menu.e845d77a.js → button-actions-with-menu.f3yuLK-L.js} +25 -27
- package/dist/chunks/{button-actions-with-menu.e845d77a.js.map → button-actions-with-menu.f3yuLK-L.js.map} +1 -1
- package/dist/chunks/button-actions.Bg9ey0p6.js +111 -0
- package/dist/chunks/button-actions.Bg9ey0p6.js.map +1 -0
- package/dist/chunks/button.DhAUh5JA.js +99 -0
- package/dist/chunks/button.DhAUh5JA.js.map +1 -0
- package/dist/chunks/{calendar.640b8d25.js → calendar.B69z8gjb.js} +287 -332
- package/dist/chunks/{calendar.640b8d25.js.map → calendar.B69z8gjb.js.map} +1 -1
- package/dist/chunks/card.70Xvba2C.js +115 -0
- package/dist/chunks/card.70Xvba2C.js.map +1 -0
- package/dist/chunks/checkbox-group.B-KdeRXC.js +152 -0
- package/dist/chunks/checkbox-group.B-KdeRXC.js.map +1 -0
- package/dist/chunks/{checkbox-input.1c3cc8ed.js → checkbox-input.DwDwI2BD.js} +27 -30
- package/dist/chunks/{checkbox-input.1c3cc8ed.js.map → checkbox-input.DwDwI2BD.js.map} +1 -1
- package/dist/chunks/{checkbox.bfed007c.js → checkbox.Bi2RDBEZ.js} +21 -23
- package/dist/chunks/{checkbox.bfed007c.js.map → checkbox.Bi2RDBEZ.js.map} +1 -1
- package/dist/chunks/checkmark-circle-fill.DVl6QSwm.js +24 -0
- package/dist/chunks/{checkmark-circle-fill.345311d2.js.map → checkmark-circle-fill.DVl6QSwm.js.map} +1 -1
- package/dist/chunks/{checkmark-small.520f01b1.js → checkmark-small.BtF8b2gE.js} +6 -8
- package/dist/chunks/{checkmark-small.520f01b1.js.map → checkmark-small.BtF8b2gE.js.map} +1 -1
- package/dist/chunks/{chevron-left.5edf02ac.js → chevron-left.CtnrsqUy.js} +13 -17
- package/dist/chunks/{chevron-left.5edf02ac.js.map → chevron-left.CtnrsqUy.js.map} +1 -1
- package/dist/chunks/{chevron-up.81185563.js → chevron-up.B2uWhZf7.js} +14 -18
- package/dist/chunks/{chevron-up.81185563.js.map → chevron-up.B2uWhZf7.js.map} +1 -1
- package/dist/chunks/click-outside.DABh6NLr.js +23 -0
- package/dist/chunks/click-outside.DABh6NLr.js.map +1 -0
- package/dist/chunks/code-snippet.C4IbjAhH.js +968 -0
- package/dist/chunks/code-snippet.C4IbjAhH.js.map +1 -0
- package/dist/chunks/{controls-group.4fb50009.js → controls-group.cSRFiEVO.js} +17 -19
- package/dist/chunks/{controls-group.4fb50009.js.map → controls-group.cSRFiEVO.js.map} +1 -1
- package/dist/chunks/{copy.f85700c6.js → copy.BtFWFG3q.js} +15 -19
- package/dist/chunks/{copy.f85700c6.js.map → copy.BtFWFG3q.js.map} +1 -1
- package/dist/chunks/country.KayLT0zy.js +93 -0
- package/dist/chunks/country.KayLT0zy.js.map +1 -0
- package/dist/chunks/{country.types.002caff2.js → country.types.Br0AjxGy.js} +5 -5
- package/dist/chunks/{country.types.002caff2.js.map → country.types.Br0AjxGy.js.map} +1 -1
- package/dist/chunks/{cross-circle-fill.27580c4b.js → cross-circle-fill.CnYH4R_h.js} +7 -9
- package/dist/chunks/{cross-circle-fill.27580c4b.js.map → cross-circle-fill.CnYH4R_h.js.map} +1 -1
- package/dist/chunks/{cross-small.e851e0de.js → cross-small.BLUwtRB-.js} +9 -11
- package/dist/chunks/{cross-small.e851e0de.js.map → cross-small.BLUwtRB-.js.map} +1 -1
- package/dist/chunks/{cross.04678d81.js → cross.CsUPDmaA.js} +9 -11
- package/dist/chunks/{cross.04678d81.js.map → cross.CsUPDmaA.js.map} +1 -1
- package/dist/chunks/currency.H7n7RQiX.js +113 -0
- package/dist/chunks/currency.H7n7RQiX.js.map +1 -0
- package/dist/chunks/dashboard-section.BcH-_en7.js +105 -0
- package/dist/chunks/dashboard-section.BcH-_en7.js.map +1 -0
- package/dist/chunks/dashed-underline.ChUlcFJR.js +59 -0
- package/dist/chunks/dashed-underline.ChUlcFJR.js.map +1 -0
- package/dist/chunks/data-grid-template.DqG5bNeD.js +66 -0
- package/dist/chunks/data-grid-template.DqG5bNeD.js.map +1 -0
- package/dist/chunks/{data-grid-template.keys.a819a991.js → data-grid-template.keys.2_AkxuNT.js} +1 -1
- package/dist/chunks/{data-grid-template.keys.a819a991.js.map → data-grid-template.keys.2_AkxuNT.js.map} +1 -1
- package/dist/chunks/data-grid.CvHAdmvs.js +2022 -0
- package/dist/chunks/data-grid.CvHAdmvs.js.map +1 -0
- package/dist/chunks/{date-input.9186a0bf.js → date-input.BqBdAO1E.js} +1 -1
- package/dist/chunks/{date-input.9186a0bf.js.map → date-input.BqBdAO1E.js.map} +1 -1
- package/dist/chunks/date-picker.ByP2Wpo0.js +196 -0
- package/dist/chunks/date-picker.ByP2Wpo0.js.map +1 -0
- package/dist/chunks/{index.8b8c3b16.js → date-range-picker.DrnklTJ-.js} +113 -117
- package/dist/chunks/date-range-picker.DrnklTJ-.js.map +1 -0
- package/dist/chunks/{index.b21197ca.js → date.DKjxxR6P.js} +44 -51
- package/dist/chunks/date.DKjxxR6P.js.map +1 -0
- package/dist/chunks/{debounce.b5ef6acf.js → debounce.DUTu11PS.js} +1 -1
- package/dist/chunks/{debounce.b5ef6acf.js.map → debounce.DUTu11PS.js.map} +1 -1
- package/dist/chunks/{dialog-page.73da22cf.js → dialog-page.DAh0M4mT.js} +20 -24
- package/dist/chunks/{dialog-page.73da22cf.js.map → dialog-page.DAh0M4mT.js.map} +1 -1
- package/dist/chunks/divider.BZfeYmB9.js +30 -0
- package/dist/chunks/divider.BZfeYmB9.js.map +1 -0
- package/dist/chunks/{dropdown-default-textbox.54ca1b18.js → dropdown-default-textbox.CKOkl_Qa.js} +30 -34
- package/dist/chunks/{dropdown-default-textbox.54ca1b18.js.map → dropdown-default-textbox.CKOkl_Qa.js.map} +1 -1
- package/dist/chunks/dropdown-tag.DCMKQy-E.js +214 -0
- package/dist/chunks/dropdown-tag.DCMKQy-E.js.map +1 -0
- package/dist/chunks/{dropdown.10c034aa.js → dropdown.yhhQCKve.js} +195 -214
- package/dist/chunks/dropdown.yhhQCKve.js.map +1 -0
- package/dist/chunks/empty-state.BqVOj4v1.js +151 -0
- package/dist/chunks/empty-state.BqVOj4v1.js.map +1 -0
- package/dist/chunks/error-message.BSxUoE3_.js +107 -0
- package/dist/chunks/{error-message.31ec12b7.js.map → error-message.BSxUoE3_.js.map} +1 -1
- package/dist/chunks/events.CMzGybJJ.js +47 -0
- package/dist/chunks/events.CMzGybJJ.js.map +1 -0
- package/dist/chunks/filter-bar.AhsOPMZ1.js +2119 -0
- package/dist/chunks/filter-bar.AhsOPMZ1.js.map +1 -0
- package/dist/chunks/{fixed-scroller.4eb9a9ac.js → fixed-scroller.Bq1AgPnw.js} +18 -20
- package/dist/chunks/{fixed-scroller.4eb9a9ac.js.map → fixed-scroller.Bq1AgPnw.js.map} +1 -1
- package/dist/chunks/{index.d553d3d1.js → focus-trap.DSkLNO_i.js} +35 -37
- package/dist/chunks/focus-trap.DSkLNO_i.js.map +1 -0
- package/dist/chunks/{footer-actions.a1e09b4f.js → footer-actions.DqMRmlV_.js} +11 -13
- package/dist/chunks/{footer-actions.a1e09b4f.js.map → footer-actions.DqMRmlV_.js.map} +1 -1
- package/dist/chunks/form-layout-title.BzNU0B72.js +187 -0
- package/dist/chunks/form-layout-title.BzNU0B72.js.map +1 -0
- package/dist/chunks/{form-layout.types.a7a1438d.js → form-layout.types.D3EKzbE7.js} +1 -1
- package/dist/chunks/{form-layout.types.a7a1438d.js.map → form-layout.types.D3EKzbE7.js.map} +1 -1
- package/dist/chunks/{get-slot-text.99c3d860.js → get-slot-text.Cgn-E48s.js} +2 -2
- package/dist/chunks/{get-slot-text.99c3d860.js.map → get-slot-text.Cgn-E48s.js.map} +1 -1
- package/dist/chunks/{grid-layout.e0025286.js → grid-layout.HvTAa4to.js} +11 -13
- package/dist/chunks/{grid-layout.e0025286.js.map → grid-layout.HvTAa4to.js.map} +1 -1
- package/dist/chunks/header.DmKHCmXh.js +245 -0
- package/dist/chunks/header.DmKHCmXh.js.map +1 -0
- package/dist/chunks/{i18n.eb5b985b.js → i18n.BQkEbtPM.js} +2 -2
- package/dist/chunks/{i18n.eb5b985b.js.map → i18n.BQkEbtPM.js.map} +1 -1
- package/dist/chunks/image.B3uqhFjl.js +82 -0
- package/dist/chunks/image.B3uqhFjl.js.map +1 -0
- package/dist/chunks/{index.fdf12170.js → index.B_EJflcs.js} +2 -2
- package/dist/chunks/{index.fdf12170.js.map → index.B_EJflcs.js.map} +1 -1
- package/dist/chunks/{index.f55fdc32.js → index.B_UZQ6qF.js} +209 -243
- package/dist/chunks/{index.f55fdc32.js.map → index.B_UZQ6qF.js.map} +1 -1
- package/dist/chunks/{index.4c062058.js → index.Cl4_42j5.js} +1 -1
- package/dist/chunks/{index.4c062058.js.map → index.Cl4_42j5.js.map} +1 -1
- package/dist/chunks/index.OCPp3NST.js +126 -0
- package/dist/chunks/index.OCPp3NST.js.map +1 -0
- package/dist/chunks/{index.d80206ed.js → index.Z84QE0E2.js} +2 -2
- package/dist/chunks/{index.d80206ed.js.map → index.Z84QE0E2.js.map} +1 -1
- package/dist/chunks/{index.86453263.js → index.xqFSZOAb.js} +2 -2
- package/dist/chunks/{index.86453263.js.map → index.xqFSZOAb.js.map} +1 -1
- package/dist/chunks/info-icon.CLguYHRt.js +41 -0
- package/dist/chunks/info-icon.CLguYHRt.js.map +1 -0
- package/dist/chunks/{info.8b6328aa.js → info.CyeBsLgt.js} +9 -11
- package/dist/chunks/{info.8b6328aa.js.map → info.CyeBsLgt.js.map} +1 -1
- package/dist/chunks/input-field.BnlEPPYr.js +218 -0
- package/dist/chunks/input-field.BnlEPPYr.js.map +1 -0
- package/dist/chunks/internal-error.BLZodVBE.js +5 -0
- package/dist/chunks/internal-error.BLZodVBE.js.map +1 -0
- package/dist/chunks/internal-error.BmrwJFpR.js +5 -0
- package/dist/chunks/internal-error.BmrwJFpR.js.map +1 -0
- package/dist/chunks/{keyboard-navigation.ca47dfa8.js → keyboard-navigation.Clz1jOaA.js} +2 -2
- package/dist/chunks/{keyboard-navigation.ca47dfa8.js.map → keyboard-navigation.Clz1jOaA.js.map} +1 -1
- package/dist/chunks/{index.317fca12.js → link.DJ1A53gF.js} +20 -24
- package/dist/chunks/link.DJ1A53gF.js.map +1 -0
- package/dist/chunks/listbox-option-tag.BDjsYOE1.js +75 -0
- package/dist/chunks/listbox-option-tag.BDjsYOE1.js.map +1 -0
- package/dist/chunks/{loading-button.eafc9e1b.js → loading-button.CoF1IhEU.js} +32 -34
- package/dist/chunks/{loading-button.eafc9e1b.js.map → loading-button.CoF1IhEU.js.map} +1 -1
- package/dist/chunks/loading-indicator.DXc7I1Lm.js +48 -0
- package/dist/chunks/loading-indicator.DXc7I1Lm.js.map +1 -0
- package/dist/chunks/{index.1ea85d4a.js → menu.2TwUMlA9.js} +82 -94
- package/dist/chunks/menu.2TwUMlA9.js.map +1 -0
- package/dist/chunks/modal-fullscreen.BB_8EMNo.js +196 -0
- package/dist/chunks/modal-fullscreen.BB_8EMNo.js.map +1 -0
- package/dist/chunks/{modal-fullscreen.keys.b9f31632.js → modal-fullscreen.keys.CMba3hYp.js} +1 -1
- package/dist/chunks/{modal-fullscreen.keys.b9f31632.js.map → modal-fullscreen.keys.CMba3hYp.js.map} +1 -1
- package/dist/chunks/modal.DLwvcaRx.js +439 -0
- package/dist/chunks/modal.DLwvcaRx.js.map +1 -0
- package/dist/chunks/no-results-found.Bg_ZcEid.js +5 -0
- package/dist/chunks/no-results-found.Bg_ZcEid.js.map +1 -0
- package/dist/chunks/no-results-found.BqvYsBR6.js +5 -0
- package/dist/chunks/no-results-found.BqvYsBR6.js.map +1 -0
- package/dist/chunks/notifications-cleared.BMZk37uf.js +5 -0
- package/dist/chunks/notifications-cleared.BMZk37uf.js.map +1 -0
- package/dist/chunks/notifications-cleared.C7W9ZXY7.js +5 -0
- package/dist/chunks/notifications-cleared.C7W9ZXY7.js.map +1 -0
- package/dist/chunks/{on-click-outside.3e0c3e2a.js → on-click-outside.CcNG5w7_.js} +1 -1
- package/dist/chunks/{on-click-outside.3e0c3e2a.js.map → on-click-outside.CcNG5w7_.js.map} +1 -1
- package/dist/chunks/page-not-found.COJLPVaU.js +5 -0
- package/dist/chunks/page-not-found.COJLPVaU.js.map +1 -0
- package/dist/chunks/page-not-found.DWW6W-PZ.js +5 -0
- package/dist/chunks/page-not-found.DWW6W-PZ.js.map +1 -0
- package/dist/chunks/pagination.BXjbVe4Z.js +494 -0
- package/dist/chunks/pagination.BXjbVe4Z.js.map +1 -0
- package/dist/chunks/{payment-method.6c1ce07c.js → payment-method.D9Qx-s4V.js} +19 -21
- package/dist/chunks/{payment-method.6c1ce07c.js.map → payment-method.D9Qx-s4V.js.map} +1 -1
- package/dist/chunks/payment-method.types.CJKfZQN5.js +5 -0
- package/dist/chunks/payment-method.types.CJKfZQN5.js.map +1 -0
- package/dist/chunks/planned-maintenance.C61sWB9h.js +5 -0
- package/dist/chunks/planned-maintenance.C61sWB9h.js.map +1 -0
- package/dist/chunks/planned-maintenance.jmWYTdet.js +5 -0
- package/dist/chunks/planned-maintenance.jmWYTdet.js.map +1 -0
- package/dist/chunks/{index.15b088b9.js → popover.B8YH92W8.js} +31 -37
- package/dist/chunks/popover.B8YH92W8.js.map +1 -0
- package/dist/chunks/{index.671768a1.js → popper-container.Bt02N3o1.js} +12 -15
- package/dist/chunks/popper-container.Bt02N3o1.js.map +1 -0
- package/dist/chunks/radio-group.CPbBFTzB.js +211 -0
- package/dist/chunks/radio-group.CPbBFTzB.js.map +1 -0
- package/dist/chunks/{radio-input.c6550a9c.js → radio-input.BQcC0INR.js} +17 -19
- package/dist/chunks/radio-input.BQcC0INR.js.map +1 -0
- package/dist/chunks/referrals.BvtT-kQS.js +5 -0
- package/dist/chunks/referrals.BvtT-kQS.js.map +1 -0
- package/dist/chunks/referrals.aX8WZigH.js +5 -0
- package/dist/chunks/referrals.aX8WZigH.js.map +1 -0
- package/dist/chunks/{refresh.71a03998.js → refresh.BKI9WwKh.js} +7 -9
- package/dist/chunks/{refresh.71a03998.js.map → refresh.BKI9WwKh.js.map} +1 -1
- package/dist/chunks/{resize.a041304d.js → resize.Bqks3WUm.js} +1 -1
- package/dist/chunks/{resize.a041304d.js.map → resize.Bqks3WUm.js.map} +1 -1
- package/dist/chunks/search-bar.CsAgO-t5.js +89 -0
- package/dist/chunks/search-bar.CsAgO-t5.js.map +1 -0
- package/dist/chunks/{search.471270fe.js → search.CBKhp7zB.js} +10 -12
- package/dist/chunks/{search.471270fe.js.map → search.CBKhp7zB.js.map} +1 -1
- package/dist/chunks/secondary-nav.CNgpPxUU.js +97 -0
- package/dist/chunks/secondary-nav.CNgpPxUU.js.map +1 -0
- package/dist/chunks/segmented-control.DGjIC7Ab.js +111 -0
- package/dist/chunks/segmented-control.DGjIC7Ab.js.map +1 -0
- package/dist/chunks/segmented-control.types.BHRLV8KU.js +5 -0
- package/dist/chunks/segmented-control.types.BHRLV8KU.js.map +1 -0
- package/dist/chunks/selection-card-group.DlOs8BkR.js +247 -0
- package/dist/chunks/selection-card-group.DlOs8BkR.js.map +1 -0
- package/dist/chunks/sidepanel.BBjm2QvZ.js +187 -0
- package/dist/chunks/sidepanel.BBjm2QvZ.js.map +1 -0
- package/dist/chunks/{sidepanel.keys.1ed8a57c.js → sidepanel.keys.R0DKQuYx.js} +1 -1
- package/dist/chunks/{sidepanel.keys.1ed8a57c.js.map → sidepanel.keys.R0DKQuYx.js.map} +1 -1
- package/dist/chunks/status.types.BhbOYpZx.js +36 -0
- package/dist/chunks/status.types.BhbOYpZx.js.map +1 -0
- package/dist/chunks/step.DY8Txb6a.js +234 -0
- package/dist/chunks/step.DY8Txb6a.js.map +1 -0
- package/dist/chunks/structured-list-item.C9NTVDvT.js +81 -0
- package/dist/chunks/structured-list-item.C9NTVDvT.js.map +1 -0
- package/dist/chunks/success.DhioLvPD.js +5 -0
- package/dist/chunks/success.DhioLvPD.js.map +1 -0
- package/dist/chunks/success.nNwxJRBS.js +5 -0
- package/dist/chunks/success.nNwxJRBS.js.map +1 -0
- package/dist/chunks/summary-grid-item-custom.CJpDnoPw.js +573 -0
- package/dist/chunks/summary-grid-item-custom.CJpDnoPw.js.map +1 -0
- package/dist/chunks/{summary-grid.keys.1d1028c2.js → summary-grid.keys.BBbFrFGF.js} +1 -1
- package/dist/chunks/{summary-grid.keys.1d1028c2.js.map → summary-grid.keys.BBbFrFGF.js.map} +1 -1
- package/dist/chunks/tabs.CE65f3E_.js +140 -0
- package/dist/chunks/tabs.CE65f3E_.js.map +1 -0
- package/dist/chunks/{tabs.keys.358742f2.js → tabs.keys.Bc2pSKRw.js} +1 -1
- package/dist/chunks/{tabs.keys.358742f2.js.map → tabs.keys.Bc2pSKRw.js.map} +1 -1
- package/dist/chunks/tag.bhKrZHTU.js +64 -0
- package/dist/chunks/tag.bhKrZHTU.js.map +1 -0
- package/dist/chunks/{teleport.84b0f20b.js → teleport.CQKBJZU5.js} +14 -16
- package/dist/chunks/{teleport.84b0f20b.js.map → teleport.CQKBJZU5.js.map} +1 -1
- package/dist/chunks/textarea.CcKbtQBs.js +208 -0
- package/dist/chunks/textarea.CcKbtQBs.js.map +1 -0
- package/dist/chunks/timeline-item.ScTrUBKC.js +364 -0
- package/dist/chunks/timeline-item.ScTrUBKC.js.map +1 -0
- package/dist/chunks/toast.0EYDj8o-.js +165 -0
- package/dist/chunks/toast.0EYDj8o-.js.map +1 -0
- package/dist/chunks/toggle-button.2U-vbQhk.js +83 -0
- package/dist/chunks/toggle-button.2U-vbQhk.js.map +1 -0
- package/dist/chunks/toggle.CiOVTWlk.js +121 -0
- package/dist/chunks/toggle.CiOVTWlk.js.map +1 -0
- package/dist/chunks/{tooltip.58ef3f4a.js → tooltip.DR8rbIYw.js} +29 -32
- package/dist/chunks/tooltip.DR8rbIYw.js.map +1 -0
- package/dist/chunks/tutorial.DMm12L0S.js +335 -0
- package/dist/chunks/tutorial.DMm12L0S.js.map +1 -0
- package/dist/chunks/{index.dd30e538.js → typography.Bjtu3Gca.js} +30 -32
- package/dist/chunks/typography.Bjtu3Gca.js.map +1 -0
- package/dist/chunks/{unique-id.a2a2b458.js → unique-id.XFfoKuc2.js} +14 -20
- package/dist/chunks/{unique-id.a2a2b458.js.map → unique-id.XFfoKuc2.js.map} +1 -1
- package/dist/chunks/upload-files.5wQwbfkp.js +5 -0
- package/dist/chunks/upload-files.5wQwbfkp.js.map +1 -0
- package/dist/chunks/upload-files.jTQY6y2X.js +5 -0
- package/dist/chunks/upload-files.jTQY6y2X.js.map +1 -0
- package/dist/chunks/{use-bento-toast-controller.c3277f73.js → use-bento-toast-controller.BifdE4ak.js} +4 -4
- package/dist/chunks/{use-bento-toast-controller.c3277f73.js.map → use-bento-toast-controller.BifdE4ak.js.map} +1 -1
- package/dist/chunks/{use-cached-selected-values.69297473.js → use-cached-selected-values.CVLzxvTi.js} +345 -346
- package/dist/chunks/use-cached-selected-values.CVLzxvTi.js.map +1 -0
- package/dist/chunks/{use-click-outside.941d1600.js → use-click-outside.DbjR7Lh4.js} +2 -2
- package/dist/chunks/{use-click-outside.941d1600.js.map → use-click-outside.DbjR7Lh4.js.map} +1 -1
- package/dist/chunks/{use-country-items.6b7985bf.js → use-country-items.C25TI6tp.js} +4 -4
- package/dist/chunks/{use-country-items.6b7985bf.js.map → use-country-items.C25TI6tp.js.map} +1 -1
- package/dist/chunks/{use-default-slot-validator.b9bff4c6.js → use-default-slot-validator.BDn0wkYP.js} +2 -2
- package/dist/chunks/{use-default-slot-validator.b9bff4c6.js.map → use-default-slot-validator.BDn0wkYP.js.map} +1 -1
- package/dist/chunks/{use-expandable-content-height.62fc84e5.js → use-expandable-content-height.GkjjbmPy.js} +1 -1
- package/dist/chunks/{use-expandable-content-height.62fc84e5.js.map → use-expandable-content-height.GkjjbmPy.js.map} +1 -1
- package/dist/chunks/{use-form-layout-loading.d03e5d48.js → use-form-layout-loading.D3lALhtC.js} +2 -2
- package/dist/chunks/{use-form-layout-loading.d03e5d48.js.map → use-form-layout-loading.D3lALhtC.js.map} +1 -1
- package/dist/chunks/use-has-slot.C9lQZ6nz.js +6 -0
- package/dist/chunks/{use-has-slot.fbeb19ec.js.map → use-has-slot.C9lQZ6nz.js.map} +1 -1
- package/dist/chunks/warning-filled.CLKRzGMT.js +24 -0
- package/dist/chunks/warning-filled.CLKRzGMT.js.map +1 -0
- package/dist/chunks/wrong-environment.BOsyKdRI.js +5 -0
- package/dist/chunks/wrong-environment.BOsyKdRI.js.map +1 -0
- package/dist/chunks/wrong-environment.BiHTPtbJ.js +5 -0
- package/dist/chunks/wrong-environment.BiHTPtbJ.js.map +1 -0
- package/dist/click-outside.js +2 -20
- package/dist/click-outside.js.map +1 -1
- package/dist/code-snippet.js +5 -2050
- package/dist/code-snippet.js.map +1 -1
- package/dist/country.js +8 -97
- package/dist/country.js.map +1 -1
- package/dist/currency.js +3 -112
- package/dist/currency.js.map +1 -1
- package/dist/dashboard-template.js +6 -0
- package/dist/dashboard-template.js.map +1 -0
- package/dist/dashed-underline.js +5 -0
- package/dist/dashed-underline.js.map +1 -0
- package/dist/data-grid-template.js +2 -65
- package/dist/data-grid-template.js.map +1 -1
- package/dist/data-grid.js +8 -1978
- package/dist/data-grid.js.map +1 -1
- package/dist/date-picker.js +5 -197
- package/dist/date-picker.js.map +1 -1
- package/dist/date-range-picker.js +2 -2
- package/dist/date.js +1 -1
- package/dist/divider.js +1 -1
- package/dist/dropdown.js +12 -227
- package/dist/dropdown.js.map +1 -1
- package/dist/empty-state.js +5 -143
- package/dist/empty-state.js.map +1 -1
- package/dist/filter-bar.js +5 -2154
- package/dist/filter-bar.js.map +1 -1
- package/dist/focus-trap.js +1 -1
- package/dist/form-layout.js +5 -192
- package/dist/form-layout.js.map +1 -1
- package/dist/header.js +2 -246
- package/dist/header.js.map +1 -1
- package/dist/image.js +4 -81
- package/dist/image.js.map +1 -1
- package/dist/index.js +276 -269
- package/dist/index.js.map +1 -1
- package/dist/info-icon.js +2 -40
- package/dist/info-icon.js.map +1 -1
- package/dist/input-field.js +7 -217
- package/dist/input-field.js.map +1 -1
- package/dist/internal.js +15 -15
- package/dist/link.js +1 -1
- package/dist/loading-indicator.js +3 -47
- package/dist/loading-indicator.js.map +1 -1
- package/dist/menu.js +1 -1
- package/dist/modal-fullscreen.js +3 -197
- package/dist/modal-fullscreen.js.map +1 -1
- package/dist/modal.js +11 -451
- package/dist/modal.js.map +1 -1
- package/dist/pagination.js +2 -507
- package/dist/pagination.js.map +1 -1
- package/dist/payment-method.js +4 -4
- package/dist/payment-method.js.map +1 -1
- package/dist/popover.js +1 -1
- package/dist/popper-container.js +1 -1
- package/dist/radio-group.js +6 -213
- package/dist/radio-group.js.map +1 -1
- package/dist/search-bar.js +6 -90
- package/dist/search-bar.js.map +1 -1
- package/dist/secondary-nav.js +2 -100
- package/dist/secondary-nav.js.map +1 -1
- package/dist/segmented-control.js +4 -215
- package/dist/segmented-control.js.map +1 -1
- package/dist/selection-card.js +4 -248
- package/dist/selection-card.js.map +1 -1
- package/dist/sidepanel.js +4 -189
- package/dist/sidepanel.js.map +1 -1
- package/dist/status.js +3 -40
- package/dist/status.js.map +1 -1
- package/dist/stepper.js +5 -237
- package/dist/stepper.js.map +1 -1
- package/dist/structured-list.js +1 -1
- package/dist/summary-grid.js +9 -584
- package/dist/summary-grid.js.map +1 -1
- package/dist/tabs.js +3 -140
- package/dist/tabs.js.map +1 -1
- package/dist/tag.js +3 -63
- package/dist/tag.js.map +1 -1
- package/dist/textarea.js +2 -209
- package/dist/textarea.js.map +1 -1
- package/dist/timeline.js +7 -367
- package/dist/timeline.js.map +1 -1
- package/dist/toast.js +2 -168
- package/dist/toast.js.map +1 -1
- package/dist/toggle.js +4 -120
- package/dist/toggle.js.map +1 -1
- package/dist/tutorial.js +2 -325
- package/dist/tutorial.js.map +1 -1
- package/dist/typography.js +1 -1
- package/dist/web-types.json +482 -305
- package/package.json +11 -10
- package/dist/assets/index11.css +0 -1
- package/dist/assets/index18.css +0 -1
- package/dist/assets/index33.css +0 -1
- package/dist/assets/index34.css +0 -1
- package/dist/assets/index35.css +0 -1
- package/dist/assets/index38.css +0 -1
- package/dist/assets/index4.css +0 -1
- package/dist/assets/index40.css +0 -1
- package/dist/assets/index44.css +0 -1
- package/dist/assets/index46.css +0 -1
- package/dist/chunks/1-generic-use.3ea646cd.js +0 -5
- package/dist/chunks/1-generic-use.3ea646cd.js.map +0 -1
- package/dist/chunks/1-generic-use.ccca5813.js +0 -5
- package/dist/chunks/1-generic-use.ccca5813.js.map +0 -1
- package/dist/chunks/2-generic-use.443db127.js +0 -5
- package/dist/chunks/2-generic-use.443db127.js.map +0 -1
- package/dist/chunks/2-generic-use.d69d7c08.js +0 -5
- package/dist/chunks/2-generic-use.d69d7c08.js.map +0 -1
- package/dist/chunks/3-generic-use.9f74667f.js +0 -5
- package/dist/chunks/3-generic-use.9f74667f.js.map +0 -1
- package/dist/chunks/3-generic-use.fe7ae2ce.js +0 -5
- package/dist/chunks/3-generic-use.fe7ae2ce.js.map +0 -1
- package/dist/chunks/4-generic-use.0356f4a1.js +0 -5
- package/dist/chunks/4-generic-use.0356f4a1.js.map +0 -1
- package/dist/chunks/4-generic-use.cd04bad0.js +0 -5
- package/dist/chunks/4-generic-use.cd04bad0.js.map +0 -1
- package/dist/chunks/_plugin-vue2_normalizer.71e2aa87.js +0 -33
- package/dist/chunks/_plugin-vue2_normalizer.71e2aa87.js.map +0 -1
- package/dist/chunks/adding-payment-methods.d570e03e.js +0 -5
- package/dist/chunks/adding-payment-methods.d570e03e.js.map +0 -1
- package/dist/chunks/adding-payment-methods.e419d6c0.js +0 -5
- package/dist/chunks/adding-payment-methods.e419d6c0.js.map +0 -1
- package/dist/chunks/adyen-giving.480913b5.js +0 -5
- package/dist/chunks/adyen-giving.480913b5.js.map +0 -1
- package/dist/chunks/adyen-giving.54ed984c.js +0 -5
- package/dist/chunks/adyen-giving.54ed984c.js.map +0 -1
- package/dist/chunks/base-button.ad74b6f8.js +0 -88
- package/dist/chunks/button-actions.81db18e8.js +0 -111
- package/dist/chunks/button-actions.81db18e8.js.map +0 -1
- package/dist/chunks/button.9d6435ae.js +0 -100
- package/dist/chunks/button.9d6435ae.js.map +0 -1
- package/dist/chunks/checkmark-circle-fill.345311d2.js +0 -26
- package/dist/chunks/checkmark.a6ed8f47.js +0 -26
- package/dist/chunks/checkmark.a6ed8f47.js.map +0 -1
- package/dist/chunks/dropdown.10c034aa.js.map +0 -1
- package/dist/chunks/error-message.31ec12b7.js +0 -111
- package/dist/chunks/events.58c00e6d.js +0 -50
- package/dist/chunks/events.58c00e6d.js.map +0 -1
- package/dist/chunks/index.15b088b9.js.map +0 -1
- package/dist/chunks/index.1ea85d4a.js.map +0 -1
- package/dist/chunks/index.317fca12.js.map +0 -1
- package/dist/chunks/index.671768a1.js.map +0 -1
- package/dist/chunks/index.7eefc59c.js.map +0 -1
- package/dist/chunks/index.885d05a9.js +0 -32
- package/dist/chunks/index.885d05a9.js.map +0 -1
- package/dist/chunks/index.8b8c3b16.js.map +0 -1
- package/dist/chunks/index.aaf965f8.js +0 -147
- package/dist/chunks/index.aaf965f8.js.map +0 -1
- package/dist/chunks/index.b21197ca.js.map +0 -1
- package/dist/chunks/index.d553d3d1.js.map +0 -1
- package/dist/chunks/index.dd30e538.js.map +0 -1
- package/dist/chunks/internal-error.35cbb071.js +0 -5
- package/dist/chunks/internal-error.35cbb071.js.map +0 -1
- package/dist/chunks/internal-error.9a4823ed.js +0 -5
- package/dist/chunks/internal-error.9a4823ed.js.map +0 -1
- package/dist/chunks/listbox-option-tag.6bbb6bbe.js +0 -107
- package/dist/chunks/listbox-option-tag.6bbb6bbe.js.map +0 -1
- package/dist/chunks/no-results-found.58856d70.js +0 -5
- package/dist/chunks/no-results-found.58856d70.js.map +0 -1
- package/dist/chunks/no-results-found.cbb12f78.js +0 -5
- package/dist/chunks/no-results-found.cbb12f78.js.map +0 -1
- package/dist/chunks/notifications-cleared.71025c22.js +0 -5
- package/dist/chunks/notifications-cleared.71025c22.js.map +0 -1
- package/dist/chunks/notifications-cleared.c4f4bed4.js +0 -5
- package/dist/chunks/notifications-cleared.c4f4bed4.js.map +0 -1
- package/dist/chunks/page-not-found.a500440d.js +0 -5
- package/dist/chunks/page-not-found.a500440d.js.map +0 -1
- package/dist/chunks/page-not-found.d1a84ba7.js +0 -5
- package/dist/chunks/page-not-found.d1a84ba7.js.map +0 -1
- package/dist/chunks/planned-maintenance.7fa5ac16.js +0 -5
- package/dist/chunks/planned-maintenance.7fa5ac16.js.map +0 -1
- package/dist/chunks/planned-maintenance.cff01aed.js +0 -5
- package/dist/chunks/planned-maintenance.cff01aed.js.map +0 -1
- package/dist/chunks/radio-input.c6550a9c.js.map +0 -1
- package/dist/chunks/referrals.178ce0eb.js +0 -5
- package/dist/chunks/referrals.178ce0eb.js.map +0 -1
- package/dist/chunks/referrals.599047da.js +0 -5
- package/dist/chunks/referrals.599047da.js.map +0 -1
- package/dist/chunks/success.41981fe8.js +0 -5
- package/dist/chunks/success.41981fe8.js.map +0 -1
- package/dist/chunks/success.77fac78b.js +0 -5
- package/dist/chunks/success.77fac78b.js.map +0 -1
- package/dist/chunks/tooltip.58ef3f4a.js.map +0 -1
- package/dist/chunks/upload-files.2708eca7.js +0 -5
- package/dist/chunks/upload-files.2708eca7.js.map +0 -1
- package/dist/chunks/upload-files.b4cd9f8b.js +0 -5
- package/dist/chunks/upload-files.b4cd9f8b.js.map +0 -1
- package/dist/chunks/use-cached-selected-values.69297473.js.map +0 -1
- package/dist/chunks/use-has-slot.fbeb19ec.js +0 -6
- package/dist/chunks/wrong-environment.c73b0bc0.js +0 -5
- package/dist/chunks/wrong-environment.c73b0bc0.js.map +0 -1
- package/dist/chunks/wrong-environment.f890a237.js +0 -5
- package/dist/chunks/wrong-environment.f890a237.js.map +0 -1
- /package/dist/assets/{index5.css → avatar-image.css} +0 -0
- /package/dist/assets/{index.css → badge.css} +0 -0
- /package/dist/assets/{index8.css → checkbox-group.css} +0 -0
- /package/dist/assets/{index10.css → country.css} +0 -0
- /package/dist/assets/{index12.css → date-picker.css} +0 -0
- /package/dist/assets/{index13.css → date-range-picker.css} +0 -0
- /package/dist/assets/{index14.css → divider.css} +0 -0
- /package/dist/assets/{index16.css → dropdown-tag.css} +0 -0
- /package/dist/assets/{index17.css → empty-state.css} +0 -0
- /package/dist/assets/{index19.css → focus-trap.css} +0 -0
- /package/dist/assets/{index21.css → header.css} +0 -0
- /package/dist/assets/{index27.css → info-icon.css} +0 -0
- /package/dist/assets/{index42.css → link.css} +0 -0
- /package/dist/assets/{index23.css → loading-indicator.css} +0 -0
- /package/dist/assets/{index24.css → pagination.css} +0 -0
- /package/dist/assets/{index45.css → popper-container.css} +0 -0
- /package/dist/assets/{index20.css → radio-group.css} +0 -0
- /package/dist/assets/{index47.css → search-bar.css} +0 -0
- /package/dist/assets/{index48.css → secondary-nav.css} +0 -0
- /package/dist/assets/{index39.css → step.css} +0 -0
- /package/dist/assets/{index41.css → summary-grid-item-custom.css} +0 -0
- /package/dist/assets/{index36.css → tag.css} +0 -0
- /package/dist/assets/{index30.css → textarea.css} +0 -0
- /package/dist/assets/{index31.css → timeline-item.css} +0 -0
- /package/dist/assets/{index32.css → toast.css} +0 -0
- /package/dist/assets/{index6.css → toggle-button.css} +0 -0
- /package/dist/assets/{index29.css → typography.css} +0 -0
package/dist/date-picker.js
CHANGED
|
@@ -1,200 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { B as K } from "./chunks/index.dd30e538.js";
|
|
4
|
-
import { c as j, B as z } from "./chunks/dropdown-default-textbox.54ca1b18.js";
|
|
5
|
-
import { d as $ } from "./chunks/debounce.b5ef6acf.js";
|
|
6
|
-
import { D as O, v as G, f as H } from "./chunks/date-input.9186a0bf.js";
|
|
7
|
-
import { g as u } from "./chunks/unique-id.a2a2b458.js";
|
|
8
|
-
import { u as B } from "./chunks/i18n.eb5b985b.js";
|
|
9
|
-
import { f as S } from "./chunks/index.b21197ca.js";
|
|
10
|
-
import { e as I, d as J, f as Q } from "./chunks/index.f55fdc32.js";
|
|
11
|
-
import { u as X } from "./chunks/use-form-layout-loading.d03e5d48.js";
|
|
12
|
-
import "./chunks/index.4c062058.js";
|
|
13
|
-
import { C as p } from "./chunks/calendar.640b8d25.js";
|
|
14
|
-
import { b as we } from "./chunks/calendar.640b8d25.js";
|
|
15
|
-
import { E as Z, F as ee } from "./chunks/error-message.31ec12b7.js";
|
|
16
|
-
import { n as ae } from "./chunks/_plugin-vue2_normalizer.71e2aa87.js";
|
|
17
|
-
import "./assets/index12.css";
|
|
18
|
-
const te = ({ datePickerValue: a, isDateIncorrect: e }) => {
|
|
19
|
-
var v;
|
|
20
|
-
const { locale: r, t: n } = B(), m = { de: J, enUS: I, fr: Q }, s = f((v = a.value) == null ? void 0 : v.toDateString());
|
|
21
|
-
return {
|
|
22
|
-
// Values
|
|
23
|
-
dateDisplayValue: D(() => e.value ? s.value : a.value ? S(a.value, O.FULL_DATE, {
|
|
24
|
-
locale: m[r.value.substring(0, 2)] || I
|
|
25
|
-
}) : n("selectDate")),
|
|
26
|
-
textInputValue: s,
|
|
27
|
-
// Methods
|
|
28
|
-
formatTextInputDisplayValue: (c = a.value) => {
|
|
29
|
-
e.value || (s.value = c ? S(c, O.NUMERIC_DATE_YEAR_FIRST, {
|
|
30
|
-
locale: m[r.value.substring(0, 2)] || I
|
|
31
|
-
}) : null);
|
|
32
|
-
}
|
|
33
|
-
};
|
|
34
|
-
};
|
|
35
|
-
var o = /* @__PURE__ */ ((a) => (a.INPUT = "input", a))(o || {});
|
|
36
|
-
const re = {
|
|
37
|
-
"en-US": {
|
|
38
|
-
provideDateInAFormat: "Provide date in a YYYY-MM-DD format",
|
|
39
|
-
selectDate: "Select a date",
|
|
40
|
-
selectDateRange: "Select a date range",
|
|
41
|
-
selectedDateIsNotAvailable: "Selected date is not available",
|
|
42
|
-
datePicker: "Date picker"
|
|
43
|
-
}
|
|
44
|
-
}, ne = 1e3, le = Y({
|
|
45
|
-
i18n: { messages: re },
|
|
46
|
-
name: "bento-date-picker",
|
|
47
|
-
components: {
|
|
48
|
-
BentoTypography: K,
|
|
49
|
-
BentoPopover: q,
|
|
50
|
-
Calendar: p,
|
|
51
|
-
ErrorMessage: Z,
|
|
52
|
-
DropdownInputDefault: j,
|
|
53
|
-
FieldLabel: ee
|
|
54
|
-
},
|
|
55
|
-
directives: { BentoClickOutsideDirective: z },
|
|
56
|
-
props: {
|
|
57
|
-
/**
|
|
58
|
-
* Descriptive supporting text visbile underneath the dropdown.
|
|
59
|
-
*/
|
|
60
|
-
description: { type: String, default: void 0 },
|
|
61
|
-
/**
|
|
62
|
-
* Disables dropdown functionality.
|
|
63
|
-
*/
|
|
64
|
-
disabled: { type: Boolean, default: !1 },
|
|
65
|
-
/**
|
|
66
|
-
* Displays component in an error state with an error message
|
|
67
|
-
*/
|
|
68
|
-
errorMessage: { type: String, default: null },
|
|
69
|
-
/**
|
|
70
|
-
* Allows you to set the first day of the week. 0 is sunday, 1 is monday, 6 is saturday
|
|
71
|
-
*/
|
|
72
|
-
firstDayOfWeek: p.props.firstDayOfWeek,
|
|
73
|
-
/**
|
|
74
|
-
* Indicate if a date should be disabled or not
|
|
75
|
-
*/
|
|
76
|
-
isDateDisabled: p.props.isDateDisabled,
|
|
77
|
-
/**
|
|
78
|
-
* Sets a minimum limit for selectable dates - dates before `min` will not be selectable
|
|
79
|
-
*/
|
|
80
|
-
min: p.props.min,
|
|
81
|
-
/**
|
|
82
|
-
* Sets a maximum limit for selectable dates - dates after `max` will not be selectable
|
|
83
|
-
*/
|
|
84
|
-
max: p.props.max,
|
|
85
|
-
/**
|
|
86
|
-
* Text that is displayed as a label above the element.
|
|
87
|
-
*/
|
|
88
|
-
label: { type: String, default: void 0 },
|
|
89
|
-
/**
|
|
90
|
-
* Highlights the dropdown is optional.
|
|
91
|
-
*/
|
|
92
|
-
optional: { type: Boolean, default: !1 },
|
|
93
|
-
/**
|
|
94
|
-
* The Boolean readonly property, when present, makes the element not mutable, meaning the user can not edit the date picker.
|
|
95
|
-
*/
|
|
96
|
-
readonly: { type: Boolean, default: !1 },
|
|
97
|
-
/**
|
|
98
|
-
* Highlights the dropdown is required.
|
|
99
|
-
*/
|
|
100
|
-
required: { type: Boolean, default: !1 },
|
|
101
|
-
/**
|
|
102
|
-
* Adds a info icon next to the label to display the passed tooltip message.
|
|
103
|
-
*/
|
|
104
|
-
tooltipText: { type: String, default: null },
|
|
105
|
-
/**
|
|
106
|
-
* Selected date
|
|
107
|
-
*/
|
|
108
|
-
value: { type: [Date, Object], default: null }
|
|
109
|
-
},
|
|
110
|
-
emits: [o.INPUT],
|
|
111
|
-
setup(a, { emit: e }) {
|
|
112
|
-
const { t: r } = B(), n = u("bento-date-picker-container"), m = u("bento-date-picker-label"), s = u("bento-date-picker-description"), b = u("bento-date-picker-error"), y = u("bento-date-picker-date-error"), v = D(() => a.label || r("datePicker", { name: n })), c = f(null), w = f(null), l = f(!1), i = f(!1), { isReadOnly: R } = X(E(a, "readonly"));
|
|
113
|
-
W(
|
|
114
|
-
() => a.disabled,
|
|
115
|
-
(t) => {
|
|
116
|
-
t && i.value && (i.value = !1);
|
|
117
|
-
}
|
|
118
|
-
);
|
|
119
|
-
const { dateDisplayValue: U, textInputValue: d, formatTextInputDisplayValue: g } = te({
|
|
120
|
-
datePickerValue: E(a, "value"),
|
|
121
|
-
isDateIncorrect: l
|
|
122
|
-
}), k = D(() => a.isDateDisabled && a.isDateDisabled(new Date(d.value)) && !i.value ? r("selectedDateIsNotAvailable") : l.value ? r("provideDateInAFormat") : null), V = D(() => ({
|
|
123
|
-
"b-date-picker__description--error": a.errorMessage || k.value
|
|
124
|
-
})), N = D(
|
|
125
|
-
() => `${a.description ? s : ""} ${a.errorMessage ? b : ""} ${k.value ? y : ""}`.trim() || null
|
|
126
|
-
), M = (t) => a.min && t <= a.min || a.max && t >= a.max ? !1 : a.isDateDisabled ? !a.isDateDisabled(t) : !0, x = () => {
|
|
127
|
-
i.value = !1;
|
|
128
|
-
}, C = () => {
|
|
129
|
-
i.value = !0, g();
|
|
130
|
-
}, F = (t) => {
|
|
131
|
-
l.value = !1, x(), e(o.INPUT, t);
|
|
132
|
-
}, h = async () => {
|
|
133
|
-
l.value && (l.value = !1, d.value = null), e(o.INPUT, null);
|
|
134
|
-
}, A = (t) => {
|
|
135
|
-
G(t);
|
|
136
|
-
}, P = (t) => {
|
|
137
|
-
if (t.length < 10)
|
|
138
|
-
return;
|
|
139
|
-
/^\d{4}-(0?[1-9]|1[012])-(0?[1-9]|[12][0-9]|3[01])$/.test(t) && M(new Date(t)) ? (l.value = !1, e(o.INPUT, new Date(t))) : t && (l.value = !0, e(o.INPUT, null));
|
|
140
|
-
}, L = $(P, ne);
|
|
141
|
-
return {
|
|
142
|
-
// Refs
|
|
143
|
-
inputContainerRef: w,
|
|
144
|
-
calendarContainerRef: c,
|
|
145
|
-
// Values,
|
|
146
|
-
dateDisplayValue: U,
|
|
147
|
-
datePickerContainerId: n,
|
|
148
|
-
descriptionConditionalClasses: V,
|
|
149
|
-
isDateIncorrect: l,
|
|
150
|
-
isDatePickerOpen: i,
|
|
151
|
-
isReadOnly: R,
|
|
152
|
-
dateErrorText: k,
|
|
153
|
-
labelId: m,
|
|
154
|
-
descriptionId: s,
|
|
155
|
-
errorId: b,
|
|
156
|
-
dateErrorId: y,
|
|
157
|
-
popoverAriaLabel: v,
|
|
158
|
-
ariaDescribedBy: N,
|
|
159
|
-
textInputValue: d,
|
|
160
|
-
// Events
|
|
161
|
-
closeDatePicker: x,
|
|
162
|
-
clearDatePickerValue: h,
|
|
163
|
-
onDateSelected: F,
|
|
164
|
-
openDatePicker: C,
|
|
165
|
-
onDateKeyDown: A,
|
|
166
|
-
onDateInputChange: (t) => {
|
|
167
|
-
d.value = H(t), i.value ? L(d.value) : P(d.value);
|
|
168
|
-
},
|
|
169
|
-
// Keyboard navigation
|
|
170
|
-
onSpaceBarOrEnter: async (t) => {
|
|
171
|
-
var _;
|
|
172
|
-
i.value || (t.preventDefault(), C(), await T(), a.value || (g(/* @__PURE__ */ new Date()), e(o.INPUT, /* @__PURE__ */ new Date()), await T()), (_ = c.value) == null || _.$refs.calendarRef[0].focusOnDate(a.value));
|
|
173
|
-
}
|
|
174
|
-
};
|
|
175
|
-
}
|
|
176
|
-
});
|
|
177
|
-
var ie = function() {
|
|
178
|
-
var e = this, r = e._self._c;
|
|
179
|
-
return e._self._setupProxy, r("div", { directives: [{ name: "bento-click-outside-directive", rawName: "v-bento-click-outside-directive", value: e.closeDatePicker, expression: "closeDatePicker" }], staticClass: "b-date-picker", on: { "!keydown": [function(n) {
|
|
180
|
-
return !n.type.indexOf("key") && e._k(n.keyCode, "space", 32, n.key, [" ", "Spacebar"]) ? null : e.onSpaceBarOrEnter.apply(null, arguments);
|
|
181
|
-
}, function(n) {
|
|
182
|
-
return !n.type.indexOf("key") && e._k(n.keyCode, "enter", 13, n.key, "Enter") ? null : e.onSpaceBarOrEnter.apply(null, arguments);
|
|
183
|
-
}] } }, [e.label ? r("field-label", { attrs: { id: e.labelId, label: e.label, "tooltip-text": e.tooltipText, optional: e.optional, required: e.required } }) : e._e(), r("div", [r("dropdown-input-default", { ref: "inputContainerRef", attrs: { "always-combobox-is-input": "", ariaControls: e.datePickerContainerId, ariaExpanded: e.isDatePickerOpen, "aria-labelledby": e.label ? e.labelId : null, "aria-describedby": e.ariaDescribedBy, disabled: e.disabled, "dynamic-filtering": "", "is-invalid": !!e.errorMessage || !!e.dateErrorText, open: e.isDatePickerOpen, value: e.textInputValue, "display-value": e.dateDisplayValue, "debounce-time": 0, readonly: e.isReadOnly }, on: { input: e.onDateInputChange, open: e.openDatePicker, keydown: e.onDateKeyDown, clear: e.clearDatePickerValue, close: e.closeDatePicker } })], 1), e.dateErrorText ? r("error-message", { staticClass: "b-date-picker__error-message", attrs: { id: e.dateErrorId, "error-message": e.dateErrorText } }) : e._e(), e.errorMessage ? r("error-message", { staticClass: "b-date-picker__error-message", attrs: { id: e.errorId, "error-message": e.errorMessage } }) : e._e(), e.description ? r("bento-typography", { staticClass: "b-date-picker__description", class: e.descriptionConditionalClasses, attrs: { el: "span" } }, [e._v(" " + e._s(e.description) + " ")]) : e._e(), e.inputContainerRef ? r("bento-popover", { staticClass: "b-date-picker__container", attrs: { id: e.datePickerContainerId, role: "dialog", open: e.isDatePickerOpen, "target-element": e.inputContainerRef, "disable-focus-trap": !0, "aria-label": e.popoverAriaLabel, "aria-modal": !0, position: "bottom-start", "fit-content": "" } }, [r("calendar", { ref: "calendarContainerRef", attrs: { "first-day-of-week": e.firstDayOfWeek, "is-date-disabled": e.isDateDisabled, "number-of-months": 1, value: e.value, min: e.min, max: e.max }, on: { input: e.onDateSelected } })], 1) : e._e()], 1);
|
|
184
|
-
}, oe = [], se = /* @__PURE__ */ ae(
|
|
185
|
-
le,
|
|
186
|
-
ie,
|
|
187
|
-
oe,
|
|
188
|
-
!1,
|
|
189
|
-
null,
|
|
190
|
-
"408106fe",
|
|
191
|
-
null,
|
|
192
|
-
null
|
|
193
|
-
);
|
|
194
|
-
const Te = se.exports;
|
|
1
|
+
import { B as a, a as r } from "./chunks/date-picker.ByP2Wpo0.js";
|
|
2
|
+
import { C as i } from "./chunks/calendar.B69z8gjb.js";
|
|
195
3
|
export {
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
4
|
+
a as BentoDatePicker,
|
|
5
|
+
r as BentoDatePickerEvent,
|
|
6
|
+
i as BentoDatePickerFirstDayOfWeek
|
|
199
7
|
};
|
|
200
8
|
//# sourceMappingURL=date-picker.js.map
|
package/dist/date-picker.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"date-picker.js","sources":["../src/components/date-picker/composables/use-date-picker-single-calendar-text.ts","../src/components/date-picker/date-picker.types.ts","../src/components/date-picker/date-picker.vue"],"sourcesContent":["import { computed, ref } from 'vue';\nimport { de, enUS, fr } from 'date-fns/locale';\nimport { useI18n } from '@/utils/ts/i18n';\nimport { UseDateDisplayText } from './use-date-picker-single-calendar-text.types';\nimport { DateFormat } from '@/types';\nimport format from 'date-fns/format';\n\n/**\n * Composable that sets and formats the date to be displayed in the input box of a Single Date Picker\n * @param {Ref<Date>} option.datePickerValue Ref to the datePickerValue set in the DatePicker component\n * @param {Ref<boolean>} option.isDateIncorrect Indicates if the date is correct or not\n */\nexport const useDatePickerSingleCalendarText: UseDateDisplayText<Date> = ({ datePickerValue, isDateIncorrect }) => {\n const { locale, t } = useI18n();\n const locales = { de, enUS, fr };\n\n const textInputValue = ref(datePickerValue.value?.toDateString());\n\n const dateDisplayValue = computed(() => {\n // Display incorrect date when there's an error with the input\n if (isDateIncorrect.value) {\n return textInputValue.value;\n }\n\n // Display \"Select a date\" when there's no date selected or input\n if (!datePickerValue.value) {\n return t('selectDate') as string;\n }\n\n // Display the date in format \"dd MMM, yyyy (25 Jun, 2023)\" if there's a valid date selected\n return format(datePickerValue.value as Date, DateFormat.FULL_DATE, {\n locale: locales[locale.value.substring(0, 2)] || enUS,\n });\n });\n\n /**\n * Formats the \"dateToFormat\" date value with the yyyy-MM-dd format and sets it as \"formatTextInputDisplayValue\" value\n * @param {DATE} dateToFormat - Date to be assigned and formatted\n */\n const formatTextInputDisplayValue = (dateToFormat: Date = datePickerValue.value) => {\n // If date is incorrect, leave the textInputValue intact\n if (isDateIncorrect.value) {\n return;\n }\n\n textInputValue.value = dateToFormat\n ? format(dateToFormat, DateFormat.NUMERIC_DATE_YEAR_FIRST, {\n locale: locales[locale.value.substring(0, 2)] || enUS,\n })\n : null;\n };\n\n return {\n // Values\n dateDisplayValue,\n textInputValue,\n\n // Methods\n formatTextInputDisplayValue,\n };\n};\n","export { CalendarFirstDayOfWeek as BentoDatePickerFirstDayOfWeek } from '@/internal';\nexport type {\n CalendarIsDateDisabled as BentoDatePickerIsDateDisabled,\n CalendarSingleDateValue as BentoDatePickerValue,\n} from '@/internal';\n\nexport enum BentoDatePickerEvent {\n INPUT = 'input',\n}\n","<!-- TODO: Remove aria props as these are part of JSX elements /vue/types/jsx.d.ts -->\n<!-- eslint-disable vue/attribute-hyphenation -->\n<template>\n <div\n v-bento-click-outside-directive=\"closeDatePicker\"\n class=\"b-date-picker\"\n @keydown.space.capture=\"onSpaceBarOrEnter\"\n @keydown.enter.capture=\"onSpaceBarOrEnter\"\n >\n <!-- Label -->\n <field-label\n v-if=\"label\"\n :id=\"labelId\"\n :label=\"label\"\n :tooltip-text=\"tooltipText\"\n :optional=\"optional\"\n :required=\"required\"\n />\n\n <!-- Input -->\n <div>\n <dropdown-input-default\n ref=\"inputContainerRef\"\n always-combobox-is-input\n :ariaControls=\"datePickerContainerId\"\n :ariaExpanded=\"isDatePickerOpen\"\n :aria-labelledby=\"label ? labelId : null\"\n :aria-describedby=\"ariaDescribedBy\"\n :disabled=\"disabled\"\n dynamic-filtering\n :is-invalid=\"!!errorMessage || !!dateErrorText\"\n :open=\"isDatePickerOpen\"\n :value=\"textInputValue\"\n :display-value=\"dateDisplayValue\"\n :debounce-time=\"0\"\n :readonly=\"isReadOnly\"\n @input=\"onDateInputChange\"\n @open=\"openDatePicker\"\n @keydown=\"onDateKeyDown\"\n @clear=\"clearDatePickerValue\"\n @close=\"closeDatePicker\"\n />\n </div>\n\n <!-- Error Messages -->\n <error-message\n v-if=\"dateErrorText\"\n :id=\"dateErrorId\"\n :error-message=\"dateErrorText\"\n class=\"b-date-picker__error-message\"\n />\n <error-message\n v-if=\"errorMessage\"\n :id=\"errorId\"\n :error-message=\"errorMessage\"\n class=\"b-date-picker__error-message\"\n />\n\n <!-- Description -->\n <bento-typography\n v-if=\"description\"\n class=\"b-date-picker__description\"\n :class=\"descriptionConditionalClasses\"\n el=\"span\"\n >\n {{ description }}\n </bento-typography>\n\n <!-- Calendar container -->\n <bento-popover\n v-if=\"inputContainerRef\"\n :id=\"datePickerContainerId\"\n class=\"b-date-picker__container\"\n role=\"dialog\"\n :open=\"isDatePickerOpen\"\n :target-element=\"inputContainerRef\"\n :disable-focus-trap=\"true\"\n :aria-label=\"popoverAriaLabel\"\n :aria-modal=\"true\"\n position=\"bottom-start\"\n fit-content\n >\n <calendar\n ref=\"calendarContainerRef\"\n :first-day-of-week=\"firstDayOfWeek\"\n :is-date-disabled=\"isDateDisabled\"\n :number-of-months=\"1\"\n :value=\"value\"\n :min=\"min\"\n :max=\"max\"\n @input=\"onDateSelected\"\n />\n </bento-popover>\n </div>\n</template>\n\n<script lang=\"ts\">\n import { computed, defineComponent, nextTick, PropType, Ref, ref, toRef, watch } from 'vue';\n\n // Components\n import { BentoPopover } from '@/components/popover';\n import { BentoTypography } from '../typography';\n import { Calendar, ErrorMessage, FieldLabel } from '@/internal';\n import { DropdownInputDefault } from '@/components/dropdown/components';\n\n // Utils\n import { debounce } from '@/utils/ts/debounce';\n import { formatDateInputValue, validateDateInput } from '@/utils/ts/date-input';\n import { generateUid } from '@/utils/ts/unique-id';\n import { useI18n } from '@/utils/ts/i18n';\n\n // Composables\n import { useDatePickerSingleCalendarText } from './composables/use-date-picker-single-calendar-text';\n import { useFormLayoutFieldLoading } from '@/composables';\n\n // Directive\n import { BentoClickOutsideDirective } from '@/directives';\n\n // Types\n import { BentoDatePickerEvent, BentoDatePickerValue } from './date-picker.types';\n\n import messages from './messages.json';\n\n type MessageSchema = (typeof messages)['en-US'];\n const DEBOUNCE_TIME = 1000;\n\n /**\n * Date picker selector.\n *\n * @example\n * import { BentoDatePicker } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoDatePicker },\n * template: `\n * <bento-date-picker\n * label=\"Label\"\n * description=\"Supporting text\"\n * required\n * optional\n * disabled\n * @input=\"onDateChanged\"\n * v-model=\"selectedDate\"\n * />\n * `,\n * setup() {\n * const selectedDate = ref(new Date()); // reactive({ startDate: new Date(), endDate: new Date() })\n * return {\n * selectedDate,\n * }\n * }\n * }\n */\n export default defineComponent({\n i18n: { messages },\n name: 'bento-date-picker',\n components: {\n BentoTypography,\n BentoPopover,\n Calendar,\n ErrorMessage,\n DropdownInputDefault,\n FieldLabel,\n },\n directives: { BentoClickOutsideDirective },\n props: {\n /**\n * Descriptive supporting text visbile underneath the dropdown.\n */\n description: { type: String, default: undefined },\n\n /**\n * Disables dropdown functionality.\n */\n disabled: { type: Boolean, default: false },\n\n /**\n * Displays component in an error state with an error message\n */\n errorMessage: { type: String, default: null },\n\n /**\n * Allows you to set the first day of the week. 0 is sunday, 1 is monday, 6 is saturday\n */\n firstDayOfWeek: Calendar.props.firstDayOfWeek,\n\n /**\n * Indicate if a date should be disabled or not\n */\n isDateDisabled: Calendar.props.isDateDisabled,\n\n /**\n * Sets a minimum limit for selectable dates - dates before `min` will not be selectable\n */\n min: Calendar.props.min,\n\n /**\n * Sets a maximum limit for selectable dates - dates after `max` will not be selectable\n */\n max: Calendar.props.max,\n\n /**\n * Text that is displayed as a label above the element.\n */\n label: { type: String, default: undefined },\n\n /**\n * Highlights the dropdown is optional.\n */\n optional: { type: Boolean, default: false },\n\n /**\n * The Boolean readonly property, when present, makes the element not mutable, meaning the user can not edit the date picker.\n */\n readonly: { type: Boolean, default: false },\n\n /**\n * Highlights the dropdown is required.\n */\n required: { type: Boolean, default: false },\n\n /**\n * Adds a info icon next to the label to display the passed tooltip message.\n */\n tooltipText: { type: String, default: null },\n\n /**\n * Selected date\n */\n value: { type: [Date, Object] as PropType<BentoDatePickerValue>, default: null },\n },\n emits: [BentoDatePickerEvent.INPUT],\n setup(props, { emit }) {\n const { t } = useI18n<{ message: MessageSchema }>({ messages });\n const datePickerContainerId = generateUid('bento-date-picker-container');\n const labelId = generateUid('bento-date-picker-label');\n const descriptionId = generateUid('bento-date-picker-description');\n const errorId = generateUid('bento-date-picker-error');\n const dateErrorId = generateUid('bento-date-picker-date-error');\n const popoverAriaLabel = computed(() => props.label || t('datePicker', { name: datePickerContainerId }));\n\n // Refs\n const calendarContainerRef = ref(null);\n const inputContainerRef = ref(null);\n\n // Values\n const isDateIncorrect = ref(false);\n const isDatePickerOpen = ref(false);\n const { isReadOnly } = useFormLayoutFieldLoading(toRef(props, 'readonly'));\n\n watch(\n () => props.disabled,\n disabled => {\n // Close date picker popover if it's opened when it's disabled\n if (disabled && isDatePickerOpen.value) {\n isDatePickerOpen.value = false;\n }\n }\n );\n\n const { dateDisplayValue, textInputValue, formatTextInputDisplayValue } = useDatePickerSingleCalendarText({\n datePickerValue: toRef(props, 'value') as Ref<Date>,\n isDateIncorrect,\n });\n\n const dateErrorText = computed(() => {\n if (\n props.isDateDisabled &&\n props.isDateDisabled(new Date(textInputValue.value)) &&\n !isDatePickerOpen.value\n ) {\n return t('selectedDateIsNotAvailable');\n }\n\n return isDateIncorrect.value ? t('provideDateInAFormat') : null;\n });\n\n const descriptionConditionalClasses = computed(() => ({\n 'b-date-picker__description--error': props.errorMessage || dateErrorText.value,\n }));\n\n const ariaDescribedBy = computed(\n () =>\n `${props.description ? descriptionId : ''} ${props.errorMessage ? errorId : ''} ${\n dateErrorText.value ? dateErrorId : ''\n }`.trim() || null\n );\n\n const isDateEnabled = (date: Date) => {\n // Check if date is between min/max bounds, if there are any\n if ((props.min && date <= props.min) || (props.max && date >= props.max)) {\n return false;\n }\n\n // Check if function is set, otherwise all dates are enabled\n if (props.isDateDisabled) {\n return !props.isDateDisabled(date);\n }\n\n return true;\n };\n\n const closeDatePicker = () => {\n isDatePickerOpen.value = false;\n };\n\n const openDatePicker = () => {\n isDatePickerOpen.value = true;\n\n formatTextInputDisplayValue();\n };\n\n const onDateSelected = (selectedDate: Date) => {\n // Reset the error state when a valid date is selected\n isDateIncorrect.value = false;\n\n closeDatePicker();\n emit(BentoDatePickerEvent.INPUT, selectedDate);\n };\n\n const clearDatePickerValue = async () => {\n if (isDateIncorrect.value) {\n isDateIncorrect.value = false;\n textInputValue.value = null;\n }\n emit(BentoDatePickerEvent.INPUT, null);\n };\n\n const onDateKeyDown = (event: KeyboardEvent) => {\n validateDateInput(event);\n };\n\n const validateDate = (stringDate: string) => {\n // Validate only if the date is complete\n if (stringDate.length < 10) {\n return;\n }\n\n // Checks for YYYY-MM-DD format\n const dateRegex = /^\\d{4}-(0?[1-9]|1[012])-(0?[1-9]|[12][0-9]|3[01])$/;\n const isValidDate = dateRegex.test(stringDate) && isDateEnabled(new Date(stringDate));\n if (isValidDate) {\n isDateIncorrect.value = false;\n emit(BentoDatePickerEvent.INPUT, new Date(stringDate));\n } else if (stringDate) {\n // Only set to true if the value exists (not null/undefined)\n isDateIncorrect.value = true;\n emit(BentoDatePickerEvent.INPUT, null);\n }\n };\n\n const validateDateDebounced = debounce(validateDate, DEBOUNCE_TIME);\n\n const onDateInputChange = (stringDate: string) => {\n textInputValue.value = formatDateInputValue(stringDate);\n // If we are closing the date picker, we should validate (and emit date inputs) immediately so the user doesn't have to wait for the debounce time.\n if (isDatePickerOpen.value) {\n validateDateDebounced(textInputValue.value);\n } else {\n validateDate(textInputValue.value);\n }\n };\n\n /**\n * Space bar and Enter keyDown event handler.\n *\n * * Opens the date picker dialog on the first keydown.\n * * Move focus to selected date, i.e., the date displayed in the date input text field. If no date has been selected, places focus on the current date.\n * @param {KeyboardEvent} event Event being triggered\n */\n const onSpaceBarOrEnter = async (event: KeyboardEvent) => {\n if (isDatePickerOpen.value) {\n return;\n }\n event.preventDefault();\n\n openDatePicker();\n\n // Wait for the date picker dialog to open\n await nextTick();\n\n // Set current date (today) if no date is selected\n if (!props.value) {\n // Format the opened date picker date to YYYY-MM-DD\n formatTextInputDisplayValue(new Date());\n emit(BentoDatePickerEvent.INPUT, new Date());\n\n // Wait for new value to be set with the emit\n await nextTick();\n }\n\n // Focus on date\n calendarContainerRef.value?.$refs.calendarRef[0].focusOnDate(props.value);\n };\n\n return {\n // Refs\n inputContainerRef,\n calendarContainerRef,\n\n // Values,\n dateDisplayValue,\n datePickerContainerId,\n descriptionConditionalClasses,\n isDateIncorrect,\n isDatePickerOpen,\n isReadOnly,\n dateErrorText,\n labelId,\n descriptionId,\n errorId,\n dateErrorId,\n popoverAriaLabel,\n ariaDescribedBy,\n textInputValue,\n\n // Events\n closeDatePicker,\n clearDatePickerValue,\n onDateSelected,\n openDatePicker,\n onDateKeyDown,\n onDateInputChange,\n\n // Keyboard navigation\n onSpaceBarOrEnter,\n };\n },\n });\n</script>\n\n<style lang=\"scss\" scoped src=\"./date-picker.scss\" />\n"],"names":["useDatePickerSingleCalendarText","datePickerValue","isDateIncorrect","locale","t","useI18n","locales","de","enUS","fr","textInputValue","ref","_a","computed","format","DateFormat","dateToFormat","BentoDatePickerEvent","BentoDatePickerEvent2","DEBOUNCE_TIME","_sfc_main","defineComponent","messages","BentoTypography","BentoPopover","Calendar","ErrorMessage","DropdownInputDefault","FieldLabel","BentoClickOutsideDirective","props","emit","datePickerContainerId","generateUid","labelId","descriptionId","errorId","dateErrorId","popoverAriaLabel","calendarContainerRef","inputContainerRef","isDatePickerOpen","isReadOnly","useFormLayoutFieldLoading","toRef","watch","disabled","dateDisplayValue","formatTextInputDisplayValue","dateErrorText","descriptionConditionalClasses","ariaDescribedBy","isDateEnabled","date","closeDatePicker","openDatePicker","onDateSelected","selectedDate","clearDatePickerValue","onDateKeyDown","event","validateDateInput","validateDate","stringDate","validateDateDebounced","debounce","formatDateInputValue","nextTick"],"mappings":"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"}
|
|
1
|
+
{"version":3,"file":"date-picker.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { B as t, a as r } from "./chunks/
|
|
2
|
-
import {
|
|
1
|
+
import { B as t, a as r } from "./chunks/date-range-picker.DrnklTJ-.js";
|
|
2
|
+
import { C as o } from "./chunks/calendar.B69z8gjb.js";
|
|
3
3
|
export {
|
|
4
4
|
t as BentoDateRangePicker,
|
|
5
5
|
r as BentoDateRangePickerEvent,
|
package/dist/date.js
CHANGED
package/dist/divider.js
CHANGED
package/dist/dropdown.js
CHANGED
|
@@ -1,230 +1,15 @@
|
|
|
1
|
-
import { B as
|
|
2
|
-
import { a as
|
|
3
|
-
import {
|
|
4
|
-
import { defineComponent as a, computed as l, toRefs as m } from "vue";
|
|
5
|
-
import { B as y, L as i } from "./chunks/listbox-option-tag.6bbb6bbe.js";
|
|
6
|
-
import { n as d } from "./chunks/_plugin-vue2_normalizer.71e2aa87.js";
|
|
7
|
-
import { d as v, B as w } from "./chunks/index.dd30e538.js";
|
|
8
|
-
import { u as b } from "./chunks/use-country-items.6b7985bf.js";
|
|
9
|
-
import { B as c } from "./chunks/country.types.002caff2.js";
|
|
10
|
-
import { B } from "./chunks/payment-method.6c1ce07c.js";
|
|
11
|
-
import "./assets/index16.css";
|
|
12
|
-
const $ = a({
|
|
13
|
-
name: "bento-dropdown-avatar"
|
|
14
|
-
}), I = /* @__PURE__ */ a({
|
|
15
|
-
...$,
|
|
16
|
-
props: {
|
|
17
|
-
...p.props,
|
|
18
|
-
/**
|
|
19
|
-
* The option elements to populate the avatar dropdown with.
|
|
20
|
-
* It must be an array of {@see BentoAvatarListboxOptions }
|
|
21
|
-
* * @property {string} value.label - Text to be displayed in the option.
|
|
22
|
-
* * @property {string,number} value.value - Value of the option.
|
|
23
|
-
* * @property {string} value.src - Image source of the avatar image.
|
|
24
|
-
*/
|
|
25
|
-
items: {
|
|
26
|
-
type: Array,
|
|
27
|
-
default: () => []
|
|
28
|
-
}
|
|
29
|
-
},
|
|
30
|
-
emits: ["input"],
|
|
31
|
-
setup(s, { emit: t }) {
|
|
32
|
-
const o = s, n = (e) => t("input", e), r = l(() => o.items.map(({ value: e, label: u, src: _ }) => ({ value: e, label: u, data: _ })));
|
|
33
|
-
return { __sfc: !0, props: o, emit: t, onInput: n, dropdownItems: r, BentoAvatar: y, BentoDropdown: p };
|
|
34
|
-
}
|
|
35
|
-
});
|
|
36
|
-
var x = function() {
|
|
37
|
-
var t = this, o = t._self._c, n = t._self._setupProxy;
|
|
38
|
-
return o("div", [o(n.BentoDropdown, t._b({ attrs: { items: n.dropdownItems }, on: { input: n.onInput }, scopedSlots: t._u([{ key: "default", fn: function({ label: r, data: e }) {
|
|
39
|
-
return [o(n.BentoAvatar, { attrs: { username: r, src: e } })];
|
|
40
|
-
} }]) }, "bento-dropdown", t.$props, !1))], 1);
|
|
41
|
-
}, D = [], h = /* @__PURE__ */ d(
|
|
42
|
-
I,
|
|
43
|
-
x,
|
|
44
|
-
D,
|
|
45
|
-
!1,
|
|
46
|
-
null,
|
|
47
|
-
null,
|
|
48
|
-
null,
|
|
49
|
-
null
|
|
50
|
-
);
|
|
51
|
-
const tt = h.exports, g = a({
|
|
52
|
-
name: "b-dropdown-country"
|
|
53
|
-
}), C = /* @__PURE__ */ a({
|
|
54
|
-
...g,
|
|
55
|
-
props: {
|
|
56
|
-
...p.props,
|
|
57
|
-
/**
|
|
58
|
-
* The option elements to populate the country dropdown with.
|
|
59
|
-
* It must be an array of {@see BentoCountryListboxOptions }
|
|
60
|
-
* * @deprecated {string} value.label - Use BentoDropdown instead of custom labels
|
|
61
|
-
* * @property {BentoCountryCode | string} value.value - Country code of the option
|
|
62
|
-
*/
|
|
63
|
-
items: {
|
|
64
|
-
type: Array,
|
|
65
|
-
default: () => []
|
|
66
|
-
},
|
|
67
|
-
/**
|
|
68
|
-
* Which label variant to display.
|
|
69
|
-
* @values iso, name, phone_code, capital
|
|
70
|
-
*/
|
|
71
|
-
variant: {
|
|
72
|
-
type: String,
|
|
73
|
-
default: c.CUSTOM,
|
|
74
|
-
validator: (s) => Object.values(c).includes(s)
|
|
75
|
-
}
|
|
76
|
-
},
|
|
77
|
-
emits: ["input"],
|
|
78
|
-
setup(s, { emit: t }) {
|
|
79
|
-
const o = s, n = (_) => t("input", _), { variant: r, items: e } = m(o), u = b(r, e);
|
|
80
|
-
return (r.value === "custom" || e.value.some((_) => _.label)) && v(
|
|
81
|
-
'BentoDropdownCountry "custom" variant and "items" prop "label" key',
|
|
82
|
-
"Use any of the other BentoDropdownCountry variants instead OR use BentoDropdown component for custom labels",
|
|
83
|
-
"2.0.0"
|
|
84
|
-
), { __sfc: !0, props: o, emit: t, onInput: n, variant: r, items: e, countryItems: u, BentoTypography: w, BentoDropdown: p };
|
|
85
|
-
}
|
|
86
|
-
});
|
|
87
|
-
var T = function() {
|
|
88
|
-
var t = this, o = t._self._c, n = t._self._setupProxy;
|
|
89
|
-
return o("div", [o(n.BentoDropdown, t._b({ attrs: { items: n.countryItems }, on: { input: n.onInput }, scopedSlots: t._u([{ key: "default", fn: function({ label: r }) {
|
|
90
|
-
return [o(n.BentoTypography, { attrs: { el: "span" } }, [t._v(t._s(r))])];
|
|
91
|
-
} }]) }, "bento-dropdown", t.$props, !1))], 1);
|
|
92
|
-
}, A = [], P = /* @__PURE__ */ d(
|
|
93
|
-
C,
|
|
94
|
-
T,
|
|
95
|
-
A,
|
|
96
|
-
!1,
|
|
97
|
-
null,
|
|
98
|
-
null,
|
|
99
|
-
null,
|
|
100
|
-
null
|
|
101
|
-
);
|
|
102
|
-
const nt = P.exports, S = a({
|
|
103
|
-
name: "b-dropdown-currency"
|
|
104
|
-
}), R = /* @__PURE__ */ a({
|
|
105
|
-
...S,
|
|
106
|
-
props: {
|
|
107
|
-
...p.props,
|
|
108
|
-
/**
|
|
109
|
-
* The option elements to populate the country dropdown with.
|
|
110
|
-
* It must be an array of {@see BentoCurrencyListboxOptions }
|
|
111
|
-
* * @property {string} value.label - Text to be displayed in the option
|
|
112
|
-
* * @property {BentoCurrencyISOCode} value.code - Currency ISO code of the option
|
|
113
|
-
*/
|
|
114
|
-
items: {
|
|
115
|
-
type: Array,
|
|
116
|
-
default: () => []
|
|
117
|
-
}
|
|
118
|
-
},
|
|
119
|
-
emits: ["input"],
|
|
120
|
-
setup(s, { emit: t }) {
|
|
121
|
-
return { __sfc: !0, emit: t, onInput: (n) => t("input", n), ListboxOptionTag: i, BentoDropdown: p };
|
|
122
|
-
}
|
|
123
|
-
});
|
|
124
|
-
var k = function() {
|
|
125
|
-
var t = this, o = t._self._c, n = t._self._setupProxy;
|
|
126
|
-
return o(n.BentoDropdown, t._b({ on: { input: n.onInput }, scopedSlots: t._u([{ key: "default", fn: function(r) {
|
|
127
|
-
return [o(n.ListboxOptionTag, { attrs: { option: r } })];
|
|
128
|
-
} }]) }, "bento-dropdown", t.$props, !1));
|
|
129
|
-
}, L = [], O = /* @__PURE__ */ d(
|
|
130
|
-
R,
|
|
131
|
-
k,
|
|
132
|
-
L,
|
|
133
|
-
!1,
|
|
134
|
-
null,
|
|
135
|
-
null,
|
|
136
|
-
null,
|
|
137
|
-
null
|
|
138
|
-
);
|
|
139
|
-
const ot = O.exports, F = a({
|
|
140
|
-
name: "bento-dropdown-payment-method"
|
|
141
|
-
}), M = /* @__PURE__ */ a({
|
|
142
|
-
...F,
|
|
143
|
-
props: {
|
|
144
|
-
...p.props,
|
|
145
|
-
/**
|
|
146
|
-
* The option elements to populate the payment method dropdown with.
|
|
147
|
-
* It must be an array of {@see BentoPaymentMethodListboxOptions }
|
|
148
|
-
* * @property {string} value.label - Text to be displayed in the option
|
|
149
|
-
* * @property {string} value.value - Payment type code that translates to a payment icon name {@see https://adyen-ui-assets.netlify.app/?path=/story/packages-ui-assets-payment-method-icons--icons}
|
|
150
|
-
*/
|
|
151
|
-
items: {
|
|
152
|
-
type: Array,
|
|
153
|
-
default: () => []
|
|
154
|
-
}
|
|
155
|
-
},
|
|
156
|
-
emits: ["input"],
|
|
157
|
-
setup(s, { emit: t }) {
|
|
158
|
-
return { __sfc: !0, emit: t, onInput: (n) => t("input", n), BentoPaymentMethod: B, BentoDropdown: p };
|
|
159
|
-
}
|
|
160
|
-
});
|
|
161
|
-
var z = function() {
|
|
162
|
-
var t = this, o = t._self._c, n = t._self._setupProxy;
|
|
163
|
-
return o("div", [o(n.BentoDropdown, t._b({ on: { input: n.onInput }, scopedSlots: t._u([{ key: "default", fn: function({ value: r, label: e }) {
|
|
164
|
-
return [o(n.BentoPaymentMethod, { attrs: { type: r, label: e } })];
|
|
165
|
-
} }]) }, "bento-dropdown", t.$props, !1))], 1);
|
|
166
|
-
}, U = [], j = /* @__PURE__ */ d(
|
|
167
|
-
M,
|
|
168
|
-
z,
|
|
169
|
-
U,
|
|
170
|
-
!1,
|
|
171
|
-
null,
|
|
172
|
-
null,
|
|
173
|
-
null,
|
|
174
|
-
null
|
|
175
|
-
);
|
|
176
|
-
const et = j.exports, E = a({
|
|
177
|
-
name: "bento-dropdown-tag"
|
|
178
|
-
}), V = /* @__PURE__ */ a({
|
|
179
|
-
...E,
|
|
180
|
-
props: {
|
|
181
|
-
...p.props,
|
|
182
|
-
/**
|
|
183
|
-
* The option elements to populate the tag dropdown with.
|
|
184
|
-
* It must be an array of {@see BentoTagListboxOptions }
|
|
185
|
-
* * @property {string} value.label - Text to be displayed in the option
|
|
186
|
-
* * @property {string,number} value.value - Value of the option
|
|
187
|
-
* * @property {string} value.variant - The BentTag variant shown for the option.
|
|
188
|
-
*/
|
|
189
|
-
items: {
|
|
190
|
-
type: Array,
|
|
191
|
-
default: () => []
|
|
192
|
-
}
|
|
193
|
-
},
|
|
194
|
-
emits: ["input"],
|
|
195
|
-
setup(s, { emit: t }) {
|
|
196
|
-
const o = s, n = (e) => t("input", e), r = l(() => {
|
|
197
|
-
var e;
|
|
198
|
-
return (e = o.items) == null ? void 0 : e.map(({ label: u, value: _, variant: f }) => ({ label: u, value: _, data: f }));
|
|
199
|
-
});
|
|
200
|
-
return { __sfc: !0, props: o, emit: t, onInput: n, tagItems: r, ListboxOptionTag: i, BentoDropdown: p };
|
|
201
|
-
}
|
|
202
|
-
});
|
|
203
|
-
var q = function() {
|
|
204
|
-
var t = this, o = t._self._c, n = t._self._setupProxy;
|
|
205
|
-
return o(n.BentoDropdown, t._b({ staticClass: "b-dropdown-tag", attrs: { items: n.tagItems, "show-slot-content-in-multiple": "" }, on: { input: n.onInput }, scopedSlots: t._u([{ key: "default", fn: function({ label: r, data: e }) {
|
|
206
|
-
return [o(n.ListboxOptionTag, { attrs: { option: { value: r, data: e, label: "" } } })];
|
|
207
|
-
} }]) }, "bento-dropdown", t.$props, !1));
|
|
208
|
-
}, G = [], H = /* @__PURE__ */ d(
|
|
209
|
-
V,
|
|
210
|
-
q,
|
|
211
|
-
G,
|
|
212
|
-
!1,
|
|
213
|
-
null,
|
|
214
|
-
"bae2dd4a",
|
|
215
|
-
null,
|
|
216
|
-
null
|
|
217
|
-
);
|
|
218
|
-
const rt = H.exports;
|
|
1
|
+
import { B as e, a as r } from "./chunks/dropdown.yhhQCKve.js";
|
|
2
|
+
import { a as t, B as p } from "./chunks/use-cached-selected-values.CVLzxvTi.js";
|
|
3
|
+
import { d as B, a as s, b as w, c as D, e as y } from "./chunks/dropdown-tag.DCMKQy-E.js";
|
|
219
4
|
export {
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
5
|
+
e as BentoDropdown,
|
|
6
|
+
B as BentoDropdownAvatar,
|
|
7
|
+
s as BentoDropdownCountry,
|
|
8
|
+
w as BentoDropdownCurrency,
|
|
9
|
+
t as BentoDropdownEvent,
|
|
10
|
+
p as BentoDropdownLazyLoadType,
|
|
11
|
+
D as BentoDropdownPaymentMethod,
|
|
12
|
+
r as BentoDropdownSize,
|
|
13
|
+
y as BentoDropdownTag
|
|
229
14
|
};
|
|
230
15
|
//# sourceMappingURL=dropdown.js.map
|
package/dist/dropdown.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"dropdown.js","sources":["../src/components/dropdown/components/variants/dropdown-avatar/dropdown-avatar.vue","../src/components/dropdown/components/variants/dropdown-country/dropdown-country.vue","../src/components/dropdown/components/variants/dropdown-currency/dropdown-currency.vue","../src/components/dropdown/components/variants/dropdown-payment-method/dropdown-payment-method.vue","../src/components/dropdown/components/variants/dropdown-tag/dropdown-tag.vue"],"sourcesContent":["<template>\n <div>\n <bento-dropdown v-slot=\"{ label, data }\" v-bind=\"$props\" :items=\"dropdownItems\" @input=\"onInput\">\n <bento-avatar :username=\"label\" :src=\"data\" />\n </bento-dropdown>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, defineComponent, PropType } from 'vue';\n import { BentoListboxSelectedValue } from '@/types';\n import { BentoAvatarListboxOptions } from './dropdown-avatar.types';\n import { BentoAvatar } from '@/internal';\n import BentoDropdown from '@/components/dropdown/dropdown.vue';\n\n const props = defineProps({\n ...BentoDropdown.props,\n /**\n * The option elements to populate the avatar dropdown with.\n * It must be an array of {@see BentoAvatarListboxOptions }\n * * @property {string} value.label - Text to be displayed in the option.\n * * @property {string,number} value.value - Value of the option.\n * * @property {string} value.src - Image source of the avatar image.\n */\n items: {\n type: Array as PropType<BentoAvatarListboxOptions>,\n default: () => [],\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an item is selected\n */\n (e: 'input', selectedValue: BentoListboxSelectedValue);\n }>();\n\n const onInput = (selectedValue: BentoListboxSelectedValue) => emit('input', selectedValue);\n\n const dropdownItems = computed(() => props.items.map(({ value, label, src }) => ({ value, label, data: src })));\n</script>\n\n<script lang=\"ts\">\n /**\n * A Avatar Dropdown showing a selectable list of countries.\n *\n * @example\n * import { BentoDropdownAvatar } from '@adyen/bento-vue2';\n * import type { BentoAvatarListboxOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdownAvatar },\n * template: `\n * <bento-dropdown-avatar\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :multiple=\"true\"\n * :isOptionsDisabled=\"option => option.value === 2\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref('user-id-1') // Default value\n * const options: BentoAvatarListboxOptions = [\n * { label: 'User 1', value: 'user-id-1' },\n * { label: 'User 2', value: 'user-id-2', src: 'image-source.jpeg' },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n name: 'bento-dropdown-avatar',\n });\n</script>\n","<template>\n <div>\n <bento-dropdown v-slot=\"{ label }\" v-bind=\"$props\" :items=\"countryItems\" @input=\"onInput\">\n <bento-typography el=\"span\">{{ label }}</bento-typography>\n </bento-dropdown>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { defineComponent, PropType, toRefs } from 'vue';\n import { BentoCountryListboxOptions } from './dropdown-country.types';\n import { BentoListboxSelectedValue } from '@/types';\n import { BentoTypography } from '@/components/typography';\n import { useCountryItems } from './composables/use-country-items';\n import { deprecate } from '@/utils/ts/deprecate';\n import { BentoCountryVariant } from '@/components/country';\n import BentoDropdown from '@/components/dropdown/dropdown.vue';\n\n const props = defineProps({\n ...BentoDropdown.props,\n /**\n * The option elements to populate the country dropdown with.\n * It must be an array of {@see BentoCountryListboxOptions }\n * * @deprecated {string} value.label - Use BentoDropdown instead of custom labels\n * * @property {BentoCountryCode | string} value.value - Country code of the option\n */\n items: {\n type: Array as PropType<BentoCountryListboxOptions>,\n default: () => [],\n },\n\n /**\n * Which label variant to display.\n * @values iso, name, phone_code, capital\n */\n variant: {\n type: String as PropType<BentoCountryVariant | `${BentoCountryVariant}`>,\n default: BentoCountryVariant.CUSTOM,\n validator: (value: BentoCountryVariant) => Object.values(BentoCountryVariant).includes(value),\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an item is selected\n */\n (e: 'input', selectedValue: BentoListboxSelectedValue);\n }>();\n\n const onInput = (selectedValue: BentoListboxSelectedValue) => emit('input', selectedValue);\n\n const { variant, items } = toRefs(props);\n const countryItems = useCountryItems(variant, items);\n\n if (variant.value === 'custom' || items.value.some(item => item.label)) {\n deprecate(\n 'BentoDropdownCountry \"custom\" variant and \"items\" prop \"label\" key',\n 'Use any of the other BentoDropdownCountry variants instead OR use BentoDropdown component for custom labels',\n '2.0.0'\n );\n }\n</script>\n\n<script lang=\"ts\">\n /**\n * A Country Dropdown showing a selectable list of countries.\n *\n * @example\n * import { BentoDropdownCountry, BentoCountryCode } from '@adyen/bento-vue2';\n * import type { BentoCountryListboxOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdown },\n * template: `\n * <bento-dropdown-country\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :multiple=\"true\"\n * :isOptionsDisabled=\"option => option.value === 2\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref(BentoCountryCode.NL) // Default value\n * const options: BentoCountryListboxOptions = [\n * { label: 'Option 1', value: BentoCountryCode.NL },\n * { label: 'Option 2', value: BentoCountryCode.BE },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n name: 'b-dropdown-country',\n });\n</script>\n","<template>\n <bento-dropdown v-slot=\"slotProps\" v-bind=\"$props\" @input=\"onInput\">\n <listbox-option-tag :option=\"slotProps\" />\n </bento-dropdown>\n</template>\n\n<script setup lang=\"ts\">\n import { defineComponent, PropType } from 'vue';\n import type { BentoCurrencyListboxOptions } from './dropdown-currency.types';\n import type { BentoListboxSelectedValue } from '@/types';\n import { ListboxOptionTag } from '@/internal';\n import BentoDropdown from '@/components/dropdown/dropdown.vue';\n\n defineProps({\n ...BentoDropdown.props,\n /**\n * The option elements to populate the country dropdown with.\n * It must be an array of {@see BentoCurrencyListboxOptions }\n * * @property {string} value.label - Text to be displayed in the option\n * * @property {BentoCurrencyISOCode} value.code - Currency ISO code of the option\n */\n items: {\n type: Array as PropType<BentoCurrencyListboxOptions>,\n default: () => [],\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an item is selected\n */\n (e: 'input', selectedValue: BentoListboxSelectedValue);\n }>();\n\n const onInput = (selectedValue: BentoListboxSelectedValue) => emit('input', selectedValue);\n</script>\n\n<script lang=\"ts\">\n /**\n * A Currency Dropdown showing a selectable list of currencies.\n *\n * @example\n * import { BentoDropdownCountry, BentoCountryCode } from '@adyen/bento-vue2';\n * import type { BentoCountryListboxOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdown },\n * template: `\n * <bento-dropdown-currency\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :multiple=\"true\"\n * :isOptionsDisabled=\"option => option.value === 2\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref(BentoCountryCode.NL) // Default value\n * const options: BentoCountryListboxOptions = [\n * { label: 'Option 1', value: BentoCountryCode.NL },\n * { label: 'Option 2', value: BentoCountryCode.BE },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n name: 'b-dropdown-currency',\n });\n</script>\n","<template>\n <div>\n <bento-dropdown v-slot=\"{ value, label }\" v-bind=\"$props\" @input=\"onInput\">\n <bento-payment-method :type=\"value\" :label=\"label\" />\n </bento-dropdown>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { defineComponent, PropType } from 'vue';\n import { BentoPaymentMethodListboxOptions } from './dropdown-payment-method.types';\n import { BentoListboxSelectedValue } from '@/types';\n import { BentoPaymentMethod } from '@/components/payment-method';\n import BentoDropdown from '@/components/dropdown/dropdown.vue';\n\n defineProps({\n ...BentoDropdown.props,\n /**\n * The option elements to populate the payment method dropdown with.\n * It must be an array of {@see BentoPaymentMethodListboxOptions }\n * * @property {string} value.label - Text to be displayed in the option\n * * @property {string} value.value - Payment type code that translates to a payment icon name {@see https://adyen-ui-assets.netlify.app/?path=/story/packages-ui-assets-payment-method-icons--icons}\n */\n items: {\n type: Array as PropType<BentoPaymentMethodListboxOptions>,\n default: () => [],\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an item is selected\n */\n (e: 'input', selectedValue: BentoListboxSelectedValue);\n }>();\n\n const onInput = (selectedValue: BentoListboxSelectedValue) => emit('input', selectedValue);\n</script>\n\n<script lang=\"ts\">\n /**\n * A Payment method Dropdown showing a selectable list of countries.\n *\n * @example\n * import { BentoDropdownPaymentMethod } from '@adyen/bento-vue2';\n * import type { BentoPaymentMethodListboxOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdownPaymentMethod },\n * template: `\n * <bento-dropdown-payment-method\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :multiple=\"true\"\n * :isOptionsDisabled=\"option => option.value === 'Visa'\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref('Ideal') // Default value\n * const options: BentoPaymentMethodListboxOptions = [\n * { label: 'Option 1', value: 'Ideal' },\n * { label: 'Option 2', value: 'Visa' },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n name: 'bento-dropdown-payment-method',\n });\n</script>\n","<template>\n <bento-dropdown\n v-slot=\"{ label, data }\"\n v-bind=\"$props\"\n class=\"b-dropdown-tag\"\n :items=\"tagItems\"\n show-slot-content-in-multiple\n @input=\"onInput\"\n >\n <listbox-option-tag :option=\"{ value: label, data, label: '' }\" />\n </bento-dropdown>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, defineComponent, PropType } from 'vue';\n import type { BentoTagListboxOptions } from './dropdown-tag.types';\n import type { BentoListboxSelectedValue } from '../../../../../types';\n import { ListboxOptionTag } from '../../../../internal';\n import BentoDropdown from '../../../dropdown.vue';\n\n const props = defineProps({\n ...BentoDropdown.props,\n /**\n * The option elements to populate the tag dropdown with.\n * It must be an array of {@see BentoTagListboxOptions }\n * * @property {string} value.label - Text to be displayed in the option\n * * @property {string,number} value.value - Value of the option\n * * @property {string} value.variant - The BentTag variant shown for the option.\n */\n items: {\n type: Array as PropType<BentoTagListboxOptions>,\n default: () => [],\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an item is selected\n */\n (e: 'input', selectedValue: BentoListboxSelectedValue);\n }>();\n\n const onInput = (selectedValue: BentoListboxSelectedValue) => emit('input', selectedValue);\n\n const tagItems = computed(() => props.items?.map(({ label, value, variant }) => ({ label, value, data: variant })));\n</script>\n\n<script lang=\"ts\">\n /**\n * A Tag Dropdown showing a selectable list of tags.\n *\n * @example\n * import { BentoDropdownTag } from '@adyen/bento-vue2';\n * import type { BentoTagListboxOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdownTag },\n * template: `\n * <bento-dropdown-tag\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref('unique-id-1') // Default value\n * const options: BentoTagListboxOptions = [\n * { label: 'Offline', value: 'unique-id-1', variant: 'red' },\n * { label: 'Online', value: 'unique-id-2', variant: 'green' },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n name: 'bento-dropdown-tag',\n });\n</script>\n\n<style lang=\"scss\" scoped src=\"./dropdown-tag.scss\" />\n"],"names":["__default__$4","defineComponent","onInput","selectedValue","emit","dropdownItems","computed","props","value","label","src","__default__$3","variant","items","toRefs","countryItems","useCountryItems","item","deprecate","__default__$2","__default__$1","__default__","tagItems","_a"],"mappings":";;;;;;;;;;;AAuEI,MAAAA,IAAAC,EAAA;AAAA,EAA+B,MAAA;AAE/B,CAAA;;;;;;;;;;;;;;;;;;iBApCAC,IAAA,CAAAC,MAAAC,EAAA,SAAAD,CAAA,GAEAE,IAAAC,EAAA,MAAAC,EAAA,MAAA,IAAA,CAAA,EAAA,OAAAC,GAAA,OAAAC,GAAA,KAAAC,EAAA,OAAA,EAAA,OAAAF,GAAA,OAAAC,GAAA,MAAAC,EAAA,EAAA,CAAA;;;;;;;;;;;;;;;;;;;sBCqDAC,IAAAV,EAAA;AAAA,EAA+B,MAAA;AAE/B,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;iBA7CAC,IAAA,CAAAC,MAAAC,EAAA,SAAAD,CAAA,GAEA,EAAA,SAAAS,GAAA,OAAAC,EAAA,IAAAC,EAAAP,CAAA,GACAQ,IAAAC,EAAAJ,GAAAC,CAAA;AAEA,YAAAD,EAAA,UAAA,YAAAC,EAAA,MAAA,KAAA,CAAAI,MAAAA,EAAA,KAAA,MACIC;AAAA,MAAA;AAAA,MACI;AAAA,MACA;AAAA,IACA;;;;;;;;;;;;;;;;;;sBCQRC,IAAAlB,EAAA;AAAA,EAA+B,MAAA;AAE/B,CAAA;;;;;;;;;;;;;;;;;0CAlCA,CAAAE,MAAAC,EAAA,SAAAD,CAAA;;;;;;;;;;;;;;;;;;sBCkCAiB,IAAAnB,EAAA;AAAA,EAA+B,MAAA;AAE/B,CAAA;;;;;;;;;;;;;;;;;0CAlCA,CAAAE,MAAAC,EAAA,SAAAD,CAAA;;;;;;;;;;;;;;;;;;sBCsCAkB,IAAApB,EAAA;AAAA,EAA+B,MAAA;AAE/B,CAAA;;;;;;;;;;;;;;;;;;iBAlCAC,IAAA,CAAAC,MAAAC,EAAA,SAAAD,CAAA,GAEAmB,IAAAhB,EAAA,MAAA;;AAAA,cAAAiB,IAAAhB,EAAA,UAAA,gBAAAgB,EAAA,IAAA,CAAA,EAAA,OAAAd,GAAA,OAAAD,GAAA,SAAAI,EAAA,OAAA,EAAA,OAAAH,GAAA,OAAAD,GAAA,MAAAI,EAAA;AAAA,KAAA;;;;;;;;;;;;;;;;;;;;"}
|
|
1
|
+
{"version":3,"file":"dropdown.js","sources":[],"sourcesContent":[],"names":[],"mappings":";;;"}
|