@refinitiv-ui/elements 6.8.7 → 6.8.9

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 (209) hide show
  1. package/CHANGELOG.md +180 -433
  2. package/LICENSE +1 -1
  3. package/README.md +13 -11
  4. package/lib/accordion/index.d.ts +1 -1
  5. package/lib/accordion/index.js +4 -7
  6. package/lib/appstate-bar/index.d.ts +2 -2
  7. package/lib/appstate-bar/index.js +10 -4
  8. package/lib/autosuggest/index.d.ts +7 -7
  9. package/lib/autosuggest/index.js +85 -80
  10. package/lib/autosuggest/themes/solar/charcoal/index.js +1 -1
  11. package/lib/autosuggest/themes/solar/pearl/index.js +1 -1
  12. package/lib/button/index.js +7 -10
  13. package/lib/button-bar/index.d.ts +1 -1
  14. package/lib/button-bar/index.js +12 -12
  15. package/lib/calendar/index.d.ts +39 -39
  16. package/lib/calendar/index.js +160 -125
  17. package/lib/calendar/utils.js +2 -2
  18. package/lib/canvas/index.d.ts +1 -1
  19. package/lib/canvas/index.js +2 -4
  20. package/lib/card/helpers/types.d.ts +2 -2
  21. package/lib/card/index.d.ts +5 -5
  22. package/lib/card/index.js +34 -28
  23. package/lib/chart/helpers/legend.js +10 -8
  24. package/lib/chart/index.d.ts +3 -3
  25. package/lib/chart/index.js +17 -17
  26. package/lib/chart/plugins/doughnut-center-label.js +6 -5
  27. package/lib/checkbox/index.d.ts +1 -1
  28. package/lib/checkbox/index.js +12 -13
  29. package/lib/clock/index.d.ts +55 -55
  30. package/lib/clock/index.js +84 -95
  31. package/lib/clock/themes/halo/dark/index.js +1 -1
  32. package/lib/clock/themes/halo/light/index.js +1 -1
  33. package/lib/clock/themes/solar/charcoal/index.js +1 -1
  34. package/lib/clock/themes/solar/pearl/index.js +1 -1
  35. package/lib/collapse/index.d.ts +1 -1
  36. package/lib/collapse/index.js +28 -19
  37. package/lib/collapse/themes/halo/dark/index.js +1 -1
  38. package/lib/collapse/themes/halo/light/index.js +1 -1
  39. package/lib/color-dialog/elements/color-palettes.d.ts +1 -1
  40. package/lib/color-dialog/elements/color-palettes.js +5 -6
  41. package/lib/color-dialog/elements/grayscale-palettes.d.ts +1 -1
  42. package/lib/color-dialog/elements/grayscale-palettes.js +9 -9
  43. package/lib/color-dialog/elements/palettes.js +5 -4
  44. package/lib/color-dialog/helpers/value-model.js +7 -9
  45. package/lib/color-dialog/index.d.ts +6 -6
  46. package/lib/color-dialog/index.js +53 -37
  47. package/lib/color-picker/index.d.ts +2 -2
  48. package/lib/color-picker/index.js +40 -34
  49. package/lib/combo-box/helpers/filter.d.ts +2 -2
  50. package/lib/combo-box/helpers/types.d.ts +1 -1
  51. package/lib/combo-box/index.d.ts +9 -9
  52. package/lib/combo-box/index.js +61 -55
  53. package/lib/configuration/elements/configuration.d.ts +1 -1
  54. package/lib/configuration/elements/configuration.js +2 -2
  55. package/lib/counter/index.d.ts +4 -4
  56. package/lib/counter/index.js +9 -7
  57. package/lib/datetime-field/index.d.ts +4 -5
  58. package/lib/datetime-field/index.js +32 -23
  59. package/lib/datetime-field/utils.js +11 -1
  60. package/lib/datetime-picker/index.d.ts +75 -75
  61. package/lib/datetime-picker/index.js +151 -132
  62. package/lib/datetime-picker/locales.js +5 -5
  63. package/lib/datetime-picker/utils.js +9 -9
  64. package/lib/dialog/draggable-element.js +1 -2
  65. package/lib/dialog/index.d.ts +6 -6
  66. package/lib/dialog/index.js +48 -38
  67. package/lib/email-field/index.d.ts +1 -1
  68. package/lib/email-field/index.js +6 -6
  69. package/lib/events.d.ts +1 -1
  70. package/lib/flag/index.d.ts +1 -1
  71. package/lib/flag/index.js +6 -5
  72. package/lib/flag/utils/FlagLoader.js +1 -1
  73. package/lib/header/index.d.ts +1 -1
  74. package/lib/header/index.js +2 -2
  75. package/lib/header/themes/halo/dark/index.js +1 -1
  76. package/lib/header/themes/halo/light/index.js +1 -1
  77. package/lib/header/themes/solar/charcoal/index.js +1 -1
  78. package/lib/header/themes/solar/pearl/index.js +1 -1
  79. package/lib/heatmap/helpers/color.d.ts +1 -1
  80. package/lib/heatmap/helpers/color.js +11 -5
  81. package/lib/heatmap/helpers/track.js +3 -3
  82. package/lib/heatmap/index.d.ts +9 -9
  83. package/lib/heatmap/index.js +51 -42
  84. package/lib/icon/index.d.ts +2 -2
  85. package/lib/icon/index.js +6 -8
  86. package/lib/icon/utils/IconLoader.d.ts +1 -0
  87. package/lib/icon/utils/IconLoader.js +9 -1
  88. package/lib/interactive-chart/helpers/types.d.ts +3 -3
  89. package/lib/interactive-chart/index.d.ts +34 -34
  90. package/lib/interactive-chart/index.js +72 -57
  91. package/lib/item/helpers/types.d.ts +1 -1
  92. package/lib/item/index.d.ts +3 -3
  93. package/lib/item/index.js +24 -20
  94. package/lib/jsx.d.ts +6 -4
  95. package/lib/label/index.d.ts +1 -1
  96. package/lib/label/index.js +11 -8
  97. package/lib/layout/index.d.ts +7 -7
  98. package/lib/layout/index.js +7 -7
  99. package/lib/led-gauge/index.d.ts +1 -1
  100. package/lib/led-gauge/index.js +10 -10
  101. package/lib/list/elements/list.d.ts +3 -3
  102. package/lib/list/elements/list.js +10 -12
  103. package/lib/list/helpers/renderer.js +2 -2
  104. package/lib/list/helpers/types.d.ts +1 -1
  105. package/lib/list/index.d.ts +1 -1
  106. package/lib/list/renderer.d.ts +7 -7
  107. package/lib/loader/index.js +7 -8
  108. package/lib/multi-input/index.d.ts +6 -6
  109. package/lib/multi-input/index.js +39 -45
  110. package/lib/notification/elements/notification-tray.d.ts +2 -2
  111. package/lib/notification/elements/notification-tray.js +3 -3
  112. package/lib/notification/elements/notification.d.ts +2 -2
  113. package/lib/notification/elements/notification.js +22 -14
  114. package/lib/notification/helpers/status.js +1 -1
  115. package/lib/number-field/index.d.ts +5 -6
  116. package/lib/number-field/index.js +37 -47
  117. package/lib/overlay/elements/overlay-viewport.d.ts +1 -1
  118. package/lib/overlay/elements/overlay.d.ts +2 -2
  119. package/lib/overlay/elements/overlay.js +154 -98
  120. package/lib/overlay/helpers/types.d.ts +1 -1
  121. package/lib/overlay/managers/backdrop-manager.d.ts +1 -1
  122. package/lib/overlay/managers/backdrop-manager.js +2 -2
  123. package/lib/overlay/managers/close-manager.js +2 -1
  124. package/lib/overlay/managers/focus-manager.js +23 -13
  125. package/lib/overlay/managers/interaction-lock-manager.d.ts +4 -4
  126. package/lib/overlay/managers/interaction-lock-manager.js +33 -25
  127. package/lib/overlay/managers/viewport-manager.d.ts +2 -2
  128. package/lib/overlay/managers/viewport-manager.js +3 -2
  129. package/lib/overlay/managers/zindex-manager.js +4 -2
  130. package/lib/overlay-menu/helpers/types.d.ts +2 -2
  131. package/lib/overlay-menu/index.d.ts +1 -1
  132. package/lib/overlay-menu/index.js +44 -33
  133. package/lib/overlay-menu/managers/menu-manager.d.ts +10 -10
  134. package/lib/overlay-menu/managers/menu-manager.js +15 -13
  135. package/lib/pagination/index.d.ts +4 -4
  136. package/lib/pagination/index.js +39 -14
  137. package/lib/panel/index.js +1 -1
  138. package/lib/password-field/index.d.ts +2 -2
  139. package/lib/password-field/index.js +4 -4
  140. package/lib/pill/index.d.ts +1 -1
  141. package/lib/pill/index.js +22 -19
  142. package/lib/progress-bar/index.d.ts +1 -1
  143. package/lib/progress-bar/index.js +38 -37
  144. package/lib/radio-button/index.d.ts +2 -2
  145. package/lib/radio-button/index.js +17 -12
  146. package/lib/radio-button/radio-button-registry.js +8 -5
  147. package/lib/rating/index.d.ts +1 -1
  148. package/lib/rating/index.js +2 -5
  149. package/lib/rating/utils.d.ts +6 -6
  150. package/lib/rating/utils.js +6 -6
  151. package/lib/search-field/index.d.ts +2 -2
  152. package/lib/search-field/index.js +4 -4
  153. package/lib/select/index.d.ts +34 -34
  154. package/lib/select/index.js +70 -83
  155. package/lib/sidebar-layout/index.d.ts +2 -2
  156. package/lib/sidebar-layout/index.js +7 -9
  157. package/lib/slider/index.d.ts +2 -2
  158. package/lib/slider/index.js +57 -45
  159. package/lib/slider/utils.d.ts +10 -10
  160. package/lib/slider/utils.js +10 -10
  161. package/lib/sparkline/index.d.ts +1 -1
  162. package/lib/sparkline/index.js +7 -8
  163. package/lib/swing-gauge/helpers.js +2 -2
  164. package/lib/swing-gauge/index.d.ts +19 -19
  165. package/lib/swing-gauge/index.js +91 -81
  166. package/lib/tab/index.d.ts +1 -1
  167. package/lib/tab/index.js +16 -27
  168. package/lib/tab/themes/halo/dark/index.js +1 -1
  169. package/lib/tab/themes/halo/light/index.js +1 -1
  170. package/lib/tab/themes/solar/charcoal/index.js +1 -1
  171. package/lib/tab/themes/solar/pearl/index.js +1 -1
  172. package/lib/tab-bar/helpers/animate.js +1 -1
  173. package/lib/tab-bar/index.d.ts +1 -1
  174. package/lib/tab-bar/index.js +34 -18
  175. package/lib/tab-bar/themes/halo/dark/index.js +1 -1
  176. package/lib/tab-bar/themes/halo/light/index.js +1 -1
  177. package/lib/text-field/index.d.ts +1 -1
  178. package/lib/text-field/index.js +36 -33
  179. package/lib/time-picker/index.d.ts +6 -6
  180. package/lib/time-picker/index.js +104 -90
  181. package/lib/toggle/index.d.ts +1 -1
  182. package/lib/toggle/index.js +4 -3
  183. package/lib/tooltip/elements/title-tooltip.js +2 -2
  184. package/lib/tooltip/index.d.ts +27 -27
  185. package/lib/tooltip/index.js +42 -38
  186. package/lib/tooltip/managers/tooltip-manager.d.ts +1 -1
  187. package/lib/tornado-chart/elements/tornado-chart.d.ts +1 -1
  188. package/lib/tornado-chart/elements/tornado-chart.js +1 -1
  189. package/lib/tornado-chart/elements/tornado-item.d.ts +2 -2
  190. package/lib/tornado-chart/elements/tornado-item.js +12 -10
  191. package/lib/tree/elements/tree-item.d.ts +3 -3
  192. package/lib/tree/elements/tree-item.js +21 -19
  193. package/lib/tree/elements/tree.d.ts +1 -1
  194. package/lib/tree/elements/tree.js +12 -11
  195. package/lib/tree/helpers/renderer.js +4 -3
  196. package/lib/tree/index.d.ts +1 -1
  197. package/lib/tree/managers/tree-manager.d.ts +1 -1
  198. package/lib/tree/managers/tree-manager.js +17 -18
  199. package/lib/tree/themes/solar/charcoal/index.js +1 -1
  200. package/lib/tree/themes/solar/pearl/index.js +1 -1
  201. package/lib/tree-select/index.d.ts +9 -9
  202. package/lib/tree-select/index.js +91 -82
  203. package/lib/tree-select/themes/halo/dark/index.js +1 -1
  204. package/lib/tree-select/themes/halo/light/index.js +1 -1
  205. package/lib/tree-select/themes/solar/charcoal/index.js +1 -1
  206. package/lib/tree-select/themes/solar/pearl/index.js +1 -1
  207. package/lib/version.js +1 -1
  208. package/package.json +16 -16
  209. package/tsconfig.tsbuildinfo +1 -1
@@ -1,31 +1,25 @@
1
1
  import { __decorate } from "tslib";
2
- import { ControlElement, html, css, FocusedPropertyKey } from '@refinitiv-ui/core';
2
+ import { ControlElement, FocusedPropertyKey, css, html } from '@refinitiv-ui/core';
3
3
  import { customElement } from '@refinitiv-ui/core/decorators/custom-element.js';
4
4
  import { property } from '@refinitiv-ui/core/decorators/property.js';
5
- import { styleMap } from '@refinitiv-ui/core/directives/style-map.js';
6
5
  import { createRef, ref } from '@refinitiv-ui/core/directives/ref.js';
7
- import { VERSION } from '../version.js';
8
- import '../overlay/index.js';
9
- import '../item/index.js';
10
- import '../icon/index.js';
11
- import { Item } from '../item/index.js';
6
+ import { styleMap } from '@refinitiv-ui/core/directives/style-map.js';
7
+ import { AnimationTaskRunner, TimeoutTaskRunner } from '@refinitiv-ui/utils/async.js';
12
8
  import { CollectionComposer } from '@refinitiv-ui/utils/collection.js';
13
- import { TimeoutTaskRunner, AnimationTaskRunner } from '@refinitiv-ui/utils/async.js';
14
9
  import { isElementOverflown } from '@refinitiv-ui/utils/element.js';
10
+ import '../icon/index.js';
11
+ import '../item/index.js';
12
+ import { Item } from '../item/index.js';
13
+ import '../overlay/index.js';
15
14
  import { registerOverflowTooltip } from '../tooltip/index.js';
15
+ import { VERSION } from '../version.js';
16
16
  // Observer config for items
17
17
  const observerOptions = {
18
18
  subtree: true,
19
19
  childList: true,
20
20
  attributes: true,
21
21
  characterData: true,
22
- attributeFilter: [
23
- 'label',
24
- 'value',
25
- 'selected',
26
- 'disabled',
27
- 'readonly'
28
- ]
22
+ attributeFilter: ['label', 'value', 'selected', 'disabled', 'readonly']
29
23
  };
30
24
  const LABEL_SEPARATOR = ', '; // TODO: for multiselect
31
25
  const POPUP_POSITION = ['bottom-start', 'top-start'];
@@ -50,7 +44,7 @@ var Navigation;
50
44
  let Select = class Select extends ControlElement {
51
45
  constructor() {
52
46
  super(...arguments);
53
- this.defaultRole = 'button';
47
+ this.defaultRole = 'combobox';
54
48
  this.composer = new CollectionComposer([]);
55
49
  this._data = null;
56
50
  this.popupDynamicStyles = {}; /* set popup min-width based on select width or CSS vars */
@@ -61,20 +55,20 @@ let Select = class Select extends ControlElement {
61
55
  this.keySearchThrottler = new TimeoutTaskRunner(KEY_SEARCH_DEBOUNCER);
62
56
  this.resizeThrottler = new AnimationTaskRunner();
63
57
  /**
64
- * Placeholder to display when no value is set
65
- */
58
+ * Placeholder to display when no value is set
59
+ */
66
60
  this.placeholder = '';
67
61
  /**
68
- * Toggles the opened state of the list
69
- */
62
+ * Toggles the opened state of the list
63
+ */
70
64
  this.opened = false;
71
65
  /**
72
- * Set state to error
73
- */
66
+ * Set state to error
67
+ */
74
68
  this.error = false;
75
69
  /**
76
- * Set state to warning
77
- */
70
+ * Set state to warning
71
+ */
78
72
  this.warning = false;
79
73
  /**
80
74
  * This variable is here to ensure that the value and data are in sync when data is set after the value.
@@ -98,8 +92,7 @@ let Select = class Select extends ControlElement {
98
92
  * @returns {void}
99
93
  */
100
94
  this.handleMutations = (mutations) => {
101
- const hasLightDomMutations = mutations
102
- .some(m => m.target.getRootNode() !== this.shadowRoot);
95
+ const hasLightDomMutations = mutations.some((m) => m.target.getRootNode() !== this.shadowRoot);
103
96
  if (hasLightDomMutations) {
104
97
  this.requestUpdate();
105
98
  }
@@ -136,19 +129,19 @@ let Select = class Select extends ControlElement {
136
129
  display: inline-block;
137
130
  }
138
131
 
139
- [part=label],
140
- [part=placeholder] {
132
+ [part='label'],
133
+ [part='placeholder'] {
141
134
  white-space: nowrap;
142
135
  overflow: hidden;
143
136
  text-overflow: ellipsis;
144
137
  }
145
- [part=icon] {
138
+ [part='icon'] {
146
139
  flex: none;
147
140
  }
148
- :host [part=list] {
141
+ :host [part='list'] {
149
142
  overflow-y: auto;
150
143
  }
151
- :host [part="list"] ::slotted(:not(ef-item)) {
144
+ :host [part='list'] ::slotted(:not(ef-item)) {
152
145
  display: none;
153
146
  }
154
147
  #box {
@@ -190,42 +183,42 @@ let Select = class Select extends ControlElement {
190
183
  `;
191
184
  }
192
185
  /**
193
- * Current text content of the selected value
194
- * @readonly
195
- */
186
+ * Current text content of the selected value
187
+ * @readonly
188
+ */
196
189
  get label() {
197
190
  return this.labels[0];
198
191
  }
199
192
  /**
200
- * Current text content of the selected values
201
- * @ignore
202
- * @readonly
203
- */
193
+ * Current text content of the selected values
194
+ * @ignore
195
+ * @readonly
196
+ */
204
197
  get labels() {
205
198
  if (this.hasDataItems()) {
206
- return this.selectedDataItems.map(item => this.composer.getItemPropertyValue(item, 'label'));
199
+ return this.selectedDataItems.map((item) => this.composer.getItemPropertyValue(item, 'label'));
207
200
  }
208
- return this.selectedSlotItems.map(item => this.getItemLabel(item));
201
+ return this.selectedSlotItems.map((item) => this.getItemLabel(item));
209
202
  }
210
203
  /**
211
- * Switch to multiple select input
212
- * @ignore
213
- * @param multiple True if element needs to support multi selection
214
- */
204
+ * Switch to multiple select input
205
+ * @ignore
206
+ * @param multiple True if element needs to support multi selection
207
+ */
215
208
  set multiple(multiple) {
216
209
  // TODO: not implemented
217
210
  }
218
211
  /**
219
- * @ignore
220
- */
212
+ * @ignore
213
+ */
221
214
  get multiple() {
222
215
  return false;
223
216
  }
224
217
  /**
225
- * Construct the menu from data object. Cannot be used with slotted content
226
- * @type {SelectData | null}
227
- * @default null
228
- */
218
+ * Construct the menu from data object. Cannot be used with slotted content
219
+ * @type {SelectData | null}
220
+ * @default null
221
+ */
229
222
  get data() {
230
223
  return this._data;
231
224
  }
@@ -249,10 +242,10 @@ let Select = class Select extends ControlElement {
249
242
  this.requestUpdate('data', oldValue);
250
243
  }
251
244
  /**
252
- * Value of the element
253
- * @param value Element value
254
- * @default -
255
- */
245
+ * Value of the element
246
+ * @param value Element value
247
+ * @default -
248
+ */
256
249
  set value(value) {
257
250
  value = this.castValue(value);
258
251
  this.cachedValue = value;
@@ -276,9 +269,9 @@ let Select = class Select extends ControlElement {
276
269
  */
277
270
  get values() {
278
271
  if (this.hasDataItems()) {
279
- return this.selectedDataItems.map(item => this.composer.getItemPropertyValue(item, 'value'));
272
+ return this.selectedDataItems.map((item) => this.composer.getItemPropertyValue(item, 'value'));
280
273
  }
281
- return this.selectedSlotItems.map(item => this.getItemValue(item));
274
+ return this.selectedSlotItems.map((item) => this.getItemValue(item));
282
275
  }
283
276
  /**
284
277
  * Called when connected to DOM
@@ -295,7 +288,8 @@ let Select = class Select extends ControlElement {
295
288
  * @returns {void}
296
289
  */
297
290
  update(changedProperties) {
298
- this.cachedValue = ''; /* reset cached value as it is only valid when value and data are set the same time */
291
+ this.cachedValue =
292
+ ''; /* reset cached value as it is only valid when value and data are set the same time */
299
293
  const focusedChanged = changedProperties.has(FocusedPropertyKey);
300
294
  // the opened logic is bound to focus state
301
295
  if (focusedChanged) {
@@ -327,7 +321,7 @@ let Select = class Select extends ControlElement {
327
321
  firstUpdated(changedProperties) {
328
322
  super.firstUpdated(changedProperties);
329
323
  this.addEventListener('keydown', this.onKeyDown); /* keydown when select is closed */
330
- registerOverflowTooltip(this, () => this.labelText, () => this.labelRef.value ? isElementOverflown(this.labelRef.value) : false);
324
+ registerOverflowTooltip(this, () => this.labelText, () => (this.labelRef.value ? isElementOverflown(this.labelRef.value) : false));
331
325
  }
332
326
  /**
333
327
  * Called when element finished updating
@@ -397,7 +391,8 @@ let Select = class Select extends ControlElement {
397
391
  // this code might happen only when opened has been set during initialisation
398
392
  // or when display is set to none
399
393
  this.resizeThrottler.schedule(() => {
400
- if (this.offsetWidth) { /* must be here to avoid infinitive loop */
394
+ if (this.offsetWidth) {
395
+ /* must be here to avoid infinitive loop */
401
396
  this.restrictPopupWidth();
402
397
  this.requestUpdate();
403
398
  }
@@ -500,7 +495,7 @@ let Select = class Select extends ControlElement {
500
495
  */
501
496
  onPopupClosed({ target }) {
502
497
  const eventOptions = {
503
- capture: true,
498
+ /* need this for IE11, otherwise the event is not removed */ capture: true,
504
499
  passive: true
505
500
  };
506
501
  target?.removeEventListener('scroll', this.onPopupScroll, eventOptions);
@@ -601,10 +596,7 @@ let Select = class Select extends ControlElement {
601
596
  */
602
597
  isValidFilterKey(event) {
603
598
  // all printable keys have length of 1. This is better than regexp as we cover all non latin characters
604
- return event.key.length === 1
605
- && !event.ctrlKey
606
- && !event.altKey
607
- && !event.metaKey;
599
+ return event.key.length === 1 && !event.ctrlKey && !event.altKey && !event.metaKey;
608
600
  }
609
601
  /**
610
602
  * Focus and highlight element according to specified direction
@@ -676,7 +668,7 @@ let Select = class Select extends ControlElement {
676
668
  let selectableElements = this.getSelectableElements();
677
669
  const highlightedIdx = this.highlightedItem ? selectableElements.indexOf(this.highlightedItem) : -1;
678
670
  selectableElements = selectableElements.concat(selectableElements.splice(0, highlightedIdx));
679
- const focusElement = selectableElements.find(item => {
671
+ const focusElement = selectableElements.find((item) => {
680
672
  const label = this.getItemLabel(item).toLowerCase();
681
673
  return label.startsWith(this.keySearchTerm) && item !== this.highlightedItem;
682
674
  });
@@ -738,7 +730,7 @@ let Select = class Select extends ControlElement {
738
730
  * @returns A list of selected elements
739
731
  */
740
732
  getSelectedElements() {
741
- return this.getSelectableElements().filter(item => item.selected);
733
+ return this.getSelectableElements().filter((item) => item.selected);
742
734
  }
743
735
  /**
744
736
  * Clears the current selected items
@@ -749,7 +741,7 @@ let Select = class Select extends ControlElement {
749
741
  this.selectedDataItems.forEach((item) => this.composer.setItemPropertyValue(item, 'selected', false));
750
742
  }
751
743
  else {
752
- this.selectedSlotItems.forEach(item => {
744
+ this.selectedSlotItems.forEach((item) => {
753
745
  item.selected = false;
754
746
  });
755
747
  }
@@ -861,11 +853,7 @@ let Select = class Select extends ControlElement {
861
853
  case 'divider':
862
854
  return html `<ef-item role="presentation" part="item" type="divider"></ef-item>`;
863
855
  case 'header':
864
- return html `<ef-item
865
- role="presentation"
866
- part="item"
867
- type="header"
868
- .label=${item.label}></ef-item>`;
856
+ return html `<ef-item role="presentation" part="item" type="header" .label=${item.label}></ef-item>`;
869
857
  // no default
870
858
  }
871
859
  return html `<ef-item
@@ -910,11 +898,11 @@ let Select = class Select extends ControlElement {
910
898
  * Get data iterator template
911
899
  */
912
900
  get dataContent() {
913
- return html `${this.composer.queryItems(() => true).map(item => this.toItem(item))}`;
901
+ return html `${this.composer.queryItems(() => true).map((item) => this.toItem(item))}`;
914
902
  }
915
903
  /**
916
- * Edit template when select is not readonly or disabled
917
- */
904
+ * Edit template when select is not readonly or disabled
905
+ */
918
906
  get popupTemplate() {
919
907
  if (this.lazyRendered) {
920
908
  return html `<ef-overlay
@@ -935,7 +923,9 @@ let Select = class Select extends ControlElement {
935
923
  @opened-changed="${this.onPopupOpenedChanged}"
936
924
  @opened="${this.onPopupOpened}"
937
925
  @refit=${this.onPopupRefit}
938
- @closed="${this.onPopupClosed}">${this.hasDataItems() ? this.dataContent : this.slottedContent}</ef-overlay>`;
926
+ @closed="${this.onPopupClosed}"
927
+ >${this.hasDataItems() ? this.dataContent : this.slottedContent}</ef-overlay
928
+ >`;
939
929
  }
940
930
  else {
941
931
  // This code is required because IE11 polyfill need items to be within a slot
@@ -949,14 +939,11 @@ let Select = class Select extends ControlElement {
949
939
  * @return Render template
950
940
  */
951
941
  render() {
952
- return html `
953
- <div id="box">
954
- <div id="text">
955
- ${this.placeholderHidden() ? this.labelTemplate : this.placeholderTemplate}
942
+ return html ` <div id="box">
943
+ <div id="text">${this.placeholderHidden() ? this.labelTemplate : this.placeholderTemplate}</div>
944
+ <ef-icon icon="down" part="icon"></ef-icon>
956
945
  </div>
957
- <ef-icon icon="down" part="icon"></ef-icon>
958
- </div>
959
- ${this.editTemplate}`;
946
+ ${this.editTemplate}`;
960
947
  }
961
948
  };
962
949
  __decorate([
@@ -1,7 +1,7 @@
1
1
  import { JSXInterface } from '../jsx';
2
- import { BasicElement, TemplateResult, CSSResultGroup, PropertyValues } from '@refinitiv-ui/core';
3
- import type { Layout } from '../layout';
2
+ import { BasicElement, CSSResultGroup, PropertyValues, TemplateResult } from '@refinitiv-ui/core';
4
3
  import '../layout/index.js';
4
+ import type { Layout } from '../layout';
5
5
  /**
6
6
  * Provides an app layout with sidebar.
7
7
  * There are 4 sections that can be slotted a component in.
@@ -1,10 +1,10 @@
1
1
  import { __decorate } from "tslib";
2
- import { BasicElement, html, css, nothing } from '@refinitiv-ui/core';
2
+ import { BasicElement, css, html, nothing } from '@refinitiv-ui/core';
3
3
  import { customElement } from '@refinitiv-ui/core/decorators/custom-element.js';
4
4
  import { property } from '@refinitiv-ui/core/decorators/property.js';
5
5
  import { query } from '@refinitiv-ui/core/decorators/query.js';
6
- import { VERSION } from '../version.js';
7
6
  import '../layout/index.js';
7
+ import { VERSION } from '../version.js';
8
8
  /**
9
9
  * Provides an app layout with sidebar.
10
10
  * There are 4 sections that can be slotted a component in.
@@ -45,7 +45,7 @@ let SidebarLayout = class SidebarLayout extends BasicElement {
45
45
  display: block;
46
46
  }
47
47
 
48
- [part=container] {
48
+ [part='container'] {
49
49
  height: 100%;
50
50
  }
51
51
 
@@ -58,16 +58,16 @@ let SidebarLayout = class SidebarLayout extends BasicElement {
58
58
  height: 100%;
59
59
  }
60
60
 
61
- [part=sidebar] {
61
+ [part='sidebar'] {
62
62
  width: var(--sidebar-width);
63
63
  }
64
64
 
65
- :host([collapsed]:not([sidebar-position])) [part=sidebar],
66
- :host([collapsed][sidebar-position=left]) [part=sidebar] {
65
+ :host([collapsed]:not([sidebar-position])) [part='sidebar'],
66
+ :host([collapsed][sidebar-position='left']) [part='sidebar'] {
67
67
  margin-left: calc(var(--sidebar-width) * -1);
68
68
  }
69
69
 
70
- :host([collapsed][sidebar-position=right]) [part=sidebar] {
70
+ :host([collapsed][sidebar-position='right']) [part='sidebar'] {
71
71
  margin-right: calc(var(--sidebar-width) * -1);
72
72
  }
73
73
  `;
@@ -80,7 +80,6 @@ let SidebarLayout = class SidebarLayout extends BasicElement {
80
80
  render() {
81
81
  return html `
82
82
  <ef-layout flex nowrap part="container">
83
-
84
83
  <ef-layout flex container part="sidebar" size="${this.sidebarWidth || nothing}">
85
84
  <ef-layout size="auto">
86
85
  <slot name="sidebar-header"></slot>
@@ -98,7 +97,6 @@ let SidebarLayout = class SidebarLayout extends BasicElement {
98
97
  <slot name="main-content"></slot>
99
98
  </ef-layout>
100
99
  </ef-layout>
101
-
102
100
  </ef-layout>
103
101
  `;
104
102
  }
@@ -1,7 +1,7 @@
1
1
  import { JSXInterface } from '../jsx';
2
- import { ControlElement, TemplateResult, CSSResultGroup, PropertyValues } from '@refinitiv-ui/core';
3
- import { TranslateDirective } from '@refinitiv-ui/translate';
2
+ import { CSSResultGroup, ControlElement, PropertyValues, TemplateResult } from '@refinitiv-ui/core';
4
3
  import '@refinitiv-ui/phrasebook/locale/en/slider.js';
4
+ import { TranslateDirective } from '@refinitiv-ui/translate';
5
5
  import '../number-field/index.js';
6
6
  /**
7
7
  * Allows users to make selections from a range of values