@vaadin/multi-select-combo-box 25.0.0-alpha2 → 25.0.0-alpha20
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 +15 -16
- package/src/{vaadin-multi-select-combo-box-styles.d.ts → styles/vaadin-multi-select-combo-box-base-styles.d.ts} +1 -3
- package/src/styles/vaadin-multi-select-combo-box-base-styles.js +58 -0
- package/src/styles/vaadin-multi-select-combo-box-chip-base-styles.js +126 -0
- package/src/styles/vaadin-multi-select-combo-box-overlay-base-styles.js +19 -0
- package/src/styles/vaadin-multi-select-combo-box-scroller-base-styles.js +8 -0
- package/src/vaadin-multi-select-combo-box-chip.js +4 -3
- package/src/vaadin-multi-select-combo-box-container.js +2 -0
- package/src/vaadin-multi-select-combo-box-item.js +7 -11
- package/src/vaadin-multi-select-combo-box-mixin.d.ts +18 -89
- package/src/vaadin-multi-select-combo-box-mixin.js +426 -307
- package/src/vaadin-multi-select-combo-box-overlay.js +5 -19
- package/src/vaadin-multi-select-combo-box-scroller.js +3 -24
- package/src/vaadin-multi-select-combo-box.d.ts +13 -7
- package/src/vaadin-multi-select-combo-box.js +42 -90
- package/vaadin-multi-select-combo-box.js +1 -1
- package/web-types.json +200 -236
- package/web-types.lit.json +76 -83
- package/src/vaadin-multi-select-combo-box-internal-mixin.js +0 -449
- package/src/vaadin-multi-select-combo-box-internal.js +0 -56
- package/src/vaadin-multi-select-combo-box-styles.js +0 -74
- package/theme/lumo/vaadin-multi-select-combo-box-chip-styles.d.ts +0 -10
- package/theme/lumo/vaadin-multi-select-combo-box-chip-styles.js +0 -107
- package/theme/lumo/vaadin-multi-select-combo-box-styles.d.ts +0 -10
- package/theme/lumo/vaadin-multi-select-combo-box-styles.js +0 -118
- package/theme/lumo/vaadin-multi-select-combo-box.d.ts +0 -8
- package/theme/lumo/vaadin-multi-select-combo-box.js +0 -8
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": "25.0.0-
|
|
4
|
+
"version": "25.0.0-alpha20",
|
|
5
5
|
"description-markup": "markdown",
|
|
6
6
|
"framework": "lit",
|
|
7
7
|
"framework-config": {
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"elements": [
|
|
17
17
|
{
|
|
18
18
|
"name": "vaadin-multi-select-combo-box",
|
|
19
|
-
"description": "`<vaadin-multi-select-combo-box>` is a web component that wraps `<vaadin-combo-box>` and extends\nits functionality to allow selecting multiple items, in addition to basic features.\n\n```html\n<vaadin-multi-select-combo-box id=\"comboBox\"></vaadin-multi-select-combo-box>\n```\n```js\nconst comboBox = document.querySelector('#comboBox');\ncomboBox.items = ['apple', 'banana', 'lemon', 'orange'];\ncomboBox.selectedItems = ['lemon', 'orange'];\n```\n\n### Styling\n\nThe following shadow DOM parts are available for styling:\n\nPart name | Description\n-----------------------|----------------\n`chips` | The element that wraps slotted chips for selected items\n`label` | The label element\n`input-field` | The element that wraps prefix, value and suffix\n`clear-button` | The clear button\n`error-message` | The error message element\n`helper-text` | The helper text element wrapper\n`required-indicator` | The `required` state indicator element\n`toggle-button` | The toggle button\n\nThe following state attributes are available for styling:\n\nAttribute | Description\n-----------------------|-----------------\n`disabled` | Set to a disabled element\n`has-value` | Set when the element has a value\n`has-label` | Set when the element has a label\n`has-helper` | Set when the element has helper text or slot\n`has-error-message` | Set when the element has an error message\n`invalid` | Set when the element is invalid\n`focused` | Set when the element is focused\n`focus-ring` | Set when the element is keyboard focused\n`loading` | Set when loading items from the data provider\n`opened` | Set when the dropdown is open\n`readonly` | Set to a readonly element\n\nThe following custom CSS properties are available for styling:\n\nCustom property | Description | Default\n-----------------------------------------------------|----------------------------|--------\n`--vaadin-field-default-width` | Default width of the field | `12em`\n`--vaadin-multi-select-combo-box-overlay-width` | Width of the overlay | `auto`\n`--vaadin-multi-select-combo-box-overlay-max-height` | Max height of the overlay | `65vh`\n`--vaadin-multi-select-combo-box-
|
|
19
|
+
"description": "`<vaadin-multi-select-combo-box>` is a web component that wraps `<vaadin-combo-box>` and extends\nits functionality to allow selecting multiple items, in addition to basic features.\n\n```html\n<vaadin-multi-select-combo-box id=\"comboBox\"></vaadin-multi-select-combo-box>\n```\n```js\nconst comboBox = document.querySelector('#comboBox');\ncomboBox.items = ['apple', 'banana', 'lemon', 'orange'];\ncomboBox.selectedItems = ['lemon', 'orange'];\n```\n\n### Styling\n\nThe following shadow DOM parts are available for styling:\n\nPart name | Description\n-----------------------|----------------\n`chips` | The element that wraps slotted chips for selected items\n`label` | The label element\n`input-field` | The element that wraps prefix, value and suffix\n`field-button` | Set on both clear and toggle buttons\n`clear-button` | The clear button\n`error-message` | The error message element\n`helper-text` | The helper text element wrapper\n`required-indicator` | The `required` state indicator element\n`toggle-button` | The toggle button\n`overlay` | The overlay container\n`content` | The overlay content\n`loader` | The loading indicator shown while loading items\n\nThe following state attributes are available for styling:\n\nAttribute | Description\n-----------------------|-----------------\n`disabled` | Set to a disabled element\n`has-value` | Set when the element has a value\n`has-label` | Set when the element has a label\n`has-helper` | Set when the element has helper text or slot\n`has-error-message` | Set when the element has an error message\n`has-tooltip` | Set when the element has a slotted tooltip\n`invalid` | Set when the element is invalid\n`focused` | Set when the element is focused\n`focus-ring` | Set when the element is keyboard focused\n`loading` | Set when loading items from the data provider\n`opened` | Set when the dropdown is open\n`readonly` | Set to a readonly element\n\nThe following custom CSS properties are available for styling:\n\nCustom property | Description | Default\n-----------------------------------------------------|----------------------------|--------\n`--vaadin-field-default-width` | Default width of the field | `12em`\n`--vaadin-multi-select-combo-box-overlay-width` | Width of the overlay | `auto`\n`--vaadin-multi-select-combo-box-overlay-max-height` | Max height of the overlay | `65vh`\n`--vaadin-multi-select-combo-box-input-min-width` | Min width of the input | `4em`\n\n### Internal components\n\nIn addition to `<vaadin-multi-select-combo-box>` itself, the following internal\ncomponents are themable:\n\n- `<vaadin-multi-select-combo-box-chip>`\n- `<vaadin-multi-select-combo-box-item>` - has the same API as `<vaadin-item>`.\n\nSee [Styling Components](https://vaadin.com/docs/latest/styling/styling-components) documentation.",
|
|
20
20
|
"extension": true,
|
|
21
21
|
"attributes": [
|
|
22
22
|
{
|
|
@@ -26,6 +26,27 @@
|
|
|
26
26
|
"kind": "expression"
|
|
27
27
|
}
|
|
28
28
|
},
|
|
29
|
+
{
|
|
30
|
+
"name": "?opened",
|
|
31
|
+
"description": "True if the dropdown is open, false otherwise.",
|
|
32
|
+
"value": {
|
|
33
|
+
"kind": "expression"
|
|
34
|
+
}
|
|
35
|
+
},
|
|
36
|
+
{
|
|
37
|
+
"name": "?autoOpenDisabled",
|
|
38
|
+
"description": "Set true to prevent the overlay from opening automatically.",
|
|
39
|
+
"value": {
|
|
40
|
+
"kind": "expression"
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
{
|
|
44
|
+
"name": "?readonly",
|
|
45
|
+
"description": "When present, it specifies that the field is read-only.",
|
|
46
|
+
"value": {
|
|
47
|
+
"kind": "expression"
|
|
48
|
+
}
|
|
49
|
+
},
|
|
29
50
|
{
|
|
30
51
|
"name": "?autofocus",
|
|
31
52
|
"description": "Specify that this control should have input focus when the page loads.",
|
|
@@ -56,7 +77,7 @@
|
|
|
56
77
|
},
|
|
57
78
|
{
|
|
58
79
|
"name": "?clearButtonVisible",
|
|
59
|
-
"description": "Set to true to display the clear icon which clears the input.",
|
|
80
|
+
"description": "Set to true to display the clear icon which clears the input.\n\nIt is up to the component to choose where to place the clear icon:\nin the Shadow DOM or in the light DOM. In any way, a reference to\nthe clear icon element should be provided via the `clearElement` getter.",
|
|
60
81
|
"value": {
|
|
61
82
|
"kind": "expression"
|
|
62
83
|
}
|
|
@@ -68,13 +89,6 @@
|
|
|
68
89
|
"kind": "expression"
|
|
69
90
|
}
|
|
70
91
|
},
|
|
71
|
-
{
|
|
72
|
-
"name": "?readonly",
|
|
73
|
-
"description": "When present, it specifies that the field is read-only.",
|
|
74
|
-
"value": {
|
|
75
|
-
"kind": "expression"
|
|
76
|
-
}
|
|
77
|
-
},
|
|
78
92
|
{
|
|
79
93
|
"name": "?autoExpandHorizontally",
|
|
80
94
|
"description": "Set to true to auto expand horizontally, causing input field to\ngrow until max width is reached.",
|
|
@@ -89,13 +103,6 @@
|
|
|
89
103
|
"kind": "expression"
|
|
90
104
|
}
|
|
91
105
|
},
|
|
92
|
-
{
|
|
93
|
-
"name": "?autoOpenDisabled",
|
|
94
|
-
"description": "Set true to prevent the overlay from opening automatically.",
|
|
95
|
-
"value": {
|
|
96
|
-
"kind": "expression"
|
|
97
|
-
}
|
|
98
|
-
},
|
|
99
106
|
{
|
|
100
107
|
"name": "?keepFilter",
|
|
101
108
|
"description": "When true, filter string isn't cleared after selecting an item.",
|
|
@@ -110,13 +117,6 @@
|
|
|
110
117
|
"kind": "expression"
|
|
111
118
|
}
|
|
112
119
|
},
|
|
113
|
-
{
|
|
114
|
-
"name": "?opened",
|
|
115
|
-
"description": "True if the dropdown is open, false otherwise.",
|
|
116
|
-
"value": {
|
|
117
|
-
"kind": "expression"
|
|
118
|
-
}
|
|
119
|
-
},
|
|
120
120
|
{
|
|
121
121
|
"name": "?allowCustomValue",
|
|
122
122
|
"description": "When true, the user can input a value that is not present in the items list.",
|
|
@@ -132,162 +132,155 @@
|
|
|
132
132
|
}
|
|
133
133
|
},
|
|
134
134
|
{
|
|
135
|
-
"name": ".
|
|
136
|
-
"description": "
|
|
137
|
-
"value": {
|
|
138
|
-
"kind": "expression"
|
|
139
|
-
}
|
|
140
|
-
},
|
|
141
|
-
{
|
|
142
|
-
"name": ".errorMessage",
|
|
143
|
-
"description": "Error to show when the field is invalid.",
|
|
135
|
+
"name": ".pageSize",
|
|
136
|
+
"description": "Number of items fetched at a time from the dataprovider.",
|
|
144
137
|
"value": {
|
|
145
138
|
"kind": "expression"
|
|
146
139
|
}
|
|
147
140
|
},
|
|
148
141
|
{
|
|
149
|
-
"name": ".
|
|
150
|
-
"description": "
|
|
142
|
+
"name": ".size",
|
|
143
|
+
"description": "Total number of items.",
|
|
151
144
|
"value": {
|
|
152
145
|
"kind": "expression"
|
|
153
146
|
}
|
|
154
147
|
},
|
|
155
148
|
{
|
|
156
|
-
"name": ".
|
|
157
|
-
"description": "
|
|
149
|
+
"name": ".dataProvider",
|
|
150
|
+
"description": "Function that provides items lazily. Receives arguments `params`, `callback`\n\n`params.page` Requested page index\n\n`params.pageSize` Current page size\n\n`params.filter` Currently applied filter\n\n`callback(items, size)` Callback function with arguments:\n - `items` Current page of items\n - `size` Total number of items.",
|
|
158
151
|
"value": {
|
|
159
152
|
"kind": "expression"
|
|
160
153
|
}
|
|
161
154
|
},
|
|
162
155
|
{
|
|
163
|
-
"name": ".
|
|
164
|
-
"description": "
|
|
156
|
+
"name": ".items",
|
|
157
|
+
"description": "A full set of items to filter the visible options from.\nThe items can be of either `String` or `Object` type.",
|
|
165
158
|
"value": {
|
|
166
159
|
"kind": "expression"
|
|
167
160
|
}
|
|
168
161
|
},
|
|
169
162
|
{
|
|
170
|
-
"name": ".
|
|
171
|
-
"description": "A
|
|
163
|
+
"name": ".filteredItems",
|
|
164
|
+
"description": "A subset of items, filtered based on the user input. Filtered items\ncan be assigned directly to omit the internal filtering functionality.\nThe items can be of either `String` or `Object` type.",
|
|
172
165
|
"value": {
|
|
173
166
|
"kind": "expression"
|
|
174
167
|
}
|
|
175
168
|
},
|
|
176
169
|
{
|
|
177
|
-
"name": ".
|
|
178
|
-
"description": "
|
|
170
|
+
"name": ".filter",
|
|
171
|
+
"description": "Filtering string the user has typed into the input field.",
|
|
179
172
|
"value": {
|
|
180
173
|
"kind": "expression"
|
|
181
174
|
}
|
|
182
175
|
},
|
|
183
176
|
{
|
|
184
|
-
"name": ".
|
|
185
|
-
"description": "
|
|
177
|
+
"name": ".itemLabelPath",
|
|
178
|
+
"description": "Path for label of the item. If `items` is an array of objects, the\n`itemLabelPath` is used to fetch the displayed string label for each\nitem.\n\nThe item label is also used for matching items when processing user\ninput, i.e., for filtering and selecting items.",
|
|
186
179
|
"value": {
|
|
187
180
|
"kind": "expression"
|
|
188
181
|
}
|
|
189
182
|
},
|
|
190
183
|
{
|
|
191
|
-
"name": ".
|
|
192
|
-
"description": "
|
|
184
|
+
"name": ".itemValuePath",
|
|
185
|
+
"description": "Path for the value of the item. If `items` is an array of objects, the\n`itemValuePath:` is used to fetch the string value for the selected\nitem.\n\nThe item value is used in the `value` property of the combo box,\nto provide the form value.",
|
|
193
186
|
"value": {
|
|
194
187
|
"kind": "expression"
|
|
195
188
|
}
|
|
196
189
|
},
|
|
197
190
|
{
|
|
198
|
-
"name": ".
|
|
199
|
-
"description": "
|
|
191
|
+
"name": ".i18n",
|
|
192
|
+
"description": "The object used to localize this component. To change the default\nlocalization, replace this with an object that provides all properties, or\njust the individual properties you want to change.\n\nThe object has the following JSON structure and default values:\n```js\n{\n // Screen reader announcement on clear button click.\n cleared: 'Selection cleared',\n // Screen reader announcement when a chip is focused.\n focused: ' focused. Press Backspace to remove',\n // Screen reader announcement when item is selected.\n selected: 'added to selection',\n // Screen reader announcement when item is deselected.\n deselected: 'removed from selection',\n // Screen reader announcement of the selected items count.\n // {count} is replaced with the actual count of items.\n total: '{count} items selected',\n}\n```",
|
|
200
193
|
"value": {
|
|
201
194
|
"kind": "expression"
|
|
202
195
|
}
|
|
203
196
|
},
|
|
204
197
|
{
|
|
205
|
-
"name": ".
|
|
206
|
-
"description": "
|
|
198
|
+
"name": ".label",
|
|
199
|
+
"description": "The label text for the input node.\nWhen no light dom defined via [slot=label], this value will be used.",
|
|
207
200
|
"value": {
|
|
208
201
|
"kind": "expression"
|
|
209
202
|
}
|
|
210
203
|
},
|
|
211
204
|
{
|
|
212
|
-
"name": ".
|
|
213
|
-
"description": "
|
|
205
|
+
"name": ".errorMessage",
|
|
206
|
+
"description": "Error to show when the field is invalid.",
|
|
214
207
|
"value": {
|
|
215
208
|
"kind": "expression"
|
|
216
209
|
}
|
|
217
210
|
},
|
|
218
211
|
{
|
|
219
|
-
"name": ".
|
|
220
|
-
"description": "
|
|
212
|
+
"name": ".helperText",
|
|
213
|
+
"description": "String used for the helper text.",
|
|
221
214
|
"value": {
|
|
222
215
|
"kind": "expression"
|
|
223
216
|
}
|
|
224
217
|
},
|
|
225
218
|
{
|
|
226
|
-
"name": ".
|
|
227
|
-
"description": "
|
|
219
|
+
"name": ".accessibleName",
|
|
220
|
+
"description": "String used to label the component to screen reader users.",
|
|
228
221
|
"value": {
|
|
229
222
|
"kind": "expression"
|
|
230
223
|
}
|
|
231
224
|
},
|
|
232
225
|
{
|
|
233
|
-
"name": ".
|
|
234
|
-
"description": "
|
|
226
|
+
"name": ".accessibleNameRef",
|
|
227
|
+
"description": "Id of the element used as label of the component to screen reader users.",
|
|
235
228
|
"value": {
|
|
236
229
|
"kind": "expression"
|
|
237
230
|
}
|
|
238
231
|
},
|
|
239
232
|
{
|
|
240
|
-
"name": ".
|
|
241
|
-
"description": "A
|
|
233
|
+
"name": ".allowedCharPattern",
|
|
234
|
+
"description": "A pattern matched against individual characters the user inputs.\n\nWhen set, the field will prevent:\n- `keydown` events if the entered key doesn't match `/^allowedCharPattern$/`\n- `paste` events if the pasted text doesn't match `/^allowedCharPattern*$/`\n- `drop` events if the dropped text doesn't match `/^allowedCharPattern*$/`\n\nFor example, to allow entering only numbers and minus signs, use:\n`allowedCharPattern = \"[\\\\d-]\"`",
|
|
242
235
|
"value": {
|
|
243
236
|
"kind": "expression"
|
|
244
237
|
}
|
|
245
238
|
},
|
|
246
239
|
{
|
|
247
|
-
"name": ".
|
|
248
|
-
"description": "The
|
|
240
|
+
"name": ".name",
|
|
241
|
+
"description": "The name of this field.",
|
|
249
242
|
"value": {
|
|
250
243
|
"kind": "expression"
|
|
251
244
|
}
|
|
252
245
|
},
|
|
253
246
|
{
|
|
254
|
-
"name": ".
|
|
255
|
-
"description": "
|
|
247
|
+
"name": ".placeholder",
|
|
248
|
+
"description": "A hint to the user of what can be entered in the control.\nThe placeholder will be only displayed in the case when\nthere is no item selected.",
|
|
256
249
|
"value": {
|
|
257
250
|
"kind": "expression"
|
|
258
251
|
}
|
|
259
252
|
},
|
|
260
253
|
{
|
|
261
|
-
"name": ".
|
|
262
|
-
"description": "
|
|
254
|
+
"name": ".title",
|
|
255
|
+
"description": "The text usually displayed in a tooltip popup when the mouse is over the field.",
|
|
263
256
|
"value": {
|
|
264
257
|
"kind": "expression"
|
|
265
258
|
}
|
|
266
259
|
},
|
|
267
260
|
{
|
|
268
|
-
"name": ".
|
|
269
|
-
"description": "
|
|
261
|
+
"name": ".itemClassNameGenerator",
|
|
262
|
+
"description": "A function used to generate CSS class names for dropdown\nitems and selected chips based on the item. The return\nvalue should be the generated class name as a string, or\nmultiple class names separated by whitespace characters.",
|
|
270
263
|
"value": {
|
|
271
264
|
"kind": "expression"
|
|
272
265
|
}
|
|
273
266
|
},
|
|
274
267
|
{
|
|
275
|
-
"name": ".
|
|
276
|
-
"description": "
|
|
268
|
+
"name": ".itemIdPath",
|
|
269
|
+
"description": "Path for the id of the item, used to detect whether the item is selected.",
|
|
277
270
|
"value": {
|
|
278
271
|
"kind": "expression"
|
|
279
272
|
}
|
|
280
273
|
},
|
|
281
274
|
{
|
|
282
|
-
"name": ".
|
|
283
|
-
"description": "
|
|
275
|
+
"name": ".selectedItems",
|
|
276
|
+
"description": "The list of selected items.\nNote: modifying the selected items creates a new array each time.",
|
|
284
277
|
"value": {
|
|
285
278
|
"kind": "expression"
|
|
286
279
|
}
|
|
287
280
|
},
|
|
288
281
|
{
|
|
289
|
-
"name": ".
|
|
290
|
-
"description": "
|
|
282
|
+
"name": ".renderer",
|
|
283
|
+
"description": "Custom function for rendering the content of every item.\nReceives three arguments:\n\n- `root` The `<vaadin-multi-select-combo-box-item>` internal container DOM element.\n- `comboBox` The reference to the `<vaadin-multi-select-combo-box>` element.\n- `model` The object with the properties related with the rendered\n item, contains:\n - `model.index` The index of the rendered item.\n - `model.item` The item.",
|
|
291
284
|
"value": {
|
|
292
285
|
"kind": "expression"
|
|
293
286
|
}
|
|
@@ -321,29 +314,29 @@
|
|
|
321
314
|
}
|
|
322
315
|
},
|
|
323
316
|
{
|
|
324
|
-
"name": "@
|
|
325
|
-
"description": "Fired when the `
|
|
317
|
+
"name": "@opened-changed",
|
|
318
|
+
"description": "Fired when the `opened` property changes.",
|
|
326
319
|
"value": {
|
|
327
320
|
"kind": "expression"
|
|
328
321
|
}
|
|
329
322
|
},
|
|
330
323
|
{
|
|
331
|
-
"name": "@
|
|
332
|
-
"description": "Fired when the `
|
|
324
|
+
"name": "@filter-changed",
|
|
325
|
+
"description": "Fired when the `filter` property changes.",
|
|
333
326
|
"value": {
|
|
334
327
|
"kind": "expression"
|
|
335
328
|
}
|
|
336
329
|
},
|
|
337
330
|
{
|
|
338
|
-
"name": "@
|
|
339
|
-
"description": "Fired when the `
|
|
331
|
+
"name": "@invalid-changed",
|
|
332
|
+
"description": "Fired when the `invalid` property changes.",
|
|
340
333
|
"value": {
|
|
341
334
|
"kind": "expression"
|
|
342
335
|
}
|
|
343
336
|
},
|
|
344
337
|
{
|
|
345
|
-
"name": "@
|
|
346
|
-
"description": "Fired when the `
|
|
338
|
+
"name": "@selected-items-changed",
|
|
339
|
+
"description": "Fired when the `selectedItems` property changes.",
|
|
347
340
|
"value": {
|
|
348
341
|
"kind": "expression"
|
|
349
342
|
}
|