@threadlabs/looma 0.15.2 → 0.15.3
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.
- package/components/ui-badge/ui-badge.html +30 -5
- package/components/ui-combobox/ui-combobox.html +14 -11
- package/components/ui-combobox/ui-combobox.js +2 -2
- package/dist/index.js +1 -1
- package/package.json +1 -1
- package/styles/ui-badge.css +31 -4
- package/vanilla/UiCombobox.d.ts +7 -7
- package/vanilla/UiCombobox.js +1 -1
- package/vue/UiBadge.vue +31 -4
- package/vue/UiCombobox.d.ts +15 -0
- package/vue/UiCombobox.vue +57 -10
- package/vue/chunks/UiBadge.js +1 -1
- package/vue/chunks/UiCombobox.js +30 -9
- package/vue/components.css +111 -84
package/vue/UiCombobox.d.ts
CHANGED
|
@@ -17,6 +17,7 @@ type __VLS_Props = {
|
|
|
17
17
|
readonly tag?: {
|
|
18
18
|
readonly label: string;
|
|
19
19
|
readonly tone?: 'neutral' | 'accent' | 'info' | 'success' | 'warning' | 'danger';
|
|
20
|
+
readonly color?: string;
|
|
20
21
|
};
|
|
21
22
|
})[];
|
|
22
23
|
label?: string;
|
|
@@ -66,6 +67,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
66
67
|
readonly tag?: {
|
|
67
68
|
readonly label: string;
|
|
68
69
|
readonly tone?: "neutral" | "accent" | "info" | "success" | "warning" | "danger";
|
|
70
|
+
readonly color?: string;
|
|
69
71
|
};
|
|
70
72
|
} | null;
|
|
71
73
|
readonly kind: "selection" | "clear" | "free-entry" | "create";
|
|
@@ -91,6 +93,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
91
93
|
readonly tag?: {
|
|
92
94
|
readonly label: string;
|
|
93
95
|
readonly tone?: "neutral" | "accent" | "info" | "success" | "warning" | "danger";
|
|
96
|
+
readonly color?: string;
|
|
94
97
|
};
|
|
95
98
|
} | null;
|
|
96
99
|
readonly kind: "selection" | "clear" | "free-entry" | "create";
|
|
@@ -105,6 +108,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
105
108
|
readonly tag?: {
|
|
106
109
|
readonly label: string;
|
|
107
110
|
readonly tone?: "neutral" | "accent" | "info" | "success" | "warning" | "danger";
|
|
111
|
+
readonly color?: string;
|
|
108
112
|
};
|
|
109
113
|
}[]) => any;
|
|
110
114
|
"create-entry": (detail: {
|
|
@@ -120,6 +124,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
120
124
|
readonly tag?: {
|
|
121
125
|
readonly label: string;
|
|
122
126
|
readonly tone?: "neutral" | "accent" | "info" | "success" | "warning" | "danger";
|
|
127
|
+
readonly color?: string;
|
|
123
128
|
};
|
|
124
129
|
} | null;
|
|
125
130
|
readonly kind: "selection" | "clear" | "free-entry" | "create";
|
|
@@ -146,6 +151,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
146
151
|
readonly tag?: {
|
|
147
152
|
readonly label: string;
|
|
148
153
|
readonly tone?: "neutral" | "accent" | "info" | "success" | "warning" | "danger";
|
|
154
|
+
readonly color?: string;
|
|
149
155
|
};
|
|
150
156
|
}[]) => any;
|
|
151
157
|
"add-item": (detail: {
|
|
@@ -159,6 +165,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
159
165
|
readonly tag?: {
|
|
160
166
|
readonly label: string;
|
|
161
167
|
readonly tone?: "neutral" | "accent" | "info" | "success" | "warning" | "danger";
|
|
168
|
+
readonly color?: string;
|
|
162
169
|
};
|
|
163
170
|
};
|
|
164
171
|
readonly index: number;
|
|
@@ -175,6 +182,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
175
182
|
readonly tag?: {
|
|
176
183
|
readonly label: string;
|
|
177
184
|
readonly tone?: "neutral" | "accent" | "info" | "success" | "warning" | "danger";
|
|
185
|
+
readonly color?: string;
|
|
178
186
|
};
|
|
179
187
|
};
|
|
180
188
|
readonly index: number;
|
|
@@ -203,6 +211,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
203
211
|
readonly tag?: {
|
|
204
212
|
readonly label: string;
|
|
205
213
|
readonly tone?: "neutral" | "accent" | "info" | "success" | "warning" | "danger";
|
|
214
|
+
readonly color?: string;
|
|
206
215
|
};
|
|
207
216
|
} | null;
|
|
208
217
|
readonly kind: "selection" | "clear" | "free-entry" | "create";
|
|
@@ -228,6 +237,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
228
237
|
readonly tag?: {
|
|
229
238
|
readonly label: string;
|
|
230
239
|
readonly tone?: "neutral" | "accent" | "info" | "success" | "warning" | "danger";
|
|
240
|
+
readonly color?: string;
|
|
231
241
|
};
|
|
232
242
|
} | null;
|
|
233
243
|
readonly kind: "selection" | "clear" | "free-entry" | "create";
|
|
@@ -242,6 +252,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
242
252
|
readonly tag?: {
|
|
243
253
|
readonly label: string;
|
|
244
254
|
readonly tone?: "neutral" | "accent" | "info" | "success" | "warning" | "danger";
|
|
255
|
+
readonly color?: string;
|
|
245
256
|
};
|
|
246
257
|
}[]) => any) | undefined;
|
|
247
258
|
"onCreate-entry"?: ((detail: {
|
|
@@ -257,6 +268,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
257
268
|
readonly tag?: {
|
|
258
269
|
readonly label: string;
|
|
259
270
|
readonly tone?: "neutral" | "accent" | "info" | "success" | "warning" | "danger";
|
|
271
|
+
readonly color?: string;
|
|
260
272
|
};
|
|
261
273
|
} | null;
|
|
262
274
|
readonly kind: "selection" | "clear" | "free-entry" | "create";
|
|
@@ -283,6 +295,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
283
295
|
readonly tag?: {
|
|
284
296
|
readonly label: string;
|
|
285
297
|
readonly tone?: "neutral" | "accent" | "info" | "success" | "warning" | "danger";
|
|
298
|
+
readonly color?: string;
|
|
286
299
|
};
|
|
287
300
|
}[]) => any) | undefined;
|
|
288
301
|
"onAdd-item"?: ((detail: {
|
|
@@ -296,6 +309,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
296
309
|
readonly tag?: {
|
|
297
310
|
readonly label: string;
|
|
298
311
|
readonly tone?: "neutral" | "accent" | "info" | "success" | "warning" | "danger";
|
|
312
|
+
readonly color?: string;
|
|
299
313
|
};
|
|
300
314
|
};
|
|
301
315
|
readonly index: number;
|
|
@@ -312,6 +326,7 @@ declare const __VLS_base: import("vue").DefineComponent<__VLS_Props, {
|
|
|
312
326
|
readonly tag?: {
|
|
313
327
|
readonly label: string;
|
|
314
328
|
readonly tone?: "neutral" | "accent" | "info" | "success" | "warning" | "danger";
|
|
329
|
+
readonly color?: string;
|
|
315
330
|
};
|
|
316
331
|
};
|
|
317
332
|
readonly index: number;
|
package/vue/UiCombobox.vue
CHANGED
|
@@ -29,6 +29,7 @@ const props = withDefaults(
|
|
|
29
29
|
readonly tag?: {
|
|
30
30
|
readonly label: string
|
|
31
31
|
readonly tone?: 'neutral' | 'accent' | 'info' | 'success' | 'warning' | 'danger'
|
|
32
|
+
readonly color?: string
|
|
32
33
|
}
|
|
33
34
|
})[]
|
|
34
35
|
label?: string
|
|
@@ -93,6 +94,7 @@ const emit = defineEmits<{
|
|
|
93
94
|
readonly tag?: {
|
|
94
95
|
readonly label: string
|
|
95
96
|
readonly tone?: 'neutral' | 'accent' | 'info' | 'success' | 'warning' | 'danger'
|
|
97
|
+
readonly color?: string
|
|
96
98
|
}
|
|
97
99
|
} | null
|
|
98
100
|
readonly kind: 'selection' | 'clear' | 'free-entry' | 'create'
|
|
@@ -108,6 +110,7 @@ const emit = defineEmits<{
|
|
|
108
110
|
readonly tag?: {
|
|
109
111
|
readonly label: string
|
|
110
112
|
readonly tone?: 'neutral' | 'accent' | 'info' | 'success' | 'warning' | 'danger'
|
|
113
|
+
readonly color?: string
|
|
111
114
|
}
|
|
112
115
|
})[],
|
|
113
116
|
]
|
|
@@ -125,6 +128,7 @@ const emit = defineEmits<{
|
|
|
125
128
|
readonly tag?: {
|
|
126
129
|
readonly label: string
|
|
127
130
|
readonly tone?: 'neutral' | 'accent' | 'info' | 'success' | 'warning' | 'danger'
|
|
131
|
+
readonly color?: string
|
|
128
132
|
}
|
|
129
133
|
} | null
|
|
130
134
|
readonly kind: 'selection' | 'clear' | 'free-entry' | 'create'
|
|
@@ -145,6 +149,7 @@ const emit = defineEmits<{
|
|
|
145
149
|
readonly tag?: {
|
|
146
150
|
readonly label: string
|
|
147
151
|
readonly tone?: 'neutral' | 'accent' | 'info' | 'success' | 'warning' | 'danger'
|
|
152
|
+
readonly color?: string
|
|
148
153
|
}
|
|
149
154
|
} | null
|
|
150
155
|
readonly kind: 'selection' | 'clear' | 'free-entry' | 'create'
|
|
@@ -177,6 +182,7 @@ const emit = defineEmits<{
|
|
|
177
182
|
readonly tag?: {
|
|
178
183
|
readonly label: string
|
|
179
184
|
readonly tone?: 'neutral' | 'accent' | 'info' | 'success' | 'warning' | 'danger'
|
|
185
|
+
readonly color?: string
|
|
180
186
|
}
|
|
181
187
|
})[],
|
|
182
188
|
]
|
|
@@ -192,6 +198,7 @@ const emit = defineEmits<{
|
|
|
192
198
|
readonly tag?: {
|
|
193
199
|
readonly label: string
|
|
194
200
|
readonly tone?: 'neutral' | 'accent' | 'info' | 'success' | 'warning' | 'danger'
|
|
201
|
+
readonly color?: string
|
|
195
202
|
}
|
|
196
203
|
}
|
|
197
204
|
readonly index: number
|
|
@@ -210,6 +217,7 @@ const emit = defineEmits<{
|
|
|
210
217
|
readonly tag?: {
|
|
211
218
|
readonly label: string
|
|
212
219
|
readonly tone?: 'neutral' | 'accent' | 'info' | 'success' | 'warning' | 'danger'
|
|
220
|
+
readonly color?: string
|
|
213
221
|
}
|
|
214
222
|
}
|
|
215
223
|
readonly index: number
|
|
@@ -241,7 +249,11 @@ const internalItems = ref<
|
|
|
241
249
|
group?: string
|
|
242
250
|
disabled?: boolean
|
|
243
251
|
description?: string
|
|
244
|
-
tag?: {
|
|
252
|
+
tag?: {
|
|
253
|
+
label: string
|
|
254
|
+
tone?: 'neutral' | 'accent' | 'info' | 'success' | 'warning' | 'danger'
|
|
255
|
+
color?: string
|
|
256
|
+
}
|
|
245
257
|
}[]
|
|
246
258
|
>([])
|
|
247
259
|
const raw = ref('')
|
|
@@ -257,7 +269,11 @@ const rows = ref<
|
|
|
257
269
|
disabled: boolean
|
|
258
270
|
selected: boolean
|
|
259
271
|
description?: string
|
|
260
|
-
tag?: {
|
|
272
|
+
tag?: {
|
|
273
|
+
label: string
|
|
274
|
+
tone?: 'neutral' | 'accent' | 'info' | 'success' | 'warning' | 'danger'
|
|
275
|
+
color?: string
|
|
276
|
+
}
|
|
261
277
|
}[]
|
|
262
278
|
>([])
|
|
263
279
|
const active = ref<number | null>(-1)
|
|
@@ -290,6 +306,7 @@ const groups = ref<
|
|
|
290
306
|
tag?: {
|
|
291
307
|
label: string
|
|
292
308
|
tone?: 'neutral' | 'accent' | 'info' | 'success' | 'warning' | 'danger'
|
|
309
|
+
color?: string
|
|
293
310
|
}
|
|
294
311
|
index: number
|
|
295
312
|
labelledBy: string | null
|
|
@@ -385,11 +402,17 @@ const isValueChangeDetail = (detail: unknown): boolean =>
|
|
|
385
402
|
|| (((detail as Record<string, unknown>)['option'] as Record<string, unknown>)[
|
|
386
403
|
'tag'
|
|
387
404
|
] as Record<string, unknown>)['tone'] === 'danger'))
|
|
405
|
+
&& ((((detail as Record<string, unknown>)['option'] as Record<string, unknown>)[
|
|
406
|
+
'tag'
|
|
407
|
+
] as Record<string, unknown>)['color'] === undefined
|
|
408
|
+
|| typeof (((detail as Record<string, unknown>)['option'] as Record<string, unknown>)[
|
|
409
|
+
'tag'
|
|
410
|
+
] as Record<string, unknown>)['color'] === 'string')
|
|
388
411
|
&& Object.keys(
|
|
389
412
|
((detail as Record<string, unknown>)['option'] as Record<string, unknown>)[
|
|
390
413
|
'tag'
|
|
391
414
|
] as object,
|
|
392
|
-
).every((key) => ['label', 'tone'].includes(key))))
|
|
415
|
+
).every((key) => ['label', 'tone', 'color'].includes(key))))
|
|
393
416
|
&& Object.keys((detail as Record<string, unknown>)['option'] as object).every((key) =>
|
|
394
417
|
['id', 'value', 'label', 'group', 'disabled', 'description', 'tag'].includes(key)
|
|
395
418
|
)) || (detail as Record<string, unknown>)['option'] === null)
|
|
@@ -436,8 +459,12 @@ const isValueChangeDetail = (detail: unknown): boolean =>
|
|
|
436
459
|
=== 'warning'
|
|
437
460
|
|| ((item as Record<string, unknown>)['tag'] as Record<string, unknown>)['tone']
|
|
438
461
|
=== 'danger'))
|
|
462
|
+
&& (((item as Record<string, unknown>)['tag'] as Record<string, unknown>)['color']
|
|
463
|
+
=== undefined
|
|
464
|
+
|| typeof ((item as Record<string, unknown>)['tag'] as Record<string, unknown>)['color']
|
|
465
|
+
=== 'string')
|
|
439
466
|
&& Object.keys((item as Record<string, unknown>)['tag'] as object).every((key) =>
|
|
440
|
-
['label', 'tone'].includes(key)
|
|
467
|
+
['label', 'tone', 'color'].includes(key)
|
|
441
468
|
)))
|
|
442
469
|
&& Object.keys(item as object).every((key) =>
|
|
443
470
|
['id', 'value', 'label', 'group', 'disabled', 'description', 'tag'].includes(key)
|
|
@@ -502,12 +529,18 @@ const isFreeEntryDetail = (detail: unknown): boolean =>
|
|
|
502
529
|
|| (((detail as Record<string, unknown>)['option'] as Record<string, unknown>)[
|
|
503
530
|
'tag'
|
|
504
531
|
] as Record<string, unknown>)['tone'] === 'danger'))
|
|
532
|
+
&& ((((detail as Record<string, unknown>)['option'] as Record<string, unknown>)[
|
|
533
|
+
'tag'
|
|
534
|
+
] as Record<string, unknown>)['color'] === undefined
|
|
535
|
+
|| typeof (((detail as Record<string, unknown>)['option'] as Record<string, unknown>)[
|
|
536
|
+
'tag'
|
|
537
|
+
] as Record<string, unknown>)['color'] === 'string')
|
|
505
538
|
&& Object.keys(
|
|
506
539
|
((detail as Record<string, unknown>)['option'] as Record<string, unknown>)[
|
|
507
540
|
'tag'
|
|
508
541
|
] as object,
|
|
509
542
|
).every((key) =>
|
|
510
|
-
['label', 'tone'].includes(key)
|
|
543
|
+
['label', 'tone', 'color'].includes(key)
|
|
511
544
|
)))
|
|
512
545
|
&& Object.keys((detail as Record<string, unknown>)['option'] as object).every((key) =>
|
|
513
546
|
['id', 'value', 'label', 'group', 'disabled', 'description', 'tag'].includes(key)
|
|
@@ -586,8 +619,12 @@ const isOptionsChangeDetail = (detail: unknown): boolean =>
|
|
|
586
619
|
=== 'warning'
|
|
587
620
|
|| ((item as Record<string, unknown>)['tag'] as Record<string, unknown>)['tone']
|
|
588
621
|
=== 'danger'))
|
|
622
|
+
&& (((item as Record<string, unknown>)['tag'] as Record<string, unknown>)['color']
|
|
623
|
+
=== undefined
|
|
624
|
+
|| typeof ((item as Record<string, unknown>)['tag'] as Record<string, unknown>)['color']
|
|
625
|
+
=== 'string')
|
|
589
626
|
&& Object.keys((item as Record<string, unknown>)['tag'] as object).every((key) =>
|
|
590
|
-
['label', 'tone'].includes(key)
|
|
627
|
+
['label', 'tone', 'color'].includes(key)
|
|
591
628
|
)))
|
|
592
629
|
&& Object.keys(item as object).every((key) =>
|
|
593
630
|
['id', 'value', 'label', 'group', 'disabled', 'description', 'tag'].includes(key)
|
|
@@ -648,10 +685,16 @@ const isAddItemDetail = (detail: unknown): boolean =>
|
|
|
648
685
|
|| (((detail as Record<string, unknown>)['item'] as Record<string, unknown>)[
|
|
649
686
|
'tag'
|
|
650
687
|
] as Record<string, unknown>)['tone'] === 'danger'))
|
|
688
|
+
&& ((((detail as Record<string, unknown>)['item'] as Record<string, unknown>)[
|
|
689
|
+
'tag'
|
|
690
|
+
] as Record<string, unknown>)['color'] === undefined
|
|
691
|
+
|| typeof (((detail as Record<string, unknown>)['item'] as Record<string, unknown>)[
|
|
692
|
+
'tag'
|
|
693
|
+
] as Record<string, unknown>)['color'] === 'string')
|
|
651
694
|
&& Object.keys(
|
|
652
695
|
((detail as Record<string, unknown>)['item'] as Record<string, unknown>)['tag'] as object,
|
|
653
696
|
).every((key) =>
|
|
654
|
-
['label', 'tone'].includes(key)
|
|
697
|
+
['label', 'tone', 'color'].includes(key)
|
|
655
698
|
)))
|
|
656
699
|
&& Object.keys((detail as Record<string, unknown>)['item'] as object).every((key) =>
|
|
657
700
|
['id', 'value', 'label', 'group', 'disabled', 'description', 'tag'].includes(key)
|
|
@@ -905,9 +948,13 @@ defineExpose({
|
|
|
905
948
|
><span class="primary" :id="`${uid}-option-${row.index}-label`">{{
|
|
906
949
|
row.label
|
|
907
950
|
}}</span>
|
|
908
|
-
<UiBadge
|
|
909
|
-
|
|
910
|
-
|
|
951
|
+
<UiBadge
|
|
952
|
+
v-if="row.tag"
|
|
953
|
+
:tone="row.tag?.tone"
|
|
954
|
+
:style="{ '--ui-badge-color': row.tag?.color }"
|
|
955
|
+
><span :id="`${uid}-option-${row.index}-tag`">{{
|
|
956
|
+
row.tag?.label
|
|
957
|
+
}}</span></UiBadge></span>
|
|
911
958
|
<span
|
|
912
959
|
v-if="row.description"
|
|
913
960
|
class="description"
|
package/vue/chunks/UiBadge.js
CHANGED
|
@@ -24,6 +24,6 @@ var UiBadge_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE
|
|
|
24
24
|
return openBlock(), createElementBlock("span", mergeProps({ "data-component": "ui-badge" }, _ctx.$attrs, { "data-ui-badge-state": hostState.value || void 0 }), [renderSlot(_ctx.$slots, "default", {}, void 0, true)], 16, _hoisted_1);
|
|
25
25
|
};
|
|
26
26
|
}
|
|
27
|
-
}), [["__scopeId", "data-v-
|
|
27
|
+
}), [["__scopeId", "data-v-3485e390"]]);
|
|
28
28
|
//#endregion
|
|
29
29
|
export { UiBadge_default as t };
|
package/vue/chunks/UiCombobox.js
CHANGED
|
@@ -2,7 +2,7 @@ import { t as _plugin_vue_export_helper_default } from "./_plugin-vue_export-hel
|
|
|
2
2
|
import { n as useComponentHost, t as createDispatch } from "./host.js";
|
|
3
3
|
import { t as UiBadge_default } from "./UiBadge.js";
|
|
4
4
|
import { t as UiTooltip_default } from "./UiTooltip.js";
|
|
5
|
-
import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, mergeProps, normalizeClass, openBlock, ref, renderList, renderSlot, toDisplayString, useTemplateRef, withCtx } from "vue";
|
|
5
|
+
import { Fragment, computed, createBlock, createCommentVNode, createElementBlock, createElementVNode, createTextVNode, createVNode, defineComponent, mergeProps, normalizeClass, normalizeStyle, openBlock, ref, renderList, renderSlot, toDisplayString, useTemplateRef, withCtx } from "vue";
|
|
6
6
|
import * as controllerModule from "@threadlabs/looma/components/ui-combobox/ui-combobox.js";
|
|
7
7
|
//#region .build/vue/UiCombobox.vue?vue&type=script&setup=true&lang.ts
|
|
8
8
|
var _hoisted_1 = ["data-ui-combobox-state"];
|
|
@@ -218,7 +218,11 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
218
218
|
"display",
|
|
219
219
|
"trigger"
|
|
220
220
|
].includes(key));
|
|
221
|
-
const isValueChangeDetail = (detail) => detail !== null && typeof detail === "object" && !Array.isArray(detail) && (typeof detail["value"] === "string" || detail["value"] === null) && typeof detail["query"] === "string" && (detail["option"] !== null && typeof detail["option"] === "object" && !Array.isArray(detail["option"]) && typeof detail["option"]["id"] === "string" && typeof detail["option"]["value"] === "string" && typeof detail["option"]["label"] === "string" && (detail["option"]["group"] === void 0 || typeof detail["option"]["group"] === "string") && (detail["option"]["disabled"] === void 0 || typeof detail["option"]["disabled"] === "boolean") && (detail["option"]["description"] === void 0 || typeof detail["option"]["description"] === "string") && (detail["option"]["tag"] === void 0 || detail["option"]["tag"] !== null && typeof detail["option"]["tag"] === "object" && !Array.isArray(detail["option"]["tag"]) && typeof detail["option"]["tag"]["label"] === "string" && (detail["option"]["tag"]["tone"] === void 0 || detail["option"]["tag"]["tone"] === "neutral" || detail["option"]["tag"]["tone"] === "accent" || detail["option"]["tag"]["tone"] === "info" || detail["option"]["tag"]["tone"] === "success" || detail["option"]["tag"]["tone"] === "warning" || detail["option"]["tag"]["tone"] === "danger") &&
|
|
221
|
+
const isValueChangeDetail = (detail) => detail !== null && typeof detail === "object" && !Array.isArray(detail) && (typeof detail["value"] === "string" || detail["value"] === null) && typeof detail["query"] === "string" && (detail["option"] !== null && typeof detail["option"] === "object" && !Array.isArray(detail["option"]) && typeof detail["option"]["id"] === "string" && typeof detail["option"]["value"] === "string" && typeof detail["option"]["label"] === "string" && (detail["option"]["group"] === void 0 || typeof detail["option"]["group"] === "string") && (detail["option"]["disabled"] === void 0 || typeof detail["option"]["disabled"] === "boolean") && (detail["option"]["description"] === void 0 || typeof detail["option"]["description"] === "string") && (detail["option"]["tag"] === void 0 || detail["option"]["tag"] !== null && typeof detail["option"]["tag"] === "object" && !Array.isArray(detail["option"]["tag"]) && typeof detail["option"]["tag"]["label"] === "string" && (detail["option"]["tag"]["tone"] === void 0 || detail["option"]["tag"]["tone"] === "neutral" || detail["option"]["tag"]["tone"] === "accent" || detail["option"]["tag"]["tone"] === "info" || detail["option"]["tag"]["tone"] === "success" || detail["option"]["tag"]["tone"] === "warning" || detail["option"]["tag"]["tone"] === "danger") && (detail["option"]["tag"]["color"] === void 0 || typeof detail["option"]["tag"]["color"] === "string") && Object.keys(detail["option"]["tag"]).every((key) => [
|
|
222
|
+
"label",
|
|
223
|
+
"tone",
|
|
224
|
+
"color"
|
|
225
|
+
].includes(key))) && Object.keys(detail["option"]).every((key) => [
|
|
222
226
|
"id",
|
|
223
227
|
"value",
|
|
224
228
|
"label",
|
|
@@ -232,7 +236,11 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
232
236
|
"option",
|
|
233
237
|
"kind",
|
|
234
238
|
"trigger"
|
|
235
|
-
].includes(key)) || Array.isArray(detail) && detail.every((item) => item !== null && typeof item === "object" && !Array.isArray(item) && typeof item["id"] === "string" && typeof item["value"] === "string" && typeof item["label"] === "string" && (item["group"] === void 0 || typeof item["group"] === "string") && (item["disabled"] === void 0 || typeof item["disabled"] === "boolean") && (item["description"] === void 0 || typeof item["description"] === "string") && (item["tag"] === void 0 || item["tag"] !== null && typeof item["tag"] === "object" && !Array.isArray(item["tag"]) && typeof item["tag"]["label"] === "string" && (item["tag"]["tone"] === void 0 || item["tag"]["tone"] === "neutral" || item["tag"]["tone"] === "accent" || item["tag"]["tone"] === "info" || item["tag"]["tone"] === "success" || item["tag"]["tone"] === "warning" || item["tag"]["tone"] === "danger") &&
|
|
239
|
+
].includes(key)) || Array.isArray(detail) && detail.every((item) => item !== null && typeof item === "object" && !Array.isArray(item) && typeof item["id"] === "string" && typeof item["value"] === "string" && typeof item["label"] === "string" && (item["group"] === void 0 || typeof item["group"] === "string") && (item["disabled"] === void 0 || typeof item["disabled"] === "boolean") && (item["description"] === void 0 || typeof item["description"] === "string") && (item["tag"] === void 0 || item["tag"] !== null && typeof item["tag"] === "object" && !Array.isArray(item["tag"]) && typeof item["tag"]["label"] === "string" && (item["tag"]["tone"] === void 0 || item["tag"]["tone"] === "neutral" || item["tag"]["tone"] === "accent" || item["tag"]["tone"] === "info" || item["tag"]["tone"] === "success" || item["tag"]["tone"] === "warning" || item["tag"]["tone"] === "danger") && (item["tag"]["color"] === void 0 || typeof item["tag"]["color"] === "string") && Object.keys(item["tag"]).every((key) => [
|
|
240
|
+
"label",
|
|
241
|
+
"tone",
|
|
242
|
+
"color"
|
|
243
|
+
].includes(key))) && Object.keys(item).every((key) => [
|
|
236
244
|
"id",
|
|
237
245
|
"value",
|
|
238
246
|
"label",
|
|
@@ -241,7 +249,11 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
241
249
|
"description",
|
|
242
250
|
"tag"
|
|
243
251
|
].includes(key)));
|
|
244
|
-
const isFreeEntryDetail = (detail) => detail !== null && typeof detail === "object" && !Array.isArray(detail) && (typeof detail["value"] === "string" || detail["value"] === null) && typeof detail["query"] === "string" && (detail["option"] !== null && typeof detail["option"] === "object" && !Array.isArray(detail["option"]) && typeof detail["option"]["id"] === "string" && typeof detail["option"]["value"] === "string" && typeof detail["option"]["label"] === "string" && (detail["option"]["group"] === void 0 || typeof detail["option"]["group"] === "string") && (detail["option"]["disabled"] === void 0 || typeof detail["option"]["disabled"] === "boolean") && (detail["option"]["description"] === void 0 || typeof detail["option"]["description"] === "string") && (detail["option"]["tag"] === void 0 || detail["option"]["tag"] !== null && typeof detail["option"]["tag"] === "object" && !Array.isArray(detail["option"]["tag"]) && typeof detail["option"]["tag"]["label"] === "string" && (detail["option"]["tag"]["tone"] === void 0 || detail["option"]["tag"]["tone"] === "neutral" || detail["option"]["tag"]["tone"] === "accent" || detail["option"]["tag"]["tone"] === "info" || detail["option"]["tag"]["tone"] === "success" || detail["option"]["tag"]["tone"] === "warning" || detail["option"]["tag"]["tone"] === "danger") &&
|
|
252
|
+
const isFreeEntryDetail = (detail) => detail !== null && typeof detail === "object" && !Array.isArray(detail) && (typeof detail["value"] === "string" || detail["value"] === null) && typeof detail["query"] === "string" && (detail["option"] !== null && typeof detail["option"] === "object" && !Array.isArray(detail["option"]) && typeof detail["option"]["id"] === "string" && typeof detail["option"]["value"] === "string" && typeof detail["option"]["label"] === "string" && (detail["option"]["group"] === void 0 || typeof detail["option"]["group"] === "string") && (detail["option"]["disabled"] === void 0 || typeof detail["option"]["disabled"] === "boolean") && (detail["option"]["description"] === void 0 || typeof detail["option"]["description"] === "string") && (detail["option"]["tag"] === void 0 || detail["option"]["tag"] !== null && typeof detail["option"]["tag"] === "object" && !Array.isArray(detail["option"]["tag"]) && typeof detail["option"]["tag"]["label"] === "string" && (detail["option"]["tag"]["tone"] === void 0 || detail["option"]["tag"]["tone"] === "neutral" || detail["option"]["tag"]["tone"] === "accent" || detail["option"]["tag"]["tone"] === "info" || detail["option"]["tag"]["tone"] === "success" || detail["option"]["tag"]["tone"] === "warning" || detail["option"]["tag"]["tone"] === "danger") && (detail["option"]["tag"]["color"] === void 0 || typeof detail["option"]["tag"]["color"] === "string") && Object.keys(detail["option"]["tag"]).every((key) => [
|
|
253
|
+
"label",
|
|
254
|
+
"tone",
|
|
255
|
+
"color"
|
|
256
|
+
].includes(key))) && Object.keys(detail["option"]).every((key) => [
|
|
245
257
|
"id",
|
|
246
258
|
"value",
|
|
247
259
|
"label",
|
|
@@ -267,7 +279,11 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
267
279
|
"issues",
|
|
268
280
|
"output"
|
|
269
281
|
].includes(key));
|
|
270
|
-
const isOptionsChangeDetail = (detail) => Array.isArray(detail) && detail.every((item) => item !== null && typeof item === "object" && !Array.isArray(item) && typeof item["id"] === "string" && typeof item["value"] === "string" && typeof item["label"] === "string" && (item["group"] === void 0 || typeof item["group"] === "string") && (item["disabled"] === void 0 || typeof item["disabled"] === "boolean") && (item["description"] === void 0 || typeof item["description"] === "string") && (item["tag"] === void 0 || item["tag"] !== null && typeof item["tag"] === "object" && !Array.isArray(item["tag"]) && typeof item["tag"]["label"] === "string" && (item["tag"]["tone"] === void 0 || item["tag"]["tone"] === "neutral" || item["tag"]["tone"] === "accent" || item["tag"]["tone"] === "info" || item["tag"]["tone"] === "success" || item["tag"]["tone"] === "warning" || item["tag"]["tone"] === "danger") &&
|
|
282
|
+
const isOptionsChangeDetail = (detail) => Array.isArray(detail) && detail.every((item) => item !== null && typeof item === "object" && !Array.isArray(item) && typeof item["id"] === "string" && typeof item["value"] === "string" && typeof item["label"] === "string" && (item["group"] === void 0 || typeof item["group"] === "string") && (item["disabled"] === void 0 || typeof item["disabled"] === "boolean") && (item["description"] === void 0 || typeof item["description"] === "string") && (item["tag"] === void 0 || item["tag"] !== null && typeof item["tag"] === "object" && !Array.isArray(item["tag"]) && typeof item["tag"]["label"] === "string" && (item["tag"]["tone"] === void 0 || item["tag"]["tone"] === "neutral" || item["tag"]["tone"] === "accent" || item["tag"]["tone"] === "info" || item["tag"]["tone"] === "success" || item["tag"]["tone"] === "warning" || item["tag"]["tone"] === "danger") && (item["tag"]["color"] === void 0 || typeof item["tag"]["color"] === "string") && Object.keys(item["tag"]).every((key) => [
|
|
283
|
+
"label",
|
|
284
|
+
"tone",
|
|
285
|
+
"color"
|
|
286
|
+
].includes(key))) && Object.keys(item).every((key) => [
|
|
271
287
|
"id",
|
|
272
288
|
"value",
|
|
273
289
|
"label",
|
|
@@ -276,7 +292,11 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
276
292
|
"description",
|
|
277
293
|
"tag"
|
|
278
294
|
].includes(key)));
|
|
279
|
-
const isAddItemDetail = (detail) => detail !== null && typeof detail === "object" && !Array.isArray(detail) && detail["item"] !== null && typeof detail["item"] === "object" && !Array.isArray(detail["item"]) && typeof detail["item"]["id"] === "string" && typeof detail["item"]["value"] === "string" && typeof detail["item"]["label"] === "string" && (detail["item"]["group"] === void 0 || typeof detail["item"]["group"] === "string") && (detail["item"]["disabled"] === void 0 || typeof detail["item"]["disabled"] === "boolean") && (detail["item"]["description"] === void 0 || typeof detail["item"]["description"] === "string") && (detail["item"]["tag"] === void 0 || detail["item"]["tag"] !== null && typeof detail["item"]["tag"] === "object" && !Array.isArray(detail["item"]["tag"]) && typeof detail["item"]["tag"]["label"] === "string" && (detail["item"]["tag"]["tone"] === void 0 || detail["item"]["tag"]["tone"] === "neutral" || detail["item"]["tag"]["tone"] === "accent" || detail["item"]["tag"]["tone"] === "info" || detail["item"]["tag"]["tone"] === "success" || detail["item"]["tag"]["tone"] === "warning" || detail["item"]["tag"]["tone"] === "danger") &&
|
|
295
|
+
const isAddItemDetail = (detail) => detail !== null && typeof detail === "object" && !Array.isArray(detail) && detail["item"] !== null && typeof detail["item"] === "object" && !Array.isArray(detail["item"]) && typeof detail["item"]["id"] === "string" && typeof detail["item"]["value"] === "string" && typeof detail["item"]["label"] === "string" && (detail["item"]["group"] === void 0 || typeof detail["item"]["group"] === "string") && (detail["item"]["disabled"] === void 0 || typeof detail["item"]["disabled"] === "boolean") && (detail["item"]["description"] === void 0 || typeof detail["item"]["description"] === "string") && (detail["item"]["tag"] === void 0 || detail["item"]["tag"] !== null && typeof detail["item"]["tag"] === "object" && !Array.isArray(detail["item"]["tag"]) && typeof detail["item"]["tag"]["label"] === "string" && (detail["item"]["tag"]["tone"] === void 0 || detail["item"]["tag"]["tone"] === "neutral" || detail["item"]["tag"]["tone"] === "accent" || detail["item"]["tag"]["tone"] === "info" || detail["item"]["tag"]["tone"] === "success" || detail["item"]["tag"]["tone"] === "warning" || detail["item"]["tag"]["tone"] === "danger") && (detail["item"]["tag"]["color"] === void 0 || typeof detail["item"]["tag"]["color"] === "string") && Object.keys(detail["item"]["tag"]).every((key) => [
|
|
296
|
+
"label",
|
|
297
|
+
"tone",
|
|
298
|
+
"color"
|
|
299
|
+
].includes(key))) && Object.keys(detail["item"]).every((key) => [
|
|
280
300
|
"id",
|
|
281
301
|
"value",
|
|
282
302
|
"label",
|
|
@@ -509,11 +529,12 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
509
529
|
id: `${uid.value}-option-${row.index}-label`
|
|
510
530
|
}, toDisplayString(row.label), 9, _hoisted_19), row.tag ? (openBlock(), createBlock(UiBadge_default, {
|
|
511
531
|
key: 0,
|
|
512
|
-
tone: row.tag?.tone
|
|
532
|
+
tone: row.tag?.tone,
|
|
533
|
+
style: normalizeStyle({ "--ui-badge-color": row.tag?.color })
|
|
513
534
|
}, {
|
|
514
535
|
default: withCtx(() => [createElementVNode("span", { id: `${uid.value}-option-${row.index}-tag` }, toDisplayString(row.tag?.label), 9, _hoisted_20)]),
|
|
515
536
|
_: 2
|
|
516
|
-
}, 1032, ["tone"])) : createCommentVNode("v-if", true)]), row.description ? (openBlock(), createElementBlock("span", {
|
|
537
|
+
}, 1032, ["tone", "style"])) : createCommentVNode("v-if", true)]), row.description ? (openBlock(), createElementBlock("span", {
|
|
517
538
|
key: 0,
|
|
518
539
|
class: "description",
|
|
519
540
|
id: `${uid.value}-option-${row.index}-description`
|
|
@@ -543,6 +564,6 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
543
564
|
], 16, _hoisted_1);
|
|
544
565
|
};
|
|
545
566
|
}
|
|
546
|
-
}), [["__scopeId", "data-v-
|
|
567
|
+
}), [["__scopeId", "data-v-af2537d5"]]);
|
|
547
568
|
//#endregion
|
|
548
569
|
export { UiCombobox_default as t };
|