@adyen/bento-vue2 1.67.0 → 1.68.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 (175) hide show
  1. package/dist/@types/index.d.ts +2066 -2264
  2. package/dist/action-bar.js +1 -1
  3. package/dist/assets/accordion-item.css +1 -1
  4. package/dist/assets/action-bar.css +1 -1
  5. package/dist/assets/base-modal.css +1 -1
  6. package/dist/assets/button-actions.css +1 -1
  7. package/dist/assets/card.css +1 -1
  8. package/dist/assets/checkbox.css +1 -1
  9. package/dist/assets/data-grid.css +1 -1
  10. package/dist/assets/dialog-page.css +1 -1
  11. package/dist/assets/dropdown.css +1 -1
  12. package/dist/assets/file-uploader.css +1 -1
  13. package/dist/assets/filter-bar.css +1 -1
  14. package/dist/assets/header-meta.css +1 -0
  15. package/dist/assets/header-with-views.css +1 -1
  16. package/dist/assets/header.css +1 -1
  17. package/dist/assets/input-field-phone-number.css +1 -1
  18. package/dist/assets/input-field.css +1 -1
  19. package/dist/assets/inspector.css +1 -1
  20. package/dist/assets/menu.css +1 -1
  21. package/dist/assets/modal-fullscreen.css +1 -1
  22. package/dist/assets/popover.css +1 -1
  23. package/dist/assets/sidepanel.css +1 -1
  24. package/dist/assets/summary-grid.css +1 -1
  25. package/dist/assets/textarea.css +1 -1
  26. package/dist/assets/use-cached-selected-values.css +1 -1
  27. package/dist/button.js +1 -1
  28. package/dist/card.js +1 -1
  29. package/dist/checkbox.js +2 -2
  30. package/dist/chunks/{action-bar.BxX3I27_.js → action-bar.Dy6tfK8c.js} +4 -4
  31. package/dist/chunks/{action-bar.BxX3I27_.js.map → action-bar.Dy6tfK8c.js.map} +1 -1
  32. package/dist/chunks/{base-modal.QGDM_kjG.js → base-modal.CkkfT6r6.js} +55 -118
  33. package/dist/chunks/base-modal.CkkfT6r6.js.map +1 -0
  34. package/dist/chunks/{button-actions-with-menu.itkbcqzk.js → button-actions-with-menu.CcxUTbsI.js} +3 -3
  35. package/dist/chunks/{button-actions-with-menu.itkbcqzk.js.map → button-actions-with-menu.CcxUTbsI.js.map} +1 -1
  36. package/dist/chunks/{button-actions.BKdI_ooV.js → button-actions.Ju27CRNG.js} +2 -2
  37. package/dist/chunks/button-actions.Ju27CRNG.js.map +1 -0
  38. package/dist/chunks/{card.BktfAMv5.js → card.CASAAsuJ.js} +2 -2
  39. package/dist/chunks/{card.BktfAMv5.js.map → card.CASAAsuJ.js.map} +1 -1
  40. package/dist/chunks/{checkbox-group.BVMGnokj.js → checkbox-group.QdX-NrSG.js} +2 -2
  41. package/dist/chunks/{checkbox-group.BVMGnokj.js.map → checkbox-group.QdX-NrSG.js.map} +1 -1
  42. package/dist/chunks/{checkbox.Bg5FM5Oa.js → checkbox.DCD6SSXC.js} +38 -37
  43. package/dist/chunks/checkbox.DCD6SSXC.js.map +1 -0
  44. package/dist/chunks/{code-snippet.DDiQ9R3o.js → code-snippet.dIKi0D7d.js} +3 -3
  45. package/dist/chunks/{code-snippet.DDiQ9R3o.js.map → code-snippet.dIKi0D7d.js.map} +1 -1
  46. package/dist/chunks/{country.Df7erZov.js → country.melpzEsY.js} +2 -2
  47. package/dist/chunks/{country.Df7erZov.js.map → country.melpzEsY.js.map} +1 -1
  48. package/dist/chunks/{dashboard-section.Beep1lY8.js → dashboard-section.DBT99mLj.js} +2 -2
  49. package/dist/chunks/{dashboard-section.Beep1lY8.js.map → dashboard-section.DBT99mLj.js.map} +1 -1
  50. package/dist/chunks/{dashed-underline.BQwLgzz6.js → dashed-underline.BbH6Lnd2.js} +2 -2
  51. package/dist/chunks/{dashed-underline.BQwLgzz6.js.map → dashed-underline.BbH6Lnd2.js.map} +1 -1
  52. package/dist/chunks/{data-grid-template.nkx0pCMA.js → data-grid-template.B2lDfM2o.js} +2 -2
  53. package/dist/chunks/{data-grid-template.nkx0pCMA.js.map → data-grid-template.B2lDfM2o.js.map} +1 -1
  54. package/dist/chunks/{data-grid.CkwZVy3a.js → data-grid.B7Z9_WDY.js} +1198 -1143
  55. package/dist/chunks/data-grid.B7Z9_WDY.js.map +1 -0
  56. package/dist/chunks/{date-picker.BLBXaDHv.js → date-picker.DGIS6Pp-.js} +2 -2
  57. package/dist/chunks/{date-picker.BLBXaDHv.js.map → date-picker.DGIS6Pp-.js.map} +1 -1
  58. package/dist/chunks/{date-range-picker.am63DgMj.js → date-range-picker.CIaKRXIQ.js} +5 -5
  59. package/dist/chunks/{date-range-picker.am63DgMj.js.map → date-range-picker.CIaKRXIQ.js.map} +1 -1
  60. package/dist/chunks/dropdown-default-textbox.94q6opSD.js.map +1 -1
  61. package/dist/chunks/dropdown-tag.BaosvGGZ.js +240 -0
  62. package/dist/chunks/dropdown-tag.BaosvGGZ.js.map +1 -0
  63. package/dist/chunks/{dropdown.HA6ISg2h.js → dropdown.DazYAy4B.js} +220 -363
  64. package/dist/chunks/dropdown.DazYAy4B.js.map +1 -0
  65. package/dist/chunks/es6.n1ewaW31.js.map +1 -1
  66. package/dist/chunks/{filter-bar.DbqsoAI1.js → filter-bar.DL19SXF1.js} +674 -669
  67. package/dist/chunks/filter-bar.DL19SXF1.js.map +1 -0
  68. package/dist/chunks/{footer-actions.BUfQFz7J.js → footer-actions.BE_zzX-e.js} +2 -2
  69. package/dist/chunks/{footer-actions.BUfQFz7J.js.map → footer-actions.BE_zzX-e.js.map} +1 -1
  70. package/dist/chunks/header-meta.CfloYa86.js +183 -0
  71. package/dist/chunks/header-meta.CfloYa86.js.map +1 -0
  72. package/dist/chunks/{header-with-views.JllLR2nW.js → header-with-views.Bxvu8mq_.js} +526 -520
  73. package/dist/chunks/header-with-views.Bxvu8mq_.js.map +1 -0
  74. package/dist/chunks/header.DvHS-PnC.js +103 -0
  75. package/dist/chunks/header.DvHS-PnC.js.map +1 -0
  76. package/dist/chunks/{input-field-password.BtOdV0gF.js → input-field-password.C1zTapiN.js} +4 -4
  77. package/dist/chunks/{input-field-password.BtOdV0gF.js.map → input-field-password.C1zTapiN.js.map} +1 -1
  78. package/dist/chunks/{input-field-phone-number.Dq-LnGag.js → input-field-phone-number.K8BYjWfa.js} +623 -607
  79. package/dist/chunks/{input-field-phone-number.Dq-LnGag.js.map → input-field-phone-number.K8BYjWfa.js.map} +1 -1
  80. package/dist/chunks/{input-field.Bg77qHT2.js → input-field.5S-pUNxA.js} +7 -7
  81. package/dist/chunks/input-field.5S-pUNxA.js.map +1 -0
  82. package/dist/chunks/{menu.EgYjFAku.js → menu.dX3_vU05.js} +154 -153
  83. package/dist/chunks/{menu.EgYjFAku.js.map → menu.dX3_vU05.js.map} +1 -1
  84. package/dist/chunks/{modal-fullscreen.BNTUOC7o.js → modal-fullscreen.DHotw1RI.js} +76 -63
  85. package/dist/chunks/modal-fullscreen.DHotw1RI.js.map +1 -0
  86. package/dist/chunks/{modal.OvB4kEGR.js → modal.eoNQ6E3U.js} +4 -4
  87. package/dist/chunks/{modal.OvB4kEGR.js.map → modal.eoNQ6E3U.js.map} +1 -1
  88. package/dist/chunks/{pagination.Dw153NzQ.js → pagination.4J7ZMyf5.js} +2 -2
  89. package/dist/chunks/{pagination.Dw153NzQ.js.map → pagination.4J7ZMyf5.js.map} +1 -1
  90. package/dist/chunks/popover.Bo4Bkudr.js +145 -0
  91. package/dist/chunks/popover.Bo4Bkudr.js.map +1 -0
  92. package/dist/chunks/popover.types.CBqyA4ly.js +6 -0
  93. package/dist/chunks/popover.types.CBqyA4ly.js.map +1 -0
  94. package/dist/chunks/{rich-text-editor.CRJRvfJn.js → rich-text-editor.BUKLdRkN.js} +2 -2
  95. package/dist/chunks/{rich-text-editor.CRJRvfJn.js.map → rich-text-editor.BUKLdRkN.js.map} +1 -1
  96. package/dist/chunks/{search-bar.BTZSePJh.js → search-bar.CuBj5FAE.js} +3 -3
  97. package/dist/chunks/{search-bar.BTZSePJh.js.map → search-bar.CuBj5FAE.js.map} +1 -1
  98. package/dist/chunks/{secondary-nav.BBhSBNn7.js → secondary-nav.C6usurfD.js} +2 -2
  99. package/dist/chunks/{secondary-nav.BBhSBNn7.js.map → secondary-nav.C6usurfD.js.map} +1 -1
  100. package/dist/chunks/{sidepanel.Dt-BnFzN.js → sidepanel.DyThBUgV.js} +2 -2
  101. package/dist/chunks/{sidepanel.Dt-BnFzN.js.map → sidepanel.DyThBUgV.js.map} +1 -1
  102. package/dist/chunks/{summary-grid.types.DsvtLg3D.js → summary-grid.types.D_FU3sUq.js} +4 -4
  103. package/dist/chunks/summary-grid.types.D_FU3sUq.js.map +1 -0
  104. package/dist/chunks/{textarea.RAU710Uw.js → textarea.UPM6N9V1.js} +7 -7
  105. package/dist/chunks/textarea.UPM6N9V1.js.map +1 -0
  106. package/dist/chunks/{timeline-item.Dz66luo5.js → timeline-item.DqLhj0Lb.js} +3 -3
  107. package/dist/chunks/{timeline-item.Dz66luo5.js.map → timeline-item.DqLhj0Lb.js.map} +1 -1
  108. package/dist/chunks/{tutorial.DAKO-fKz.js → tutorial.DRRfp81j.js} +7 -6
  109. package/dist/chunks/{tutorial.DAKO-fKz.js.map → tutorial.DRRfp81j.js.map} +1 -1
  110. package/dist/chunks/{use-cached-selected-values.DQPABFfG.js → use-cached-selected-values.0EeyFfyF.js} +413 -410
  111. package/dist/chunks/use-cached-selected-values.0EeyFfyF.js.map +1 -0
  112. package/dist/chunks/{use-country-items.HFnjuDsG.js → use-country-items.BllTb5MK.js} +2 -2
  113. package/dist/chunks/{use-country-items.HFnjuDsG.js.map → use-country-items.BllTb5MK.js.map} +1 -1
  114. package/dist/chunks/{use-country-phon-code.DVgE19zT.js → use-country-phon-code.BOaJ9PDl.js} +507 -498
  115. package/dist/chunks/{use-country-phon-code.DVgE19zT.js.map → use-country-phon-code.BOaJ9PDl.js.map} +1 -1
  116. package/dist/code-snippet.js +1 -1
  117. package/dist/country.js +2 -2
  118. package/dist/dashboard-template.js +1 -1
  119. package/dist/dashed-underline.js +1 -1
  120. package/dist/data-grid-template.js +1 -1
  121. package/dist/data-grid.js +1 -1
  122. package/dist/date-picker.js +1 -1
  123. package/dist/date-range-picker.js +1 -1
  124. package/dist/dropdown.js +3 -3
  125. package/dist/filter-bar.js +1 -1
  126. package/dist/header-with-views.js +1 -1
  127. package/dist/header.js +1 -1
  128. package/dist/index.js +155 -154
  129. package/dist/index.js.map +1 -1
  130. package/dist/input-field-password.js +1 -1
  131. package/dist/input-field-phone-number.js +1 -1
  132. package/dist/input-field.js +1 -1
  133. package/dist/internal.js +15 -14
  134. package/dist/menu.js +1 -1
  135. package/dist/modal-fullscreen.js +1 -1
  136. package/dist/modal.js +11 -11
  137. package/dist/pagination.js +1 -1
  138. package/dist/popover.js +3 -2
  139. package/dist/popover.js.map +1 -1
  140. package/dist/rich-text-editor.js +1 -1
  141. package/dist/search-bar.js +2 -2
  142. package/dist/secondary-nav.js +1 -1
  143. package/dist/sidepanel.js +1 -1
  144. package/dist/styles/bento-dark.css +10 -2
  145. package/dist/styles/bento-light.css +10 -2
  146. package/dist/styles/bento.css +10 -2
  147. package/dist/styles/legacy.css +10 -2
  148. package/dist/styles/styleguide.css +10 -2
  149. package/dist/summary-grid.js +1 -1
  150. package/dist/textarea.js +1 -1
  151. package/dist/timeline.js +1 -1
  152. package/dist/tutorial.js +1 -1
  153. package/dist/web-types.json +265 -51
  154. package/package.json +6 -6
  155. package/dist/assets/info-icon-with-popover.css +0 -1
  156. package/dist/chunks/base-modal.QGDM_kjG.js.map +0 -1
  157. package/dist/chunks/button-actions.BKdI_ooV.js.map +0 -1
  158. package/dist/chunks/checkbox.Bg5FM5Oa.js.map +0 -1
  159. package/dist/chunks/data-grid.CkwZVy3a.js.map +0 -1
  160. package/dist/chunks/dropdown-tag.DYIkCBa6.js +0 -215
  161. package/dist/chunks/dropdown-tag.DYIkCBa6.js.map +0 -1
  162. package/dist/chunks/dropdown.HA6ISg2h.js.map +0 -1
  163. package/dist/chunks/filter-bar.DbqsoAI1.js.map +0 -1
  164. package/dist/chunks/header-with-views.JllLR2nW.js.map +0 -1
  165. package/dist/chunks/header.04Y0unpy.js +0 -188
  166. package/dist/chunks/header.04Y0unpy.js.map +0 -1
  167. package/dist/chunks/info-icon-with-popover.B1DnkW4B.js +0 -71
  168. package/dist/chunks/info-icon-with-popover.B1DnkW4B.js.map +0 -1
  169. package/dist/chunks/input-field.Bg77qHT2.js.map +0 -1
  170. package/dist/chunks/modal-fullscreen.BNTUOC7o.js.map +0 -1
  171. package/dist/chunks/popover.BGHbPUOr.js +0 -295
  172. package/dist/chunks/popover.BGHbPUOr.js.map +0 -1
  173. package/dist/chunks/summary-grid.types.DsvtLg3D.js.map +0 -1
  174. package/dist/chunks/textarea.RAU710Uw.js.map +0 -1
  175. package/dist/chunks/use-cached-selected-values.DQPABFfG.js.map +0 -1
@@ -1,22 +1,22 @@
1
- import { ref as S, watch as be, computed as d, defineComponent as N, useSlots as ye, toRefs as _e, nextTick as h, useAttrs as Te, toRef as w, inject as Ne } from "vue";
2
- import { d as pe, B as Ae } from "./typography.J1v_SPG3.js";
3
- import { a as V, b as $, c as Re, B as P, D as Me } from "./dropdown-default-textbox.94q6opSD.js";
1
+ import { ref as h, watch as _e, computed as r, defineComponent as R, useSlots as ge, toRefs as Ce, nextTick as S, useAttrs as Te, toRef as w, inject as Ne } from "vue";
2
+ import { d as fe, B as Re } from "./typography.J1v_SPG3.js";
3
+ import { a as Y, b as M, c as Ae, B as W, D as Me } from "./dropdown-default-textbox.94q6opSD.js";
4
4
  /* empty css */
5
- import { n as F } from "./_plugin-vue2_normalizer.CeySl7Fu.js";
6
- import { s as J } from "./events.CMzGybJJ.js";
7
- import { g as k } from "./generate-uid.NJ8tVoha.js";
8
- import { u as $e } from "./aria-label.CaUURpnB.js";
9
- import { u as Q } from "./i18n.BQkEbtPM.js";
10
- import { a as p, b as Y, B as Z, c as Pe, u as ke, d as Fe } from "./use-cached-selected-values.DQPABFfG.js";
5
+ import { n as $ } from "./_plugin-vue2_normalizer.CeySl7Fu.js";
6
+ import { s as Z } from "./events.CMzGybJJ.js";
7
+ import { g as P } from "./generate-uid.NJ8tVoha.js";
8
+ import { u as Pe } from "./aria-label.CaUURpnB.js";
9
+ import { u as X } from "./i18n.BQkEbtPM.js";
10
+ import { a as p, b as Q, B as ve, c as $e, u as ke, d as Fe } from "./use-cached-selected-values.0EeyFfyF.js";
11
11
  import { u as Ke } from "./use-form-layout-loading.D3lALhtC.js";
12
12
  import { u as ze } from "./use-has-slot.C9lQZ6nz.js";
13
- import { B as E, a as je } from "./keyboard-navigation.pB8weElW.js";
14
- import { B as We } from "./directive.Cbdox5VL.js";
15
- import { F as Ue, E as qe } from "./error-message.BgxnwPLF.js";
16
- import { P as fe } from "./popper-container.DIFqmRsp.js";
17
- import { B as He } from "./popover.BGHbPUOr.js";
13
+ import { B as E, a as We } from "./keyboard-navigation.pB8weElW.js";
14
+ import { B as Ue } from "./directive.Cbdox5VL.js";
15
+ import { F as Ve, E as je } from "./error-message.BgxnwPLF.js";
16
+ import { P as me } from "./popper-container.DIFqmRsp.js";
17
+ import { B as qe } from "./popover.Bo4Bkudr.js";
18
18
  import "../assets/dropdown.css";
19
- const Ve = {
19
+ const He = {
20
20
  "en-US": {
21
21
  apply: "Apply",
22
22
  cancel: "Cancel",
@@ -30,20 +30,20 @@ const Ve = {
30
30
  apply: "Aplicar",
31
31
  cancel: "Cancelar"
32
32
  }
33
- }, Je = (n, t, o, e) => {
34
- const a = S(n.value), { t: l } = Q();
35
- be(n, () => {
36
- a.value = n.value;
33
+ }, Je = (a, t, o, e) => {
34
+ const n = h(a.value), { t: l } = X();
35
+ _e(a, () => {
36
+ n.value = a.value;
37
37
  });
38
- const s = d(
39
- () => JSON.stringify(a.value) === JSON.stringify(n.value)
38
+ const s = r(
39
+ () => JSON.stringify(n.value) === JSON.stringify(a.value)
40
40
  ), i = () => {
41
- e(p.SELECT, a.value), e(p.CLOSE_DROPDOWN);
41
+ e(p.SELECT, n.value), e(p.CLOSE_DROPDOWN);
42
42
  }, c = () => {
43
- a.value = n.value, e(p.CLOSE_DROPDOWN);
44
- }, b = () => {
45
- o.value && t.value && (a.value = n.value);
46
- }, r = d(() => [
43
+ n.value = a.value, e(p.CLOSE_DROPDOWN);
44
+ }, m = () => {
45
+ o.value && t.value && (n.value = a.value);
46
+ }, d = r(() => [
47
47
  {
48
48
  title: l("apply"),
49
49
  event: i,
@@ -54,7 +54,7 @@ const Ve = {
54
54
  event: c
55
55
  }
56
56
  ]), u = (y) => {
57
- a.value = y, t.value || e(p.SELECT, y);
57
+ n.value = y, t.value || e(p.SELECT, y);
58
58
  }, _ = (y) => {
59
59
  u(y), e(p.TAB);
60
60
  }, g = (y) => {
@@ -74,17 +74,17 @@ const Ve = {
74
74
  };
75
75
  return {
76
76
  // Values
77
- actions: r,
78
- internalSelectedValue: a,
77
+ actions: d,
78
+ internalSelectedValue: n,
79
79
  // Methods
80
80
  listeners: x,
81
81
  onEscapeKey: O,
82
- onOutsideDropdownClick: b
82
+ onOutsideDropdownClick: m
83
83
  };
84
- }, Ye = N({
85
- i18n: { messages: Ve },
84
+ }, Ye = R({
85
+ i18n: { messages: He },
86
86
  name: "bento-dropdown-options-container"
87
- }), Ze = /* @__PURE__ */ N({
87
+ }), Ze = /* @__PURE__ */ R({
88
88
  ...Ye,
89
89
  props: {
90
90
  /**
@@ -144,8 +144,8 @@ const Ve = {
144
144
  */
145
145
  lazyLoadType: {
146
146
  type: String,
147
- default: Z.AUTOMATIC,
148
- validator: (n) => Object.values(Z).includes(n)
147
+ default: ve.AUTOMATIC,
148
+ validator: (a) => Object.values(ve).includes(a)
149
149
  },
150
150
  /**
151
151
  * Indicates if new options are lazy loading.
@@ -175,7 +175,7 @@ const Ve = {
175
175
  *
176
176
  * If enabled, hides the "Select all" checkbox in "multiple" mode.
177
177
  */
178
- searching: Y.props.searching,
178
+ searching: Q.props.searching,
179
179
  /**
180
180
  * If enabled, dropdown will display non-selectable, static categories
181
181
  */
@@ -184,7 +184,7 @@ const Ve = {
184
184
  * Reference to the DOM element or Vue component for positioning
185
185
  * the Dropdown container.
186
186
  */
187
- targetElement: { type: fe.props.targetElement.type, required: !0 },
187
+ targetElement: { type: me.props.targetElement.type, required: !0 },
188
188
  /**
189
189
  * Enables virtual scrolling if set to true or by providing an object with itemHeight function.
190
190
  * The itemHeight function is used to calculate the height of rendered item given it's index.
@@ -195,15 +195,15 @@ const Ve = {
195
195
  }
196
196
  },
197
197
  emits: [],
198
- setup(n, { expose: t, emit: o }) {
199
- const e = n, a = ye(), { selectedValue: l, multiple: s } = _e(e), i = S(null), { t: c } = Q(), b = d(() => e.open && !e.disabled), r = d(() => c("noOptionsMatchThisSearch")), u = d(() => ({
198
+ setup(a, { expose: t, emit: o }) {
199
+ const e = a, n = ge(), { selectedValue: l, multiple: s } = Ce(e), i = h(null), { t: c } = X(), m = r(() => e.open && !e.disabled), d = r(() => c("noOptionsMatchThisSearch")), u = r(() => ({
200
200
  "b-dropdown-options-container--single": !(e != null && e.multiple)
201
- })), _ = d(() => ({
201
+ })), _ = r(() => ({
202
202
  "b-dropdown-options-container__listbox--single": !(e != null && e.multiple)
203
- })), { actions: g, internalSelectedValue: f, listeners: O, onEscapeKey: L, onOutsideDropdownClick: x } = Je(l, s, b, o), y = d(() => e != null && e.multiple ? He : fe), B = d(() => {
204
- var I;
203
+ })), { actions: g, internalSelectedValue: f, listeners: O, onEscapeKey: L, onOutsideDropdownClick: x } = Je(l, s, m, o), y = r(() => e != null && e.multiple ? qe : me), I = r(() => {
204
+ var B;
205
205
  const D = {
206
- "min-width": `${(I = e == null ? void 0 : e.targetElement) == null ? void 0 : I.clientWidth}px`,
206
+ "min-width": `${(B = e == null ? void 0 : e.targetElement) == null ? void 0 : B.clientWidth}px`,
207
207
  "max-width": "min(500px, 95%)"
208
208
  };
209
209
  return e != null && e.multiple ? {
@@ -212,7 +212,7 @@ const Ve = {
212
212
  actions: g.value,
213
213
  divider: !0,
214
214
  fallbackPosition: ["top-start"],
215
- id: k(`dropdown-options-${e.id}`),
215
+ id: P(`dropdown-options-${e.id}`),
216
216
  open: e.open,
217
217
  position: "bottom-start",
218
218
  style: {
@@ -225,7 +225,7 @@ const Ve = {
225
225
  offset: [0, 8],
226
226
  position: "bottom-start",
227
227
  style: {
228
- display: b.value ? "block" : "none",
228
+ display: m.value ? "block" : "none",
229
229
  ...D
230
230
  },
231
231
  targetElement: e.targetElement
@@ -233,19 +233,19 @@ const Ve = {
233
233
  });
234
234
  return t({
235
235
  onOutsideDropdownClick: x
236
- }), { __sfc: !0, slots: a, emit: o, props: e, selectedValue: l, multiple: s, dropdownOptionsListboxRef: i, t: c, isDropdownOpen: b, noResultsMessage: r, conditionalClasses: u, conditionalListboxClasses: _, actions: g, internalSelectedValue: f, listeners: O, onEscapeKey: L, onOutsideDropdownClick: x, popperContainerOrPopoverComponent: y, popperContainerOrPopoverProps: B, BentoListbox: Y };
236
+ }), { __sfc: !0, slots: n, emit: o, props: e, selectedValue: l, multiple: s, dropdownOptionsListboxRef: i, t: c, isDropdownOpen: m, noResultsMessage: d, conditionalClasses: u, conditionalListboxClasses: _, actions: g, internalSelectedValue: f, listeners: O, onEscapeKey: L, onOutsideDropdownClick: x, popperContainerOrPopoverComponent: y, popperContainerOrPopoverProps: I, BentoListbox: Q };
237
237
  }
238
238
  });
239
239
  var Qe = function() {
240
240
  var t = this, o = t._self._c, e = t._self._setupProxy;
241
- return o(e.popperContainerOrPopoverComponent, t._b({ tag: "component", staticClass: "b-dropdown-options-container", class: e.conditionalClasses }, "component", e.popperContainerOrPopoverProps, !1), [o("div", { on: { keydown: function(a) {
242
- return !a.type.indexOf("key") && t._k(a.keyCode, "esc", 27, a.key, ["Esc", "Escape"]) ? null : e.onEscapeKey.apply(null, arguments);
243
- } } }, [o(e.BentoListbox, t._g({ ref: "dropdownOptionsListboxRef", staticClass: "b-dropdown-options-container__listbox", class: e.conditionalListboxClasses, attrs: { id: t.id, "aria-label": t.ariaLabel, "component-loading": t.componentLoading, "empty-state": t.emptyState, "is-option-disabled": t.isOptionDisabled, items: t.items, "selected-value": e.internalSelectedValue, multiple: e.multiple, "static-categories": t.staticCategories, "no-results-message": e.noResultsMessage, searching: t.searching, loading: t.loading, "lazy-load-type": t.lazyLoadType, "has-more-items": t.hasMoreItems, "virtual-scroll": t.virtualScroll }, scopedSlots: t._u([t._l(e.slots, function(a, l) {
241
+ return o(e.popperContainerOrPopoverComponent, t._b({ tag: "component", staticClass: "b-dropdown-options-container", class: e.conditionalClasses }, "component", e.popperContainerOrPopoverProps, !1), [o("div", { on: { keydown: function(n) {
242
+ return !n.type.indexOf("key") && t._k(n.keyCode, "esc", 27, n.key, ["Esc", "Escape"]) ? null : e.onEscapeKey.apply(null, arguments);
243
+ } } }, [o(e.BentoListbox, t._g({ ref: "dropdownOptionsListboxRef", staticClass: "b-dropdown-options-container__listbox", class: e.conditionalListboxClasses, attrs: { id: t.id, "aria-label": t.ariaLabel, "component-loading": t.componentLoading, "empty-state": t.emptyState, "is-option-disabled": t.isOptionDisabled, items: t.items, "selected-value": e.internalSelectedValue, multiple: e.multiple, "static-categories": t.staticCategories, "no-results-message": e.noResultsMessage, searching: t.searching, loading: t.loading, "lazy-load-type": t.lazyLoadType, "has-more-items": t.hasMoreItems, "virtual-scroll": t.virtualScroll }, scopedSlots: t._u([t._l(e.slots, function(n, l) {
244
244
  return { key: l, fn: function(s) {
245
245
  return [t._t(l, null, null, s)];
246
246
  } };
247
247
  })], null, !0) }, e.listeners))], 1)]);
248
- }, Xe = [], Ge = /* @__PURE__ */ F(
248
+ }, Xe = [], Ge = /* @__PURE__ */ $(
249
249
  Ze,
250
250
  Qe,
251
251
  Xe,
@@ -254,34 +254,34 @@ var Qe = function() {
254
254
  "d774d15c"
255
255
  );
256
256
  const et = Ge.exports;
257
- let ve = 0;
257
+ let be = 0;
258
258
  const tt = {
259
259
  beforeCreate() {
260
- this.uuid = ve.toString(), ve += 1;
260
+ this.uuid = be.toString(), be += 1;
261
261
  }
262
262
  };
263
263
  var ot = function() {
264
264
  var t = this, o = t._self._c;
265
265
  return o("svg", t._b({ staticClass: "ui-assets-icons-16", attrs: { role: "img", xmlns: "http://www.w3.org/2000/svg", width: "16", height: "16", fill: "none" } }, "svg", t.$attrs, !1), [t.$attrs["svg-title"] ? o("title", [t._v(t._s(t.$attrs["svg-title"]))]) : t._e(), o("path", { attrs: { fill: "#001222", d: "M5.00011 5.43922L8.00011 8.43922L11.0001 5.43922L12.0608 6.49988L8.00011 10.5605L3.93945 6.49988L5.00011 5.43922Z" } })]);
266
- }, at = [], nt = /* @__PURE__ */ F(
266
+ }, nt = [], at = /* @__PURE__ */ $(
267
267
  tt,
268
268
  ot,
269
- at,
269
+ nt,
270
270
  !1,
271
271
  null,
272
272
  null
273
273
  );
274
- const st = nt.exports;
275
- let me = 0;
274
+ const st = at.exports;
275
+ let ye = 0;
276
276
  const lt = {
277
277
  beforeCreate() {
278
- this.uuid = me.toString(), me += 1;
278
+ this.uuid = ye.toString(), ye += 1;
279
279
  }
280
280
  };
281
281
  var it = function() {
282
282
  var t = this, o = t._self._c;
283
283
  return o("svg", t._b({ staticClass: "ui-assets-icons-16", attrs: { role: "img", xmlns: "http://www.w3.org/2000/svg", width: "16", height: "16", fill: "none" } }, "svg", t.$attrs, !1), [t.$attrs["svg-title"] ? o("title", [t._v(t._s(t.$attrs["svg-title"]))]) : t._e(), o("path", { attrs: { fill: "#001222", d: "M10.9999 10.5608L7.9999 7.56077L4.9999 10.5608L3.93924 9.50011L7.9999 5.43945L12.0606 9.50011L10.9999 10.5608Z" } })]);
284
- }, rt = [], dt = /* @__PURE__ */ F(
284
+ }, rt = [], dt = /* @__PURE__ */ $(
285
285
  lt,
286
286
  it,
287
287
  rt,
@@ -289,10 +289,10 @@ var it = function() {
289
289
  null,
290
290
  null
291
291
  );
292
- const ct = dt.exports, ut = N({
292
+ const ct = dt.exports, ut = R({
293
293
  name: "dropdown-small-textbox",
294
294
  inheritAttrs: !1
295
- }), pt = /* @__PURE__ */ N({
295
+ }), pt = /* @__PURE__ */ R({
296
296
  ...ut,
297
297
  props: {
298
298
  /**
@@ -353,33 +353,33 @@ const ct = dt.exports, ut = N({
353
353
  value: { type: String, default: "" }
354
354
  },
355
355
  emits: ["clear", "close", "input", "keydown", "open"],
356
- setup(n, { expose: t, emit: o }) {
357
- const e = n, a = S(null), l = d(() => ({
358
- [`b-dropdown-small-textbox--${V.DISABLED}`]: e.disabled,
359
- [`b-dropdown-small-textbox--${V.READONLY}`]: e.readonly,
360
- [`b-dropdown-small-textbox--${V.OPENED}`]: e.open
361
- })), s = d(() => e.open && !e.disabled && !e.readonly), i = (f) => {
356
+ setup(a, { expose: t, emit: o }) {
357
+ const e = a, n = h(null), l = r(() => ({
358
+ [`b-dropdown-small-textbox--${Y.DISABLED}`]: e.disabled,
359
+ [`b-dropdown-small-textbox--${Y.READONLY}`]: e.readonly,
360
+ [`b-dropdown-small-textbox--${Y.OPENED}`]: e.open
361
+ })), s = r(() => e.open && !e.disabled && !e.readonly), i = (f) => {
362
362
  o("input", f);
363
363
  }, c = (f) => {
364
364
  o("keydown", f);
365
- }, b = (f) => {
366
- J(f), o("open");
367
- }, r = (f) => {
368
- J(f), o("close");
365
+ }, m = (f) => {
366
+ Z(f), o("open");
367
+ }, d = (f) => {
368
+ Z(f), o("close");
369
369
  }, u = (f) => {
370
- J(f), o("clear");
370
+ Z(f), o("clear");
371
371
  }, _ = {
372
- [$.INPUT]: i,
373
- [$.OPEN]: b,
374
- [$.CLOSE]: r,
375
- [$.CLEAR]: u,
376
- [$.KEYDOWN]: c
372
+ [M.INPUT]: i,
373
+ [M.OPEN]: m,
374
+ [M.CLOSE]: d,
375
+ [M.CLEAR]: u,
376
+ [M.KEYDOWN]: c
377
377
  }, g = () => {
378
- a.value.focus();
378
+ n.value.focus();
379
379
  };
380
380
  return t({
381
381
  focus: g
382
- }), { __sfc: !0, emit: o, props: e, baseTextbox: a, conditionalClasses: l, isDropdownOpen: s, onInput: i, onKeyDown: c, openDropdown: b, closeDropdown: r, clearValue: u, listeners: _, focus: g, BentoDropdownSize: P, DropdownBaseTextbox: Re, ChevronDownSmallIcon: st, ChevronUpSmallIcon: ct };
382
+ }), { __sfc: !0, emit: o, props: e, baseTextbox: n, conditionalClasses: l, isDropdownOpen: s, onInput: i, onKeyDown: c, openDropdown: m, closeDropdown: d, clearValue: u, listeners: _, focus: g, BentoDropdownSize: W, DropdownBaseTextbox: Ae, ChevronDownSmallIcon: st, ChevronUpSmallIcon: ct };
383
383
  }
384
384
  });
385
385
  var ft = function() {
@@ -387,7 +387,7 @@ var ft = function() {
387
387
  return o("div", { staticClass: "b-dropdown-small-textbox", class: e.conditionalClasses }, [o(e.DropdownBaseTextbox, t._g(t._b({ ref: "baseTextbox", staticClass: "b-dropdown-small-textbox__textbox", attrs: { size: e.BentoDropdownSize.SMALL }, scopedSlots: t._u([{ key: "icon", fn: function() {
388
388
  return [o("div", { staticClass: "b-dropdown-small-textbox__chevron" }, [o(e.ChevronUpSmallIcon, { directives: [{ name: "show", rawName: "v-show", value: e.isDropdownOpen, expression: "isDropdownOpen" }], attrs: { "svg-title": "opened" } }), o(e.ChevronDownSmallIcon, { directives: [{ name: "show", rawName: "v-show", value: !e.isDropdownOpen, expression: "!isDropdownOpen" }], attrs: { "svg-title": "closed" } })], 1)];
389
389
  }, proxy: !0 }]) }, "dropdown-base-textbox", { ...t.$attrs, ...t.$props }, !1), e.listeners))], 1);
390
- }, vt = [], mt = /* @__PURE__ */ F(
390
+ }, vt = [], mt = /* @__PURE__ */ $(
391
391
  pt,
392
392
  ft,
393
393
  vt,
@@ -395,92 +395,92 @@ var ft = function() {
395
395
  null,
396
396
  "d0e53db8"
397
397
  );
398
- const bt = mt.exports, yt = (n, t) => t.value.reduce((o, e) => {
398
+ const bt = mt.exports, yt = (a, t) => t.value.reduce((o, e) => {
399
399
  if (e.items) {
400
- const a = e.items.filter(
401
- (s) => n.value.find((i) => i.value === s.value)
400
+ const n = e.items.filter(
401
+ (s) => a.value.find((i) => i.value === s.value)
402
402
  );
403
- a.length === e.items.length ? o.push(e.displayValue ?? e.label) : a.forEach(({ label: s, displayValue: i }) => o.push(i ?? s));
403
+ n.length === e.items.length ? o.push(e.displayValue ?? e.label) : n.forEach(({ label: s, displayValue: i }) => o.push(i ?? s));
404
404
  }
405
- return n.value.find((a) => a.value === e.value) && o.push(e.displayValue ?? e.label), o;
406
- }, []).join(", "), _t = ({ items: n, placeholder: t, selectedValues: o, isMultiSelect: e }) => {
407
- const a = d(
408
- () => e.value && n.value.find((s) => {
405
+ return a.value.find((n) => n.value === e.value) && o.push(e.displayValue ?? e.label), o;
406
+ }, []).join(", "), _t = ({ items: a, placeholder: t, selectedValues: o, isMultiSelect: e }) => {
407
+ const n = r(
408
+ () => e.value && a.value.find((s) => {
409
409
  var i;
410
410
  return (i = s.items) == null ? void 0 : i.length;
411
411
  })
412
412
  );
413
- return d(() => o.value.length ? a.value ? yt(o, n) : o.value.map(({ label: s, displayValue: i }) => i ?? s).join(", ") : t.value || null);
414
- }, ge = (n) => {
413
+ return r(() => o.value.length ? n.value ? yt(o, a) : o.value.map(({ label: s, displayValue: i }) => i ?? s).join(", ") : t.value || null);
414
+ }, he = (a) => {
415
415
  var t;
416
- (t = n.value.$children) == null || t[0].$refs.textbox.focus();
416
+ (t = a.value.$children) == null || t[0].$refs.textbox.focus();
417
417
  }, gt = ({
418
- inputContainerRef: n,
418
+ inputContainerRef: a,
419
419
  optionsContainerRef: t,
420
420
  selectedValueIndex: o,
421
421
  isDropdownOpen: e,
422
- isDynamicFltering: a,
422
+ isDynamicFltering: n,
423
423
  items: l,
424
424
  isMultiple: s
425
- }, i, c, b) => {
426
- const r = async (m) => {
425
+ }, i, c, m) => {
426
+ const d = async (b) => {
427
427
  var C;
428
- a.value && await h(), (C = l.value[m]) == null || C.focus();
429
- }, u = async (m) => {
430
- var K, A;
431
- a.value && await h();
432
- const C = (K = t.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef) == null ? void 0 : K.$el.querySelectorAll(
428
+ n.value && await S(), (C = l.value[b]) == null || C.focus();
429
+ }, u = async (b) => {
430
+ var F, K;
431
+ n.value && await S();
432
+ const C = (F = t.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef) == null ? void 0 : F.$el.querySelectorAll(
433
433
  "button"
434
434
  );
435
- C.length ? (A = C[m]) == null || A.focus() : r(m);
436
- }, _ = (m) => {
435
+ C.length ? (K = C[b]) == null || K.focus() : d(b);
436
+ }, _ = (b) => {
437
437
  var C;
438
438
  return (C = t.value.$refs.dropdownOptionsListboxRef.$refs.listboxItemRef) == null ? void 0 : C.setListboxFocusedIndex(
439
- m
439
+ b
440
440
  );
441
- }, g = ({ detail: m }) => {
442
- m.preventDefault(), e.value || c(), h(() => {
443
- s ? u(0) : (_(o.value), r(o.value));
441
+ }, g = () => {
442
+ e.value || c(), S(() => {
443
+ _(0), d(0);
444
444
  });
445
- }, f = ({ detail: m }) => {
446
- m.preventDefault(), e.value || c(), h(() => {
447
- s ? u(0) : (_(o.value), r(o.value));
445
+ }, f = () => {
446
+ e.value || c(), S(() => {
447
+ _(l.value.length - 1), d(l.value.length - 1);
448
448
  });
449
- }, O = () => {
450
- e.value || (c(), h(() => {
451
- _(l.value.length - 1), r(l.value.length - 1);
452
- }));
453
- }, L = () => {
454
- e.value && (b(), ge(n));
449
+ }, O = ({ detail: b }) => {
450
+ b.preventDefault(), g();
451
+ }, L = ({ detail: b }) => {
452
+ b.preventDefault(), f();
455
453
  }, x = () => {
456
- e.value && b();
454
+ g();
457
455
  }, y = () => {
458
- e.value || c(), h(() => {
459
- r(0);
456
+ f();
457
+ }, I = ({ detail: b }) => {
458
+ b.preventDefault(), i(), e.value && S(() => {
459
+ s ? u(0) : (_(o.value), d(o.value));
460
460
  });
461
- }, B = ({ detail: m }) => {
462
- m.preventDefault(), i(), e.value && h(() => {
463
- s ? u(0) : (_(o.value), r(o.value));
464
- });
465
- }, D = ({ detail: m }) => {
466
- m.preventDefault(), i(), e.value && h(() => {
467
- s ? u(0) : (_(o.value), r(o.value));
461
+ }, D = ({ detail: b }) => {
462
+ b.preventDefault(), i(), e.value && S(() => {
463
+ s ? u(0) : (_(o.value), d(o.value));
468
464
  });
465
+ }, B = () => {
466
+ e.value && m();
467
+ }, k = () => {
468
+ e.value && (m(), he(a));
469
469
  };
470
- return d(() => ({
471
- ...a.value ? {} : { [E.SPACE]: B },
470
+ return r(() => ({
471
+ [E.ARROW_DOWN]: O,
472
+ [E.ARROW_UP]: L,
473
+ [E.HOME]: x,
474
+ [E.END]: y,
475
+ ...n.value ? {} : { [E.SPACE]: I },
472
476
  [E.ENTER]: D,
473
- [E.ARROW_DOWN]: g,
474
- [E.ARROW_UP]: f,
475
- [E.END]: O,
476
- [E.ESCAPE]: L,
477
- [E.HOME]: y,
478
- [E.TAB]: x
477
+ [E.TAB]: B,
478
+ [E.ESCAPE]: k
479
479
  }));
480
- }, Ct = ({ inputContainerRef: n, isDropdownOpen: t }, o) => {
480
+ }, Ct = ({ inputContainerRef: a, isDropdownOpen: t }, o) => {
481
481
  const e = () => {
482
- t.value && o(), h(() => {
483
- ge(n);
482
+ t.value && o(), S(() => {
483
+ he(a);
484
484
  });
485
485
  };
486
486
  return {
@@ -490,18 +490,18 @@ const bt = mt.exports, yt = (n, t) => t.value.reduce((o, e) => {
490
490
  [p.SPACE]: e
491
491
  };
492
492
  };
493
- function ht(n, t, o, e) {
494
- const a = S(n), l = S(t), s = (c, b = []) => b.flatMap((r) => r.label.toLocaleLowerCase().includes(c) ? e != null && e.value && r.items ? [...s(c, r.items)] : [r, ...s(c, r.items)] : r.items ? [...s(c, r.items)] : []);
495
- return be(a, () => {
496
- o !== void 0 && o(a.value);
497
- }), d(() => {
498
- if (!a.value || o !== void 0)
493
+ function ht(a, t, o, e) {
494
+ const n = h(a), l = h(t), s = (c, m = []) => m.flatMap((d) => d.label.toLocaleLowerCase().includes(c) ? e != null && e.value && d.items ? [...s(c, d.items)] : [d, ...s(c, d.items)] : d.items ? [...s(c, d.items)] : []);
495
+ return _e(n, () => {
496
+ o !== void 0 && o(n.value);
497
+ }), r(() => {
498
+ if (!n.value || o !== void 0)
499
499
  return l.value;
500
- const c = a.value.toLocaleLowerCase();
500
+ const c = n.value.toLocaleLowerCase();
501
501
  return s(c, l.value);
502
502
  });
503
503
  }
504
- const St = {
504
+ const wt = {
505
505
  "en-US": {
506
506
  all: "All",
507
507
  ariaLabelFallback: "Dropdown",
@@ -515,270 +515,127 @@ const St = {
515
515
  all: "Todos",
516
516
  clearFilter: "Limpar filtro"
517
517
  }
518
- }, wt = Symbol("input field component injection key"), Ht = Symbol("input field hint injection key"), Vt = Symbol("input field parent component injection key"), Lt = N({
519
- i18n: { messages: St },
518
+ }, Lt = Symbol("input field component injection key"), qt = Symbol("input field hint injection key"), Ht = Symbol("input field parent component injection key"), xt = R({
519
+ i18n: { messages: wt },
520
520
  name: "b-dropdown",
521
521
  components: {
522
522
  DropdownInputDefault: Me,
523
523
  DropdownInputSmall: bt
524
524
  }
525
- }), xt = /* @__PURE__ */ N({
526
- ...Lt,
525
+ }), St = /* @__PURE__ */ R({
526
+ ...xt,
527
527
  props: {
528
- /**
529
- * @deprecated from version 2.0.0. Use the aria-label attribute instead.
530
- */
531
- /**
532
- * Defines a string value that labels an interactive element.
533
- */
534
- ariaLabel: { type: String, default: null },
535
- /**
536
- * Renders the dropdown with a condensed style.
537
- */
528
+ ariaLabel: { default: null },
538
529
  condensed: { type: Boolean, default: !1 },
539
- /**
540
- * Empty state props used with the inner empty state component which is displayed when no search results are found.
541
- */
542
- emptyState: {
543
- type: Object,
544
- default: void 0
545
- },
546
- /**
547
- * Disables dropdown functionality.
548
- */
530
+ emptyState: { default: void 0 },
549
531
  disabled: { type: Boolean, default: !1 },
550
- /**
551
- * Sets the possibility to type into the textbox.
552
- */
553
- dynamicFiltering: {
554
- type: Boolean,
555
- default: !1
556
- },
557
- /**
558
- * Highlights the dropdown in an erroneous state.
559
- *
560
- * @deprecated Use "errorMessage" prop instead
561
- */
532
+ dynamicFiltering: { type: Boolean, default: !1 },
562
533
  error: { type: Boolean, default: !1 },
563
- /**
564
- * Highlights the dropdown in an erroneous state with an error message.
565
- */
566
- errorMessage: { type: String, default: null },
567
- /**
568
- * Descriptive supporting text visbile underneath the dropdown.
569
- */
570
- description: { type: String, default: null },
571
- /**
572
- * Indicates whether there are more items to load
573
- */
534
+ errorMessage: { default: null },
535
+ description: { default: null },
574
536
  hasMoreItems: { type: Boolean, default: !1 },
575
- /**
576
- * Function that dertermines which options are disabled from interaction.
577
- *
578
- * @type {BentoListboxIsOptionDisabled}
579
- * @param {BentoListboxOptionItem} option - Dropdown option object
580
- * @param {string} option.label - Option's label text
581
- * @param {string|number} option.value - Option's value
582
- * @param {unknown} option.data - Option's extra data to be passed to the default slot
583
- */
584
- isOptionDisabled: {
585
- type: Function,
586
- default: void 0
587
- },
588
- /**
589
- * The option elements to populate the dropdown with.
590
- * It must be an array of {@see BentoListboxOptionItem }
591
- * * @property {string} value.label - Text to be displayed in the option
592
- * * @property {string,number} value.value - Value of the option
593
- */
594
- items: {
595
- type: Array,
596
- default: () => []
597
- },
598
- /**
599
- * Text that is displayed as a label above the element.
600
- */
601
- label: { type: String, default: null },
602
- /**
603
- * Indicates if new options are lazy loading.
604
- */
537
+ isOptionDisabled: { default: void 0 },
538
+ items: { default: () => [] },
539
+ label: { default: null },
605
540
  loading: { type: Boolean, default: !1 },
606
- /**
607
- * Indicates that dropdown items are loading
608
- */
609
541
  componentLoading: { type: Boolean, default: !1 },
610
- /**
611
- * The type of `Lazy Load`.
612
- * Type "automatic" will enable infinite scrolling
613
- * Type "button" will enable lazy loading with "Show more" button
614
- */
615
- lazyLoadType: {
616
- type: String,
617
- default: Y.props.lazyLoadType.default,
618
- validator: (n) => Object.values(Z).includes(n)
619
- },
620
- /*
621
- * If enabled, the user will be able to select multiple items.
622
- */
542
+ lazyLoadType: { default: Q.props.lazyLoadType.default },
623
543
  multiple: { type: Boolean, default: !1 },
624
- /**
625
- * Highlights the dropdown is optional.
626
- */
627
544
  optional: { type: Boolean, default: !1 },
628
- /**
629
- * Text that appears in the form control when it has no value set
630
- */
631
- placeholder: { type: String, default: null },
632
- /**
633
- * Sets the dropdown to readonly state
634
- */
545
+ placeholder: { default: null },
635
546
  readonly: { type: Boolean, default: !1 },
636
- /**
637
- * Highlights the dropdown is required.
638
- */
639
547
  required: { type: Boolean, default: !1 },
640
- /**
641
- * Dropdown search options and events.
642
- * @see BentoDropdownSearchOptions
643
- */
644
- search: {
645
- type: Object,
646
- default: void 0
647
- },
648
- /**
649
- * Toggles whether to use the slot content select items shown in the textbox in multiple mode.
650
- */
548
+ search: { default: void 0 },
651
549
  showSlotContentInMultiple: { type: Boolean, default: !1 },
652
- /**
653
- * @deprecated Do not use. Only 'default' size should be used.
654
- */
655
- size: {
656
- type: String,
657
- default: null,
658
- validator: (n) => Object.values(P).includes(n)
659
- },
660
- /**
661
- * If enabled, dropdown will display non-selectable, static categories
662
- */
550
+ size: { default: null },
663
551
  staticCategories: { type: Boolean, default: !1 },
664
- /**
665
- * Adds a info icon next to the label to display the passed tooltip message.
666
- */
667
- tooltipText: { type: String, default: null },
668
- /**
669
- * The `input` value.
670
- * Providing an empty string will select no options.
671
- * Set to an empty string `''` if you don't want any of the available options to be selected.
672
- */
673
- value: {
674
- type: [String, Number, Array, Object],
675
- default: null
676
- },
677
- /**
678
- * Enables virtual scrolling if set to true or by providing an object with itemHeight function.
679
- * The itemHeight function is used to calculate the height of rendered item given it's index.
680
- */
681
- virtualScroll: {
682
- type: [Boolean, Object],
683
- default: !1
684
- },
685
- /**
686
- * Enables value/label value handling. When `true`, the component expects and emits value/label
687
- * pair objects instead of primitive values.
688
- *
689
- * This affects both the `value` prop and the `input` event payload.
690
- *
691
- * - **Input (`value` prop):** Expects a `{ value: string | number, label: string }` object (or an array of them for multi-select).
692
- * - **Output (`input` event):** Emits a `{ value: string | number, label: string }` object (or an array of them) upon selection.
693
- *
694
- * This is particularly useful when a selected item's label is not available in the `items` prop,
695
- * allowing the component to display the correct label for values loaded from external sources.
696
- * @default false
697
- */
552
+ tooltipText: { default: null },
553
+ value: { default: null },
554
+ virtualScroll: { default: !1 },
698
555
  enableValueLabelPair: { type: Boolean, default: !1 }
699
556
  },
700
557
  emits: ["input", "show-more"],
701
- setup(n, { expose: t, emit: o }) {
702
- var ue;
703
- const e = n, a = Te(), l = ye(), s = ze(l), { t: i } = Q(), c = S(null), b = S(null), r = S(null), u = S(!1), _ = k("bento-dropdown-options-container"), g = k("dropdown-label"), f = k("dropdown-description"), O = k("dropdown-error"), { isReadOnly: L } = Ke(w(e, "readonly")), { cachedSelectedListboxOptions: x, cachedListboxSelectedValues: y, setCachedValues: B } = Pe(
558
+ setup(a, { expose: t, emit: o }) {
559
+ var pe;
560
+ const e = a, n = Te(), l = ge(), s = ze(l), { t: i } = X(), c = h(null), m = h(null), d = h(null), u = h(!1), _ = P("bento-dropdown-options-container"), g = P("dropdown-label"), f = P("dropdown-description"), O = P("dropdown-error"), { isReadOnly: L } = Ke(w(e, "readonly")), { cachedSelectedListboxOptions: x, cachedListboxSelectedValues: y, setCachedValues: I } = $e(
704
561
  w(e, "items"),
705
562
  w(e, "value"),
706
563
  w(e, "multiple"),
707
564
  w(e, "enableValueLabelPair")
708
- ), D = S(a["aria-label"]), { ariaLabel: I, label: m } = _e(e), C = d(() => i("ariaLabelFallback")), K = $e({
565
+ ), D = h(n["aria-label"]), { ariaLabel: B, label: k } = Ce(e), U = r(() => i("ariaLabelFallback")), b = Pe({
709
566
  // TODO: take ariaLabel ref away when aria-label prop is removed
710
- ariaLabel: I.value || D,
711
- label: m,
712
- defaultFallback: C
713
- }), A = e.size === P.SMALL || Ne(wt, !1), Ce = d(() => A ? P.SMALL : P.DEFAULT), he = d(() => ({
567
+ ariaLabel: B.value || D,
568
+ label: k,
569
+ defaultFallback: U
570
+ }), C = e.size === W.SMALL || Ne(Lt, !1), F = r(() => C ? W.SMALL : W.DEFAULT), K = r(() => ({
714
571
  "b-dropdown--condensed": e.condensed
715
- })), Se = d(() => ({
572
+ })), we = r(() => ({
716
573
  "b-dropdown__description--error": !!e.errorMessage
717
- })), T = S(""), R = w(e, "items"), X = w(e, "staticCategories"), j = ht(T, R, (ue = e == null ? void 0 : e.search) == null ? void 0 : ue.searchEvent, X), W = d(() => e.dynamicFiltering && !!T.value), we = _t({
718
- items: R,
574
+ })), T = h(""), A = w(e, "items"), G = w(e, "staticCategories"), V = ht(T, A, (pe = e == null ? void 0 : e.search) == null ? void 0 : pe.searchEvent, G), j = r(() => e.dynamicFiltering && !!T.value), Le = _t({
575
+ items: A,
719
576
  placeholder: w(e, "placeholder"),
720
577
  isMultiSelect: w(e, "multiple"),
721
578
  selectedValues: x
722
- }), Le = d(() => {
579
+ }), xe = r(() => {
723
580
  if (e != null && e.multiple && Array.isArray(e.value))
724
581
  return e.items.filter(
725
582
  ({ value: v }) => (e == null ? void 0 : e.value) && (e == null ? void 0 : e.value).includes(v)
726
583
  );
727
584
  if (!e.multiple && e.staticCategories) {
728
585
  const v = e.items.find(
729
- (H) => H.items.some((Ie) => Ie.value === e.value)
586
+ (J) => J.items.some((Ie) => Ie.value === e.value)
730
587
  );
731
- return v ? v.items.find((H) => H.value === e.value) : null;
588
+ return v ? v.items.find((J) => J.value === e.value) : null;
732
589
  }
733
590
  return e.items.find(({ value: v }) => v === (e == null ? void 0 : e.value));
734
- }), G = d(() => {
735
- const v = j.value.findIndex(({ value: M }) => e.value === M);
591
+ }), ee = r(() => {
592
+ const v = V.value.findIndex(({ value: N }) => e.enableValueLabelPair ? e.value.value === N : e.value === N);
736
593
  return v > -1 ? v : 0;
737
- }), { isMultiLevelSelect: U, flattenedItemsList: ee } = ke(R), te = d(() => U.value && !e.staticCategories), oe = d(() => te.value ? "treeitem" : "option"), xe = d(() => {
594
+ }), { isMultiLevelSelect: q, flattenedItemsList: te } = ke(A), oe = r(() => q.value && !e.staticCategories), ne = r(() => oe.value ? "treeitem" : "option"), Se = r(() => {
738
595
  if (e.multiple) {
739
- const v = Array.isArray(e.value) ? e.value.length : 0, M = U.value ? ee.value.length : R.value.length;
740
- return v === 0 ? null : !e.hasMoreItems && M > 0 && M === v ? i("all") : v;
596
+ const v = Array.isArray(e.value) ? e.value.length : 0, N = q.value ? te.value.length : A.value.length;
597
+ return v === 0 ? null : !e.hasMoreItems && N > 0 && N === v ? i("all") : v;
741
598
  }
742
599
  return null;
743
- }), Oe = d(
600
+ }), Oe = r(
744
601
  () => `${e.description ? f : ""} ${e.errorMessage ? O : ""}`.trim() || null
745
- ), ae = d(() => {
602
+ ), ae = r(() => {
746
603
  var v;
747
- return (v = r.value) == null ? void 0 : v.$el;
748
- }), { visibleDomOptions: ne, updateVisibleDomOptions: q } = Fe(
604
+ return (v = d.value) == null ? void 0 : v.$el;
605
+ }), { visibleDomOptions: se, updateVisibleDomOptions: H } = Fe(
749
606
  ae,
750
- j,
751
- oe
752
- ), se = () => {
753
- L.value || (u.value = !0, h(() => {
754
- q();
607
+ V,
608
+ ne
609
+ ), le = () => {
610
+ L.value || (u.value = !0, S(() => {
611
+ H();
755
612
  }));
756
613
  }, z = () => {
757
614
  u.value = !1;
758
- }, le = () => {
759
- L.value || (u.value = !u.value, h(() => {
760
- q();
761
- }), W.value && (T.value = ""));
615
+ }, ie = () => {
616
+ L.value || (u.value = !u.value, S(() => {
617
+ H();
618
+ }), j.value && (T.value = ""));
762
619
  }, Ee = () => {
763
- W.value && (T.value = ""), u.value && (u.value = !1, r.value.onOutsideDropdownClick());
764
- }, ie = (v) => {
765
- e.multiple || (T.value = "", u.value = !1), B(v), o("input", y.value);
766
- }, re = () => {
620
+ j.value && (T.value = ""), u.value && (u.value = !1, d.value.onOutsideDropdownClick());
621
+ }, re = (v) => {
622
+ e.multiple || (T.value = "", u.value = !1), I(v), o("input", y.value);
623
+ }, de = () => {
767
624
  o(p.SHOW_MORE);
768
625
  }, De = gt(
769
626
  {
770
627
  inputContainerRef: c,
771
- optionsContainerRef: r,
772
- selectedValueIndex: G,
628
+ optionsContainerRef: d,
629
+ selectedValueIndex: ee,
773
630
  isDropdownOpen: u,
774
631
  isDynamicFltering: w(e, "dynamicFiltering"),
775
- items: ne,
632
+ items: se,
776
633
  isMultiple: e.multiple
777
634
  },
635
+ ie,
778
636
  le,
779
- se,
780
637
  z
781
- ), de = Ct(
638
+ ), ce = Ct(
782
639
  {
783
640
  inputContainerRef: c,
784
641
  isDropdownOpen: u
@@ -786,27 +643,27 @@ const St = {
786
643
  z
787
644
  ), Be = {
788
645
  [p.CLOSE_DROPDOWN]: z,
789
- [p.SELECT]: ie,
790
- [p.SHOW_MORE]: re,
791
- ...de
646
+ [p.SELECT]: re,
647
+ [p.SHOW_MORE]: de,
648
+ ...ce
792
649
  };
793
- e.error && pe(
650
+ e.error && fe(
794
651
  'BentoDropdown "error" property',
795
652
  `Use the BentoDropdown "errorMessage" property instead to indicate that there is a modifier error.
796
653
  Having the field as "undefined" will hide/remove the error.
797
654
  <bento-dropdown errorMessage="Error message text" />`,
798
655
  "2.0.0"
799
- ), e.size && pe('BentoDropdown "size" property', "Do not use. Only 'default' size should be used.", "2.0.0");
800
- const ce = () => {
656
+ ), e.size && fe('BentoDropdown "size" property', "Do not use. Only 'default' size should be used.", "2.0.0");
657
+ const ue = () => {
801
658
  c.value.focus();
802
659
  };
803
660
  return t({
804
- focus: ce
805
- }), { __sfc: !0, attrs: a, slots: l, hasSlot: s, props: e, emit: o, t: i, inputContainerRef: c, inputContainerRefWrapper: b, optionsContainerRef: r, isDropdownOpen: u, dropdownOptionsContainerId: _, labelId: g, descriptionId: f, errorId: O, isReadOnly: L, cachedSelectedListboxOptions: x, cachedListboxSelectedValues: y, setCachedValues: B, ariaLabelAttribute: D, ariaLabel: I, label: m, computedAriaLabelFallbackMessage: C, computedAriaLabel: K, isInputComponent: A, computedSize: Ce, conditionalClasses: he, descriptionConditionalClasses: Se, searchTerm: T, items: R, staticCategories: X, filteredItems: j, isSearching: W, displayValue: we, selectedValueItem: Le, selectedValueIndex: G, isMultiLevelSelect: U, flattenedItemsList: ee, isTreePattern: te, computedOptionRole: oe, additionalItemsSelected: xe, ariaDescribedBy: Oe, listboxRef: ae, visibleDomOptions: ne, updateVisibleDomOptions: q, openDropdown: se, closeDropdown: z, toggleDropdown: le, clickOutsideDropdown: Ee, onOptionSelected: ie, emitShowMoreEvent: re, textboxKeyboardNavigationListeners: De, listboxKeyboardNavigationListeners: de, listboxListeners: Be, focus: ce, BentoDropdownOptionsContainer: et, BentoTypography: Ae, ErrorMessage: qe, FieldLabel: Ue, vBentoClickOutsideDirective: We, vBentoKeyboardNavigationDirective: je };
661
+ focus: ue
662
+ }), { __sfc: !0, attrs: n, slots: l, hasSlot: s, props: e, emit: o, t: i, inputContainerRef: c, inputContainerRefWrapper: m, optionsContainerRef: d, isDropdownOpen: u, dropdownOptionsContainerId: _, labelId: g, descriptionId: f, errorId: O, isReadOnly: L, cachedSelectedListboxOptions: x, cachedListboxSelectedValues: y, setCachedValues: I, ariaLabelAttribute: D, ariaLabel: B, label: k, computedAriaLabelFallbackMessage: U, computedAriaLabel: b, isInputComponent: C, computedSize: F, conditionalClasses: K, descriptionConditionalClasses: we, searchTerm: T, items: A, staticCategories: G, filteredItems: V, isSearching: j, displayValue: Le, selectedValueItem: xe, selectedValueIndex: ee, isMultiLevelSelect: q, flattenedItemsList: te, isTreePattern: oe, computedOptionRole: ne, additionalItemsSelected: Se, ariaDescribedBy: Oe, listboxRef: ae, visibleDomOptions: se, updateVisibleDomOptions: H, openDropdown: le, closeDropdown: z, toggleDropdown: ie, clickOutsideDropdown: Ee, onOptionSelected: re, emitShowMoreEvent: de, textboxKeyboardNavigationListeners: De, listboxKeyboardNavigationListeners: ce, listboxListeners: Be, focus: ue, BentoDropdownOptionsContainer: et, BentoTypography: Re, ErrorMessage: je, FieldLabel: Ve, vBentoClickOutsideDirective: Ue, vBentoKeyboardNavigationDirective: We };
806
663
  }
807
664
  });
808
665
  var Ot = function() {
809
- var a;
666
+ var n;
810
667
  var t = this, o = t._self._c, e = t._self._setupProxy;
811
668
  return o("div", { directives: [{ name: "bento-click-outside-directive", rawName: "v-bento-click-outside-directive", value: e.clickOutsideDropdown, expression: "clickOutsideDropdown" }], staticClass: "b-dropdown", class: e.conditionalClasses }, [e.label ? o(e.FieldLabel, { attrs: { id: e.labelId, condensed: t.condensed, label: e.label, "tooltip-text": t.tooltipText, optional: t.optional, required: t.required } }) : t._e(), o("div", t._g({ directives: [{ name: "bento-keyboard-navigation-directive", rawName: "v-bento-keyboard-navigation-directive" }], ref: "inputContainerRefWrapper" }, e.textboxKeyboardNavigationListeners), [o(e.computedSize, { ref: "inputContainerRef", tag: "component", attrs: { condensed: t.condensed, value: e.searchTerm, "additional-items-selected": e.additionalItemsSelected, "aria-controls": e.dropdownOptionsContainerId, ariaExpanded: e.isDropdownOpen, "aria-labelledby": e.label ? e.labelId : null, "aria-describedby": e.ariaDescribedBy, "aria-label": e.computedAriaLabel, "aria-readonly": e.isReadOnly, readonly: e.isReadOnly, disabled: t.disabled, "display-value": e.displayValue, "dynamic-filtering": t.dynamicFiltering, "is-invalid": !!t.errorMessage || t.error, multiple: t.multiple, open: e.isDropdownOpen, "selected-value-item": e.isInputComponent ? void 0 : e.selectedValueItem, "show-slot-content-in-multiple": t.showSlotContentInMultiple }, on: { input: function(l) {
812
669
  e.searchTerm = l;
@@ -814,27 +671,27 @@ var Ot = function() {
814
671
  return { key: s, fn: function(i) {
815
672
  return [t._t(s, null, null, i)];
816
673
  } };
817
- })], null, !0) })], 1), e.inputContainerRef ? o(e.BentoDropdownOptionsContainer, t._g({ ref: "optionsContainerRef", attrs: { id: e.dropdownOptionsContainerId, "aria-label": e.computedAriaLabel, "component-loading": t.componentLoading, "empty-state": t.emptyState, "debounce-time": (a = t.search) == null ? void 0 : a.debounceTime, disabled: t.disabled, "is-option-disabled": t.isOptionDisabled, items: e.filteredItems, multiple: t.multiple, "static-categories": e.staticCategories, open: e.isDropdownOpen, "selected-value": e.cachedSelectedListboxOptions, searching: e.isSearching, "target-element": e.inputContainerRefWrapper, loading: t.loading, "has-more-items": t.hasMoreItems, "lazy-load-type": t.lazyLoadType, "virtual-scroll": t.virtualScroll }, scopedSlots: t._u([t._l(e.slots, function(l, s) {
674
+ })], null, !0) })], 1), e.inputContainerRef ? o(e.BentoDropdownOptionsContainer, t._g({ ref: "optionsContainerRef", attrs: { id: e.dropdownOptionsContainerId, "aria-label": e.computedAriaLabel, "component-loading": t.componentLoading, "empty-state": t.emptyState, "debounce-time": (n = t.search) == null ? void 0 : n.debounceTime, disabled: t.disabled, "is-option-disabled": t.isOptionDisabled, items: e.filteredItems, multiple: t.multiple, "static-categories": e.staticCategories, open: e.isDropdownOpen, "selected-value": e.cachedSelectedListboxOptions, searching: e.isSearching, "target-element": e.inputContainerRefWrapper, loading: t.loading, "has-more-items": t.hasMoreItems, "lazy-load-type": t.lazyLoadType, "virtual-scroll": t.virtualScroll }, scopedSlots: t._u([t._l(e.slots, function(l, s) {
818
675
  return { key: s, fn: function(i) {
819
676
  return [t._t(s, null, null, i)];
820
677
  } };
821
678
  })], null, !0) }, e.listboxListeners)) : t._e(), t.errorMessage ? o(e.ErrorMessage, { staticClass: "b-dropdown__error-message", attrs: { id: e.errorId, "error-message": t.errorMessage } }) : t._e(), t.description || e.hasSlot("description") ? o(e.BentoTypography, { staticClass: "b-dropdown__description", class: e.descriptionConditionalClasses, attrs: { id: e.descriptionId, el: "span" } }, [t._t("description", function() {
822
679
  return [t._v(" " + t._s(t.description) + " ")];
823
680
  })], 2) : t._e()], 1);
824
- }, Et = [], Dt = /* @__PURE__ */ F(
825
- xt,
681
+ }, Et = [], Dt = /* @__PURE__ */ $(
682
+ St,
826
683
  Ot,
827
684
  Et,
828
685
  !1,
829
686
  null,
830
- "0a1282c1"
687
+ "b8f9ffa8"
831
688
  );
832
689
  const Jt = Dt.exports;
833
690
  export {
834
691
  Jt as B,
835
- Ht as I,
836
- wt as a,
837
- Vt as b,
692
+ qt as I,
693
+ Lt as a,
694
+ Ht as b,
838
695
  ht as u
839
696
  };
840
- //# sourceMappingURL=dropdown.HA6ISg2h.js.map
697
+ //# sourceMappingURL=dropdown.DazYAy4B.js.map