@duetds/components 10.5.0 → 10.7.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 (479) hide show
  1. package/hydrate/index.js +658 -282
  2. package/hydrate/index.mjs +658 -282
  3. package/lib/cjs/{a11y-utils-DaAO4N9d.js → a11y-utils-DmCjy3Q3.js} +1 -1
  4. package/lib/cjs/{app-globals-CHNvdfQj.js → app-globals-D1tikFob.js} +1 -1
  5. package/lib/cjs/duet-action-button.cjs.entry.js +6 -6
  6. package/lib/cjs/duet-alert.cjs.entry.js +4 -4
  7. package/lib/cjs/duet-badge.cjs.entry.js +7 -7
  8. package/lib/cjs/duet-banner.cjs.entry.js +17 -18
  9. package/lib/cjs/duet-breadcrumb.cjs.entry.js +7 -7
  10. package/lib/cjs/duet-breadcrumbs.cjs.entry.js +7 -7
  11. package/lib/cjs/duet-button_2.cjs.entry.js +8 -8
  12. package/lib/cjs/duet-callout.cjs.entry.js +5 -5
  13. package/lib/cjs/duet-caption_4.cjs.entry.js +11 -11
  14. package/lib/cjs/duet-card.cjs.entry.js +22 -10
  15. package/lib/cjs/duet-checkbox.cjs.entry.js +3 -3
  16. package/lib/cjs/duet-checkmark.cjs.entry.js +4 -4
  17. package/lib/cjs/duet-chip.cjs.entry.js +28 -12
  18. package/lib/cjs/duet-choice_2.cjs.entry.js +7 -7
  19. package/lib/cjs/duet-collapsible.cjs.entry.js +4 -4
  20. package/lib/cjs/duet-combobox.cjs.entry.js +7 -17
  21. package/lib/cjs/duet-contact-card.cjs.entry.js +18 -7
  22. package/lib/cjs/duet-cookie-consent.cjs.entry.js +3 -3
  23. package/lib/cjs/duet-date-picker.cjs.entry.js +127 -14
  24. package/lib/cjs/duet-divider_2.cjs.entry.js +5 -5
  25. package/lib/cjs/duet-editable-table_3.cjs.entry.js +15 -15
  26. package/lib/cjs/duet-empty-state.cjs.entry.js +2 -2
  27. package/lib/cjs/duet-fieldset.cjs.entry.js +6 -6
  28. package/lib/cjs/duet-file-chooser.cjs.entry.js +2 -2
  29. package/lib/cjs/duet-footer.cjs.entry.js +5 -5
  30. package/lib/cjs/duet-grid_2.cjs.entry.js +12 -8
  31. package/lib/cjs/duet-header_2.cjs.entry.js +7 -7
  32. package/lib/cjs/duet-hero.cjs.entry.js +27 -21
  33. package/lib/cjs/duet-icon.cjs.entry.js +7 -7
  34. package/lib/cjs/duet-indicator.cjs.entry.js +5 -5
  35. package/lib/cjs/duet-input_2.cjs.entry.js +70 -18
  36. package/lib/cjs/duet-layout.cjs.entry.js +7 -7
  37. package/lib/cjs/duet-list_2.cjs.entry.js +5 -5
  38. package/lib/cjs/duet-menu-bar-button.cjs.entry.js +4 -4
  39. package/lib/cjs/duet-menu-bar-dropdown-link.cjs.entry.js +5 -5
  40. package/lib/cjs/duet-menu-bar-dropdown.cjs.entry.js +7 -7
  41. package/lib/cjs/duet-menu-bar-item.cjs.entry.js +7 -7
  42. package/lib/cjs/duet-menu-bar-link.cjs.entry.js +4 -4
  43. package/lib/cjs/duet-menu-bar.cjs.entry.js +6 -6
  44. package/lib/cjs/duet-modal.cjs.entry.js +15 -15
  45. package/lib/cjs/duet-multiselect.cjs.entry.js +11 -11
  46. package/lib/cjs/duet-nav.cjs.entry.js +3 -3
  47. package/lib/cjs/duet-notification_2.cjs.entry.js +10 -10
  48. package/lib/cjs/duet-number-input.cjs.entry.js +9 -9
  49. package/lib/cjs/duet-overlay.cjs.entry.js +3 -3
  50. package/lib/cjs/duet-page-heading.cjs.entry.js +6 -6
  51. package/lib/cjs/duet-pagination_2.cjs.entry.js +19 -19
  52. package/lib/cjs/duet-panel.cjs.entry.js +4 -4
  53. package/lib/cjs/duet-phone-input.cjs.entry.js +11 -6
  54. package/lib/cjs/duet-popup-menu_2.cjs.entry.js +10 -10
  55. package/lib/cjs/duet-progress.cjs.entry.js +3 -3
  56. package/lib/cjs/duet-promo-card.cjs.entry.js +20 -8
  57. package/lib/cjs/duet-radio_2.cjs.entry.js +7 -7
  58. package/lib/cjs/duet-range-slider.cjs.entry.js +8 -8
  59. package/lib/cjs/duet-scrollable_3.cjs.entry.js +18 -18
  60. package/lib/cjs/duet-section-layout.cjs.entry.js +4 -4
  61. package/lib/cjs/duet-select.cjs.entry.js +9 -9
  62. package/lib/cjs/duet-shaped-image.cjs.entry.js +4 -4
  63. package/lib/cjs/duet-share-chart-item.cjs.entry.js +2 -2
  64. package/lib/cjs/duet-share-chart.cjs.entry.js +8 -8
  65. package/lib/cjs/duet-show-more.cjs.entry.js +6 -6
  66. package/lib/cjs/duet-slideout-lang.cjs.entry.js +4 -4
  67. package/lib/cjs/duet-slideout-link.cjs.entry.js +7 -7
  68. package/lib/cjs/duet-slideout-panel-dropdown.cjs.entry.js +6 -6
  69. package/lib/cjs/duet-slideout-panel.cjs.entry.js +13 -13
  70. package/lib/cjs/duet-slideout.cjs.entry.js +20 -14
  71. package/lib/cjs/duet-status-icon.cjs.entry.js +3 -3
  72. package/lib/cjs/duet-step_2.cjs.entry.js +7 -7
  73. package/lib/cjs/duet-submenu-bar-dropdown-link.cjs.entry.js +5 -5
  74. package/lib/cjs/duet-submenu-bar-dropdown.cjs.entry.js +7 -7
  75. package/lib/cjs/duet-submenu-bar-item.cjs.entry.js +7 -7
  76. package/lib/cjs/duet-submenu-bar-link.cjs.entry.js +4 -4
  77. package/lib/cjs/duet-submenu-bar.cjs.entry.js +7 -7
  78. package/lib/cjs/duet-teaser.cjs.entry.js +110 -0
  79. package/lib/cjs/duet-textarea.cjs.entry.js +8 -8
  80. package/lib/cjs/duet-toggle.cjs.entry.js +9 -9
  81. package/lib/cjs/duet-toolbar-dropdown-link.cjs.entry.js +5 -5
  82. package/lib/cjs/duet-toolbar-dropdown.cjs.entry.js +7 -7
  83. package/lib/cjs/duet-toolbar-item.cjs.entry.js +8 -8
  84. package/lib/cjs/duet-toolbar-link.cjs.entry.js +4 -4
  85. package/lib/cjs/duet-toolbar.cjs.entry.js +4 -4
  86. package/lib/cjs/duet-tooltip-button_2.cjs.entry.js +10 -10
  87. package/lib/cjs/duet-tooltip.cjs.entry.js +5 -5
  88. package/lib/cjs/duet-tray.cjs.entry.js +7 -7
  89. package/lib/cjs/duet-upload-aria-status.cjs.entry.js +2 -2
  90. package/lib/cjs/duet-upload-item.cjs.entry.js +6 -6
  91. package/lib/cjs/duet-visually-hidden.cjs.entry.js +2 -2
  92. package/lib/cjs/duet.cjs.js +3 -3
  93. package/lib/cjs/{errorcodes.utils-Dkf_MfrJ.js → errorcodes.utils-Di-nO8ua.js} +1 -1
  94. package/lib/cjs/{focus-utils-BuGg0Oha.js → focus-utils-uEO1pi2O.js} +1 -1
  95. package/lib/cjs/{index-ZxE6MB5V.js → index-BGRMvA4R.js} +13 -9
  96. package/lib/cjs/{keyboard-utils-D9UlHbik.js → keyboard-utils-DibQafwg.js} +2 -0
  97. package/lib/cjs/{label-CpPOBfjS.js → label-CwgdRt0Q.js} +1 -1
  98. package/lib/cjs/{language-utils-C7Z0KYg-.js → language-utils-CrB5zNlc.js} +1 -1
  99. package/lib/cjs/loader.cjs.js +3 -3
  100. package/lib/cjs/picture-utils-CZhgDlXJ.js +20 -0
  101. package/lib/cjs/{slot-utils-BXdHT3A1.js → slot-utils-4v5bqyQh.js} +1 -1
  102. package/lib/cjs/{themeable-component-CIDaln0Z.js → themeable-component-I4SEm6nQ.js} +1 -1
  103. package/lib/cjs/{token-utils-DY3-olMV.js → token-utils-ZISdNshf.js} +1 -1
  104. package/lib/cjs/{tokens.module-CTbvyezn.js → tokens.module-CGRpZaa1.js} +2 -1
  105. package/lib/collection/collection-manifest.json +1 -0
  106. package/lib/collection/components/duet-action-button/duet-action-button.js +2 -2
  107. package/lib/collection/components/duet-alert/duet-alert.js +1 -1
  108. package/lib/collection/components/duet-badge/duet-badge.js +2 -2
  109. package/lib/collection/components/duet-banner/duet-banner.css +12 -0
  110. package/lib/collection/components/duet-banner/duet-banner.js +51 -7
  111. package/lib/collection/components/duet-breadcrumbs/duet-breadcrumb.js +4 -4
  112. package/lib/collection/components/duet-breadcrumbs/duet-breadcrumbs.js +2 -2
  113. package/lib/collection/components/duet-button/duet-button.js +8 -8
  114. package/lib/collection/components/duet-callout/duet-callout.js +2 -2
  115. package/lib/collection/components/duet-caption/duet-caption.js +1 -1
  116. package/lib/collection/components/duet-card/duet-card.css +3 -0
  117. package/lib/collection/components/duet-card/duet-card.js +63 -7
  118. package/lib/collection/components/duet-checkbox/duet-checkbox.js +3 -3
  119. package/lib/collection/components/duet-chip/duet-chip.js +53 -17
  120. package/lib/collection/components/duet-choice/duet-checkmark.js +2 -2
  121. package/lib/collection/components/duet-choice/duet-choice.js +3 -3
  122. package/lib/collection/components/duet-choice-group/duet-choice-group.js +2 -2
  123. package/lib/collection/components/duet-collapsible/duet-collapsible.js +3 -3
  124. package/lib/collection/components/duet-combobox/duet-combobox.js +4 -16
  125. package/lib/collection/components/duet-contact-card/duet-contact-card.css +3 -0
  126. package/lib/collection/components/duet-contact-card/duet-contact-card.js +58 -2
  127. package/lib/collection/components/duet-cookie-consent/duet-cookie-consent.js +1 -1
  128. package/lib/collection/components/duet-date-picker/date-picker-month.js +4 -2
  129. package/lib/collection/components/duet-date-picker/date-utils.js +7 -0
  130. package/lib/collection/components/duet-date-picker/disallowed-days.js +23 -0
  131. package/lib/collection/components/duet-date-picker/duet-date-picker.js +100 -10
  132. package/lib/collection/components/duet-date-picker/finnish-bank-holidays.js +66 -0
  133. package/lib/collection/components/duet-divider/duet-divider.js +1 -1
  134. package/lib/collection/components/duet-editable-table/duet-editable-table.js +5 -5
  135. package/lib/collection/components/duet-empty-state/duet-empty-state.js +3 -3
  136. package/lib/collection/components/duet-fieldset/duet-fieldset.js +3 -3
  137. package/lib/collection/components/duet-file-chooser/duet-file-chooser.js +1 -1
  138. package/lib/collection/components/duet-footer/duet-footer.js +7 -7
  139. package/lib/collection/components/duet-grid/duet-grid.css +22 -0
  140. package/lib/collection/components/duet-grid/duet-grid.js +17 -8
  141. package/lib/collection/components/duet-grid-item/duet-grid-item.js +2 -2
  142. package/lib/collection/components/duet-header/duet-header.js +15 -15
  143. package/lib/collection/components/duet-heading/duet-heading.js +1 -1
  144. package/lib/collection/components/duet-hero/duet-hero.css +235 -144
  145. package/lib/collection/components/duet-hero/duet-hero.js +72 -21
  146. package/lib/collection/components/duet-icon/duet-icon.js +3 -3
  147. package/lib/collection/components/duet-indicator/duet-indicator.js +3 -3
  148. package/lib/collection/components/duet-input/duet-input.js +73 -20
  149. package/lib/collection/components/duet-label/duet-label.js +2 -2
  150. package/lib/collection/components/duet-layout/duet-layout.js +6 -6
  151. package/lib/collection/components/duet-link/duet-link.js +2 -2
  152. package/lib/collection/components/duet-list/duet-list.js +4 -4
  153. package/lib/collection/components/duet-list-item/duet-list-item.js +2 -2
  154. package/lib/collection/components/duet-logo/duet-logo.js +2 -2
  155. package/lib/collection/components/duet-menu-bar/duet-menu-bar.js +4 -4
  156. package/lib/collection/components/duet-menu-bar-button/duet-menu-bar-button.js +2 -2
  157. package/lib/collection/components/duet-menu-bar-dropdown/duet-menu-bar-dropdown.js +4 -4
  158. package/lib/collection/components/duet-menu-bar-dropdown-link/duet-menu-bar-dropdown-link.js +2 -2
  159. package/lib/collection/components/duet-menu-bar-item/duet-menu-bar-item.js +2 -2
  160. package/lib/collection/components/duet-menu-bar-link/duet-menu-bar-link.js +2 -2
  161. package/lib/collection/components/duet-modal/duet-modal.js +11 -11
  162. package/lib/collection/components/duet-multiselect/duet-multiselect.js +11 -11
  163. package/lib/collection/components/duet-nav/duet-nav.js +1 -1
  164. package/lib/collection/components/duet-notification/duet-notification.js +2 -2
  165. package/lib/collection/components/duet-notification-drawer/duet-notification-drawer.js +4 -4
  166. package/lib/collection/components/duet-number-input/duet-number-input.js +8 -8
  167. package/lib/collection/components/duet-overlay/duet-overlay.js +2 -2
  168. package/lib/collection/components/duet-page-heading/duet-page-heading.js +3 -3
  169. package/lib/collection/components/duet-pagination/duet-pagination.js +13 -13
  170. package/lib/collection/components/duet-panel/duet-panel.js +3 -3
  171. package/lib/collection/components/duet-paragraph/duet-paragraph.js +5 -5
  172. package/lib/collection/components/duet-phone-input/duet-phone-input.js +30 -5
  173. package/lib/collection/components/duet-popup-menu/duet-popup-menu.js +1 -1
  174. package/lib/collection/components/duet-popup-menu-item/duet-popup-menu-item.js +4 -4
  175. package/lib/collection/components/duet-promo-card/duet-promo-card.css +4 -0
  176. package/lib/collection/components/duet-promo-card/duet-promo-card.js +58 -2
  177. package/lib/collection/components/duet-radio/duet-radio.js +6 -6
  178. package/lib/collection/components/duet-radio-group/duet-radio-group.js +1 -1
  179. package/lib/collection/components/duet-range-slider/duet-range-slider.js +4 -4
  180. package/lib/collection/components/duet-range-stepper/duet-range-stepper.js +3 -3
  181. package/lib/collection/components/duet-scrollable/duet-scrollable.js +5 -5
  182. package/lib/collection/components/duet-section-layout/duet-section-layout.js +3 -3
  183. package/lib/collection/components/duet-select/duet-select.js +10 -10
  184. package/lib/collection/components/duet-shaped-image/duet-shaped-image.js +2 -2
  185. package/lib/collection/components/duet-share-chart/duet-share-chart.js +2 -2
  186. package/lib/collection/components/duet-share-chart-item/duet-share-chart-item.js +1 -1
  187. package/lib/collection/components/duet-show-more/duet-show-more.js +3 -3
  188. package/lib/collection/components/duet-slideout/duet-slideout.js +12 -6
  189. package/lib/collection/components/duet-slideout-lang/duet-slideout-lang.js +1 -1
  190. package/lib/collection/components/duet-slideout-link/duet-slideout-link.js +2 -2
  191. package/lib/collection/components/duet-slideout-panel/duet-slideout-panel.js +6 -6
  192. package/lib/collection/components/duet-slideout-panel-dropdown/duet-slideout-panel-dropdown.js +4 -4
  193. package/lib/collection/components/duet-spacer/duet-spacer.js +3 -3
  194. package/lib/collection/components/duet-spinner/duet-spinner.js +2 -2
  195. package/lib/collection/components/duet-status-icon/duet-status-icon.js +2 -2
  196. package/lib/collection/components/duet-step/duet-step.js +4 -4
  197. package/lib/collection/components/duet-stepper/duet-stepper.js +2 -2
  198. package/lib/collection/components/duet-submenu-bar/duet-submenu-bar.js +5 -5
  199. package/lib/collection/components/duet-submenu-bar-dropdown/duet-submenu-bar-dropdown.js +4 -4
  200. package/lib/collection/components/duet-submenu-bar-dropdown-link/duet-submenu-bar-dropdown-link.js +2 -2
  201. package/lib/collection/components/duet-submenu-bar-item/duet-submenu-bar-item.js +1 -1
  202. package/lib/collection/components/duet-submenu-bar-link/duet-submenu-bar-link.js +1 -1
  203. package/lib/collection/components/duet-tab/duet-tab.js +2 -2
  204. package/lib/collection/components/duet-tab-group/duet-tab-group.js +9 -9
  205. package/lib/collection/components/duet-table/duet-table-styles.js +5 -5
  206. package/lib/collection/components/duet-table/duet-table.js +2 -2
  207. package/lib/collection/components/duet-teaser/duet-teaser.css +127 -0
  208. package/lib/collection/components/duet-teaser/duet-teaser.js +462 -0
  209. package/lib/collection/components/duet-textarea/duet-textarea.js +7 -7
  210. package/lib/collection/components/duet-toggle/duet-toggle.js +4 -4
  211. package/lib/collection/components/duet-toolbar/duet-toolbar.js +2 -2
  212. package/lib/collection/components/duet-toolbar-dropdown/duet-toolbar-dropdown.js +4 -4
  213. package/lib/collection/components/duet-toolbar-dropdown-link/duet-toolbar-dropdown-link.js +2 -2
  214. package/lib/collection/components/duet-toolbar-item/duet-toolbar-item.js +3 -3
  215. package/lib/collection/components/duet-toolbar-link/duet-toolbar-link.js +2 -2
  216. package/lib/collection/components/duet-tooltip/duet-tooltip-button.js +3 -3
  217. package/lib/collection/components/duet-tooltip/duet-tooltip-popup.js +3 -3
  218. package/lib/collection/components/duet-tooltip/duet-tooltip.js +1 -1
  219. package/lib/collection/components/duet-tray/duet-tray.js +2 -2
  220. package/lib/collection/components/duet-upload/duet-upload.js +16 -16
  221. package/lib/collection/components/duet-upload-aria-status/duet-upload-aria-status.js +1 -1
  222. package/lib/collection/components/duet-upload-item/duet-upload-item.js +4 -4
  223. package/lib/collection/components/duet-visually-hidden/duet-visually-hidden.js +1 -1
  224. package/lib/collection/utils/keyboard-utils.js +1 -0
  225. package/lib/collection/utils/picture-utils.js +6 -1
  226. package/lib/duet/duet.esm.js +1 -1
  227. package/lib/duet/{p-61ec0e1c.entry.js → p-017873ec.entry.js} +1 -1
  228. package/lib/duet/{p-b1326cbb.entry.js → p-047af1e2.entry.js} +1 -1
  229. package/lib/duet/{p-516397ba.entry.js → p-058fcc72.entry.js} +1 -1
  230. package/lib/duet/p-05a6360b.entry.js +4 -0
  231. package/lib/duet/p-05b5ef84.entry.js +4 -0
  232. package/lib/duet/{p-6ef683d5.entry.js → p-07d43c60.entry.js} +1 -1
  233. package/lib/duet/{p-52beb436.entry.js → p-0ab559fb.entry.js} +1 -1
  234. package/lib/duet/{p-fe829b53.entry.js → p-0acf9bcf.entry.js} +1 -1
  235. package/lib/duet/{p-d3baa815.entry.js → p-0c42cc61.entry.js} +1 -1
  236. package/lib/duet/{p-443af533.entry.js → p-0df7094e.entry.js} +1 -1
  237. package/lib/duet/p-10baba94.entry.js +4 -0
  238. package/lib/duet/{p-30108edc.entry.js → p-1358a396.entry.js} +1 -1
  239. package/lib/duet/{p-70961edb.entry.js → p-1498e4a8.entry.js} +1 -1
  240. package/lib/duet/p-16d5dd2c.entry.js +4 -0
  241. package/lib/duet/p-1ec31f22.entry.js +4 -0
  242. package/lib/duet/{p-d6f0afa5.entry.js → p-2013545d.entry.js} +1 -1
  243. package/lib/duet/p-2265c46a.entry.js +4 -0
  244. package/lib/duet/{p-f040706c.entry.js → p-2394b3cd.entry.js} +1 -1
  245. package/lib/duet/{p-d779fe42.entry.js → p-2b17c517.entry.js} +1 -1
  246. package/lib/duet/{p-c54be349.entry.js → p-2f0f3a4a.entry.js} +1 -1
  247. package/lib/duet/{p-a9104184.entry.js → p-3ce04abc.entry.js} +1 -1
  248. package/lib/duet/{p-dedf6a32.entry.js → p-420df0aa.entry.js} +1 -1
  249. package/lib/duet/{p-c216e746.entry.js → p-430fad4e.entry.js} +1 -1
  250. package/lib/duet/p-453001ea.entry.js +4 -0
  251. package/lib/duet/{p-fa13ffe9.entry.js → p-4695398d.entry.js} +1 -1
  252. package/lib/duet/p-4bc7198d.entry.js +4 -0
  253. package/lib/duet/p-4e028274.entry.js +4 -0
  254. package/lib/duet/{p-8b0dfbd7.entry.js → p-5be103d0.entry.js} +1 -1
  255. package/lib/duet/{p-407f7f03.entry.js → p-5e5b6dc7.entry.js} +1 -1
  256. package/lib/duet/{p-42ec7305.entry.js → p-5fc88879.entry.js} +1 -1
  257. package/lib/duet/{p-e08dce92.entry.js → p-6865e880.entry.js} +1 -1
  258. package/lib/duet/{p-cb6c4158.entry.js → p-68a9ffb5.entry.js} +1 -1
  259. package/lib/duet/{p-b747f6e9.entry.js → p-69bcb076.entry.js} +1 -1
  260. package/lib/duet/p-71da8fbe.entry.js +4 -0
  261. package/lib/duet/{p-20a8ef81.entry.js → p-76e2c659.entry.js} +1 -1
  262. package/lib/duet/{p-74aac967.entry.js → p-7f5387dd.entry.js} +1 -1
  263. package/lib/duet/{p-110c7572.entry.js → p-84ed366e.entry.js} +1 -1
  264. package/lib/duet/{p-a8876b3d.entry.js → p-868647de.entry.js} +1 -1
  265. package/lib/duet/{p-a483117e.entry.js → p-8ad4bb4c.entry.js} +1 -1
  266. package/lib/duet/{p-3690576a.entry.js → p-8b9ffff4.entry.js} +1 -1
  267. package/lib/duet/{p-461d4089.entry.js → p-8da66626.entry.js} +1 -1
  268. package/lib/duet/{p-9ae7aaef.entry.js → p-8ea85c31.entry.js} +1 -1
  269. package/lib/duet/p-940a87e7.entry.js +4 -0
  270. package/lib/duet/{p-268b3066.entry.js → p-99550717.entry.js} +1 -1
  271. package/lib/duet/{p-8ace1eb4.entry.js → p-9987420d.entry.js} +1 -1
  272. package/lib/duet/{p-833802f9.entry.js → p-9d41df85.entry.js} +1 -1
  273. package/lib/duet/{p-3f7afd87.entry.js → p-9dee0205.entry.js} +1 -1
  274. package/lib/duet/{p-CFqvB5PA.js → p-B0XOGsB6.js} +1 -1
  275. package/lib/duet/p-B44ykle6.js +4 -0
  276. package/lib/duet/{p-R3pTP2Oy.js → p-B5SMAn1G.js} +1 -1
  277. package/lib/duet/p-BAiGBGTO.js +4 -0
  278. package/lib/duet/p-BWz_ChlU.js +4 -0
  279. package/lib/duet/p-BaefVzkx.js +4 -0
  280. package/lib/duet/{p-B8-N_qjs.js → p-Bnup2-sN.js} +1 -1
  281. package/lib/duet/p-C6rGA5IU.js +4 -0
  282. package/lib/duet/p-D4MpGrUR.js +5 -0
  283. package/lib/duet/p-DSNAI2Lx.js +4 -0
  284. package/lib/duet/{p-D2ly4TZR.js → p-DYmL1tSl.js} +1 -1
  285. package/lib/duet/{p-C5Yfx2kd.js → p-DtprEjjN.js} +1 -1
  286. package/lib/duet/{p-38973524.entry.js → p-a2106abd.entry.js} +1 -1
  287. package/lib/duet/p-a2a2f775.entry.js +4 -0
  288. package/lib/duet/{p-3277233e.entry.js → p-a2f7ef35.entry.js} +1 -1
  289. package/lib/duet/{p-829db926.entry.js → p-a62e6d8d.entry.js} +1 -1
  290. package/lib/duet/{p-40fa7371.entry.js → p-a6dc8c7d.entry.js} +1 -1
  291. package/lib/duet/{p-02d8e844.entry.js → p-a944ffff.entry.js} +1 -1
  292. package/lib/duet/{p-4b7f1244.entry.js → p-aebcf484.entry.js} +1 -1
  293. package/lib/duet/{p-bdbf0fae.entry.js → p-b2f0905a.entry.js} +1 -1
  294. package/lib/duet/p-b3a7ef62.entry.js +4 -0
  295. package/lib/duet/{p-70612314.entry.js → p-b4a1c719.entry.js} +1 -1
  296. package/lib/duet/p-b5204ec2.entry.js +4 -0
  297. package/lib/duet/{p-8012c7bc.entry.js → p-b58cfa18.entry.js} +1 -1
  298. package/lib/duet/{p-2dd7d75e.entry.js → p-b69946d4.entry.js} +1 -1
  299. package/lib/duet/{p-317e81f3.entry.js → p-b7351bfd.entry.js} +1 -1
  300. package/lib/duet/{p-3b2fba0f.entry.js → p-b7bb7472.entry.js} +1 -1
  301. package/lib/duet/{p-d3b5c997.entry.js → p-b9e97305.entry.js} +1 -1
  302. package/lib/duet/p-bb7fa0cf.entry.js +4 -0
  303. package/lib/duet/p-bef7eed7.entry.js +4 -0
  304. package/lib/duet/p-bffae8f6.entry.js +4 -0
  305. package/lib/duet/{p-c1afac0d.entry.js → p-c26e2123.entry.js} +1 -1
  306. package/lib/duet/{p-e7f2359a.entry.js → p-c49a72ad.entry.js} +1 -1
  307. package/lib/duet/{p-1da7703d.entry.js → p-c5c63d0f.entry.js} +1 -1
  308. package/lib/duet/{p-43e076b5.entry.js → p-c9a12663.entry.js} +1 -1
  309. package/lib/duet/{p-a5177d32.entry.js → p-ccaf5c28.entry.js} +1 -1
  310. package/lib/duet/{p-7fd39204.entry.js → p-d78923f9.entry.js} +1 -1
  311. package/lib/duet/p-d8383f1a.entry.js +4 -0
  312. package/lib/duet/{p-3f35fce3.entry.js → p-e3d91f53.entry.js} +1 -1
  313. package/lib/duet/p-e78af675.entry.js +4 -0
  314. package/lib/duet/{p-9e1a59d1.entry.js → p-e9a7215b.entry.js} +1 -1
  315. package/lib/duet/p-ebe55a34.entry.js +4 -0
  316. package/lib/duet/{p-efa4eecc.entry.js → p-ef340dc6.entry.js} +1 -1
  317. package/lib/duet/{p-317a1fc0.entry.js → p-f17438c7.entry.js} +1 -1
  318. package/lib/duet/{p-7353ee4c.entry.js → p-f264879d.entry.js} +1 -1
  319. package/lib/duet/p-f61ebeb1.entry.js +4 -0
  320. package/lib/duet/p-f647f09e.entry.js +4 -0
  321. package/lib/duet/p-f89da74c.entry.js +4 -0
  322. package/lib/duet/{p-2f8a47e2.entry.js → p-f959ca52.entry.js} +1 -1
  323. package/lib/duet/{p-19863cdf.entry.js → p-fb0f6212.entry.js} +1 -1
  324. package/lib/duet/p-fb59f80d.entry.js +4 -0
  325. package/lib/duet/{p-7eea47d5.entry.js → p-feae1702.entry.js} +1 -1
  326. package/lib/duet/p-kkZE1C6Z.js +4 -0
  327. package/lib/esm/{a11y-utils-ChN5Nhxh.js → a11y-utils-DZqe1lDK.js} +1 -1
  328. package/lib/esm/{app-globals-4kCk2rkO.js → app-globals-Byl9AdI1.js} +1 -1
  329. package/lib/esm/duet-action-button.entry.js +6 -6
  330. package/lib/esm/duet-alert.entry.js +4 -4
  331. package/lib/esm/duet-badge.entry.js +7 -7
  332. package/lib/esm/duet-banner.entry.js +17 -18
  333. package/lib/esm/duet-breadcrumb.entry.js +7 -7
  334. package/lib/esm/duet-breadcrumbs.entry.js +7 -7
  335. package/lib/esm/duet-button_2.entry.js +8 -8
  336. package/lib/esm/duet-callout.entry.js +5 -5
  337. package/lib/esm/duet-caption_4.entry.js +11 -11
  338. package/lib/esm/duet-card.entry.js +23 -11
  339. package/lib/esm/duet-checkbox.entry.js +3 -3
  340. package/lib/esm/duet-checkmark.entry.js +4 -4
  341. package/lib/esm/duet-chip.entry.js +28 -12
  342. package/lib/esm/duet-choice_2.entry.js +7 -7
  343. package/lib/esm/duet-collapsible.entry.js +4 -4
  344. package/lib/esm/duet-combobox.entry.js +7 -17
  345. package/lib/esm/duet-contact-card.entry.js +18 -7
  346. package/lib/esm/duet-cookie-consent.entry.js +3 -3
  347. package/lib/esm/duet-date-picker.entry.js +127 -14
  348. package/lib/esm/duet-divider_2.entry.js +5 -5
  349. package/lib/esm/duet-editable-table_3.entry.js +15 -15
  350. package/lib/esm/duet-empty-state.entry.js +2 -2
  351. package/lib/esm/duet-fieldset.entry.js +6 -6
  352. package/lib/esm/duet-file-chooser.entry.js +2 -2
  353. package/lib/esm/duet-footer.entry.js +5 -5
  354. package/lib/esm/duet-grid_2.entry.js +12 -8
  355. package/lib/esm/duet-header_2.entry.js +7 -7
  356. package/lib/esm/duet-hero.entry.js +27 -21
  357. package/lib/esm/duet-icon.entry.js +7 -7
  358. package/lib/esm/duet-indicator.entry.js +5 -5
  359. package/lib/esm/duet-input_2.entry.js +70 -18
  360. package/lib/esm/duet-layout.entry.js +7 -7
  361. package/lib/esm/duet-list_2.entry.js +5 -5
  362. package/lib/esm/duet-menu-bar-button.entry.js +4 -4
  363. package/lib/esm/duet-menu-bar-dropdown-link.entry.js +5 -5
  364. package/lib/esm/duet-menu-bar-dropdown.entry.js +7 -7
  365. package/lib/esm/duet-menu-bar-item.entry.js +7 -7
  366. package/lib/esm/duet-menu-bar-link.entry.js +4 -4
  367. package/lib/esm/duet-menu-bar.entry.js +6 -6
  368. package/lib/esm/duet-modal.entry.js +15 -15
  369. package/lib/esm/duet-multiselect.entry.js +11 -11
  370. package/lib/esm/duet-nav.entry.js +3 -3
  371. package/lib/esm/duet-notification_2.entry.js +10 -10
  372. package/lib/esm/duet-number-input.entry.js +9 -9
  373. package/lib/esm/duet-overlay.entry.js +3 -3
  374. package/lib/esm/duet-page-heading.entry.js +6 -6
  375. package/lib/esm/duet-pagination_2.entry.js +19 -19
  376. package/lib/esm/duet-panel.entry.js +4 -4
  377. package/lib/esm/duet-phone-input.entry.js +11 -6
  378. package/lib/esm/duet-popup-menu_2.entry.js +10 -10
  379. package/lib/esm/duet-progress.entry.js +3 -3
  380. package/lib/esm/duet-promo-card.entry.js +20 -8
  381. package/lib/esm/duet-radio_2.entry.js +7 -7
  382. package/lib/esm/duet-range-slider.entry.js +8 -8
  383. package/lib/esm/duet-scrollable_3.entry.js +18 -18
  384. package/lib/esm/duet-section-layout.entry.js +4 -4
  385. package/lib/esm/duet-select.entry.js +9 -9
  386. package/lib/esm/duet-shaped-image.entry.js +4 -4
  387. package/lib/esm/duet-share-chart-item.entry.js +2 -2
  388. package/lib/esm/duet-share-chart.entry.js +8 -8
  389. package/lib/esm/duet-show-more.entry.js +6 -6
  390. package/lib/esm/duet-slideout-lang.entry.js +4 -4
  391. package/lib/esm/duet-slideout-link.entry.js +7 -7
  392. package/lib/esm/duet-slideout-panel-dropdown.entry.js +6 -6
  393. package/lib/esm/duet-slideout-panel.entry.js +13 -13
  394. package/lib/esm/duet-slideout.entry.js +20 -14
  395. package/lib/esm/duet-status-icon.entry.js +3 -3
  396. package/lib/esm/duet-step_2.entry.js +7 -7
  397. package/lib/esm/duet-submenu-bar-dropdown-link.entry.js +5 -5
  398. package/lib/esm/duet-submenu-bar-dropdown.entry.js +7 -7
  399. package/lib/esm/duet-submenu-bar-item.entry.js +7 -7
  400. package/lib/esm/duet-submenu-bar-link.entry.js +4 -4
  401. package/lib/esm/duet-submenu-bar.entry.js +7 -7
  402. package/lib/esm/duet-teaser.entry.js +108 -0
  403. package/lib/esm/duet-textarea.entry.js +8 -8
  404. package/lib/esm/duet-toggle.entry.js +9 -9
  405. package/lib/esm/duet-toolbar-dropdown-link.entry.js +5 -5
  406. package/lib/esm/duet-toolbar-dropdown.entry.js +7 -7
  407. package/lib/esm/duet-toolbar-item.entry.js +8 -8
  408. package/lib/esm/duet-toolbar-link.entry.js +4 -4
  409. package/lib/esm/duet-toolbar.entry.js +4 -4
  410. package/lib/esm/duet-tooltip-button_2.entry.js +10 -10
  411. package/lib/esm/duet-tooltip.entry.js +5 -5
  412. package/lib/esm/duet-tray.entry.js +7 -7
  413. package/lib/esm/duet-upload-aria-status.entry.js +2 -2
  414. package/lib/esm/duet-upload-item.entry.js +6 -6
  415. package/lib/esm/duet-visually-hidden.entry.js +2 -2
  416. package/lib/esm/duet.js +4 -4
  417. package/lib/esm/{errorcodes.utils-DuFCu_27.js → errorcodes.utils-KA3z1KuW.js} +1 -1
  418. package/lib/esm/{focus-utils-CFswdkeD.js → focus-utils-id9x3opi.js} +1 -1
  419. package/lib/esm/{index-B2cboDWM.js → index-D4MpGrUR.js} +13 -9
  420. package/lib/esm/{keyboard-utils-Db8rvjPI.js → keyboard-utils-BaefVzkx.js} +2 -1
  421. package/lib/esm/{label-CJxIWUOT.js → label-Caev3m-F.js} +1 -1
  422. package/lib/esm/{language-utils-C4M4ASkT.js → language-utils-DTyUbpD-.js} +1 -1
  423. package/lib/esm/loader.js +4 -4
  424. package/lib/esm/picture-utils-4PMNZDR2.js +18 -0
  425. package/lib/esm/{slot-utils--sNK1DNn.js → slot-utils-BhEk4zKY.js} +1 -1
  426. package/lib/esm/{themeable-component-BBi3552X.js → themeable-component-B_d7Klmd.js} +1 -1
  427. package/lib/esm/{token-utils-B0KAgyj_.js → token-utils-BILzD7LX.js} +1 -1
  428. package/lib/esm/{tokens.module-DEzE2U5T.js → tokens.module-kkZE1C6Z.js} +1 -1
  429. package/lib/types/components/duet-banner/duet-banner.d.ts +10 -1
  430. package/lib/types/components/duet-button/duet-button.d.ts +1 -1
  431. package/lib/types/components/duet-card/duet-card.d.ts +10 -0
  432. package/lib/types/components/duet-chip/duet-chip.d.ts +15 -8
  433. package/lib/types/components/duet-combobox/duet-combobox.d.ts +0 -1
  434. package/lib/types/components/duet-contact-card/duet-contact-card.d.ts +10 -0
  435. package/lib/types/components/duet-date-picker/date-picker-month.d.ts +3 -0
  436. package/lib/types/components/duet-date-picker/date-utils.d.ts +4 -0
  437. package/lib/types/components/duet-date-picker/disallowed-days.d.ts +9 -0
  438. package/lib/types/components/duet-date-picker/duet-date-picker.d.ts +14 -0
  439. package/lib/types/components/duet-date-picker/finnish-bank-holidays.d.ts +11 -0
  440. package/lib/types/components/duet-grid/duet-grid.d.ts +2 -1
  441. package/lib/types/components/duet-hero/duet-hero.d.ts +10 -0
  442. package/lib/types/components/duet-input/duet-input.d.ts +11 -0
  443. package/lib/types/components/duet-phone-input/duet-phone-input.d.ts +5 -0
  444. package/lib/types/components/duet-promo-card/duet-promo-card.d.ts +11 -0
  445. package/lib/types/components/duet-teaser/duet-teaser.d.ts +93 -0
  446. package/lib/types/components.d.ts +291 -14
  447. package/lib/types/utils/keyboard-utils.d.ts +1 -0
  448. package/lib/types/utils/picture-utils.d.ts +4 -0
  449. package/package.json +5 -5
  450. package/lib/duet/p-06297bd8.entry.js +0 -4
  451. package/lib/duet/p-0c04f9f5.entry.js +0 -4
  452. package/lib/duet/p-18a8ea12.entry.js +0 -4
  453. package/lib/duet/p-1bca9931.entry.js +0 -4
  454. package/lib/duet/p-3f3c6e64.entry.js +0 -4
  455. package/lib/duet/p-4af6a8ed.entry.js +0 -4
  456. package/lib/duet/p-5284c707.entry.js +0 -4
  457. package/lib/duet/p-5c9f443c.entry.js +0 -4
  458. package/lib/duet/p-5f5f72d4.entry.js +0 -4
  459. package/lib/duet/p-5lFzA17H.js +0 -4
  460. package/lib/duet/p-6b469225.entry.js +0 -4
  461. package/lib/duet/p-7294c37d.entry.js +0 -4
  462. package/lib/duet/p-72b504ef.entry.js +0 -4
  463. package/lib/duet/p-734249e0.entry.js +0 -4
  464. package/lib/duet/p-7c08fd87.entry.js +0 -4
  465. package/lib/duet/p-83238bf3.entry.js +0 -4
  466. package/lib/duet/p-86ffd3cb.entry.js +0 -4
  467. package/lib/duet/p-871620d3.entry.js +0 -4
  468. package/lib/duet/p-93ff8fe4.entry.js +0 -4
  469. package/lib/duet/p-9c9811ba.entry.js +0 -4
  470. package/lib/duet/p-B2cboDWM.js +0 -5
  471. package/lib/duet/p-BzYmwX5_.js +0 -4
  472. package/lib/duet/p-Cg4m_WHe.js +0 -4
  473. package/lib/duet/p-DEzE2U5T.js +0 -4
  474. package/lib/duet/p-Db8rvjPI.js +0 -4
  475. package/lib/duet/p-a068c086.entry.js +0 -4
  476. package/lib/duet/p-c2026c6b.entry.js +0 -4
  477. package/lib/duet/p-cbcee3e2.entry.js +0 -4
  478. package/lib/duet/p-d5f90dbc.entry.js +0 -4
  479. package/lib/duet/p-s8EL6NG5.js +0 -4
@@ -6,6 +6,7 @@ import { h } from "@stencil/core";
6
6
  import { DuetStringsExternalDefaults } from "../../common-strings";
7
7
  import { inheritGlobalTheme } from "../../common/themeable-component";
8
8
  import { connectLanguageChangeObserver, disconnectLanguageChangeObserver, getLanguage, getLocaleString, } from "../../utils/language-utils";
9
+ import { DuetPicture } from "../../utils/picture-utils";
9
10
  import { checkNamedSlotElement, getElementsFromNamedSlot, hasSlot } from "../../utils/slot-utils";
10
11
  import { parsePossibleJSON } from "../../utils/string-utils";
11
12
  /**
@@ -129,6 +130,11 @@ export class DuetHero {
129
130
  * Image position.
130
131
  */
131
132
  this.imagePosition = "auto";
133
+ /**
134
+ * Make the image load with higher or lower priority. Value "high" sets the img's attributes fetchpriority and loading to
135
+ * "high" and "eager", while value "low" sets those attributes to "low" and "lazy"
136
+ */
137
+ this.imagePriority = "high";
132
138
  /**
133
139
  * Style variation of the hero area.
134
140
  */
@@ -237,17 +243,17 @@ export class DuetHero {
237
243
  const campaignOrSection = this.variation === "campaign" || this.variation === "section";
238
244
  const imageSizeIsCover = this.imageSize === "cover";
239
245
  const imagePositionIsCenter = this.imagePosition === "center";
240
- const styles = {
241
- backgroundImage: `url(${this.image})`,
242
- backgroundSize: imageSizeIsCover ? "cover" : null,
243
- backgroundPosition: imagePositionIsCenter ? "center" : null,
244
- };
245
- const bgImgA11yAttrs = this.image && this.imageAlt
246
- ? {
247
- role: "img",
248
- ["aria-label"]: this.imageAlt,
249
- }
250
- : {};
246
+ const imageClass = `${imageSizeIsCover ? "cover" : ""} ${imagePositionIsCenter ? "center" : ""}`.trim();
247
+ const getPictureSource = (className) => ({
248
+ img: {
249
+ src: this.image,
250
+ alt: this.imageAlt || "",
251
+ loading: this.imagePriority === "low" ? "lazy" : "eager",
252
+ fetchpriority: this.imagePriority,
253
+ class: className || "",
254
+ },
255
+ sources: parsePossibleJSON(this.sources),
256
+ });
251
257
  const buttonStyles = {
252
258
  transform: "translateX(-8px)",
253
259
  };
@@ -284,7 +290,7 @@ export class DuetHero {
284
290
  outlineColor = "color-primary-turva";
285
291
  }
286
292
  }
287
- return (h("div", { key: 'c9ddbcc16c2911a20e497cd8aa384fa5c07d33aa', role: "region", class: {
293
+ return (h("div", { key: 'dfdf7ff48804ea8afc843f2901dae041929c9266', role: "region", class: {
288
294
  "duet-hero": true,
289
295
  "duet-theme-turva": this.theme === "turva",
290
296
  "duet-has-category-icon": !!this.categoryIcon,
@@ -302,17 +308,17 @@ export class DuetHero {
302
308
  "duet-hero-text-center": this.variation !== "product" && ((this.textCenter && !this.leftAlign) || campaignOrSection),
303
309
  "duet-hero-left-align": this.variation === "product" || (this.leftAlign && !campaignOrSection),
304
310
  "duet-hero-narrow": this.layout === "narrow",
305
- }, part: "duet-hero" }, campaignOrSection && this.image && (h("div", { key: 'a11039ca72275168553d2bba06cd909229dc1925', class: "background-area" }, h("div", { key: 'a21ad76654ac39c2fa21795f1cca235dc92e6404', class: "background-container" }, h("div", { key: '12d3583034b68b6fb747c749c0449146c40cb471', class: "background" }, h("img", { key: '8961eadf230127f3783efad4c48be759c4657e2a', class: `${imageSizeIsCover ? "cover" : ""} ${imagePositionIsCenter ? "center" : ""}`, src: this.image, alt: this.imageAlt || "", role: this.imageAlt ? null : "presentation" })), h("div", { key: 'bdfeab66795ec39e3f0383d9c2ef713733eb1a87', class: "brand-shape" })))), this.variation === "product" && this.image && (h("div", { key: 'f08f6d3f621e7dac9a46f1942d87a6ec8cc8afa1', class: { "background-area": true, [this.layout]: true } }, h("div", { key: 'dcb0f245be411d836d24d7adb5c98b82841d6038', class: { "background-container": true, [this.layout]: true } }, h("div", { key: 'a5c5eccc8dcf20d10c7be435873c815eaf0713e2', class: { background: true, [this.layout]: true } }, h("div", { key: '358763fb7ceea2e54bb6d5249a3b4281de220758', class: { "background-mask": true, [this.layout]: true } }), this.theme !== "turva" && h("div", { key: 'a11b4ea782b4e6887ec4d6573188adeec90577b1', class: { "brand-shape": true, [this.layout]: true } }), h("div", { key: '7afb89a0beb1d7675c33fcc831880c8126f1299a', class: { "brand-shaped-image": true, [this.layout]: true } }, h("div", { key: 'd9f4649e3eb88d062cbde9eb311f195357f67d5d', class: { "brand-shaped-image-wrapper": true, [this.layout]: true } }, h("div", Object.assign({ key: 'e75eeac505d3b021f0a7de2c195b9846b77c7c17', class: { "brand-shaped-image-bg": true, [this.layout]: true }, style: styles }, bgImgA11yAttrs)))), this.categoryIcon && (h("div", { key: '3c7d8d8ef1ccb2a63c0cde7ce064adb3ac49ba9a', class: { "brand-shaped-icon": true, [this.layout]: true } }, h("duet-icon", { key: '23ff81f55a6f02a5fee73f17ea54a96cee164b85', class: { [this.layout]: true }, background: "none", name: this.categoryIcon, margin: "none", size: "auto", responsive: false }))))))), this.variation === "content" && this.image && (h("div", { key: 'd1d02c374a68c1b68fb2f9d848e5a7c357b5a220', class: "background-area" }, h("div", { key: '9f53455c7fca9008387d26b0dfc89c104076c248', class: "background" }, h("div", { key: '80d50fdf1c366ac730e88fff3d59f10f725f66bb', class: "background-mask" }), this.theme !== "turva" && h("div", { key: 'b079b624311717908bb1e1c37a0c56ad560ed44e', class: "brand-shape" }), h("div", { key: '247c5196610c63556bf2f66e2d8334d9cce8bdfa', class: "brand-shaped-image" }, h("div", { key: 'a83da29f05f36125276f4e74096648b30a8e9898', class: "brand-shaped-image-wrapper" }, h("div", Object.assign({ key: '150f6775a489981cbeaa8aa03f188f165d48aee0', class: "brand-shaped-image-bg", style: styles }, bgImgA11yAttrs))))))), h("div", { key: '558787b0fd8e59329b907d7dda223526d14b632d', class: { "duet-hero-wrapper": true, [this.layout]: true } }, this.image && this.variation === "image" && (h("div", { key: '12abfe5fb1240e186528ecbc2119c0797480e77f', class: "duet-hero-image-mask" }, h("div", { key: '0592878e99fd51f01ce16c2bf2ac1ae44c4636a1', class: "duet-hero-image-wrapper" }, h("div", Object.assign({ key: 'd7a6838d0f589bb56ea831375e8a6237fe3c4bf2', class: "duet-hero-image", style: styles }, bgImgA11yAttrs))))), (this.variation === "gray" || this.variation === "light" || this.variation === "minimal") &&
306
- this.processedBack && (h("div", { key: 'dbef4d7459000d59a63deb5834086f5e607f8a0a', class: "duet-hero-back" }, h("duet-button", { key: '19481b475ec5fa1a83ee3d94d6170e823d80e5ae', style: buttonStyles, variation: "plain", icon: "action-arrow-left-small", theme: this.theme, iconSize: "small", color: buttonColor, padding: "none", margin: "none", fixed: true, url: this.processedBack.href, identifier: this.processedBack.id, onClick: event => this.handleClick(event, {
311
+ }, part: "duet-hero" }, campaignOrSection && this.image && (h("div", { key: '38e648e7447b8db00a773ff4025d68500401f7bc', class: "background-area" }, h("div", { key: '803534bf55dc7737cd41ec1d75fbed052334a19a', class: "background-container" }, h("div", { key: '27d0577a3993d7eaa767812700ff290986535b20', class: "background" }, h(DuetPicture, Object.assign({ key: '6cc4a5648f7466ed44125cd22e35a6eeb725b18a' }, getPictureSource(imageClass)))), h("div", { key: '76a95c713cd90761ea2d670389183e2c04a97a80', class: "brand-shape" })))), this.variation === "product" && this.image && (h("div", { key: 'c436973c44f7d497a70a96a51eb0f96be6eda95a', class: { "background-area": true, [this.layout]: true } }, h("div", { key: 'e5a17290d952644ba521a4b3976387456f650cd4', class: { "background-container": true, [this.layout]: true } }, h("div", { key: '8fdf828e65411a86393e096d8f3b6415076d97e0', class: { background: true, [this.layout]: true } }, h("div", { key: '0ada9a2b55d78b2774063d099cb03a8e09693584', class: { "background-mask": true, [this.layout]: true } }), this.theme !== "turva" && h("div", { key: 'b24d91804b31920da022285d0565667c8e92997e', class: { "brand-shape": true, [this.layout]: true } }), h("div", { key: '226619d3d283b31fa7e8caadaf49473a170abb3a', class: { "brand-shaped-image": true, [this.layout]: true } }, h("div", { key: '0a0415ca70e98b277bf151f28e1f4f1639338fa6', class: { "brand-shaped-image-wrapper": true, [this.layout]: true } }, h("div", { key: 'c866eb1fa36ab6cc43e8839669069046c2faae60', class: { "brand-shaped-image-bg": true, [this.layout]: true } }, h(DuetPicture, Object.assign({ key: 'a98b41e51c70043f55128a19718911f321b7527f' }, getPictureSource()))))), this.categoryIcon && (h("div", { key: '0d3b0c0428a32d2df977a6ac63be04ed6a7f72c6', class: { "brand-shaped-icon": true, [this.layout]: true } }, h("duet-icon", { key: '7af6dee3ca69df4b1d8e87830636ec18ad3a40b7', class: { [this.layout]: true }, background: "none", name: this.categoryIcon, margin: "none", size: "auto", responsive: false }))))))), this.variation === "content" && this.image && (h("div", { key: '20bd7ce2aca1d5062f0f0e1f4889a97ec308b1d9', class: "background-area" }, h("div", { key: '1847e876158decc257b4445501d1bb8e208ddb0e', class: "background" }, h("div", { key: '236489bc1fff1be4cf44d267dfbb5c3bcb119dad', class: "background-mask" }), this.theme !== "turva" && h("div", { key: '3c1e73a037c1ec3b129caaac2a689bf60ce62710', class: "brand-shape" }), h("div", { key: '9cfc2c3b6f5022d863fd6c869ffda7e0df51e013', class: "brand-shaped-image" }, h("div", { key: '8471e4f399016fb37f5f5e46f8bab0865179c6a3', class: "brand-shaped-image-wrapper" }, h("div", { key: '68bfcd1b748c5f7d0b3661152a489707f12024ac', class: "brand-shaped-image-bg" }, h(DuetPicture, Object.assign({ key: '78a267d0198018669353675e01ad0ca70491b36f' }, getPictureSource())))))))), h("div", { key: '4ab0bf9e9dee5b6889db6cc396cd304eda1bd870', class: { "duet-hero-wrapper": true, [this.layout]: true } }, this.image && this.variation === "image" && (h("div", { key: '208c46264f1ea0ce04845324a68cf5848ad95535', class: "duet-hero-image-mask" }, h("div", { key: 'b95a0b0a8840c5835a4e9668bd9481fcd9bfa87b', class: "duet-hero-image-wrapper" }, h("div", { key: '04633cc8d3020b921c42551a5e065bc942540fcc', class: "duet-hero-image" }, h(DuetPicture, Object.assign({ key: '7415ca53535a1295d42eb2b29cc6dbe7a93a04ae' }, getPictureSource(imageClass))))))), (this.variation === "gray" || this.variation === "light" || this.variation === "minimal") &&
312
+ this.processedBack && (h("div", { key: '59cbdb9c4195074e03310b65a88b4bafd74f9916', class: "duet-hero-back" }, h("duet-button", { key: 'ce17a681e39b9ad5c21edec2472175919f68b02f', style: buttonStyles, variation: "plain", icon: "action-arrow-left-small", theme: this.theme, iconSize: "small", color: buttonColor, padding: "none", margin: "none", fixed: true, url: this.processedBack.href, identifier: this.processedBack.id, onClick: event => this.handleClick(event, {
307
313
  label: this.processedBack.label,
308
314
  href: this.processedBack.href,
309
315
  id: this.processedBack.id,
310
316
  analyticsId: this.processedBack.analyticsId,
311
- }) }, this.processedBack.label))), (this.variation === "gray" || this.variation === "minimal") && this.categoryIcon && (h("duet-icon", { key: 'f1afc26bae892d9ae01824cae17226859bcb2156', class: { "duet-hero-icon": true, "duet-hero-icon-has-heading": this.preHeading !== "" }, size: "x-large", background: this.categoryIconColor, name: this.categoryIcon })), h("div", { key: '8ce3263c60dc312e31098663adadec75d34c9e0e', class: { "duet-hero-text": true }, part: "duet-hero-text" }, (this.preHeading || this.hasPreHeadingSlot) && (h("duet-paragraph", { key: 'a9faf36bb7d72156356b527ef585f4db2f07885f', margin: "none", class: "duet-hero-pre", size: this.variation === "content" ? "small" : "medium", "aria-hidden": "true" }, this.preHeading ? (this.preHeading) : (h("span", null, h("slot", { name: "pre-heading" }))))), h("slot", { key: '10e35d0acadfbe28c7c3c9a5725190c00cc35214', name: "badge" }), (this.heading || this.hasHeadingSlot) && (h("duet-heading", { key: 'd289ee15b7e8ae4e821195252e132ba6dfd4bb13', theme: this.theme, level: this.hasHeadingSlotNative ? "div" : this.level, class: { "duet-hero-heading": true, "duet-hero-heading-has-pre": this.preHeading !== "" }, color: headingColor, visualLevel: headingVisualLevel, margin: campaignOrSection ? "none" : "auto", accessibleLabel: this.getAccessibleHeading() }, this.heading ? this.heading : h("slot", { name: "heading" }))), campaignOrSection && this.hasSubHeadingSlot && (h("duet-heading", { key: '66f747db21ef3d390d01c78ff7b05879a4d435c5', theme: this.theme, level: this.hasSubHeadingSlotNative ? "div" : this.subHeadingLevel, class: { "duet-hero-subheading": true }, color: this.theme === "turva" ? "secondary-turva" : "secondary", visualLevel: "h2" }, h("slot", { key: 'a61351c8a3463e0d7b3881d4ed2eb430a4d708f8', name: "subheading" }))), this.description && (h("duet-paragraph", { key: '5e17ebff3513457595a670b8b180ad4c900bb5ac', theme: this.theme, color: textColor, variation: "intro" }, this.description)), (this.variation === "gray" || this.variation === "minimal") && this.processedListItems && (h("duet-list", { key: '7cb299e23a2062bdf5a7831891b9a3590ad51ad5', theme: this.theme, "label-width": "30", breakpoint: "large", mobile: this.leftAlign ? undefined : "center" }, this.processedListItems.map(item => (h("duet-list-item", null, h("span", { slot: "label" }, item.label), h("span", { slot: "value" }, item.value)))))), this.buttonLabel && (h("duet-button", { key: '132f4b0f22736d84217d2ef92fb137bb37ae1bfa', url: this.buttonUrl, icon: this.icon, iconRight: this.iconRight, iconSize: this.iconSize, variation: buttonVariation, theme: this.theme, identifier: this.buttonId, onClick: event => this.handleClick(event, this.buttonData), fixed: true }, this.buttonLabel)), h("slot", { key: 'ba4d8449b00fe95aa8e9e2b4c0f43143e851c44f' })), (this.variation === "gray" || this.variation === "minimal") && this.processedActions && (h("div", { key: 'da7c7c2652fe88ee7a097e696e56c301d8d813b9', class: "duet-hero-links" }, this.processedActions.map(item => (h("a", { class: "duet-hero-link", href: item.href, id: item.id, target: item.external ? "_blank" : "_self", onClick: event => this.handleClick(event, item) }, h("div", { class: "duet-hero-action-icon" }, h("duet-icon", { size: "small", margin: "none", name: item.icon, color: "currentColor", outline: outlineColor })), h("span", null, item.label), item.external && h("duet-visually-hidden", null, ", ", this.accessibleLabelExternal), item.external && (h("div", { class: "duet-hero-action-arrow" }, h("duet-icon", { icon: newWindowIcon.svg, size: "xx-small", margin: "none", color: "currentColor" })))))))), this.image &&
317
+ }) }, this.processedBack.label))), (this.variation === "gray" || this.variation === "minimal") && this.categoryIcon && (h("duet-icon", { key: '191763dfcef22bcd3ccd7b8ac096ae6446de2d98', class: { "duet-hero-icon": true, "duet-hero-icon-has-heading": this.preHeading !== "" }, size: "x-large", background: this.categoryIconColor, name: this.categoryIcon })), h("div", { key: '7ee11a778839f281ce31673e60f4923ff223e3ac', class: { "duet-hero-text": true }, part: "duet-hero-text" }, (this.preHeading || this.hasPreHeadingSlot) && (h("duet-paragraph", { key: '7d7f43ba3e592cbad30f8f28000ff361209bf443', margin: "none", class: "duet-hero-pre", size: this.variation === "content" ? "small" : "medium", "aria-hidden": "true" }, this.preHeading ? (this.preHeading) : (h("span", null, h("slot", { name: "pre-heading" }))))), h("slot", { key: 'e73727e5aa7fad6aaaceabcf6f81c6572f0a15a9', name: "badge" }), (this.heading || this.hasHeadingSlot) && (h("duet-heading", { key: '5884aecc75704d8dccc6c709a6768ddd578c4dde', theme: this.theme, level: this.hasHeadingSlotNative ? "div" : this.level, class: { "duet-hero-heading": true, "duet-hero-heading-has-pre": this.preHeading !== "" }, color: headingColor, visualLevel: headingVisualLevel, margin: campaignOrSection ? "none" : "auto", accessibleLabel: this.getAccessibleHeading() }, this.heading ? this.heading : h("slot", { name: "heading" }))), campaignOrSection && this.hasSubHeadingSlot && (h("duet-heading", { key: '763778e5026dbfa90ef3e68f0f1b7d037043b88d', theme: this.theme, level: this.hasSubHeadingSlotNative ? "div" : this.subHeadingLevel, class: { "duet-hero-subheading": true }, color: this.theme === "turva" ? "secondary-turva" : "secondary", visualLevel: "h2" }, h("slot", { key: '9588038687bc9dfcb10a04b5e5cdaa6e3ef253de', name: "subheading" }))), this.description && (h("duet-paragraph", { key: 'f0d60545403dfcc453d79aa1bfdd5582b876ae49', theme: this.theme, color: textColor, variation: "intro" }, this.description)), (this.variation === "gray" || this.variation === "minimal") && this.processedListItems && (h("duet-list", { key: '7006a276c36ca7001df5c93d6fc3e792f8a07169', theme: this.theme, "label-width": "30", breakpoint: "large", mobile: this.leftAlign ? undefined : "center" }, this.processedListItems.map(item => (h("duet-list-item", null, h("span", { slot: "label" }, item.label), h("span", { slot: "value" }, item.value)))))), this.buttonLabel && (h("duet-button", { key: '2954e77b3dde7b49573c25f1566d5f820c1dea3b', url: this.buttonUrl, icon: this.icon, iconRight: this.iconRight, iconSize: this.iconSize, variation: buttonVariation, theme: this.theme, identifier: this.buttonId, onClick: event => this.handleClick(event, this.buttonData), fixed: true }, this.buttonLabel)), h("slot", { key: '87703efb26e4376a71a692aa444988dacbf45d68' })), (this.variation === "gray" || this.variation === "minimal") && this.processedActions && (h("div", { key: '92123389406d8b37e76d0305fb7a2e1d194ce1d4', class: "duet-hero-links" }, this.processedActions.map(item => (h("a", { class: "duet-hero-link", href: item.href, id: item.id, target: item.external ? "_blank" : "_self", onClick: event => this.handleClick(event, item) }, h("div", { class: "duet-hero-action-icon" }, h("duet-icon", { size: "small", margin: "none", name: item.icon, color: "currentColor", outline: outlineColor })), h("span", null, item.label), item.external && h("duet-visually-hidden", null, ", ", this.accessibleLabelExternal), item.external && (h("div", { class: "duet-hero-action-arrow" }, h("duet-icon", { icon: newWindowIcon.svg, size: "xx-small", margin: "none", color: "currentColor" })))))))), this.image &&
312
318
  this.variation !== "image" &&
313
319
  !campaignOrSection &&
314
320
  this.variation !== "product" &&
315
- this.variation !== "content" && h("div", Object.assign({ key: 'b02c3a2b4e9722c7fc64b62e708c2d69d668b5a7', class: "duet-hero-image", style: styles }, bgImgA11yAttrs)), h("slot", { key: 'a8869163ed1e35a8987e126305221199705f4a88', name: "bottom" }))));
321
+ this.variation !== "content" && (h("div", { key: 'cd09b6b83414a647857f014ddd08f9b49b4d122a', class: "duet-hero-image" }, h(DuetPicture, Object.assign({ key: '68b91f0d9db476f3aa31c63b2a04465705e61658' }, getPictureSource(imageClass))))), h("slot", { key: '8f23feb29e40591b85303a1864fb5736274b7596', name: "bottom" }))));
316
322
  }
317
323
  static get is() { return "duet-hero"; }
318
324
  static get encapsulation() { return "shadow"; }
@@ -502,7 +508,7 @@ export class DuetHero {
502
508
  "references": {
503
509
  "DuetHeroIconSize": {
504
510
  "location": "local",
505
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-hero/duet-hero.tsx",
511
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-hero/duet-hero.tsx",
506
512
  "id": "src/components/duet-hero/duet-hero.tsx::DuetHeroIconSize"
507
513
  }
508
514
  }
@@ -744,7 +750,7 @@ export class DuetHero {
744
750
  "references": {
745
751
  "DuetHeroButtonData": {
746
752
  "location": "local",
747
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-hero/duet-hero.tsx",
753
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-hero/duet-hero.tsx",
748
754
  "id": "src/components/duet-hero/duet-hero.tsx::DuetHeroButtonData"
749
755
  }
750
756
  }
@@ -877,6 +883,51 @@ export class DuetHero {
877
883
  "setter": false,
878
884
  "reflect": false
879
885
  },
886
+ "imagePriority": {
887
+ "type": "string",
888
+ "attribute": "image-priority",
889
+ "mutable": false,
890
+ "complexType": {
891
+ "original": "\"high\" | \"low\"",
892
+ "resolved": "\"high\" | \"low\"",
893
+ "references": {}
894
+ },
895
+ "required": false,
896
+ "optional": false,
897
+ "docs": {
898
+ "tags": [],
899
+ "text": "Make the image load with higher or lower priority. Value \"high\" sets the img's attributes fetchpriority and loading to\n\"high\" and \"eager\", while value \"low\" sets those attributes to \"low\" and \"lazy\""
900
+ },
901
+ "getter": false,
902
+ "setter": false,
903
+ "reflect": false,
904
+ "defaultValue": "\"high\""
905
+ },
906
+ "sources": {
907
+ "type": "string",
908
+ "attribute": "sources",
909
+ "mutable": false,
910
+ "complexType": {
911
+ "original": "DuetSource[] | string",
912
+ "resolved": "DuetSource[] | string",
913
+ "references": {
914
+ "DuetSource": {
915
+ "location": "import",
916
+ "path": "../../utils/picture-utils",
917
+ "id": "src/utils/picture-utils.tsx::DuetSource"
918
+ }
919
+ }
920
+ },
921
+ "required": false,
922
+ "optional": false,
923
+ "docs": {
924
+ "tags": [],
925
+ "text": "Array of sources for responsive images. Sources have the properties of <source> element."
926
+ },
927
+ "getter": false,
928
+ "setter": false,
929
+ "reflect": false
930
+ },
880
931
  "variation": {
881
932
  "type": "string",
882
933
  "attribute": "variation",
@@ -887,7 +938,7 @@ export class DuetHero {
887
938
  "references": {
888
939
  "DuetHeroVariation": {
889
940
  "location": "local",
890
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-hero/duet-hero.tsx",
941
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-hero/duet-hero.tsx",
891
942
  "id": "src/components/duet-hero/duet-hero.tsx::DuetHeroVariation"
892
943
  }
893
944
  }
@@ -1006,7 +1057,7 @@ export class DuetHero {
1006
1057
  "references": {
1007
1058
  "DuetHeroClickEvent": {
1008
1059
  "location": "local",
1009
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-hero/duet-hero.tsx",
1060
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-hero/duet-hero.tsx",
1010
1061
  "id": "src/components/duet-hero/duet-hero.tsx::DuetHeroClickEvent"
1011
1062
  }
1012
1063
  }
@@ -1027,7 +1078,7 @@ export class DuetHero {
1027
1078
  "references": {
1028
1079
  "DuetHeroAnalyticsEvent": {
1029
1080
  "location": "local",
1030
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-hero/duet-hero.tsx",
1081
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-hero/duet-hero.tsx",
1031
1082
  "id": "src/components/duet-hero/duet-hero.tsx::DuetHeroAnalyticsEvent"
1032
1083
  }
1033
1084
  }
@@ -144,11 +144,11 @@ export class DuetIcon {
144
144
  : {};
145
145
  const iconStyles = Object.assign({}, iconRotationStyles);
146
146
  const shapeStyle = this.shape === "brand-rotated" ? "duet-icon-shape-brand" : `duet-icon-shape-${this.shape}`;
147
- return (h(Host, { key: 'f6a74ccabd59055d22eec3654bde9c81fd4a9ce3', class: {
147
+ return (h(Host, { key: '4165c86903dae730023be910be36389c7151045d', class: {
148
148
  "duet-m-0": this.margin === "none",
149
149
  "duet-icon-has-outline": !!this.outline,
150
150
  "duet-icon-has-background": !!this.background,
151
- } }, h("span", { key: 'f2ea10e9ec8459d5a5995781e193c6d8df7fb1ef', "aria-hidden": "true", style: styles, class: {
151
+ } }, h("span", { key: '9efda9e15441290db9c499f59fc3f4feed86e5b2', "aria-hidden": "true", style: styles, class: {
152
152
  "duet-icon": true,
153
153
  "duet-theme-turva": this.theme === "turva",
154
154
  "duet-theme-default": this.theme === "default",
@@ -157,7 +157,7 @@ export class DuetIcon {
157
157
  [shapeStyle]: true,
158
158
  rotated: this.shape === "brand-rotated" && this.theme !== "turva",
159
159
  "duet-icon-not-responsive": !this.responsive,
160
- } }, h("span", { key: '3d93b31d1831fa77b71a5f574a38d838636c7757', "aria-hidden": "true", class: { "duet-icon-svg": true, rotated: this.shape === "brand-rotated" && this.theme !== "turva" }, "data-name": this.name, innerHTML: this.svgContent, style: iconStyles }))));
160
+ } }, h("span", { key: 'a59c6e8741e859747f51863e7677de1f95e71b29', "aria-hidden": "true", class: { "duet-icon-svg": true, rotated: this.shape === "brand-rotated" && this.theme !== "turva" }, "data-name": this.name, innerHTML: this.svgContent, style: iconStyles }))));
161
161
  }
162
162
  static get is() { return "duet-icon"; }
163
163
  static get encapsulation() { return "shadow"; }
@@ -45,11 +45,11 @@ export class DuetIndicator {
45
45
  inheritGlobalTheme(this);
46
46
  }
47
47
  render() {
48
- return (h(Host, { key: '6c412435545134515ed6bb4eb8f5e1ec8701dce7' }, h("span", { key: 'f7c0f6b5019c3d9abcd01b8da701ad123910b5b3', class: {
48
+ return (h(Host, { key: '329e985ec026dde828ee0e4f896bbbf68054a4ce' }, h("span", { key: '688c53ea00e20e7c2aa612ed6cdaede9a83655f9', class: {
49
49
  "duet-indicator": true,
50
50
  [`duet-indicator-${this.variation}`]: true,
51
51
  "duet-theme-turva": this.theme === "turva",
52
- } }), h("duet-visually-hidden", { key: 'c4ceeb86a4ab008a251f1ce9f4f6271c3fab73ef' }, this.getAccessibleLabel())));
52
+ } }), h("duet-visually-hidden", { key: '37a42c32af9d6d46946d30239592a4794e16de93' }, this.getAccessibleLabel())));
53
53
  }
54
54
  static get is() { return "duet-indicator"; }
55
55
  static get encapsulation() { return "shadow"; }
@@ -75,7 +75,7 @@ export class DuetIndicator {
75
75
  "references": {
76
76
  "IndicatorVariation": {
77
77
  "location": "local",
78
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-indicator/duet-indicator.tsx",
78
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-indicator/duet-indicator.tsx",
79
79
  "id": "src/components/duet-indicator/duet-indicator.tsx::IndicatorVariation"
80
80
  }
81
81
  }
@@ -8,7 +8,7 @@ import { inheritGlobalTheme } from "../../common";
8
8
  import { DuetInternalLabel } from "../../common/label";
9
9
  import { createID } from "../../utils/create-id";
10
10
  import { cleanValue, resetCursor } from "../../utils/input-utils";
11
- import { isArrowLeftKey, isArrowRightKey, isBackspaceKey, isEnterKey, isEscapeKey } from "../../utils/keyboard-utils";
11
+ import { isArrowLeftKey, isArrowRightKey, isBackspaceKey, isCharacterInsertKey, isEnterKey, isEscapeKey, } from "../../utils/keyboard-utils";
12
12
  import { connectLanguageChangeObserver, disconnectLanguageChangeObserver, getLanguage, getLocaleString, } from "../../utils/language-utils";
13
13
  import { checkNamedSlotElement, proxyInputToSlot } from "../../utils/slot-utils";
14
14
  const icons = {
@@ -33,6 +33,7 @@ export class DuetInput {
33
33
  this.topCaptionPlaceholderId = createID("DuetCaptionPlaceholderTop");
34
34
  this.chipCountId = createID("DuetInputChipCount");
35
35
  this.errorId = createID("DuetError");
36
+ this.maxlengthAnnouncementKey = 0;
36
37
  this.disallowPatternRegex = null;
37
38
  this.clearLabel = {
38
39
  en: "Clear",
@@ -69,6 +70,11 @@ export class DuetInput {
69
70
  fi: "valittu",
70
71
  sv: "valt",
71
72
  };
73
+ this.maxlengthReachedLabel = {
74
+ en: "This field has a maximum length of {max} characters. Limit reached.",
75
+ fi: "Tämän kentän enimmäispituus on {max} merkkiä. Raja on saavutettu.",
76
+ sv: "Det här fältet har en maximal längd på {max} tecken. Gränsen är nådd.",
77
+ };
72
78
  /**
73
79
  * State() variables
74
80
  */
@@ -78,6 +84,10 @@ export class DuetInput {
78
84
  */
79
85
  this.isFocused = false;
80
86
  this._accessiblePopup = undefined;
87
+ /**
88
+ * Text announced to screen readers when the maxlength limit is reached.
89
+ */
90
+ this.maxlengthAnnouncement = "";
81
91
  /**
82
92
  * Indicates the id or a string of space seperated ids of a component(s) that describes the input.
83
93
  */
@@ -208,9 +218,22 @@ export class DuetInput {
208
218
  * Component event handling.
209
219
  */
210
220
  this.onInput = (ev) => {
211
- if (this.maxlength && this.nativeInput.value.length > this.maxlength) {
221
+ var _a;
222
+ // In addition to input event, maxlength handling uses also keyDown and paste events as input event may not be
223
+ // triggered when entry is truncated by the browser.
224
+ if (this.maxlength) {
225
+ const wasAtMaxlength = (((_a = this.value) === null || _a === void 0 ? void 0 : _a.length) || 0) >= this.maxlength;
226
+ const nativeLength = this.nativeInput.value.length;
212
227
  // Android doesn't honor maxlength
213
- this.nativeInput.value = this.nativeInput.value.slice(0, this.maxlength);
228
+ const inputOverflow = nativeLength > this.maxlength;
229
+ if (inputOverflow) {
230
+ this.nativeInput.value = this.nativeInput.value.slice(0, this.maxlength);
231
+ }
232
+ const limitJustReached = !wasAtMaxlength && nativeLength === this.maxlength;
233
+ const limitExceededWhileFull = wasAtMaxlength && inputOverflow;
234
+ if (limitJustReached || limitExceededWhileFull) {
235
+ this.handleMaxlengthLimitReached();
236
+ }
214
237
  }
215
238
  if (this.disallowPatternRegex) {
216
239
  cleanValue(this.nativeInput, this.disallowPatternRegex);
@@ -256,6 +279,30 @@ export class DuetInput {
256
279
  component: "duet-input",
257
280
  });
258
281
  };
282
+ this.onInputKeyDown = (ev) => {
283
+ if (this.maxlength && isCharacterInsertKey(ev) && this.isAtMaxlengthWithoutSelection()) {
284
+ this.handleMaxlengthLimitReached();
285
+ }
286
+ };
287
+ this.onInputPaste = () => {
288
+ if (this.maxlength && this.isAtMaxlengthWithoutSelection()) {
289
+ this.handleMaxlengthLimitReached();
290
+ }
291
+ };
292
+ this.isAtMaxlengthWithoutSelection = () => {
293
+ const input = this.nativeInput;
294
+ const inputIsWithoutSelection = input.selectionStart === input.selectionEnd;
295
+ const inputIsAtMaxlength = input.value.length >= this.maxlength;
296
+ return inputIsWithoutSelection && inputIsAtMaxlength;
297
+ };
298
+ this.handleMaxlengthLimitReached = () => {
299
+ clearTimeout(this.maxlengthAnnouncementTimeoutId);
300
+ this.maxlengthAnnouncement = "";
301
+ this.maxlengthAnnouncementTimeoutId = setTimeout(() => {
302
+ this.maxlengthAnnouncementKey++;
303
+ this.maxlengthAnnouncement = this.maxlengthReachedLabel[this.language].replace("{max}", String(this.maxlength));
304
+ }, 300);
305
+ };
259
306
  /**
260
307
  * Private functions
261
308
  */
@@ -536,10 +583,15 @@ export class DuetInput {
536
583
  if (this.type === "password") {
537
584
  return "off";
538
585
  }
586
+ const tokens = this.autoComplete.split(/\s+/);
539
587
  // If attribute includes "email", e.g. "work email", don't overwrite it
540
- if (this.type === "email" && this.autoComplete !== "off" && !this.autoComplete.includes("email")) {
588
+ if (this.type === "email" && this.autoComplete !== "off" && !tokens.includes("email")) {
541
589
  return "email";
542
590
  }
591
+ // If attribute includes "tel", e.g. "mobile tel", don't overwrite it
592
+ if (this.type === "tel" && this.autoComplete !== "off" && !tokens.includes("tel")) {
593
+ return "tel";
594
+ }
543
595
  return this.autoComplete;
544
596
  }
545
597
  /**
@@ -606,7 +658,7 @@ export class DuetInput {
606
658
  this.type !== "password" &&
607
659
  this.type !== "time" &&
608
660
  this.variation !== "button";
609
- return (h(Host, { key: '776ea6ee90a20ff356574b64890a7b98d9947e6c', class: { "duet-expand": this.expand, "duet-m-0": this.margin === "none" }, onKeyUp: e => this.keyHandler(e) }, this.type === "time" && (h("duet-visually-hidden", { key: 'a56addb34f4bcf57a59e060921e3dacab36a98b7', "aria-live": "polite", "aria-atomic": "true" }, selectedTime ? `${this.timeAnnouncement[this.language]} ${selectedTime.toLocaleTimeString()}` : "")), h("div", { key: '04447fa85e1470adbfc2307f7b2fd5758454e0b7', class: {
661
+ return (h(Host, { key: '1119e8e51f3a490e34665e77ce32ec21f7bc70c7', class: { "duet-expand": this.expand, "duet-m-0": this.margin === "none" }, onKeyUp: e => this.keyHandler(e) }, this.type === "time" && (h("duet-visually-hidden", { key: '31afa65dcb1b161f8c5a87c65953a26a552066b8', "aria-live": "polite", "aria-atomic": "true" }, selectedTime ? `${this.timeAnnouncement[this.language]} ${selectedTime.toLocaleTimeString()}` : "")), h("div", { key: '5574afef8c592593193cbf0c99eaf8eaa84dbf11', class: {
610
662
  "duet-input-container": true,
611
663
  "duet-theme-turva": this.theme === "turva",
612
664
  [`duet-input-variation-${this.variation}`]: true,
@@ -623,11 +675,11 @@ export class DuetInput {
623
675
  "has-prefix": !!this.fieldPrefix,
624
676
  "has-suffix": !!this.fieldSuffix,
625
677
  disabled: this.disabled,
626
- } }, h("div", { key: 'f5f3de4654fac36f5ffb7e0302ffccb56263728a', class: "duet-input-label-container" }, h(DuetInternalLabel, { key: '566d4df4f7cfe09b50f4aedaf342cef70e7fc80a', theme: this.theme === "turva" ? "turva" : "default", margin: this.isCaptionVisible ? "small" : "auto", color: this.labelColor, weight: this.labelWeight, id: this.labelId, for: identifier }, this.label), this.tooltip && (h("duet-tooltip", { key: '7560dd36ade42746228061727b2fb2b38dce7ed6', class: "duet-input-tooltip", direction: this.tooltipDirection, accessibleInputLabel: this.label, theme: this.theme === "turva" ? "turva" : "default" }, this.tooltip)), h("slot", { key: '9b8a15f4f79269696a24c9fd989186f95dfc1e62', name: "tooltip" })), this.caption && (h("duet-caption", { key: 'c425ac21ec5942adfe5a4e48ae20080ab661bf4d', id: this.topCaptionId, size: "medium" }, this.caption)), h("div", { key: 'ac98b112529396687ec21a938c55ce1b3d86f091', class: {
678
+ } }, h("div", { key: 'cd0dfb4e8ef821c84d342fff017da9b3e6938134', class: "duet-input-label-container" }, h(DuetInternalLabel, { key: '7ef9a4e3ccbc5b7ac030ca66912eb0471103ed10', theme: this.theme === "turva" ? "turva" : "default", margin: this.isCaptionVisible ? "small" : "auto", color: this.labelColor, weight: this.labelWeight, id: this.labelId, for: identifier }, this.label), this.tooltip && (h("duet-tooltip", { key: 'f263424aa51a59f4252cad4b4a1347b5986869ae', class: "duet-input-tooltip", direction: this.tooltipDirection, accessibleInputLabel: this.label, theme: this.theme === "turva" ? "turva" : "default" }, this.tooltip)), h("slot", { key: 'b4afd5ae65bbc03083b81996965cb354d6fd2a35', name: "tooltip" })), this.caption && (h("duet-caption", { key: '1d126824ee2ef4b7a4dae8650363e9da0b58c288', id: this.topCaptionId, size: "medium" }, this.caption)), h("div", { key: 'adb5b8fa3b3de37c96d74fd1b888de75689a3ce0', class: {
627
679
  "duet-input-relative": true,
628
680
  "duet-theme-turva": this.theme === "turva",
629
681
  "has-error": !!this.error,
630
- } }, this.placeholder && this.echoPlaceholder && (this.value || this.type === "time") && (h("duet-caption", { key: 'db332864c2b97112aa2b9347da3d6c2468f77b0b', id: this.topCaptionPlaceholderId, class: "duet-input-placeholder", margin: "none", size: "small" }, this.placeholder)), this.chips && (h("duet-visually-hidden", { key: 'e92de63c87071f00143ee9db06c94361970b704a', id: this.chipCountId }, ", ", `${this.getAllChips().length} ${getLocaleString(this.chipsSelectedDesriptionLabel)}`, ",")), this.variation === "button-left" && h("slot", { key: '274e2fe6a604c30aa879ac72a33154f1fb3c8fc9', name: "button-left" }), this.fieldPrefix && (h("span", { key: '2bd5154e89d13c7562283684a3087c3c48481fb9', class: "input-adornment prefix", id: this.prefixId }, this.fieldPrefix)), h("input", Object.assign({ key: '0b77d2e90b3acdb1452d73ad2a736e924200009a', ref: input => (this.nativeInput = input), onInput: this.onInput, onBlur: this.onBlur, onFocus: this.onFocus, type: this.getInputType(), class: {
682
+ } }, this.placeholder && this.echoPlaceholder && (this.value || this.type === "time") && (h("duet-caption", { key: 'fcadd06bf9e0dc4115c0bd004de23fa5692b03fc', id: this.topCaptionPlaceholderId, class: "duet-input-placeholder", margin: "none", size: "small" }, this.placeholder)), this.chips && (h("duet-visually-hidden", { key: '84a8a1feed5a0895936f5e1d5ee310c6282f1678', id: this.chipCountId }, ", ", `${this.getAllChips().length} ${getLocaleString(this.chipsSelectedDesriptionLabel)}`, ",")), this.variation === "button-left" && h("slot", { key: '90533c1b234e2644eb97317f903abbf04fee8138', name: "button-left" }), this.fieldPrefix && (h("span", { key: '151fd6757766b8c7e86ded73639d87bb32814089', class: "input-adornment prefix", id: this.prefixId }, this.fieldPrefix)), h("input", Object.assign({ key: '06811722717032661d4ba5e3bfa9c2b6196cf082', ref: input => (this.nativeInput = input), onInput: this.onInput, onKeyDown: this.onInputKeyDown, onPaste: this.onInputPaste, onBlur: this.onBlur, onFocus: this.onFocus, type: this.getInputType(), class: {
631
683
  "duet-input": true,
632
684
  disabled: this.disabled,
633
685
  "is-number": this.component === "number",
@@ -635,17 +687,17 @@ export class DuetInput {
635
687
  "after-chip": this.getAllChips().length > 0,
636
688
  "align-right": this.inputAlign === "right",
637
689
  [`input-padding-${this.inputPadding}`]: true,
638
- }, value: this.value, disabled: this.disabled, "aria-invalid": this.error ? "true" : "false", "aria-labelledby": this.getAriaLabelledBy(), "aria-controls": this.accessibleControls, "aria-autocomplete": this.accessibleAutocomplete, "aria-activedescendant": this.accessibleActiveDescendant, "aria-details": this.accessibleDetails, "aria-description": this.accessibleDescription, "aria-expanded": this.accessibleExpanded, "aria-haspopup": this.accessibleHasPopup, "aria-owns": this.accessibleOwns, "aria-describedby": this.getAriaDescribedBy(), placeholder: this.placeholder, spellcheck: "false", minlength: this.minlength, maxlength: this.maxlength, autocomplete: this.getAutocomplete(), required: this.required, role: this.role, name: this.name, id: identifier }, inputProps)), this.fieldSuffix && (h("span", { key: '00f86f44a74b91127a1c11b696b51983d62a7c28', class: "input-adornment suffix", id: this.suffixId }, this.fieldSuffix)), !this.value && hasInputIcon && (h("div", { key: 'f1d531cc26ab9de06b90e38a4b790069fe920d88', class: "duet-input-icon" }, h("duet-icon", { key: 'fb14ea462e583a24e6bbd0337666dfa4ef9c9a1a', margin: "none", size: "small", icon: icons[this.type].svg, color: "currentColor" }))), this.clear && this.value && (h("div", { key: 'f2e415cb5d8c5eaa0bbb1bb0cad942d8a976e9a5', class: {
690
+ }, value: this.value, disabled: this.disabled, "aria-invalid": this.error ? "true" : "false", "aria-labelledby": this.getAriaLabelledBy(), "aria-controls": this.accessibleControls, "aria-autocomplete": this.accessibleAutocomplete, "aria-activedescendant": this.accessibleActiveDescendant, "aria-details": this.accessibleDetails, "aria-description": this.accessibleDescription, "aria-expanded": this.accessibleExpanded, "aria-haspopup": this.accessibleHasPopup, "aria-owns": this.accessibleOwns, "aria-describedby": this.getAriaDescribedBy(), placeholder: this.placeholder, spellcheck: "false", minlength: this.minlength, maxlength: this.maxlength, autocomplete: this.getAutocomplete(), required: this.required, role: this.role, name: this.name, id: identifier }, inputProps)), this.maxlength && (h("duet-visually-hidden", { key: `maxlength-announcement-${this.maxlengthAnnouncementKey}`, "aria-live": "polite", "aria-atomic": "true" }, this.maxlengthAnnouncement)), this.fieldSuffix && (h("span", { key: 'b2d284fc05798f7dab08555f524cabf4f94f0e19', class: "input-adornment suffix", id: this.suffixId }, this.fieldSuffix)), !this.value && hasInputIcon && (h("div", { key: '8364a8a7687b6e37279585edf55da9005673f4df', class: "duet-input-icon" }, h("duet-icon", { key: '1b420da3e76241f1e105ce5ef8b9f40e6490424d', margin: "none", size: "small", icon: icons[this.type].svg, color: "currentColor" }))), this.clear && this.value && (h("div", { key: 'c67978258fbf64a22563a8e139b7a7de012bb4ca', class: {
639
691
  "duet-input-clear-icon": true,
640
692
  "duet-input-clear-icon-single": !hasInputIcon,
641
693
  "duet-input-clear-icon-double": !!this.icon,
642
694
  "duet-input-clear-icon-button": this.variation === "button",
643
695
  [`input-padding-${this.inputPadding}`]: true,
644
- } }, h("button", { key: '7046a5f2c94bf429f4fc46dd4a9d590171975f04', onClick: this.handleClearClick, id: this.clearId, "aria-label": this.clearLabel[this.language], "aria-keyshortcuts": "Escape" }, h("duet-icon", { key: 'd33b0603197b14c98b4b8d76773f0c2325d365a9', margin: "none", size: "medium", name: "action-clear-input", color: "currentColor" })))), this.icon && this.variation !== "button" && (h("div", { key: 'f5b6861e2cd8f9affe011fc08700092296ef50c8', class: "duet-input-icon" }, h("duet-icon", { key: 'af0f1a819e505da950eec079950eb2a6c13c5254', margin: "none", size: "small", name: this.icon, color: "currentColor" }))), this.variation === "button" && h("slot", { key: 'db2a27e9e1683615a207b34f63a2981e0bbfe3e8', name: "button" }), this.variation === "revealable" && (h("duet-button", { key: 'f2c727cd4f07ea799ad033e737f490d14a285ded', ref: button => (this.togglePasswordRevealedButton = button), onBlur: this.onBlur, onFocus: this.onFocus, onClick: this.togglePasswordRevealed, icon: this.isPasswordRevealed ? "action-hide" : "action-show", accessibleLabel: this.isPasswordRevealed
696
+ } }, h("button", { key: 'b243244d6d5184c42a9afb93483479a0b07bad7d', onClick: this.handleClearClick, id: this.clearId, "aria-label": this.clearLabel[this.language], "aria-keyshortcuts": "Escape" }, h("duet-icon", { key: '2ff21863005e55dc7a4dc1a16e2e2e40ad7f85cf', margin: "none", size: "medium", name: "action-clear-input", color: "currentColor" })))), this.icon && this.variation !== "button" && (h("div", { key: '7732892f159a6c7c9ad7c89b0031052b1ed45502', class: "duet-input-icon" }, h("duet-icon", { key: '97de6dc8ff0c506db494dc36edc6d0107792c2b9', margin: "none", size: "small", name: this.icon, color: "currentColor" }))), this.variation === "button" && h("slot", { key: '5c940caf605e2eaff4db2a36c63548db78f36f41', name: "button" }), this.variation === "revealable" && (h("duet-button", { key: 'caf0a7c8bec4a620e2ca5f897eaabc1814f32c5d', ref: button => (this.togglePasswordRevealedButton = button), onBlur: this.onBlur, onFocus: this.onFocus, onClick: this.togglePasswordRevealed, icon: this.isPasswordRevealed ? "action-hide" : "action-show", accessibleLabel: this.isPasswordRevealed
645
697
  ? this.hidePasswordLabel[this.language]
646
- : this.showPasswordLabel[this.language], margin: "none", variation: "input-button-embedded", fixed: true, iconOnly: true })), this.variation === "revealable" && this.isPasswordRevealed !== undefined && (h("duet-visually-hidden", { key: 'd240447d7431097c99bd50fa6241a48d87b48ae0' }, h("span", { key: '47d29c787f119d0dae23436a69b192855b7bca63', "aria-live": "polite" }, this.isPasswordRevealed
698
+ : this.showPasswordLabel[this.language], margin: "none", variation: "input-button-embedded", fixed: true, iconOnly: true })), this.variation === "revealable" && this.isPasswordRevealed !== undefined && (h("duet-visually-hidden", { key: 'cc394dbd7d28fc9e1cf0a864c67e7e7a6a835d1a' }, h("span", { key: '20033ed28c86634d6faf03180e53cff84def1329', "aria-live": "polite" }, this.isPasswordRevealed
647
699
  ? this.passwordShownAriaAnnouncement[this.language]
648
- : this.passwordHiddenAriaAnnouncement[this.language]))), h("slot", { key: 'cd872ef0355479149e3b926e98e33ebccc1d0faa' })), h("span", { key: 'bbbbc5e7b7b1ddd8064bdda229ad110686075dd2', class: "duet-input-help", id: this.errorId, "aria-atomic": "true", "aria-live": this.accessibleLiveError, "aria-relevant": "additions removals" }, this.error && h("span", { key: '91876b01063f2de6147210b06daad0e5a3c71b3c', class: "duet-input-error" }, this.error)))));
700
+ : this.passwordHiddenAriaAnnouncement[this.language]))), h("slot", { key: 'b72c50503fa80fd1ba6764b7b3348bc5d7b2813c' })), h("span", { key: '25790e8c5147bb271fefa6cbce2343287b57c816', class: "duet-input-help", id: this.errorId, "aria-atomic": "true", "aria-live": this.accessibleLiveError, "aria-relevant": "additions removals" }, this.error && h("span", { key: 'c62d261a03ebec492aed9c65a836525e47660cfc', class: "duet-input-error" }, this.error)))));
649
701
  }
650
702
  static get is() { return "duet-input"; }
651
703
  static get encapsulation() { return "shadow"; }
@@ -1165,7 +1217,7 @@ export class DuetInput {
1165
1217
  "references": {
1166
1218
  "DuetInputType": {
1167
1219
  "location": "local",
1168
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-input/duet-input.tsx",
1220
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-input/duet-input.tsx",
1169
1221
  "id": "src/components/duet-input/duet-input.tsx::DuetInputType"
1170
1222
  }
1171
1223
  }
@@ -1191,7 +1243,7 @@ export class DuetInput {
1191
1243
  "references": {
1192
1244
  "DuetVariationType": {
1193
1245
  "location": "local",
1194
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-input/duet-input.tsx",
1246
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-input/duet-input.tsx",
1195
1247
  "id": "src/components/duet-input/duet-input.tsx::DuetVariationType"
1196
1248
  }
1197
1249
  }
@@ -1532,7 +1584,7 @@ export class DuetInput {
1532
1584
  "references": {
1533
1585
  "DuetInputComponentType": {
1534
1586
  "location": "local",
1535
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-input/duet-input.tsx",
1587
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-input/duet-input.tsx",
1536
1588
  "id": "src/components/duet-input/duet-input.tsx::DuetInputComponentType"
1537
1589
  }
1538
1590
  }
@@ -1756,7 +1808,8 @@ export class DuetInput {
1756
1808
  "language": {},
1757
1809
  "isPasswordRevealed": {},
1758
1810
  "isFocused": {},
1759
- "_accessiblePopup": {}
1811
+ "_accessiblePopup": {},
1812
+ "maxlengthAnnouncement": {}
1760
1813
  };
1761
1814
  }
1762
1815
  static get events() {
@@ -1776,7 +1829,7 @@ export class DuetInput {
1776
1829
  "references": {
1777
1830
  "DuetInputEvent": {
1778
1831
  "location": "local",
1779
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-input/duet-input.tsx",
1832
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-input/duet-input.tsx",
1780
1833
  "id": "src/components/duet-input/duet-input.tsx::DuetInputEvent"
1781
1834
  }
1782
1835
  }
@@ -1797,7 +1850,7 @@ export class DuetInput {
1797
1850
  "references": {
1798
1851
  "DuetInputEvent": {
1799
1852
  "location": "local",
1800
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-input/duet-input.tsx",
1853
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-input/duet-input.tsx",
1801
1854
  "id": "src/components/duet-input/duet-input.tsx::DuetInputEvent"
1802
1855
  }
1803
1856
  }
@@ -1818,7 +1871,7 @@ export class DuetInput {
1818
1871
  "references": {
1819
1872
  "DuetInputEvent": {
1820
1873
  "location": "local",
1821
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-input/duet-input.tsx",
1874
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-input/duet-input.tsx",
1822
1875
  "id": "src/components/duet-input/duet-input.tsx::DuetInputEvent"
1823
1876
  }
1824
1877
  }
@@ -1839,7 +1892,7 @@ export class DuetInput {
1839
1892
  "references": {
1840
1893
  "DuetInputEvent": {
1841
1894
  "location": "local",
1842
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-input/duet-input.tsx",
1895
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-input/duet-input.tsx",
1843
1896
  "id": "src/components/duet-input/duet-input.tsx::DuetInputEvent"
1844
1897
  }
1845
1898
  }
@@ -1860,7 +1913,7 @@ export class DuetInput {
1860
1913
  "references": {
1861
1914
  "DuetInputEvent": {
1862
1915
  "location": "local",
1863
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-input/duet-input.tsx",
1916
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-input/duet-input.tsx",
1864
1917
  "id": "src/components/duet-input/duet-input.tsx::DuetInputEvent"
1865
1918
  }
1866
1919
  }
@@ -121,7 +121,7 @@ export class DuetLabel {
121
121
  "references": {
122
122
  "DuetLabelMargin": {
123
123
  "location": "local",
124
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-label/duet-label.tsx",
124
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-label/duet-label.tsx",
125
125
  "id": "src/components/duet-label/duet-label.tsx::DuetLabelMargin"
126
126
  }
127
127
  }
@@ -147,7 +147,7 @@ export class DuetLabel {
147
147
  "references": {
148
148
  "DuetLabelSize": {
149
149
  "location": "local",
150
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-label/duet-label.tsx",
150
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-label/duet-label.tsx",
151
151
  "id": "src/components/duet-label/duet-label.tsx::DuetLabelSize"
152
152
  }
153
153
  }
@@ -66,24 +66,24 @@ export class DuetLayout {
66
66
  * Always the last one in the class.
67
67
  */
68
68
  render() {
69
- return (h(Host, { key: '7796cda5c4db65768c100838b80382b318b3ac73', class: {
69
+ return (h(Host, { key: 'c3ba619c0c3088257b425ba8f5022ebef33c1100', class: {
70
70
  center: this.center,
71
71
  "duet-middle": this.middle,
72
72
  "duet-ie": isInternetExplorer(),
73
- } }, h("div", { key: '1b4f06b0ccaf2a93e30cb57085b3260c9d138d1f', class: { "duet-layout-wrapper": true, "duet-m-0": this.margin === "none" } }, this.hasTop && (h("div", { key: '9b64258743ef0f5802e2853b2251788fc3c7f02d', class: {
73
+ } }, h("div", { key: 'd627f63579dfb957bf3abe17191e8a8e943f0aae', class: { "duet-layout-wrapper": true, "duet-m-0": this.margin === "none" } }, this.hasTop && (h("div", { key: '4586ff77f2ef4209020a2401eef63273527a2e27', class: {
74
74
  "duet-layout-top": true,
75
75
  "duet-center": this.center,
76
- } }, h("div", { key: '8de64147ed6cd7c0942f5f477da01c1ee4a8a0ce', class: "duet-layout-top-wrapper" }, h("slot", { key: '5b3dcec144e1e7a7707f52b18b8b1dc1d3cb13e7', name: "top" })))), h("div", { key: '57ef787cdd754a6749f76ce151ed15bb779b110b', class: {
76
+ } }, h("div", { key: 'daebb47e73054b59bb0459dc3327e0e60b17ebbe', class: "duet-layout-top-wrapper" }, h("slot", { key: '339fac00b53c0b4f532cfc77d5743217b5f72057', name: "top" })))), h("div", { key: 'bbf287d1f0aa701c40553a426b7a77b0a1c24c17', class: {
77
77
  "duet-layout": true,
78
78
  "has-sidebar": this.hasSidebar,
79
79
  "duet-center": this.center,
80
80
  [`padding-${this.paddingBreakpoint}`]: !!this.paddingBreakpoint,
81
- } }, h("main", { key: '11712887cb73595787e00eb4ae51be583e222d69', class: "duet-main" }, this.hasPageHeading && h("slot", { key: '024128c99761e9ce2df803f1a7af98da0bb39d48', name: "page-heading" }), h("slot", { key: '5ec1793d46d607633b527d9497e9c160f1879f4a', name: "main" })), this.hasSidebar && (h("aside", { key: 'c68315f8b323267fabd94fb2f45fa29294c6e17a', class: "duet-sidebar" }, h("div", { key: '5222f4a3bc1b36710f1efc85cd09c31cd676d661', class: {
81
+ } }, h("main", { key: '0d75aa9aeb65fa61f8e0ff114cee467abe49f1cd', class: "duet-main" }, this.hasPageHeading && h("slot", { key: 'fd0ed7464c54122f1cfbbfbfc40f78d8c9ab41c7', name: "page-heading" }), h("slot", { key: '1004e4007a1d82e22147ddf3a883e8ddc9c7b0dc', name: "main" })), this.hasSidebar && (h("aside", { key: '167c6d2495c8bbc7cd0275f723e0810b9fc311b6', class: "duet-sidebar" }, h("div", { key: 'f0bbcbeb756bf18ba1b678c405c3890fb00ad857', class: {
82
82
  "duet-sidebar-container": true,
83
83
  "has-tabs": this.tabs,
84
84
  sticky: this.sticky,
85
85
  [this.stickyDistance]: this.sticky,
86
- } }, h("slot", { key: '2c51db0affb26210fbbf38b7776d66f64c530f6f', name: "sidebar" }))))))));
86
+ } }, h("slot", { key: 'b8b30e8b29bb87ea6a0c0891ca5f841d0921f72b', name: "sidebar" }))))))));
87
87
  }
88
88
  static get is() { return "duet-layout"; }
89
89
  static get encapsulation() { return "shadow"; }
@@ -155,7 +155,7 @@ export class DuetLayout {
155
155
  "references": {
156
156
  "DuetLayoutStickyDistance": {
157
157
  "location": "local",
158
- "path": "/Users/juha-matti.laaksonen/duetds/packages/components/src/components/duet-layout/duet-layout.tsx",
158
+ "path": "/Users/kasimir/projects/lahitapiola/duet-design-system/packages/components/src/components/duet-layout/duet-layout.tsx",
159
159
  "id": "src/components/duet-layout/duet-layout.tsx::DuetLayoutStickyDistance"
160
160
  }
161
161
  }
@@ -187,10 +187,10 @@ export class DuetLink {
187
187
  const Tag = !this.url && this.variation !== "default" ? "button" : "a";
188
188
  const role = !this.url && this.variation === "default" ? "button" : null;
189
189
  const isButton = Tag === "button";
190
- return (h(Host, { key: '63ea212c967fed116f28d316bf7b4dc6f7bed88d', class: {
190
+ return (h(Host, { key: '1cac563de2598ea4f66a666a8e9ba85d74ef4d29', class: {
191
191
  [`duet-link-${this.variation}`]: true,
192
192
  "duet-m-0": this.margin === "none",
193
- } }, h(Tag, { key: 'c799db0446fbca186340c781f23ccecaf58e4336', href: this.url, class: {
193
+ } }, h(Tag, { key: '0ff450feb862488c1bfaf626a234559904f301a1', href: this.url, class: {
194
194
  "duet-link": true,
195
195
  "duet-link-is-external": this.external,
196
196
  "duet-link-is-download": !!this.download,