@adyen/bento-vue3 1.9.0 → 1.11.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 +2 -0
- package/dist/@types/packages/vue2/src/components/button/button.vue.d.ts +23 -2455
- package/dist/@types/packages/vue2/src/components/button/components/button-actions/button-actions.types.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/button/components/loading-button/loading-button.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/checkbox/checkbox.vue.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/checkbox/components/checkbox-group/checkbox-group.vue.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/code-snippet/{composables/useLanguage.d.ts → utils/get-lang-loader.d.ts} +1 -3
- package/dist/@types/packages/vue2/src/components/country/composables/index.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/country/composables/{useCountryCapital/useCountryCapital.d.ts → use-country-capital/use-country-capital.d.ts} +1 -1
- package/dist/@types/packages/vue2/src/components/country/composables/{useCountryName/useCountryName.d.ts → use-country-name/use-country-name.d.ts} +1 -1
- package/dist/@types/packages/vue2/src/components/country/composables/{useCountryPhoneCode/useCountryPhoneCode.d.ts → use-country-phone-code/use-country-phon-code.d.ts} +1 -1
- package/dist/@types/packages/vue2/src/components/country/country.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/data-grid/components/data-grid-cell-actions/data-grid-cell-actions.types.d.ts +14 -0
- package/dist/@types/packages/vue2/src/components/data-grid/components/data-grid-cell-actions/data-grid-cell-actions.vue.d.ts +33 -0
- package/dist/@types/packages/vue2/src/components/data-grid/components/data-grid-columns/data-grid-columns-types.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/data-grid/components/data-grid-columns/data-grid-columns.vue.d.ts +21 -4
- package/dist/@types/packages/vue2/src/components/data-grid/components/index.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/data-grid/composables/index.d.ts +10 -8
- package/dist/@types/packages/vue2/src/components/data-grid/composables/use-calculate-column-width/index.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/data-grid/composables/{useCalculateColumnWidth/useCalculateColumnWidth.d.ts → use-calculate-column-width/use-calculate-column-width.d.ts} +2 -2
- package/dist/@types/packages/vue2/src/components/data-grid/composables/use-column-reorderer/use-column-reorderer.d.ts +121 -0
- package/dist/@types/packages/vue2/src/components/data-grid/composables/use-config-settings/use-config-settings.d.ts +154 -0
- package/dist/@types/packages/vue2/src/components/data-grid/composables/{useKeyboardNavigator/useKeyboardNavigator.d.ts → use-keyboard-navigator/use-keyboard-navigator.d.ts} +1 -1
- package/dist/@types/packages/vue2/src/components/data-grid/composables/{useResizer.d.ts → use-resizer.d.ts} +0 -1
- package/dist/@types/packages/vue2/src/components/data-grid/composables/{useScroller/useScroller.d.ts → use-scroller/use-scroller.d.ts} +1 -1
- package/dist/@types/packages/vue2/src/components/data-grid/composables/{useSelector.d.ts → use-selector.d.ts} +1 -1
- package/dist/@types/packages/vue2/src/components/data-grid/data-grid.types.d.ts +5 -2
- package/dist/@types/packages/vue2/src/components/data-grid/data-grid.vue.d.ts +15 -5
- package/dist/@types/packages/vue2/src/components/divider/divider.keys.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-base-textbox/dropdown-base-textbox.types.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-base-textbox/dropdown-base-textbox.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-default-textbox/dropdown-default-textbox.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-options-container/composables/useDropdownOptionsListbox.d.ts +2 -1
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-options-container/dropdown-options-container.vue.d.ts +16 -6
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-small-textbox/dropdown-small-textbox.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/dropdown/composables/useDisplayValue.types.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/dropdown/dropdown.vue.d.ts +2355 -6
- package/dist/@types/packages/vue2/src/components/empty-state/empty-state.types.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/empty-state/empty-state.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/filter-bar/components/all-filters-modal/all-filters-modal.vue.d.ts +84 -12
- package/dist/@types/packages/vue2/src/components/filter-bar/filter-bar.types.d.ts +3 -1
- package/dist/@types/packages/vue2/src/components/internal/controls-group/controls-group.vue.d.ts +8 -0
- package/dist/@types/packages/vue2/src/components/internal/copy/copy.types.d.ts +8 -0
- package/dist/@types/packages/vue2/src/components/internal/copy/copy.vue.d.ts +20 -0
- package/dist/@types/packages/vue2/src/components/internal/copy/index.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-multi-select/components/listbox-multi-select-options/components/listbox-multi-select-category/listbox-multi-select-category.types.d.ts +2 -1
- package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-multi-select/components/listbox-multi-select-options/components/listbox-multi-select-category/listbox-multi-select-category.vue.d.ts +51 -0
- package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-multi-select/components/listbox-multi-select-options/listbox-multi-select-options.vue.d.ts +10 -0
- package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-multi-select/listbox-multi-select.vue.d.ts +9 -0
- package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-single-select/components/listbox-single-select-category/index.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-single-select/components/listbox-single-select-category/listbox-single-select-category.vue.d.ts +12 -0
- package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-single-select/listbox-single-select.vue.d.ts +10 -0
- package/dist/@types/packages/vue2/src/components/internal/listbox/composables/use-multi-level-items/use-multi-level-items.d.ts +6 -0
- package/dist/@types/packages/vue2/src/components/internal/listbox/index.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/internal/listbox/listbox.vue.d.ts +11 -2
- package/dist/@types/packages/vue2/src/components/menu/components/menu-item/menu-item.types.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/menu/components/menu-item/menu-item.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/menu/components/sub-menu-item-list/sub-menu-item-list.vue.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/menu/menu.vue.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/modal/components/base-modal/base-modal.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/modal/components/modal-dialog/modal-dialog.vue.d.ts +316 -3
- package/dist/@types/packages/vue2/src/components/popover/popover.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/radio-group/radio-group.vue.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/secondary-nav/components/secondary-nav-category/index.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/secondary-nav/components/secondary-nav-category/secondary-nav-category.vue.d.ts +18 -0
- package/dist/@types/packages/vue2/src/components/secondary-nav/components/secondary-nav-item/index.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/secondary-nav/components/secondary-nav-item/secondary-nav-item.vue.d.ts +21 -0
- package/dist/@types/packages/vue2/src/components/secondary-nav/index.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/secondary-nav/secondary-nav.keys.d.ts +3 -0
- package/dist/@types/packages/vue2/src/components/secondary-nav/secondary-nav.types.d.ts +14 -0
- package/dist/@types/packages/vue2/src/components/secondary-nav/secondary-nav.vue.d.ts +22 -0
- package/dist/@types/packages/vue2/src/components/structured-list/components/structered-list-item/structured-list-item.vue.d.ts +3 -4
- package/dist/@types/packages/vue2/src/components/structured-list/structured-list.types.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/structured-list/structured-list.vue.d.ts +15 -2
- package/dist/@types/packages/vue2/src/components/timeline/components/timeline-item/timeline-item.vue.d.ts +15 -10
- package/dist/@types/packages/vue2/src/components/timeline/timeline.types.d.ts +9 -0
- package/dist/@types/packages/vue2/src/index.d.ts +1 -0
- package/dist/@types/packages/vue2/src/types/elements.d.ts +2 -1
- package/dist/@types/packages/vue2/src/utils/ts/deprecate.d.ts +1 -0
- package/dist/accordion.js +2 -2
- package/dist/action-bar.js +5 -5
- package/dist/alert.js +23 -23
- package/dist/alert.js.map +1 -1
- package/dist/assets/base-modal.css +1 -1
- package/dist/assets/button.css +1 -1
- package/dist/assets/checkbox.css +1 -1
- package/dist/assets/controls-group.css +1 -1
- package/dist/assets/copy.css +1 -1
- package/dist/assets/dropdown-default-textbox.css +1 -1
- package/dist/assets/dropdown.css +1 -1
- package/dist/assets/fixed-scroller.css +1 -1
- package/dist/assets/index.css +1 -1
- package/dist/assets/index10.css +1 -1
- package/dist/assets/index11.css +1 -1
- package/dist/assets/index12.css +1 -1
- package/dist/assets/index13.css +1 -1
- package/dist/assets/index14.css +1 -1
- package/dist/assets/index16.css +1 -1
- package/dist/assets/index17.css +1 -1
- package/dist/assets/index18.css +1 -1
- package/dist/assets/index19.css +1 -1
- package/dist/assets/index2.css +1 -1
- package/dist/assets/index20.css +1 -1
- package/dist/assets/index21.css +1 -1
- package/dist/assets/index22.css +1 -1
- package/dist/assets/index23.css +1 -1
- package/dist/assets/index24.css +1 -1
- package/dist/assets/index25.css +1 -1
- package/dist/assets/index26.css +1 -1
- package/dist/assets/index27.css +1 -1
- package/dist/assets/index28.css +1 -1
- package/dist/assets/index29.css +1 -1
- package/dist/assets/index3.css +1 -1
- package/dist/assets/index30.css +1 -1
- package/dist/assets/index31.css +1 -1
- package/dist/assets/index32.css +1 -1
- package/dist/assets/index33.css +1 -1
- package/dist/assets/index34.css +1 -1
- package/dist/assets/index35.css +1 -1
- package/dist/assets/index36.css +1 -1
- package/dist/assets/index37.css +1 -1
- package/dist/assets/index38.css +1 -1
- package/dist/assets/index39.css +1 -1
- package/dist/assets/index4.css +1 -1
- package/dist/assets/index40.css +1 -1
- package/dist/assets/index41.css +1 -1
- package/dist/assets/index42.css +1 -1
- package/dist/assets/index43.css +1 -1
- package/dist/assets/index44.css +1 -1
- package/dist/assets/index45.css +1 -1
- package/dist/assets/index46.css +1 -1
- package/dist/assets/index47.css +1 -0
- package/dist/assets/index5.css +1 -1
- package/dist/assets/index6.css +1 -1
- package/dist/assets/index7.css +1 -1
- package/dist/assets/index9.css +1 -1
- package/dist/assets/listbox.css +1 -1
- package/dist/assets/loading-button.css +1 -1
- package/dist/avatar-image.js +1 -1
- package/dist/badge.js +1 -1
- package/dist/button.js +57 -46
- package/dist/button.js.map +1 -1
- package/dist/card.js +2 -2
- package/dist/checkbox.js +73 -54
- package/dist/checkbox.js.map +1 -1
- package/dist/chunks/{base-button.aa085dfa.js → base-button.39fae75f.js} +2 -2
- package/dist/chunks/{base-button.aa085dfa.js.map → base-button.39fae75f.js.map} +1 -1
- package/dist/chunks/{base-modal.a629cb32.js → base-modal.161ce8f0.js} +86 -86
- package/dist/chunks/base-modal.161ce8f0.js.map +1 -0
- package/dist/chunks/{button-actions-with-menu.f6dfb14d.js → button-actions-with-menu.2ff339f6.js} +3 -3
- package/dist/chunks/{button-actions-with-menu.f6dfb14d.js.map → button-actions-with-menu.2ff339f6.js.map} +1 -1
- package/dist/chunks/button.623a46d2.js +118 -0
- package/dist/chunks/button.623a46d2.js.map +1 -0
- package/dist/chunks/{calendar.fa7712e8.js → calendar.b1d05580.js} +4 -4
- package/dist/chunks/{calendar.fa7712e8.js.map → calendar.b1d05580.js.map} +1 -1
- package/dist/chunks/checkbox.d65694f2.js +278 -0
- package/dist/chunks/checkbox.d65694f2.js.map +1 -0
- package/dist/chunks/{controls-group.d6543674.js → controls-group.30352ce4.js} +21 -17
- package/dist/chunks/controls-group.30352ce4.js.map +1 -0
- package/dist/chunks/copy.2a9cddc1.js +145 -0
- package/dist/chunks/copy.2a9cddc1.js.map +1 -0
- package/dist/chunks/country.types.002caff2.js +5871 -0
- package/dist/chunks/country.types.002caff2.js.map +1 -0
- package/dist/chunks/{dropdown-default-textbox.4108b289.js → dropdown-default-textbox.a731b5fb.js} +25 -25
- package/dist/chunks/dropdown-default-textbox.a731b5fb.js.map +1 -0
- package/dist/chunks/{dropdown.63de9aac.js → dropdown.96431c25.js} +399 -359
- package/dist/chunks/dropdown.96431c25.js.map +1 -0
- package/dist/chunks/{field-label.3c19a29a.js → field-label.b681234d.js} +5 -5
- package/dist/chunks/{field-label.3c19a29a.js.map → field-label.b681234d.js.map} +1 -1
- package/dist/chunks/{fixed-scroller.bced60dd.js → fixed-scroller.ebfb2f80.js} +2 -2
- package/dist/chunks/{fixed-scroller.bced60dd.js.map → fixed-scroller.ebfb2f80.js.map} +1 -1
- package/dist/chunks/{footer-actions.cefaf1e2.js → footer-actions.03015ba1.js} +3 -3
- package/dist/chunks/{footer-actions.cefaf1e2.js.map → footer-actions.03015ba1.js.map} +1 -1
- package/dist/chunks/{index.98174339.js → index.03605cb0.js} +5 -5
- package/dist/chunks/{index.98174339.js.map → index.03605cb0.js.map} +1 -1
- package/dist/chunks/index.09f7f1b5.js +124 -0
- package/dist/chunks/index.09f7f1b5.js.map +1 -0
- package/dist/chunks/index.0a8ddfaa.js +168 -0
- package/dist/chunks/index.0a8ddfaa.js.map +1 -0
- package/dist/chunks/index.113137fb.js +21 -0
- package/dist/chunks/index.113137fb.js.map +1 -0
- package/dist/chunks/{index.89dfe209.js → index.1dac266a.js} +3 -3
- package/dist/chunks/{index.89dfe209.js.map → index.1dac266a.js.map} +1 -1
- package/dist/chunks/{index.0ee895e0.js → index.45d00aad.js} +2 -2
- package/dist/chunks/{index.0ee895e0.js.map → index.45d00aad.js.map} +1 -1
- package/dist/chunks/{index.4d2a13e1.js → index.80078bf9.js} +2 -2
- package/dist/chunks/{index.4d2a13e1.js.map → index.80078bf9.js.map} +1 -1
- package/dist/chunks/{index.85832db5.js → index.a4a6e52f.js} +3 -3
- package/dist/chunks/{index.85832db5.js.map → index.a4a6e52f.js.map} +1 -1
- package/dist/chunks/index.cf561336.js +622 -0
- package/dist/chunks/index.cf561336.js.map +1 -0
- package/dist/chunks/{index.c6fecf1c.js → index.ef1c4d59.js} +33 -33
- package/dist/chunks/{index.c6fecf1c.js.map → index.ef1c4d59.js.map} +1 -1
- package/dist/chunks/{listbox-option-tag.b1eb32bd.js → listbox-option-tag.ff6d6f32.js} +3 -3
- package/dist/chunks/{listbox-option-tag.b1eb32bd.js.map → listbox-option-tag.ff6d6f32.js.map} +1 -1
- package/dist/chunks/listbox.dd9883c5.js +1419 -0
- package/dist/chunks/listbox.dd9883c5.js.map +1 -0
- package/dist/chunks/{loading-button.4b88e24d.js → loading-button.30c5fede.js} +19 -19
- package/dist/chunks/{loading-button.4b88e24d.js.map → loading-button.30c5fede.js.map} +1 -1
- package/dist/chunks/{tooltip.27c32d36.js → tooltip.785993dd.js} +15 -15
- package/dist/chunks/tooltip.785993dd.js.map +1 -0
- package/dist/chunks/use-has-slot.4d98bf29.js.map +1 -1
- package/dist/chunks/useCountryItems.d2a1f224.js +29 -0
- package/dist/chunks/{useCountryItems.e83ef8f0.js.map → useCountryItems.d2a1f224.js.map} +1 -1
- package/dist/code-snippet.js +136 -138
- package/dist/code-snippet.js.map +1 -1
- package/dist/country.js +51 -5912
- package/dist/country.js.map +1 -1
- package/dist/currency.js +1 -1
- package/dist/data-grid.js +1325 -1021
- package/dist/data-grid.js.map +1 -1
- package/dist/date-picker.js +20 -20
- package/dist/date-picker.js.map +1 -1
- package/dist/date-range-picker.js +2 -2
- package/dist/date.js +1 -1
- package/dist/divider.js +2 -10
- package/dist/divider.js.map +1 -1
- package/dist/dropdown.js +51 -50
- package/dist/dropdown.js.map +1 -1
- package/dist/empty-state.js +23 -23
- package/dist/empty-state.js.map +1 -1
- package/dist/filter-bar.js +759 -747
- package/dist/filter-bar.js.map +1 -1
- package/dist/focus-trap.js +1 -1
- package/dist/form-layout.js +2 -2
- package/dist/form-layout.js.map +1 -1
- package/dist/header.js +3 -3
- package/dist/index.js +194 -185
- package/dist/index.js.map +1 -1
- package/dist/info-icon.js +3 -3
- package/dist/input-field.js +4 -4
- package/dist/internal.js +17 -15
- package/dist/link.js +2 -2
- package/dist/loading-indicator.js +1 -1
- package/dist/menu.js +1 -1
- package/dist/modal.js +67 -64
- package/dist/modal.js.map +1 -1
- package/dist/pagination.js +15 -13
- package/dist/pagination.js.map +1 -1
- package/dist/payment-method.js +2 -2
- package/dist/popover.js +1 -1
- package/dist/popper-container.js +1 -1
- package/dist/radio-group.js +69 -67
- package/dist/radio-group.js.map +1 -1
- package/dist/search-bar.js +8 -8
- package/dist/secondary-nav.js +110 -0
- package/dist/secondary-nav.js.map +1 -0
- package/dist/segmented-control.js +3 -3
- package/dist/sidepanel.js +5 -5
- package/dist/status.js +2 -2
- package/dist/stepper.js +3 -3
- package/dist/structured-list.js +1 -1
- package/dist/summary-grid.js +3 -3
- package/dist/tabs.js +3 -3
- package/dist/tag.js +3 -3
- package/dist/textarea.js +173 -161
- package/dist/textarea.js.map +1 -1
- package/dist/timeline.js +244 -237
- package/dist/timeline.js.map +1 -1
- package/dist/toast.js +3 -3
- package/dist/toggle.js +2 -2
- package/dist/tutorial.js +5 -5
- package/dist/typography.js +1 -1
- package/dist/web-types.json +1 -1
- package/package.json +2 -2
- package/dist/@types/packages/vue2/src/components/data-grid/composables/useColumnReorderer/useColumnReorderer.d.ts +0 -67
- package/dist/@types/packages/vue2/src/components/data-grid/composables/useConfigSettings/useConfigSettings.d.ts +0 -73
- package/dist/chunks/base-modal.a629cb32.js.map +0 -1
- package/dist/chunks/button.82ed953e.js +0 -148
- package/dist/chunks/button.82ed953e.js.map +0 -1
- package/dist/chunks/checkbox.731dc0ab.js +0 -264
- package/dist/chunks/checkbox.731dc0ab.js.map +0 -1
- package/dist/chunks/controls-group.d6543674.js.map +0 -1
- package/dist/chunks/copy.330d594e.js +0 -126
- package/dist/chunks/copy.330d594e.js.map +0 -1
- package/dist/chunks/dropdown-default-textbox.4108b289.js.map +0 -1
- package/dist/chunks/dropdown.63de9aac.js.map +0 -1
- package/dist/chunks/index.73ed22a7.js +0 -594
- package/dist/chunks/index.73ed22a7.js.map +0 -1
- package/dist/chunks/index.75f3672e.js +0 -124
- package/dist/chunks/index.75f3672e.js.map +0 -1
- package/dist/chunks/index.edcaf766.js +0 -150
- package/dist/chunks/index.edcaf766.js.map +0 -1
- package/dist/chunks/listbox.ac43f8ab.js +0 -1309
- package/dist/chunks/listbox.ac43f8ab.js.map +0 -1
- package/dist/chunks/tooltip.27c32d36.js.map +0 -1
- package/dist/chunks/useCountryItems.e83ef8f0.js +0 -29
- /package/dist/@types/packages/vue2/src/components/data-grid/composables/{useCalculateColumnWidth/useCalculateColumnWidth.types.d.ts → use-calculate-column-width/use-calculate-column-width.types.d.ts} +0 -0
- /package/dist/@types/packages/vue2/src/components/data-grid/composables/{useCalculateStickyElementHeight/useCalculateStickyElementHeight.d.ts → use-calculate-sticky-element-height/use-calculate-sticky-element-height.d.ts} +0 -0
- /package/dist/@types/packages/vue2/src/components/data-grid/composables/{useKeyboardNavigator/useKeyboardNavigator.types.d.ts → use-keyboard-navigator/use-keyboard-navigator.types.d.ts} +0 -0
- /package/dist/@types/packages/vue2/src/components/data-grid/composables/{useLazyLoading/useLazyLoading.d.ts → use-lazy-loading/use-lazy-loading.d.ts} +0 -0
- /package/dist/@types/packages/vue2/src/components/data-grid/composables/{useSorter.d.ts → use-sorter.d.ts} +0 -0
|
@@ -0,0 +1,622 @@
|
|
|
1
|
+
import { openBlock as c, createElementBlock as L, mergeProps as q, toDisplayString as P, createCommentVNode as E, createElementVNode as R, defineComponent as N, computed as k, resolveComponent as _, createBlock as B, normalizeClass as U, createSlots as j, withCtx as h, createVNode as S, createTextVNode as D, resolveDynamicComponent as se, renderSlot as T, ref as f, onMounted as ie, Transition as ue, withKeys as C, withModifiers as K, Fragment as Z, renderList as z, normalizeStyle as J, inject as ae, provide as le, resolveDirective as re, withDirectives as de } from "vue";
|
|
2
|
+
import { _ as O } from "./_plugin-vue_export-helper.dad06003.js";
|
|
3
|
+
import { g as F } from "./unique-id.a2a2b458.js";
|
|
4
|
+
import { B as ce } from "./directive.0408e565.js";
|
|
5
|
+
import { a as me } from "./button.623a46d2.js";
|
|
6
|
+
import { a as pe, B as V } from "./index.03605cb0.js";
|
|
7
|
+
import { B as Y, D as fe } from "./index.113137fb.js";
|
|
8
|
+
import { u as ve } from "./use-has-slot.4d98bf29.js";
|
|
9
|
+
import { a as _e, C as H } from "./chevron-left.4ee92950.js";
|
|
10
|
+
import { B as be, a as W } from "./base-button.39fae75f.js";
|
|
11
|
+
import { B as ye } from "./index.09f7f1b5.js";
|
|
12
|
+
import "../assets/index27.css";
|
|
13
|
+
let A = 0;
|
|
14
|
+
const Ce = {
|
|
15
|
+
beforeCreate() {
|
|
16
|
+
this.uuid = A.toString(), A += 1;
|
|
17
|
+
}
|
|
18
|
+
}, he = { key: 0 }, ge = /* @__PURE__ */ R("path", {
|
|
19
|
+
fill: "#00112C",
|
|
20
|
+
d: "M8 4C8.29667 4 8.58668 3.91203 8.83335 3.74721C9.08003 3.58238 9.27229 3.34811 9.38582 3.07403C9.49935 2.79994 9.52906 2.49834 9.47118 2.20737C9.4133 1.91639 9.27044 1.64912 9.06066 1.43934C8.85088 1.22956 8.58361 1.0867 8.29264 1.02882C8.00167 0.970945 7.70006 1.00065 7.42598 1.11418C7.15189 1.22771 6.91762 1.41997 6.7528 1.66665C6.58797 1.91332 6.5 2.20333 6.5 2.5C6.5 2.89783 6.65803 3.27936 6.93934 3.56066C7.22064 3.84197 7.60218 4 8 4Z"
|
|
21
|
+
}, null, -1), Ie = /* @__PURE__ */ R("path", {
|
|
22
|
+
fill: "#00112C",
|
|
23
|
+
d: "M8 15C8.29667 15 8.58668 14.912 8.83335 14.7472C9.08003 14.5824 9.27229 14.3481 9.38582 14.074C9.49935 13.7999 9.52906 13.4983 9.47118 13.2074C9.4133 12.9164 9.27044 12.6491 9.06066 12.4393C8.85088 12.2296 8.58361 12.0867 8.29264 12.0288C8.00167 11.9709 7.70006 12.0007 7.42598 12.1142C7.15189 12.2277 6.91762 12.42 6.7528 12.6666C6.58797 12.9133 6.5 13.2033 6.5 13.5C6.5 13.8978 6.65803 14.2794 6.93934 14.5607C7.22064 14.842 7.60218 15 8 15Z"
|
|
24
|
+
}, null, -1), $e = /* @__PURE__ */ R("path", {
|
|
25
|
+
fill: "#00112C",
|
|
26
|
+
d: "M8.83335 9.24721C8.58668 9.41203 8.29667 9.5 8 9.5C7.60218 9.5 7.22064 9.34197 6.93934 9.06066C6.65803 8.77936 6.5 8.39783 6.5 8C6.5 7.70333 6.58797 7.41332 6.7528 7.16665C6.91762 6.91997 7.15189 6.72771 7.42598 6.61418C7.70006 6.50065 8.00167 6.47094 8.29264 6.52882C8.58361 6.5867 8.85088 6.72956 9.06066 6.93934C9.27044 7.14912 9.4133 7.41639 9.47118 7.70737C9.52906 7.99834 9.49935 8.29994 9.38582 8.57403C9.27229 8.84811 9.08003 9.08238 8.83335 9.24721Z"
|
|
27
|
+
}, null, -1);
|
|
28
|
+
function Be(e, n, v, u, r, l) {
|
|
29
|
+
return c(), L("svg", q({ role: "img" }, e.$attrs, {
|
|
30
|
+
class: "ui-assets-icons-16",
|
|
31
|
+
xmlns: "http://www.w3.org/2000/svg",
|
|
32
|
+
width: "16",
|
|
33
|
+
height: "16",
|
|
34
|
+
fill: "none"
|
|
35
|
+
}), [
|
|
36
|
+
e.$attrs["svg-title"] ? (c(), L("title", he, P(e.$attrs["svg-title"]), 1)) : E("", !0),
|
|
37
|
+
ge,
|
|
38
|
+
Ie,
|
|
39
|
+
$e
|
|
40
|
+
], 16);
|
|
41
|
+
}
|
|
42
|
+
const Me = /* @__PURE__ */ O(Ce, [["render", Be]]), ke = N({
|
|
43
|
+
name: "menu-item",
|
|
44
|
+
components: { BaseButton: be, BentoTypography: ye, ChevronRightIcon: _e },
|
|
45
|
+
props: {
|
|
46
|
+
/**
|
|
47
|
+
* menu-item text that gets displayed as the main label
|
|
48
|
+
*/
|
|
49
|
+
text: {
|
|
50
|
+
type: String,
|
|
51
|
+
required: !0
|
|
52
|
+
},
|
|
53
|
+
/**
|
|
54
|
+
* menu-item action that gets executed when the MeniItem is clicked
|
|
55
|
+
*/
|
|
56
|
+
handler: {
|
|
57
|
+
type: Function,
|
|
58
|
+
required: !0
|
|
59
|
+
},
|
|
60
|
+
/**
|
|
61
|
+
* menu-item text that gets displayed as the secondary label
|
|
62
|
+
*/
|
|
63
|
+
secondaryText: {
|
|
64
|
+
type: String,
|
|
65
|
+
default: null
|
|
66
|
+
},
|
|
67
|
+
/**
|
|
68
|
+
* Optional chevron icon displayed to the right of the menu-item
|
|
69
|
+
*/
|
|
70
|
+
chevron: {
|
|
71
|
+
type: Boolean,
|
|
72
|
+
default: !1
|
|
73
|
+
},
|
|
74
|
+
/**
|
|
75
|
+
* Optional icon displayed to the left of the menu-item
|
|
76
|
+
*/
|
|
77
|
+
icon: {
|
|
78
|
+
// Types for Vue2 (Object) and Vue3 (Function)
|
|
79
|
+
// TODO: Remove Object when fully migrated to Vue3
|
|
80
|
+
type: [Object, Function],
|
|
81
|
+
default: null
|
|
82
|
+
},
|
|
83
|
+
/**
|
|
84
|
+
* Disables menu-item button functionality
|
|
85
|
+
*/
|
|
86
|
+
disabled: {
|
|
87
|
+
type: Boolean,
|
|
88
|
+
default: !1
|
|
89
|
+
},
|
|
90
|
+
/**
|
|
91
|
+
* Displays an indent variant od the menu-item
|
|
92
|
+
*/
|
|
93
|
+
indent: {
|
|
94
|
+
type: Boolean,
|
|
95
|
+
default: !1
|
|
96
|
+
},
|
|
97
|
+
/**
|
|
98
|
+
* Displays menu-item button as critical
|
|
99
|
+
*/
|
|
100
|
+
critical: {
|
|
101
|
+
type: Boolean,
|
|
102
|
+
default: !1
|
|
103
|
+
},
|
|
104
|
+
/**
|
|
105
|
+
* Renders the text in a bold variant
|
|
106
|
+
*/
|
|
107
|
+
isTitle: {
|
|
108
|
+
type: Boolean,
|
|
109
|
+
default: !1
|
|
110
|
+
}
|
|
111
|
+
},
|
|
112
|
+
emits: [W.CLICK],
|
|
113
|
+
setup(e, { emit: n }) {
|
|
114
|
+
return {
|
|
115
|
+
// Values
|
|
116
|
+
conditionalClasses: k(() => ({
|
|
117
|
+
"b-menu-item--critical": e.critical,
|
|
118
|
+
"b-menu-item--indent": e.indent
|
|
119
|
+
})),
|
|
120
|
+
// Methods
|
|
121
|
+
onClick: (r) => {
|
|
122
|
+
r.stopPropagation(), e.handler(), n(W.CLICK);
|
|
123
|
+
}
|
|
124
|
+
};
|
|
125
|
+
}
|
|
126
|
+
});
|
|
127
|
+
function Se(e, n, v, u, r, l) {
|
|
128
|
+
const a = _("bento-typography"), i = _("chevron-right-icon"), d = _("base-button");
|
|
129
|
+
return c(), B(d, {
|
|
130
|
+
class: U(["b-menu-item", e.conditionalClasses]),
|
|
131
|
+
role: "menuitem",
|
|
132
|
+
disabled: e.disabled,
|
|
133
|
+
tabindex: "-1",
|
|
134
|
+
onClick: e.onClick
|
|
135
|
+
}, j({
|
|
136
|
+
default: h(() => [
|
|
137
|
+
S(a, {
|
|
138
|
+
el: "span",
|
|
139
|
+
variant: "body",
|
|
140
|
+
stronger: e.isTitle,
|
|
141
|
+
class: "b-menu-item__primary-text"
|
|
142
|
+
}, {
|
|
143
|
+
default: h(() => [
|
|
144
|
+
D(P(e.text), 1)
|
|
145
|
+
]),
|
|
146
|
+
_: 1
|
|
147
|
+
}, 8, ["stronger"]),
|
|
148
|
+
e.secondaryText ? (c(), B(a, {
|
|
149
|
+
key: 0,
|
|
150
|
+
el: "span",
|
|
151
|
+
variant: "body",
|
|
152
|
+
class: "b-menu-item__secondary-text"
|
|
153
|
+
}, {
|
|
154
|
+
default: h(() => [
|
|
155
|
+
D(P(e.secondaryText), 1)
|
|
156
|
+
]),
|
|
157
|
+
_: 1
|
|
158
|
+
})) : E("", !0)
|
|
159
|
+
]),
|
|
160
|
+
_: 2
|
|
161
|
+
}, [
|
|
162
|
+
e.icon ? {
|
|
163
|
+
name: "iconLeft",
|
|
164
|
+
fn: h(() => [
|
|
165
|
+
(c(), B(se(e.icon), {
|
|
166
|
+
class: "b-menu-item__icon-left",
|
|
167
|
+
"aria-hidden": "true"
|
|
168
|
+
}))
|
|
169
|
+
]),
|
|
170
|
+
key: "0"
|
|
171
|
+
} : void 0,
|
|
172
|
+
e.chevron ? {
|
|
173
|
+
name: "iconRight",
|
|
174
|
+
fn: h(() => [
|
|
175
|
+
S(i, { "aria-hidden": "true" })
|
|
176
|
+
]),
|
|
177
|
+
key: "1"
|
|
178
|
+
} : void 0
|
|
179
|
+
]), 1032, ["class", "disabled", "onClick"]);
|
|
180
|
+
}
|
|
181
|
+
const G = /* @__PURE__ */ O(ke, [["render", Se], ["__scopeId", "data-v-9e8afd9c"]]);
|
|
182
|
+
var g = /* @__PURE__ */ ((e) => (e.BACK = "back", e.CLOSE = "close", e.OPEN = "open", e))(g || {});
|
|
183
|
+
const Le = N({
|
|
184
|
+
name: "bento-menu-list-container"
|
|
185
|
+
});
|
|
186
|
+
const we = { class: "b-menu-list-container" };
|
|
187
|
+
function Ee(e, n, v, u, r, l) {
|
|
188
|
+
return c(), L("div", we, [
|
|
189
|
+
T(e.$slots, "default", {}, void 0, !0)
|
|
190
|
+
]);
|
|
191
|
+
}
|
|
192
|
+
const Q = /* @__PURE__ */ O(Le, [["render", Ee], ["__scopeId", "data-v-ea0113ba"]]), X = {
|
|
193
|
+
"en-US": {
|
|
194
|
+
menuButton: "Open menu",
|
|
195
|
+
backButton: "Go back"
|
|
196
|
+
}
|
|
197
|
+
}, Oe = N({
|
|
198
|
+
i18n: { messages: X },
|
|
199
|
+
name: "sub-menu-item-list",
|
|
200
|
+
components: { BentoDivider: Y, MenuItem: G, MenuListContainer: Q },
|
|
201
|
+
props: {
|
|
202
|
+
items: {
|
|
203
|
+
type: Array,
|
|
204
|
+
required: !0
|
|
205
|
+
},
|
|
206
|
+
title: {
|
|
207
|
+
type: String,
|
|
208
|
+
required: !0
|
|
209
|
+
}
|
|
210
|
+
},
|
|
211
|
+
emits: [g.CLOSE, g.BACK],
|
|
212
|
+
setup(e, { emit: n }) {
|
|
213
|
+
const v = f(null), u = f(0), r = f(e.items.length), l = () => n(g.CLOSE), a = () => n(g.BACK), i = k(() => {
|
|
214
|
+
var p;
|
|
215
|
+
const s = (p = e.items) == null ? void 0 : p.map((b) => ({
|
|
216
|
+
...b,
|
|
217
|
+
indent: !b.icon,
|
|
218
|
+
isTitle: !1,
|
|
219
|
+
clickHandler: l
|
|
220
|
+
}));
|
|
221
|
+
return [
|
|
222
|
+
{
|
|
223
|
+
text: e.title,
|
|
224
|
+
secondaryText: null,
|
|
225
|
+
critical: !1,
|
|
226
|
+
icon: H,
|
|
227
|
+
isTitle: !0,
|
|
228
|
+
disabled: !1,
|
|
229
|
+
indent: !1,
|
|
230
|
+
handler: a,
|
|
231
|
+
clickHandler: a,
|
|
232
|
+
addDivider: !0
|
|
233
|
+
},
|
|
234
|
+
...s
|
|
235
|
+
];
|
|
236
|
+
}), d = async () => {
|
|
237
|
+
var s, p, b, $, I;
|
|
238
|
+
(I = ($ = (b = (p = (s = v.value) == null ? void 0 : s.children) == null ? void 0 : p[u.value]) == null ? void 0 : b.children) == null ? void 0 : $[0]) == null || I.focus();
|
|
239
|
+
};
|
|
240
|
+
ie(async () => {
|
|
241
|
+
setTimeout(() => d(), 150);
|
|
242
|
+
});
|
|
243
|
+
const o = () => {
|
|
244
|
+
u.value > 0 ? (u.value -= 1, i.value[u.value].disabled && o()) : u.value = r.value, d();
|
|
245
|
+
}, t = () => {
|
|
246
|
+
u.value < r.value ? (u.value += 1, i.value[u.value].disabled && t()) : u.value = 0, d();
|
|
247
|
+
};
|
|
248
|
+
return {
|
|
249
|
+
// Enums
|
|
250
|
+
BentoMenuEvent: g,
|
|
251
|
+
// Values
|
|
252
|
+
subMenuItemListRefLocal: v,
|
|
253
|
+
subMenuFocusedIndex: u,
|
|
254
|
+
ChevronLeftIcon: H,
|
|
255
|
+
computedItems: i,
|
|
256
|
+
// Methods
|
|
257
|
+
closeMenu: l,
|
|
258
|
+
onBackButton: a,
|
|
259
|
+
focusPrevious: o,
|
|
260
|
+
focusNext: t
|
|
261
|
+
};
|
|
262
|
+
}
|
|
263
|
+
});
|
|
264
|
+
function Re(e, n, v, u, r, l) {
|
|
265
|
+
const a = _("menu-item"), i = _("bento-divider"), d = _("menu-list-container");
|
|
266
|
+
return c(), B(ue, {
|
|
267
|
+
name: "b-sub-menu-item-list__transition",
|
|
268
|
+
appear: ""
|
|
269
|
+
}, {
|
|
270
|
+
default: h(() => [
|
|
271
|
+
S(d, { class: "b-sub-menu-item-list" }, {
|
|
272
|
+
default: h(() => [
|
|
273
|
+
R("ul", {
|
|
274
|
+
ref: "subMenuItemListRefLocal",
|
|
275
|
+
role: "menu",
|
|
276
|
+
class: "b-sub-menu-item-list__list",
|
|
277
|
+
onKeydown: [
|
|
278
|
+
n[0] || (n[0] = C(K((...o) => e.focusNext && e.focusNext(...o), ["stop"]), ["down"])),
|
|
279
|
+
n[1] || (n[1] = C(K((...o) => e.focusPrevious && e.focusPrevious(...o), ["stop"]), ["up"])),
|
|
280
|
+
n[2] || (n[2] = C(K((...o) => e.onBackButton && e.onBackButton(...o), ["stop"]), ["esc"]))
|
|
281
|
+
]
|
|
282
|
+
}, [
|
|
283
|
+
(c(!0), L(Z, null, z(e.computedItems, (o, t) => (c(), L("li", {
|
|
284
|
+
key: `sub-menu-item-list-item-${t}`,
|
|
285
|
+
role: "none"
|
|
286
|
+
}, [
|
|
287
|
+
S(a, {
|
|
288
|
+
text: o.text,
|
|
289
|
+
handler: o.handler,
|
|
290
|
+
"secondary-text": o.secondaryText,
|
|
291
|
+
icon: o.icon,
|
|
292
|
+
"is-title": o.isTitle,
|
|
293
|
+
disabled: o.disabled,
|
|
294
|
+
critical: o.critical,
|
|
295
|
+
indent: o.indent,
|
|
296
|
+
tabindex: t === e.subMenuFocusedIndex ? "0" : "-1",
|
|
297
|
+
onClick: o.clickHandler
|
|
298
|
+
}, null, 8, ["text", "handler", "secondary-text", "icon", "is-title", "disabled", "critical", "indent", "tabindex", "onClick"]),
|
|
299
|
+
o.addDivider ? (c(), B(i, {
|
|
300
|
+
key: 0,
|
|
301
|
+
class: "b-sub-menu-item-list__divider"
|
|
302
|
+
})) : E("", !0)
|
|
303
|
+
]))), 128))
|
|
304
|
+
], 544)
|
|
305
|
+
]),
|
|
306
|
+
_: 1
|
|
307
|
+
})
|
|
308
|
+
]),
|
|
309
|
+
_: 1
|
|
310
|
+
});
|
|
311
|
+
}
|
|
312
|
+
const Ne = /* @__PURE__ */ O(Oe, [["render", Re], ["__scopeId", "data-v-621db243"]]), Te = N({
|
|
313
|
+
name: "menu-item-list",
|
|
314
|
+
components: { BentoDivider: Y, MenuItem: G, MenuListContainer: Q, SubMenuItemList: Ne },
|
|
315
|
+
props: {
|
|
316
|
+
/**
|
|
317
|
+
* The data to be displayed in the list
|
|
318
|
+
*/
|
|
319
|
+
data: {
|
|
320
|
+
type: Array,
|
|
321
|
+
required: !0
|
|
322
|
+
},
|
|
323
|
+
/**
|
|
324
|
+
* Displays the menu-items of the list in the indent variant. Only applies to elements that don't have an icon to their left.
|
|
325
|
+
*/
|
|
326
|
+
indentItems: {
|
|
327
|
+
type: Boolean,
|
|
328
|
+
default: !1
|
|
329
|
+
},
|
|
330
|
+
/**
|
|
331
|
+
* If set to true, focuses the last item on the list instead of the first. Used for accessibility purposes when the menu is opened with the 'up' arrow key.
|
|
332
|
+
*/
|
|
333
|
+
focusLastElement: {
|
|
334
|
+
type: Boolean,
|
|
335
|
+
default: !1
|
|
336
|
+
}
|
|
337
|
+
},
|
|
338
|
+
emits: [g.CLOSE],
|
|
339
|
+
setup(e, { emit: n }) {
|
|
340
|
+
const v = f(null), u = f(null), r = f(null), l = f(!1), a = f(null), i = f(e.focusLastElement ? e.data.length - 1 : 0), d = f(0), o = f(e.data.length - 1), t = k(() => e.data.some((m) => m.icon)), s = k(() => e.indentItems || t.value ? e.data.map((m) => {
|
|
341
|
+
let y = !1;
|
|
342
|
+
return m.icon || (y = !0), {
|
|
343
|
+
...m,
|
|
344
|
+
// eslint-disable-next-line no-param-reassign
|
|
345
|
+
indent: y
|
|
346
|
+
};
|
|
347
|
+
}) : e.data), p = () => {
|
|
348
|
+
var m, y, M;
|
|
349
|
+
return (M = (y = (m = v.value) == null ? void 0 : m.children[i.value]) == null ? void 0 : y.children[0]) == null ? void 0 : M.focus();
|
|
350
|
+
}, b = () => n(g.CLOSE), $ = async (m, y) => {
|
|
351
|
+
m.items ? (a.value = y, l.value = !0) : (a.value = y, l.value = !1, b());
|
|
352
|
+
}, I = () => {
|
|
353
|
+
i.value > 0 ? (i.value -= 1, s.value[i.value].disabled && I()) : i.value = o.value, p();
|
|
354
|
+
}, w = () => {
|
|
355
|
+
i.value < o.value ? (i.value += 1, s.value[i.value].disabled && w()) : i.value = 0, p();
|
|
356
|
+
}, x = (m, y) => {
|
|
357
|
+
var M;
|
|
358
|
+
(M = m == null ? void 0 : m.items) != null && M.length && (a.value = y, l.value = !0);
|
|
359
|
+
}, ee = () => {
|
|
360
|
+
a.value && l.value && (a.value = null, l.value = !1);
|
|
361
|
+
}, ne = () => {
|
|
362
|
+
l.value = !1, a.value = null, p();
|
|
363
|
+
}, te = k(() => {
|
|
364
|
+
var m, y, M;
|
|
365
|
+
return (M = (y = (m = r.value) == null ? void 0 : m[0]) == null ? void 0 : y.$el) == null ? void 0 : M.offsetHeight;
|
|
366
|
+
}), oe = k(() => l.value ? `${te.value}px` : "");
|
|
367
|
+
return {
|
|
368
|
+
// Values
|
|
369
|
+
menuItemListRef: v,
|
|
370
|
+
menuItemListWrapperRef: u,
|
|
371
|
+
subMenuItemListRef: r,
|
|
372
|
+
computedData: s,
|
|
373
|
+
computedHeight: oe,
|
|
374
|
+
focusedIndex: i,
|
|
375
|
+
subMenuFocusedIndex: d,
|
|
376
|
+
showSubMenu: l,
|
|
377
|
+
visibleSubMenuIndex: a,
|
|
378
|
+
// Methods
|
|
379
|
+
toggleMenu: $,
|
|
380
|
+
closeMenu: b,
|
|
381
|
+
focusPrevious: I,
|
|
382
|
+
focusNext: w,
|
|
383
|
+
focusRight: x,
|
|
384
|
+
focusLeft: ee,
|
|
385
|
+
onBackButton: ne
|
|
386
|
+
};
|
|
387
|
+
}
|
|
388
|
+
});
|
|
389
|
+
const Ke = ["onKeydown"];
|
|
390
|
+
function Pe(e, n, v, u, r, l) {
|
|
391
|
+
const a = _("menu-item"), i = _("bento-divider"), d = _("sub-menu-item-list"), o = _("menu-list-container");
|
|
392
|
+
return c(), B(o, {
|
|
393
|
+
ref: "menuItemListWrapperRef",
|
|
394
|
+
style: J({ height: e.computedHeight })
|
|
395
|
+
}, {
|
|
396
|
+
default: h(() => [
|
|
397
|
+
R("ul", {
|
|
398
|
+
ref: "menuItemListRef",
|
|
399
|
+
class: "b-menu-item-list",
|
|
400
|
+
role: "menu",
|
|
401
|
+
onKeydown: [
|
|
402
|
+
n[1] || (n[1] = C((...t) => e.focusNext && e.focusNext(...t), ["down"])),
|
|
403
|
+
n[2] || (n[2] = C((...t) => e.focusPrevious && e.focusPrevious(...t), ["up"])),
|
|
404
|
+
n[3] || (n[3] = C((...t) => e.closeMenu && e.closeMenu(...t), ["esc"])),
|
|
405
|
+
n[4] || (n[4] = C((...t) => e.closeMenu && e.closeMenu(...t), ["tab"]))
|
|
406
|
+
]
|
|
407
|
+
}, [
|
|
408
|
+
(c(!0), L(Z, null, z(e.computedData, (t, s) => {
|
|
409
|
+
var p, b, $, I;
|
|
410
|
+
return c(), L("li", {
|
|
411
|
+
key: `menu-item-${s}`,
|
|
412
|
+
class: "b-menu-item-list__item",
|
|
413
|
+
role: "none",
|
|
414
|
+
onKeydown: [
|
|
415
|
+
C((w) => e.focusRight(t, s), ["right"]),
|
|
416
|
+
n[0] || (n[0] = C((w) => e.focusLeft(), ["left"]))
|
|
417
|
+
]
|
|
418
|
+
}, [
|
|
419
|
+
S(a, {
|
|
420
|
+
text: t.text,
|
|
421
|
+
handler: (p = t.items) != null && p.length ? () => null : t.handler,
|
|
422
|
+
"secondary-text": t.secondaryText,
|
|
423
|
+
icon: t.icon,
|
|
424
|
+
chevron: !!((b = t.items) != null && b.length),
|
|
425
|
+
disabled: t.disabled,
|
|
426
|
+
critical: t.critical,
|
|
427
|
+
indent: t.indent,
|
|
428
|
+
tabindex: s === e.subMenuFocusedIndex ? "0" : "-1",
|
|
429
|
+
"aria-haspopup": !!(($ = t.items) != null && $.length),
|
|
430
|
+
"aria-expanded": e.showSubMenu && e.visibleSubMenuIndex === s,
|
|
431
|
+
onClick: (w) => e.toggleMenu(t, s)
|
|
432
|
+
}, null, 8, ["text", "handler", "secondary-text", "icon", "chevron", "disabled", "critical", "indent", "tabindex", "aria-haspopup", "aria-expanded", "onClick"]),
|
|
433
|
+
t.addDivider ? (c(), B(i, {
|
|
434
|
+
key: 0,
|
|
435
|
+
class: "b-menu-item-list__divider"
|
|
436
|
+
})) : E("", !0),
|
|
437
|
+
(I = t.items) != null && I.length && e.showSubMenu && e.visibleSubMenuIndex === s ? (c(), B(d, {
|
|
438
|
+
key: 1,
|
|
439
|
+
ref_for: !0,
|
|
440
|
+
ref: "subMenuItemListRef",
|
|
441
|
+
items: t.items,
|
|
442
|
+
title: t.text,
|
|
443
|
+
onBack: e.onBackButton,
|
|
444
|
+
onClose: e.closeMenu
|
|
445
|
+
}, null, 8, ["items", "title", "onBack", "onClose"])) : E("", !0)
|
|
446
|
+
], 40, Ke);
|
|
447
|
+
}), 128))
|
|
448
|
+
], 544)
|
|
449
|
+
]),
|
|
450
|
+
_: 1
|
|
451
|
+
}, 8, ["style"]);
|
|
452
|
+
}
|
|
453
|
+
const De = /* @__PURE__ */ O(Te, [["render", Pe], ["__scopeId", "data-v-f1d94ee8"]]), Fe = Symbol("menu inverse style injection key"), Ve = N({
|
|
454
|
+
i18n: { messages: X },
|
|
455
|
+
name: "bento-menu",
|
|
456
|
+
components: { BentoButton: me, BentoPopover: pe, MenuItemList: De, OptionsVerticalIcon: Me },
|
|
457
|
+
directives: { BentoClickOutsideDirective: ce },
|
|
458
|
+
props: {
|
|
459
|
+
/**
|
|
460
|
+
* Object containing props to change the menu button appearance. Accepts the same props present in BentoButton.
|
|
461
|
+
*/
|
|
462
|
+
button: {
|
|
463
|
+
type: Object,
|
|
464
|
+
default: () => ({
|
|
465
|
+
variant: "secondary"
|
|
466
|
+
})
|
|
467
|
+
},
|
|
468
|
+
/**
|
|
469
|
+
* The data to be displayed in the list
|
|
470
|
+
*/
|
|
471
|
+
data: {
|
|
472
|
+
type: Array,
|
|
473
|
+
required: !0
|
|
474
|
+
},
|
|
475
|
+
/**
|
|
476
|
+
* The position of where the menu should open.
|
|
477
|
+
*/
|
|
478
|
+
menuPosition: {
|
|
479
|
+
type: String,
|
|
480
|
+
default: V.BOTTOM_START,
|
|
481
|
+
validator: (e) => Object.values(V).includes(e)
|
|
482
|
+
},
|
|
483
|
+
/**
|
|
484
|
+
* Instructs the menu popover to be visible outside of the containing container.
|
|
485
|
+
* @see {@link https://floating-ui.com/docs/usefloating#strategy}
|
|
486
|
+
*/
|
|
487
|
+
menuFixedPositioning: {
|
|
488
|
+
type: Boolean,
|
|
489
|
+
default: !1
|
|
490
|
+
},
|
|
491
|
+
/**
|
|
492
|
+
* Sets a custom width for the menu popover.
|
|
493
|
+
*/
|
|
494
|
+
menuWidth: {
|
|
495
|
+
type: Number,
|
|
496
|
+
default: null
|
|
497
|
+
}
|
|
498
|
+
},
|
|
499
|
+
emits: [g.CLOSE, g.OPEN],
|
|
500
|
+
setup(e, { emit: n, slots: v }) {
|
|
501
|
+
const u = f(null), r = f(!1), l = f(!1), a = F("menu"), i = F("menu-popover"), d = ae(Fe, f(!1));
|
|
502
|
+
le(fe, d);
|
|
503
|
+
const o = k(() => ({
|
|
504
|
+
"b-menu--inverse": d.value
|
|
505
|
+
})), t = k(() => e.menuWidth ? { width: `${e.menuWidth}px` } : null), s = () => {
|
|
506
|
+
r.value = !0, n(g.OPEN);
|
|
507
|
+
}, p = () => {
|
|
508
|
+
r.value && (r.value = !1, u.value.$el.focus(), n(g.CLOSE));
|
|
509
|
+
}, b = (w) => {
|
|
510
|
+
w.stopPropagation(), r.value ? p() : s();
|
|
511
|
+
}, $ = () => {
|
|
512
|
+
l.value = !1, s();
|
|
513
|
+
}, I = () => {
|
|
514
|
+
l.value = !0, s();
|
|
515
|
+
};
|
|
516
|
+
return {
|
|
517
|
+
// Values
|
|
518
|
+
menuButtonRef: u,
|
|
519
|
+
menuId: a,
|
|
520
|
+
popoverId: i,
|
|
521
|
+
showMenu: r,
|
|
522
|
+
computedMenuWidth: t,
|
|
523
|
+
isLastElementFocused: l,
|
|
524
|
+
// Classes
|
|
525
|
+
computedClasses: o,
|
|
526
|
+
isInverseColorSet: d,
|
|
527
|
+
// Methods
|
|
528
|
+
hasSlot: ve(v),
|
|
529
|
+
onKeyDown: $,
|
|
530
|
+
onKeyUp: I,
|
|
531
|
+
closeMenu: p,
|
|
532
|
+
toggleShowMenu: b
|
|
533
|
+
};
|
|
534
|
+
}
|
|
535
|
+
});
|
|
536
|
+
function He(e, n, v, u, r, l) {
|
|
537
|
+
const a = _("options-vertical-icon"), i = _("bento-button"), d = _("menu-item-list"), o = _("bento-popover"), t = re("bento-click-outside-directive");
|
|
538
|
+
return de((c(), L("div", {
|
|
539
|
+
class: U([e.computedClasses, "b-menu"]),
|
|
540
|
+
onKeydown: [
|
|
541
|
+
n[0] || (n[0] = C((...s) => e.onKeyDown && e.onKeyDown(...s), ["down"])),
|
|
542
|
+
n[1] || (n[1] = C((...s) => e.onKeyUp && e.onKeyUp(...s), ["up"])),
|
|
543
|
+
n[2] || (n[2] = C((...s) => e.closeMenu && e.closeMenu(...s), ["esc"]))
|
|
544
|
+
]
|
|
545
|
+
}, [
|
|
546
|
+
S(i, q({
|
|
547
|
+
ref: "menuButtonRef",
|
|
548
|
+
"aria-haspopup": "true"
|
|
549
|
+
}, e.button, {
|
|
550
|
+
"aria-expanded": `${e.showMenu}`,
|
|
551
|
+
"aria-controls": e.showMenu ? e.menuId : null,
|
|
552
|
+
inverse: e.isInverseColorSet,
|
|
553
|
+
onClick: e.toggleShowMenu
|
|
554
|
+
}), j({ _: 2 }, [
|
|
555
|
+
!e.hasSlot("default") || e.hasSlot("iconLeft") ? {
|
|
556
|
+
name: "iconLeft",
|
|
557
|
+
fn: h(() => [
|
|
558
|
+
T(e.$slots, "iconLeft", {}, () => [
|
|
559
|
+
S(a, {
|
|
560
|
+
title: e.$t("menuButton")
|
|
561
|
+
}, null, 8, ["title"])
|
|
562
|
+
], !0)
|
|
563
|
+
]),
|
|
564
|
+
key: "0"
|
|
565
|
+
} : void 0,
|
|
566
|
+
e.hasSlot("default") ? {
|
|
567
|
+
name: "default",
|
|
568
|
+
fn: h(() => [
|
|
569
|
+
T(e.$slots, "default", {}, void 0, !0)
|
|
570
|
+
]),
|
|
571
|
+
key: "1"
|
|
572
|
+
} : void 0,
|
|
573
|
+
e.hasSlot("iconRight") ? {
|
|
574
|
+
name: "iconRight",
|
|
575
|
+
fn: h(() => [
|
|
576
|
+
T(e.$slots, "iconRight", {}, void 0, !0)
|
|
577
|
+
]),
|
|
578
|
+
key: "2"
|
|
579
|
+
} : void 0
|
|
580
|
+
]), 1040, ["aria-expanded", "aria-controls", "inverse", "onClick"]),
|
|
581
|
+
e.menuButtonRef ? (c(), B(o, {
|
|
582
|
+
key: 0,
|
|
583
|
+
id: e.menuId,
|
|
584
|
+
open: e.showMenu,
|
|
585
|
+
class: "b-menu__popover",
|
|
586
|
+
style: J(e.computedMenuWidth),
|
|
587
|
+
"target-element": e.menuButtonRef,
|
|
588
|
+
position: e.menuPosition,
|
|
589
|
+
"fixed-positioning": e.menuFixedPositioning,
|
|
590
|
+
"fallback-position": [
|
|
591
|
+
"bottom-start",
|
|
592
|
+
"bottom-end",
|
|
593
|
+
"top-start",
|
|
594
|
+
"top-end",
|
|
595
|
+
"right-start",
|
|
596
|
+
"right-end",
|
|
597
|
+
"left-start",
|
|
598
|
+
"left-end"
|
|
599
|
+
],
|
|
600
|
+
"without-space": ""
|
|
601
|
+
}, {
|
|
602
|
+
default: h(() => [
|
|
603
|
+
S(d, {
|
|
604
|
+
data: e.data,
|
|
605
|
+
"focus-last-element": e.isLastElementFocused,
|
|
606
|
+
onClose: e.closeMenu
|
|
607
|
+
}, null, 8, ["data", "focus-last-element", "onClose"])
|
|
608
|
+
]),
|
|
609
|
+
_: 1
|
|
610
|
+
}, 8, ["id", "open", "style", "target-element", "position", "fixed-positioning"])) : E("", !0)
|
|
611
|
+
], 34)), [
|
|
612
|
+
[t, e.closeMenu]
|
|
613
|
+
]);
|
|
614
|
+
}
|
|
615
|
+
const Xe = /* @__PURE__ */ O(Ve, [["render", He], ["__scopeId", "data-v-d1b63c73"]]);
|
|
616
|
+
export {
|
|
617
|
+
Xe as B,
|
|
618
|
+
Fe as M,
|
|
619
|
+
Me as O,
|
|
620
|
+
g as a
|
|
621
|
+
};
|
|
622
|
+
//# sourceMappingURL=index.cf561336.js.map
|