@scania/tegel 1.26.0-value-prop-fix.beta.0 → 1.27.0-allow-numbers-and-zero-values-beta.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 (181) hide show
  1. package/dist/cjs/index-ca8040ad.js +4 -4
  2. package/dist/cjs/loader.cjs.js +1 -1
  3. package/dist/cjs/tds-banner.cjs.entry.js +1 -1
  4. package/dist/cjs/tds-checkbox.cjs.entry.js +10 -3
  5. package/dist/cjs/tds-chip.cjs.entry.js +7 -2
  6. package/dist/cjs/tds-dropdown_2.cjs.entry.js +39 -34
  7. package/dist/cjs/tds-folder-tab.cjs.entry.js +21 -2
  8. package/dist/cjs/tds-folder-tabs.cjs.entry.js +4 -2
  9. package/dist/cjs/tds-icon.cjs.entry.js +1 -1
  10. package/dist/cjs/tds-inline-tab.cjs.entry.js +21 -2
  11. package/dist/cjs/tds-inline-tabs.cjs.entry.js +4 -2
  12. package/dist/cjs/tds-link.cjs.entry.js +17 -3
  13. package/dist/cjs/tds-message.cjs.entry.js +15 -3
  14. package/dist/cjs/tds-modal.cjs.entry.js +74 -2
  15. package/dist/cjs/tds-navigation-tab.cjs.entry.js +21 -2
  16. package/dist/cjs/tds-navigation-tabs.cjs.entry.js +6 -4
  17. package/dist/cjs/tds-popover-core.cjs.entry.js +1 -1
  18. package/dist/cjs/tds-text-field.cjs.entry.js +13 -7
  19. package/dist/cjs/tds-textarea.cjs.entry.js +21 -9
  20. package/dist/cjs/tds-toast.cjs.entry.js +4 -4
  21. package/dist/cjs/tds-toggle.cjs.entry.js +2 -2
  22. package/dist/cjs/tds-tooltip.cjs.entry.js +14 -4
  23. package/dist/cjs/tegel.cjs.js +1 -1
  24. package/dist/collection/components/banner/banner.css +1 -1
  25. package/dist/collection/components/banner/banner.js +1 -1
  26. package/dist/collection/components/checkbox/checkbox.js +44 -3
  27. package/dist/collection/components/chip/chip.js +24 -2
  28. package/dist/collection/components/dropdown/dropdown-option/dropdown-option.js +2 -2
  29. package/dist/collection/components/dropdown/dropdown.js +54 -32
  30. package/dist/collection/components/icon/icon.js +1 -1
  31. package/dist/collection/components/icon/iconsArray.js +96 -1
  32. package/dist/collection/components/link/link.js +17 -3
  33. package/dist/collection/components/message/message.css +44 -26
  34. package/dist/collection/components/message/message.js +49 -2
  35. package/dist/collection/components/modal/modal.js +103 -3
  36. package/dist/collection/components/popover-core/tds-popover-core.css +596 -53
  37. package/dist/collection/components/tabs/folder-tabs/folder-tab/folder-tab.js +21 -2
  38. package/dist/collection/components/tabs/folder-tabs/folder-tabs.js +40 -2
  39. package/dist/collection/components/tabs/inline-tabs/inline-tab/inline-tab.js +21 -2
  40. package/dist/collection/components/tabs/inline-tabs/inline-tabs.js +40 -2
  41. package/dist/collection/components/tabs/navigation-tabs/navigation-tab/navigation-tab.js +21 -2
  42. package/dist/collection/components/tabs/navigation-tabs/navigation-tabs.js +42 -4
  43. package/dist/collection/components/text-field/text-field.js +31 -8
  44. package/dist/collection/components/textarea/textarea.css +11 -6
  45. package/dist/collection/components/textarea/textarea.js +38 -8
  46. package/dist/collection/components/toast/toast.css +1 -1
  47. package/dist/collection/components/toast/toast.js +3 -3
  48. package/dist/collection/components/toggle/toggle.js +2 -2
  49. package/dist/collection/components/tooltip/tooltip.js +40 -4
  50. package/dist/collection/utils/axeHelpers.js +1 -1
  51. package/dist/components/{p-c65351ab.js → p-14ab9663.js} +12 -3
  52. package/dist/components/p-17338bcb.js +115 -0
  53. package/dist/components/{p-98730c19.js → p-2d93a742.js} +4 -4
  54. package/dist/components/p-4487c541.js +65 -0
  55. package/dist/components/{p-29d19dc8.js → p-60ff84f2.js} +1 -1
  56. package/dist/components/{p-3cd8af42.js → p-797c8dce.js} +39 -33
  57. package/dist/components/{p-4c1e3344.js → p-83db8b35.js} +1 -1
  58. package/dist/components/p-e71e3b2e.js +2052 -0
  59. package/dist/components/tds-accordion-item.js +1 -1
  60. package/dist/components/tds-banner.js +2 -2
  61. package/dist/components/tds-checkbox.js +1 -1
  62. package/dist/components/tds-chip.js +9 -3
  63. package/dist/components/tds-datetime.js +1 -1
  64. package/dist/components/tds-dropdown-option.js +1 -1
  65. package/dist/components/tds-dropdown.js +1 -1
  66. package/dist/components/tds-folder-tab.js +21 -2
  67. package/dist/components/tds-folder-tabs.js +7 -3
  68. package/dist/components/tds-footer-group.js +1 -1
  69. package/dist/components/tds-header-cell.js +1 -1
  70. package/dist/components/tds-header-dropdown.js +3 -3
  71. package/dist/components/tds-header-hamburger.js +1 -1
  72. package/dist/components/tds-header-launcher-button.js +1 -1
  73. package/dist/components/tds-header-launcher.js +4 -4
  74. package/dist/components/tds-icon.js +1 -1
  75. package/dist/components/tds-inline-tab.js +21 -2
  76. package/dist/components/tds-inline-tabs.js +7 -3
  77. package/dist/components/tds-link.js +17 -3
  78. package/dist/components/tds-message.js +19 -5
  79. package/dist/components/tds-modal.js +78 -4
  80. package/dist/components/tds-navigation-tab.js +21 -2
  81. package/dist/components/tds-navigation-tabs.js +9 -5
  82. package/dist/components/tds-popover-canvas.js +1 -1
  83. package/dist/components/tds-popover-core.js +1 -1
  84. package/dist/components/tds-popover-menu.js +1 -1
  85. package/dist/components/tds-side-menu-close-button.js +1 -1
  86. package/dist/components/tds-side-menu-dropdown.js +1 -1
  87. package/dist/components/tds-slider.js +1 -1
  88. package/dist/components/tds-step.js +1 -1
  89. package/dist/components/tds-table-body-input-wrapper.js +1 -1
  90. package/dist/components/tds-table-body-row.js +1 -1
  91. package/dist/components/tds-table-footer.js +4 -4
  92. package/dist/components/tds-table-header-input-wrapper.js +1 -1
  93. package/dist/components/tds-table-header.js +1 -1
  94. package/dist/components/tds-table-toolbar.js +1 -1
  95. package/dist/components/tds-text-field.js +15 -8
  96. package/dist/components/tds-textarea.js +36 -11
  97. package/dist/components/tds-toast.js +5 -5
  98. package/dist/components/tds-toggle.js +2 -2
  99. package/dist/components/tds-tooltip.js +1 -102
  100. package/dist/esm/index-51d04e39.js +4 -4
  101. package/dist/esm/loader.js +1 -1
  102. package/dist/esm/tds-banner.entry.js +1 -1
  103. package/dist/esm/tds-checkbox.entry.js +10 -3
  104. package/dist/esm/tds-chip.entry.js +7 -2
  105. package/dist/esm/tds-dropdown_2.entry.js +39 -34
  106. package/dist/esm/tds-folder-tab.entry.js +22 -3
  107. package/dist/esm/tds-folder-tabs.entry.js +4 -2
  108. package/dist/esm/tds-icon.entry.js +1 -1
  109. package/dist/esm/tds-inline-tab.entry.js +22 -3
  110. package/dist/esm/tds-inline-tabs.entry.js +4 -2
  111. package/dist/esm/tds-link.entry.js +17 -3
  112. package/dist/esm/tds-message.entry.js +15 -3
  113. package/dist/esm/tds-modal.entry.js +74 -2
  114. package/dist/esm/tds-navigation-tab.entry.js +22 -3
  115. package/dist/esm/tds-navigation-tabs.entry.js +6 -4
  116. package/dist/esm/tds-popover-core.entry.js +1 -1
  117. package/dist/esm/tds-text-field.entry.js +13 -7
  118. package/dist/esm/tds-textarea.entry.js +21 -9
  119. package/dist/esm/tds-toast.entry.js +4 -4
  120. package/dist/esm/tds-toggle.entry.js +2 -2
  121. package/dist/esm/tds-tooltip.entry.js +14 -4
  122. package/dist/esm/tegel.js +1 -1
  123. package/dist/tegel/p-0f2c9507.entry.js +1 -0
  124. package/dist/tegel/p-125a6b06.entry.js +1 -0
  125. package/dist/tegel/p-28517288.entry.js +1 -0
  126. package/dist/tegel/p-2af57972.entry.js +1 -0
  127. package/dist/tegel/p-3e9ca19a.entry.js +1 -0
  128. package/dist/tegel/{p-be1d1345.entry.js → p-4465f687.entry.js} +1 -1
  129. package/dist/tegel/p-668b7662.entry.js +1 -0
  130. package/dist/tegel/{p-4e298888.entry.js → p-66f394a2.entry.js} +1 -1
  131. package/dist/tegel/p-754a4921.entry.js +1 -0
  132. package/dist/tegel/{p-46205cfb.entry.js → p-769d0503.entry.js} +1 -1
  133. package/dist/tegel/p-843413ba.entry.js +1 -0
  134. package/dist/tegel/p-97f10223.entry.js +1 -0
  135. package/dist/tegel/p-a21250b8.entry.js +1 -0
  136. package/dist/tegel/p-aadb2553.entry.js +1 -0
  137. package/dist/tegel/p-b08886e3.entry.js +1 -0
  138. package/dist/tegel/p-b114ec3d.entry.js +1 -0
  139. package/dist/tegel/p-c3607f10.entry.js +1 -0
  140. package/dist/tegel/p-ddda64eb.entry.js +1 -0
  141. package/dist/tegel/p-eaa279dd.entry.js +1 -0
  142. package/dist/tegel/p-ee960089.entry.js +1 -0
  143. package/dist/tegel/tegel.css +13 -3
  144. package/dist/tegel/tegel.esm.js +1 -1
  145. package/dist/types/components/checkbox/checkbox.d.ts +5 -0
  146. package/dist/types/components/chip/chip.d.ts +3 -0
  147. package/dist/types/components/dropdown/dropdown.d.ts +5 -0
  148. package/dist/types/components/message/message.d.ts +5 -0
  149. package/dist/types/components/modal/modal.d.ts +6 -0
  150. package/dist/types/components/tabs/folder-tabs/folder-tab/folder-tab.d.ts +2 -0
  151. package/dist/types/components/tabs/folder-tabs/folder-tabs.d.ts +4 -0
  152. package/dist/types/components/tabs/inline-tabs/inline-tab/inline-tab.d.ts +2 -0
  153. package/dist/types/components/tabs/inline-tabs/inline-tabs.d.ts +4 -0
  154. package/dist/types/components/tabs/navigation-tabs/navigation-tab/navigation-tab.d.ts +2 -0
  155. package/dist/types/components/tabs/navigation-tabs/navigation-tabs.d.ts +4 -0
  156. package/dist/types/components/text-field/text-field.d.ts +4 -1
  157. package/dist/types/components/textarea/textarea.d.ts +7 -4
  158. package/dist/types/components/tooltip/tooltip.d.ts +3 -0
  159. package/dist/types/components.d.ts +130 -2
  160. package/dist/types/types/Icons.d.ts +1 -1
  161. package/dist/types/utils/axeHelpers.d.ts +1 -2
  162. package/package.json +1 -1
  163. package/dist/components/p-4764a1d5.js +0 -2052
  164. package/dist/components/p-a2b7bdef.js +0 -65
  165. package/dist/tegel/p-065d6f83.entry.js +0 -1
  166. package/dist/tegel/p-0c1e632d.entry.js +0 -1
  167. package/dist/tegel/p-168122a7.entry.js +0 -1
  168. package/dist/tegel/p-19eb4ae1.entry.js +0 -1
  169. package/dist/tegel/p-4e33cbda.entry.js +0 -1
  170. package/dist/tegel/p-4ee344e5.entry.js +0 -1
  171. package/dist/tegel/p-64c80f14.entry.js +0 -1
  172. package/dist/tegel/p-72fd0083.entry.js +0 -1
  173. package/dist/tegel/p-93a4bd11.entry.js +0 -1
  174. package/dist/tegel/p-a0fc0cc2.entry.js +0 -1
  175. package/dist/tegel/p-b35e7208.entry.js +0 -1
  176. package/dist/tegel/p-b6526302.entry.js +0 -1
  177. package/dist/tegel/p-b686f1ad.entry.js +0 -1
  178. package/dist/tegel/p-cca85da0.entry.js +0 -1
  179. package/dist/tegel/p-d0abf078.entry.js +0 -1
  180. package/dist/tegel/p-dcbc35af.entry.js +0 -1
  181. package/dist/tegel/p-f43278f0.entry.js +0 -1
@@ -80,7 +80,7 @@ export class TdsDropdownOption {
80
80
  this.internalValue = convertToString(this.value);
81
81
  }
82
82
  render() {
83
- return (h(Host, { key: 'af1229553e89c02aca1d7c11bbc80acd25ce44b5', role: "option", "aria-disabled": this.disabled, "aria-selected": this.selected }, h("div", { key: 'c93eb33d1864028690ab981c0f676f03993265c4', class: `dropdown-option
83
+ return (h(Host, { key: 'f471d5238869b3a522b36d99d7549c1229cd83a2' }, h("div", { key: 'da9edccba96999b0ee40f8c599325774593de814', class: `dropdown-option
84
84
  ${this.size}
85
85
  ${this.selected ? 'selected' : ''}
86
86
  ${this.disabled ? 'disabled' : ''}
@@ -92,7 +92,7 @@ export class TdsDropdownOption {
92
92
  this.handleMultiselect(event);
93
93
  }, disabled: this.disabled, checked: this.selected, class: {
94
94
  [this.size]: true,
95
- } }, h("div", { slot: "label" }, h("slot", null))))) : (h("button", { onClick: () => {
95
+ } }, h("div", { slot: "label" }, h("slot", null))))) : (h("button", { role: "option", "aria-disabled": this.disabled, "aria-selected": this.selected, onClick: () => {
96
96
  this.handleSingleSelect();
97
97
  }, onFocus: (event) => this.handleFocus(event), onBlur: (event) => this.handleBlur(event), disabled: this.disabled, class: this.size }, h("div", { class: "single-select" }, h("slot", null), this.selected && h("tds-icon", { name: "tick", size: "16px" })))))));
98
98
  }
@@ -14,7 +14,7 @@ export class TdsDropdown {
14
14
  const defaultValues = this.multiselect
15
15
  ? this.internalDefaultValue.split(',')
16
16
  : [this.internalDefaultValue];
17
- this.updateDropdownState(defaultValues);
17
+ this.updateDropdownStateInternal(defaultValues);
18
18
  }
19
19
  };
20
20
  this.getChildren = () => {
@@ -30,7 +30,7 @@ export class TdsDropdown {
30
30
  return this.selectedOptions
31
31
  .map((stringValue) => {
32
32
  var _a;
33
- const matchingElement = (_a = this.getChildren()) === null || _a === void 0 ? void 0 : _a.find((element) => element.value === stringValue);
33
+ const matchingElement = (_a = this.getChildren()) === null || _a === void 0 ? void 0 : _a.find((element) => convertToString(element.value) === convertToString(stringValue));
34
34
  return matchingElement;
35
35
  })
36
36
  .filter(Boolean);
@@ -149,6 +149,7 @@ export class TdsDropdown {
149
149
  this.noResultText = 'No result';
150
150
  this.defaultValue = undefined;
151
151
  this.value = null;
152
+ this.tdsAriaLabel = undefined;
152
153
  this.open = false;
153
154
  this.internalValue = undefined;
154
155
  this.filterResult = undefined;
@@ -157,18 +158,15 @@ export class TdsDropdown {
157
158
  this.selectedOptions = [];
158
159
  }
159
160
  handleValueChange(newValue) {
160
- console.log('Value changed:', newValue); // Debug
161
161
  // Normalize to array
162
162
  const normalizedValue = this.normalizeValue(newValue);
163
- console.log('Normalized value:', normalizedValue); // Debug
164
163
  // Only update if actually changed
165
164
  if (this.hasValueChanged(normalizedValue, this.selectedOptions)) {
166
- console.log('Value has changed, updating state'); // Debug
167
- this.updateDropdownState(normalizedValue);
165
+ this.updateDropdownStateFromUser(normalizedValue);
168
166
  }
169
167
  }
170
168
  normalizeValue(value) {
171
- if (!value || value === '')
169
+ if (value === null || value === undefined || value === '')
172
170
  return [];
173
171
  // For single select, ensure we handle both string and array inputs
174
172
  if (!this.multiselect) {
@@ -193,11 +191,15 @@ export class TdsDropdown {
193
191
  return true;
194
192
  return newValue.some((val) => !currentValue.includes(val));
195
193
  }
196
- updateDropdownState(values) {
197
- console.log('Updating dropdown state with values:', values); // Debug
194
+ updateDropdownStateInternal(values) {
195
+ this.updateDropdownState(values, false);
196
+ }
197
+ updateDropdownStateFromUser(values) {
198
+ this.updateDropdownState(values, true);
199
+ }
200
+ updateDropdownState(values, emitChange = true) {
198
201
  // Validate the values first
199
202
  const validValues = this.validateValues(values);
200
- console.log('Valid values:', validValues); // Debug
201
203
  // Update internal state
202
204
  this.selectedOptions = [...validValues];
203
205
  // Update the value prop
@@ -208,8 +210,9 @@ export class TdsDropdown {
208
210
  this.updateOptionElements();
209
211
  // Update display value
210
212
  this.updateDisplayValue();
211
- // Emit change event
212
- this.emitChange();
213
+ // Emit change event only if value has changed by user
214
+ if (emitChange)
215
+ this.emitChange();
213
216
  // Update value attribute
214
217
  this.setValueAttribute();
215
218
  }
@@ -217,7 +220,7 @@ export class TdsDropdown {
217
220
  // Make sure we have children before validation
218
221
  const children = this.getChildren();
219
222
  if (!children || children.length === 0) {
220
- console.warn('No dropdown options found'); // Debug
223
+ console.warn('No dropdown options found');
221
224
  return values; // Return original values if no children yet
222
225
  }
223
226
  return values.filter((val) => {
@@ -258,18 +261,18 @@ export class TdsDropdown {
258
261
  else {
259
262
  normalizedValue = [convertToString(value)];
260
263
  }
261
- this.updateDropdownState(normalizedValue);
264
+ this.updateDropdownStateFromUser(normalizedValue);
262
265
  return this.getSelectedChildren().map((element) => ({
263
266
  value: element.value,
264
267
  label: element.textContent.trim(),
265
268
  }));
266
269
  }
267
270
  async reset() {
268
- this.updateDropdownState([]);
271
+ this.updateDropdownStateFromUser([]);
269
272
  }
270
273
  async removeValue(oldValue) {
271
274
  const newValues = this.selectedOptions.filter((v) => v !== oldValue);
272
- this.updateDropdownState(newValues);
275
+ this.updateDropdownStateFromUser(newValues);
273
276
  }
274
277
  /** Method that forces focus on the input element. */
275
278
  async focusElement() {
@@ -349,10 +352,8 @@ export class TdsDropdown {
349
352
  componentWillLoad() {
350
353
  // First handle the value prop if it exists
351
354
  if (this.value !== null && this.value !== undefined) {
352
- console.log('Initial value:', this.value); // Debug
353
355
  const normalizedValue = this.normalizeValue(this.value);
354
- console.log('Normalized value:', normalizedValue); // Debug
355
- this.updateDropdownState(normalizedValue);
356
+ this.updateDropdownStateInternal(normalizedValue);
356
357
  return; // Exit early if we handled the value prop
357
358
  }
358
359
  // Only use defaultValue if no value prop was provided
@@ -360,8 +361,8 @@ export class TdsDropdown {
360
361
  const defaultValueStr = convertToString(this.defaultValue);
361
362
  const initialValue = this.multiselect
362
363
  ? defaultValueStr.split(',').map(convertToString)
363
- : [convertToString(this.defaultValue)];
364
- this.updateDropdownState(initialValue);
364
+ : [defaultValueStr];
365
+ this.updateDropdownStateInternal(initialValue);
365
366
  }
366
367
  }
367
368
  /** Method to handle slot changes */
@@ -377,10 +378,10 @@ export class TdsDropdown {
377
378
  */
378
379
  async appendValue(value) {
379
380
  if (this.multiselect) {
380
- this.updateDropdownState([...this.selectedOptions, value]);
381
+ this.updateDropdownStateFromUser([...this.selectedOptions, value]);
381
382
  }
382
383
  else {
383
- this.updateDropdownState([value]);
384
+ this.updateDropdownStateFromUser([value]);
384
385
  }
385
386
  }
386
387
  componentDidRender() {
@@ -395,11 +396,16 @@ export class TdsDropdown {
395
396
  form.removeEventListener('reset', this.resetInput);
396
397
  }
397
398
  }
399
+ connectedCallback() {
400
+ if (!this.tdsAriaLabel) {
401
+ console.warn('Tegel Dropdown component: tdsAriaLabel prop is missing');
402
+ }
403
+ }
398
404
  render() {
399
405
  appendHiddenInput(this.host, this.name, this.selectedOptions.join(','), this.disabled);
400
- return (h(Host, { key: 'a6be6e0f01f203fd2d5777f9026a5b7ed5afc313', role: "select", class: {
406
+ return (h(Host, { key: 'b8c418ebe609789c1610178d764a7d620e2231c2', class: {
401
407
  [`tds-mode-variant-${this.modeVariant}`]: Boolean(this.modeVariant),
402
- } }, this.label && this.labelPosition === 'outside' && (h("div", { key: 'bf629a4d977f27f31cd056f126295d7f3bf00dd7', class: `label-outside ${this.disabled ? 'disabled' : ''}` }, this.label)), h("div", { key: '98ea1eee12a76341af8f2cc81846c93e99f2eae8', class: {
408
+ } }, this.label && this.labelPosition === 'outside' && (h("div", { key: 'ee5c005d5020e2226ce54c93a90f2098e081a6df', class: `label-outside ${this.disabled ? 'disabled' : ''}` }, this.label)), h("div", { key: 'ca674a2361f1301886bb855b7093c67b999a500a', class: {
403
409
  'dropdown-select': true,
404
410
  [this.size]: true,
405
411
  'disabled': this.disabled,
@@ -412,7 +418,7 @@ export class TdsDropdown {
412
418
  label-inside-as-placeholder
413
419
  ${this.size}
414
420
  ${this.selectedOptions.length ? 'selected' : ''}
415
- ` }, this.label)), h("input", {
421
+ ` }, this.label)), h("input", { "aria-label": this.tdsAriaLabel, "aria-disabled": this.disabled,
416
422
  // eslint-disable-next-line no-return-assign
417
423
  ref: (inputEl) => (this.inputElement = inputEl), class: {
418
424
  placeholder: this.labelPosition === 'inside',
@@ -426,8 +432,7 @@ export class TdsDropdown {
426
432
  if (event.key === 'Escape') {
427
433
  this.open = false;
428
434
  }
429
- }
430
- })), h("tds-icon", { tabIndex: 0, role: "button", "aria-label": "Clear filter", svgTitle: "Clear filter", onClick: this.handleFilterReset, onKeyDown: (event) => {
435
+ } })), h("tds-icon", { tabIndex: 0, role: "button", "aria-label": "Clear filter", svgTitle: "Clear filter", onClick: this.handleFilterReset, onKeyDown: (event) => {
431
436
  if (event.key === 'Enter') {
432
437
  this.handleFilterReset();
433
438
  }
@@ -438,7 +443,7 @@ export class TdsDropdown {
438
443
  if (event.key === 'Enter') {
439
444
  this.handleToggleOpen();
440
445
  }
441
- }, class: `menu-icon ${this.open ? 'open' : 'closed'}`, name: "chevron_down", size: "16px" }))) : (h("button", { onClick: () => this.handleToggleOpen(), onKeyDown: (event) => {
446
+ }, class: `menu-icon ${this.open ? 'open' : 'closed'}`, name: "chevron_down", size: "16px" }))) : (h("button", { "aria-label": this.tdsAriaLabel, "aria-disabled": this.disabled, onClick: () => this.handleToggleOpen(), onKeyDown: (event) => {
442
447
  if (event.key === 'Escape') {
443
448
  this.open = false;
444
449
  }
@@ -450,7 +455,7 @@ export class TdsDropdown {
450
455
  label-inside-as-placeholder
451
456
  ${this.size}
452
457
  ${this.selectedOptions.length ? 'selected' : ''}
453
- ` }, this.label)), h("div", { class: `placeholder ${this.size}` }, this.selectedOptions.length ? this.getValue() : this.placeholder), h("tds-icon", { "aria-label": "Open/Close dropdown", svgTitle: "Open/Close dropdown", class: `menu-icon ${this.open ? 'open' : 'closed'}`, name: "chevron_down", size: "16px" }))))), h("div", { key: 'ca3b744399468b3d74e1982b1cb648222e601646', ref: (element) => {
458
+ ` }, this.label)), h("div", { class: `placeholder ${this.size}` }, this.selectedOptions.length ? this.getValue() : this.placeholder), h("tds-icon", { "aria-label": "Open/Close dropdown", svgTitle: "Open/Close dropdown", class: `menu-icon ${this.open ? 'open' : 'closed'}`, name: "chevron_down", size: "16px" }))))), h("div", { key: '14558013e5903958942dc7dd3ef2d3a49f79b245', role: "listbox", "aria-label": this.tdsAriaLabel, "aria-orientation": "vertical", "aria-multiselectable": this.multiselect, ref: (element) => {
454
459
  this.dropdownList = element;
455
460
  }, class: {
456
461
  'dropdown-list': true,
@@ -461,11 +466,11 @@ export class TdsDropdown {
461
466
  'closed': !this.open,
462
467
  [`animation-enter-${this.animation}`]: this.animation !== 'none' && this.open,
463
468
  [`animation-exit-${this.animation}`]: this.animation !== 'none' && !this.open,
464
- } }, h("slot", { key: '97fac699a505a4ce347ee5665aa251a5562d9c97', onSlotchange: () => this.handleSlotChange() }), this.filterResult === 0 && this.noResultText !== '' && (h("div", { key: 'a549305b88f3de4a2dfd8050ea2652b459ecca7d', class: `no-result ${this.size}` }, this.noResultText))), this.helper && (h("div", { key: '3d336b6588a9b9f29f9ac3a92d4c0f81fc65a9d5', class: {
469
+ } }, h("slot", { key: '5f69c2fcb5b6a130888d7cd92d4cb882122e3e58', onSlotchange: () => this.handleSlotChange() }), this.filterResult === 0 && this.noResultText !== '' && (h("div", { key: 'bae7a62960f90cd7b679ac4956a677dbff378ac7', class: `no-result ${this.size}` }, this.noResultText))), this.helper && (h("div", { key: 'be5fe56a1e19e812fa983c22f130c0d3001da55b', class: {
465
470
  helper: true,
466
471
  error: this.error,
467
472
  disabled: this.disabled,
468
- } }, this.error && h("tds-icon", { key: 'fe85fe0e24269416805a570074a65c34224a6fc9', name: "error", size: "16px" }), this.helper))));
473
+ } }, this.error && h("tds-icon", { key: 'c0ccc491caa1aca628aff12e02d8a917a74e9c86', name: "error", size: "16px" }), this.helper))));
469
474
  }
470
475
  static get is() { return "tds-dropdown"; }
471
476
  static get encapsulation() { return "shadow"; }
@@ -780,6 +785,23 @@ export class TdsDropdown {
780
785
  "attribute": "value",
781
786
  "reflect": false,
782
787
  "defaultValue": "null"
788
+ },
789
+ "tdsAriaLabel": {
790
+ "type": "string",
791
+ "mutable": false,
792
+ "complexType": {
793
+ "original": "string",
794
+ "resolved": "string",
795
+ "references": {}
796
+ },
797
+ "required": false,
798
+ "optional": false,
799
+ "docs": {
800
+ "tags": [],
801
+ "text": "Defines aria-label attribute for input"
802
+ },
803
+ "attribute": "tds-aria-label",
804
+ "reflect": false
783
805
  }
784
806
  };
785
807
  }
@@ -49,7 +49,7 @@ export class Icon {
49
49
  "mutable": false,
50
50
  "complexType": {
51
51
  "original": "IconNames",
52
- "resolved": "\"profile\" | \"expand\" | \"info\" | \"error\" | \"global\" | \"copy\" | \"document\" | \"link\" | \"image\" | \"download\" | \"target\" | \"history\" | \"print\" | \"24v_battery_inactive\" | \"24v_battery\" | \"arrow_diagonal\" | \"arrow_down\" | \"arrow_left\" | \"arrow_right\" | \"arrow_up\" | \"audio_inactive\" | \"back\" | \"backward_inactive\" | \"backward\" | \"bento\" | \"burger\" | \"calendar_inactive\" | \"calendar\" | \"card\" | \"cart\" | \"charging_speed_inactive\" | \"charging_speed\" | \"charging_stopped\" | \"chevron_down\" | \"chevron_left\" | \"chevron_right\" | \"chevron_up\" | \"clock_inactive\" | \"clock\" | \"contact_inactive\" | \"contact\" | \"cross\" | \"dashboard\" | \"document_check\" | \"document_doc\" | \"document_eye\" | \"document_pdf\" | \"document_ppt\" | \"document_tool\" | \"document_wrong\" | \"document_xls\" | \"dollar\" | \"doner\" | \"double_kebab\" | \"edit_inactive\" | \"edit\" | \"email\" | \"export_inactive\" | \"export\" | \"eye_inactive\" | \"eye\" | \"face_dissatisfied\" | \"face_neutral\" | \"face_satisfied\" | \"filters_inactive\" | \"filters\" | \"flash\" | \"folder\" | \"forward_inactive\" | \"fuel_gauge_inactive\" | \"fuel_gauge\" | \"hatch_open_inactive\" | \"heart_inactive\" | \"heart\" | \"heating_inactive_screen\" | \"history_inactive\" | \"home_inactive\" | \"home\" | \"image_add\" | \"image_inactive\" | \"image_set\" | \"insights\" | \"kebab\" | \"link_broken\" | \"lock_inactive\" | \"lock\" | \"maximize_fullscreen\" | \"meatballs\" | \"message_inactive\" | \"message\" | \"mileage_inactive\" | \"mileage\" | \"minimize_fullscreen\" | \"minus\" | \"notification_inactive\" | \"notification\" | \"pause_inactive\" | \"pause\" | \"phone_inactive\" | \"phone\" | \"pie_chart\" | \"pin_inactive\" | \"pin\" | \"plus\" | \"print_inactive\" | \"profile_inactive\" | \"proportions_inactive\" | \"proportions\" | \"range_inactive\" | \"range\" | \"redirect\" | \"refresh_inactive\" | \"refresh\" | \"reload_inactive\" | \"reload\" | \"report_inactive\" | \"report\" | \"save_inactive\" | \"save\" | \"search\" | \"send_inactive\" | \"send\" | \"settings\" | \"share\" | \"skip_backwards\" | \"skip_forward\" | \"smartphone_inactive\" | \"smartphone\" | \"sorting\" | \"speedometer_inactive\" | \"speedometer\" | \"star\" | \"support\" | \"target_inactive\" | \"text_inactive\" | \"tick\" | \"timer\" | \"tool_inactive\" | \"tool\" | \"trailer\" | \"trash_inactive\" | \"trash\" | \"truck\" | \"upload\" | \"wallet\" | \"warning\" | \"wifi_inactive\" | \"wifi\"",
52
+ "resolved": "\"profile\" | \"expand\" | \"info\" | \"error\" | \"global\" | \"merge\" | \"copy\" | \"document\" | \"audio\" | \"link\" | \"video\" | \"image\" | \"text\" | \"download\" | \"target\" | \"placeholder\" | \"history\" | \"print\" | \"key\" | \"24v_battery_inactive\" | \"24v_battery\" | \"acceleration_inactive\" | \"acceleration\" | \"adblue_inactive\" | \"adblue\" | \"arrow_diagonal\" | \"arrow_down\" | \"arrow_left\" | \"arrow_right\" | \"arrow_up\" | \"audio_inactive\" | \"award\" | \"back\" | \"backward_inactive\" | \"backward\" | \"bento\" | \"bug_inactive\" | \"bug\" | \"burger\" | \"bus_inactive\" | \"bus\" | \"calendar_inactive\" | \"calendar\" | \"camera_inactive\" | \"camera\" | \"card\" | \"cart\" | \"charging_complete\" | \"charging_failed\" | \"charging_speed_inactive\" | \"charging_speed\" | \"charging_stopped\" | \"chevron_down\" | \"chevron_left\" | \"chevron_right\" | \"chevron_up\" | \"clock_inactive\" | \"clock\" | \"contact_inactive\" | \"contact\" | \"cookie_inactive\" | \"cookie\" | \"coolant_level_inactive\" | \"coolant_level\" | \"cross\" | \"cup_inactive\" | \"cup\" | \"dashboard\" | \"department_inactive\" | \"department\" | \"departure_scheduling_inactive\" | \"departure_scheduling\" | \"diamond_inactive\" | \"diamond\" | \"document_check\" | \"document_doc\" | \"document_eye\" | \"document_pdf\" | \"document_plus_inactive\" | \"document_plus\" | \"document_ppt\" | \"document_tool\" | \"document_wrong\" | \"document_xls\" | \"dollar\" | \"doner\" | \"double_kebab\" | \"driving_licence_inactive\" | \"driving_licence\" | \"drop_inactive\" | \"drop\" | \"edit_inactive\" | \"edit\" | \"email\" | \"engine_inactive\" | \"engine\" | \"environment_inactive\" | \"environment\" | \"exit\" | \"expand_inactive\" | \"export_inactive\" | \"export\" | \"eye_inactive\" | \"eye\" | \"face_dissatisfied\" | \"face_neutral\" | \"face_satisfied\" | \"factory_inactive\" | \"factory\" | \"ferry_inactive\" | \"ferry\" | \"filters_inactive\" | \"filters\" | \"flash_inactive\" | \"flash\" | \"folder\" | \"forward_inactive\" | \"forward\" | \"fuel_gauge_inactive\" | \"fuel_gauge\" | \"fuel_inactive\" | \"fuel\" | \"gift inactive\" | \"gift\" | \"guided_tour_inactive\" | \"guided_tour\" | \"hatch_open_1\" | \"hatch_open_2\" | \"hatch_open_inactive\" | \"hatch_open\" | \"heart_inactive\" | \"heart\" | \"heating_inactive_screen\" | \"history_inactive\" | \"home_inactive\" | \"home\" | \"idea_inactive\" | \"idea\" | \"image_add\" | \"image_inactive\" | \"image_set\" | \"insights\" | \"kebab\" | \"key_inactive\" | \"layer_inactive\" | \"layer\" | \"link_broken\" | \"list_inactive\" | \"list\" | \"lock_inactive\" | \"lock\" | \"map_cursor_inactive\" | \"map_cursor\" | \"maximize_fullscreen\" | \"meatballs\" | \"merge_inactive\" | \"message_inactive\" | \"message\" | \"mileage_inactive\" | \"mileage\" | \"minimize_fullscreen\" | \"minus\" | \"navigate_inactive\" | \"navigate\" | \"notification_inactive\" | \"notification\" | \"oil_level_inactive\" | \"oil_level\" | \"pause_inactive\" | \"pause\" | \"phone_inactive\" | \"phone\" | \"pie_chart\" | \"pin_inactive\" | \"pin\" | \"play_inactive\" | \"play\" | \"plus\" | \"powerplug_inactive\" | \"powerplug\" | \"print_inactive\" | \"privacy_inactive\" | \"privacy\" | \"profile_inactive\" | \"proportions_inactive\" | \"proportions\" | \"range_inactive\" | \"range\" | \"redirect\" | \"refresh_inactive\" | \"refresh\" | \"reload_inactive\" | \"reload\" | \"repeat\" | \"report_inactive\" | \"report\" | \"route_inactive\" | \"route\" | \"save_inactive\" | \"save\" | \"search\" | \"send_inactive\" | \"send\" | \"settings\" | \"share\" | \"skip_backwards\" | \"skip_forward\" | \"smartphone_inactive\" | \"smartphone\" | \"sorting\" | \"speedometer_inactive\" | \"speedometer\" | \"star\" | \"support\" | \"target_inactive\" | \"temperature_inactive\" | \"temperature\" | \"text_inactive\" | \"thumbs_down\" | \"thumbs_up\" | \"tick\" | \"timer\" | \"tool_inactive\" | \"tool\" | \"trailer_inactive\" | \"trailer\" | \"trash_inactive\" | \"trash\" | \"truck_inactive\" | \"truck\" | \"undo_inactive\" | \"undo\" | \"unlock\" | \"upload\" | \"video_inactive\" | \"wallet\" | \"warning\" | \"weight_inactive\" | \"weight\" | \"wifi_inactive\" | \"wifi\" | \"windscreen_heating_inactive\" | \"windscreen_heating\"",
53
53
  "references": {
54
54
  "IconNames": {
55
55
  "location": "import",