@quidgest/ui 0.13.2 → 0.14.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 (180) hide show
  1. package/dist/manifest/components.json +4 -0
  2. package/dist/ui.css +77 -0
  3. package/dist/ui.esm.js +1134 -912
  4. package/dist/ui.js +6 -6
  5. package/dist/ui.min.css +1 -1
  6. package/dist/ui.min.js +96 -87
  7. package/dist/ui.scss +86 -4
  8. package/esm/components/QBadge/QBadge.d.ts +10 -35
  9. package/esm/components/QBadge/QBadge.d.ts.map +1 -1
  10. package/esm/components/QBadge/QBadge.vue.js +19 -22
  11. package/esm/components/QBadge/index.d.ts +3 -139
  12. package/esm/components/QBadge/index.d.ts.map +1 -1
  13. package/esm/components/QBadge/types.d.ts +30 -0
  14. package/esm/components/QBadge/types.d.ts.map +1 -0
  15. package/esm/components/QBadge/types.js +8 -0
  16. package/esm/components/QButton/QButton.d.ts +8 -50
  17. package/esm/components/QButton/QButton.d.ts.map +1 -1
  18. package/esm/components/QButton/index.d.ts +3 -197
  19. package/esm/components/QButton/index.d.ts.map +1 -1
  20. package/esm/components/QButton/types.d.ts +47 -0
  21. package/esm/components/QButton/types.d.ts.map +1 -0
  22. package/esm/components/QButtonGroup/QButtonGroup.d.ts +7 -21
  23. package/esm/components/QButtonGroup/QButtonGroup.d.ts.map +1 -1
  24. package/esm/components/QButtonGroup/index.d.ts +3 -79
  25. package/esm/components/QButtonGroup/index.d.ts.map +1 -1
  26. package/esm/components/QButtonGroup/types.d.ts +19 -0
  27. package/esm/components/QButtonGroup/types.d.ts.map +1 -0
  28. package/esm/components/QButtonToggle/QButtonToggle.d.ts +6 -33
  29. package/esm/components/QButtonToggle/QButtonToggle.d.ts.map +1 -1
  30. package/esm/components/QButtonToggle/index.d.ts +3 -115
  31. package/esm/components/QButtonToggle/index.d.ts.map +1 -1
  32. package/esm/components/QButtonToggle/types.d.ts +32 -0
  33. package/esm/components/QButtonToggle/types.d.ts.map +1 -0
  34. package/esm/components/QCombobox/QCombobox.d.ts +266 -144
  35. package/esm/components/QCombobox/QCombobox.d.ts.map +1 -1
  36. package/esm/components/QCombobox/QCombobox.vue.js +52 -62
  37. package/esm/components/QCombobox/index.d.ts +3 -1075
  38. package/esm/components/QCombobox/index.d.ts.map +1 -1
  39. package/esm/components/QCombobox/types.d.ts +92 -0
  40. package/esm/components/QCombobox/types.d.ts.map +1 -0
  41. package/esm/components/QCombobox/types.js +14 -0
  42. package/esm/components/QDialog/QDialog.d.ts +18 -93
  43. package/esm/components/QDialog/QDialog.d.ts.map +1 -1
  44. package/esm/components/QDialog/QDialog.vue.js +45 -61
  45. package/esm/components/QDialog/index.d.ts +3 -267
  46. package/esm/components/QDialog/index.d.ts.map +1 -1
  47. package/esm/components/QDialog/types.d.ts +82 -0
  48. package/esm/components/QDialog/types.d.ts.map +1 -0
  49. package/esm/components/QDialog/types.js +23 -0
  50. package/esm/components/QField/QField.d.ts +15 -47
  51. package/esm/components/QField/QField.d.ts.map +1 -1
  52. package/esm/components/QField/index.d.ts +3 -168
  53. package/esm/components/QField/index.d.ts.map +1 -1
  54. package/esm/components/QField/types.d.ts +37 -0
  55. package/esm/components/QField/types.d.ts.map +1 -0
  56. package/esm/components/QIcon/InlineSvg.d.ts.map +1 -1
  57. package/esm/components/QIcon/InlineSvg.js +6 -13
  58. package/esm/components/QIcon/QIcon.d.ts +3 -19
  59. package/esm/components/QIcon/QIcon.d.ts.map +1 -1
  60. package/esm/components/QIcon/QIcon.vue.js +2 -2
  61. package/esm/components/QIcon/QIconFont.d.ts +2 -22
  62. package/esm/components/QIcon/QIconFont.d.ts.map +1 -1
  63. package/esm/components/QIcon/QIconFont.vue.js +9 -9
  64. package/esm/components/QIcon/QIconImg.d.ts +3 -27
  65. package/esm/components/QIcon/QIconImg.d.ts.map +1 -1
  66. package/esm/components/QIcon/QIconImg.vue.js +3 -3
  67. package/esm/components/QIcon/QIconSvg.d.ts +4 -36
  68. package/esm/components/QIcon/QIconSvg.d.ts.map +1 -1
  69. package/esm/components/QIcon/QIconSvg.vue.js +9 -9
  70. package/esm/components/QIcon/index.d.ts +9 -156
  71. package/esm/components/QIcon/index.d.ts.map +1 -1
  72. package/esm/components/QIcon/types.d.ts +40 -0
  73. package/esm/components/QIcon/types.d.ts.map +1 -0
  74. package/esm/components/QInputGroup/QInputGroup.d.ts +12 -42
  75. package/esm/components/QInputGroup/QInputGroup.d.ts.map +1 -1
  76. package/esm/components/QInputGroup/index.d.ts +3 -153
  77. package/esm/components/QInputGroup/index.d.ts.map +1 -1
  78. package/esm/components/QInputGroup/types.d.ts +35 -0
  79. package/esm/components/QInputGroup/types.d.ts.map +1 -0
  80. package/esm/components/QLineLoader/QLineLoader.d.ts +2 -6
  81. package/esm/components/QLineLoader/QLineLoader.d.ts.map +1 -1
  82. package/esm/components/QLineLoader/index.d.ts +3 -13
  83. package/esm/components/QLineLoader/index.d.ts.map +1 -1
  84. package/esm/components/QLineLoader/types.d.ts +7 -0
  85. package/esm/components/QLineLoader/types.d.ts.map +1 -0
  86. package/esm/components/QList/QList.d.ts +11 -52
  87. package/esm/components/QList/QList.d.ts.map +1 -1
  88. package/esm/components/QList/QListItem.d.ts +10 -53
  89. package/esm/components/QList/QListItem.d.ts.map +1 -1
  90. package/esm/components/QList/QListItem.vue.js +22 -28
  91. package/esm/components/QList/QListItemGroup.d.ts +7 -13
  92. package/esm/components/QList/QListItemGroup.d.ts.map +1 -1
  93. package/esm/components/QList/index.d.ts +7 -452
  94. package/esm/components/QList/index.d.ts.map +1 -1
  95. package/esm/components/QList/types.d.ts +102 -0
  96. package/esm/components/QList/types.d.ts.map +1 -0
  97. package/esm/components/QList/types.js +11 -0
  98. package/esm/components/QOverlay/QOverlay.d.ts +33 -118
  99. package/esm/components/QOverlay/QOverlay.d.ts.map +1 -1
  100. package/esm/components/QOverlay/QOverlay.vue.js +1 -2
  101. package/esm/components/QOverlay/index.d.ts +3 -339
  102. package/esm/components/QOverlay/index.d.ts.map +1 -1
  103. package/esm/components/QOverlay/types.d.ts +88 -0
  104. package/esm/components/QOverlay/types.d.ts.map +1 -0
  105. package/esm/components/QPopover/QPopover.d.ts +17 -58
  106. package/esm/components/QPopover/QPopover.d.ts.map +1 -1
  107. package/esm/components/QPopover/QPopover.vue.js +25 -24
  108. package/esm/components/QPopover/index.d.ts +3 -180
  109. package/esm/components/QPopover/index.d.ts.map +1 -1
  110. package/esm/components/QPopover/types.d.ts +44 -0
  111. package/esm/components/QPopover/types.d.ts.map +1 -0
  112. package/esm/components/QPropertyList/QPropertyList.d.ts +70 -0
  113. package/esm/components/QPropertyList/QPropertyList.d.ts.map +1 -0
  114. package/esm/components/QPropertyList/QPropertyList.vue.js +146 -0
  115. package/esm/components/QPropertyList/QPropertyList.vue2.js +4 -0
  116. package/esm/components/QPropertyList/QPropertyListGroup.d.ts +48 -0
  117. package/esm/components/QPropertyList/QPropertyListGroup.d.ts.map +1 -0
  118. package/esm/components/QPropertyList/QPropertyListGroup.vue.js +72 -0
  119. package/esm/components/QPropertyList/QPropertyListGroup.vue2.js +4 -0
  120. package/esm/components/QPropertyList/QPropertyListPanel.d.ts +53 -0
  121. package/esm/components/QPropertyList/QPropertyListPanel.d.ts.map +1 -0
  122. package/esm/components/QPropertyList/QPropertyListPanel.vue.js +45 -0
  123. package/esm/components/QPropertyList/QPropertyListPanel.vue2.js +4 -0
  124. package/esm/components/QPropertyList/QPropertyListRow.d.ts +29 -0
  125. package/esm/components/QPropertyList/QPropertyListRow.d.ts.map +1 -0
  126. package/esm/components/QPropertyList/QPropertyListRow.vue.js +64 -0
  127. package/esm/components/QPropertyList/QPropertyListRow.vue2.js +4 -0
  128. package/esm/components/QPropertyList/index.d.ts +13 -0
  129. package/esm/components/QPropertyList/index.d.ts.map +1 -0
  130. package/esm/components/QPropertyList/index.js +12 -0
  131. package/esm/components/QPropertyList/types.d.ts +101 -0
  132. package/esm/components/QPropertyList/types.d.ts.map +1 -0
  133. package/esm/components/QPropertyList/types.js +14 -0
  134. package/esm/components/QSelect/QSelect.d.ts +25 -102
  135. package/esm/components/QSelect/QSelect.d.ts.map +1 -1
  136. package/esm/components/QSelect/QSelect.vue.js +80 -91
  137. package/esm/components/QSelect/index.d.ts +3 -369
  138. package/esm/components/QSelect/index.d.ts.map +1 -1
  139. package/esm/components/QSelect/types.d.ts +80 -0
  140. package/esm/components/QSelect/types.d.ts.map +1 -0
  141. package/esm/components/QSelect/types.js +14 -0
  142. package/esm/components/QSkeletonLoader/QSkeletonLoader.d.ts +2 -14
  143. package/esm/components/QSkeletonLoader/QSkeletonLoader.d.ts.map +1 -1
  144. package/esm/components/QSkeletonLoader/index.d.ts +3 -31
  145. package/esm/components/QSkeletonLoader/index.d.ts.map +1 -1
  146. package/esm/components/QSkeletonLoader/types.d.ts +15 -0
  147. package/esm/components/QSkeletonLoader/types.d.ts.map +1 -0
  148. package/esm/components/QSpinnerLoader/QSpinnerLoader.d.ts +2 -10
  149. package/esm/components/QSpinnerLoader/QSpinnerLoader.d.ts.map +1 -1
  150. package/esm/components/QSpinnerLoader/QSpinnerLoader.vue.js +6 -6
  151. package/esm/components/QSpinnerLoader/index.d.ts +3 -22
  152. package/esm/components/QSpinnerLoader/index.d.ts.map +1 -1
  153. package/esm/components/QSpinnerLoader/types.d.ts +11 -0
  154. package/esm/components/QSpinnerLoader/types.d.ts.map +1 -0
  155. package/esm/components/QTextField/QTextField.d.ts +13 -61
  156. package/esm/components/QTextField/QTextField.d.ts.map +1 -1
  157. package/esm/components/QTextField/index.d.ts +3 -229
  158. package/esm/components/QTextField/index.d.ts.map +1 -1
  159. package/esm/components/QTextField/types.d.ts +51 -0
  160. package/esm/components/QTextField/types.d.ts.map +1 -0
  161. package/esm/components/QThemeProvider/QThemeProvider.d.ts +6 -8
  162. package/esm/components/QThemeProvider/QThemeProvider.d.ts.map +1 -1
  163. package/esm/components/QThemeProvider/index.d.ts +3 -37
  164. package/esm/components/QThemeProvider/index.d.ts.map +1 -1
  165. package/esm/components/QThemeProvider/types.d.ts +7 -0
  166. package/esm/components/QThemeProvider/types.d.ts.map +1 -0
  167. package/esm/components/QTooltip/QTooltip.d.ts +30 -94
  168. package/esm/components/QTooltip/QTooltip.d.ts.map +1 -1
  169. package/esm/components/QTooltip/index.d.ts +3 -279
  170. package/esm/components/QTooltip/index.d.ts.map +1 -1
  171. package/esm/components/QTooltip/types.d.ts +67 -0
  172. package/esm/components/QTooltip/types.d.ts.map +1 -0
  173. package/esm/components/index.d.ts +1 -0
  174. package/esm/components/index.d.ts.map +1 -1
  175. package/esm/components/index.js +42 -37
  176. package/esm/composables/defaults.js +3 -6
  177. package/esm/index.d.ts +4 -0
  178. package/esm/utils/color.js +1 -2
  179. package/esm/utils/setupPropsProxy.js +2 -4
  180. package/package.json +35 -36
@@ -1,86 +1,19 @@
1
- import { QFieldSize } from '../QField';
2
- import { Icon } from '../QIcon';
3
- import { QListItemGroupProps, QListItemProps } from '../QList';
4
1
  import { Primitive } from '../../types/primitive';
5
2
 
6
- export type QSelectProps = {
7
- /**
8
- * The field unique identifier.
9
- */
10
- id?: string;
11
- /**
12
- * The label of the input.
13
- */
14
- label?: string;
15
- /**
16
- * Whether the value of the component can be cleared.
17
- */
18
- clearable?: boolean;
19
- /**
20
- * Whether the select is readonly.
21
- */
22
- readonly?: boolean;
23
- /**
24
- * Whether the select 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
- * Whether the items of the list are being loaded.
34
- */
35
- loading?: boolean;
36
- /**
37
- * The list of available items for selection.
38
- */
39
- items: (Omit<QListItemProps, 'value' | 'label'> & {
40
- [key: string]: any;
41
- })[];
42
- /**
43
- * The item groups used for organizing the available items.
44
- */
45
- groups?: (QListItemGroupProps & {
46
- id: string;
47
- })[];
48
- /**
49
- * Property on each item that contains its value.
50
- */
51
- itemValue?: string;
52
- /**
53
- * Property on each item that contains its title.
54
- */
55
- itemLabel?: string;
56
- /**
57
- * The value to be used in comparisons,
58
- * used to check if the field has a selected item.
59
- */
60
- emptyValue?: Primitive;
61
- /**
62
- * The size category of the input.
63
- */
64
- size?: QFieldSize;
65
- /**
66
- * Custom set of classes to apply to the component.
67
- */
68
- class?: string | unknown[];
69
- /**
70
- * The internal elements of the component
71
- */
72
- internals?: Internals;
73
- };
74
- declare const DEFAULT_TEXTS: Record<string, string>;
75
- declare const DEFAULT_ICONS: Record<string, Icon>;
76
- type Internals = {
77
- icons: typeof DEFAULT_ICONS;
78
- texts: typeof DEFAULT_TEXTS;
3
+ declare function __VLS_template(): {
4
+ prepend?(_: {}): any;
5
+ append?(_: {}): any;
6
+ extras?(_: {}): any;
7
+ "body.prepend"?(_: {}): any;
8
+ item?(_: {
9
+ item: import('../QList/types').Item;
10
+ }): any;
11
+ "body.append"?(_: {}): any;
79
12
  };
80
- declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<{
13
+ declare const __VLS_component: import('vue').DefineComponent<{
81
14
  modelValue: import('vue').PropType<any>;
82
15
  size: {
83
- type: import('vue').PropType<QFieldSize>;
16
+ type: import('vue').PropType<import('../QField').QFieldSize>;
84
17
  default: undefined;
85
18
  };
86
19
  class: {
@@ -101,20 +34,20 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<{
101
34
  type: import('vue').PropType<boolean>;
102
35
  };
103
36
  internals: {
104
- type: import('vue').PropType<Internals>;
37
+ type: import('vue').PropType<import('./types').Internals>;
105
38
  default: () => {
106
- icons: Record<string, Icon>;
39
+ icons: Record<string, import('../QIcon').Icon>;
107
40
  texts: Record<string, string>;
108
41
  };
109
42
  };
110
43
  items: {
111
- type: import('vue').PropType<(Omit<QListItemProps, "label" | "value"> & {
44
+ type: import('vue').PropType<(Omit<import('../QList').QListItemProps, "label" | "value"> & {
112
45
  [key: string]: any;
113
46
  })[]>;
114
47
  required: true;
115
48
  };
116
49
  groups: {
117
- type: import('vue').PropType<(QListItemGroupProps & {
50
+ type: import('vue').PropType<(import('../QList').QListItemGroupProps & {
118
51
  id: string;
119
52
  })[]>;
120
53
  default: () => never[];
@@ -149,7 +82,7 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<{
149
82
  }, string, import('vue').PublicProps, Readonly<import('vue').ExtractPropTypes<{
150
83
  modelValue: import('vue').PropType<any>;
151
84
  size: {
152
- type: import('vue').PropType<QFieldSize>;
85
+ type: import('vue').PropType<import('../QField').QFieldSize>;
153
86
  default: undefined;
154
87
  };
155
88
  class: {
@@ -170,20 +103,20 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<{
170
103
  type: import('vue').PropType<boolean>;
171
104
  };
172
105
  internals: {
173
- type: import('vue').PropType<Internals>;
106
+ type: import('vue').PropType<import('./types').Internals>;
174
107
  default: () => {
175
- icons: Record<string, Icon>;
108
+ icons: Record<string, import('../QIcon').Icon>;
176
109
  texts: Record<string, string>;
177
110
  };
178
111
  };
179
112
  items: {
180
- type: import('vue').PropType<(Omit<QListItemProps, "label" | "value"> & {
113
+ type: import('vue').PropType<(Omit<import('../QList').QListItemProps, "label" | "value"> & {
181
114
  [key: string]: any;
182
115
  })[]>;
183
116
  required: true;
184
117
  };
185
118
  groups: {
186
- type: import('vue').PropType<(QListItemGroupProps & {
119
+ type: import('vue').PropType<(import('../QList').QListItemGroupProps & {
187
120
  id: string;
188
121
  })[]>;
189
122
  default: () => never[];
@@ -216,29 +149,19 @@ declare const _default: __VLS_WithTemplateSlots<import('vue').DefineComponent<{
216
149
  onShow?: (() => any) | undefined;
217
150
  onHide?: (() => any) | undefined;
218
151
  }, {
219
- size: QFieldSize;
152
+ size: import('../QField').QFieldSize;
220
153
  class: string | unknown[];
221
154
  label: string;
222
- internals: Internals;
223
- groups: (QListItemGroupProps & {
155
+ internals: import('./types').Internals;
156
+ groups: (import('../QList').QListItemGroupProps & {
224
157
  id: string;
225
158
  })[];
226
159
  itemValue: string;
227
160
  itemLabel: string;
228
161
  id: string;
229
162
  emptyValue: Primitive;
230
- }, {}>, {
231
- prepend?(_: {}): any;
232
- append?(_: {}): any;
233
- extras?(_: {}): any;
234
- "body.prepend"?(_: {}): any;
235
- item?(_: {
236
- item: Omit<QListItemProps, "label" | "value"> & {
237
- [key: string]: any;
238
- };
239
- }): any;
240
- "body.append"?(_: {}): any;
241
- }>;
163
+ }, {}>;
164
+ declare const _default: __VLS_WithTemplateSlots<typeof __VLS_component, ReturnType<typeof __VLS_template>>;
242
165
  export default _default;
243
166
  type __VLS_WithTemplateSlots<T, S> = T & {
244
167
  new (): {
@@ -1 +1 @@
1
- {"version":3,"file":"QSelect.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QSelect/QSelect.vue"],"names":[],"mappings":"AAwHA;AAWC,OAAO,KAAK,EAAE,UAAU,EAAE,MAAM,qBAAqB,CAAA;AACrD,OAAO,KAAK,EAAE,IAAI,EAAE,MAAM,oBAAoB,CAAA;AAC9C,OAAO,KAAK,EAAE,mBAAmB,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAA;AAC7E,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAA;AAMlD,MAAM,MAAM,YAAY,GAAG;IAC1B;;OAEG;IACH,EAAE,CAAC,EAAE,MAAM,CAAA;IAEX;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,CAAA;IAEd;;OAEG;IACH,SAAS,CAAC,EAAE,OAAO,CAAA;IAEnB;;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,OAAO,CAAC,EAAE,OAAO,CAAA;IAEjB;;OAEG;IACH,KAAK,EAAE,CAAC,IAAI,CAAC,cAAc,EAAE,OAAO,GAAG,OAAO,CAAC,GAAG;QAGjD,CAAC,GAAG,EAAE,MAAM,GAAG,GAAG,CAAA;KAClB,CAAC,EAAE,CAAA;IAEJ;;OAEG;IACH,MAAM,CAAC,EAAE,CAAC,mBAAmB,GAAG;QAC/B,EAAE,EAAE,MAAM,CAAA;KACV,CAAC,EAAE,CAAA;IAEJ;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAA;IAElB;;OAEG;IACH,SAAS,CAAC,EAAE,MAAM,CAAA;IAElB;;;OAGG;IACH,UAAU,CAAC,EAAE,SAAS,CAAA;IAEtB;;OAEG;IACH,IAAI,CAAC,EAAE,UAAU,CAAA;IAEjB;;OAEG;IACH,KAAK,CAAC,EAAE,MAAM,GAAG,OAAO,EAAE,CAAA;IAE1B;;OAEG;IACH,SAAS,CAAC,EAAE,SAAS,CAAA;CACrB,CAAA;AAKD,QAAA,MAAM,aAAa,EAAE,MAAM,CAAC,MAAM,EAAE,MAAM,CAEzC,CAAA;AAGD,QAAA,MAAM,aAAa,EAAE,MAAM,CAAC,MAAM,EAAE,IAAI,CAOvC,CAAA;AAGD,KAAK,SAAS,GAAG;IAChB,KAAK,EAAE,OAAO,aAAa,CAAA;IAC3B,KAAK,EAAE,OAAO,aAAa,CAAA;CAC3B,CAAA;;gBAyMU,OAAO,KAAK,EAAE,QAAQ,CAAC,GAAG,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;gBAA3B,OAAO,KAAK,EAAE,QAAQ,CAAC,GAAG,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;qBA2VT,GAAG;oBACJ,GAAG;oBACH,GAAG;4BACK,GAAG;;;;;QACZ,GAAG;2BACM,GAAG;;AAxiBxC,wBAylBI;AASJ,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAAE,QAAO;QAClD,MAAM,EAAE,CAAC,CAAC;KACT,CAAA;CAAE,CAAC"}
1
+ {"version":3,"file":"QSelect.vue.d.ts","sourceRoot":"","sources":["../../../src/components/QSelect/QSelect.vue"],"names":[],"mappings":"AAwHA;AAYC,OAAO,KAAK,EAAE,SAAS,EAAE,MAAM,mBAAmB,CAAA;AAqNnD,iBAAS,cAAc;qBAqVO,GAAG;oBACJ,GAAG;oBACH,GAAG;4BACK,GAAG;;;QACZ,GAAG;2BACM,GAAG;EAGvC;AAkCD,QAAA,MAAM,eAAe;gBArYT,OAAO,KAAK,EAAE,QAAQ,CAAC,GAAG,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBAkZ8J,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;gBAlZ7L,OAAO,KAAK,EAAE,QAAQ,CAAC,GAAG,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;kBAkZ8J,IAAI;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;MAHvM,CAAC;wBACkB,uBAAuB,CAAC,OAAO,eAAe,EAAE,UAAU,CAAC,OAAO,cAAc,CAAC,CAAC;AAAvG,wBAAwG;AAUxG,KAAK,uBAAuB,CAAC,CAAC,EAAE,CAAC,IAAI,CAAC,GAAG;IAAE,QAAO;QAClD,MAAM,EAAE,CAAC,CAAC;KACT,CAAA;CAAE,CAAC"}
@@ -1,29 +1,21 @@
1
- import { defineComponent as J, mergeModels as R, useModel as Y, ref as m, computed as k, watch as Z, nextTick as ee, openBlock as t, createElementBlock as p, Fragment as D, createVNode as v, unref as n, normalizeClass as le, withModifiers as F, createSlots as oe, withCtx as s, renderSlot as u, createBlock as g, normalizeProps as C, guardReactiveProps as M, createCommentVNode as h, toDisplayString as O, createTextVNode as ae, mergeProps as te, createElementVNode as ne } from "vue";
1
+ import { defineComponent as J, mergeModels as R, useModel as Y, ref as f, computed as k, watch as Z, nextTick as ee, openBlock as t, createElementBlock as m, Fragment as D, createVNode as p, unref as n, normalizeClass as le, withModifiers as F, createSlots as ae, withCtx as i, renderSlot as u, createBlock as g, normalizeProps as S, guardReactiveProps as M, createCommentVNode as h, toDisplayString as O, createTextVNode as oe, mergeProps as te, createElementVNode as ne } from "vue";
2
2
  import { QButton as U } from "../QButton/index.js";
3
3
  import { QField as ie } from "../QField/index.js";
4
- import { QIcon as S } from "../QIcon/index.js";
4
+ import { QIcon as x } from "../QIcon/index.js";
5
5
  import { QList as se } from "../QList/index.js";
6
6
  import { QOverlay as de } from "../QOverlay/index.js";
7
7
  import { QSpinnerLoader as re } from "../QSpinnerLoader/index.js";
8
- const ue = {
8
+ import { DEFAULT_ICONS as ue, DEFAULT_TEXTS as ce } from "./types.js";
9
+ const fe = {
9
10
  key: 0,
10
11
  class: "q-select__value"
11
- }, ce = {
12
+ }, me = {
12
13
  key: 1,
13
14
  class: "q-select__placeholder"
14
- }, fe = ["data-key"], me = {
15
+ }, pe = ["data-key"], ve = {
15
16
  key: 0,
16
17
  class: "q-select__loader"
17
- }, pe = {
18
- placeholder: "Choose..."
19
- }, ve = {
20
- chevron: {
21
- icon: "chevron-down"
22
- },
23
- clear: {
24
- icon: "close"
25
- }
26
- }, Ve = /* @__PURE__ */ J({
18
+ }, qe = /* @__PURE__ */ J({
27
19
  __name: "QSelect",
28
20
  props: /* @__PURE__ */ R({
29
21
  id: { default: void 0 },
@@ -40,7 +32,7 @@ const ue = {
40
32
  emptyValue: { type: [String, Number, Boolean, Symbol], default: void 0 },
41
33
  size: { default: void 0 },
42
34
  class: { default: "" },
43
- internals: { default: () => ({ icons: ve, texts: pe }) }
35
+ internals: { default: () => ({ icons: ue, texts: ce }) }
44
36
  }, {
45
37
  modelValue: {
46
38
  type: [String, Number, Boolean, Symbol]
@@ -48,83 +40,83 @@ const ue = {
48
40
  modelModifiers: {}
49
41
  }),
50
42
  emits: /* @__PURE__ */ R(["before-show", "before-hide", "show", "hide"], ["update:modelValue"]),
51
- setup(x, { emit: A }) {
52
- const l = x, y = A, c = Y(x, "modelValue"), a = m(!1), w = m(""), b = m(null), _ = m(null), V = m(null), P = k(() => d.value === void 0), d = k(
43
+ setup(B, { emit: A }) {
44
+ const l = B, v = A, y = Y(B, "modelValue"), o = f(!1), _ = f(""), b = f(null), w = f(null), V = f(null), P = k(() => s.value === void 0), s = k(
53
45
  () => {
54
46
  var e;
55
- return (e = l.items) == null ? void 0 : e.find((o) => o[l.itemValue] === c.value);
47
+ return (e = l.items) == null ? void 0 : e.find((a) => a[l.itemValue] === y.value);
56
48
  }
57
49
  ), K = k(
58
- () => d.value ? d.value[l.itemLabel] : ""
50
+ () => s.value ? s.value[l.itemLabel] : ""
59
51
  ), q = k(
60
52
  () => l.clearable && !l.readonly && !l.disabled && !l.loading
61
53
  );
62
- function B(e) {
63
- c.value = e, L();
54
+ function C(e) {
55
+ y.value = e, L();
64
56
  }
65
57
  function E() {
66
- q.value && (B(l.emptyValue), I());
58
+ q.value && (C(l.emptyValue), I());
67
59
  }
68
60
  function H(e) {
69
- var o, r, f;
70
- !((o = V.value) != null && o.contains(e.relatedTarget)) && !((f = (r = b.value) == null ? void 0 : r.fieldRef) != null && f.contains(e.relatedTarget)) && L();
61
+ var a, d, c;
62
+ !((a = V.value) != null && a.contains(e.relatedTarget)) && !((c = (d = b.value) == null ? void 0 : d.fieldRef) != null && c.contains(e.relatedTarget)) && L();
71
63
  }
72
64
  function W() {
73
- a.value || (y("before-show"), a.value = !0);
65
+ o.value || (v("before-show"), o.value = !0);
74
66
  }
75
67
  function L() {
76
- a.value && (y("before-hide"), a.value = !1);
68
+ o.value && (v("before-hide"), o.value = !1);
77
69
  }
78
70
  function T() {
79
- l.readonly || l.disabled || (a.value ? L() : W());
71
+ l.readonly || l.disabled || (o.value ? L() : W());
80
72
  }
81
73
  let $;
82
74
  function z(e) {
83
75
  if (!(!e.key || l.readonly || l.disabled)) {
84
- if (window.clearTimeout($), ["Enter", " ", "ArrowDown", "ArrowUp", "Home", "End"].includes(e.key) && (e.preventDefault(), e.stopPropagation()), ["Enter", " "].includes(e.key) && (a.value = !0), ["Escape", "Tab"].includes(e.key) && (a.value ? a.value = !1 : q.value && e.key === "Escape" && E()), e.key === "Delete" && l.clearable && E(), /^[a-z]$/i.test(e.key)) {
85
- w.value += e.key.toLowerCase();
86
- for (let o = 0; o < l.items.length; o++)
87
- if (l.items[o][l.itemLabel].toLowerCase().startsWith(w.value)) {
88
- G(o);
76
+ if (window.clearTimeout($), ["Enter", " ", "ArrowDown", "ArrowUp", "Home", "End"].includes(e.key) && (e.preventDefault(), e.stopPropagation()), ["Enter", " "].includes(e.key) && (o.value = !0), ["Escape", "Tab"].includes(e.key) && (o.value ? o.value = !1 : q.value && e.key === "Escape" && E()), e.key === "Delete" && l.clearable && E(), /^[a-z]$/i.test(e.key)) {
77
+ _.value += e.key.toLowerCase();
78
+ for (let a = 0; a < l.items.length; a++)
79
+ if (l.items[a][l.itemLabel].toLowerCase().startsWith(_.value)) {
80
+ G(a);
89
81
  break;
90
82
  }
91
83
  }
92
84
  $ = window.setTimeout(function() {
93
- w.value = "";
85
+ _.value = "";
94
86
  }, 500);
95
87
  }
96
88
  }
97
89
  function X() {
98
90
  var e;
99
- l.loading ? (e = V.value) == null || e.focus() : N(), y("show");
91
+ l.loading ? (e = V.value) == null || e.focus() : N(), v("show");
100
92
  }
101
93
  function j() {
102
- I(), y("hide");
94
+ I(), v("hide");
103
95
  }
104
96
  function I() {
105
- var e, o;
106
- (o = (e = b.value) == null ? void 0 : e.fieldRef) == null || o.focus();
97
+ var e, a;
98
+ (a = (e = b.value) == null ? void 0 : e.fieldRef) == null || a.focus();
107
99
  }
108
100
  function N() {
109
101
  var e;
110
- (e = _.value) == null || e.$el.focus();
102
+ (e = w.value) == null || e.$el.focus();
111
103
  }
112
104
  function G(e) {
113
- var o;
114
- (o = _.value) == null || o.focusItem(e);
105
+ var a;
106
+ (a = w.value) == null || a.focusItem(e);
115
107
  }
116
108
  return Z(
117
109
  () => l.loading,
118
110
  (e) => {
119
- !e && a.value && ee(N);
111
+ !e && o.value && ee(N);
120
112
  }
121
- ), (e, o) => {
122
- var r, f;
123
- return t(), p(
113
+ ), (e, a) => {
114
+ var d, c;
115
+ return t(), m(
124
116
  D,
125
117
  null,
126
118
  [
127
- v(n(ie), {
119
+ p(n(ie), {
128
120
  id: l.id,
129
121
  label: l.label,
130
122
  required: l.required,
@@ -137,22 +129,22 @@ const ue = {
137
129
  {
138
130
  "q-select--readonly": l.readonly,
139
131
  "q-select--disabled": l.disabled,
140
- "q-select--expanded": a.value
132
+ "q-select--expanded": o.value
141
133
  },
142
134
  l.class
143
135
  ]),
144
136
  readonly: l.readonly,
145
137
  disabled: l.disabled,
146
138
  "data-loading": l.loading,
147
- "aria-expanded": a.value,
139
+ "aria-expanded": o.value,
148
140
  "aria-haspopup": "listbox",
149
141
  size: l.size,
150
142
  onClick: T,
151
143
  onKeydown: F(z, ["stop"])
152
- }, oe({
153
- append: s(() => [
144
+ }, ae({
145
+ append: i(() => [
154
146
  u(e.$slots, "append"),
155
- q.value && c.value ? (t(), g(n(U), {
147
+ q.value && y.value ? (t(), g(n(U), {
156
148
  key: 0,
157
149
  class: "q-select__clear",
158
150
  "b-style": "plain",
@@ -160,10 +152,10 @@ const ue = {
160
152
  tabindex: "-1",
161
153
  onClick: E
162
154
  }, {
163
- default: s(() => [
164
- v(
165
- n(S),
166
- C(M(l.internals.icons.clear)),
155
+ default: i(() => [
156
+ p(
157
+ n(x),
158
+ S(M(l.internals.icons.clear)),
167
159
  null,
168
160
  16
169
161
  /* FULL_PROPS */
@@ -181,10 +173,10 @@ const ue = {
181
173
  disabled: l.disabled,
182
174
  onClick: T
183
175
  }, {
184
- default: s(() => [
185
- v(
186
- n(S),
187
- C(M(l.internals.icons.chevron)),
176
+ default: i(() => [
177
+ p(
178
+ n(x),
179
+ S(M(l.internals.icons.chevron)),
188
180
  null,
189
181
  16
190
182
  /* FULL_PROPS */
@@ -194,13 +186,13 @@ const ue = {
194
186
  /* STABLE */
195
187
  }, 8, ["disabled"]))
196
188
  ]),
197
- default: s(() => [
198
- P.value ? (t(), p("span", ce, [
199
- !l.readonly && !l.disabled ? (t(), p(
189
+ default: i(() => [
190
+ P.value ? (t(), m("span", me, [
191
+ !l.readonly && !l.disabled ? (t(), m(
200
192
  D,
201
193
  { key: 0 },
202
194
  [
203
- ae(
195
+ oe(
204
196
  O(e.internals.texts.placeholder),
205
197
  1
206
198
  /* TEXT */
@@ -209,9 +201,9 @@ const ue = {
209
201
  64
210
202
  /* STABLE_FRAGMENT */
211
203
  )) : h("v-if", !0)
212
- ])) : (t(), p(
204
+ ])) : (t(), m(
213
205
  "span",
214
- ue,
206
+ fe,
215
207
  O(K.value),
216
208
  1
217
209
  /* TEXT */
@@ -220,15 +212,15 @@ const ue = {
220
212
  _: 2
221
213
  /* DYNAMIC */
222
214
  }, [
223
- (r = d.value) != null && r.icon || e.$slots.prepend ? {
215
+ (d = s.value) != null && d.icon || e.$slots.prepend ? {
224
216
  name: "prepend",
225
- fn: s(() => {
226
- var i, Q;
217
+ fn: i(() => {
218
+ var r, Q;
227
219
  return [
228
220
  u(e.$slots, "prepend"),
229
- (i = d.value) != null && i.icon ? (t(), g(
230
- n(S),
231
- C(te({ key: 0 }, (Q = d.value) == null ? void 0 : Q.icon)),
221
+ (r = s.value) != null && r.icon ? (t(), g(
222
+ n(x),
223
+ S(te({ key: 0 }, (Q = s.value) == null ? void 0 : Q.icon)),
232
224
  null,
233
225
  16
234
226
  /* FULL_PROPS */
@@ -239,26 +231,26 @@ const ue = {
239
231
  } : void 0,
240
232
  e.$slots.extras ? {
241
233
  name: "extras",
242
- fn: s(() => [
234
+ fn: i(() => [
243
235
  u(e.$slots, "extras")
244
236
  ]),
245
237
  key: "1"
246
238
  } : void 0
247
239
  ]), 1032, ["id", "label", "required", "tabindex", "class", "readonly", "disabled", "data-loading", "aria-expanded", "size"]),
248
- v(n(de), {
249
- modelValue: a.value,
250
- "onUpdate:modelValue": o[1] || (o[1] = (i) => a.value = i),
240
+ p(n(de), {
241
+ modelValue: o.value,
242
+ "onUpdate:modelValue": a[0] || (a[0] = (r) => o.value = r),
251
243
  spy: "",
252
244
  trigger: "manual",
253
245
  placement: "bottom-start",
254
246
  width: "anchor",
255
247
  "scroll-lock": "",
256
- anchor: (f = b.value) == null ? void 0 : f.$el,
248
+ anchor: (c = b.value) == null ? void 0 : c.$el,
257
249
  offset: 2,
258
250
  onEnter: X,
259
251
  onLeave: j
260
252
  }, {
261
- default: s(() => [
253
+ default: i(() => [
262
254
  ne("div", {
263
255
  ref_key: "contentRef",
264
256
  ref: V,
@@ -270,32 +262,29 @@ const ue = {
270
262
  onKeydown: F(z, ["stop"])
271
263
  }, [
272
264
  u(e.$slots, "body.prepend"),
273
- l.loading ? (t(), p("div", me, [
274
- v(n(re), { size: 24 })
265
+ l.loading ? (t(), m("div", ve, [
266
+ p(n(re), { size: 24 })
275
267
  ])) : (t(), g(n(se), {
276
268
  key: 1,
277
269
  ref_key: "listRef",
278
- ref: _,
270
+ ref: w,
279
271
  class: "q-select__items",
280
272
  selectable: "",
281
- modelValue: c.value,
282
- "onUpdate:modelValue": [
283
- o[0] || (o[0] = (i) => c.value = i),
284
- B
285
- ],
273
+ "model-value": y.value,
286
274
  items: l.items,
287
275
  groups: e.groups,
288
276
  "item-label": l.itemLabel,
289
- "item-value": l.itemValue
277
+ "item-value": l.itemValue,
278
+ "onUpdate:modelValue": C
290
279
  }, {
291
- item: s(({ item: i }) => [
292
- u(e.$slots, "item", { item: i })
280
+ item: i(({ item: r }) => [
281
+ u(e.$slots, "item", { item: r })
293
282
  ]),
294
283
  _: 3
295
284
  /* FORWARDED */
296
- }, 8, ["modelValue", "items", "groups", "item-label", "item-value"])),
285
+ }, 8, ["model-value", "items", "groups", "item-label", "item-value"])),
297
286
  u(e.$slots, "body.append")
298
- ], 40, fe)
287
+ ], 40, pe)
299
288
  ]),
300
289
  _: 3
301
290
  /* FORWARDED */
@@ -308,5 +297,5 @@ const ue = {
308
297
  }
309
298
  });
310
299
  export {
311
- Ve as default
300
+ qe as default
312
301
  };