@vaadin/multi-select-combo-box 24.1.5 → 24.2.0-alpha10
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/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@vaadin/multi-select-combo-box",
|
|
3
|
-
"version": "24.
|
|
3
|
+
"version": "24.2.0-alpha10",
|
|
4
4
|
"publishConfig": {
|
|
5
5
|
"access": "public"
|
|
6
6
|
},
|
|
@@ -37,21 +37,21 @@
|
|
|
37
37
|
],
|
|
38
38
|
"dependencies": {
|
|
39
39
|
"@polymer/polymer": "^3.0.0",
|
|
40
|
-
"@vaadin/a11y-base": "
|
|
41
|
-
"@vaadin/combo-box": "
|
|
42
|
-
"@vaadin/component-base": "
|
|
43
|
-
"@vaadin/field-base": "
|
|
44
|
-
"@vaadin/input-container": "
|
|
45
|
-
"@vaadin/item": "
|
|
46
|
-
"@vaadin/lit-renderer": "
|
|
47
|
-
"@vaadin/overlay": "
|
|
48
|
-
"@vaadin/vaadin-lumo-styles": "
|
|
49
|
-
"@vaadin/vaadin-material-styles": "
|
|
50
|
-
"@vaadin/vaadin-themable-mixin": "
|
|
40
|
+
"@vaadin/a11y-base": "24.2.0-alpha10",
|
|
41
|
+
"@vaadin/combo-box": "24.2.0-alpha10",
|
|
42
|
+
"@vaadin/component-base": "24.2.0-alpha10",
|
|
43
|
+
"@vaadin/field-base": "24.2.0-alpha10",
|
|
44
|
+
"@vaadin/input-container": "24.2.0-alpha10",
|
|
45
|
+
"@vaadin/item": "24.2.0-alpha10",
|
|
46
|
+
"@vaadin/lit-renderer": "24.2.0-alpha10",
|
|
47
|
+
"@vaadin/overlay": "24.2.0-alpha10",
|
|
48
|
+
"@vaadin/vaadin-lumo-styles": "24.2.0-alpha10",
|
|
49
|
+
"@vaadin/vaadin-material-styles": "24.2.0-alpha10",
|
|
50
|
+
"@vaadin/vaadin-themable-mixin": "24.2.0-alpha10"
|
|
51
51
|
},
|
|
52
52
|
"devDependencies": {
|
|
53
53
|
"@esm-bundle/chai": "^4.3.4",
|
|
54
|
-
"@vaadin/testing-helpers": "^0.
|
|
54
|
+
"@vaadin/testing-helpers": "^0.5.0",
|
|
55
55
|
"lit": "^2.0.0",
|
|
56
56
|
"sinon": "^13.0.2"
|
|
57
57
|
},
|
|
@@ -59,5 +59,5 @@
|
|
|
59
59
|
"web-types.json",
|
|
60
60
|
"web-types.lit.json"
|
|
61
61
|
],
|
|
62
|
-
"gitHead": "
|
|
62
|
+
"gitHead": "ca16b5f88b00ae05fb6d7c7e9874525048e389f0"
|
|
63
63
|
}
|
|
@@ -232,18 +232,20 @@ class MultiSelectComboBoxInternal extends ComboBoxDataProviderMixin(ComboBoxMixi
|
|
|
232
232
|
/**
|
|
233
233
|
* Override method inherited from the combo-box
|
|
234
234
|
* to close dropdown on blur when readonly.
|
|
235
|
-
* @param {
|
|
235
|
+
* @param {boolean} focused
|
|
236
236
|
* @protected
|
|
237
237
|
* @override
|
|
238
238
|
*/
|
|
239
|
-
|
|
239
|
+
_setFocused(focused) {
|
|
240
240
|
// Disable combo-box logic that updates selectedItem
|
|
241
241
|
// based on the overlay focused index on input blur
|
|
242
|
-
|
|
242
|
+
if (!focused) {
|
|
243
|
+
this._ignoreCommitValue = true;
|
|
244
|
+
}
|
|
243
245
|
|
|
244
|
-
super.
|
|
246
|
+
super._setFocused(focused);
|
|
245
247
|
|
|
246
|
-
if (this.readonly && !this._closeOnBlurIsPrevented) {
|
|
248
|
+
if (!focused && this.readonly && !this._closeOnBlurIsPrevented) {
|
|
247
249
|
this.close();
|
|
248
250
|
}
|
|
249
251
|
}
|
|
@@ -53,6 +53,11 @@ export type MultiSelectComboBoxChangeEvent<TItem> = Event & {
|
|
|
53
53
|
*/
|
|
54
54
|
export type MultiSelectComboBoxCustomValueSetEvent = CustomEvent<string>;
|
|
55
55
|
|
|
56
|
+
/**
|
|
57
|
+
* Fired when the `dirty` property changes.
|
|
58
|
+
*/
|
|
59
|
+
export type MultiSelectComboBoxDirtyChangedEvent = CustomEvent<{ value: boolean }>;
|
|
60
|
+
|
|
56
61
|
/**
|
|
57
62
|
* Fired when the `filter` property changes.
|
|
58
63
|
*/
|
|
@@ -78,6 +83,8 @@ export interface MultiSelectComboBoxEventMap<TItem> extends HTMLElementEventMap
|
|
|
78
83
|
|
|
79
84
|
'custom-value-set': MultiSelectComboBoxCustomValueSetEvent;
|
|
80
85
|
|
|
86
|
+
'dirty-changed': MultiSelectComboBoxDirtyChangedEvent;
|
|
87
|
+
|
|
81
88
|
'filter-changed': MultiSelectComboBoxFilterChangedEvent;
|
|
82
89
|
|
|
83
90
|
'invalid-changed': MultiSelectComboBoxInvalidChangedEvent;
|
|
@@ -159,6 +166,7 @@ export interface MultiSelectComboBoxEventMap<TItem> extends HTMLElementEventMap
|
|
|
159
166
|
* @fires {CustomEvent} custom-value-set - Fired when the user sets a custom value.
|
|
160
167
|
* @fires {CustomEvent} filter-changed - Fired when the `filter` property changes.
|
|
161
168
|
* @fires {CustomEvent} invalid-changed - Fired when the `invalid` property changes.
|
|
169
|
+
* @fires {CustomEvent} dirty-changed - Fired when the `dirty` property changes.
|
|
162
170
|
* @fires {CustomEvent} selected-items-changed - Fired when the `selectedItems` property changes.
|
|
163
171
|
* @fires {CustomEvent} validated - Fired whenever the field is validated.
|
|
164
172
|
*/
|
|
@@ -527,6 +527,7 @@ class MultiSelectComboBox extends ResizeMixin(InputControlMixin(ThemableMixin(El
|
|
|
527
527
|
this._tooltipController = new TooltipController(this);
|
|
528
528
|
this.addController(this._tooltipController);
|
|
529
529
|
this._tooltipController.setPosition('top');
|
|
530
|
+
this._tooltipController.setAriaTarget(this.inputElement);
|
|
530
531
|
this._tooltipController.setShouldShow((target) => !target.opened);
|
|
531
532
|
|
|
532
533
|
this._inputField = this.shadowRoot.querySelector('[part="input-field"]');
|
|
@@ -812,6 +813,7 @@ class MultiSelectComboBox extends ResizeMixin(InputControlMixin(ThemableMixin(El
|
|
|
812
813
|
|
|
813
814
|
/** @private */
|
|
814
815
|
__updateSelection(selectedItems) {
|
|
816
|
+
this.dirty = true;
|
|
815
817
|
this.selectedItems = selectedItems;
|
|
816
818
|
|
|
817
819
|
this.validate();
|
package/web-types.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/web-types",
|
|
3
3
|
"name": "@vaadin/multi-select-combo-box",
|
|
4
|
-
"version": "24.
|
|
4
|
+
"version": "24.2.0-alpha10",
|
|
5
5
|
"description-markup": "markdown",
|
|
6
6
|
"contributions": {
|
|
7
7
|
"html": {
|
|
@@ -120,6 +120,17 @@
|
|
|
120
120
|
]
|
|
121
121
|
}
|
|
122
122
|
},
|
|
123
|
+
{
|
|
124
|
+
"name": "dirty",
|
|
125
|
+
"description": "Whether the field is dirty.\n\nThe field is automatically marked as dirty once the user triggers\nan `input` or `change` event. Additionally, the field can be manually\nmarked as dirty by setting the property to `true`.",
|
|
126
|
+
"value": {
|
|
127
|
+
"type": [
|
|
128
|
+
"boolean",
|
|
129
|
+
"null",
|
|
130
|
+
"undefined"
|
|
131
|
+
]
|
|
132
|
+
}
|
|
133
|
+
},
|
|
123
134
|
{
|
|
124
135
|
"name": "clear-button-visible",
|
|
125
136
|
"description": "Set to true to display the clear icon which clears the input.",
|
|
@@ -431,6 +442,17 @@
|
|
|
431
442
|
]
|
|
432
443
|
}
|
|
433
444
|
},
|
|
445
|
+
{
|
|
446
|
+
"name": "dirty",
|
|
447
|
+
"description": "Whether the field is dirty.\n\nThe field is automatically marked as dirty once the user triggers\nan `input` or `change` event. Additionally, the field can be manually\nmarked as dirty by setting the property to `true`.",
|
|
448
|
+
"value": {
|
|
449
|
+
"type": [
|
|
450
|
+
"boolean",
|
|
451
|
+
"null",
|
|
452
|
+
"undefined"
|
|
453
|
+
]
|
|
454
|
+
}
|
|
455
|
+
},
|
|
434
456
|
{
|
|
435
457
|
"name": "clearButtonVisible",
|
|
436
458
|
"description": "Set to true to display the clear icon which clears the input.",
|
|
@@ -722,6 +744,10 @@
|
|
|
722
744
|
{
|
|
723
745
|
"name": "invalid-changed",
|
|
724
746
|
"description": "Fired when the `invalid` property changes."
|
|
747
|
+
},
|
|
748
|
+
{
|
|
749
|
+
"name": "dirty-changed",
|
|
750
|
+
"description": "Fired when the `dirty` property changes."
|
|
725
751
|
}
|
|
726
752
|
]
|
|
727
753
|
}
|
package/web-types.lit.json
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"$schema": "https://json.schemastore.org/web-types",
|
|
3
3
|
"name": "@vaadin/multi-select-combo-box",
|
|
4
|
-
"version": "24.
|
|
4
|
+
"version": "24.2.0-alpha10",
|
|
5
5
|
"description-markup": "markdown",
|
|
6
6
|
"framework": "lit",
|
|
7
7
|
"framework-config": {
|
|
@@ -47,6 +47,13 @@
|
|
|
47
47
|
"kind": "expression"
|
|
48
48
|
}
|
|
49
49
|
},
|
|
50
|
+
{
|
|
51
|
+
"name": "?dirty",
|
|
52
|
+
"description": "Whether the field is dirty.\n\nThe field is automatically marked as dirty once the user triggers\nan `input` or `change` event. Additionally, the field can be manually\nmarked as dirty by setting the property to `true`.",
|
|
53
|
+
"value": {
|
|
54
|
+
"kind": "expression"
|
|
55
|
+
}
|
|
56
|
+
},
|
|
50
57
|
{
|
|
51
58
|
"name": "?clearButtonVisible",
|
|
52
59
|
"description": "Set to true to display the clear icon which clears the input.",
|
|
@@ -298,6 +305,13 @@
|
|
|
298
305
|
"value": {
|
|
299
306
|
"kind": "expression"
|
|
300
307
|
}
|
|
308
|
+
},
|
|
309
|
+
{
|
|
310
|
+
"name": "@dirty-changed",
|
|
311
|
+
"description": "Fired when the `dirty` property changes.",
|
|
312
|
+
"value": {
|
|
313
|
+
"kind": "expression"
|
|
314
|
+
}
|
|
301
315
|
}
|
|
302
316
|
]
|
|
303
317
|
}
|