@adyen/bento-vue3 1.68.2 → 1.69.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 +1 -0
- package/dist/@types/index.d.ts +752 -1177
- package/dist/accordion.js +1 -1
- package/dist/action-bar.js +1 -1
- package/dist/alert.js +1 -1
- package/dist/assets/accordion-item.css +1 -1
- package/dist/assets/action-bar.css +1 -1
- package/dist/assets/base-button.css +1 -1
- package/dist/assets/base-modal.css +1 -1
- package/dist/assets/button-actions-with-menu.css +1 -1
- package/dist/assets/button.css +1 -1
- package/dist/assets/calendar.css +1 -1
- package/dist/assets/card.css +1 -1
- package/dist/assets/checkbox-group.css +1 -1
- package/dist/assets/checkbox-input.css +1 -1
- package/dist/assets/checkbox.css +1 -1
- package/dist/assets/chip.css +1 -1
- package/dist/assets/copy.css +1 -1
- package/dist/assets/country.css +1 -1
- package/dist/assets/currency.css +1 -1
- package/dist/assets/dashed-underline.css +1 -1
- package/dist/assets/data-grid-template.css +1 -1
- package/dist/assets/data-grid.css +1 -1
- package/dist/assets/date-picker.css +1 -1
- package/dist/assets/date-range-picker.css +1 -1
- package/dist/assets/dialog-page.css +1 -1
- package/dist/assets/divider.css +1 -1
- package/dist/assets/dropdown-default-textbox.css +1 -1
- package/dist/assets/dropdown-tag.css +1 -1
- package/dist/assets/dropdown.css +1 -1
- package/dist/assets/empty-state.css +1 -1
- package/dist/assets/file-uploader.css +1 -1
- package/dist/assets/filter-bar.css +1 -1
- package/dist/assets/focus-trap.css +1 -1
- package/dist/assets/footer-actions.css +1 -1
- package/dist/assets/form-layout-title.css +1 -1
- package/dist/assets/grid-layout.css +1 -1
- package/dist/assets/header-meta.css +1 -1
- package/dist/assets/header-with-views.css +1 -1
- package/dist/assets/header.css +1 -1
- package/dist/assets/info-icon.css +1 -1
- package/dist/assets/input-field-password.css +1 -1
- package/dist/assets/input-field-phone-number.css +1 -1
- package/dist/assets/input-field.css +1 -1
- package/dist/assets/inspector.css +1 -1
- package/dist/assets/layout-row.css +1 -1
- package/dist/assets/listbox-option-tag.css +1 -1
- package/dist/assets/loading-indicator.css +1 -1
- package/dist/assets/modal-fullscreen.css +1 -1
- package/dist/assets/pagination.css +1 -1
- package/dist/assets/payment-method.css +1 -1
- package/dist/assets/popper-container.css +1 -1
- package/dist/assets/promo-banner.css +1 -1
- package/dist/assets/radio-group.css +1 -1
- package/dist/assets/radio-input.css +1 -1
- package/dist/assets/rich-text-editor.css +1 -1
- package/dist/assets/search-bar.css +1 -1
- package/dist/assets/secondary-nav.css +1 -1
- package/dist/assets/segmented-control.css +1 -1
- package/dist/assets/selection-card-group.css +1 -1
- package/dist/assets/sidepanel.css +1 -1
- package/dist/assets/status.css +1 -1
- package/dist/assets/step.css +1 -1
- package/dist/assets/structured-list-item.css +1 -1
- package/dist/assets/tab.css +1 -1
- package/dist/assets/tag.css +1 -1
- package/dist/assets/textarea.css +1 -1
- package/dist/assets/timeline-item.css +1 -1
- package/dist/assets/toast.css +1 -1
- package/dist/assets/toggle-button.css +1 -1
- package/dist/assets/toggle.css +1 -1
- package/dist/assets/tooltip.css +1 -1
- package/dist/assets/tutorial.css +1 -1
- package/dist/assets/typography.css +1 -1
- package/dist/assets/use-cached-selected-values.css +1 -1
- package/dist/avatar.js +1 -1
- package/dist/button.js +9 -9
- package/dist/card.js +1 -1
- package/dist/checkbox.js +2 -2
- package/dist/chip.js +1 -1
- package/dist/chunks/{accordion-item.DOnW0OnU.js → accordion-item.H062lKz1.js} +3 -3
- package/dist/chunks/accordion-item.H062lKz1.js.map +1 -0
- package/dist/chunks/{action-bar.CflF49oL.js → action-bar.CbO7oNER.js} +7 -8
- package/dist/chunks/action-bar.CbO7oNER.js.map +1 -0
- package/dist/chunks/{alert.DvleqX0i.js → alert.DFSdD4jX.js} +3 -3
- package/dist/chunks/{alert.DvleqX0i.js.map → alert.DFSdD4jX.js.map} +1 -1
- package/dist/chunks/aria-label.CaUURpnB.js.map +1 -1
- package/dist/chunks/{avatar.B0-9jC6H.js → avatar.BtxoYBvq.js} +2 -2
- package/dist/chunks/avatar.BtxoYBvq.js.map +1 -0
- package/dist/chunks/{base-button.DdNFlbgH.js → base-button.Bcwm87OM.js} +19 -19
- package/dist/chunks/base-button.Bcwm87OM.js.map +1 -0
- package/dist/chunks/{base-modal.C3_r3rmc.js → base-modal.7vdoT8zp.js} +21 -21
- package/dist/chunks/base-modal.7vdoT8zp.js.map +1 -0
- package/dist/chunks/button-actions-with-menu.zdsGh7un.js +93 -0
- package/dist/chunks/button-actions-with-menu.zdsGh7un.js.map +1 -0
- package/dist/chunks/button-actions.types.BptAXjD8.js +8 -0
- package/dist/chunks/button-actions.types.BptAXjD8.js.map +1 -0
- package/dist/chunks/{button.AB0SOQMn.js → button.wMNce6wZ.js} +4 -4
- package/dist/chunks/button.wMNce6wZ.js.map +1 -0
- package/dist/chunks/{calendar._oPk_A1C.js → calendar.CYrrR8wd.js} +10 -11
- package/dist/chunks/calendar.CYrrR8wd.js.map +1 -0
- package/dist/chunks/{card.CS34Mi_G.js → card.CNYYIpQW.js} +6 -5
- package/dist/chunks/card.CNYYIpQW.js.map +1 -0
- package/dist/chunks/{checkbox-group.JRo6xNpe.js → checkbox-group.fX5_d3XZ.js} +6 -6
- package/dist/chunks/checkbox-group.fX5_d3XZ.js.map +1 -0
- package/dist/chunks/{checkbox-input.DFkwZ4GM.js → checkbox-input.B1hV3DU-.js} +2 -2
- package/dist/chunks/checkbox-input.B1hV3DU-.js.map +1 -0
- package/dist/chunks/{checkbox.DGrG3GN1.js → checkbox.C62ek8A8.js} +27 -27
- package/dist/chunks/checkbox.C62ek8A8.js.map +1 -0
- package/dist/chunks/{chip.CneNX2_j.js → chip.CoBGGkn7.js} +11 -11
- package/dist/chunks/chip.CoBGGkn7.js.map +1 -0
- package/dist/chunks/{code-snippet.D5M76Qy6.js → code-snippet.CrKl93Wq.js} +8 -8
- package/dist/chunks/code-snippet.CrKl93Wq.js.map +1 -0
- package/dist/chunks/{controls-group.CrzkSu0U.js → controls-group.2xftPPd7.js} +3 -3
- package/dist/chunks/{controls-group.CrzkSu0U.js.map → controls-group.2xftPPd7.js.map} +1 -1
- package/dist/chunks/{copy.RUoQOydT.js → copy.-8xjj6Hr.js} +17 -18
- package/dist/chunks/copy.-8xjj6Hr.js.map +1 -0
- package/dist/chunks/{country.Q95voxeL.js → country.BdqTkF7A.js} +8 -8
- package/dist/chunks/country.BdqTkF7A.js.map +1 -0
- package/dist/chunks/country.types.C0Q_hhgJ.js.map +1 -1
- package/dist/chunks/{currency.CZVdyZUH.js → currency.XiEfa4LT.js} +3 -3
- package/dist/chunks/currency.XiEfa4LT.js.map +1 -0
- package/dist/chunks/{dashboard-section.Bhd5Lsy2.js → dashboard-section.Di16gWGI.js} +4 -4
- package/dist/chunks/{dashboard-section.Bhd5Lsy2.js.map → dashboard-section.Di16gWGI.js.map} +1 -1
- package/dist/chunks/{dashed-underline.DkzQkpaf.js → dashed-underline.CyZEW1LZ.js} +30 -32
- package/dist/chunks/dashed-underline.CyZEW1LZ.js.map +1 -0
- package/dist/chunks/{data-grid-template.DSwj7e1E.js → data-grid-template.CnYNEhPR.js} +5 -5
- package/dist/chunks/data-grid-template.CnYNEhPR.js.map +1 -0
- package/dist/chunks/{data-grid.BEdELRNZ.js → data-grid.aEQt05d9.js} +1626 -1554
- package/dist/chunks/data-grid.aEQt05d9.js.map +1 -0
- package/dist/chunks/{date-picker.CAoXTiZR.js → date-picker.Bk0A3rha.js} +25 -26
- package/dist/chunks/date-picker.Bk0A3rha.js.map +1 -0
- package/dist/chunks/date-range-picker.l-CSmXBk.js +1168 -0
- package/dist/chunks/date-range-picker.l-CSmXBk.js.map +1 -0
- package/dist/chunks/{date.DSjCnSgL.js → date.BZENjOb6.js} +2 -2
- package/dist/chunks/{date.DSjCnSgL.js.map → date.BZENjOb6.js.map} +1 -1
- package/dist/chunks/{dialog-page.C80HOigq.js → dialog-page.BJaRwRhF.js} +15 -15
- package/dist/chunks/dialog-page.BJaRwRhF.js.map +1 -0
- package/dist/chunks/{divider.qUOSAbU6.js → divider.DnKNNyWB.js} +2 -2
- package/dist/chunks/divider.DnKNNyWB.js.map +1 -0
- package/dist/chunks/{dropdown-default-textbox.Ce5D3ipi.js → dropdown-default-textbox.DWgL31p1.js} +111 -109
- package/dist/chunks/dropdown-default-textbox.DWgL31p1.js.map +1 -0
- package/dist/chunks/dropdown-tag.CnqIUH1X.js +263 -0
- package/dist/chunks/dropdown-tag.CnqIUH1X.js.map +1 -0
- package/dist/chunks/{dropdown.CMOYmQLB.js → dropdown.Co86azLK.js} +71 -71
- package/dist/chunks/dropdown.Co86azLK.js.map +1 -0
- package/dist/chunks/{empty-state.D7llINgF.js → empty-state.YNNEDsnK.js} +4 -4
- package/dist/chunks/empty-state.YNNEDsnK.js.map +1 -0
- package/dist/chunks/{error-message.DHMHq9bR.js → error-message.Cu4cIfdg.js} +3 -3
- package/dist/chunks/{error-message.DHMHq9bR.js.map → error-message.Cu4cIfdg.js.map} +1 -1
- package/dist/chunks/es6.MoTTyETW.js +12 -0
- package/dist/chunks/es6.MoTTyETW.js.map +1 -0
- package/dist/chunks/events.CMzGybJJ.js +47 -0
- package/dist/chunks/events.CMzGybJJ.js.map +1 -0
- package/dist/chunks/{file-uploader.B_EI2fAc.js → file-uploader.09149Fx8.js} +153 -154
- package/dist/chunks/file-uploader.09149Fx8.js.map +1 -0
- package/dist/chunks/{filter-bar.DoHMLZ4O.js → filter-bar.D6n7Srr5.js} +215 -219
- package/dist/chunks/filter-bar.D6n7Srr5.js.map +1 -0
- package/dist/chunks/{fixed-scroller.D5nAPPbo.js → fixed-scroller.QlDKOD7y.js} +2 -2
- package/dist/chunks/{fixed-scroller.D5nAPPbo.js.map → fixed-scroller.QlDKOD7y.js.map} +1 -1
- package/dist/chunks/{focus-trap.CljZgv9i.js → focus-trap.rjp24a37.js} +2 -2
- package/dist/chunks/focus-trap.rjp24a37.js.map +1 -0
- package/dist/chunks/{footer-actions.Bje-DDqw.js → footer-actions.0cBTJ1kw.js} +5 -5
- package/dist/chunks/footer-actions.0cBTJ1kw.js.map +1 -0
- package/dist/chunks/{form-layout-title.rpIO-I9A.js → form-layout-title.Cq_xVPUq.js} +5 -5
- package/dist/chunks/form-layout-title.Cq_xVPUq.js.map +1 -0
- package/dist/chunks/{grid-layout.BTLE3rac.js → grid-layout.DDaRNz4-.js} +2 -2
- package/dist/chunks/grid-layout.DDaRNz4-.js.map +1 -0
- package/dist/chunks/{header-meta.Yt43-cUI.js → header-meta.BJGF0E3r.js} +26 -27
- package/dist/chunks/{header-meta.Yt43-cUI.js.map → header-meta.BJGF0E3r.js.map} +1 -1
- package/dist/chunks/{header-with-views.BUed3ocZ.js → header-with-views.Drzq84zs.js} +99 -103
- package/dist/chunks/header-with-views.Drzq84zs.js.map +1 -0
- package/dist/chunks/{header.CwKjDgKv.js → header.B6DzOioR.js} +32 -32
- package/dist/chunks/header.B6DzOioR.js.map +1 -0
- package/dist/chunks/image.vue_vue_type_script_setup_true_lang.DQT2oNEF.js.map +1 -1
- package/dist/chunks/{info-icon.DprUQ9fj.js → info-icon.DKnzFXy1.js} +8 -9
- package/dist/chunks/info-icon.DKnzFXy1.js.map +1 -0
- package/dist/chunks/{input-field-password.DN0Jro1V.js → input-field-password.DC8lJFsr.js} +8 -8
- package/dist/chunks/input-field-password.DC8lJFsr.js.map +1 -0
- package/dist/chunks/{input-field-phone-number.BhPsrafR.js → input-field-phone-number.BbMEzDiR.js} +42 -41
- package/dist/chunks/{input-field-phone-number.BhPsrafR.js.map → input-field-phone-number.BbMEzDiR.js.map} +1 -1
- package/dist/chunks/{input-field.su5Cq8Dt.js → input-field.6bH4yGb2.js} +5 -5
- package/dist/chunks/input-field.6bH4yGb2.js.map +1 -0
- package/dist/chunks/{inspector.CoZCPfHC.js → inspector.Bsv68G-e.js} +13 -13
- package/dist/chunks/inspector.Bsv68G-e.js.map +1 -0
- package/dist/chunks/{keyboard-navigation.CqgGzfZQ.js → keyboard-navigation.pB8weElW.js} +2 -2
- package/dist/chunks/keyboard-navigation.pB8weElW.js.map +1 -0
- package/dist/chunks/{layout-row.CZNtHaXd.js → layout-row.CIg1pwOd.js} +9 -9
- package/dist/chunks/layout-row.CIg1pwOd.js.map +1 -0
- package/dist/chunks/{link.BBpxiclu.js → link.Di0rtpOj.js} +2 -2
- package/dist/chunks/{link.BBpxiclu.js.map → link.Di0rtpOj.js.map} +1 -1
- package/dist/chunks/{listbox-option-tag.0BK6jWO9.js → listbox-option-tag.C6WHiASI.js} +7 -7
- package/dist/chunks/listbox-option-tag.C6WHiASI.js.map +1 -0
- package/dist/chunks/{loading-indicator.DEepb9Wl.js → loading-indicator.BmAQqPP2.js} +3 -3
- package/dist/chunks/loading-indicator.BmAQqPP2.js.map +1 -0
- package/dist/chunks/minus-small.DYIyF5XW.js.map +1 -1
- package/dist/chunks/{modal-fullscreen.DBTnoSX9.js → modal-fullscreen.BHzyS4y7.js} +18 -19
- package/dist/chunks/modal-fullscreen.BHzyS4y7.js.map +1 -0
- package/dist/chunks/{modal.vue_vue_type_script_setup_true_lang.Cd-mQUJ8.js → modal.vue_vue_type_script_setup_true_lang.CqDhzFJ9.js} +6 -6
- package/dist/chunks/modal.vue_vue_type_script_setup_true_lang.CqDhzFJ9.js.map +1 -0
- package/dist/chunks/{pagination.fYQak4C8.js → pagination.BuYH2_62.js} +5 -5
- package/dist/chunks/pagination.BuYH2_62.js.map +1 -0
- package/dist/chunks/{payment-method.eazefwm6.js → payment-method.4cnK2M5b.js} +3 -3
- package/dist/chunks/payment-method.4cnK2M5b.js.map +1 -0
- package/dist/chunks/popover.types.BQILgzhs.js +6 -0
- package/dist/chunks/popover.types.BQILgzhs.js.map +1 -0
- package/dist/chunks/{popper-container.b5h4zYgT.js → popper-container.idDrquM6.js} +285 -281
- package/dist/chunks/popper-container.idDrquM6.js.map +1 -0
- package/dist/chunks/{promo-banner.CQp3z2CP.js → promo-banner.il4_mdEk.js} +4 -4
- package/dist/chunks/promo-banner.il4_mdEk.js.map +1 -0
- package/dist/chunks/{radio-group.H9A5QcNu.js → radio-group.BG8W9epW.js} +8 -8
- package/dist/chunks/radio-group.BG8W9epW.js.map +1 -0
- package/dist/chunks/{radio-input.DKfQGxtp.js → radio-input.DvPjlvPm.js} +2 -2
- package/dist/chunks/radio-input.DvPjlvPm.js.map +1 -0
- package/dist/chunks/{rich-text-editor.Dx78coVL.js → rich-text-editor.vqti0Ls0.js} +8 -8
- package/dist/chunks/rich-text-editor.vqti0Ls0.js.map +1 -0
- package/dist/chunks/{search-bar.CUrcP_wf.js → search-bar.RGL70u_Y.js} +46 -44
- package/dist/chunks/search-bar.RGL70u_Y.js.map +1 -0
- package/dist/chunks/{secondary-nav.j3ddtYoZ.js → secondary-nav.Dtw_Dm_X.js} +28 -28
- package/dist/chunks/secondary-nav.Dtw_Dm_X.js.map +1 -0
- package/dist/chunks/{segmented-control.5-vlm8Gt.js → segmented-control.C6QyN2jS.js} +6 -7
- package/dist/chunks/segmented-control.C6QyN2jS.js.map +1 -0
- package/dist/chunks/{selection-card-group.B4xpnd-z.js → selection-card-group.DpogJSo0.js} +16 -16
- package/dist/chunks/selection-card-group.DpogJSo0.js.map +1 -0
- package/dist/chunks/{sidepanel.DPN__L3Q.js → sidepanel.BqRWoCd3.js} +14 -14
- package/dist/chunks/sidepanel.BqRWoCd3.js.map +1 -0
- package/dist/chunks/{status.types.Bdv2zuuh.js → status.types.B7vJ-_oJ.js} +9 -9
- package/dist/chunks/status.types.B7vJ-_oJ.js.map +1 -0
- package/dist/chunks/{step.BtNhPZAf.js → step.BdZrreHU.js} +8 -9
- package/dist/chunks/step.BdZrreHU.js.map +1 -0
- package/dist/chunks/{structured-list-item.BQbEDKhg.js → structured-list-item.DIwkcIMT.js} +18 -19
- package/dist/chunks/structured-list-item.DIwkcIMT.js.map +1 -0
- package/dist/chunks/{summary-grid.types.CjbbSZBJ.js → summary-grid.types.DHUnTXI-.js} +7 -7
- package/dist/chunks/{summary-grid.types.CjbbSZBJ.js.map → summary-grid.types.DHUnTXI-.js.map} +1 -1
- package/dist/chunks/{tab.CAt51ksU.js → tab.jIG8-7-Q.js} +5 -5
- package/dist/chunks/tab.jIG8-7-Q.js.map +1 -0
- package/dist/chunks/{tag.D3in0-Bp.js → tag.BP8fBCx-.js} +9 -10
- package/dist/chunks/tag.BP8fBCx-.js.map +1 -0
- package/dist/chunks/textarea.CtfRoIUw.js +295 -0
- package/dist/chunks/textarea.CtfRoIUw.js.map +1 -0
- package/dist/chunks/{timeline-item.CuCII37W.js → timeline-item.DthjD14m.js} +11 -11
- package/dist/chunks/timeline-item.DthjD14m.js.map +1 -0
- package/dist/chunks/{toast.CSoCPteL.js → toast.w_FD0zQA.js} +18 -18
- package/dist/chunks/toast.w_FD0zQA.js.map +1 -0
- package/dist/chunks/toggle-button.ByyLw0Yf.js +1347 -0
- package/dist/chunks/toggle-button.ByyLw0Yf.js.map +1 -0
- package/dist/chunks/{toggle.BuKXexA6.js → toggle.CjEL1ko8.js} +3 -3
- package/dist/chunks/toggle.CjEL1ko8.js.map +1 -0
- package/dist/chunks/{tooltip.VYPUHERk.js → tooltip.Dww8NiUR.js} +70 -64
- package/dist/chunks/tooltip.Dww8NiUR.js.map +1 -0
- package/dist/chunks/{tutorial.vue_vue_type_script_setup_true_lang.Dmf8fGaM.js → tutorial.vue_vue_type_script_setup_true_lang.rY33hqQQ.js} +48 -51
- package/dist/chunks/tutorial.vue_vue_type_script_setup_true_lang.rY33hqQQ.js.map +1 -0
- package/dist/chunks/{typography.DN5eC5ch.js → typography.CFHvBR7L.js} +25 -25
- package/dist/chunks/typography.CFHvBR7L.js.map +1 -0
- package/dist/chunks/{use-bento-toast-controller.D3LA1FCd.js → use-bento-toast-controller.BzKbXZPO.js} +2 -2
- package/dist/chunks/{use-bento-toast-controller.D3LA1FCd.js.map → use-bento-toast-controller.BzKbXZPO.js.map} +1 -1
- package/dist/chunks/{use-cached-selected-values.Dyoz6cUK.js → use-cached-selected-values.BcNRo4mZ.js} +16 -17
- package/dist/chunks/use-cached-selected-values.BcNRo4mZ.js.map +1 -0
- package/dist/chunks/use-country-items.Duh4bMqW.js.map +1 -1
- package/dist/chunks/use-country-phon-code.BOaJ9PDl.js.map +1 -1
- package/dist/chunks/use-has-slot.B7eQSabc.js.map +1 -1
- package/dist/code-snippet.js +1 -1
- package/dist/country.js +1 -1
- package/dist/currency.js +1 -1
- package/dist/dashboard-template.js +1 -1
- package/dist/dashed-underline.js +1 -1
- package/dist/data-grid-template.js +1 -1
- package/dist/data-grid.js +1 -1
- package/dist/date-picker.js +2 -2
- package/dist/date-range-picker.js +2 -2
- package/dist/date.js +1 -1
- package/dist/divider.js +1 -1
- package/dist/dropdown.js +4 -4
- package/dist/empty-state.js +1 -1
- package/dist/file-uploader.js +1 -1
- package/dist/filter-bar.js +1 -1
- package/dist/focus-trap.js +1 -1
- package/dist/form-layout.js +1 -1
- package/dist/header-with-views.js +1 -1
- package/dist/header.js +1 -1
- package/dist/index.js +204 -207
- package/dist/index.js.map +1 -1
- package/dist/info-icon.js +1 -1
- package/dist/input-field-password.js +1 -1
- package/dist/input-field-phone-number.js +3 -2
- package/dist/input-field.js +1 -1
- package/dist/inspector.js +1 -1
- package/dist/internal.js +33 -32
- package/dist/internal.js.map +1 -1
- package/dist/layout.js +1 -1
- package/dist/link.js +1 -1
- package/dist/loading-indicator.js +1 -1
- package/dist/menu.js +1 -1
- package/dist/modal-fullscreen.js +1 -1
- package/dist/modal.js +2 -2
- package/dist/pagination.js +1 -1
- package/dist/payment-method.js +1 -1
- package/dist/popover.js +2 -2
- package/dist/popper-container.js +4 -5
- package/dist/popper-container.js.map +1 -1
- package/dist/promo-banner.js +1 -1
- package/dist/radio-group.js +2 -2
- package/dist/rich-text-editor.js +1 -1
- package/dist/search-bar.js +2 -2
- package/dist/secondary-nav.js +1 -1
- package/dist/segmented-control.js +1 -1
- package/dist/selection-card.js +1 -1
- package/dist/sidepanel.js +1 -1
- package/dist/status.js +1 -1
- package/dist/stepper.js +1 -1
- package/dist/structured-list.js +1 -1
- package/dist/styles/bento-dark.css +17 -4
- package/dist/styles/bento-light.css +17 -4
- package/dist/styles/bento.css +17 -4
- package/dist/styles/legacy.css +17 -4
- package/dist/styles/styleguide.css +17 -4
- package/dist/styles/utility.css +3 -0
- package/dist/summary-grid.js +1 -1
- package/dist/tabs.js +1 -1
- package/dist/tag.js +1 -1
- package/dist/textarea.js +1 -1
- package/dist/timeline.js +1 -1
- package/dist/toast.js +1 -1
- package/dist/toggle.js +1 -1
- package/dist/tutorial.js +1 -1
- package/dist/typography.js +1 -1
- package/dist/use-form-v4.js.map +1 -1
- package/dist/web-types.json +1 -1
- package/package.json +6 -6
- package/dist/assets/button-actions.css +0 -1
- package/dist/assets/menu.css +0 -1
- package/dist/assets/popover.css +0 -1
- package/dist/assets/teleport.css +0 -1
- package/dist/chunks/accordion-item.DOnW0OnU.js.map +0 -1
- package/dist/chunks/action-bar.CflF49oL.js.map +0 -1
- package/dist/chunks/avatar.B0-9jC6H.js.map +0 -1
- package/dist/chunks/base-button.DdNFlbgH.js.map +0 -1
- package/dist/chunks/base-modal.C3_r3rmc.js.map +0 -1
- package/dist/chunks/base-modal.keys.C2PQXcE2.js +0 -5
- package/dist/chunks/base-modal.keys.C2PQXcE2.js.map +0 -1
- package/dist/chunks/button-actions-with-menu.8ZYh7-9s.js +0 -91
- package/dist/chunks/button-actions-with-menu.8ZYh7-9s.js.map +0 -1
- package/dist/chunks/button-actions.CZdO9YOk.js +0 -264
- package/dist/chunks/button-actions.CZdO9YOk.js.map +0 -1
- package/dist/chunks/button.AB0SOQMn.js.map +0 -1
- package/dist/chunks/calendar._oPk_A1C.js.map +0 -1
- package/dist/chunks/card.CS34Mi_G.js.map +0 -1
- package/dist/chunks/checkbox-group.JRo6xNpe.js.map +0 -1
- package/dist/chunks/checkbox-input.DFkwZ4GM.js.map +0 -1
- package/dist/chunks/checkbox.DGrG3GN1.js.map +0 -1
- package/dist/chunks/chip.CneNX2_j.js.map +0 -1
- package/dist/chunks/code-snippet.D5M76Qy6.js.map +0 -1
- package/dist/chunks/copy.RUoQOydT.js.map +0 -1
- package/dist/chunks/country.Q95voxeL.js.map +0 -1
- package/dist/chunks/currency.CZVdyZUH.js.map +0 -1
- package/dist/chunks/dashed-underline.DkzQkpaf.js.map +0 -1
- package/dist/chunks/data-grid-template.DSwj7e1E.js.map +0 -1
- package/dist/chunks/data-grid.BEdELRNZ.js.map +0 -1
- package/dist/chunks/date-picker.CAoXTiZR.js.map +0 -1
- package/dist/chunks/date-range-picker.DtV4L3L6.js +0 -1225
- package/dist/chunks/date-range-picker.DtV4L3L6.js.map +0 -1
- package/dist/chunks/dialog-page.C80HOigq.js.map +0 -1
- package/dist/chunks/divider.qUOSAbU6.js.map +0 -1
- package/dist/chunks/dropdown-default-textbox.Ce5D3ipi.js.map +0 -1
- package/dist/chunks/dropdown-tag.B3fptORX.js +0 -230
- package/dist/chunks/dropdown-tag.B3fptORX.js.map +0 -1
- package/dist/chunks/dropdown.CMOYmQLB.js.map +0 -1
- package/dist/chunks/empty-state.D7llINgF.js.map +0 -1
- package/dist/chunks/es6.n1ewaW31.js +0 -11
- package/dist/chunks/es6.n1ewaW31.js.map +0 -1
- package/dist/chunks/events.FNmSWp_P.js +0 -52
- package/dist/chunks/events.FNmSWp_P.js.map +0 -1
- package/dist/chunks/file-uploader.B_EI2fAc.js.map +0 -1
- package/dist/chunks/filter-bar.DoHMLZ4O.js.map +0 -1
- package/dist/chunks/focus-trap.CljZgv9i.js.map +0 -1
- package/dist/chunks/footer-actions.Bje-DDqw.js.map +0 -1
- package/dist/chunks/form-layout-title.rpIO-I9A.js.map +0 -1
- package/dist/chunks/grid-layout.BTLE3rac.js.map +0 -1
- package/dist/chunks/header-with-views.BUed3ocZ.js.map +0 -1
- package/dist/chunks/header.CwKjDgKv.js.map +0 -1
- package/dist/chunks/info-icon.DprUQ9fj.js.map +0 -1
- package/dist/chunks/input-field-password.DN0Jro1V.js.map +0 -1
- package/dist/chunks/input-field.su5Cq8Dt.js.map +0 -1
- package/dist/chunks/inspector.CoZCPfHC.js.map +0 -1
- package/dist/chunks/keyboard-navigation.CqgGzfZQ.js.map +0 -1
- package/dist/chunks/layout-row.CZNtHaXd.js.map +0 -1
- package/dist/chunks/listbox-option-tag.0BK6jWO9.js.map +0 -1
- package/dist/chunks/loading-indicator.DEepb9Wl.js.map +0 -1
- package/dist/chunks/menu.EtjeOPXX.js +0 -680
- package/dist/chunks/menu.EtjeOPXX.js.map +0 -1
- package/dist/chunks/modal-fullscreen.DBTnoSX9.js.map +0 -1
- package/dist/chunks/modal-fullscreen.keys.CMba3hYp.js +0 -5
- package/dist/chunks/modal-fullscreen.keys.CMba3hYp.js.map +0 -1
- package/dist/chunks/modal.vue_vue_type_script_setup_true_lang.Cd-mQUJ8.js.map +0 -1
- package/dist/chunks/pagination.fYQak4C8.js.map +0 -1
- package/dist/chunks/payment-method.eazefwm6.js.map +0 -1
- package/dist/chunks/popover.DYgCCUCJ.js +0 -200
- package/dist/chunks/popover.DYgCCUCJ.js.map +0 -1
- package/dist/chunks/popover.types.V8old-GW.js +0 -6
- package/dist/chunks/popover.types.V8old-GW.js.map +0 -1
- package/dist/chunks/popper-container.b5h4zYgT.js.map +0 -1
- package/dist/chunks/popper-container.types.BCZMbVFD.js +0 -9
- package/dist/chunks/popper-container.types.BCZMbVFD.js.map +0 -1
- package/dist/chunks/promo-banner.CQp3z2CP.js.map +0 -1
- package/dist/chunks/radio-group.H9A5QcNu.js.map +0 -1
- package/dist/chunks/radio-input.DKfQGxtp.js.map +0 -1
- package/dist/chunks/rich-text-editor.Dx78coVL.js.map +0 -1
- package/dist/chunks/search-bar.CUrcP_wf.js.map +0 -1
- package/dist/chunks/secondary-nav.j3ddtYoZ.js.map +0 -1
- package/dist/chunks/segmented-control.5-vlm8Gt.js.map +0 -1
- package/dist/chunks/selection-card-group.B4xpnd-z.js.map +0 -1
- package/dist/chunks/sidepanel.DPN__L3Q.js.map +0 -1
- package/dist/chunks/sidepanel.keys.R0DKQuYx.js +0 -5
- package/dist/chunks/sidepanel.keys.R0DKQuYx.js.map +0 -1
- package/dist/chunks/status.types.Bdv2zuuh.js.map +0 -1
- package/dist/chunks/step.BtNhPZAf.js.map +0 -1
- package/dist/chunks/structured-list-item.BQbEDKhg.js.map +0 -1
- package/dist/chunks/tab.CAt51ksU.js.map +0 -1
- package/dist/chunks/tag.D3in0-Bp.js.map +0 -1
- package/dist/chunks/teleport.CfGWjxe2.js +0 -129
- package/dist/chunks/teleport.CfGWjxe2.js.map +0 -1
- package/dist/chunks/textarea.BBhN67-I.js +0 -282
- package/dist/chunks/textarea.BBhN67-I.js.map +0 -1
- package/dist/chunks/timeline-item.CuCII37W.js.map +0 -1
- package/dist/chunks/toast.CSoCPteL.js.map +0 -1
- package/dist/chunks/toggle-button.NQwrfSr1.js +0 -80
- package/dist/chunks/toggle-button.NQwrfSr1.js.map +0 -1
- package/dist/chunks/toggle.BuKXexA6.js.map +0 -1
- package/dist/chunks/tooltip.VYPUHERk.js.map +0 -1
- package/dist/chunks/tutorial.vue_vue_type_script_setup_true_lang.Dmf8fGaM.js.map +0 -1
- package/dist/chunks/typography.DN5eC5ch.js.map +0 -1
- package/dist/chunks/use-cached-selected-values.Dyoz6cUK.js.map +0 -1
- package/dist/chunks/use-click-outside.BnhTgpSt.js +0 -14
- package/dist/chunks/use-click-outside.BnhTgpSt.js.map +0 -1
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { defineComponent as ye, useAttrs as me, useSlots as we, ref as D, provide as _e, inject as J, toRef as De, computed as d, toRefs as he, createBlock as u, openBlock as n, unref as a, normalizeClass as Ee, withCtx as c, createCommentVNode as i, createElementVNode as I, createElementBlock as b, renderSlot as p, withModifiers as j, mergeProps as P, withKeys as Te, createTextVNode as Ne, toDisplayString as ke, createVNode as Ae } from "vue";
|
|
2
|
-
import { a as ge, I as Le, b as Oe, B as z } from "./dropdown.
|
|
3
|
-
import { p as R, d as X, B as h } from "./typography.
|
|
2
|
+
import { a as ge, I as Le, b as Oe, B as z } from "./dropdown.Co86azLK.js";
|
|
3
|
+
import { p as R, d as X, B as h } from "./typography.CFHvBR7L.js";
|
|
4
4
|
import { g as E } from "./generate-uid.NJ8tVoha.js";
|
|
5
5
|
import { g as Se } from "./get-slot-text.DQlZEsId.js";
|
|
6
6
|
import { u as Ie } from "./aria-label.CaUURpnB.js";
|
|
7
7
|
import { u as Pe } from "./i18n.B6g5VX0q.js";
|
|
8
8
|
import { u as Re } from "./use-form-layout-loading.D3lALhtC.js";
|
|
9
9
|
import { u as Ce } from "./use-has-slot.B7eQSabc.js";
|
|
10
|
-
import { F as $e, E as Be } from "./error-message.
|
|
10
|
+
import { F as $e, E as Be } from "./error-message.Cu4cIfdg.js";
|
|
11
11
|
import { _ as Me } from "./_plugin-vue_export-helper.CHgC5LLL.js";
|
|
12
12
|
import "../assets/input-field.css";
|
|
13
13
|
var v = /* @__PURE__ */ ((t) => (t.DEFAULT = "default", t.PAYMENT_METHOD = "payment-method", t.STATIC_VALUE = "static-value", t.DROPDOWN = "dropdown", t))(v || {}), f = /* @__PURE__ */ ((t) => (t.START = "start", t.END = "end", t))(f || {}), T = /* @__PURE__ */ ((t) => (t.CONDENSED = "condensed", t.DISABLED = "disabled", t.READONLY = "readonly", t.ERROR = "error", t))(T || {}), C = /* @__PURE__ */ ((t) => (t.SEARCH = "search", t.TEXT = "text", t.NUMBER = "number", t))(C || {}), Ue = /* @__PURE__ */ ((t) => (t.INPUT = "input", t.ESCAPE_PRESSED = "escape-pressed", t.UPDATE_DROPDOWN = "update:dropdown", t.DROPDOWN_INPUT = "dropdown-input", t.FOCUS = "focus", t.CHANGE = "change", t.BLUR = "blur", t.KEYDOWN = "keydown", t))(Ue || {});
|
|
@@ -292,7 +292,7 @@ const Z = {
|
|
|
292
292
|
_: 3
|
|
293
293
|
}, 8, ["class"]));
|
|
294
294
|
}
|
|
295
|
-
}), lt = /* @__PURE__ */ Me(Xe, [["__scopeId", "data-v-
|
|
295
|
+
}), lt = /* @__PURE__ */ Me(Xe, [["__scopeId", "data-v-7cad434e"]]);
|
|
296
296
|
export {
|
|
297
297
|
lt as B,
|
|
298
298
|
v as a,
|
|
@@ -301,4 +301,4 @@ export {
|
|
|
301
301
|
C as d,
|
|
302
302
|
Ue as e
|
|
303
303
|
};
|
|
304
|
-
//# sourceMappingURL=input-field.
|
|
304
|
+
//# sourceMappingURL=input-field.6bH4yGb2.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"input-field.6bH4yGb2.js","sources":["../../../vue2/src/components/input-field/input-field.types.ts","../../../vue2/src/components/input-field/input-field.vue"],"sourcesContent":["// eslint-disable-next-line @typescript-eslint/consistent-type-imports\nimport { BentoDropdown } from '@/components/dropdown/';\n\n/**\n * @deprecated for usage with properties since version 2.0. Use the string literal instead.\n */\nexport enum BentoInputFieldVariant {\n DEFAULT = 'default',\n PAYMENT_METHOD = 'payment-method',\n STATIC_VALUE = 'static-value',\n DROPDOWN = 'dropdown',\n}\n\n/**\n * @deprecated for usage with properties since version 2.0. Use the string literal instead.\n */\nexport enum BentoInputFieldElementPosition {\n START = 'start',\n END = 'end',\n}\n\nexport enum BentoInputFieldStateClass {\n CONDENSED = 'condensed',\n DISABLED = 'disabled',\n READONLY = 'readonly',\n ERROR = 'error',\n}\n\n/**\n * @deprecated for usage with properties since version 2.0. Use the string literal instead.\n */\nexport enum BentoInputFieldType {\n SEARCH = 'search',\n TEXT = 'text',\n NUMBER = 'number',\n}\n\nexport type BentoInputFieldValue = string | number;\n\ntype DropdownProps = InstanceType<typeof BentoDropdown>['$props'];\nexport type BentoInputDropdownProps = {\n /**\n * Text that labels the dropdown element\n */\n 'aria-label'?: string;\n /**\n * Enables dynamic filtering\n */\n dynamicFiltering?: DropdownProps['dynamicFiltering'];\n /**\n * List of available items\n */\n items: DropdownProps['items'];\n /**\n * Sets the dropdown in read-only mode\n */\n readonly?: DropdownProps['readonly'];\n /**\n * Selected value of the dropdown\n */\n value?: DropdownProps['value'];\n};\n\n/**\n * @deprecated The use of these enums is no longer supported.\n * Use `v-on:` or `@` to listen to the events being emitted.\n * This enum will be removed in 2.0.\n */\nexport enum BentoInputFieldEvent {\n INPUT = 'input',\n ESCAPE_PRESSED = 'escape-pressed',\n UPDATE_DROPDOWN = 'update:dropdown',\n DROPDOWN_INPUT = 'dropdown-input',\n FOCUS = 'focus',\n CHANGE = 'change',\n BLUR = 'blur',\n KEYDOWN = 'keydown',\n}\n\nexport interface BentoInputFieldProps {\n /**\n * Indicates whether the element is exposed to an accessibility API.\n */\n ariaHidden?: boolean;\n\n /**\n * Text that labels an the input element\n *\n * @deprecated from version 2.0.0. Use the aria-label attribute instead.\n */\n ariaLabel?: string;\n\n /**\n * Reduces height of the input\n */\n condensed?: boolean;\n\n /**\n * Disables the possibility of changing value in the input-field\n */\n disabled?: boolean;\n\n /**\n * Dropdown props for the small selectable dropdown menu.\n * Properties supported:\n *\n * - `aria-label`: Text that labels the dropdown element\n * - `dynamicFiltering`: Enables dynamic filtering\n * - `items`: List of available items\n * - `readonly`: Sets the dropdown in read-only mode\n * - `value`: Selected value of the dropdown\n */\n dropdown?: BentoInputDropdownProps;\n\n /**\n * Position of the dropdown before or after input value\n */\n dropdownPosition?: BentoInputFieldElementPosition | `${BentoInputFieldElementPosition}`;\n\n /**\n * Adds error validation class for outlining input-field.\n *\n * @deprecated Use \"errorMessage\" prop instead\n */\n error?: boolean;\n\n /**\n * Renders input-field with an error state and the error message beneath the input box\n */\n errorMessage?: string;\n\n /**\n * Highlights the dropdown is optional.\n */\n optional?: boolean;\n\n /**\n * Text displayed as the placeholder of the input-field\n */\n placeholder?: string;\n\n /**\n * When present, indicates that the user must specify a value for the input before the owning form can be submitted.\n * The `required` attribute is supported by input types like `text`, `search`, and `number`.\n */\n required?: boolean;\n\n /**\n * Setting this property to true will set the input field to read only state.\n */\n readonly?: boolean;\n\n /**\n * Renders a font numeric style with slashed zeros instead of normal ones.\n */\n slashedZero?: boolean;\n\n /**\n * Static text that displayed before or after input value\n * Applicable to the Static Value variant\n */\n staticValue?: string;\n\n /**\n * Position of Static Value before or after input value\n */\n staticValuePosition?: BentoInputFieldElementPosition | `${BentoInputFieldElementPosition}`;\n\n /**\n * Adds a info icon next to the label to display the passed tooltip message.\n */\n tooltipText?: string;\n\n /**\n * A string specifying the type of control to render.\n * All `input` types are available but only `search`, `text` and `number` are fully supported.\n *\n * If `type` is `search`, use `bento-search-bar` instead.\n */\n type?: BentoInputFieldType | `${BentoInputFieldType}` | HTMLInputElement['type'];\n\n /**\n * Text displayed as the value of the input-field\n */\n value?: BentoInputFieldValue;\n\n /**\n * Describes the different variants for the input element\n */\n variant?: BentoInputFieldVariant | `${BentoInputFieldVariant}`;\n}\n","<template>\n <bento-typography\n class=\"b-input-field\"\n data-testid=\"input-text-container\"\n :class=\"inputFieldConditionalClasses\"\n el=\"div\"\n variant=\"body\"\n >\n <field-label\n v-if=\"hasSlot('default')\"\n :for=\"inputFieldId\"\n data-testid=\"input-field-label\"\n :tooltip-text=\"tooltipText\"\n :optional=\"optional\"\n :required=\"required\"\n @click=\"focusInput\"\n >\n <slot></slot>\n </field-label>\n\n <div class=\"b-input-field__input-box\" data-testid=\"input-box\" :aria-disabled=\"disabled\" @click=\"focusInput\">\n <!-- Optional Icon for Default text variant -->\n <span\n v-if=\"isDefaultVariant && (hasSlot('defaultIconBefore') || hasSlot('iconBefore'))\"\n :aria-hidden=\"ariaHidden ? 'true' : undefined\"\n class=\"b-input-field__icon-before\"\n >\n <slot v-if=\"hasSlot('iconBefore')\" name=\"iconBefore\" />\n <slot v-if=\"hasSlot('defaultIconBefore') && !hasSlot('iconBefore')\" name=\"defaultIconBefore\" />\n </span>\n\n <!-- Mandatory Icon for Payment Method variant -->\n <span\n v-if=\"isPaymentMethodVariant && hasSlot('paymentMethod')\"\n :aria-hidden=\"ariaHidden ? 'true' : undefined\"\n class=\"b-input-field__payment-method\"\n >\n <slot name=\"paymentMethod\" />\n </span>\n\n <!-- Dropdown at start -->\n <div\n v-if=\"shouldDisplayDropdownAtStart\"\n :id=\"dropdownId\"\n class=\"b-input-field__dropdown b-input-field__dropdown--start\"\n @click.stop\n >\n <bento-dropdown\n v-if=\"dropdown\"\n ref=\"inputDropdownElement\"\n v-bind=\"inputFieldDropdownProps\"\n :disabled=\"disabled\"\n :readonly=\"isDropdownReadOnly\"\n @input=\"onDropdownInput\"\n />\n </div>\n\n <!-- Static Value at start -->\n <bento-typography\n v-if=\"shouldDisplayStaticValueAtStart\"\n :id=\"staticValueId\"\n class=\"b-input-field__static-value b-input-field__static-value--start\"\n el=\"span\"\n variant=\"body\"\n >\n <slot name=\"staticValue\" />\n </bento-typography>\n <div class=\"b-input-field__input-container\">\n <input\n :id=\"inputFieldId\"\n v-bind=\"attrs\"\n ref=\"inputFieldElement\"\n class=\"b-input-field__input\"\n :aria-label=\"computedAriaLabel\"\n :aria-describedby=\"computedAriaDescribedBy\"\n :aria-owns=\"computedAriaOwns\"\n :aria-invalid=\"shouldShowError\"\n :placeholder=\"placeholder\"\n :required=\"required\"\n :type=\"type\"\n :value=\"value\"\n :disabled=\"disabled\"\n :readonly=\"isReadOnly\"\n @input=\"onInput\"\n @change=\"emit('change')\"\n @focus=\"onFocus\"\n @blur=\"onBlur\"\n @keydown=\"emit('keydown', $event)\"\n @keyup=\"emit('keyup', $event)\"\n @keydown.esc=\"emit('escape-pressed')\"\n />\n\n <!-- Hint at the end -->\n <bento-typography v-if=\"hint && isFocused && value\" el=\"span\" class=\"b-input-field__hint\">\n {{ hint }}\n </bento-typography>\n </div>\n\n <span\n v-if=\"hasSlot('iconAfter')\"\n :aria-hidden=\"ariaHidden ? 'true' : undefined\"\n class=\"b-input-field__icon-after\"\n data-testid=\"input-text__icon-after\"\n >\n <slot name=\"iconAfter\" />\n </span>\n\n <!-- Static Value at the end -->\n <bento-typography\n v-if=\"shouldDisplayStaticValueAtEnd\"\n :id=\"staticValueId\"\n class=\"b-input-field__static-value b-input-field__static-value--end\"\n el=\"span\"\n variant=\"body\"\n >\n <slot name=\"staticValue\" />\n </bento-typography>\n\n <!-- Dropdown at end -->\n <div\n v-if=\"shouldDisplayDropdownAtEnd\"\n :id=\"dropdownId\"\n data-testid=\"input-field-dropdown-container-end\"\n class=\"b-input-field__dropdown b-input-field__dropdown--end\"\n @click.stop\n >\n <bento-dropdown\n v-if=\"dropdown\"\n :id=\"dropdownId\"\n ref=\"inputDropdownElement\"\n v-bind=\"inputFieldDropdownProps\"\n :disabled=\"disabled\"\n :readonly=\"isDropdownReadOnly\"\n @input=\"onDropdownInput\"\n />\n </div>\n </div>\n\n <error-message\n v-if=\"shouldShowError && !!errorMessage\"\n :id=\"errorId\"\n :error-message=\"errorMessage\"\n class=\"b-input-field__error-message\"\n />\n\n <span v-if=\"hasSlot('description')\" :id=\"descriptionId\" class=\"b-input-field__description\" @click=\"focusInput\">\n <bento-typography el=\"span\" variant=\"body\">\n <slot id=\"description\" name=\"description\" />\n </bento-typography>\n </span>\n </bento-typography>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, inject, provide, type Ref, ref, toRef, toRefs, useAttrs, useSlots } from 'vue';\n\n // Components\n import { BentoDropdown } from '@/components/dropdown';\n import { BentoTypography } from '@/components/typography';\n import { ErrorMessage, FieldLabel } from '@/internal';\n\n // Utils\n import { deprecate } from '@/utils/ts/deprecate';\n import { generateUid } from '@/core/utils/ts';\n import { getSlotText } from '@/utils/ts/get-slot-text';\n import { useAriaLabel } from '@/utils/ts/aria-label';\n import { useI18n } from '@/utils/ts/i18n';\n import { printDevelopmentWarning } from '@/utils/ts/print-development-warning';\n import {\n INPUT_FIELD_COMPONENT_INJECTION_KEY,\n INPUT_FIELD_HINT_INJECTION_KEY,\n INPUT_FIELD_PARENT_COMPONENT_INJECTION_KEY,\n } from '@/components/input-field/input-field.keys';\n\n // Composables\n import { useFormLayoutFieldLoading, useHasSlot } from '@/composables';\n\n // Types\n import {\n type BentoInputDropdownProps,\n BentoInputFieldElementPosition,\n type BentoInputFieldProps,\n BentoInputFieldStateClass,\n BentoInputFieldType,\n BentoInputFieldVariant,\n } from './input-field.types';\n import { type BentoListboxSelectedValue } from '@/types';\n\n import messages from './messages.json';\n\n type MessageSchema = (typeof messages)['en-US'];\n\n const attrs = useAttrs();\n const slots = useSlots();\n\n const props = withDefaults(defineProps<BentoInputFieldProps>(), {\n ariaHidden: true,\n ariaLabel: undefined,\n condensed: false,\n disabled: false,\n dropdown: undefined,\n dropdownPosition: BentoInputFieldElementPosition.START,\n error: false,\n errorMessage: null,\n optional: false,\n placeholder: '',\n required: false,\n readonly: false,\n slashedZero: false,\n staticValue: '',\n staticValuePosition: BentoInputFieldElementPosition.START,\n tooltipText: null,\n type: BentoInputFieldType.TEXT,\n value: undefined,\n variant: BentoInputFieldVariant.DEFAULT,\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when the Input Field's internal dropdown changes it's value. Contains every dropdown prop passed with the updated selected value as 'value'\n */\n (e: 'update:dropdown', updatedDropdownProps: BentoInputDropdownProps): void;\n\n /**\n * Emitted when the element has lost focus\n */\n (e: 'blur'): void;\n\n /**\n * Emitted when the user modifies the element's value. Unlike the 'input' event, the change event is not necessarily fired for each alteration to an element's value\n */\n (e: 'change'): void;\n\n /**\n * Emitted when the Input Field's internal dropdown changes it's value\n */\n (e: 'dropdown-input', selectedValue: BentoListboxSelectedValue): void;\n\n /**\n * Emitted when the \"ESC\" key is pressed\n */\n (e: 'escape-pressed'): void;\n\n /**\n * Emitted when the element has received focus\n */\n (e: 'focus'): void;\n\n /**\n * Emitted when a key is pressed down\n */\n (e: 'keydown', event: KeyboardEvent): void;\n\n /**\n * Emitted when a key is pressed and lifted up\n */\n (e: 'keyup', event: KeyboardEvent): void;\n\n /**\n * Emitted when the component's model changes\n */\n (e: 'input', inputValue: string): void;\n }>();\n\n const { t } = useI18n<{ message: MessageSchema }>({ messages });\n const hasSlot = useHasSlot(slots);\n const inputFieldElement = ref(null);\n const inputDropdownElement = ref(null);\n const inputFieldId = generateUid('input');\n const dropdownId = generateUid('input-dropdown');\n const staticValueId = generateUid('input-static-value');\n const descriptionId = generateUid('input-description');\n const errorId = generateUid('input-error');\n const isFocused = ref(false);\n\n // Provide INPUT_FIELD_COMPONENT_INJECTION_KEY as true, to set the input only dropdown size variant in the BentoDropdown comp\n provide(INPUT_FIELD_COMPONENT_INJECTION_KEY, true);\n // Renders the input with a hint if a string is provided\n const hint = inject<Ref<string | undefined>>(INPUT_FIELD_HINT_INJECTION_KEY, ref(undefined));\n\n const onFocus = () => {\n isFocused.value = true;\n emit('focus');\n };\n\n const onBlur = () => {\n isFocused.value = false;\n emit('blur');\n };\n\n const { isReadOnly } = useFormLayoutFieldLoading(toRef(props, 'readonly'));\n const isDropdownReadOnly = computed<BentoInputDropdownProps['readonly']>(\n () => isReadOnly.value || props.dropdown?.readonly\n );\n\n const shouldShowStaticValue = computed(\n () => props.variant === BentoInputFieldVariant.STATIC_VALUE && !!slots.staticValue\n );\n\n const isDefaultVariant = computed(() => props.variant === BentoInputFieldVariant.DEFAULT);\n\n const isPaymentMethodVariant = computed(() => props.variant === BentoInputFieldVariant.PAYMENT_METHOD);\n\n const shouldDisplayStaticValueAtStart = computed(\n () => shouldShowStaticValue.value && props.staticValuePosition === BentoInputFieldElementPosition.START\n );\n const shouldDisplayStaticValueAtEnd = computed(\n () => shouldShowStaticValue.value && props.staticValuePosition === BentoInputFieldElementPosition.END\n );\n\n const shouldShowDropdown = computed(() => props.variant === BentoInputFieldVariant.DROPDOWN && !!props.dropdown);\n const shouldDisplayDropdownAtStart = computed(\n () => shouldShowDropdown.value && props.dropdownPosition === BentoInputFieldElementPosition.START\n );\n const shouldDisplayDropdownAtEnd = computed(\n () => shouldShowDropdown.value && props.dropdownPosition === BentoInputFieldElementPosition.END\n );\n\n const shouldShowError = computed(\n () => !props.disabled && !isReadOnly.value && (!!props.errorMessage || props.error)\n );\n\n const computedAriaOwns = computed(() => {\n if (shouldShowDropdown.value === true && shouldShowStaticValue.value === true) {\n return `${staticValueId} ${dropdownId}`;\n }\n if (shouldShowDropdown.value === true) {\n return `${dropdownId}`;\n }\n if (shouldShowStaticValue.value === true) {\n return `${staticValueId}`;\n }\n return null;\n });\n\n // vue-i18n issue with t() used in script - direct usage in template works\n // requires either createI18n({ legacy: false }) or to be wrapped in computed()\n const computedAriaLabelFallbackMessage = computed(() => t('ariaLabelFallback'));\n const computedAriaLabelDropdowFallback = computed(() =>\n t('ariaLabelDropdownFallback', { inputLabel: computedAriaLabel.value })\n );\n\n const ariaLabelAttribute = ref(attrs['aria-label']);\n const { ariaLabel } = toRefs(props);\n const computedAriaLabel = useAriaLabel({\n ariaLabel: ariaLabelAttribute.value as string,\n // TODO: take this line away when the aria-label props is removed\n label: ariaLabel,\n defaultFallback: hasSlot('default')\n ? (getSlotText(slots)('default') as string)\n : computedAriaLabelFallbackMessage,\n });\n\n const computedAriaDescribedBy = computed(\n () =>\n `${hasSlot('description') ? descriptionId : ''} ${\n shouldShowError.value && !!props.errorMessage ? errorId : ''\n }`\n );\n\n const inputFieldConditionalClasses = computed(() => ({\n [`b-input-field--${BentoInputFieldStateClass.CONDENSED}`]: props.condensed,\n [`b-input-field--${BentoInputFieldStateClass.DISABLED}`]: props.disabled,\n [`b-input-field--${BentoInputFieldStateClass.READONLY}`]: isReadOnly.value,\n [`b-input-field--${BentoInputFieldStateClass.ERROR}`]: shouldShowError.value,\n [`b-input-field--slashed-zero`]: props.slashedZero,\n }));\n\n const inputFieldDropdownProps = computed(() => ({\n 'aria-label': computedAriaLabelDropdowFallback.value,\n ...props.dropdown,\n }));\n\n const onInput = (event: Event) => {\n const inputValue = (event.target as HTMLInputElement).value;\n if (!props.disabled && !isReadOnly.value) {\n emit('input', inputValue);\n }\n };\n\n const onDropdownInput = (selectedValue: BentoListboxSelectedValue) => {\n emit('dropdown-input', selectedValue);\n emit('update:dropdown', { ...props?.dropdown, value: selectedValue });\n };\n\n const focusInput = () => {\n inputFieldElement.value.focus();\n };\n\n const focus = () => {\n if (props.variant === 'dropdown') {\n inputDropdownElement.value.focus();\n } else {\n focusInput();\n }\n };\n\n // Expose method so that other components can focus on it in Vue3\n defineExpose({\n focusInput,\n focus,\n });\n\n const inputFieldParentComponent = inject(INPUT_FIELD_PARENT_COMPONENT_INJECTION_KEY, '');\n\n if (!Object.values(BentoInputFieldType).includes(props.type as BentoInputFieldType) && !inputFieldParentComponent) {\n if (props.type === 'tel') {\n printDevelopmentWarning(\n `\"bento-input-field\" dropdown does not support the type '${props.type}', use \"bento-input-field-phone-number\" instead.`\n );\n } else if (props.type === 'password') {\n printDevelopmentWarning(\n `\"bento-input-field\" dropdown does not support the type '${props.type}', use \"bento-input-field-password\" instead.`\n );\n } else {\n printDevelopmentWarning(`\"bento-input-field\" dropdown does not support the type '${props.type}'`);\n }\n }\n\n /**\n * Deprecations\n */\n if (props.error) {\n deprecate(\n 'BentoInputField \"error\" property',\n `Use the BentoInputField \"errorMessage\" property instead to indicate that there is a modifier error.\n Having the field as \"undefined\" will hide/remove the error.\n <bento-dropdown errorMessage=\"Error message text\" />`,\n '2.0.0'\n );\n }\n\n if (hasSlot('defaultIconBefore')) {\n deprecate(\n 'BentoInputField \"defaultIconBefore\" slot',\n `Use the BentoInputField \"iconBefore\" slot instead to add an icon at the left side of the input field\n <bento-input-field>\n \\t<template #iconBefore>\n \\t\\t<my-icon-goes-here />\n \\t</template>\n </bento-input-field>`,\n '2.0.0'\n );\n }\n</script>\n\n<script lang=\"ts\">\n /**\n * Input field component is used to create interactive controls for web-based\n * forms in order to accept data from the user.\n *\n * @example\n * import { BentoInputField } from '@adyen/bento-vue2'\n *\n * const inputValue = ref('');\n *\n * export default {\n * components: { BentoInputField },\n * tempate: `\n * <bento-input-field\n * :value=\"inputValue\"\n * :input=\"newValue => inputValue.value = newValue\"\n * >\n * }\n */\n export default {\n i18n: { messages },\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"./input-field.scss\" />\n"],"names":["BentoInputFieldVariant","BentoInputFieldVariant2","BentoInputFieldElementPosition","BentoInputFieldElementPosition2","BentoInputFieldStateClass","BentoInputFieldStateClass2","BentoInputFieldType","BentoInputFieldType2","BentoInputFieldEvent","BentoInputFieldEvent2","__default__","messages","attrs","useAttrs","slots","useSlots","props","__props","emit","__emit","t","useI18n","hasSlot","useHasSlot","inputFieldElement","ref","inputDropdownElement","inputFieldId","generateUid","dropdownId","staticValueId","descriptionId","errorId","isFocused","provide","INPUT_FIELD_COMPONENT_INJECTION_KEY","hint","inject","INPUT_FIELD_HINT_INJECTION_KEY","onFocus","onBlur","isReadOnly","useFormLayoutFieldLoading","toRef","isDropdownReadOnly","computed","_a","shouldShowStaticValue","isDefaultVariant","isPaymentMethodVariant","shouldDisplayStaticValueAtStart","shouldDisplayStaticValueAtEnd","shouldShowDropdown","shouldDisplayDropdownAtStart","shouldDisplayDropdownAtEnd","shouldShowError","computedAriaOwns","computedAriaLabelFallbackMessage","computedAriaLabelDropdowFallback","computedAriaLabel","ariaLabelAttribute","ariaLabel","toRefs","useAriaLabel","getSlotText","computedAriaDescribedBy","inputFieldConditionalClasses","inputFieldDropdownProps","onInput","event","inputValue","onDropdownInput","selectedValue","focusInput","__expose","inputFieldParentComponent","INPUT_FIELD_PARENT_COMPONENT_INJECTION_KEY","printDevelopmentWarning","deprecate"],"mappings":";;;;;;;;;;;;AAMY,IAAAA,IAAA,kBAAAC,OACRA,EAAA,UAAA,WACAA,EAAA,iBAAA,kBACAA,EAAA,eAAA,gBACAA,EAAA,WAAA,YAJQA,IAAAD,KAAA,CAAA,CAAA,GAUAE,IAAA,kBAAAC,OACRA,EAAA,QAAA,SACAA,EAAA,MAAA,OAFQA,IAAAD,KAAA,CAAA,CAAA,GAKAE,IAAA,kBAAAC,OACRA,EAAA,YAAA,aACAA,EAAA,WAAA,YACAA,EAAA,WAAA,YACAA,EAAA,QAAA,SAJQA,IAAAD,KAAA,CAAA,CAAA,GAUAE,IAAA,kBAAAC,OACRA,EAAA,SAAA,UACAA,EAAA,OAAA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ACI6D;AAAA,MAAA,2DAAA7D,EAAA,IAAA;AAAA,IACyE,IACzEA,EAAA,SAAA,aAEA6D;AAAA,MAAA,2DAAA7D,EAAA,IAAA;AAAA,IACyE,IAGzE6D,EAAA,2DAAA7D,EAAA,IAAA,GAAA,IAORA,EAAA,SACI8D;AAAA,MAAA;AAAA,MACI;AAAA;AAAA;AAAA,MACA;AAAA,IAGA,GAIRxD,EAAA,mBAAA,KACIwD;AAAA,MAAA;AAAA,MACI;AAAA;AAAA;AAAA;AAAA;AAAA;AAAA,MACA;AAAA,IAMA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { ref as v, watch as x, defineComponent as N, computed as
|
|
2
|
-
import { d as U, B as X } from "./typography.
|
|
3
|
-
import { B } from "./button.
|
|
4
|
-
import { B as j } from "./loading-indicator.
|
|
5
|
-
import { B as q, s as J, g as W, a as Q, f as Z } from "./focus-trap.
|
|
1
|
+
import { ref as v, watch as x, defineComponent as N, computed as b, createElementBlock as E, openBlock as f, normalizeClass as V, createElementVNode as s, createVNode as i, renderSlot as w, Transition as K, withCtx as l, createCommentVNode as T, withKeys as z, unref as n, Fragment as G, createTextVNode as H, toDisplayString as k, createBlock as O, nextTick as Y } from "vue";
|
|
2
|
+
import { d as U, B as X } from "./typography.CFHvBR7L.js";
|
|
3
|
+
import { B } from "./button.wMNce6wZ.js";
|
|
4
|
+
import { B as j } from "./loading-indicator.BmAQqPP2.js";
|
|
5
|
+
import { B as q, s as J, g as W, a as Q, f as Z } from "./focus-trap.rjp24a37.js";
|
|
6
6
|
import { E as ee } from "./expand.C9IAqYYL.js";
|
|
7
7
|
import { C as te } from "./cross.B92GxFTY.js";
|
|
8
8
|
import { g as ne } from "./generate-uid.NJ8tVoha.js";
|
|
@@ -54,25 +54,25 @@ const I = {
|
|
|
54
54
|
},
|
|
55
55
|
emits: ["update:is-open", "update:active-page", "expand"],
|
|
56
56
|
setup(_, { emit: L }) {
|
|
57
|
-
const t = _, r = L, { t: c } = oe({ messages: I }), o = ne("returnToMainContentDescription"), S = v(null), m = v(null), A = v(null), h = v(null), { width: F } = se(S), p =
|
|
57
|
+
const t = _, r = L, { t: c } = oe({ messages: I }), o = ne("returnToMainContentDescription"), S = v(null), m = v(null), A = v(null), h = v(null), { width: F } = se(S), p = b(() => {
|
|
58
58
|
const d = t.size === "small" ? 740 : 915;
|
|
59
59
|
return F.value > 0 && F.value < d;
|
|
60
|
-
}),
|
|
60
|
+
}), g = b(() => t.pageFocusAnchor), D = b(() => ({
|
|
61
61
|
[`b-inspector--${t.size}`]: !0,
|
|
62
62
|
[`b-inspector--${t.relativeLayout}`]: !0,
|
|
63
63
|
"b-inspector--is-compact": p.value
|
|
64
|
-
})), P =
|
|
65
|
-
t.isOpen ? (await Y(), J(m.value,
|
|
64
|
+
})), P = b(() => `${c("inspector")}, ${t.title}`), { findValidFocusFallback: y } = re(A), C = async () => {
|
|
65
|
+
t.isOpen ? (await Y(), J(m.value, g.value)) : u(g.value ?? y());
|
|
66
66
|
}, R = (e) => {
|
|
67
67
|
if (p.value)
|
|
68
68
|
return;
|
|
69
69
|
const a = e.shiftKey ? -1 : 1, d = W(a, m.value);
|
|
70
|
-
Q() === d && (e.preventDefault(), h.value = document.activeElement, u(
|
|
70
|
+
Q() === d && (e.preventDefault(), h.value = document.activeElement, u(g.value ?? y()), r("update:active-page", void 0));
|
|
71
71
|
}, $ = (e) => {
|
|
72
72
|
const a = e.shiftKey && e.ctrlKey && e.key === "S";
|
|
73
73
|
t.isOpen && !p.value && a && M();
|
|
74
74
|
}, M = () => {
|
|
75
|
-
Z(m.value) ? (h.value = document.activeElement, u(
|
|
75
|
+
Z(m.value) ? (h.value = document.activeElement, u(g.value ?? y()), r("update:active-page", void 0)) : u(h.value);
|
|
76
76
|
}, u = (e) => {
|
|
77
77
|
e && (e == null || e.focus(), document.activeElement !== e && u(e.parentElement));
|
|
78
78
|
};
|
|
@@ -193,8 +193,8 @@ const I = {
|
|
|
193
193
|
})
|
|
194
194
|
], 34));
|
|
195
195
|
}
|
|
196
|
-
}), Ae = /* @__PURE__ */ ie(me, [["__scopeId", "data-v-
|
|
196
|
+
}), Ae = /* @__PURE__ */ ie(me, [["__scopeId", "data-v-7df4c2ca"]]);
|
|
197
197
|
export {
|
|
198
198
|
Ae as B
|
|
199
199
|
};
|
|
200
|
-
//# sourceMappingURL=inspector.
|
|
200
|
+
//# sourceMappingURL=inspector.Bsv68G-e.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"inspector.Bsv68G-e.js","sources":["../../../vue2/src/components/inspector/composables/use-focus-history/use-focus-history.ts","../../../vue2/src/components/inspector/inspector.vue"],"sourcesContent":["import { ref, type Ref } from 'vue';\nimport { useActiveElement } from '@vueuse/core';\nimport { watch } from 'vue';\n\n/**\n * A composable to track the focus history within a target element.\n * @param targetEl The stable parent element to monitor for focus changes.\n */\nexport function useFocusHistory(targetEl: Ref<HTMLElement | null>) {\n const MAX_HISTORY_LENGTH = 3;\n\n const focusHistory = ref<Element[]>([]);\n\n const currentActiveElement = useActiveElement();\n\n // Edge case 1:\n // While the inspector is opened, if user tabs through the data-grid to the inspector, and closes it,\n // it returns to the last element on the data grid regardless if it is a data-grid-cell.\n //\n // Edge case 2:\n // Buttons or actions teleported out of the data-grid may have the focus shifted into a different context.\n watch(currentActiveElement, newlyFocusedElement => {\n // Check if the newly focused element is a child of our target container.\n if (!targetEl.value || !newlyFocusedElement || !targetEl.value.contains(newlyFocusedElement)) {\n return;\n }\n\n // Add the focused element to the history\n focusHistory.value.unshift(newlyFocusedElement);\n\n if (focusHistory.value.length > MAX_HISTORY_LENGTH) {\n focusHistory.value.pop();\n }\n });\n\n /**\n * Iterates through the focus history to find the first valid element\n * that is still present in the DOM.\n * @returns The first valid historical element, or null if none are found.\n */\n const findValidFocusFallback = (): HTMLElement | null => {\n for (const el of focusHistory.value) {\n if (el && document.body.contains(el as Node)) {\n return el as HTMLElement;\n }\n }\n\n return null; // No valid fallback found\n };\n\n return {\n findValidFocusFallback,\n };\n}\n","<template>\n <div ref=\"wrapper\" class=\"b-inspector\" :class=\"conditionalClass\" @keydown=\"handleSectionFocus\">\n <div ref=\"page\" class=\"b-inspector__page-wrapper\">\n <div class=\"b-inspector__page\">\n <slot name=\"page\" />\n </div>\n </div>\n <Transition name=\"b-inspector__animation\" mode=\"out-in\" @before-enter=\"setFocus\" @after-leave=\"setFocus\">\n <aside\n v-if=\"isOpen\"\n ref=\"inspector\"\n class=\"b-inspector__container-wrapper\"\n :aria-label=\"inspectorAriaLabel\"\n @keydown.tab=\"handleTabNavigation\"\n >\n <bento-focus-trap :disabled=\"!isCompact\">\n <div class=\"b-inspector__container\">\n <div class=\"b-inspector__header\">\n <template v-if=\"!isCompact\">\n <bento-button\n class=\"b-inspector__return-content\"\n variant=\"secondary\"\n condensed\n :aria-describedby=\"returnToMainContentDescriptionId\"\n @click=\"moveFocusBetweenSections\"\n >\n {{ t('returnToMainContent') }}\n </bento-button>\n <span\n :id=\"returnToMainContentDescriptionId\"\n class=\"b-inspector__return-content-description\"\n >{{ t('returnToMainContentDescription') }}</span\n >\n </template>\n <bento-typography el=\"h2\" variant=\"title\" class=\"b-inspector__title\">\n {{ title }}\n </bento-typography>\n <div class=\"b-inspector__icons\">\n <bento-button v-if=\"expandable\" variant=\"tertiary\" @click=\"emit('expand')\">\n <template #iconLeft><expand-icon :svg-title=\"t('expand')\"></expand-icon></template>\n </bento-button>\n <bento-button variant=\"tertiary\" @click=\"emit('update:is-open', false)\">\n <template #iconLeft><cross-icon :svg-title=\"t('close')\"></cross-icon></template>\n </bento-button>\n </div>\n </div>\n <div class=\"b-inspector__content\">\n <bento-loading-indicator v-if=\"loading\" large class=\"b-inspector__loading-indicator\" />\n <slot v-else name=\"content\" />\n </div>\n </div>\n </bento-focus-trap>\n </aside>\n </Transition>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, nextTick, ref, watch } from 'vue';\n import { BentoTypography } from '@/components/typography';\n import { BentoButton } from '@/components/button';\n import { BentoLoadingIndicator } from '@/components/loading-indicator';\n import { BentoFocusTrap } from '@/components/focus-trap';\n import ExpandIcon from '@adyen/ui-assets-icons-16/vue/expand';\n import CrossIcon from '@adyen/ui-assets-icons-16/vue/cross';\n\n import { generateUid } from '@/core/utils/ts';\n import { useI18n } from '@/utils/ts/i18n';\n import { deprecate } from '@/utils/ts/deprecate';\n import { getNextFocusableElement } from '@/utils/ts/focus-trap.utils';\n import { useElementSize } from '@vueuse/core';\n import moveFocusInside, { focusInside, getActiveElement } from 'focus-lock';\n\n import { type BentoInspectorProps } from './inspector.types';\n import { useFocusHistory } from './composables/use-focus-history/use-focus-history';\n import messages from './messages.json';\n\n type MessageSchema = (typeof messages)['en-US'];\n\n const props = withDefaults(defineProps<BentoInspectorProps>(), {\n activePage: '',\n expandable: false,\n isOpen: false,\n loading: false,\n size: 'small',\n relativeLayout: 'push-content',\n pageFocusAnchor: null,\n });\n\n const emit = defineEmits<{\n /**\n * Emits update to keep isOpen prop in sync\n */\n (e: 'update:is-open', value: boolean): void;\n /**\n * Emits update to keep activePage prop in sync\n */\n (e: 'update:active-page', value: string): void;\n /**\n * Emits event when user click expand button\n */\n (e: 'expand'): void;\n }>();\n\n const { t } = useI18n<{ message: MessageSchema }>({ messages });\n const returnToMainContentDescriptionId = generateUid('returnToMainContentDescription');\n const wrapper = ref<HTMLElement>(null);\n const inspector = ref<HTMLElement>(null);\n const page = ref<HTMLElement>(null);\n const inspectorLastFocusedElement = ref<HTMLElement>(null);\n\n const { width: wrapperWidth } = useElementSize(wrapper);\n\n const isCompact = computed(() => {\n const COMPACT_THRESHOLD_SMALL = 740;\n const COMPACT_THRESHOLD_LARGE = 915;\n\n // small inspector to occupy full screen if < 740px\n // large inspector to occupy full screen if < 915px\n const threshold = props.size === 'small' ? COMPACT_THRESHOLD_SMALL : COMPACT_THRESHOLD_LARGE;\n\n return wrapperWidth.value > 0 && wrapperWidth.value < threshold;\n });\n\n const computedPageLastFocusedElement = computed(() => props.pageFocusAnchor);\n\n const conditionalClass = computed(() => ({\n [`b-inspector--${props.size}`]: true,\n [`b-inspector--${props.relativeLayout}`]: true,\n [`b-inspector--is-compact`]: isCompact.value,\n }));\n\n const inspectorAriaLabel = computed(() => `${t('inspector')}, ${props.title}`);\n\n const { findValidFocusFallback } = useFocusHistory(page);\n\n const setFocus = async () => {\n if (props.isOpen) {\n await nextTick();\n moveFocusInside(inspector.value, computedPageLastFocusedElement.value);\n } else {\n // This doesn't work with data grid cell actions, as the button gets destroyed once is not being hovered.\n // To be reviewed after LevelAccess revision\n focusElement(computedPageLastFocusedElement.value ?? findValidFocusFallback());\n }\n };\n\n const handleTabNavigation = event => {\n if (isCompact.value) {\n return;\n }\n const direction = event.shiftKey ? -1 : 1;\n const focusableEl = getNextFocusableElement(direction, inspector.value);\n // If the nextfocusableEl is the same as the activeElement that means it's the last focusable element\n // inside the inspector, so the focus is moved back to the last focused element on the page\n if (getActiveElement() === focusableEl) {\n event.preventDefault();\n inspectorLastFocusedElement.value = document.activeElement as HTMLElement;\n focusElement(computedPageLastFocusedElement.value ?? findValidFocusFallback());\n // Set active-page as undefined when focus is not on page\n emit('update:active-page', undefined);\n }\n };\n\n const handleSectionFocus = event => {\n const sectionShortcut = event.shiftKey && event.ctrlKey && event.key === 'S';\n if (props.isOpen && !isCompact.value && sectionShortcut) {\n moveFocusBetweenSections();\n }\n };\n\n const moveFocusBetweenSections = () => {\n if (focusInside(inspector.value)) {\n inspectorLastFocusedElement.value = document.activeElement as HTMLElement;\n focusElement(computedPageLastFocusedElement.value ?? findValidFocusFallback());\n // Set active-page as undefined when focus is not on page\n emit('update:active-page', undefined);\n } else {\n focusElement(inspectorLastFocusedElement.value);\n }\n };\n\n const focusElement = (element: HTMLElement) => {\n if (!element) {\n return;\n }\n element?.focus();\n if (document.activeElement !== element) {\n focusElement(element.parentElement);\n }\n };\n\n watch(\n () => props.activePage,\n () => {\n if (props.activePage) {\n setFocus();\n }\n }\n );\n\n if (!props.activePage) {\n deprecate(\n 'BentoInspector \"active-page\" as optional',\n `Make sure to set the \"active-page\" prop and keep it in sync with \"update:active-page\".\n \"active-page\" prop will be required in the next version`,\n '2.0.0'\n );\n }\n</script>\n\n<script lang=\"ts\">\n /**\n * Inspector allows users to access additional information or details of an object/item. The inspector opens adjacent to the main content, pushing it aside to maintain visibility and accessibility to both the main content and inspector.\n *\n * @example\n * import { BentoInspector } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoInspector },\n * template: `\n * <bento-inspector\n * title=\"Inspector\"\n * size=\"large\"\n * :is-open=\"isOpen\"\n * :active-page=\"activePage\"\n * expandable\n * @update:is-open=\"isOpen = $event\"\n * @update:active-page=\"activePage = $event\"\n * >\n * <template #page>Content of the page</template>\n * <template #content>Content of the inspector</template>\n * </bento-inspector>\n * `\n * }\n */\n export default { i18n: { messages } };\n</script>\n\n<style lang=\"scss\" scoped src=\"./inspector.scss\" />\n"],"names":["useFocusHistory","targetEl","focusHistory","ref","currentActiveElement","useActiveElement","watch","newlyFocusedElement","el","__default__","messages","props","__props","emit","__emit","t","useI18n","returnToMainContentDescriptionId","generateUid","wrapper","inspector","page","inspectorLastFocusedElement","wrapperWidth","useElementSize","isCompact","computed","threshold","computedPageLastFocusedElement","conditionalClass","inspectorAriaLabel","findValidFocusFallback","setFocus$1","nextTick","setFocus","focusElement","handleTabNavigation","event","direction","focusableEl","getNextFocusableElement","getActiveElement","handleSectionFocus","sectionShortcut","moveFocusBetweenSections","focusInside","element","deprecate"],"mappings":";;;;;;;;;;;;AAQO,SAAAA,GAAAC,GAAA;AAGH,QAAAC,IAAAC,EAAA,CAAA,CAAA,GAEAC,IAAA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@
|
|
|
1
|
-
import { l as a } from "./events.
|
|
1
|
+
import { l as a } from "./events.CMzGybJJ.js";
|
|
2
2
|
var t = /* @__PURE__ */ ((s) => (s.ARROW_DOWN = "keydown:arrow-down", s.ARROW_LEFT = "keydown:arrow-left", s.ARROW_RIGHT = "keydown:arrow-right", s.ARROW_UP = "keydown:arrow-up", s.END = "keydown:end", s.ENTER = "keydown:enter", s.ESCAPE = "keydown:escape", s.HOME = "keydown:home", s.PAGE_DOWN = "keydown:page-down", s.PAGE_UP = "keydown:page-up", s.SHIFT_PAGE_DOWN = "keydown:shift-page-down", s.SHIFT_PAGE_UP = "keydown:shift-page-up", s.TAB = "keydown:tab", s.SPACE = "keydown:space", s))(t || {});
|
|
3
3
|
const d = (s) => (e) => {
|
|
4
4
|
switch (e.key) {
|
|
@@ -63,4 +63,4 @@ export {
|
|
|
63
63
|
t as B,
|
|
64
64
|
r as a
|
|
65
65
|
};
|
|
66
|
-
//# sourceMappingURL=keyboard-navigation.
|
|
66
|
+
//# sourceMappingURL=keyboard-navigation.pB8weElW.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"keyboard-navigation.pB8weElW.js","sources":["../../../vue2/src/types/keyboard-navigation.ts","../../../vue2/src/directives/keyboard-navigation/keyboard-navigation.ts"],"sourcesContent":["export enum BentoKeyboardNavigationKeyDownEvent {\n ARROW_DOWN = 'keydown:arrow-down',\n ARROW_LEFT = 'keydown:arrow-left',\n ARROW_RIGHT = 'keydown:arrow-right',\n ARROW_UP = 'keydown:arrow-up',\n END = 'keydown:end',\n ENTER = 'keydown:enter',\n ESCAPE = 'keydown:escape',\n HOME = 'keydown:home',\n PAGE_DOWN = 'keydown:page-down',\n PAGE_UP = 'keydown:page-up',\n SHIFT_PAGE_DOWN = 'keydown:shift-page-down',\n SHIFT_PAGE_UP = 'keydown:shift-page-up',\n TAB = 'keydown:tab',\n SPACE = 'keydown:space',\n}\n","import { listen } from '@/utils/ts/events';\nimport { type Binding } from './keyboard-navigation.types';\nimport { BentoKeyboardNavigationKeyDownEvent } from '@/types';\nimport type { DirectiveHook } from 'vue';\n\nconst onKeyEvent = (el: Element) => (event: KeyboardEvent) => {\n switch (event.key) {\n case 'Esc':\n case 'Escape':\n el.dispatchEvent(new CustomEvent(BentoKeyboardNavigationKeyDownEvent.ESCAPE, { detail: event }));\n break;\n case 'Enter':\n el.dispatchEvent(new CustomEvent(BentoKeyboardNavigationKeyDownEvent.ENTER, { detail: event }));\n break;\n case 'Tab':\n el.dispatchEvent(new CustomEvent(BentoKeyboardNavigationKeyDownEvent.TAB, { detail: event }));\n break;\n // Space\n case ' ':\n el.dispatchEvent(new CustomEvent(BentoKeyboardNavigationKeyDownEvent.SPACE, { detail: event }));\n break;\n case 'Right':\n case 'ArrowRight':\n el.dispatchEvent(new CustomEvent(BentoKeyboardNavigationKeyDownEvent.ARROW_RIGHT, { detail: event }));\n break;\n case 'Left':\n case 'ArrowLeft':\n el.dispatchEvent(new CustomEvent(BentoKeyboardNavigationKeyDownEvent.ARROW_LEFT, { detail: event }));\n break;\n case 'Up':\n case 'ArrowUp':\n el.dispatchEvent(new CustomEvent(BentoKeyboardNavigationKeyDownEvent.ARROW_UP, { detail: event }));\n break;\n case 'Down':\n case 'ArrowDown':\n el.dispatchEvent(new CustomEvent(BentoKeyboardNavigationKeyDownEvent.ARROW_DOWN, { detail: event }));\n break;\n case 'PageUp':\n if (event.shiftKey) {\n el.dispatchEvent(new CustomEvent(BentoKeyboardNavigationKeyDownEvent.SHIFT_PAGE_UP, { detail: event }));\n } else {\n el.dispatchEvent(new CustomEvent(BentoKeyboardNavigationKeyDownEvent.PAGE_UP, { detail: event }));\n }\n break;\n case 'PageDown':\n if (event.shiftKey) {\n el.dispatchEvent(\n new CustomEvent(BentoKeyboardNavigationKeyDownEvent.SHIFT_PAGE_DOWN, { detail: event })\n );\n } else {\n el.dispatchEvent(new CustomEvent(BentoKeyboardNavigationKeyDownEvent.PAGE_DOWN, { detail: event }));\n }\n break;\n case 'Home':\n el.dispatchEvent(new CustomEvent(BentoKeyboardNavigationKeyDownEvent.HOME, { detail: event }));\n break;\n case 'End':\n el.dispatchEvent(new CustomEvent(BentoKeyboardNavigationKeyDownEvent.END, { detail: event }));\n break;\n default:\n break;\n }\n};\n\nconst bindDirective: DirectiveHook<Element> = (el, binding: Binding<undefined>) => {\n // Register the listener cleanup function\n // eslint-disable-next-line no-param-reassign\n binding['keyDownListener'] = listen(el, 'keydown', onKeyEvent(el));\n};\n\nconst unbindDirective: DirectiveHook<Element> = (_, binding: Binding<undefined>) => {\n if (binding.keyDownListener) {\n binding.keyDownListener();\n }\n};\n\nexport const BentoKeyboardNavigationDirective = {\n // Vue 2 Directive hooks\n bind: bindDirective,\n unbind: unbindDirective,\n // Vue 3 Directive hooks\n beforeMount: bindDirective,\n unmounted: unbindDirective,\n};\n"],"names":["BentoKeyboardNavigationKeyDownEvent","onKeyEvent","el","event","bindDirective","binding","listen","unbindDirective","_","BentoKeyboardNavigationDirective"],"mappings":";AAAY,IAAAA,sBAAAA,OACRA,EAAA,aAAa,sBACbA,EAAA,aAAa,sBACbA,EAAA,cAAc,uBACdA,EAAA,WAAW,oBACXA,EAAA,MAAM,eACNA,EAAA,QAAQ,iBACRA,EAAA,SAAS,kBACTA,EAAA,OAAO,gBACPA,EAAA,YAAY,qBACZA,EAAA,UAAU,mBACVA,EAAA,kBAAkB,2BAClBA,EAAA,gBAAgB,yBAChBA,EAAA,MAAM,eACNA,EAAA,QAAQ,iBAdAA,IAAAA,KAAA,CAAA,CAAA;ACKZ,MAAMC,IAAa,CAACC,MAAgB,CAACC,MAAyB;AAC1D,UAAQA,EAAM,KAAK;AAAA,IACf,KAAK;AAAA,IACL,KAAK;AACE,MAAAD,EAAA,cAAc,IAAI,YAAYF,EAAoC,QAAQ,EAAE,QAAQG,EAAM,CAAC,CAAC;AAC/F;AAAA,IACJ,KAAK;AACE,MAAAD,EAAA,cAAc,IAAI,YAAYF,EAAoC,OAAO,EAAE,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G,EAAM,CAAC,CAAC;AAC7F;AAAA,IACJ,KAAK;AACE,MAAAD,EAAA,cAAc,IAAI,YAAYF,EAAoC,KAAK,EAAE,QAAQG,EAAM,CAAC,CAAC;AAC5F;AAAA,EAEA;AAEZ,GAEMC,IAAwC,CAACF,GAAIG,MAAgC;AAG/E,EAAAA,EAAQ,kBAAqBC,EAAOJ,GAAI,WAAWD,EAAWC,CAAE,CAAC;AACrE,GAEMK,IAA0C,CAACC,GAAGH,MAAgC;AAChF,EAAIA,EAAQ,mBACRA,EAAQ,gBAAgB;AAEhC,GAEaI,IAAmC;AAAA;AAAA,EAE5C,MAAML;AAAA,EACN,QAAQG;AAAA;AAAA,EAER,aAAaH;AAAA,EACb,WAAWG;AACf;"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { defineComponent as $, provide as T, toRef as g, computed as l, createBlock as E, openBlock as d, resolveDynamicComponent as N, unref as u, normalizeClass as c, withCtx as z, renderSlot as m, useSlots as O, inject as x, ref as i, watch as M, nextTick as V, onMounted as j, createElementBlock as
|
|
1
|
+
import { defineComponent as $, provide as T, toRef as g, computed as l, createBlock as E, openBlock as d, resolveDynamicComponent as N, unref as u, normalizeClass as c, withCtx as z, renderSlot as m, useSlots as O, inject as x, ref as i, watch as M, nextTick as V, onMounted as j, createElementBlock as b, createCommentVNode as P, createElementVNode as L } from "vue";
|
|
2
2
|
import { _ as B } from "./_plugin-vue_export-helper.CHgC5LLL.js";
|
|
3
|
-
import { B as W } from "./typography.
|
|
3
|
+
import { B as W } from "./typography.CFHvBR7L.js";
|
|
4
4
|
import { u as Y } from "./use-has-slot.B7eQSabc.js";
|
|
5
5
|
import { f as A } from "./index.FNUaPG4G.js";
|
|
6
6
|
import "../assets/layout-row.css";
|
|
@@ -26,7 +26,7 @@ const I = Symbol("Layout size inject key"), D = {}, F = /* @__PURE__ */ $({
|
|
|
26
26
|
_: 3
|
|
27
27
|
}, 8, ["class"]));
|
|
28
28
|
}
|
|
29
|
-
}), oo = /* @__PURE__ */ B(F, [["__scopeId", "data-v-
|
|
29
|
+
}), oo = /* @__PURE__ */ B(F, [["__scopeId", "data-v-126a4f4f"]]), H = ["3-9", "9-3", "4-8", "8-4", "6-6"], J = { key: 0 }, K = {}, Q = /* @__PURE__ */ $({
|
|
30
30
|
...K,
|
|
31
31
|
__name: "layout-row",
|
|
32
32
|
props: {
|
|
@@ -45,10 +45,10 @@ const I = Symbol("Layout size inject key"), D = {}, F = /* @__PURE__ */ $({
|
|
|
45
45
|
return M(
|
|
46
46
|
A("(min-width: 768px)"),
|
|
47
47
|
async (e) => {
|
|
48
|
-
var r, C,
|
|
48
|
+
var r, C, k;
|
|
49
49
|
await V();
|
|
50
50
|
const n = ((r = s.value) == null ? void 0 : r.firstChild) === _.value;
|
|
51
|
-
e && !n ? (C = s.value) == null || C.prepend(_.value) : !e && (o.columnsLayout === "3-9" || o.columnsLayout === "4-8") && ((
|
|
51
|
+
e && !n ? (C = s.value) == null || C.prepend(_.value) : !e && (o.columnsLayout === "3-9" || o.columnsLayout === "4-8") && ((k = s.value) == null || k.prepend(y.value));
|
|
52
52
|
},
|
|
53
53
|
{ immediate: !0 }
|
|
54
54
|
), j(() => {
|
|
@@ -65,9 +65,9 @@ const I = Symbol("Layout size inject key"), D = {}, F = /* @__PURE__ */ $({
|
|
|
65
65
|
class: c(["b-layout-row", R.value])
|
|
66
66
|
}, {
|
|
67
67
|
default: z(() => [
|
|
68
|
-
u(t)("default") ? (d(),
|
|
68
|
+
u(t)("default") ? (d(), b("div", J, [
|
|
69
69
|
m(e.$slots, "default", {}, void 0, !0)
|
|
70
|
-
])) : u(t)("col-1") && u(t)("col-2") ? (d(),
|
|
70
|
+
])) : u(t)("col-1") && u(t)("col-2") ? (d(), b("div", {
|
|
71
71
|
key: 1,
|
|
72
72
|
ref_key: "row",
|
|
73
73
|
ref: s,
|
|
@@ -92,9 +92,9 @@ const I = Symbol("Layout size inject key"), D = {}, F = /* @__PURE__ */ $({
|
|
|
92
92
|
_: 3
|
|
93
93
|
}, 8, ["class"]));
|
|
94
94
|
}
|
|
95
|
-
}), eo = /* @__PURE__ */ B(Q, [["__scopeId", "data-v-
|
|
95
|
+
}), eo = /* @__PURE__ */ B(Q, [["__scopeId", "data-v-f166e5f9"]]);
|
|
96
96
|
export {
|
|
97
97
|
eo as a,
|
|
98
98
|
oo as l
|
|
99
99
|
};
|
|
100
|
-
//# sourceMappingURL=layout-row.
|
|
100
|
+
//# sourceMappingURL=layout-row.CIg1pwOd.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"layout-row.CIg1pwOd.js","sources":["../../../vue2/src/components/layout/layout.keys.ts","../../../vue2/src/components/layout/layout.vue","../../../vue2/src/components/layout/layout.types.ts","../../../vue2/src/components/layout/components/layout-row/layout-row.vue"],"sourcesContent":["export const LAYOUT_SIZE_INJECTION_KEY = Symbol('Layout size inject key');\n","<template>\n <component :is=\"wrapperElement\" class=\"b-layout\" :class=\"conditionalClasses\">\n <slot />\n </component>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, provide, toRef } from 'vue';\n import { type BentoLayoutProps } from './layout.types';\n import { LAYOUT_SIZE_INJECTION_KEY } from '@/components/layout/layout.keys';\n\n const props = withDefaults(defineProps<BentoLayoutProps>(), {\n size: 'full-width',\n variant: 'page',\n });\n\n provide(LAYOUT_SIZE_INJECTION_KEY, toRef(props, 'size'));\n\n const conditionalClasses = computed(() => ({\n 'b-layout--component': props.variant === 'component',\n }));\n\n const wrapperElement = props.variant === 'page' ? 'main' : 'div';\n</script>\n\n<script lang=\"ts\">\n /**\n * Layout is a basic scaffolding of a page that defines spacing, some functionality and responsive behaviour of its top level sections.\n *\n * @example\n * import { BentoLayout, BentoLayoutRow } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoLayout, BentoLayoutRow },\n * template: `\n * <bento-layout size=\"narrow\">\n * <bento-layout-row>\n * Row 1\n * </bento-layout-row>\n * <bento-layout-row>\n * Row 2\n * </bento-layout-row>\n * </bento-layout>\n * `\n * }\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./layout.scss\" />\n","/**\n * @private\n */\nexport const BentoLayoutVariantOptions = ['page', 'component'] as const;\nexport const BentoLayoutSizeOptions = ['full-width', 'narrow', 'half-width'] as const;\nexport const BentoLayoutRowColumnLayoutOptions = ['3-9', '9-3', '4-8', '8-4', '6-6'] as const;\n\n// Public\nexport type BentoLayoutVariant = (typeof BentoLayoutVariantOptions)[number];\nexport type BentoLayoutSize = (typeof BentoLayoutSizeOptions)[number];\nexport type BentoLayoutRowColumnLayout = (typeof BentoLayoutRowColumnLayoutOptions)[number];\n\nexport interface BentoLayoutProps {\n /** Defines if the layout is used in a page or only a section */\n variant?: BentoLayoutVariant;\n /** Defines the size of the page */\n size?: BentoLayoutSize;\n}\n\nexport interface BentoLayoutRowProps {\n /** Sets the layout of the columns when multiple columns are used */\n columnsLayout?: BentoLayoutRowColumnLayout;\n}\n","<template>\n <bento-typography el=\"div\" class=\"b-layout-row\" :class=\"conditionalRowClass\">\n <div v-if=\"hasSlot('default')\">\n <slot />\n </div>\n <div v-else-if=\"hasSlot('col-1') && hasSlot('col-2')\" ref=\"row\" :class=\"conditionalRowWithColumnsClass\">\n <div ref=\"col1\" :class=\"conditionalColumnClass.col1\">\n <slot name=\"col-1\"></slot>\n </div>\n <div ref=\"col2\" :class=\"conditionalColumnClass.col2\">\n <slot name=\"col-2\"></slot>\n </div>\n </div>\n </bento-typography>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, inject, nextTick, onMounted, ref, type Ref, useSlots, watch } from 'vue';\n import { BentoTypography } from '@/components/typography';\n import { useHasSlot } from '@/composables';\n import {\n BentoLayoutRowColumnLayoutOptions,\n type BentoLayoutRowProps,\n type BentoLayoutSize,\n } from '../../layout.types';\n import { useMediaQuery } from '@vueuse/core';\n\n import { LAYOUT_SIZE_INJECTION_KEY } from '@/components/layout/layout.keys';\n\n const props = withDefaults(defineProps<BentoLayoutRowProps>(), {\n columnsLayout: '6-6',\n });\n\n const slots = useSlots();\n const hasSlot = useHasSlot(slots);\n const size = inject<Ref<BentoLayoutSize>>(LAYOUT_SIZE_INJECTION_KEY, ref('full-width'));\n\n const row = ref<HTMLElement>(null);\n const col1 = ref<HTMLElement>(null);\n const col2 = ref<HTMLElement>(null);\n\n const isFullWidth = computed(() => size.value === 'full-width');\n const isValidColumnLayout = computed(() => BentoLayoutRowColumnLayoutOptions.includes(props.columnsLayout));\n\n const conditionalRowClass = computed(() => `b-layout-row--${size.value}`);\n\n const conditionalRowWithColumnsClass = computed(() => ({\n 'b-layout-row__column-wrapper': isFullWidth.value,\n }));\n\n const conditionalColumnClass = computed(() => {\n const columns = isValidColumnLayout.value ? props.columnsLayout.split('-') : [6, 6];\n const getColumnModifier = index => (isFullWidth.value ? columns[index] : size.value);\n\n return {\n col1: `b-layout-row__column--${getColumnModifier(0)}`,\n col2: `b-layout-row__column--${getColumnModifier(1)}`,\n };\n });\n\n watch(\n useMediaQuery('(min-width: 768px)'),\n async isLargeScreen => {\n await nextTick();\n const areColumnsInTheRightOrder = row.value?.firstChild === col1.value;\n if (isLargeScreen && !areColumnsInTheRightOrder) {\n row.value?.prepend(col1.value);\n } else if (!isLargeScreen && (props.columnsLayout === '3-9' || props.columnsLayout === '4-8')) {\n row.value?.prepend(col2.value);\n }\n },\n { immediate: true }\n );\n\n onMounted(() => {\n if (!isFullWidth.value && (hasSlot('col-1') || hasSlot('col-2'))) {\n throw new Error(\n 'Column slots can only be used with the `full-width` size. Please check documentation for more info.'\n );\n }\n\n if (!isValidColumnLayout.value) {\n throw new Error(\n `${props.columnsLayout} is not a valid column layout. Please refer to the documentation for the list of available column layouts.`\n );\n }\n });\n</script>\n\n<script lang=\"ts\">\n /**\n * Page row is subcomponent of Layout meant to be used to generate the row layout.\n *\n * @example\n * import { BentoLayout, BentoLayoutRow } from '@adyen/bento-vue2';\n *\n * export default {\n * components: { BentoLayout, BentoLayoutRow },\n * template: `\n * <bento-layout>\n * <bento-layout-row columns-layout=\"3-9\">\n * <template #col-1>Narrow 3-9</template>\n * <template #col-2>Wide 3-9</template>\n * </bento-layout-row>\n * <bento-layout-row>\n * <template #col-1>6-6</template>\n * <template #col-2>6-6</template>\n * </bento-layout-row>\n * </bento-layout>\n * `\n * }\n */\n export default {};\n</script>\n\n<style lang=\"scss\" scoped src=\"./layout-row.scss\" />\n"],"names":["LAYOUT_SIZE_INJECTION_KEY","__default__$1","props","__props","provide","toRef","conditionalClasses","computed","wrapperElement","BentoLayoutRowColumnLayoutOptions","__default__","slots","useSlots","hasSlot","useHasSlot","size","inject","ref","row","col1","col2","isFullWidth","isValidColumnLayout","conditionalRowClass","conditionalRowWithColumnsClass","conditionalColumnClass","columns","getColumnModifier","index","watch","useMediaQuery","isLargeScreen","nextTick","areColumnsInTheRightOrder","_a","_b","_c","onMounted"],"mappings":";;;;;;AAAa,MAAAA,IAAA,OAAA,wBAAA,GC8CTC,IAAA,CAAA;;;;;;;;AAnCA,UAAAC,IAAAC;AAKA,IAAAC,EAAAJ,GAAAK,EAAAH,GAAA,MAAA,CAAA;AAEA,UAAAI,IAAAC,EAAA,OAAA;AAAA,MAA2C,uBAAAL,EAAA,YAAA;AAAA,IACE,EAAA,GAG7CM,IAAAN,EAAA,YAAA,SAAA,SAAA;;;;;;;;;;mECjBGO,IAAA,CAAA,OAAA,OAAA,OAAA,OAAA,KAAA,mBC2GHC,IAAA,CAAA;;;;;;;AAnFA,UAAAR,IAAAC,GAIAQ,IAAAC,EAAA,GACAC,IAAAC,EAAAH,CAAA,GACAI,IAAAC,EAAAhB,GAAAiB,EAAA,YAAA,CAAA,GAEAC,IAAAD,EAAA,IAAA,GACAE,IAAAF,EAAA,IAAA,GACAG,IAAAH,EAAA,IAAA,GAEAI,IAAAd,EAAA,MAAAQ,EAAA,UAAA,YAAA,GACAO,IAAAf,EAAA,MAAAE,EAAA,SAAAP,EAAA,aAAA,CAAA,GAEAqB,IAAAhB,EAAA,MAAA,iBAAAQ,EAAA,KAAA,EAAA,GAEAS,IAAAjB,EAAA,OAAA;AAAA,MAAuD,gCAAAc,EAAA;AAAA,IACP,EAAA,GAGhDI,IAAAlB,EAAA,MAAA;AACI,YAAAmB,IAAAJ,EAAA,QAAApB,EAAA,cAAA,MAAA,GAAA,IAAA,CAAA,GAAA,CAAA,GACAyB,IAAA,CAAAC,MAAAP,EAAA,QAAAK,EAAAE,CAAA,IAAAb,EAAA;AAEA,aAAA;AAAA,QAAO,MAAA,yBAAAY,EAAA,CAAA,CAAA;AAAA,QACgD,MAAA,yBAAAA,EAAA,CAAA,CAAA;AAAA,MACA;AAAA,IACvD,CAAA;AAGJ,WAAAE;AAAA,MAAAC,EAAA,oBAAA;AAAA,MACsC,OAAAC,MAAA;;AAE9B,cAAAC,EAAA;AACA,cAAAC,MAAAC,IAAAhB,EAAA,UAAA,gBAAAgB,EAAA,gBAAAf,EAAA;AACA,QAAAY,KAAA,CAAAE,KACIE,IAAAjB,EAAA,UAAA,QAAAiB,EAAA,QAAAhB,EAAA,SAA6B,CAAAY,MAAA7B,EAAA,kBAAA,SAAAA,EAAA,kBAAA,YAE7BkC,IAAAlB,EAAA,UAAA,QAAAkB,EAAA,QAAAhB,EAAA;AAAA,MACJ;AAAA,MACJ,EAAA,WAAA,GAAA;AAAA,IACkB,GAGtBiB,EAAA,MAAA;AACI,UAAA,CAAAhB,EAAA,UAAAR,EAAA,OAAA,KAAAA,EAAA,OAAA;AACI,cAAA,IAAA;AAAA,UAAU;AAAA,QACN;AAIR,UAAA,CAAAS,EAAA;AACI,cAAA,IAAA;AAAA,UAAU,GAAApB,EAAA,aAAA;AAAA,QACgB;AAAA,IAE9B,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { createElementBlock as l, openBlock as a, mergeProps as y, createCommentVNode as _, createElementVNode as E, toDisplayString as w, defineComponent as C, computed as p, createBlock as c, renderSlot as s, unref as r, withCtx as g, createVNode as L } from "vue";
|
|
2
|
-
import { B as h } from "./typography.
|
|
2
|
+
import { B as h } from "./typography.CFHvBR7L.js";
|
|
3
3
|
import { RouterLink as N } from "vue-router";
|
|
4
4
|
/* empty css */
|
|
5
5
|
import { _ as $ } from "./_plugin-vue_export-helper.CHgC5LLL.js";
|
|
@@ -113,4 +113,4 @@ export {
|
|
|
113
113
|
U as E,
|
|
114
114
|
i as a
|
|
115
115
|
};
|
|
116
|
-
//# sourceMappingURL=link.
|
|
116
|
+
//# sourceMappingURL=link.Di0rtpOj.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"link.
|
|
1
|
+
{"version":3,"file":"link.Di0rtpOj.js","sources":["../../../core/src/components/link/link.types.ts","../../../ui-assets/icons-16/dist/vue/external-link.vue","../../src/components/link/link.vue"],"sourcesContent":["/**\n * @deprecated for usage with properties since version 2.0. Use the string literal instead.\n */\nexport enum BentoLinkVariant {\n DEFAULT = 'default',\n QUIET = 'quiet',\n}\n\nexport interface LinkProps {\n /**\n * Disable the default typography for the component. Only use this when the component is inside another typography component.\n */\n disableTypography?: boolean;\n\n /**\n * Set the rendered link to a regular external anchor link and renders an external link icon.\n */\n external?: boolean;\n\n /**\n * Set to true if used inside a `BentoButton` component.\n */\n isButton?: boolean;\n\n /**\n * Set the rendered link to a regular external anchor link.\n */\n isNotRouting?: boolean;\n\n /**\n * Sets the target of the rendered link.\n */\n target?: string;\n\n /**\n * Set to true to truncate link. Doesn't work with disableTypography.\n */\n truncate?: boolean;\n\n /**\n * Link variant type affecting visual style.\n * @values default, quiet\n */\n variant?: BentoLinkVariant | `${BentoLinkVariant}`;\n}\n","\n<template>\n <svg role=\"img\" v-bind=\"$attrs\" class=\"ui-assets-icons-16\" xmlns=\"http://www.w3.org/2000/svg\" width=\"16\" height=\"16\" fill=\"none\"><title v-if=\"$attrs['svg-title']\">{{ $attrs['svg-title'] }}</title><path fill=\"#001222\" d=\"M2.93933 11.9999L10.1893 4.74989H5.24999V3.24989H12.75V10.7499H11.25V5.81055L3.99999 13.0605L2.93933 11.9999Z\"/></svg>\n</template>\n<script>\n import '../css/main.css';\n\n let uuid = 0;\n\n export default {\n beforeCreate() {\n this.uuid = uuid.toString();\n uuid += 1;\n },\n };\n</script>\n","<template>\n <a\n v-if=\"external || isNotRouting\"\n v-bind=\"$attrs\"\n :href=\"to?.toString()\"\n :target=\"computedTarget\"\n :class=\"conditionalClasses\"\n @click=\"onClick\"\n >\n <bento-typography v-if=\"!disableTypography\" class=\"b-link__text\" el=\"span\" variant=\"body\">\n <slot />\n </bento-typography>\n <slot v-else />\n <span v-if=\"showExternalLinkIcon\" class=\"b-link__external-link-icon\">\n <external-link-icon aria-hidden=\"true\" />\n </span>\n </a>\n <router-link\n v-else\n v-bind=\"{ ...props, ...$attrs, ...nonForwardedProps }\"\n :to=\"props.to\"\n :class=\"conditionalClasses\"\n :target=\"target\"\n @click=\"onClick\"\n >\n <bento-typography v-if=\"!disableTypography\" class=\"b-link__text\" el=\"span\" variant=\"body\">\n <slot />\n </bento-typography>\n <slot v-else />\n </router-link>\n</template>\n\n<script setup lang=\"ts\">\n import { BentoLinkVariant } from '@/core/components/link/link.types';\n import { BentoTypography } from '@/components/typography';\n import { computed } from 'vue';\n import { RouterLink } from 'vue-router';\n import type { BentoLinkProps } from './link.types';\n\n import ExternalLinkIcon from '@adyen/ui-assets-icons-16/vue/external-link';\n\n const props = withDefaults(defineProps<BentoLinkProps>(), {\n target: null,\n variant: BentoLinkVariant.DEFAULT,\n });\n\n // Props that should not be forwarded to the underlying anchor element\n const nonForwardedProps = {\n variant: undefined,\n isButton: undefined,\n truncate: undefined,\n disableTypography: undefined,\n external: undefined,\n isNotRouting: undefined,\n };\n\n const emit = defineEmits(['click']);\n const conditionalClasses = computed(() => ({\n 'b-link': !props.isButton,\n [`b-link--${BentoLinkVariant.QUIET}`]: props.variant === BentoLinkVariant.QUIET,\n [`b-link--truncate`]: props.truncate,\n }));\n const computedTarget = computed(() => (props.external ? (props.target ?? '_blank') : props.target));\n const showExternalLinkIcon = computed(() => !(props.isButton || props.isNotRouting));\n\n // eslint-disable-next-line @typescript-eslint/no-explicit-any\n const onClick = (e: MouseEvent, navigateCallback?: any) => {\n emit('click', e);\n if (navigateCallback) {\n navigateCallback();\n }\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"@/core/components/link/link.scss\" />\n"],"names":["BentoLinkVariant","BentoLinkVariant2","uuid","openBlock","createElementBlock","mergeProps","_ctx","createCommentVNode","props","__props","nonForwardedProps","emit","__emit","conditionalClasses","computed","computedTarget","showExternalLinkIcon","onClick","e","navigateCallback"],"mappings":";;;;;;AAGY,IAAAA,IAAA,kBAAAC,OACRA,EAAA,UAAA,WACAA,EAAA,QAAA,SAFQA,IAAAD,KAAA,CAAA,CAAA;ACIR,IAAAE,IAAA;;EAGI,eAAA;8BAEIA,KAAA;AAAA;;;AAVR,SAAAC,EAAA,GAAAC,EAAA,OAAAC,EAAA,EAAA,MAAA,MAAA,GAAAC,EAAA,QAAA;AAAA,IAAgC,OAAA;AAAA,IAA2B,OAAA;AAAA,IAAmC,OAAA;AAAA,IAAW,QAAA;AAAA,IAAY,MAAA;AAAA;gFAFzHC,EAAA,IAAA,EAAA;AAAA;MAE8M,MAAA;AAAA,MAAe,GAAA;AAAA;;;;;;;;;;;;;;;;;;;;;;;;;ACuCzN,UAAAC,IAAAC,GAMAC,IAAA;AAAA,MAA0B,SAAA;AAAA,MACb,UAAA;AAAA,MACC,UAAA;AAAA,MACA,mBAAA;AAAA,MACS,UAAA;AAAA,MACT,cAAA;AAAA,IACI,GAGlBC,IAAAC,GACAC,IAAAC,EAAA,OAAA;AAAA,MAA2C,UAAA,CAAAN,EAAA;AAAA,MACtB,CAAA,WAAAR,EAAA,KAAA,EAAA,GAAAQ,EAAA,YAAAR,EAAA;AAAA,MACyD,oBAAAQ,EAAA;AAAA,IAC9C,EAAA,GAEhCO,IAAAD,EAAA,MAAAN,EAAA,WAAAA,EAAA,UAAA,WAAAA,EAAA,MAAA,GACAQ,IAAAF,EAAA,MAAA,EAAAN,EAAA,YAAAA,EAAA,aAAA,GAGAS,IAAA,CAAAC,GAAAC,MAAA;AACI,MAAAR,EAAA,SAAAO,CAAA,GACAC,KACIA,EAAA;AAAA,IACJ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;"}
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { defineComponent as r, computed as i, resolveComponent as t, createElementBlock as s, openBlock as e, createElementVNode as l, createBlock as c, createCommentVNode as m, createVNode as _, withCtx as d, createTextVNode as b, toDisplayString as g } from "vue";
|
|
2
|
-
import { B as u } from "./tag.
|
|
3
|
-
import { B as f } from "./typography.
|
|
2
|
+
import { B as u } from "./tag.BP8fBCx-.js";
|
|
3
|
+
import { B as f } from "./typography.CFHvBR7L.js";
|
|
4
4
|
import { _ as h } from "./_plugin-vue_export-helper.CHgC5LLL.js";
|
|
5
5
|
import "../assets/listbox-option-tag.css";
|
|
6
6
|
const y = r({
|
|
@@ -26,13 +26,13 @@ const y = r({
|
|
|
26
26
|
};
|
|
27
27
|
}
|
|
28
28
|
}), v = { class: "b-listbox-tag-option" }, B = ["aria-hidden"];
|
|
29
|
-
function x(o,
|
|
30
|
-
const
|
|
29
|
+
function x(o, n, k, C, N, T) {
|
|
30
|
+
const a = t("bento-tag"), p = t("bento-typography");
|
|
31
31
|
return e(), s("span", v, [
|
|
32
32
|
l("span", {
|
|
33
33
|
"aria-hidden": !!o.option.label
|
|
34
34
|
}, [
|
|
35
|
-
_(
|
|
35
|
+
_(a, {
|
|
36
36
|
class: "b-listbox-tag-option__tag",
|
|
37
37
|
label: o.option.value.toString(),
|
|
38
38
|
variant: o.variant
|
|
@@ -50,8 +50,8 @@ function x(o, a, k, C, N, T) {
|
|
|
50
50
|
})) : m("", !0)
|
|
51
51
|
]);
|
|
52
52
|
}
|
|
53
|
-
const O = /* @__PURE__ */ h(y, [["render", x], ["__scopeId", "data-v-
|
|
53
|
+
const O = /* @__PURE__ */ h(y, [["render", x], ["__scopeId", "data-v-68f1810e"]]);
|
|
54
54
|
export {
|
|
55
55
|
O as L
|
|
56
56
|
};
|
|
57
|
-
//# sourceMappingURL=listbox-option-tag.
|
|
57
|
+
//# sourceMappingURL=listbox-option-tag.C6WHiASI.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"listbox-option-tag.C6WHiASI.js","sources":["../../../vue2/src/components/internal/listbox/components/listbox-option-tag/listbox-option-tag.vue"],"sourcesContent":["<template>\n <span class=\"b-listbox-tag-option\">\n <span :aria-hidden=\"!!option.label\">\n <bento-tag class=\"b-listbox-tag-option__tag\" :label=\"option.value.toString()\" :variant=\"variant\" />\n </span>\n <bento-typography v-if=\"option.label\" el=\"span\" class=\"b-listbox-tag-option__label\">\n {{ option.label }}\n </bento-typography>\n </span>\n</template>\n<script lang=\"ts\">\n import { computed, defineComponent, type PropType } from 'vue';\n import type { BentoListboxOptionItem } from '@/types';\n import { BentoTag, type BentoTagVariant } from '@/components/tag';\n import { BentoTypography } from '@/components/typography';\n\n /**\n * A Tag Dropdown option item used in the Dropdown and Filter components.\n */\n export default defineComponent({\n name: 'listbox-tag-option',\n components: {\n BentoTag,\n BentoTypography,\n },\n props: {\n /**\n * The option item that contains all the option item's data.\n * @type {BentoListboxOptionItem}\n */\n option: {\n type: Object as PropType<BentoListboxOptionItem>,\n required: true,\n },\n },\n setup(props) {\n const variant = computed(() => props.option.data as BentoTagVariant);\n\n return {\n // Values\n variant,\n };\n },\n });\n</script>\n<style lang=\"scss\" scoped src=\"./listbox-option-tag.scss\" />\n"],"names":["_sfc_main","defineComponent","BentoTag","BentoTypography","props","computed","openBlock","createElementBlock","_hoisted_1","createElementVNode","_ctx","_hoisted_2","createTextVNode","toDisplayString","createCommentVNode"],"mappings":";;;;;AAmBI,MAAAA,IAAAC,EAAA;AAAA,EAA+B,MAAA;AAAA,EACrB,YAAA;AAAA,IACM,UAAAC;AAAA,IACR,iBAAAC;AAAA,EACA;AAAA,EACJ,OAAA;AAAA;AAAA;AAAA;AAAA;AAAA,IACO,QAAA;AAAA,MAKK,MAAA;AAAA,MACE,UAAA;AAAA,IACI;AAAA,EACd;AAAA,EACJ,MAAAC,GAAA;AAII,WAAA;AAAA;AAAA,MAAO,SAFPC,EAAA,MAAAD,EAAA,OAAA,IAAA;AAAA,IAII;AAAA,EACJ;AAER,CAAA;;;AAzCW,SAAAE,EAAA,GAAAC,EAAA,QAAAC,GAAA;AAAA,IAA2BC,EAAA,QAAA;AAAA;IACqE,GAAA;AAAA;QAAzB,OAAA;AAAA,QAAY,OAAAC,EAAA,OAAA,MAAA,SAAA;AAAA,QAHlG,SAAAA,EAAA;AAAA,MAAA,GAAA,MAAA,GAAA,CAAA,SAAA,SAAA,CAAA;AAAA,IAK4C,GAAA,GAAAC,CAAA;AAAA;MAAW,KAAA;AAAA,MAAM,IAAA;AAAA,MAL7D,OAAA;AAAA,IAAA,GAAA;AAAA;QAAAC,EAAAC,EAAAH,EAAA,OAAA,KAAA,GAAA,CAAA;AAAA,MAAA,CAAA;AAAA,MAAA,GAAA;AAAA,IAAA,CAAA,KAAAI,EAAA,IAAA,EAAA;AAAA;;;"}
|
|
@@ -36,9 +36,9 @@ function u(a, n, o, f, g, _) {
|
|
|
36
36
|
"data-testid": "loading-indicator"
|
|
37
37
|
}, null, 2);
|
|
38
38
|
}
|
|
39
|
-
const
|
|
39
|
+
const T = /* @__PURE__ */ m(p, [["render", u], ["__scopeId", "data-v-757d02b0"]]);
|
|
40
40
|
export {
|
|
41
|
-
|
|
41
|
+
T as B,
|
|
42
42
|
e as a
|
|
43
43
|
};
|
|
44
|
-
//# sourceMappingURL=loading-indicator.
|
|
44
|
+
//# sourceMappingURL=loading-indicator.BmAQqPP2.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"loading-indicator.BmAQqPP2.js","sources":["../../../vue2/src/components/loading-indicator/loading-indicator.types.ts","../../../vue2/src/components/loading-indicator/loading-indicator.vue"],"sourcesContent":["export enum BentoLoadingIndicatorEvent {\n START = 'loading-start',\n END = 'loading-end',\n}\n","<template>\n <div class=\"b-loading-indicator\" :class=\"conditionalClasses\" aria-hidden=\"true\" data-testid=\"loading-indicator\" />\n</template>\n\n<script lang=\"ts\">\n import { computed, defineComponent, onMounted, onUnmounted } from 'vue';\n import { BentoLoadingIndicatorEvent } from './loading-indicator.types';\n\n export default defineComponent({\n name: 'bento-loading-indicator',\n props: {\n /**\n * Displays the loading indicator in a small size\n */\n small: { type: Boolean, default: false },\n /**\n * Displays the loading indicator in a large size\n */\n large: { type: Boolean, default: false },\n /**\n * Displays the loading indicator in a white variant\n */\n inverse: { type: Boolean, default: false },\n },\n emits: [BentoLoadingIndicatorEvent.START, BentoLoadingIndicatorEvent.END],\n setup(props, { emit }) {\n onMounted(() => emit(BentoLoadingIndicatorEvent.START));\n\n onUnmounted(() => emit(BentoLoadingIndicatorEvent.END));\n\n const conditionalClasses = computed(() => ({\n 'b-loading-indicator--inverse': props.inverse,\n 'b-loading-indicator--small': props.small,\n 'b-loading-indicator--large': props.large,\n }));\n\n return {\n conditionalClasses,\n };\n },\n });\n</script>\n\n<style lang=\"scss\" scoped src=\"@/core/components/loading-indicator/loading-indicator.scss\" />\n"],"names":["BentoLoadingIndicatorEvent","BentoLoadingIndicatorEvent2","_sfc_main","defineComponent","props","emit","onMounted","onUnmounted","computed","_sfc_render","_ctx","_cache","$props","$setup","$data","$options","openBlock","createElementBlock","normalizeClass"],"mappings":";;;AAAY,IAAAA,IAAA,kBAAAC,OACRA,EAAA,QAAA,iBACAA,EAAA,MAAA,eAFQA,IAAAD,KAAA,CAAA,CAAA;ACQR,MAAAE,IAAAC,EAAA;AAAA,EAA+B,MAAA;AAAA,EACrB,OAAA;AAAA;AAAA;AAAA;AAAA,IACC,OAAA,EAAA,MAAA,SAAA,SAAA,GAAA;AAAA;AAAA;AAAA;AAAA,IAIoC,OAAA,EAAA,MAAA,SAAA,SAAA,GAAA;AAAA;AAAA;AAAA;AAAA,IAIA,SAAA,EAAA,MAAA,SAAA,SAAA,GAAA;AAAA,EAIE;AAAA,EAC7C,OAAA,CAAAH,EAAA,OAAAA,EAAA,GAAA;AAAA,EACwE,MAAAI,GAAA,EAAA,MAAAC,EAAA,GAAA;AAEpE,WAAAC,EAAA,MAAAD,EAAAL,EAAA,KAAA,CAAA,GAEAO,EAAA,MAAAF,EAAAL,EAAA,GAAA,CAAA,GAQA;AAAA,MAAO,oBANPQ,EAAA,OAAA;AAAA,QAA2C,gCAAAJ,EAAA;AAAA,QACD,8BAAAA,EAAA;AAAA,QACF,8BAAAA,EAAA;AAAA,MACA,EAAA;AAAA,IAIpC;AAAA,EACJ;AAER,CAAA;AAvCU,SAAAK,EAAAC,GAAAC,GAAAC,GAAAC,GAAAC,GAAAC,GAAA;AAAmD,SAAAC,EAAA,GAAAC,EAAA,OAAA;AAAA,IAAkB,OAAAC,EAAA,CAAA,uBAAAR,EAAA,kBAAA,CAAA;AAAA,IAAgC,eAAA;AAAA;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"minus-small.DYIyF5XW.js","sources":["../../../
|
|
1
|
+
{"version":3,"file":"minus-small.DYIyF5XW.js","sources":["../../../vue2/src/components/internal/checkbox-input/checkbox-input.types.ts","../../../ui-assets/icons-16/dist/vue/minus-small.vue"],"sourcesContent":["export type MultiCheckboxInputType = Array<string | number>;\nexport type CheckboxInputType = boolean | MultiCheckboxInputType;\n\nexport enum CheckboxInputState {\n UNCHECKED = 'unchecked',\n CHECKED = 'checked',\n DISABLED = 'disabled',\n ERROR = 'error',\n READONLY = 'readonly',\n INDETERMINATE = 'indeterminate',\n}\n\nexport enum CheckboxInputEvent {\n UPDATE = 'update:model-value',\n}\n\ninterface CheckboxInputGroupItem {\n value: string | number;\n disabled?: boolean;\n hasError?: boolean;\n errorMessage?: string;\n readonly?: boolean;\n}\n\nexport type CheckboxInputGroupItems = Array<CheckboxInputGroupItem>;\n","\n<template>\n <svg role=\"img\" v-bind=\"$attrs\" class=\"ui-assets-icons-16\" xmlns=\"http://www.w3.org/2000/svg\" width=\"16\" height=\"16\" fill=\"none\"><title v-if=\"$attrs['svg-title']\">{{ $attrs['svg-title'] }}</title><path fill=\"#001222\" d=\"M4.25 7.25H11.75V8.75H4.25V7.25Z\"/></svg>\n</template>\n<script>\n import '../css/main.css';\n\n let uuid = 0;\n\n export default {\n beforeCreate() {\n this.uuid = uuid.toString();\n uuid += 1;\n },\n };\n</script>\n"],"names":["CheckboxInputState","CheckboxInputEvent","uuid","_sfc_main","_openBlock","_createElementBlock","_mergeProps","_ctx","_hoisted_1","_createCommentVNode","_createElementVNode"],"mappings":";;;AAGY,IAAAA,sBAAAA,OACRA,EAAA,YAAY,aACZA,EAAA,UAAU,WACVA,EAAA,WAAW,YACXA,EAAA,QAAQ,SACRA,EAAA,WAAW,YACXA,EAAA,gBAAgB,iBANRA,IAAAA,KAAA,CAAA,CAAA,GASAC,sBAAAA,OACRA,EAAA,SAAS,sBADDA,IAAAA,KAAA,CAAA,CAAA;ACLR,IAAIC,IAAO;AAEX,MAAKC,IAAU;AAAA,EACX,eAAe;AACX,SAAK,OAAOD,EAAK,SAAU,GAC3BA,KAAQ;AAAA,EACX;AACJ,SAdL,KAAA,EAAA;;AAEI,SAAAE,EAAA,GAAAC,EAAqQ,OAArQC,EAAqQ,EAAhQ,MAAK,MAAK,GAASC,EAAM,QAAA;AAAA,IAAE,OAAM;AAAA,IAAqB,OAAM;AAAA,IAA6B,OAAM;AAAA,IAAK,QAAO;AAAA,IAAK,MAAK;AAAA;IAAoBA,EAAM,OAAA,WAAA,UAAnBF,EAAmE,SAFxMG,KAE0KD,EAAM,OAAA,WAAA,CAAA,GAAA,CAAA,KAFhLE,EAAA,IAAA,EAAA;AAAA,oBAEwMC,EAA2D,QAAA;AAAA,MAArD,MAAK;AAAA,MAAU,GAAE;AAAA;;;;"}
|
|
@@ -1,15 +1,14 @@
|
|
|
1
1
|
import { defineComponent as k, useSlots as w, onMounted as U, createBlock as u, openBlock as l, unref as a, withCtx as o, createElementVNode as c, renderSlot as p, createElementBlock as O, createCommentVNode as m, createTextVNode as S, toDisplayString as N, getCurrentInstance as Y, toRefs as j, ref as r, computed as z, watch as H, nextTick as q, provide as B, withKeys as Q, normalizeClass as W, withModifiers as X, createSlots as Z, createVNode as A } from "vue";
|
|
2
|
-
import { B as ee } from "./button.
|
|
3
|
-
import { B as te } from "./focus-trap.
|
|
4
|
-
import { B as L } from "./typography.
|
|
2
|
+
import { B as ee } from "./button.wMNce6wZ.js";
|
|
3
|
+
import { B as te } from "./focus-trap.rjp24a37.js";
|
|
4
|
+
import { B as L } from "./typography.CFHvBR7L.js";
|
|
5
5
|
import { u as x } from "./use-has-slot.B7eQSabc.js";
|
|
6
|
-
import { D as ae, B as le, b as oe, a as se } from "./dialog-page.
|
|
7
|
-
import { B as ne } from "./button
|
|
6
|
+
import { D as ae, B as le, b as oe, a as se } from "./dialog-page.BJaRwRhF.js";
|
|
7
|
+
import { B as ne, i as ie } from "./toggle-button.ByyLw0Yf.js";
|
|
8
8
|
import { _ as D } from "./_plugin-vue_export-helper.CHgC5LLL.js";
|
|
9
|
-
import { C as
|
|
10
|
-
import { u as
|
|
11
|
-
import { g as
|
|
12
|
-
import { M as ue } from "./modal-fullscreen.keys.CMba3hYp.js";
|
|
9
|
+
import { C as re } from "./cross.B92GxFTY.js";
|
|
10
|
+
import { u as ce } from "./i18n.B6g5VX0q.js";
|
|
11
|
+
import { g as ue } from "./generate-uid.NJ8tVoha.js";
|
|
13
12
|
import "../assets/modal-fullscreen.css";
|
|
14
13
|
const de = { class: "b-modal-fullscreen-page__header" }, fe = { class: "b-modal-fullscreen-page__header-section b-modal-fullscreen-page__header-section--title" }, me = {
|
|
15
14
|
key: 0,
|
|
@@ -122,12 +121,12 @@ const de = { class: "b-modal-fullscreen-page__header" }, fe = { class: "b-modal-
|
|
|
122
121
|
_: 3
|
|
123
122
|
}, 8, ["page-id", "previous-page"]));
|
|
124
123
|
}
|
|
125
|
-
}), he = /* @__PURE__ */ D(_e, [["__scopeId", "data-v-
|
|
124
|
+
}), he = /* @__PURE__ */ D(_e, [["__scopeId", "data-v-a1480899"]]);
|
|
126
125
|
function be() {
|
|
127
126
|
var e;
|
|
128
127
|
return ((e = Y()) == null ? void 0 : e.vnode.props) ?? {};
|
|
129
128
|
}
|
|
130
|
-
const
|
|
129
|
+
const T = {
|
|
131
130
|
"en-US": {
|
|
132
131
|
close: "Close"
|
|
133
132
|
},
|
|
@@ -138,7 +137,7 @@ const M = {
|
|
|
138
137
|
close: "Fechar"
|
|
139
138
|
}
|
|
140
139
|
}, ye = ["id", "onKeydown"], Be = { class: "b-modal-fullscreen__close-button" }, Ee = {
|
|
141
|
-
i18n: { messages:
|
|
140
|
+
i18n: { messages: T }
|
|
142
141
|
}, Ie = /* @__PURE__ */ k({
|
|
143
142
|
...Ee,
|
|
144
143
|
__name: "modal-fullscreen",
|
|
@@ -189,7 +188,7 @@ const M = {
|
|
|
189
188
|
},
|
|
190
189
|
emits: ["before-close", "update:active-page", "update:is-open"],
|
|
191
190
|
setup(e, { emit: v }) {
|
|
192
|
-
const g = e, s = v, { activePage: d, isOpen: f } = j(g), { t:
|
|
191
|
+
const g = e, s = v, { activePage: d, isOpen: f } = j(g), { t: M } = ce({ messages: T }), n = r(null), _ = r(!1), E = ue("modal-fullscreen"), h = r(!1), $ = be(), F = w(), I = x(F), G = z(() => ({
|
|
193
192
|
"b-modal-fullscreen--hide": _.value
|
|
194
193
|
})), R = () => {
|
|
195
194
|
_.value && (n.value.close(), i.value[0] && s("update:active-page", i.value[0]), i.value = [], _.value = !1, h.value = !1, s("update:is-open", !1));
|
|
@@ -210,7 +209,7 @@ const M = {
|
|
|
210
209
|
await q(), n.value && (f.value ? (h.value = !0, n.value.showModal(), i.value.length || i.value.push(d.value)) : n.value.open && C());
|
|
211
210
|
},
|
|
212
211
|
{ immediate: !0 }
|
|
213
|
-
), B(
|
|
212
|
+
), B(ie, E);
|
|
214
213
|
const K = r(le.TRANSITION_LEVEL_DEEPER), b = r([]), i = r([]);
|
|
215
214
|
B(oe, {
|
|
216
215
|
activePage: d,
|
|
@@ -261,11 +260,11 @@ const M = {
|
|
|
261
260
|
c("div", Be, [
|
|
262
261
|
A(a(ee), {
|
|
263
262
|
variant: "tertiary",
|
|
264
|
-
"aria-label": a(
|
|
263
|
+
"aria-label": a(M)("close"),
|
|
265
264
|
onClick: P
|
|
266
265
|
}, {
|
|
267
266
|
iconLeft: o(() => [
|
|
268
|
-
A(a(
|
|
267
|
+
A(a(re), { "aria-hidden": !0 })
|
|
269
268
|
]),
|
|
270
269
|
_: 1
|
|
271
270
|
}, 8, ["aria-label"])
|
|
@@ -275,9 +274,9 @@ const M = {
|
|
|
275
274
|
})) : m("", !0)
|
|
276
275
|
], 42, ye));
|
|
277
276
|
}
|
|
278
|
-
}),
|
|
277
|
+
}), $e = /* @__PURE__ */ D(Ie, [["__scopeId", "data-v-cb49a06b"]]);
|
|
279
278
|
export {
|
|
280
279
|
he as B,
|
|
281
|
-
|
|
280
|
+
$e as m
|
|
282
281
|
};
|
|
283
|
-
//# sourceMappingURL=modal-fullscreen.
|
|
282
|
+
//# sourceMappingURL=modal-fullscreen.BHzyS4y7.js.map
|