@adyen/bento-vue3 1.43.0 → 1.44.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.
Files changed (213) hide show
  1. package/dist/@types/packages/vue2/src/components/button/components/button-actions/composables/use-stack-buttons/use-stack-buttons.d.ts +10 -0
  2. package/dist/@types/packages/vue2/src/components/card/card.vue.d.ts +1 -1
  3. package/dist/@types/packages/vue2/src/components/checkbox/checkbox.vue.d.ts +3 -3
  4. package/dist/@types/packages/vue2/src/components/checkbox/components/checkbox-group/checkbox-group.vue.d.ts +8 -8
  5. package/dist/@types/packages/vue2/src/components/code-snippet/code-snippet.vue.d.ts +50 -32
  6. package/dist/@types/packages/vue2/src/components/data-grid/components/data-grid-config-settings/data-grid-config-settings.vue.d.ts +3 -3
  7. package/dist/@types/packages/vue2/src/components/data-grid/data-grid.vue.d.ts +3 -3
  8. package/dist/@types/packages/vue2/src/components/date-picker/date-picker.vue.d.ts +21 -15
  9. package/dist/@types/packages/vue2/src/components/date-range-picker/components/date-range-picker-calendar/date-range-picker-calendar.vue.d.ts +56 -38
  10. package/dist/@types/packages/vue2/src/components/date-range-picker/date-range-picker.vue.d.ts +77 -53
  11. package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-base-textbox/dropdown-base-textbox.vue.d.ts +6 -4
  12. package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-default-textbox/dropdown-default-textbox.vue.d.ts +4 -2
  13. package/dist/@types/packages/vue2/src/components/dropdown/components/dropdown-small-textbox/dropdown-small-textbox.vue.d.ts +1 -1
  14. package/dist/@types/packages/vue2/src/components/dropdown/dropdown.vue.d.ts +20 -12
  15. package/dist/@types/packages/vue2/src/components/empty-state/empty-state.vue.d.ts +1 -1
  16. package/dist/@types/packages/vue2/src/components/file-uploader/file-uploader.types.d.ts +6 -2
  17. package/dist/@types/packages/vue2/src/components/filter-bar/components/all-filters-modal/all-filters-modal.vue.d.ts +228 -180
  18. package/dist/@types/packages/vue2/src/components/filter-bar/components/base-filter/base-filter.vue.d.ts +6 -6
  19. package/dist/@types/packages/vue2/src/components/filter-bar/components/boolean-filter/boolean-filter.vue.d.ts +12 -12
  20. package/dist/@types/packages/vue2/src/components/filter-bar/components/date-filter/date-filter.vue.d.ts +27 -21
  21. package/dist/@types/packages/vue2/src/components/filter-bar/components/date-range-filter/date-range-filter.vue.d.ts +139 -97
  22. package/dist/@types/packages/vue2/src/components/filter-bar/components/filter-bar-button/filter-bar-button.vue.d.ts +1 -1
  23. package/dist/@types/packages/vue2/src/components/filter-bar/components/input-filter/input-filter.vue.d.ts +15 -15
  24. package/dist/@types/packages/vue2/src/components/filter-bar/components/range-filter/range-filter.vue.d.ts +15 -15
  25. package/dist/@types/packages/vue2/src/components/filter-bar/filter-bar.vue.d.ts +208 -160
  26. package/dist/@types/packages/vue2/src/components/header/header.vue.d.ts +9 -0
  27. package/dist/@types/packages/vue2/src/components/input-field/input-field.vue.d.ts +3 -3
  28. package/dist/@types/packages/vue2/src/components/input-field-password/input-field-password.vue.d.ts +1 -1
  29. package/dist/@types/packages/vue2/src/components/internal/button-actions-with-menu/button-actions-with-menu.keys.d.ts +1 -0
  30. package/dist/@types/packages/vue2/src/components/internal/button-actions-with-menu/button-actions-with-menu.vue.d.ts +16 -1
  31. package/dist/@types/packages/vue2/src/components/internal/button-actions-with-menu/index.d.ts +2 -0
  32. package/dist/@types/packages/vue2/src/components/internal/checkbox-input/checkbox-input.vue.d.ts +1 -1
  33. package/dist/@types/packages/vue2/src/components/internal/controls-group/controls-group.vue.d.ts +1 -1
  34. package/dist/@types/packages/vue2/src/components/internal/field-label/field-label.vue.d.ts +1 -1
  35. package/dist/@types/packages/vue2/src/components/internal/index.d.ts +1 -0
  36. 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 +3 -3
  37. 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 +6 -6
  38. package/dist/@types/packages/vue2/src/components/internal/listbox/components/listbox-multi-select/listbox-multi-select.vue.d.ts +9 -9
  39. package/dist/@types/packages/vue2/src/components/internal/listbox/listbox.vue.d.ts +15 -15
  40. package/dist/@types/packages/vue2/src/components/internal/radio-input/radio-input.vue.d.ts +1 -1
  41. package/dist/@types/packages/vue2/src/components/internal/tooltip/tooltip.vue.d.ts +5 -5
  42. package/dist/@types/packages/vue2/src/components/menu/components/menu-item-list/menu-item-list.vue.d.ts +15 -0
  43. package/dist/@types/packages/vue2/src/components/menu/menu.vue.d.ts +48 -3
  44. package/dist/@types/packages/vue2/src/components/modal/components/base-modal/base-modal.vue.d.ts +1 -1
  45. package/dist/@types/packages/vue2/src/components/modal/components/modal-default/modal-default.vue.d.ts +1 -1
  46. package/dist/@types/packages/vue2/src/components/modal/components/modal-dialog/modal-dialog.vue.d.ts +1 -1
  47. package/dist/@types/packages/vue2/src/components/modal/components/modal-page/modal-page.vue.d.ts +1 -1
  48. package/dist/@types/packages/vue2/src/components/modal/modal.vue.d.ts +7 -7
  49. package/dist/@types/packages/vue2/src/components/modal-fullscreen/components/modal-fullscreen-page.vue.d.ts +1 -1
  50. package/dist/@types/packages/vue2/src/components/modal-fullscreen/modal-fullscreen.vue.d.ts +1 -1
  51. package/dist/@types/packages/vue2/src/components/popover/popover.vue.d.ts +1 -1
  52. package/dist/@types/packages/vue2/src/components/popper-container/popper-container.vue.d.ts +1 -1
  53. package/dist/@types/packages/vue2/src/components/promo-banner/promo-banner.vue.d.ts +2 -2
  54. package/dist/@types/packages/vue2/src/components/radio-group/radio-group.vue.d.ts +2 -2
  55. package/dist/@types/packages/vue2/src/components/selection-card/components/selection-card-group/selection-card-group.vue.d.ts +3 -3
  56. package/dist/@types/packages/vue2/src/components/sidepanel/components/sidepanel-page.vue.d.ts +1 -1
  57. package/dist/@types/packages/vue2/src/components/summary-grid/components/summary-grid-item/summary-grid-item.vue.d.ts +1 -1
  58. package/dist/@types/packages/vue2/src/components/summary-grid/components/summary-grid-item-amount/summary-grid-item-amount.vue.d.ts +2 -2
  59. package/dist/@types/packages/vue2/src/components/summary-grid/components/summary-grid-item-custom/summary-grid-item-custom.vue.d.ts +1 -1
  60. package/dist/@types/packages/vue2/src/components/summary-grid/components/summary-grid-item-numeric/summary-grid-item-numeric.vue.d.ts +1 -1
  61. package/dist/@types/packages/vue2/src/components/summary-grid/components/summary-grid-item-percentage/summary-grid-item-percentage.vue.d.ts +1 -1
  62. package/dist/@types/packages/vue2/src/components/summary-grid/components/summary-grid-item-text/summary-grid-item-text.vue.d.ts +1 -1
  63. package/dist/@types/packages/vue2/src/components/textarea/textarea.vue.d.ts +6 -4
  64. package/dist/@types/packages/vue2/src/components/timeline/timeline.vue.d.ts +6 -4
  65. package/dist/@types/packages/vue2/src/composables/use-form-validate/use-form.d.ts +9 -6
  66. package/dist/@types/packages/vue2/src/composables/use-form-validate/use-form.types.d.ts +5 -1
  67. package/dist/action-bar.js +1 -1
  68. package/dist/assets/accordion-item.css +1 -1
  69. package/dist/assets/action-bar.css +1 -1
  70. package/dist/assets/base-modal.css +1 -1
  71. package/dist/assets/button-actions-with-menu.css +1 -1
  72. package/dist/assets/button-actions.css +1 -1
  73. package/dist/assets/card.css +1 -1
  74. package/dist/assets/data-grid.css +1 -1
  75. package/dist/assets/dialog-page.css +1 -1
  76. package/dist/assets/dropdown-default-textbox.css +1 -1
  77. package/dist/assets/dropdown.css +1 -1
  78. package/dist/assets/file-uploader.css +1 -1
  79. package/dist/assets/header.css +1 -1
  80. package/dist/assets/inspector.css +1 -1
  81. package/dist/assets/menu.css +1 -1
  82. package/dist/assets/modal-fullscreen.css +1 -1
  83. package/dist/assets/popover.css +1 -1
  84. package/dist/assets/selection-card-group.css +1 -1
  85. package/dist/assets/sidepanel.css +1 -1
  86. package/dist/assets/textarea.css +1 -1
  87. package/dist/button.js +7 -8
  88. package/dist/button.js.map +1 -1
  89. package/dist/card.js +1 -1
  90. package/dist/checkbox.js +2 -2
  91. package/dist/chunks/{action-bar.COQrEUYU.js → action-bar.B-_JS43H.js} +10 -9
  92. package/dist/chunks/action-bar.B-_JS43H.js.map +1 -0
  93. package/dist/chunks/{base-modal.ku0lyHOs.js → base-modal.BR_pB6eH.js} +2 -2
  94. package/dist/chunks/{base-modal.ku0lyHOs.js.map → base-modal.BR_pB6eH.js.map} +1 -1
  95. package/dist/chunks/button-actions-with-menu.GT_kNv28.js +119 -0
  96. package/dist/chunks/button-actions-with-menu.GT_kNv28.js.map +1 -0
  97. package/dist/chunks/button-actions.BjlQS6tm.js +322 -0
  98. package/dist/chunks/button-actions.BjlQS6tm.js.map +1 -0
  99. package/dist/chunks/{card.D_XL2TWr.js → card.BrEfcUoE.js} +2 -2
  100. package/dist/chunks/{card.D_XL2TWr.js.map → card.BrEfcUoE.js.map} +1 -1
  101. package/dist/chunks/{checkbox-group.BUmkYc2R.js → checkbox-group.C5IweVVx.js} +2 -2
  102. package/dist/chunks/{checkbox-group.BUmkYc2R.js.map → checkbox-group.C5IweVVx.js.map} +1 -1
  103. package/dist/chunks/{checkbox.L94hTcPY.js → checkbox.B72ok3Yu.js} +15 -15
  104. package/dist/chunks/{checkbox.L94hTcPY.js.map → checkbox.B72ok3Yu.js.map} +1 -1
  105. package/dist/chunks/{code-snippet.DbUGxmYi.js → code-snippet.S5NdUu0p.js} +4 -4
  106. package/dist/chunks/{code-snippet.DbUGxmYi.js.map → code-snippet.S5NdUu0p.js.map} +1 -1
  107. package/dist/chunks/{dashboard-section.YU5gKDEJ.js → dashboard-section.LWxBcOV_.js} +2 -2
  108. package/dist/chunks/{dashboard-section.YU5gKDEJ.js.map → dashboard-section.LWxBcOV_.js.map} +1 -1
  109. package/dist/chunks/{dashed-underline.BKfUevuM.js → dashed-underline.CRlWNPrd.js} +2 -2
  110. package/dist/chunks/{dashed-underline.BKfUevuM.js.map → dashed-underline.CRlWNPrd.js.map} +1 -1
  111. package/dist/chunks/{data-grid-template.DI27ou71.js → data-grid-template.BZVeRN6g.js} +2 -2
  112. package/dist/chunks/{data-grid-template.DI27ou71.js.map → data-grid-template.BZVeRN6g.js.map} +1 -1
  113. package/dist/chunks/{data-grid.DgPWs1hH.js → data-grid.CKDW-rbM.js} +10 -10
  114. package/dist/chunks/{data-grid.DgPWs1hH.js.map → data-grid.CKDW-rbM.js.map} +1 -1
  115. package/dist/chunks/{date-picker.DDsfecHp.js → date-picker.BrZ2X1nQ.js} +3 -3
  116. package/dist/chunks/{date-picker.DDsfecHp.js.map → date-picker.BrZ2X1nQ.js.map} +1 -1
  117. package/dist/chunks/{date-range-picker.DjPmRy0E.js → date-range-picker.4y2goCI8.js} +6 -6
  118. package/dist/chunks/{date-range-picker.DjPmRy0E.js.map → date-range-picker.4y2goCI8.js.map} +1 -1
  119. package/dist/chunks/{dropdown-default-textbox.CcRQ1f4U.js → dropdown-default-textbox.ZjVeMHVC.js} +131 -120
  120. package/dist/chunks/{dropdown-default-textbox.CcRQ1f4U.js.map → dropdown-default-textbox.ZjVeMHVC.js.map} +1 -1
  121. package/dist/chunks/{dropdown-tag.BKDmDRSv.js → dropdown-tag.ClKm4xAo.js} +2 -2
  122. package/dist/chunks/{dropdown-tag.BKDmDRSv.js.map → dropdown-tag.ClKm4xAo.js.map} +1 -1
  123. package/dist/chunks/dropdown.Sj2OLuEF.js +911 -0
  124. package/dist/chunks/{dropdown.DpjMobyf.js.map → dropdown.Sj2OLuEF.js.map} +1 -1
  125. package/dist/chunks/es6.C-HLzYPA.js +11 -0
  126. package/dist/chunks/{es6.b4enG1py.js.map → es6.C-HLzYPA.js.map} +1 -1
  127. package/dist/chunks/{file-uploader.cRbwpcAw.js → file-uploader.BgRbkW2V.js} +368 -365
  128. package/dist/chunks/file-uploader.BgRbkW2V.js.map +1 -0
  129. package/dist/chunks/{filter-bar.BwJTrH5U.js → filter-bar.CM1FZ02d.js} +16 -17
  130. package/dist/chunks/{filter-bar.BwJTrH5U.js.map → filter-bar.CM1FZ02d.js.map} +1 -1
  131. package/dist/chunks/{footer-actions.DvIVWqWv.js → footer-actions.Dvsb0g5Y.js} +2 -2
  132. package/dist/chunks/{footer-actions.DvIVWqWv.js.map → footer-actions.Dvsb0g5Y.js.map} +1 -1
  133. package/dist/chunks/{header.C0NBlBJv.js → header.8BzBNgxj.js} +23 -23
  134. package/dist/chunks/{header.C0NBlBJv.js.map → header.8BzBNgxj.js.map} +1 -1
  135. package/dist/chunks/{input-field-password.DxNS4MmO.js → input-field-password.CXsERnQX.js} +3 -3
  136. package/dist/chunks/{input-field-password.DxNS4MmO.js.map → input-field-password.CXsERnQX.js.map} +1 -1
  137. package/dist/chunks/{input-field.BQKEQIZd.js → input-field.C-7_iMIS.js} +2 -2
  138. package/dist/chunks/{input-field.BQKEQIZd.js.map → input-field.C-7_iMIS.js.map} +1 -1
  139. package/dist/chunks/{menu.BpqOdkxR.js → menu.hDynz4lc.js} +132 -104
  140. package/dist/chunks/menu.hDynz4lc.js.map +1 -0
  141. package/dist/chunks/{modal-fullscreen.DtgTb1Xh.js → modal-fullscreen.BCGaxVNb.js} +2 -2
  142. package/dist/chunks/{modal-fullscreen.DtgTb1Xh.js.map → modal-fullscreen.BCGaxVNb.js.map} +1 -1
  143. package/dist/chunks/{modal.vue_vue_type_script_setup_true_lang.CjD91zJo.js → modal.vue_vue_type_script_setup_true_lang.DJXx8ftn.js} +4 -4
  144. package/dist/chunks/{modal.vue_vue_type_script_setup_true_lang.CjD91zJo.js.map → modal.vue_vue_type_script_setup_true_lang.DJXx8ftn.js.map} +1 -1
  145. package/dist/chunks/{pagination.C34l_EYf.js → pagination.C9kqX5tD.js} +2 -2
  146. package/dist/chunks/{pagination.C34l_EYf.js.map → pagination.C9kqX5tD.js.map} +1 -1
  147. package/dist/chunks/{popover.D9Zw4w9l.js → popover.DwGgnCyn.js} +2 -2
  148. package/dist/chunks/{popover.D9Zw4w9l.js.map → popover.DwGgnCyn.js.map} +1 -1
  149. package/dist/chunks/{search-bar.Dy0dBek2.js → search-bar.DPC0amNg.js} +3 -3
  150. package/dist/chunks/{search-bar.Dy0dBek2.js.map → search-bar.DPC0amNg.js.map} +1 -1
  151. package/dist/chunks/{secondary-nav.DYFnrUIK.js → secondary-nav.DH7aXddE.js} +3 -3
  152. package/dist/chunks/{secondary-nav.DYFnrUIK.js.map → secondary-nav.DH7aXddE.js.map} +1 -1
  153. package/dist/chunks/{selection-card-group.BY8o4PYF.js → selection-card-group.DDBJ423n.js} +19 -19
  154. package/dist/chunks/{selection-card-group.BY8o4PYF.js.map → selection-card-group.DDBJ423n.js.map} +1 -1
  155. package/dist/chunks/{sidepanel.BywianGe.js → sidepanel.8NclWh0V.js} +2 -2
  156. package/dist/chunks/{sidepanel.BywianGe.js.map → sidepanel.8NclWh0V.js.map} +1 -1
  157. package/dist/chunks/{teleport.CI0k6eaC.js → teleport.B255JhsV.js} +26 -17
  158. package/dist/chunks/teleport.B255JhsV.js.map +1 -0
  159. package/dist/chunks/{textarea.vAp6HFi9.js → textarea.D1weaQCC.js} +72 -68
  160. package/dist/chunks/{textarea.vAp6HFi9.js.map → textarea.D1weaQCC.js.map} +1 -1
  161. package/dist/chunks/{timeline-item.ND_EMuwP.js → timeline-item.BDYrjKhM.js} +3 -3
  162. package/dist/chunks/{timeline-item.ND_EMuwP.js.map → timeline-item.BDYrjKhM.js.map} +1 -1
  163. package/dist/chunks/{tutorial.vue_vue_type_script_setup_true_lang.LBw_ALfS.js → tutorial.vue_vue_type_script_setup_true_lang.ltZUbc6M.js} +4 -4
  164. package/dist/chunks/{tutorial.vue_vue_type_script_setup_true_lang.LBw_ALfS.js.map → tutorial.vue_vue_type_script_setup_true_lang.ltZUbc6M.js.map} +1 -1
  165. package/dist/chunks/{use-cached-selected-values.BOZK76mN.js → use-cached-selected-values.B6beyyvX.js} +3 -3
  166. package/dist/chunks/{use-cached-selected-values.BOZK76mN.js.map → use-cached-selected-values.B6beyyvX.js.map} +1 -1
  167. package/dist/code-snippet.js +1 -1
  168. package/dist/dashboard-template.js +1 -1
  169. package/dist/dashed-underline.js +1 -1
  170. package/dist/data-grid-template.js +1 -1
  171. package/dist/data-grid.js +1 -1
  172. package/dist/date-picker.js +1 -1
  173. package/dist/date-range-picker.js +1 -1
  174. package/dist/dropdown.js +4 -4
  175. package/dist/file-uploader.js +1 -1
  176. package/dist/filter-bar.js +1 -1
  177. package/dist/header.js +1 -1
  178. package/dist/index.js +67 -68
  179. package/dist/index.js.map +1 -1
  180. package/dist/input-field-password.js +1 -1
  181. package/dist/input-field.js +1 -1
  182. package/dist/internal.js +28 -24
  183. package/dist/internal.js.map +1 -1
  184. package/dist/menu.js +1 -1
  185. package/dist/modal-fullscreen.js +1 -1
  186. package/dist/modal.js +2 -2
  187. package/dist/pagination.js +1 -1
  188. package/dist/popover.js +1 -1
  189. package/dist/search-bar.js +2 -2
  190. package/dist/secondary-nav.js +1 -1
  191. package/dist/selection-card.js +1 -1
  192. package/dist/sidepanel.js +1 -1
  193. package/dist/textarea.js +1 -1
  194. package/dist/timeline.js +1 -1
  195. package/dist/tutorial.js +1 -1
  196. package/dist/web-types.json +1 -1
  197. package/package.json +2 -2
  198. package/dist/@types/packages/vue2/src/components/button/button.demo.d.ts +0 -6
  199. package/dist/assets/loading-button.css +0 -1
  200. package/dist/chunks/action-bar.COQrEUYU.js.map +0 -1
  201. package/dist/chunks/button-actions-with-menu.Bn7Kdx4v.js +0 -106
  202. package/dist/chunks/button-actions-with-menu.Bn7Kdx4v.js.map +0 -1
  203. package/dist/chunks/button-actions.Bjfo46Q_.js +0 -150
  204. package/dist/chunks/button-actions.Bjfo46Q_.js.map +0 -1
  205. package/dist/chunks/dropdown.DpjMobyf.js +0 -907
  206. package/dist/chunks/es6.b4enG1py.js +0 -10
  207. package/dist/chunks/file-uploader.cRbwpcAw.js.map +0 -1
  208. package/dist/chunks/loading-button.CNWhVIPK.js +0 -137
  209. package/dist/chunks/loading-button.CNWhVIPK.js.map +0 -1
  210. package/dist/chunks/menu.BpqOdkxR.js.map +0 -1
  211. package/dist/chunks/teleport.CI0k6eaC.js.map +0 -1
  212. package/dist/chunks/use-click-outside.D6aIgS15.js +0 -14
  213. package/dist/chunks/use-click-outside.D6aIgS15.js.map +0 -1
@@ -1,907 +0,0 @@
1
- import { ref as $, watch as Ee, computed as c, defineComponent as z, useSlots as Oe, toRefs as Ce, openBlock as L, createBlock as P, resolveDynamicComponent as Be, mergeProps as M, withCtx as F, createElementVNode as ee, withKeys as Ye, unref as o, createVNode as Z, toHandlers as X, createSlots as re, renderList as de, renderSlot as Q, normalizeProps as ue, guardReactiveProps as ce, createElementBlock as k, toDisplayString as ve, createCommentVNode as K, normalizeClass as fe, withDirectives as G, vShow as Le, nextTick as A, useAttrs as _e, toRef as C, inject as Ze, createTextVNode as Qe } from "vue";
2
- import { d as xe, B as Xe } from "./typography.DNzU41ah.js";
3
- import { a as ne, b as q, c as Ge, B as J, D as et } from "./dropdown-default-textbox.CcRQ1f4U.js";
4
- import { _ as Y } from "./_plugin-vue_export-helper.CHgC5LLL.js";
5
- import { s as ie } from "./events.FNmSWp_P.js";
6
- import { g as V } from "./generate-uid.D-HFI38h.js";
7
- import { u as tt } from "./aria-label.CaUURpnB.js";
8
- import { u as be } from "./i18n.CPGoe9tN.js";
9
- import { u as lt } from "./use-form-layout-loading.D3lALhtC.js";
10
- import { B as at } from "./directive.O3yEdalv.js";
11
- import { B as T, a as ot } from "./keyboard-navigation.C3QMVRKY.js";
12
- import { a as u, B as pe, b as me, c as st, u as nt } from "./use-cached-selected-values.BOZK76mN.js";
13
- import { u as it } from "./use-has-slot.B7eQSabc.js";
14
- import { F as rt, E as dt } from "./error-message.BYXS0kUN.js";
15
- import { P as Se } from "./popper-container.Cyf6zCPq.js";
16
- import "./popper-container.types.BCZMbVFD.js";
17
- import { B as ut } from "./popover.D9Zw4w9l.js";
18
- import "../assets/dropdown.css";
19
- const ye = {
20
- "en-US": {
21
- apply: "Apply",
22
- cancel: "Cancel",
23
- noOptionsMatchThisSearch: "No options match this search"
24
- },
25
- "pt-BR": {
26
- apply: "Aplicar",
27
- cancel: "Cancelar"
28
- },
29
- "ja-JP": {
30
- apply: "適用",
31
- cancel: "キャンセル"
32
- }
33
- }, ct = (t, a, s, l) => {
34
- const n = $(t.value), { t: e } = be({ messages: ye });
35
- Ee(t, () => {
36
- n.value = t.value;
37
- });
38
- const i = c(
39
- () => JSON.stringify(n.value) === JSON.stringify(t.value)
40
- ), m = () => {
41
- l(u.SELECT, n.value), l(u.CLOSE_DROPDOWN);
42
- }, r = () => {
43
- n.value = t.value, l(u.CLOSE_DROPDOWN);
44
- }, g = () => {
45
- s.value && a.value && (n.value = t.value);
46
- }, p = c(() => [
47
- {
48
- title: e("apply"),
49
- event: m,
50
- disabled: i.value
51
- },
52
- {
53
- title: e("cancel"),
54
- event: r
55
- }
56
- ]), d = (h) => {
57
- n.value = h, a.value || l(u.SELECT, h);
58
- }, f = (h) => {
59
- d(h), l(u.TAB);
60
- }, E = (h) => {
61
- d(h), l(u.ENTER);
62
- }, B = (h) => {
63
- d(h), l(u.SPACE);
64
- }, I = () => {
65
- r(), l(u.ESCAPE);
66
- }, S = () => {
67
- l(u.SHOW_MORE);
68
- }, O = {
69
- [u.SELECT]: d,
70
- [u.SHOW_MORE]: S,
71
- [u.TAB]: f,
72
- [u.SPACE]: B,
73
- [u.ENTER]: E
74
- };
75
- return {
76
- // Values
77
- actions: p,
78
- internalSelectedValue: n,
79
- // Methods
80
- listeners: O,
81
- onEscapeKey: I,
82
- onOutsideDropdownClick: g
83
- };
84
- }, ft = z({
85
- i18n: { messages: ye },
86
- name: "bento-dropdown-options-container"
87
- }), pt = /* @__PURE__ */ z({
88
- ...ft,
89
- props: {
90
- /**
91
- * Defines a string value that labels an interactive element.
92
- */
93
- ariaLabel: { type: String, default: null },
94
- /**
95
- * Empty state props used with the inner empty state component which is displayed when no search results are found.
96
- */
97
- emptyState: {
98
- type: Object,
99
- default: void 0
100
- },
101
- /**
102
- * Disables dropdown functionality
103
- */
104
- disabled: { type: Boolean, default: !1 },
105
- /**
106
- * Indicates whether there are more items to load
107
- */
108
- hasMoreItems: { type: Boolean, default: !1 },
109
- /**
110
- * Identifies the listbox whose contents are controlled by the the combobox on which the aria-controls attribute is set.
111
- */
112
- id: { type: String, required: !0 },
113
- /**
114
- * Function that allows the options to be disabled
115
- *
116
- * @type {BentoDropdownIsOptionDisabled}
117
- * @param {BentoDropdownOptionItem} option - Dropdown option object
118
- * @param {string} option.label - Option's label text
119
- * @param {string|number} option.value - Option's value
120
- * @param {unknown} option.data - Option's extra data to be passed to the default slot
121
- */
122
- isOptionDisabled: {
123
- type: Function,
124
- default: void 0
125
- },
126
- /**
127
- * The option elements to populate the dropdown with.
128
- * It must be an array of {@see BentoDropdownOptionItem }
129
- * * @property {string} value.label - Text to be displayed in the option
130
- * * @property {string,number} value.value - Value of the option
131
- */
132
- items: {
133
- type: Array,
134
- required: !0
135
- },
136
- /**
137
- * The type of `Lazy Load`.
138
- * Type "automatic" will enable infinite scrolling
139
- * Type "button" will enable lazy loading with "Show more" button
140
- */
141
- lazyLoadType: {
142
- type: String,
143
- default: pe.AUTOMATIC,
144
- validator: (t) => Object.values(pe).includes(t)
145
- },
146
- /**
147
- * Indicates if new options are loading.
148
- */
149
- loading: { type: Boolean, default: !1 },
150
- /**
151
- * If enabled, the user will be able to select multiple items.
152
- */
153
- multiple: { type: Boolean, default: !1 },
154
- /**
155
- * Indicates if the dropdown is open so that
156
- * the container can be displayed.
157
- */
158
- open: { type: Boolean, required: !0 },
159
- /**
160
- * The `input` value.
161
- * Providing an empty string or empty array will select no options.
162
- * Set to an empty string `''` if you don't want any of the available options to be selected for single select
163
- */
164
- selectedValue: {
165
- type: Array,
166
- default: null
167
- },
168
- /**
169
- * Flag that indicates that an external search it's being made
170
- * to filter out the items inside the the multi-select listbox
171
- *
172
- * If enabled, hides the "Select all" checkbox in "multiple" mode.
173
- */
174
- searching: me.props.searching,
175
- /**
176
- * If enabled, dropdown will display non-selectable, static categories
177
- */
178
- staticCategories: { type: Boolean, default: !1 },
179
- /**
180
- * Reference to the DOM element or Vue component for positioning
181
- * the Dropdown container.
182
- */
183
- targetElement: { type: Se.props.targetElement.type, required: !0 },
184
- /**
185
- * Enables virtual scrolling if set to true or by providing an object with itemHeight function.
186
- * The itemHeight function is used to calculate the height of rendered item given it's index.
187
- */
188
- virtualScroll: {
189
- type: [Boolean, Object],
190
- default: !1
191
- }
192
- },
193
- setup(t, { expose: a, emit: s }) {
194
- const l = Oe(), n = s, e = t, { selectedValue: i, multiple: m } = Ce(e), r = $(null), { t: g } = be({ messages: ye }), p = c(() => e.open && !e.disabled), d = c(() => g("noOptionsMatchThisSearch")), f = c(() => ({
195
- "b-dropdown-options-container--single": !(e != null && e.multiple)
196
- })), E = c(() => ({
197
- "b-dropdown-options-container__listbox--single": !(e != null && e.multiple)
198
- })), { actions: B, internalSelectedValue: I, listeners: S, onEscapeKey: O, onOutsideDropdownClick: h } = ct(i, m, p, n), v = c(() => e != null && e.multiple ? ut : Se), y = c(() => {
199
- var w;
200
- const x = {
201
- "min-width": `${(w = e == null ? void 0 : e.targetElement) == null ? void 0 : w.clientWidth}px`,
202
- "max-width": "min(500px, 95%)"
203
- };
204
- return e != null && e.multiple ? {
205
- actionsLayout: "space-between",
206
- actions: B.value,
207
- divider: !0,
208
- fallbackPosition: ["top-start"],
209
- id: V(`dropdown-options-${e.id}`),
210
- open: e.open,
211
- position: "bottom-start",
212
- style: {
213
- width: "auto",
214
- ...x
215
- },
216
- targetElement: e.targetElement
217
- } : {
218
- fallbackPosition: ["top-start"],
219
- offset: [0, 8],
220
- position: "bottom-start",
221
- style: {
222
- display: p.value ? "block" : "none",
223
- ...x
224
- },
225
- targetElement: e.targetElement
226
- };
227
- });
228
- return a({
229
- onOutsideDropdownClick: h
230
- }), (x, w) => (L(), P(Be(v.value), M({
231
- class: ["b-dropdown-options-container", f.value],
232
- "aria-label": t.ariaLabel
233
- }, y.value), {
234
- default: F(() => [
235
- ee("div", {
236
- onKeydown: w[0] || (w[0] = Ye(
237
- //@ts-ignore
238
- (...j) => o(O) && o(O)(...j),
239
- ["esc"]
240
- ))
241
- }, [
242
- Z(o(me), M({
243
- id: t.id,
244
- ref_key: "dropdownOptionsListboxRef",
245
- ref: r,
246
- "aria-label": t.ariaLabel,
247
- class: ["b-dropdown-options-container__listbox", E.value],
248
- "empty-state": t.emptyState,
249
- "is-option-disabled": t.isOptionDisabled,
250
- items: t.items,
251
- "selected-value": o(I),
252
- multiple: o(m),
253
- "static-categories": t.staticCategories,
254
- "no-results-message": d.value,
255
- searching: t.searching,
256
- loading: t.loading,
257
- "lazy-load-type": t.lazyLoadType,
258
- "has-more-items": t.hasMoreItems,
259
- "virtual-scroll": t.virtualScroll
260
- }, X(o(S))), re({ _: 2 }, [
261
- de(o(l), (j, W) => ({
262
- name: W,
263
- fn: F((te) => [
264
- Q(x.$slots, W, ue(ce(te)), void 0, !0)
265
- ])
266
- }))
267
- ]), 1040, ["id", "aria-label", "class", "empty-state", "is-option-disabled", "items", "selected-value", "multiple", "static-categories", "no-results-message", "searching", "loading", "lazy-load-type", "has-more-items", "virtual-scroll"])
268
- ], 32)
269
- ]),
270
- _: 3
271
- }, 16, ["aria-label", "class"]));
272
- }
273
- }), mt = /* @__PURE__ */ Y(pt, [["__scopeId", "data-v-9390dd46"]]);
274
- let we = 0;
275
- const vt = {
276
- beforeCreate() {
277
- this.uuid = we.toString(), we += 1;
278
- }
279
- }, bt = { key: 0 };
280
- function yt(t, a, s, l, n, e) {
281
- return L(), k("svg", M({ role: "img" }, t.$attrs, {
282
- class: "ui-assets-icons-16",
283
- xmlns: "http://www.w3.org/2000/svg",
284
- width: "16",
285
- height: "16",
286
- fill: "none"
287
- }), [
288
- t.$attrs["svg-title"] ? (L(), k("title", bt, ve(t.$attrs["svg-title"]), 1)) : K("", !0),
289
- a[0] || (a[0] = ee("path", {
290
- fill: "#00112C",
291
- d: "M5.00011 5.43922L8.00011 8.43922L11.0001 5.43922L12.0608 6.49988L8.00011 10.5605L3.93945 6.49988L5.00011 5.43922Z"
292
- }, null, -1))
293
- ], 16);
294
- }
295
- const gt = /* @__PURE__ */ Y(vt, [["render", yt]]);
296
- let $e = 0;
297
- const ht = {
298
- beforeCreate() {
299
- this.uuid = $e.toString(), $e += 1;
300
- }
301
- }, Lt = { key: 0 };
302
- function xt(t, a, s, l, n, e) {
303
- return L(), k("svg", M({ role: "img" }, t.$attrs, {
304
- class: "ui-assets-icons-16",
305
- xmlns: "http://www.w3.org/2000/svg",
306
- width: "16",
307
- height: "16",
308
- fill: "none"
309
- }), [
310
- t.$attrs["svg-title"] ? (L(), k("title", Lt, ve(t.$attrs["svg-title"]), 1)) : K("", !0),
311
- a[0] || (a[0] = ee("path", {
312
- fill: "#00112C",
313
- d: "M10.9999 10.5608L7.9999 7.56077L4.9999 10.5608L3.93924 9.50011L7.9999 5.43945L12.0606 9.50011L10.9999 10.5608Z"
314
- }, null, -1))
315
- ], 16);
316
- }
317
- const St = /* @__PURE__ */ Y(ht, [["render", xt]]), wt = { class: "b-dropdown-small-textbox__chevron" }, $t = z({
318
- name: "dropdown-small-textbox",
319
- inheritAttrs: !1
320
- }), Et = /* @__PURE__ */ z({
321
- ...$t,
322
- props: {
323
- /**
324
- * The number of additional items that have been selected in the dropdown.
325
- */
326
- additionalItemsSelected: { type: [Number, String], default: 0 },
327
- /**
328
- * Sets the aria-controls attribute on the textbox. This should correspond to the popover's id that the textbox triggers.
329
- */
330
- ariaControls: { type: String, required: !0 },
331
- /**
332
- * 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.
333
- */
334
- ariaExpanded: {
335
- type: [String, Boolean],
336
- required: !0
337
- },
338
- /**
339
- * If no label element is used then the aria-label is be set should be set.
340
- */
341
- ariaLabel: { type: String, default: null },
342
- /**
343
- * Corresponds to the label's id that labels the textbox element.
344
- */
345
- ariaLabelledby: { type: String, default: null },
346
- /**
347
- * Custom debounce time. Default: 300
348
- */
349
- debounceTime: { type: Number, default: 300 },
350
- /**
351
- * Disables any textbox functionality
352
- */
353
- disabled: { type: Boolean, default: !1 },
354
- /**
355
- * Selected option's label
356
- */
357
- displayValue: { type: String, default: null },
358
- /**
359
- * Sets the possibility to type into the textbox
360
- */
361
- dynamicFiltering: { type: Boolean, default: !1 },
362
- /**
363
- * Marks the textbox as invalid, rendering an error state
364
- */
365
- isInvalid: { type: Boolean, default: !1 },
366
- /**
367
- * Indicates if the dropdown is open so that
368
- * the respective event can be emitted
369
- */
370
- open: { type: Boolean, default: !1 },
371
- /**
372
- * Sets the dropdown to readonly state
373
- */
374
- readonly: { type: Boolean, default: !1 },
375
- /**
376
- * The input value
377
- */
378
- value: { type: String, default: "" }
379
- },
380
- emits: ["clear", "close", "input", "keydown", "open"],
381
- setup(t, { emit: a }) {
382
- const s = a, l = t, n = c(() => ({
383
- [`b-dropdown-small-textbox--${ne.DISABLED}`]: l.disabled,
384
- [`b-dropdown-small-textbox--${ne.READONLY}`]: l.readonly,
385
- [`b-dropdown-small-textbox--${ne.OPENED}`]: l.open
386
- })), e = c(() => l.open && !l.disabled && !l.readonly), i = (f) => {
387
- s("input", f);
388
- }, m = (f) => {
389
- s("keydown", f);
390
- }, r = (f) => {
391
- ie(f), s("open");
392
- }, g = (f) => {
393
- ie(f), s("close");
394
- }, p = (f) => {
395
- ie(f), s("clear");
396
- }, d = {
397
- [q.INPUT]: i,
398
- [q.OPEN]: r,
399
- [q.CLOSE]: g,
400
- [q.CLEAR]: p,
401
- [q.KEYDOWN]: m
402
- };
403
- return (f, E) => (L(), k("div", {
404
- class: fe(["b-dropdown-small-textbox", n.value])
405
- }, [
406
- Z(Ge, M({ ...f.$attrs, ...f.$props }, {
407
- class: "b-dropdown-small-textbox__textbox",
408
- size: o(J).SMALL
409
- }, X(d)), {
410
- icon: F(() => [
411
- ee("div", wt, [
412
- G(Z(o(St), { "svg-title": "opened" }, null, 512), [
413
- [Le, e.value]
414
- ]),
415
- G(Z(o(gt), { "svg-title": "closed" }, null, 512), [
416
- [Le, !e.value]
417
- ])
418
- ])
419
- ]),
420
- _: 1
421
- }, 16, ["size"])
422
- ], 2));
423
- }
424
- }), Ot = /* @__PURE__ */ Y(Et, [["__scopeId", "data-v-2fa2d897"]]), Ct = (t, a) => a.value.reduce((s, l) => {
425
- if (l.items) {
426
- const n = l.items.filter(
427
- (i) => t.value.find((m) => m.value === i.value)
428
- );
429
- n.length === l.items.length ? s.push(l.label) : n.forEach(({ label: i }) => s.push(i));
430
- }
431
- return t.value.find((n) => n.value === l.value) && s.push(l.label), s;
432
- }, []).join(", "), Bt = ({ items: t, placeholder: a, selectedValues: s, isMultiSelect: l }) => {
433
- const n = c(
434
- () => l.value && t.value.find((i) => {
435
- var m;
436
- return (m = i.items) == null ? void 0 : m.length;
437
- })
438
- );
439
- return c(() => s.value.length ? n.value ? Ct(s, t) : s.value.map(({ label: i }) => i).join(", ") : a.value || null);
440
- }, Ie = (t) => {
441
- var a;
442
- (a = t.value.$children) == null || a[0].$refs.textbox.focus();
443
- }, It = ({
444
- inputContainerRef: t,
445
- optionsContainerRef: a,
446
- selectedValueIndex: s,
447
- isDropdownOpen: l,
448
- isDynamicFltering: n,
449
- items: e,
450
- isMultiple: i
451
- }, m, r, g) => {
452
- const p = ({ detail: v }) => {
453
- v.preventDefault(), l.value || r(), A(() => {
454
- var y;
455
- i ? (y = a.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children) == null || y[0].$el.focus() : (a.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.setListboxFocusedIndex(
456
- s.value
457
- ), a.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.listboxItemRef[s.value].$el.focus());
458
- });
459
- }, d = ({ detail: v }) => {
460
- v.preventDefault(), l.value || r(), A(() => {
461
- a.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.setListboxFocusedIndex(
462
- s.value
463
- ), a.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.listboxItemRef[s.value].$el.focus();
464
- });
465
- }, f = () => {
466
- l.value || (r(), A(() => {
467
- var v, y;
468
- if (i) {
469
- const x = a.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children;
470
- (v = a.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children) == null || v[x.length - 1].$children[e.length - 1].$el.focus();
471
- } else
472
- (y = a.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children) == null || y[e.length - 1].$el.focus();
473
- }));
474
- }, E = () => {
475
- l.value && (g(), Ie(t));
476
- }, B = () => {
477
- l.value && g();
478
- }, I = () => {
479
- l.value || r(), A(() => {
480
- var v;
481
- (v = a.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children) == null || v[0].$el.focus();
482
- });
483
- }, S = ({ detail: v }) => {
484
- v.preventDefault(), m(), l.value && A(() => {
485
- var y, x;
486
- i ? (y = a.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children) == null || y[0].$el.focus() : (x = a.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children) == null || x[s.value].$el.focus();
487
- });
488
- }, O = () => {
489
- m(), l.value && A(() => {
490
- var v, y;
491
- i ? (v = a.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children) == null || v[0].$el.focus() : (y = a.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef.$children) == null || y[s.value].$el.focus();
492
- });
493
- };
494
- return c(() => ({
495
- ...n.value ? {} : { [T.SPACE]: S },
496
- [T.ENTER]: O,
497
- [T.ARROW_DOWN]: p,
498
- [T.ARROW_UP]: d,
499
- [T.END]: f,
500
- [T.ESCAPE]: E,
501
- [T.HOME]: I,
502
- [T.TAB]: B
503
- }));
504
- }, Dt = ({ inputContainerRef: t, isDropdownOpen: a }, s) => {
505
- const l = () => {
506
- a.value && s(), A(() => {
507
- Ie(t);
508
- });
509
- };
510
- return {
511
- [u.ENTER]: l,
512
- [u.ESCAPE]: l,
513
- [u.TAB]: l,
514
- [u.SPACE]: l
515
- };
516
- };
517
- function Rt(t, a, s, l) {
518
- const n = $(t), e = $(a), i = (r, g = []) => g.flatMap((p) => p.label.toLocaleLowerCase().includes(r) ? l != null && l.value && p.items ? [...i(r, p.items)] : [p, ...i(r, p.items)] : p.items ? [...i(r, p.items)] : []);
519
- return Ee(n, () => {
520
- s !== void 0 && s(n.value);
521
- }), c(() => {
522
- if (!n.value || s !== void 0)
523
- return e.value;
524
- const r = n.value.toLocaleLowerCase();
525
- return i(r, e.value);
526
- });
527
- }
528
- const De = {
529
- "en-US": {
530
- all: "All",
531
- clearSearch: "Clear filter",
532
- ariaLabelFallback: "Dropdown"
533
- },
534
- "pt-BR": {
535
- all: "Todos",
536
- clearFilter: "Limpar filtro"
537
- },
538
- "ja-JP": {
539
- all: "すべて",
540
- clearFilter: "フィルターをクリア"
541
- }
542
- }, Tt = Symbol("input field component injection key"), Xt = Symbol("input field hint injection key"), Nt = z({
543
- i18n: { messages: De },
544
- name: "b-dropdown",
545
- components: {
546
- DropdownInputDefault: et,
547
- DropdownInputSmall: Ot
548
- }
549
- }), At = /* @__PURE__ */ z({
550
- ...Nt,
551
- props: {
552
- /**
553
- * @deprecated from version 2.0.0. Use the aria-label attribute instead.
554
- */
555
- /**
556
- * Defines a string value that labels an interactive element.
557
- */
558
- ariaLabel: { type: String, default: null },
559
- /**
560
- * Renders the dropdown with a condensed style.
561
- */
562
- condensed: { type: Boolean, default: !1 },
563
- /**
564
- * Empty state props used with the inner empty state component which is displayed when no search results are found.
565
- */
566
- emptyState: {
567
- type: Object,
568
- default: void 0
569
- },
570
- /**
571
- * Disables dropdown functionality.
572
- */
573
- disabled: { type: Boolean, default: !1 },
574
- /**
575
- * Sets the possibility to type into the textbox.
576
- */
577
- dynamicFiltering: {
578
- type: Boolean,
579
- default: !1
580
- },
581
- /**
582
- * Highlights the dropdown in an erroneous state.
583
- *
584
- * @deprecated Use "errorMessage" prop instead
585
- */
586
- error: { type: Boolean, default: !1 },
587
- /**
588
- * Highlights the dropdown in an erroneous state with an error message.
589
- */
590
- errorMessage: { type: String, default: null },
591
- /**
592
- * Descriptive supporting text visbile underneath the dropdown.
593
- */
594
- description: { type: String, default: null },
595
- /**
596
- * Indicates whether there are more items to load
597
- */
598
- hasMoreItems: { type: Boolean, default: !1 },
599
- /**
600
- * Function that dertermines which options are disabled from interaction.
601
- *
602
- * @type {BentoListboxIsOptionDisabled}
603
- * @param {BentoListboxOptionItem} option - Dropdown option object
604
- * @param {string} option.label - Option's label text
605
- * @param {string|number} option.value - Option's value
606
- * @param {unknown} option.data - Option's extra data to be passed to the default slot
607
- */
608
- isOptionDisabled: {
609
- type: Function,
610
- default: void 0
611
- },
612
- /**
613
- * The option elements to populate the dropdown with.
614
- * It must be an array of {@see BentoListboxOptionItem }
615
- * * @property {string} value.label - Text to be displayed in the option
616
- * * @property {string,number} value.value - Value of the option
617
- */
618
- items: {
619
- type: Array,
620
- default: () => []
621
- },
622
- /**
623
- * Text that is displayed as a label above the element.
624
- */
625
- label: { type: String, default: null },
626
- /**
627
- * Indicates if new options are loading.
628
- */
629
- loading: { type: Boolean, default: !1 },
630
- /**
631
- * The type of `Lazy Load`.
632
- * Type "automatic" will enable infinite scrolling
633
- * Type "button" will enable lazy loading with "Show more" button
634
- */
635
- lazyLoadType: {
636
- type: String,
637
- default: me.props.lazyLoadType.default,
638
- validator: (t) => Object.values(pe).includes(t)
639
- },
640
- /*
641
- * If enabled, the user will be able to select multiple items.
642
- */
643
- multiple: { type: Boolean, default: !1 },
644
- /**
645
- * Highlights the dropdown is optional.
646
- */
647
- optional: { type: Boolean, default: !1 },
648
- /**
649
- * Text that appears in the form control when it has no value set
650
- */
651
- placeholder: { type: String, default: null },
652
- /**
653
- * Sets the dropdown to readonly state
654
- */
655
- readonly: { type: Boolean, default: !1 },
656
- /**
657
- * Highlights the dropdown is required.
658
- */
659
- required: { type: Boolean, default: !1 },
660
- /**
661
- * Dropdown search options and events.
662
- * @see BentoDropdownSearchOptions
663
- */
664
- search: {
665
- type: Object,
666
- default: void 0
667
- },
668
- /**
669
- * Toggles whether to use the slot content select items shown in the textbox in multiple mode.
670
- */
671
- showSlotContentInMultiple: { type: Boolean, default: !1 },
672
- /**
673
- * @deprecated Do not use. Only 'default' size should be used.
674
- */
675
- size: {
676
- type: String,
677
- default: null,
678
- validator: (t) => Object.values(J).includes(t)
679
- },
680
- /**
681
- * If enabled, dropdown will display non-selectable, static categories
682
- */
683
- staticCategories: { type: Boolean, default: !1 },
684
- /**
685
- * Adds a info icon next to the label to display the passed tooltip message.
686
- */
687
- tooltipText: { type: String, default: null },
688
- /**
689
- * The `input` value.
690
- * Providing an empty string will select no options.
691
- * Set to an empty string `''` if you don't want any of the available options to be selected.
692
- */
693
- value: {
694
- type: [String, Number, Array],
695
- default: null
696
- },
697
- /**
698
- * Enables virtual scrolling if set to true or by providing an object with itemHeight function.
699
- * The itemHeight function is used to calculate the height of rendered item given it's index.
700
- */
701
- virtualScroll: {
702
- type: [Boolean, Object],
703
- default: !1
704
- }
705
- },
706
- emits: ["input", "show-more"],
707
- setup(t, { emit: a }) {
708
- var he;
709
- const s = _e(), l = Oe(), n = it(l), e = t, i = a, { t: m } = be({ messages: De }), r = $(null), g = $(null), p = $(null), d = $(!1), f = V("bento-dropdown-options-container"), E = V("dropdown-label"), B = V("dropdown-description"), I = V("dropdown-error"), { isReadOnly: S } = lt(C(e, "readonly")), { cachedSelectedListboxOptions: O, cachedListboxSelectedValues: h, setCachedValues: v } = st(
710
- C(e, "items"),
711
- C(e, "value"),
712
- C(e, "multiple")
713
- ), y = $(s["aria-label"]), { ariaLabel: x, label: w } = Ce(e), j = tt({
714
- // TODO: take ariaLabel ref away when aria-label prop is removed
715
- ariaLabel: x || y,
716
- label: w,
717
- defaultFallback: m("ariaLabelFallback")
718
- }), W = e.size === J.SMALL || Ze(Tt, !1), te = c(() => W ? J.SMALL : J.DEFAULT), Re = c(() => ({
719
- "b-dropdown--condensed": e.condensed
720
- })), Te = c(() => ({
721
- "b-dropdown__description--error": !!e.errorMessage
722
- })), N = $(""), _ = C(e, "items"), ge = C(e, "staticCategories"), Ne = Rt(N, _, (he = e == null ? void 0 : e.search) == null ? void 0 : he.searchEvent, ge), le = c(() => e.dynamicFiltering && !!N.value), Ae = Bt({
723
- items: _,
724
- placeholder: C(e, "placeholder"),
725
- isMultiSelect: C(e, "multiple"),
726
- selectedValues: O
727
- }), Me = c(() => {
728
- if (e != null && e.multiple && Array.isArray(e.value))
729
- return e.items.filter(
730
- ({ value: b }) => (e == null ? void 0 : e.value) && (e == null ? void 0 : e.value).includes(b)
731
- );
732
- if (!e.multiple && e.staticCategories) {
733
- const b = e.items.find(
734
- (R) => R.items.some((U) => U.value === e.value)
735
- );
736
- return b ? b.items.find((R) => R.value === e.value) : null;
737
- }
738
- return e.items.find(({ value: b }) => b === (e == null ? void 0 : e.value));
739
- }), ke = c(() => {
740
- const b = e.items.findIndex(({ value: D }) => e.value === D);
741
- return b > 0 ? b : 0;
742
- }), { isMultiLevelSelect: Pe, flattenedItemsList: Ke } = nt(_), Fe = c(() => {
743
- var b;
744
- if (e.multiple) {
745
- const D = (b = e == null ? void 0 : e.value) == null ? void 0 : b.length, R = Pe.value ? Ke.value.length : _.value.length;
746
- return !e.hasMoreItems && R === D ? m("all") : D;
747
- }
748
- return null;
749
- }), ze = c(
750
- () => `${e.description ? B : ""} ${e.errorMessage ? I : ""}`.trim() || null
751
- ), je = () => {
752
- S.value || (d.value = !0);
753
- }, ae = () => {
754
- d.value = !1;
755
- }, oe = () => {
756
- S.value || (d.value = !d.value, le.value && (N.value = ""));
757
- }, We = () => {
758
- le.value && (N.value = ""), d.value && (d.value = !1, p.value.onOutsideDropdownClick());
759
- }, Ue = (b) => {
760
- e.multiple || (N.value = "", d.value = !1), v(b), i("input", h.value);
761
- }, He = () => {
762
- i(u.SHOW_MORE);
763
- }, qe = It(
764
- {
765
- inputContainerRef: r,
766
- optionsContainerRef: p,
767
- selectedValueIndex: ke,
768
- isDropdownOpen: d,
769
- isDynamicFltering: C(e, "dynamicFiltering"),
770
- items: e.items,
771
- isMultiple: e.multiple
772
- },
773
- oe,
774
- je,
775
- ae
776
- ), Je = Dt(
777
- {
778
- inputContainerRef: r,
779
- isDropdownOpen: d
780
- },
781
- ae
782
- ), Ve = {
783
- [u.CLOSE_DROPDOWN]: ae,
784
- [u.SELECT]: Ue,
785
- [u.SHOW_MORE]: He,
786
- ...Je
787
- };
788
- return e.error && xe(
789
- 'BentoDropdown "error" property',
790
- `Use the BentoDropdown "errorMessage" property instead to indicate that there is a modifier error.
791
- Having the field as "undefined" will hide/remove the error.
792
- <bento-dropdown errorMessage="Error message text" />`,
793
- "2.0.0"
794
- ), e.size && xe('BentoDropdown "size" property', "Do not use. Only 'default' size should be used.", "2.0.0"), (b, D) => {
795
- var R;
796
- return G((L(), k("div", {
797
- class: fe(["b-dropdown", Re.value])
798
- }, [
799
- o(w) ? (L(), P(o(rt), {
800
- key: 0,
801
- id: o(E),
802
- condensed: t.condensed,
803
- label: o(w),
804
- "tooltip-text": t.tooltipText,
805
- optional: t.optional,
806
- required: t.required
807
- }, null, 8, ["id", "condensed", "label", "tooltip-text", "optional", "required"])) : K("", !0),
808
- G((L(), k("div", M({
809
- ref_key: "inputContainerRefWrapper",
810
- ref: g
811
- }, X(o(qe), !0)), [
812
- (L(), P(Be(te.value), {
813
- ref_key: "inputContainerRef",
814
- ref: r,
815
- condensed: t.condensed,
816
- value: N.value,
817
- "additional-items-selected": Fe.value,
818
- ariaControls: o(f),
819
- ariaExpanded: d.value,
820
- "aria-labelledby": o(w) ? o(E) : null,
821
- "aria-describedby": ze.value,
822
- "aria-label": o(j),
823
- "aria-readonly": o(S),
824
- readonly: o(S),
825
- disabled: t.disabled,
826
- "display-value": o(Ae),
827
- "dynamic-filtering": t.dynamicFiltering,
828
- "is-invalid": !!t.errorMessage || t.error,
829
- multiple: t.multiple,
830
- open: d.value,
831
- "selected-value-item": o(W) ? void 0 : Me.value,
832
- "show-slot-content-in-multiple": t.showSlotContentInMultiple,
833
- onInput: D[0] || (D[0] = (U) => N.value = U),
834
- onOpen: oe,
835
- onClose: oe
836
- }, re({ _: 2 }, [
837
- de(o(l), (U, H) => ({
838
- name: H,
839
- fn: F((se) => [
840
- Q(b.$slots, H, ue(ce(se)), void 0, !0)
841
- ])
842
- }))
843
- ]), 1064, ["condensed", "value", "additional-items-selected", "ariaControls", "ariaExpanded", "aria-labelledby", "aria-describedby", "aria-label", "aria-readonly", "readonly", "disabled", "display-value", "dynamic-filtering", "is-invalid", "multiple", "open", "selected-value-item", "show-slot-content-in-multiple"]))
844
- ], 16)), [
845
- [o(ot)]
846
- ]),
847
- r.value ? (L(), P(o(mt), M({
848
- key: 1,
849
- id: o(f),
850
- ref_key: "optionsContainerRef",
851
- ref: p,
852
- "aria-label": o(j),
853
- "empty-state": t.emptyState,
854
- "debounce-time": (R = t.search) == null ? void 0 : R.debounceTime,
855
- disabled: t.disabled,
856
- "is-option-disabled": t.isOptionDisabled,
857
- items: o(Ne),
858
- multiple: t.multiple,
859
- "static-categories": ge.value,
860
- open: d.value,
861
- "selected-value": o(O),
862
- searching: le.value,
863
- "target-element": g.value,
864
- loading: t.loading,
865
- "has-more-items": t.hasMoreItems,
866
- "lazy-load-type": t.lazyLoadType,
867
- "virtual-scroll": t.virtualScroll
868
- }, X(Ve)), re({ _: 2 }, [
869
- de(o(l), (U, H) => ({
870
- name: H,
871
- fn: F((se) => [
872
- Q(b.$slots, H, ue(ce(se)), void 0, !0)
873
- ])
874
- }))
875
- ]), 1040, ["id", "aria-label", "empty-state", "debounce-time", "disabled", "is-option-disabled", "items", "multiple", "static-categories", "open", "selected-value", "searching", "target-element", "loading", "has-more-items", "lazy-load-type", "virtual-scroll"])) : K("", !0),
876
- t.errorMessage ? (L(), P(o(dt), {
877
- key: 2,
878
- id: o(I),
879
- "error-message": t.errorMessage,
880
- class: "b-dropdown__error-message"
881
- }, null, 8, ["id", "error-message"])) : K("", !0),
882
- t.description || o(n)("description") ? (L(), P(o(Xe), {
883
- key: 3,
884
- id: o(B),
885
- class: fe(["b-dropdown__description", Te.value]),
886
- el: "span"
887
- }, {
888
- default: F(() => [
889
- Q(b.$slots, "description", {}, () => [
890
- Qe(ve(t.description), 1)
891
- ], !0)
892
- ]),
893
- _: 3
894
- }, 8, ["id", "class"])) : K("", !0)
895
- ], 2)), [
896
- [o(at), We]
897
- ]);
898
- };
899
- }
900
- }), Gt = /* @__PURE__ */ Y(At, [["__scopeId", "data-v-6bb19b16"]]);
901
- export {
902
- Gt as B,
903
- Xt as I,
904
- Tt as a,
905
- Rt as u
906
- };
907
- //# sourceMappingURL=dropdown.DpjMobyf.js.map