@threadlabs/looma 0.23.10 → 0.23.12
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 +13 -2
- package/components/ui-combobox/ui-combobox.html +6 -0
- package/components/ui-combobox/ui-combobox.js +17 -1
- package/dist/index.js +1 -1
- package/package.json +1 -1
- package/styles/ui-badge.css +15 -1
- package/vanilla/UiCombobox.d.ts +2 -0
- package/vanilla/UiCombobox.js +1 -1
- package/vue/UiBadge.vue +13 -2
- package/vue/UiCombobox.d.ts +18 -0
- package/vue/UiCombobox.vue +39 -0
- package/vue/chunks/UiBadge.js +2 -2
- package/vue/chunks/UiCombobox.js +46 -1
- package/vue/components.css +98 -87
package/vue/UiCombobox.d.ts
CHANGED
|
@@ -22,6 +22,10 @@ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPro
|
|
|
22
22
|
type: PropType<boolean | null>;
|
|
23
23
|
default: boolean;
|
|
24
24
|
};
|
|
25
|
+
autoHighlight: {
|
|
26
|
+
type: PropType<"none" | "single" | null>;
|
|
27
|
+
default: string;
|
|
28
|
+
};
|
|
25
29
|
clearable: {
|
|
26
30
|
type: PropType<boolean | null>;
|
|
27
31
|
default: boolean;
|
|
@@ -102,6 +106,10 @@ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPro
|
|
|
102
106
|
type: PropType<boolean | null>;
|
|
103
107
|
default: boolean;
|
|
104
108
|
};
|
|
109
|
+
selectOnTab: {
|
|
110
|
+
type: PropType<boolean | null>;
|
|
111
|
+
default: boolean;
|
|
112
|
+
};
|
|
105
113
|
selectedValues: {
|
|
106
114
|
type: PropType<readonly (string)[] | null>;
|
|
107
115
|
default: null;
|
|
@@ -275,6 +283,10 @@ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPro
|
|
|
275
283
|
type: PropType<boolean | null>;
|
|
276
284
|
default: boolean;
|
|
277
285
|
};
|
|
286
|
+
autoHighlight: {
|
|
287
|
+
type: PropType<"none" | "single" | null>;
|
|
288
|
+
default: string;
|
|
289
|
+
};
|
|
278
290
|
clearable: {
|
|
279
291
|
type: PropType<boolean | null>;
|
|
280
292
|
default: boolean;
|
|
@@ -355,6 +367,10 @@ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPro
|
|
|
355
367
|
type: PropType<boolean | null>;
|
|
356
368
|
default: boolean;
|
|
357
369
|
};
|
|
370
|
+
selectOnTab: {
|
|
371
|
+
type: PropType<boolean | null>;
|
|
372
|
+
default: boolean;
|
|
373
|
+
};
|
|
358
374
|
selectedValues: {
|
|
359
375
|
type: PropType<readonly (string)[] | null>;
|
|
360
376
|
default: null;
|
|
@@ -548,8 +564,10 @@ declare const __VLS_base: import("vue").DefineComponent<import("vue").ExtractPro
|
|
|
548
564
|
readonly: boolean | null;
|
|
549
565
|
allowCreate: boolean | null;
|
|
550
566
|
allowFreeText: boolean | null;
|
|
567
|
+
autoHighlight: "none" | "single" | null;
|
|
551
568
|
labelVisibility: "visible" | "sr-only" | null;
|
|
552
569
|
openOnFocus: boolean | null;
|
|
570
|
+
selectOnTab: boolean | null;
|
|
553
571
|
selectedValues: readonly string[] | null;
|
|
554
572
|
tokenSeparators: readonly string[] | null;
|
|
555
573
|
}, {}, {}, {}, string, import("vue").ComponentProvideOptions, true, {}, any>;
|
package/vue/UiCombobox.vue
CHANGED
|
@@ -36,6 +36,15 @@ const propValidityContract = {
|
|
|
36
36
|
description: 'Allows values that do not match an authored option.',
|
|
37
37
|
default: false,
|
|
38
38
|
},
|
|
39
|
+
autoHighlight: {
|
|
40
|
+
type: { kind: 'terminal', name: 'keyword' },
|
|
41
|
+
required: false,
|
|
42
|
+
target: { attribute: 'autohighlight' },
|
|
43
|
+
description:
|
|
44
|
+
'single highlights the only enabled authored suggestion while typing. Ambiguous results and an empty query stay unhighlighted. none preserves manual\n highlighting with the arrow keys.',
|
|
45
|
+
values: ['none', 'single'],
|
|
46
|
+
default: 'none',
|
|
47
|
+
},
|
|
39
48
|
clearable: {
|
|
40
49
|
type: { kind: 'terminal', name: 'boolean' },
|
|
41
50
|
required: false,
|
|
@@ -206,6 +215,14 @@ const propValidityContract = {
|
|
|
206
215
|
'Requires a value: adds an asterisk to the label, marks the input required for native form validation, and makes validation report "A value is required."\n when the field is left empty. In multiple mode a chosen item satisfies it, whatever is left in the input.',
|
|
207
216
|
default: false,
|
|
208
217
|
},
|
|
218
|
+
selectOnTab: {
|
|
219
|
+
type: { kind: 'terminal', name: 'boolean' },
|
|
220
|
+
required: false,
|
|
221
|
+
target: { attribute: 'selectontab' },
|
|
222
|
+
description:
|
|
223
|
+
'Commits a highlighted authored suggestion on forward Tab, then lets focus advance normally. In multiple mode a selected suggestion is retained without\n duplication or removal. Shift+Tab does not commit, and Tab never chooses the create offer.',
|
|
224
|
+
default: false,
|
|
225
|
+
},
|
|
209
226
|
selectedValues: {
|
|
210
227
|
type: { kind: 'list', item: { kind: 'terminal', name: 'string' } },
|
|
211
228
|
required: false,
|
|
@@ -241,6 +258,7 @@ const propValidityContract = {
|
|
|
241
258
|
const props = defineProps({
|
|
242
259
|
allowCreate: { type: null as unknown as PropType<boolean | null>, default: false },
|
|
243
260
|
allowFreeText: { type: null as unknown as PropType<boolean | null>, default: false },
|
|
261
|
+
autoHighlight: { type: null as unknown as PropType<'none' | 'single' | null>, default: 'none' },
|
|
244
262
|
clearable: { type: null as unknown as PropType<boolean | null>, default: false },
|
|
245
263
|
disabled: { type: null as unknown as PropType<boolean | null>, default: false },
|
|
246
264
|
disclosure: { type: null as unknown as PropType<boolean | null>, default: false },
|
|
@@ -278,6 +296,7 @@ const props = defineProps({
|
|
|
278
296
|
query: { type: null as unknown as PropType<string | null>, default: null },
|
|
279
297
|
readonly: { type: null as unknown as PropType<boolean | null>, default: false },
|
|
280
298
|
required: { type: null as unknown as PropType<boolean | null>, default: false },
|
|
299
|
+
selectOnTab: { type: null as unknown as PropType<boolean | null>, default: false },
|
|
281
300
|
selectedValues: { type: null as unknown as PropType<readonly (string)[] | null>, default: null },
|
|
282
301
|
size: { type: null as unknown as PropType<'sm' | 'md' | 'lg' | null>, default: 'md' },
|
|
283
302
|
tokenSeparators: { type: null as unknown as PropType<readonly (string)[] | null>, default: null },
|
|
@@ -286,6 +305,7 @@ const props = defineProps({
|
|
|
286
305
|
const acceptedProps: Record<string, unknown> = {
|
|
287
306
|
allowCreate: false,
|
|
288
307
|
allowFreeText: false,
|
|
308
|
+
autoHighlight: 'none',
|
|
289
309
|
clearable: false,
|
|
290
310
|
disabled: false,
|
|
291
311
|
disclosure: false,
|
|
@@ -303,6 +323,7 @@ const acceptedProps: Record<string, unknown> = {
|
|
|
303
323
|
query: null,
|
|
304
324
|
readonly: false,
|
|
305
325
|
required: false,
|
|
326
|
+
selectOnTab: false,
|
|
306
327
|
selectedValues: null,
|
|
307
328
|
size: 'md',
|
|
308
329
|
tokenSeparators: null,
|
|
@@ -323,6 +344,13 @@ const checkedProps = computed(() => ({
|
|
|
323
344
|
'allowFreeText',
|
|
324
345
|
acceptedProps,
|
|
325
346
|
) as boolean,
|
|
347
|
+
autoHighlight: checkedProp<'none' | 'single'>(
|
|
348
|
+
props['autoHighlight'],
|
|
349
|
+
{ kind: 'terminal', name: 'keyword' },
|
|
350
|
+
false,
|
|
351
|
+
'autoHighlight',
|
|
352
|
+
acceptedProps,
|
|
353
|
+
) as 'none' | 'single',
|
|
326
354
|
clearable: checkedProp<boolean>(
|
|
327
355
|
props['clearable'],
|
|
328
356
|
{ kind: 'terminal', name: 'boolean' },
|
|
@@ -491,6 +519,13 @@ const checkedProps = computed(() => ({
|
|
|
491
519
|
'required',
|
|
492
520
|
acceptedProps,
|
|
493
521
|
) as boolean,
|
|
522
|
+
selectOnTab: checkedProp<boolean>(
|
|
523
|
+
props['selectOnTab'],
|
|
524
|
+
{ kind: 'terminal', name: 'boolean' },
|
|
525
|
+
false,
|
|
526
|
+
'selectOnTab',
|
|
527
|
+
acceptedProps,
|
|
528
|
+
) as boolean,
|
|
494
529
|
selectedValues: checkedProp<readonly (string)[]>(
|
|
495
530
|
props['selectedValues'],
|
|
496
531
|
{ kind: 'list', item: { kind: 'terminal', name: 'string' } },
|
|
@@ -1271,6 +1306,7 @@ const { host, ready } = useComponentHost(() => import('../components/ui-combobox
|
|
|
1271
1306
|
propNames: [
|
|
1272
1307
|
'allowCreate',
|
|
1273
1308
|
'allowFreeText',
|
|
1309
|
+
'autoHighlight',
|
|
1274
1310
|
'clearable',
|
|
1275
1311
|
'disabled',
|
|
1276
1312
|
'disclosure',
|
|
@@ -1288,6 +1324,7 @@ const { host, ready } = useComponentHost(() => import('../components/ui-combobox
|
|
|
1288
1324
|
'query',
|
|
1289
1325
|
'readonly',
|
|
1290
1326
|
'required',
|
|
1327
|
+
'selectOnTab',
|
|
1291
1328
|
'selectedValues',
|
|
1292
1329
|
'size',
|
|
1293
1330
|
'tokenSeparators',
|
|
@@ -1402,6 +1439,7 @@ function uniqueKeys<T>(
|
|
|
1402
1439
|
v-prop-validity="{ contract: propValidityContract, values: { ...props } }"
|
|
1403
1440
|
:data-allow-create="reflectedProp('allowCreate', 'allow-create', checkedProps.allowCreate, undefined, false)"
|
|
1404
1441
|
:data-allow-free-text="reflectedProp('allowFreeText', 'allow-free-text', checkedProps.allowFreeText, undefined, false)"
|
|
1442
|
+
:data-auto-highlight="reflectedProp('autoHighlight', 'auto-highlight', checkedProps.autoHighlight, undefined, false)"
|
|
1405
1443
|
:data-clearable="reflectedProp('clearable', 'clearable', checkedProps.clearable, undefined, false)"
|
|
1406
1444
|
:data-disabled="reflectedProp('disabled', 'disabled', checkedProps.disabled, undefined, false)"
|
|
1407
1445
|
:data-disclosure="reflectedProp('disclosure', 'disclosure', checkedProps.disclosure, undefined, false)"
|
|
@@ -1419,6 +1457,7 @@ function uniqueKeys<T>(
|
|
|
1419
1457
|
:data-query="reflectedProp('query', 'query', checkedProps.query, undefined, false)"
|
|
1420
1458
|
:data-readonly="reflectedProp('readonly', 'readonly', checkedProps.readonly, undefined, false)"
|
|
1421
1459
|
:data-required="reflectedProp('required', 'required', checkedProps.required, undefined, false)"
|
|
1460
|
+
:data-select-on-tab="reflectedProp('selectOnTab', 'select-on-tab', checkedProps.selectOnTab, undefined, false)"
|
|
1422
1461
|
:data-selected-values="reflectedProp('selectedValues', 'selected-values', checkedProps.selectedValues, undefined, false)"
|
|
1423
1462
|
:data-size="reflectedProp('size', 'size', checkedProps.size, undefined, false)"
|
|
1424
1463
|
:data-token-separators="reflectedProp('tokenSeparators', 'token-separators', checkedProps.tokenSeparators, undefined, false)"
|
package/vue/chunks/UiBadge.js
CHANGED
|
@@ -87,7 +87,7 @@ var UiBadge_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE
|
|
|
87
87
|
},
|
|
88
88
|
required: false,
|
|
89
89
|
target: { attribute: "variant" },
|
|
90
|
-
description: "Emphasis. subtle sets toned text over a soft wash; solid fills with the tone and uses contrasting text; outline keeps the surface with a toned edge.\n Neutral looks the same in solid and subtle.",
|
|
90
|
+
description: "Emphasis. subtle sets toned text over a soft wash; solid fills with the tone and uses contrasting text; outline keeps the surface with a toned edge.\n Neutral looks the same in solid and subtle. When space is constrained, the label truncates with an ellipsis while its full text remains available.",
|
|
91
91
|
values: [
|
|
92
92
|
"solid",
|
|
93
93
|
"subtle",
|
|
@@ -169,6 +169,6 @@ var UiBadge_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__PURE
|
|
|
169
169
|
}]]);
|
|
170
170
|
};
|
|
171
171
|
}
|
|
172
|
-
}), [["__scopeId", "data-v-
|
|
172
|
+
}), [["__scopeId", "data-v-18b6e16a"]]);
|
|
173
173
|
//#endregion
|
|
174
174
|
export { UiBadge_default as t };
|
package/vue/chunks/UiCombobox.js
CHANGED
|
@@ -9,6 +9,7 @@ import { Fragment, computed, createBlock, createCommentVNode, createElementBlock
|
|
|
9
9
|
var _hoisted_1 = [
|
|
10
10
|
"data-allow-create",
|
|
11
11
|
"data-allow-free-text",
|
|
12
|
+
"data-auto-highlight",
|
|
12
13
|
"data-clearable",
|
|
13
14
|
"data-disabled",
|
|
14
15
|
"data-disclosure",
|
|
@@ -26,6 +27,7 @@ var _hoisted_1 = [
|
|
|
26
27
|
"data-query",
|
|
27
28
|
"data-readonly",
|
|
28
29
|
"data-required",
|
|
30
|
+
"data-select-on-tab",
|
|
29
31
|
"data-selected-values",
|
|
30
32
|
"data-size",
|
|
31
33
|
"data-token-separators",
|
|
@@ -140,6 +142,10 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
140
142
|
type: null,
|
|
141
143
|
default: false
|
|
142
144
|
},
|
|
145
|
+
autoHighlight: {
|
|
146
|
+
type: null,
|
|
147
|
+
default: "none"
|
|
148
|
+
},
|
|
143
149
|
clearable: {
|
|
144
150
|
type: null,
|
|
145
151
|
default: false
|
|
@@ -208,6 +214,10 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
208
214
|
type: null,
|
|
209
215
|
default: false
|
|
210
216
|
},
|
|
217
|
+
selectOnTab: {
|
|
218
|
+
type: null,
|
|
219
|
+
default: false
|
|
220
|
+
},
|
|
211
221
|
selectedValues: {
|
|
212
222
|
type: null,
|
|
213
223
|
default: null
|
|
@@ -263,6 +273,17 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
263
273
|
description: "Allows values that do not match an authored option.",
|
|
264
274
|
default: false
|
|
265
275
|
},
|
|
276
|
+
autoHighlight: {
|
|
277
|
+
type: {
|
|
278
|
+
kind: "terminal",
|
|
279
|
+
name: "keyword"
|
|
280
|
+
},
|
|
281
|
+
required: false,
|
|
282
|
+
target: { attribute: "autohighlight" },
|
|
283
|
+
description: "single highlights the only enabled authored suggestion while typing. Ambiguous results and an empty query stay unhighlighted. none preserves manual\n highlighting with the arrow keys.",
|
|
284
|
+
values: ["none", "single"],
|
|
285
|
+
default: "none"
|
|
286
|
+
},
|
|
266
287
|
clearable: {
|
|
267
288
|
type: {
|
|
268
289
|
kind: "terminal",
|
|
@@ -531,6 +552,16 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
531
552
|
description: "Requires a value: adds an asterisk to the label, marks the input required for native form validation, and makes validation report \"A value is required.\"\n when the field is left empty. In multiple mode a chosen item satisfies it, whatever is left in the input.",
|
|
532
553
|
default: false
|
|
533
554
|
},
|
|
555
|
+
selectOnTab: {
|
|
556
|
+
type: {
|
|
557
|
+
kind: "terminal",
|
|
558
|
+
name: "boolean"
|
|
559
|
+
},
|
|
560
|
+
required: false,
|
|
561
|
+
target: { attribute: "selectontab" },
|
|
562
|
+
description: "Commits a highlighted authored suggestion on forward Tab, then lets focus advance normally. In multiple mode a selected suggestion is retained without\n duplication or removal. Shift+Tab does not commit, and Tab never chooses the create offer.",
|
|
563
|
+
default: false
|
|
564
|
+
},
|
|
534
565
|
selectedValues: {
|
|
535
566
|
type: {
|
|
536
567
|
kind: "list",
|
|
@@ -584,6 +615,7 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
584
615
|
const acceptedProps = {
|
|
585
616
|
allowCreate: false,
|
|
586
617
|
allowFreeText: false,
|
|
618
|
+
autoHighlight: "none",
|
|
587
619
|
clearable: false,
|
|
588
620
|
disabled: false,
|
|
589
621
|
disclosure: false,
|
|
@@ -601,6 +633,7 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
601
633
|
query: null,
|
|
602
634
|
readonly: false,
|
|
603
635
|
required: false,
|
|
636
|
+
selectOnTab: false,
|
|
604
637
|
selectedValues: null,
|
|
605
638
|
size: "md",
|
|
606
639
|
tokenSeparators: null,
|
|
@@ -615,6 +648,10 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
615
648
|
kind: "terminal",
|
|
616
649
|
name: "boolean"
|
|
617
650
|
}, false, "allowFreeText", acceptedProps),
|
|
651
|
+
autoHighlight: checkedProp(props["autoHighlight"], {
|
|
652
|
+
kind: "terminal",
|
|
653
|
+
name: "keyword"
|
|
654
|
+
}, false, "autoHighlight", acceptedProps),
|
|
618
655
|
clearable: checkedProp(props["clearable"], {
|
|
619
656
|
kind: "terminal",
|
|
620
657
|
name: "boolean"
|
|
@@ -781,6 +818,10 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
781
818
|
kind: "terminal",
|
|
782
819
|
name: "boolean"
|
|
783
820
|
}, false, "required", acceptedProps),
|
|
821
|
+
selectOnTab: checkedProp(props["selectOnTab"], {
|
|
822
|
+
kind: "terminal",
|
|
823
|
+
name: "boolean"
|
|
824
|
+
}, false, "selectOnTab", acceptedProps),
|
|
784
825
|
selectedValues: checkedProp(props["selectedValues"], {
|
|
785
826
|
kind: "list",
|
|
786
827
|
item: {
|
|
@@ -1063,6 +1104,7 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
1063
1104
|
propNames: [
|
|
1064
1105
|
"allowCreate",
|
|
1065
1106
|
"allowFreeText",
|
|
1107
|
+
"autoHighlight",
|
|
1066
1108
|
"clearable",
|
|
1067
1109
|
"disabled",
|
|
1068
1110
|
"disclosure",
|
|
@@ -1080,6 +1122,7 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
1080
1122
|
"query",
|
|
1081
1123
|
"readonly",
|
|
1082
1124
|
"required",
|
|
1125
|
+
"selectOnTab",
|
|
1083
1126
|
"selectedValues",
|
|
1084
1127
|
"size",
|
|
1085
1128
|
"tokenSeparators",
|
|
@@ -1176,6 +1219,7 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
1176
1219
|
return withDirectives((openBlock(), createElementBlock("div", mergeProps({ "data-component": "ui-combobox" }, nativeAttrs(_ctx.$attrs), {
|
|
1177
1220
|
"data-allow-create": reflectedProp("allowCreate", "allow-create", checkedProps.value.allowCreate, void 0, false),
|
|
1178
1221
|
"data-allow-free-text": reflectedProp("allowFreeText", "allow-free-text", checkedProps.value.allowFreeText, void 0, false),
|
|
1222
|
+
"data-auto-highlight": reflectedProp("autoHighlight", "auto-highlight", checkedProps.value.autoHighlight, void 0, false),
|
|
1179
1223
|
"data-clearable": reflectedProp("clearable", "clearable", checkedProps.value.clearable, void 0, false),
|
|
1180
1224
|
"data-disabled": reflectedProp("disabled", "disabled", checkedProps.value.disabled, void 0, false),
|
|
1181
1225
|
"data-disclosure": reflectedProp("disclosure", "disclosure", checkedProps.value.disclosure, void 0, false),
|
|
@@ -1193,6 +1237,7 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
1193
1237
|
"data-query": reflectedProp("query", "query", checkedProps.value.query, void 0, false),
|
|
1194
1238
|
"data-readonly": reflectedProp("readonly", "readonly", checkedProps.value.readonly, void 0, false),
|
|
1195
1239
|
"data-required": reflectedProp("required", "required", checkedProps.value.required, void 0, false),
|
|
1240
|
+
"data-select-on-tab": reflectedProp("selectOnTab", "select-on-tab", checkedProps.value.selectOnTab, void 0, false),
|
|
1196
1241
|
"data-selected-values": reflectedProp("selectedValues", "selected-values", checkedProps.value.selectedValues, void 0, false),
|
|
1197
1242
|
"data-size": reflectedProp("size", "size", checkedProps.value.size, void 0, false),
|
|
1198
1243
|
"data-token-separators": reflectedProp("tokenSeparators", "token-separators", checkedProps.value.tokenSeparators, void 0, false),
|
|
@@ -1413,6 +1458,6 @@ var UiCombobox_default = /*#__PURE__*/ _plugin_vue_export_helper_default(/* @__P
|
|
|
1413
1458
|
}]]);
|
|
1414
1459
|
};
|
|
1415
1460
|
}
|
|
1416
|
-
}), [["__scopeId", "data-v-
|
|
1461
|
+
}), [["__scopeId", "data-v-8e9a00eb"]]);
|
|
1417
1462
|
//#endregion
|
|
1418
1463
|
export { UiCombobox_default as t };
|