@quidgest/ui 0.29.0 → 0.30.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 (245) hide show
  1. package/CHANGELOG.md +59 -0
  2. package/README.md +2 -20
  3. package/dist/json/api.json +1059 -803
  4. package/dist/ui.css +77 -29
  5. package/dist/ui.esm.js +1093 -994
  6. package/dist/ui.min.css +1 -1
  7. package/dist/ui.scss +75 -24
  8. package/esm/components/QAccordion/QAccordion.d.ts.map +1 -1
  9. package/esm/components/QAccordion/QAccordion.vue.js +2 -0
  10. package/esm/components/QAccordion/QAccordionItem.d.ts.map +1 -1
  11. package/esm/components/QAccordion/QAccordionItem.vue.js +3 -0
  12. package/esm/components/QAccordion/index.d.ts +3 -0
  13. package/esm/components/QAccordion/index.d.ts.map +1 -1
  14. package/esm/components/QAccordion/types.d.ts +8 -0
  15. package/esm/components/QAccordion/types.d.ts.map +1 -1
  16. package/esm/components/QAlert/QAlert.d.ts +1 -1
  17. package/esm/components/QAlert/index.d.ts +3 -3
  18. package/esm/components/QAvatar/QAvatar.d.ts +1 -1
  19. package/esm/components/QAvatar/index.d.ts +3 -3
  20. package/esm/components/QBadgeIndicator/QBadgeIndicator.d.ts.map +1 -1
  21. package/esm/components/QBadgeIndicator/QBadgeIndicator.vue.js +23 -13
  22. package/esm/components/QBadgeIndicator/types.d.ts +13 -0
  23. package/esm/components/QBadgeIndicator/types.d.ts.map +1 -1
  24. package/esm/components/QBreadcrumbs/QBreadcrumbs.d.ts.map +1 -1
  25. package/esm/components/QBreadcrumbs/QBreadcrumbs.vue.js +31 -31
  26. package/esm/components/QButton/QButton.d.ts.map +1 -1
  27. package/esm/components/QButton/QButton.vue.js +54 -48
  28. package/esm/components/QButtonGroup/QButtonGroup.d.ts.map +1 -1
  29. package/esm/components/QCard/QCard.d.ts.map +1 -1
  30. package/esm/components/QCard/QCard.vue.js +48 -32
  31. package/esm/components/QCard/types.d.ts +9 -0
  32. package/esm/components/QCard/types.d.ts.map +1 -1
  33. package/esm/components/QCarousel/QCarousel.d.ts +1 -0
  34. package/esm/components/QCarousel/QCarousel.d.ts.map +1 -1
  35. package/esm/components/QCarousel/QCarousel.vue.js +84 -80
  36. package/esm/components/QCarousel/index.d.ts +6 -0
  37. package/esm/components/QCarousel/index.d.ts.map +1 -1
  38. package/esm/components/QCarousel/types.d.ts +9 -1
  39. package/esm/components/QCarousel/types.d.ts.map +1 -1
  40. package/esm/components/QCheckbox/QCheckbox.d.ts.map +1 -1
  41. package/esm/components/QCheckbox/QCheckbox.vue.js +9 -1
  42. package/esm/components/QCheckbox/index.d.ts +3 -0
  43. package/esm/components/QCheckbox/index.d.ts.map +1 -1
  44. package/esm/components/QCheckbox/types.d.ts +8 -0
  45. package/esm/components/QCheckbox/types.d.ts.map +1 -1
  46. package/esm/components/QCollapsible/QCollapsible.d.ts +1 -0
  47. package/esm/components/QCollapsible/QCollapsible.d.ts.map +1 -1
  48. package/esm/components/QCollapsible/QCollapsible.vue.js +55 -47
  49. package/esm/components/QCollapsible/index.d.ts +6 -0
  50. package/esm/components/QCollapsible/index.d.ts.map +1 -1
  51. package/esm/components/QCollapsible/types.d.ts +9 -0
  52. package/esm/components/QCollapsible/types.d.ts.map +1 -1
  53. package/esm/components/QColorPicker/QColorPicker.d.ts.map +1 -1
  54. package/esm/components/QColorPicker/QColorPicker.vue.js +4 -1
  55. package/esm/components/QColorPicker/index.d.ts +3 -0
  56. package/esm/components/QColorPicker/index.d.ts.map +1 -1
  57. package/esm/components/QColorPicker/types.d.ts +7 -0
  58. package/esm/components/QColorPicker/types.d.ts.map +1 -1
  59. package/esm/components/QCombobox/QCombobox.d.ts +7 -0
  60. package/esm/components/QCombobox/QCombobox.d.ts.map +1 -1
  61. package/esm/components/QCombobox/QCombobox.vue.js +258 -235
  62. package/esm/components/QCombobox/constants.d.ts +1 -0
  63. package/esm/components/QCombobox/constants.d.ts.map +1 -1
  64. package/esm/components/QCombobox/constants.js +1 -0
  65. package/esm/components/QCombobox/index.d.ts +11 -0
  66. package/esm/components/QCombobox/index.d.ts.map +1 -1
  67. package/esm/components/QDateTimePicker/QDateTimePicker.d.ts +180 -0
  68. package/esm/components/QDateTimePicker/QDateTimePicker.d.ts.map +1 -1
  69. package/esm/components/QDateTimePicker/QDateTimePicker.vue.js +637 -542
  70. package/esm/components/QDateTimePicker/index.d.ts +90 -0
  71. package/esm/components/QDateTimePicker/index.d.ts.map +1 -1
  72. package/esm/components/QDialog/QDialog.d.ts.map +1 -1
  73. package/esm/components/QDialog/QDialog.vue.js +2 -0
  74. package/esm/components/QDialog/types.d.ts +3 -1
  75. package/esm/components/QDialog/types.d.ts.map +1 -1
  76. package/esm/components/QDropdownMenu/QDropdownMenu.d.ts +3 -1
  77. package/esm/components/QDropdownMenu/QDropdownMenu.d.ts.map +1 -1
  78. package/esm/components/QDropdownMenu/QDropdownMenu.vue.js +84 -27
  79. package/esm/components/QDropdownMenu/QDropdownMenuContent.d.ts +9 -2
  80. package/esm/components/QDropdownMenu/QDropdownMenuContent.d.ts.map +1 -1
  81. package/esm/components/QDropdownMenu/QDropdownMenuContent.vue.js +168 -135
  82. package/esm/components/QDropdownMenu/ids.d.ts +8 -0
  83. package/esm/components/QDropdownMenu/ids.d.ts.map +1 -0
  84. package/esm/components/QDropdownMenu/ids.js +6 -0
  85. package/esm/components/QDropdownMenu/index.d.ts +9 -3
  86. package/esm/components/QDropdownMenu/index.d.ts.map +1 -1
  87. package/esm/components/QDropdownMenu/types.d.ts +3 -1
  88. package/esm/components/QDropdownMenu/types.d.ts.map +1 -1
  89. package/esm/components/QField/QField.d.ts +2 -0
  90. package/esm/components/QField/QField.d.ts.map +1 -1
  91. package/esm/components/QField/QField.vue.js +68 -61
  92. package/esm/components/QField/ids.d.ts +15 -0
  93. package/esm/components/QField/ids.d.ts.map +1 -0
  94. package/esm/components/QField/ids.js +10 -0
  95. package/esm/components/QField/index.d.ts +2 -0
  96. package/esm/components/QField/index.d.ts.map +1 -1
  97. package/esm/components/QFileUpload/QFileUpload.d.ts +355 -0
  98. package/esm/components/QFileUpload/QFileUpload.d.ts.map +1 -1
  99. package/esm/components/QFileUpload/QFileUpload.vue.js +118 -88
  100. package/esm/components/QFileUpload/constants.d.ts +2 -0
  101. package/esm/components/QFileUpload/constants.d.ts.map +1 -1
  102. package/esm/components/QFileUpload/constants.js +3 -1
  103. package/esm/components/QFileUpload/index.d.ts +182 -0
  104. package/esm/components/QFileUpload/index.d.ts.map +1 -1
  105. package/esm/components/QIcon/QIconFont.d.ts.map +1 -1
  106. package/esm/components/QIcon/QIconFont.vue.js +2 -1
  107. package/esm/components/QIcon/QIconImg.d.ts.map +1 -1
  108. package/esm/components/QIcon/QIconImg.vue.js +1 -0
  109. package/esm/components/QIcon/QIconSvg.d.ts.map +1 -1
  110. package/esm/components/QInputGroup/QInputGroup.d.ts +5 -0
  111. package/esm/components/QInputGroup/QInputGroup.d.ts.map +1 -1
  112. package/esm/components/QInputGroup/QInputGroup.vue.js +48 -41
  113. package/esm/components/QInputGroup/index.d.ts +3 -0
  114. package/esm/components/QInputGroup/index.d.ts.map +1 -1
  115. package/esm/components/QLabel/QLabel.d.ts.map +1 -1
  116. package/esm/components/QLabel/QLabel.vue.js +21 -19
  117. package/esm/components/QLabel/ids.d.ts +9 -0
  118. package/esm/components/QLabel/ids.d.ts.map +1 -0
  119. package/esm/components/QLabel/ids.js +6 -0
  120. package/esm/components/QLineLoader/QLineLoader.d.ts.map +1 -1
  121. package/esm/components/QLineLoader/QLineLoader.vue.js +15 -14
  122. package/esm/components/QList/QList.d.ts +3 -3
  123. package/esm/components/QList/QList.d.ts.map +1 -1
  124. package/esm/components/QList/QList.vue.js +135 -117
  125. package/esm/components/QList/QListItem.d.ts.map +1 -1
  126. package/esm/components/QList/QListItem.vue.js +54 -50
  127. package/esm/components/QList/context.d.ts +8 -0
  128. package/esm/components/QList/context.d.ts.map +1 -0
  129. package/esm/components/QList/context.js +4 -0
  130. package/esm/components/QMeter/QMeter.d.ts.map +1 -1
  131. package/esm/components/QMeter/QMeter.vue.js +38 -19
  132. package/esm/components/QMeter/index.d.ts +2 -10
  133. package/esm/components/QMeter/index.d.ts.map +1 -1
  134. package/esm/components/QMeter/types.d.ts +9 -1
  135. package/esm/components/QMeter/types.d.ts.map +1 -1
  136. package/esm/components/QObfuscation/QObfuscation.d.ts.map +1 -1
  137. package/esm/components/QObfuscation/QObfuscation.vue.js +42 -26
  138. package/esm/components/QObfuscation/index.d.ts.map +1 -1
  139. package/esm/components/QOverflow/QOverflow.d.ts.map +1 -1
  140. package/esm/components/QOverflow/QOverflow.vue.js +94 -73
  141. package/esm/components/QOverlay/QOverlay.d.ts.map +1 -1
  142. package/esm/components/QOverlay/QOverlay.vue.js +162 -132
  143. package/esm/components/QPasswordField/QPasswordField.d.ts +4 -0
  144. package/esm/components/QPasswordField/QPasswordField.d.ts.map +1 -1
  145. package/esm/components/QPasswordField/QPasswordField.vue.js +72 -66
  146. package/esm/components/QPasswordField/QPasswordFieldMeterOverlay.d.ts.map +1 -1
  147. package/esm/components/QPasswordField/QPasswordFieldMeterOverlay.vue.js +4 -2
  148. package/esm/components/QPasswordField/index.d.ts +2 -0
  149. package/esm/components/QPasswordField/index.d.ts.map +1 -1
  150. package/esm/components/QPasswordField/types.d.ts +4 -0
  151. package/esm/components/QPasswordField/types.d.ts.map +1 -1
  152. package/esm/components/QPhoneField/QPhoneField.d.ts +34 -3
  153. package/esm/components/QPhoneField/QPhoneField.d.ts.map +1 -1
  154. package/esm/components/QPhoneField/QPhoneField.vue.js +98 -102
  155. package/esm/components/QPhoneField/constants.d.ts +2 -1
  156. package/esm/components/QPhoneField/constants.d.ts.map +1 -1
  157. package/esm/components/QPhoneField/constants.js +1 -1
  158. package/esm/components/QPhoneField/index.d.ts +26 -8
  159. package/esm/components/QPhoneField/index.d.ts.map +1 -1
  160. package/esm/components/QPhoneField/types.d.ts +5 -2
  161. package/esm/components/QPhoneField/types.d.ts.map +1 -1
  162. package/esm/components/QPopover/QPopover.d.ts +1 -1
  163. package/esm/components/QPopover/index.d.ts +3 -3
  164. package/esm/components/QProgress/QProgress.d.ts.map +1 -1
  165. package/esm/components/QProgress/QProgress.vue.js +1 -1
  166. package/esm/components/QPropertyList/QPropertyList.vue.js +1 -1
  167. package/esm/components/QPropertyList/QPropertyListRow.d.ts.map +1 -1
  168. package/esm/components/QPropertyList/index.d.ts.map +1 -1
  169. package/esm/components/QRadioGroup/QRadioButton.d.ts.map +1 -1
  170. package/esm/components/QRadioGroup/QRadioButton.vue.js +1 -1
  171. package/esm/components/QRadioGroup/QRadioGroup.d.ts.map +1 -1
  172. package/esm/components/QRadioGroup/QRadioGroup.vue.js +53 -41
  173. package/esm/components/QRemoveScrollBar/utils/gap.d.ts.map +1 -1
  174. package/esm/components/QSection/QSection.d.ts.map +1 -1
  175. package/esm/components/QSection/QSection.vue.js +3 -2
  176. package/esm/components/QSection/types.d.ts +3 -4
  177. package/esm/components/QSection/types.d.ts.map +1 -1
  178. package/esm/components/QSelect/QSelect.d.ts +6 -0
  179. package/esm/components/QSelect/QSelect.d.ts.map +1 -1
  180. package/esm/components/QSelect/QSelect.vue.js +405 -355
  181. package/esm/components/QSelect/constants.d.ts +2 -0
  182. package/esm/components/QSelect/constants.d.ts.map +1 -1
  183. package/esm/components/QSelect/constants.js +3 -1
  184. package/esm/components/QSelect/index.d.ts +8 -0
  185. package/esm/components/QSelect/index.d.ts.map +1 -1
  186. package/esm/components/QSidebar/QSidebarItem.d.ts +1 -0
  187. package/esm/components/QSidebar/QSidebarItem.d.ts.map +1 -1
  188. package/esm/components/QSidebar/QSidebarItem.vue.js +3 -0
  189. package/esm/components/QSidebar/QSidebarPanel.d.ts.map +1 -1
  190. package/esm/components/QSidebar/QSidebarPanel.vue.js +93 -32
  191. package/esm/components/QSidebar/index.d.ts +3 -0
  192. package/esm/components/QSidebar/index.d.ts.map +1 -1
  193. package/esm/components/QSidebar/types.d.ts +20 -1
  194. package/esm/components/QSidebar/types.d.ts.map +1 -1
  195. package/esm/components/QSkeletonLoader/QSkeletonLoader.d.ts.map +1 -1
  196. package/esm/components/QSkeletonLoader/QSkeletonLoader.vue.js +16 -15
  197. package/esm/components/QSpinnerLoader/QSpinnerLoader.d.ts.map +1 -1
  198. package/esm/components/QSpinnerLoader/QSpinnerLoader.vue.js +11 -10
  199. package/esm/components/QSteps/QSteps.d.ts +3 -2
  200. package/esm/components/QSteps/QSteps.d.ts.map +1 -1
  201. package/esm/components/QSteps/QSteps.vue.js +171 -152
  202. package/esm/components/QSteps/QStepsNav.d.ts +7 -0
  203. package/esm/components/QSteps/QStepsNav.d.ts.map +1 -1
  204. package/esm/components/QSteps/QStepsNav.vue.js +29 -15
  205. package/esm/components/QSteps/constants.d.ts +4 -2
  206. package/esm/components/QSteps/constants.d.ts.map +1 -1
  207. package/esm/components/QSteps/constants.js +2 -0
  208. package/esm/components/QSwitch/QSwitch.d.ts +2 -0
  209. package/esm/components/QSwitch/QSwitch.d.ts.map +1 -1
  210. package/esm/components/QSwitch/QSwitch.vue.js +12 -2
  211. package/esm/components/QSwitch/index.d.ts +4 -0
  212. package/esm/components/QSwitch/index.d.ts.map +1 -1
  213. package/esm/components/QSwitch/types.d.ts +8 -0
  214. package/esm/components/QSwitch/types.d.ts.map +1 -1
  215. package/esm/components/QTabs/QTab.d.ts.map +1 -1
  216. package/esm/components/QTabs/QTab.vue.js +1 -0
  217. package/esm/components/QTextArea/QTextArea.d.ts.map +1 -1
  218. package/esm/components/QTextArea/QTextArea.vue.js +6 -2
  219. package/esm/components/QTextField/QTextField.d.ts +4 -0
  220. package/esm/components/QTextField/QTextField.d.ts.map +1 -1
  221. package/esm/components/QTextField/QTextField.vue.js +5 -3
  222. package/esm/components/QTextField/index.d.ts +2 -0
  223. package/esm/components/QTextField/index.d.ts.map +1 -1
  224. package/esm/components/QThemeProvider/QThemeProvider.d.ts.map +1 -1
  225. package/esm/components/QToast/QToast.d.ts +1 -0
  226. package/esm/components/QToast/QToast.d.ts.map +1 -1
  227. package/esm/components/QToast/QToast.vue.js +89 -85
  228. package/esm/components/QToast/index.d.ts +6 -0
  229. package/esm/components/QToast/index.d.ts.map +1 -1
  230. package/esm/components/QToast/types.d.ts +8 -0
  231. package/esm/components/QToast/types.d.ts.map +1 -1
  232. package/esm/components/QTooltip/QTooltip.d.ts.map +1 -1
  233. package/esm/components/QTooltip/QTooltip.vue.js +19 -11
  234. package/esm/components/__internal__/QClearButton/QClearButton.d.ts.map +1 -1
  235. package/esm/components/__internal__/QHelpPopover/QHelpPopover.d.ts.map +1 -1
  236. package/esm/index.d.ts.map +1 -1
  237. package/esm/utils/focus.d.ts +10 -0
  238. package/esm/utils/focus.d.ts.map +1 -1
  239. package/esm/utils/focus.js +5 -2
  240. package/esm/utils/loader.d.ts +19 -0
  241. package/esm/utils/loader.d.ts.map +1 -0
  242. package/esm/utils/loader.js +6 -0
  243. package/package.json +24 -23
  244. package/dist/ui.js +0 -1846
  245. package/dist/ui.min.js +0 -1846
@@ -1,46 +1,59 @@
1
1
  import { useId as e } from "../../composables/useId/index.js";
2
2
  import { QIcon as t } from "../QIcon/index.js";
3
- import { QOverlay as n } from "../QOverlay/index.js";
4
- import { QPopover as ee } from "../QPopover/index.js";
5
- import { QSpinnerLoader as r } from "../QSpinnerLoader/index.js";
6
- import { mergeDescribedBy as i } from "../__internal__/QHelpPopover/resolveHelp.js";
7
- import { QButton as a } from "../QButton/index.js";
8
- import { QChevron as o } from "../__internal__/QChevron/index.js";
9
- import { QBadge as s } from "../QBadge/index.js";
3
+ import { getNextTabbable as n } from "../../utils/focus.js";
4
+ import { QOverlay as r } from "../QOverlay/index.js";
5
+ import { QPopover as i } from "../QPopover/index.js";
6
+ import { QSpinnerLoader as a } from "../QSpinnerLoader/index.js";
7
+ import { mergeDescribedBy as o } from "../__internal__/QHelpPopover/resolveHelp.js";
8
+ import { QButton as ee } from "../QButton/index.js";
9
+ import { QChevron as s } from "../__internal__/QChevron/index.js";
10
+ import { QBadge as c } from "../QBadge/index.js";
10
11
  import { QList as te } from "../QList/index.js";
11
12
  import { QField as ne } from "../QField/index.js";
12
13
  import { QClearButton as re } from "../__internal__/QClearButton/index.js";
13
- import { DEFAULT_ICONS as c, DEFAULT_TEXTS as l } from "./constants.js";
14
- import { Fragment as u, computed as d, createBlock as f, createCommentVNode as p, createElementBlock as m, createElementVNode as h, createSlots as ie, createTextVNode as g, createVNode as _, defineComponent as ae, mergeModels as v, mergeProps as y, nextTick as b, normalizeClass as x, normalizeProps as oe, onBeforeUnmount as se, onMounted as ce, openBlock as S, ref as le, renderList as ue, renderSlot as C, toDisplayString as w, toRef as de, unref as T, useAttrs as fe, useModel as pe, useTemplateRef as E, vModelText as me, watch as D, withCtx as O, withDirectives as he, withModifiers as ge } from "vue";
14
+ import { DEFAULT_ICONS as l, DEFAULT_TEXTS as ie } from "./constants.js";
15
+ import { Fragment as u, computed as d, createBlock as f, createCommentVNode as p, createElementBlock as m, createElementVNode as h, createSlots as ae, createTextVNode as g, createVNode as _, defineComponent as oe, mergeModels as v, mergeProps as y, nextTick as b, normalizeClass as se, normalizeProps as ce, onBeforeUnmount as le, onMounted as ue, openBlock as x, ref as de, renderList as fe, renderSlot as S, toDisplayString as C, toHandlers as pe, toRef as me, unref as w, useAttrs as he, useModel as ge, useTemplateRef as T, watch as E, withCtx as D, withModifiers as _e } from "vue";
15
16
  //#region src/components/QSelect/QSelect.vue?vue&type=script&setup=true&lang.ts
16
- var _e = {
17
+ var ve = {
17
18
  key: 0,
18
19
  ref: "valueContainer",
19
20
  class: "q-select__value-container"
20
- }, ve = {
21
+ }, ye = {
21
22
  key: 1,
22
23
  class: "q-select__multi-value"
23
- }, ye = {
24
+ }, be = {
24
25
  key: 1,
25
26
  ref: "separatorMeasure",
26
27
  class: "q-select__separator-measure q-select__multi-value--hidden"
27
- }, be = {
28
+ }, xe = {
28
29
  key: 1,
29
30
  class: "q-select__value"
30
- }, xe = {
31
+ }, Se = {
31
32
  key: 1,
32
33
  class: "q-select__placeholder"
33
- }, Se = [
34
+ }, Ce = [
34
35
  "id",
36
+ "value",
37
+ "aria-invalid",
35
38
  "aria-describedby",
36
39
  "tabindex",
37
40
  "aria-expanded",
38
41
  "aria-controls",
42
+ "aria-required",
43
+ "aria-readonly",
44
+ "aria-disabled",
45
+ "aria-busy",
39
46
  "aria-keyshortcuts"
40
- ], Ce = ["data-key"], we = {
47
+ ], we = {
48
+ class: "q-sr-only",
49
+ role: "status"
50
+ }, Te = ["data-key"], Ee = {
41
51
  key: 0,
42
52
  class: "q-select__loader"
43
- }, k = ", ", A = /*@__PURE__*/ ae({
53
+ }, De = {
54
+ key: 2,
55
+ class: "q-select__loader"
56
+ }, O = ", ", k = /*@__PURE__*/ oe({
44
57
  inheritAttrs: !1,
45
58
  __name: "QSelect",
46
59
  props: /*@__PURE__*/ v({
@@ -52,8 +65,8 @@ var _e = {
52
65
  labelPosition: {},
53
66
  help: {},
54
67
  helpDisplay: {},
55
- icons: { default: () => c },
56
- texts: { default: () => l },
68
+ icons: { default: () => l },
69
+ texts: { default: () => ie },
57
70
  size: {},
58
71
  readonly: { type: Boolean },
59
72
  disabled: { type: Boolean },
@@ -89,75 +102,84 @@ var _e = {
89
102
  "show",
90
103
  "hide"
91
104
  ], ["update:modelValue", "update:open"]),
92
- setup(c, { expose: l, emit: ae }) {
93
- let v = c, A = ae, j = pe(c, "modelValue"), M = e(de(v, "id")), Te = fe(), N = d(() => `${M.value}_input`), Ee = d(() => `${M.value}_listbox`), P = pe(c, "open"), De = d(() => v.overflow === "fit-content" ? "auto" : "anchor"), F = le(0), I = !0, L = E("trigger"), Oe = d(() => typeof Te["aria-describedby"] == "string" ? Te["aria-describedby"] : void 0), ke = E("input"), Ae = E("list"), je = E("content"), Me = E("valueContainer"), Ne = E("allBadges"), Pe = E("allPlainTexts"), Fe = E("hiddenItemsCountBadge"), R = E("counterMeasure"), Ie = E("separatorMeasure"), z = null, B = /* @__PURE__ */ new Set(), V = null;
94
- function Le() {
95
- V && clearTimeout(V), V = setTimeout(() => {
105
+ setup(l, { expose: ie, emit: oe }) {
106
+ let v = l, k = oe, A = ge(l, "modelValue"), j = e(me(v, "id")), M = he(), Oe = d(() => `${j.value}_input`), ke = d(() => `${j.value}_listbox`), N = ge(l, "open"), P = d(() => !!(N.value && !v.loading && v.items?.length)), Ae = d(() => !N.value || P.value ? "" : v.loading ? v.texts.loading : v.texts.noData), je = d(() => v.overflow === "fit-content" ? "auto" : "anchor"), F = de(0), I = !0, L = !1, R = T("trigger"), Me = d(() => typeof M["aria-describedby"] == "string" ? M["aria-describedby"] : void 0), z = T("input"), Ne = d(() => v.readonly && !v.disabled ? { click: () => void 0 } : {}), Pe = d(() => {
107
+ let e = Be.value?.$el;
108
+ return e?.querySelector("button") ?? e;
109
+ });
110
+ function Fe() {
111
+ return typeof M["aria-label"] == "string" ? M["aria-label"] : Array.from(z.value?.labels ?? []).map((e) => e.textContent?.trim()).filter(Boolean).join(" ") || void 0;
112
+ }
113
+ let Ie = T("list"), B = T("content"), Le = T("valueContainer"), Re = T("allBadges"), ze = T("allPlainTexts"), Be = T("hiddenItemsCountBadge"), V = T("counterMeasure"), Ve = T("separatorMeasure"), H = null, U = /* @__PURE__ */ new Set(), W = null;
114
+ function He() {
115
+ W && clearTimeout(W), W = setTimeout(() => {
96
116
  $();
97
117
  }, 120);
98
118
  }
99
- function Re(e) {
100
- if (!z) return;
119
+ function Ue(e) {
120
+ if (!H) return;
101
121
  let t = new Set(e);
102
- for (let e of B) t.has(e) || (z.unobserve(e), B.delete(e));
103
- for (let e of t) B.has(e) || (z.observe(e), B.add(e));
122
+ for (let e of U) t.has(e) || (H.unobserve(e), U.delete(e));
123
+ for (let e of t) U.has(e) || (H.observe(e), U.add(e));
104
124
  }
105
- ce(() => {
125
+ ue(() => {
106
126
  $();
107
- let e = L.value?.fieldRef;
108
- e && (z = new ResizeObserver(() => {
109
- Le();
110
- }), z.observe(e));
111
- }), se(() => {
112
- z?.disconnect(), B.clear(), V && clearTimeout(V);
127
+ let e = R.value?.fieldRef;
128
+ e && (H = new ResizeObserver(() => {
129
+ He();
130
+ }), H.observe(e));
131
+ }), le(() => {
132
+ H?.disconnect(), U.clear(), W && clearTimeout(W);
113
133
  });
114
- let H = d(() => U.value.length === 0), U = d(() => {
115
- if (v.multiple) return (j.value ?? []).map((e) => Be(e)).filter((e) => !!e);
116
- let e = j.value === void 0 ? void 0 : Be(j.value);
134
+ let G = d(() => K.value.length === 0), K = d(() => {
135
+ if (v.multiple) return (A.value ?? []).map((e) => Ge(e)).filter((e) => !!e);
136
+ let e = A.value === void 0 ? void 0 : Ge(A.value);
117
137
  return e ? [e] : [];
118
- }), ze = d(() => {
138
+ }), We = d(() => {
119
139
  let e = /* @__PURE__ */ new Map();
120
140
  return v.items?.forEach((t, n) => {
121
141
  e.set(t.key, n);
122
142
  }), e;
123
- }), W = d(() => U.value?.map(K).filter(Boolean).join(", ")), G = d(() => v.clearable && !v.readonly && !v.disabled && !v.loading && !H.value);
124
- function Be(e) {
143
+ }), q = d(() => K.value?.map(Y).filter(Boolean).join(", ")), J = d(() => v.clearable && !v.readonly && !v.disabled && !v.loading && !G.value);
144
+ function Ge(e) {
125
145
  return v.items?.find((t) => t[v.itemValue] === e);
126
146
  }
127
- function Ve(e) {
128
- let t = U.value[e]?.[v.itemValue];
129
- q(j.value.filter((e) => e !== t));
147
+ function Ke(e) {
148
+ let t = K.value[e]?.[v.itemValue];
149
+ X(A.value.filter((e) => e !== t));
130
150
  }
131
- function K(e) {
151
+ function Y(e) {
132
152
  return e?.[v.itemLabel] ?? "";
133
153
  }
134
- function He(e) {
135
- return e + 1 < U.value.length - F.value ? k : "";
154
+ function qe(e) {
155
+ return e + 1 < K.value.length - F.value ? O : "";
136
156
  }
137
- function q(e) {
138
- Array.isArray(e) ? j.value = e.sort((e, t) => ze.value.get(e) - ze.value.get(t)) : (j.value = e, Y());
157
+ function X(e) {
158
+ Array.isArray(e) ? A.value = e.sort((e, t) => We.value.get(e) - We.value.get(t)) : (A.value = e, Q(!L));
139
159
  }
140
- function J() {
141
- q(v.emptyValue), Z();
160
+ function Z() {
161
+ X(v.emptyValue), it();
142
162
  }
143
- function Ue(e) {
163
+ function Je(e) {
144
164
  let t = e.relatedTarget;
145
- !je.value?.contains(t) && !L.value?.fieldRef?.contains(t) && Y(!1);
165
+ !B.value?.contains(t) && !R.value?.fieldRef?.contains(t) && Q(!1);
146
166
  }
147
- function We() {
148
- P.value || v.readonly || v.disabled || (I = !0, A("before-show"), P.value = !0);
167
+ function Ye() {
168
+ N.value || v.readonly || v.disabled || (I = !0, k("before-show"), N.value = !0);
149
169
  }
150
- function Y(e = !0) {
151
- P.value &&= (I = e, A("before-hide"), !1);
170
+ function Q(e = !0) {
171
+ N.value &&= (I = e, k("before-hide"), !1);
152
172
  }
153
- function Ge(e) {
154
- P.value && (e.target?.closest("input, button, a, [tabindex]") || e.preventDefault());
173
+ function Xe(e) {
174
+ N.value && (e.target?.closest("input, button, a, [tabindex]") || e.preventDefault());
155
175
  }
156
- function Ke() {
157
- v.readonly || v.disabled || (P.value ? Y() : We());
176
+ function Ze() {
177
+ v.readonly || v.disabled || (N.value ? Q() : Ye());
158
178
  }
159
- function X(e) {
160
- !e.key || v.readonly || v.disabled || ([
179
+ function Qe(e) {
180
+ if (!e.key || v.readonly || v.disabled) return;
181
+ let t = e.altKey && e.key === "ArrowDown" && !N.value;
182
+ (e.altKey || e.ctrlKey || e.metaKey) && !t || ([
161
183
  "Enter",
162
184
  " ",
163
185
  "ArrowDown",
@@ -169,335 +191,363 @@ var _e = {
169
191
  "Enter",
170
192
  " ",
171
193
  "ArrowDown"
172
- ].includes(e.key) && We(), ["Escape", "Tab"].includes(e.key) && (P.value ? Y(e.key !== "Tab") : G.value && e.key === "Escape" && J()), G.value && e.key === "Delete" && J());
194
+ ].includes(e.key) && Ye(), ["Escape", "Tab"].includes(e.key) && (N.value ? Q(e.key !== "Tab") : J.value && e.key === "Escape" && Z()), J.value && e.key === "Delete" && Z());
173
195
  }
174
- function qe(e) {
175
- e.key.length === 1 && e.preventDefault(), X(e);
196
+ function $e(e) {
197
+ if (e.key !== "Tab") {
198
+ Qe(e);
199
+ return;
200
+ }
201
+ e.preventDefault(), L = !0;
202
+ let t = !e.shiftKey, r = B.value;
203
+ b(() => {
204
+ L = !1, Q(!1);
205
+ let e = R.value?.$el;
206
+ ((t && e ? n(e, r) : void 0) ?? z.value)?.focus();
207
+ });
176
208
  }
177
- async function Je() {
178
- await b(), v.loading ? je.value?.focus() : Q(), A("show");
209
+ function et(e) {
210
+ e.preventDefault();
179
211
  }
180
- function Ye() {
181
- I && Z(), I = !0, A("hide");
212
+ function tt() {
213
+ Q(!1);
182
214
  }
183
- function Z() {
184
- ke.value?.focus();
215
+ async function nt() {
216
+ await b(), v.loading ? B.value?.focus() : at(), k("show");
217
+ }
218
+ function rt() {
219
+ I && it(), I = !0, k("hide");
220
+ }
221
+ function it() {
222
+ z.value?.focus();
185
223
  }
186
- function Q() {
187
- Ae.value?.$el.focus();
224
+ function at() {
225
+ Ie.value?.$el.focus();
188
226
  }
189
227
  async function $() {
190
- if (await b(), await b(), !v.multiple || !Me.value || H.value) {
228
+ if (await b(), await b(), !v.multiple || !Le.value || G.value) {
191
229
  F.value = 0;
192
230
  return;
193
231
  }
194
- let e = Me.value, t = e.getBoundingClientRect().width, n = parseFloat(getComputedStyle(e).columnGap) || 0, ee = R.value?.$el.getBoundingClientRect().width ?? 0, r = v.badges ? (Ne.value ?? []).map((e) => e.$el) : Pe.value ?? [], i = r.map((e) => e.getBoundingClientRect().width), a = Ie.value?.getBoundingClientRect().width ?? 0;
195
- if (Re(R.value ? [...r, R.value.$el] : r), i.reduce((e, t) => e + t, 0) + n * (i.length - 1) - a <= t) {
232
+ let e = Le.value, t = e.getBoundingClientRect().width, n = parseFloat(getComputedStyle(e).columnGap) || 0, r = V.value?.$el.getBoundingClientRect().width ?? 0, i = v.badges ? (Re.value ?? []).map((e) => e.$el) : ze.value ?? [], a = i.map((e) => e.getBoundingClientRect().width), o = Ve.value?.getBoundingClientRect().width ?? 0;
233
+ if (Ue(V.value ? [...i, V.value.$el] : i), a.reduce((e, t) => e + t, 0) + n * (a.length - 1) - o <= t) {
196
234
  F.value = 0;
197
235
  return;
198
236
  }
199
- let o = ee, s = 0;
200
- for (let e of i) {
201
- if (o + n + e - a > t) break;
202
- o += n + e, s++;
237
+ let ee = r, s = 0;
238
+ for (let e of a) {
239
+ if (ee + n + e - o > t) break;
240
+ ee += n + e, s++;
203
241
  }
204
- F.value = i.length - s;
242
+ F.value = a.length - s;
205
243
  }
206
- return D(() => v.loading, (e) => {
207
- !e && P.value && b(Q);
208
- }), D(() => v.badges, $), D(U, $, { deep: !0 }), D(() => v.clearable, $), D([
209
- P,
244
+ return E(() => v.loading, (e) => {
245
+ !e && N.value && b(at);
246
+ }), E(() => v.badges, $), E(K, $, { deep: !0 }), E(() => v.clearable, $), E([
247
+ N,
210
248
  () => v.readonly,
211
249
  () => v.disabled
212
250
  ], ([e, t, n]) => {
213
- e && (t || n) && Y(!1);
251
+ e && (t || n) && Q(!1);
214
252
  }, {
215
253
  flush: "sync",
216
254
  immediate: !0
217
- }), l({ focusList: Q }), (e, l) => (S(), m(u, null, [_(T(ne), {
218
- id: T(M),
219
- ref: "trigger",
220
- label: v.label,
221
- for: N.value,
222
- "label-position": v.labelPosition,
223
- required: v.required,
224
- class: x([
225
- "q-select",
226
- {
227
- "q-select--readonly": v.readonly,
228
- "q-select--disabled": v.disabled
229
- },
230
- v.class
231
- ]),
232
- readonly: v.readonly,
233
- disabled: v.disabled,
234
- "data-loading": v.loading,
235
- size: v.size,
236
- invalid: v.invalid,
237
- help: v.help,
238
- "help-display": v.helpDisplay,
239
- icons: v.icons,
240
- texts: v.texts,
241
- onMousedown: Ge,
242
- onClick: Ke,
243
- onKeydown: X
244
- }, ie({
245
- default: O(({ describedBy: n }) => [C(e.$slots, "value", {
246
- empty: H.value,
247
- items: U.value,
248
- value: j.value
249
- }, () => [H.value ? (S(), m("span", xe, [!v.readonly && !v.disabled ? (S(), m(u, { key: 0 }, [g(w(v.texts.placeholder), 1)], 64)) : p("v-if", !0)])) : (S(), m(u, { key: 0 }, [v.badges || v.multiple ? (S(), m("span", _e, [v.multiple ? (S(), m(u, { key: 0 }, [
250
- (S(!0), m(u, null, ue(U.value, (e, n) => (S(), m(u, { key: `visible-${n}` }, [n < U.value.length - F.value ? (S(), m(u, { key: 0 }, [v.badges ? (S(), f(T(s), {
251
- key: 0,
252
- pill: "",
253
- size: "small",
254
- focusable: !1,
255
- color: v.readonly || v.disabled ? "neutral" : void 0,
256
- disabled: v.readonly || v.disabled,
257
- removable: !v.readonly && !v.disabled && (!v.required || U.value.length > 1),
258
- icons: v.icons,
259
- texts: v.texts,
260
- "onClick:remove": () => Ve(n)
261
- }, {
262
- default: O(() => [e?.icon ? (S(), f(T(t), y({
255
+ }), ie({ focusList: at }), (e, n) => (x(), m(u, null, [
256
+ _(w(ne), {
257
+ id: w(j),
258
+ ref: "trigger",
259
+ label: v.label,
260
+ for: Oe.value,
261
+ "label-position": v.labelPosition,
262
+ required: v.required,
263
+ class: se([
264
+ "q-select",
265
+ {
266
+ "q-select--readonly": v.readonly,
267
+ "q-select--disabled": v.disabled
268
+ },
269
+ v.class
270
+ ]),
271
+ readonly: v.readonly,
272
+ disabled: v.disabled,
273
+ "data-loading": v.loading,
274
+ size: v.size,
275
+ invalid: v.invalid,
276
+ help: v.help,
277
+ "help-display": v.helpDisplay,
278
+ icons: v.icons,
279
+ texts: v.texts,
280
+ onMousedown: Xe,
281
+ onClick: Ze,
282
+ onKeydown: Qe
283
+ }, ae({
284
+ default: D(({ describedBy: n, invalid: r }) => [S(e.$slots, "value", {
285
+ empty: G.value,
286
+ items: K.value,
287
+ value: A.value
288
+ }, () => [G.value ? (x(), m("span", Se, [!v.readonly && !v.disabled ? (x(), m(u, { key: 0 }, [g(C(v.texts.placeholder), 1)], 64)) : p("v-if", !0)])) : (x(), m(u, { key: 0 }, [v.badges || v.multiple ? (x(), m("span", ve, [v.multiple ? (x(), m(u, { key: 0 }, [
289
+ (x(!0), m(u, null, fe(K.value, (e, n) => (x(), m(u, { key: `visible-${n}` }, [n < K.value.length - F.value ? (x(), m(u, { key: 0 }, [v.badges ? (x(), f(w(c), {
263
290
  key: 0,
264
- ref_for: !0
265
- }, e.icon), null, 16)) : p("v-if", !0), g(" " + w(K(e)), 1)]),
266
- _: 2
267
- }, 1032, [
268
- "color",
269
- "disabled",
270
- "removable",
271
- "icons",
272
- "texts",
273
- "onClick:remove"
274
- ])) : v.multiple ? (S(), m("span", ve, w(K(e) + He(n)), 1)) : p("v-if", !0)], 64)) : p("v-if", !0)], 64))), 128)),
275
- F.value > 0 ? (S(), m(u, { key: 0 }, [_(T(s), {
276
- ref: "hiddenItemsCountBadge",
291
+ pill: "",
292
+ size: "small",
293
+ focusable: !1,
294
+ color: v.readonly || v.disabled ? "neutral" : void 0,
295
+ disabled: v.readonly || v.disabled,
296
+ removable: !v.readonly && !v.disabled && (!v.required || K.value.length > 1),
297
+ icons: v.icons,
298
+ texts: v.texts,
299
+ "onClick:remove": () => Ke(n)
300
+ }, {
301
+ default: D(() => [e?.icon ? (x(), f(w(t), y({
302
+ key: 0,
303
+ ref_for: !0
304
+ }, e.icon), null, 16)) : p("v-if", !0), g(" " + C(Y(e)), 1)]),
305
+ _: 2
306
+ }, 1032, [
307
+ "color",
308
+ "disabled",
309
+ "removable",
310
+ "icons",
311
+ "texts",
312
+ "onClick:remove"
313
+ ])) : v.multiple ? (x(), m("span", ye, C(Y(e) + qe(n)), 1)) : p("v-if", !0)], 64)) : p("v-if", !0)], 64))), 128)),
314
+ F.value > 0 ? (x(), m(u, { key: 0 }, [_(w(c), y({
315
+ ref: "hiddenItemsCountBadge",
316
+ pill: "",
317
+ size: "small",
318
+ focusable: v.readonly && !v.disabled,
319
+ icons: v.icons,
320
+ texts: v.texts,
321
+ class: ["q-select__badge-count", { "q-select__badge-count--clickable": v.readonly || v.disabled }]
322
+ }, pe(Ne.value)), {
323
+ default: D(() => [g(" +" + C(F.value), 1)]),
324
+ _: 1
325
+ }, 16, [
326
+ "focusable",
327
+ "icons",
328
+ "texts",
329
+ "class"
330
+ ]), v.readonly || v.disabled ? (x(), f(w(i), {
331
+ key: 0,
332
+ anchor: Pe.value,
333
+ text: q.value,
334
+ placement: "bottom-start"
335
+ }, {
336
+ default: D(() => [g(C(q.value), 1)]),
337
+ _: 1
338
+ }, 8, ["anchor", "text"])) : p("v-if", !0)], 64)) : p("v-if", !0),
339
+ (x(!0), m(u, null, fe(K.value, (e, n) => (x(), m(u, { key: `measure-${n}` }, [v.badges ? (x(), f(w(c), {
340
+ key: 0,
341
+ ref_for: !0,
342
+ ref: "allBadges",
343
+ pill: "",
344
+ size: "small",
345
+ focusable: !1,
346
+ color: v.readonly || v.disabled ? "neutral" : void 0,
347
+ disabled: "",
348
+ class: "q-select__badge-hidden",
349
+ icons: v.icons,
350
+ texts: v.texts,
351
+ removable: !v.readonly && !v.disabled && (!v.required || K.value.length > 1)
352
+ }, {
353
+ default: D(() => [e?.icon ? (x(), f(w(t), y({
354
+ key: 0,
355
+ ref_for: !0
356
+ }, e.icon), null, 16)) : p("v-if", !0), g(" " + C(Y(e)), 1)]),
357
+ _: 2
358
+ }, 1032, [
359
+ "color",
360
+ "icons",
361
+ "texts",
362
+ "removable"
363
+ ])) : v.multiple ? (x(), m(u, { key: 1 }, [p(" Always with the separator, so its width does not change with the count "), h("span", {
364
+ ref_for: !0,
365
+ ref: "allPlainTexts",
366
+ class: "q-select__multi-value--hidden"
367
+ }, C(Y(e) + O), 513)], 2112)) : p("v-if", !0)], 64))), 128)),
368
+ p(" The separator alone, which the last item shown goes without "),
369
+ v.badges ? p("v-if", !0) : (x(), m("span", be, C(O), 512)),
370
+ p(" The widest counter it can show, so the count keeps room for it "),
371
+ _(w(c), {
372
+ ref: "counterMeasure",
373
+ pill: "",
374
+ size: "small",
375
+ focusable: !1,
376
+ icons: v.icons,
377
+ texts: v.texts,
378
+ class: "q-select__badge-count-measure q-select__badge-hidden"
379
+ }, {
380
+ default: D(() => [g(" +" + C(K.value.length), 1)]),
381
+ _: 1
382
+ }, 8, ["icons", "texts"])
383
+ ], 64)) : (x(), f(w(c), {
384
+ key: 1,
277
385
  pill: "",
278
386
  size: "small",
279
387
  focusable: !1,
388
+ disabled: v.readonly || v.disabled,
389
+ removable: !v.readonly && !v.disabled && !v.required,
280
390
  icons: v.icons,
281
391
  texts: v.texts,
282
- class: x(["q-select__badge-count", { "q-select__badge-count--clickable": v.readonly || v.disabled }])
392
+ "onClick:remove": Z
283
393
  }, {
284
- default: O(() => [g(" +" + w(F.value), 1)]),
394
+ default: D(() => [K.value[0]?.icon ? (x(), f(w(t), ce(y({ key: 0 }, K.value[0].icon)), null, 16)) : p("v-if", !0), g(" " + C(Y(K.value[0])), 1)]),
285
395
  _: 1
286
396
  }, 8, [
397
+ "disabled",
398
+ "removable",
287
399
  "icons",
288
- "texts",
289
- "class"
290
- ]), v.readonly || v.disabled ? (S(), f(T(ee), {
291
- key: 0,
292
- anchor: Fe.value?.$el,
293
- text: W.value,
294
- placement: "bottom-start"
295
- }, {
296
- default: O(() => [g(w(W.value), 1)]),
297
- _: 1
298
- }, 8, ["anchor", "text"])) : p("v-if", !0)], 64)) : p("v-if", !0),
299
- (S(!0), m(u, null, ue(U.value, (e, n) => (S(), m(u, { key: `measure-${n}` }, [v.badges ? (S(), f(T(s), {
300
- key: 0,
301
- ref_for: !0,
302
- ref: "allBadges",
303
- pill: "",
304
- size: "small",
305
- focusable: !1,
306
- color: v.readonly || v.disabled ? "neutral" : void 0,
307
- disabled: "",
308
- class: "q-select__badge-hidden",
309
- icons: v.icons,
310
- texts: v.texts,
311
- removable: !v.readonly && !v.disabled && (!v.required || U.value.length > 1)
312
- }, {
313
- default: O(() => [e?.icon ? (S(), f(T(t), y({
400
+ "texts"
401
+ ]))], 512)) : (x(), m("span", xe, C(q.value), 1))], 64))]), h("input", y({
402
+ id: Oe.value,
403
+ ref: "input",
404
+ value: q.value,
405
+ "aria-invalid": r || void 0
406
+ }, e.$attrs, {
407
+ "aria-describedby": w(o)(n, Me.value),
408
+ class: "q-select__input",
409
+ inputmode: "none",
410
+ type: "text",
411
+ autocomplete: "off",
412
+ tabindex: v.disabled ? -1 : 0,
413
+ role: "combobox",
414
+ "aria-expanded": P.value,
415
+ "aria-controls": P.value ? ke.value : void 0,
416
+ "aria-haspopup": "listbox",
417
+ "aria-required": v.required || void 0,
418
+ "aria-readonly": v.readonly || void 0,
419
+ "aria-disabled": v.disabled || void 0,
420
+ "aria-busy": v.loading || void 0,
421
+ "aria-keyshortcuts": J.value ? "Delete" : void 0,
422
+ onBeforeinput: et
423
+ }), null, 16, Ce)]),
424
+ append: D(() => [
425
+ S(e.$slots, "append"),
426
+ J.value ? (x(), f(w(re), {
314
427
  key: 0,
315
- ref_for: !0
316
- }, e.icon), null, 16)) : p("v-if", !0), g(" " + w(K(e)), 1)]),
317
- _: 2
318
- }, 1032, [
319
- "color",
320
- "icons",
321
- "texts",
322
- "removable"
323
- ])) : v.multiple ? (S(), m(u, { key: 1 }, [p(" Always with the separator, so its width does not change with the count "), h("span", {
324
- ref_for: !0,
325
- ref: "allPlainTexts",
326
- class: "q-select__multi-value--hidden"
327
- }, w(K(e) + k), 513)], 2112)) : p("v-if", !0)], 64))), 128)),
328
- p(" The separator alone, which the last item shown goes without "),
329
- v.badges ? p("v-if", !0) : (S(), m("span", ye, w(k), 512)),
330
- p(" The widest counter it can show, so the count keeps room for it "),
331
- _(T(s), {
332
- ref: "counterMeasure",
333
- pill: "",
334
- size: "small",
335
- focusable: !1,
336
- icons: v.icons,
337
- texts: v.texts,
338
- class: "q-select__badge-count-measure q-select__badge-hidden"
339
- }, {
340
- default: O(() => [g(" +" + w(U.value.length), 1)]),
341
- _: 1
342
- }, 8, ["icons", "texts"])
343
- ], 64)) : (S(), f(T(s), {
344
- key: 1,
345
- pill: "",
346
- size: "small",
347
- focusable: !1,
348
- disabled: v.readonly || v.disabled,
349
- removable: !v.readonly && !v.disabled && !v.required,
350
- icons: v.icons,
351
- texts: v.texts,
352
- "onClick:remove": J
353
- }, {
354
- default: O(() => [U.value[0]?.icon ? (S(), f(T(t), oe(y({ key: 0 }, U.value[0].icon)), null, 16)) : p("v-if", !0), g(" " + w(K(U.value[0])), 1)]),
355
- _: 1
356
- }, 8, [
428
+ icons: v.icons,
429
+ texts: v.texts,
430
+ onClick: Z
431
+ }, null, 8, ["icons", "texts"])) : p("v-if", !0),
432
+ v.readonly ? p("v-if", !0) : (x(), f(w(ee), {
433
+ key: 1,
434
+ class: "q-select__chevron",
435
+ "aria-label": v.texts.showOptions,
436
+ variant: "ghost",
437
+ color: "neutral",
438
+ borderless: "",
439
+ tabindex: -1,
440
+ disabled: v.disabled,
441
+ onClick: Ze
442
+ }, {
443
+ default: D(() => [_(w(s), {
444
+ "model-value": N.value,
445
+ icons: v.icons
446
+ }, null, 8, ["model-value", "icons"])]),
447
+ _: 1
448
+ }, 8, ["aria-label", "disabled"]))
449
+ ]),
450
+ _: 2
451
+ }, [K.value.length === 1 && K.value[0].icon && !v.badges || e.$slots.prepend ? {
452
+ name: "prepend",
453
+ fn: D(() => [S(e.$slots, "prepend"), K.value.length === 1 && K.value[0].icon && !v.badges ? (x(), f(w(t), ce(y({ key: 0 }, K.value[0].icon)), null, 16)) : p("v-if", !0)]),
454
+ key: "0"
455
+ } : void 0, e.$slots.extras ? {
456
+ name: "extras",
457
+ fn: D(() => [S(e.$slots, "extras")]),
458
+ key: "1"
459
+ } : void 0]), 1032, [
460
+ "id",
461
+ "label",
462
+ "for",
463
+ "label-position",
464
+ "required",
465
+ "class",
466
+ "readonly",
357
467
  "disabled",
358
- "removable",
468
+ "data-loading",
469
+ "size",
470
+ "invalid",
471
+ "help",
472
+ "help-display",
359
473
  "icons",
360
474
  "texts"
361
- ]))], 512)) : (S(), m("span", be, w(W.value), 1))], 64))]), he(h("input", y({
362
- id: N.value,
363
- ref: "input",
364
- "onUpdate:modelValue": l[0] ||= (e) => W.value = e
365
- }, e.$attrs, {
366
- "aria-describedby": T(i)(n, Oe.value),
367
- class: "q-select__input",
368
- inputmode: "none",
369
- type: "text",
370
- autocomplete: "off",
371
- tabindex: v.disabled ? -1 : 0,
372
- role: "combobox",
373
- "aria-expanded": P.value,
374
- "aria-controls": P.value ? Ee.value : void 0,
375
- "aria-haspopup": "listbox",
376
- "aria-keyshortcuts": G.value ? "Delete" : void 0,
377
- onKeydown: qe
378
- }), null, 16, Se), [[me, W.value]])]),
379
- append: O(() => [
380
- C(e.$slots, "append"),
381
- G.value ? (S(), f(T(re), {
382
- key: 0,
383
- icons: v.icons,
384
- texts: v.texts,
385
- onClick: J
386
- }, null, 8, ["icons", "texts"])) : p("v-if", !0),
387
- v.readonly ? p("v-if", !0) : (S(), f(T(a), {
388
- key: 1,
389
- class: "q-select__chevron",
390
- "aria-label": v.texts.showOptions,
391
- variant: "ghost",
392
- color: "neutral",
393
- borderless: "",
394
- tabindex: -1,
395
- disabled: v.disabled,
396
- onClick: Ke
397
- }, {
398
- default: O(() => [_(T(o), {
399
- "model-value": P.value,
400
- icons: v.icons
401
- }, null, 8, ["model-value", "icons"])]),
402
- _: 1
403
- }, 8, ["aria-label", "disabled"]))
404
475
  ]),
405
- _: 2
406
- }, [U.value.length === 1 && U.value[0].icon && !v.badges || e.$slots.prepend ? {
407
- name: "prepend",
408
- fn: O(() => [C(e.$slots, "prepend"), U.value.length === 1 && U.value[0].icon && !v.badges ? (S(), f(T(t), oe(y({ key: 0 }, U.value[0].icon)), null, 16)) : p("v-if", !0)]),
409
- key: "0"
410
- } : void 0, e.$slots.extras ? {
411
- name: "extras",
412
- fn: O(() => [C(e.$slots, "extras")]),
413
- key: "1"
414
- } : void 0]), 1032, [
415
- "id",
416
- "label",
417
- "for",
418
- "label-position",
419
- "required",
420
- "class",
421
- "readonly",
422
- "disabled",
423
- "data-loading",
424
- "size",
425
- "invalid",
426
- "help",
427
- "help-display",
428
- "icons",
429
- "texts"
430
- ]), _(T(n), {
431
- modelValue: P.value,
432
- "onUpdate:modelValue": l[1] ||= (e) => P.value = e,
433
- spy: "",
434
- "non-modal": "",
435
- trigger: "manual",
436
- placement: "bottom-start",
437
- width: De.value,
438
- "scroll-lock": "",
439
- inline: v.inline,
440
- anchor: v.overlayAnchor ?? L.value?.fieldRef,
441
- offset: 2,
442
- onEnter: Je,
443
- onLeave: Ye
444
- }, {
445
- default: O(() => [h("div", {
446
- ref: "content",
447
- "data-testid": "combobox-dropdown",
448
- "data-key": T(M),
449
- class: "q-select__body",
450
- tabindex: "-1",
451
- onFocusout: Ue,
452
- onKeydown: ge(X, ["stop"])
453
- }, [
454
- C(e.$slots, "body.prepend"),
455
- v.loading ? (S(), m("div", we, [_(T(r), { size: 24 })])) : (S(), f(T(te), {
456
- key: 1,
457
- id: Ee.value,
458
- ref: "list",
459
- class: x(["q-select__items", `q-select__items--${v.overflow}`]),
460
- label: v.label,
461
- selectable: "",
462
- icons: v.icons,
463
- required: v.required,
464
- multiple: v.multiple,
465
- "model-value": j.value,
466
- items: v.items,
467
- groups: c.groups,
468
- "item-label": v.itemLabel,
469
- "item-value": v.itemValue,
470
- "item-title": v.overflow === "truncate",
471
- "select-on-tab": v.selectOnTab,
472
- "onUpdate:modelValue": q
473
- }, {
474
- item: O(({ item: t }) => [C(e.$slots, "item", { item: t })]),
475
- _: 3
476
- }, 8, [
477
- "id",
478
- "class",
479
- "label",
480
- "icons",
481
- "required",
482
- "multiple",
483
- "model-value",
484
- "items",
485
- "groups",
486
- "item-label",
487
- "item-value",
488
- "item-title",
489
- "select-on-tab"
490
- ])),
491
- C(e.$slots, "body.append")
492
- ], 40, Ce)]),
493
- _: 3
494
- }, 8, [
495
- "modelValue",
496
- "width",
497
- "inline",
498
- "anchor"
499
- ])], 64));
476
+ h("span", we, C(Ae.value), 1),
477
+ _(w(r), {
478
+ "model-value": N.value,
479
+ spy: "",
480
+ "non-modal": "",
481
+ trigger: "manual",
482
+ placement: "bottom-start",
483
+ width: je.value,
484
+ "scroll-lock": "",
485
+ inline: v.inline,
486
+ anchor: v.overlayAnchor ?? R.value?.fieldRef,
487
+ offset: 2,
488
+ "onUpdate:modelValue": tt,
489
+ onEnter: nt,
490
+ onLeave: rt
491
+ }, {
492
+ default: D(() => [p(" eslint-disable-next-line vuejs-accessibility/no-static-element-interactions -- Takes the keys and focus of the list inside it "), h("div", {
493
+ ref: "content",
494
+ "data-testid": "combobox-dropdown",
495
+ "data-key": w(j),
496
+ class: "q-select__body",
497
+ tabindex: "-1",
498
+ onFocusout: Je,
499
+ onKeydown: _e($e, ["stop"])
500
+ }, [
501
+ S(e.$slots, "body.prepend"),
502
+ v.loading ? (x(), m("div", Ee, [_(w(a), { size: 24 })])) : v.items?.length ? (x(), f(w(te), {
503
+ key: 1,
504
+ id: ke.value,
505
+ ref: "list",
506
+ class: se(["q-select__items", `q-select__items--${v.overflow}`]),
507
+ label: Fe(),
508
+ "aria-labelledby": w(M)["aria-labelledby"],
509
+ selectable: "",
510
+ icons: v.icons,
511
+ required: v.required,
512
+ multiple: v.multiple,
513
+ "model-value": A.value,
514
+ items: v.items,
515
+ groups: l.groups,
516
+ "item-label": v.itemLabel,
517
+ "item-value": v.itemValue,
518
+ "item-title": v.overflow === "truncate",
519
+ "select-on-tab": v.selectOnTab,
520
+ "onUpdate:modelValue": X
521
+ }, {
522
+ item: D(({ item: t }) => [S(e.$slots, "item", { item: t })]),
523
+ _: 3
524
+ }, 8, [
525
+ "id",
526
+ "class",
527
+ "label",
528
+ "aria-labelledby",
529
+ "icons",
530
+ "required",
531
+ "multiple",
532
+ "model-value",
533
+ "items",
534
+ "groups",
535
+ "item-label",
536
+ "item-value",
537
+ "item-title",
538
+ "select-on-tab"
539
+ ])) : (x(), m("div", De, C(v.texts.noData), 1)),
540
+ S(e.$slots, "body.append")
541
+ ], 40, Te)]),
542
+ _: 3
543
+ }, 8, [
544
+ "model-value",
545
+ "width",
546
+ "inline",
547
+ "anchor"
548
+ ])
549
+ ], 64));
500
550
  }
501
551
  });
502
552
  //#endregion
503
- export { A as default };
553
+ export { k as default };