@adyen/bento-vue3 2.1.0 → 2.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (66) hide show
  1. package/dist/assets/accordion-item.css +1 -1
  2. package/dist/assets/action-bar.css +1 -1
  3. package/dist/assets/base-modal.css +1 -1
  4. package/dist/assets/button-actions.css +1 -1
  5. package/dist/assets/card.css +1 -1
  6. package/dist/assets/data-grid.css +1 -1
  7. package/dist/assets/dialog-page.css +1 -1
  8. package/dist/assets/file-uploader.css +1 -1
  9. package/dist/assets/inspector.css +1 -1
  10. package/dist/assets/modal-fullscreen.css +1 -1
  11. package/dist/assets/navigation-menu-group.css +1 -1
  12. package/dist/assets/secondary-nav.css +1 -1
  13. package/dist/assets/sidepanel.css +1 -1
  14. package/dist/chunks/{calendar.EuBZ9HoM.js → calendar.0d9D-nmt.js} +2 -2
  15. package/dist/chunks/{calendar.EuBZ9HoM.js.map → calendar.0d9D-nmt.js.map} +1 -1
  16. package/dist/chunks/{code-snippet.DNDXr7t6.js → code-snippet.Ct8V995o.js} +2 -2
  17. package/dist/chunks/{code-snippet.DNDXr7t6.js.map → code-snippet.Ct8V995o.js.map} +1 -1
  18. package/dist/chunks/{data-grid.o5MQdWnJ.js → data-grid.1Inq7Qcv.js} +5 -5
  19. package/dist/chunks/{data-grid.o5MQdWnJ.js.map → data-grid.1Inq7Qcv.js.map} +1 -1
  20. package/dist/chunks/{date-picker.DyB8XkiY.js → date-picker.DwA7PxtZ.js} +8 -8
  21. package/dist/chunks/{date-picker.DyB8XkiY.js.map → date-picker.DwA7PxtZ.js.map} +1 -1
  22. package/dist/chunks/{date-range-picker.BcQUUVcW.js → date-range-picker.CpYS55md.js} +46 -46
  23. package/dist/chunks/{date-range-picker.BcQUUVcW.js.map → date-range-picker.CpYS55md.js.map} +1 -1
  24. package/dist/chunks/{dropdown-tag.BvXqllkv.js → dropdown-tag.BpJ_jwDg.js} +2 -2
  25. package/dist/chunks/{dropdown-tag.BvXqllkv.js.map → dropdown-tag.BpJ_jwDg.js.map} +1 -1
  26. package/dist/chunks/{dropdown.BoSI-Rre.js → dropdown.CpcbBlcE.js} +41 -41
  27. package/dist/chunks/{dropdown.BoSI-Rre.js.map → dropdown.CpcbBlcE.js.map} +1 -1
  28. package/dist/chunks/{filter-bar.6ElVHgFA.js → filter-bar.BR84cHEs.js} +8 -8
  29. package/dist/chunks/{filter-bar.6ElVHgFA.js.map → filter-bar.BR84cHEs.js.map} +1 -1
  30. package/dist/chunks/{header-with-views.Dl6bfk_7.js → header-with-views.BbRmt1H5.js} +3 -3
  31. package/dist/chunks/{header-with-views.Dl6bfk_7.js.map → header-with-views.BbRmt1H5.js.map} +1 -1
  32. package/dist/chunks/{input-field-password.BXptrVTT.js → input-field-password.DbeEL3hn.js} +2 -2
  33. package/dist/chunks/{input-field-password.BXptrVTT.js.map → input-field-password.DbeEL3hn.js.map} +1 -1
  34. package/dist/chunks/{input-field-phone-number.Crxi8Wm7.js → input-field-phone-number.COLI-j2g.js} +2 -2
  35. package/dist/chunks/{input-field-phone-number.Crxi8Wm7.js.map → input-field-phone-number.COLI-j2g.js.map} +1 -1
  36. package/dist/chunks/{input-field._keU91LW.js → input-field.CNYZ-qxB.js} +2 -2
  37. package/dist/chunks/{input-field._keU91LW.js.map → input-field.CNYZ-qxB.js.map} +1 -1
  38. package/dist/chunks/{input-time.D7UW_ww_.js → input-time.ClwtIJrn.js} +3 -3
  39. package/dist/chunks/{input-time.D7UW_ww_.js.map → input-time.ClwtIJrn.js.map} +1 -1
  40. package/dist/chunks/{pagination.C-kvJ-XK.js → pagination.Bx1uI60B.js} +2 -2
  41. package/dist/chunks/{pagination.C-kvJ-XK.js.map → pagination.Bx1uI60B.js.map} +1 -1
  42. package/dist/chunks/{search-bar.D1Jz7hdd.js → search-bar.ChSjMgxy.js} +3 -3
  43. package/dist/chunks/{search-bar.D1Jz7hdd.js.map → search-bar.ChSjMgxy.js.map} +1 -1
  44. package/dist/chunks/{secondary-nav.D32VFDTi.js → secondary-nav.CJ7ZpLYv.js} +2 -2
  45. package/dist/chunks/{secondary-nav.D32VFDTi.js.map → secondary-nav.CJ7ZpLYv.js.map} +1 -1
  46. package/dist/chunks/{use-date-input-formatter.BIVkaB1k.js → use-date-input-formatter.ByQ6j4AU.js} +2 -2
  47. package/dist/chunks/{use-date-input-formatter.BIVkaB1k.js.map → use-date-input-formatter.ByQ6j4AU.js.map} +1 -1
  48. package/dist/code-snippet.js +1 -1
  49. package/dist/data-grid.js +1 -1
  50. package/dist/date-picker.js +2 -2
  51. package/dist/date-range-picker.js +2 -2
  52. package/dist/date-time-picker.js +4 -4
  53. package/dist/dropdown.js +2 -2
  54. package/dist/filter-bar.js +1 -1
  55. package/dist/header-with-views.js +1 -1
  56. package/dist/index.js +16 -16
  57. package/dist/input-field-password.js +1 -1
  58. package/dist/input-field-phone-number.js +1 -1
  59. package/dist/input-field.js +1 -1
  60. package/dist/input-time.js +1 -1
  61. package/dist/internal.js +2 -2
  62. package/dist/pagination.js +1 -1
  63. package/dist/search-bar.js +2 -2
  64. package/dist/secondary-nav.js +1 -1
  65. package/dist/web-types.json +1 -1
  66. package/package.json +2 -2
@@ -1,6 +1,6 @@
1
1
  import { defineComponent as d, computed as P, openBlock as h, createElementBlock as O, normalizeProps as B, guardReactiveProps as M, createVNode as p, mergeProps as L, withCtx as y, unref as i, toRefs as C, createTextVNode as V, toDisplayString as g, ref as A, watch as R, createBlock as U, createElementVNode as T, createCommentVNode as F } from "vue";
2
2
  import { B as z } from "./avatar.Bes5Qw12.js";
3
- import { B as m, f as D } from "./dropdown.BoSI-Rre.js";
3
+ import { B as m, f as D } from "./dropdown.CpcbBlcE.js";
4
4
  import { u as _ } from "./form-field.B60VsF8d.js";
5
5
  import { B as j } from "./typography.B6elnWpr.js";
6
6
  import { u as q } from "./use-country-items.CAYJt6XS.js";
@@ -275,4 +275,4 @@ export {
275
275
  ue as c,
276
276
  de as d
277
277
  };
278
- //# sourceMappingURL=dropdown-tag.BvXqllkv.js.map
278
+ //# sourceMappingURL=dropdown-tag.BpJ_jwDg.js.map
@@ -1 +1 @@
1
- {"version":3,"file":"dropdown-tag.BvXqllkv.js","sources":["../../../vue2/src/components/dropdown/components/variants/dropdown-avatar/dropdown-avatar.vue","../../../vue2/src/components/dropdown/components/variants/dropdown-country/dropdown-country.vue","../../../vue2/src/components/dropdown/components/variants/dropdown-currency/dropdown-currency.vue","../../../vue2/src/components/dropdown/components/variants/dropdown-payment-method/dropdown-payment-method.vue","../../../vue2/src/components/dropdown/components/variants/dropdown-tag/dropdown-tag.vue"],"sourcesContent":["<template>\n <div v-bind=\"getNonAriaLabelAttributes($attrs)\">\n <bento-dropdown\n v-slot=\"{ label, data }\"\n v-bind=\"{ ...$props, ariaLabel: undefined }\"\n :aria-label=\"getAriaLabel($attrs)\"\n :items=\"dropdownItems\"\n @update:model-value=\"onUpdateModelValue\"\n @show-more=\"emit('show-more')\"\n @open=\"emit('open')\"\n >\n <bento-avatar :username=\"label\" :src=\"data\" />\n </bento-dropdown>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, defineComponent, type PropType } from 'vue';\n import { isVue2 } from 'vue-demi';\n import { type BentoListboxSelectedValue } from '@/types/listbox';\n import { type BentoAvatarListboxOptions } from './dropdown-avatar.types';\n import { BentoAvatar } from '@/components/avatar';\n import BentoDropdown from '@/components/dropdown/dropdown.vue';\n import { useFormFieldEmits } from '@/utils/ts/form-field/form-field';\n\n const props = defineProps({\n ...BentoDropdown.props,\n /**\n * @deprecated Since v3.0.0. Use `aria-label` instead.\n * Defines a string value that labels an interactive element.\n */\n ...(isVue2 ? { ariaLabel: { type: String, default: null } } : {}),\n /**\n * The option elements to populate the avatar dropdown with.\n * It must be an array of {@see BentoAvatarListboxOptions }\n * @property {string} value.label - Text to be displayed in the option.\n * @property {string | number} value.value - Value of the option.\n * @property {string} value.src - Image source of the avatar image.\n */\n items: {\n type: Array as PropType<BentoAvatarListboxOptions>,\n default: () => [],\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an option is clicked. Updates the selected option from the \"modelValue\" property linked to the v-model.\n */\n (e: 'update:model-value', 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 * Emitted when the dropdown is opened.\n */\n (e: 'open');\n }>();\n\n const { emitValue } = useFormFieldEmits<BentoListboxSelectedValue>(emit);\n\n const getAriaLabel = (attributes: Record<string, unknown>) =>\n Object.prototype.hasOwnProperty.call(attributes, 'aria-label')\n ? attributes['aria-label']\n : (attributes.ariaLabel ?? props.ariaLabel);\n const getNonAriaLabelAttributes = (attributes: Record<string, unknown>) =>\n Object.fromEntries(Object.entries(attributes).filter(([key]) => key !== 'aria-label' && key !== 'ariaLabel'));\n\n const onUpdateModelValue = (selectedValue: BentoListboxSelectedValue) => emitValue(selectedValue);\n\n const dropdownItems = computed(() => props.items.map(({ value, label, src }) => ({ value, label, data: src })));\n</script>\n\n<script lang=\"ts\">\n /**\n * A Avatar Dropdown showing a selectable list of countries.\n *\n * @example\n * import { BentoDropdownAvatar } from '@adyen/bento-vue2';\n * import type { BentoAvatarListboxOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdownAvatar },\n * template: `\n * <bento-dropdown-avatar\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :multiple=\"true\"\n * :isOptionsDisabled=\"option => option.value === 2\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref('user-id-1') // Default value\n * const options: BentoAvatarListboxOptions = [\n * { label: 'User 1', value: 'user-id-1' },\n * { label: 'User 2', value: 'user-id-2', src: 'image-source.jpeg' },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n name: 'bento-dropdown-avatar',\n inheritAttrs: false,\n model: { prop: 'modelValue', event: 'update:model-value' },\n });\n</script>\n","<template>\n <div v-bind=\"getNonAriaLabelAttributes($attrs)\">\n <bento-dropdown\n v-slot=\"{ label }\"\n v-bind=\"{ ...$props, ariaLabel: undefined }\"\n :aria-label=\"getAriaLabel($attrs)\"\n :items=\"countryItems\"\n @update:model-value=\"onUpdateModelValue\"\n @show-more=\"emit('show-more')\"\n @open=\"emit('open')\"\n >\n <bento-typography el=\"span\">{{ label }}</bento-typography>\n </bento-dropdown>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { defineComponent, type PropType, toRefs } from 'vue';\n import { isVue2 } from 'vue-demi';\n import { type BentoCountryListboxOptions } from './dropdown-country.types';\n import { type BentoListboxSelectedValue } from '@/types/listbox';\n import { BentoTypography } from '@/components/typography';\n import { useCountryItems } from './composables/use-country-items';\n import { useFormFieldEmits } from '@/utils/ts/form-field/form-field';\n import { BentoCountryVariant } from '@/components/country';\n import BentoDropdown from '@/components/dropdown/dropdown.vue';\n\n const props = defineProps({\n ...BentoDropdown.props,\n /**\n * @deprecated Since v3.0.0. Use `aria-label` instead.\n * Defines a string value that labels an interactive element.\n */\n ...(isVue2 ? { ariaLabel: { type: String, default: null } } : {}),\n /**\n * The option elements to populate the country dropdown with.\n * It must be an array of {@see BentoCountryListboxOptions }\n * @deprecated Since v3.0.0. Use `BentoDropdown` instead.\n * @property {BentoCountryCode | string} value.value - Country code of the option\n */\n items: {\n type: Array as PropType<BentoCountryListboxOptions>,\n default: () => [],\n },\n\n /**\n * Which label variant to display.\n * @values iso, name, phone_code, capital\n */\n variant: {\n type: String as PropType<BentoCountryVariant | `${BentoCountryVariant}`>,\n default: BentoCountryVariant.NAME,\n validator: (value: BentoCountryVariant) => Object.values(BentoCountryVariant).includes(value),\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an option is clicked. Updates the selected option from the \"modelValue\" property linked to the v-model.\n */\n (e: 'update:model-value', 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 * Emitted when the dropdown is opened.\n */\n (e: 'open');\n }>();\n\n const { emitValue } = useFormFieldEmits<BentoListboxSelectedValue>(emit);\n\n const getAriaLabel = (attributes: Record<string, unknown>) =>\n Object.prototype.hasOwnProperty.call(attributes, 'aria-label')\n ? attributes['aria-label']\n : (attributes.ariaLabel ?? props.ariaLabel);\n const getNonAriaLabelAttributes = (attributes: Record<string, unknown>) =>\n Object.fromEntries(Object.entries(attributes).filter(([key]) => key !== 'aria-label' && key !== 'ariaLabel'));\n\n const onUpdateModelValue = (selectedValue: BentoListboxSelectedValue) => emitValue(selectedValue);\n\n const { variant, items } = toRefs(props);\n const countryItems = useCountryItems(variant, items);\n</script>\n\n<script lang=\"ts\">\n /**\n * A Country Dropdown showing a selectable list of countries.\n *\n * @example\n * import { BentoDropdownCountry, BentoCountryCode } from '@adyen/bento-vue2';\n * import type { BentoCountryListboxOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdown },\n * template: `\n * <bento-dropdown-country\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :multiple=\"true\"\n * :isOptionsDisabled=\"option => option.value === 2\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref(BentoCountryCode.NL) // Default value\n * const options: BentoCountryListboxOptions = [\n * { value: BentoCountryCode.NL },\n * { value: BentoCountryCode.BE },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n name: 'b-dropdown-country',\n inheritAttrs: false,\n model: { prop: 'modelValue', event: 'update:model-value' },\n });\n</script>\n","<template>\n <bento-dropdown\n v-slot=\"slotProps\"\n v-bind=\"{ ...getNonAriaLabelAttributes($attrs), ...$props, ariaLabel: undefined }\"\n :aria-label=\"getAriaLabel($attrs)\"\n :search=\"search\"\n :items=\"filteredItems\"\n @update:model-value=\"onUpdateModelValue\"\n @show-more=\"emit('show-more')\"\n @open=\"emit('open')\"\n >\n <listbox-option-tag :option=\"slotProps\" />\n </bento-dropdown>\n</template>\n\n<script setup lang=\"ts\">\n import { defineComponent, type PropType, ref, watch } from 'vue';\n import { isVue2 } from 'vue-demi';\n import type { BentoCurrencyListboxOptions } from './dropdown-currency.types';\n import type { BentoListboxSelectedValue } from '@/types/listbox';\n import { ListboxOptionTag } from '@/internal/listbox/';\n import BentoDropdown from '@/components/dropdown/dropdown.vue';\n import { useSearchBarFilter } from '@/components/search-bar/useSearchBarDataFilter';\n import { useFormFieldEmits } from '@/utils/ts/form-field/form-field';\n\n const props = defineProps({\n ...BentoDropdown.props,\n /**\n * @deprecated Since v3.0.0. Use `aria-label` instead.\n * Defines a string value that labels an interactive element.\n */\n ...(isVue2 ? { ariaLabel: { type: String, default: null } } : {}),\n /**\n * The option elements to populate the currency dropdown with.\n * It must be an array of {@see BentoCurrencyListboxOptions }\n * @property {string} value.label - Text to be displayed in the option\n * @property {BentoCurrencyISOCode} value.code - Currency ISO code of the option\n */\n items: {\n type: Array as PropType<BentoCurrencyListboxOptions>,\n default: () => [],\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an option is clicked. Updates the selected option from the \"modelValue\" property linked to the v-model.\n */\n (e: 'update:model-value', 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 * Emitted when the dropdown is opened.\n */\n (e: 'open');\n }>();\n\n const { emitValue } = useFormFieldEmits<BentoListboxSelectedValue>(emit);\n\n const getAriaLabel = (attributes: Record<string, unknown>) =>\n Object.prototype.hasOwnProperty.call(attributes, 'aria-label')\n ? attributes['aria-label']\n : (attributes.ariaLabel ?? props.ariaLabel);\n const getNonAriaLabelAttributes = (attributes: Record<string, unknown>) =>\n Object.fromEntries(Object.entries(attributes).filter(([key]) => key !== 'aria-label' && key !== 'ariaLabel'));\n\n const onUpdateModelValue = (selectedValue: BentoListboxSelectedValue) => emitValue(selectedValue);\n\n const filteredItems = ref<BentoCurrencyListboxOptions>([]);\n\n watch(\n () => props.items,\n () => (filteredItems.value = props.items),\n { immediate: true }\n );\n\n const search = props.search\n ? props.search\n : {\n debounceTime: 500,\n searchEvent: async (searchTerm: string) => {\n // Combine value and label to be able to search by the currency code\n const searchableItems = props.items.map(item => ({\n ...item,\n label: `${item.value} ${item.label}`,\n }));\n\n const searchResults = useSearchBarFilter(\n ref(searchTerm),\n ref<BentoCurrencyListboxOptions>(searchableItems),\n props?.search?.searchEvent,\n ref(false)\n ).value;\n\n // Restore original labels by removing the prepended value\n const normalizedResults = searchResults?.map(result => ({\n ...result,\n label: result.label.substring(result.value.length + 1),\n }));\n\n filteredItems.value = normalizedResults;\n },\n };\n</script>\n\n<script lang=\"ts\">\n /**\n * A Currency Dropdown showing a selectable list of currencies.\n *\n * @example\n * import { BentoDropdownCountry, BentoCountryCode } from '@adyen/bento-vue2';\n * import type { BentoCountryListboxOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdown },\n * template: `\n * <bento-dropdown-currency\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :multiple=\"true\"\n * :isOptionsDisabled=\"option => option.value === 2\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref(BentoCountryCode.NL) // Default value\n * const options: BentoCountryListboxOptions = [\n * { label: 'Option 1', value: BentoCountryCode.NL },\n * { label: 'Option 2', value: BentoCountryCode.BE },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n name: 'b-dropdown-currency',\n inheritAttrs: false,\n model: { prop: 'modelValue', event: 'update:model-value' },\n });\n</script>\n","<template>\n <div v-bind=\"getNonAriaLabelAttributes($attrs)\">\n <bento-dropdown\n class=\"b-dropdown-payment-method\"\n v-bind=\"{ ...$props, ariaLabel: undefined }\"\n :aria-label=\"getAriaLabel($attrs)\"\n @update:model-value=\"onUpdateModelValue\"\n @show-more=\"emit('show-more')\"\n @open=\"emit('open')\"\n >\n <template #display-value=\"{ label, value }\">\n <bento-payment-method :type=\"value\" :label=\"label\" />\n </template>\n\n <template #default=\"{ value, label, description }\">\n <div class=\"b-dropdown-payment-method__item\">\n <bento-payment-method :type=\"value\" :label=\"description ? undefined : label\" />\n\n <div v-if=\"description\" class=\"b-dropdown-payment-method__text\">\n <bento-typography el=\"span\">{{ label }}</bento-typography>\n <bento-typography el=\"span\" class=\"b-dropdown-payment-method__description\">{{\n description\n }}</bento-typography>\n </div>\n </div>\n </template>\n </bento-dropdown>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { defineComponent, type PropType } from 'vue';\n import { isVue2 } from 'vue-demi';\n import { BentoPaymentMethod } from '@/components/payment-method';\n import { BentoTypography } from '@/components/typography';\n import BentoDropdown from '@/components/dropdown/dropdown.vue';\n import { type BentoPaymentMethodListboxOptions } from './dropdown-payment-method.types';\n import { type BentoListboxSelectedValue } from '@/types/listbox';\n import { useFormFieldEmits } from '@/utils/ts/form-field/form-field';\n\n const props = defineProps({\n ...BentoDropdown.props,\n /**\n * @deprecated Since v3.0.0. Use `aria-label` instead.\n * Defines a string value that labels an interactive element.\n */\n ...(isVue2 ? { ariaLabel: { type: String, default: null } } : {}),\n /**\n * The option elements to populate the payment method dropdown with.\n * It must be an array of {@see BentoPaymentMethodListboxOptions }\n * @property {string} value.label - Text to be displayed in the option\n * @property {string} value.value - Payment type code that translates to a payment icon name {@see https://adyen-ui-assets.netlify.app/?path=/story/packages-ui-assets-payment-method-icons--icons}\n */\n items: {\n type: Array as PropType<BentoPaymentMethodListboxOptions>,\n default: () => [],\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an option is clicked. Updates the selected option from the \"modelValue\" property linked to the v-model.\n */\n (e: 'update:model-value', 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 * Emitted when the dropdown is opened.\n */\n (e: 'open');\n }>();\n\n const { emitValue } = useFormFieldEmits<BentoListboxSelectedValue>(emit);\n\n const getAriaLabel = (attributes: Record<string, unknown>) =>\n Object.prototype.hasOwnProperty.call(attributes, 'aria-label')\n ? attributes['aria-label']\n : (attributes.ariaLabel ?? props.ariaLabel);\n const getNonAriaLabelAttributes = (attributes: Record<string, unknown>) =>\n Object.fromEntries(Object.entries(attributes).filter(([key]) => key !== 'aria-label' && key !== 'ariaLabel'));\n\n const onUpdateModelValue = (selectedValue: BentoListboxSelectedValue) => emitValue(selectedValue);\n</script>\n\n<script lang=\"ts\">\n /**\n * A Payment method Dropdown showing a selectable list of countries.\n *\n * @example\n * import { BentoDropdownPaymentMethod } from '@adyen/bento-vue2';\n * import type { BentoPaymentMethodListboxOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdownPaymentMethod },\n * template: `\n * <bento-dropdown-payment-method\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :multiple=\"true\"\n * :isOptionsDisabled=\"option => option.value === 'Visa'\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref('ideal') // Default value\n * const options: BentoPaymentMethodListboxOptions = [\n * { label: 'Option 1', value: 'ideal' },\n * { label: 'Option 2', value: 'visa' },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n name: 'bento-dropdown-payment-method',\n inheritAttrs: false,\n model: { prop: 'modelValue', event: 'update:model-value' },\n });\n</script>\n\n<style lang=\"scss\" scoped src=\"./dropdown-payment-method.scss\" />\n","<template>\n <bento-dropdown\n v-slot=\"{ label, data }\"\n v-bind=\"{ ...getNonAriaLabelAttributes($attrs), ...$props, ariaLabel: undefined }\"\n class=\"b-dropdown-tag\"\n :aria-label=\"getAriaLabel($attrs)\"\n :items=\"tagItems\"\n show-slot-content-in-multiple\n @update:model-value=\"onUpdateModelValue\"\n @show-more=\"emit('show-more')\"\n @open=\"emit('open')\"\n >\n <listbox-option-tag :option=\"{ value: label, data, label: '' }\" />\n </bento-dropdown>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, defineComponent, type PropType } from 'vue';\n import { isVue2 } from 'vue-demi';\n import type { BentoTagListboxOptions } from './dropdown-tag.types';\n import type { BentoListboxSelectedValue } from '@/types/listbox';\n import { ListboxOptionTag } from '../../../../internal';\n import BentoDropdown from '../../../dropdown.vue';\n import { useFormFieldEmits } from '@/utils/ts/form-field/form-field';\n\n const props = defineProps({\n ...BentoDropdown.props,\n /**\n * @deprecated Since v3.0.0. Use `aria-label` instead.\n * Defines a string value that labels an interactive element.\n */\n ...(isVue2 ? { ariaLabel: { type: String, default: null } } : {}),\n /**\n * The option elements to populate the tag dropdown with.\n * It must be an array of {@see BentoTagListboxOptions }\n * @property {string} value.label - Text to be displayed in the option\n * @property {string | number} value.value - Value of the option\n * @property {string} value.variant - The BentTag variant shown for the option.\n */\n items: {\n type: Array as PropType<BentoTagListboxOptions>,\n default: () => [],\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an option is clicked. Updates the selected option from the \"modelValue\" property linked to the v-model.\n */\n (e: 'update:model-value', 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 * Emitted when the dropdown is opened.\n */\n (e: 'open');\n }>();\n\n const { emitValue } = useFormFieldEmits<BentoListboxSelectedValue>(emit);\n\n const getAriaLabel = (attributes: Record<string, unknown>) =>\n Object.prototype.hasOwnProperty.call(attributes, 'aria-label')\n ? attributes['aria-label']\n : (attributes.ariaLabel ?? props.ariaLabel);\n const getNonAriaLabelAttributes = (attributes: Record<string, unknown>) =>\n Object.fromEntries(Object.entries(attributes).filter(([key]) => key !== 'aria-label' && key !== 'ariaLabel'));\n\n const onUpdateModelValue = (selectedValue: BentoListboxSelectedValue) => emitValue(selectedValue);\n\n const tagItems = computed(() => props.items?.map(({ label, value, variant }) => ({ label, value, data: variant })));\n</script>\n\n<script lang=\"ts\">\n /**\n * A Tag Dropdown showing a selectable list of tags.\n *\n * @example\n * import { BentoDropdownTag } from '@adyen/bento-vue2';\n * import type { BentoTagListboxOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdownTag },\n * template: `\n * <bento-dropdown-tag\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref('unique-id-1') // Default value\n * const options: BentoTagListboxOptions = [\n * { label: 'Offline', value: 'unique-id-1', variant: 'red' },\n * { label: 'Online', value: 'unique-id-2', variant: 'green' },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n name: 'bento-dropdown-tag',\n inheritAttrs: false,\n model: { prop: 'modelValue', event: 'update:model-value' },\n });\n</script>\n\n<style lang=\"scss\" scoped src=\"./dropdown-tag.scss\" />\n"],"names":["__default__$4","defineComponent","props","__props","emit","__emit","emitValue","useFormFieldEmits","getAriaLabel","attributes","getNonAriaLabelAttributes","key","onUpdateModelValue","selectedValue","dropdownItems","computed","value","label","src","__default__$3","variant","items","toRefs","countryItems","useCountryItems","__default__$2","filteredItems","ref","watch","search","searchTerm","searchableItems","item","normalizedResults","useSearchBarFilter","result","__default__$1","__default__","tagItems"],"mappings":";;;;;;;;;;;AA2GI,MAAAA,IAAAC,EAAA;AAAA,EAA+B,MAAA;AAAA,EACrB,cAAA;AAAA,EACQ,OAAA,EAAA,MAAA,cAAA,OAAA,qBAAA;AAElB,CAAA;;;;;;;;;;;;;;;;;;AAtFA,UAAAC,IAAAC,GAoBAC,IAAAC,GAmBA,EAAA,WAAAC,EAAA,IAAAC,EAAAH,CAAA,GAEAI,IAAA,CAAAC,MAAA,OAAA,UAAA,eAAA,KAAAA,GAAA,YAAA,IAAAA,EAAA,YAAA,IAAAA,EAAA,aAAAP,EAAA,WAIAQ,IAAA,CAAAD,MAAA,OAAA,YAAA,OAAA,QAAAA,CAAA,EAAA,OAAA,CAAA,CA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AA,IAAAA,EAAA,aAAAP,EAAA,WAIAQ,IAAA,CAAAD,MAAA,OAAA,YAAA,OAAA,QAAAA,CAAA,EAAA,OAAA,CAAA,CAAAE,CAAA,MAAAA,MAAA,gBAAAA,MAAA,WAAA,CAAA,GAGAC,IAAA,CAAAC,MAAAP,EAAAO,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;mECkBAwB,IAAApC,EAAA;AAAA,EAA+B,MAAA;AAAA,EACrB,cAAA;AAAA,EACQ,OAAA,EAAA,MAAA,cAAA,OAAA,qBAAA;AAElB,CAAA;;;;;;;;;;;;;;;;;;AApFA,UAAAC,IAAAC,GAoBAC,IAAAC,GAmBA,EAAA,WAAAC,EAAA,IAAAC,EAAAH,CAAA,GAEAI,IAAA,CAAAC,MAAA,OAAA,UAAA,eAAA,KAAAA,GAAA,YAAA,IAAAA,EAAA,YAAA,IAAAA,EAAA,aAAAP,EAAA,WAIAQ,IAAA,CAAAD,MAAA,OAAA,YAAA,OAAA,QAAAA,CAAA,EAAA,OAAA,CAAA,CAAAE,CAAA,MAAAA,MAAA,gBAAAA,MAAA,WAAA,CAAA,GAGAC,IAAA,CAAAC,MAAAP,EAAAO,CAAA,GAEAyB,IAAAvB,EAAA,MAAAb,EAAA,OAAA,IAAA,CAAA,EAAA,OAAAe,GAAA,OAAAD,GAAA,SAAAI,EAAA,OAAA,EAAA,OAAAH,GAAA,OAAAD,GAAA,MAAAI,EAAA,EAAA,CAAA;;;;;;;;;;;;;;;;;;;"}
1
+ {"version":3,"file":"dropdown-tag.BpJ_jwDg.js","sources":["../../../vue2/src/components/dropdown/components/variants/dropdown-avatar/dropdown-avatar.vue","../../../vue2/src/components/dropdown/components/variants/dropdown-country/dropdown-country.vue","../../../vue2/src/components/dropdown/components/variants/dropdown-currency/dropdown-currency.vue","../../../vue2/src/components/dropdown/components/variants/dropdown-payment-method/dropdown-payment-method.vue","../../../vue2/src/components/dropdown/components/variants/dropdown-tag/dropdown-tag.vue"],"sourcesContent":["<template>\n <div v-bind=\"getNonAriaLabelAttributes($attrs)\">\n <bento-dropdown\n v-slot=\"{ label, data }\"\n v-bind=\"{ ...$props, ariaLabel: undefined }\"\n :aria-label=\"getAriaLabel($attrs)\"\n :items=\"dropdownItems\"\n @update:model-value=\"onUpdateModelValue\"\n @show-more=\"emit('show-more')\"\n @open=\"emit('open')\"\n >\n <bento-avatar :username=\"label\" :src=\"data\" />\n </bento-dropdown>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, defineComponent, type PropType } from 'vue';\n import { isVue2 } from 'vue-demi';\n import { type BentoListboxSelectedValue } from '@/types/listbox';\n import { type BentoAvatarListboxOptions } from './dropdown-avatar.types';\n import { BentoAvatar } from '@/components/avatar';\n import BentoDropdown from '@/components/dropdown/dropdown.vue';\n import { useFormFieldEmits } from '@/utils/ts/form-field/form-field';\n\n const props = defineProps({\n ...BentoDropdown.props,\n /**\n * @deprecated Since v3.0.0. Use `aria-label` instead.\n * Defines a string value that labels an interactive element.\n */\n ...(isVue2 ? { ariaLabel: { type: String, default: null } } : {}),\n /**\n * The option elements to populate the avatar dropdown with.\n * It must be an array of {@see BentoAvatarListboxOptions }\n * @property {string} value.label - Text to be displayed in the option.\n * @property {string | number} value.value - Value of the option.\n * @property {string} value.src - Image source of the avatar image.\n */\n items: {\n type: Array as PropType<BentoAvatarListboxOptions>,\n default: () => [],\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an option is clicked. Updates the selected option from the \"modelValue\" property linked to the v-model.\n */\n (e: 'update:model-value', 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 * Emitted when the dropdown is opened.\n */\n (e: 'open');\n }>();\n\n const { emitValue } = useFormFieldEmits<BentoListboxSelectedValue>(emit);\n\n const getAriaLabel = (attributes: Record<string, unknown>) =>\n Object.prototype.hasOwnProperty.call(attributes, 'aria-label')\n ? attributes['aria-label']\n : (attributes.ariaLabel ?? props.ariaLabel);\n const getNonAriaLabelAttributes = (attributes: Record<string, unknown>) =>\n Object.fromEntries(Object.entries(attributes).filter(([key]) => key !== 'aria-label' && key !== 'ariaLabel'));\n\n const onUpdateModelValue = (selectedValue: BentoListboxSelectedValue) => emitValue(selectedValue);\n\n const dropdownItems = computed(() => props.items.map(({ value, label, src }) => ({ value, label, data: src })));\n</script>\n\n<script lang=\"ts\">\n /**\n * A Avatar Dropdown showing a selectable list of countries.\n *\n * @example\n * import { BentoDropdownAvatar } from '@adyen/bento-vue2';\n * import type { BentoAvatarListboxOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdownAvatar },\n * template: `\n * <bento-dropdown-avatar\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :multiple=\"true\"\n * :isOptionsDisabled=\"option => option.value === 2\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref('user-id-1') // Default value\n * const options: BentoAvatarListboxOptions = [\n * { label: 'User 1', value: 'user-id-1' },\n * { label: 'User 2', value: 'user-id-2', src: 'image-source.jpeg' },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n name: 'bento-dropdown-avatar',\n inheritAttrs: false,\n model: { prop: 'modelValue', event: 'update:model-value' },\n });\n</script>\n","<template>\n <div v-bind=\"getNonAriaLabelAttributes($attrs)\">\n <bento-dropdown\n v-slot=\"{ label }\"\n v-bind=\"{ ...$props, ariaLabel: undefined }\"\n :aria-label=\"getAriaLabel($attrs)\"\n :items=\"countryItems\"\n @update:model-value=\"onUpdateModelValue\"\n @show-more=\"emit('show-more')\"\n @open=\"emit('open')\"\n >\n <bento-typography el=\"span\">{{ label }}</bento-typography>\n </bento-dropdown>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { defineComponent, type PropType, toRefs } from 'vue';\n import { isVue2 } from 'vue-demi';\n import { type BentoCountryListboxOptions } from './dropdown-country.types';\n import { type BentoListboxSelectedValue } from '@/types/listbox';\n import { BentoTypography } from '@/components/typography';\n import { useCountryItems } from './composables/use-country-items';\n import { useFormFieldEmits } from '@/utils/ts/form-field/form-field';\n import { BentoCountryVariant } from '@/components/country';\n import BentoDropdown from '@/components/dropdown/dropdown.vue';\n\n const props = defineProps({\n ...BentoDropdown.props,\n /**\n * @deprecated Since v3.0.0. Use `aria-label` instead.\n * Defines a string value that labels an interactive element.\n */\n ...(isVue2 ? { ariaLabel: { type: String, default: null } } : {}),\n /**\n * The option elements to populate the country dropdown with.\n * It must be an array of {@see BentoCountryListboxOptions }\n * @deprecated Since v3.0.0. Use `BentoDropdown` instead.\n * @property {BentoCountryCode | string} value.value - Country code of the option\n */\n items: {\n type: Array as PropType<BentoCountryListboxOptions>,\n default: () => [],\n },\n\n /**\n * Which label variant to display.\n * @values iso, name, phone_code, capital\n */\n variant: {\n type: String as PropType<BentoCountryVariant | `${BentoCountryVariant}`>,\n default: BentoCountryVariant.NAME,\n validator: (value: BentoCountryVariant) => Object.values(BentoCountryVariant).includes(value),\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an option is clicked. Updates the selected option from the \"modelValue\" property linked to the v-model.\n */\n (e: 'update:model-value', 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 * Emitted when the dropdown is opened.\n */\n (e: 'open');\n }>();\n\n const { emitValue } = useFormFieldEmits<BentoListboxSelectedValue>(emit);\n\n const getAriaLabel = (attributes: Record<string, unknown>) =>\n Object.prototype.hasOwnProperty.call(attributes, 'aria-label')\n ? attributes['aria-label']\n : (attributes.ariaLabel ?? props.ariaLabel);\n const getNonAriaLabelAttributes = (attributes: Record<string, unknown>) =>\n Object.fromEntries(Object.entries(attributes).filter(([key]) => key !== 'aria-label' && key !== 'ariaLabel'));\n\n const onUpdateModelValue = (selectedValue: BentoListboxSelectedValue) => emitValue(selectedValue);\n\n const { variant, items } = toRefs(props);\n const countryItems = useCountryItems(variant, items);\n</script>\n\n<script lang=\"ts\">\n /**\n * A Country Dropdown showing a selectable list of countries.\n *\n * @example\n * import { BentoDropdownCountry, BentoCountryCode } from '@adyen/bento-vue2';\n * import type { BentoCountryListboxOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdown },\n * template: `\n * <bento-dropdown-country\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :multiple=\"true\"\n * :isOptionsDisabled=\"option => option.value === 2\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref(BentoCountryCode.NL) // Default value\n * const options: BentoCountryListboxOptions = [\n * { value: BentoCountryCode.NL },\n * { value: BentoCountryCode.BE },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n name: 'b-dropdown-country',\n inheritAttrs: false,\n model: { prop: 'modelValue', event: 'update:model-value' },\n });\n</script>\n","<template>\n <bento-dropdown\n v-slot=\"slotProps\"\n v-bind=\"{ ...getNonAriaLabelAttributes($attrs), ...$props, ariaLabel: undefined }\"\n :aria-label=\"getAriaLabel($attrs)\"\n :search=\"search\"\n :items=\"filteredItems\"\n @update:model-value=\"onUpdateModelValue\"\n @show-more=\"emit('show-more')\"\n @open=\"emit('open')\"\n >\n <listbox-option-tag :option=\"slotProps\" />\n </bento-dropdown>\n</template>\n\n<script setup lang=\"ts\">\n import { defineComponent, type PropType, ref, watch } from 'vue';\n import { isVue2 } from 'vue-demi';\n import type { BentoCurrencyListboxOptions } from './dropdown-currency.types';\n import type { BentoListboxSelectedValue } from '@/types/listbox';\n import { ListboxOptionTag } from '@/internal/listbox/';\n import BentoDropdown from '@/components/dropdown/dropdown.vue';\n import { useSearchBarFilter } from '@/components/search-bar/useSearchBarDataFilter';\n import { useFormFieldEmits } from '@/utils/ts/form-field/form-field';\n\n const props = defineProps({\n ...BentoDropdown.props,\n /**\n * @deprecated Since v3.0.0. Use `aria-label` instead.\n * Defines a string value that labels an interactive element.\n */\n ...(isVue2 ? { ariaLabel: { type: String, default: null } } : {}),\n /**\n * The option elements to populate the currency dropdown with.\n * It must be an array of {@see BentoCurrencyListboxOptions }\n * @property {string} value.label - Text to be displayed in the option\n * @property {BentoCurrencyISOCode} value.code - Currency ISO code of the option\n */\n items: {\n type: Array as PropType<BentoCurrencyListboxOptions>,\n default: () => [],\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an option is clicked. Updates the selected option from the \"modelValue\" property linked to the v-model.\n */\n (e: 'update:model-value', 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 * Emitted when the dropdown is opened.\n */\n (e: 'open');\n }>();\n\n const { emitValue } = useFormFieldEmits<BentoListboxSelectedValue>(emit);\n\n const getAriaLabel = (attributes: Record<string, unknown>) =>\n Object.prototype.hasOwnProperty.call(attributes, 'aria-label')\n ? attributes['aria-label']\n : (attributes.ariaLabel ?? props.ariaLabel);\n const getNonAriaLabelAttributes = (attributes: Record<string, unknown>) =>\n Object.fromEntries(Object.entries(attributes).filter(([key]) => key !== 'aria-label' && key !== 'ariaLabel'));\n\n const onUpdateModelValue = (selectedValue: BentoListboxSelectedValue) => emitValue(selectedValue);\n\n const filteredItems = ref<BentoCurrencyListboxOptions>([]);\n\n watch(\n () => props.items,\n () => (filteredItems.value = props.items),\n { immediate: true }\n );\n\n const search = props.search\n ? props.search\n : {\n debounceTime: 500,\n searchEvent: async (searchTerm: string) => {\n // Combine value and label to be able to search by the currency code\n const searchableItems = props.items.map(item => ({\n ...item,\n label: `${item.value} ${item.label}`,\n }));\n\n const searchResults = useSearchBarFilter(\n ref(searchTerm),\n ref<BentoCurrencyListboxOptions>(searchableItems),\n props?.search?.searchEvent,\n ref(false)\n ).value;\n\n // Restore original labels by removing the prepended value\n const normalizedResults = searchResults?.map(result => ({\n ...result,\n label: result.label.substring(result.value.length + 1),\n }));\n\n filteredItems.value = normalizedResults;\n },\n };\n</script>\n\n<script lang=\"ts\">\n /**\n * A Currency Dropdown showing a selectable list of currencies.\n *\n * @example\n * import { BentoDropdownCountry, BentoCountryCode } from '@adyen/bento-vue2';\n * import type { BentoCountryListboxOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdown },\n * template: `\n * <bento-dropdown-currency\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :multiple=\"true\"\n * :isOptionsDisabled=\"option => option.value === 2\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref(BentoCountryCode.NL) // Default value\n * const options: BentoCountryListboxOptions = [\n * { label: 'Option 1', value: BentoCountryCode.NL },\n * { label: 'Option 2', value: BentoCountryCode.BE },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n name: 'b-dropdown-currency',\n inheritAttrs: false,\n model: { prop: 'modelValue', event: 'update:model-value' },\n });\n</script>\n","<template>\n <div v-bind=\"getNonAriaLabelAttributes($attrs)\">\n <bento-dropdown\n class=\"b-dropdown-payment-method\"\n v-bind=\"{ ...$props, ariaLabel: undefined }\"\n :aria-label=\"getAriaLabel($attrs)\"\n @update:model-value=\"onUpdateModelValue\"\n @show-more=\"emit('show-more')\"\n @open=\"emit('open')\"\n >\n <template #display-value=\"{ label, value }\">\n <bento-payment-method :type=\"value\" :label=\"label\" />\n </template>\n\n <template #default=\"{ value, label, description }\">\n <div class=\"b-dropdown-payment-method__item\">\n <bento-payment-method :type=\"value\" :label=\"description ? undefined : label\" />\n\n <div v-if=\"description\" class=\"b-dropdown-payment-method__text\">\n <bento-typography el=\"span\">{{ label }}</bento-typography>\n <bento-typography el=\"span\" class=\"b-dropdown-payment-method__description\">{{\n description\n }}</bento-typography>\n </div>\n </div>\n </template>\n </bento-dropdown>\n </div>\n</template>\n\n<script setup lang=\"ts\">\n import { defineComponent, type PropType } from 'vue';\n import { isVue2 } from 'vue-demi';\n import { BentoPaymentMethod } from '@/components/payment-method';\n import { BentoTypography } from '@/components/typography';\n import BentoDropdown from '@/components/dropdown/dropdown.vue';\n import { type BentoPaymentMethodListboxOptions } from './dropdown-payment-method.types';\n import { type BentoListboxSelectedValue } from '@/types/listbox';\n import { useFormFieldEmits } from '@/utils/ts/form-field/form-field';\n\n const props = defineProps({\n ...BentoDropdown.props,\n /**\n * @deprecated Since v3.0.0. Use `aria-label` instead.\n * Defines a string value that labels an interactive element.\n */\n ...(isVue2 ? { ariaLabel: { type: String, default: null } } : {}),\n /**\n * The option elements to populate the payment method dropdown with.\n * It must be an array of {@see BentoPaymentMethodListboxOptions }\n * @property {string} value.label - Text to be displayed in the option\n * @property {string} value.value - Payment type code that translates to a payment icon name {@see https://adyen-ui-assets.netlify.app/?path=/story/packages-ui-assets-payment-method-icons--icons}\n */\n items: {\n type: Array as PropType<BentoPaymentMethodListboxOptions>,\n default: () => [],\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an option is clicked. Updates the selected option from the \"modelValue\" property linked to the v-model.\n */\n (e: 'update:model-value', 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 * Emitted when the dropdown is opened.\n */\n (e: 'open');\n }>();\n\n const { emitValue } = useFormFieldEmits<BentoListboxSelectedValue>(emit);\n\n const getAriaLabel = (attributes: Record<string, unknown>) =>\n Object.prototype.hasOwnProperty.call(attributes, 'aria-label')\n ? attributes['aria-label']\n : (attributes.ariaLabel ?? props.ariaLabel);\n const getNonAriaLabelAttributes = (attributes: Record<string, unknown>) =>\n Object.fromEntries(Object.entries(attributes).filter(([key]) => key !== 'aria-label' && key !== 'ariaLabel'));\n\n const onUpdateModelValue = (selectedValue: BentoListboxSelectedValue) => emitValue(selectedValue);\n</script>\n\n<script lang=\"ts\">\n /**\n * A Payment method Dropdown showing a selectable list of countries.\n *\n * @example\n * import { BentoDropdownPaymentMethod } from '@adyen/bento-vue2';\n * import type { BentoPaymentMethodListboxOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdownPaymentMethod },\n * template: `\n * <bento-dropdown-payment-method\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :multiple=\"true\"\n * :isOptionsDisabled=\"option => option.value === 'Visa'\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref('ideal') // Default value\n * const options: BentoPaymentMethodListboxOptions = [\n * { label: 'Option 1', value: 'ideal' },\n * { label: 'Option 2', value: 'visa' },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n name: 'bento-dropdown-payment-method',\n inheritAttrs: false,\n model: { prop: 'modelValue', event: 'update:model-value' },\n });\n</script>\n\n<style lang=\"scss\" scoped src=\"./dropdown-payment-method.scss\" />\n","<template>\n <bento-dropdown\n v-slot=\"{ label, data }\"\n v-bind=\"{ ...getNonAriaLabelAttributes($attrs), ...$props, ariaLabel: undefined }\"\n class=\"b-dropdown-tag\"\n :aria-label=\"getAriaLabel($attrs)\"\n :items=\"tagItems\"\n show-slot-content-in-multiple\n @update:model-value=\"onUpdateModelValue\"\n @show-more=\"emit('show-more')\"\n @open=\"emit('open')\"\n >\n <listbox-option-tag :option=\"{ value: label, data, label: '' }\" />\n </bento-dropdown>\n</template>\n\n<script setup lang=\"ts\">\n import { computed, defineComponent, type PropType } from 'vue';\n import { isVue2 } from 'vue-demi';\n import type { BentoTagListboxOptions } from './dropdown-tag.types';\n import type { BentoListboxSelectedValue } from '@/types/listbox';\n import { ListboxOptionTag } from '../../../../internal';\n import BentoDropdown from '../../../dropdown.vue';\n import { useFormFieldEmits } from '@/utils/ts/form-field/form-field';\n\n const props = defineProps({\n ...BentoDropdown.props,\n /**\n * @deprecated Since v3.0.0. Use `aria-label` instead.\n * Defines a string value that labels an interactive element.\n */\n ...(isVue2 ? { ariaLabel: { type: String, default: null } } : {}),\n /**\n * The option elements to populate the tag dropdown with.\n * It must be an array of {@see BentoTagListboxOptions }\n * @property {string} value.label - Text to be displayed in the option\n * @property {string | number} value.value - Value of the option\n * @property {string} value.variant - The BentTag variant shown for the option.\n */\n items: {\n type: Array as PropType<BentoTagListboxOptions>,\n default: () => [],\n },\n });\n\n const emit = defineEmits<{\n /**\n * Emitted when an option is clicked. Updates the selected option from the \"modelValue\" property linked to the v-model.\n */\n (e: 'update:model-value', 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 * Emitted when the dropdown is opened.\n */\n (e: 'open');\n }>();\n\n const { emitValue } = useFormFieldEmits<BentoListboxSelectedValue>(emit);\n\n const getAriaLabel = (attributes: Record<string, unknown>) =>\n Object.prototype.hasOwnProperty.call(attributes, 'aria-label')\n ? attributes['aria-label']\n : (attributes.ariaLabel ?? props.ariaLabel);\n const getNonAriaLabelAttributes = (attributes: Record<string, unknown>) =>\n Object.fromEntries(Object.entries(attributes).filter(([key]) => key !== 'aria-label' && key !== 'ariaLabel'));\n\n const onUpdateModelValue = (selectedValue: BentoListboxSelectedValue) => emitValue(selectedValue);\n\n const tagItems = computed(() => props.items?.map(({ label, value, variant }) => ({ label, value, data: variant })));\n</script>\n\n<script lang=\"ts\">\n /**\n * A Tag Dropdown showing a selectable list of tags.\n *\n * @example\n * import { BentoDropdownTag } from '@adyen/bento-vue2';\n * import type { BentoTagListboxOptions } from '@adyen/bento-vue2'\n *\n * export default {\n * components: { BentoDropdownTag },\n * template: `\n * <bento-dropdown-tag\n * v-model=\"selectedValue\"\n * :disabled=\"false\"\n * :items=\"options\"\n * />\n * `,\n * setup() {\n * const selectedValue = ref('unique-id-1') // Default value\n * const options: BentoTagListboxOptions = [\n * { label: 'Offline', value: 'unique-id-1', variant: 'red' },\n * { label: 'Online', value: 'unique-id-2', variant: 'green' },\n * ];\n * return { options, selectedValue };\n * }\n * }\n */\n export default defineComponent({\n name: 'bento-dropdown-tag',\n inheritAttrs: false,\n model: { prop: 'modelValue', event: 'update:model-value' },\n });\n</script>\n\n<style lang=\"scss\" scoped src=\"./dropdown-tag.scss\" />\n"],"names":["__default__$4","defineComponent","props","__props","emit","__emit","emitValue","useFormFieldEmits","getAriaLabel","attributes","getNonAriaLabelAttributes","key","onUpdateModelValue","selectedValue","dropdownItems","computed","value","label","src","__default__$3","variant","items","toRefs","countryItems","useCountryItems","__default__$2","filteredItems","ref","watch","search","searchTerm","searchableItems","item","normalizedResults","useSearchBarFilter","result","__default__$1","__default__","tagItems"],"mappings":";;;;;;;;;;;AA2GI,MAAAA,IAAAC,EAAA;AAAA,EAA+B,MAAA;AAAA,EACrB,cAAA;AAAA,EACQ,OAAA,EAAA,MAAA,cAAA,OAAA,qBAAA;AAElB,CAAA;;;;;;;;;;;;;;;;;;AAtFA,UAAAC,IAAAC,GAoBAC,IAAAC,GAmBA,EAAA,WAAAC,EAAA,IAAAC,EAAAH,CAAA,GAEAI,IAAA,CAAAC,MAAA,OAAA,UAAA,eAAA,KAAAA,GAAA,YAAA,IAAAA,EAAA,YAAA,IAAAA,EAAA,aAAAP,EAAA,WAIAQ,IAAA,CAAAD,MAAA,OAAA,YAAA,OAAA,QAAAA,CAAA,EAAA,OAAA,CAAA,CAAAE,CAAA,MAAAA,MAAA,gBAAAA,MAAA,WAAA,CAAA,GAGAC,IAAA,CAAAC,MAAAP,EAAAO,CAAA,GAEAC,IAAAC,EAAA,MAAAb,EAAA,MAAA,IAAA,CAAA,EAAA,OAAAc,GAAA,OAAAC,GAAA,KAAAC,EAAA,OAAA,EAAA,OAAAF,GAAA,OAAAC,GAAA,MAAAC,EAAA,EAAA,CAAA;;;;;;;;;;;;;;;;;;;IC4CAC,IAAAlB,EAAA;AAAA,EAA+B,MAAA;AAAA,EACrB,cAAA;AAAA,EACQ,OAAA,EAAA,MAAA,cAAA,O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;;;;;;;;;;;;;;;;;;AApFA,UAAAC,IAAAC,GAoBAC,IAAAC,GAmBA,EAAA,WAAAC,EAAA,IAAAC,EAAAH,CAAA,GAEAI,IAAA,CAAAC,MAAA,OAAA,UAAA,eAAA,KAAAA,GAAA,YAAA,IAAAA,EAAA,YAAA,IAAAA,EAAA,aAAAP,EAAA,WAIAQ,IAAA,CAAAD,MAAA,OAAA,YAAA,OAAA,QAAAA,CAAA,EAAA,OAAA,CAAA,CAAAE,CAAA,MAAAA,MAAA,gBAAAA,MAAA,WAAA,CAAA,GAGAC,IAAA,CAAAC,MAAAP,EAAAO,CAAA,GAEAyB,IAAAvB,EAAA,MAAAb,EAAA,OAAA,IAAA,CAAA,EAAA,OAAAe,GAAA,OAAAD,GAAA,SAAAI,EAAA,OAAA,EAAA,OAAAH,GAAA,OAAAD,GAAA,MAAAI,EAAA,EAAA,CAAA;;;;;;;;;;;;;;;;;;;"}
@@ -2,28 +2,28 @@ import { computed as r, ref as A, onMounted as Wt, onUnmounted as qt, watch as h
2
2
  import { B as Be } from "./typography.B6elnWpr.js";
3
3
  import { g as De } from "./generate-uid.DBWe4g6T.js";
4
4
  import { u as Re } from "./index.CGBfMQdv.js";
5
- import { s as Fe } from "./events.BQOQSSb7.js";
5
+ import { u as jt } from "./form-field.B60VsF8d.js";
6
+ import { u as Ht } from "./use-form-layout-loading.CWbjZiwP.js";
6
7
  import { u as Et } from "./use-has-slot.CyMiImRQ.js";
7
- import { _ as jt } from "./cross-circle-fill.DJbpTaVE.js";
8
- import { _ as Ht } from "./cross-circle-fill-small.C87G_8OX.js";
9
- import { _ as ue } from "./_plugin-vue_export-helper.CHgC5LLL.js";
10
- import { _ as Ot } from "./chevron-down.DDkuHzKj.js";
11
- import { _ as Tt } from "./chevron-up.CE9uVcoS.js";
12
- /* empty css */
13
- import { u as Jt } from "./form-field.B60VsF8d.js";
14
- import { u as Xt } from "./use-form-layout-loading.CWbjZiwP.js";
15
- import { B as Zt } from "./directive.D1-d-C2K.js";
8
+ import { B as Jt } from "./directive.D1-d-C2K.js";
16
9
  import { B as le, a as je } from "./keyboard-navigation.DWmhelVv.js";
17
- import { B as At } from "./loading-indicator.BPol9I84.js";
18
- import { B as wt } from "./empty-state.BuK12EGe.js";
19
- import { B as tt, _ as Qt } from "./minus-small.DBR64xRS.js";
20
- import { _ as el } from "./checkmark-small.DJcd8Sd7.js";
21
- import { B as tl } from "./chip.D4OozULC.js";
22
- import { b as lt, a as ll, h as al, e as ol } from "./button-actions.DvuGEQxM.js";
23
- import { o as sl } from "./resize.Bqks3WUm.js";
24
- import { F as nl } from "./field-label.vrUwhoOg.js";
10
+ import { B as Ot } from "./loading-indicator.BPol9I84.js";
11
+ import { B as Tt } from "./empty-state.BuK12EGe.js";
12
+ import { o as Xt } from "./resize.Bqks3WUm.js";
13
+ import { B as tt, _ as Zt } from "./minus-small.DBR64xRS.js";
14
+ import { _ as Qt } from "./checkmark-small.DJcd8Sd7.js";
15
+ /* empty css */
16
+ import { _ as ue } from "./_plugin-vue_export-helper.CHgC5LLL.js";
17
+ import { B as el } from "./chip.D4OozULC.js";
18
+ import { _ as At } from "./chevron-down.DDkuHzKj.js";
19
+ import { _ as wt } from "./chevron-up.CE9uVcoS.js";
20
+ import { b as lt, a as tl, h as ll, e as al } from "./button-actions.DvuGEQxM.js";
21
+ import { F as ol } from "./field-label.vrUwhoOg.js";
25
22
  import { P as ht } from "./popper-container.Rfj8UdMD.js";
26
- import { E as il } from "./error-message.DJ5l0EUH.js";
23
+ import { E as sl } from "./error-message.DJ5l0EUH.js";
24
+ import { s as Fe } from "./events.BQOQSSb7.js";
25
+ import { _ as nl } from "./cross-circle-fill.DJbpTaVE.js";
26
+ import { _ as il } from "./cross-circle-fill-small.C87G_8OX.js";
27
27
  import "../assets/dropdown.css";
28
28
  const _t = (e, a, o, l) => {
29
29
  const i = r(
@@ -81,7 +81,7 @@ function rl(e, { disabled: a, itemHeight: o, overscan: l = 5, prefixHeight: i })
81
81
  h();
82
82
  };
83
83
  a || (Wt(() => {
84
- s.value && (u.value = s.value.clientHeight, c = sl(s.value, ({ clientHeight: T }) => {
84
+ s.value && (u.value = s.value.clientHeight, c = Xt(s.value, ({ clientHeight: T }) => {
85
85
  u.value = T, h();
86
86
  }), h());
87
87
  }), qt(() => {
@@ -680,7 +680,7 @@ const El = /* @__PURE__ */ ue(Ll, [["render", Il]]), Ol = { key: 0 }, Tl = {
680
680
  class: we(["b-checkbox-input", o.value]),
681
681
  role: "presentation"
682
682
  }, [
683
- i.indeterminate ? (p(), F(v(Qt), {
683
+ i.indeterminate ? (p(), F(v(Zt), {
684
684
  key: 0,
685
685
  class: "b-checkbox-input__icon",
686
686
  "svg-title": "",
@@ -691,7 +691,7 @@ const El = /* @__PURE__ */ ue(Ll, [["render", Il]]), Ol = { key: 0 }, Tl = {
691
691
  "svg-title": "",
692
692
  "aria-hidden": "true",
693
693
  "data-testid": "decorative-checkbox-double-checkmark-icon"
694
- })) : i.checked ? (p(), F(v(el), {
694
+ })) : i.checked ? (p(), F(v(Qt), {
695
695
  key: 2,
696
696
  class: "b-checkbox-input__icon",
697
697
  "svg-title": "",
@@ -739,7 +739,7 @@ const Dt = {
739
739
  () => o.loading ? lt.LOADING : lt.START
740
740
  ), s = r(() => o.loading ? a("loading") : a("showMore"));
741
741
  return (n, t) => l.value || n.loading ? (p(), I("div", _l, [
742
- l.value ? (p(), F(v(ll), {
742
+ l.value ? (p(), F(v(tl), {
743
743
  key: 0,
744
744
  state: i.value,
745
745
  tabindex: n.tabindex,
@@ -751,7 +751,7 @@ const Dt = {
751
751
  ne(j(s.value), 1)
752
752
  ]),
753
753
  _: 1
754
- }, 8, ["state", "tabindex", "condensed"])) : n.loading ? (p(), F(v(At), { key: 1 })) : Y("", !0)
754
+ }, 8, ["state", "tabindex", "condensed"])) : n.loading ? (p(), F(v(Ot), { key: 1 })) : Y("", !0)
755
755
  ])) : Y("", !0);
756
756
  }
757
757
  }), Bt = /* @__PURE__ */ ue($l, [["__scopeId", "data-v-ae5fccad"]]), Rt = {
@@ -803,7 +803,7 @@ const Dt = {
803
803
  Se(Oe(n, ["prevent"]), ["space"])
804
804
  ]
805
805
  }, [
806
- l.value ? (p(), F(v(wt), {
806
+ l.value ? (p(), F(v(Tt), {
807
807
  key: 0,
808
808
  variant: "basic",
809
809
  class: "b-listbox-multi-select-nested-lazy-load__error-message"
@@ -842,8 +842,8 @@ const Dt = {
842
842
  BentoTypography: Be,
843
843
  BentoListboxOption: ot,
844
844
  BentoListboxMultiSelectNestedLazyLoad: Rl,
845
- ChevronDownIcon: Ot,
846
- ChevronUpIcon: Tt,
845
+ ChevronDownIcon: At,
846
+ ChevronUpIcon: wt,
847
847
  DecorativeCheckbox: yt
848
848
  },
849
849
  props: {
@@ -1490,7 +1490,7 @@ const Yl = /* @__PURE__ */ ue(Kl, [["render", ql], ["__scopeId", "data-v-dba55b0
1490
1490
  (p(!0), I(Ce, null, re(Te.value, (E) => (p(), I("li", {
1491
1491
  key: E.value
1492
1492
  }, [
1493
- q(v(tl), {
1493
+ q(v(el), {
1494
1494
  ref_for: !0,
1495
1495
  ref_key: "selectedListboxItemsRef",
1496
1496
  ref: b,
@@ -1577,11 +1577,11 @@ const Yl = /* @__PURE__ */ ue(Kl, [["render", ql], ["__scopeId", "data-v-dba55b0
1577
1577
  }, Ql = 36, ea = Q({
1578
1578
  name: "bento-listbox",
1579
1579
  components: {
1580
- BentoEmptyState: wt,
1580
+ BentoEmptyState: Tt,
1581
1581
  BentoListboxSingleSelect: El,
1582
1582
  BentoListboxMultiSelect: Ct,
1583
1583
  BentoTypography: Be,
1584
- BentoLoadingIndicator: At,
1584
+ BentoLoadingIndicator: Ot,
1585
1585
  BentoListboxLazyLoad: Bt
1586
1586
  },
1587
1587
  directives: { BentoKeyboardNavigationDirective: je },
@@ -2108,7 +2108,7 @@ const gt = {
2108
2108
  "b-dropdown-options-container--single": !s?.multiple
2109
2109
  })), S = r(() => ({
2110
2110
  "b-dropdown-options-container__listbox--single": !s?.multiple
2111
- })), { actions: h, internalSelectedValue: N, listeners: w, onEscapeKey: $, onOutsideDropdownClick: T } = ia(n, t, c, i), M = r(() => s?.multiple ? al : ht), _ = r(() => {
2111
+ })), { actions: h, internalSelectedValue: N, listeners: w, onEscapeKey: $, onOutsideDropdownClick: T } = ia(n, t, c, i), M = r(() => s?.multiple ? ll : ht), _ = r(() => {
2112
2112
  const L = {
2113
2113
  "min-width": `${s?.targetElement?.clientWidth}px`,
2114
2114
  "max-width": "min(500px, 95%)"
@@ -2472,10 +2472,10 @@ const ca = /* @__PURE__ */ Symbol("dropdown small size injection key"), Ft = /*
2472
2472
  onKeydown: Se(Oe(te, ["stop"]), ["enter"]),
2473
2473
  onKeyup: Se(te, ["space"])
2474
2474
  }, [
2475
- e.size === v(He).SMALL ? (p(), F(v(Ht), {
2475
+ e.size === v(He).SMALL ? (p(), F(v(il), {
2476
2476
  key: 0,
2477
2477
  "svg-title": v(l)("clearSearch")
2478
- }, null, 8, ["svg-title"])) : (p(), F(v(jt), {
2478
+ }, null, 8, ["svg-title"])) : (p(), F(v(nl), {
2479
2479
  key: 1,
2480
2480
  "svg-title": v(l)("clearSearch")
2481
2481
  }, null, 8, ["svg-title"]))
@@ -2624,10 +2624,10 @@ const ca = /* @__PURE__ */ Symbol("dropdown small size injection key"), Ft = /*
2624
2624
  }, fe(h)), Ee({
2625
2625
  icon: R(() => [
2626
2626
  Z("div", La, [
2627
- Le(q(v(Tt), { "svg-title": "opened" }, null, 512), [
2627
+ Le(q(v(wt), { "svg-title": "opened" }, null, 512), [
2628
2628
  [ze, f.value]
2629
2629
  ]),
2630
- Le(q(v(Ot), { "svg-title": "closed" }, null, 512), [
2630
+ Le(q(v(At), { "svg-title": "closed" }, null, 512), [
2631
2631
  [ze, !f.value]
2632
2632
  ])
2633
2633
  ])
@@ -2981,7 +2981,7 @@ const Kt = {
2981
2981
  },
2982
2982
  emits: ["update:model-value", "show-more", "open"],
2983
2983
  setup(e, { expose: a, emit: o }) {
2984
- const l = vt(), i = Ge(), s = (m) => Object.fromEntries(Object.entries(m).filter(([ye]) => !ye.startsWith("aria-"))), n = Et(i), t = e, f = o, { t: u } = Re({ messages: Kt }), { emitValue: c } = Jt(f), d = A(null), b = A(null), S = A(null), h = A(!1), N = A(!1), w = De("bento-dropdown-options-container"), $ = De("dropdown-label"), T = De("dropdown-description"), M = De("dropdown-error"), { isReadOnly: _ } = Xt(de(t, "readonly")), L = r(() => t.modelValue), { cachedSelectedListboxOptions: x, cachedListboxSelectedValues: D, setCachedValues: z } = na(
2984
+ const l = vt(), i = Ge(), s = (m) => Object.fromEntries(Object.entries(m).filter(([ye]) => !ye.startsWith("aria-"))), n = Et(i), t = e, f = o, { t: u } = Re({ messages: Kt }), { emitValue: c } = jt(f), d = A(null), b = A(null), S = A(null), h = A(!1), N = A(!1), w = De("bento-dropdown-options-container"), $ = De("dropdown-label"), T = De("dropdown-description"), M = De("dropdown-error"), { isReadOnly: _ } = Ht(de(t, "readonly")), L = r(() => t.modelValue), { cachedSelectedListboxOptions: x, cachedListboxSelectedValues: D, setCachedValues: z } = na(
2985
2985
  de(t, "items"),
2986
2986
  L,
2987
2987
  de(t, "multiple"),
@@ -3117,7 +3117,7 @@ const Kt = {
3117
3117
  }), (m, ye) => Le((p(), I("div", V(s(m.$attrs), {
3118
3118
  class: ["b-dropdown", W.value]
3119
3119
  }), [
3120
- m.label ? (p(), F(v(nl), {
3120
+ m.label ? (p(), F(v(ol), {
3121
3121
  key: 0,
3122
3122
  id: v($),
3123
3123
  condensed: m.condensed,
@@ -3176,7 +3176,7 @@ const Kt = {
3176
3176
  ], 16)), [
3177
3177
  [v(je)]
3178
3178
  ]),
3179
- d.value ? (p(), F(v(ol), {
3179
+ d.value ? (p(), F(v(al), {
3180
3180
  key: 1,
3181
3181
  disabled: m.teleport?.disabled,
3182
3182
  to: m.teleport?.to
@@ -3214,7 +3214,7 @@ const Kt = {
3214
3214
  ]),
3215
3215
  _: 3
3216
3216
  }, 8, ["disabled", "to"])) : Y("", !0),
3217
- m.errorMessage ? (p(), F(v(il), {
3217
+ m.errorMessage ? (p(), F(v(sl), {
3218
3218
  key: 2,
3219
3219
  id: v(M),
3220
3220
  "error-message": m.errorMessage,
@@ -3234,7 +3234,7 @@ const Kt = {
3234
3234
  _: 3
3235
3235
  }, 8, ["id", "class"])) : Y("", !0)
3236
3236
  ], 16)), [
3237
- [v(Zt), g.value]
3237
+ [v(Jt), g.value]
3238
3238
  ]);
3239
3239
  }
3240
3240
  }), fo = /* @__PURE__ */ ue(za, [["__scopeId", "data-v-1ca3a8a7"]]);
@@ -3254,4 +3254,4 @@ export {
3254
3254
  yt as j,
3255
3255
  na as u
3256
3256
  };
3257
- //# sourceMappingURL=dropdown.BoSI-Rre.js.map
3257
+ //# sourceMappingURL=dropdown.CpcbBlcE.js.map