@duetds/components 4.28.0 → 4.31.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 (502) hide show
  1. package/README.md +4 -4
  2. package/hydrate/index.js +914 -168
  3. package/lib/cjs/{action-arrow-down-small-ce4eddbc.js → action-arrow-down-small-ef77a2d1.js} +3 -0
  4. package/lib/cjs/{action-new-window-small-764927c8.js → action-new-window-small-fa51dfb9.js} +3 -0
  5. package/lib/cjs/{app-globals-10f3c9d9.js → app-globals-a032b236.js} +3 -0
  6. package/lib/cjs/{bodyScrollLock.es6-ec4c4a5c.js → bodyScrollLock.es6-6ef1142a.js} +3 -0
  7. package/lib/cjs/{common-strings-210be249.js → common-strings-de17f887.js} +3 -0
  8. package/lib/cjs/{create-id-d0d6cd15.js → create-id-c3b984b1.js} +3 -0
  9. package/lib/cjs/{dom-3e7d9c3b.js → dom-e89ebf90.js} +4 -1
  10. package/lib/cjs/duet-alert.cjs.entry.js +10 -4
  11. package/lib/cjs/duet-badge.cjs.entry.js +7 -4
  12. package/lib/cjs/duet-button_2.cjs.entry.js +17 -10
  13. package/lib/cjs/duet-caption_4.cjs.entry.js +23 -17
  14. package/lib/cjs/duet-card.cjs.entry.js +13 -10
  15. package/lib/cjs/duet-checkbox.cjs.entry.js +7 -4
  16. package/lib/cjs/duet-choice_2.cjs.entry.js +16 -11
  17. package/lib/cjs/duet-collapsible.cjs.entry.js +512 -8
  18. package/lib/cjs/duet-cookie-consent.cjs.entry.js +6 -3
  19. package/lib/cjs/duet-date-picker.cjs.entry.js +31 -15
  20. package/lib/cjs/duet-divider_2.cjs.entry.js +7 -4
  21. package/lib/cjs/duet-empty-state.cjs.entry.js +6 -3
  22. package/lib/cjs/duet-fieldset.cjs.entry.js +7 -4
  23. package/lib/cjs/duet-footer.cjs.entry.js +15 -8
  24. package/lib/cjs/duet-grid_2.cjs.entry.js +8 -5
  25. package/lib/cjs/duet-header_2.cjs.entry.js +68 -21
  26. package/lib/cjs/duet-hero.cjs.entry.js +16 -10
  27. package/lib/cjs/duet-icon.cjs.entry.js +22 -6
  28. package/lib/cjs/duet-input_2.cjs.entry.js +16 -8
  29. package/lib/cjs/duet-layout.cjs.entry.js +6 -3
  30. package/lib/cjs/duet-list_2.cjs.entry.js +8 -5
  31. package/lib/cjs/duet-modal.cjs.entry.js +19 -12
  32. package/lib/cjs/duet-notification_2.cjs.entry.js +17 -9
  33. package/lib/cjs/duet-number-input.cjs.entry.js +54 -24
  34. package/lib/cjs/duet-radio_2.cjs.entry.js +9 -6
  35. package/lib/cjs/duet-range-slider.cjs.entry.js +9 -6
  36. package/lib/cjs/duet-select.cjs.entry.js +8 -5
  37. package/lib/cjs/duet-step_2.cjs.entry.js +9 -6
  38. package/lib/cjs/duet-tab_2.cjs.entry.js +23 -11
  39. package/lib/cjs/duet-table.cjs.entry.js +7 -4
  40. package/lib/cjs/duet-textarea.cjs.entry.js +8 -5
  41. package/lib/cjs/duet-toggle.cjs.entry.js +7 -4
  42. package/lib/cjs/duet-tooltip.cjs.entry.js +33 -15
  43. package/lib/cjs/duet-tray.cjs.entry.js +33 -15
  44. package/lib/cjs/duet-visually-hidden.cjs.entry.js +5 -2
  45. package/lib/cjs/duet.cjs.js +8 -5
  46. package/lib/cjs/{focus-utils-162d8238.js → focus-utils-bd331feb.js} +4 -1
  47. package/lib/cjs/{index-69f4451b.js → index-113c2add.js} +11 -1
  48. package/lib/cjs/index.cjs.js +3 -0
  49. package/lib/cjs/{input-utils-712b8b32.js → input-utils-f3e3854c.js} +28 -0
  50. package/lib/cjs/{is-internet-explorer-cd4610fc.js → is-internet-explorer-91361c56.js} +3 -0
  51. package/lib/cjs/{keyboard-utils-a0b0a23c.js → keyboard-utils-b4e3d1d3.js} +3 -0
  52. package/lib/cjs/language-utils-48b8860b.js +93 -0
  53. package/lib/cjs/loader.cjs.js +7 -4
  54. package/lib/cjs/{shadow-css-09555044.js → shadow-css-0c8c175b.js} +4 -1
  55. package/lib/cjs/string-utils-267e3dbb.js +53 -0
  56. package/lib/cjs/{themeable-component-c462e6fd.js → themeable-component-0c1be552.js} +3 -0
  57. package/lib/cjs/{token-utils-4e9d1b6c.js → token-utils-13e5d13e.js} +4 -1
  58. package/lib/cjs/{tokens.module-6f0eaf7f.js → tokens.module-53b3bd92.js} +3 -0
  59. package/lib/cjs/{watch-options-edeeafd0.js → watch-options-3877c082.js} +3 -0
  60. package/lib/collection/collection-manifest.json +1 -1
  61. package/lib/collection/common-strings.js +3 -0
  62. package/lib/collection/components/duet-alert/duet-alert.js +19 -6
  63. package/lib/collection/components/duet-badge/duet-badge.css +1 -0
  64. package/lib/collection/components/duet-badge/duet-badge.js +4 -1
  65. package/lib/collection/components/duet-button/duet-button.css +3 -3
  66. package/lib/collection/components/duet-button/duet-button.js +28 -11
  67. package/lib/collection/components/duet-caption/duet-caption.js +4 -1
  68. package/lib/collection/components/duet-card/duet-card.css +10 -7
  69. package/lib/collection/components/duet-card/duet-card.js +9 -8
  70. package/lib/collection/components/duet-checkbox/duet-checkbox.js +4 -1
  71. package/lib/collection/components/duet-choice/duet-choice.css +0 -1
  72. package/lib/collection/components/duet-choice/duet-choice.js +17 -8
  73. package/lib/collection/components/duet-choice-group/duet-choice-group.css +3 -1
  74. package/lib/collection/components/duet-choice-group/duet-choice-group.js +5 -2
  75. package/lib/collection/components/duet-collapsible/duet-collapsible.js +110 -6
  76. package/lib/collection/components/duet-cookie-consent/duet-cookie-consent.js +4 -1
  77. package/lib/collection/components/duet-date-picker/date-i18n.js +3 -0
  78. package/lib/collection/components/duet-date-picker/date-picker-day.js +4 -1
  79. package/lib/collection/components/duet-date-picker/date-picker-input.js +4 -1
  80. package/lib/collection/components/duet-date-picker/date-picker-month.js +4 -1
  81. package/lib/collection/components/duet-date-picker/date-utils.js +3 -0
  82. package/lib/collection/components/duet-date-picker/duet-date-picker.css +1 -1
  83. package/lib/collection/components/duet-date-picker/duet-date-picker.js +85 -35
  84. package/lib/collection/components/duet-date-picker/utils.js +3 -0
  85. package/lib/collection/components/duet-divider/duet-divider.js +4 -1
  86. package/lib/collection/components/duet-empty-state/duet-empty-state.js +4 -1
  87. package/lib/collection/components/duet-fieldset/duet-fieldset.js +5 -2
  88. package/lib/collection/components/duet-footer/duet-footer.js +33 -12
  89. package/lib/collection/components/duet-grid/duet-grid.js +4 -1
  90. package/lib/collection/components/duet-grid-item/duet-grid-item.js +4 -1
  91. package/lib/collection/components/duet-header/duet-header.js +108 -36
  92. package/lib/collection/components/duet-heading/duet-heading.css +1 -0
  93. package/lib/collection/components/duet-heading/duet-heading.js +5 -2
  94. package/lib/collection/components/duet-hero/duet-hero.js +35 -15
  95. package/lib/collection/components/duet-icon/duet-icon.js +6 -3
  96. package/lib/collection/components/duet-icon/icon-utils.js +17 -1
  97. package/lib/collection/components/duet-input/duet-input.js +12 -4
  98. package/lib/collection/components/duet-label/duet-label.css +2 -0
  99. package/lib/collection/components/duet-label/duet-label.js +4 -1
  100. package/lib/collection/components/duet-layout/duet-layout.js +4 -1
  101. package/lib/collection/components/duet-link/duet-link.js +35 -17
  102. package/lib/collection/components/duet-list/duet-list.js +5 -2
  103. package/lib/collection/components/duet-list-item/duet-list-item.js +4 -1
  104. package/lib/collection/components/duet-logo/duet-logo.js +15 -4
  105. package/lib/collection/components/duet-modal/duet-modal.js +40 -17
  106. package/lib/collection/components/duet-notification/duet-notification.js +19 -4
  107. package/lib/collection/components/duet-notification-drawer/duet-notification-drawer.js +24 -12
  108. package/lib/collection/components/duet-number-input/duet-number-input.js +182 -31
  109. package/lib/collection/components/duet-number-input/number-input-utils.js +3 -0
  110. package/lib/collection/components/duet-paragraph/duet-paragraph.js +5 -2
  111. package/lib/collection/components/duet-radio/duet-radio.js +4 -1
  112. package/lib/collection/components/duet-radio-group/duet-radio-group.js +5 -2
  113. package/lib/collection/components/duet-range-slider/duet-range-slider.js +6 -3
  114. package/lib/collection/components/duet-select/duet-select.js +4 -1
  115. package/lib/collection/components/duet-spacer/duet-spacer.js +4 -1
  116. package/lib/collection/components/duet-spinner/duet-spinner.js +5 -2
  117. package/lib/collection/components/duet-step/duet-step.js +6 -3
  118. package/lib/collection/components/duet-stepper/duet-stepper.js +4 -1
  119. package/lib/collection/components/duet-tab/duet-tab.js +4 -1
  120. package/lib/collection/components/duet-tab-group/duet-tab-group.js +56 -10
  121. package/lib/collection/components/duet-table/duet-table.js +5 -2
  122. package/lib/collection/components/duet-textarea/duet-textarea.js +5 -2
  123. package/lib/collection/components/duet-toggle/duet-toggle.js +4 -1
  124. package/lib/collection/components/duet-tooltip/duet-tooltip.js +98 -17
  125. package/lib/collection/components/duet-tray/duet-tray.js +97 -16
  126. package/lib/collection/components/duet-visually-hidden/duet-visually-hidden.js +4 -1
  127. package/lib/collection/global/duet-global.js +3 -0
  128. package/lib/collection/utils/create-id.js +3 -0
  129. package/lib/collection/utils/fixture-utils.js +15 -5
  130. package/lib/collection/utils/focus-utils.js +3 -0
  131. package/lib/collection/utils/form-components.js +3 -0
  132. package/lib/collection/utils/group-by.js +3 -0
  133. package/lib/collection/utils/input-utils.js +27 -0
  134. package/lib/collection/utils/is-internet-explorer.js +3 -0
  135. package/lib/collection/utils/keyboard-utils.js +3 -0
  136. package/lib/collection/utils/language-utils.js +46 -8
  137. package/lib/collection/utils/string-utils.js +24 -0
  138. package/lib/collection/utils/test-utils.js +3 -0
  139. package/lib/collection/utils/themeable-component.js +3 -0
  140. package/lib/collection/utils/token-utils.js +3 -0
  141. package/lib/collection/utils/watch-options.js +3 -0
  142. package/lib/custom-elements-bundle/index.js +970 -222
  143. package/lib/duet/duet.esm.js +4 -1
  144. package/lib/duet/duet.js +1 -1
  145. package/lib/duet/index.esm.js +3 -0
  146. package/lib/duet/p-0058512b.js +4 -0
  147. package/lib/duet/p-0224db45.entry.js +4 -0
  148. package/lib/duet/{p-c261a84b.system.entry.js → p-02ad46a0.system.entry.js} +4 -1
  149. package/lib/duet/{p-ae82ab86.js → p-04f9f1bf.js} +3 -0
  150. package/lib/duet/{p-62b75c80.system.js → p-053b71e6.system.js} +3 -0
  151. package/lib/duet/{p-f5e7899b.system.entry.js → p-07263910.system.entry.js} +4 -1
  152. package/lib/duet/{p-6242ef49.system.js → p-0c4bbd65.system.js} +3 -0
  153. package/lib/duet/{p-8b9ee5b0.js → p-115c79b6.js} +3 -0
  154. package/lib/duet/{p-a69855b7.js → p-15c15c6a.js} +3 -0
  155. package/lib/duet/{p-e780bfa0.js → p-18d801be.js} +3 -0
  156. package/lib/duet/p-1bfbc988.entry.js +4 -0
  157. package/lib/duet/p-1cd7177f.entry.js +4 -0
  158. package/lib/duet/p-1cec5a70.system.entry.js +4 -0
  159. package/lib/duet/p-1e7222c2.entry.js +4 -0
  160. package/lib/duet/p-202bbd70.entry.js +4 -0
  161. package/lib/duet/{p-44d3eb2f.system.entry.js → p-22f56356.system.entry.js} +4 -1
  162. package/lib/duet/{p-551d38f9.js → p-2826f987.js} +3 -0
  163. package/lib/duet/p-28b67b94.entry.js +4 -0
  164. package/lib/duet/{p-01dad2d3.js → p-322d1c38.js} +4 -1
  165. package/lib/duet/p-33426ddc.entry.js +4 -0
  166. package/lib/duet/p-33cf6ed1.entry.js +4 -0
  167. package/lib/duet/p-3d3f773d.system.entry.js +4 -0
  168. package/lib/duet/p-3e1ef509.system.entry.js +4 -0
  169. package/lib/duet/p-3f78a826.system.js +4 -0
  170. package/lib/duet/{p-50e14ff9.system.js → p-418b2ce7.system.js} +3 -0
  171. package/lib/duet/{p-9d4322ba.system.js → p-43e39d98.system.js} +3 -0
  172. package/lib/duet/p-44ffb960.entry.js +4 -0
  173. package/lib/duet/p-453955cc.system.entry.js +4 -0
  174. package/lib/duet/p-4670a654.entry.js +4 -0
  175. package/lib/duet/p-47645ea8.system.entry.js +4 -0
  176. package/lib/duet/p-504dbf8f.system.entry.js +4 -0
  177. package/lib/duet/p-5230ee3c.system.entry.js +4 -0
  178. package/lib/duet/p-56e172f5.system.entry.js +4 -0
  179. package/lib/duet/{p-7d7a595e.system.js → p-57ea2576.system.js} +4 -1
  180. package/lib/duet/p-5aa0d34d.entry.js +4 -0
  181. package/lib/duet/{p-63b13a5f.system.js → p-5f6bd5db.system.js} +3 -0
  182. package/lib/duet/p-5fc7e1f7.system.entry.js +4 -0
  183. package/lib/duet/p-605bc214.system.entry.js +4 -0
  184. package/lib/duet/p-60ab57d4.entry.js +4 -0
  185. package/lib/duet/p-64109493.entry.js +4 -0
  186. package/lib/duet/p-69a5dc6b.entry.js +4 -0
  187. package/lib/duet/p-6a230911.system.entry.js +4 -0
  188. package/lib/duet/p-6a356ab1.system.js +4 -0
  189. package/lib/duet/p-6a760b8a.entry.js +4 -0
  190. package/lib/duet/p-6d2da245.entry.js +4 -0
  191. package/lib/duet/p-704245ef.js +4 -0
  192. package/lib/duet/p-712e7dde.system.entry.js +4 -0
  193. package/lib/duet/p-746655ba.entry.js +4 -0
  194. package/lib/duet/p-76f00bd5.js +4 -0
  195. package/lib/duet/p-7b6db837.system.entry.js +4 -0
  196. package/lib/duet/p-7d080785.system.entry.js +4 -0
  197. package/lib/duet/p-82dc2e0b.entry.js +4 -0
  198. package/lib/duet/p-8c8e82aa.system.js +4 -0
  199. package/lib/duet/{p-5fe386d7.system.entry.js → p-8c980350.system.entry.js} +4 -1
  200. package/lib/duet/{p-1fcc25b6.system.entry.js → p-8cb47a70.system.entry.js} +4 -1
  201. package/lib/duet/p-8f03c3eb.entry.js +4 -0
  202. package/lib/duet/{p-50ea2036.system.js → p-8faaaf5f.system.js} +3 -0
  203. package/lib/duet/p-91fa68a5.js +4 -0
  204. package/lib/duet/p-92d38668.system.entry.js +4 -0
  205. package/lib/duet/p-95626e7e.system.entry.js +4 -0
  206. package/lib/duet/p-96808a2e.system.entry.js +4 -0
  207. package/lib/duet/p-96c103b2.system.entry.js +4 -0
  208. package/lib/duet/p-986779fb.js +4 -0
  209. package/lib/duet/{p-a0c363a1.js → p-9a89ec39.js} +3 -0
  210. package/lib/duet/p-9a8d5b11.system.js +4 -0
  211. package/lib/duet/p-9a945278.system.js +4 -0
  212. package/lib/duet/p-9c94be45.entry.js +4 -0
  213. package/lib/duet/p-9ce1baab.system.entry.js +4 -0
  214. package/lib/duet/p-9dfcd29a.js +4 -0
  215. package/lib/duet/p-9ff25646.entry.js +4 -0
  216. package/lib/duet/p-a1d12e94.system.entry.js +4 -0
  217. package/lib/duet/{p-a78af9f5.js → p-a28cf57b.js} +3 -0
  218. package/lib/duet/p-b03a46b6.entry.js +4 -0
  219. package/lib/duet/p-b1b8e510.entry.js +4 -0
  220. package/lib/duet/p-b694cbf5.system.js +4 -0
  221. package/lib/duet/p-b7e50cfa.entry.js +4 -0
  222. package/lib/duet/p-b82927b0.system.entry.js +4 -0
  223. package/lib/duet/p-ba205dca.entry.js +4 -0
  224. package/lib/duet/{p-2dd28142.system.js → p-bb12b972.system.js} +3 -0
  225. package/lib/duet/p-bcae23fc.system.entry.js +4 -0
  226. package/lib/duet/{p-a0e09a50.js → p-bd779757.js} +3 -0
  227. package/lib/duet/{p-69599f4e.js → p-bd9a7d8f.js} +3 -0
  228. package/lib/duet/p-be19c57b.system.entry.js +4 -0
  229. package/lib/duet/{p-6e296e99.js → p-c1325e35.js} +3 -0
  230. package/lib/duet/p-c4737f88.entry.js +4 -0
  231. package/lib/duet/{p-c3058688.js → p-c5beceed.js} +4 -1
  232. package/lib/duet/p-c5f10483.system.entry.js +4 -0
  233. package/lib/duet/{p-d95998b4.system.js → p-c7ae95bd.system.js} +3 -0
  234. package/lib/duet/{p-31c3b93f.system.js → p-ce0892e6.system.js} +3 -0
  235. package/lib/duet/p-d35fd913.system.entry.js +4 -0
  236. package/lib/duet/p-d4b4bfa6.entry.js +4 -0
  237. package/lib/duet/p-d7623eb8.system.entry.js +4 -0
  238. package/lib/duet/p-d863e150.system.js +4 -0
  239. package/lib/duet/p-dc85d2a4.entry.js +4 -0
  240. package/lib/duet/p-de093c16.entry.js +4 -0
  241. package/lib/duet/p-de842863.entry.js +4 -0
  242. package/lib/duet/p-e08b8909.entry.js +4 -0
  243. package/lib/duet/p-e39471b6.entry.js +4 -0
  244. package/lib/duet/{p-f180f2f2.system.js → p-e566ff11.system.js} +3 -0
  245. package/lib/duet/{p-cd603d87.system.js → p-e58ca7af.system.js} +4 -1
  246. package/lib/duet/p-e834c8d5.system.entry.js +4 -0
  247. package/lib/duet/{p-a8a8954e.system.entry.js → p-ef45cfe9.system.entry.js} +4 -1
  248. package/lib/duet/{p-73baca13.system.js → p-efaa0c04.system.js} +3 -0
  249. package/lib/duet/{p-fd305188.system.entry.js → p-f0b1850a.system.entry.js} +4 -1
  250. package/lib/duet/{p-871f3440.js → p-f11208c3.js} +3 -0
  251. package/lib/duet/p-f53c8019.entry.js +4 -0
  252. package/lib/duet/{p-95253d0a.entry.js → p-f96c4093.system.entry.js} +4 -1
  253. package/lib/duet/p-fbd83d67.entry.js +4 -0
  254. package/lib/duet/{p-dbe056ce.system.js → p-fd98468a.system.js} +3 -0
  255. package/lib/duet/p-fdecaf46.entry.js +4 -0
  256. package/lib/esm/{action-arrow-down-small-c24d2c7f.js → action-arrow-down-small-82273dc8.js} +3 -0
  257. package/lib/esm/{action-new-window-small-d592feb6.js → action-new-window-small-1945be91.js} +3 -0
  258. package/lib/esm/{app-globals-2796679e.js → app-globals-6641e444.js} +3 -0
  259. package/lib/esm/{bodyScrollLock.es6-cf1e49b2.js → bodyScrollLock.es6-61b5e9a4.js} +3 -0
  260. package/lib/esm/{common-strings-d5205fd4.js → common-strings-97e04e4b.js} +3 -0
  261. package/lib/esm/{create-id-124e0fc4.js → create-id-981107da.js} +3 -0
  262. package/lib/esm/{dom-1f98a75f.js → dom-21034390.js} +4 -1
  263. package/lib/esm/duet-alert.entry.js +10 -4
  264. package/lib/esm/duet-badge.entry.js +7 -4
  265. package/lib/esm/duet-button_2.entry.js +17 -10
  266. package/lib/esm/duet-caption_4.entry.js +23 -17
  267. package/lib/esm/duet-card.entry.js +13 -10
  268. package/lib/esm/duet-checkbox.entry.js +7 -4
  269. package/lib/esm/duet-choice_2.entry.js +16 -11
  270. package/lib/esm/duet-collapsible.entry.js +512 -8
  271. package/lib/esm/duet-cookie-consent.entry.js +6 -3
  272. package/lib/esm/duet-date-picker.entry.js +31 -15
  273. package/lib/esm/duet-divider_2.entry.js +7 -4
  274. package/lib/esm/duet-empty-state.entry.js +6 -3
  275. package/lib/esm/duet-fieldset.entry.js +7 -4
  276. package/lib/esm/duet-footer.entry.js +15 -8
  277. package/lib/esm/duet-grid_2.entry.js +8 -5
  278. package/lib/esm/duet-header_2.entry.js +68 -21
  279. package/lib/esm/duet-hero.entry.js +16 -10
  280. package/lib/esm/duet-icon.entry.js +22 -6
  281. package/lib/esm/duet-input_2.entry.js +16 -8
  282. package/lib/esm/duet-layout.entry.js +6 -3
  283. package/lib/esm/duet-list_2.entry.js +8 -5
  284. package/lib/esm/duet-modal.entry.js +19 -12
  285. package/lib/esm/duet-notification_2.entry.js +17 -9
  286. package/lib/esm/duet-number-input.entry.js +54 -24
  287. package/lib/esm/duet-radio_2.entry.js +9 -6
  288. package/lib/esm/duet-range-slider.entry.js +9 -6
  289. package/lib/esm/duet-select.entry.js +8 -5
  290. package/lib/esm/duet-step_2.entry.js +9 -6
  291. package/lib/esm/duet-tab_2.entry.js +23 -11
  292. package/lib/esm/duet-table.entry.js +7 -4
  293. package/lib/esm/duet-textarea.entry.js +8 -5
  294. package/lib/esm/duet-toggle.entry.js +7 -4
  295. package/lib/esm/duet-tooltip.entry.js +33 -15
  296. package/lib/esm/duet-tray.entry.js +33 -15
  297. package/lib/esm/duet-visually-hidden.entry.js +5 -2
  298. package/lib/esm/duet.js +8 -5
  299. package/lib/esm/{focus-utils-e76191e8.js → focus-utils-1995e5a9.js} +4 -1
  300. package/lib/esm/{index-aaa7610e.js → index-6e246691.js} +11 -1
  301. package/lib/esm/index.js +3 -1
  302. package/lib/esm/{input-utils-8a4c03a1.js → input-utils-f4cafee1.js} +28 -1
  303. package/lib/esm/{is-internet-explorer-0b40c5fe.js → is-internet-explorer-62b3bdbd.js} +3 -0
  304. package/lib/esm/{keyboard-utils-956f0d36.js → keyboard-utils-584cedd7.js} +3 -0
  305. package/lib/esm/language-utils-d5c38f65.js +89 -0
  306. package/lib/esm/loader.js +7 -4
  307. package/lib/esm/{shadow-css-67b66845.js → shadow-css-31e2d504.js} +4 -1
  308. package/lib/esm/string-utils-2f1793b8.js +49 -0
  309. package/lib/esm/{themeable-component-2a857b64.js → themeable-component-572685dd.js} +3 -0
  310. package/lib/esm/{token-utils-56e2be37.js → token-utils-5a35377f.js} +4 -1
  311. package/lib/esm/{tokens.module-17f6088f.js → tokens.module-edb66c04.js} +3 -0
  312. package/lib/esm/{watch-options-8f61a365.js → watch-options-de55ea78.js} +3 -0
  313. package/lib/esm-es5/{action-arrow-down-small-c24d2c7f.js → action-arrow-down-small-82273dc8.js} +3 -0
  314. package/lib/esm-es5/{action-new-window-small-d592feb6.js → action-new-window-small-1945be91.js} +3 -0
  315. package/lib/esm-es5/{app-globals-2796679e.js → app-globals-6641e444.js} +3 -0
  316. package/lib/esm-es5/{bodyScrollLock.es6-cf1e49b2.js → bodyScrollLock.es6-61b5e9a4.js} +3 -0
  317. package/lib/esm-es5/{common-strings-d5205fd4.js → common-strings-97e04e4b.js} +3 -0
  318. package/lib/esm-es5/{create-id-124e0fc4.js → create-id-981107da.js} +3 -0
  319. package/lib/esm-es5/{dom-1f98a75f.js → dom-21034390.js} +3 -0
  320. package/lib/esm-es5/duet-alert.entry.js +4 -1
  321. package/lib/esm-es5/duet-badge.entry.js +4 -1
  322. package/lib/esm-es5/duet-button_2.entry.js +4 -1
  323. package/lib/esm-es5/duet-caption_4.entry.js +4 -1
  324. package/lib/esm-es5/duet-card.entry.js +4 -1
  325. package/lib/esm-es5/duet-checkbox.entry.js +4 -1
  326. package/lib/esm-es5/duet-choice_2.entry.js +4 -1
  327. package/lib/esm-es5/duet-collapsible.entry.js +4 -1
  328. package/lib/esm-es5/duet-cookie-consent.entry.js +4 -1
  329. package/lib/esm-es5/duet-date-picker.entry.js +4 -1
  330. package/lib/esm-es5/duet-divider_2.entry.js +4 -1
  331. package/lib/esm-es5/duet-empty-state.entry.js +4 -1
  332. package/lib/esm-es5/duet-fieldset.entry.js +4 -1
  333. package/lib/esm-es5/duet-footer.entry.js +4 -1
  334. package/lib/esm-es5/duet-grid_2.entry.js +4 -1
  335. package/lib/esm-es5/duet-header_2.entry.js +4 -1
  336. package/lib/esm-es5/duet-hero.entry.js +4 -1
  337. package/lib/esm-es5/duet-icon.entry.js +4 -1
  338. package/lib/esm-es5/duet-input_2.entry.js +4 -1
  339. package/lib/esm-es5/duet-layout.entry.js +4 -1
  340. package/lib/esm-es5/duet-list_2.entry.js +4 -1
  341. package/lib/esm-es5/duet-modal.entry.js +4 -1
  342. package/lib/esm-es5/duet-notification_2.entry.js +4 -1
  343. package/lib/esm-es5/duet-number-input.entry.js +4 -1
  344. package/lib/esm-es5/duet-radio_2.entry.js +4 -1
  345. package/lib/esm-es5/duet-range-slider.entry.js +4 -1
  346. package/lib/esm-es5/duet-select.entry.js +4 -1
  347. package/lib/esm-es5/duet-step_2.entry.js +4 -1
  348. package/lib/esm-es5/duet-tab_2.entry.js +4 -1
  349. package/lib/esm-es5/duet-table.entry.js +4 -1
  350. package/lib/esm-es5/duet-textarea.entry.js +4 -1
  351. package/lib/esm-es5/duet-toggle.entry.js +4 -1
  352. package/lib/esm-es5/duet-tooltip.entry.js +4 -1
  353. package/lib/esm-es5/duet-tray.entry.js +4 -1
  354. package/lib/esm-es5/duet-visually-hidden.entry.js +4 -1
  355. package/lib/esm-es5/duet.js +4 -1
  356. package/lib/esm-es5/{focus-utils-e76191e8.js → focus-utils-1995e5a9.js} +4 -1
  357. package/lib/esm-es5/index-6e246691.js +4 -0
  358. package/lib/esm-es5/index.js +3 -0
  359. package/lib/esm-es5/input-utils-f4cafee1.js +4 -0
  360. package/lib/esm-es5/{is-internet-explorer-0b40c5fe.js → is-internet-explorer-62b3bdbd.js} +3 -0
  361. package/lib/esm-es5/{keyboard-utils-956f0d36.js → keyboard-utils-584cedd7.js} +3 -0
  362. package/lib/esm-es5/language-utils-d5c38f65.js +4 -0
  363. package/lib/esm-es5/loader.js +4 -1
  364. package/lib/esm-es5/{shadow-css-67b66845.js → shadow-css-31e2d504.js} +3 -0
  365. package/lib/esm-es5/string-utils-2f1793b8.js +4 -0
  366. package/lib/esm-es5/{themeable-component-2a857b64.js → themeable-component-572685dd.js} +3 -0
  367. package/lib/esm-es5/{token-utils-56e2be37.js → token-utils-5a35377f.js} +4 -1
  368. package/lib/esm-es5/{tokens.module-17f6088f.js → tokens.module-edb66c04.js} +3 -0
  369. package/lib/esm-es5/{watch-options-8f61a365.js → watch-options-de55ea78.js} +3 -0
  370. package/lib/html.html-data.json +140 -2
  371. package/lib/loader/cdn.js +3 -1
  372. package/lib/loader/index.cjs.js +3 -1
  373. package/lib/loader/index.d.ts +0 -1
  374. package/lib/loader/index.es2017.js +3 -1
  375. package/lib/loader/index.js +3 -1
  376. package/lib/types/components/duet-alert/duet-alert.d.ts +4 -2
  377. package/lib/types/components/duet-badge/duet-badge.d.ts +1 -1
  378. package/lib/types/components/duet-button/duet-button.d.ts +6 -3
  379. package/lib/types/components/duet-caption/duet-caption.d.ts +1 -1
  380. package/lib/types/components/duet-card/duet-card.d.ts +1 -1
  381. package/lib/types/components/duet-checkbox/duet-checkbox.d.ts +1 -1
  382. package/lib/types/components/duet-choice/duet-choice.d.ts +5 -4
  383. package/lib/types/components/duet-collapsible/duet-collapsible.d.ts +24 -1
  384. package/lib/types/components/duet-date-picker/date-picker-month.d.ts +1 -1
  385. package/lib/types/components/duet-date-picker/duet-date-picker.d.ts +16 -7
  386. package/lib/types/components/duet-divider/duet-divider.d.ts +1 -1
  387. package/lib/types/components/duet-empty-state/duet-empty-state.d.ts +1 -1
  388. package/lib/types/components/duet-fieldset/duet-fieldset.d.ts +1 -1
  389. package/lib/types/components/duet-footer/duet-footer.d.ts +7 -3
  390. package/lib/types/components/duet-grid-item/duet-grid-item.d.ts +1 -1
  391. package/lib/types/components/duet-header/duet-header.d.ts +50 -8
  392. package/lib/types/components/duet-heading/duet-heading.d.ts +1 -1
  393. package/lib/types/components/duet-hero/duet-hero.d.ts +8 -5
  394. package/lib/types/components/duet-icon/duet-icon.d.ts +1 -1
  395. package/lib/types/components/duet-input/duet-input.d.ts +2 -2
  396. package/lib/types/components/duet-link/duet-link.d.ts +8 -5
  397. package/lib/types/components/duet-list/duet-list.d.ts +1 -1
  398. package/lib/types/components/duet-logo/duet-logo.d.ts +3 -1
  399. package/lib/types/components/duet-modal/duet-modal.d.ts +11 -5
  400. package/lib/types/components/duet-notification/duet-notification.d.ts +4 -1
  401. package/lib/types/components/duet-notification-drawer/duet-notification-drawer.d.ts +6 -5
  402. package/lib/types/components/duet-number-input/duet-number-input.d.ts +29 -2
  403. package/lib/types/components/duet-paragraph/duet-paragraph.d.ts +1 -1
  404. package/lib/types/components/duet-radio/duet-radio.d.ts +2 -2
  405. package/lib/types/components/duet-range-slider/duet-range-slider.d.ts +2 -2
  406. package/lib/types/components/duet-select/duet-select.d.ts +1 -1
  407. package/lib/types/components/duet-step/duet-step.d.ts +1 -1
  408. package/lib/types/components/duet-stepper/duet-stepper.d.ts +1 -1
  409. package/lib/types/components/duet-tab-group/duet-tab-group.d.ts +10 -1
  410. package/lib/types/components/duet-textarea/duet-textarea.d.ts +2 -2
  411. package/lib/types/components/duet-toggle/duet-toggle.d.ts +2 -2
  412. package/lib/types/components/duet-tooltip/duet-tooltip.d.ts +16 -1
  413. package/lib/types/components/duet-tray/duet-tray.d.ts +15 -0
  414. package/lib/types/components.d.ts +265 -33
  415. package/lib/types/utils/input-utils.d.ts +9 -0
  416. package/lib/types/utils/language-utils.d.ts +26 -3
  417. package/lib/types/utils/string-utils.d.ts +1 -0
  418. package/lib/types/utils/test-utils.d.ts +1 -1
  419. package/package.json +39 -23
  420. package/lib/cjs/language-utils-0f4f60f1.js +0 -54
  421. package/lib/cjs/string-utils-0336d6da.js +0 -28
  422. package/lib/duet/p-00914fa8.entry.js +0 -1
  423. package/lib/duet/p-08b10b1b.entry.js +0 -1
  424. package/lib/duet/p-0a5bdffc.entry.js +0 -1
  425. package/lib/duet/p-117e6a2d.system.entry.js +0 -1
  426. package/lib/duet/p-11f650f9.system.entry.js +0 -1
  427. package/lib/duet/p-120f15f9.entry.js +0 -1
  428. package/lib/duet/p-1270fad1.entry.js +0 -1
  429. package/lib/duet/p-15c4ae87.system.entry.js +0 -1
  430. package/lib/duet/p-19d86321.system.js +0 -1
  431. package/lib/duet/p-1a544f89.js +0 -1
  432. package/lib/duet/p-1a773ea3.system.entry.js +0 -1
  433. package/lib/duet/p-1f18716e.entry.js +0 -1
  434. package/lib/duet/p-2141f564.system.js +0 -1
  435. package/lib/duet/p-23f2a281.entry.js +0 -1
  436. package/lib/duet/p-28072b15.entry.js +0 -1
  437. package/lib/duet/p-2ce3a1bc.entry.js +0 -1
  438. package/lib/duet/p-2f56c5d0.entry.js +0 -1
  439. package/lib/duet/p-330725c5.js +0 -1
  440. package/lib/duet/p-378186a8.entry.js +0 -1
  441. package/lib/duet/p-393dc5f0.system.entry.js +0 -1
  442. package/lib/duet/p-4486ae28.system.entry.js +0 -1
  443. package/lib/duet/p-45713f8a.system.entry.js +0 -1
  444. package/lib/duet/p-4e4d8137.system.entry.js +0 -1
  445. package/lib/duet/p-4f4895e0.entry.js +0 -1
  446. package/lib/duet/p-51f89eec.entry.js +0 -1
  447. package/lib/duet/p-545f6a97.entry.js +0 -1
  448. package/lib/duet/p-568ab60b.system.entry.js +0 -1
  449. package/lib/duet/p-598ba79a.js +0 -1
  450. package/lib/duet/p-598edf9e.system.entry.js +0 -1
  451. package/lib/duet/p-5e6a5340.entry.js +0 -1
  452. package/lib/duet/p-64fd394a.entry.js +0 -1
  453. package/lib/duet/p-66c75914.system.entry.js +0 -1
  454. package/lib/duet/p-6dc51621.system.entry.js +0 -1
  455. package/lib/duet/p-6f41124b.system.js +0 -1
  456. package/lib/duet/p-6f6b2cc5.system.entry.js +0 -1
  457. package/lib/duet/p-700243af.entry.js +0 -1
  458. package/lib/duet/p-770d46e6.entry.js +0 -1
  459. package/lib/duet/p-8498e753.system.entry.js +0 -1
  460. package/lib/duet/p-852e96c1.system.js +0 -1
  461. package/lib/duet/p-86de511c.system.entry.js +0 -1
  462. package/lib/duet/p-8db7a844.system.entry.js +0 -1
  463. package/lib/duet/p-91255671.js +0 -1
  464. package/lib/duet/p-921afc00.entry.js +0 -1
  465. package/lib/duet/p-9ac41fbc.system.entry.js +0 -1
  466. package/lib/duet/p-9b6adcb3.system.entry.js +0 -1
  467. package/lib/duet/p-9b9cb411.system.entry.js +0 -1
  468. package/lib/duet/p-9ff8c7c4.entry.js +0 -1
  469. package/lib/duet/p-a4d8b2c4.entry.js +0 -1
  470. package/lib/duet/p-a92bdc1c.system.entry.js +0 -1
  471. package/lib/duet/p-b6e261ef.js +0 -1
  472. package/lib/duet/p-b761ef2d.entry.js +0 -1
  473. package/lib/duet/p-b87ce8c9.system.entry.js +0 -1
  474. package/lib/duet/p-bdf5fe15.entry.js +0 -1
  475. package/lib/duet/p-c0c1bcba.system.js +0 -1
  476. package/lib/duet/p-c5fe3120.system.entry.js +0 -1
  477. package/lib/duet/p-c6d19c6c.system.entry.js +0 -1
  478. package/lib/duet/p-c8068a31.entry.js +0 -1
  479. package/lib/duet/p-cb073c9b.entry.js +0 -1
  480. package/lib/duet/p-cb49c05a.system.js +0 -1
  481. package/lib/duet/p-cb62f051.entry.js +0 -1
  482. package/lib/duet/p-ce55045f.js +0 -1
  483. package/lib/duet/p-d20651ba.entry.js +0 -1
  484. package/lib/duet/p-d7c57e6c.entry.js +0 -1
  485. package/lib/duet/p-da0df691.system.entry.js +0 -1
  486. package/lib/duet/p-dc2d2635.system.entry.js +0 -1
  487. package/lib/duet/p-dcd0f562.system.entry.js +0 -1
  488. package/lib/duet/p-dd4281d5.entry.js +0 -1
  489. package/lib/duet/p-e374aba6.entry.js +0 -1
  490. package/lib/duet/p-e693d73a.system.entry.js +0 -1
  491. package/lib/duet/p-e7bef783.entry.js +0 -1
  492. package/lib/duet/p-ec326c4c.system.entry.js +0 -1
  493. package/lib/duet/p-efa3e05d.entry.js +0 -1
  494. package/lib/duet/p-f2cca5cc.system.js +0 -1
  495. package/lib/duet/p-f3d07b69.entry.js +0 -1
  496. package/lib/duet/p-fbeb43e8.entry.js +0 -1
  497. package/lib/esm/language-utils-c7ce7c0e.js +0 -50
  498. package/lib/esm/string-utils-9ef35d2a.js +0 -25
  499. package/lib/esm-es5/index-aaa7610e.js +0 -1
  500. package/lib/esm-es5/input-utils-8a4c03a1.js +0 -1
  501. package/lib/esm-es5/language-utils-c7ce7c0e.js +0 -1
  502. package/lib/esm-es5/string-utils-9ef35d2a.js +0 -1
@@ -1,9 +1,12 @@
1
- import { Component, Element, State, Watch, Prop, Event, h } from "@stencil/core";
2
- import { inheritGlobalTheme } from "../../utils/themeable-component";
1
+ /*!
2
+ * Built with Duet Design System
3
+ */
3
4
  import newWindowIcon from "@duetds/icons/lib/assets/action-new-window-small";
4
- import { parsePossibleJSON } from "../../utils/string-utils";
5
- import { getLanguage, getLocaleString } from "../../utils/language-utils";
5
+ import { Component, Element, Event, h, Prop, State, Watch } from "@stencil/core";
6
6
  import { DuetStringsExternalDefaults } from "../../common-strings";
7
+ import { getLanguage, getLocaleString } from "../../utils/language-utils";
8
+ import { parsePossibleJSON } from "../../utils/string-utils";
9
+ import { inheritGlobalTheme } from "../../utils/themeable-component";
7
10
  /**
8
11
  * @slot default - This is an unamed slot for a text or extra button that is placed after any buttons (or list item)
9
12
  * @slot badge - This is a slot for a status badge that sits next to pre-heading inside the hero component.
@@ -67,17 +70,20 @@ export class DuetHero {
67
70
  /**
68
71
  * The currently active language. This setting changes the accessible labels to match the
69
72
  * chosen language.
73
+ * @deprecated this is now handled via the html lang tag, and is no longer used - kept to avoid breaking changes and ease unit testing
74
+ * @default "fi"
70
75
  */
71
76
  this.language = getLanguage();
72
77
  /**
73
- * Property to change accessibleLabelExternal defaults on the component.
74
- * normally you would handle these strings on an application level and override @accessibleLabelExternal when needed
78
+ * Defaults for accessibleLabelExternal
79
+ * @default {fi: "Avautuu uuteen ikkunaan",sv: "Öppnas i nytt fönster",en: "Opens in a new window"}
75
80
  */
76
81
  this.accessibleLabelExternalDefaults = DuetStringsExternalDefaults;
77
82
  /**
78
83
  * Adds accessible label for tooltip that is shown in external link (url & external have both been set)
84
+ * @default {fi: "Avautuu uuteen ikkunaan",sv: "Öppnas i nytt fönster",en: "Opens in a new window"}
79
85
  */
80
- this.accessibleLabelExternal = getLocaleString(this.accessibleLabelExternalDefaults, this.language);
86
+ this.accessibleLabelExternal = getLocaleString(this.accessibleLabelExternalDefaults);
81
87
  /**
82
88
  * URL that the button links to.
83
89
  */
@@ -478,7 +484,13 @@ export class DuetHero {
478
484
  "required": false,
479
485
  "optional": false,
480
486
  "docs": {
481
- "tags": [],
487
+ "tags": [{
488
+ "text": "this is now handled via the html lang tag, and is no longer used - kept to avoid breaking changes and ease unit testing",
489
+ "name": "deprecated"
490
+ }, {
491
+ "text": "\"fi\"",
492
+ "name": "default"
493
+ }],
482
494
  "text": "The currently active language. This setting changes the accessible labels to match the\nchosen language."
483
495
  },
484
496
  "attribute": "language",
@@ -486,11 +498,11 @@ export class DuetHero {
486
498
  "defaultValue": "getLanguage()"
487
499
  },
488
500
  "accessibleLabelExternalDefaults": {
489
- "type": "unknown",
501
+ "type": "string",
490
502
  "mutable": false,
491
503
  "complexType": {
492
- "original": "DuetLangObject",
493
- "resolved": "DuetLangObject",
504
+ "original": "DuetLangObject | string",
505
+ "resolved": "DuetLangObject | string",
494
506
  "references": {
495
507
  "DuetLangObject": {
496
508
  "location": "import",
@@ -501,9 +513,14 @@ export class DuetHero {
501
513
  "required": false,
502
514
  "optional": false,
503
515
  "docs": {
504
- "tags": [],
505
- "text": "Property to change accessibleLabelExternal defaults on the component.\nnormally you would handle these strings on an application level and override @accessibleLabelExternal when needed"
516
+ "tags": [{
517
+ "text": "{fi: \"Avautuu uuteen ikkunaan\",sv: \"\u00D6ppnas i nytt f\u00F6nster\",en: \"Opens in a new window\"}",
518
+ "name": "default"
519
+ }],
520
+ "text": "Defaults for accessibleLabelExternal"
506
521
  },
522
+ "attribute": "accessible-label-external-default",
523
+ "reflect": false,
507
524
  "defaultValue": "DuetStringsExternalDefaults"
508
525
  },
509
526
  "accessibleLabelExternal": {
@@ -517,12 +534,15 @@ export class DuetHero {
517
534
  "required": false,
518
535
  "optional": false,
519
536
  "docs": {
520
- "tags": [],
537
+ "tags": [{
538
+ "text": "{fi: \"Avautuu uuteen ikkunaan\",sv: \"\u00D6ppnas i nytt f\u00F6nster\",en: \"Opens in a new window\"}",
539
+ "name": "default"
540
+ }],
521
541
  "text": "Adds accessible label for tooltip that is shown in external link (url & external have both been set)"
522
542
  },
523
543
  "attribute": "accessible-label-external",
524
544
  "reflect": false,
525
- "defaultValue": "getLocaleString(this.accessibleLabelExternalDefaults, this.language)"
545
+ "defaultValue": "getLocaleString(this.accessibleLabelExternalDefaults)"
526
546
  },
527
547
  "buttonUrl": {
528
548
  "type": "string",
@@ -1,7 +1,10 @@
1
- import { Component, Prop, Element, Host, h, State, Build, Watch } from "@stencil/core";
2
- import { getColorByName } from "../../utils/token-utils";
1
+ /*!
2
+ * Built with Duet Design System
3
+ */
4
+ import { Build, Component, Element, h, Host, Prop, State, Watch } from "@stencil/core";
3
5
  import { inheritGlobalTheme } from "../../utils/themeable-component";
4
- import { fetchIconByUrl, buildIconUrl } from "./icon-utils";
6
+ import { getColorByName } from "../../utils/token-utils";
7
+ import { buildIconUrl, fetchIconByUrl } from "./icon-utils";
5
8
  export class DuetIcon {
6
9
  constructor() {
7
10
  /**
@@ -1,3 +1,6 @@
1
+ /*!
2
+ * Built with Duet Design System
3
+ */
1
4
  const cleanupSvg = (svgContent) => {
2
5
  if (typeof document === "undefined" || !svgContent) {
3
6
  return;
@@ -32,7 +35,20 @@ const isValid = (elm) => {
32
35
  }
33
36
  return true;
34
37
  };
35
- export const buildIconUrl = (iconName) => `https://cdn.duetds.com/api/icons/${process.env.DUET_ICON_VERSION}/lib/assets/${iconName}.svg`;
38
+ export const buildIconUrl = (iconName) => {
39
+ // under normal operations the Icons should always be loaded from the CDN
40
+ const cdnURI = `https://cdn.duetds.com/api/icons/${process.env.DUET_ICON_VERSION}/lib/assets/${iconName}.svg`;
41
+ // however for vizdiffing and local development / testing we need to be able to access the raw images
42
+ const localURI = `http://0.0.0.0:3334/icons/lib/assets/${iconName}.svg`;
43
+ const host = window.location.hostname;
44
+ const re = /(localhost|loca\.lt|127\.0\.0\.1|0\.0\.0\.0)/i;
45
+ if (host.match(re)) {
46
+ return localURI;
47
+ }
48
+ else {
49
+ return cdnURI;
50
+ }
51
+ };
36
52
  const iconCache = {};
37
53
  export function fetchIconByUrl(url) {
38
54
  if (iconCache[url]) {
@@ -1,9 +1,12 @@
1
- import { Component, Prop, Element, Method, Host, Event, Watch, h } from "@stencil/core";
2
- import { createID } from "../../utils/create-id";
1
+ /*!
2
+ * Built with Duet Design System
3
+ */
3
4
  import emailIcon from "@duetds/icons/lib/assets/form-email";
4
5
  import searchIcon from "@duetds/icons/lib/assets/form-search";
6
+ import { Component, Element, Event, h, Host, Method, Prop, Watch } from "@stencil/core";
7
+ import { createID } from "../../utils/create-id";
8
+ import { cleanValue, resetCursor } from "../../utils/input-utils";
5
9
  import { inheritGlobalTheme } from "../../utils/themeable-component";
6
- import { cleanValue } from "../../utils/input-utils";
7
10
  const icons = {
8
11
  search: searchIcon,
9
12
  email: emailIcon,
@@ -129,8 +132,13 @@ export class DuetInput {
129
132
  this.disallowPatternRegex = this.disallowPattern ? new RegExp(this.disallowPattern, "g") : null;
130
133
  }
131
134
  valueChanged() {
132
- if (this.nativeInput) {
135
+ var _a;
136
+ if (((_a = this === null || this === void 0 ? void 0 : this.nativeInput) === null || _a === void 0 ? void 0 : _a.value) !== this.value) {
137
+ const restoreCursor = resetCursor(this.nativeInput);
133
138
  this.nativeInput.value = this.value;
139
+ // restore selection position after having set value
140
+ // (in webkit based browsers settings value trigger cursor position and will set it to EndOfText)
141
+ restoreCursor();
134
142
  }
135
143
  this.isCaptionVisible = !!(this.caption || (this.placeholder && this.echoPlaceholder && this.value));
136
144
  const emitEvent = () => this.duetChange.emit({
@@ -62,10 +62,12 @@ label {
62
62
  line-height: 1.25;
63
63
  color: #00294d;
64
64
  text-align: left;
65
+ word-break: break-word;
65
66
  }
66
67
  label span {
67
68
  font-size: 1rem;
68
69
  font-weight: 600 !important;
70
+ word-break: break-word;
69
71
  }
70
72
 
71
73
  :host(.duet-label-small) label {
@@ -1,4 +1,7 @@
1
- import { Component, Host, Prop, h } from "@stencil/core";
1
+ /*!
2
+ * Built with Duet Design System
3
+ */
4
+ import { Component, h, Host, Prop } from "@stencil/core";
2
5
  import { inheritGlobalTheme } from "../../utils/themeable-component";
3
6
  export class DuetLabel {
4
7
  constructor() {
@@ -1,4 +1,7 @@
1
- import { Component, Prop, Host, Element, h } from "@stencil/core";
1
+ /*!
2
+ * Built with Duet Design System
3
+ */
4
+ import { Component, Element, h, Host, Prop } from "@stencil/core";
2
5
  import isInternetExplorer from "../../utils/is-internet-explorer";
3
6
  /**
4
7
  * @slot main - The layout component’s primary content. Use this for the main content on the page.
@@ -1,24 +1,30 @@
1
- import { Component, Prop, Host, h, Build, Fragment, Method } from "@stencil/core";
1
+ /*!
2
+ * Built with Duet Design System
3
+ */
2
4
  import newWindowIcon from "@duetds/icons/lib/assets/action-new-window-small";
3
- import { inheritGlobalTheme } from "../../utils/themeable-component";
4
- import { getLanguage, getLocaleString } from "../../utils/language-utils";
5
+ import { Build, Component, Fragment, h, Host, Method, Prop } from "@stencil/core";
5
6
  import { DuetStringsExternalDefaults } from "../../common-strings";
7
+ import { getLanguage, getLocaleString } from "../../utils/language-utils";
8
+ import { inheritGlobalTheme } from "../../utils/themeable-component";
6
9
  export class DuetLink {
7
10
  constructor() {
8
11
  /**
9
12
  * The currently active language. This setting changes the external link
10
13
  * accessible label to match the chosen language.
14
+ * @deprecated this is now handled via the html lang tag, and is no longer used - kept to avoid breaking changes and ease unit testing
15
+ * @default "fi"
11
16
  */
12
17
  this.language = getLanguage();
13
18
  /**
14
- * Property to change accessibleLabelExternal defaults on the component.
15
- * normally you would handle these strings on an application level and override @accessibleLabelExternal when needed
19
+ * Defaults for accessibleLabelExternal
20
+ * @default {fi: "Avautuu uuteen ikkunaan",sv: "Öppnas i nytt fönster",en: "Opens in a new window"}
16
21
  */
17
22
  this.accessibleLabelExternalDefaults = DuetStringsExternalDefaults;
18
23
  /**
19
24
  * Adds accessible label for tooltip that is shown in external link (url & external have both been set)
25
+ * @default {fi: "Avautuu uuteen ikkunaan",sv: "Öppnas i nytt fönster",en: "Opens in a new window"}
20
26
  */
21
- this.accessibleLabelExternal = getLocaleString(this.accessibleLabelExternalDefaults, this.language);
27
+ this.accessibleLabelExternal = getLocaleString(this.accessibleLabelExternalDefaults);
22
28
  /**
23
29
  * Theme of the button.
24
30
  */
@@ -58,9 +64,7 @@ export class DuetLink {
58
64
  }, target: this.external ? "_blank" : "_self", "aria-label": this.accessibleLabel, id: this.identifier, ref: el => (this.nativeLink = el) },
59
65
  h("slot", null),
60
66
  Build.isBrowser && this.external && (h(Fragment, null,
61
- h("duet-visually-hidden", null,
62
- ", ",
63
- this.accessibleLabelExternal),
67
+ h("duet-visually-hidden", null, this.accessibleLabelExternal),
64
68
  h("span", { class: "duet-link-external" },
65
69
  h("duet-icon", { icon: newWindowIcon.svg, size: "xx-small", margin: "none", color: "currentColor" })))))));
66
70
  }
@@ -107,7 +111,13 @@ export class DuetLink {
107
111
  "required": false,
108
112
  "optional": false,
109
113
  "docs": {
110
- "tags": [],
114
+ "tags": [{
115
+ "text": "this is now handled via the html lang tag, and is no longer used - kept to avoid breaking changes and ease unit testing",
116
+ "name": "deprecated"
117
+ }, {
118
+ "text": "\"fi\"",
119
+ "name": "default"
120
+ }],
111
121
  "text": "The currently active language. This setting changes the external link\naccessible label to match the chosen language."
112
122
  },
113
123
  "attribute": "language",
@@ -115,11 +125,11 @@ export class DuetLink {
115
125
  "defaultValue": "getLanguage()"
116
126
  },
117
127
  "accessibleLabelExternalDefaults": {
118
- "type": "unknown",
128
+ "type": "string",
119
129
  "mutable": false,
120
130
  "complexType": {
121
- "original": "DuetLangObject",
122
- "resolved": "DuetLangObject",
131
+ "original": "DuetLangObject | string",
132
+ "resolved": "DuetLangObject | string",
123
133
  "references": {
124
134
  "DuetLangObject": {
125
135
  "location": "import",
@@ -130,9 +140,14 @@ export class DuetLink {
130
140
  "required": false,
131
141
  "optional": false,
132
142
  "docs": {
133
- "tags": [],
134
- "text": "Property to change accessibleLabelExternal defaults on the component.\nnormally you would handle these strings on an application level and override @accessibleLabelExternal when needed"
143
+ "tags": [{
144
+ "text": "{fi: \"Avautuu uuteen ikkunaan\",sv: \"\u00D6ppnas i nytt f\u00F6nster\",en: \"Opens in a new window\"}",
145
+ "name": "default"
146
+ }],
147
+ "text": "Defaults for accessibleLabelExternal"
135
148
  },
149
+ "attribute": "accessible-label-external-default",
150
+ "reflect": false,
136
151
  "defaultValue": "DuetStringsExternalDefaults"
137
152
  },
138
153
  "accessibleLabelExternal": {
@@ -146,12 +161,15 @@ export class DuetLink {
146
161
  "required": false,
147
162
  "optional": false,
148
163
  "docs": {
149
- "tags": [],
164
+ "tags": [{
165
+ "text": "{fi: \"Avautuu uuteen ikkunaan\",sv: \"\u00D6ppnas i nytt f\u00F6nster\",en: \"Opens in a new window\"}",
166
+ "name": "default"
167
+ }],
150
168
  "text": "Adds accessible label for tooltip that is shown in external link (url & external have both been set)"
151
169
  },
152
170
  "attribute": "accessible-label-external",
153
171
  "reflect": false,
154
- "defaultValue": "getLocaleString(this.accessibleLabelExternalDefaults, this.language)"
172
+ "defaultValue": "getLocaleString(this.accessibleLabelExternalDefaults)"
155
173
  },
156
174
  "identifier": {
157
175
  "type": "string",
@@ -1,6 +1,9 @@
1
- import { Component, Prop, Watch, Element, h } from "@stencil/core";
2
- import { watchForOptions } from "../../utils/watch-options";
1
+ /*!
2
+ * Built with Duet Design System
3
+ */
4
+ import { Component, Element, h, Prop, Watch } from "@stencil/core";
3
5
  import { inheritGlobalTheme } from "../../utils/themeable-component";
6
+ import { watchForOptions } from "../../utils/watch-options";
4
7
  export class DuetList {
5
8
  constructor() {
6
9
  /**
@@ -1,4 +1,7 @@
1
- import { Component, Host, h } from "@stencil/core";
1
+ /*!
2
+ * Built with Duet Design System
3
+ */
4
+ import { Component, h, Host } from "@stencil/core";
2
5
  /**
3
6
  * @slot label - The list item component’s label content. Use this to put content into description list’s dt element.
4
7
  * @slot value - The list item component’s value content. Use this to put content into description list’s dd element.
@@ -1,8 +1,11 @@
1
- import { Component, Prop, Element, Method, Host, h } from "@stencil/core";
1
+ /*!
2
+ * Built with Duet Design System
3
+ */
4
+ import { colorBrandBlue, colorBrandGrayTurva, colorGrayLightest, colorPrimaryTurva } from "@duetds/tokens";
5
+ import { Component, Element, h, Host, Method, Prop } from "@stencil/core";
2
6
  import { createID } from "../../utils/create-id";
3
- import { colorBrandGrayTurva, colorPrimaryTurva, colorGrayLightest, colorBrandBlue } from "@duetds/tokens";
4
- import { inheritGlobalTheme } from "../../utils/themeable-component";
5
7
  import { getLanguage } from "../../utils/language-utils";
8
+ import { inheritGlobalTheme } from "../../utils/themeable-component";
6
9
  const TurvaLogo = ({ inverse, logoId }) => {
7
10
  const logoColor = inverse ? colorGrayLightest : colorBrandGrayTurva;
8
11
  const textColor = inverse ? colorGrayLightest : colorPrimaryTurva;
@@ -64,6 +67,8 @@ export class DuetLogo {
64
67
  this.href = "/";
65
68
  /**
66
69
  * The language of the logo.
70
+ * @deprecated this is now handled via the html lang tag, and is no longer used - kept to avoid breaking changes and ease unit testing
71
+ * @default "fi"
67
72
  */
68
73
  this.language = getLanguage();
69
74
  }
@@ -226,7 +231,13 @@ export class DuetLogo {
226
231
  "required": false,
227
232
  "optional": false,
228
233
  "docs": {
229
- "tags": [],
234
+ "tags": [{
235
+ "text": "this is now handled via the html lang tag, and is no longer used - kept to avoid breaking changes and ease unit testing",
236
+ "name": "deprecated"
237
+ }, {
238
+ "text": "\"fi\"",
239
+ "name": "default"
240
+ }],
230
241
  "text": "The language of the logo."
231
242
  },
232
243
  "attribute": "language",
@@ -1,14 +1,20 @@
1
- import { Event, State, Element, Component, Method, Watch, Listen, Prop, h } from "@stencil/core";
1
+ /*!
2
+ * Built with Duet Design System
3
+ */
4
+ import { Component, Element, Event, h, Listen, Method, Prop, State, Watch } from "@stencil/core";
2
5
  import { disableBodyScroll, enableBodyScroll } from "body-scroll-lock/lib/bodyScrollLock.es6.js";
3
6
  import { createID } from "../../utils/create-id";
4
- import { inheritGlobalTheme } from "../../utils/themeable-component";
5
- import { isEscapeKey } from "../../utils/keyboard-utils";
6
7
  import { focusElement, FocusGuard } from "../../utils/focus-utils";
7
- import { getLocaleString, getLanguage } from "../../utils/language-utils";
8
+ import { isEscapeKey } from "../../utils/keyboard-utils";
9
+ import { getLanguage, getLocaleString } from "../../utils/language-utils";
10
+ import { inheritGlobalTheme } from "../../utils/themeable-component";
8
11
  // The transition below is slightly higher than the actual CSS transition as VoiceOver on
9
12
  // iOS has otherwise problems moving the focus from modal back to the original element.
10
13
  // This issue is similar to what we’ve seen in Duet Date Picker + iOS VoiceOver.
11
14
  const TRANSITION_MS = 600;
15
+ /**
16
+ * @slot top - This is a slot that takes any content and will be displayed as the first thing in the hero area (typically an image)
17
+ */
12
18
  export class DuetModal {
13
19
  constructor() {
14
20
  var _a, _b;
@@ -41,13 +47,15 @@ export class DuetModal {
41
47
  /**
42
48
  * The currently active language. This setting also changes the logo to match
43
49
  * the chosen language.
50
+ * @deprecated this is now handled via the html lang tag, and is no longer used - kept to avoid breaking changes and ease unit testing
51
+ * @default "fi"
44
52
  */
45
53
  this.language = getLanguage();
46
54
  /**
47
- * Property to change accessibleCloseLabel defaults on the component.
48
- * normally you would handle these strings on an application level and override @accessibleCloseLabel when needed
55
+ * Defaults for accessibleCloseLabel
56
+ * @default {fi: "Sulje ikkuna", sv: "Stäng fönstret", en: "Close the dialog", }
49
57
  */
50
- this.accessibleCloseLabelDefault = {
58
+ this.accessibleCloseLabelDefaults = {
51
59
  fi: "Sulje ikkuna",
52
60
  sv: "Stäng fönstret",
53
61
  en: "Close the dialog",
@@ -56,8 +64,9 @@ export class DuetModal {
56
64
  * Adds accessible label for the close icon that is only shown for screen
57
65
  * readers. This property is always required to create an accessibly interface!
58
66
  * Swedish translation for this property is “Stäng fönstret”.
67
+ * @default {fi: "Sulje ikkuna", sv: "Stäng fönstret", en: "Close the dialog", }
59
68
  */
60
- this.accessibleCloseLabel = getLocaleString(this.accessibleCloseLabelDefault);
69
+ this.accessibleCloseLabel = getLocaleString(this.accessibleCloseLabelDefaults, this.language);
61
70
  /**
62
71
  * Size of the modal window.
63
72
  */
@@ -253,19 +262,25 @@ export class DuetModal {
253
262
  "required": false,
254
263
  "optional": false,
255
264
  "docs": {
256
- "tags": [],
265
+ "tags": [{
266
+ "text": "this is now handled via the html lang tag, and is no longer used - kept to avoid breaking changes and ease unit testing",
267
+ "name": "deprecated"
268
+ }, {
269
+ "text": "\"fi\"",
270
+ "name": "default"
271
+ }],
257
272
  "text": "The currently active language. This setting also changes the logo to match\nthe chosen language."
258
273
  },
259
274
  "attribute": "language",
260
275
  "reflect": false,
261
276
  "defaultValue": "getLanguage()"
262
277
  },
263
- "accessibleCloseLabelDefault": {
264
- "type": "unknown",
278
+ "accessibleCloseLabelDefaults": {
279
+ "type": "string",
265
280
  "mutable": false,
266
281
  "complexType": {
267
- "original": "DuetLangObject",
268
- "resolved": "DuetLangObject",
282
+ "original": "DuetLangObject | string",
283
+ "resolved": "DuetLangObject | string",
269
284
  "references": {
270
285
  "DuetLangObject": {
271
286
  "location": "import",
@@ -276,9 +291,14 @@ export class DuetModal {
276
291
  "required": false,
277
292
  "optional": false,
278
293
  "docs": {
279
- "tags": [],
280
- "text": "Property to change accessibleCloseLabel defaults on the component.\nnormally you would handle these strings on an application level and override @accessibleCloseLabel when needed"
294
+ "tags": [{
295
+ "text": "{fi: \"Sulje ikkuna\", sv: \"St\u00E4ng f\u00F6nstret\", en: \"Close the dialog\", }",
296
+ "name": "default"
297
+ }],
298
+ "text": "Defaults for accessibleCloseLabel"
281
299
  },
300
+ "attribute": "accessible-close-label-default",
301
+ "reflect": false,
282
302
  "defaultValue": "{\n fi: \"Sulje ikkuna\",\n sv: \"St\u00E4ng f\u00F6nstret\",\n en: \"Close the dialog\",\n }"
283
303
  },
284
304
  "accessibleCloseLabel": {
@@ -292,12 +312,15 @@ export class DuetModal {
292
312
  "required": false,
293
313
  "optional": false,
294
314
  "docs": {
295
- "tags": [],
315
+ "tags": [{
316
+ "text": "{fi: \"Sulje ikkuna\", sv: \"St\u00E4ng f\u00F6nstret\", en: \"Close the dialog\", }",
317
+ "name": "default"
318
+ }],
296
319
  "text": "Adds accessible label for the close icon that is only shown for screen\nreaders. This property is always required to create an accessibly interface!\nSwedish translation for this property is \u201CSt\u00E4ng f\u00F6nstret\u201D."
297
320
  },
298
321
  "attribute": "accessible-close-label",
299
322
  "reflect": false,
300
- "defaultValue": "getLocaleString(this.accessibleCloseLabelDefault)"
323
+ "defaultValue": "getLocaleString(this.accessibleCloseLabelDefaults, this.language)"
301
324
  },
302
325
  "size": {
303
326
  "type": "string",
@@ -1,11 +1,16 @@
1
- import { h, Component, Prop, Method, Element } from "@stencil/core";
2
- import { inheritGlobalTheme } from "../../utils/themeable-component";
1
+ /*!
2
+ * Built with Duet Design System
3
+ */
4
+ import { Component, Element, h, Method, Prop } from "@stencil/core";
3
5
  import { getLanguage, getLocaleString } from "../../utils/language-utils";
6
+ import { inheritGlobalTheme } from "../../utils/themeable-component";
4
7
  export class DuetNotification {
5
8
  constructor() {
6
9
  /**
7
10
  * The currently active language.
8
11
  * Used for announcing unread notifications to screen readers.
12
+ * @deprecated this is now handled via the html lang tag, and is no longer used - kept to avoid breaking changes and ease unit testing
13
+ * @default "fi"
9
14
  */
10
15
  this.language = getLanguage();
11
16
  /**
@@ -19,6 +24,7 @@ export class DuetNotification {
19
24
  };
20
25
  /**
21
26
  * Adds accessible label for tooltip that is shown over unread counter
27
+ * @default { en: "Unread", fi: "Lukematon", sv: "Oläst" }
22
28
  */
23
29
  this.accessibleLabelUnread = getLocaleString(this.accessibleLabelUnreadDefaults, this.language);
24
30
  /**
@@ -97,7 +103,13 @@ export class DuetNotification {
97
103
  "required": false,
98
104
  "optional": false,
99
105
  "docs": {
100
- "tags": [],
106
+ "tags": [{
107
+ "text": "this is now handled via the html lang tag, and is no longer used - kept to avoid breaking changes and ease unit testing",
108
+ "name": "deprecated"
109
+ }, {
110
+ "text": "\"fi\"",
111
+ "name": "default"
112
+ }],
101
113
  "text": "The currently active language.\nUsed for announcing unread notifications to screen readers."
102
114
  },
103
115
  "attribute": "language",
@@ -136,7 +148,10 @@ export class DuetNotification {
136
148
  "required": false,
137
149
  "optional": false,
138
150
  "docs": {
139
- "tags": [],
151
+ "tags": [{
152
+ "text": "{ en: \"Unread\", fi: \"Lukematon\", sv: \"Ol\u00E4st\" }",
153
+ "name": "default"
154
+ }],
140
155
  "text": "Adds accessible label for tooltip that is shown over unread counter"
141
156
  },
142
157
  "attribute": "accessible-label-unread",
@@ -1,7 +1,10 @@
1
- import { Component, Prop, Element, h, State, Listen, Method } from "@stencil/core";
1
+ /*!
2
+ * Built with Duet Design System
3
+ */
2
4
  import arrowDownIcon from "@duetds/icons/lib/assets/action-arrow-down-small";
3
- import { inheritGlobalTheme } from "../../utils/themeable-component";
5
+ import { Component, Element, h, Listen, Method, Prop, State } from "@stencil/core";
4
6
  import { getLanguage, getLocaleString } from "../../utils/language-utils";
7
+ import { inheritGlobalTheme } from "../../utils/themeable-component";
5
8
  const ESC_KEY = 27;
6
9
  export class DuetNotificationDrawer {
7
10
  constructor() {
@@ -24,8 +27,8 @@ export class DuetNotificationDrawer {
24
27
  */
25
28
  this.language = getLanguage();
26
29
  /**
27
- * Property to change accessibleLabelNotifications defaults on the component.
28
- * normally you would handle these strings on an application level and override @accessibleLabelNotifications when needed
30
+ * Defaults for accessibleLabelNotifications
31
+ * @default {en: "No notifications", fi: "Ei ilmoituksia", sv: "Inga notifikationer"}
29
32
  */
30
33
  this.accessibleLabelNotificationsDefaults = {
31
34
  en: "No notifications",
@@ -34,8 +37,9 @@ export class DuetNotificationDrawer {
34
37
  };
35
38
  /**
36
39
  * Adds accessible label for tooltip that is shown for notifications
40
+ * @default {en: "No notifications", fi: "Ei ilmoituksia", sv: "Inga notifikationer"}
37
41
  */
38
- this.accessibleLabelNotifications = getLocaleString(this.accessibleLabelNotificationsDefaults, this.language);
42
+ this.accessibleLabelNotifications = getLocaleString(this.accessibleLabelNotificationsDefaults);
39
43
  /**
40
44
  * Show a badge that indicates something has changed.
41
45
  */
@@ -213,11 +217,11 @@ export class DuetNotificationDrawer {
213
217
  "defaultValue": "getLanguage()"
214
218
  },
215
219
  "accessibleLabelNotificationsDefaults": {
216
- "type": "unknown",
220
+ "type": "string",
217
221
  "mutable": false,
218
222
  "complexType": {
219
- "original": "DuetLangObject",
220
- "resolved": "DuetLangObject",
223
+ "original": "| DuetLangObject\n | string",
224
+ "resolved": "DuetLangObject | string",
221
225
  "references": {
222
226
  "DuetLangObject": {
223
227
  "location": "import",
@@ -228,9 +232,14 @@ export class DuetNotificationDrawer {
228
232
  "required": false,
229
233
  "optional": false,
230
234
  "docs": {
231
- "tags": [],
232
- "text": "Property to change accessibleLabelNotifications defaults on the component.\nnormally you would handle these strings on an application level and override @accessibleLabelNotifications when needed"
235
+ "tags": [{
236
+ "text": "{en: \"No notifications\", fi: \"Ei ilmoituksia\", sv: \"Inga notifikationer\"}",
237
+ "name": "default"
238
+ }],
239
+ "text": "Defaults for accessibleLabelNotifications"
233
240
  },
241
+ "attribute": "accessible-label-notification-default",
242
+ "reflect": false,
234
243
  "defaultValue": "{\n en: \"No notifications\",\n fi: \"Ei ilmoituksia\",\n sv: \"Inga notifikationer\",\n }"
235
244
  },
236
245
  "accessibleLabelNotifications": {
@@ -244,12 +253,15 @@ export class DuetNotificationDrawer {
244
253
  "required": false,
245
254
  "optional": false,
246
255
  "docs": {
247
- "tags": [],
256
+ "tags": [{
257
+ "text": "{en: \"No notifications\", fi: \"Ei ilmoituksia\", sv: \"Inga notifikationer\"}",
258
+ "name": "default"
259
+ }],
248
260
  "text": "Adds accessible label for tooltip that is shown for notifications"
249
261
  },
250
262
  "attribute": "accessible-label-notifications",
251
263
  "reflect": false,
252
- "defaultValue": "getLocaleString(\n this.accessibleLabelNotificationsDefaults,\n this.language\n )"
264
+ "defaultValue": "getLocaleString(this.accessibleLabelNotificationsDefaults)"
253
265
  },
254
266
  "badge": {
255
267
  "type": "boolean",