@quidgest/ui 0.11.0 → 0.12.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 (200) hide show
  1. package/dist/manifest/components.json +24 -0
  2. package/dist/ui.css +5 -2
  3. package/dist/ui.esm.js +630 -600
  4. package/dist/ui.js +8 -5
  5. package/dist/ui.min.css +1 -1
  6. package/dist/ui.min.js +146 -132
  7. package/dist/ui.scss +6 -3
  8. package/esm/components/QButton/QButton.d.ts +92 -0
  9. package/esm/components/QButton/QButton.d.ts.map +1 -0
  10. package/esm/components/QButton/QButton.vue.js +87 -0
  11. package/esm/components/QButton/QButton.vue2.js +4 -0
  12. package/esm/components/QButton/index.d.ts +4 -0
  13. package/esm/components/QButton/index.d.ts.map +1 -0
  14. package/esm/components/QButtonGroup/QButtonGroup.d.ts +51 -0
  15. package/esm/components/QButtonGroup/QButtonGroup.d.ts.map +1 -0
  16. package/esm/components/QButtonGroup/QButtonGroup.vue.js +41 -0
  17. package/esm/components/QButtonGroup/QButtonGroup.vue2.js +4 -0
  18. package/esm/components/QButtonGroup/index.d.ts +4 -0
  19. package/esm/components/QButtonGroup/index.d.ts.map +1 -0
  20. package/esm/components/QButtonToggle/QButtonToggle.d.ts +81 -0
  21. package/esm/components/QButtonToggle/QButtonToggle.d.ts.map +1 -0
  22. package/esm/components/QButtonToggle/QButtonToggle.vue.js +58 -0
  23. package/esm/components/QButtonToggle/QButtonToggle.vue2.js +4 -0
  24. package/esm/components/QButtonToggle/index.d.ts +4 -0
  25. package/esm/components/QButtonToggle/index.d.ts.map +1 -0
  26. package/esm/components/QCombobox/QCombobox.d.ts +524 -0
  27. package/esm/components/QCombobox/QCombobox.d.ts.map +1 -0
  28. package/esm/components/QCombobox/QCombobox.vue.js +381 -0
  29. package/esm/components/QCombobox/QCombobox.vue2.js +4 -0
  30. package/esm/components/QCombobox/index.d.ts +4 -0
  31. package/esm/components/QCombobox/index.d.ts.map +1 -0
  32. package/esm/components/QField/QField.d.ts +89 -0
  33. package/esm/components/QField/QField.d.ts.map +1 -0
  34. package/esm/components/QField/QField.vue.js +81 -0
  35. package/esm/components/QField/QField.vue2.js +4 -0
  36. package/esm/components/QField/index.d.ts +5 -0
  37. package/esm/components/QField/index.d.ts.map +1 -0
  38. package/esm/components/QField/index.js +6 -0
  39. package/esm/components/QIcon/InlineSvg.d.ts +110 -0
  40. package/esm/components/QIcon/InlineSvg.d.ts.map +1 -0
  41. package/esm/components/QIcon/InlineSvg.js +139 -0
  42. package/esm/components/QIcon/QIcon.d.ts +50 -0
  43. package/esm/components/QIcon/QIcon.d.ts.map +1 -0
  44. package/esm/components/QIcon/QIcon.vue.js +36 -0
  45. package/esm/components/QIcon/QIcon.vue2.js +4 -0
  46. package/esm/components/QIcon/QIconFont.d.ts +57 -0
  47. package/esm/components/QIcon/QIconFont.d.ts.map +1 -0
  48. package/esm/components/QIcon/QIconFont.vue.js +29 -0
  49. package/esm/components/QIcon/QIconFont.vue2.js +4 -0
  50. package/esm/components/QIcon/QIconImg.d.ts +38 -0
  51. package/esm/components/QIcon/QIconImg.d.ts.map +1 -0
  52. package/esm/components/QIcon/QIconImg.vue.js +22 -0
  53. package/esm/components/QIcon/QIconImg.vue2.js +4 -0
  54. package/esm/components/QIcon/QIconSvg.d.ts +72 -0
  55. package/esm/components/QIcon/QIconSvg.d.ts.map +1 -0
  56. package/esm/components/QIcon/QIconSvg.vue.js +34 -0
  57. package/esm/components/QIcon/QIconSvg.vue2.js +4 -0
  58. package/esm/components/QIcon/index.d.ts +8 -0
  59. package/esm/components/QIcon/index.d.ts.map +1 -0
  60. package/esm/components/QIcon/index.js +15 -0
  61. package/esm/components/QInputGroup/QInputGroup.d.ts +85 -0
  62. package/esm/components/QInputGroup/QInputGroup.d.ts.map +1 -0
  63. package/esm/components/QInputGroup/QInputGroup.vue.js +79 -0
  64. package/esm/components/QInputGroup/QInputGroup.vue2.js +4 -0
  65. package/esm/components/QInputGroup/index.d.ts +4 -0
  66. package/esm/components/QInputGroup/index.d.ts.map +1 -0
  67. package/esm/components/QLineLoader/QLineLoader.d.ts +32 -0
  68. package/esm/components/QLineLoader/QLineLoader.d.ts.map +1 -0
  69. package/esm/components/QLineLoader/QLineLoader.vue.js +22 -0
  70. package/esm/components/QLineLoader/QLineLoader.vue2.js +4 -0
  71. package/esm/components/QLineLoader/index.d.ts +4 -0
  72. package/esm/components/QLineLoader/index.d.ts.map +1 -0
  73. package/esm/components/QList/QList.d.ts +159 -0
  74. package/esm/components/QList/QList.d.ts.map +1 -0
  75. package/esm/components/QList/QList.vue.js +186 -0
  76. package/esm/components/QList/QList.vue2.js +4 -0
  77. package/esm/components/QList/QListItem.d.ts +82 -0
  78. package/esm/components/QList/QListItem.d.ts.map +1 -0
  79. package/esm/components/QList/QListItem.vue.js +75 -0
  80. package/esm/components/QList/QListItem.vue2.js +4 -0
  81. package/esm/components/QList/QListItemGroup.d.ts +43 -0
  82. package/esm/components/QList/QListItemGroup.d.ts.map +1 -0
  83. package/esm/components/QList/QListItemGroup.vue.js +29 -0
  84. package/esm/components/QList/QListItemGroup.vue2.js +4 -0
  85. package/esm/components/QList/index.d.ts +7 -0
  86. package/esm/components/QList/index.d.ts.map +1 -0
  87. package/esm/components/QList/index.js +12 -0
  88. package/esm/components/QOverlay/QOverlay.d.ts +236 -0
  89. package/esm/components/QOverlay/QOverlay.d.ts.map +1 -0
  90. package/esm/components/QOverlay/QOverlay.vue.js +250 -0
  91. package/esm/components/QOverlay/QOverlay.vue2.js +4 -0
  92. package/esm/components/QOverlay/index.d.ts +4 -0
  93. package/esm/components/QOverlay/index.d.ts.map +1 -0
  94. package/esm/components/QOverlay/index.js +6 -0
  95. package/esm/components/QPopover/QPopover.d.ts +132 -0
  96. package/esm/components/QPopover/QPopover.d.ts.map +1 -0
  97. package/esm/components/QPopover/QPopover.vue.js +71 -0
  98. package/esm/components/QPopover/QPopover.vue2.js +4 -0
  99. package/esm/components/QPopover/index.d.ts +4 -0
  100. package/esm/components/QPopover/index.d.ts.map +1 -0
  101. package/esm/components/QSelect/QSelect.d.ts +265 -0
  102. package/esm/components/QSelect/QSelect.d.ts.map +1 -0
  103. package/esm/components/QSelect/QSelect.vue.js +317 -0
  104. package/esm/components/QSelect/QSelect.vue2.js +4 -0
  105. package/esm/components/QSelect/index.d.ts +4 -0
  106. package/esm/components/QSelect/index.d.ts.map +1 -0
  107. package/esm/components/QSkeletonLoader/QSkeletonLoader.d.ts +46 -0
  108. package/esm/components/QSkeletonLoader/QSkeletonLoader.d.ts.map +1 -0
  109. package/esm/components/QSkeletonLoader/QSkeletonLoader.vue.js +39 -0
  110. package/esm/components/QSkeletonLoader/QSkeletonLoader.vue2.js +4 -0
  111. package/esm/components/QSkeletonLoader/index.d.ts +4 -0
  112. package/esm/components/QSkeletonLoader/index.d.ts.map +1 -0
  113. package/esm/components/QSpinnerLoader/QSpinnerLoader.d.ts +39 -0
  114. package/esm/components/QSpinnerLoader/QSpinnerLoader.d.ts.map +1 -0
  115. package/esm/components/QSpinnerLoader/QSpinnerLoader.vue.js +26 -0
  116. package/esm/components/QSpinnerLoader/QSpinnerLoader.vue2.js +4 -0
  117. package/esm/components/QSpinnerLoader/index.d.ts +4 -0
  118. package/esm/components/QSpinnerLoader/index.d.ts.map +1 -0
  119. package/esm/components/QSpinnerLoader/index.js +6 -0
  120. package/esm/components/QTextField/QTextField.d.ts +162 -0
  121. package/esm/components/QTextField/QTextField.d.ts.map +1 -0
  122. package/esm/components/QTextField/QTextField.vue.js +99 -0
  123. package/esm/components/QTextField/QTextField.vue2.js +4 -0
  124. package/esm/components/QTextField/index.d.ts +4 -0
  125. package/esm/components/QTextField/index.d.ts.map +1 -0
  126. package/esm/components/QTextField/index.js +6 -0
  127. package/esm/components/QThemeProvider/QThemeProvider.d.ts +25 -0
  128. package/esm/components/QThemeProvider/QThemeProvider.d.ts.map +1 -0
  129. package/esm/components/QThemeProvider/QThemeProvider.vue.js +24 -0
  130. package/esm/components/QThemeProvider/QThemeProvider.vue2.js +4 -0
  131. package/esm/components/QThemeProvider/index.d.ts +4 -0
  132. package/esm/components/QThemeProvider/index.d.ts.map +1 -0
  133. package/esm/components/QTooltip/QTooltip.d.ts +189 -0
  134. package/esm/components/QTooltip/QTooltip.d.ts.map +1 -0
  135. package/esm/components/QTooltip/QTooltip.vue.js +74 -0
  136. package/esm/components/QTooltip/QTooltip.vue2.js +4 -0
  137. package/esm/components/QTooltip/index.d.ts +4 -0
  138. package/esm/components/QTooltip/index.d.ts.map +1 -0
  139. package/esm/components/index.d.ts +18 -0
  140. package/esm/components/index.d.ts.map +1 -0
  141. package/esm/components/index.js +46 -0
  142. package/esm/composables/defaults.d.ts +25 -0
  143. package/esm/composables/defaults.d.ts.map +1 -0
  144. package/esm/composables/defaults.js +33 -0
  145. package/esm/composables/index.d.ts +2 -0
  146. package/esm/composables/index.d.ts.map +1 -0
  147. package/esm/composables/overlay.d.ts +116 -0
  148. package/esm/composables/overlay.d.ts.map +1 -0
  149. package/esm/composables/overlay.js +142 -0
  150. package/esm/composables/theme.d.ts +18 -0
  151. package/esm/composables/theme.d.ts.map +1 -0
  152. package/esm/composables/theme.js +20 -0
  153. package/esm/composables/uid.d.ts +8 -0
  154. package/esm/composables/uid.d.ts.map +1 -0
  155. package/esm/composables/uid.js +7 -0
  156. package/esm/framework.d.ts +29 -0
  157. package/esm/framework.d.ts.map +1 -0
  158. package/esm/framework.js +47 -0
  159. package/esm/index.d.ts +35 -0
  160. package/esm/index.d.ts.map +1 -0
  161. package/esm/index.js +12 -0
  162. package/esm/templates/index.d.ts +2 -0
  163. package/esm/templates/index.d.ts.map +1 -0
  164. package/esm/templates/index.js +5 -0
  165. package/esm/templates/theme.d.ts +5 -0
  166. package/esm/templates/theme.d.ts.map +1 -0
  167. package/esm/templates/theme.js +67 -0
  168. package/esm/types/primitive.d.ts +2 -0
  169. package/esm/types/primitive.d.ts.map +1 -0
  170. package/esm/utils/color.d.ts +105 -0
  171. package/esm/utils/color.d.ts.map +1 -0
  172. package/esm/utils/color.js +14 -0
  173. package/esm/utils/getCurrentInstance.d.ts +2 -0
  174. package/esm/utils/getCurrentInstance.d.ts.map +1 -0
  175. package/esm/utils/getElement.d.ts +6 -0
  176. package/esm/utils/getElement.d.ts.map +1 -0
  177. package/esm/utils/getElement.js +6 -0
  178. package/esm/utils/isEmpty.d.ts +2 -0
  179. package/esm/utils/isEmpty.d.ts.map +1 -0
  180. package/esm/utils/isEmpty.js +6 -0
  181. package/esm/utils/isObject.d.ts +2 -0
  182. package/esm/utils/isObject.d.ts.map +1 -0
  183. package/esm/utils/isObject.js +6 -0
  184. package/esm/utils/merge.d.ts +2 -0
  185. package/esm/utils/merge.d.ts.map +1 -0
  186. package/esm/utils/merge.js +21 -0
  187. package/esm/utils/setupPropsProxy.d.ts +12 -0
  188. package/esm/utils/setupPropsProxy.d.ts.map +1 -0
  189. package/esm/utils/setupPropsProxy.js +32 -0
  190. package/esm/utils/string.d.ts +7 -0
  191. package/esm/utils/string.d.ts.map +1 -0
  192. package/esm/utils/string.js +6 -0
  193. package/esm/utils/theme.d.ts +22 -0
  194. package/esm/utils/theme.d.ts.map +1 -0
  195. package/esm/utils/theme.js +40 -0
  196. package/package.json +46 -49
  197. package/dist/index.d.ts +0 -4076
  198. package/dist/ui.esm.js.map +0 -1
  199. package/dist/ui.js.map +0 -1
  200. package/dist/ui.min.js.map +0 -1
@@ -0,0 +1,381 @@
1
+ import { defineComponent as re, mergeModels as K, useModel as C, ref as k, onMounted as ce, computed as v, watch as I, nextTick as w, openBlock as y, createElementBlock as S, Fragment as fe, createVNode as V, unref as c, normalizeClass as me, withModifiers as j, createSlots as ve, withCtx as r, renderSlot as f, createBlock as T, normalizeProps as Q, guardReactiveProps as W, createCommentVNode as X, createElementVNode as pe, toDisplayString as be } from "vue";
2
+ import G from "../QButton/QButton.vue.js";
3
+ import "../QIcon/index.js";
4
+ import "../QList/index.js";
5
+ import "../QOverlay/index.js";
6
+ import "../QSpinnerLoader/index.js";
7
+ import "../QTextField/index.js";
8
+ import ye from "../QTextField/QTextField.vue.js";
9
+ import J from "../QIcon/QIcon.vue.js";
10
+ import he from "../QOverlay/QOverlay.vue.js";
11
+ import ge from "../QSpinnerLoader/QSpinnerLoader.vue.js";
12
+ import ke from "../QList/QList.vue.js";
13
+ const Ie = ["data-key"], we = {
14
+ key: 0,
15
+ class: "q-select__loader"
16
+ }, Ve = {
17
+ key: 2,
18
+ class: "q-select__loader"
19
+ }, xe = {
20
+ noData: "No data available"
21
+ }, _e = {
22
+ chevron: {
23
+ icon: "chevron-down"
24
+ },
25
+ clear: {
26
+ icon: "close"
27
+ }
28
+ }, ze = /* @__PURE__ */ re({
29
+ __name: "QCombobox",
30
+ props: /* @__PURE__ */ K({
31
+ id: { default: void 0 },
32
+ placeholder: { default: "" },
33
+ selectionMode: { default: "automatic" },
34
+ filterMode: { default: "builtin" },
35
+ label: { default: "" },
36
+ clearable: { type: Boolean },
37
+ readonly: { type: Boolean },
38
+ disabled: { type: Boolean },
39
+ required: { type: Boolean },
40
+ loading: { type: Boolean },
41
+ items: {},
42
+ groups: { default: () => [] },
43
+ itemValue: { default: "key" },
44
+ itemLabel: { default: "label" },
45
+ emptyValue: { type: [String, Number, Boolean, Symbol], default: void 0 },
46
+ size: { default: void 0 },
47
+ texts: { default: () => xe },
48
+ icons: { default: () => _e },
49
+ class: { default: void 0 }
50
+ }, {
51
+ modelValue: {
52
+ type: [String, Number, Boolean, Symbol]
53
+ },
54
+ modelModifiers: {},
55
+ open: { type: Boolean },
56
+ openModifiers: {},
57
+ search: { default: "" },
58
+ searchModifiers: {}
59
+ }),
60
+ emits: /* @__PURE__ */ K(["before-show", "before-hide", "show", "hide"], ["update:modelValue", "update:open", "update:search"]),
61
+ setup(x, { expose: Y, emit: Z }) {
62
+ const l = x, _ = Z, d = C(x, "modelValue"), i = C(x, "open"), s = C(x, "search"), t = k(void 0), m = k(null), u = k(null), $ = k(null), L = k(null);
63
+ ce(g);
64
+ const M = v(() => l.clearable && !l.readonly && !l.disabled), p = v(() => {
65
+ var e;
66
+ return l.filterMode === "manual" || !le.value ? l.items : (e = l.items) == null ? void 0 : e.filter(
67
+ (o) => o[l.itemLabel].toLowerCase().startsWith(s.value.toLowerCase())
68
+ );
69
+ }), h = v(() => {
70
+ var e;
71
+ return (e = l.items) == null ? void 0 : e.find((o) => o[l.itemValue] === d.value);
72
+ }), A = v(() => h.value === void 0), D = v(() => {
73
+ const e = t.value;
74
+ if (e !== void 0 && p.value[e])
75
+ return p.value[e];
76
+ }), ee = v(() => {
77
+ var o;
78
+ if (t.value === void 0)
79
+ return;
80
+ const e = (o = u.value) == null ? void 0 : o.getItem(t.value);
81
+ return e == null ? void 0 : e.id;
82
+ }), le = v(() => {
83
+ var e;
84
+ return s.value.length > 0 && s.value !== ((e = h.value) == null ? void 0 : e[l.itemLabel]);
85
+ });
86
+ function z(e) {
87
+ d.value = e, F();
88
+ }
89
+ function g() {
90
+ var o;
91
+ const e = ((o = h.value) == null ? void 0 : o[l.itemLabel]) || "";
92
+ s.value !== e && (s.value = e);
93
+ }
94
+ function B() {
95
+ i.value || l.readonly || l.disabled || (_("before-show"), i.value = !0, E());
96
+ }
97
+ function F() {
98
+ i.value && (_("before-hide"), i.value = !1, t.value = void 0);
99
+ }
100
+ function oe() {
101
+ i.value ? F() : N();
102
+ }
103
+ function ae() {
104
+ M.value && (d.value = l.emptyValue, t.value = void 0, E());
105
+ }
106
+ function N() {
107
+ if (B(), h.value !== void 0) {
108
+ const e = p.value.indexOf(h.value);
109
+ e !== -1 && w(() => O(e));
110
+ }
111
+ }
112
+ function te(e) {
113
+ var o, a;
114
+ if (!(!e.key || l.readonly || l.disabled))
115
+ if (["ArrowDown", "ArrowUp", "Home", "End"].includes(e.key) && (e.preventDefault(), e.stopPropagation()), e.key === "Escape")
116
+ g(), i.value && F();
117
+ else if (["ArrowDown", "ArrowUp"].includes(e.key))
118
+ i.value ? w(() => {
119
+ if (t.value === void 0)
120
+ q();
121
+ else {
122
+ const n = e.key === "ArrowDown" ? "next" : "prev";
123
+ ie(t.value, n);
124
+ }
125
+ }) : (B(), w(() => {
126
+ e.key === "ArrowDown" ? q() : ne();
127
+ }));
128
+ else if (e.key === "Enter") {
129
+ if (D.value === void 0)
130
+ return;
131
+ z(D.value[l.itemValue]);
132
+ } else
133
+ e.key === "Home" ? t.value = (o = u.value) == null ? void 0 : o.getFirstFocusableItemIndex() : e.key === "End" ? t.value = (a = u.value) == null ? void 0 : a.getLastFocusableItemIndex() : (/^[a-z]$/i.test(e.key) || e.key === "Backspace") && B();
134
+ }
135
+ function q() {
136
+ var e, o;
137
+ if (A.value)
138
+ t.value = (o = u.value) == null ? void 0 : o.getFirstFocusableItemIndex();
139
+ else {
140
+ const a = p.value.findIndex(
141
+ (n) => n[l.itemValue] === d.value
142
+ );
143
+ a === -1 ? t.value = (e = u.value) == null ? void 0 : e.getFirstFocusableItemIndex() : t.value = a;
144
+ }
145
+ }
146
+ function ne() {
147
+ var e;
148
+ t.value = (e = u.value) == null ? void 0 : e.getLastFocusableItemIndex();
149
+ }
150
+ function ie(e, o) {
151
+ var a;
152
+ t.value = (a = u.value) == null ? void 0 : a.getAdjacentItemIndex(e, o);
153
+ }
154
+ function U(e) {
155
+ var b, P, R, H;
156
+ const o = ((b = $ == null ? void 0 : $.value) == null ? void 0 : b.$el) === e.relatedTarget, a = (R = (P = m == null ? void 0 : m.value) == null ? void 0 : P.$el) == null ? void 0 : R.contains(e.relatedTarget), n = (H = L == null ? void 0 : L.value) == null ? void 0 : H.contains(e.relatedTarget);
157
+ if (o || n || a) {
158
+ e.preventDefault(), e.stopPropagation();
159
+ return;
160
+ }
161
+ F(), M.value && !s.value && (d.value = l.emptyValue), g();
162
+ }
163
+ function E() {
164
+ var e, o;
165
+ (o = (e = m.value) == null ? void 0 : e.inputRef) == null || o.focus();
166
+ }
167
+ function se() {
168
+ E();
169
+ }
170
+ function ue() {
171
+ _("show");
172
+ }
173
+ function de() {
174
+ _("hide");
175
+ }
176
+ function O(e) {
177
+ var a;
178
+ const o = (a = u.value) == null ? void 0 : a.getItem(e);
179
+ u.value && (u.value.$el.scrollTop = o == null ? void 0 : o.offsetTop);
180
+ }
181
+ return I(d, g), I(
182
+ () => l.items,
183
+ (e, o) => {
184
+ if (!A.value) {
185
+ const a = o.find((n) => n[l.itemValue] === d.value);
186
+ s.value === (a == null ? void 0 : a[l.itemLabel]) && g();
187
+ }
188
+ },
189
+ { deep: !0 }
190
+ ), I(t, (e) => {
191
+ e !== void 0 && O(e);
192
+ }), I(s, (e) => {
193
+ e && i.value && l.selectionMode === "automatic" && w(q);
194
+ }), I(
195
+ () => l.loading,
196
+ (e) => {
197
+ !e && i.value && w(q);
198
+ }
199
+ ), Y({
200
+ triggerEl: m
201
+ }), (e, o) => {
202
+ var a;
203
+ return y(), S(
204
+ fe,
205
+ null,
206
+ [
207
+ V(c(ye), {
208
+ modelValue: s.value,
209
+ "onUpdate:modelValue": o[0] || (o[0] = (n) => s.value = n),
210
+ id: l.id,
211
+ label: l.label,
212
+ required: l.required,
213
+ ref_key: "triggerEl",
214
+ ref: m,
215
+ role: "combobox",
216
+ placeholder: l.placeholder,
217
+ class: me([
218
+ "q-combobox",
219
+ {
220
+ "q-combobox--readonly": l.readonly,
221
+ "q-combobox--disabled": l.disabled,
222
+ "q-combobox--expanded": i.value
223
+ },
224
+ l.class
225
+ ]),
226
+ readonly: l.readonly,
227
+ disabled: l.disabled,
228
+ "data-loading": l.loading,
229
+ autocomplete: "off",
230
+ "aria-expanded": i.value,
231
+ "aria-haspopup": "listbox",
232
+ "aria-autocomplete": "list",
233
+ "aria-activedescendant": ee.value,
234
+ size: l.size,
235
+ onClick: N,
236
+ onFocusout: U,
237
+ onKeydown: j(te, ["stop"])
238
+ }, ve({
239
+ "label.prepend": r(() => [
240
+ f(e.$slots, "label.prepend")
241
+ ]),
242
+ "label.append": r(() => [
243
+ f(e.$slots, "label.append")
244
+ ]),
245
+ append: r(() => [
246
+ f(e.$slots, "append"),
247
+ M.value && s.value ? (y(), T(c(G), {
248
+ key: 0,
249
+ class: "q-combobox__clear",
250
+ "b-style": "plain",
251
+ borderless: "",
252
+ tabindex: "-1",
253
+ onClick: ae
254
+ }, {
255
+ default: r(() => [
256
+ V(
257
+ c(J),
258
+ Q(W(l.icons.clear)),
259
+ null,
260
+ 16
261
+ /* FULL_PROPS */
262
+ )
263
+ ]),
264
+ _: 1
265
+ /* STABLE */
266
+ })) : X("v-if", !0),
267
+ l.readonly ? X("v-if", !0) : (y(), T(c(G), {
268
+ key: 1,
269
+ ref_key: "toggleRef",
270
+ ref: $,
271
+ class: "q-combobox__chevron",
272
+ "b-style": "plain",
273
+ borderless: "",
274
+ tabindex: "-1",
275
+ disabled: l.disabled,
276
+ onMousedown: j(oe, ["stop", "prevent"])
277
+ }, {
278
+ default: r(() => [
279
+ V(
280
+ c(J),
281
+ Q(W(l.icons.chevron)),
282
+ null,
283
+ 16
284
+ /* FULL_PROPS */
285
+ )
286
+ ]),
287
+ _: 1
288
+ /* STABLE */
289
+ }, 8, ["disabled"]))
290
+ ]),
291
+ _: 2
292
+ /* DYNAMIC */
293
+ }, [
294
+ e.$slots.prepend ? {
295
+ name: "prepend",
296
+ fn: r(() => [
297
+ f(e.$slots, "prepend")
298
+ ]),
299
+ key: "0"
300
+ } : void 0,
301
+ e.$slots.extras ? {
302
+ name: "extras",
303
+ fn: r(() => [
304
+ f(e.$slots, "extras")
305
+ ]),
306
+ key: "1"
307
+ } : void 0
308
+ ]), 1032, ["modelValue", "id", "label", "required", "placeholder", "class", "readonly", "disabled", "data-loading", "aria-expanded", "aria-activedescendant", "size"]),
309
+ V(c(he), {
310
+ modelValue: i.value,
311
+ "onUpdate:modelValue": o[2] || (o[2] = (n) => i.value = n),
312
+ spy: "",
313
+ "non-modal": "",
314
+ trigger: "manual",
315
+ placement: "bottom-start",
316
+ width: "anchor",
317
+ offset: 4,
318
+ anchor: (a = m.value) == null ? void 0 : a.$el,
319
+ onEnter: ue,
320
+ onLeave: de
321
+ }, {
322
+ default: r(() => {
323
+ var n;
324
+ return [
325
+ pe("div", {
326
+ ref_key: "contentRef",
327
+ ref: L,
328
+ class: "q-select__body",
329
+ "data-testid": "combobox-dropdown",
330
+ "data-key": l.id,
331
+ onFocusout: U
332
+ }, [
333
+ f(e.$slots, "body.prepend"),
334
+ l.loading ? (y(), S("div", we, [
335
+ V(c(ge), { size: 24 })
336
+ ])) : p.value.length ? (y(), T(c(ke), {
337
+ key: 1,
338
+ ref_key: "listRef",
339
+ ref: u,
340
+ class: "q-select__items",
341
+ modelValue: d.value,
342
+ "onUpdate:modelValue": [
343
+ o[1] || (o[1] = (b) => d.value = b),
344
+ z
345
+ ],
346
+ highlighted: (n = D.value) == null ? void 0 : n[l.itemValue],
347
+ items: p.value,
348
+ groups: e.groups,
349
+ "item-label": l.itemLabel,
350
+ "item-value": l.itemValue,
351
+ onMouseup: se
352
+ }, {
353
+ item: r(({ item: b }) => [
354
+ f(e.$slots, "item", { item: b })
355
+ ]),
356
+ _: 3
357
+ /* FORWARDED */
358
+ }, 8, ["modelValue", "highlighted", "items", "groups", "item-label", "item-value"])) : (y(), S(
359
+ "div",
360
+ Ve,
361
+ be(e.texts.noData),
362
+ 1
363
+ /* TEXT */
364
+ )),
365
+ f(e.$slots, "body.append")
366
+ ], 40, Ie)
367
+ ];
368
+ }),
369
+ _: 3
370
+ /* FORWARDED */
371
+ }, 8, ["modelValue", "anchor"])
372
+ ],
373
+ 64
374
+ /* STABLE_FRAGMENT */
375
+ );
376
+ };
377
+ }
378
+ });
379
+ export {
380
+ ze as default
381
+ };
@@ -0,0 +1,4 @@
1
+ import f from "./QCombobox.vue.js";
2
+ export {
3
+ f as default
4
+ };
@@ -0,0 +1,4 @@
1
+ import { default as QCombobox } from "./QCombobox";
2
+
3
+ export { QCombobox };
4
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/QCombobox/index.ts"],"names":[],"mappings":"AACA,OAAO,SAAS,MAAM,iBAAiB,CAAA;AAQvC,OAAO,EAAE,SAAS,EAAE,CAAA"}
@@ -0,0 +1,89 @@
1
+ export type QFieldSize = 'mini' | 'small' | 'medium' | 'large' | 'xlarge' | 'xxlarge' | 'block';
2
+ export type QFieldProps = {
3
+ /**
4
+ * The field unique identifier.
5
+ */
6
+ id?: string;
7
+ /**
8
+ * The label of the input.
9
+ */
10
+ label?: string;
11
+ /**
12
+ * The form field associated with the label.
13
+ */
14
+ for?: string;
15
+ /**
16
+ * The size category of the field.
17
+ */
18
+ size?: QFieldSize;
19
+ /**
20
+ * Whether the input is readonly.
21
+ */
22
+ readonly?: boolean;
23
+ /**
24
+ * Whether the input is disabled.
25
+ */
26
+ disabled?: boolean;
27
+ /**
28
+ * If set to true, an asterisk (*) is displayed
29
+ * to indicate that the field is required.
30
+ */
31
+ required?: boolean;
32
+ /**
33
+ * Custom set of classes to apply to the component.
34
+ */
35
+ class?: string | unknown[];
36
+ };
37
+ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<QFieldProps>, {
38
+ id: undefined;
39
+ label: string;
40
+ for: undefined;
41
+ size: string;
42
+ class: undefined;
43
+ }>, {
44
+ fieldRef: import('vue').Ref<HTMLElement | null>;
45
+ }, unknown, {}, {}, import('vue').ComponentOptionsMixin, import('vue').ComponentOptionsMixin, {}, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<__VLS_WithDefaults<__VLS_TypePropsToRuntimeProps<QFieldProps>, {
46
+ id: undefined;
47
+ label: string;
48
+ for: undefined;
49
+ size: string;
50
+ class: undefined;
51
+ }>>>, {
52
+ size: QFieldSize;
53
+ class: string | unknown[];
54
+ label: string;
55
+ id: string;
56
+ for: string;
57
+ }, {}>, {
58
+ "label.prepend"?(_: {}): any;
59
+ "label.append"?(_: {}): any;
60
+ control?(_: {}): any;
61
+ prepend?(_: {}): any;
62
+ default?(_: {}): any;
63
+ append?(_: {}): any;
64
+ extras?(_: {}): any;
65
+ }>;
66
+ export default _default;
67
+ type __VLS_NonUndefinedable<T> = T extends undefined ? never : T;
68
+ type __VLS_TypePropsToRuntimeProps<T> = {
69
+ [K in keyof T]-?: {} extends Pick<T, K> ? {
70
+ type: import('vue').PropType<__VLS_NonUndefinedable<T[K]>>;
71
+ } : {
72
+ type: import('vue').PropType<T[K]>;
73
+ required: true;
74
+ };
75
+ };
76
+ type __VLS_WithDefaults<P, D> = {
77
+ [K in keyof Pick<P, keyof P>]: K extends keyof D ? __VLS_Prettify<P[K] & {
78
+ default: D[K];
79
+ }> : P[K];
80
+ };
81
+ type __VLS_Prettify<T> = {
82
+ [K in keyof T]: T[K];
83
+ } & {};
84
+ type __VLS_WithTemplateSlots<T, S> = T & {
85
+ new (): {
86
+ $slots: S;
87
+ };
88
+ };
89
+ //# sourceMappingURL=QField.vue.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"QField.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QField/QField"],"names":[],"mappings":"AA+CA;AAQC,MAAM,MAAM,UAAU,GAAG,MAAM,GAAG,OAAO,GAAG,QAAQ,GAAG,OAAO,GAAG,QAAQ,GAAG,SAAS,GAAG,OAAO,CAAA;AAE/F,MAAM,MAAM,WAAW,GAAG;IACzB;;OAEG;IACH,EAAE,CAAC,EAAE,MAAM,CAAA;IAEX;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAA;IAEd;;OAEG;IACH,GAAG,CAAC,EAAE,MAAM,CAAA;IAEZ;;OAEG;IACH,IAAI,CAAC,EAAE,UAAU,CAAA;IAEjB;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;IAElB;;OAEG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;IAElB;;;OAGG;IACH,QAAQ,CAAC,EAAE,OAAO,CAAA;IAElB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,GAAG,OAAO,EAAE,CAAA;CAC1B,CAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;AAqPF,wBAAwG;AACxG,KAAK,sBAAsB,CAAC,CAAC,IAAI,CAAC,SAAS,SAAS,GAAG,KAAK,GAAG,CAAC,CAAC;AACjE,KAAK,6BAA6B,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,CAAC,CAAC,GAAG,EAAE,SAAS,IAAI,CAAC,CAAC,EAAE,CAAC,CAAC,GAAG;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,sBAAsB,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAA;KAAE,GAAG;QAAE,IAAI,EAAE,OAAO,KAAK,EAAE,QAAQ,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC,CAAC;QAAC,QAAQ,EAAE,IAAI,CAAA;KAAE;CAAE,CAAC;AAC9M,KAAK,kBAAkB,CAAC,CAAC,EAAE,CAAC,IAAI;KAE1B,CAAC,IAAI,MAAM,IAAI,CAAC,CAAC,EAAE,MAAM,CAAC,CAAC,GAAG,CAAC,SAAS,MAAM,CAAC,GAAG,cAAc,CAAC,CAAC,CAAC,CAAC,CAAC,GAAG;QACxE,OAAO,EAAE,CAAC,CAAC,CAAC,CAAC,CAAA;KACb,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CACT,CAAC;AACN,KAAK,cAAc,CAAC,CAAC,IAAI;KAAG,CAAC,IAAI,MAAM,CAAC,GAAG,CAAC,CAAC,CAAC,CAAC;CAAG,GAAG,EAAE,CAAC;AACxD,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAAE,QAAO;QAClD,MAAM,EAAE,CAAC,CAAC;KACT,CAAA;CAAE,CAAC"}
@@ -0,0 +1,81 @@
1
+ import { defineComponent as u, ref as c, computed as _, openBlock as d, createElementBlock as o, unref as m, normalizeClass as q, renderSlot as s, createElementVNode as r, toDisplayString as v, createCommentVNode as i, mergeProps as y } from "vue";
2
+ import { useId as $ } from "../../composables/uid.js";
3
+ const b = ["id"], h = {
4
+ key: 0,
5
+ class: "q-field__label"
6
+ }, k = ["for"], B = {
7
+ key: 0,
8
+ class: "q-field__prepend"
9
+ }, z = {
10
+ key: 1,
11
+ class: "q-field__append"
12
+ }, C = {
13
+ key: 1,
14
+ class: "q-field__extras"
15
+ }, N = /* @__PURE__ */ u({
16
+ inheritAttrs: !1,
17
+ __name: "QField",
18
+ props: {
19
+ id: { default: void 0 },
20
+ label: { default: "" },
21
+ for: { default: void 0 },
22
+ size: { default: "medium" },
23
+ readonly: { type: Boolean },
24
+ disabled: { type: Boolean },
25
+ required: { type: Boolean },
26
+ class: { default: void 0 }
27
+ },
28
+ setup(a, { expose: n }) {
29
+ const e = a, f = $(e.id), t = c(null), p = _(() => e.required && !e.readonly && !e.disabled);
30
+ return n({
31
+ fieldRef: t
32
+ }), (l, R) => (d(), o("div", {
33
+ id: m(f),
34
+ class: q([
35
+ "q-field",
36
+ `q-field--${e.size}`,
37
+ {
38
+ "q-field--readonly": e.readonly,
39
+ "q-field--disabled": e.disabled,
40
+ "q-field--required": p.value
41
+ },
42
+ e.class
43
+ ])
44
+ }, [
45
+ e.label ? (d(), o("div", h, [
46
+ s(l.$slots, "label.prepend"),
47
+ r("label", {
48
+ for: e.for
49
+ }, v(e.label), 9, k),
50
+ s(l.$slots, "label.append")
51
+ ])) : i("v-if", !0),
52
+ s(l.$slots, "control", {}, () => [
53
+ r(
54
+ "div",
55
+ y({
56
+ class: "q-field__control",
57
+ ref_key: "fieldRef",
58
+ ref: t
59
+ }, l.$attrs),
60
+ [
61
+ l.$slots.prepend ? (d(), o("div", B, [
62
+ s(l.$slots, "prepend")
63
+ ])) : i("v-if", !0),
64
+ s(l.$slots, "default"),
65
+ l.$slots.append ? (d(), o("div", z, [
66
+ s(l.$slots, "append")
67
+ ])) : i("v-if", !0)
68
+ ],
69
+ 16
70
+ /* FULL_PROPS */
71
+ )
72
+ ]),
73
+ l.$slots.extras ? (d(), o("div", C, [
74
+ s(l.$slots, "extras")
75
+ ])) : i("v-if", !0)
76
+ ], 10, b));
77
+ }
78
+ });
79
+ export {
80
+ N as default
81
+ };
@@ -0,0 +1,4 @@
1
+ import f from "./QField.vue.js";
2
+ export {
3
+ f as default
4
+ };
@@ -0,0 +1,5 @@
1
+ import { default as QField, QFieldProps, QFieldSize } from "./QField";
2
+
3
+ export { QField };
4
+ export type { QFieldProps, QFieldSize };
5
+ //# sourceMappingURL=index.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../../src/components/QField/index.ts"],"names":[],"mappings":"AACA,OAAO,MAAM,MAAM,cAAc,CAAA;AAEjC,OAAO,KAAK,EAAE,WAAW,EAAE,UAAU,EAAE,MAAM,cAAc,CAAA;AAQ3D,OAAO,EAAE,MAAM,EAAE,CAAA;AAGjB,YAAY,EAAE,WAAW,EAAE,UAAU,EAAE,CAAA"}
@@ -0,0 +1,6 @@
1
+ import o from "./QField.vue.js";
2
+ import { setupPropsProxy as r } from "../../utils/setupPropsProxy.js";
3
+ r(o);
4
+ export {
5
+ o as QField
6
+ };