@adyen/bento-vue3 1.23.0 → 1.25.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/packages/vue2/src/components/alert/alert.types.d.ts +3 -0
- package/dist/@types/packages/vue2/src/components/alert/alert.vue.d.ts +46 -54
- package/dist/@types/packages/vue2/src/components/avatar-image/avatar-image.vue.d.ts +38 -48
- package/dist/@types/packages/vue2/src/components/card/card.vue.d.ts +86 -174
- package/dist/@types/packages/vue2/src/components/checkbox/checkbox.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/checkbox/components/checkbox-group/checkbox-group.vue.d.ts +2 -2
- package/dist/@types/packages/vue2/src/components/data-grid/components/data-grid-cell/data-grid-cell.keys.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/data-grid/components/data-grid-cell/data-grid-cell.types.d.ts +8 -1
- package/dist/@types/packages/vue2/src/components/data-grid/components/data-grid-cell/data-grid-cell.vue.d.ts +6 -3
- package/dist/@types/packages/vue2/src/components/data-grid/components/data-grid-cell-actions/data-grid-cell-actions.vue.d.ts +6 -2
- package/dist/@types/packages/vue2/src/components/data-grid/components/data-grid-config-settings/data-grid-config-settings.vue.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/data-grid/composables/use-calculate-column-width/use-calculate-column-width.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/data-grid/data-grid.vue.d.ts +5 -5
- package/dist/@types/packages/vue2/src/components/date-picker/date-picker.vue.d.ts +2 -2
- package/dist/@types/packages/vue2/src/components/date-range-picker/date-range-picker.vue.d.ts +2 -2
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-base-textbox/dropdown-base-textbox.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-default-textbox/dropdown-default-textbox.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-options-container/composables/use-dropdown-options-listbox.d.ts +13 -7
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-options-container/dropdown-options-container.vue.d.ts +14 -14
- package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-small-textbox/dropdown-small-textbox.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/dropdown/composables/use-display-value.d.ts +2 -2
- package/dist/@types/packages/vue2/src/components/dropdown/composables/use-display-value.types.d.ts +3 -24
- package/dist/@types/packages/vue2/src/components/dropdown/dropdown.vue.d.ts +5 -5
- package/dist/@types/packages/vue2/src/components/empty-state/empty-state.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/filter-bar/components/base-filter-button/base-filter-button.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/filter-bar/components/range-filter/index.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/filter-bar/components/select-filter/components/index.d.ts +2 -0
- package/dist/@types/packages/vue2/src/components/filter-bar/components/select-filter/components/select-filter-button/select-filter-button.vue.d.ts +148 -0
- package/dist/@types/packages/vue2/src/components/filter-bar/components/select-filter/components/select-filter-dropdown/select-filter-dropdown.vue.d.ts +150 -0
- package/dist/@types/packages/vue2/src/components/filter-bar/components/select-filter/select-filter.vue.d.ts +28 -27
- package/dist/@types/packages/vue2/src/components/input-field/input-field.vue.d.ts +21 -9
- package/dist/@types/packages/vue2/src/components/internal/checkbox-input/checkbox-input.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/internal/controls-group/controls-group.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/internal/dialog-page/dialog-page.types.d.ts +1 -0
- package/dist/@types/packages/vue2/src/components/internal/field-label/field-label.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-multi-select/components/listbox-multi-select-chips/listbox-multi-select-chips.vue.d.ts +3 -3
- 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 +25 -20
- 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 +1 -2
- package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-multi-select/listbox-multi-select.vue.d.ts +45 -9
- package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-single-select/listbox-single-select.vue.d.ts +10 -9
- package/dist/@types/packages/vue2/src/components/internal/listbox/composables/use-cached-selected-values/use-cached-selected-values.d.ts +2 -2
- package/dist/@types/packages/vue2/src/components/internal/listbox/listbox.vue.d.ts +15 -15
- package/dist/@types/packages/vue2/src/components/internal/radio-input/radio-input.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/menu/components/menu-item-list/menu-item-list.vue.d.ts +3 -2
- package/dist/@types/packages/vue2/src/components/menu/components/menu-list-container/menu-list-container.vue.d.ts +8 -1
- package/dist/@types/packages/vue2/src/components/menu/menu.vue.d.ts +3 -1
- package/dist/@types/packages/vue2/src/components/modal/components/base-modal/base-modal.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/modal/components/modal-default/modal-default.vue.d.ts +2 -2
- package/dist/@types/packages/vue2/src/components/modal/modal.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/popper-container/popper-container.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/radio-group/radio-group.vue.d.ts +2 -2
- package/dist/@types/packages/vue2/src/components/selection-card/components/selection-card-group/selection-card-group.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/summary-grid/components/summary-grid-item/summary-grid-item.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/summary-grid/components/summary-grid-item-amount/summary-grid-item-amount.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/summary-grid/components/summary-grid-item-numeric/summary-grid-item-numeric.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/summary-grid/components/summary-grid-item-percentage/summary-grid-item-percentage.vue.d.ts +3 -3
- package/dist/@types/packages/vue2/src/components/textarea/textarea.vue.d.ts +2 -2
- package/dist/@types/packages/vue2/src/components/toast/components/toast-item/toast-item.vue.d.ts +7 -40
- package/dist/@types/packages/vue2/src/components/toast/components/toast-shadow-stack/toast-shadow-stack.types.d.ts +5 -0
- package/dist/@types/packages/vue2/src/components/toast/components/toast-shadow-stack/toast-shadow-stack.vue.d.ts +7 -0
- package/dist/@types/packages/vue2/src/components/toast/index.d.ts +0 -1
- package/dist/@types/packages/vue2/src/components/toast/toast.vue.d.ts +1 -29
- package/dist/@types/packages/vue2/src/components/toggle/toggle.vue.d.ts +1 -1
- package/dist/@types/packages/vue2/src/components/tooltip/tooltip.vue.d.ts +195 -55
- package/dist/@types/packages/vue2/src/components/typography/typography.vue.d.ts +71 -85
- package/dist/@types/packages/vue2/src/composables/index.d.ts +1 -0
- package/dist/@types/packages/vue2/src/composables/use-bento-toast-controller/index.d.ts +2 -0
- package/dist/@types/packages/vue2/src/composables/use-bento-toast-controller/install.d.ts +6 -0
- package/dist/@types/packages/vue2/src/composables/use-bento-toast-controller/toast-stack.d.ts +7 -0
- package/dist/@types/packages/vue2/src/composables/use-bento-toast-controller/use-bento-toast-controller.d.ts +2 -0
- package/dist/@types/packages/vue2/src/composables/use-bento-toast-controller/use-bento-toast-controller.types.d.ts +23 -0
- package/dist/@types/packages/vue2/src/composables/use-click-outside/index.d.ts +1 -0
- package/dist/@types/packages/vue2/src/index.d.ts +2 -0
- package/dist/@types/packages/vue2/src/utils/ts/storybook.d.ts +10 -0
- package/dist/accordion.js +2 -2
- package/dist/action-bar.js +6 -6
- package/dist/alert.js +150 -154
- package/dist/alert.js.map +1 -1
- package/dist/assets/base-modal.css +1 -1
- package/dist/assets/dialog-page.css +1 -1
- package/dist/assets/dropdown.css +1 -1
- package/dist/assets/grid-layout.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/index15.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 -1
- package/dist/assets/index48.css +1 -1
- package/dist/assets/index5.css +1 -1
- package/dist/assets/index6.css +1 -1
- package/dist/assets/index7.css +1 -1
- package/dist/assets/index8.css +1 -1
- package/dist/assets/index9.css +1 -1
- package/dist/assets/{listbox.css → use-cached-selected-values.css} +1 -1
- package/dist/avatar-image.js +1 -1
- package/dist/button.js +5 -5
- package/dist/card.js +168 -267
- package/dist/card.js.map +1 -1
- package/dist/checkbox.js +5 -5
- package/dist/chunks/{base-button.13df4e44.js → base-button.6be8b60e.js} +2 -2
- package/dist/chunks/{base-button.13df4e44.js.map → base-button.6be8b60e.js.map} +1 -1
- package/dist/chunks/{base-modal.30bce990.js → base-modal.310c4790.js} +6 -6
- package/dist/chunks/{base-modal.30bce990.js.map → base-modal.310c4790.js.map} +1 -1
- package/dist/chunks/{button-actions-with-menu.a5d2bb13.js → button-actions-with-menu.a007b034.js} +4 -4
- package/dist/chunks/{button-actions-with-menu.a5d2bb13.js.map → button-actions-with-menu.a007b034.js.map} +1 -1
- package/dist/chunks/{button-actions.ec3c649c.js → button-actions.adc0a2fe.js} +3 -3
- package/dist/chunks/{button-actions.ec3c649c.js.map → button-actions.adc0a2fe.js.map} +1 -1
- package/dist/chunks/{button.e965bf53.js → button.de5589fa.js} +3 -3
- package/dist/chunks/{button.e965bf53.js.map → button.de5589fa.js.map} +1 -1
- package/dist/chunks/{calendar.52fe4032.js → calendar.73f5b904.js} +4 -4
- package/dist/chunks/{calendar.52fe4032.js.map → calendar.73f5b904.js.map} +1 -1
- package/dist/chunks/{checkbox.1442f41a.js → checkbox.4c96cc23.js} +3 -3
- package/dist/chunks/{checkbox.1442f41a.js.map → checkbox.4c96cc23.js.map} +1 -1
- package/dist/chunks/{controls-group.1f29b602.js → controls-group.37a67734.js} +3 -3
- package/dist/chunks/{controls-group.1f29b602.js.map → controls-group.37a67734.js.map} +1 -1
- package/dist/chunks/{copy.d052f444.js → copy.43de2653.js} +4 -4
- package/dist/chunks/{copy.d052f444.js.map → copy.43de2653.js.map} +1 -1
- package/dist/chunks/dialog-page.cd8c7fff.js +173 -0
- package/dist/chunks/dialog-page.cd8c7fff.js.map +1 -0
- package/dist/chunks/{dropdown-default-textbox.e0ca5afb.js → dropdown-default-textbox.424e0eb6.js} +2 -2
- package/dist/chunks/{dropdown-default-textbox.e0ca5afb.js.map → dropdown-default-textbox.424e0eb6.js.map} +1 -1
- package/dist/chunks/{dropdown.257691c0.js → dropdown.57b2ea6f.js} +295 -317
- package/dist/chunks/dropdown.57b2ea6f.js.map +1 -0
- package/dist/chunks/{error-message.56247bcc.js → error-message.4bd22112.js} +2 -2
- package/dist/chunks/{error-message.56247bcc.js.map → error-message.4bd22112.js.map} +1 -1
- package/dist/chunks/{fixed-scroller.47546775.js → fixed-scroller.5b93a6a6.js} +2 -2
- package/dist/chunks/{fixed-scroller.47546775.js.map → fixed-scroller.5b93a6a6.js.map} +1 -1
- package/dist/chunks/{footer-actions.3c2dbf43.js → footer-actions.c401ec50.js} +4 -4
- package/dist/chunks/{footer-actions.3c2dbf43.js.map → footer-actions.c401ec50.js.map} +1 -1
- package/dist/chunks/index.11b6dd35.js +74 -0
- package/dist/chunks/index.11b6dd35.js.map +1 -0
- package/dist/chunks/{index.4fb57ba0.js → index.38752f78.js} +6 -6
- package/dist/chunks/{index.4fb57ba0.js.map → index.38752f78.js.map} +1 -1
- package/dist/chunks/index.73ac0db6.js +62 -0
- package/dist/chunks/index.73ac0db6.js.map +1 -0
- package/dist/chunks/{index.824101bb.js → index.8682bd04.js} +2 -2
- package/dist/chunks/{index.824101bb.js.map → index.8682bd04.js.map} +1 -1
- package/dist/chunks/{index.10c69f39.js → index.8b10ee32.js} +212 -191
- package/dist/chunks/index.8b10ee32.js.map +1 -0
- package/dist/chunks/{index.f800b267.js → index.98bbaed9.js} +2 -2
- package/dist/chunks/{index.f800b267.js.map → index.98bbaed9.js.map} +1 -1
- package/dist/chunks/{index.bf4a116b.js → index.aa83aa48.js} +3 -3
- package/dist/chunks/{index.bf4a116b.js.map → index.aa83aa48.js.map} +1 -1
- package/dist/chunks/{index.08d813e2.js → index.bab8811d.js} +6 -6
- package/dist/chunks/{index.08d813e2.js.map → index.bab8811d.js.map} +1 -1
- package/dist/chunks/{index.44f2aca7.js → index.ea65003b.js} +2 -2
- package/dist/chunks/{index.44f2aca7.js.map → index.ea65003b.js.map} +1 -1
- package/dist/chunks/{index.9aaed799.js → index.f71015d8.js} +3 -3
- package/dist/chunks/{index.9aaed799.js.map → index.f71015d8.js.map} +1 -1
- package/dist/chunks/{index.56c13d2c.js → index.faec0854.js} +15 -15
- package/dist/chunks/{index.56c13d2c.js.map → index.faec0854.js.map} +1 -1
- package/dist/chunks/{listbox-option-tag.4de1659c.js → listbox-option-tag.d1a3b340.js} +3 -3
- package/dist/chunks/{listbox-option-tag.4de1659c.js.map → listbox-option-tag.d1a3b340.js.map} +1 -1
- package/dist/chunks/{loading-button.6e15f27f.js → loading-button.2db95771.js} +2 -2
- package/dist/chunks/{loading-button.6e15f27f.js.map → loading-button.2db95771.js.map} +1 -1
- package/dist/chunks/{payment-method.df1b62db.js → payment-method.26fa5509.js} +2 -2
- package/dist/chunks/{payment-method.df1b62db.js.map → payment-method.26fa5509.js.map} +1 -1
- package/dist/chunks/{tooltip.066fd8f7.js → tooltip.e29f7d7e.js} +3 -3
- package/dist/chunks/{tooltip.066fd8f7.js.map → tooltip.e29f7d7e.js.map} +1 -1
- package/dist/chunks/use-bento-toast-controller.98ca249a.js +50 -0
- package/dist/chunks/use-bento-toast-controller.98ca249a.js.map +1 -0
- package/dist/chunks/use-cached-selected-values.a9b0fb3d.js +1537 -0
- package/dist/chunks/use-cached-selected-values.a9b0fb3d.js.map +1 -0
- package/dist/code-snippet.js +7 -7
- package/dist/code-snippet.js.map +1 -1
- package/dist/country.js +2 -2
- package/dist/currency.js +1 -1
- package/dist/data-grid-template.js +1 -1
- package/dist/data-grid.js +1207 -1169
- package/dist/data-grid.js.map +1 -1
- package/dist/date-picker.js +19 -19
- package/dist/date-picker.js.map +1 -1
- package/dist/date-range-picker.js +2 -2
- package/dist/date.js +1 -1
- package/dist/divider.js +1 -1
- package/dist/dropdown.js +7 -7
- package/dist/empty-state.js +3 -3
- package/dist/filter-bar.js +1260 -1112
- package/dist/filter-bar.js.map +1 -1
- package/dist/focus-trap.js +1 -1
- package/dist/form-layout.js +2 -2
- package/dist/header.js +4 -4
- package/dist/index.js +259 -274
- package/dist/index.js.map +1 -1
- package/dist/info-icon.js +3 -3
- package/dist/input-field.js +100 -93
- package/dist/input-field.js.map +1 -1
- package/dist/internal.js +31 -78
- package/dist/internal.js.map +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 +6 -6
- package/dist/modal.js +6 -6
- package/dist/pagination.js +4 -4
- package/dist/payment-method.js +1 -1
- package/dist/popover.js +1 -1
- package/dist/popper-container.js +1 -1
- package/dist/radio-group.js +112 -112
- package/dist/radio-group.js.map +1 -1
- package/dist/search-bar.js +2 -2
- package/dist/secondary-nav.js +2 -2
- package/dist/segmented-control.js +3 -3
- package/dist/selection-card.js +4 -4
- package/dist/sidepanel.js +64 -62
- package/dist/sidepanel.js.map +1 -1
- 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 +4 -4
- package/dist/timeline.js +7 -7
- package/dist/toast.js +185 -154
- package/dist/toast.js.map +1 -1
- package/dist/toggle.js +2 -2
- package/dist/tutorial.js +6 -6
- package/dist/typography.js +1 -1
- package/dist/web-types.json +1 -1
- package/package.json +7 -3
- package/dist/@types/packages/vue2/src/components/toast/components/toast-item/index.d.ts +0 -2
- package/dist/@types/packages/vue2/src/components/toast/components/toast-item/toast-item.types.d.ts +0 -9
- package/dist/@types/packages/vue2/src/plugins/toastController.d.ts +0 -12
- package/dist/@types/packages/vue2/src/utils/ts/toastController.d.ts +0 -2
- package/dist/chunks/dialog-page.d505c5ec.js +0 -172
- package/dist/chunks/dialog-page.d505c5ec.js.map +0 -1
- package/dist/chunks/dropdown.257691c0.js.map +0 -1
- package/dist/chunks/index.0e01e0b2.js +0 -101
- package/dist/chunks/index.0e01e0b2.js.map +0 -1
- package/dist/chunks/index.10c69f39.js.map +0 -1
- package/dist/chunks/index.99c63a74.js +0 -125
- package/dist/chunks/index.99c63a74.js.map +0 -1
- package/dist/chunks/info-filled.a6f9d7d0.js +0 -44
- package/dist/chunks/info-filled.a6f9d7d0.js.map +0 -1
- package/dist/chunks/listbox.eb436d06.js +0 -1466
- package/dist/chunks/listbox.eb436d06.js.map +0 -1
- package/dist/chunks/toastController.0b01d2e8.js +0 -9
- package/dist/chunks/toastController.0b01d2e8.js.map +0 -1
|
@@ -1,172 +0,0 @@
|
|
|
1
|
-
import { openBlock as n, createElementBlock as u, mergeProps as M, toDisplayString as Z, createCommentVNode as c, createElementVNode as q, defineComponent as Q, useSlots as W, ref as g, computed as r, inject as N, watch as h, nextTick as P, onUnmounted as X, createBlock as ee, Transition as te, unref as e, withCtx as A, normalizeClass as B, normalizeStyle as ae, createVNode as C, renderSlot as y } from "vue";
|
|
2
|
-
import { a as oe } from "./button.e965bf53.js";
|
|
3
|
-
import { _ as O } from "./_plugin-vue_export-helper.dad06003.js";
|
|
4
|
-
import { u as se } from "./use-has-slot.4d98bf29.js";
|
|
5
|
-
import { u as le } from "./i18n.f7e6533e.js";
|
|
6
|
-
import { i as ne } from "./index.99c63a74.js";
|
|
7
|
-
import "../assets/dialog-page.css";
|
|
8
|
-
let $ = 0;
|
|
9
|
-
const ie = {
|
|
10
|
-
beforeCreate() {
|
|
11
|
-
this.uuid = $.toString(), $ += 1;
|
|
12
|
-
}
|
|
13
|
-
}, re = { key: 0 }, ue = /* @__PURE__ */ q("path", {
|
|
14
|
-
fill: "#00112C",
|
|
15
|
-
d: "M3.80655 7.25434L8.06077 3.00011L7.00011 1.93945L0.939453 8.00011L7.00011 14.0608L8.06077 13.0001L3.81499 8.75433L14.7508 8.74316L14.7492 7.24316L3.80655 7.25434Z"
|
|
16
|
-
}, null, -1);
|
|
17
|
-
function ce(t, S, i, b, v, w) {
|
|
18
|
-
return n(), u("svg", M({ role: "img" }, t.$attrs, {
|
|
19
|
-
class: "ui-assets-icons-16",
|
|
20
|
-
xmlns: "http://www.w3.org/2000/svg",
|
|
21
|
-
width: "16",
|
|
22
|
-
height: "16",
|
|
23
|
-
fill: "none"
|
|
24
|
-
}), [
|
|
25
|
-
t.$attrs["svg-title"] ? (n(), u("title", re, Z(t.$attrs["svg-title"]), 1)) : c("", !0),
|
|
26
|
-
ue
|
|
27
|
-
], 16);
|
|
28
|
-
}
|
|
29
|
-
const de = /* @__PURE__ */ O(ie, [["render", ce]]);
|
|
30
|
-
var E = /* @__PURE__ */ ((t) => (t.TRANSITION_LEVEL_DEEPER = "b-dialog-page__animation--level-deeper", t.TRANSITION_LEVEL_UPPER = "b-dialog-page__animation--level-upper", t))(E || {});
|
|
31
|
-
const ve = Symbol("dialog registerPage injection key"), ge = Symbol("dialog page config data injection key"), R = {
|
|
32
|
-
"en-US": {
|
|
33
|
-
goToPreviousPage: "Go to previous page"
|
|
34
|
-
}
|
|
35
|
-
}, _e = {
|
|
36
|
-
key: 0,
|
|
37
|
-
class: "b-dialog-page"
|
|
38
|
-
}, pe = {
|
|
39
|
-
i18n: { messages: R }
|
|
40
|
-
}, fe = /* @__PURE__ */ Q({
|
|
41
|
-
...pe,
|
|
42
|
-
__name: "dialog-page",
|
|
43
|
-
props: {
|
|
44
|
-
/**
|
|
45
|
-
* Identifier of the page, used with activePage prop to handle navigation
|
|
46
|
-
*/
|
|
47
|
-
pageId: {
|
|
48
|
-
type: String,
|
|
49
|
-
default: void 0
|
|
50
|
-
},
|
|
51
|
-
/**
|
|
52
|
-
* Show header and actions border
|
|
53
|
-
*/
|
|
54
|
-
alwaysShowBorder: {
|
|
55
|
-
type: Boolean,
|
|
56
|
-
default: !1
|
|
57
|
-
},
|
|
58
|
-
/**
|
|
59
|
-
* Pass custom styling to the back button to position it correctly with the header slot
|
|
60
|
-
*/
|
|
61
|
-
backButtonStyling: { type: Object, default: null },
|
|
62
|
-
/**
|
|
63
|
-
* ID of the page for the back button to navigate to. Only use it to overwrite the default back behavior
|
|
64
|
-
* Used when the back button should not take the user to the natural previous page
|
|
65
|
-
* Set to `null` to hide back button in the page
|
|
66
|
-
*/
|
|
67
|
-
previousPage: {
|
|
68
|
-
type: String,
|
|
69
|
-
default: void 0
|
|
70
|
-
}
|
|
71
|
-
},
|
|
72
|
-
emits: ["animationend"],
|
|
73
|
-
setup(t, { emit: S }) {
|
|
74
|
-
const i = t, b = W(), v = se(b), { t: w } = le({ messages: R }), o = g(null), _ = g(!1), I = g(!0), L = g(!1), p = r(() => l.value ? l.value === i.pageId : !0), G = r(() => ({
|
|
75
|
-
"b-dialog-page__header--with-border": i.alwaysShowBorder || _.value && !I.value
|
|
76
|
-
})), V = r(() => ({
|
|
77
|
-
"b-dialog-page__footer--with-border": i.alwaysShowBorder || _.value && !L.value
|
|
78
|
-
})), D = () => {
|
|
79
|
-
o.value && (I.value = o.value.scrollTop === 0, L.value = o.value.scrollHeight - o.value.clientHeight === o.value.scrollTop);
|
|
80
|
-
}, T = async (a) => {
|
|
81
|
-
a && (await P(), _.value = o.value && o.value.scrollHeight > o.value.clientHeight);
|
|
82
|
-
}, { activePage: l, animation: f, isOpen: m, pages: x, previousPages: s, updatePage: H } = N(
|
|
83
|
-
ge
|
|
84
|
-
);
|
|
85
|
-
h(() => m.value, T, { immediate: !0 }), h(() => p.value, T, { immediate: !0 });
|
|
86
|
-
const j = r(() => i.previousPage ? !0 : i.previousPage === null ? !1 : z.value && p.value), U = () => {
|
|
87
|
-
f.value = E.TRANSITION_LEVEL_DEEPER, S("animationend");
|
|
88
|
-
}, z = r(() => s.value.length > 1), k = r(() => s.value[s.value.length - 1]), J = r(() => x.value.some((a) => a === l.value)), K = async (a) => {
|
|
89
|
-
if (a) {
|
|
90
|
-
const d = s.value.indexOf(a);
|
|
91
|
-
d !== -1 ? s.value = s.value.slice(0, d + 1) : s.value = [a];
|
|
92
|
-
} else
|
|
93
|
-
s.value.pop();
|
|
94
|
-
f.value = E.TRANSITION_LEVEL_UPPER, await P(), H(k.value);
|
|
95
|
-
};
|
|
96
|
-
h(
|
|
97
|
-
() => l.value,
|
|
98
|
-
async () => {
|
|
99
|
-
if (await P(), !!m.value) {
|
|
100
|
-
if (l.value && !J.value && ne) {
|
|
101
|
-
console.error(
|
|
102
|
-
`The activePage passed "${l.value}" does not match the id of any of the pages`
|
|
103
|
-
);
|
|
104
|
-
return;
|
|
105
|
-
}
|
|
106
|
-
l.value !== k.value && s.value.push(l.value);
|
|
107
|
-
}
|
|
108
|
-
},
|
|
109
|
-
{ immediate: !0 }
|
|
110
|
-
);
|
|
111
|
-
const Y = N(ve), { unregisterPage: F } = Y(i.pageId);
|
|
112
|
-
return X(() => F()), (a, d) => (n(), ee(te, {
|
|
113
|
-
name: e(f),
|
|
114
|
-
mode: "out-in",
|
|
115
|
-
onAfterLeave: U
|
|
116
|
-
}, {
|
|
117
|
-
default: A(() => [
|
|
118
|
-
e(m) && e(p) ? (n(), u("div", _e, [
|
|
119
|
-
e(v)("header") ? (n(), u("div", {
|
|
120
|
-
key: 0,
|
|
121
|
-
class: B(["b-dialog-page__header", e(G)])
|
|
122
|
-
}, [
|
|
123
|
-
e(j) ? (n(), u("div", {
|
|
124
|
-
key: 0,
|
|
125
|
-
class: "b-dialog-page__back-button",
|
|
126
|
-
style: ae(t.backButtonStyling),
|
|
127
|
-
"data-testid": "back-button"
|
|
128
|
-
}, [
|
|
129
|
-
C(e(oe), {
|
|
130
|
-
variant: "tertiary",
|
|
131
|
-
onClick: d[0] || (d[0] = (me) => K(t.previousPage))
|
|
132
|
-
}, {
|
|
133
|
-
default: A(() => [
|
|
134
|
-
C(e(de), {
|
|
135
|
-
"svg-title": e(w)("goToPreviousPage")
|
|
136
|
-
}, null, 8, ["svg-title"])
|
|
137
|
-
]),
|
|
138
|
-
_: 1
|
|
139
|
-
})
|
|
140
|
-
], 4)) : c("", !0),
|
|
141
|
-
y(a.$slots, "header", {}, void 0, !0)
|
|
142
|
-
], 2)) : c("", !0),
|
|
143
|
-
e(v)("content") ? (n(), u("div", {
|
|
144
|
-
key: 1,
|
|
145
|
-
ref_key: "contentElement",
|
|
146
|
-
ref: o,
|
|
147
|
-
class: "b-dialog-page__content",
|
|
148
|
-
onScroll: D
|
|
149
|
-
}, [
|
|
150
|
-
y(a.$slots, "content", {}, void 0, !0)
|
|
151
|
-
], 544)) : c("", !0),
|
|
152
|
-
e(v)("footer") ? (n(), u("div", {
|
|
153
|
-
key: 2,
|
|
154
|
-
class: B(["b-dialog-page__footer", e(V)])
|
|
155
|
-
}, [
|
|
156
|
-
y(a.$slots, "footer", {}, void 0, !0)
|
|
157
|
-
], 2)) : c("", !0)
|
|
158
|
-
])) : c("", !0)
|
|
159
|
-
]),
|
|
160
|
-
_: 3
|
|
161
|
-
}, 8, ["name"]));
|
|
162
|
-
}
|
|
163
|
-
});
|
|
164
|
-
const we = /* @__PURE__ */ O(fe, [["__scopeId", "data-v-af5820fe"]]);
|
|
165
|
-
export {
|
|
166
|
-
de as A,
|
|
167
|
-
E as B,
|
|
168
|
-
we as D,
|
|
169
|
-
ve as a,
|
|
170
|
-
ge as b
|
|
171
|
-
};
|
|
172
|
-
//# sourceMappingURL=dialog-page.d505c5ec.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"dialog-page.d505c5ec.js","sources":["../../../../node_modules/@adyen/ui-assets-icons-16/dist/vue/arrow-left.vue","../../../vue2/src/components/internal/dialog-page/dialog-page.types.ts","../../../vue2/src/components/internal/dialog-page/dialog-page.keys.ts","../../../vue2/src/components/internal/dialog-page/dialog-page.vue"],"sourcesContent":["\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=\"#00112C\" d=\"M3.80655 7.25434L8.06077 3.00011L7.00011 1.93945L0.939453 8.00011L7.00011 14.0608L8.06077 13.0001L3.81499 8.75433L14.7508 8.74316L14.7492 7.24316L3.80655 7.25434Z\"/></svg>\n</template>\n<script>\n let uuid = 0;\n\n export default {\n beforeCreate() {\n this.uuid = uuid.toString();\n uuid += 1;\n },\n };\n</script>\n<style>\n @import '../css/main.css';\n</style>\n","import { Ref } from 'vue';\n\nexport enum BentoDialogPageAnimation {\n TRANSITION_LEVEL_DEEPER = 'b-dialog-page__animation--level-deeper',\n TRANSITION_LEVEL_UPPER = 'b-dialog-page__animation--level-upper',\n}\n\nexport interface BentoDialogPageConfigData {\n activePage: Ref<string>;\n animation: Ref<string>;\n isOpen: Ref<boolean>;\n pages: Ref<string[]>;\n previousPages: Ref<string[]>;\n updatePage: (page: string) => void;\n}\n\nexport type BentoDialogPageRegisterPage = (pageId: string) => { unregisterPage: () => void };\n","export const DIALOG_PAGE_REGISTER_PAGE_INJECTION_KEY = Symbol('dialog registerPage injection key');\nexport const DIALOG_PAGE_CONFIG_INJECTION_KEY = Symbol('dialog page config data injection key');\n","<template>\n <Transition :name=\"animation\" mode=\"out-in\" @after-leave=\"updateAnimation\">\n <div v-if=\"isOpen && showPage\" class=\"b-dialog-page\">\n <div v-if=\"hasSlot('header')\" class=\"b-dialog-page__header\" :class=\"headerConditionalClasses\">\n <div\n v-if=\"showBackButton\"\n class=\"b-dialog-page__back-button\"\n :style=\"backButtonStyling\"\n data-testid=\"back-button\"\n >\n <bento-button variant=\"tertiary\" @click=\"goToPreviousPage(previousPage)\">\n <arrow-left-icon :svg-title=\"t('goToPreviousPage')\" />\n </bento-button>\n </div>\n <slot name=\"header\"></slot>\n </div>\n <div v-if=\"hasSlot('content')\" ref=\"contentElement\" class=\"b-dialog-page__content\" @scroll=\"onScroll\">\n <slot name=\"content\" />\n </div>\n <div v-if=\"hasSlot('footer')\" class=\"b-dialog-page__footer\" :class=\"footerConditionalClasses\">\n <slot name=\"footer\" />\n </div>\n </div>\n </Transition>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, inject, nextTick, onUnmounted, PropType, ref, useSlots, watch } from 'vue';\n\n import { BentoButton } from '@/components/button';\n import ArrowLeftIcon from '@adyen/ui-assets-icons-16/vue/arrow-left';\n\n import { useHasSlot } from '@/composables/use-has-slot/use-has-slot';\n import { useI18n } from '@/utils/ts/i18n';\n import { isDevelopmentEnviroment } from '@/utils/ts/dev-environment';\n\n import {\n BentoDialogPageAnimation,\n BentoDialogPageConfigData,\n BentoDialogPageRegisterPage,\n } from './dialog-page.types';\n import type { CSSProperties } from 'vue/types/jsx';\n\n import { DIALOG_PAGE_CONFIG_INJECTION_KEY, DIALOG_PAGE_REGISTER_PAGE_INJECTION_KEY } from './dialog-page.keys';\n\n import messages from './messages.json';\n\n type MessageSchema = (typeof messages)['en-US'];\n\n const props = defineProps({\n /**\n * Identifier of the page, used with activePage prop to handle navigation\n */\n pageId: {\n type: String,\n default: undefined,\n },\n\n /**\n * Show header and actions border\n */\n alwaysShowBorder: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Pass custom styling to the back button to position it correctly with the header slot\n */\n backButtonStyling: { type: Object as PropType<CSSProperties>, default: null },\n\n /**\n * ID of the page for the back button to navigate to. Only use it to overwrite the default back behavior\n * Used when the back button should not take the user to the natural previous page\n * Set to `null` to hide back button in the page\n */\n previousPage: {\n type: String,\n default: undefined,\n },\n });\n\n const emit = defineEmits<{\n /**\n * Fires when the animation ends\n */\n (e: 'animationend'): void;\n }>();\n\n const slots = useSlots();\n const hasSlot = useHasSlot(slots);\n const { t } = useI18n<{ message: MessageSchema }>({ messages });\n\n // Refs\n const contentElement = ref<HTMLDivElement>(null);\n const hasScroll = ref(false);\n const isScrollAtTop = ref(true);\n const isScrollAtBottom = ref(false);\n\n // Logic to choose which page is active/shown\n const showPage = computed(() => (activePage.value ? activePage.value === props.pageId : true));\n\n // Scrolling styling logic\n const headerConditionalClasses = computed(() => ({\n 'b-dialog-page__header--with-border': props.alwaysShowBorder || (hasScroll.value && !isScrollAtTop.value),\n }));\n\n const footerConditionalClasses = computed(() => ({\n 'b-dialog-page__footer--with-border': props.alwaysShowBorder || (hasScroll.value && !isScrollAtBottom.value),\n }));\n\n const onScroll = () => {\n if (!contentElement.value) {\n return;\n }\n\n isScrollAtTop.value = contentElement.value.scrollTop === 0;\n isScrollAtBottom.value =\n contentElement.value.scrollHeight - contentElement.value.clientHeight === contentElement.value.scrollTop;\n };\n\n const calculateScroll = async watchedValue => {\n if (!watchedValue) {\n return;\n }\n // Wait for content to be rendered to be able to calculate the height\n await nextTick();\n hasScroll.value = contentElement.value && contentElement.value.scrollHeight > contentElement.value.clientHeight;\n };\n\n const { activePage, animation, isOpen, pages, previousPages, updatePage } = inject<BentoDialogPageConfigData>(\n DIALOG_PAGE_CONFIG_INJECTION_KEY\n );\n\n watch(() => isOpen.value, calculateScroll, { immediate: true });\n watch(() => showPage.value, calculateScroll, { immediate: true });\n\n // Logic to determine whether the back button should be shown on the page\n const showBackButton = computed(() => {\n if (props.previousPage) {\n return true;\n }\n if (props.previousPage === null) {\n return false;\n }\n return hasPreviousPages.value && showPage.value;\n });\n\n // Animation\n const updateAnimation = () => {\n animation.value = BentoDialogPageAnimation.TRANSITION_LEVEL_DEEPER;\n emit('animationend');\n };\n\n // Previous page logic\n const hasPreviousPages = computed(() => previousPages.value.length > 1);\n const lastPage = computed(() => previousPages.value[previousPages.value.length - 1]);\n const isActivePageValid = computed(() => pages.value.some(page => page === activePage.value));\n\n const goToPreviousPage = async (page: string) => {\n if (page) {\n const index = previousPages.value.indexOf(page);\n if (index !== -1) {\n previousPages.value = previousPages.value.slice(0, index + 1);\n } else {\n previousPages.value = [page];\n }\n } else {\n previousPages.value.pop();\n }\n\n animation.value = BentoDialogPageAnimation.TRANSITION_LEVEL_UPPER;\n await nextTick();\n updatePage(lastPage.value);\n };\n\n // Add new page to the previousPage array to keep track of user navigation\n watch(\n () => activePage.value,\n async () => {\n await nextTick();\n if (!isOpen.value) {\n return;\n }\n\n if (!!activePage.value && !isActivePageValid.value) {\n if (isDevelopmentEnviroment) {\n // eslint-disable-next-line no-console\n console.error(\n `The activePage passed \"${activePage.value}\" does not match the id of any of the pages`\n );\n return;\n }\n }\n\n if (activePage.value !== lastPage.value) {\n previousPages.value.push(activePage.value);\n }\n },\n { immediate: true }\n );\n\n // Register page to parent component and inject data from parent component\n const registerPage = inject<BentoDialogPageRegisterPage>(DIALOG_PAGE_REGISTER_PAGE_INJECTION_KEY);\n const { unregisterPage } = registerPage(props.pageId);\n\n // Unregister page on unmounting the page\n onUnmounted(() => unregisterPage());\n</script>\n\n<script lang=\"ts\">\n /**\n * DialogPage is an internal component used to render different pages of dialog components (Modal, ModalFullscreen and Sidepanel)\n *\n * @example\n * import { DialogPage } from '@/internal';\n *\n * export default {\n * components: { DialogPage },\n * template: `\n * <dialog-page pageId='step1' always-show-border>\n * <template #header>Header</template>\n * <template #content>Content</template>\n * <template #footer>Footer</template>\n * </dialog-page>\n * `\n * }\n */\n export default {\n i18n: { messages },\n };\n</script>\n\n<style lang=\"scss\" scoped src=\"./dialog-page.scss\" />\n"],"names":["uuid","openBlock","createElementBlock","mergeProps","_ctx","_hoisted_1$1","toDisplayString","BentoDialogPageAnimation","BentoDialogPageAnimation2","DIALOG_PAGE_REGISTER_PAGE_INJECTION_KEY","DIALOG_PAGE_CONFIG_INJECTION_KEY","__default__","messages","slots","useSlots","hasSlot","useHasSlot","t","useI18n","contentElement","ref","hasScroll","isScrollAtTop","isScrollAtBottom","showPage","computed","activePage","props","headerConditionalClasses","footerConditionalClasses","onScroll","calculateScroll","watchedValue","nextTick","animation","isOpen","pages","previousPages","updatePage","inject","watch","showBackButton","hasPreviousPages","updateAnimation","emit","lastPage","isActivePageValid","page","goToPreviousPage","index","isDevelopmentEnviroment","registerPage","unregisterPage","onUnmounted"],"mappings":";;;;;;;AAKI,IAAAA,IAAA;;EAGI,eAAA;8BAEIA,KAAA;AAAA;;EARkM,MAAA;AAAA,EAAe,GAAA;;;AAAzN,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;6BAAYH,EAAA,GAAAC,EAAA,SAAAG,IAAAC,EAAAF,EAAA,OAAA,WAAA,CAAA,GAAA,CAAA;;;;;ACAzH,IAAAG,IAAA,kB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AD,EAAAxB,EAAA,MAAA;AAGA,WAAA0B,EAAA,MAAAD,EAAA,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[0]}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"dropdown.257691c0.js","sources":["../../../vue2/src/components/dropdown/dropdown.types.ts","../../../vue2/src/components/dropdown/components/dropdown-options-container/composables/use-dropdown-options-listbox.ts","../../../vue2/src/components/dropdown/components/dropdown-options-container/dropdown-options-container.vue","../../../../node_modules/@adyen/ui-assets-icons-16/dist/vue/chevron-down-small.vue","../../../../node_modules/@adyen/ui-assets-icons-16/dist/vue/chevron-up-small.vue","../../../vue2/src/components/dropdown/components/dropdown-small-textbox/dropdown-small-textbox.vue","../../../vue2/src/components/dropdown/composables/use-display-value.ts","../../../vue2/src/components/dropdown/composables/use-keyboard-navigation.ts","../../../vue2/src/components/search-bar/useSearchBarDataFilter.ts","../../../vue2/src/components/input-field/input-field.keys.ts","../../../vue2/src/components/dropdown/dropdown.vue"],"sourcesContent":["/**\n * @deprecated Do not use. Only 'default' size should be used.\n */\nexport enum BentoDropdownSize {\n DEFAULT = 'DropdownInputDefault',\n SMALL = 'DropdownInputSmall',\n}\n\nexport {\n /**\n * @deprecated since version 2.0. Use the string literal instead.\n */\n BentoListboxLazyLoadType as BentoDropdownLazyLoadType,\n BentoListboxEvent as BentoDropdownEvent,\n} from '@/types';\n\nexport type { BentoListboxSearchOptions as BentoDropdownSearchOptions } from '@/types';\nexport type { BentoListboxEmptyStateProps as BentoDropdownEmptyStateProps } from '@/types';\nexport type { BentoListboxVirtulisationOptions as BentoDropdownVirtulisationOptions } from '@/types';\n","import { computed, ref, Ref, watch } from 'vue';\nimport { BentoListboxEvent, BentoListboxSelectedValue } from '@/types';\nimport { BentoDropdownEvent } from '../../../dropdown.types';\nimport { useI18n } from '@/utils/ts/i18n';\nimport messages from '../messages.json';\n\ntype MessageSchema = (typeof messages)['en-US'];\n\n/**\n * A composable that handles all dropdown options option selecting logic & listeners.\n * If single select dropdown then emits straight up to dropdown.\n * If multi select dropdown then stores selections in internal state and only emits when Apply button is pressed.\n *\n * @param selectedValue The selectedValue property passed into the dropdown options container component.\n * @param multiple The multiple property passed into the dropdown options container component.\n * @param isOpen The isOpen property passed into the dropdown options container component.\n * @param emit The emit function for the dropdown options container component.\n */\nexport const useDropdownOptionsListbox = (\n selectedValue: Ref<BentoListboxSelectedValue>,\n multiple: Ref<boolean>,\n isOpen: Ref<boolean>,\n emit: (event: BentoListboxEvent | BentoDropdownEvent, selectedValue?: BentoListboxSelectedValue) => void\n) => {\n const internalSelectedValue = ref(selectedValue.value);\n const { t } = useI18n<{ message: MessageSchema }>({ messages });\n\n watch(selectedValue, () => {\n internalSelectedValue.value = selectedValue.value;\n });\n\n // Multi-select dropdown cancel and apply button logic\n const isApplyButtonDisabled = computed(\n () => JSON.stringify(internalSelectedValue.value) === JSON.stringify(selectedValue.value)\n );\n\n const onApplyClick = () => {\n emit(BentoListboxEvent.SELECT, internalSelectedValue.value);\n emit(BentoDropdownEvent.CLOSE_DROPDOWN);\n };\n\n const onCancelClick = () => {\n internalSelectedValue.value = selectedValue.value;\n emit(BentoDropdownEvent.CLOSE_DROPDOWN);\n };\n\n const onOutsideDropdownClick = () => {\n if (isOpen.value && multiple.value) {\n internalSelectedValue.value = selectedValue.value;\n }\n };\n\n const actions = computed(() => [\n {\n title: t('apply') as string,\n event: onApplyClick,\n disabled: isApplyButtonDisabled.value,\n },\n {\n title: t('cancel') as string,\n event: onCancelClick,\n },\n ]);\n\n // Click and keyboard navigation event listners\n const onOptionSelected = (newSelectedValue: BentoListboxSelectedValue) => {\n internalSelectedValue.value = newSelectedValue;\n if (!multiple.value) {\n emit(BentoDropdownEvent.SELECT, newSelectedValue);\n }\n };\n\n const onTabKey = (newSelectedValue: BentoListboxSelectedValue) => {\n onOptionSelected(newSelectedValue);\n emit(BentoDropdownEvent.TAB);\n };\n\n const onEnterKey = (newSelectedValue: BentoListboxSelectedValue) => {\n onOptionSelected(newSelectedValue);\n emit(BentoDropdownEvent.ENTER);\n };\n\n const onSpaceKey = (newSelectedValue: BentoListboxSelectedValue) => {\n onOptionSelected(newSelectedValue);\n emit(BentoDropdownEvent.SPACE);\n };\n\n const onEscapeKey = () => {\n onCancelClick();\n emit(BentoListboxEvent.ESCAPE);\n };\n\n const emitShowMoreEvent = () => {\n emit(BentoDropdownEvent.SHOW_MORE);\n };\n\n const listeners = {\n [BentoListboxEvent.SELECT]: onOptionSelected,\n [BentoListboxEvent.SHOW_MORE]: emitShowMoreEvent,\n [BentoListboxEvent.TAB]: onTabKey,\n [BentoListboxEvent.SPACE]: onSpaceKey,\n [BentoListboxEvent.ENTER]: onEnterKey,\n };\n\n return {\n // Values\n actions,\n internalSelectedValue,\n\n // Methods\n listeners,\n onEscapeKey,\n onOutsideDropdownClick,\n };\n};\n","<template>\n <component\n :is=\"popperContainerOrPopoverComponent\"\n class=\"b-dropdown-options-container\"\n :class=\"conditionalClasses\"\n v-bind=\"popperContainerOrPopoverProps\"\n >\n <div @keydown.esc=\"onEscapeKey\">\n <bento-listbox\n :id=\"id\"\n ref=\"dropdownOptionsListboxRef\"\n :aria-label=\"ariaLabel\"\n class=\"b-dropdown-options-container__listbox\"\n :class=\"conditionalListboxClasses\"\n :empty-state=\"emptyState\"\n :is-option-disabled=\"isOptionDisabled\"\n :items=\"items\"\n :selected-value=\"internalSelectedValue\"\n :multiple=\"multiple\"\n :static-categories=\"staticCategories\"\n :no-results-message=\"noResultsMessage\"\n :searching=\"searching\"\n :loading=\"loading\"\n :lazy-load-type=\"lazyLoadType\"\n :has-more-items=\"hasMoreItems\"\n :virtual-scroll=\"virtualScroll\"\n v-on=\"listeners\"\n >\n <template v-for=\"(_, innerSlot) of slots\" #[innerSlot]=\"scope\">\n <slot :name=\"innerSlot\" v-bind=\"scope\" />\n </template>\n </bento-listbox>\n </div>\n </component>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, defineComponent, PropType, ref, toRefs, useSlots } from 'vue';\n import { BentoListbox } from '@/internal';\n import {\n BentoListboxEvent,\n BentoListboxIsOptionDisabled,\n BentoListboxOptions,\n BentoListboxSelectedValue,\n } from '@/types';\n import { PopperContainer } from '@/components/popper-container';\n import {\n BentoDropdownEmptyStateProps,\n BentoDropdownEvent,\n BentoDropdownLazyLoadType,\n BentoDropdownSize,\n BentoDropdownVirtulisationOptions,\n } from '../../dropdown.types';\n import { useI18n } from '@/utils/ts/i18n';\n import { BentoPopover } from '@/components/popover';\n import { useDropdownOptionsListbox } from './composables/use-dropdown-options-listbox';\n import { generateUid } from '@/utils/ts/unique-id';\n import messages from './messages.json';\n\n type MessageSchema = (typeof messages)['en-US'];\n\n const slots = useSlots();\n\n const emit = defineEmits<{\n /**\n * Emitted when the dropdown is closing.\n */\n (e: BentoDropdownEvent.CLOSE_DROPDOWN);\n\n /**\n * Emitted when the `ENTER` key is pressed\n */\n (e: BentoListboxEvent.ENTER, newSelectedValue: BentoListboxSelectedValue);\n\n /**\n * Emitted when the `ESCAPE` key is pressed\n */\n (e: BentoListboxEvent.ESCAPE);\n\n /**\n * Emitted when an item is selected\n */\n (e: BentoListboxEvent.SELECT, newSelectedValue: BentoListboxSelectedValue);\n\n /**\n * Emitted when:\n * - `lazyLoad` is `automatic` and the scroll meets the end of the list\n * - `lazyload` is `button` and the button is clicked\n */\n (e: BentoDropdownEvent.SHOW_MORE);\n\n /**\n * Emitted when the `SPACE` key is pressed\n */\n (e: BentoListboxEvent.SPACE, newSelectedValue: BentoListboxSelectedValue);\n\n /**\n * Emitted when the `TAB` key is pressed\n */\n (e: BentoListboxEvent.TAB, newSelectedValue: BentoListboxSelectedValue);\n }>();\n\n const props = defineProps({\n /**\n * Defines a string value that labels an interactive element.\n */\n ariaLabel: { type: String, default: null },\n\n /**\n * Empty state props used with the inner empty state component which is displayed when no search results are found.\n */\n emptyState: {\n type: Object as PropType<BentoDropdownEmptyStateProps>,\n default: undefined,\n },\n\n /**\n * Disables dropdown functionality\n */\n disabled: { type: Boolean, default: false },\n\n /**\n * Indicates whether there are more items to load\n */\n hasMoreItems: { type: Boolean, default: false },\n\n /**\n * Identifies the listbox whose contents are controlled by the the combobox on which the aria-controls attribute is set.\n */\n id: { type: String, required: true },\n\n /**\n * Dropdown input size\n */\n inputSize: {\n type: String as PropType<BentoDropdownSize | `${BentoDropdownSize}`>,\n default: BentoDropdownSize.DEFAULT,\n validator: (value: BentoDropdownSize) => Object.values(BentoDropdownSize).includes(value),\n },\n\n /**\n * Function that allows the options to be disabled\n *\n * @type {BentoDropdownIsOptionDisabled}\n * @param {BentoDropdownOptionItem} option - Dropdown option object\n * @param {string} option.label - Option's label text\n * @param {string|number} option.value - Option's value\n * @param {unknown} option.data - Option's extra data to be passed to the default slot\n */\n isOptionDisabled: {\n type: Function as PropType<BentoListboxIsOptionDisabled>,\n default: undefined,\n },\n\n /**\n * The option elements to populate the dropdown with.\n * It must be an array of {@see BentoDropdownOptionItem }\n * * @property {string} value.label - Text to be displayed in the option\n * * @property {string,number} value.value - Value of the option\n */\n items: {\n type: Array as PropType<BentoListboxOptions>,\n required: true,\n },\n\n /**\n * The type of `Lazy Load`.\n * Type \"automatic\" will enable infinite scrolling\n * Type \"button\" will enable lazy loading with \"Show more\" button\n */\n lazyLoadType: {\n type: String as PropType<BentoDropdownLazyLoadType | `${BentoDropdownLazyLoadType}`>,\n default: BentoDropdownLazyLoadType.AUTOMATIC,\n validator: (value: BentoDropdownLazyLoadType) => Object.values(BentoDropdownLazyLoadType).includes(value),\n },\n\n /**\n * Indicates if new options are loading.\n */\n loading: { type: Boolean, default: false },\n\n /**\n * If enabled, the user will be able to select multiple items.\n */\n multiple: { type: Boolean, default: false },\n\n /**\n * Indicates if the dropdown is open so that\n * the container can be displayed.\n */\n open: { type: Boolean, required: true },\n\n /**\n * The `input` value.\n * Providing an empty string or empty array will select no options.\n * Set to an empty string `''` if you don't want any of the available options to be selected for single select\n */\n selectedValue: {\n type: [String, Number, Array] as PropType<BentoListboxSelectedValue>,\n default: null,\n },\n\n /**\n * Flag that indicates that an external search it's being made\n * to filter out the items inside the the multi-select listbox\n *\n * If enabled, hides the \"Select all\" checkbox in \"multiple\" mode.\n */\n searching: BentoListbox.props.searching,\n\n /**\n * If enabled, dropdown will display non-selectable, static categories\n */\n staticCategories: { type: Boolean, default: false },\n\n /**\n * Reference to the DOM element or Vue component for positioning\n * the Dropdown container.\n */\n targetElement: { type: PopperContainer.props.targetElement.type, required: true },\n\n /**\n * Enables virtual scrolling if set to true or by providing an object with itemHeight function.\n * The itemHeight function is used to calculate the height of rendered item given it's index.\n */\n virtualScroll: {\n type: [Boolean, Object] as PropType<BentoDropdownVirtulisationOptions>,\n default: false,\n },\n });\n\n const { selectedValue, multiple } = toRefs(props);\n const dropdownOptionsListboxRef = ref(null);\n const { t } = useI18n<{ message: MessageSchema }>({ messages });\n const isDropdownOpen = computed(() => props.open && !props.disabled);\n const noResultsMessage = computed(() => t('noOptionsMatchThisSearch') as string);\n\n const conditionalClasses = computed(() => ({\n 'b-dropdown-options-container--single': !props?.multiple,\n }));\n\n const conditionalListboxClasses = computed(() => ({\n 'b-dropdown-options-container__listbox--small': props.inputSize === BentoDropdownSize.SMALL,\n 'b-dropdown-options-container__listbox--single': !props?.multiple,\n }));\n\n const { actions, internalSelectedValue, listeners, onEscapeKey, onOutsideDropdownClick } =\n useDropdownOptionsListbox(selectedValue, multiple, isDropdownOpen, emit);\n\n // Use different components depending on if the dropdown is a single or multi-select\n const popperContainerOrPopoverComponent = computed(() => (props?.multiple ? BentoPopover : PopperContainer));\n\n const popperContainerOrPopoverProps = computed(() => {\n const containerMinAndMaxWidth = {\n 'min-width': `${(props?.targetElement as HTMLElement)?.clientWidth}px`,\n 'max-width': 'min(500px, 95%)',\n };\n\n return props?.multiple\n ? ({\n actionsLayout: 'space-between',\n actions: actions.value,\n divider: true,\n fallbackPosition: ['top-start'],\n id: generateUid(`dropdown-options-${props.id}`),\n open: props.open,\n position: 'bottom-start',\n style: {\n width: 'auto',\n ...containerMinAndMaxWidth,\n },\n targetElement: props.targetElement,\n } as InstanceType<typeof BentoPopover>['$props'])\n : ({\n fallbackPosition: ['top-start'],\n offset: [0, 8],\n position: 'bottom-start',\n style: {\n display: isDropdownOpen.value ? 'block' : 'none',\n ...containerMinAndMaxWidth,\n },\n targetElement: props.targetElement,\n } as InstanceType<typeof PopperContainer>['$props']);\n });\n\n defineExpose({\n onOutsideDropdownClick,\n });\n</script>\n\n<script lang=\"ts\">\n /**\n * Dropdown options container.\n * It lists all the available options.\n *\n * @example\n * <bento-dropdown-options-container\n * v-if=\"inputContainerRef\" <!-- Ref to the input to match the width -->\n * :id=\"dropdownOptionsContainerId\"\n * :target-element=\"inputContainerRef\"\n * :aria-label=\"ariaLabel\"\n * :open=\"isDropdownOpen\"\n * :disabled=\"disabled\"\n * :multiple=\"multiple\"\n * :selected=\"value\"\n * :isOptionDisabled=\"option => option.value === 2\"\n * :items=\"[{\n * { label: 'Option 1', value: 1 },\n * { label: 'Option 2', value: 2 },\n * }]\"\n * @select=\"onOptionSelected\"\n * />\n */\n export default defineComponent({\n i18n: { messages },\n name: 'bento-dropdown-options-container',\n });\n</script>\n\n<style lang=\"scss\" scoped src=\"./dropdown-options-container.scss\" />\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=\"#00112C\" d=\"M5.00011 5.43922L8.00011 8.43922L11.0001 5.43922L12.0608 6.49988L8.00011 10.5605L3.93945 6.49988L5.00011 5.43922Z\"/></svg>\n</template>\n<script>\n let uuid = 0;\n\n export default {\n beforeCreate() {\n this.uuid = uuid.toString();\n uuid += 1;\n },\n };\n</script>\n<style>\n @import '../css/main.css';\n</style>\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=\"#00112C\" d=\"M10.9999 10.5608L7.9999 7.56077L4.9999 10.5608L3.93924 9.50011L7.9999 5.43945L12.0606 9.50011L10.9999 10.5608Z\"/></svg>\n</template>\n<script>\n let uuid = 0;\n\n export default {\n beforeCreate() {\n this.uuid = uuid.toString();\n uuid += 1;\n },\n };\n</script>\n<style>\n @import '../css/main.css';\n</style>\n","<template>\n <div class=\"b-dropdown-small-textbox\" :class=\"conditionalClasses\">\n <dropdown-base-textbox\n v-bind=\"{ ...$attrs, ...$props }\"\n class=\"b-dropdown-small-textbox__textbox\"\n v-on=\"listeners\"\n >\n <template #icon>\n <div class=\"b-dropdown-small-textbox__chevron\">\n <chevron-up-small-icon v-show=\"isDropdownOpen\" svg-title=\"opened\" />\n <chevron-down-small-icon v-show=\"!isDropdownOpen\" svg-title=\"closed\" />\n </div>\n </template>\n </dropdown-base-textbox>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, defineComponent, PropType } from 'vue';\n import {\n DropdownBaseTextboxEvent,\n DropdownBaseTextboxState,\n } from '@/components/dropdown/components/dropdown-base-textbox/dropdown-base-textbox.types';\n import { Booleanish } from '@/types';\n import DropdownBaseTextbox from '@/components/dropdown/components/dropdown-base-textbox/dropdown-base-textbox.vue';\n import ChevronDownSmallIcon from '@adyen/ui-assets-icons-16/vue/chevron-down-small';\n import ChevronUpSmallIcon from '@adyen/ui-assets-icons-16/vue/chevron-up-small';\n\n const emit = defineEmits<{\n /**\n * Emitted on click, space, enter and esc user events. It will close the dropdown.\n */\n (e: 'open');\n\n /**\n * Emitted on click, space and enter user events. It will open the dropdown.\n */\n (e: 'close');\n }>();\n\n const props = defineProps({\n /**\n * The number of additional items that have been selected in the dropdown.\n */\n additionalItemsSelected: { type: [Number, String] as PropType<number | string>, default: 0 },\n\n /**\n * Sets the aria-controls attribute on the textbox. This should correspond to the popover's id that the textbox triggers.\n */\n ariaControls: { type: String, required: true },\n\n /**\n * Indicates whether the content the textbox triggers is visible or not. Needs to be set accordingly when the textbox is used and changed every time the popover is shown/hidden.\n */\n ariaExpanded: {\n type: [String, Boolean] as PropType<Booleanish>,\n required: true,\n },\n\n /**\n * If no label element is used then the aria-label is be set should be set.\n */\n ariaLabel: { type: String, default: null },\n\n /**\n * Corresponds to the label's id that labels the textbox element.\n */\n ariaLabelledby: { type: String, default: null },\n\n /**\n * Custom debounce time. Default: 300\n */\n debounceTime: { type: Number, default: 300 },\n\n /**\n * Disables any textbox functionality\n */\n disabled: { type: Boolean, default: false },\n\n /**\n * Selected option's label\n */\n displayValue: { type: String, default: null },\n\n /**\n * Sets the possibility to type into the textbox\n */\n dynamicFiltering: { type: Boolean, default: false },\n\n /**\n * Marks the textbox as invalid, rendering an error state\n */\n isInvalid: { type: Boolean, default: false },\n\n /**\n * Indicates if the dropdown is open so that\n * the respective event can be emitted\n */\n open: { type: Boolean, default: false },\n\n /**\n * Sets the dropdown to readonly state\n */\n readonly: { type: Boolean, default: false },\n\n /**\n * The input value\n */\n value: { type: String, default: '' },\n });\n\n const conditionalClasses = computed(() => ({\n [`b-dropdown-small-textbox--${DropdownBaseTextboxState.DISABLED}`]: props.disabled,\n [`b-dropdown-small-textbox--${DropdownBaseTextboxState.READONLY}`]: props.readonly,\n [`b-dropdown-small-textbox--${DropdownBaseTextboxState.OPENED}`]: props.open,\n }));\n\n const isDropdownOpen = computed(() => props.open && !props.disabled && !props.readonly);\n\n const openDropdown = () => {\n emit('open');\n };\n\n const closeDropdown = () => {\n emit('close');\n };\n\n const listeners = {\n [DropdownBaseTextboxEvent.OPEN]: openDropdown,\n [DropdownBaseTextboxEvent.CLOSE]: closeDropdown,\n };\n</script>\n\n<script lang=\"ts\">\n /**\n * For internal use only, textbox component in its small variant used in the dropdown component.\n */\n export default defineComponent({\n name: 'dropdown-small-textbox',\n inheritAttrs: false,\n });\n</script>\n\n<style lang=\"scss\" scoped src=\"./dropdown-small-textbox.scss\" />\n","import { computed } from 'vue';\nimport {\n CategoryMultiSelectOptions,\n MultiSelectOptions,\n SingleSelectOptions,\n UseDisplayValue,\n} from './use-display-value.types';\nimport { BentoListboxMultiSelectValue, BentoListboxOptionItem } from '@/types';\n\n/**\n * Generates the `displayValue` for the Single select based on\n * the selection, the placeholder or it can be empty if there's nothing to show.\n *\n * @param options Single select options\n * @returns The text to be displayed by the dropdown\n */\nconst singleSelect = ({ items, placeholder, selectedValue, staticCategories }: SingleSelectOptions) => {\n // If no value selected, return placeholder or nothing\n // 0 is a possible value\n // eslint-disable-next-line eqeqeq -- The following are not valid value: undefined, null and empty string\n if (selectedValue.value == null || selectedValue.value === '') {\n return placeholder.value || null;\n }\n\n // Find selected values in the list of items\n let selectedItem: BentoListboxOptionItem;\n if (staticCategories) {\n const category = items.value.find(cat => cat.items.some(item => item.value === selectedValue.value));\n selectedItem = category?.items.find(item => item.value === selectedValue.value);\n } else {\n selectedItem = items.value.find(({ value }) => value === selectedValue.value);\n }\n\n // Return selected value's label or the selected value's value when it is not found\n return selectedItem ? selectedItem.label : selectedValue.value.toString();\n};\n\n/**\n * Generates the `displayValue` for the Multi Select based on\n * the selection, the placeholder or it can be empty if there's nothing to show.\n *\n * @param options Category select options\n * @returns The text to be displayed by the dropdown\n */\nconst multiSelect = ({ selectedValues, items, placeholder }: MultiSelectOptions) => {\n // No selected values\n if (!selectedValues.value || (selectedValues.value as BentoListboxMultiSelectValue)?.length === 0) {\n return placeholder.value || null;\n }\n\n return (selectedValues.value as BentoListboxMultiSelectValue)\n .map(selectedValue => {\n const selectedItem = items.value.find(({ value }) => value === selectedValue);\n return selectedItem ? selectedItem.label : selectedValue;\n })\n .join(', ');\n};\n\n/**\n * Generates the `displayValue` for the Category Multi Select based on\n * the selection, the placeholder or it can be empty if there's nothing to show.\n *\n * @param options Multi select options\n * @returns The text to be displayed by the dropdown\n */\nconst categoryMultiSelect = ({ selectedValues, items, placeholder }: CategoryMultiSelectOptions) => {\n // No selected values\n if (!selectedValues.value || !(selectedValues.value as Array<string | number>)?.length) {\n return placeholder.value || null;\n }\n\n return items.value\n .reduce((acc, option) => {\n // Category items\n if (option.items) {\n const selectedCategoryOptions = option.items.filter(categoryOption =>\n (selectedValues.value as Array<string | number>).includes(categoryOption.value)\n );\n\n // If the category is fully selected add the category name\n const isCategoryFullySelected = selectedCategoryOptions.length === option.items.length;\n if (isCategoryFullySelected) {\n acc.push(option.label);\n } else {\n // If category is partially selected add each selected option and category\n selectedCategoryOptions.forEach(({ label }) => acc.push(label));\n }\n }\n\n // Non-category option\n if ((selectedValues.value as Array<string | number>).includes(option.value)) {\n acc.push(option.label);\n }\n\n return acc;\n }, [])\n .join(', ');\n};\n\n/**\n * Generates the `displayValue` for the Dropdown based on\n * the selection, the placeholder or it can be empty if there's nothing to show.\n *\n * When there is a selected value but the value is not present in the list, the\n * value is then returned as there is no way to know what the text/label is.\n *\n * @param options Options needed to calculate the display value based on the type of Dropdown (single, multi, category)\n * @returns The text to be displayed by the dropdown\n */\nexport const useDisplayValue: UseDisplayValue = ({ items, placeholder, value, multiple, staticCategories }) => {\n const isCategoryMultilevel = computed(() => items.value.find(option => option.items?.length));\n\n const displayValue = computed(() => {\n if (!multiple.value) {\n const result = singleSelect({\n items,\n placeholder,\n selectedValue: value,\n staticCategories: staticCategories.value,\n });\n return result;\n }\n\n // Category multi select\n if (isCategoryMultilevel.value) {\n return categoryMultiSelect({ selectedValues: value, placeholder, items });\n }\n\n // Multi select\n return multiSelect({ selectedValues: value, items, placeholder });\n });\n\n return displayValue;\n};\n","import { BentoKeyboardNavigationKeyDownEvent } from '@/types';\nimport { BentoListboxEvent } from '@/types/listbox';\nimport { computed, nextTick, Ref } from 'vue';\nimport {\n UseListboxKeyboardNavigationOptions,\n UseTextboxKeyboardNavigationOptions,\n} from './use-keyboard-navigation.types';\n\n/**\n * Returns the focus to the textbox of the dropdown if it exists\n * when the dropdown is being closed.\n * @param elementToFocusOn Reference to the input container\n */\nconst focusOnTextbox = (elementToFocusOn: Ref) => {\n elementToFocusOn.value.$children?.[0].$refs.textbox.focus();\n};\n\n/**\n * Controls the keyboard navigation inside the Dropdown's textbox for Single and Multi select.\n * Adds support for the keys:\n *\n * - Arrow up\n * - Arrow Down\n * - End key\n * - Home key\n * - Escape key\n * - Space key\n * - Enter Key\n *\n * @param options Options from the Dropdown to handle the navigation\n * @param toggleDropdown Function to open/close the Dropdown\n * @param openDropdown Function to open the Dropdown\n * @param closeDropdown Function to close the Dropdown\n * @returns List of event listeners available to the Dropdown's textbox\n */\nexport const useTextboxKeyboardNavigation = (\n {\n inputContainerRef,\n optionsContainerRef,\n selectedValueIndex,\n isDropdownOpen,\n isDynamicFltering,\n items,\n isMultiple,\n }: UseTextboxKeyboardNavigationOptions,\n toggleDropdown: () => void,\n openDropdown: () => void,\n closeDropdown: () => void\n) => {\n const onArrowDown = ({ detail: event }) => {\n event.preventDefault();\n if (!isDropdownOpen.value) {\n openDropdown();\n nextTick(() => {\n if (isMultiple) {\n optionsContainerRef.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children?.[0].$el.focus();\n } else {\n optionsContainerRef.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children?.[\n selectedValueIndex.value\n ].$el.focus();\n }\n });\n }\n };\n const onArrowUp = ({ detail: event }) => {\n event.preventDefault();\n if (!isDropdownOpen.value) {\n openDropdown();\n nextTick(() => {\n optionsContainerRef.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children?.[0].$el.focus();\n });\n }\n };\n\n const onEndKey = () => {\n if (!isDropdownOpen.value) {\n openDropdown();\n nextTick(() => {\n if (isMultiple) {\n const firstLayer =\n optionsContainerRef.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children;\n optionsContainerRef.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children?.[\n firstLayer.length - 1\n ].$children[items.length - 1].$el.focus();\n } else {\n optionsContainerRef.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children?.[\n items.length - 1\n ].$el.focus();\n }\n });\n }\n };\n\n const onEscapeKey = () => {\n if (isDropdownOpen.value) {\n closeDropdown();\n focusOnTextbox(inputContainerRef);\n }\n };\n\n const onHomeKey = () => {\n if (!isDropdownOpen.value) {\n openDropdown();\n }\n nextTick(() => {\n optionsContainerRef.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children?.[0].$el.focus();\n });\n };\n\n const onSpaceKey = ({ detail: event }) => {\n event.preventDefault();\n toggleDropdown();\n if (isDropdownOpen.value) {\n nextTick(() => {\n if (isMultiple) {\n optionsContainerRef.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children?.[0].$el.focus();\n } else {\n optionsContainerRef.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children?.[\n selectedValueIndex.value\n ].$el.focus();\n }\n });\n }\n };\n\n const onEnterKey = () => {\n toggleDropdown();\n if (isDropdownOpen.value) {\n nextTick(() => {\n if (isMultiple) {\n optionsContainerRef.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children?.[0].$el.focus();\n } else {\n optionsContainerRef.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children?.[\n selectedValueIndex.value\n ].$el.focus();\n }\n });\n }\n };\n\n const textboxKeyboardNavigationListeners = computed(() => ({\n ...(!isDynamicFltering.value ? { [BentoKeyboardNavigationKeyDownEvent.SPACE]: onSpaceKey } : {}),\n [BentoKeyboardNavigationKeyDownEvent.ENTER]: onEnterKey,\n [BentoKeyboardNavigationKeyDownEvent.ARROW_DOWN]: onArrowDown,\n [BentoKeyboardNavigationKeyDownEvent.ARROW_UP]: onArrowUp,\n [BentoKeyboardNavigationKeyDownEvent.END]: onEndKey,\n [BentoKeyboardNavigationKeyDownEvent.ESCAPE]: onEscapeKey,\n [BentoKeyboardNavigationKeyDownEvent.HOME]: onHomeKey,\n }));\n\n return textboxKeyboardNavigationListeners;\n};\n\n/**\n * Controls the keyboard navigation inside the Dropdown's listbox container for Single and Multi select.\n * Adds support for the keys:\n *\n * - Escape key\n * - Enter Key\n * - Tab\n * - Space key\n *\n * @param options Options from the Dropdown to handle the navigation inside the listbox\n * @param closeDropdown Function to close the Dropdown\n * @returns List of event listeners available to the Dropdown's listbox container\n */\nexport const useListboxKeyboardNavigation = (\n { inputContainerRef, isDropdownOpen }: UseListboxKeyboardNavigationOptions,\n closeDropdown: () => void\n) => {\n const closeDropdownAndFocusOnTextbox = () => {\n if (isDropdownOpen.value) {\n closeDropdown();\n }\n nextTick(() => {\n focusOnTextbox(inputContainerRef);\n });\n };\n\n const listboxKeyboardNavigationListeners = {\n [BentoListboxEvent.ENTER]: closeDropdownAndFocusOnTextbox,\n [BentoListboxEvent.ESCAPE]: closeDropdownAndFocusOnTextbox,\n [BentoListboxEvent.TAB]: closeDropdownAndFocusOnTextbox,\n [BentoListboxEvent.SPACE]: closeDropdownAndFocusOnTextbox,\n };\n\n return listboxKeyboardNavigationListeners;\n};\n","import { computed, ref, Ref, watch } from 'vue';\nimport { BentoSearchBarItem } from './search-bar.types';\n\n/**\n * Filters an array {@see BentoSearchBarData} containing elements of type {@see BentoSearchBarItem}\n * by the {@param searchTerm}.\n *\n * @param {Ref<String>} searchTerm - Text that satisfies the search criteria.\n * @param {Ref<BentoSearchBarData>} data - Array to be filtered by {@param searchTerm}\n * @returns {Ref<BentoSearchBarData>} New instance of the array filtered by the {@param searchTerm} text\n */\nexport function useSearchBarFilter<T extends BentoSearchBarItem>(\n searchTerm: Ref<string>,\n data: Ref<T[]>,\n searchEvent?: (searchValue: string) => void\n) {\n const searchTermRef = ref(searchTerm);\n const dataRef = ref(data);\n\n const findHits = (searchTermLowerCased: string, options: Array<BentoSearchBarItem> = []) =>\n options.flatMap(option => {\n if (option.label.toLocaleLowerCase().includes(searchTermLowerCased)) {\n return [option, ...findHits(searchTermLowerCased, option.items)];\n }\n\n if (option.items) {\n return [...findHits(searchTermLowerCased, option.items)];\n }\n\n return [];\n });\n\n // If search event exists trigger it on the search term changing\n watch(searchTermRef, () => {\n if (searchEvent !== undefined) {\n searchEvent(searchTermRef.value);\n }\n });\n\n const filterInputData = computed(() => {\n if (!searchTermRef.value) {\n return dataRef.value;\n }\n // If search event exists, emit the new search value into the event and do not manipulate data.\n if (searchEvent !== undefined) {\n return dataRef.value;\n }\n\n const searchTermLowerCased = searchTermRef.value.toLocaleLowerCase();\n const filtered = findHits(searchTermLowerCased, dataRef.value);\n return filtered;\n });\n\n return filterInputData;\n}\n","export const INPUT_FIELD_COMPONENT_INJECTION_KEY = Symbol('input field component injection key');\n","<!-- TODO: Remove aria props as these are part of JSX elements /vue/types/jsx.d.ts -->\n<!-- eslint-disable vue/attribute-hyphenation -->\n<template>\n <div v-bento-click-outside-directive=\"clickOutsideDropdown\" class=\"b-dropdown\" :class=\"conditionalClasses\">\n <field-label\n v-if=\"label\"\n :id=\"labelId\"\n :condensed=\"condensed\"\n :label=\"label\"\n :tooltip-text=\"tooltipText\"\n :optional=\"optional\"\n :required=\"required\"\n />\n <div\n ref=\"inputContainerRefWrapper\"\n v-bento-keyboard-navigation-directive\n v-on=\"textboxKeyboardNavigationListeners\"\n >\n <component\n :is=\"size\"\n ref=\"inputContainerRef\"\n :condensed=\"condensed\"\n :value=\"searchTerm\"\n :additional-items-selected=\"additionalItemsSelected\"\n :ariaControls=\"dropdownOptionsContainerId\"\n :ariaExpanded=\"isDropdownOpen\"\n :aria-labelledby=\"label ? labelId : null\"\n :aria-describedby=\"ariaDescribedBy\"\n :aria-label=\"computedAriaLabel\"\n :aria-readonly=\"isReadOnly\"\n :readonly=\"isReadOnly\"\n :disabled=\"disabled\"\n :display-value=\"displayValue\"\n :dynamic-filtering=\"dynamicFiltering\"\n :is-invalid=\"!!errorMessage || error\"\n :multiple=\"multiple\"\n :open=\"isDropdownOpen\"\n :selected-value-item=\"!isInputComponent ? selectedValueItem : undefined\"\n :show-slot-content-in-multiple=\"showSlotContentInMultiple\"\n @input=\"searchTerm = $event\"\n @open=\"toggleDropdown\"\n @close=\"toggleDropdown\"\n >\n <template v-for=\"(_, innerSlot) of slots\" #[innerSlot]=\"scope\">\n <slot :name=\"innerSlot\" v-bind=\"scope\" />\n </template>\n </component>\n </div>\n <bento-dropdown-options-container\n v-if=\"inputContainerRef\"\n :id=\"dropdownOptionsContainerId\"\n ref=\"optionsContainerRef\"\n :aria-label=\"computedAriaLabel\"\n :empty-state=\"emptyState\"\n :debounce-time=\"search?.debounceTime\"\n :disabled=\"disabled\"\n :input-size=\"size\"\n :is-option-disabled=\"isOptionDisabled\"\n :items=\"filteredItems\"\n :multiple=\"multiple\"\n :static-categories=\"staticCategories\"\n :open=\"isDropdownOpen\"\n :selected-value=\"value\"\n :searching=\"isSearching\"\n :target-element=\"inputContainerRefWrapper\"\n :loading=\"loading\"\n :has-more-items=\"hasMoreItems\"\n :lazy-load-type=\"lazyLoadType\"\n :virtual-scroll=\"virtualScroll\"\n v-on=\"listboxListeners\"\n >\n <template v-for=\"(_, innerSlot) of slots\" #[innerSlot]=\"scope\">\n <slot :name=\"innerSlot\" v-bind=\"scope\" />\n </template>\n </bento-dropdown-options-container>\n <error-message\n v-if=\"!!errorMessage\"\n :id=\"errorId\"\n :error-message=\"errorMessage\"\n class=\"b-dropdown__error-message\"\n />\n <bento-typography\n v-if=\"description || hasSlot('description')\"\n :id=\"descriptionId\"\n class=\"b-dropdown__description\"\n :class=\"descriptionConditionalClasses\"\n el=\"span\"\n >\n <slot name=\"description\">\n {{ description }}\n </slot>\n </bento-typography>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, defineComponent, inject, PropType, Ref, ref, toRef, toRefs, useAttrs, useSlots } from 'vue';\n\n // Components\n import { BentoDropdownOptionsContainer } from './components/dropdown-options-container';\n import { BentoTypography } from '@/components/typography';\n import { DropdownInputDefault, DropdownInputSmall } from './components';\n import { BentoListbox, ErrorMessage, FieldLabel, useMultiLevelItems } from '@/internal';\n\n // Utils\n import { deprecate } from '@/utils/ts/deprecate';\n import { generateUid } from '@/utils/ts/unique-id';\n import { useAriaLabel } from '@/utils/ts/aria-label';\n import { useI18n } from '@/utils/ts/i18n';\n\n // Composables\n import { useDisplayValue, useListboxKeyboardNavigation, useTextboxKeyboardNavigation } from './composables';\n import { useFormLayoutFieldLoading } from '@/composables/use-form-layout-loading/use-form-layout-loading';\n import { useSearchBarFilter } from '@/components/search-bar/useSearchBarDataFilter';\n\n // Directives\n import { BentoClickOutsideDirective as vBentoClickOutsideDirective } from '@/directives/click-outside';\n import { BentoKeyboardNavigationDirective as vBentoKeyboardNavigationDirective } from '@/directives';\n\n // Types\n import {\n BentoDropdownEmptyStateProps,\n BentoDropdownEvent,\n BentoDropdownLazyLoadType,\n BentoDropdownSearchOptions,\n BentoDropdownSize,\n BentoDropdownVirtulisationOptions,\n } from './dropdown.types';\n import {\n BentoListboxEvent,\n BentoListboxIsOptionDisabled,\n BentoListboxMultiSelectValue,\n BentoListboxOptions,\n BentoListboxSelectedValue,\n } from '@/types';\n\n import messages from './messages.json';\n import { useHasSlot } from '@/composables';\n import { INPUT_FIELD_COMPONENT_INJECTION_KEY } from '@/components/input-field/input-field.keys';\n\n type MessageSchema = (typeof messages)['en-US'];\n\n const attrs = useAttrs();\n const slots = useSlots();\n const hasSlot = useHasSlot(slots);\n const props = defineProps({\n /**\n * @deprecated from version 2.0.0. Use the aria-label attribute instead.\n */\n /**\n * Defines a string value that labels an interactive element.\n */\n ariaLabel: { type: String, default: null },\n\n /**\n * Renders the dropdown with a condensed style.\n */\n condensed: { type: Boolean, default: false },\n\n /**\n * Empty state props used with the inner empty state component which is displayed when no search results are found.\n */\n emptyState: {\n type: Object as PropType<BentoDropdownEmptyStateProps>,\n default: undefined,\n },\n\n /**\n * Disables dropdown functionality.\n */\n disabled: { type: Boolean, default: false },\n\n /**\n * Sets the possibility to type into the textbox.\n */\n dynamicFiltering: {\n type: Boolean,\n default: false,\n },\n\n /**\n * Highlights the dropdown in an erroneous state.\n *\n * @deprecated Use \"errorMessage\" prop instead\n */\n error: { type: Boolean, default: false },\n\n /**\n * Highlights the dropdown in an erroneous state with an error message.\n */\n errorMessage: { type: String, default: null },\n\n /**\n * Descriptive supporting text visbile underneath the dropdown.\n */\n description: { type: String, default: null },\n\n /**\n * Indicates whether there are more items to load\n */\n hasMoreItems: { type: Boolean, default: false },\n\n /**\n * Function that dertermines which options are disabled from interaction.\n *\n * @type {BentoListboxIsOptionDisabled}\n * @param {BentoListboxOptionItem} option - Dropdown option object\n * @param {string} option.label - Option's label text\n * @param {string|number} option.value - Option's value\n * @param {unknown} option.data - Option's extra data to be passed to the default slot\n */\n isOptionDisabled: {\n type: Function as PropType<BentoListboxIsOptionDisabled>,\n default: undefined,\n },\n\n /**\n * The option elements to populate the dropdown with.\n * It must be an array of {@see BentoListboxOptionItem }\n * * @property {string} value.label - Text to be displayed in the option\n * * @property {string,number} value.value - Value of the option\n */\n items: {\n type: Array as PropType<BentoListboxOptions>,\n default: () => [],\n },\n\n /**\n * Text that is displayed as a label above the element.\n */\n label: { type: String, default: null },\n\n /**\n * Indicates if new options are loading.\n */\n loading: { type: Boolean, default: false },\n\n /**\n * The type of `Lazy Load`.\n * Type \"automatic\" will enable infinite scrolling\n * Type \"button\" will enable lazy loading with \"Show more\" button\n */\n lazyLoadType: {\n type: String as PropType<BentoDropdownLazyLoadType | `${BentoDropdownLazyLoadType}`>,\n default: BentoListbox.props.lazyLoadType.default,\n validator: (value: BentoDropdownLazyLoadType) => Object.values(BentoDropdownLazyLoadType).includes(value),\n },\n\n /*\n * If enabled, the user will be able to select multiple items.\n */\n multiple: { type: Boolean, default: false },\n\n /**\n * Highlights the dropdown is optional.\n */\n optional: { type: Boolean, default: false },\n\n /**\n * Text that appears in the form control when it has no value set\n */\n placeholder: { type: String, default: null },\n\n /**\n * Sets the dropdown to readonly state\n */\n readonly: { type: Boolean, default: false },\n\n /**\n * Highlights the dropdown is required.\n */\n required: { type: Boolean, default: false },\n\n /**\n * Dropdown search options and events.\n * @see BentoDropdownSearchOptions\n */\n search: {\n type: Object as PropType<BentoDropdownSearchOptions>,\n default: undefined,\n },\n\n /**\n * Toggles whether to use the slot content select items shown in the textbox in multiple mode.\n */\n showSlotContentInMultiple: { type: Boolean, default: false },\n\n /**\n * @deprecated Do not use. Only 'default' size should be used.\n */\n size: {\n type: String as PropType<BentoDropdownSize | `${BentoDropdownSize}`>,\n default: null,\n validator: (value: BentoDropdownSize) => Object.values(BentoDropdownSize).includes(value),\n },\n\n /**\n * If enabled, dropdown will display non-selectable, static categories\n */\n staticCategories: { type: Boolean, default: false },\n\n /**\n * Adds a info icon next to the label to display the passed tooltip message.\n */\n tooltipText: { type: String, default: null },\n\n /**\n * The `input` value.\n * Providing an empty string will select no options.\n * Set to an empty string `''` if you don't want any of the available options to be selected.\n */\n value: {\n type: [String, Number, Array] as PropType<BentoListboxSelectedValue>,\n default: null,\n },\n\n /**\n * Enables virtual scrolling if set to true or by providing an object with itemHeight function.\n * The itemHeight function is used to calculate the height of rendered item given it's index.\n */\n virtualScroll: {\n type: [Boolean, Object] as PropType<BentoDropdownVirtulisationOptions>,\n default: false,\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an option is clicked. Updates the selected option from the \"value\" property linked to the v-model.\n */\n (e: 'input', selectedValue: BentoListboxSelectedValue);\n\n /**\n * Emitted when:\n * - `lazyLoad` is `automatic` and the scroll meets the end of the list\n * - `lazyload` is `button` and the button is clicked\n */\n (e: 'show-more');\n }>();\n\n const { t } = useI18n<{ message: MessageSchema }>({ messages });\n\n const inputContainerRef = ref(null);\n const inputContainerRefWrapper = ref(null);\n const optionsContainerRef: Ref<InstanceType<typeof BentoDropdownOptionsContainer>> = ref(null);\n const isDropdownOpen = ref(false);\n const dropdownOptionsContainerId = generateUid('bento-dropdown-options-container');\n const labelId = generateUid('dropdown-label');\n const descriptionId = generateUid('dropdown-description');\n const errorId = generateUid('dropdown-error');\n\n const { isReadOnly } = useFormLayoutFieldLoading(toRef(props, 'readonly'));\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: t('ariaLabelFallback'),\n });\n\n // Inject input field component key to change the dropdown size\n const isInputComponent =\n props.size === BentoDropdownSize.SMALL || inject(INPUT_FIELD_COMPONENT_INJECTION_KEY, false);\n const size = computed(() => (isInputComponent ? BentoDropdownSize.SMALL : BentoDropdownSize.DEFAULT));\n\n const conditionalClasses = computed(() => ({\n 'b-dropdown--condensed': props.condensed,\n }));\n\n // Description styles\n const descriptionConditionalClasses = computed(() => ({\n 'b-dropdown__description--error': !!props.errorMessage,\n }));\n\n // Filtering\n const searchTerm = ref('');\n const items = toRef(props, 'items');\n const filteredItems = useSearchBarFilter(searchTerm, items, props?.search?.searchEvent);\n const isSearching = computed(() => props.dynamicFiltering && !!searchTerm.value);\n\n const displayValue = useDisplayValue({\n items,\n staticCategories: toRef(props, 'staticCategories'),\n multiple: toRef(props, 'multiple'),\n placeholder: toRef(props, 'placeholder'),\n value: toRef(props, 'value'),\n });\n\n const selectedValueItem = computed(() => {\n if (props?.multiple) {\n return props.items.filter(\n ({ value }) => props?.value && (props?.value as BentoListboxMultiSelectValue).includes(value)\n );\n }\n if (!props.multiple && props.staticCategories) {\n // Find the category that holds the selected value\n const category = props.items.find(categoryItem =>\n categoryItem.items.some(item => item.value === props.value)\n );\n // Find the specific item within the category\n const selectedCategoryItem = category ? category.items.find(item => item.value === props.value) : null;\n\n return selectedCategoryItem;\n }\n\n return props.items.find(({ value }) => value === props?.value);\n });\n\n const selectedValueIndex = computed(() => {\n const index = props.items.findIndex(({ value }) => props.value === value);\n return index > 0 ? index : 0;\n });\n\n const { isMultiLevelSelect, flattenedItemsList } = useMultiLevelItems(items);\n\n const additionalItemsSelected = computed(() => {\n if (props.multiple) {\n const selectedItems = (props?.value as BentoListboxMultiSelectValue)?.length;\n const total = isMultiLevelSelect.value ? flattenedItemsList.value.length : items.value.length;\n return total === selectedItems ? t('all') : selectedItems;\n }\n\n return null;\n });\n\n // ARIA\n const ariaDescribedBy = computed(\n () => `${props.description ? descriptionId : ''} ${props.errorMessage ? errorId : ''}`.trim() || null\n );\n\n const openDropdown = () => {\n if (isReadOnly.value) {\n return;\n }\n isDropdownOpen.value = true;\n };\n\n const closeDropdown = () => {\n isDropdownOpen.value = false;\n };\n\n const toggleDropdown = () => {\n if (isReadOnly.value) {\n return;\n }\n isDropdownOpen.value = !isDropdownOpen.value;\n\n // Clear search\n if (isSearching.value) {\n searchTerm.value = '';\n }\n };\n\n const clickOutsideDropdown = () => {\n if (isSearching.value) {\n searchTerm.value = '';\n }\n\n if (isDropdownOpen.value) {\n isDropdownOpen.value = false;\n // Reset the internal dropdown options state\n optionsContainerRef.value.onOutsideDropdownClick();\n }\n };\n\n const onOptionSelected = (selectedValue: BentoListboxSelectedValue) => {\n // Clear and close the dropdown on single selection\n if (!props.multiple) {\n searchTerm.value = '';\n isDropdownOpen.value = false;\n }\n\n emit('input', selectedValue);\n };\n\n const emitShowMoreEvent = () => {\n emit(BentoDropdownEvent.SHOW_MORE);\n };\n\n const textboxKeyboardNavigationListeners = useTextboxKeyboardNavigation(\n {\n inputContainerRef,\n optionsContainerRef,\n selectedValueIndex,\n isDropdownOpen,\n isDynamicFltering: toRef(props, 'dynamicFiltering'),\n items: props.items,\n isMultiple: props.multiple,\n },\n toggleDropdown,\n openDropdown,\n closeDropdown\n );\n\n const listboxKeyboardNavigationListeners = useListboxKeyboardNavigation(\n {\n inputContainerRef,\n isDropdownOpen,\n },\n closeDropdown\n );\n\n const listboxListeners = {\n [BentoListboxEvent.CLOSE_DROPDOWN]: closeDropdown,\n [BentoListboxEvent.SELECT]: onOptionSelected,\n [BentoListboxEvent.SHOW_MORE]: emitShowMoreEvent,\n ...listboxKeyboardNavigationListeners,\n };\n\n if (props.error) {\n deprecate(\n 'BentoDropdown \"error\" property',\n `Use the BentoDropdown \"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 (props.size) {\n deprecate('BentoDropdown \"size\" property', `Do not use. Only 'default' size should be used.`, '2.0.0');\n }\n</script>\n\n<script lang=\"ts\">\n /**\n * A Dropdown shows a selected option's.\n * Use a dropdown when you want users to select options\n * from a list of pre-defined options.\n *\n * @example\n * import { BentoDropdown } from '@adyen/bento-vue2';\n * import type { BentoDropdownOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdown },\n * template: `\n * <bento-dropdown\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :multiple=\"true\"\n * :isOptionsDisabled=\"option => option.value === 2\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref(2) // Default value\n * const options: BentoDropdownOptions = [\n * { label: 'Option 1', value: 1 },\n * { label: 'Option 2', value: 2 },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n i18n: { messages },\n name: 'b-dropdown',\n components: {\n DropdownInputDefault,\n DropdownInputSmall,\n },\n });\n</script>\n\n<style lang=\"scss\" scoped src=\"./dropdown.scss\" />\n"],"names":["BentoDropdownSize","BentoDropdownSize2","useDropdownOptionsListbox","selectedValue","multiple","isOpen","emit","internalSelectedValue","ref","t","useI18n","messages$1","watch","isApplyButtonDisabled","computed","onApplyClick","BentoListboxEvent","onCancelClick","onOutsideDropdownClick","actions","onOptionSelected","newSelectedValue","onTabKey","onEnterKey","onSpaceKey","onEscapeKey","emitShowMoreEvent","listeners","__default__$2","defineComponent","slots","useSlots","toRefs","props","dropdownOptionsListboxRef","isDropdownOpen","noResultsMessage","conditionalClasses","conditionalListboxClasses","popperContainerOrPopoverComponent","BentoPopover","PopperContainer","popperContainerOrPopoverProps","containerMinAndMaxWidth","_a","generateUid","expose","uuid$1","openBlock","createElementBlock","mergeProps","_ctx","_hoisted_1$2","toDisplayString","uuid","_hoisted_1$1","__default__$1","DropdownBaseTextboxState","openDropdown","closeDropdown","DropdownBaseTextboxEvent","singleSelect","items","placeholder","staticCategories","selectedItem","category","cat","item","value","multiSelect","selectedValues","categoryMultiSelect","acc","option","selectedCategoryOptions","categoryOption","label","useDisplayValue","isCategoryMultilevel","focusOnTextbox","elementToFocusOn","useTextboxKeyboardNavigation","inputContainerRef","optionsContainerRef","selectedValueIndex","isDynamicFltering","isMultiple","toggleDropdown","onArrowDown","event","nextTick","_b","onArrowUp","onEndKey","firstLayer","onHomeKey","BentoKeyboardNavigationKeyDownEvent","useListboxKeyboardNavigation","closeDropdownAndFocusOnTextbox","useSearchBarFilter","searchTerm","data","searchEvent","searchTermRef","dataRef","findHits","searchTermLowerCased","options","INPUT_FIELD_COMPONENT_INJECTION_KEY","__default__","messages","DropdownInputDefault","DropdownInputSmall","attrs","useAttrs","hasSlot","useHasSlot","inputContainerRefWrapper","dropdownOptionsContainerId","labelId","descriptionId","errorId","isReadOnly","useFormLayoutFieldLoading","toRef","ariaLabelAttribute","ariaLabel","computedAriaLabel","useAriaLabel","isInputComponent","inject","size","descriptionConditionalClasses","filteredItems","isSearching","displayValue","selectedValueItem","categoryItem","index","isMultiLevelSelect","flattenedItemsList","useMultiLevelItems","additionalItemsSelected","selectedItems","ariaDescribedBy","clickOutsideDropdown","textboxKeyboardNavigationListeners","listboxKeyboardNavigationListeners","listboxListeners","deprecate"],"mappings":";;;;;;;;;;;;;;;AAGY,IAAAA,IAAA,kBAAAC,OACRA,EAAA,UAAA,wBACAA,EAAA,QAAA,sBAFQA,IAAAD,KAAA,CAAA,CAAA;;;;;;;GCeLE,KAAA,CAAAC,GAAAC,GAAAC,GAAAC,MAAA;AAMH,QAAAC,IAAAC,EAAAL,EAAA,KAAA,GACA,EAAA,GAAAM,EAAA,IAAAC,GAAA,EAAA,UAAAC,GAAA,CAAA;AAEA,EAAAC,GAAAT,G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;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;","x_google_ignoreList":[3,4]}
|
|
@@ -1,101 +0,0 @@
|
|
|
1
|
-
import { ref as d, computed as i, defineComponent as u, toRefs as p, resolveComponent as _, openBlock as s, createElementBlock as n, normalizeClass as m, createVNode as v, withCtx as g, createTextVNode as f, toDisplayString as y } from "vue";
|
|
2
|
-
import { B as L } from "./index.99c63a74.js";
|
|
3
|
-
import { _ as b } from "./_plugin-vue_export-helper.dad06003.js";
|
|
4
|
-
import "../assets/index10.css";
|
|
5
|
-
const h = (e) => {
|
|
6
|
-
const a = d(e);
|
|
7
|
-
return i(() => a.value ? a.value.trim().charAt(0).toUpperCase() : null);
|
|
8
|
-
};
|
|
9
|
-
var t = /* @__PURE__ */ ((e) => (e.LARGE = "large", e.SMALL = "small", e))(t || {}), r = /* @__PURE__ */ ((e) => (e.BLUE = "blue", e.GREEN = "green", e.RED = "red", e.YELLOW = "yellow", e))(r || {});
|
|
10
|
-
const E = u({
|
|
11
|
-
name: "avatar-image",
|
|
12
|
-
components: { BentoTypography: L },
|
|
13
|
-
props: {
|
|
14
|
-
/**
|
|
15
|
-
* Image src to load the profile picture.
|
|
16
|
-
*/
|
|
17
|
-
src: {
|
|
18
|
-
type: String,
|
|
19
|
-
default: null
|
|
20
|
-
},
|
|
21
|
-
/**
|
|
22
|
-
* Name of the user that will be used to extract initials to display default value.
|
|
23
|
-
* John => J
|
|
24
|
-
* John Smith => JS
|
|
25
|
-
* John Smith Doe => JD
|
|
26
|
-
* John Smith Doe Holly => JH
|
|
27
|
-
*/
|
|
28
|
-
username: {
|
|
29
|
-
type: String,
|
|
30
|
-
default: null
|
|
31
|
-
},
|
|
32
|
-
/**
|
|
33
|
-
* Variants supported for small and large.
|
|
34
|
-
* Default - large
|
|
35
|
-
*/
|
|
36
|
-
variant: {
|
|
37
|
-
type: String,
|
|
38
|
-
default: t.LARGE,
|
|
39
|
-
validator: (e) => Object.values(t).includes(e)
|
|
40
|
-
},
|
|
41
|
-
/**
|
|
42
|
-
* Avatar color. Defaults to yellow.
|
|
43
|
-
*/
|
|
44
|
-
color: {
|
|
45
|
-
type: String,
|
|
46
|
-
default: r.YELLOW,
|
|
47
|
-
validator: (e) => Object.values(r).includes(e)
|
|
48
|
-
}
|
|
49
|
-
},
|
|
50
|
-
setup(e) {
|
|
51
|
-
const { username: a } = p(e), o = h(a);
|
|
52
|
-
return {
|
|
53
|
-
// Values
|
|
54
|
-
conditionalClasses: i(() => ({
|
|
55
|
-
[`b-avatar-image--${t.SMALL}`]: e.variant === t.SMALL,
|
|
56
|
-
[`b-avatar-image--${e.color}`]: e.color
|
|
57
|
-
})),
|
|
58
|
-
initials: o
|
|
59
|
-
};
|
|
60
|
-
}
|
|
61
|
-
});
|
|
62
|
-
const S = ["src"], $ = {
|
|
63
|
-
key: 1,
|
|
64
|
-
class: "b-avatar-image__default",
|
|
65
|
-
"data-testid": "avatar-content"
|
|
66
|
-
};
|
|
67
|
-
function C(e, a, o, c, R, k) {
|
|
68
|
-
const l = _("bento-typography");
|
|
69
|
-
return s(), n("div", {
|
|
70
|
-
class: m(["b-avatar-image", e.conditionalClasses]),
|
|
71
|
-
"aria-hidden": "true",
|
|
72
|
-
"data-testid": "avatar"
|
|
73
|
-
}, [
|
|
74
|
-
e.src ? (s(), n("img", {
|
|
75
|
-
key: 0,
|
|
76
|
-
src: e.src,
|
|
77
|
-
class: "b-avatar-image__image",
|
|
78
|
-
alt: "Profile picture",
|
|
79
|
-
"data-testid": "avatar-content"
|
|
80
|
-
}, null, 8, S)) : (s(), n("div", $, [
|
|
81
|
-
v(l, {
|
|
82
|
-
el: "span",
|
|
83
|
-
variant: "body",
|
|
84
|
-
strongest: ""
|
|
85
|
-
}, {
|
|
86
|
-
default: g(() => [
|
|
87
|
-
f(y(e.initials), 1)
|
|
88
|
-
]),
|
|
89
|
-
_: 1
|
|
90
|
-
})
|
|
91
|
-
]))
|
|
92
|
-
], 2);
|
|
93
|
-
}
|
|
94
|
-
const M = /* @__PURE__ */ b(E, [["render", C], ["__scopeId", "data-v-43c406e6"]]);
|
|
95
|
-
export {
|
|
96
|
-
M as A,
|
|
97
|
-
r as B,
|
|
98
|
-
t as a,
|
|
99
|
-
h as u
|
|
100
|
-
};
|
|
101
|
-
//# sourceMappingURL=index.0e01e0b2.js.map
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"index.0e01e0b2.js","sources":["../../../vue2/src/composables/initials.ts","../../../vue2/src/components/avatar-image/avatar-image.types.ts","../../../vue2/src/components/avatar-image/avatar-image.vue"],"sourcesContent":["import { computed, ComputedRef, ref } from 'vue';\nimport { MaybeRef } from '@/types';\n\n/** Extracts the first letter of a username\n * @param username - The name to return the initials of\n * Common patterns:\n * 1. John => J\n * 2. John Smith => J\n * John Smith Doe Holly => J\n */\nexport const useInitials = (username: MaybeRef<string | null>): ComputedRef<string | null> => {\n const computedUsername = ref(username);\n return computed(() => (computedUsername.value ? computedUsername.value.trim().charAt(0).toUpperCase() : null));\n};\n","export enum BentoAvatarImageVariant {\n LARGE = 'large',\n SMALL = 'small',\n}\n\nexport enum BentoAvatarImageColor {\n BLUE = 'blue',\n GREEN = 'green',\n RED = 'red',\n YELLOW = 'yellow',\n}\n","<template>\n <div class=\"b-avatar-image\" :class=\"conditionalClasses\" aria-hidden=\"true\" data-testid=\"avatar\">\n <img v-if=\"src\" :src=\"src\" class=\"b-avatar-image__image\" alt=\"Profile picture\" data-testid=\"avatar-content\" />\n <div v-else class=\"b-avatar-image__default\" data-testid=\"avatar-content\">\n <bento-typography el=\"span\" variant=\"body\" strongest>\n {{ initials }}\n </bento-typography>\n </div>\n </div>\n</template>\n\n<script lang=\"ts\">\n import { computed, defineComponent, PropType, toRefs } from 'vue';\n import { BentoAvatarImageColor, BentoAvatarImageVariant } from './avatar-image.types';\n import { BentoTypography } from '@/components/typography';\n import { useInitials } from '@/composables';\n\n export default defineComponent({\n name: 'avatar-image',\n components: { BentoTypography },\n props: {\n /**\n * Image src to load the profile picture.\n */\n src: {\n type: String,\n default: null,\n },\n /**\n * Name of the user that will be used to extract initials to display default value.\n * John => J\n * John Smith => JS\n * John Smith Doe => JD\n * John Smith Doe Holly => JH\n */\n username: {\n type: String,\n default: null,\n },\n /**\n * Variants supported for small and large.\n * Default - large\n */\n variant: {\n type: String as PropType<BentoAvatarImageVariant>,\n default: BentoAvatarImageVariant.LARGE,\n validator: (value: BentoAvatarImageVariant) => Object.values(BentoAvatarImageVariant).includes(value),\n },\n /**\n * Avatar color. Defaults to yellow.\n */\n color: {\n type: String as PropType<BentoAvatarImageColor>,\n default: BentoAvatarImageColor.YELLOW,\n validator: (value: BentoAvatarImageColor) => Object.values(BentoAvatarImageColor).includes(value),\n },\n },\n setup(props) {\n const { username } = toRefs(props);\n const initials = useInitials(username);\n\n const conditionalClasses = computed(() => ({\n [`b-avatar-image--${BentoAvatarImageVariant.SMALL}`]: props.variant === BentoAvatarImageVariant.SMALL,\n [`b-avatar-image--${props.color}`]: props.color,\n }));\n\n return {\n // Values\n conditionalClasses,\n initials,\n };\n },\n });\n</script>\n\n<style lang=\"scss\" scoped src=\"./avatar-image.scss\" />\n"],"names":["useInitials","username","computedUsername","ref","computed","BentoAvatarImageVariant","BentoAvatarImageVariant2","BentoAvatarImageColor","BentoAvatarImageColor2","_sfc_main","defineComponent","BentoTypography","value","props","toRefs","initials","openBlock","createElementBlock","normalizeClass","_ctx","_hoisted_1","_hoisted_2","createVNode","_component_bento_typography"],"mappings":";;;;AAUa,MAAAA,IAAA,CAAAC,MAAA;AACT,QAAAC,IAAAC,EAAAF,CAAA;AACA,SAAAG,EAAA,MAAAF,EAAA,QAAAA,EAAA,MAAA,KAAA,EAAA,OAAA,CAAA,EAAA,YAAA,IAAA,IAAA;AACJ;ACbY,IAAAG,IAAA,kBAAAC,OACRA,EAAA,QAAA,SACAA,EAAA,QAAA,SAFQA,IAAAD,KAAA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