@refinitiv-ui/elements 6.9.0-next.0 → 6.9.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 (440) hide show
  1. package/CHANGELOG.md +218 -380
  2. package/LICENSE +1 -1
  3. package/README.md +12 -10
  4. package/lib/accordion/index.d.ts +1 -1
  5. package/lib/accordion/index.js +4 -7
  6. package/lib/accordion/themes/halo/dark/index.js +0 -1
  7. package/lib/accordion/themes/halo/light/index.js +0 -1
  8. package/lib/accordion/themes/solar/charcoal/index.js +0 -1
  9. package/lib/accordion/themes/solar/pearl/index.js +0 -1
  10. package/lib/appstate-bar/index.d.ts +2 -2
  11. package/lib/appstate-bar/index.js +10 -4
  12. package/lib/appstate-bar/themes/halo/dark/index.js +0 -1
  13. package/lib/appstate-bar/themes/halo/light/index.js +0 -1
  14. package/lib/appstate-bar/themes/solar/charcoal/index.js +0 -1
  15. package/lib/appstate-bar/themes/solar/pearl/index.js +0 -1
  16. package/lib/autosuggest/index.d.ts +7 -7
  17. package/lib/autosuggest/index.js +89 -84
  18. package/lib/autosuggest/themes/halo/dark/index.js +0 -1
  19. package/lib/autosuggest/themes/halo/light/index.js +0 -1
  20. package/lib/autosuggest/themes/solar/charcoal/index.js +1 -2
  21. package/lib/autosuggest/themes/solar/pearl/index.js +1 -2
  22. package/lib/button/index.js +7 -10
  23. package/lib/button/themes/halo/dark/index.js +0 -1
  24. package/lib/button/themes/halo/light/index.js +0 -1
  25. package/lib/button/themes/solar/charcoal/index.js +0 -1
  26. package/lib/button/themes/solar/pearl/index.js +0 -1
  27. package/lib/button-bar/index.d.ts +1 -1
  28. package/lib/button-bar/index.js +12 -12
  29. package/lib/button-bar/themes/halo/dark/index.js +0 -1
  30. package/lib/button-bar/themes/halo/light/index.js +0 -1
  31. package/lib/button-bar/themes/solar/charcoal/index.js +0 -1
  32. package/lib/button-bar/themes/solar/pearl/index.js +0 -1
  33. package/lib/calendar/index.d.ts +39 -39
  34. package/lib/calendar/index.js +165 -132
  35. package/lib/calendar/themes/halo/dark/index.js +0 -1
  36. package/lib/calendar/themes/halo/light/index.js +0 -1
  37. package/lib/calendar/themes/solar/charcoal/index.js +0 -1
  38. package/lib/calendar/themes/solar/pearl/index.js +0 -1
  39. package/lib/calendar/utils.js +2 -2
  40. package/lib/canvas/index.d.ts +1 -1
  41. package/lib/canvas/index.js +2 -4
  42. package/lib/canvas/themes/halo/dark/index.js +0 -1
  43. package/lib/canvas/themes/halo/light/index.js +0 -1
  44. package/lib/canvas/themes/solar/charcoal/index.js +0 -1
  45. package/lib/canvas/themes/solar/pearl/index.js +0 -1
  46. package/lib/card/helpers/types.d.ts +2 -2
  47. package/lib/card/index.d.ts +5 -5
  48. package/lib/card/index.js +34 -28
  49. package/lib/card/themes/halo/dark/index.js +0 -1
  50. package/lib/card/themes/halo/light/index.js +0 -1
  51. package/lib/card/themes/solar/charcoal/index.js +0 -1
  52. package/lib/card/themes/solar/pearl/index.js +0 -1
  53. package/lib/chart/helpers/legend.js +10 -8
  54. package/lib/chart/index.d.ts +3 -3
  55. package/lib/chart/index.js +17 -17
  56. package/lib/chart/plugins/doughnut-center-label.js +7 -6
  57. package/lib/chart/themes/halo/dark/index.js +0 -1
  58. package/lib/chart/themes/halo/light/index.js +0 -1
  59. package/lib/chart/themes/solar/charcoal/index.js +0 -1
  60. package/lib/chart/themes/solar/pearl/index.js +0 -1
  61. package/lib/checkbox/index.d.ts +1 -1
  62. package/lib/checkbox/index.js +12 -13
  63. package/lib/checkbox/themes/halo/dark/index.js +0 -1
  64. package/lib/checkbox/themes/halo/light/index.js +0 -1
  65. package/lib/checkbox/themes/solar/charcoal/index.js +0 -1
  66. package/lib/checkbox/themes/solar/pearl/index.js +0 -1
  67. package/lib/clock/index.d.ts +55 -55
  68. package/lib/clock/index.js +84 -95
  69. package/lib/clock/themes/halo/dark/index.js +1 -2
  70. package/lib/clock/themes/halo/light/index.js +1 -2
  71. package/lib/clock/themes/solar/charcoal/index.js +1 -2
  72. package/lib/clock/themes/solar/pearl/index.js +1 -2
  73. package/lib/collapse/index.d.ts +1 -1
  74. package/lib/collapse/index.js +28 -19
  75. package/lib/collapse/themes/halo/dark/index.js +1 -2
  76. package/lib/collapse/themes/halo/light/index.js +1 -2
  77. package/lib/collapse/themes/solar/charcoal/index.js +0 -1
  78. package/lib/collapse/themes/solar/pearl/index.js +0 -1
  79. package/lib/color-dialog/elements/color-palettes.d.ts +1 -1
  80. package/lib/color-dialog/elements/color-palettes.js +5 -6
  81. package/lib/color-dialog/elements/grayscale-palettes.d.ts +1 -1
  82. package/lib/color-dialog/elements/grayscale-palettes.js +9 -9
  83. package/lib/color-dialog/elements/palettes.js +5 -4
  84. package/lib/color-dialog/helpers/value-model.js +7 -9
  85. package/lib/color-dialog/index.d.ts +6 -6
  86. package/lib/color-dialog/index.js +53 -37
  87. package/lib/color-dialog/themes/halo/dark/index.js +0 -1
  88. package/lib/color-dialog/themes/halo/light/index.js +0 -1
  89. package/lib/color-dialog/themes/solar/charcoal/index.js +0 -1
  90. package/lib/color-dialog/themes/solar/pearl/index.js +0 -1
  91. package/lib/color-picker/index.d.ts +2 -2
  92. package/lib/color-picker/index.js +40 -34
  93. package/lib/color-picker/themes/halo/dark/index.js +0 -1
  94. package/lib/color-picker/themes/halo/light/index.js +0 -1
  95. package/lib/color-picker/themes/solar/charcoal/index.js +0 -1
  96. package/lib/color-picker/themes/solar/pearl/index.js +0 -1
  97. package/lib/combo-box/helpers/filter.d.ts +2 -2
  98. package/lib/combo-box/helpers/types.d.ts +1 -1
  99. package/lib/combo-box/index.d.ts +9 -9
  100. package/lib/combo-box/index.js +61 -55
  101. package/lib/combo-box/themes/halo/dark/index.js +0 -1
  102. package/lib/combo-box/themes/halo/light/index.js +0 -1
  103. package/lib/combo-box/themes/solar/charcoal/index.js +0 -1
  104. package/lib/combo-box/themes/solar/pearl/index.js +0 -1
  105. package/lib/configuration/custom-elements.json +15 -0
  106. package/lib/configuration/custom-elements.md +7 -0
  107. package/lib/{config/elements/config.d.ts → configuration/elements/configuration.d.ts} +14 -7
  108. package/lib/{config/elements/config.js → configuration/elements/configuration.js} +17 -15
  109. package/lib/configuration/helpers/context.d.ts +5 -0
  110. package/lib/configuration/helpers/context.js +3 -0
  111. package/lib/{config/helpers/context.d.ts → configuration/helpers/types.d.ts} +0 -3
  112. package/lib/configuration/helpers/types.js +1 -0
  113. package/lib/configuration/index.d.ts +3 -0
  114. package/lib/{config → configuration}/index.js +1 -1
  115. package/lib/counter/index.d.ts +4 -4
  116. package/lib/counter/index.js +9 -7
  117. package/lib/counter/themes/halo/dark/index.js +0 -1
  118. package/lib/counter/themes/halo/light/index.js +0 -1
  119. package/lib/counter/themes/solar/charcoal/index.js +0 -1
  120. package/lib/counter/themes/solar/pearl/index.js +0 -1
  121. package/lib/datetime-field/index.d.ts +4 -5
  122. package/lib/datetime-field/index.js +32 -23
  123. package/lib/datetime-field/themes/halo/dark/index.js +0 -1
  124. package/lib/datetime-field/themes/halo/light/index.js +0 -1
  125. package/lib/datetime-field/themes/solar/charcoal/index.js +0 -1
  126. package/lib/datetime-field/themes/solar/pearl/index.js +0 -1
  127. package/lib/datetime-field/utils.js +11 -1
  128. package/lib/datetime-picker/index.d.ts +75 -75
  129. package/lib/datetime-picker/index.js +154 -135
  130. package/lib/datetime-picker/locales.js +5 -5
  131. package/lib/datetime-picker/themes/halo/dark/index.js +0 -1
  132. package/lib/datetime-picker/themes/halo/light/index.js +0 -1
  133. package/lib/datetime-picker/themes/solar/charcoal/index.js +0 -1
  134. package/lib/datetime-picker/themes/solar/pearl/index.js +0 -1
  135. package/lib/datetime-picker/utils.js +9 -9
  136. package/lib/dialog/custom-elements.json +0 -11
  137. package/lib/dialog/custom-elements.md +3 -4
  138. package/lib/dialog/draggable-element.js +1 -2
  139. package/lib/dialog/index.d.ts +7 -7
  140. package/lib/dialog/index.js +48 -38
  141. package/lib/dialog/themes/halo/dark/index.js +0 -1
  142. package/lib/dialog/themes/halo/light/index.js +0 -1
  143. package/lib/dialog/themes/solar/charcoal/index.js +0 -1
  144. package/lib/dialog/themes/solar/pearl/index.js +0 -1
  145. package/lib/email-field/index.d.ts +1 -1
  146. package/lib/email-field/index.js +6 -6
  147. package/lib/email-field/themes/halo/dark/index.js +0 -1
  148. package/lib/email-field/themes/halo/light/index.js +0 -1
  149. package/lib/email-field/themes/solar/charcoal/index.js +0 -1
  150. package/lib/email-field/themes/solar/pearl/index.js +0 -1
  151. package/lib/events.d.ts +1 -1
  152. package/lib/flag/custom-elements.json +0 -12
  153. package/lib/flag/custom-elements.md +0 -3
  154. package/lib/flag/index.d.ts +12 -8
  155. package/lib/flag/index.js +20 -12
  156. package/lib/flag/themes/halo/dark/index.js +0 -1
  157. package/lib/flag/themes/halo/light/index.js +0 -1
  158. package/lib/flag/themes/solar/charcoal/index.js +0 -1
  159. package/lib/flag/themes/solar/pearl/index.js +0 -1
  160. package/lib/flag/utils/FlagLoader.js +1 -1
  161. package/lib/header/index.d.ts +1 -1
  162. package/lib/header/index.js +2 -2
  163. package/lib/header/themes/halo/dark/index.js +1 -2
  164. package/lib/header/themes/halo/light/index.js +1 -2
  165. package/lib/header/themes/solar/charcoal/index.js +1 -2
  166. package/lib/header/themes/solar/pearl/index.js +1 -2
  167. package/lib/heatmap/helpers/color.d.ts +1 -1
  168. package/lib/heatmap/helpers/color.js +11 -5
  169. package/lib/heatmap/helpers/track.js +3 -3
  170. package/lib/heatmap/helpers/types.d.ts +10 -10
  171. package/lib/heatmap/index.d.ts +9 -9
  172. package/lib/heatmap/index.js +104 -65
  173. package/lib/heatmap/themes/halo/dark/index.js +0 -1
  174. package/lib/heatmap/themes/halo/light/index.js +0 -1
  175. package/lib/heatmap/themes/solar/charcoal/index.js +0 -1
  176. package/lib/heatmap/themes/solar/pearl/index.js +0 -1
  177. package/lib/icon/custom-elements.json +0 -13
  178. package/lib/icon/custom-elements.md +0 -1
  179. package/lib/icon/index.d.ts +16 -6
  180. package/lib/icon/index.js +22 -11
  181. package/lib/icon/themes/halo/dark/index.js +0 -1
  182. package/lib/icon/themes/halo/light/index.js +0 -1
  183. package/lib/icon/themes/solar/charcoal/index.js +0 -1
  184. package/lib/icon/themes/solar/pearl/index.js +0 -1
  185. package/lib/icon/utils/IconLoader.d.ts +1 -0
  186. package/lib/icon/utils/IconLoader.js +9 -1
  187. package/lib/interactive-chart/custom-elements.json +5 -0
  188. package/lib/interactive-chart/custom-elements.md +1 -0
  189. package/lib/interactive-chart/helpers/types.d.ts +3 -3
  190. package/lib/interactive-chart/index.d.ts +40 -36
  191. package/lib/interactive-chart/index.js +78 -59
  192. package/lib/interactive-chart/themes/halo/dark/index.js +0 -1
  193. package/lib/interactive-chart/themes/halo/light/index.js +0 -1
  194. package/lib/interactive-chart/themes/solar/charcoal/index.js +0 -1
  195. package/lib/interactive-chart/themes/solar/pearl/index.js +0 -1
  196. package/lib/item/helpers/types.d.ts +1 -1
  197. package/lib/item/index.d.ts +3 -3
  198. package/lib/item/index.js +24 -20
  199. package/lib/item/themes/halo/dark/index.js +0 -1
  200. package/lib/item/themes/halo/light/index.js +0 -1
  201. package/lib/item/themes/solar/charcoal/index.js +0 -1
  202. package/lib/item/themes/solar/pearl/index.js +0 -1
  203. package/lib/jsx.d.ts +6 -4
  204. package/lib/label/index.d.ts +1 -1
  205. package/lib/label/index.js +11 -8
  206. package/lib/label/themes/halo/dark/index.js +0 -1
  207. package/lib/label/themes/halo/light/index.js +0 -1
  208. package/lib/label/themes/solar/charcoal/index.js +0 -1
  209. package/lib/label/themes/solar/pearl/index.js +0 -1
  210. package/lib/layout/index.d.ts +7 -7
  211. package/lib/layout/index.js +7 -7
  212. package/lib/layout/themes/halo/dark/index.js +0 -1
  213. package/lib/layout/themes/halo/light/index.js +0 -1
  214. package/lib/layout/themes/solar/charcoal/index.js +0 -1
  215. package/lib/layout/themes/solar/pearl/index.js +0 -1
  216. package/lib/led-gauge/index.d.ts +1 -1
  217. package/lib/led-gauge/index.js +10 -10
  218. package/lib/led-gauge/themes/halo/dark/index.js +0 -1
  219. package/lib/led-gauge/themes/halo/light/index.js +0 -1
  220. package/lib/led-gauge/themes/solar/charcoal/index.js +0 -1
  221. package/lib/led-gauge/themes/solar/pearl/index.js +0 -1
  222. package/lib/list/elements/list.d.ts +3 -3
  223. package/lib/list/elements/list.js +10 -12
  224. package/lib/list/helpers/renderer.js +2 -2
  225. package/lib/list/helpers/types.d.ts +1 -1
  226. package/lib/list/index.d.ts +1 -1
  227. package/lib/list/renderer.d.ts +7 -7
  228. package/lib/list/themes/halo/dark/index.js +0 -2
  229. package/lib/list/themes/halo/light/index.js +0 -2
  230. package/lib/list/themes/solar/charcoal/index.js +0 -2
  231. package/lib/list/themes/solar/pearl/index.js +0 -2
  232. package/lib/loader/index.js +7 -8
  233. package/lib/loader/themes/halo/dark/index.js +0 -1
  234. package/lib/loader/themes/halo/light/index.js +0 -1
  235. package/lib/loader/themes/solar/charcoal/index.js +0 -1
  236. package/lib/loader/themes/solar/pearl/index.js +0 -1
  237. package/lib/multi-input/index.d.ts +6 -6
  238. package/lib/multi-input/index.js +39 -45
  239. package/lib/multi-input/themes/halo/dark/index.js +0 -1
  240. package/lib/multi-input/themes/halo/light/index.js +0 -1
  241. package/lib/multi-input/themes/solar/charcoal/index.js +0 -1
  242. package/lib/multi-input/themes/solar/pearl/index.js +0 -1
  243. package/lib/notification/elements/notification-tray.d.ts +2 -2
  244. package/lib/notification/elements/notification-tray.js +3 -3
  245. package/lib/notification/elements/notification.d.ts +2 -2
  246. package/lib/notification/elements/notification.js +17 -14
  247. package/lib/notification/helpers/status.js +1 -1
  248. package/lib/notification/themes/halo/dark/index.js +1 -3
  249. package/lib/notification/themes/halo/light/index.js +1 -3
  250. package/lib/notification/themes/solar/charcoal/index.js +1 -3
  251. package/lib/notification/themes/solar/pearl/index.js +1 -3
  252. package/lib/number-field/index.d.ts +12 -6
  253. package/lib/number-field/index.js +64 -48
  254. package/lib/number-field/themes/halo/dark/index.js +0 -1
  255. package/lib/number-field/themes/halo/light/index.js +0 -1
  256. package/lib/number-field/themes/solar/charcoal/index.js +0 -1
  257. package/lib/number-field/themes/solar/pearl/index.js +0 -1
  258. package/lib/overlay/elements/overlay-viewport.d.ts +1 -1
  259. package/lib/overlay/elements/overlay.d.ts +2 -2
  260. package/lib/overlay/elements/overlay.js +154 -98
  261. package/lib/overlay/helpers/types.d.ts +1 -1
  262. package/lib/overlay/managers/backdrop-manager.d.ts +1 -1
  263. package/lib/overlay/managers/backdrop-manager.js +2 -2
  264. package/lib/overlay/managers/close-manager.js +2 -1
  265. package/lib/overlay/managers/focus-manager.js +23 -13
  266. package/lib/overlay/managers/interaction-lock-manager.d.ts +4 -4
  267. package/lib/overlay/managers/interaction-lock-manager.js +33 -25
  268. package/lib/overlay/managers/viewport-manager.d.ts +2 -2
  269. package/lib/overlay/managers/viewport-manager.js +3 -2
  270. package/lib/overlay/managers/zindex-manager.js +4 -2
  271. package/lib/overlay/themes/halo/dark/index.js +0 -2
  272. package/lib/overlay/themes/halo/light/index.js +0 -2
  273. package/lib/overlay/themes/solar/charcoal/index.js +0 -2
  274. package/lib/overlay/themes/solar/pearl/index.js +0 -2
  275. package/lib/overlay-menu/helpers/types.d.ts +2 -2
  276. package/lib/overlay-menu/index.d.ts +1 -1
  277. package/lib/overlay-menu/index.js +44 -33
  278. package/lib/overlay-menu/managers/menu-manager.d.ts +10 -10
  279. package/lib/overlay-menu/managers/menu-manager.js +15 -13
  280. package/lib/overlay-menu/themes/halo/dark/index.js +0 -1
  281. package/lib/overlay-menu/themes/halo/light/index.js +0 -1
  282. package/lib/overlay-menu/themes/solar/charcoal/index.js +0 -1
  283. package/lib/overlay-menu/themes/solar/pearl/index.js +0 -1
  284. package/lib/pagination/index.d.ts +4 -4
  285. package/lib/pagination/index.js +39 -14
  286. package/lib/pagination/themes/halo/dark/index.js +0 -1
  287. package/lib/pagination/themes/halo/light/index.js +0 -1
  288. package/lib/pagination/themes/solar/charcoal/index.js +0 -1
  289. package/lib/pagination/themes/solar/pearl/index.js +0 -1
  290. package/lib/panel/index.js +1 -1
  291. package/lib/panel/themes/halo/dark/index.js +0 -1
  292. package/lib/panel/themes/halo/light/index.js +0 -1
  293. package/lib/panel/themes/solar/charcoal/index.js +0 -1
  294. package/lib/panel/themes/solar/pearl/index.js +0 -1
  295. package/lib/password-field/index.d.ts +2 -2
  296. package/lib/password-field/index.js +7 -4
  297. package/lib/password-field/themes/halo/dark/index.js +1 -2
  298. package/lib/password-field/themes/halo/light/index.js +1 -2
  299. package/lib/password-field/themes/solar/charcoal/index.js +1 -2
  300. package/lib/password-field/themes/solar/pearl/index.js +1 -2
  301. package/lib/pill/index.d.ts +1 -1
  302. package/lib/pill/index.js +22 -19
  303. package/lib/pill/themes/halo/dark/index.js +0 -1
  304. package/lib/pill/themes/halo/light/index.js +0 -1
  305. package/lib/pill/themes/solar/charcoal/index.js +0 -1
  306. package/lib/pill/themes/solar/pearl/index.js +0 -1
  307. package/lib/progress-bar/index.d.ts +1 -1
  308. package/lib/progress-bar/index.js +38 -37
  309. package/lib/progress-bar/themes/halo/dark/index.js +0 -1
  310. package/lib/progress-bar/themes/halo/light/index.js +0 -1
  311. package/lib/progress-bar/themes/solar/charcoal/index.js +0 -1
  312. package/lib/progress-bar/themes/solar/pearl/index.js +0 -1
  313. package/lib/radio-button/index.d.ts +2 -2
  314. package/lib/radio-button/index.js +17 -12
  315. package/lib/radio-button/radio-button-registry.js +8 -5
  316. package/lib/radio-button/themes/halo/dark/index.js +0 -1
  317. package/lib/radio-button/themes/halo/light/index.js +0 -1
  318. package/lib/radio-button/themes/solar/charcoal/index.js +0 -1
  319. package/lib/radio-button/themes/solar/pearl/index.js +0 -1
  320. package/lib/rating/index.d.ts +1 -1
  321. package/lib/rating/index.js +2 -5
  322. package/lib/rating/themes/halo/dark/index.js +0 -1
  323. package/lib/rating/themes/halo/light/index.js +0 -1
  324. package/lib/rating/themes/solar/charcoal/index.js +0 -1
  325. package/lib/rating/themes/solar/pearl/index.js +0 -1
  326. package/lib/rating/utils.d.ts +6 -6
  327. package/lib/rating/utils.js +6 -6
  328. package/lib/search-field/index.d.ts +2 -2
  329. package/lib/search-field/index.js +4 -4
  330. package/lib/search-field/themes/halo/dark/index.js +0 -1
  331. package/lib/search-field/themes/halo/light/index.js +0 -1
  332. package/lib/search-field/themes/solar/charcoal/index.js +0 -1
  333. package/lib/search-field/themes/solar/pearl/index.js +0 -1
  334. package/lib/select/index.d.ts +34 -34
  335. package/lib/select/index.js +70 -83
  336. package/lib/select/themes/halo/dark/index.js +0 -1
  337. package/lib/select/themes/halo/light/index.js +0 -1
  338. package/lib/select/themes/solar/charcoal/index.js +0 -1
  339. package/lib/select/themes/solar/pearl/index.js +0 -1
  340. package/lib/sidebar-layout/index.d.ts +2 -2
  341. package/lib/sidebar-layout/index.js +7 -9
  342. package/lib/sidebar-layout/themes/halo/dark/index.js +0 -1
  343. package/lib/sidebar-layout/themes/halo/light/index.js +0 -1
  344. package/lib/sidebar-layout/themes/solar/charcoal/index.js +0 -1
  345. package/lib/sidebar-layout/themes/solar/pearl/index.js +0 -1
  346. package/lib/slider/index.d.ts +2 -2
  347. package/lib/slider/index.js +72 -49
  348. package/lib/slider/themes/halo/dark/index.js +0 -1
  349. package/lib/slider/themes/halo/light/index.js +0 -1
  350. package/lib/slider/themes/solar/charcoal/index.js +0 -1
  351. package/lib/slider/themes/solar/pearl/index.js +0 -1
  352. package/lib/slider/utils.d.ts +10 -10
  353. package/lib/slider/utils.js +10 -10
  354. package/lib/sparkline/index.d.ts +1 -1
  355. package/lib/sparkline/index.js +7 -8
  356. package/lib/sparkline/themes/halo/dark/index.js +0 -1
  357. package/lib/sparkline/themes/halo/light/index.js +0 -1
  358. package/lib/sparkline/themes/solar/charcoal/index.js +0 -1
  359. package/lib/sparkline/themes/solar/pearl/index.js +0 -1
  360. package/lib/swing-gauge/helpers.js +2 -2
  361. package/lib/swing-gauge/index.d.ts +19 -19
  362. package/lib/swing-gauge/index.js +91 -81
  363. package/lib/swing-gauge/themes/halo/dark/index.js +0 -1
  364. package/lib/swing-gauge/themes/halo/light/index.js +0 -1
  365. package/lib/swing-gauge/themes/solar/charcoal/index.js +0 -1
  366. package/lib/swing-gauge/themes/solar/pearl/index.js +0 -1
  367. package/lib/tab/index.d.ts +1 -1
  368. package/lib/tab/index.js +16 -27
  369. package/lib/tab/themes/halo/dark/index.js +1 -2
  370. package/lib/tab/themes/halo/light/index.js +1 -2
  371. package/lib/tab/themes/solar/charcoal/index.js +1 -2
  372. package/lib/tab/themes/solar/pearl/index.js +1 -2
  373. package/lib/tab-bar/helpers/animate.js +1 -1
  374. package/lib/tab-bar/index.d.ts +1 -1
  375. package/lib/tab-bar/index.js +34 -18
  376. package/lib/tab-bar/themes/halo/dark/index.js +1 -2
  377. package/lib/tab-bar/themes/halo/light/index.js +1 -2
  378. package/lib/tab-bar/themes/solar/charcoal/index.js +0 -1
  379. package/lib/tab-bar/themes/solar/pearl/index.js +0 -1
  380. package/lib/text-field/index.d.ts +1 -1
  381. package/lib/text-field/index.js +36 -33
  382. package/lib/text-field/themes/halo/dark/index.js +0 -1
  383. package/lib/text-field/themes/halo/light/index.js +0 -1
  384. package/lib/text-field/themes/solar/charcoal/index.js +0 -1
  385. package/lib/text-field/themes/solar/pearl/index.js +0 -1
  386. package/lib/time-picker/index.d.ts +6 -6
  387. package/lib/time-picker/index.js +104 -90
  388. package/lib/time-picker/themes/halo/dark/index.js +0 -1
  389. package/lib/time-picker/themes/halo/light/index.js +0 -1
  390. package/lib/time-picker/themes/solar/charcoal/index.js +0 -1
  391. package/lib/time-picker/themes/solar/pearl/index.js +0 -1
  392. package/lib/toggle/index.d.ts +1 -1
  393. package/lib/toggle/index.js +4 -3
  394. package/lib/toggle/themes/halo/dark/index.js +1 -2
  395. package/lib/toggle/themes/halo/light/index.js +1 -2
  396. package/lib/toggle/themes/solar/charcoal/index.js +1 -2
  397. package/lib/toggle/themes/solar/pearl/index.js +1 -2
  398. package/lib/tooltip/elements/title-tooltip.js +2 -2
  399. package/lib/tooltip/helpers/renderer.d.ts +1 -1
  400. package/lib/tooltip/helpers/renderer.js +3 -3
  401. package/lib/tooltip/index.d.ts +27 -27
  402. package/lib/tooltip/index.js +42 -38
  403. package/lib/tooltip/managers/tooltip-manager.d.ts +1 -1
  404. package/lib/tooltip/themes/halo/dark/index.js +0 -1
  405. package/lib/tooltip/themes/halo/light/index.js +0 -1
  406. package/lib/tooltip/themes/solar/charcoal/index.js +0 -1
  407. package/lib/tooltip/themes/solar/pearl/index.js +0 -1
  408. package/lib/tornado-chart/elements/tornado-chart.d.ts +1 -1
  409. package/lib/tornado-chart/elements/tornado-chart.js +1 -1
  410. package/lib/tornado-chart/elements/tornado-item.d.ts +2 -2
  411. package/lib/tornado-chart/elements/tornado-item.js +12 -10
  412. package/lib/tornado-chart/themes/halo/dark/index.js +0 -2
  413. package/lib/tornado-chart/themes/halo/light/index.js +0 -2
  414. package/lib/tornado-chart/themes/solar/charcoal/index.js +0 -2
  415. package/lib/tornado-chart/themes/solar/pearl/index.js +0 -2
  416. package/lib/tree/elements/tree-item.d.ts +3 -3
  417. package/lib/tree/elements/tree-item.js +21 -19
  418. package/lib/tree/elements/tree.d.ts +1 -1
  419. package/lib/tree/elements/tree.js +12 -11
  420. package/lib/tree/helpers/renderer.js +4 -3
  421. package/lib/tree/index.d.ts +1 -1
  422. package/lib/tree/managers/tree-manager.d.ts +1 -1
  423. package/lib/tree/managers/tree-manager.js +17 -18
  424. package/lib/tree/themes/halo/dark/index.js +0 -2
  425. package/lib/tree/themes/halo/light/index.js +0 -2
  426. package/lib/tree/themes/solar/charcoal/index.js +1 -3
  427. package/lib/tree/themes/solar/pearl/index.js +1 -3
  428. package/lib/tree-select/index.d.ts +9 -9
  429. package/lib/tree-select/index.js +91 -82
  430. package/lib/tree-select/themes/halo/dark/index.js +1 -2
  431. package/lib/tree-select/themes/halo/light/index.js +1 -2
  432. package/lib/tree-select/themes/solar/charcoal/index.js +1 -2
  433. package/lib/tree-select/themes/solar/pearl/index.js +1 -2
  434. package/lib/version.js +1 -1
  435. package/package.json +19 -18
  436. package/tsconfig.tsbuildinfo +1 -0
  437. package/lib/config/custom-elements.json +0 -23
  438. package/lib/config/custom-elements.md +0 -8
  439. package/lib/config/helpers/context.js +0 -2
  440. package/lib/config/index.d.ts +0 -2
@@ -1,21 +1,21 @@
1
1
  import { __decorate } from "tslib";
2
- import { ControlElement, html, css, nothing, WarningNotice } from '@refinitiv-ui/core';
2
+ import { ControlElement, WarningNotice, 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 { state } from '@refinitiv-ui/core/decorators/state.js';
6
6
  import { cache } from '@refinitiv-ui/core/directives/cache.js';
7
7
  import { guard } from '@refinitiv-ui/core/directives/guard.js';
8
- import { ref, createRef } from '@refinitiv-ui/core/directives/ref.js';
9
- import { VERSION } from '../version.js';
8
+ import { createRef, ref } from '@refinitiv-ui/core/directives/ref.js';
9
+ import '@refinitiv-ui/phrasebook/locale/en/calendar.js';
10
+ import { TranslatePropertyKey, getLocale, translate } from '@refinitiv-ui/translate';
10
11
  import { isIE } from '@refinitiv-ui/utils/browser.js';
11
- import { DateFormat, format, utcFormat, utcParse, isValidDate, isWeekend, isAfter, isBefore, addMonths, subMonths, isToday, isThisMonth, isThisYear, isSameDay, isSameMonth, isSameYear, toDateSegment, parse } from '@refinitiv-ui/utils/date.js';
12
- import { left, right, up, down, first, last } from '@refinitiv-ui/utils/navigation.js';
13
- import { monthInfo, weekdaysNames, monthsNames, formatLocaleDate, ViewFormatTranslateParams } from './utils.js';
14
- import { translate, getLocale, TranslatePropertyKey } from '@refinitiv-ui/translate';
15
- import { RenderView, CalendarLocaleScope, FIRST_DAY_OF_WEEK, YEARS_PER_YEAR_VIEW, DAY_VIEW, YEAR_VIEW, MONTH_VIEW } from './constants.js';
16
- import './locales.js';
12
+ import { DateFormat, addMonths, format, isAfter, isBefore, isSameDay, isSameMonth, isSameYear, isThisMonth, isThisYear, isToday, isValidDate, isWeekend, parse, subMonths, toDateSegment, utcFormat, utcParse } from '@refinitiv-ui/utils/date.js';
13
+ import { down, first, last, left, right, up } from '@refinitiv-ui/utils/navigation.js';
17
14
  import '../button/index.js';
18
- import '@refinitiv-ui/phrasebook/locale/en/calendar.js';
15
+ import { VERSION } from '../version.js';
16
+ import { CalendarLocaleScope, DAY_VIEW, FIRST_DAY_OF_WEEK, MONTH_VIEW, RenderView, YEARS_PER_YEAR_VIEW, YEAR_VIEW } from './constants.js';
17
+ import './locales.js';
18
+ import { ViewFormatTranslateParams, formatLocaleDate, monthInfo, monthsNames, weekdaysNames } from './utils.js';
19
19
  /**
20
20
  * Standard calendar element
21
21
  *
@@ -41,28 +41,28 @@ let Calendar = class Calendar extends ControlElement {
41
41
  this._min = '';
42
42
  this._max = '';
43
43
  /**
44
- * Only enable weekdays
45
- */
44
+ * Only enable weekdays
45
+ */
46
46
  this.weekdaysOnly = false;
47
47
  /**
48
- * Only enable weekends
49
- */
48
+ * Only enable weekends
49
+ */
50
50
  this.weekendsOnly = false;
51
51
  /**
52
- * Custom filter, used for enabling/disabling certain dates
53
- * @type {CalendarFilter | null}
54
- */
52
+ * Custom filter, used for enabling/disabling certain dates
53
+ * @type {CalendarFilter | null}
54
+ */
55
55
  this.filter = null;
56
56
  this._view = '';
57
57
  this.localFirstDayOfWeek = FIRST_DAY_OF_WEEK; // used from locales. 0 stands for Sunday
58
58
  this._firstDayOfWeek = null; // used from setter
59
59
  /**
60
- * Set to switch to range select mode
61
- */
60
+ * Set to switch to range select mode
61
+ */
62
62
  this.range = false;
63
63
  /**
64
- * Set to switch to multiple select mode
65
- */
64
+ * Set to switch to multiple select mode
65
+ */
66
66
  this.multiple = false;
67
67
  this._values = [];
68
68
  /**
@@ -105,19 +105,20 @@ let Calendar = class Calendar extends ControlElement {
105
105
  :host {
106
106
  display: inline-block;
107
107
  }
108
- [part~=navigation], [part~=navigation] section {
108
+ [part~='navigation'],
109
+ [part~='navigation'] section {
109
110
  display: flex;
110
111
  flex-flow: row nowrap;
111
112
  }
112
- [part~=navigation] {
113
+ [part~='navigation'] {
113
114
  justify-content: space-between;
114
115
  }
115
- [part~=navigation] > div {
116
+ [part~='navigation'] > div {
116
117
  display: flex;
117
118
  flex: 1;
118
119
  justify-content: center;
119
120
  }
120
- [part~=cell-content] {
121
+ [part~='cell-content'] {
121
122
  position: absolute;
122
123
  top: 0;
123
124
  bottom: 0;
@@ -127,44 +128,45 @@ let Calendar = class Calendar extends ControlElement {
127
128
  align-items: center;
128
129
  justify-content: center;
129
130
  }
130
- [part=navigation] [part] {
131
+ [part='navigation'] [part] {
131
132
  flex: none;
132
133
  }
133
- [part=table] {
134
+ [part='table'] {
134
135
  width: 100%;
135
136
  }
136
- [part~=row] {
137
+ [part~='row'] {
137
138
  display: flex;
138
139
  width: 100%;
139
140
  }
140
- [part~=cell] {
141
+ [part~='cell'] {
141
142
  position: relative;
142
143
  }
143
- [part~=cell][part~=year] {
144
+ [part~='cell'][part~='year'] {
144
145
  width: calc(100% / ${YEAR_VIEW.columnCount});
145
146
  padding-top: calc(100% / ${YEAR_VIEW.columnCount});
146
147
  }
147
- [part~=cell][part~=month] {
148
+ [part~='cell'][part~='month'] {
148
149
  width: calc(100% / ${MONTH_VIEW.columnCount});
149
150
  padding-top: calc(100% / ${MONTH_VIEW.columnCount});
150
151
  }
151
- [part~=cell][part~=day], [part~=cell][part~=day-name] {
152
+ [part~='cell'][part~='day'],
153
+ [part~='cell'][part~='day-name'] {
152
154
  width: calc(100% / ${DAY_VIEW.columnCount});
153
155
  padding-top: calc(100% / ${DAY_VIEW.columnCount});
154
156
  }
155
- [part~=cell-content]:not([tabindex]) {
157
+ [part~='cell-content']:not([tabindex]) {
156
158
  pointer-events: none;
157
159
  }
158
- [part~=selectable] {
160
+ [part~='selectable'] {
159
161
  cursor: pointer;
160
162
  }
161
163
  `;
162
164
  }
163
165
  /**
164
- * Set minimum date
165
- * @param min min date
166
- * @default -
167
- */
166
+ * Set minimum date
167
+ * @param min min date
168
+ * @default -
169
+ */
168
170
  set min(min) {
169
171
  const oldMin = this._min;
170
172
  if (!this.isValidValue(min)) {
@@ -180,10 +182,10 @@ let Calendar = class Calendar extends ControlElement {
180
182
  return this._min;
181
183
  }
182
184
  /**
183
- * Set maximum date
184
- * @param max max date
185
- * @default -
186
- */
185
+ * Set maximum date
186
+ * @param max max date
187
+ * @default -
188
+ */
187
189
  set max(max) {
188
190
  const oldMax = this._max;
189
191
  if (!this.isValidValue(max)) {
@@ -199,10 +201,10 @@ let Calendar = class Calendar extends ControlElement {
199
201
  return this._max;
200
202
  }
201
203
  /**
202
- * Current calendar view date
203
- * @param view view date
204
- * @default -
205
- */
204
+ * Current calendar view date
205
+ * @param view view date
206
+ * @default -
207
+ */
206
208
  set view(view) {
207
209
  if (view && !isValidDate(view, DateFormat.yyyyMM)) {
208
210
  this.warnInvalidView(view);
@@ -217,7 +219,10 @@ let Calendar = class Calendar extends ControlElement {
217
219
  }
218
220
  get view() {
219
221
  /* as soon as user interaction has happened, always rely on view */
220
- return this._view || (this.value ? utcFormat(toDateSegment(this.value), DateFormat.yyyyMM) : format(new Date(), DateFormat.yyyyMM));
222
+ return (this._view ||
223
+ (this.value
224
+ ? utcFormat(toDateSegment(this.value), DateFormat.yyyyMM)
225
+ : format(new Date(), DateFormat.yyyyMM)));
221
226
  }
222
227
  /**
223
228
  * Set the first day of the week.
@@ -238,10 +243,10 @@ let Calendar = class Calendar extends ControlElement {
238
243
  return this._firstDayOfWeek === null ? this.localFirstDayOfWeek : this._firstDayOfWeek;
239
244
  }
240
245
  /**
241
- * Current date time value
242
- * @param value Calendar value
243
- * @default -
244
- */
246
+ * Current date time value
247
+ * @param value Calendar value
248
+ * @default -
249
+ */
245
250
  set value(value) {
246
251
  this.values = [value];
247
252
  }
@@ -341,7 +346,7 @@ let Calendar = class Calendar extends ControlElement {
341
346
  */
342
347
  async performUpdate() {
343
348
  const localFirstDayOfWeek = Number(await this.dateTPromise('FIRST_DAY_OF_WEEK'));
344
- this.localFirstDayOfWeek = isNaN(localFirstDayOfWeek) ? FIRST_DAY_OF_WEEK : (localFirstDayOfWeek % 7);
349
+ this.localFirstDayOfWeek = isNaN(localFirstDayOfWeek) ? FIRST_DAY_OF_WEEK : localFirstDayOfWeek % 7;
345
350
  void super.performUpdate();
346
351
  }
347
352
  /**
@@ -354,15 +359,18 @@ let Calendar = class Calendar extends ControlElement {
354
359
  super.willUpdate(changedProperties);
355
360
  // This code is here to ensure that focus is not lost
356
361
  // while navigating through the render views using keyboard
357
- if (this.focused && changedProperties.has('renderView') && this.viewBtnRef.value && this.activeElement !== this.viewBtnRef.value) {
362
+ if (this.focused &&
363
+ changedProperties.has('renderView') &&
364
+ this.viewBtnRef.value &&
365
+ this.activeElement !== this.viewBtnRef.value) {
358
366
  this.viewBtnRef.value.focus();
359
367
  }
360
368
  }
361
369
  /**
362
- * Updates the element
363
- * @param changedProperties Properties that has changed
364
- * @returns {void}
365
- */
370
+ * Updates the element
371
+ * @param changedProperties Properties that has changed
372
+ * @returns {void}
373
+ */
366
374
  update(changedProperties) {
367
375
  if (!this.localMonthsNames || changedProperties.has(TranslatePropertyKey)) {
368
376
  const locale = getLocale(this);
@@ -400,7 +408,7 @@ let Calendar = class Calendar extends ControlElement {
400
408
  */
401
409
  firstUpdated(changedProperties) {
402
410
  super.firstUpdated(changedProperties);
403
- this.renderRoot.addEventListener('keydown', event => this.onKeyDown(event));
411
+ this.renderRoot.addEventListener('keydown', (event) => this.onKeyDown(event));
404
412
  }
405
413
  /**
406
414
  * Show invalid view message
@@ -419,10 +427,10 @@ let Calendar = class Calendar extends ControlElement {
419
427
  new WarningNotice(`The specified value "${value}" does not conform to the required format. The format is "yyyy-MM-dd".`).once();
420
428
  }
421
429
  /**
422
- * Validate that the value confirms the control type
423
- * @param value Value to check
424
- * @returns false if value is invalid
425
- */
430
+ * Validate that the value confirms the control type
431
+ * @param value Value to check
432
+ * @returns false if value is invalid
433
+ */
426
434
  isValidValue(value) {
427
435
  return value === '' || isValidDate(value);
428
436
  }
@@ -434,7 +442,7 @@ let Calendar = class Calendar extends ControlElement {
434
442
  */
435
443
  filterAndWarnInvalidValues(values) {
436
444
  const filtered = [];
437
- values.forEach(value => {
445
+ values.forEach((value) => {
438
446
  if (this.isValidValue(value)) {
439
447
  value && filtered.push(value);
440
448
  }
@@ -450,11 +458,11 @@ let Calendar = class Calendar extends ControlElement {
450
458
  * @returns true if filter needs to be constructed
451
459
  */
452
460
  shouldConstructFilters(changedProperties) {
453
- return changedProperties.has('min')
454
- || changedProperties.has('max')
455
- || changedProperties.has('weekdaysOnly')
456
- || changedProperties.has('weekendsOnly')
457
- || changedProperties.has('filter');
461
+ return (changedProperties.has('min') ||
462
+ changedProperties.has('max') ||
463
+ changedProperties.has('weekdaysOnly') ||
464
+ changedProperties.has('weekendsOnly') ||
465
+ changedProperties.has('filter'));
458
466
  }
459
467
  /**
460
468
  * Construct and store a collection of filters
@@ -463,13 +471,13 @@ let Calendar = class Calendar extends ControlElement {
463
471
  */
464
472
  constructFilters() {
465
473
  const filters = [];
466
- this.min && filters.push(date => isSameDay(date, this.min) || isAfter(date, this.min));
467
- this.max && filters.push(date => isSameDay(date, this.max) || isBefore(date, this.max));
474
+ this.min && filters.push((date) => isSameDay(date, this.min) || isAfter(date, this.min));
475
+ this.max && filters.push((date) => isSameDay(date, this.max) || isBefore(date, this.max));
468
476
  if (this.weekdaysOnly) {
469
- filters.push(date => !isWeekend(date));
477
+ filters.push((date) => !isWeekend(date));
470
478
  }
471
479
  if (this.weekendsOnly) {
472
- filters.push(date => isWeekend(date));
480
+ filters.push((date) => isWeekend(date));
473
481
  }
474
482
  if (this.filter) {
475
483
  filters.push(this.filter);
@@ -538,7 +546,7 @@ let Calendar = class Calendar extends ControlElement {
538
546
  * @returns {void}
539
547
  */
540
548
  setNavigationMap(rows) {
541
- this.navigationGrid = rows.map(row => row.map(cell => cell.value && !cell.disabled ? 1 : 0));
549
+ this.navigationGrid = rows.map((row) => row.map((cell) => (cell.value && !cell.disabled ? 1 : 0)));
542
550
  }
543
551
  /**
544
552
  * Run when next button is tapped.
@@ -632,14 +640,16 @@ let Calendar = class Calendar extends ControlElement {
632
640
  this.activeCellIndex = cell.index;
633
641
  const cellSegment = toDateSegment(cell.value);
634
642
  const viewSegment = toDateSegment(this.view);
635
- if (this.renderView === RenderView.YEAR) { /* YEAR -> MONTH */
643
+ if (this.renderView === RenderView.YEAR) {
644
+ /* YEAR -> MONTH */
636
645
  viewSegment.year = cellSegment.year;
637
646
  if (this.notifyViewChange(viewSegment)) {
638
647
  this.renderView = RenderView.MONTH;
639
648
  }
640
649
  return;
641
650
  }
642
- if (this.renderView === RenderView.MONTH) { /* MONTH -> DAY */
651
+ if (this.renderView === RenderView.MONTH) {
652
+ /* MONTH -> DAY */
643
653
  viewSegment.year = cellSegment.year;
644
654
  viewSegment.month = cellSegment.month;
645
655
  if (this.notifyViewChange(viewSegment)) {
@@ -785,7 +795,8 @@ let Calendar = class Calendar extends ControlElement {
785
795
  if (!this.values.length) {
786
796
  values = [value];
787
797
  }
788
- else if (this.values.length === 1) { /* from is populated */
798
+ else if (this.values.length === 1) {
799
+ /* from is populated */
789
800
  const from = this.values[0];
790
801
  const to = value;
791
802
  if (isAfter(to, from) || isSameDay(to, from)) {
@@ -795,16 +806,12 @@ let Calendar = class Calendar extends ControlElement {
795
806
  values = [value];
796
807
  }
797
808
  }
798
- else if (this.values.indexOf(value) === -1) {
799
- values = [value];
800
- }
801
809
  else {
802
- // remove range if start/end index match
803
- values = [];
810
+ values = [value];
804
811
  }
805
812
  }
806
813
  else {
807
- values = this.value === value ? [] : [value];
814
+ values = [value];
808
815
  }
809
816
  this.notifyValuesChange(values);
810
817
  }
@@ -864,7 +871,9 @@ let Calendar = class Calendar extends ControlElement {
864
871
  const day = segment.day;
865
872
  const fromYear = Math.floor(segment.year / YEARS_PER_YEAR_VIEW) * YEARS_PER_YEAR_VIEW;
866
873
  const toYear = fromYear + YEARS_PER_YEAR_VIEW - 1;
867
- return html `${this.viewFormattedDate({ year: fromYear, month, day })} - ${this.viewFormattedDate({ year: toYear, month, day })}`;
874
+ const fromView = this.viewFormattedDate({ year: fromYear, month, day });
875
+ const toView = this.viewFormattedDate({ year: toYear, month, day });
876
+ return html `${fromView} - ${toView}`;
868
877
  case RenderView.DAY:
869
878
  default:
870
879
  return this.viewFormattedDate(segment, true);
@@ -961,7 +970,7 @@ let Calendar = class Calendar extends ControlElement {
961
970
  const totalCount = MONTH_VIEW.totalCount;
962
971
  const monthsNames = this.localMonthsNames;
963
972
  const before = (totalCount - monthCount) / 2;
964
- const startIdx = monthCount - before % monthCount;
973
+ const startIdx = monthCount - (before % monthCount);
965
974
  const after = before + monthCount;
966
975
  const months = [];
967
976
  const rows = [];
@@ -1067,8 +1076,7 @@ let Calendar = class Calendar extends ControlElement {
1067
1076
  this.setActiveCell(rows);
1068
1077
  this.setNavigationMap(rows);
1069
1078
  return html `
1070
- ${guard([this.firstDayOfWeek, this.lang], () => this.renderWeekdayNames)}
1071
- ${this.renderRows(rows)}
1079
+ ${guard([this.firstDayOfWeek, this.lang], () => this.renderWeekdayNames)} ${this.renderRows(rows)}
1072
1080
  `;
1073
1081
  }
1074
1082
  /**
@@ -1076,14 +1084,16 @@ let Calendar = class Calendar extends ControlElement {
1076
1084
  */
1077
1085
  get renderWeekdayNames() {
1078
1086
  const firstDayOfWeek = this.firstDayOfWeek;
1079
- const weekdaysNames = this.localWeekdaysNames.slice(firstDayOfWeek).concat(this.localWeekdaysNames.slice(0, firstDayOfWeek));
1080
- return html `
1081
- <div role="row"
1082
- part="row day-name-row">${weekdaysNames.map(day => html `
1083
- <div scope="col" role="columnheader" part="cell day-name" abbr="${day.long}">
1084
- <div part="cell-content">${day.narrow}</div>
1085
- </div>
1086
- `)}</div>`;
1087
+ const weekdaysNames = this.localWeekdaysNames
1088
+ .slice(firstDayOfWeek)
1089
+ .concat(this.localWeekdaysNames.slice(0, firstDayOfWeek));
1090
+ return html ` <div role="row" part="row day-name-row">
1091
+ ${weekdaysNames.map((day) => html `
1092
+ <div scope="col" role="columnheader" part="cell day-name" abbr="${day.long}">
1093
+ <div part="cell-content">${day.narrow}</div>
1094
+ </div>
1095
+ `)}
1096
+ </div>`;
1087
1097
  }
1088
1098
  /**
1089
1099
  * Render a view based on the current render view
@@ -1128,10 +1138,12 @@ let Calendar = class Calendar extends ControlElement {
1128
1138
  renderCell(cell) {
1129
1139
  const isSelection = cell.value !== undefined;
1130
1140
  const isSelectable = isSelection && !cell.disabled;
1141
+ const isSelected = cell.selected ? 'true' : 'false';
1142
+ const isActive = cell.active ? 0 : -1;
1131
1143
  return html `<div
1132
1144
  role="gridcell"
1133
1145
  part="cell ${cell.view}"
1134
- aria-selected="${isSelectable ? (cell.selected ? 'true' : 'false') : nothing}"
1146
+ aria-selected="${isSelectable ? isSelected : nothing}"
1135
1147
  ?active=${cell.active}
1136
1148
  ?disabled=${cell.disabled}
1137
1149
  ?idle=${cell.idle}
@@ -1141,17 +1153,25 @@ let Calendar = class Calendar extends ControlElement {
1141
1153
  ?selected=${cell.selected}
1142
1154
  ?range=${cell.range}
1143
1155
  ?range-from=${cell.rangeFrom}
1144
- ?range-to=${cell.rangeTo}>
1145
- <div role="${cell.value ? 'button' : nothing}"
1146
- tabindex=${isSelectable ? (cell.active ? 0 : -1) : nothing}
1147
- aria-label="${isSelectable && !isIE ? this.t(this.getCellLabelKey(cell), {
1148
- // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
1149
- value: parse(cell.value),
1150
- view: this.renderView
1151
- }) : nothing}"
1152
- part="cell-content${isSelection ? ' selection' : ''}${isSelectable ? ' selectable' : ''}"
1153
- .value=${cell.value}
1154
- .index=${cell.index}>${cell.text}</div>
1156
+ ?range-to=${cell.rangeTo}
1157
+ >
1158
+ <div
1159
+ role="${cell.value ? 'button' : nothing}"
1160
+ tabindex=${isSelectable ? isActive : nothing}
1161
+ aria-label="${isSelectable && !isIE
1162
+ ? this.t(this.getCellLabelKey(cell), {
1163
+ /* IE11 has significant performance hit, disable */
1164
+ // eslint-disable-next-line @typescript-eslint/no-non-null-assertion
1165
+ value: parse(cell.value),
1166
+ view: this.renderView
1167
+ })
1168
+ : nothing}"
1169
+ part="cell-content${isSelection ? ' selection' : ''}${isSelectable ? ' selectable' : ''}"
1170
+ .value=${cell.value}
1171
+ .index=${cell.index}
1172
+ >
1173
+ ${cell.text}
1174
+ </div>
1155
1175
  </div>`;
1156
1176
  }
1157
1177
  /**
@@ -1160,7 +1180,7 @@ let Calendar = class Calendar extends ControlElement {
1160
1180
  * @returns template result
1161
1181
  */
1162
1182
  renderRows(rows) {
1163
- return rows.map(row => html `<div role="row" part="row">${row.map(cell => this.renderCell(cell))}</div>`);
1183
+ return rows.map((row) => html `<div role="row" part="row">${row.map((cell) => this.renderCell(cell))}</div>`);
1164
1184
  }
1165
1185
  /**
1166
1186
  * Render button navigation template
@@ -1185,31 +1205,36 @@ let Calendar = class Calendar extends ControlElement {
1185
1205
  // no default
1186
1206
  }
1187
1207
  return html `<div part="navigation">
1188
- <ef-button
1189
- part="btn-prev"
1190
- aria-label="${prevBtnAriaLabel}"
1191
- icon="left"
1192
- @tap=${this.onPreviousTap}></ef-button>
1193
- <ef-button
1194
- ${ref(this.viewBtnRef)}
1195
- aria-description="${viewBtnAriaLabel}"
1196
- part="btn-view"
1197
- textpos="before"
1198
- .icon="${this.renderView === RenderView.DAY ? 'down' : 'up'}"
1199
- @tap="${this.onRenderViewTap}">${this.formattedViewRender}</ef-button>
1200
- <ef-button
1201
- part="btn-next"
1202
- aria-label="${nextBtnAriaLabel}"
1203
- icon="right"
1204
- @tap=${this.onNextTap}></ef-button>
1205
- </div>`;
1208
+ <ef-button
1209
+ part="btn-prev"
1210
+ aria-label="${prevBtnAriaLabel}"
1211
+ icon="left"
1212
+ @tap=${this.onPreviousTap}
1213
+ ></ef-button>
1214
+ <ef-button
1215
+ ${ref(this.viewBtnRef)}
1216
+ aria-description="${viewBtnAriaLabel}"
1217
+ part="btn-view"
1218
+ textpos="before"
1219
+ .icon="${this.renderView === RenderView.DAY ? 'down' : 'up'}"
1220
+ @tap="${this.onRenderViewTap}"
1221
+ >${this.formattedViewRender}</ef-button
1222
+ >
1223
+ <ef-button
1224
+ part="btn-next"
1225
+ aria-label="${nextBtnAriaLabel}"
1226
+ icon="right"
1227
+ @tap=${this.onNextTap}
1228
+ ></ef-button>
1229
+ </div>`;
1206
1230
  }
1207
1231
  /**
1208
1232
  * A template used to notify currently selected value for screen readers
1209
1233
  * @returns template result
1210
1234
  */
1211
1235
  get selectionTemplate() {
1212
- if (isIE || !this.announceValues) { /* IE11 has significant performance complications */
1236
+ if (isIE || !this.announceValues) {
1237
+ /* IE11 has significant performance complications */
1213
1238
  return;
1214
1239
  }
1215
1240
  return html `<div
@@ -1218,9 +1243,13 @@ let Calendar = class Calendar extends ControlElement {
1218
1243
  aria-live="polite"
1219
1244
  aria-label="${this.value
1220
1245
  ? this.range
1221
- ? this.t('SELECTED_RANGE', { from: parse(this.values[0]), to: this.values[1] ? parse(this.values[1]) : null })
1246
+ ? this.t('SELECTED_RANGE', {
1247
+ from: parse(this.values[0]),
1248
+ to: this.values[1] ? parse(this.values[1]) : null
1249
+ })
1222
1250
  : this.t('SELECTED_DATE', { value: parse(this.value), count: this.values.length })
1223
- : this.t('SELECTED_NONE', { multiple: this.multiple, range: this.range })}"></div>`;
1251
+ : this.t('SELECTED_NONE', { multiple: this.multiple, range: this.range })}"
1252
+ ></div>`;
1224
1253
  }
1225
1254
  /**
1226
1255
  * A `TemplateResult` that will be used
@@ -1231,10 +1260,14 @@ let Calendar = class Calendar extends ControlElement {
1231
1260
  return html `
1232
1261
  ${guard([this.values, this.lang, this.range, this.multiple, this.announceValues], () => this.selectionTemplate)}
1233
1262
  ${guard([this.view, this.renderView, this.lang], () => this.buttonNavigationTemplate)}
1234
- <div role="grid"
1235
- aria-multiselectable="${this.range || this.multiple}"
1236
- part="table"
1237
- @tap=${this.onTableTap}>${this.viewRender}</div>
1263
+ <div
1264
+ role="grid"
1265
+ aria-multiselectable="${this.range || this.multiple}"
1266
+ part="table"
1267
+ @tap=${this.onTableTap}
1268
+ >
1269
+ ${this.viewRender}
1270
+ </div>
1238
1271
  <div part="footer"><slot name="footer"></slot></div>
1239
1272
  `;
1240
1273
  }
@@ -1,3 +1,2 @@
1
1
  import '@refinitiv-ui/elements/button/themes/halo/dark';
2
-
3
2
  dispatchEvent(new CustomEvent('ef.customStyles.define', { detail: { name: 'ef-calendar', styles: ':host{font-style:normal;font-variant:normal;font-weight:400;line-height:normal;text-align:left;text-indent:0;text-shadow:none;text-transform:none;white-space:normal;word-break:normal;word-spacing:normal;word-wrap:normal;outline:0;font-size:12px;color:#ccc;min-width:196px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background:#262626;padding:4px 3px}:host [part=navigation]{padding-bottom:3px}:host [part=btn-next],:host [part=btn-prev],:host [part=btn-view]{margin:0}:host [part=btn-view]{background:0 0;margin-left:16px;border:none;color:inherit;padding:0}:host [part=btn-view]:hover,:host [part=btn-view][focused=visible]{opacity:.8}:host [part=table]{width:100%;background:#262626}:host [part~=row]:not(:first-of-type) [part~=cell] [part~=cell-content]{top:1px}:host [part~=day-name-row]{background-color:#333}:host [part~=cell][disabled]{opacity:.4}:host [part~=cell][today]{color:#fff}:host [part~=cell][today] [part~=selection]{background:#404040}:host [part~=cell]:not([selected]):not([range]):not([disabled])[idle] [part~=selection]{opacity:.6}:host [part~=cell]:not([today]):not([range]) [part~=selection]:hover{color:#fff}:host [part~=cell]:not(:active) [part~=selection]:hover{border-color:#1429bd}:host [part~=cell]:not([today]):not([range]):not(:active) [part~=selection]:hover,:host [part~=cell][today][selected] [part~=selection]:hover{background:#1429bd}:host [part~=cell]:not([selected]):not([range]):not([today]) [part~=selection]:hover{background:#1429bd}:host [part~=cell]:not([selected]):not([range]):not([today]):not(:active) [part~=selection]:hover{border-color:#1429bd}:host [part~=cell]:not([selected]):not([range]):not([today]):not([disabled]):active [part~=selection]{color:#fff;background-color:#0f1e8a}:host [part~=cell][range]:not(:active) [part~=selection]:hover,:host [part~=cell][selected]:not(:active) [part~=selection]:hover,:host [part~=cell][today]:not(:active) [part~=selection]:hover{border-color:#1429bd}:host [part~=cell][range]:not([disabled]):active [part~=selection],:host [part~=cell][selected]:not([disabled]):active [part~=selection],:host [part~=cell][today]:not([disabled]):active [part~=selection]{color:#fff;background-color:#0f1e8a}:host [part~=cell][range] [part~=selection]{background:rgba(51,75,255,.2)}:host [part~=cell][range][today]{color:#fff}:host [part~=cell][selected]{color:#fff}:host [part~=cell][selected] [part~=selection]{background:#334bff}:host [part~=cell]:not(:first-of-type) [part~=cell-content]{left:1px}:host [part~=day-name]{color:#999;font-weight:600}:host [part~=day-name] [part~=cell-content]{background-color:#1a1a1a}:host [part~=cell-content]{background:#0d0d0d;top:0;bottom:0;right:0;left:0}:host [part~=selection]{outline:0;border:1px solid #0d0d0d}:host([focused=visible]) [part~=cell] [part~=selection]:focus{outline:#1429bd solid 1px}:host([disabled]){opacity:.4}' }}));
@@ -1,3 +1,2 @@
1
1
  import '@refinitiv-ui/elements/button/themes/halo/light';
2
-
3
2
  dispatchEvent(new CustomEvent('ef.customStyles.define', { detail: { name: 'ef-calendar', styles: ':host{font-style:normal;font-variant:normal;font-weight:400;line-height:normal;text-align:left;text-indent:0;text-shadow:none;text-transform:none;white-space:normal;word-break:normal;word-spacing:normal;word-wrap:normal;outline:0;font-size:12px;color:#0d0d0d;min-width:196px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background:#f2f2f2;padding:4px 3px}:host [part=navigation]{padding-bottom:3px}:host [part=btn-next],:host [part=btn-prev],:host [part=btn-view]{margin:0}:host [part=btn-next]:not(:hover):not(:focus):not(:active),:host [part=btn-prev]:not(:hover):not(:focus):not(:active){color:#595959}:host [part=btn-view]{background:0 0;margin-left:16px;border:none;color:inherit;padding:0}:host [part=btn-view]:hover,:host [part=btn-view][focused=visible]{opacity:.8}:host [part=table]{width:100%;background:#e6e6e6}:host [part~=row]:not(:first-of-type) [part~=cell] [part~=cell-content]{top:1px}:host [part~=day-name-row]{background-color:#e6e6e6}:host [part~=cell][disabled]{opacity:.4}:host [part~=cell][today]{color:#0d0d0d}:host [part~=cell][today] [part~=selection]{background:#d9d9d9}:host [part~=cell]:not([selected]):not([range]):not([disabled])[idle] [part~=selection]{opacity:.6}:host [part~=cell]:not([today]):not([range]) [part~=selection]:hover{color:#fff}:host [part~=cell]:not(:active) [part~=selection]:hover{border-color:#1429bd}:host [part~=cell]:not([today]):not([range]):not(:active) [part~=selection]:hover,:host [part~=cell][today][selected] [part~=selection]:hover{background:#1429bd}:host [part~=cell]:not([selected]):not([range]):not([today]) [part~=selection]:hover{background:#1429bd}:host [part~=cell]:not([selected]):not([range]):not([today]):not(:active) [part~=selection]:hover{border-color:#1429bd}:host [part~=cell]:not([selected]):not([range]):not([today]):not([disabled]):active [part~=selection]{color:#fff;background-color:#0f1e8a}:host [part~=cell][range]:not(:active) [part~=selection]:hover,:host [part~=cell][selected]:not(:active) [part~=selection]:hover,:host [part~=cell][today]:not(:active) [part~=selection]:hover{border-color:#1429bd}:host [part~=cell][range]:not([disabled]):active [part~=selection],:host [part~=cell][selected]:not([disabled]):active [part~=selection],:host [part~=cell][today]:not([disabled]):active [part~=selection]{color:#fff;background-color:#0f1e8a}:host [part~=cell][range] [part~=selection]{background:rgba(51,75,255,.2)}:host [part~=cell][range][today]{color:#fff}:host [part~=cell][selected]{color:#fff}:host [part~=cell][selected] [part~=selection]{background:#334bff}:host [part~=cell]:not(:first-of-type) [part~=cell-content]{left:1px}:host [part~=day-name]{color:#737373;font-weight:600}:host [part~=day-name] [part~=cell-content]{background-color:#fafafa}:host [part~=cell-content]{background:#fff;top:0;bottom:0;right:0;left:0}:host [part~=selection]{outline:0;border:1px solid #fff}:host([focused=visible]) [part~=cell] [part~=selection]:focus{outline:#1429bd solid 1px}:host([disabled]){opacity:.4}' }}));
@@ -1,3 +1,2 @@
1
1
  import '@refinitiv-ui/elements/button/themes/solar/charcoal';
2
-
3
2
  dispatchEvent(new CustomEvent('ef.customStyles.define', { detail: { name: 'ef-calendar', styles: ':host{font-style:normal;font-variant:normal;font-weight:400;line-height:normal;text-align:left;text-indent:0;text-shadow:none;text-transform:none;white-space:normal;word-break:normal;word-spacing:normal;word-wrap:normal;outline:0;font-size:13px;color:#c2c2c2;min-width:224px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background:#3c3c42;padding:4px}:host [part=navigation]{padding-bottom:4px}:host [part=btn-next],:host [part=btn-prev],:host [part=btn-view]{margin:0}:host [part=btn-view]{background:0 0;color:inherit;box-shadow:none;margin-left:15px;padding:0}:host [part=btn-view]:not([focused=visible]){border:none}:host [part=table]{width:100%;box-shadow:0 0 0 1px #000;background:#212124}:host [part~=row]:not(:last-of-type){box-shadow:0 1px 0 0 #0a0a0a}:host [part~=row]:not(:first-of-type) [part~=cell] [part~=selection]{top:1px}:host [part~=cell]:not(:last-of-type){box-shadow:1px 0 0 0 #0a0a0a}:host [part~=cell][disabled]{opacity:.4}:host [part~=cell][today]{color:#f93}:host [part~=cell][today] [part~=selection]{background:#3c3c42}:host [part~=cell]:not([selected]):not([range]):not([disabled])[idle] [part~=selection]{opacity:.6}:host [part~=cell]:not([selected]):not([range]) [part~=selection]:focus,:host [part~=cell]:not([selected]):not([range]) [part~=selection]:hover{background:#3c3c42;color:#e2e2e2}:host [part~=cell]:not([selected]):not([range]) [part~=selection]:focus{outline:#f93 dotted 1px}:host [part~=cell][range] [part~=selection]{background:rgba(255,153,51,.2)}:host [part~=cell][range][today]{color:#f93}:host [part~=cell][selected]{color:#000}:host [part~=cell][selected] [part~=selection]{background:#f93}:host [part~=cell]:not(:first-of-type) [part~=selection]{left:1px}:host [part~=day-name]{background-color:#151516;color:#666570;font-size:10px;font-weight:700}:host [part~=selection]{outline:0;top:0;bottom:0;right:0;left:0}:host([disabled]){opacity:.4}' }}));
@@ -1,3 +1,2 @@
1
1
  import '@refinitiv-ui/elements/button/themes/solar/pearl';
2
-
3
2
  dispatchEvent(new CustomEvent('ef.customStyles.define', { detail: { name: 'ef-calendar', styles: ':host{font-style:normal;font-variant:normal;font-weight:400;line-height:normal;text-align:left;text-indent:0;text-shadow:none;text-transform:none;white-space:normal;word-break:normal;word-spacing:normal;word-wrap:normal;outline:0;font-size:13px;color:#484848;min-width:224px;-webkit-user-select:none;-moz-user-select:none;-ms-user-select:none;user-select:none;background:#fff;padding:4px}:host [part=navigation]{padding-bottom:4px}:host [part=btn-next],:host [part=btn-prev],:host [part=btn-view]{margin:0}:host [part=btn-view]{background:0 0;color:inherit;box-shadow:none;margin-left:15px;padding:0}:host [part=btn-view]:not([focused=visible]){border:none}:host [part=table]{width:100%;box-shadow:0 0 0 1px #a9afba;background:#fff}:host [part~=row]:not(:last-of-type){box-shadow:0 1px 0 0 #d5d8db}:host [part~=row]:not(:first-of-type) [part~=cell] [part~=selection]{top:1px}:host [part~=cell]:not(:last-of-type){box-shadow:1px 0 0 0 #d5d8db}:host [part~=cell][disabled]{opacity:.4}:host [part~=cell][today]{color:#fff}:host [part~=cell][today] [part~=selection]{background:#acafb5}:host [part~=cell]:not([selected]):not([range]):not([disabled])[idle] [part~=selection]{opacity:.6}:host [part~=cell]:not([selected]):not([range]) [part~=selection]:focus,:host [part~=cell]:not([selected]):not([range]) [part~=selection]:hover{background:#e4e8ed;color:#000}:host [part~=cell]:not([selected]):not([range]) [part~=selection]:focus{outline:#ee7600 dotted 1px}:host [part~=cell][range] [part~=selection]{background:rgba(255,153,51,.2)}:host [part~=cell][range][today]{color:#f93}:host [part~=cell][selected]{color:#fff}:host [part~=cell][selected] [part~=selection]{background:#f93}:host [part~=cell]:not(:first-of-type) [part~=selection]{left:1px}:host [part~=day-name]{background-color:#e4e8ed;color:#6e6e78;font-size:10px;font-weight:700}:host [part~=selection]{outline:0;top:0;bottom:0;right:0;left:0}:host([disabled]){opacity:.4}' }}));
@@ -1,5 +1,5 @@
1
- import { toDateSegment, getDaysInMonth, utcParse } from '@refinitiv-ui/utils/date.js';
2
1
  import { DEFAULT_LOCALE, resolveLocale } from '@refinitiv-ui/i18n';
2
+ import { getDaysInMonth, toDateSegment, utcParse } from '@refinitiv-ui/utils/date.js';
3
3
  import { CalendarLocaleScope } from './constants.js';
4
4
  /**
5
5
  * Get information about number of days, month number and year from date object
@@ -102,7 +102,7 @@ const formatLocaleDate = (date, locale, includeMonth = false, includeEra = false
102
102
  const year = date.getUTCFullYear();
103
103
  const month = date.getUTCMonth();
104
104
  // BC flags are not supported. Always use English
105
- return `${includeMonth ? `${monthNames[month]} ` : ''} ${year > 0 ? year : year === 0 ? '1' : Math.abs(year - 1)}${includeEra ? year <= 0 ? ' BC' : ' AD' : ''}`;
105
+ return `${includeMonth ? `${monthNames[month]} ` : ''} ${year > 0 ? year : year === 0 ? '1' : Math.abs(year - 1)}${includeEra ? (year <= 0 ? ' BC' : ' AD') : ''}`;
106
106
  };
107
107
  /**
108
108
  * Used to format views
@@ -1,5 +1,5 @@
1
1
  import { JSXInterface } from '../jsx';
2
- import { ResponsiveElement, TemplateResult, CSSResultGroup, ElementSize } from '@refinitiv-ui/core';
2
+ import { CSSResultGroup, ElementSize, ResponsiveElement, TemplateResult } from '@refinitiv-ui/core';
3
3
  /**
4
4
  * A Component uses to draw graphics on a web page,
5
5
  * it works similarly to the normal HTML5 Canvas element.
@@ -1,5 +1,5 @@
1
1
  import { __decorate } from "tslib";
2
- import { ResponsiveElement, html, css } from '@refinitiv-ui/core';
2
+ import { ResponsiveElement, 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
5
  import { VERSION } from '../version.js';
@@ -156,9 +156,7 @@ let Canvas = class Canvas extends ResponsiveElement {
156
156
  * @return Render template
157
157
  */
158
158
  render() {
159
- return html `
160
- <canvas id="canvas"></canvas>
161
- `;
159
+ return html ` <canvas id="canvas"></canvas> `;
162
160
  }
163
161
  };
164
162
  __decorate([