@duetds/components 4.35.4 → 5.0.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 (332) hide show
  1. package/hydrate/index.js +1708 -1055
  2. package/lib/cjs/duet-action-button.cjs.entry.js +163 -0
  3. package/lib/cjs/duet-alert.cjs.entry.js +1 -1
  4. package/lib/cjs/duet-badge.cjs.entry.js +1 -1
  5. package/lib/cjs/duet-breadcrumb.cjs.entry.js +1 -1
  6. package/lib/cjs/duet-breadcrumbs.cjs.entry.js +1 -1
  7. package/lib/cjs/duet-button_2.cjs.entry.js +14 -5
  8. package/lib/cjs/duet-caption_4.cjs.entry.js +3 -3
  9. package/lib/cjs/duet-card.cjs.entry.js +4 -4
  10. package/lib/cjs/duet-checkbox.cjs.entry.js +1 -1
  11. package/lib/cjs/duet-choice_2.cjs.entry.js +3 -3
  12. package/lib/cjs/duet-collapsible.cjs.entry.js +4 -4
  13. package/lib/cjs/duet-cookie-consent.cjs.entry.js +1 -1
  14. package/lib/cjs/duet-date-picker.cjs.entry.js +4 -4
  15. package/lib/cjs/duet-divider_2.cjs.entry.js +1 -1
  16. package/lib/cjs/{duet-editable-table_4.cjs.entry.js → duet-editable-table_3.cjs.entry.js} +382 -346
  17. package/lib/cjs/duet-empty-state.cjs.entry.js +1 -1
  18. package/lib/cjs/duet-fieldset.cjs.entry.js +1 -1
  19. package/lib/cjs/duet-footer.cjs.entry.js +1 -1
  20. package/lib/cjs/duet-grid_2.cjs.entry.js +2 -2
  21. package/lib/cjs/duet-header_2.cjs.entry.js +4 -4
  22. package/lib/cjs/duet-hero.cjs.entry.js +1 -1
  23. package/lib/cjs/duet-icon.cjs.entry.js +3 -3
  24. package/lib/cjs/duet-input_2.cjs.entry.js +1 -1
  25. package/lib/cjs/duet-layout.cjs.entry.js +1 -1
  26. package/lib/cjs/duet-list_2.cjs.entry.js +1 -1
  27. package/lib/cjs/duet-modal.cjs.entry.js +3 -3
  28. package/lib/cjs/duet-notification_2.cjs.entry.js +1 -1
  29. package/lib/cjs/duet-number-input.cjs.entry.js +2 -2
  30. package/lib/cjs/duet-pagination_2.cjs.entry.js +458 -0
  31. package/lib/cjs/duet-progress.cjs.entry.js +1 -1
  32. package/lib/cjs/duet-radio_2.cjs.entry.js +1 -1
  33. package/lib/cjs/duet-range-slider.cjs.entry.js +2 -2
  34. package/lib/cjs/duet-scrollable_3.cjs.entry.js +3 -3
  35. package/lib/cjs/duet-select.cjs.entry.js +16 -4
  36. package/lib/cjs/duet-step_2.cjs.entry.js +2 -2
  37. package/lib/cjs/duet-textarea.cjs.entry.js +1 -1
  38. package/lib/cjs/duet-toggle.cjs.entry.js +1 -1
  39. package/lib/cjs/duet-tooltip.cjs.entry.js +1 -1
  40. package/lib/cjs/duet-tray.cjs.entry.js +2 -2
  41. package/lib/cjs/duet-upload-aria-status.cjs.entry.js +1 -1
  42. package/lib/cjs/duet-visually-hidden.cjs.entry.js +1 -1
  43. package/lib/cjs/duet.cjs.js +2 -2
  44. package/lib/cjs/{focus-utils-eb8c5b20.js → focus-utils-7a11c463.js} +1 -1
  45. package/lib/cjs/{index-6ae8090f.js → index-da5d5aaf.js} +4 -1
  46. package/lib/cjs/js-utils-be1d29ae.js +39 -0
  47. package/lib/cjs/{keyboard-utils-b4e3d1d3.js → keyboard-utils-898cfe14.js} +8 -0
  48. package/lib/cjs/loader.cjs.js +2 -2
  49. package/lib/cjs/{token-utils-05bd23b4.js → token-utils-ac8432d1.js} +10 -7
  50. package/lib/cjs/{tokens-8596cece.js → tokens-72efc7fd.js} +0 -0
  51. package/lib/cjs/{tokens.module-6b2df1c2.js → tokens.module-6afcc9c1.js} +0 -0
  52. package/lib/collection/collection-manifest.json +22 -11
  53. package/lib/collection/components/duet-action-button/duet-action-button.css +87 -0
  54. package/lib/collection/components/duet-action-button/duet-action-button.js +489 -0
  55. package/lib/collection/components/duet-button/duet-button.css +3 -0
  56. package/lib/collection/components/duet-button/duet-button.js +50 -1
  57. package/lib/collection/components/duet-card/duet-card.js +1 -1
  58. package/lib/collection/components/duet-collapsible/duet-collapsible.js +2 -1
  59. package/lib/collection/components/duet-date-picker/duet-date-picker.css +2 -57
  60. package/lib/collection/components/duet-date-picker/duet-date-picker.js +2 -6
  61. package/lib/collection/components/duet-editable-table/duet-editable-table-tabledata.js +3 -2
  62. package/lib/collection/components/duet-editable-table/duet-editable-table.css +20 -1
  63. package/lib/collection/components/duet-editable-table/duet-editable-table.js +331 -205
  64. package/lib/collection/components/duet-pagination/duet-pagination-utils.js +9 -0
  65. package/lib/collection/components/duet-pagination/duet-pagination.css +61 -0
  66. package/lib/collection/components/duet-pagination/duet-pagination.js +541 -0
  67. package/lib/collection/components/duet-range-stepper/duet-range-stepper.css +49 -0
  68. package/lib/collection/components/duet-range-stepper/duet-range-stepper.js +340 -0
  69. package/lib/collection/components/duet-select/duet-select.css +26 -0
  70. package/lib/collection/components/duet-select/duet-select.js +39 -4
  71. package/lib/collection/components/duet-tab-group/duet-tab-group.js +5 -1
  72. package/lib/collection/components/duet-table/duet-table.css +42 -8
  73. package/lib/collection/components/duet-table/duet-table.js +11 -2
  74. package/lib/collection/components/duet-upload/duet-upload.css +25 -0
  75. package/lib/collection/components/duet-upload/duet-upload.js +270 -166
  76. package/lib/collection/components/duet-upload/upload-validators.js +1 -1
  77. package/lib/collection/utils/fixture-utils.js +3 -5
  78. package/lib/collection/utils/js-utils.js +36 -1
  79. package/lib/collection/utils/keyboard-utils.js +4 -0
  80. package/lib/collection/utils/test-utils.js +2 -1
  81. package/lib/collection/utils/token-utils.js +33 -6
  82. package/lib/custom-elements-bundle/index.d.ts +18 -12
  83. package/lib/custom-elements-bundle/index.js +1653 -1046
  84. package/lib/duet/duet.esm.js +1 -1
  85. package/lib/duet/duet.js +1 -1
  86. package/lib/duet/{p-503f1286.entry.js → p-00209700.entry.js} +1 -1
  87. package/lib/duet/{p-76fa8882.entry.js → p-01144f93.entry.js} +1 -1
  88. package/lib/duet/{p-ec2aea5f.system.entry.js → p-021bf3a2.system.entry.js} +1 -1
  89. package/lib/duet/{p-0169d57e.entry.js → p-04c6e557.entry.js} +1 -1
  90. package/lib/duet/{p-03a5fe42.system.entry.js → p-06fd151e.system.entry.js} +1 -1
  91. package/lib/duet/p-0988f548.entry.js +4 -0
  92. package/lib/duet/{p-d5a4b17f.system.entry.js → p-0e1130a0.system.entry.js} +1 -1
  93. package/lib/duet/{p-e4e99da0.entry.js → p-0fedc1c6.entry.js} +1 -1
  94. package/lib/duet/{p-2c85e001.system.entry.js → p-111b70c5.system.entry.js} +1 -1
  95. package/lib/duet/p-12825e2c.entry.js +4 -0
  96. package/lib/duet/p-166c09ce.system.entry.js +4 -0
  97. package/lib/duet/{p-8367a2d1.entry.js → p-1be45fc6.entry.js} +1 -1
  98. package/lib/duet/{p-253fd12a.system.entry.js → p-1da57e19.system.entry.js} +1 -1
  99. package/lib/duet/{p-b72ed5ef.system.entry.js → p-21c9efa8.system.entry.js} +1 -1
  100. package/lib/duet/{p-01679b51.entry.js → p-2245c56b.entry.js} +1 -1
  101. package/lib/duet/p-2273fc88.js +4 -0
  102. package/lib/duet/{p-5630828a.system.entry.js → p-232762b3.system.entry.js} +1 -1
  103. package/lib/duet/{p-3025a411.system.js → p-251dc733.system.js} +1 -1
  104. package/lib/duet/{p-ddb6344c.system.js → p-268c0abb.system.js} +0 -0
  105. package/lib/duet/{p-9077cd24.system.entry.js → p-2b6dac5c.system.entry.js} +1 -1
  106. package/lib/duet/{p-bba528b5.entry.js → p-35cdec32.entry.js} +1 -1
  107. package/lib/duet/{p-ee598605.entry.js → p-37bdfcc6.entry.js} +1 -1
  108. package/lib/duet/{p-c3d552d5.entry.js → p-3c7d81b0.entry.js} +1 -1
  109. package/lib/duet/{p-824d2360.system.entry.js → p-3f77090f.system.entry.js} +1 -1
  110. package/lib/duet/{p-7b451394.system.js → p-3fafe82f.system.js} +1 -1
  111. package/lib/duet/{p-2395f96e.system.entry.js → p-4b221aa3.system.entry.js} +1 -1
  112. package/lib/duet/{p-4ea864dd.system.entry.js → p-4b7b1d2a.system.entry.js} +1 -1
  113. package/lib/duet/p-4c282c1a.entry.js +4 -0
  114. package/lib/duet/p-51a7c020.entry.js +4 -0
  115. package/lib/duet/{p-e8ce8394.entry.js → p-5298f6fb.entry.js} +1 -1
  116. package/lib/duet/p-5746d88c.js +4 -0
  117. package/lib/duet/{p-dfd96467.entry.js → p-589c2f28.entry.js} +1 -1
  118. package/lib/duet/{p-f98fca13.system.entry.js → p-592315ca.system.entry.js} +1 -1
  119. package/lib/duet/{p-6cff80cb.system.entry.js → p-59a0ec33.system.entry.js} +1 -1
  120. package/lib/duet/p-5e1f64cb.entry.js +4 -0
  121. package/lib/duet/{p-73b5248d.entry.js → p-608645ed.entry.js} +1 -1
  122. package/lib/duet/{p-8ea92cc5.entry.js → p-683f1962.entry.js} +1 -1
  123. package/lib/duet/{p-55fff1fe.entry.js → p-6932c6d8.entry.js} +1 -1
  124. package/lib/duet/{p-731444f6.entry.js → p-6934cb1b.entry.js} +1 -1
  125. package/lib/duet/{p-caab828f.system.entry.js → p-6d209c01.system.entry.js} +1 -1
  126. package/lib/duet/{p-61198eee.system.entry.js → p-70e5c803.system.entry.js} +1 -1
  127. package/lib/duet/p-74780bca.system.js +4 -0
  128. package/lib/duet/p-74d267d3.system.entry.js +4 -0
  129. package/lib/duet/{p-2bfe8b50.system.entry.js → p-766daacb.system.entry.js} +1 -1
  130. package/lib/duet/p-77acbfe4.system.js +4 -0
  131. package/lib/duet/p-7953cff9.system.entry.js +4 -0
  132. package/lib/duet/{p-01f3fbd4.system.entry.js → p-7e939e57.system.entry.js} +1 -1
  133. package/lib/duet/{p-fa99eaa4.system.js → p-812b0905.system.js} +0 -0
  134. package/lib/duet/{p-c122428f.entry.js → p-814ed07c.entry.js} +1 -1
  135. package/lib/duet/{p-04304e51.entry.js → p-82a0e535.entry.js} +1 -1
  136. package/lib/duet/{p-4a60b131.system.entry.js → p-8338702d.system.entry.js} +1 -1
  137. package/lib/duet/{p-e682d701.system.entry.js → p-85b4b5c0.system.entry.js} +2 -2
  138. package/lib/duet/{p-e3229d0d.entry.js → p-86538787.entry.js} +1 -1
  139. package/lib/duet/p-898f30a5.js +4 -0
  140. package/lib/duet/{p-40a76f20.entry.js → p-8f01f647.entry.js} +1 -1
  141. package/lib/duet/{p-a39a0a45.entry.js → p-8f6def3f.entry.js} +1 -1
  142. package/lib/duet/{p-753098ec.entry.js → p-90464434.entry.js} +1 -1
  143. package/lib/duet/p-92639d0b.system.js +4 -0
  144. package/lib/duet/{p-873e4c51.system.entry.js → p-97f95c02.system.entry.js} +2 -2
  145. package/lib/duet/{p-ea30becb.system.entry.js → p-982deb44.system.entry.js} +1 -1
  146. package/lib/duet/{p-7fd62541.entry.js → p-9dc88c43.entry.js} +1 -1
  147. package/lib/duet/{p-412f58cf.entry.js → p-a37e57d8.entry.js} +1 -1
  148. package/lib/duet/{p-da1f6193.system.entry.js → p-a71510b8.system.entry.js} +1 -1
  149. package/lib/duet/p-a8eec12e.system.entry.js +4 -0
  150. package/lib/duet/{p-4d8cd455.system.entry.js → p-abcfbb23.system.entry.js} +1 -1
  151. package/lib/duet/{p-99262d61.entry.js → p-ac2b38e6.entry.js} +1 -1
  152. package/lib/duet/{p-24b4eefb.system.entry.js → p-ace2cd17.system.entry.js} +1 -1
  153. package/lib/duet/{p-94a2da86.system.entry.js → p-ad278903.system.entry.js} +1 -1
  154. package/lib/duet/{p-a0deb526.entry.js → p-aea907ad.entry.js} +1 -1
  155. package/lib/duet/{p-9690681b.system.entry.js → p-b432d318.system.entry.js} +1 -1
  156. package/lib/duet/{p-44fe8367.system.entry.js → p-b4e75f80.system.entry.js} +1 -1
  157. package/lib/duet/{p-c1b34a78.system.entry.js → p-b8c8105c.system.entry.js} +1 -1
  158. package/lib/duet/{p-efd978ee.entry.js → p-ba7480e9.entry.js} +1 -1
  159. package/lib/duet/p-bc7dba26.entry.js +4 -0
  160. package/lib/duet/{p-a926b44b.entry.js → p-bf06f635.entry.js} +1 -1
  161. package/lib/duet/p-c6ccf366.system.entry.js +4 -0
  162. package/lib/duet/{p-7cdb8bfa.entry.js → p-cd1a767f.entry.js} +1 -1
  163. package/lib/duet/p-d6d9b0c6.system.entry.js +4 -0
  164. package/lib/duet/{p-8143f3de.js → p-d7bc0102.js} +0 -0
  165. package/lib/duet/{p-fb98ac5a.entry.js → p-d9e329c0.entry.js} +1 -1
  166. package/lib/duet/p-dbb4a588.js +4 -0
  167. package/lib/duet/{p-f51f8554.entry.js → p-dc67d989.entry.js} +1 -1
  168. package/lib/duet/{p-a69667c7.entry.js → p-de9ff67c.entry.js} +1 -1
  169. package/lib/duet/{p-0f185a8a.system.entry.js → p-deb8ac4d.system.entry.js} +1 -1
  170. package/lib/duet/p-e2e0bc49.system.js +4 -0
  171. package/lib/duet/{p-6b24111b.system.entry.js → p-e624799f.system.entry.js} +1 -1
  172. package/lib/duet/{p-8973aa31.system.entry.js → p-e887d6db.system.entry.js} +1 -1
  173. package/lib/duet/p-e9c3053b.js +4 -0
  174. package/lib/duet/{p-a212f672.system.entry.js → p-ebed7c5e.system.entry.js} +1 -1
  175. package/lib/duet/{p-ad07f399.js → p-ed75c8b3.js} +0 -0
  176. package/lib/duet/{p-4a931c6c.system.entry.js → p-f020852e.system.entry.js} +1 -1
  177. package/lib/duet/p-f2abd301.entry.js +4 -0
  178. package/lib/duet/{p-fc35b926.system.entry.js → p-f54d1487.system.entry.js} +1 -1
  179. package/lib/duet/{p-17f85b90.entry.js → p-fc44a819.entry.js} +1 -1
  180. package/lib/duet/{p-bc6794bc.system.entry.js → p-fcdd24f8.system.entry.js} +1 -1
  181. package/lib/duet/{p-5e895b06.entry.js → p-fed35d92.entry.js} +1 -1
  182. package/lib/duet/{p-de5c3a36.entry.js → p-ff308f4c.entry.js} +1 -1
  183. package/lib/esm/duet-action-button.entry.js +159 -0
  184. package/lib/esm/duet-alert.entry.js +1 -1
  185. package/lib/esm/duet-badge.entry.js +1 -1
  186. package/lib/esm/duet-breadcrumb.entry.js +1 -1
  187. package/lib/esm/duet-breadcrumbs.entry.js +1 -1
  188. package/lib/esm/duet-button_2.entry.js +14 -5
  189. package/lib/esm/duet-caption_4.entry.js +3 -3
  190. package/lib/esm/duet-card.entry.js +4 -4
  191. package/lib/esm/duet-checkbox.entry.js +1 -1
  192. package/lib/esm/duet-choice_2.entry.js +3 -3
  193. package/lib/esm/duet-collapsible.entry.js +4 -4
  194. package/lib/esm/duet-cookie-consent.entry.js +1 -1
  195. package/lib/esm/duet-date-picker.entry.js +4 -4
  196. package/lib/esm/duet-divider_2.entry.js +1 -1
  197. package/lib/esm/{duet-editable-table_4.entry.js → duet-editable-table_3.entry.js} +384 -347
  198. package/lib/esm/duet-empty-state.entry.js +1 -1
  199. package/lib/esm/duet-fieldset.entry.js +1 -1
  200. package/lib/esm/duet-footer.entry.js +1 -1
  201. package/lib/esm/duet-grid_2.entry.js +2 -2
  202. package/lib/esm/duet-header_2.entry.js +4 -4
  203. package/lib/esm/duet-hero.entry.js +1 -1
  204. package/lib/esm/duet-icon.entry.js +3 -3
  205. package/lib/esm/duet-input_2.entry.js +1 -1
  206. package/lib/esm/duet-layout.entry.js +1 -1
  207. package/lib/esm/duet-list_2.entry.js +1 -1
  208. package/lib/esm/duet-modal.entry.js +3 -3
  209. package/lib/esm/duet-notification_2.entry.js +1 -1
  210. package/lib/esm/duet-number-input.entry.js +2 -2
  211. package/lib/esm/duet-pagination_2.entry.js +453 -0
  212. package/lib/esm/duet-progress.entry.js +1 -1
  213. package/lib/esm/duet-radio_2.entry.js +1 -1
  214. package/lib/esm/duet-range-slider.entry.js +2 -2
  215. package/lib/esm/duet-scrollable_3.entry.js +3 -3
  216. package/lib/esm/duet-select.entry.js +16 -4
  217. package/lib/esm/duet-step_2.entry.js +2 -2
  218. package/lib/esm/duet-textarea.entry.js +1 -1
  219. package/lib/esm/duet-toggle.entry.js +1 -1
  220. package/lib/esm/duet-tooltip.entry.js +1 -1
  221. package/lib/esm/duet-tray.entry.js +2 -2
  222. package/lib/esm/duet-upload-aria-status.entry.js +1 -1
  223. package/lib/esm/duet-visually-hidden.entry.js +1 -1
  224. package/lib/esm/duet.js +2 -2
  225. package/lib/esm/{focus-utils-6db957a7.js → focus-utils-b0b3361f.js} +1 -1
  226. package/lib/esm/{index-828dfb4e.js → index-16f4da7f.js} +4 -1
  227. package/lib/esm/js-utils-52e0944c.js +36 -0
  228. package/lib/esm/{keyboard-utils-584cedd7.js → keyboard-utils-6eb55cd5.js} +5 -1
  229. package/lib/esm/loader.js +2 -2
  230. package/lib/esm/{token-utils-75f78ca4.js → token-utils-e9a0cb88.js} +10 -7
  231. package/lib/esm/{tokens-e110dc89.js → tokens-57d98824.js} +0 -0
  232. package/lib/esm/{tokens.module-49cbf963.js → tokens.module-a13e9683.js} +0 -0
  233. package/lib/esm-es5/duet-action-button.entry.js +4 -0
  234. package/lib/esm-es5/duet-alert.entry.js +1 -1
  235. package/lib/esm-es5/duet-badge.entry.js +1 -1
  236. package/lib/esm-es5/duet-breadcrumb.entry.js +1 -1
  237. package/lib/esm-es5/duet-breadcrumbs.entry.js +1 -1
  238. package/lib/esm-es5/duet-button_2.entry.js +1 -1
  239. package/lib/esm-es5/duet-caption_4.entry.js +1 -1
  240. package/lib/esm-es5/duet-card.entry.js +1 -1
  241. package/lib/esm-es5/duet-checkbox.entry.js +1 -1
  242. package/lib/esm-es5/duet-choice_2.entry.js +1 -1
  243. package/lib/esm-es5/duet-collapsible.entry.js +1 -1
  244. package/lib/esm-es5/duet-cookie-consent.entry.js +1 -1
  245. package/lib/esm-es5/duet-date-picker.entry.js +2 -2
  246. package/lib/esm-es5/duet-divider_2.entry.js +1 -1
  247. package/lib/esm-es5/duet-editable-table_3.entry.js +4 -0
  248. package/lib/esm-es5/duet-empty-state.entry.js +1 -1
  249. package/lib/esm-es5/duet-fieldset.entry.js +1 -1
  250. package/lib/esm-es5/duet-footer.entry.js +1 -1
  251. package/lib/esm-es5/duet-grid_2.entry.js +1 -1
  252. package/lib/esm-es5/duet-header_2.entry.js +1 -1
  253. package/lib/esm-es5/duet-hero.entry.js +1 -1
  254. package/lib/esm-es5/duet-icon.entry.js +1 -1
  255. package/lib/esm-es5/duet-input_2.entry.js +1 -1
  256. package/lib/esm-es5/duet-layout.entry.js +1 -1
  257. package/lib/esm-es5/duet-list_2.entry.js +1 -1
  258. package/lib/esm-es5/duet-modal.entry.js +1 -1
  259. package/lib/esm-es5/duet-notification_2.entry.js +1 -1
  260. package/lib/esm-es5/duet-number-input.entry.js +1 -1
  261. package/lib/esm-es5/duet-pagination_2.entry.js +4 -0
  262. package/lib/esm-es5/duet-progress.entry.js +1 -1
  263. package/lib/esm-es5/duet-radio_2.entry.js +1 -1
  264. package/lib/esm-es5/duet-range-slider.entry.js +1 -1
  265. package/lib/esm-es5/duet-scrollable_3.entry.js +1 -1
  266. package/lib/esm-es5/duet-select.entry.js +2 -2
  267. package/lib/esm-es5/duet-step_2.entry.js +1 -1
  268. package/lib/esm-es5/duet-textarea.entry.js +1 -1
  269. package/lib/esm-es5/duet-toggle.entry.js +1 -1
  270. package/lib/esm-es5/duet-tooltip.entry.js +1 -1
  271. package/lib/esm-es5/duet-tray.entry.js +1 -1
  272. package/lib/esm-es5/duet-upload-aria-status.entry.js +1 -1
  273. package/lib/esm-es5/duet-visually-hidden.entry.js +1 -1
  274. package/lib/esm-es5/duet.js +1 -1
  275. package/lib/esm-es5/focus-utils-b0b3361f.js +4 -0
  276. package/lib/esm-es5/{index-828dfb4e.js → index-16f4da7f.js} +1 -1
  277. package/lib/esm-es5/js-utils-52e0944c.js +4 -0
  278. package/lib/esm-es5/keyboard-utils-6eb55cd5.js +4 -0
  279. package/lib/esm-es5/loader.js +1 -1
  280. package/lib/esm-es5/token-utils-e9a0cb88.js +4 -0
  281. package/lib/esm-es5/{tokens-e110dc89.js → tokens-57d98824.js} +0 -0
  282. package/lib/esm-es5/{tokens.module-49cbf963.js → tokens.module-a13e9683.js} +0 -0
  283. package/lib/html.html-data.json +5266 -0
  284. package/lib/types/components/duet-action-button/duet-action-button.d.ts +112 -0
  285. package/lib/types/components/duet-button/duet-button.d.ts +9 -0
  286. package/lib/types/components/duet-card/duet-card.d.ts +1 -1
  287. package/lib/types/components/duet-collapsible/duet-collapsible.d.ts +1 -0
  288. package/lib/types/components/duet-editable-table/duet-editable-table-tabledata.d.ts +2 -2
  289. package/lib/types/components/duet-editable-table/duet-editable-table.d.ts +106 -48
  290. package/lib/types/components/duet-pagination/duet-pagination-utils.d.ts +1 -0
  291. package/lib/types/components/duet-pagination/duet-pagination.d.ts +105 -0
  292. package/lib/types/components/duet-range-stepper/duet-range-stepper.d.ts +70 -0
  293. package/lib/types/components/duet-select/duet-select.d.ts +5 -0
  294. package/lib/types/components/duet-tab-group/duet-tab-group.d.ts +4 -0
  295. package/lib/types/components/duet-table/duet-table.d.ts +16 -0
  296. package/lib/types/components/duet-upload/duet-upload.d.ts +68 -58
  297. package/lib/types/components.d.ts +402 -140
  298. package/lib/types/utils/js-utils.d.ts +2 -0
  299. package/lib/types/utils/keyboard-utils.d.ts +4 -0
  300. package/lib/types/utils/token-utils.d.ts +2 -0
  301. package/package.json +5 -6
  302. package/lib/cjs/duet-editable-table-button.cjs.entry.js +0 -96
  303. package/lib/collection/components/duet-editable-table/duet-editable-table-button.css +0 -32
  304. package/lib/collection/components/duet-editable-table/duet-editable-table-button.js +0 -225
  305. package/lib/collection/components/duet-editable-table/duet-editable-table-item.css +0 -36
  306. package/lib/collection/components/duet-editable-table/duet-editable-table-item.js +0 -225
  307. package/lib/duet/p-0427e1a5.entry.js +0 -4
  308. package/lib/duet/p-04f9f1bf.js +0 -4
  309. package/lib/duet/p-0f91d386.system.entry.js +0 -4
  310. package/lib/duet/p-227e5196.js +0 -4
  311. package/lib/duet/p-2545734a.entry.js +0 -4
  312. package/lib/duet/p-2b8316ee.system.entry.js +0 -4
  313. package/lib/duet/p-477c2e5c.entry.js +0 -4
  314. package/lib/duet/p-50b4fb2c.js +0 -4
  315. package/lib/duet/p-66bf27b9.system.entry.js +0 -4
  316. package/lib/duet/p-68ecdc4f.system.entry.js +0 -4
  317. package/lib/duet/p-853cd059.js +0 -4
  318. package/lib/duet/p-a16a58c1.system.js +0 -4
  319. package/lib/duet/p-b0c16ee5.entry.js +0 -4
  320. package/lib/duet/p-b3a2a1e8.entry.js +0 -4
  321. package/lib/duet/p-bb12b972.system.js +0 -4
  322. package/lib/duet/p-c63e49e2.system.entry.js +0 -4
  323. package/lib/duet/p-e6349dd2.entry.js +0 -4
  324. package/lib/duet/p-ef3fc3f3.system.js +0 -4
  325. package/lib/esm/duet-editable-table-button.entry.js +0 -92
  326. package/lib/esm-es5/duet-editable-table-button.entry.js +0 -4
  327. package/lib/esm-es5/duet-editable-table_4.entry.js +0 -4
  328. package/lib/esm-es5/focus-utils-6db957a7.js +0 -4
  329. package/lib/esm-es5/keyboard-utils-584cedd7.js +0 -4
  330. package/lib/esm-es5/token-utils-75f78ca4.js +0 -4
  331. package/lib/types/components/duet-editable-table/duet-editable-table-button.d.ts +0 -73
  332. package/lib/types/components/duet-editable-table/duet-editable-table-item.d.ts +0 -76
@@ -2,7 +2,7 @@
2
2
  * Built with Duet Design System
3
3
  */
4
4
  const NAMESPACE = 'duet';
5
- const Env = /* duet */ {"cdnURILocal":"http://0.0.0.0:3334","cdnURIProd":"https://cdn.duetds.com/api","duetIconVersion":"2.2.15"};
5
+ const Env = /* duet */ {"cdnURILocal":"http://0.0.0.0:3334","cdnURIProd":"https://cdn.duetds.com/api","duetIconVersion":"2.2.18"};
6
6
 
7
7
  let scopeId;
8
8
  let contentRef;
@@ -1165,6 +1165,9 @@ const postUpdateComponent = (hostRef) => {
1165
1165
  const endPostUpdate = createTime('postUpdate', tagName);
1166
1166
  const instance = elm;
1167
1167
  const ancestorComponent = hostRef.$ancestorComponent$;
1168
+ {
1169
+ safeCall(instance, 'componentDidRender');
1170
+ }
1168
1171
  if (!(hostRef.$flags$ & 64 /* hasLoadedComponent */)) {
1169
1172
  hostRef.$flags$ |= 64 /* hasLoadedComponent */;
1170
1173
  {
@@ -1659,6 +1662,60 @@ const appGlobalScript = () => {
1659
1662
 
1660
1663
  const globalScripts = appGlobalScript;
1661
1664
 
1665
+ function chr4() {
1666
+ return Math.random().toString(16).slice(-4);
1667
+ }
1668
+ function createID(prefix) {
1669
+ return `${prefix}-${chr4()}${chr4()}-${chr4()}-${chr4()}-${chr4()}-${chr4()}${chr4()}${chr4()}`;
1670
+ }
1671
+
1672
+ const debounce = (func, timeout = 250) => {
1673
+ let timer;
1674
+ return (...args) => {
1675
+ clearTimeout(timer);
1676
+ timer = setTimeout(() => {
1677
+ func.apply(undefined, args);
1678
+ }, timeout);
1679
+ };
1680
+ };
1681
+ function fieldSorter(fields) {
1682
+ return function (a, b) {
1683
+ return fields
1684
+ .map(function (o) {
1685
+ let dir = 1;
1686
+ if (o[0] === "-") {
1687
+ dir = -1;
1688
+ o = o.substring(1);
1689
+ }
1690
+ if (a[o] > b[o]) {
1691
+ return dir;
1692
+ }
1693
+ if (a[o] < b[o]) {
1694
+ return -dir;
1695
+ }
1696
+ return 0;
1697
+ })
1698
+ .reduce(function firstNonZeroValue(p, n) {
1699
+ return p ? p : n;
1700
+ }, 0);
1701
+ };
1702
+ }
1703
+
1704
+ const isArrowLeftKey = (e) => e.keyCode === 37;
1705
+ const isArrowUpKey = (e) => e.keyCode === 38;
1706
+ const isArrowRightKey = (e) => e.keyCode === 39;
1707
+ const isArrowDownKey = (e) => e.keyCode === 40;
1708
+ const isArrowKey = (e) => isArrowDownKey(e) || isArrowRightKey(e) || isArrowUpKey(e) || isArrowLeftKey(e);
1709
+ const isEscapeKey = (e) => e.key === "Escape" || e.key === "Esc" || e.keyCode === 27;
1710
+ const isBackspaceKey = (e) => e.keyCode === 8;
1711
+ const isSpaceKey = (e) => e.key === "Space" || e.keyCode === 32;
1712
+ const isPlusKey = (e) => e.key === "+" || e.keyCode === 43;
1713
+ const isMinusKey = (e) => e.key === "-" || e.keyCode === 45;
1714
+ const isQuestionKey = (e) => e.key === "?";
1715
+ const isEnterKey = (e) => e.key === "Enter" || e.keyCode === 13;
1716
+ const isKeyboardClick = (e) => isEnterKey(e) || isSpaceKey(e);
1717
+ const isNumber = (e) => (e.keyCode >= 48 && e.keyCode <= 57) || (e.keyCode >= 96 && e.keyCode <= 105);
1718
+
1662
1719
  function isObject(maybeObj) {
1663
1720
  return Object.prototype.toString.call(maybeObj) === "[object Object]";
1664
1721
  }
@@ -1796,165 +1853,587 @@ const inheritGlobalTheme = (component) => {
1796
1853
  }
1797
1854
  };
1798
1855
 
1799
- const duetAlertCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:block;width:100%;max-height:999px;border-radius:4px;transition:opacity 300ms ease, visibility 300ms ease, transform 300ms ease, max-height 300ms ease}:host(:focus){outline:0}:host(.user-is-tabbing:focus){border-radius:4px;box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}:host(.user-is-tabbing.duet-theme-turva:focus){box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}:host(.duet-alert-is-dismissed){max-height:0;visibility:hidden;opacity:0;transform:scale(0.98)}:host(.duet-alert-is-dismissed) .duet-alert{margin:0 !important}.duet-alert{margin-bottom:16px !important;position:relative;width:100%;padding:16px;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;font-weight:400;line-height:1.25;color:#00294d;background:#f2f8fb;border:1px solid #0077b3;border-radius:4px;transition:margin 100ms 300ms ease}.duet-alert.duet-p-0{padding:0 !important}.duet-alert.duet-m-0{margin:0 !important}.duet-alert.duet-theme-turva{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#171c3a;background:#f3f4f5;border-color:#171c3a}.duet-alert.warning{background:#fffbf4;border-color:#f7b228}.duet-alert.warning.duet-theme-turva{background:#fffaf3;border-color:#faa40f}.duet-alert.danger{background:#fdf4f7;border-color:#de2362}.duet-alert.danger.duet-theme-turva{background:#fdf4f3;border-color:#e02a0d}.duet-alert.success{background:#f2f9f7;border-color:#00875a}.duet-alert.success.duet-theme-turva{background:#f3f9f6;border-color:#08874e}.duet-alert-dismiss{position:absolute;top:2px;right:2px}.duet-alert-container{display:inline-flex;align-items:center;justify-content:center;width:100%;margin:0 auto !important}.duet-alert-container span{width:100%}.duet-alert-has-icon .duet-alert-container{margin-top:2px !important}.duet-alert-icon{display:inline-block;align-self:center;width:20px;min-width:20px;height:20px;margin:0 16px 0 0 !important}.duet-alert-icon duet-icon{width:20px;height:20px}.duet-alert-is-dismissible{padding:16px 48px 16px 16px;text-align:left}.duet-alert-is-dismissible .duet-alert-container{text-align:left}";
1856
+ const colorWarning = "rgb(247, 178, 40)";
1857
+ const colorGrayDarker = "rgb(101, 119, 135)";
1858
+ const colorGrayLighter = "rgb(245, 248, 250)";
1859
+ const colorCategoryHome = "rgb(211, 36, 131)";
1860
+ const colorPrimary = "rgb(0, 119, 179)";
1861
+ const colorCategoryVehicle = "rgb(54, 74, 129)";
1862
+ const colorSuccess = "rgb(0, 135, 90)";
1863
+ const colorCategoryFamily = "rgb(11, 114, 136)";
1864
+ const colorPrimaryLightest = "rgb(243, 249, 252)";
1865
+ const colorPrimaryLighter = "rgb(230, 242, 248)";
1866
+ const colorBrandBlue = "rgb(0, 161, 212)";
1867
+ const colorPrimaryDark = "rgb(0, 77, 128)";
1868
+ const colorGrayLightest = "rgb(255, 255, 255)";
1869
+ const colorCategoryFinance = "rgb(122, 1, 196)";
1870
+ const colorGrayDark = "rgb(144, 149, 153)";
1871
+ const colorGrayLight = "rgb(225, 227, 230)";
1872
+ const colorSecondary = "rgb(0, 41, 77)";
1873
+ const colorCategoryPet = "rgb(168, 1, 78)";
1874
+ const colorPrimaryLight = "rgb(205, 229, 241)";
1875
+ const colorCategoryTravel = "rgb(213, 66, 3)";
1876
+ const colorGray = "rgb(207, 210, 212)";
1877
+ const colorDanger = "rgb(222, 35, 98)";
1878
+ const colorGrayDarkerTurva = "rgb(68, 68, 69)";
1879
+ const colorGrayLighterTurva = "rgb(245, 245, 247)";
1880
+ const colorCategoryHomeTurva = "rgb(161, 10, 78)";
1881
+ const colorPrimaryTurva = "rgb(198, 12, 48)";
1882
+ const colorCategoryVehicleTurva = "rgb(23, 28, 58)";
1883
+ const colorSuccessTurva = "rgb(8, 135, 78)";
1884
+ const colorPrimaryLightestTurva = "rgb(252, 243, 244)";
1885
+ const colorCategoryFamilyTurva = "rgb(199, 12, 112)";
1886
+ const colorCategoryUnionTurva = "rgb(169, 69, 124)";
1887
+ const colorPrimaryLighterTurva = "rgb(249, 230, 234)";
1888
+ const colorPrimaryDarkTurva = "rgb(148, 9, 37)";
1889
+ const colorGrayLightestTurva = "rgb(255, 255, 255)";
1890
+ const colorGrayDarkTurva = "rgb(116, 116, 117)";
1891
+ const colorGrayLightTurva = "rgb(228, 228, 230)";
1892
+ const colorBrandGrayTurva = "rgb(178, 180, 179)";
1893
+ const colorSecondaryTurva = "rgb(23, 28, 58)";
1894
+ const colorPrimaryLightTurva = "rgb(244, 207, 214)";
1895
+ const colorCategoryTravelTurva = "rgb(9, 129, 148)";
1896
+ const colorGrayTurva = "rgb(207, 207, 209)";
1897
+ const colorDangerTurva = "rgb(224, 42, 13)";
1898
+ const colorWarningTurva = "rgb(250, 164, 15)";
1899
+ const colorData07 = "rgb(192, 101, 247)";
1900
+ const colorData08 = "rgb(0, 105, 191)";
1901
+ const colorData09 = "rgb(19, 120, 53)";
1902
+ const colorData10 = "rgb(179, 60, 24)";
1903
+ const colorData11 = "rgb(13, 163, 166)";
1904
+ const colorData01 = "rgb(122, 1, 196)";
1905
+ const colorData12 = "rgb(11, 114, 136)";
1906
+ const colorData02 = "rgb(0, 155, 204)";
1907
+ const colorData13 = "rgb(179, 137, 24)";
1908
+ const colorData03 = "rgb(27, 171, 75)";
1909
+ const colorData14 = "rgb(128, 98, 17)";
1910
+ const colorData04 = "rgb(255, 86, 34)";
1911
+ const colorData15 = "rgb(0, 41, 77)";
1912
+ const colorData05 = "rgb(245, 76, 154)";
1913
+ const colorData06 = "rgb(194, 21, 101)";
1914
+ const fontWeightExtraBold = "800";
1915
+ const letterSpacingHeading = "-0.01rem";
1916
+ const fontFamilyHeadingTurva = "'turva-sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol'";
1917
+ const fontFamilyTextTurva = "'turva-sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol'";
1918
+ const fontFamilyHeading = "'localtapiola-sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol'";
1919
+ const fontFamilyText = "'localtapiola-sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol'";
1920
+ const fontWeightBold = "700";
1921
+ const fontWeightNormal = "400";
1922
+ const fontWeightSemiBold = "600";
1923
+ const fontSizeXxxxLarge = "4.5rem";
1924
+ const fontSizeXxxLarge = "3rem";
1925
+ const fontSizeXxLarge = "2.25rem";
1926
+ const fontSizeXLarge = "1.5rem";
1927
+ const fontSizeLarge = "1.25rem";
1928
+ const fontSizeMedium = "1rem";
1929
+ const fontSizeSmall = "0.875rem";
1930
+ const fontSizeXSmall = "0.75rem";
1931
+ const radiusSharp = "0";
1932
+ const radiusDefault = "4px";
1933
+ const radiusCircle = "50%";
1934
+ const radiusPill = "20rem";
1935
+ const shadowTooltipTurva = "0 2px 10px 0 rgba(117, 117, 117, 0.13)";
1936
+ const shadowDefault = "0 2px 6px 0 rgba(0, 41, 77, 0.07)";
1937
+ const shadowTooltip = "0 2px 10px 0 rgba(0, 41, 77, 0.07)";
1938
+ const shadowCardTurva = "0 2px 6px 0 rgba(117, 117, 117, 0.13), 0 -1px 0 0 rgba(0, 0, 0, 0.09), -1px 0 0 0 rgba(0, 0, 0, 0.07), 1px 0 0 0 rgba(0, 0, 0, 0.07), 0 1px 0 0 rgba(0, 0, 0, 0.07)";
1939
+ const shadowModal = "0 2px 20px 0 rgba(0, 0, 0, 0.2)";
1940
+ const shadowCard = "0 2px 6px 0 rgba(0, 41, 77, 0.07), 0 -1px 0 0 rgba(0, 0, 0, 0.09), -1px 0 0 0 rgba(0, 0, 0, 0.07), 1px 0 0 0 rgba(0, 0, 0, 0.07), 0 1px 0 0 rgba(0, 0, 0, 0.07)";
1941
+ const shadowHoverTurva = "0 2px 10px 0 rgba(117, 117, 117, 0.15)";
1942
+ const shadowHover = "0 2px 10px 0 rgba(0, 41, 77, 0.1)";
1943
+ const shadowDefaultTurva = "0 2px 6px 0 rgba(117, 117, 117, 0.13)";
1944
+ const spaceXxSmall = "4px";
1945
+ const spaceLarge = "20px";
1946
+ const spaceXSmall = "8px";
1947
+ const spaceXxxSmall = "2px";
1948
+ const spaceSmall = "12px";
1949
+ const spaceMedium = "16px";
1950
+ const spaceXxLarge = "36px";
1951
+ const spaceXxxxLarge = "72px";
1952
+ const spaceXxxxxLarge = "94px";
1953
+ const spaceXxxLarge = "48px";
1954
+ const spaceXLarge = "28px";
1955
+ const sizeIconXxLarge = "48px";
1956
+ const sizeFormBorder = "1px";
1957
+ const sizeStepMedium = "40px";
1958
+ const sizeButtonMinWidth = "8rem";
1959
+ const sizeHeader = "4rem";
1960
+ const sizeIconXxxLarge = "72px";
1961
+ const sizeIconXLarge = "36px";
1962
+ const sizeIconXxSmall = "10px";
1963
+ const sizeStepSmall = "30px";
1964
+ const sizeNavigation = "3rem";
1965
+ const sizeIconLarge = "30px";
1966
+ const sizeLayoutMaxWidth = "1110px";
1967
+ const sizeTappableSquare = "48px";
1968
+ const sizeIconXSmall = "16px";
1969
+ const sizeIconXxxSmall = "7px";
1970
+ const sizeButtonBorder = "2px";
1971
+ const sizeButtonTinyBorder = "1px";
1972
+ const sizeIconMedium = "24px";
1973
+ const sizeIconSmall = "20px";
1974
+ const opacity85 = "0.85";
1975
+ const opacity75 = "0.75";
1976
+ const opacity50 = "0.50";
1977
+ const opacity30 = "0.30";
1978
+ const zIndexDropdown = "600";
1979
+ const zIndexSpinner = "800";
1980
+ const zIndexDefault = "1";
1981
+ const zIndexToast = "500";
1982
+ const zIndexPopup = "950";
1983
+ const zIndexModal = "900";
1984
+ const zIndexSticky = "300";
1985
+ const zIndexMasked = "100";
1986
+ const zIndexDeep = "-999999";
1987
+ const zIndexOverlay = "700";
1988
+ const zIndexMask = "200";
1989
+ const zIndexHeader = "400";
1990
+ const lineHeightMedium = "1.5";
1991
+ const lineHeightSmall = "1.25";
1992
+ const lineHeightXSmall = "1.1";
1993
+ const transitionQuickly = "300ms ease";
1994
+ const transitionSlowly = "600ms ease";
1995
+ const mediaQueryXxSmall = "'(max-width: 22.5em)'";
1996
+ const mediaQueryXSmall = "'(max-width: 35.9375em)'";
1997
+ const mediaQuerySmall = "'(min-width: 36em)'";
1998
+ const mediaQueryMedium = "'(min-width: 48em)'";
1999
+ const mediaQueryLarge = "'(min-width: 62em)'";
2000
+ const mediaQueryXLarge = "'(min-width: 64.0625em)'";
2001
+ const mediaQueryXxLarge = "'(min-width: 76.25em)'";
2002
+ const mediaQueryXxxLarge = "'(min-width: 106.25em)'";
1800
2003
 
1801
- let DuetAlert$1 = class extends H {
1802
- constructor() {
1803
- super();
1804
- this.__registerHost();
1805
- this.__attachShadow();
1806
- this.duetDismiss = createEvent$2(this, "duetDismiss", 7);
1807
- /**
1808
- * Theme of the card.
1809
- */
1810
- this.theme = "";
1811
- /**
1812
- * State() variables
1813
- * Inlined decorator, alphabetical order.
1814
- */
1815
- this.isDismissed = false;
1816
- /**
1817
- * Property to change languageDefaults on the component.
1818
- * normally you would handle these strings on an application level and override @accessibleLabel when needed
1819
- * @default {fi: "Sulje viesti", sv: "Stäng meddelandet", en: "Close the message"}
1820
- */
1821
- this.accessibleLabelDefaults = {
1822
- fi: "Sulje viesti",
1823
- sv: "Stäng meddelandet",
1824
- en: "Close the message",
1825
- };
1826
- /**
1827
- * Adds accessible label for the dismissible alert close button.
1828
- * @default {fi: "Sulje viesti", sv: "Stäng meddelandet", en: "Close the message"}
1829
- */
1830
- this.accessibleLabel = getLocaleString(this.accessibleLabelDefaults);
1831
- /**
1832
- * Enable or disabled announcements by assistive technologies.
1833
- */
1834
- this.announcements = true;
1835
- /**
1836
- * Icon to display to the left of the content.
1837
- */
1838
- this.icon = "";
1839
- /**
1840
- * Controls the margin of the component.
1841
- */
1842
- this.margin = "auto";
1843
- /**
1844
- * Controls the padding of the component.
1845
- */
1846
- this.padding = "auto";
1847
- /**
1848
- * Style variation of the alert.
1849
- */
1850
- this.variation = "default";
1851
- /**
1852
- * Should a button be rendered to dismiss the alert?
1853
- */
1854
- this.dismissible = false;
1855
- this.handleDismiss = (ev) => {
1856
- this.isDismissed = true;
1857
- this.duetDismiss.emit({
1858
- component: "duet-alert",
1859
- originalEvent: ev,
1860
- });
1861
- };
1862
- }
1863
- /**
1864
- * Component lifecycle events.
1865
- */
1866
- componentWillLoad() {
1867
- inheritGlobalTheme(this);
1868
- }
1869
- componentDidLoad() {
1870
- if (this.autoDismiss) {
1871
- this.timeoutID = setTimeout(() => this.handleDismiss(), this.autoDismiss);
1872
- }
1873
- }
1874
- disconnectedCallback() {
1875
- if (this.timeoutID) {
1876
- clearTimeout(this.timeoutID);
1877
- }
2004
+ const tokens$2 = /*#__PURE__*/Object.freeze({
2005
+ __proto__: null,
2006
+ colorWarning: colorWarning,
2007
+ colorGrayDarker: colorGrayDarker,
2008
+ colorGrayLighter: colorGrayLighter,
2009
+ colorCategoryHome: colorCategoryHome,
2010
+ colorPrimary: colorPrimary,
2011
+ colorCategoryVehicle: colorCategoryVehicle,
2012
+ colorSuccess: colorSuccess,
2013
+ colorCategoryFamily: colorCategoryFamily,
2014
+ colorPrimaryLightest: colorPrimaryLightest,
2015
+ colorPrimaryLighter: colorPrimaryLighter,
2016
+ colorBrandBlue: colorBrandBlue,
2017
+ colorPrimaryDark: colorPrimaryDark,
2018
+ colorGrayLightest: colorGrayLightest,
2019
+ colorCategoryFinance: colorCategoryFinance,
2020
+ colorGrayDark: colorGrayDark,
2021
+ colorGrayLight: colorGrayLight,
2022
+ colorSecondary: colorSecondary,
2023
+ colorCategoryPet: colorCategoryPet,
2024
+ colorPrimaryLight: colorPrimaryLight,
2025
+ colorCategoryTravel: colorCategoryTravel,
2026
+ colorGray: colorGray,
2027
+ colorDanger: colorDanger,
2028
+ colorGrayDarkerTurva: colorGrayDarkerTurva,
2029
+ colorGrayLighterTurva: colorGrayLighterTurva,
2030
+ colorCategoryHomeTurva: colorCategoryHomeTurva,
2031
+ colorPrimaryTurva: colorPrimaryTurva,
2032
+ colorCategoryVehicleTurva: colorCategoryVehicleTurva,
2033
+ colorSuccessTurva: colorSuccessTurva,
2034
+ colorPrimaryLightestTurva: colorPrimaryLightestTurva,
2035
+ colorCategoryFamilyTurva: colorCategoryFamilyTurva,
2036
+ colorCategoryUnionTurva: colorCategoryUnionTurva,
2037
+ colorPrimaryLighterTurva: colorPrimaryLighterTurva,
2038
+ colorPrimaryDarkTurva: colorPrimaryDarkTurva,
2039
+ colorGrayLightestTurva: colorGrayLightestTurva,
2040
+ colorGrayDarkTurva: colorGrayDarkTurva,
2041
+ colorGrayLightTurva: colorGrayLightTurva,
2042
+ colorBrandGrayTurva: colorBrandGrayTurva,
2043
+ colorSecondaryTurva: colorSecondaryTurva,
2044
+ colorPrimaryLightTurva: colorPrimaryLightTurva,
2045
+ colorCategoryTravelTurva: colorCategoryTravelTurva,
2046
+ colorGrayTurva: colorGrayTurva,
2047
+ colorDangerTurva: colorDangerTurva,
2048
+ colorWarningTurva: colorWarningTurva,
2049
+ colorData07: colorData07,
2050
+ colorData08: colorData08,
2051
+ colorData09: colorData09,
2052
+ colorData10: colorData10,
2053
+ colorData11: colorData11,
2054
+ colorData01: colorData01,
2055
+ colorData12: colorData12,
2056
+ colorData02: colorData02,
2057
+ colorData13: colorData13,
2058
+ colorData03: colorData03,
2059
+ colorData14: colorData14,
2060
+ colorData04: colorData04,
2061
+ colorData15: colorData15,
2062
+ colorData05: colorData05,
2063
+ colorData06: colorData06,
2064
+ fontWeightExtraBold: fontWeightExtraBold,
2065
+ letterSpacingHeading: letterSpacingHeading,
2066
+ fontFamilyHeadingTurva: fontFamilyHeadingTurva,
2067
+ fontFamilyTextTurva: fontFamilyTextTurva,
2068
+ fontFamilyHeading: fontFamilyHeading,
2069
+ fontFamilyText: fontFamilyText,
2070
+ fontWeightBold: fontWeightBold,
2071
+ fontWeightNormal: fontWeightNormal,
2072
+ fontWeightSemiBold: fontWeightSemiBold,
2073
+ fontSizeXxxxLarge: fontSizeXxxxLarge,
2074
+ fontSizeXxxLarge: fontSizeXxxLarge,
2075
+ fontSizeXxLarge: fontSizeXxLarge,
2076
+ fontSizeXLarge: fontSizeXLarge,
2077
+ fontSizeLarge: fontSizeLarge,
2078
+ fontSizeMedium: fontSizeMedium,
2079
+ fontSizeSmall: fontSizeSmall,
2080
+ fontSizeXSmall: fontSizeXSmall,
2081
+ radiusSharp: radiusSharp,
2082
+ radiusDefault: radiusDefault,
2083
+ radiusCircle: radiusCircle,
2084
+ radiusPill: radiusPill,
2085
+ shadowTooltipTurva: shadowTooltipTurva,
2086
+ shadowDefault: shadowDefault,
2087
+ shadowTooltip: shadowTooltip,
2088
+ shadowCardTurva: shadowCardTurva,
2089
+ shadowModal: shadowModal,
2090
+ shadowCard: shadowCard,
2091
+ shadowHoverTurva: shadowHoverTurva,
2092
+ shadowHover: shadowHover,
2093
+ shadowDefaultTurva: shadowDefaultTurva,
2094
+ spaceXxSmall: spaceXxSmall,
2095
+ spaceLarge: spaceLarge,
2096
+ spaceXSmall: spaceXSmall,
2097
+ spaceXxxSmall: spaceXxxSmall,
2098
+ spaceSmall: spaceSmall,
2099
+ spaceMedium: spaceMedium,
2100
+ spaceXxLarge: spaceXxLarge,
2101
+ spaceXxxxLarge: spaceXxxxLarge,
2102
+ spaceXxxxxLarge: spaceXxxxxLarge,
2103
+ spaceXxxLarge: spaceXxxLarge,
2104
+ spaceXLarge: spaceXLarge,
2105
+ sizeIconXxLarge: sizeIconXxLarge,
2106
+ sizeFormBorder: sizeFormBorder,
2107
+ sizeStepMedium: sizeStepMedium,
2108
+ sizeButtonMinWidth: sizeButtonMinWidth,
2109
+ sizeHeader: sizeHeader,
2110
+ sizeIconXxxLarge: sizeIconXxxLarge,
2111
+ sizeIconXLarge: sizeIconXLarge,
2112
+ sizeIconXxSmall: sizeIconXxSmall,
2113
+ sizeStepSmall: sizeStepSmall,
2114
+ sizeNavigation: sizeNavigation,
2115
+ sizeIconLarge: sizeIconLarge,
2116
+ sizeLayoutMaxWidth: sizeLayoutMaxWidth,
2117
+ sizeTappableSquare: sizeTappableSquare,
2118
+ sizeIconXSmall: sizeIconXSmall,
2119
+ sizeIconXxxSmall: sizeIconXxxSmall,
2120
+ sizeButtonBorder: sizeButtonBorder,
2121
+ sizeButtonTinyBorder: sizeButtonTinyBorder,
2122
+ sizeIconMedium: sizeIconMedium,
2123
+ sizeIconSmall: sizeIconSmall,
2124
+ opacity85: opacity85,
2125
+ opacity75: opacity75,
2126
+ opacity50: opacity50,
2127
+ opacity30: opacity30,
2128
+ zIndexDropdown: zIndexDropdown,
2129
+ zIndexSpinner: zIndexSpinner,
2130
+ zIndexDefault: zIndexDefault,
2131
+ zIndexToast: zIndexToast,
2132
+ zIndexPopup: zIndexPopup,
2133
+ zIndexModal: zIndexModal,
2134
+ zIndexSticky: zIndexSticky,
2135
+ zIndexMasked: zIndexMasked,
2136
+ zIndexDeep: zIndexDeep,
2137
+ zIndexOverlay: zIndexOverlay,
2138
+ zIndexMask: zIndexMask,
2139
+ zIndexHeader: zIndexHeader,
2140
+ lineHeightMedium: lineHeightMedium,
2141
+ lineHeightSmall: lineHeightSmall,
2142
+ lineHeightXSmall: lineHeightXSmall,
2143
+ transitionQuickly: transitionQuickly,
2144
+ transitionSlowly: transitionSlowly,
2145
+ mediaQueryXxSmall: mediaQueryXxSmall,
2146
+ mediaQueryXSmall: mediaQueryXSmall,
2147
+ mediaQuerySmall: mediaQuerySmall,
2148
+ mediaQueryMedium: mediaQueryMedium,
2149
+ mediaQueryLarge: mediaQueryLarge,
2150
+ mediaQueryXLarge: mediaQueryXLarge,
2151
+ mediaQueryXxLarge: mediaQueryXxLarge,
2152
+ mediaQueryXxxLarge: mediaQueryXxxLarge
2153
+ });
2154
+
2155
+ const allowedThemes = ["turva"];
2156
+ function isDashCase(str) {
2157
+ const dash = str.includes("-");
2158
+ const barredString = str.includes(" ") || str.includes("_");
2159
+ const barredStartingString = str.charAt(0) === "-";
2160
+ return dash && !barredString && !barredStartingString;
2161
+ }
2162
+ function capitalize(str = "") {
2163
+ return `${str.charAt(0).toUpperCase()}${str.slice(1)}`;
2164
+ }
2165
+ function lowerCaseFirst(str = "") {
2166
+ return `${str.charAt(0).toLowerCase()}${str.slice(1)}`;
2167
+ }
2168
+ function camelize(str = "") {
2169
+ const arr = str.split("-");
2170
+ //loop through each element of the array and capitalize the first letter.'
2171
+ arr.forEach((string, index) => {
2172
+ arr[index] = capitalize(string);
2173
+ });
2174
+ return arr.join("");
2175
+ }
2176
+ function getTheme(theme = "") {
2177
+ if (allowedThemes.includes(theme.toLowerCase())) {
2178
+ return theme.toLowerCase();
1878
2179
  }
1879
- /**
1880
- * render() function
1881
- * Always the last one in the class.
1882
- */
1883
- render() {
1884
- const closeColor = this.theme === "turva" ? "secondary-turva" : "secondary";
1885
- const role = this.variation === "danger" || this.variation === "warning" ? "alert" : "status";
1886
- return (h$1(Host, { tabindex: "0", class: { "duet-theme-turva": this.theme === "turva", "duet-alert-is-dismissed": this.isDismissed }, role: this.announcements ? role : undefined }, h$1("div", { class: {
1887
- "duet-alert": true,
1888
- "duet-alert-has-icon": !!this.icon,
1889
- "duet-alert-is-dismissible": this.dismissible,
1890
- "duet-p-0": this.padding === "none",
1891
- "duet-m-0": this.margin === "none",
1892
- [this.variation]: true,
1893
- "duet-theme-turva": this.theme === "turva",
1894
- } }, h$1("div", { class: "duet-alert-container" }, this.icon && (h$1("div", { class: "duet-alert-icon" }, h$1("duet-icon", { size: "auto", name: this.icon, color: "currentColor" }))), h$1("span", null, h$1("slot", null))), this.dismissible && (h$1("div", { class: "duet-alert-dismiss" }, h$1("duet-button", { variation: "plain", accessibleLabel: this.accessibleLabel, color: closeColor, iconSize: "medium", icon: "navigation-close", iconOnly: true, margin: "none", theme: this.theme, onClick: this.handleDismiss, fixed: true }))))));
2180
+ return "";
2181
+ }
2182
+ function capitalizeFirstLetter(string) {
2183
+ return string.charAt(0).toUpperCase() + string.slice(1);
2184
+ }
2185
+ function hasType(t, str = "") {
2186
+ return str.indexOf(capitalizeFirstLetter(t)) === 0 || str.indexOf(t) === 0;
2187
+ }
2188
+ function addPrefix(prefix, str = "") {
2189
+ if (str && !isDashCase(str) && !hasType(prefix, str)) {
2190
+ return `${prefix}${capitalize(str)}`;
1895
2191
  }
1896
- static get style() { return duetAlertCss; }
1897
- };
2192
+ return str;
2193
+ }
2194
+ function addTheme(str, theme) {
2195
+ const hasTheme = getTheme(theme).length;
2196
+ if (hasTheme && str.indexOf(theme) === -1) {
2197
+ return `${str}${capitalize(theme)}`;
2198
+ }
2199
+ return str;
2200
+ }
2201
+ function getColorByName(name, theme = "") {
2202
+ if (!name) {
2203
+ return undefined;
2204
+ }
2205
+ const defaultColor = convertToColorName(name);
2206
+ const themedColor = convertToColorName(name, theme);
2207
+ // lets just try to get the color first to save some cycles
2208
+ let resolvedToken = tokens$2[themedColor];
2209
+ if (!resolvedToken) {
2210
+ resolvedToken = tokens$2[defaultColor];
2211
+ }
2212
+ return resolvedToken;
2213
+ }
2214
+ function convertToColorName(name = "", theme = "") {
2215
+ let colorResolution = name;
2216
+ const dash = isDashCase(name);
2217
+ if (dash) {
2218
+ colorResolution = camelize(colorResolution);
2219
+ }
2220
+ colorResolution = addPrefix("color", colorResolution);
2221
+ colorResolution = addTheme(colorResolution, theme);
2222
+ // takes care of the case where colorPrimaryDark ends up with ColorPrimaryDark
2223
+ colorResolution = lowerCaseFirst(colorResolution);
2224
+ return colorResolution;
2225
+ }
1898
2226
 
1899
- const duetBadgeCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-right:4px !important;margin-bottom:2px !important;display:inline-block;width:auto;vertical-align:middle}:host:last-child,:host:last-of-type{margin-right:0 !important}:host(.duet-m-0){margin:0 !important}.duet-badge{width:100%;padding:4.4444444444px 12px 5.4444444444px;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:0.75rem;font-style:normal;font-weight:600;line-height:1.25;color:#00294d;text-align:center;word-break:break-word;vertical-align:middle;background:#e6f1f7;border-radius:20rem}.duet-badge.duet-p-0{padding:0 !important}.duet-badge.duet-m-0{margin:0 !important}.duet-badge.duet-theme-turva{padding:5.4444444444px 12px 4.4444444444px;font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-weight:700;color:#171c3a;background:#e8e8eb}.duet-badge.warning{background:#fef3df}.duet-badge.warning.duet-theme-turva{background:#fef1db}.duet-badge.danger{background:#fce9ef}.duet-badge.danger.duet-theme-turva{background:#fceae7}.duet-badge.success{background:#e6f3ef}.duet-badge.success.duet-theme-turva{background:#e6f3ed}";
2227
+ const duetActionButtonCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:inline-block;margin:0 auto}button.duet-action-button{white-space:nowrap}button.duet-action-button{display:inline-flex;align-items:center;justify-content:center;width:32px;height:32px;min-height:auto !important;padding:0 !important;margin:0 0 0 8px !important;color:#00294d;cursor:pointer;background:#f5f8fa;border-radius:50%;transition:background-color 300ms ease !important}.duet-theme-turva button.duet-action-button{color:#171c3a;background:#f5f5f7}button.duet-action-button duet-icon{display:block}@media (max-width: 35.9375em){button.duet-action-button{width:32px;height:32px}}button.duet-action-button:not(:disabled):hover{background:#e9ecee !important}.duet-theme-turva button.duet-action-button:not(:disabled):hover{background:#e9e9eb !important}button.duet-action-button:focus{outline:0;box-shadow:0 0 0 2px #0077b3 !important}.duet-theme-turva button.duet-action-button:focus{box-shadow:0 0 0 2px #171c3a !important}button.duet-action-button:active:focus{background:#dddfe1 !important;box-shadow:none}.duet-theme-turva button.duet-action-button:active:focus{background:#ddddde !important}button.duet-action-button:disabled{color:#909599;cursor:default;background:#f5f8fa;opacity:0.75}.duet-theme-turva button.duet-action-button:disabled{color:#747475;background:#f5f5f7}";
1900
2228
 
1901
- let DuetBadge$1 = class extends H {
2229
+ let DuetActionButton$1 = class extends H {
1902
2230
  constructor() {
1903
2231
  super();
1904
2232
  this.__registerHost();
1905
2233
  this.__attachShadow();
2234
+ this.duetActionEvent = createEvent$2(this, "duetActionEvent", 6);
2235
+ this.numbersStore = "";
1906
2236
  /**
1907
- * Theme of the badge.
2237
+ * Theme of the pagination.
1908
2238
  */
1909
2239
  this.theme = "";
1910
2240
  /**
1911
- * Style variation of the alert.
2241
+ * Name of the icon to display
1912
2242
  */
1913
- this.variation = "default";
2243
+ this.iconName = "action-arrow-left-small";
1914
2244
  /**
1915
- * Controls the margin of the component.
2245
+ * Color of the icon to display
1916
2246
  */
1917
- this.margin = "auto";
1918
- }
1919
- /**
1920
- * Component lifecycle events.
1921
- */
1922
- componentWillLoad() {
1923
- inheritGlobalTheme(this);
1924
- }
1925
- /**
1926
- * render() function
1927
- * Always the last one of the class.
1928
- */
1929
- render() {
1930
- return (h$1(Host, { class: { "duet-m-0": this.margin === "none" } }, h$1("div", { class: {
1931
- "duet-badge": true,
1932
- [this.variation]: true,
1933
- "duet-theme-turva": this.theme === "turva",
1934
- } }, h$1("slot", null))));
2247
+ this.iconColor = "currentColor";
2248
+ /**
2249
+ * Size of the icon
2250
+ */
2251
+ this.iconSize = "xx-small";
2252
+ /**
2253
+ * Name of action being called
2254
+ */
2255
+ this.actionName = "default-action";
2256
+ /**
2257
+ * Name of id of action that was called being called
2258
+ */
2259
+ this.actionId = undefined;
2260
+ /**
2261
+ * Name of id of action that was called being called
2262
+ */
2263
+ this.actionMeta = undefined;
2264
+ /**
2265
+ * Disables the button
2266
+ */
2267
+ this.disabled = false;
2268
+ /**
2269
+ * Custom color to be used for the icon, as a design token entered in camelCase
2270
+ * or kebab-case. Example: "color-primary". This property can also be set to
2271
+ * "currentColor" which forces the icon to use the CSS text color of parent
2272
+ * element instead. Useful when you want to control the color in stylesheet
2273
+ * instead.
2274
+ */
2275
+ this.color = "";
2276
+ /**
2277
+ * Custom color to be used for a background, as a design token entered
2278
+ * in camelCase or kebab-case. Using this option the icon will always be resized
2279
+ * to $size-icon-medium on mobile viewports. Example: "color-primary".
2280
+ */
2281
+ this.background = "";
2282
+ /**
2283
+ * Described By id
2284
+ */
2285
+ this.ariaDescribedBy = undefined;
2286
+ /**
2287
+ * Aria description the button
2288
+ */
2289
+ this.ariaDescription = undefined;
2290
+ /**
2291
+ * Default pagination labels
2292
+ */
2293
+ this.ariaLabelsDefaults = {
2294
+ en: {
2295
+ label: "Click to activate action",
2296
+ },
2297
+ fi: {
2298
+ label: "Klikkaa toiminnon aktivointiin",
2299
+ },
2300
+ sv: {
2301
+ label: "Klicka för att aktivera åtgärd",
2302
+ },
2303
+ };
2304
+ /**
2305
+ * Default pagination labels
2306
+ */
2307
+ this.ariaLabels = getLocaleString(this.ariaLabelsDefaults);
2308
+ /**
2309
+ * Used to indicate which dom element with ID this element controls
2310
+ */
2311
+ this.ariaControls = "";
2312
+ this.listId = createID("duet-action-button");
2313
+ /**
2314
+ * Private methods.
2315
+ */
2316
+ //helper to emit relevant page events
2317
+ this.emitPageEvent = debounce(e => {
2318
+ this.duetActionEvent.emit({
2319
+ component: "duet-action-button",
2320
+ originalEvent: e,
2321
+ action: this.actionId,
2322
+ name: this.actionName,
2323
+ meta: this.actionMeta,
2324
+ id: this.listId,
2325
+ });
2326
+ });
1935
2327
  }
1936
- static get style() { return duetBadgeCss; }
2328
+ //handle a11y keyboard navigation events
2329
+ async onKeyboardDown(e) {
2330
+ if (isKeyboardClick(e)) {
2331
+ this.emitPageEvent(e);
2332
+ }
2333
+ }
2334
+ //set update current when mouse click on page number
2335
+ async onMouseHandler(e) {
2336
+ e.preventDefault();
2337
+ this.duetActionEvent.emit({
2338
+ component: "duet-action-button",
2339
+ originalEvent: e,
2340
+ action: this.actionName,
2341
+ id: this.actionId,
2342
+ meta: this.actionMeta,
2343
+ });
2344
+ }
2345
+ /**
2346
+ * Component lifecycle events.
2347
+ */
2348
+ componentWillLoad() {
2349
+ inheritGlobalTheme(this);
2350
+ }
2351
+ /**
2352
+ * render() function
2353
+ * Always the last one in the class.
2354
+ */
2355
+ render() {
2356
+ const color = this.color === "currentColor" ? "currentColor" : getColorByName(this.color, this.theme);
2357
+ const styles = {
2358
+ color,
2359
+ background: getColorByName(this.background, this.theme),
2360
+ "border-color": getColorByName(this.iconColor, this.theme),
2361
+ "border-width": "1px",
2362
+ "border-style": "solid",
2363
+ };
2364
+ return (h$1(Host, { onKeyDown: e => this.onKeyboardDown(e) }, h$1("button", { part: "button", style: styles, disabled: this.disabled, id: this.listId, class: {
2365
+ "duet-action-button": true,
2366
+ "duet-action-button--disabled": this.disabled,
2367
+ [`duet-action-button--${this.theme}`]: this.theme !== "",
2368
+ }, type: "button", onClick: e => this.onMouseHandler(e), "aria-label": this.ariaLabels.label, "aria-description": this.ariaDescription, "aria-describedby": this.ariaDescribedBy, "aria-controls": this.ariaControls }, h$1("duet-icon", { part: "icon", name: this.iconName, color: this.iconColor, margin: "none", size: this.iconSize }), h$1("duet-visually-hidden", null, h$1("slot", null)))));
2369
+ }
2370
+ get element() { return this; }
2371
+ static get style() { return duetActionButtonCss; }
1937
2372
  };
1938
2373
 
1939
- const duetBreadcrumbCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:block;width:100%}.duet-breadcrumb{display:flex;flex-direction:row;align-items:center;justify-content:flex-start;height:100%;font-size:0.875rem;color:#00294d;text-decoration:none}.duet-breadcrumb:hover{color:#004d80}.duet-breadcrumb.duet-theme-turva{color:#171c3a}.duet-breadcrumb.duet-theme-turva:hover{color:#940925}.duet-breadcrumb:focus{outline:0}.duet-breadcrumb:active{opacity:0.75}:host(.user-is-tabbing) .duet-breadcrumb:focus{box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}:host(.user-is-tabbing) .duet-breadcrumb.duet-theme-turva:focus{box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}";
2374
+ const duetAlertCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:block;width:100%;max-height:999px;border-radius:4px;transition:opacity 300ms ease, visibility 300ms ease, transform 300ms ease, max-height 300ms ease}:host(:focus){outline:0}:host(.user-is-tabbing:focus){border-radius:4px;box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}:host(.user-is-tabbing.duet-theme-turva:focus){box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}:host(.duet-alert-is-dismissed){max-height:0;visibility:hidden;opacity:0;transform:scale(0.98)}:host(.duet-alert-is-dismissed) .duet-alert{margin:0 !important}.duet-alert{margin-bottom:16px !important;position:relative;width:100%;padding:16px;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;font-weight:400;line-height:1.25;color:#00294d;background:#f2f8fb;border:1px solid #0077b3;border-radius:4px;transition:margin 100ms 300ms ease}.duet-alert.duet-p-0{padding:0 !important}.duet-alert.duet-m-0{margin:0 !important}.duet-alert.duet-theme-turva{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#171c3a;background:#f3f4f5;border-color:#171c3a}.duet-alert.warning{background:#fffbf4;border-color:#f7b228}.duet-alert.warning.duet-theme-turva{background:#fffaf3;border-color:#faa40f}.duet-alert.danger{background:#fdf4f7;border-color:#de2362}.duet-alert.danger.duet-theme-turva{background:#fdf4f3;border-color:#e02a0d}.duet-alert.success{background:#f2f9f7;border-color:#00875a}.duet-alert.success.duet-theme-turva{background:#f3f9f6;border-color:#08874e}.duet-alert-dismiss{position:absolute;top:2px;right:2px}.duet-alert-container{display:inline-flex;align-items:center;justify-content:center;width:100%;margin:0 auto !important}.duet-alert-container span{width:100%}.duet-alert-has-icon .duet-alert-container{margin-top:2px !important}.duet-alert-icon{display:inline-block;align-self:center;width:20px;min-width:20px;height:20px;margin:0 16px 0 0 !important}.duet-alert-icon duet-icon{width:20px;height:20px}.duet-alert-is-dismissible{padding:16px 48px 16px 16px;text-align:left}.duet-alert-is-dismissible .duet-alert-container{text-align:left}";
1940
2375
 
1941
- let DuetBreadcrumb$1 = class extends H {
2376
+ let DuetAlert$1 = class extends H {
1942
2377
  constructor() {
1943
2378
  super();
1944
2379
  this.__registerHost();
1945
2380
  this.__attachShadow();
2381
+ this.duetDismiss = createEvent$2(this, "duetDismiss", 7);
1946
2382
  /**
1947
- * Theme
2383
+ * Theme of the card.
1948
2384
  */
1949
2385
  this.theme = "";
1950
2386
  /**
1951
- * Href
2387
+ * State() variables
2388
+ * Inlined decorator, alphabetical order.
1952
2389
  */
1953
- this.href = "";
2390
+ this.isDismissed = false;
1954
2391
  /**
1955
- * Icon
2392
+ * Property to change languageDefaults on the component.
2393
+ * normally you would handle these strings on an application level and override @accessibleLabel when needed
2394
+ * @default {fi: "Sulje viesti", sv: "Stäng meddelandet", en: "Close the message"}
2395
+ */
2396
+ this.accessibleLabelDefaults = {
2397
+ fi: "Sulje viesti",
2398
+ sv: "Stäng meddelandet",
2399
+ en: "Close the message",
2400
+ };
2401
+ /**
2402
+ * Adds accessible label for the dismissible alert close button.
2403
+ * @default {fi: "Sulje viesti", sv: "Stäng meddelandet", en: "Close the message"}
2404
+ */
2405
+ this.accessibleLabel = getLocaleString(this.accessibleLabelDefaults);
2406
+ /**
2407
+ * Enable or disabled announcements by assistive technologies.
2408
+ */
2409
+ this.announcements = true;
2410
+ /**
2411
+ * Icon to display to the left of the content.
1956
2412
  */
1957
2413
  this.icon = "";
2414
+ /**
2415
+ * Controls the margin of the component.
2416
+ */
2417
+ this.margin = "auto";
2418
+ /**
2419
+ * Controls the padding of the component.
2420
+ */
2421
+ this.padding = "auto";
2422
+ /**
2423
+ * Style variation of the alert.
2424
+ */
2425
+ this.variation = "default";
2426
+ /**
2427
+ * Should a button be rendered to dismiss the alert?
2428
+ */
2429
+ this.dismissible = false;
2430
+ this.handleDismiss = (ev) => {
2431
+ this.isDismissed = true;
2432
+ this.duetDismiss.emit({
2433
+ component: "duet-alert",
2434
+ originalEvent: ev,
2435
+ });
2436
+ };
1958
2437
  }
1959
2438
  /**
1960
2439
  * Component lifecycle events.
@@ -1962,451 +2441,179 @@ let DuetBreadcrumb$1 = class extends H {
1962
2441
  componentWillLoad() {
1963
2442
  inheritGlobalTheme(this);
1964
2443
  }
2444
+ componentDidLoad() {
2445
+ if (this.autoDismiss) {
2446
+ this.timeoutID = setTimeout(() => this.handleDismiss(), this.autoDismiss);
2447
+ }
2448
+ }
2449
+ disconnectedCallback() {
2450
+ if (this.timeoutID) {
2451
+ clearTimeout(this.timeoutID);
2452
+ }
2453
+ }
1965
2454
  /**
1966
2455
  * render() function
1967
2456
  * Always the last one in the class.
1968
2457
  */
1969
2458
  render() {
1970
- return (h$1(Host, null, h$1("a", { class: {
1971
- "duet-breadcrumb": true,
2459
+ const closeColor = this.theme === "turva" ? "secondary-turva" : "secondary";
2460
+ const role = this.variation === "danger" || this.variation === "warning" ? "alert" : "status";
2461
+ return (h$1(Host, { tabindex: "0", class: { "duet-theme-turva": this.theme === "turva", "duet-alert-is-dismissed": this.isDismissed }, role: this.announcements ? role : undefined }, h$1("div", { class: {
2462
+ "duet-alert": true,
2463
+ "duet-alert-has-icon": !!this.icon,
2464
+ "duet-alert-is-dismissible": this.dismissible,
2465
+ "duet-p-0": this.padding === "none",
2466
+ "duet-m-0": this.margin === "none",
2467
+ [this.variation]: true,
1972
2468
  "duet-theme-turva": this.theme === "turva",
1973
- }, href: this.href, "aria-label": this.accessibleLabel }, this.icon && h$1("duet-icon", { size: "x-small", name: this.icon, margin: "none", color: "currentColor" }), !this.icon && h$1("slot", null))));
2469
+ } }, h$1("div", { class: "duet-alert-container" }, this.icon && (h$1("div", { class: "duet-alert-icon" }, h$1("duet-icon", { size: "auto", name: this.icon, color: "currentColor" }))), h$1("span", null, h$1("slot", null))), this.dismissible && (h$1("div", { class: "duet-alert-dismiss" }, h$1("duet-button", { variation: "plain", accessibleLabel: this.accessibleLabel, color: closeColor, iconSize: "medium", icon: "navigation-close", iconOnly: true, margin: "none", theme: this.theme, onClick: this.handleDismiss, fixed: true }))))));
1974
2470
  }
1975
- static get style() { return duetBreadcrumbCss; }
2471
+ static get style() { return duetAlertCss; }
1976
2472
  };
1977
2473
 
1978
- var actionArrowRightSmall={"title":"action-arrow-right-small","tags":"action arrow right small caret","svg":"<svg fill=\"currentColor\" viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\" role=\"img\"><path d=\"M19.5 12a2.3 2.3 0 0 1-.78 1.729L7.568 23.54a1.847 1.847 0 0 1-2.439-2.773l9.752-8.579a.25.25 0 0 0 0-.376L5.129 3.233A1.847 1.847 0 0 1 7.568.46l11.148 9.808A2.31 2.31 0 0 1 19.5 12z\"/></svg>"};
1979
-
1980
- const duetBreadcrumbsCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:block}.duet-breadcrumbs{font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"}.duet-breadcrumbs ol{display:flex;flex-direction:row;flex-wrap:wrap;gap:8px;align-items:center;justify-content:flex-start;padding:10px 16px;color:#00294d;list-style:none;background:#f3f9fc;border-bottom:1px solid #e1e3e6}@media (min-width: 62em){.duet-breadcrumbs ol{padding:10px 36px}}.duet-breadcrumbs.duet-theme-turva{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"}.duet-breadcrumbs.duet-theme-turva ol{color:#171c3a;background:#fcf3f4}.duet-breadcrumbs .duet-breadrumbs-arrow{display:inherit;align-items:center;justify-content:center;width:0.375rem;height:0.375rem}.duet-breadcrumbs .hide{display:none}";
2474
+ const duetBadgeCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-right:4px !important;margin-bottom:2px !important;display:inline-block;width:auto;vertical-align:middle}:host:last-child,:host:last-of-type{margin-right:0 !important}:host(.duet-m-0){margin:0 !important}.duet-badge{width:100%;padding:4.4444444444px 12px 5.4444444444px;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:0.75rem;font-style:normal;font-weight:600;line-height:1.25;color:#00294d;text-align:center;word-break:break-word;vertical-align:middle;background:#e6f1f7;border-radius:20rem}.duet-badge.duet-p-0{padding:0 !important}.duet-badge.duet-m-0{margin:0 !important}.duet-badge.duet-theme-turva{padding:5.4444444444px 12px 4.4444444444px;font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-weight:700;color:#171c3a;background:#e8e8eb}.duet-badge.warning{background:#fef3df}.duet-badge.warning.duet-theme-turva{background:#fef1db}.duet-badge.danger{background:#fce9ef}.duet-badge.danger.duet-theme-turva{background:#fceae7}.duet-badge.success{background:#e6f3ef}.duet-badge.success.duet-theme-turva{background:#e6f3ed}";
1981
2475
 
1982
- let DuetBreadcrumbs$1 = class extends H {
2476
+ let DuetBadge$1 = class extends H {
1983
2477
  constructor() {
1984
2478
  super();
1985
2479
  this.__registerHost();
1986
2480
  this.__attachShadow();
1987
- this.observers = [];
1988
- this.breadcrumbsAriaLabel = getLocaleString({
1989
- fi: "Murupolku",
1990
- sv: "Ströbröd",
1991
- en: "Breadcrumbs",
1992
- });
1993
2481
  /**
1994
- * Theme
2482
+ * Theme of the badge.
1995
2483
  */
1996
2484
  this.theme = "";
2485
+ /**
2486
+ * Style variation of the alert.
2487
+ */
2488
+ this.variation = "default";
2489
+ /**
2490
+ * Controls the margin of the component.
2491
+ */
2492
+ this.margin = "auto";
1997
2493
  }
1998
2494
  /**
1999
2495
  * Component lifecycle events.
2000
2496
  */
2001
2497
  componentWillLoad() {
2002
2498
  inheritGlobalTheme(this);
2003
- this.children = Array.from(this.element.children);
2004
2499
  }
2005
- connectedCallback() {
2006
- Array.from(this.element.children).forEach(child => {
2007
- const observer = new MutationObserver(() => (this.children = Array.from(this.element.children)));
2008
- observer.observe(child, {
2009
- childList: true,
2010
- subtree: true,
2011
- attributes: true,
2012
- characterData: true,
2013
- });
2014
- this.observers = [...this.observers, observer];
2015
- });
2500
+ /**
2501
+ * render() function
2502
+ * Always the last one of the class.
2503
+ */
2504
+ render() {
2505
+ return (h$1(Host, { class: { "duet-m-0": this.margin === "none" } }, h$1("div", { class: {
2506
+ "duet-badge": true,
2507
+ [this.variation]: true,
2508
+ "duet-theme-turva": this.theme === "turva",
2509
+ } }, h$1("slot", null))));
2016
2510
  }
2017
- disconnectedCallback() {
2018
- this.observers.forEach(observer => observer.disconnect());
2019
- this.observers = [];
2511
+ static get style() { return duetBadgeCss; }
2512
+ };
2513
+
2514
+ const duetBreadcrumbCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:block;width:100%}.duet-breadcrumb{display:flex;flex-direction:row;align-items:center;justify-content:flex-start;height:100%;font-size:0.875rem;color:#00294d;text-decoration:none}.duet-breadcrumb:hover{color:#004d80}.duet-breadcrumb.duet-theme-turva{color:#171c3a}.duet-breadcrumb.duet-theme-turva:hover{color:#940925}.duet-breadcrumb:focus{outline:0}.duet-breadcrumb:active{opacity:0.75}:host(.user-is-tabbing) .duet-breadcrumb:focus{box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}:host(.user-is-tabbing) .duet-breadcrumb.duet-theme-turva:focus{box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}";
2515
+
2516
+ let DuetBreadcrumb$1 = class extends H {
2517
+ constructor() {
2518
+ super();
2519
+ this.__registerHost();
2520
+ this.__attachShadow();
2521
+ /**
2522
+ * Theme
2523
+ */
2524
+ this.theme = "";
2525
+ /**
2526
+ * Href
2527
+ */
2528
+ this.href = "";
2529
+ /**
2530
+ * Icon
2531
+ */
2532
+ this.icon = "";
2533
+ }
2534
+ /**
2535
+ * Component lifecycle events.
2536
+ */
2537
+ componentWillLoad() {
2538
+ inheritGlobalTheme(this);
2020
2539
  }
2021
2540
  /**
2022
2541
  * render() function
2023
2542
  * Always the last one in the class.
2024
2543
  */
2025
2544
  render() {
2026
- return (h$1(Host, null, h$1("nav", { "aria-label": this.breadcrumbsAriaLabel, class: {
2027
- "duet-breadcrumbs": true,
2545
+ return (h$1(Host, null, h$1("a", { class: {
2546
+ "duet-breadcrumb": true,
2028
2547
  "duet-theme-turva": this.theme === "turva",
2029
- } }, h$1("ol", null, this.children.map((child, index) => (h$1(Fragment, null, index > 0 && (h$1("li", { "aria-hidden": "true" }, h$1("duet-icon", { class: "duet-breadrumbs-arrow", size: "auto", icon: actionArrowRightSmall.svg, margin: "none", color: "currentColor" }))), h$1("li", { innerHTML: child.outerHTML }), h$1("div", { class: "hide" }, h$1("slot", null)))))))));
2548
+ }, href: this.href, "aria-label": this.accessibleLabel }, this.icon && h$1("duet-icon", { size: "x-small", name: this.icon, margin: "none", color: "currentColor" }), !this.icon && h$1("slot", null))));
2030
2549
  }
2031
- get element() { return this; }
2032
- static get style() { return duetBreadcrumbsCss; }
2550
+ static get style() { return duetBreadcrumbCss; }
2033
2551
  };
2034
2552
 
2035
- const DuetStringsExternalDefaults = {
2036
- fi: "Avautuu uuteen ikkunaan",
2037
- sv: "Öppnas i nytt fönster",
2038
- en: "Opens in a new window",
2039
- };
2553
+ var actionArrowRightSmall={"title":"action-arrow-right-small","tags":"action arrow right small caret","svg":"<svg fill=\"currentColor\" viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\" role=\"img\"><path d=\"M19.5 12a2.3 2.3 0 0 1-.78 1.729L7.568 23.54a1.847 1.847 0 0 1-2.439-2.773l9.752-8.579a.25.25 0 0 0 0-.376L5.129 3.233A1.847 1.847 0 0 1 7.568.46l11.148 9.808A2.31 2.31 0 0 1 19.5 12z\"/></svg>"};
2040
2554
 
2041
- const colorWarning = "rgb(247, 178, 40)";
2042
- const colorGrayDarker = "rgb(101, 119, 135)";
2043
- const colorGrayLighter = "rgb(245, 248, 250)";
2044
- const colorCategoryHome = "rgb(211, 36, 131)";
2045
- const colorPrimary = "rgb(0, 119, 179)";
2046
- const colorCategoryVehicle = "rgb(54, 74, 129)";
2047
- const colorSuccess = "rgb(0, 135, 90)";
2048
- const colorCategoryFamily = "rgb(11, 114, 136)";
2049
- const colorPrimaryLightest = "rgb(243, 249, 252)";
2050
- const colorPrimaryLighter = "rgb(230, 242, 248)";
2051
- const colorBrandBlue = "rgb(0, 161, 212)";
2052
- const colorPrimaryDark = "rgb(0, 77, 128)";
2053
- const colorGrayLightest = "rgb(255, 255, 255)";
2054
- const colorCategoryFinance = "rgb(122, 1, 196)";
2055
- const colorGrayDark = "rgb(144, 149, 153)";
2056
- const colorGrayLight = "rgb(225, 227, 230)";
2057
- const colorSecondary = "rgb(0, 41, 77)";
2058
- const colorCategoryPet = "rgb(168, 1, 78)";
2059
- const colorPrimaryLight = "rgb(205, 229, 241)";
2060
- const colorCategoryTravel = "rgb(213, 66, 3)";
2061
- const colorGray = "rgb(207, 210, 212)";
2062
- const colorDanger = "rgb(222, 35, 98)";
2063
- const colorGrayDarkerTurva = "rgb(68, 68, 69)";
2064
- const colorGrayLighterTurva = "rgb(245, 245, 247)";
2065
- const colorCategoryHomeTurva = "rgb(161, 10, 78)";
2066
- const colorPrimaryTurva = "rgb(198, 12, 48)";
2067
- const colorCategoryVehicleTurva = "rgb(23, 28, 58)";
2068
- const colorSuccessTurva = "rgb(8, 135, 78)";
2069
- const colorPrimaryLightestTurva = "rgb(252, 243, 244)";
2070
- const colorCategoryFamilyTurva = "rgb(199, 12, 112)";
2071
- const colorCategoryUnionTurva = "rgb(169, 69, 124)";
2072
- const colorPrimaryLighterTurva = "rgb(249, 230, 234)";
2073
- const colorPrimaryDarkTurva = "rgb(148, 9, 37)";
2074
- const colorGrayLightestTurva = "rgb(255, 255, 255)";
2075
- const colorGrayDarkTurva = "rgb(116, 116, 117)";
2076
- const colorGrayLightTurva = "rgb(228, 228, 230)";
2077
- const colorBrandGrayTurva = "rgb(178, 180, 179)";
2078
- const colorSecondaryTurva = "rgb(23, 28, 58)";
2079
- const colorPrimaryLightTurva = "rgb(244, 207, 214)";
2080
- const colorCategoryTravelTurva = "rgb(9, 129, 148)";
2081
- const colorGrayTurva = "rgb(207, 207, 209)";
2082
- const colorDangerTurva = "rgb(224, 42, 13)";
2083
- const colorWarningTurva = "rgb(250, 164, 15)";
2084
- const colorData07 = "rgb(192, 101, 247)";
2085
- const colorData08 = "rgb(0, 105, 191)";
2086
- const colorData09 = "rgb(19, 120, 53)";
2087
- const colorData10 = "rgb(179, 60, 24)";
2088
- const colorData11 = "rgb(13, 163, 166)";
2089
- const colorData01 = "rgb(122, 1, 196)";
2090
- const colorData12 = "rgb(11, 114, 136)";
2091
- const colorData02 = "rgb(0, 155, 204)";
2092
- const colorData13 = "rgb(179, 137, 24)";
2093
- const colorData03 = "rgb(27, 171, 75)";
2094
- const colorData14 = "rgb(128, 98, 17)";
2095
- const colorData04 = "rgb(255, 86, 34)";
2096
- const colorData15 = "rgb(0, 41, 77)";
2097
- const colorData05 = "rgb(245, 76, 154)";
2098
- const colorData06 = "rgb(194, 21, 101)";
2099
- const fontWeightExtraBold = "800";
2100
- const letterSpacingHeading = "-0.01rem";
2101
- const fontFamilyHeadingTurva = "'turva-sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol'";
2102
- const fontFamilyTextTurva = "'turva-sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol'";
2103
- const fontFamilyHeading = "'localtapiola-sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol'";
2104
- const fontFamilyText = "'localtapiola-sans', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Helvetica, Arial, sans-serif, 'Apple Color Emoji', 'Segoe UI Emoji', 'Segoe UI Symbol'";
2105
- const fontWeightBold = "700";
2106
- const fontWeightNormal = "400";
2107
- const fontWeightSemiBold = "600";
2108
- const fontSizeXxxxLarge = "4.5rem";
2109
- const fontSizeXxxLarge = "3rem";
2110
- const fontSizeXxLarge = "2.25rem";
2111
- const fontSizeXLarge = "1.5rem";
2112
- const fontSizeLarge = "1.25rem";
2113
- const fontSizeMedium = "1rem";
2114
- const fontSizeSmall = "0.875rem";
2115
- const fontSizeXSmall = "0.75rem";
2116
- const radiusSharp = "0";
2117
- const radiusDefault = "4px";
2118
- const radiusCircle = "50%";
2119
- const radiusPill = "20rem";
2120
- const shadowTooltipTurva = "0 2px 10px 0 rgba(117, 117, 117, 0.13)";
2121
- const shadowDefault = "0 2px 6px 0 rgba(0, 41, 77, 0.07)";
2122
- const shadowTooltip = "0 2px 10px 0 rgba(0, 41, 77, 0.07)";
2123
- const shadowCardTurva = "0 2px 6px 0 rgba(117, 117, 117, 0.13), 0 -1px 0 0 rgba(0, 0, 0, 0.09), -1px 0 0 0 rgba(0, 0, 0, 0.07), 1px 0 0 0 rgba(0, 0, 0, 0.07), 0 1px 0 0 rgba(0, 0, 0, 0.07)";
2124
- const shadowModal = "0 2px 20px 0 rgba(0, 0, 0, 0.2)";
2125
- const shadowCard = "0 2px 6px 0 rgba(0, 41, 77, 0.07), 0 -1px 0 0 rgba(0, 0, 0, 0.09), -1px 0 0 0 rgba(0, 0, 0, 0.07), 1px 0 0 0 rgba(0, 0, 0, 0.07), 0 1px 0 0 rgba(0, 0, 0, 0.07)";
2126
- const shadowHoverTurva = "0 2px 10px 0 rgba(117, 117, 117, 0.15)";
2127
- const shadowHover = "0 2px 10px 0 rgba(0, 41, 77, 0.1)";
2128
- const shadowDefaultTurva = "0 2px 6px 0 rgba(117, 117, 117, 0.13)";
2129
- const spaceXxSmall = "4px";
2130
- const spaceLarge = "20px";
2131
- const spaceXSmall = "8px";
2132
- const spaceXxxSmall = "2px";
2133
- const spaceSmall = "12px";
2134
- const spaceMedium = "16px";
2135
- const spaceXxLarge = "36px";
2136
- const spaceXxxxLarge = "72px";
2137
- const spaceXxxxxLarge = "94px";
2138
- const spaceXxxLarge = "48px";
2139
- const spaceXLarge = "28px";
2140
- const sizeIconXxLarge = "48px";
2141
- const sizeFormBorder = "1px";
2142
- const sizeStepMedium = "40px";
2143
- const sizeButtonMinWidth = "8rem";
2144
- const sizeHeader = "4rem";
2145
- const sizeIconXxxLarge = "72px";
2146
- const sizeIconXLarge = "36px";
2147
- const sizeIconXxSmall = "10px";
2148
- const sizeStepSmall = "30px";
2149
- const sizeNavigation = "3rem";
2150
- const sizeIconLarge = "30px";
2151
- const sizeLayoutMaxWidth = "1110px";
2152
- const sizeTappableSquare = "48px";
2153
- const sizeIconXSmall = "16px";
2154
- const sizeIconXxxSmall = "7px";
2155
- const sizeButtonBorder = "2px";
2156
- const sizeButtonTinyBorder = "1px";
2157
- const sizeIconMedium = "24px";
2158
- const sizeIconSmall = "20px";
2159
- const opacity85 = "0.85";
2160
- const opacity75 = "0.75";
2161
- const opacity50 = "0.50";
2162
- const opacity30 = "0.30";
2163
- const zIndexDropdown = "600";
2164
- const zIndexSpinner = "800";
2165
- const zIndexDefault = "1";
2166
- const zIndexToast = "500";
2167
- const zIndexPopup = "950";
2168
- const zIndexModal = "900";
2169
- const zIndexSticky = "300";
2170
- const zIndexMasked = "100";
2171
- const zIndexDeep = "-999999";
2172
- const zIndexOverlay = "700";
2173
- const zIndexMask = "200";
2174
- const zIndexHeader = "400";
2175
- const lineHeightMedium = "1.5";
2176
- const lineHeightSmall = "1.25";
2177
- const lineHeightXSmall = "1.1";
2178
- const transitionQuickly = "300ms ease";
2179
- const transitionSlowly = "600ms ease";
2180
- const mediaQueryXxSmall = "'(max-width: 22.5em)'";
2181
- const mediaQueryXSmall = "'(max-width: 35.9375em)'";
2182
- const mediaQuerySmall = "'(min-width: 36em)'";
2183
- const mediaQueryMedium = "'(min-width: 48em)'";
2184
- const mediaQueryLarge = "'(min-width: 62em)'";
2185
- const mediaQueryXLarge = "'(min-width: 64.0625em)'";
2186
- const mediaQueryXxLarge = "'(min-width: 76.25em)'";
2187
- const mediaQueryXxxLarge = "'(min-width: 106.25em)'";
2188
-
2189
- const tokens$2 = /*#__PURE__*/Object.freeze({
2190
- __proto__: null,
2191
- colorWarning: colorWarning,
2192
- colorGrayDarker: colorGrayDarker,
2193
- colorGrayLighter: colorGrayLighter,
2194
- colorCategoryHome: colorCategoryHome,
2195
- colorPrimary: colorPrimary,
2196
- colorCategoryVehicle: colorCategoryVehicle,
2197
- colorSuccess: colorSuccess,
2198
- colorCategoryFamily: colorCategoryFamily,
2199
- colorPrimaryLightest: colorPrimaryLightest,
2200
- colorPrimaryLighter: colorPrimaryLighter,
2201
- colorBrandBlue: colorBrandBlue,
2202
- colorPrimaryDark: colorPrimaryDark,
2203
- colorGrayLightest: colorGrayLightest,
2204
- colorCategoryFinance: colorCategoryFinance,
2205
- colorGrayDark: colorGrayDark,
2206
- colorGrayLight: colorGrayLight,
2207
- colorSecondary: colorSecondary,
2208
- colorCategoryPet: colorCategoryPet,
2209
- colorPrimaryLight: colorPrimaryLight,
2210
- colorCategoryTravel: colorCategoryTravel,
2211
- colorGray: colorGray,
2212
- colorDanger: colorDanger,
2213
- colorGrayDarkerTurva: colorGrayDarkerTurva,
2214
- colorGrayLighterTurva: colorGrayLighterTurva,
2215
- colorCategoryHomeTurva: colorCategoryHomeTurva,
2216
- colorPrimaryTurva: colorPrimaryTurva,
2217
- colorCategoryVehicleTurva: colorCategoryVehicleTurva,
2218
- colorSuccessTurva: colorSuccessTurva,
2219
- colorPrimaryLightestTurva: colorPrimaryLightestTurva,
2220
- colorCategoryFamilyTurva: colorCategoryFamilyTurva,
2221
- colorCategoryUnionTurva: colorCategoryUnionTurva,
2222
- colorPrimaryLighterTurva: colorPrimaryLighterTurva,
2223
- colorPrimaryDarkTurva: colorPrimaryDarkTurva,
2224
- colorGrayLightestTurva: colorGrayLightestTurva,
2225
- colorGrayDarkTurva: colorGrayDarkTurva,
2226
- colorGrayLightTurva: colorGrayLightTurva,
2227
- colorBrandGrayTurva: colorBrandGrayTurva,
2228
- colorSecondaryTurva: colorSecondaryTurva,
2229
- colorPrimaryLightTurva: colorPrimaryLightTurva,
2230
- colorCategoryTravelTurva: colorCategoryTravelTurva,
2231
- colorGrayTurva: colorGrayTurva,
2232
- colorDangerTurva: colorDangerTurva,
2233
- colorWarningTurva: colorWarningTurva,
2234
- colorData07: colorData07,
2235
- colorData08: colorData08,
2236
- colorData09: colorData09,
2237
- colorData10: colorData10,
2238
- colorData11: colorData11,
2239
- colorData01: colorData01,
2240
- colorData12: colorData12,
2241
- colorData02: colorData02,
2242
- colorData13: colorData13,
2243
- colorData03: colorData03,
2244
- colorData14: colorData14,
2245
- colorData04: colorData04,
2246
- colorData15: colorData15,
2247
- colorData05: colorData05,
2248
- colorData06: colorData06,
2249
- fontWeightExtraBold: fontWeightExtraBold,
2250
- letterSpacingHeading: letterSpacingHeading,
2251
- fontFamilyHeadingTurva: fontFamilyHeadingTurva,
2252
- fontFamilyTextTurva: fontFamilyTextTurva,
2253
- fontFamilyHeading: fontFamilyHeading,
2254
- fontFamilyText: fontFamilyText,
2255
- fontWeightBold: fontWeightBold,
2256
- fontWeightNormal: fontWeightNormal,
2257
- fontWeightSemiBold: fontWeightSemiBold,
2258
- fontSizeXxxxLarge: fontSizeXxxxLarge,
2259
- fontSizeXxxLarge: fontSizeXxxLarge,
2260
- fontSizeXxLarge: fontSizeXxLarge,
2261
- fontSizeXLarge: fontSizeXLarge,
2262
- fontSizeLarge: fontSizeLarge,
2263
- fontSizeMedium: fontSizeMedium,
2264
- fontSizeSmall: fontSizeSmall,
2265
- fontSizeXSmall: fontSizeXSmall,
2266
- radiusSharp: radiusSharp,
2267
- radiusDefault: radiusDefault,
2268
- radiusCircle: radiusCircle,
2269
- radiusPill: radiusPill,
2270
- shadowTooltipTurva: shadowTooltipTurva,
2271
- shadowDefault: shadowDefault,
2272
- shadowTooltip: shadowTooltip,
2273
- shadowCardTurva: shadowCardTurva,
2274
- shadowModal: shadowModal,
2275
- shadowCard: shadowCard,
2276
- shadowHoverTurva: shadowHoverTurva,
2277
- shadowHover: shadowHover,
2278
- shadowDefaultTurva: shadowDefaultTurva,
2279
- spaceXxSmall: spaceXxSmall,
2280
- spaceLarge: spaceLarge,
2281
- spaceXSmall: spaceXSmall,
2282
- spaceXxxSmall: spaceXxxSmall,
2283
- spaceSmall: spaceSmall,
2284
- spaceMedium: spaceMedium,
2285
- spaceXxLarge: spaceXxLarge,
2286
- spaceXxxxLarge: spaceXxxxLarge,
2287
- spaceXxxxxLarge: spaceXxxxxLarge,
2288
- spaceXxxLarge: spaceXxxLarge,
2289
- spaceXLarge: spaceXLarge,
2290
- sizeIconXxLarge: sizeIconXxLarge,
2291
- sizeFormBorder: sizeFormBorder,
2292
- sizeStepMedium: sizeStepMedium,
2293
- sizeButtonMinWidth: sizeButtonMinWidth,
2294
- sizeHeader: sizeHeader,
2295
- sizeIconXxxLarge: sizeIconXxxLarge,
2296
- sizeIconXLarge: sizeIconXLarge,
2297
- sizeIconXxSmall: sizeIconXxSmall,
2298
- sizeStepSmall: sizeStepSmall,
2299
- sizeNavigation: sizeNavigation,
2300
- sizeIconLarge: sizeIconLarge,
2301
- sizeLayoutMaxWidth: sizeLayoutMaxWidth,
2302
- sizeTappableSquare: sizeTappableSquare,
2303
- sizeIconXSmall: sizeIconXSmall,
2304
- sizeIconXxxSmall: sizeIconXxxSmall,
2305
- sizeButtonBorder: sizeButtonBorder,
2306
- sizeButtonTinyBorder: sizeButtonTinyBorder,
2307
- sizeIconMedium: sizeIconMedium,
2308
- sizeIconSmall: sizeIconSmall,
2309
- opacity85: opacity85,
2310
- opacity75: opacity75,
2311
- opacity50: opacity50,
2312
- opacity30: opacity30,
2313
- zIndexDropdown: zIndexDropdown,
2314
- zIndexSpinner: zIndexSpinner,
2315
- zIndexDefault: zIndexDefault,
2316
- zIndexToast: zIndexToast,
2317
- zIndexPopup: zIndexPopup,
2318
- zIndexModal: zIndexModal,
2319
- zIndexSticky: zIndexSticky,
2320
- zIndexMasked: zIndexMasked,
2321
- zIndexDeep: zIndexDeep,
2322
- zIndexOverlay: zIndexOverlay,
2323
- zIndexMask: zIndexMask,
2324
- zIndexHeader: zIndexHeader,
2325
- lineHeightMedium: lineHeightMedium,
2326
- lineHeightSmall: lineHeightSmall,
2327
- lineHeightXSmall: lineHeightXSmall,
2328
- transitionQuickly: transitionQuickly,
2329
- transitionSlowly: transitionSlowly,
2330
- mediaQueryXxSmall: mediaQueryXxSmall,
2331
- mediaQueryXSmall: mediaQueryXSmall,
2332
- mediaQuerySmall: mediaQuerySmall,
2333
- mediaQueryMedium: mediaQueryMedium,
2334
- mediaQueryLarge: mediaQueryLarge,
2335
- mediaQueryXLarge: mediaQueryXLarge,
2336
- mediaQueryXxLarge: mediaQueryXxLarge,
2337
- mediaQueryXxxLarge: mediaQueryXxxLarge
2338
- });
2555
+ const duetBreadcrumbsCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:block}.duet-breadcrumbs{font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"}.duet-breadcrumbs ol{display:flex;flex-direction:row;flex-wrap:wrap;gap:8px;align-items:center;justify-content:flex-start;padding:10px 16px;color:#00294d;list-style:none;background:#f3f9fc;border-bottom:1px solid #e1e3e6}@media (min-width: 62em){.duet-breadcrumbs ol{padding:10px 36px}}.duet-breadcrumbs.duet-theme-turva{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"}.duet-breadcrumbs.duet-theme-turva ol{color:#171c3a;background:#fcf3f4}.duet-breadcrumbs .duet-breadrumbs-arrow{display:inherit;align-items:center;justify-content:center;width:0.375rem;height:0.375rem}.duet-breadcrumbs .hide{display:none}";
2339
2556
 
2340
- const allowedThemes = ["turva"];
2341
- function isDashCase(str) {
2342
- const dash = str.includes("-");
2343
- const barredString = str.includes(" ") || str.includes("_");
2344
- const barredStartingString = str.charAt(0) === "-";
2345
- return dash && !barredString && !barredStartingString;
2346
- }
2347
- function capitalize(str = "") {
2348
- return `${str.charAt(0).toUpperCase()}${str.slice(1)}`;
2349
- }
2350
- function lowerCaseFirst(str = "") {
2351
- return `${str.charAt(0).toLowerCase()}${str.slice(1)}`;
2352
- }
2353
- function camelize(str = "") {
2354
- const arr = str.split("-");
2355
- //loop through each element of the array and capitalize the first letter.'
2356
- arr.forEach((string, index) => {
2357
- arr[index] = capitalize(string);
2358
- });
2359
- return arr.join("");
2360
- }
2361
- function getTheme(theme = "") {
2362
- if (allowedThemes.includes(theme.toLowerCase())) {
2363
- return theme.toLowerCase();
2364
- }
2365
- return "";
2366
- }
2367
- function hasColor(str = "") {
2368
- return str.indexOf("Color") === 0 || str.indexOf("color") === 0;
2369
- }
2370
- function addColor(str = "") {
2371
- if (str && !isDashCase(str) && !hasColor(str)) {
2372
- return `color${capitalize(str)}`;
2557
+ let DuetBreadcrumbs$1 = class extends H {
2558
+ constructor() {
2559
+ super();
2560
+ this.__registerHost();
2561
+ this.__attachShadow();
2562
+ this.observers = [];
2563
+ this.breadcrumbsAriaLabel = getLocaleString({
2564
+ fi: "Murupolku",
2565
+ sv: "Ströbröd",
2566
+ en: "Breadcrumbs",
2567
+ });
2568
+ /**
2569
+ * Theme
2570
+ */
2571
+ this.theme = "";
2373
2572
  }
2374
- return str;
2375
- }
2376
- function addTheme(str, theme) {
2377
- const hasTheme = getTheme(theme).length;
2378
- if (hasTheme && str.indexOf(theme) === -1) {
2379
- return `${str}${capitalize(theme)}`;
2573
+ /**
2574
+ * Component lifecycle events.
2575
+ */
2576
+ componentWillLoad() {
2577
+ inheritGlobalTheme(this);
2578
+ this.children = Array.from(this.element.children);
2380
2579
  }
2381
- return str;
2382
- }
2383
- function getColorByName(name, theme = "") {
2384
- if (!name) {
2385
- return undefined;
2580
+ connectedCallback() {
2581
+ Array.from(this.element.children).forEach(child => {
2582
+ const observer = new MutationObserver(() => (this.children = Array.from(this.element.children)));
2583
+ observer.observe(child, {
2584
+ childList: true,
2585
+ subtree: true,
2586
+ attributes: true,
2587
+ characterData: true,
2588
+ });
2589
+ this.observers = [...this.observers, observer];
2590
+ });
2386
2591
  }
2387
- const defaultColor = convertToColorName(name);
2388
- const themedColor = convertToColorName(name, theme);
2389
- // lets just try to get the color first to save some cycles
2390
- let resolvedToken = tokens$2[themedColor];
2391
- if (!resolvedToken) {
2392
- resolvedToken = tokens$2[defaultColor];
2592
+ disconnectedCallback() {
2593
+ this.observers.forEach(observer => observer.disconnect());
2594
+ this.observers = [];
2393
2595
  }
2394
- return resolvedToken;
2395
- }
2396
- function convertToColorName(name = "", theme = "") {
2397
- let colorResolution = name;
2398
- const dash = isDashCase(name);
2399
- if (dash) {
2400
- colorResolution = camelize(colorResolution);
2596
+ /**
2597
+ * render() function
2598
+ * Always the last one in the class.
2599
+ */
2600
+ render() {
2601
+ return (h$1(Host, null, h$1("nav", { "aria-label": this.breadcrumbsAriaLabel, class: {
2602
+ "duet-breadcrumbs": true,
2603
+ "duet-theme-turva": this.theme === "turva",
2604
+ } }, h$1("ol", null, this.children.map((child, index) => (h$1(Fragment, null, index > 0 && (h$1("li", { "aria-hidden": "true" }, h$1("duet-icon", { class: "duet-breadrumbs-arrow", size: "auto", icon: actionArrowRightSmall.svg, margin: "none", color: "currentColor" }))), h$1("li", { innerHTML: child.outerHTML }), h$1("div", { class: "hide" }, h$1("slot", null)))))))));
2401
2605
  }
2402
- colorResolution = addColor(colorResolution);
2403
- colorResolution = addTheme(colorResolution, theme);
2404
- // takes care of the case where colorPrimaryDark ends up with ColorPrimaryDark
2405
- colorResolution = lowerCaseFirst(colorResolution);
2406
- return colorResolution;
2407
- }
2606
+ get element() { return this; }
2607
+ static get style() { return duetBreadcrumbsCss; }
2608
+ };
2609
+
2610
+ const DuetStringsExternalDefaults = {
2611
+ fi: "Avautuu uuteen ikkunaan",
2612
+ sv: "Öppnas i nytt fönster",
2613
+ en: "Opens in a new window",
2614
+ };
2408
2615
 
2409
- const duetButtonCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-right:8px !important;margin-bottom:12px !important;position:relative;z-index:1;display:inline-flex;width:auto;max-width:100%;vertical-align:bottom;-webkit-tap-highlight-color:transparent}:host:last-child,:host:last-of-type{margin-right:0 !important}@media (max-width: 35.9375em){:host{width:100%}}:host(.duet-small){margin-right:2px !important;margin-bottom:8px !important}:host(.duet-small):last-child,:host(.duet-small):last-of-type{margin-right:0 !important}@media (max-width: 35.9375em){:host(.duet-small){width:auto}}:host(.duet-expand){width:100% !important}:host(.duet-m-0){margin:0 !important}:host(.duet-fixed){width:auto !important}:host(:last-child){margin-right:0 !important}.duet-button-container{position:relative;width:100%}.duet-button{padding:14px 27px 15px !important;-webkit-user-select:none;user-select:none;position:relative;z-index:100;display:block;width:100%;min-width:8rem;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;font-weight:600;font-variant-numeric:tabular-nums;-webkit-hyphens:auto;hyphens:auto;line-height:1.1;color:#0077b3 !important;text-align:center;text-decoration:none;cursor:pointer;background:transparent;border-style:solid;border-width:2px;border-radius:20rem;transition:background-color 300ms ease, color 300ms ease, border 300ms ease, box-shadow 300ms ease}.duet-button.duet-p-0{padding:0 !important}.duet-button.duet-m-0{margin:0 !important}.duet-button.duet-button-is-small:not(.duet-button-icon-only){padding:9px 19px 10px !important;min-width:5.3333333333rem;font-size:0.875rem}.duet-button.duet-button-is-small:not(.duet-button-icon-only).icon{padding-left:48px !important}.duet-button.duet-button-is-small:not(.duet-button-icon-only).icon-right{padding-right:48px !important;padding-left:20px !important}.duet-theme-turva .duet-button{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#c60c30 !important}.duet-button .duet-button-contents{position:relative;display:inline-block;margin:0 auto;pointer-events:none}.duet-button.duet-no-wrap{white-space:nowrap}.duet-button.icon{padding-left:52px !important}.duet-button.icon-right{padding-right:52px !important;padding-left:28px !important}.duet-button svg{width:100%;min-width:100%;fill:currentColor}.duet-button .duet-button-icon{position:absolute;top:50%;left:-28px;display:flex;align-items:center;justify-content:center;width:16px;height:16px;margin:0 !important;transform:translateY(-50%)}.duet-button .duet-button-icon duet-icon{width:16px;height:16px}.duet-button .duet-button-icon.right{right:-28px;left:auto}.duet-button .duet-button-icon.large{left:-32px;width:20px;height:20px}.duet-button .duet-button-icon.large duet-icon{width:20px;height:20px}.duet-button .duet-button-icon.large.right{right:-32px;left:auto}.duet-button .duet-button-icon.medium-small{left:-16px;width:10px;height:10px;padding-top:1px}.duet-button .duet-button-icon.medium-small duet-icon{width:10px;height:10px}.duet-button .duet-button-icon.medium-small.right{right:-16px;left:auto}.duet-button .duet-button-icon.small{left:-16px;width:7px;height:7px}.duet-button .duet-button-icon.small duet-icon{width:7px;height:7px}.duet-button .duet-button-icon.small.right{right:-16px;left:auto}.duet-button:focus{outline:0;box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}.duet-theme-turva .duet-button:focus{box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}.duet-button:active{opacity:0.75;transition:none}.duet-button.default{border-color:#e1e3e6}.duet-theme-turva .duet-button.default{color:#c60c30 !important;border-color:#e4e4e6}.duet-button.default:hover{border-color:#0077b3}.duet-theme-turva .duet-button.default:hover{border-color:#c60c30}.duet-button.default.duet-button-negative{background-color:white}.duet-theme-turva .duet-button.default.duet-button-negative{background-color:#e4e4e6 !important}.duet-button.default.duet-button-negative:hover{color:#0077b3 !important;border-color:#0077b3}.duet-theme-turva .duet-button.default.duet-button-negative:hover{color:#c60c30 !important;border-color:#c60c30}.duet-button.primary{color:white !important;background:#0077b3;border-color:#0077b3}.duet-theme-turva .duet-button.primary{color:white !important;background:#c60c30;border-color:#c60c30}.duet-button.primary:hover{background:#005f8f;border-color:#005f8f;box-shadow:0 4px 20px rgba(34, 34, 34, 0.1)}.duet-theme-turva .duet-button.primary:hover{background:#940925;border-color:#940925}.duet-button.primary:focus{outline:0;box-shadow:0 0 0 1px white, 0 0 0 4px rgba(0, 119, 179, 0.75)}.duet-theme-turva .duet-button.primary:focus{box-shadow:0 0 0 1px white, 0 0 0 4px rgba(23, 28, 58, 0.7)}.duet-button.secondary{color:#00294d !important;background:transparent;border-color:#00294d}.duet-theme-turva .duet-button.secondary{color:#171c3a !important;border-color:#171c3a}.duet-button.secondary:hover{color:#0077b3 !important;border-color:#0077b3}.duet-theme-turva .duet-button.secondary:hover{color:#c60c30 !important;border-color:#c60c30}.duet-button.secondary.duet-button-negative{color:#e1e3e6 !important;border-color:white}.duet-theme-turva .duet-button.secondary.duet-button-negative{color:#e4e4e6 !important}.duet-button.secondary.duet-button-negative:hover{color:#0077b3 !important;border-color:#0077b3}.duet-theme-turva .duet-button.secondary.duet-button-negative:hover{color:#c60c30 !important;border-color:#c60c30}.duet-button.negative{color:#00294d !important;background:white;border-color:white}.duet-theme-turva .duet-button.negative{color:#171c3a !important}.duet-button.negative:hover{color:white !important;background:transparent;border-color:white}.duet-button.negative:focus{outline:0;box-shadow:0 0 0 1px #00294d, 0 0 0 4px rgba(255, 255, 255, 0.7)}.duet-theme-turva .duet-button.negative:focus{box-shadow:0 0 0 1px #171c3a, 0 0 0 4px rgba(255, 255, 255, 0.7)}.duet-button.destructive-primary{color:white !important;background:#de2362;border-color:#de2362}.duet-theme-turva .duet-button.destructive-primary{color:white !important;background:#e02a0d;border-color:#e02a0d}.duet-button.destructive-primary:hover{background:#b21c4e;border-color:#b21c4e;box-shadow:0 4px 20px rgba(34, 34, 34, 0.1)}.duet-theme-turva .duet-button.destructive-primary:hover{background:#b3220a}.duet-button.destructive,.duet-button.destructive-secondary{color:#de2362 !important;background:white;border-color:#de2362}.duet-theme-turva .duet-button.destructive,.duet-theme-turva .duet-button.destructive-secondary{color:#e02a0d !important;background:white;border-color:#e02a0d}.duet-button.destructive:hover,.duet-button.destructive-secondary:hover{color:white !important;background:#b21c4e;border-color:#b21c4e}.duet-theme-turva .duet-button.destructive:hover,.duet-theme-turva .duet-button.destructive-secondary:hover{color:white !important;background:#b3220a;border-color:#b3220a}.duet-button.plain{min-width:48px;padding-right:0 !important;padding-left:0 !important;line-height:1.5;text-align:left;background:transparent;border:0;border-color:transparent;border-radius:4px}.duet-theme-turva .duet-button.plain{color:#c60c30 !important;background:transparent;border-color:transparent}.duet-button.plain.icon{padding-left:20px !important}.duet-button.plain.icon.icon-right{padding-right:20px !important;padding-left:0 !important}.duet-button.plain.icon.medium{padding-left:24px !important}.duet-button.plain.icon.medium.icon-right{padding-right:24px !important;padding-left:0 !important}.duet-button.plain.icon.large{padding-left:30px !important}.duet-button.plain.icon.large.icon-right{padding-right:30px !important;padding-left:0 !important}.duet-button.plain .duet-button-icon.left{left:-16.6666666667px !important}.duet-button.plain .duet-button-icon.left.medium{left:-24px !important}.duet-button.plain .duet-button-icon.left.large{left:-30px !important}.duet-button.plain .duet-button-icon.right{right:-16.6666666667px !important}.duet-button.plain .duet-button-icon.right.medium{right:-24px !important}.duet-button.plain .duet-button-icon.right.large{right:-30px !important}.duet-button.plain[disabled]{color:#657787 !important;background:transparent !important;border-color:transparent !important}.duet-theme-turva .duet-button.plain[disabled]{color:transparent !important;background:transparent !important;border-color:#e4e4e6 !important}.duet-button.plain:hover{color:#004d80 !important;background:transparent !important}.duet-theme-turva .duet-button.plain:hover{color:#940925 !important}.duet-button.plain.duet-button-negative{color:white !important}.duet-theme-turva .duet-button.plain.duet-button-negative{color:#e4e4e6 !important}.duet-button.plain.duet-button-negative:hover{color:#0077b3 !important}.duet-theme-turva .duet-button.plain.duet-button-negative:hover{color:#c60c30 !important}.duet-button.duet-button-icon-only{min-width:48px;min-height:48px;padding:0 !important}.duet-button.duet-button-icon-only .duet-button-contents{position:static}.duet-button.duet-button-icon-only .duet-button-icon.left.large,.duet-button.duet-button-icon-only .duet-button-icon.left.medium,.duet-button.duet-button-icon-only .duet-button-icon.left.small{position:absolute;top:50% !important;left:50% !important;padding:0;margin:0;transform:translateX(-50%) translateY(-50%)}.duet-button[disabled],.duet-button[disabled]:hover,.duet-button.duet-button-negative[disabled],.duet-button.duet-button-negative[disabled]:hover{color:#657787 !important;background:#e1e3e6 !important;border-color:#e1e3e6 !important;box-shadow:none !important}.duet-theme-turva .duet-button[disabled],.duet-theme-turva .duet-button[disabled]:hover,.duet-theme-turva .duet-button.duet-button-negative [disabled],.duet-theme-turva .duet-button.duet-button-negative [disabled]:hover{color:#747475 !important;background:#e4e4e6 !important;border-color:#e4e4e6 !important}.duet-button-is-loading.primary{color:white}.duet-button-is-loading.default{color:#0077b3}.duet-button-is-loading.default.duet-theme-turva{color:#c60c30}.duet-button-is-loading .duet-button-contents{visibility:hidden;opacity:0}";
2616
+ const duetButtonCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-right:8px !important;margin-bottom:12px !important;position:relative;z-index:1;display:inline-flex;width:auto;max-width:100%;vertical-align:bottom;-webkit-tap-highlight-color:transparent}:host:last-child,:host:last-of-type{margin-right:0 !important}@media (max-width: 35.9375em){:host{width:100%}}:host(.duet-small){margin-right:2px !important;margin-bottom:8px !important}:host(.duet-small):last-child,:host(.duet-small):last-of-type{margin-right:0 !important}@media (max-width: 35.9375em){:host(.duet-small){width:auto}}:host(.duet-expand){width:100% !important}:host(.duet-m-0){margin:0 !important}:host(.duet-fixed){width:auto !important}:host(:last-child){margin-right:0 !important}.duet-button-container{position:relative;width:100%}.duet-button{padding:14px 27px 15px !important;-webkit-user-select:none;user-select:none;position:relative;z-index:100;display:block;width:100%;min-width:8rem;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;font-weight:600;font-variant-numeric:tabular-nums;-webkit-hyphens:auto;hyphens:auto;line-height:1.1;color:#0077b3 !important;text-align:center;text-decoration:none;cursor:pointer;background:transparent;border-style:solid;border-width:2px;border-radius:20rem;transition:background-color 300ms ease, color 300ms ease, border 300ms ease, box-shadow 300ms ease}.duet-button.duet-p-0{padding:0 !important}.duet-button.duet-m-0{margin:0 !important}.duet-button.duet-button-text-center{text-align:center !important}.duet-button.duet-button-is-small:not(.duet-button-icon-only){padding:9px 19px 10px !important;min-width:5.3333333333rem;font-size:0.875rem}.duet-button.duet-button-is-small:not(.duet-button-icon-only).icon{padding-left:48px !important}.duet-button.duet-button-is-small:not(.duet-button-icon-only).icon-right{padding-right:48px !important;padding-left:20px !important}.duet-theme-turva .duet-button{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#c60c30 !important}.duet-button .duet-button-contents{position:relative;display:inline-block;margin:0 auto;pointer-events:none}.duet-button.duet-no-wrap{white-space:nowrap}.duet-button.icon{padding-left:52px !important}.duet-button.icon-right{padding-right:52px !important;padding-left:28px !important}.duet-button svg{width:100%;min-width:100%;fill:currentColor}.duet-button .duet-button-icon{position:absolute;top:50%;left:-28px;display:flex;align-items:center;justify-content:center;width:16px;height:16px;margin:0 !important;transform:translateY(-50%)}.duet-button .duet-button-icon duet-icon{width:16px;height:16px}.duet-button .duet-button-icon.right{right:-28px;left:auto}.duet-button .duet-button-icon.large{left:-32px;width:20px;height:20px}.duet-button .duet-button-icon.large duet-icon{width:20px;height:20px}.duet-button .duet-button-icon.large.right{right:-32px;left:auto}.duet-button .duet-button-icon.medium-small{left:-16px;width:10px;height:10px;padding-top:1px}.duet-button .duet-button-icon.medium-small duet-icon{width:10px;height:10px}.duet-button .duet-button-icon.medium-small.right{right:-16px;left:auto}.duet-button .duet-button-icon.small{left:-16px;width:7px;height:7px}.duet-button .duet-button-icon.small duet-icon{width:7px;height:7px}.duet-button .duet-button-icon.small.right{right:-16px;left:auto}.duet-button:focus{outline:0;box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}.duet-theme-turva .duet-button:focus{box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}.duet-button:active{opacity:0.75;transition:none}.duet-button.default{border-color:#e1e3e6}.duet-theme-turva .duet-button.default{color:#c60c30 !important;border-color:#e4e4e6}.duet-button.default:hover{border-color:#0077b3}.duet-theme-turva .duet-button.default:hover{border-color:#c60c30}.duet-button.default.duet-button-negative{background-color:white}.duet-theme-turva .duet-button.default.duet-button-negative{background-color:#e4e4e6 !important}.duet-button.default.duet-button-negative:hover{color:#0077b3 !important;border-color:#0077b3}.duet-theme-turva .duet-button.default.duet-button-negative:hover{color:#c60c30 !important;border-color:#c60c30}.duet-button.primary{color:white !important;background:#0077b3;border-color:#0077b3}.duet-theme-turva .duet-button.primary{color:white !important;background:#c60c30;border-color:#c60c30}.duet-button.primary:hover{background:#005f8f;border-color:#005f8f;box-shadow:0 4px 20px rgba(34, 34, 34, 0.1)}.duet-theme-turva .duet-button.primary:hover{background:#940925;border-color:#940925}.duet-button.primary:focus{outline:0;box-shadow:0 0 0 1px white, 0 0 0 4px rgba(0, 119, 179, 0.75)}.duet-theme-turva .duet-button.primary:focus{box-shadow:0 0 0 1px white, 0 0 0 4px rgba(23, 28, 58, 0.7)}.duet-button.secondary{color:#00294d !important;background:transparent;border-color:#00294d}.duet-theme-turva .duet-button.secondary{color:#171c3a !important;border-color:#171c3a}.duet-button.secondary:hover{color:#0077b3 !important;border-color:#0077b3}.duet-theme-turva .duet-button.secondary:hover{color:#c60c30 !important;border-color:#c60c30}.duet-button.secondary.duet-button-negative{color:#e1e3e6 !important;border-color:white}.duet-theme-turva .duet-button.secondary.duet-button-negative{color:#e4e4e6 !important}.duet-button.secondary.duet-button-negative:hover{color:#0077b3 !important;border-color:#0077b3}.duet-theme-turva .duet-button.secondary.duet-button-negative:hover{color:#c60c30 !important;border-color:#c60c30}.duet-button.negative{color:#00294d !important;background:white;border-color:white}.duet-theme-turva .duet-button.negative{color:#171c3a !important}.duet-button.negative:hover{color:white !important;background:transparent;border-color:white}.duet-button.negative:focus{outline:0;box-shadow:0 0 0 1px #00294d, 0 0 0 4px rgba(255, 255, 255, 0.7)}.duet-theme-turva .duet-button.negative:focus{box-shadow:0 0 0 1px #171c3a, 0 0 0 4px rgba(255, 255, 255, 0.7)}.duet-button.destructive-primary{color:white !important;background:#de2362;border-color:#de2362}.duet-theme-turva .duet-button.destructive-primary{color:white !important;background:#e02a0d;border-color:#e02a0d}.duet-button.destructive-primary:hover{background:#b21c4e;border-color:#b21c4e;box-shadow:0 4px 20px rgba(34, 34, 34, 0.1)}.duet-theme-turva .duet-button.destructive-primary:hover{background:#b3220a}.duet-button.destructive,.duet-button.destructive-secondary{color:#de2362 !important;background:white;border-color:#de2362}.duet-theme-turva .duet-button.destructive,.duet-theme-turva .duet-button.destructive-secondary{color:#e02a0d !important;background:white;border-color:#e02a0d}.duet-button.destructive:hover,.duet-button.destructive-secondary:hover{color:white !important;background:#b21c4e;border-color:#b21c4e}.duet-theme-turva .duet-button.destructive:hover,.duet-theme-turva .duet-button.destructive-secondary:hover{color:white !important;background:#b3220a;border-color:#b3220a}.duet-button.plain{min-width:48px;padding-right:0 !important;padding-left:0 !important;line-height:1.5;text-align:left;background:transparent;border:0;border-color:transparent;border-radius:4px}.duet-theme-turva .duet-button.plain{color:#c60c30 !important;background:transparent;border-color:transparent}.duet-button.plain.icon{padding-left:20px !important}.duet-button.plain.icon.icon-right{padding-right:20px !important;padding-left:0 !important}.duet-button.plain.icon.medium{padding-left:24px !important}.duet-button.plain.icon.medium.icon-right{padding-right:24px !important;padding-left:0 !important}.duet-button.plain.icon.large{padding-left:30px !important}.duet-button.plain.icon.large.icon-right{padding-right:30px !important;padding-left:0 !important}.duet-button.plain .duet-button-icon.left{left:-16.6666666667px !important}.duet-button.plain .duet-button-icon.left.medium{left:-24px !important}.duet-button.plain .duet-button-icon.left.large{left:-30px !important}.duet-button.plain .duet-button-icon.right{right:-16.6666666667px !important}.duet-button.plain .duet-button-icon.right.medium{right:-24px !important}.duet-button.plain .duet-button-icon.right.large{right:-30px !important}.duet-button.plain[disabled]{color:#657787 !important;background:transparent !important;border-color:transparent !important}.duet-theme-turva .duet-button.plain[disabled]{color:transparent !important;background:transparent !important;border-color:#e4e4e6 !important}.duet-button.plain:hover{color:#004d80 !important;background:transparent !important}.duet-theme-turva .duet-button.plain:hover{color:#940925 !important}.duet-button.plain.duet-button-negative{color:white !important}.duet-theme-turva .duet-button.plain.duet-button-negative{color:#e4e4e6 !important}.duet-button.plain.duet-button-negative:hover{color:#0077b3 !important}.duet-theme-turva .duet-button.plain.duet-button-negative:hover{color:#c60c30 !important}.duet-button.duet-button-icon-only{min-width:48px;min-height:48px;padding:0 !important}.duet-button.duet-button-icon-only .duet-button-contents{position:static}.duet-button.duet-button-icon-only .duet-button-icon.left.large,.duet-button.duet-button-icon-only .duet-button-icon.left.medium,.duet-button.duet-button-icon-only .duet-button-icon.left.small{position:absolute;top:50% !important;left:50% !important;padding:0;margin:0;transform:translateX(-50%) translateY(-50%)}.duet-button[disabled],.duet-button[disabled]:hover,.duet-button.duet-button-negative[disabled],.duet-button.duet-button-negative[disabled]:hover{color:#657787 !important;background:#e1e3e6 !important;border-color:#e1e3e6 !important;box-shadow:none !important}.duet-theme-turva .duet-button[disabled],.duet-theme-turva .duet-button[disabled]:hover,.duet-theme-turva .duet-button.duet-button-negative [disabled],.duet-theme-turva .duet-button.duet-button-negative [disabled]:hover{color:#747475 !important;background:#e4e4e6 !important;border-color:#e4e4e6 !important}.duet-button-is-loading.primary{color:white}.duet-button-is-loading.default{color:#0077b3}.duet-button-is-loading.default.duet-theme-turva{color:#c60c30}.duet-button-is-loading .duet-button-contents{visibility:hidden;opacity:0}";
2410
2617
 
2411
2618
  let DuetButton$1 = class extends H {
2412
2619
  constructor() {
@@ -2415,6 +2622,10 @@ let DuetButton$1 = class extends H {
2415
2622
  this.__attachShadow();
2416
2623
  this.duetFocus = createEvent$2(this, "duetFocus", 7);
2417
2624
  this.duetBlur = createEvent$2(this, "duetBlur", 7);
2625
+ /**
2626
+ * Use this property to add an aria-haspopup attribute to a button, if you are using it as a menu button.
2627
+ */
2628
+ this.accessiblePopup = "false";
2418
2629
  /**
2419
2630
  * Loading state of the button
2420
2631
  */
@@ -2441,6 +2652,10 @@ let DuetButton$1 = class extends H {
2441
2652
  * Controls the padding of the component.
2442
2653
  */
2443
2654
  this.padding = "auto";
2655
+ /**
2656
+ * Centers the text of a button
2657
+ */
2658
+ this.centerText = false;
2444
2659
  /**
2445
2660
  * Controls the text wrapping.
2446
2661
  */
@@ -2605,6 +2820,7 @@ let DuetButton$1 = class extends H {
2605
2820
  "duet-button": true,
2606
2821
  "duet-button-is-small": this.size === "small",
2607
2822
  "duet-button-icon-only": this.iconOnly,
2823
+ "duet-button-text-center": this.centerText,
2608
2824
  "duet-button-negative": this.negative || this.variation === "negative",
2609
2825
  [this.variation]: true,
2610
2826
  disabled: this.disabled,
@@ -2630,7 +2846,7 @@ let DuetButton$1 = class extends H {
2630
2846
  "duet-theme-turva": this.theme === "turva",
2631
2847
  "duet-button-negative": this.negative || this.variation === "negative",
2632
2848
  [this.variation]: true,
2633
- } }, this.url ? (h$1("a", Object.assign({}, commonProps, { href: this.url, target: this.external ? "_blank" : "_self", rel: this.external ? "noopener" : undefined }), commonChildren, this.external && h$1("duet-visually-hidden", null, ", ", this.accessibleLabelExternal))) : (h$1("button", Object.assign({}, commonProps, { type: this.getButtonType(), disabled: this.disabled, name: this.name, value: this.value, "aria-pressed": this.accessiblePressed != null ? this.accessiblePressed.toString() : undefined }), commonChildren)), this.loading && h$1("duet-spinner", { color: "currentColor" }))));
2849
+ } }, this.url ? (h$1("a", Object.assign({}, commonProps, { href: this.url, target: this.external ? "_blank" : "_self", rel: this.external ? "noopener" : undefined }), commonChildren, this.external && h$1("duet-visually-hidden", null, ", ", this.accessibleLabelExternal))) : (h$1("button", Object.assign({}, commonProps, { type: this.getButtonType(), disabled: this.disabled, name: this.name, value: this.value, "aria-pressed": this.accessiblePressed != null ? this.accessiblePressed.toString() : undefined, "aria-haspopup": this.accessiblePopup != null ? this.accessiblePopup.toString() : undefined }), commonChildren)), this.loading && h$1("duet-spinner", { color: "currentColor" }))));
2634
2850
  }
2635
2851
  get element() { return this; }
2636
2852
  static get watchers() { return {
@@ -2690,24 +2906,6 @@ let DuetCaption$1 = class extends H {
2690
2906
 
2691
2907
  var actionArrowUp={"title":"action-arrow-up","tags":"action arrow up caret","svg":"<svg fill=\"currentColor\" viewBox=\"0 0 24 24\" xmlns=\"http://www.w3.org/2000/svg\" role=\"img\"><path d=\"M.75 17.939a.752.752 0 0 1-.53-1.281L10.94 5.94c.283-.284.659-.44 1.059-.44.401 0 .777.156 1.06.438l10.721 10.72a.752.752 0 0 1-.53 1.281.743.743 0 0 1-.53-.22L12 7 1.28 17.719a.743.743 0 0 1-.53.22z\"/></svg>"};
2692
2908
 
2693
- function chr4() {
2694
- return Math.random().toString(16).slice(-4);
2695
- }
2696
- function createID(prefix) {
2697
- return `${prefix}-${chr4()}${chr4()}-${chr4()}-${chr4()}-${chr4()}-${chr4()}${chr4()}${chr4()}`;
2698
- }
2699
-
2700
- const isArrowLeftKey = (e) => e.keyCode === 37;
2701
- const isArrowUpKey = (e) => e.keyCode === 38;
2702
- const isArrowRightKey = (e) => e.keyCode === 39;
2703
- const isArrowDownKey = (e) => e.keyCode === 40;
2704
- const isEscapeKey = (e) => e.key === "Escape" || e.key === "Esc" || e.keyCode === 27;
2705
- const isBackspaceKey = (e) => e.keyCode === 8;
2706
- const isSpaceKey = (e) => e.key === "Space" || e.keyCode === 32;
2707
- const isQuestionKey = (e) => e.key === "?";
2708
- const isEnterKey = (e) => e.key === "Enter" || e.keyCode === 13;
2709
- const isKeyboardClick = (e) => isEnterKey(e) || isSpaceKey(e);
2710
-
2711
2909
  const duetCardCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-bottom:20px !important;display:flex;width:100%;vertical-align:top}:host(.duet-card-info){margin-bottom:16px !important}:host(.duet-m-0){margin:0 !important}.duet-card{padding:20px !important;position:relative;display:block;width:100%;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;font-style:normal;font-weight:400;line-height:1.5;color:#00294d;text-decoration:none;border-radius:4px;box-shadow:0 2px 6px 0 rgba(0, 41, 77, 0.07), 0 -1px 0 0 rgba(0, 0, 0, 0.09), -1px 0 0 0 rgba(0, 0, 0, 0.07), 1px 0 0 0 rgba(0, 0, 0, 0.07), 0 1px 0 0 rgba(0, 0, 0, 0.07)}.duet-card.duet-p-0{padding:0 !important}.duet-card.duet-m-0{margin:0 !important}.duet-card:focus{outline:0;box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}.duet-theme-turva .duet-card:focus,.duet-card:focus.duet-theme-turva{box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}@media (min-width: 36em){.duet-card{padding:28px !important}}.duet-card.duet-theme-turva{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#171c3a;box-shadow:0 2px 6px 0 rgba(117, 117, 117, 0.13), 0 -1px 0 0 rgba(0, 0, 0, 0.09), -1px 0 0 0 rgba(0, 0, 0, 0.07), 1px 0 0 0 rgba(0, 0, 0, 0.07), 0 1px 0 0 rgba(0, 0, 0, 0.07)}@media (min-width: 36em){.duet-card.x-small{padding:20px !important}}@media (min-width: 36em){.duet-card.medium{padding:28px !important}}@media (min-width: 48em){.duet-card.medium{padding:36px !important}}@media (min-width: 36em){.duet-card.large{padding:36px !important}}@media (min-width: 48em){.duet-card.large{padding:48px !important}}@media (min-width: 36em){.duet-card.x-large{padding:48px !important}}@media (min-width: 48em){.duet-card.x-large{padding:72px !important}}.duet-card.duet-card-collapsed{padding-bottom:0 !important}@media (min-width: 36em){.duet-card.duet-card-collapsed{padding-bottom:0 !important}}.duet-card.info{background:rgba(0, 80, 128, 0.04) !important;box-shadow:none}.duet-card.info.duet-theme-turva{background:rgba(23, 28, 58, 0.035) !important}.duet-card.plain{box-shadow:none}.duet-card.plain:not(.duet-card-has-bg){background:transparent !important}.duet-card-heading-grid{display:flex;flex-direction:row}.duet-card-icon{align-self:center}.duet-card-heading-text{flex:1;word-break:break-word}.duet-card-secondary-heading{font-size:1rem;font-weight:600;word-break:break-word}.duet-card-secondary-heading--inline{display:block;flex:1;align-self:flex-start;line-height:1.875;text-align:right}@media (max-width: 22.5em){.duet-card-secondary-heading--inline{display:none}}.duet-card-secondary-heading--new-line{display:none}@media (max-width: 22.5em){.duet-card-secondary-heading--new-line{display:block}}.duet-card-heading{position:relative;display:block;padding:16px 20px;margin:-20px -20px 20px;overflow:hidden;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1.25rem;font-weight:800;color:#00294d;border-bottom:1px solid #e1e3e6}@media (min-width: 36em){.duet-card-heading{padding:15px 28px 16px !important;margin:-28px -28px 20px}}.duet-card-heading[role=button]{-webkit-user-select:none;user-select:none;cursor:pointer;border-radius:4px;-webkit-appearance:none;-webkit-tap-highlight-color:transparent;appearance:none}.duet-card-heading[role=button]:focus{outline:0}:host(.user-is-tabbing) .duet-card-heading[role=button]:focus{border-radius:4px;box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}:host(.user-is-tabbing) .duet-theme-turva .duet-card-heading[role=button]:focus{box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}.duet-card-collapsed .duet-card-heading{margin-bottom:0 !important;border-bottom:0 !important}.duet-theme-turva .duet-card-heading{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#171c3a;border-color:#e4e4e6}@media (min-width: 36em){.x-small .duet-card-heading{padding:10px 20px 11px !important;margin:-20px -20px 20px}}@media (min-width: 48em){.x-small .duet-card-heading{padding:10px 20px 11px !important;margin:-20px -20px 20px}}.medium .duet-card-heading{margin:-20px -20px 20px}@media (min-width: 36em){.medium .duet-card-heading{padding:15px 28px 16px !important;margin:-28px -28px 20px}}@media (min-width: 48em){.medium .duet-card-heading{padding:19px 36px 20px !important;margin:-36px -36px 28px}}.large .duet-card-heading{margin:-20px -20px 20px}@media (min-width: 36em){.large .duet-card-heading{padding:19px 36px 20px !important;margin:-36px -36px 28px}}@media (min-width: 48em){.large .duet-card-heading{padding:26px 48px 27px !important;margin:-48px -48px 36px}}.x-large .duet-card-heading{margin:-20px -20px 20px}@media (min-width: 36em){.x-large .duet-card-heading{padding:26px 48px 27px !important;margin:-48px -48px 36px}}@media (min-width: 48em){.x-large .duet-card-heading{padding:39px 72px 40px !important;margin:-72px -72px 48px}}.none .duet-card-heading{padding:0 0 20px !important;margin:0 0 20px}.duet-card-footer{padding:20px;margin:20px -20px -20px;font-size:0.875rem;line-height:1.25;background:#f5f8fa;border-bottom-right-radius:4px;border-bottom-left-radius:4px}.duet-theme-turva .duet-card-footer{background:#f5f5f7}@media (min-width: 36em){.duet-card-footer{padding:15px 28px 16px !important;margin:20px -28px -28px}}@media (min-width: 48em){.duet-card-footer{padding:15px 28px 16px !important;margin:20px -28px -28px}}@media (min-width: 36em){.x-small .duet-card-footer{padding:15px 28px 16px !important;padding-left:20px !important;margin:20px -20px -20px}}@media (min-width: 36em){.medium .duet-card-footer{padding:15px 28px 16px !important;margin:20px -28px -28px}}@media (min-width: 48em){.medium .duet-card-footer{padding:19px 36px 20px !important;margin:28px -36px -36px}}@media (min-width: 36em){.large .duet-card-footer{padding:19px 36px 20px !important;margin:28px -36px -36px}}@media (min-width: 48em){.large .duet-card-footer{padding:26px 48px 27px !important;margin:36px -48px -48px}}@media (min-width: 36em){.x-large .duet-card-footer{padding:26px 48px 27px !important;margin:36px -48px -48px}}@media (min-width: 48em){.x-large .duet-card-footer{padding:39px 72px 40px !important;margin:48px -72px -72px}}.none .duet-card-footer{padding:12px 0 !important;margin:20px 0 0}.duet-card-content{width:100%}.duet-card-collapsed .duet-card-content{display:none}.duet-card-caret{position:relative;top:6px;align-self:flex-start;transition:300ms ease}[aria-expanded=false] .duet-card-caret{transform:rotate(-180deg)}.duet-card-image-mask{position:relative;width:calc(100% + 40px);margin:-20px 0 20px -20px;overflow:hidden;border-top-left-radius:4px;border-top-right-radius:4px}@media (min-width: 36em){.small .duet-card-image-mask{width:calc(100% + 56px);margin:-28px 0 28px -28px}}@media (min-width: 36em){.medium .duet-card-image-mask{width:calc(100% + 56px);margin:-28px 0 28px -28px}}@media (min-width: 48em){.medium .duet-card-image-mask{width:calc(100% + 72px);margin:-36px 0 28px -36px}}@media (min-width: 36em){.large .duet-card-image-mask{width:calc(100% + 72px);margin:-36px 0 36px -36px}}@media (min-width: 48em){.large .duet-card-image-mask{width:calc(100% + 96px);margin:-48px 0 36px -48px}}@media (min-width: 36em){.x-large .duet-card-image-mask{width:calc(100% + 96px);margin:-48px 0 36px -48px}}@media (min-width: 48em){.x-large .duet-card-image-mask{width:calc(100% + 144px);margin:-72px 0 36px -72px}}.none .duet-card-image-mask{width:100%;margin:0 0 20px}.duet-card-image{display:block;width:102%;min-width:1px;max-width:102%;height:auto;min-height:1px;margin-left:-1%;transition:transform 300ms ease;transform:scale(1.0001)}a.duet-card{transition:box-shadow 300ms ease, background-position 300ms ease}a.duet-card:hover{box-shadow:0 2px 6px 0 rgba(0, 41, 77, 0.07), 0 -1px 0 0 rgba(0, 0, 0, 0.09), -1px 0 0 0 rgba(0, 0, 0, 0.07), 1px 0 0 0 rgba(0, 0, 0, 0.07), 0 1px 0 0 rgba(0, 0, 0, 0.07), 0 2px 10px 0 rgba(0, 41, 77, 0.1)}a.duet-card:hover .duet-card-image{transform:scale(1.024)}.duet-theme-turva a.duet-card:hover{box-shadow:0 2px 6px 0 rgba(117, 117, 117, 0.13), 0 -1px 0 0 rgba(0, 0, 0, 0.09), -1px 0 0 0 rgba(0, 0, 0, 0.07), 1px 0 0 0 rgba(0, 0, 0, 0.07), 0 1px 0 0 rgba(0, 0, 0, 0.07), 0 2px 10px 0 rgba(117, 117, 117, 0.15)}a.duet-card:active{transition:none;transform:translateY(1px)}";
2712
2910
 
2713
2911
  let DuetCard$1 = class extends H {
@@ -4158,7 +4356,7 @@ let DuetCollapsible$1 = class extends H {
4158
4356
  "duet-collapsible-heading": true,
4159
4357
  "duet-theme-turva": this.theme === "turva",
4160
4358
  "duet-collapsible-normal-weight": this.headingWeight === "normal",
4161
- }, style: { "font-size": this.getFontSizeFromTokens() }, role: "button", tabindex: "0", ref: button => (this.nativeButton = button), "aria-expanded": this.open ? "true" : "false", "aria-controls": this.id, onClick: this.handleClick, onKeyDown: this.handleKeyDown }, h$1("div", { class: "duet-collapsible-heading-icon" }, h$1("duet-icon", { margin: "none", color: this.theme === "turva" ? "secondary-turva" : "secondary", size: this.getEquivalentIconSize(), icon: actionArrowDownSmall.svg })), h$1("div", { class: "duet-collapsible-heading-content", part: "duet-collapsible-heading-content" }, this.heading)), h$1("div", { id: this.id, class: { "duet-collapsible-content": true, "duet-theme-turva": this.theme === "turva" } }, h$1("slot", null))));
4359
+ }, style: { "font-size": this.getFontSizeFromTokens() }, role: "button", tabindex: "0", ref: button => (this.nativeButton = button), "aria-expanded": this.open ? "true" : "false", "aria-controls": this.id, onClick: this.handleClick, onKeyDown: this.handleKeyDown }, h$1("div", { class: "duet-collapsible-heading-icon" }, h$1("duet-icon", { margin: "none", color: this.theme === "turva" ? "secondary-turva" : "secondary", size: this.getEquivalentIconSize(), icon: actionArrowDownSmall.svg })), h$1("div", { class: "duet-collapsible-heading-content", part: "duet-collapsible-heading-content" }, this.heading)), h$1("div", { id: this.id, class: { "duet-collapsible-content": true, "duet-theme-turva": this.theme === "turva" }, part: "duet-collapsible-content" }, h$1("slot", null))));
4162
4360
  }
4163
4361
  get element() { return this; }
4164
4362
  static get style() { return duetCollapsibleCss; }
@@ -4592,7 +4790,7 @@ const DatePickerMonth = ({ selectedDate, focusedDate, labelledById, theme, langu
4592
4790
  } }))))))))));
4593
4791
  };
4594
4792
 
4595
- const duetDatePickerCss = "*.sc-duet-date-picker,*.sc-duet-date-picker::after,*.sc-duet-date-picker::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}.sc-duet-date-picker-h{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-right:16px !important;margin-bottom:12px !important;position:relative;display:inline-flex;width:100%;min-width:calc(33.333% - 8px);max-width:100%;text-align:left;vertical-align:top}.sc-duet-date-picker-h:last-child,.sc-duet-date-picker-h:last-of-type{margin-right:0 !important}@media (min-width: 36em){.sc-duet-date-picker-h{width:calc(50% - 16px - 3px)}}.duet-expand.sc-duet-date-picker-h{width:100% !important}.duet-m-0.sc-duet-date-picker-h{margin:0 !important}.duet-date.sc-duet-date-picker{position:relative;width:100%}.duet-date.sc-duet-date-picker button.sc-duet-date-picker,.duet-date-dialog.sc-duet-date-picker button.sc-duet-date-picker{max-width:initial !important;min-height:initial !important;padding:0 !important;margin:0 !important;transition:initial}.duet-date-button.sc-duet-date-picker{-webkit-user-select:none;user-select:none;position:absolute;top:1px;right:1px;z-index:200;display:flex;align-items:center;justify-content:center;width:48px;height:calc(100% - 2px);color:#00294d;cursor:pointer;background:transparent !important;border-left:1px solid #cfd2d4 !important;border-radius:0 4px 4px 0 !important}.duet-theme-turva.sc-duet-date-picker .duet-date-button.sc-duet-date-picker{color:#171c3a;border-color:#cfcfd1}.duet-date-button.sc-duet-date-picker::before{position:absolute;top:0;left:-6px;width:6px;height:100%;content:\"\";background:linear-gradient(to left, rgba(207, 210, 212, 0.2) 0%, rgba(207, 210, 212, 0.2) 1px, rgba(207, 210, 212, 0.1) 1px, rgba(207, 210, 212, 0) 100%)}.duet-date-button.sc-duet-date-picker:disabled{pointer-events:none;cursor:default;background:#f5f8fa !important;border:0 !important}.duet-theme-turva.sc-duet-date-picker .duet-date-button.sc-duet-date-picker:disabled{background:#f5f5f7 !important}.duet-date-button.sc-duet-date-picker:disabled::before{display:none}.duet-date-button.sc-duet-date-picker:disabled duet-icon.sc-duet-date-picker{opacity:0.4}.duet-date-button.sc-duet-date-picker duet-icon.sc-duet-date-picker{transform:translateY(-1px)}.duet-date-button.sc-duet-date-picker:active duet-icon.sc-duet-date-picker{transform:translateY(0)}.duet-date-button.sc-duet-date-picker:focus{color:#0077b3;border-color:transparent;outline:0;box-shadow:0 0 0 2px #0077b3}.duet-theme-turva.sc-duet-date-picker .duet-date-button.sc-duet-date-picker:focus{color:#171c3a;box-shadow:0 0 0 2px #171c3a}.duet-date-dialog.sc-duet-date-picker{position:absolute;top:100%;left:0;z-index:900;display:flex;width:100%;visibility:hidden;opacity:0;transition:transform 300ms ease, opacity 300ms ease, visibility 300ms ease;transform:scale(0.96) translateZ(0) translateY(-20px);transform-origin:top right}@media (min-width: 36em){.duet-date-dialog.left.sc-duet-date-picker{right:0;left:auto;width:auto}}@media (max-width: 35.9375em){.duet-date-dialog.sc-duet-date-picker{position:fixed;top:0;right:0;bottom:0;background:rgba(0, 41, 77, 0.75);transition:opacity 400ms ease, visibility 400ms ease;transform:translateZ(0);transform-origin:bottom center}.duet-date-dialog.duet-theme-turva.sc-duet-date-picker{background:rgba(23, 28, 58, 0.75)}}.duet-date-dialog.active.sc-duet-date-picker{visibility:visible;opacity:1;transition-property:transform, opacity;transform:scale(1.0001) translateZ(0) translateY(0)}@media (min-width: 36em){.duet-date-dialog.error.sc-duet-date-picker{top:calc(100% - 28px);margin-top:4px}}.duet-date-dialog-wrapper.sc-duet-date-picker{position:relative;z-index:600;width:100%;min-width:290px;max-width:310px;padding:16px 16px 20px;margin-top:8px;margin-left:auto;background:white;border:1px solid #e1e3e6;border-radius:4px;box-shadow:0 4px 10px 0 rgba(0, 41, 77, 0.15);transform:none}.duet-theme-turva.sc-duet-date-picker .duet-date-dialog-wrapper.sc-duet-date-picker{border-color:#e4e4e6}@media (max-width: 35.9375em){.duet-date-dialog-wrapper.sc-duet-date-picker{position:absolute;bottom:0;left:0;z-index:900;max-width:none;min-height:25em;padding:0 8% 20px;margin:0;visibility:hidden;border:0;border-radius:0;border-top-left-radius:4px;border-top-right-radius:4px;opacity:0;transition:transform 400ms ease, opacity 400ms ease, visibility 400ms ease;transform:translateZ(0) translateY(100%)}.active.sc-duet-date-picker .duet-date-dialog-wrapper.sc-duet-date-picker{visibility:visible;opacity:1;transition-property:transform, opacity;transform:translateZ(0) translateY(0)}}.duet-date-table.sc-duet-date-picker{width:100%;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;font-weight:400;line-height:1.25;color:#00294d;text-align:center;border-spacing:0;border-collapse:collapse}.duet-date-table.duet-theme-turva.sc-duet-date-picker{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#171c3a}.duet-date-table.sc-duet-date-picker th.sc-duet-date-picker{padding-bottom:8px;font-size:0.75rem;font-weight:600;line-height:1.25;text-decoration:none;text-transform:uppercase;letter-spacing:1px}.duet-date-table.sc-duet-date-picker .duet-date-table-cell.sc-duet-date-picker{text-align:center}.duet-date-table-button.sc-duet-date-picker{position:relative;z-index:100;display:inline-block !important;width:36.9230769231px !important;height:36.9230769231px !important;min-height:initial !important;padding:0 !important;margin:0 !important;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:0.875rem;font-weight:400;font-variant-numeric:tabular-nums;line-height:1.25 !important;color:#00294d !important;text-align:center;vertical-align:initial !important;cursor:pointer;background:transparent !important;border-radius:50% !important;transition:initial !important}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.sc-duet-date-picker{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\" !important;color:#171c3a !important}.duet-date-table-button.sc-duet-date-picker:hover{background:#e6f2f8 !important}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.sc-duet-date-picker:hover{background:#f9e6ea !important}.duet-date-table-button.today.sc-duet-date-picker{z-index:200;color:#004d80 !important;background:#f3f9fc !important;box-shadow:0 0 0 1px #0077b3 !important}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.today.sc-duet-date-picker{color:#940925 !important;background:#fcf3f4 !important;box-shadow:0 0 0 1px #c60c30 !important}.duet-date-table-button[aria-pressed=true].sc-duet-date-picker,.duet-date-table-button.sc-duet-date-picker:focus{color:white !important;background:#0077b3 !important;outline:0}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button[aria-pressed=true].sc-duet-date-picker,.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.sc-duet-date-picker:focus{color:white !important;background:#c60c30 !important}.duet-date-table-button.sc-duet-date-picker:active{z-index:200;color:white !important;background:#0077b3 !important;box-shadow:0 0 5px #0077b3 !important}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.sc-duet-date-picker:active{color:white !important;background:#c60c30 !important;box-shadow:0 0 5px #c60c30 !important}.duet-date-table-button.sc-duet-date-picker:focus{z-index:200;box-shadow:0 0 5px #0077b3 !important}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.sc-duet-date-picker:focus{box-shadow:0 0 5px #c60c30 !important}.duet-date-table-button.disabled.sc-duet-date-picker{color:#909599 !important;cursor:default;background:transparent !important;box-shadow:none !important}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.disabled.sc-duet-date-picker{color:#747475 !important;background:transparent !important;box-shadow:none !important}.duet-date-table-button.outside.sc-duet-date-picker{color:#909599 !important;pointer-events:none;cursor:default;background:#f5f8fa !important;box-shadow:none;opacity:0.75}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.outside.sc-duet-date-picker{color:#747475;background:#f5f5f7;box-shadow:none}.duet-date-dialog-header.sc-duet-date-picker{margin-bottom:16px !important;display:flex;align-items:center;justify-content:space-between;width:100%}.duet-date-dialog-buttons.sc-duet-date-picker{white-space:nowrap}.duet-date-dialog-buttons.sc-duet-date-picker button.sc-duet-date-picker{display:inline-flex;align-items:center;justify-content:center;width:32px;height:32px;min-height:auto !important;padding:0 !important;margin:0 0 0 8px !important;color:#00294d;cursor:pointer;background:#f5f8fa;border-radius:50%;transition:background-color 300ms ease !important}.duet-theme-turva.sc-duet-date-picker .duet-date-dialog-buttons.sc-duet-date-picker button.sc-duet-date-picker{color:#171c3a;background:#f5f5f7}.duet-date-dialog-buttons.sc-duet-date-picker button.sc-duet-date-picker duet-icon.sc-duet-date-picker{display:block}@media (max-width: 35.9375em){.duet-date-dialog-buttons.sc-duet-date-picker button.sc-duet-date-picker{width:40px;height:40px}}.duet-date-dialog-buttons.sc-duet-date-picker button.sc-duet-date-picker:not(:disabled):hover{background:#e9ecee !important}.duet-theme-turva.sc-duet-date-picker .duet-date-dialog-buttons.sc-duet-date-picker button.sc-duet-date-picker:not(:disabled):hover{background:#e9e9eb !important}.duet-date-dialog-buttons.sc-duet-date-picker button.sc-duet-date-picker:focus{outline:0;box-shadow:0 0 0 2px #0077b3}.duet-theme-turva.sc-duet-date-picker .duet-date-dialog-buttons.sc-duet-date-picker button.sc-duet-date-picker:focus{box-shadow:0 0 0 2px #171c3a}.duet-date-dialog-buttons.sc-duet-date-picker button.sc-duet-date-picker:active:focus{background:#dddfe1;box-shadow:none}.duet-theme-turva.sc-duet-date-picker .duet-date-dialog-buttons.sc-duet-date-picker button.sc-duet-date-picker:active:focus{background:#ddddde}.duet-date-dialog-buttons.sc-duet-date-picker button.sc-duet-date-picker:disabled{color:#909599;cursor:default;background:#f5f8fa;opacity:0.75}.duet-theme-turva.sc-duet-date-picker .duet-date-dialog-buttons.sc-duet-date-picker button.sc-duet-date-picker:disabled{color:#747475;background:#f5f5f7}.duet-date-dialog-select.sc-duet-date-picker{position:relative;display:inline-flex;margin-top:4px}.duet-date-dialog-select.sc-duet-date-picker .duet-date-dialog-select-label.sc-duet-date-picker{position:relative;z-index:1;display:flex;align-items:center;width:100%;padding:0 8px;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1.25rem;font-weight:600;line-height:1.25;color:#00294d;pointer-events:none;border-radius:4px}.duet-theme-turva.sc-duet-date-picker .duet-date-dialog-select.sc-duet-date-picker .duet-date-dialog-select-label.sc-duet-date-picker{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#171c3a}.duet-date-dialog-select.sc-duet-date-picker span.sc-duet-date-picker{margin-right:4px}.duet-date-dialog-select.sc-duet-date-picker select.sc-duet-date-picker{position:absolute;top:0;left:0;z-index:2;width:100%;height:100%;font-size:1rem;cursor:pointer;opacity:0}.duet-date-dialog-select.sc-duet-date-picker select.sc-duet-date-picker:focus+.duet-date-dialog-select-label.sc-duet-date-picker{box-shadow:0 0 0 2px #0077b3}.duet-theme-turva.sc-duet-date-picker .duet-date-dialog-select.sc-duet-date-picker select.sc-duet-date-picker:focus+.duet-date-dialog-select-label.sc-duet-date-picker{box-shadow:0 0 0 2px #171c3a}.duet-date-dialog-mobile-header.sc-duet-date-picker{position:relative;display:flex;align-items:center;justify-content:space-between;width:120%;padding:12px 20px;margin-bottom:20px;margin-left:-10%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;border-bottom:1px solid #cfd2d4}@media (min-width: 36em){.duet-date-dialog-mobile-header.sc-duet-date-picker{position:absolute;top:-8px;right:-8px;width:auto;padding:0;margin:0;overflow:visible;border:0}}.duet-theme-turva.sc-duet-date-picker .duet-date-dialog-mobile-header.sc-duet-date-picker{border-color:#cfcfd1}.duet-date-dialog-mobile-header.sc-duet-date-picker duet-label.sc-duet-date-picker{display:inline-block;max-width:84%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}@media (min-width: 36em){.duet-date-dialog-mobile-header.sc-duet-date-picker duet-label.sc-duet-date-picker{display:none}}.duet-date-picker-close.sc-duet-date-picker{display:flex;align-items:center;justify-content:center;width:24px;height:24px !important;padding:0 !important;color:#00294d !important;cursor:pointer;background:#f5f8fa !important;border-radius:50%;-webkit-appearance:none;appearance:none}@media (min-width: 36em){.duet-date-picker-close.sc-duet-date-picker{opacity:0}}.duet-theme-turva.sc-duet-date-picker .duet-date-picker-close.sc-duet-date-picker{background:#f5f5f7 !important}.duet-date-picker-close.sc-duet-date-picker:hover{background:#f5f8fa !important}.duet-theme-turva.sc-duet-date-picker .duet-date-picker-close.sc-duet-date-picker:hover{background:#f5f5f7 !important}.duet-date-picker-close.sc-duet-date-picker:focus{outline:none;box-shadow:0 0 0 2px #0077b3}@media (min-width: 36em){.duet-date-picker-close.sc-duet-date-picker:focus{opacity:1}}.duet-theme-turva.sc-duet-date-picker .duet-date-picker-close.sc-duet-date-picker:focus{box-shadow:0 0 0 2px #171c3a}";
4793
+ const duetDatePickerCss = "*.sc-duet-date-picker,*.sc-duet-date-picker::after,*.sc-duet-date-picker::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}.sc-duet-date-picker-h{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-right:16px !important;margin-bottom:12px !important;position:relative;display:inline-flex;width:100%;min-width:calc(33.333% - 8px);max-width:100%;text-align:left;vertical-align:top}.sc-duet-date-picker-h:last-child,.sc-duet-date-picker-h:last-of-type{margin-right:0 !important}@media (min-width: 36em){.sc-duet-date-picker-h{width:calc(50% - 16px - 3px)}}.duet-expand.sc-duet-date-picker-h{width:100% !important}.duet-m-0.sc-duet-date-picker-h{margin:0 !important}.duet-date.sc-duet-date-picker{position:relative;width:100%}.duet-date.sc-duet-date-picker button.sc-duet-date-picker,.duet-date-dialog.sc-duet-date-picker button.sc-duet-date-picker{max-width:initial !important;min-height:initial !important;padding:0 !important;margin:0 !important;transition:initial}.duet-date-button.sc-duet-date-picker{-webkit-user-select:none;user-select:none;position:absolute;top:1px;right:1px;z-index:200;display:flex;align-items:center;justify-content:center;width:48px;height:calc(100% - 2px);color:#00294d;cursor:pointer;background:transparent !important;border-left:1px solid #cfd2d4 !important;border-radius:0 4px 4px 0 !important}.duet-theme-turva.sc-duet-date-picker .duet-date-button.sc-duet-date-picker{color:#171c3a;border-color:#cfcfd1}.duet-date-button.sc-duet-date-picker::before{position:absolute;top:0;left:-6px;width:6px;height:100%;content:\"\";background:linear-gradient(to left, rgba(207, 210, 212, 0.2) 0%, rgba(207, 210, 212, 0.2) 1px, rgba(207, 210, 212, 0.1) 1px, rgba(207, 210, 212, 0) 100%)}.duet-date-button.sc-duet-date-picker:disabled{pointer-events:none;cursor:default;background:#f5f8fa !important;border:0 !important}.duet-theme-turva.sc-duet-date-picker .duet-date-button.sc-duet-date-picker:disabled{background:#f5f5f7 !important}.duet-date-button.sc-duet-date-picker:disabled::before{display:none}.duet-date-button.sc-duet-date-picker:disabled duet-icon.sc-duet-date-picker{opacity:0.4}.duet-date-button.sc-duet-date-picker duet-icon.sc-duet-date-picker{transform:translateY(-1px)}.duet-date-button.sc-duet-date-picker:active duet-icon.sc-duet-date-picker{transform:translateY(0)}.duet-date-button.sc-duet-date-picker:focus{color:#0077b3;border-color:transparent;outline:0;box-shadow:0 0 0 2px #0077b3}.duet-theme-turva.sc-duet-date-picker .duet-date-button.sc-duet-date-picker:focus{color:#171c3a;box-shadow:0 0 0 2px #171c3a}.duet-date-dialog.sc-duet-date-picker{position:absolute;top:100%;left:0;z-index:900;display:flex;width:100%;visibility:hidden;opacity:0;transition:transform 300ms ease, opacity 300ms ease, visibility 300ms ease;transform:scale(0.96) translateZ(0) translateY(-20px);transform-origin:top right}@media (min-width: 36em){.duet-date-dialog.left.sc-duet-date-picker{right:0;left:auto;width:auto}}@media (max-width: 35.9375em){.duet-date-dialog.sc-duet-date-picker{position:fixed;top:0;right:0;bottom:0;background:rgba(0, 41, 77, 0.75);transition:opacity 400ms ease, visibility 400ms ease;transform:translateZ(0);transform-origin:bottom center}.duet-date-dialog.duet-theme-turva.sc-duet-date-picker{background:rgba(23, 28, 58, 0.75)}}.duet-date-dialog.active.sc-duet-date-picker{visibility:visible;opacity:1;transition-property:transform, opacity;transform:scale(1.0001) translateZ(0) translateY(0)}@media (min-width: 36em){.duet-date-dialog.error.sc-duet-date-picker{top:calc(100% - 28px);margin-top:4px}}.duet-date-dialog-wrapper.sc-duet-date-picker{position:relative;z-index:600;width:100%;min-width:290px;max-width:310px;padding:16px 16px 20px;margin-top:8px;margin-left:auto;background:white;border:1px solid #e1e3e6;border-radius:4px;box-shadow:0 4px 10px 0 rgba(0, 41, 77, 0.15);transform:none}.duet-theme-turva.sc-duet-date-picker .duet-date-dialog-wrapper.sc-duet-date-picker{border-color:#e4e4e6}@media (max-width: 35.9375em){.duet-date-dialog-wrapper.sc-duet-date-picker{position:absolute;bottom:0;left:0;z-index:900;max-width:none;min-height:25em;padding:0 8% 20px;margin:0;visibility:hidden;border:0;border-radius:0;border-top-left-radius:4px;border-top-right-radius:4px;opacity:0;transition:transform 400ms ease, opacity 400ms ease, visibility 400ms ease;transform:translateZ(0) translateY(100%)}.active.sc-duet-date-picker .duet-date-dialog-wrapper.sc-duet-date-picker{visibility:visible;opacity:1;transition-property:transform, opacity;transform:translateZ(0) translateY(0)}}.duet-date-table.sc-duet-date-picker{width:100%;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;font-weight:400;line-height:1.25;color:#00294d;text-align:center;border-spacing:0;border-collapse:collapse}.duet-date-table.duet-theme-turva.sc-duet-date-picker{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#171c3a}.duet-date-table.sc-duet-date-picker th.sc-duet-date-picker{padding-bottom:8px;font-size:0.75rem;font-weight:600;line-height:1.25;text-decoration:none;text-transform:uppercase;letter-spacing:1px}.duet-date-table.sc-duet-date-picker .duet-date-table-cell.sc-duet-date-picker{text-align:center}.duet-date-table-button.sc-duet-date-picker{position:relative;z-index:100;display:inline-block !important;width:36.9230769231px !important;height:36.9230769231px !important;min-height:initial !important;padding:0 !important;margin:0 !important;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:0.875rem;font-weight:400;font-variant-numeric:tabular-nums;line-height:1.25 !important;color:#00294d !important;text-align:center;vertical-align:initial !important;cursor:pointer;background:transparent !important;border-radius:50% !important;transition:initial !important}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.sc-duet-date-picker{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\" !important;color:#171c3a !important}.duet-date-table-button.sc-duet-date-picker:hover{background:#e6f2f8 !important}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.sc-duet-date-picker:hover{background:#f9e6ea !important}.duet-date-table-button.today.sc-duet-date-picker{z-index:200;color:#004d80 !important;background:#f3f9fc !important;box-shadow:0 0 0 1px #0077b3 !important}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.today.sc-duet-date-picker{color:#940925 !important;background:#fcf3f4 !important;box-shadow:0 0 0 1px #c60c30 !important}.duet-date-table-button[aria-pressed=true].sc-duet-date-picker,.duet-date-table-button.sc-duet-date-picker:focus{color:white !important;background:#0077b3 !important;outline:0}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button[aria-pressed=true].sc-duet-date-picker,.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.sc-duet-date-picker:focus{color:white !important;background:#c60c30 !important}.duet-date-table-button.sc-duet-date-picker:active{z-index:200;color:white !important;background:#0077b3 !important;box-shadow:0 0 5px #0077b3 !important}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.sc-duet-date-picker:active{color:white !important;background:#c60c30 !important;box-shadow:0 0 5px #c60c30 !important}.duet-date-table-button.sc-duet-date-picker:focus{z-index:200;box-shadow:0 0 5px #0077b3 !important}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.sc-duet-date-picker:focus{box-shadow:0 0 5px #c60c30 !important}.duet-date-table-button.disabled.sc-duet-date-picker{color:#909599 !important;cursor:default;background:transparent !important;box-shadow:none !important}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.disabled.sc-duet-date-picker{color:#747475 !important;background:transparent !important;box-shadow:none !important}.duet-date-table-button.outside.sc-duet-date-picker{color:#909599 !important;pointer-events:none;cursor:default;background:#f5f8fa !important;box-shadow:none;opacity:0.75}.duet-theme-turva.sc-duet-date-picker .duet-date-table-button.outside.sc-duet-date-picker{color:#747475;background:#f5f5f7;box-shadow:none}.duet-date-dialog-header.sc-duet-date-picker{margin-bottom:16px !important;display:flex;align-items:center;justify-content:space-between;width:100%}.duet-date-dialog-buttons.sc-duet-date-picker{white-space:nowrap}.duet-date-dialog-buttons.sc-duet-date-picker .sc-duet-date-picker::part(button){border:0}.duet-date-dialog-select.sc-duet-date-picker{position:relative;display:inline-flex;margin-top:4px}.duet-date-dialog-select.sc-duet-date-picker .duet-date-dialog-select-label.sc-duet-date-picker{position:relative;z-index:1;display:flex;align-items:center;width:100%;padding:0 8px;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1.25rem;font-weight:600;line-height:1.25;color:#00294d;pointer-events:none;border-radius:4px}.duet-theme-turva.sc-duet-date-picker .duet-date-dialog-select.sc-duet-date-picker .duet-date-dialog-select-label.sc-duet-date-picker{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#171c3a}.duet-date-dialog-select.sc-duet-date-picker span.sc-duet-date-picker{margin-right:4px}.duet-date-dialog-select.sc-duet-date-picker select.sc-duet-date-picker{position:absolute;top:0;left:0;z-index:2;width:100%;height:100%;font-size:1rem;cursor:pointer;opacity:0}.duet-date-dialog-select.sc-duet-date-picker select.sc-duet-date-picker:focus+.duet-date-dialog-select-label.sc-duet-date-picker{box-shadow:0 0 0 2px #0077b3}.duet-theme-turva.sc-duet-date-picker .duet-date-dialog-select.sc-duet-date-picker select.sc-duet-date-picker:focus+.duet-date-dialog-select-label.sc-duet-date-picker{box-shadow:0 0 0 2px #171c3a}.duet-date-dialog-mobile-header.sc-duet-date-picker{position:relative;display:flex;align-items:center;justify-content:space-between;width:120%;padding:12px 20px;margin-bottom:20px;margin-left:-10%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;border-bottom:1px solid #cfd2d4}@media (min-width: 36em){.duet-date-dialog-mobile-header.sc-duet-date-picker{position:absolute;top:-8px;right:-8px;width:auto;padding:0;margin:0;overflow:visible;border:0}}.duet-theme-turva.sc-duet-date-picker .duet-date-dialog-mobile-header.sc-duet-date-picker{border-color:#cfcfd1}.duet-date-dialog-mobile-header.sc-duet-date-picker duet-label.sc-duet-date-picker{display:inline-block;max-width:84%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}@media (min-width: 36em){.duet-date-dialog-mobile-header.sc-duet-date-picker duet-label.sc-duet-date-picker{display:none}}.duet-date-picker-close.sc-duet-date-picker{display:flex;align-items:center;justify-content:center;width:24px;height:24px !important;padding:0 !important;color:#00294d !important;cursor:pointer;background:#f5f8fa !important;border-radius:50%;-webkit-appearance:none;appearance:none}@media (min-width: 36em){.duet-date-picker-close.sc-duet-date-picker{opacity:0}}.duet-theme-turva.sc-duet-date-picker .duet-date-picker-close.sc-duet-date-picker{background:#f5f5f7 !important}.duet-date-picker-close.sc-duet-date-picker:hover{background:#f5f8fa !important}.duet-theme-turva.sc-duet-date-picker .duet-date-picker-close.sc-duet-date-picker:hover{background:#f5f5f7 !important}.duet-date-picker-close.sc-duet-date-picker:focus{outline:none;box-shadow:0 0 0 2px #0077b3}@media (min-width: 36em){.duet-date-picker-close.sc-duet-date-picker:focus{opacity:1}}.duet-theme-turva.sc-duet-date-picker .duet-date-picker-close.sc-duet-date-picker:focus{box-shadow:0 0 0 2px #171c3a}";
4596
4794
 
4597
4795
  let DuetDatePicker$1 = class extends H {
4598
4796
  constructor() {
@@ -4988,7 +5186,7 @@ let DuetDatePicker$1 = class extends H {
4988
5186
  left: this.direction === "left",
4989
5187
  error: !!this.error,
4990
5188
  active: this.open,
4991
- }, role: "dialog", "aria-modal": "true", "aria-hidden": this.open ? "false" : "true", "aria-labelledby": this.dialogLabelId, onTouchMove: this.handleTouchMove, onTouchStart: this.handleTouchStart, onTouchEnd: this.handleTouchEnd }, h$1(FocusGuard, { moveFocusTo: this.focusedDayNode }), h$1("div", { class: "duet-date-dialog-wrapper", onKeyDown: this.handleEscKey, ref: element => (this.dialogWrapperNode = element) }, h$1("duet-visually-hidden", { "aria-live": "polite" }, text.keyboardInstruction), h$1("div", { class: "duet-date-dialog-mobile-header" }, h$1("duet-label", { margin: "none" }, this.label), h$1("button", { class: "duet-date-picker-close", ref: element => (this.closeButtonNode = element), onClick: () => this.hide(), type: "button" }, h$1("duet-icon", { name: "navigation-close-small", margin: "none", color: "currentColor", size: "xx-small" }), h$1("duet-visually-hidden", null, text.closeLabel))), h$1("div", { class: "duet-date-dialog-header" }, h$1("div", { class: "duet-date-dialog-dropdowns" }, h$1("duet-visually-hidden", null, h$1("h2", { id: this.dialogLabelId, "aria-live": "polite", "aria-atomic": "true" }, text.monthLabels[focusedMonth], " ", this.focusedDay.getFullYear())), h$1("duet-visually-hidden", null, h$1("label", { htmlFor: this.monthSelectId }, text.monthSelectLabel)), h$1("div", { class: "duet-date-dialog-select" }, h$1("select", { id: this.monthSelectId, class: "duet-date-month-select", ref: element => (this.monthSelectNode = element), onChange: this.handleMonthSelect }, text.monthLabels.map((month, i) => (h$1("option", { key: month, value: i, selected: i === focusedMonth, disabled: !inRange(new Date(focusedYear, i, 1), minDate ? startOfMonth(minDate) : null, maxDate ? endOfMonth(maxDate) : null) }, month)))), h$1("div", { class: "duet-date-dialog-select-label", "aria-hidden": "true" }, h$1("span", null, text.monthLabelsShort[focusedMonth]), h$1("duet-icon", { name: "action-arrow-down-small", color: "currentColor", margin: "none", size: "xxx-small" }))), h$1("duet-visually-hidden", null, h$1("label", { htmlFor: this.yearSelectId }, text.yearSelectLabel)), h$1("div", { class: "duet-date-dialog-select" }, h$1("select", { id: this.yearSelectId, class: "duet-date-year-select", onChange: this.handleYearSelect }, range(minYear, maxYear).map(year => (h$1("option", { key: year, selected: year === focusedYear }, year)))), h$1("div", { class: "duet-date-dialog-select-label", "aria-hidden": "true" }, h$1("span", null, this.focusedDay.getFullYear()), h$1("duet-icon", { name: "action-arrow-down-small", color: "currentColor", margin: "none", size: "xxx-small" })))), h$1("div", { class: "duet-date-dialog-buttons" }, h$1("button", { class: "duet-date-dialog-prev", onClick: this.handlePreviousMonthClick, disabled: prevMonthDisabled, type: "button" }, h$1("duet-icon", { name: "action-arrow-left-small", color: "currentColor", margin: "none", size: "xx-small" }), h$1("duet-visually-hidden", null, text.prevMonthLabel)), h$1("button", { class: "duet-date-dialog-next", onClick: this.handleNextMonthClick, disabled: nextMonthDisabled, type: "button" }, h$1("duet-icon", { name: "action-arrow-right-small", color: "currentColor", margin: "none", size: "xx-small" }), h$1("duet-visually-hidden", null, text.nextMonthLabel)))), h$1(DatePickerMonth, { selectedDate: valueAsDate, focusedDate: this.focusedDay, onDateSelect: this.handleDaySelect, onKeyboardNavigation: this.handleKeyboardNavigation, labelledById: this.dialogLabelId, language: this.language, theme: this.theme, min: minDate, max: maxDate, focusedDayRef: element => (this.focusedDayNode = element), onFocusEnter: this.enableActiveFocus, onFocusExit: this.disableActiveFocus })), h$1(FocusGuard, { moveFocusTo: this.closeButtonNode }))));
5189
+ }, role: "dialog", "aria-modal": "true", "aria-hidden": this.open ? "false" : "true", "aria-labelledby": this.dialogLabelId, onTouchMove: this.handleTouchMove, onTouchStart: this.handleTouchStart, onTouchEnd: this.handleTouchEnd }, h$1(FocusGuard, { moveFocusTo: this.focusedDayNode }), h$1("div", { class: "duet-date-dialog-wrapper", onKeyDown: this.handleEscKey, ref: element => (this.dialogWrapperNode = element) }, h$1("duet-visually-hidden", { "aria-live": "polite" }, text.keyboardInstruction), h$1("div", { class: "duet-date-dialog-mobile-header" }, h$1("duet-label", { margin: "none" }, this.label), h$1("button", { class: "duet-date-picker-close", ref: element => (this.closeButtonNode = element), onClick: () => this.hide(), type: "button" }, h$1("duet-icon", { name: "navigation-close-small", margin: "none", color: "currentColor", size: "xx-small" }), h$1("duet-visually-hidden", null, text.closeLabel))), h$1("div", { class: "duet-date-dialog-header" }, h$1("div", { class: "duet-date-dialog-dropdowns" }, h$1("duet-visually-hidden", null, h$1("h2", { id: this.dialogLabelId, "aria-live": "polite", "aria-atomic": "true" }, text.monthLabels[focusedMonth], " ", this.focusedDay.getFullYear())), h$1("duet-visually-hidden", null, h$1("label", { htmlFor: this.monthSelectId }, text.monthSelectLabel)), h$1("div", { class: "duet-date-dialog-select" }, h$1("select", { id: this.monthSelectId, class: "duet-date-month-select", ref: element => (this.monthSelectNode = element), onChange: this.handleMonthSelect }, text.monthLabels.map((month, i) => (h$1("option", { key: month, value: i, selected: i === focusedMonth, disabled: !inRange(new Date(focusedYear, i, 1), minDate ? startOfMonth(minDate) : null, maxDate ? endOfMonth(maxDate) : null) }, month)))), h$1("div", { class: "duet-date-dialog-select-label", "aria-hidden": "true" }, h$1("span", null, text.monthLabelsShort[focusedMonth]), h$1("duet-icon", { name: "action-arrow-down-small", color: "currentColor", margin: "none", size: "xxx-small" }))), h$1("duet-visually-hidden", null, h$1("label", { htmlFor: this.yearSelectId }, text.yearSelectLabel)), h$1("div", { class: "duet-date-dialog-select" }, h$1("select", { id: this.yearSelectId, class: "duet-date-year-select", onChange: this.handleYearSelect }, range(minYear, maxYear).map(year => (h$1("option", { key: year, selected: year === focusedYear }, year)))), h$1("div", { class: "duet-date-dialog-select-label", "aria-hidden": "true" }, h$1("span", null, this.focusedDay.getFullYear()), h$1("duet-icon", { name: "action-arrow-down-small", color: "currentColor", margin: "none", size: "xxx-small" })))), h$1("div", { class: "duet-date-dialog-buttons" }, h$1("duet-action-button", { class: "duet-date-dialog-prev", onClick: this.handlePreviousMonthClick, disabled: prevMonthDisabled, "icon-name": "action-arrow-left-small" }, text.prevMonthLabel), h$1("duet-action-button", { class: "duet-date-dialog-next", onClick: this.handleNextMonthClick, disabled: nextMonthDisabled, "icon-name": "action-arrow-right-small" }, text.nextMonthLabel))), h$1(DatePickerMonth, { selectedDate: valueAsDate, focusedDate: this.focusedDay, onDateSelect: this.handleDaySelect, onKeyboardNavigation: this.handleKeyboardNavigation, labelledById: this.dialogLabelId, language: this.language, theme: this.theme, min: minDate, max: maxDate, focusedDayRef: element => (this.focusedDayNode = element), onFocusEnter: this.enableActiveFocus, onFocusExit: this.disableActiveFocus })), h$1(FocusGuard, { moveFocusTo: this.closeButtonNode }))));
4992
5190
  }
4993
5191
  get element() { return this; }
4994
5192
  static get watchers() { return {
@@ -5014,394 +5212,241 @@ let DuetDivider$1 = class extends H {
5014
5212
  /**
5015
5213
  * Controls the margin of the component.
5016
5214
  */
5017
- this.margin = "auto";
5018
- }
5019
- /**
5020
- * Component lifecycle events.
5021
- */
5022
- componentWillLoad() {
5023
- inheritGlobalTheme(this);
5024
- }
5025
- /**
5026
- * render() function
5027
- * Always the last one in the class.
5028
- */
5029
- render() {
5030
- return (h$1("div", { class: {
5031
- "duet-m-0": this.margin === "none",
5032
- "duet-m-s": this.margin === "small",
5033
- "duet-divider": true,
5034
- "duet-theme-turva": this.theme === "turva",
5035
- } }));
5036
- }
5037
- get element() { return this; }
5038
- static get style() { return duetDividerCss; }
5039
- };
5040
-
5041
- const debounce = (func, timeout = 50) => {
5042
- let timer;
5043
- return (...args) => {
5044
- clearTimeout(timer);
5045
- timer = setTimeout(() => {
5046
- func.apply(undefined, args);
5047
- }, timeout);
5048
- };
5049
- };
5050
-
5051
- /**
5052
- * Produces a function which uses template strings to do simple interpolation from objects.
5053
- *
5054
- * Usage:
5055
- * var makeMeKing = generateTemplateFn('${name} is now the king of ${country}!');
5056
- *
5057
- * console.log(makeMeKing({ name: 'Bryan', country: 'Scotland'}));
5058
- * // Logs 'Bryan is now the king of Scotland!'
5059
- */
5060
- const generateTemplateFn = (function () {
5061
- const cache = {};
5062
- function generateTemplate(template) {
5063
- if (typeof template !== "string") {
5064
- template = template.outerHTML;
5065
- }
5066
- let fn = cache[template];
5067
- if (!fn) {
5068
- // Replace ${expressions} (etc) with ${map.expressions}.
5069
- const sanitized = template
5070
- .replace(/\$\{([\s]*[^;\s\{]+[\s]*)\}/g, function (_, match) {
5071
- return `\$\{map.${match.trim()}\}`;
5072
- })
5073
- // Afterwards, replace anything that's not ${map.expressions}' (etc) with a blank string.
5074
- .replace(/(\$\{(?!map\.)[^}]+\})/g, "");
5075
- fn = Function("map", `return \`${sanitized}\``);
5076
- }
5077
- return fn;
5078
- }
5079
- return generateTemplate;
5080
- })();
5081
-
5082
- const duetEditableTableCss = "duet-editable-table{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}.duet-editable-table-header tr .duet-editable-table-header-hidden{padding:0 !important;font-size:0;border-bottom:0}";
5083
-
5084
- let DuetEditableTable$1 = class extends H {
5085
- constructor() {
5086
- super();
5087
- this.__registerHost();
5088
- this.__attachShadow();
5089
- this.template = undefined;
5090
- /**
5091
- * State() variables
5092
- * @internal
5093
- */
5094
- this.tick = Date.now();
5095
- /**
5096
- * Map of items that contain list of things.
5097
- */
5098
- this.items = new Map();
5099
- /**
5100
- * Key used to set vertical alignment of action buttons
5101
- */
5102
- this.alignment = "middle";
5103
- /**
5104
- * Array of internationalized defaults for the default groups labels.
5105
- */
5106
- this.groupsLabelDefaults = {
5107
- fi: "Kaikki",
5108
- en: "All items",
5109
- sv: "Alla objekt",
5110
- };
5111
- /**
5112
- * Array of internationalized defaults for the default action labels.
5113
- */
5114
- this.actionLabelDefaults = {
5115
- fi: "Toiminnot",
5116
- en: "Actions",
5117
- sv: "Handlingar",
5118
- };
5119
- /**
5120
- * Array of group names that you want the editable table to display (can be used to hide or show groups depending on conditions).
5121
- * @default { id: "all", label: this.groupsLabelDefaults, actionLabel: this.actionLabelDefaults }.
5122
- * @example [{ id: "success", label: {fi: "Onnistunut", en: "Success", sv: "Alt klart", }}].
5123
- */
5124
- this.groups = [
5125
- { id: "all", label: this.groupsLabelDefaults, actionLabel: this.actionLabelDefaults },
5126
- ];
5127
- /**
5128
- * Array of actions that are mapped via the map variable to the various groups defined in group.
5129
- * @default undefined
5130
- * @example [{
5131
- variation: "default",
5132
- icon: "action-edit-2",
5133
- id: "edit",
5134
- map: ["success"],
5135
- label: {
5136
- fi: " Label",
5137
- en: " Label",
5138
- sv: " Label",
5139
- }
5140
- }]
5141
- */
5142
- this.actions = undefined;
5143
- /**
5144
- * Shows or hides the table labels.
5145
- */
5146
- this.hideGroups = false;
5147
- /**
5148
- * Exposes the aria role for optimizing accessibility.
5149
- */
5150
- this.accessibleRole = undefined;
5151
- /**
5152
- * Theme of the table.
5153
- */
5154
- this.theme = "";
5155
- /**
5156
- * Private methods.
5157
- */
5158
- this.kick = debounce(() => {
5159
- this.tick = Date.now();
5160
- }, 100); // will trigger re-render
5161
- /**
5162
- * If a user defines a template section within editable table, try to read an use it.
5163
- */
5164
- this.getTemplate = () => {
5165
- const templateDom = this.element.getElementsByTagName("template");
5166
- if (templateDom === null || templateDom === void 0 ? void 0 : templateDom.length) {
5167
- const templateString = templateDom[0].content.firstElementChild.outerHTML;
5168
- return generateTemplateFn(templateString);
5169
- }
5170
- else {
5171
- return false;
5172
- }
5173
- };
5174
- this.getItemData = (data) => {
5175
- const { item, group, uid } = data;
5176
- if (this.template) {
5177
- return {
5178
- group,
5179
- uid,
5180
- item: this.template(item),
5181
- };
5182
- }
5183
- return { item, group, uid };
5184
- };
5185
- this.filterMap = needle => {
5186
- if (needle === "all") {
5187
- return Array.from(this.items);
5188
- }
5189
- return Array.from(this.items).filter(item => needle === item[1].group);
5190
- };
5191
- }
5192
- /**
5193
- * Component lifecycle events.
5194
- */
5195
- componentWillLoad() {
5196
- // look for a <template> region in the duet-editable-table
5197
- this.template = this.getTemplate();
5198
- // take care of the case where groups and actions are defined as html properties instead of javascript objects
5199
- if (typeof this.groups === "string") {
5200
- this.internalGroupArray = sanitizeString(this.groups);
5201
- }
5202
- else {
5203
- this.internalGroupArray = this.groups;
5204
- }
5205
- if (typeof this.actions === "string") {
5206
- this.internalActionsArray = sanitizeString(this.actions);
5207
- }
5208
- else {
5209
- this.internalActionsArray = this.actions;
5210
- }
5211
- inheritGlobalTheme(this);
5212
- }
5213
- /**
5214
- * Method to force an update of a tabular data array.
5215
- * when called the method will rerender the entire tabular structure.
5216
- */
5217
- async updateTable(passedItems = undefined) {
5218
- this.items = new Map(passedItems || this.items);
5219
- this.kick();
5220
- }
5221
- render() {
5222
- return (h$1(Host, { class: {
5223
- "duet-theme-turva": this.theme === "turva",
5224
- } }, this.internalGroupArray.map(group => {
5225
- const currentGroup = this.filterMap(group.id);
5226
- if (!currentGroup.length) {
5227
- return;
5228
- }
5229
- return (h$1("duet-table", { variation: "plain", breakpoint: "none", role: "", margin: this.hideGroups ? "none" : "auto" }, h$1("table", { class: "duet-editable-table", "aria-role": this.accessibleRole }, h$1("thead", { class: "duet-editable-table-header" }, h$1("tr", null, h$1("th", { class: {
5230
- "duet-editable-table-header-hidden": this.hideGroups,
5231
- } }, !this.hideGroups ? (getLocaleString(group.label)) : (h$1("duet-visually-hidden", null, getLocaleString(group.label)))), h$1("th", { class: {
5232
- "duet-editable-table-header-hidden": this.hideGroups,
5233
- } }, h$1("duet-visually-hidden", null, group.actionLabel
5234
- ? getLocaleString(group.actionLabel)
5235
- : getLocaleString(this.actionLabelDefaults))))), h$1("tbody", null, currentGroup.map(dataAsArray => {
5236
- const [key, value] = dataAsArray;
5237
- return (h$1("duet-editable-table-item", { theme: this.theme, keyName: key, data: this.getItemData(value), groupId: group.id, part: group.id, alignment: this.alignment, actions: this.internalActionsArray }));
5238
- })))));
5239
- })));
5240
- }
5241
- get element() { return this; }
5242
- static get style() { return duetEditableTableCss; }
5243
- };
5244
-
5245
- const duetEditableTableButtonCss = "*.sc-duet-editable-table-button,*.sc-duet-editable-table-button::after,*.sc-duet-editable-table-button::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}.sc-duet-editable-table-button-h button.sc-duet-editable-table-button{display:flex;align-content:space-between;justify-content:center;min-width:32px;max-width:32px;height:100%;min-height:32px;max-height:32px;padding:0;margin:0;cursor:pointer !important;background-color:transparent;border:1px solid;border-radius:50%}.sc-duet-editable-table-button-h button.sc-duet-editable-table-button duet-icon.sc-duet-editable-table-button{align-self:center}";
5246
-
5247
- let DuetEditableTableButton$1 = class extends H {
5248
- constructor() {
5249
- super();
5250
- this.__registerHost();
5251
- this.duetEditableItemAction = createEvent$2(this, "duetEditableItemAction", 7);
5252
- this.isHovering = false;
5253
- /**
5254
- * Theme of the empty state component.
5255
- */
5256
- this.theme = undefined;
5257
- /**
5258
- * action items passed from host component
5259
- * @internal
5260
- */
5261
- this.actions = undefined;
5262
- /**
5263
- * uid that gets passed along when the action is emitted
5264
- * @internal
5265
- */
5266
- this.uid = "";
5267
- /**
5268
- * group associated with action
5269
- * @internal
5270
- */
5271
- this.group = "";
5272
- /**
5273
- * key of the item in the map
5274
- * @internal
5275
- */
5276
- this.keyName = "";
5277
- this.onMouseEnter = () => {
5278
- this.isHovering = true;
5279
- };
5280
- this.onMouseLeave = () => {
5281
- this.isHovering = false;
5282
- };
5283
- this.getColours = (byName = false) => {
5284
- let colorHover = this.actions.color_hover;
5285
- let colorBlur = this.actions.color;
5286
- if (byName) {
5287
- colorHover = getColorByName(this.actions.color_hover, this.theme);
5288
- colorBlur = getColorByName(this.actions.color, this.theme);
5289
- }
5290
- return this.isHovering ? colorHover : colorBlur;
5291
- };
5215
+ this.margin = "auto";
5292
5216
  }
5293
5217
  /**
5294
- /**
5295
5218
  * Component lifecycle events.
5296
5219
  */
5297
5220
  componentWillLoad() {
5298
5221
  inheritGlobalTheme(this);
5299
5222
  }
5300
- /**
5301
- /**
5302
- * private functions
5303
- */
5304
- emitActionEvent(ev) {
5305
- this.duetEditableItemAction.emit({
5306
- originalEvent: ev,
5307
- uid: this.uid,
5308
- group: this.group,
5309
- action: this.actions.id,
5310
- keyName: this.keyName,
5311
- component: "duet-editable-table-item",
5312
- });
5313
- }
5314
5223
  /**
5315
5224
  * render() function
5316
5225
  * Always the last one in the class.
5317
5226
  */
5318
5227
  render() {
5319
- return (h$1("button", { style: {
5320
- "border-color": this.getColours(true),
5321
- }, onMouseEnter: this.onMouseEnter, onMouseLeave: this.onMouseLeave, role: "menuitem", class: "duet-editable-table-actions-items-button", "aria-label": this.actions.label ? getLocaleString(this.actions.label) : undefined, onClick: ev => this.emitActionEvent(ev) }, h$1("duet-icon", { class: "duet-editable-table-actions-items-icon", size: "x-small", name: this.actions.icon, color: this.getColours(), margin: "none" })));
5228
+ return (h$1("div", { class: {
5229
+ "duet-m-0": this.margin === "none",
5230
+ "duet-m-s": this.margin === "small",
5231
+ "duet-divider": true,
5232
+ "duet-theme-turva": this.theme === "turva",
5233
+ } }));
5322
5234
  }
5323
- get el() { return this; }
5324
- static get style() { return duetEditableTableButtonCss; }
5235
+ get element() { return this; }
5236
+ static get style() { return duetDividerCss; }
5325
5237
  };
5326
5238
 
5327
5239
  //simple functional component that renders the data in the table
5328
5240
  const TableData = ({ data, groupId, alignment }, _children) => {
5241
+ const classNames = `duet-editable-table duet-editable-table-content-${groupId}`;
5329
5242
  if (typeof data === "string") {
5330
- return (h("td", { innerHTML: data, class: "duet-editable-table-content", part: `${groupId}content`, style: { verticalAlign: alignment } }));
5243
+ return h("td", { innerHTML: data, class: classNames, part: `${groupId}content`, style: { verticalAlign: alignment } });
5331
5244
  }
5332
5245
  else {
5333
- return (h("td", { class: "duet-editable-table-content", part: `${groupId}content`, style: { verticalAlign: alignment } }, data));
5246
+ return (h("td", { class: classNames, part: `${groupId}content`, style: { verticalAlign: alignment } }, data));
5334
5247
  }
5335
5248
  };
5336
5249
 
5337
- const duetEditableTableItemCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{display:table-row;height:32px}.duet-editable-table-content,.duet-editable-table-actions{height:32px;padding:12px 0;vertical-align:middle;break-word:break-all;border-bottom:1px solid #e1e3e6}.duet-editable-table-actions-items{display:flex;justify-content:flex-end}.duet-editable-table-actions-items duet-editable-table-button{padding-left:8px}.duet-editable-table .editable-item-small{font-size:0.75rem;font-weight:400}";
5250
+ const duetEditableTableCss = ".sc-duet-editable-table-h{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}.duet-editable-table-actions-menu.sc-duet-editable-table{position:relative;padding:0 !important;margin:0}.duet-editable-table-actions-menu-button.sc-duet-editable-table{position:relative;right:-16px;float:right;padding:0}.duet-editable-table-actions-menu-icon.sc-duet-editable-table .duet-icon.sc-duet-editable-table{max-width:16px;max-height:16px}.duet-editable-table-row.duet-table-action-row.sc-duet-editable-table .duet-text-right.sc-duet-editable-table{text-align:right}.duet-editable-table-header.sc-duet-editable-table tr.sc-duet-editable-table .duet-editable-table-header-hidden.sc-duet-editable-table{padding:0 !important;font-size:0;border-bottom:0}";
5338
5251
 
5339
- let DuetEditableTableItem$1 = class extends H {
5252
+ let DuetEditableTable$1 = class extends H {
5340
5253
  constructor() {
5341
5254
  super();
5342
5255
  this.__registerHost();
5343
- this.__attachShadow();
5344
- this.duetEditableItemAction = createEvent$2(this, "duetEditableItemAction", 7);
5345
- this.isHovering = false;
5256
+ this.duetTableToggle = createEvent$2(this, "duetTableToggle", 7);
5257
+ this.duetMenuClick = createEvent$2(this, "duetMenuClick", 7);
5346
5258
  /**
5347
- * Theme of the empty state component.
5259
+ * Duet-table: margin of the component.
5348
5260
  */
5349
- this.theme = "";
5261
+ this.margin = "auto";
5262
+ /**
5263
+ * Duet-table: Style variation of the table.
5264
+ */
5265
+ this.variation = "striped";
5266
+ /**
5267
+ * Duet-table: Controls whether the table has a sticky header.
5268
+ * Sticky headers are not compatible with breakpoint="none-scrollable".
5269
+ */
5270
+ this.sticky = false;
5271
+ /**
5272
+ * Duet-table: Adjust the distance from top of the viewport (in pixels) when the
5273
+ * table header becomes sticky.
5274
+ */
5275
+ this.stickyDistance = "with-links";
5350
5276
  /**
5351
- * Actions that can be performed on the element
5277
+ * Duet-table: By default the table is responsive - it will be flattened at narrow viewport widths.
5278
+ * This prop controls the breakpoint at which the table should be rendered as a _regular_ table.
5279
+ * Set to "none" to disable the responsive functionality.
5280
+ * Set to "none-scrollable" to disable responsive functionality _and_ allow horizontal scrolling -
5281
+ * this is useful for comparison tables where it's important to maintain column and row layout.
5282
+ */
5283
+ this.breakpoint = "small";
5284
+ /**
5285
+ * Define actions for all items in a table
5286
+ * An alternative to inline HTML table.
5287
+ * required for Sortable tables
5288
+ * @default undefined
5352
5289
  */
5353
5290
  this.actions = undefined;
5354
5291
  /**
5355
- * GroupId used to pierce the shadowdom - gets concatenated with "content & actions" and used as part="groupIDcontent/actions" to pierce the content/Action item
5356
- * @internal
5292
+ * Define columns for a table
5293
+ * An alternative to inline HTML table.
5294
+ * required for Sortable tables
5295
+ * @default undefined
5296
+ */
5297
+ this.columns = undefined;
5298
+ /**
5299
+ * Define rows for a table
5300
+ * An alternative to inline HTML table.
5301
+ * required for Sortable tables
5302
+ * @default undefined
5303
+ */
5304
+ this.rows = undefined;
5305
+ /**
5306
+ * Controls whether the table is sortable by headers
5307
+ */
5308
+ this.sortable = false;
5309
+ /**
5310
+ * Optional id that get passed to the table and used to setup ::parts
5357
5311
  */
5358
5312
  this.groupId = "";
5359
5313
  /**
5360
- * Key used to set vertical alignment of action buttons
5314
+ * Theme of the table.
5361
5315
  */
5362
- this.alignment = "middle";
5316
+ this.theme = "";
5363
5317
  /**
5364
- * Key used to identify item, when running actions
5318
+ * Exposes the aria role for optimizing accessibility.
5365
5319
  */
5366
- this.keyName = "";
5320
+ this.accessibleRole = undefined;
5321
+ this.sortableDefaultLabel = {
5322
+ fi: "Järjestä",
5323
+ en: "Click to sort",
5324
+ sv: "Klicka för att sortera",
5325
+ };
5326
+ this.actionColumnLabel = {
5327
+ en: "Actions for rows",
5328
+ fi: "Toiminnot rivillä",
5329
+ sv: "Åtgärder för rader",
5330
+ };
5367
5331
  /**
5368
- * Object of data itemsused to render the entire row
5332
+ * Private methods.
5369
5333
  */
5370
- this.data = undefined;
5371
- }
5372
- watchPropHandler(_newValue, _oldValue) {
5373
- // console.log("The new value of activated is: ", _newValue)
5334
+ this.toggleColumn = (column, e) => {
5335
+ e.preventDefault();
5336
+ const { sort_order, direction, index, key } = column;
5337
+ this.duetTableToggle.emit({
5338
+ sort_order,
5339
+ index,
5340
+ direction,
5341
+ key,
5342
+ component: "duet-editable-table",
5343
+ originalEvent: e,
5344
+ });
5345
+ };
5346
+ this.handleKeyDown = (column, e) => {
5347
+ if (isKeyboardClick(e)) {
5348
+ this.toggleColumn(column, e);
5349
+ }
5350
+ };
5374
5351
  }
5375
5352
  /**
5376
- /**
5377
5353
  * Component lifecycle events.
5378
5354
  */
5379
5355
  componentWillLoad() {
5380
5356
  inheritGlobalTheme(this);
5381
5357
  }
5358
+ createLabel(column) {
5359
+ const { sort_order, direction, index, label } = column;
5360
+ const i18nLabel = getLocaleString(label);
5361
+ if (!this.sortable) {
5362
+ return i18nLabel;
5363
+ }
5364
+ const getButtonIcon = () => {
5365
+ // "action-subtract-small" https://cdn.duetds.com/api/icons/2.2.12/lib/assets/action-subtract-small.svg
5366
+ // "action-arrow-down-small" https://cdn.duetds.com/api/icons/2.2.12/lib/assets/action-arrow-down-small.svg
5367
+ // "action-arrow-up-small" https://cdn.duetds.com/api/icons/2.2.12/lib/assets/action-arrow-up-small.svg
5368
+ if (!!sort_order && direction === 1) {
5369
+ return "action-arrow-down-small";
5370
+ }
5371
+ else if (!!sort_order && direction === -1) {
5372
+ return "action-arrow-up-small";
5373
+ }
5374
+ return "action-subtract-small";
5375
+ };
5376
+ return (h$1("span", { class: "duet-table-label", "data-index": index }, h$1("duet-button", { size: "small", icon: getButtonIcon(), "icon-size": "medium-small", "accessible-label": getLocaleString(this.sortableDefaultLabel), variation: "plain", margin: "none", "icon-right": true, onClick: event => this.toggleColumn(column, event), onKeyDown: event => this.handleKeyDown(column, event) }, i18nLabel)));
5377
+ }
5378
+ getSortedColumns() {
5379
+ //create a new array from sort instead of mutating original
5380
+ return [...this.columns].sort(fieldSorter(["index"]));
5381
+ }
5382
+ getRowSortOrder() {
5383
+ //create a new array from sort instead of mutating original
5384
+ const fields = [...this.columns].sort(fieldSorter(["sort_order"]));
5385
+ //return only key from objects that have sort_order
5386
+ return fields
5387
+ .filter(column => column.sort_order)
5388
+ .map(column => {
5389
+ // add - in-front of descending direction (required by field-sorter)
5390
+ return column.direction === -1 ? `-${column.key}` : column.key;
5391
+ });
5392
+ }
5393
+ renderTableHeader() {
5394
+ if (!this.columns) {
5395
+ return;
5396
+ }
5397
+ const sortedColumns = this.getSortedColumns();
5398
+ return (h$1("tr", { class: {
5399
+ "duet-table-action-header": !!this.actions,
5400
+ } }, sortedColumns.map(column => {
5401
+ if (column.display !== false) {
5402
+ return h$1("th", { scope: "col" }, this.createLabel(column));
5403
+ }
5404
+ }), this.actions && (h$1("th", { scope: "col", class: "duet-table-action-header-heading" }, this.actions && h$1("duet-visually-hidden", null, getLocaleString(this.actionColumnLabel))))));
5405
+ }
5406
+ renderActions(rowItem, index) {
5407
+ // escape early
5408
+ if (!this.actions) {
5409
+ return;
5410
+ }
5411
+ // iterate through actions and add them in the sidebar
5412
+ return (h$1("td", { class: "duet-text-right" }, this.actions.map(actionItem => {
5413
+ return (h$1("duet-action-button", { actionMeta: Object.assign({}, (rowItem === null || rowItem === void 0 ? void 0 : rowItem.meta) || {}, { index }), actionId: (rowItem === null || rowItem === void 0 ? void 0 : rowItem.uid) || (rowItem === null || rowItem === void 0 ? void 0 : rowItem.id) || null, actionName: actionItem.name, theme: this.theme, iconName: actionItem.icon, iconColor: actionItem.color, iconSize: actionItem.size, background: actionItem.background }));
5414
+ })));
5415
+ }
5416
+ renderTableBody() {
5417
+ const columns = this.getSortedColumns();
5418
+ const rowSortOrder = this.getRowSortOrder();
5419
+ const sortedRows = [...this.rows].sort(fieldSorter(rowSortOrder));
5420
+ // return a tbody with rows for each item in sortedRows
5421
+ return sortedRows.map((row, index) => (h$1("tr", { class: {
5422
+ "duet-table-action-row": !!this.actions,
5423
+ "duet-editable-table-row": true,
5424
+ [`duet-editable-table-row-${this.groupId}`]: true,
5425
+ }, "data-meta": JSON.stringify(row.meta) }, columns.map(column => {
5426
+ //if we don't have any data for this column, try getting an item instead (for backwards compatibility
5427
+ const value = row[column.key] ? row[column.key] : row.item;
5428
+ if (column.display !== false) {
5429
+ return h$1(TableData, { data: value, groupId: this.groupId });
5430
+ }
5431
+ }), this.actions && this.renderActions(row, index))));
5432
+ }
5382
5433
  /**
5383
- /**
5384
- * private functions
5385
- */
5386
- /**
5387
- * render() function
5388
- * Always the last one in the class.
5434
+ * Render Methods
5389
5435
  */
5390
5436
  render() {
5391
- return (h$1(Host, { role: "row" }, h$1(TableData, { data: this.data.item, alignment: this.alignment, groupId: this.groupId }), h$1("td", { class: "duet-editable-table-actions", style: { verticalAlign: this.alignment } }, h$1("div", { class: "duet-editable-table-actions-items", part: `${this.groupId}actions` }, this.actions.map(result => {
5392
- const { map = undefined } = result;
5393
- // if map has been specified, only show the current action if groupID matches the map array
5394
- if (map && !map.includes(this.groupId)) {
5395
- return;
5396
- }
5397
- return (h$1("duet-editable-table-button", { keyName: this.keyName, group: this.data.group, uid: this.data.uid, actions: result, theme: this.theme }));
5398
- })))));
5437
+ return (h$1(Host, { class: {
5438
+ [`duet-editable-table-${this.variation}`]: true,
5439
+ [`duet-editable-table-${this.theme}`]: true,
5440
+ // sticky only valid when in regular table layout
5441
+ "duet-editable-table-scrollable": this.breakpoint === "none-scrollable",
5442
+ "duet-editable-table-sortable": this.sortable,
5443
+ "duet-editable-table-actions": !!this.actions,
5444
+ "duet-m-0": this.margin === "none",
5445
+ "duet-theme-turva": this.theme === "turva",
5446
+ } }, h$1("duet-table", { sticky: this.sticky, stickyDistance: this.stickyDistance, margin: this.margin, theme: this.theme, variation: this.variation, breakpoint: this.breakpoint }, h$1("table", { role: this.accessibleRole }, h$1("caption", null, h$1("slot", { name: "tcaption" })), h$1("thead", null, h$1("tr", null, h$1("td", { class: "duet-editable-table-actions-menu", colSpan: 99 }, h$1("slot", { name: "thead-first" }))), this.renderTableHeader(), h$1("tr", null, h$1("td", { class: "duet-editable-table-actions-menu", colSpan: 99 }, h$1("slot", { name: "thead-last" })))), h$1("tbody", null, this.renderTableBody()), h$1("tfoot", null, h$1("tr", null, h$1("th", { class: "duet-editable-table-footer-menu", colSpan: 99 }, h$1("slot", { name: "tfoot" }))))))));
5399
5447
  }
5400
- get el() { return this; }
5401
- static get watchers() { return {
5402
- "data": ["watchPropHandler"]
5403
- }; }
5404
- static get style() { return duetEditableTableItemCss; }
5448
+ get element() { return this; }
5449
+ static get style() { return duetEditableTableCss; }
5405
5450
  };
5406
5451
 
5407
5452
  const duetEmptyStateCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:block;width:100%;height:100%}.duet-empty-state{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;width:100%;height:100%;padding:48px;color:#00294d;text-align:center;background:#f5f8fa;border-radius:4px}.duet-empty-state.duet-theme-turva{color:#171c3a;background:#f5f5f7}";
@@ -8578,6 +8623,295 @@ let DuetNumberInput$1 = class extends H {
8578
8623
  static get style() { return duetNumberInputCss; }
8579
8624
  };
8580
8625
 
8626
+ const shouldDisplayNavigation = (visibleItems, total, take) => {
8627
+ if (visibleItems * 2 > total / take) {
8628
+ return false;
8629
+ }
8630
+ return true;
8631
+ };
8632
+
8633
+ const duetPaginationCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:inline-block;margin:0 auto}.duet-pagination-nav{position:relative}.duet-pagination ::part(button){border:0}.duet-pagination,.duet-pagination li{display:flex;flex-wrap:wrap;gap:0.1rem;align-items:center}.duet-pagination-item-is-active .duet-pagination-page-number{border-bottom-color:inherit;border-bottom-style:solid;border-bottom-width:2px}.duet-pagination duet-button{width:30px;min-width:36px;font-weight:600;text-decoration:none;border-left-width:0}.duet-pagination-overlay{position:absolute;top:1rem;z-index:300;width:100%;text-align:center}.duet-pagination.duet-pagination-is-dimmed{opacity:0.5}";
8634
+
8635
+ let DuetPagination$1 = class extends H {
8636
+ constructor() {
8637
+ super();
8638
+ this.__registerHost();
8639
+ this.__attachShadow();
8640
+ this.duetPageChange = createEvent$2(this, "duetPageChange", 3);
8641
+ this.listId = createID("duet-pagination-list");
8642
+ this.numbersStore = "";
8643
+ /**
8644
+ * State() variables
8645
+ * @internal
8646
+ */
8647
+ this.totalPages = 10;
8648
+ /**
8649
+ * State() variables
8650
+ * @internal
8651
+ */
8652
+ this.internalSectionIndex = 0;
8653
+ /**
8654
+ * Theme of the pagination.
8655
+ */
8656
+ this.theme = "";
8657
+ /**
8658
+ * Characters to use for the jump buttons.
8659
+ */
8660
+ this.jumpString = "...";
8661
+ /**
8662
+ * Variation of the paginator (compact and default supported)
8663
+ */
8664
+ this.variation = "default";
8665
+ /**
8666
+ * Default pagination labels
8667
+ */
8668
+ this.accessibleLabelsDefaults = {
8669
+ en: {
8670
+ next_page: "Next page",
8671
+ previous_page: "Previous page",
8672
+ first_page: "First page",
8673
+ last_page: "Last page",
8674
+ jump_to: "Jump to page",
8675
+ go_to: "Go to page",
8676
+ description: "You may use arrow keys to select page number, or enter a page number when this element is in focus to jump to a page",
8677
+ pagination_label: "Pagination, choose a number to jump to a page",
8678
+ prev_section: "Show previous {0} page numbers, screen reader user should use arrowkeys to navigate",
8679
+ next_section: "Show next {0} page numbers, screen reader user should use arrowkeys to navigate",
8680
+ },
8681
+ fi: {
8682
+ next_page: "Seuraava sivu",
8683
+ previous_page: "Edellinen sivu",
8684
+ first_page: "Ensimmäinen sivu",
8685
+ last_page: "Viimeinen sivu",
8686
+ jump_to: "Siirry sivulle",
8687
+ go_to: "Siirry sivulle",
8688
+ description: "Voit käyttää nuolinäppäimiä sivunumeron valitsemiseen, tai kirjoittaa sivunumeron, jos tämä elementti on aktiivinen, siirtymään sivulle",
8689
+ pagination_label: "Sivutus, valitse sivunumero siirtyäksesi sivulle",
8690
+ prev_section: "Näytä edelliset {0} sivunumerot, käyttäjän pitää käyttää nuolinäppäimiä navigoidaksesi",
8691
+ next_section: "Näytä seuraavat {0} sivunumerot, käyttäjän pitää käyttää nuolinäppäimiä navigoidaksesi",
8692
+ },
8693
+ sv: {
8694
+ next_page: "Nästa sida",
8695
+ previous_page: "Föregående sida",
8696
+ first_page: "Första sidan",
8697
+ last_page: "Sista sidan",
8698
+ jump_to: "Hoppa till sida",
8699
+ go_to: "Hoppa till sida",
8700
+ description: "Du kan använda piltangenterna för att välja sida, eller skriva in sida när elementet är i fokus för att hoppa till en sida",
8701
+ pagination_label: "Sidutning, välj en siffra för att hoppa till en sida",
8702
+ prev_section: "Visa föregående {0} sidnummer, skrivbordsläsare ska använda piltangenterna för att navigera",
8703
+ next_section: "Visa nästa {0} sidnummer, skrivbordsläsare ska använda piltangenterna för att navigera",
8704
+ },
8705
+ };
8706
+ /**
8707
+ * Default pagination labels
8708
+ */
8709
+ this.accessibleLabels = getLocaleString(this.accessibleLabelsDefaults);
8710
+ /**
8711
+ * The size of the take, when paginating.
8712
+ */
8713
+ this.take = 5;
8714
+ /**
8715
+ * Amount of visible page numbers to show
8716
+ */
8717
+ this.visibleItems = 5;
8718
+ /**
8719
+ * The total size of the paginating data
8720
+ */
8721
+ this.total = 1000;
8722
+ /**
8723
+ * Used to indicate which dom element with ID this element controls
8724
+ */
8725
+ this.ariaControls = "";
8726
+ /**
8727
+ * The current page
8728
+ */
8729
+ this.current = 1;
8730
+ /**
8731
+ * Private methods.
8732
+ */
8733
+ // called from the watcher and used to make sure any changed to current also updates the internal section index
8734
+ this.actionChain = async (after, before) => {
8735
+ if (after === 0) {
8736
+ this.current = 1;
8737
+ }
8738
+ else if (before !== after) {
8739
+ const calculatedSectionIndex = Math.ceil(after / this.visibleItems) - 1;
8740
+ if (calculatedSectionIndex !== this.internalSectionIndex) {
8741
+ this.internalSectionIndex = calculatedSectionIndex;
8742
+ await this.setFocus();
8743
+ }
8744
+ }
8745
+ };
8746
+ //helper to emit relevant page events
8747
+ this.emitPageEvent = debounce((ev, passedPage) => {
8748
+ const page = Number(passedPage || this.current);
8749
+ this.duetPageChange.emit({
8750
+ component: "duet-pagination",
8751
+ from: page * this.take,
8752
+ to: page * this.take + this.take,
8753
+ current: page,
8754
+ take: this.take,
8755
+ type: "page",
8756
+ originalEvent: ev,
8757
+ });
8758
+ }, 500);
8759
+ // this will return the entered number, or the current page if the user presses enter
8760
+ this.getEnteredNumber = debounce(ev => {
8761
+ this.emitPageEvent(ev, this.numbersStore);
8762
+ this.current = Number(this.numbersStore);
8763
+ this.numbersStore = "";
8764
+ this.duetPageChange.emit({
8765
+ component: "duet-pagination",
8766
+ from: this.current * this.take,
8767
+ to: this.current * this.take + this.take,
8768
+ current: this.current,
8769
+ take: this.take,
8770
+ type: "jump",
8771
+ originalEvent: ev,
8772
+ });
8773
+ }, 500);
8774
+ }
8775
+ watchStateHandler(newValue, oldValue) {
8776
+ this.actionChain(newValue, oldValue);
8777
+ }
8778
+ /**
8779
+ * Component lifecycle events.
8780
+ */
8781
+ componentWillLoad() {
8782
+ // we want to keep the internal current index in sync with the current prop, but take advantage of the multiple with 0 for the first iteration
8783
+ this.internalSectionIndex = Math.ceil(this.current / this.visibleItems) - 1;
8784
+ this.calculatePageTake();
8785
+ inheritGlobalTheme(this);
8786
+ }
8787
+ componentWillRender() {
8788
+ if (this.internalSectionIndex !== 0 && this.internalSectionIndex !== this.totalPages) {
8789
+ this.calculatePageTake();
8790
+ }
8791
+ }
8792
+ componentDidRender() {
8793
+ this.setFocus();
8794
+ }
8795
+ //get totalpages from visible and total
8796
+ calculatePageTake() {
8797
+ this.totalPages = Math.ceil(this.total / this.take);
8798
+ }
8799
+ //set update current when mouse click on page number
8800
+ async onMouseHandler(e, dir) {
8801
+ e.preventDefault();
8802
+ e.stopPropagation();
8803
+ this.current = this.current + dir;
8804
+ }
8805
+ //handle a11y keyboard navigation events
8806
+ async onKeyboardDown(e) {
8807
+ let next = this.current;
8808
+ // handle a11y based keyboard navigation for left/right/up/down
8809
+ if (isArrowLeftKey(e) || isArrowUpKey(e)) {
8810
+ next--;
8811
+ }
8812
+ if (isArrowRightKey(e) || isArrowDownKey(e)) {
8813
+ next++;
8814
+ }
8815
+ if (isArrowKey(e)) {
8816
+ if (next <= this.totalPages) {
8817
+ this.current = next;
8818
+ this.emitPageEvent(e);
8819
+ }
8820
+ }
8821
+ //handle the jump feature, where numbers can be entered
8822
+ if (isNumber(e) && this.shouldDisplayNavigation()) {
8823
+ this.numbersStore = this.numbersStore + e.key;
8824
+ if (Number(this.numbersStore) > this.totalPages) {
8825
+ this.numbersStore = this.totalPages + "";
8826
+ }
8827
+ this.getEnteredNumber(e);
8828
+ }
8829
+ }
8830
+ // utility to set focus on active button
8831
+ async setFocus() {
8832
+ const currentDomElement = this.nativeNav.querySelector(`li.duet-pagination-item-is-active duet-button`);
8833
+ currentDomElement && (await currentDomElement.setFocus());
8834
+ }
8835
+ //handles click on page numbers
8836
+ pageClickHandler(e) {
8837
+ e.preventDefault();
8838
+ const clickedId = Number(e.target.getAttribute("data-id"));
8839
+ this.current = clickedId;
8840
+ this.emitPageEvent({}, clickedId);
8841
+ }
8842
+ //handles click on the next section buttons
8843
+ sectionClickHandler(e, direction) {
8844
+ e.preventDefault();
8845
+ let next = this.internalSectionIndex + direction;
8846
+ if (next >= this.totalPages / this.take) {
8847
+ next = this.totalPages / this.take - 1;
8848
+ }
8849
+ const newSection = next;
8850
+ this.internalSectionIndex = newSection >= 0 ? newSection : 0;
8851
+ }
8852
+ //handles click on the jump (1)button
8853
+ jumpToStart(e) {
8854
+ e.preventDefault();
8855
+ this.internalSectionIndex = 0;
8856
+ this.current = 1;
8857
+ }
8858
+ //handles click on the jump (total) button
8859
+ jumpToEnd(e) {
8860
+ e.preventDefault();
8861
+ this.internalSectionIndex = this.totalPages / this.take - 1;
8862
+ this.current = this.totalPages;
8863
+ }
8864
+ // render the individual page numbers
8865
+ renderPageNumbers() {
8866
+ const items = [];
8867
+ let i = this.internalSectionIndex * this.visibleItems;
8868
+ do {
8869
+ i++;
8870
+ if (i > this.totalPages) {
8871
+ break;
8872
+ }
8873
+ items.push(h$1("li", { class: {
8874
+ "duet-pagination-item": true,
8875
+ "duet-pagination-item-is-active": i === this.current,
8876
+ }, role: "menuitem" }, h$1("duet-button", { class: {
8877
+ "duet-pagination-link": true,
8878
+ }, color: i !== this.current ? "secondary" : "primary", "data-id": i, "center-text": true, variation: "plain", margin: "none", accessibleLabel: `${this.accessibleLabels.go_to} ${i}`, onClick: e => this.pageClickHandler(e) }, h$1("div", { class: "duet-pagination-page-number", "aria-hidden": true }, i))));
8879
+ } while (i < this.visibleItems + this.internalSectionIndex * this.visibleItems);
8880
+ return items;
8881
+ }
8882
+ shouldDisplayNavigation() {
8883
+ if (this.variation !== "compact") {
8884
+ return shouldDisplayNavigation(this.visibleItems, this.total, this.take);
8885
+ }
8886
+ return false;
8887
+ }
8888
+ /**
8889
+ * render() function
8890
+ * Always the last one in the class.
8891
+ */
8892
+ render() {
8893
+ return (h$1(Host, { onKeyDown: e => this.onKeyboardDown(e) }, h$1("nav", { role: "navigation", "aria-labelledby": this.listId, "aria-describedby": this.listId, ref: el => (this.nativeNav = el), "aria-controls": this.ariaControls, class: {
8894
+ "duet-pagination-nav": true,
8895
+ [`duet-pagination-variation-${this.variation}`]: true,
8896
+ } }, this.numbersStore !== "" && (h$1("div", { "aria-live": "assertive", "aria-relevant": "text", class: "duet-pagination-overlay", "aria-label": `${this.accessibleLabels.jump_to} ${this.numbersStore}`, part: "navigation-overlay" }, h$1("duet-badge", null, "jump to page : ", this.numbersStore))), h$1("ol", { id: this.listId, class: {
8897
+ "duet-pagination": true,
8898
+ "duet-pagination-is-dimmed": this.numbersStore !== "",
8899
+ }, role: "menubar", "aria-label": this.accessibleLabels.pagination_label, "aria-description": this.accessibleLabels.description }, h$1("li", { class: {
8900
+ "duet-pagination-page-button": true,
8901
+ "duet-pagination-button-first": true,
8902
+ }, role: "menuitem", part: "navigation-arrow" }, h$1("duet-action-button", { disabled: this.internalSectionIndex === 0 && this.current <= 1, "data-direction": "back", onClick: e => this.onMouseHandler(e, -1), "aria-label": this.accessibleLabels.previous_page, "icon-name": "action-arrow-left-small" })), this.internalSectionIndex !== 0 && this.shouldDisplayNavigation() && (h$1(Fragment, null, h$1("li", { class: "duet-pagination-item", role: "menuitem", part: "navigation-jump" }, h$1("duet-button", { class: "duet-pagination-link", "center-text": "true", variation: "plain", color: "secondary", margin: "none", accessibleLabel: this.accessibleLabels.first_page, onClick: e => this.jumpToStart(e) }, h$1("div", { class: "duet-pagination-page-number" }, "1"))), h$1("li", { class: "duet-pagination-item", role: "menuitem", part: "navigation-section" }, h$1("duet-button", { class: "duet-pagination-link", "center-text": "true", color: "secondary", variation: "plain", margin: "none", accessibleLabel: this.accessibleLabels.prev_section.replace("{0}", `${this.visibleItems}`), onClick: e => this.sectionClickHandler(e, -1) }, h$1("div", { class: "duet-pagination-page-number", "aria-hidden": "true" }, "..."))))), this.renderPageNumbers(), this.internalSectionIndex !== this.totalPages / this.visibleItems - 1 && this.shouldDisplayNavigation() && (h$1(Fragment, null, h$1("li", { class: "duet-pagination-item", role: "menuitem", part: "navigation-section" }, h$1("duet-button", { class: "duet-pagination-link", "center-text": "true", color: "secondary", variation: "plain", margin: "none", accessibleLabel: this.accessibleLabels.next_section.replace("{0}", `${this.visibleItems}`), onClick: e => this.sectionClickHandler(e, 1) }, h$1("div", { class: "duet-pagination-page-number", "aria-hidden": "true" }, "..."))), h$1("li", { class: "duet-pagination-item", role: "menuitem", part: "navigation-jump" }, h$1("duet-button", { class: "duet-pagination-link", "center-text": "true", color: "secondary", variation: "plain", margin: "none", accessibleLabel: this.accessibleLabels.last_page, onClick: e => this.jumpToEnd(e) }, h$1("div", { class: "duet-pagination-page-number" }, this.totalPages))))), h$1("li", { class: {
8903
+ "duet-pagination-page-button": true,
8904
+ "duet-pagination-button-last": true,
8905
+ }, role: "menuitem", part: "navigation-arrow" }, h$1("duet-action-button", { disabled: this.current === this.totalPages &&
8906
+ this.internalSectionIndex === Math.ceil(this.totalPages / this.visibleItems) - 1, class: "duet-date-dialog-next", "aria-label": this.accessibleLabels.next_page, onClick: e => this.onMouseHandler(e, 1), "icon-name": "action-arrow-right-small" }))))));
8907
+ }
8908
+ get element() { return this; }
8909
+ static get watchers() { return {
8910
+ "current": ["watchStateHandler"]
8911
+ }; }
8912
+ static get style() { return duetPaginationCss; }
8913
+ };
8914
+
8581
8915
  const duetParagraphCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;position:relative;display:block;width:100%}.duet-paragraph{margin-bottom:16px !important;display:block;width:100%;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;font-style:normal;font-weight:400;font-variant-numeric:tabular-nums;-webkit-hyphens:auto;hyphens:auto;line-height:1.5;color:#00294d}.duet-paragraph.duet-p-0{padding:0 !important}.duet-paragraph.duet-m-0{margin:0 !important}.duet-paragraph.duet-theme-turva{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#171c3a}.duet-paragraph.duet-paragraph-small{font-size:0.875rem}.duet-paragraph.duet-paragraph-semi-bold{font-weight:600}.duet-paragraph.duet-paragraph-bold{font-weight:700}.duet-paragraph.duet-m-0{margin:0 !important}.duet-paragraph.intro{font-size:2.7vw;margin-bottom:28px !important;-webkit-hyphens:inherit;hyphens:inherit}@media (max-width: 37.037037037rem){.duet-paragraph.intro{font-size:1rem}}@media (min-width: 46.2962962963rem){.duet-paragraph.intro{font-size:1.25rem}}.duet-paragraph.intro.duet-m-0{margin:0 !important}::slotted(a){font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-style:normal;font-weight:400;color:#0077b3;text-decoration:underline;transition:300ms ease}::slotted(a).duet-theme-turva{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#c60c30}::slotted(a):hover{color:#004d80;text-decoration:none}::slotted(a):hover.duet-theme-turva{color:#940925}::slotted(a):active{opacity:0.75;transition:none}";
8582
8916
 
8583
8917
  let DuetParagraph$1 = class extends H {
@@ -9072,41 +9406,197 @@ let DuetRangeSlider$1 = class extends H {
9072
9406
  componentWillLoad() {
9073
9407
  inheritGlobalTheme(this);
9074
9408
  }
9075
- /**
9076
- * Sets focus on the specified `duet-range-slider`. Use this method instead of the global
9077
- * `input.focus()`.
9078
- */
9079
- async setFocus(options) {
9080
- this.nativeInput.focus(options);
9409
+ /**
9410
+ * Sets focus on the specified `duet-range-slider`. Use this method instead of the global
9411
+ * `input.focus()`.
9412
+ */
9413
+ async setFocus(options) {
9414
+ this.nativeInput.focus(options);
9415
+ }
9416
+ /**
9417
+ * Local methods.
9418
+ */
9419
+ calculatePercentage() {
9420
+ return ((this.value - this.min) / (this.max - this.min)) * 100;
9421
+ }
9422
+ /**
9423
+ * render() function
9424
+ * Always the last one in the class.
9425
+ */
9426
+ render() {
9427
+ const identifier = this.identifier || this.rangeId;
9428
+ const theme = this.theme === "turva" ? "turva" : "default";
9429
+ const { inactive, active } = colors[theme];
9430
+ const percentage = this.calculatePercentage();
9431
+ const rangeStyles = {
9432
+ background: `-webkit-linear-gradient(left,${active} 0%,${active} ${percentage}%,${inactive} ${percentage}%)`,
9433
+ };
9434
+ return (h$1(Host, { class: { "duet-m-0": this.margin === "none", "duet-expand": this.expand } }, h$1("div", { class: {
9435
+ "duet-range-container": true,
9436
+ "duet-label-hidden": this.labelHidden,
9437
+ "duet-theme-turva": this.theme === "turva",
9438
+ "duet-ie": isInternetExplorer(),
9439
+ "duet-range-disabled": this.disabled,
9440
+ } }, h$1("duet-label", { theme: theme, margin: "small", for: identifier }, this.label), h$1("output", { "aria-hidden": "true", htmlFor: identifier, class: "duet-output" }, this.value.toLocaleString(this.locale), this.unit), h$1("input", { onInput: this.onInput, onChange: this.onChange, ref: input => (this.nativeInput = input), type: "range", min: this.min, max: this.max, step: this.step, value: this.value, style: rangeStyles, "aria-valuemin": this.min, "aria-valuemax": this.max, "aria-valuenow": this.value, "aria-valuetext": `${this.value} ${this.unit}`, "aria-controls": this.accessibleControls, "aria-activedescendant": this.accessibleActiveDescendant, "aria-owns": this.accessibleOwns, "aria-describedby": this.accessibleDescribedBy, id: identifier, name: this.name, disabled: this.disabled, required: this.required, class: "duet-range" }))));
9441
+ }
9442
+ get element() { return this; }
9443
+ static get style() { return duetRangeSliderCss; }
9444
+ };
9445
+
9446
+ const duetRangeStepperCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;display:inline-block;margin:0 auto}.duet-range-stepper{display:flex;flex-wrap:wrap;gap:0;align-items:baseline;justify-content:center;min-width:30px;min-height:30px;font-weight:600;text-decoration:none;border-left-width:0}.duet-range-stepper{white-space:nowrap}.duet-range-stepper .duet-range-step-counter{font-weight:600;color:#00294d}.duet-range-stepper ::part(button){border:0}";
9447
+
9448
+ let DuetRangeStepper$1 = class extends H {
9449
+ constructor() {
9450
+ super();
9451
+ this.__registerHost();
9452
+ this.__attachShadow();
9453
+ this.duetRangeStepUpdate = createEvent$2(this, "duetRangeStepUpdate", 7);
9454
+ this.leftBn = createID("duetRangeStepper-left");
9455
+ this.rightBn = createID("duetRangeStepper-right");
9456
+ /**
9457
+ * Theme of the component.
9458
+ */
9459
+ this.theme = "";
9460
+ /**
9461
+ * Start value
9462
+ * @default 1
9463
+ */
9464
+ this.stepIndex = 1;
9465
+ /**
9466
+ * How big is the step
9467
+ * @default 99
9468
+ */
9469
+ this.stepSize = 50;
9470
+ /**
9471
+ * Total of
9472
+ * @default undefined
9473
+ */
9474
+ this.total = 1000;
9475
+ /**
9476
+ * Default range stepper labels
9477
+ */
9478
+ this.ariaLabelsDefaults = {
9479
+ en: {
9480
+ next_increment: "Next range increment",
9481
+ previous_increment: "Previous range increment",
9482
+ x_of_y: "{0}–{1} of {2}",
9483
+ },
9484
+ fi: {
9485
+ next_increment: "Seuraava välillä",
9486
+ previous_increment: "Edellinen välillä",
9487
+ x_of_y: "{0}–{1} / {2}",
9488
+ },
9489
+ sv: {
9490
+ next_increment: "Nästa intervall",
9491
+ previous_increment: "Föregående intervall",
9492
+ x_of_y: "{0}–{1} av {2}",
9493
+ },
9494
+ };
9495
+ /**
9496
+ * Default pagination labels
9497
+ */
9498
+ this.ariaLabels = getLocaleString(this.ariaLabelsDefaults);
9499
+ /**
9500
+ * Used to indicate which dom element with ID this element controls
9501
+ */
9502
+ this.ariaControls = "";
9503
+ this.handleClick = (e, direction) => {
9504
+ e.preventDefault();
9505
+ this.increment(direction);
9506
+ this.handleStepClick(e);
9507
+ };
9508
+ }
9509
+ watchStateHandler(newValue) {
9510
+ if (newValue === 1) {
9511
+ this.leftBnRef.setAttribute("disabled", "");
9512
+ this.rightBnRef.focus();
9513
+ }
9514
+ else {
9515
+ this.leftBnRef.removeAttribute("disabled");
9516
+ }
9517
+ if (newValue === this.total / this.stepSize) {
9518
+ this.rightBnRef.setAttribute("disabled", "");
9519
+ this.leftBnRef.focus();
9520
+ }
9521
+ else {
9522
+ this.rightBnRef.removeAttribute("disabled");
9523
+ }
9524
+ }
9525
+ handleStepClick(e) {
9526
+ this.duetRangeStepUpdate.emit({
9527
+ originalEvent: e,
9528
+ component: "duet-range-stepper",
9529
+ from: this.stepIndex * this.stepSize - this.stepSize,
9530
+ to: this.stepIndex * this.stepSize,
9531
+ index: this.stepIndex,
9532
+ });
9533
+ }
9534
+ componentWillLoad() {
9535
+ inheritGlobalTheme(this);
9536
+ }
9537
+ componentDidLoad() {
9538
+ this.watchStateHandler(this.stepIndex);
9081
9539
  }
9082
- /**
9083
- * Local methods.
9084
- */
9085
- calculatePercentage() {
9086
- return ((this.value - this.min) / (this.max - this.min)) * 100;
9540
+ increment(direction) {
9541
+ const newIndex = this.stepIndex + direction;
9542
+ if (newIndex <= 0) {
9543
+ this.stepIndex = 1;
9544
+ }
9545
+ else {
9546
+ if (newIndex * this.stepSize <= this.total) {
9547
+ this.stepIndex = newIndex;
9548
+ }
9549
+ }
9550
+ }
9551
+ generateStepSize() {
9552
+ // this function uses this.stepIndex and this.range to generate a range of number like 1-100
9553
+ // this is used to generate the step size
9554
+ let start = (this.stepIndex - 1) * this.stepSize;
9555
+ //easy fix for starting position
9556
+ if (start === 0) {
9557
+ start = 1;
9558
+ }
9559
+ const end = this.stepIndex * this.stepSize;
9560
+ return this.ariaLabels.x_of_y
9561
+ .replace("{0}", String(start))
9562
+ .replace("{1}", String(end))
9563
+ .replace("{2}", String(this.total));
9564
+ }
9565
+ //handle a11y keyboard navigation events
9566
+ async onKeyboardDown(e) {
9567
+ // handle a11y based keyboard navigation for left/right/up/down
9568
+ let next = this.stepIndex;
9569
+ let dir = 1;
9570
+ if (isArrowLeftKey(e) || isArrowUpKey(e) || isMinusKey(e)) {
9571
+ next--;
9572
+ dir = -1;
9573
+ this.leftBnRef.focus();
9574
+ }
9575
+ if (isArrowRightKey(e) || isArrowDownKey(e) || isPlusKey(e)) {
9576
+ next++;
9577
+ dir = 1;
9578
+ }
9579
+ if (isArrowKey(e)) {
9580
+ if (next > 0 && next * this.stepSize <= this.total) {
9581
+ this.handleClick(e, dir);
9582
+ }
9583
+ }
9087
9584
  }
9088
9585
  /**
9089
9586
  * render() function
9090
9587
  * Always the last one in the class.
9091
9588
  */
9092
9589
  render() {
9093
- const identifier = this.identifier || this.rangeId;
9094
- const theme = this.theme === "turva" ? "turva" : "default";
9095
- const { inactive, active } = colors[theme];
9096
- const percentage = this.calculatePercentage();
9097
- const rangeStyles = {
9098
- background: `-webkit-linear-gradient(left,${active} 0%,${active} ${percentage}%,${inactive} ${percentage}%)`,
9099
- };
9100
- return (h$1(Host, { class: { "duet-m-0": this.margin === "none", "duet-expand": this.expand } }, h$1("div", { class: {
9101
- "duet-range-container": true,
9102
- "duet-label-hidden": this.labelHidden,
9590
+ return (h$1("div", { class: {
9591
+ "duet-range-stepper": true,
9103
9592
  "duet-theme-turva": this.theme === "turva",
9104
- "duet-ie": isInternetExplorer(),
9105
- "duet-range-disabled": this.disabled,
9106
- } }, h$1("duet-label", { theme: theme, margin: "small", for: identifier }, this.label), h$1("output", { "aria-hidden": "true", htmlFor: identifier, class: "duet-output" }, this.value.toLocaleString(this.locale), this.unit), h$1("input", { onInput: this.onInput, onChange: this.onChange, ref: input => (this.nativeInput = input), type: "range", min: this.min, max: this.max, step: this.step, value: this.value, style: rangeStyles, "aria-valuemin": this.min, "aria-valuemax": this.max, "aria-valuenow": this.value, "aria-valuetext": `${this.value} ${this.unit}`, "aria-controls": this.accessibleControls, "aria-activedescendant": this.accessibleActiveDescendant, "aria-owns": this.accessibleOwns, "aria-describedby": this.accessibleDescribedBy, id: identifier, name: this.name, disabled: this.disabled, required: this.required, class: "duet-range" }))));
9593
+ }, onKeyDown: e => this.onKeyboardDown(e), "aria-controls": this.ariaControls }, h$1("span", { class: "duet-range-step-counter", part: "range-numbers" }, this.generateStepSize()), h$1("duet-action-button", { class: "duet-range-step-button duet-range-step-minus", onClick: e => this.handleClick(e, -1), id: this.leftBn, "aria-label": this.ariaLabels.previous_increment, ref: el => (this.leftBnRef = el), part: "navigation-arrow", iconName: "action-arrow-left-small" }), h$1("duet-action-button", { class: "duet-range-step-button duet-range-step-plus", onClick: e => this.handleClick(e, 1), "aria-label": this.ariaLabels.next_increment, id: this.rightBn, ref: el => (this.rightBnRef = el), part: "navigation-arrow", iconName: "action-arrow-right-small" })));
9107
9594
  }
9108
9595
  get element() { return this; }
9109
- static get style() { return duetRangeSliderCss; }
9596
+ static get watchers() { return {
9597
+ "stepIndex": ["watchStateHandler"]
9598
+ }; }
9599
+ static get style() { return duetRangeStepperCss; }
9110
9600
  };
9111
9601
 
9112
9602
  const duetScrollableCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;-webkit-tap-highlight-color:transparent}:host{position:relative !important}:host .duet-scrollable-items{display:flex}:host .duet-scrollable-items .duet-scrollable-button{position:relative;flex:0 0 auto;flex-basis:40px;padding:10px;cursor:pointer}:host .duet-scrollable-items .duet-scrollable-button:active{transform:scale(0.8)}:host .duet-scrollable-items .duet-scrollable-button--left{left:-12px}:host .duet-scrollable-items .duet-scrollable-button--right{right:-12px}:host .duet-scrollable-items .duet-scrollable-button--occluded{display:none}:host .duet-scrollable-items .duet-scrollable-list{display:flex;flex-wrap:nowrap;gap:20px;padding-top:2px;overflow-x:auto;overflow-y:hidden;white-space:nowrap;scroll-snap-type:x mandatory;scroll-behavior:smooth;scroll-margin:0 20px;-ms-overflow-style:-ms-autohiding-scrollbar;-webkit-overflow-scrolling:touch;}:host .duet-scrollable-items .duet-scrollable-list::-webkit-scrollbar{display:none}::slotted(*){scroll-snap-align:center;margin-left:0;-webkit-transition:-webkit-transform 0.2s ease-in-out;transition:-webkit-transform 0.2s ease-in-out;transition:transform 0.2s ease-in-out;transition:transform 0.2s ease-in-out, -webkit-transform 0.2s ease-in-out}";
@@ -9268,7 +9758,7 @@ let DuetScrollable$1 = class extends H {
9268
9758
  static get style() { return duetScrollableCss; }
9269
9759
  };
9270
9760
 
9271
- const duetSelectCss = "@charset \"UTF-8\";*.sc-duet-select,*.sc-duet-select::after,*.sc-duet-select::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}.sc-duet-select-h{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-right:16px !important;margin-bottom:12px !important;display:inline-flex;width:100%;max-width:100%;vertical-align:bottom}.sc-duet-select-h:last-child,.sc-duet-select-h:last-of-type{margin-right:0 !important}@media (min-width: 36em){.sc-duet-select-h{width:calc(50% - 16px - 3px)}.duet-expand.sc-duet-select-h{width:100% !important}}.duet-m-0.sc-duet-select-h{margin:0 !important}duet-tooltip.sc-duet-select{position:absolute;top:12px;right:0}@media (min-width: 48em){duet-tooltip.sc-duet-select{position:relative;top:4px;right:auto}}.duet-select-placeholder.sc-duet-select{position:absolute;top:-9px;left:9px;z-index:200;display:block;width:auto;max-width:60%;padding:0 0.25rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;background:white}.duet-select-container.sc-duet-select{position:relative;width:100%}.duet-select-wrapper.sc-duet-select{position:relative;width:100%;padding:15px 14px !important;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;font-weight:400;line-height:1.25}.duet-theme-turva.sc-duet-select .duet-select-wrapper.sc-duet-select{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"}.duet-select-wrapper.sc-duet-select::after{content:\"  \"}.duet-select-wrapper.sc-duet-select select.sc-duet-select{position:absolute;top:0;right:0;bottom:0;left:0;z-index:200;width:100%;height:100%;padding:0;margin:0;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;cursor:pointer;border:0;outline:none;opacity:0}.duet-theme-turva.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"}.duet-select-wrapper.sc-duet-select select.sc-duet-select:hover+.duet-select.sc-duet-select{border-color:#909599;box-shadow:0 0 0 1px #909599}.duet-theme-turva.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select:hover+.duet-select.sc-duet-select{border-color:#747475;box-shadow:0 0 0 1px #747475}.has-error.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select:hover+.duet-select.sc-duet-select{box-shadow:0 0 0 1px #de2362}.duet-theme-turva.has-error.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select:hover+.duet-select.sc-duet-select{box-shadow:0 0 0 1px #e02a0d}.duet-select-wrapper.sc-duet-select select.sc-duet-select:focus+.duet-select.sc-duet-select{border-color:#0077b3;outline:0;box-shadow:0 0 0 1px #0077b3;transition:none}.duet-theme-turva.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select:focus+.duet-select.sc-duet-select{border-color:#171c3a;box-shadow:0 0 0 1px #171c3a}.duet-theme-turva.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select:focus+.duet-select.sc-duet-select .duet-select-icon.sc-duet-select{color:#171c3a}.duet-select-wrapper.sc-duet-select select.sc-duet-select:focus+.duet-select.sc-duet-select .duet-select-icon.sc-duet-select{color:#0077b3}.has-error.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select:focus+.duet-select.sc-duet-select{box-shadow:0 0 0 1px #de2362}.duet-theme-turva.has-error.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select:focus+.duet-select.sc-duet-select{box-shadow:0 0 0 1px #e02a0d}.duet-select-wrapper.sc-duet-select select[disabled].sc-duet-select{cursor:default !important}.duet-select-wrapper.sc-duet-select select[disabled].sc-duet-select+.duet-select.sc-duet-select{color:#00294d !important;cursor:default !important;background:#f5f8fa !important;border-color:#f5f8fa !important;box-shadow:none !important;opacity:1 !important;-webkit-text-fill-color:#00294d !important}.duet-theme-turva.sc-duet-select .duet-select-wrapper.sc-duet-select select[disabled].sc-duet-select+.duet-select.sc-duet-select{color:#171c3a !important;background:#f5f5f7 !important;border-color:#f5f5f7 !important;-webkit-text-fill-color:#171c3a !important}.duet-select.sc-duet-select{position:absolute;top:0;right:0;bottom:0;left:0;z-index:100;display:block;width:100%;min-width:8rem;padding:12px 14px !important;padding-right:48px !important;overflow:hidden;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;font-weight:400;font-variant-numeric:tabular-nums;line-height:1.5;color:#00294d;text-align:left;text-overflow:ellipsis;white-space:nowrap;background:white;border:1px solid #909599;border-radius:4px;transition:150ms ease}.has-error.sc-duet-select .duet-select.sc-duet-select{border-color:#de2362 !important}.has-error.sc-duet-select .duet-select.sc-duet-select .duet-select-icon.sc-duet-select{color:#de2362 !important}.duet-theme-turva.has-error.sc-duet-select .duet-select.sc-duet-select{border-color:#e02a0d !important}.duet-theme-turva.has-error.sc-duet-select .duet-select.sc-duet-select .duet-select-icon.sc-duet-select{color:#e02a0d !important}.duet-theme-turva.sc-duet-select .duet-select.sc-duet-select{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#171c3a;border-color:#747475}.duet-select.sc-duet-select svg.sc-duet-select{position:absolute;top:50%;right:16px;z-index:200;width:20px;height:20px;color:#00294d;pointer-events:none;transform:translateY(-50%)}.duet-theme-turva.sc-duet-select .duet-select.sc-duet-select svg.sc-duet-select{color:#171c3a}.duet-select-help.sc-duet-select{display:block;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:0.875rem;font-weight:400;line-height:1.25;color:#657787;border-radius:4px}.duet-select-help.sc-duet-select span.sc-duet-select{display:block;margin-top:8px}.duet-theme-turva.sc-duet-select .duet-select-help.sc-duet-select{color:#747475}.has-error.sc-duet-select .duet-select-help.sc-duet-select{color:#de2362}.duet-theme-turva.has-error.sc-duet-select .duet-select-help.sc-duet-select{color:#e02a0d}.duet-label-hidden.sc-duet-select duet-label.sc-duet-select{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0 0 0 0);border:0}";
9761
+ const duetSelectCss = "@charset \"UTF-8\";*.sc-duet-select,*.sc-duet-select::after,*.sc-duet-select::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}.sc-duet-select-h{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-right:16px !important;margin-bottom:12px !important;display:inline-flex;width:100%;max-width:100%;vertical-align:bottom}.sc-duet-select-h:last-child,.sc-duet-select-h:last-of-type{margin-right:0 !important}@media (min-width: 36em){.sc-duet-select-h{width:calc(50% - 16px - 3px)}.duet-expand.sc-duet-select-h{width:100% !important}}.duet-select-variation-tiny.sc-duet-select-h{position:relative;top:-2px;width:72px;margin:0 !important;vertical-align:baseline}.duet-m-0.sc-duet-select-h{margin:0 !important}duet-tooltip.sc-duet-select{position:absolute;top:12px;right:0}@media (min-width: 48em){duet-tooltip.sc-duet-select{position:relative;top:4px;right:auto}}.duet-select-placeholder.sc-duet-select{position:absolute;top:-9px;left:9px;z-index:200;display:block;width:auto;max-width:60%;padding:0 0.25rem;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;background:white}.duet-select-container.sc-duet-select{position:relative;width:100%}.duet-select-container.duet-select-variation-tiny.sc-duet-select{width:72px}.duet-select-wrapper.sc-duet-select{position:relative;width:100%;padding:15px 14px !important;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;font-weight:400;line-height:1.25}.duet-theme-turva.sc-duet-select .duet-select-wrapper.sc-duet-select{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"}.duet-select-variation-tiny.sc-duet-select .duet-select-wrapper.sc-duet-select{width:81px;padding:0 !important}.duet-select-wrapper.sc-duet-select::after{content:\"  \"}.duet-select-wrapper.sc-duet-select select.sc-duet-select{position:absolute;top:0;right:0;bottom:0;left:0;z-index:200;width:100%;height:100%;padding:0;margin:0;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;cursor:pointer;border:0;outline:none;opacity:0}.duet-theme-turva.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"}.duet-select-wrapper.sc-duet-select select.sc-duet-select:hover+.duet-select.sc-duet-select{border-color:#909599;box-shadow:0 0 0 1px #909599}.duet-theme-turva.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select:hover+.duet-select.sc-duet-select{border-color:#747475;box-shadow:0 0 0 1px #747475}.has-error.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select:hover+.duet-select.sc-duet-select{box-shadow:0 0 0 1px #de2362}.duet-theme-turva.has-error.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select:hover+.duet-select.sc-duet-select{box-shadow:0 0 0 1px #e02a0d}.duet-select-wrapper.sc-duet-select select.sc-duet-select:focus+.duet-select.sc-duet-select{border-color:#0077b3;outline:0;box-shadow:0 0 0 1px #0077b3;transition:none}.duet-theme-turva.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select:focus+.duet-select.sc-duet-select{border-color:#171c3a;box-shadow:0 0 0 1px #171c3a}.duet-theme-turva.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select:focus+.duet-select.sc-duet-select .duet-select-icon.sc-duet-select{color:#171c3a}.duet-select-wrapper.sc-duet-select select.sc-duet-select:focus+.duet-select.sc-duet-select .duet-select-icon.sc-duet-select{color:#0077b3}.has-error.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select:focus+.duet-select.sc-duet-select{box-shadow:0 0 0 1px #de2362}.duet-theme-turva.has-error.sc-duet-select .duet-select-wrapper.sc-duet-select select.sc-duet-select:focus+.duet-select.sc-duet-select{box-shadow:0 0 0 1px #e02a0d}.duet-select-wrapper.sc-duet-select select[disabled].sc-duet-select{cursor:default !important}.duet-select-wrapper.sc-duet-select select[disabled].sc-duet-select+.duet-select.sc-duet-select{color:#00294d !important;cursor:default !important;background:#f5f8fa !important;border-color:#f5f8fa !important;box-shadow:none !important;opacity:1 !important;-webkit-text-fill-color:#00294d !important}.duet-theme-turva.sc-duet-select .duet-select-wrapper.sc-duet-select select[disabled].sc-duet-select+.duet-select.sc-duet-select{color:#171c3a !important;background:#f5f5f7 !important;border-color:#f5f5f7 !important;-webkit-text-fill-color:#171c3a !important}.duet-select.sc-duet-select{position:absolute;top:0;right:0;bottom:0;left:0;z-index:100;display:block;width:100%;min-width:8rem;padding:12px 14px !important;padding-right:48px !important;overflow:hidden;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;font-weight:400;font-variant-numeric:tabular-nums;line-height:1.5;color:#00294d;text-align:left;text-overflow:ellipsis;white-space:nowrap;background:white;border:1px solid #909599;border-radius:4px;transition:150ms ease}.has-error.sc-duet-select .duet-select.sc-duet-select{border-color:#de2362 !important}.has-error.sc-duet-select .duet-select.sc-duet-select .duet-select-icon.sc-duet-select{color:#de2362 !important}.duet-theme-turva.has-error.sc-duet-select .duet-select.sc-duet-select{border-color:#e02a0d !important}.duet-theme-turva.has-error.sc-duet-select .duet-select.sc-duet-select .duet-select-icon.sc-duet-select{color:#e02a0d !important}.duet-theme-turva.sc-duet-select .duet-select.sc-duet-select{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";color:#171c3a;border-color:#747475}.duet-select.sc-duet-select svg.sc-duet-select{position:absolute;top:50%;right:16px;z-index:200;width:20px;height:20px;color:#00294d;pointer-events:none;transform:translateY(-50%)}.duet-theme-turva.sc-duet-select .duet-select.sc-duet-select svg.sc-duet-select{color:#171c3a}.duet-select-variation-tiny.sc-duet-select .duet-select.sc-duet-select{width:72px;min-width:inherit;padding:0 !important;margin-bottom:-4px;overflow:visible;font-weight:600;text-align:center}.duet-select-variation-tiny.sc-duet-select .duet-select.sc-duet-select duet-icon.sc-duet-select{padding-left:10px}.duet-select-help.sc-duet-select{display:block;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:0.875rem;font-weight:400;line-height:1.25;color:#657787;border-radius:4px}.duet-select-help.sc-duet-select span.sc-duet-select{display:block;margin-top:8px}.duet-theme-turva.sc-duet-select .duet-select-help.sc-duet-select{color:#747475}.has-error.sc-duet-select .duet-select-help.sc-duet-select{color:#de2362}.duet-theme-turva.has-error.sc-duet-select .duet-select-help.sc-duet-select{color:#e02a0d}.duet-label-hidden.sc-duet-select duet-label.sc-duet-select{position:absolute;width:1px;height:1px;padding:0;margin:-1px;overflow:hidden;clip:rect(0 0 0 0);border:0}";
9272
9762
 
9273
9763
  function isOptionGroup(item) {
9274
9764
  return "options" in item;
@@ -9304,6 +9794,10 @@ let DuetSelect$1 = class extends H {
9304
9794
  * Inlined decorator, alphabetical order.
9305
9795
  */
9306
9796
  this.processedItems = null;
9797
+ /**
9798
+ * Variation of dropdown. -tiny is used for small numbers / tiny option ranges.
9799
+ */
9800
+ this.variation = "default";
9307
9801
  /**
9308
9802
  * Controls the margin of the component.
9309
9803
  */
@@ -9435,15 +9929,23 @@ let DuetSelect$1 = class extends H {
9435
9929
  */
9436
9930
  render() {
9437
9931
  const identifier = this.identifier || this.selectId;
9438
- return (h$1(Host, { onClick: this.onClick, class: { "duet-m-0": this.margin === "none", "duet-expand": this.expand } }, h$1("div", { class: {
9932
+ return (h$1(Host, { onClick: this.onClick, class: {
9933
+ "duet-m-0": this.margin === "none",
9934
+ "duet-expand": this.expand,
9935
+ "duet-select-variation-tiny": this.variation === "tiny",
9936
+ } }, h$1("div", { class: {
9439
9937
  "duet-select-container": true,
9440
9938
  "duet-label-hidden": this.labelHidden,
9441
9939
  "duet-theme-turva": this.theme === "turva",
9940
+ "duet-select-variation-tiny": this.variation === "tiny",
9442
9941
  "duet-input-top-caption-shown": this.isCaptionVisible,
9443
9942
  "has-error": !!this.error,
9444
9943
  } }, h$1("duet-label", { theme: this.theme === "turva" ? "turva" : "default", class: { "duet-has-tooltip": !!this.tooltip }, id: this.labelId, for: identifier }, this.label), this.tooltip && (h$1("duet-tooltip", { direction: this.tooltipDirection, accessibleInputLabel: this.label }, this.tooltip)), this.caption && (h$1("duet-caption", { id: this.topCaptionId, size: "medium" }, this.caption)), h$1("div", { class: "duet-select-wrapper" }, this.placeholder && this.echoPlaceholder && this.value && (h$1("duet-caption", { id: this.topCaptionPlaceholderId, class: "duet-select-placeholder", size: "small" }, this.placeholder)), h$1("select", { ref: select => (this.nativeSelect = select), disabled: this.disabled, name: this.name, id: identifier, role: this.role, "aria-labelledby": `${this.labelId} ${this.errorId}`, "aria-controls": this.accessibleControls, "aria-activedescendant": this.accessibleActiveDescendant, "aria-owns": this.accessibleOwns, onFocus: this.onFocus, onBlur: this.onBlur, onChange: this.onChange, required: this.required, "aria-describedby": this.accessibleDescribedBy }, this.placeholder && (h$1("option", { disabled: true, selected: true, value: "" }, this.placeholder)), !this.processedItems ? (h$1("option", null, "Virhe valintoja ladattaessa. P\u00E4ivit\u00E4 sivu ja kokeile uusiksi.")) : (this.processedItems.map(item => {
9445
9944
  return isOptionGroup(item) ? this.renderOptionGroup(item) : this.renderOption(item);
9446
- }))), h$1("div", { class: "duet-select", "aria-hidden": "true" }, h$1("span", { key: this.value }, this.getSelectedItemLabel()), h$1("svg", { role: "img", class: "duet-select-icon", fill: "currentColor", viewBox: "0 0 24 24", xmlns: "http://www.w3.org/2000/svg" }, h$1("path", { d: "m12 18.999c-.4 0-.776-.156-1.059-.438l-10.721-10.72c-.142-.142-.22-.33-.22-.531 0-.2.078-.389.22-.53.142-.142.33-.22.53-.22s.389.078.53.22l10.72 10.719 10.72-10.719c.142-.142.33-.22.53-.22s.389.078.53.22c.142.142.22.33.22.53s-.078.389-.22.53l-10.72 10.72c-.282.283-.659.439-1.06.439z" })))), h$1("span", { class: "duet-select-help", id: this.errorId, "aria-live": "assertive", "aria-relevant": "additions removals" }, this.error && h$1("span", null, this.error)))));
9945
+ }))), h$1("div", { class: {
9946
+ "duet-select": true,
9947
+ "duet-select-variation-tiny": this.variation === "tiny",
9948
+ }, "aria-hidden": "true" }, h$1("span", { key: this.value }, this.getSelectedItemLabel()), this.variation !== "tiny" && (h$1("svg", { role: "img", class: "duet-select-icon", fill: "currentColor", viewBox: "0 0 24 24", xmlns: "http://www.w3.org/2000/svg" }, h$1("path", { d: "m12 18.999c-.4 0-.776-.156-1.059-.438l-10.721-10.72c-.142-.142-.22-.33-.22-.531 0-.2.078-.389.22-.53.142-.142.33-.22.53-.22s.389.078.53.22l10.72 10.719 10.72-10.719c.142-.142.33-.22.53-.22s.389.078.53.22c.142.142.22.33.22.53s-.078.389-.22.53l-10.72 10.72c-.282.283-.659.439-1.06.439z" }))), this.variation === "tiny" && (h$1("duet-icon", { name: "action-arrow-down-small", color: "currentColor", margin: "none", size: "xx-small" })))), h$1("span", { class: "duet-select-help", id: this.errorId, "aria-live": "assertive", "aria-relevant": "additions removals" }, this.error && h$1("span", null, this.error)))));
9447
9949
  }
9448
9950
  get element() { return this; }
9449
9951
  static get watchers() { return {
@@ -9891,7 +10393,7 @@ let DuetTabGroup$1 = class extends H {
9891
10393
  };
9892
10394
  this.renderTab = () => {
9893
10395
  const renderedTabs = this.tabs.map((element, index) => {
9894
- return (h$1("button", { role: "tab", id: this.getButtonId(index), "aria-controls": this.getTabId(index), "aria-selected": element.selected ? "true" : "false", "aria-description": this.getAccessibleDescription(index), part: `${this.identifier}-button`, type: "button", class: {
10396
+ return (h$1("button", { role: "tab", id: this.getButtonId(index), "aria-controls": this.getTabId(index), "aria-selected": element.selected ? "true" : "false", "aria-description": this.getAccessibleDescription(index), part: `${this.identifier}-button ${element.selected ? `${this.identifier}-button--selected` : ""}`, type: "button", class: {
9895
10397
  "duet-p-0": this.padding === "none",
9896
10398
  "duet-tab-button": true,
9897
10399
  selected: element.selected,
@@ -10014,7 +10516,7 @@ let DuetTabGroup$1 = class extends H {
10014
10516
  static get style() { return duetTabGroupCss; }
10015
10517
  };
10016
10518
 
10017
- const duetTableCss = "duet-table{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-bottom:20px !important;display:block;font-variant-numeric:tabular-nums}duet-table table,duet-table thead,duet-table tbody,duet-table tfoot,duet-table th,duet-table td,duet-table tr{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}duet-table.duet-m-0{margin:0 !important}duet-table table{width:100%;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;text-align:left;border-spacing:0;border-collapse:separate}duet-table.duet-theme-turva table{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"}duet-table td{-webkit-hyphens:auto;hyphens:auto;color:#00294d}duet-table.duet-theme-turva td{color:#171c3a}duet-table th{font-weight:600;line-height:1.25;color:#657787;text-align:left}duet-table.duet-theme-turva th{color:#747475}duet-table tbody th{font-weight:600;color:#00294d}duet-table.duet-theme-turva tbody th{color:#171c3a}.duet-table-flattened table,.duet-table-flattened thead,.duet-table-flattened tbody,.duet-table-flattened tfoot,.duet-table-flattened th,.duet-table-flattened td,.duet-table-flattened tr{display:block}.duet-table-flattened thead tr{position:absolute !important;top:0;width:1px !important;height:1px !important;padding:0 !important;overflow:hidden !important;clip:rect(1px, 1px, 1px, 1px) !important;border:0 !important}.duet-table-flattened td{line-height:1.25}.duet-table-flattened td:not(:last-child){margin-bottom:16px !important}.duet-table-flattened tbody td,.duet-table-flattened tbody th,.duet-table-flattened tfoot td{padding:0 !important;text-align:left !important}.duet-table-flattened tbody th{font-weight:600;line-height:1.25;color:#657787;text-align:left}.duet-table-flattened td[data-heading]::before{margin-bottom:4px !important;display:block;font-size:1rem;font-weight:600;color:#00294d;content:attr(data-heading)}.duet-table-flattened.duet-theme-turva td[data-heading]::before{color:#171c3a}.duet-table-sticky thead th{position:sticky;top:0;background:white}.duet-table-striped td,.duet-table-striped th{padding:20px !important}@media (max-width: 35.9375em){.duet-table-striped td,.duet-table-striped th{padding:20px 12px !important}}.duet-table-striped tbody th{background:white}.duet-table-striped.duet-table-sticky thead th{border-bottom:1px solid #e1e3e6}.duet-table-striped.duet-table-sticky.duet-theme-turva thead th{border-bottom-color:#e4e4e6}.duet-table-striped tbody:not(:first-of-type) th{padding-top:40px !important}.duet-table-striped tbody:only-of-type tr:nth-of-type(odd){background:rgba(0, 80, 128, 0.04)}.duet-table-striped.duet-theme-turva tbody:only-of-type tr:nth-of-type(odd){background:rgba(23, 28, 58, 0.04)}.duet-table-striped tbody:not(:only-of-type) tr:nth-of-type(even){background:rgba(0, 80, 128, 0.04)}.duet-table-striped.duet-theme-turva tbody:not(:only-of-type) tr:nth-of-type(even){background:rgba(23, 28, 58, 0.04)}.duet-table-striped tfoot td{border-top:1px solid #e1e3e6}.duet-table-striped.duet-theme-turva tfoot td{border-top-color:#e4e4e6}.duet-table-striped.duet-table-flattened tbody:not(:first-of-type) th{padding-top:20px !important}.duet-table-striped.duet-table-flattened tr{padding:20px !important}.duet-table-striped.duet-table-flattened tfoot td{border-top:0}.duet-table-striped.duet-table-flattened tfoot tr{border-top:1px solid #e1e3e6}.duet-table-striped.duet-table-flattened.duet-theme-turva tfoot tr{border-top-color:#e4e4e6}.duet-table-fixed th,.duet-table-minimal th,.duet-table-plain th{padding:16px !important;border-bottom:1px solid #657787}.duet-table-fixed th:first-child,.duet-table-minimal th:first-child,.duet-table-plain th:first-child{padding-left:0 !important}.duet-table-fixed th:last-child,.duet-table-minimal th:last-child,.duet-table-plain th:last-child{padding-right:0 !important}.duet-theme-turva.duet-table-fixed th,.duet-theme-turva.duet-table-minimal th,.duet-theme-turva.duet-table-plain th{border-bottom-color:#444445}.duet-table-fixed tbody th,.duet-table-minimal tbody th,.duet-table-plain tbody th{padding-top:40px !important;border-bottom-color:#e1e3e6}.duet-theme-turva.duet-table-fixed tbody th,.duet-theme-turva.duet-table-minimal tbody th,.duet-theme-turva.duet-table-plain tbody th{border-bottom-color:#e4e4e6}.duet-table-fixed td,.duet-table-minimal td,.duet-table-plain td{padding:16px !important}.duet-table-fixed td:first-child,.duet-table-minimal td:first-child,.duet-table-plain td:first-child{padding-left:0 !important}.duet-table-fixed td:last-child,.duet-table-minimal td:last-child,.duet-table-plain td:last-child{padding-right:0 !important}.duet-table-fixed tbody td,.duet-table-minimal tbody td,.duet-table-plain tbody td{border-bottom:1px solid #e1e3e6}.duet-theme-turva.duet-table-fixed tbody td,.duet-theme-turva.duet-table-minimal tbody td,.duet-theme-turva.duet-table-plain tbody td{border-bottom-color:#e4e4e6}.duet-table-flattened.duet-table-fixed tbody:first-of-type th,.duet-table-flattened.duet-table-minimal tbody:first-of-type th,.duet-table-flattened.duet-table-plain tbody:first-of-type th{padding-top:0 !important}.duet-table-flattened.duet-table-fixed td,.duet-table-flattened.duet-table-minimal td,.duet-table-flattened.duet-table-plain td,.duet-table-flattened.duet-table-fixed tbody th,.duet-table-flattened.duet-table-minimal tbody th,.duet-table-flattened.duet-table-plain tbody th{border-bottom:0}.duet-table-flattened.duet-table-fixed tr,.duet-table-flattened.duet-table-minimal tr,.duet-table-flattened.duet-table-plain tr{padding:20px 0 !important}.duet-table-flattened.duet-table-fixed tbody th,.duet-table-flattened.duet-table-minimal tbody th,.duet-table-flattened.duet-table-plain tbody th{padding-top:20px !important}.duet-table-flattened.duet-table-fixed tfoot td,.duet-table-flattened.duet-table-minimal tfoot td,.duet-table-flattened.duet-table-plain tfoot td{margin-bottom:4px !important}.duet-table-flattened.duet-table-fixed tbody:not(:only-of-type) tr:first-child,.duet-table-flattened.duet-table-minimal tbody:not(:only-of-type) tr:first-child,.duet-table-flattened.duet-table-plain tbody:not(:only-of-type) tr:first-child{border-bottom:0}.duet-table-plain.duet-table-flattened tbody tr{border-bottom:1px solid #e1e3e6}.duet-table-plain.duet-table-flattened.duet-theme-turva tbody tr{border-bottom-color:#e4e4e6}.duet-table-minimal tbody tr,.duet-table-minimal tbody tr td{vertical-align:top;border-bottom:0 none}.duet-table-minimal tbody tr:last-of-type,.duet-table-minimal tbody tr:last-of-type td{border-bottom:1px solid #e1e3e6}.duet-table-minimal.duet-table-flattened tbody tr,.duet-table-minimal.duet-table-flattened tbody tr td{border-bottom:0 none}.duet-table-minimal.duet-table-flattened tbody tr td[data-heading]::before{display:none}.duet-table-minimal.duet-table-flattened tfoot{border-top:1px solid #e1e3e6}.duet-table-minimal.duet-table-flattened.duet-theme-turva tfoot{border-top-color:#e4e4e6}.duet-table-fixed table{table-layout:fixed}.duet-table-fixed tbody tr,.duet-table-fixed tbody tr td,.duet-table-fixed tbody tr td:first-child{padding:4px !important;vertical-align:text-bottom;border-bottom:0 none}.duet-table-fixed thead{display:none}.duet-table-fixed tbody tr,.duet-table-fixed tbody tr td{border-bottom:0 none}.duet-table-fixed:not(.duet-table-flattened) tfoot{border-top:1px solid #e1e3e6}.duet-table-fixed:not(.duet-table-flattened).duet-theme-turva tfoot{border-top-color:#e4e4e6}.duet-table-scrollable{position:relative;width:100%;overflow-x:auto;background:linear-gradient(90deg, #fff 0%, rgba(255, 255, 255, 0)), linear-gradient(-90deg, #fff 0%, rgba(255, 255, 255, 0)) 100% 0, radial-gradient(farthest-side at 0% 50%, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0)), radial-gradient(farthest-side at 100% 50%, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0)) 100% 0%;background-repeat:no-repeat;background-attachment:local, local, scroll, scroll;background-size:100px 100%, 100px 100%, 12px 100%, 12px 100%}.duet-table-selected-column{background:rgba(0, 119, 179, 0.08)}.duet-theme-turva .duet-table-selected-column{background:rgba(68, 68, 69, 0.08)}";
10519
+ const duetTableCss = "duet-table{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;margin-bottom:20px !important;display:block;font-variant-numeric:tabular-nums}duet-table table,duet-table thead,duet-table tbody,duet-table tfoot,duet-table th,duet-table td,duet-table tr{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}duet-table.duet-m-0{margin:0 !important}duet-table table{width:100%;font-family:\"localtapiola-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\";font-size:1rem;text-align:left;border-spacing:0;border-collapse:separate}duet-table.duet-theme-turva table{font-family:\"turva-sans\", -apple-system, BlinkMacSystemFont, \"Segoe UI\", Roboto, Helvetica, Arial, sans-serif, \"Apple Color Emoji\", \"Segoe UI Emoji\", \"Segoe UI Symbol\"}duet-table td{-webkit-hyphens:auto;hyphens:auto;color:#00294d}duet-table.duet-theme-turva td{color:#171c3a}duet-table th{font-weight:600;line-height:1.25;color:#657787;text-align:left}duet-table.duet-theme-turva th{color:#747475}duet-table tbody th{font-weight:600;color:#00294d}duet-table.duet-theme-turva tbody th{color:#171c3a}duet-table .duet-table-action-row td:last-child{justify-self:end;padding-right:20px !important;white-space:nowrap}.duet-table-flattened tbody tr{display:grid;grid-template-columns:repeat(2, 1fr);grid-auto-rows:auto;gap:10px}.duet-table-flattened tbody tr.duet-table-action-row td:last-child::before{padding:0;content:\"\"}.duet-table-flattened thead tr{position:absolute !important;top:0;width:1px !important;height:1px !important;padding:0 !important;overflow:hidden !important;clip:rect(1px, 1px, 1px, 1px) !important;border:0 !important}.duet-table-flattened td{grid-column:1/2;line-height:1.25}.duet-table-flattened td:not(:last-child){margin-bottom:16px !important}.duet-table-flattened td:first-child{grid-row:1;grid-column:1}.duet-table-flattened td:last-child{grid-row:1;grid-column:2}.duet-table-flattened tbody td,.duet-table-flattened tbody th,.duet-table-flattened tfoot td{padding:0 !important;text-align:left !important}.duet-table-flattened tbody th{font-weight:600;line-height:1.25;color:#657787;text-align:left}.duet-table-flattened td[data-heading]::before{margin-bottom:4px !important;display:block;font-size:1rem;font-weight:600;color:#00294d;content:attr(data-heading)}.duet-table-flattened.duet-theme-turva td[data-heading]::before{color:#171c3a}.duet-table-sticky thead th{position:sticky;top:0;background:white}.duet-table-striped td,.duet-table-striped th{padding:20px !important}@media (max-width: 35.9375em){.duet-table-striped td,.duet-table-striped th{padding:20px 12px !important}}.duet-table-striped tbody th{background:white}.duet-table-striped.duet-table-sticky thead th{border-bottom:1px solid #e1e3e6}.duet-table-striped.duet-table-sticky.duet-theme-turva thead th{border-bottom-color:#e4e4e6}.duet-table-striped tbody:not(:first-of-type) th{padding-top:40px !important}.duet-table-striped tbody:only-of-type tr:nth-of-type(odd){background:rgba(0, 80, 128, 0.04)}.duet-table-striped.duet-theme-turva tbody:only-of-type tr:nth-of-type(odd){background:rgba(23, 28, 58, 0.04)}.duet-table-striped tbody:not(:only-of-type) tr:nth-of-type(even){background:rgba(0, 80, 128, 0.04)}.duet-table-striped.duet-theme-turva tbody:not(:only-of-type) tr:nth-of-type(even){background:rgba(23, 28, 58, 0.04)}.duet-table-striped tfoot td{border-top:1px solid #e1e3e6}.duet-table-striped.duet-theme-turva tfoot td{border-top-color:#e4e4e6}.duet-table-striped.duet-table-flattened tbody:not(:first-of-type) th{padding-top:20px !important}.duet-table-striped.duet-table-flattened tr{padding:20px !important}.duet-table-striped.duet-table-flattened tfoot td{border-top:0}.duet-table-striped.duet-table-flattened tfoot tr{border-top:1px solid #e1e3e6}.duet-table-striped.duet-table-flattened.duet-theme-turva tfoot tr{border-top-color:#e4e4e6}.duet-table-fixed th,.duet-table-minimal th,.duet-table-plain th{padding:16px !important;border-bottom:1px solid #657787}.duet-table-fixed th:first-child,.duet-table-minimal th:first-child,.duet-table-plain th:first-child{padding-left:0 !important}.duet-table-fixed th:last-child,.duet-table-minimal th:last-child,.duet-table-plain th:last-child{padding-right:0 !important}.duet-theme-turva.duet-table-fixed th,.duet-theme-turva.duet-table-minimal th,.duet-theme-turva.duet-table-plain th{border-bottom-color:#444445}.duet-table-fixed tbody th,.duet-table-minimal tbody th,.duet-table-plain tbody th{padding-top:40px !important;border-bottom-color:#e1e3e6}.duet-theme-turva.duet-table-fixed tbody th,.duet-theme-turva.duet-table-minimal tbody th,.duet-theme-turva.duet-table-plain tbody th{border-bottom-color:#e4e4e6}.duet-table-fixed td,.duet-table-minimal td,.duet-table-plain td{padding:16px !important}.duet-table-fixed td:first-child,.duet-table-minimal td:first-child,.duet-table-plain td:first-child{padding-left:0 !important}.duet-table-fixed td:last-child,.duet-table-minimal td:last-child,.duet-table-plain td:last-child{padding-right:0 !important}.duet-table-fixed tbody td,.duet-table-minimal tbody td,.duet-table-plain tbody td{border-bottom:1px solid #e1e3e6}.duet-theme-turva.duet-table-fixed tbody td,.duet-theme-turva.duet-table-minimal tbody td,.duet-theme-turva.duet-table-plain tbody td{border-bottom-color:#e4e4e6}.duet-table-flattened.duet-table-fixed tbody:first-of-type th,.duet-table-flattened.duet-table-minimal tbody:first-of-type th,.duet-table-flattened.duet-table-plain tbody:first-of-type th{padding-top:0 !important}.duet-table-flattened.duet-table-fixed td,.duet-table-flattened.duet-table-minimal td,.duet-table-flattened.duet-table-plain td,.duet-table-flattened.duet-table-fixed tbody th,.duet-table-flattened.duet-table-minimal tbody th,.duet-table-flattened.duet-table-plain tbody th{border-bottom:0}.duet-table-flattened.duet-table-fixed tr,.duet-table-flattened.duet-table-minimal tr,.duet-table-flattened.duet-table-plain tr{padding:20px 0 !important}.duet-table-flattened.duet-table-fixed tbody th,.duet-table-flattened.duet-table-minimal tbody th,.duet-table-flattened.duet-table-plain tbody th{padding-top:20px !important}.duet-table-flattened.duet-table-fixed tfoot td,.duet-table-flattened.duet-table-minimal tfoot td,.duet-table-flattened.duet-table-plain tfoot td{margin-bottom:4px !important}.duet-table-flattened.duet-table-fixed tbody:not(:only-of-type) tr:first-child,.duet-table-flattened.duet-table-minimal tbody:not(:only-of-type) tr:first-child,.duet-table-flattened.duet-table-plain tbody:not(:only-of-type) tr:first-child{border-bottom:0}.duet-table-plain.duet-table-flattened tbody tr{border-bottom:1px solid #e1e3e6}.duet-table-plain.duet-table-flattened.duet-theme-turva tbody tr{border-bottom-color:#e4e4e6}.duet-table-minimal tbody tr,.duet-table-minimal tbody tr td{vertical-align:top;border-bottom:0 none}.duet-table-minimal tbody tr:last-of-type,.duet-table-minimal tbody tr:last-of-type td{border-bottom:1px solid #e1e3e6}.duet-table-minimal.duet-table-flattened tbody tr,.duet-table-minimal.duet-table-flattened tbody tr td{border-bottom:0 none}.duet-table-minimal.duet-table-flattened tbody tr td[data-heading]::before{display:none}.duet-table-minimal.duet-table-flattened tfoot{border-top:1px solid #e1e3e6}.duet-table-minimal.duet-table-flattened.duet-theme-turva tfoot{border-top-color:#e4e4e6}.duet-table-fixed table{table-layout:fixed}.duet-table-fixed tbody tr,.duet-table-fixed tbody tr td,.duet-table-fixed tbody tr td:first-child{padding:4px !important;vertical-align:text-bottom;border-bottom:0 none}.duet-table-fixed thead{display:none}.duet-table-fixed tbody tr,.duet-table-fixed tbody tr td{border-bottom:0 none}.duet-table-fixed:not(.duet-table-flattened) tfoot{border-top:1px solid #e1e3e6}.duet-table-fixed:not(.duet-table-flattened).duet-theme-turva tfoot{border-top-color:#e4e4e6}.duet-table-scrollable{position:relative;width:100%;overflow-x:auto;background:linear-gradient(90deg, #fff 0%, rgba(255, 255, 255, 0)), linear-gradient(-90deg, #fff 0%, rgba(255, 255, 255, 0)) 100% 0, radial-gradient(farthest-side at 0% 50%, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0)), radial-gradient(farthest-side at 100% 50%, rgba(0, 0, 0, 0.1), rgba(0, 0, 0, 0)) 100% 0%;background-repeat:no-repeat;background-attachment:local, local, scroll, scroll;background-size:100px 100%, 100px 100%, 12px 100%, 12px 100%}.duet-table-selected-column{background:rgba(0, 119, 179, 0.08)}.duet-theme-turva .duet-table-selected-column{background:rgba(68, 68, 69, 0.08)}.duet-table-sortable tbody tr td:first-child,.duet-table-sortable thead tr th:first-child{padding:20px}.duet-table-sortable:not(.duet-table-flattened) tfoot{border-top:1px solid #e1e3e6}.duet-table-sortable:not(.duet-table-flattened).duet-theme-turva tfoot{border-top-color:#e4e4e6}.duet-table-actions table{table-layout:auto}.duet-table-actions thead th:last-child{width:1px;white-space:nowrap}";
10018
10520
 
10019
10521
  // remove wrapping speech marks.
10020
10522
  // media query tokens are wrapped in speech marks,
@@ -10075,9 +10577,9 @@ let DuetTable$1 = class extends H {
10075
10577
  }
10076
10578
  connectedCallback() {
10077
10579
  this.mq = matchMedia(breakpointToToken[this.breakpoint]);
10078
- this.mq.addEventListener("change", this.handleMediaQueryChange);
10580
+ this.mq.addEventListener("change", debounce(this.handleMediaQueryChange, 50));
10079
10581
  this.handleMediaQueryChange(this.mq);
10080
- this.observer = new MutationObserver(() => this.copyHeadingsToCells());
10582
+ this.observer = new MutationObserver(() => debounce(this.copyHeadingsToCells(), 50));
10081
10583
  this.observer.observe(this.element, {
10082
10584
  childList: true,
10083
10585
  subtree: true,
@@ -10108,6 +10610,9 @@ let DuetTable$1 = class extends H {
10108
10610
  this.mq = null;
10109
10611
  this.matchesBreakpoint = true;
10110
10612
  }
10613
+ /**
10614
+ * Local methods.
10615
+ */
10111
10616
  copyHeadingsToCells() {
10112
10617
  const headingElements = this.element.querySelectorAll("thead th");
10113
10618
  const rowElements = this.element.querySelectorAll("tbody tr");
@@ -11007,7 +11512,7 @@ const validateFile = (item, validators) => {
11007
11512
  if (item) {
11008
11513
  const { name, type, size } = item;
11009
11514
  const mime = validateFileMime(type, allowedMimetypes);
11010
- const ext = validateFileExtension(name, allowedExtensions);
11515
+ const ext = validateFileExtension(name.toLowerCase(), allowedExtensions);
11011
11516
  const bytes = validateFileSize(size, maxBytes);
11012
11517
  if (!mime) {
11013
11518
  errorMessage = getError("duet-upload-101");
@@ -11087,7 +11592,7 @@ const makeXhrRequest = ({ payload, options, onFailure, onSuccess, onProgress })
11087
11592
  return xhr;
11088
11593
  };
11089
11594
 
11090
- const duetUploadCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}::slotted([slot=header]){margin-bottom:16px}::slotted([slot=fileheader]){margin:16px 0 0 0}::slotted([slot=filefooter]){margin-top:16px}.duet-upload{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}.duet-upload-item-size{font-size:0.75rem;font-weight:400}.duet-upload-filelist{margin-bottom:25px}.duet-upload-filelist-empty{display:flex;align-items:center;justify-content:center;width:100%;height:75px;margin:0 auto;font-size:1rem;font-weight:400;background-color:#f5f8fa}";
11595
+ const duetUploadCss = "*,*::after,*::before{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}:host{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}::slotted([slot=header]){margin-bottom:16px}::slotted([slot=fileheader]){margin:16px 0 0 0}::slotted([slot=filefooter]){margin-top:16px}.duet-upload{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none}.duet-upload-item-size{font-size:0.75rem;font-weight:400}.duet-upload-filelist{margin-bottom:25px}.duet-upload-filelist-empty{display:flex;align-items:center;justify-content:center;width:100%;height:75px;margin:0 auto;font-size:1rem;font-weight:400;background-color:#f5f8fa}.duet-upload-editable-table-header-hidden{display:none}.duet-upload-editable-table tbody .duet-upload-editable-table-data{padding:0 !important;border:0}.duet-upload-editable-table duet-editable-table tfoot,.duet-upload-editable-table duet-editable-table thead{display:none}.duet-upload-editable-table duet-editable-table .duet-editable-table-content{padding-right:0 !important;padding-left:0 !important}.duet-upload-editable-table duet-editable-table duet-table .duet-table-action-row td{padding:0.75rem 0 !important}.duet-upload-editable-table duet-editable-table duet-table .duet-table-action-row td:last-child{padding-right:0 !important}.duet-upload-editable-table duet-editable-table .duet-editable-table-row-inprogress duet-action-button::part(button){border:0}";
11091
11596
 
11092
11597
  let DuetUpload$1 = class extends H {
11093
11598
  constructor() {
@@ -11103,25 +11608,6 @@ let DuetUpload$1 = class extends H {
11103
11608
  this.duetCancel = createEvent$2(this, "duetCancel", 3);
11104
11609
  this.duetProgress = createEvent$2(this, "duetProgress", 3);
11105
11610
  this.duetUpload = createEvent$2(this, "duetUpload", 3);
11106
- /**
11107
- * Own Properties
11108
- */
11109
- this.buttonId = createID("DuetButton");
11110
- this.labelId = createID("DuetLabel");
11111
- this.uploadId = createID("DuetUpload");
11112
- this.editableTableId = createID("DuetEditableTable");
11113
- this.filesInProgress = new Map();
11114
- this.fileMaxReached = false;
11115
- this.bytesMaxReached = false;
11116
- this.internalStatusMessageLabel = undefined;
11117
- /**
11118
- * Properties
11119
- */
11120
- this.DefaultGroups = {
11121
- inprogress: "inprogress",
11122
- success: "success",
11123
- failure: "failure",
11124
- };
11125
11611
  /**
11126
11612
  * State() variables
11127
11613
  */
@@ -11143,8 +11629,9 @@ let DuetUpload$1 = class extends H {
11143
11629
  {
11144
11630
  icon: "action-delete",
11145
11631
  color: "color-danger",
11146
- color_hover: "primary-dark",
11147
- id: "delete",
11632
+ size: "x-small",
11633
+ background: "gray-lightest",
11634
+ name: "delete",
11148
11635
  map: ["success", "failure"],
11149
11636
  label: {
11150
11637
  fi: "Poista tiedosto",
@@ -11155,8 +11642,9 @@ let DuetUpload$1 = class extends H {
11155
11642
  {
11156
11643
  icon: "navigation-close",
11157
11644
  color: "primary",
11158
- color_hover: "primary-dark",
11159
- id: "cancel",
11645
+ size: "x-small",
11646
+ background: "gray-lightest",
11647
+ name: "cancel",
11160
11648
  map: ["inprogress"],
11161
11649
  label: {
11162
11650
  fi: "Keskeytä lähetys",
@@ -11226,8 +11714,8 @@ let DuetUpload$1 = class extends H {
11226
11714
  inProgressWithErrors: "Uploading {filesInProgress}, {filesUploaded} uploaded of {filesTotal}, {filesWithErrors} failed",
11227
11715
  done: "All {filesTotal} added successfully",
11228
11716
  doneWithErrors: "Action completed, {filesUploaded} has been added successfully, {filesWithErrors} had errors",
11229
- files: "tiedostoa",
11230
- file: "tiedosto",
11717
+ files: "File",
11718
+ file: "file",
11231
11719
  },
11232
11720
  };
11233
11721
  /**
@@ -11382,19 +11870,72 @@ let DuetUpload$1 = class extends H {
11382
11870
  * by default this is off, setting this to true will limit the users choices to what has been explicitly set
11383
11871
  */
11384
11872
  this.limitSelection = false;
11873
+ /**
11874
+ * Own Properties
11875
+ */
11876
+ this.buttonId = createID("DuetButton");
11877
+ this.labelId = createID("DuetLabel");
11878
+ this.uploadId = createID("DuetUpload");
11879
+ this.filesInProgress = new Map();
11880
+ this.fileMaxReached = false;
11881
+ this.bytesMaxReached = false;
11882
+ this.internalStatusMessageLabel = undefined;
11883
+ /**
11884
+ * Properties
11885
+ */
11886
+ this.DefaultGroups = {
11887
+ inprogress: "inprogress",
11888
+ success: "success",
11889
+ failure: "failure",
11890
+ };
11891
+ /**
11892
+ * Array of group names that you want the editable table to use to display files
11893
+ * @required
11894
+ * @example [{ id: "success", label: {fi: "Onnistunut", en: "Success", sv: "Alt klart", }}]
11895
+ */
11896
+ this.groups = [
11897
+ {
11898
+ id: this.DefaultGroups.inprogress,
11899
+ label: {
11900
+ fi: "Kesken olevat tiedostot",
11901
+ sv: "Filer inprogress",
11902
+ en: "Files inprogress",
11903
+ },
11904
+ },
11905
+ {
11906
+ id: this.DefaultGroups.success,
11907
+ label: {
11908
+ fi: "Valmiit tiedostot",
11909
+ sv: "Files success",
11910
+ en: "Files success",
11911
+ },
11912
+ },
11913
+ {
11914
+ id: this.DefaultGroups.failure,
11915
+ label: {
11916
+ fi: "Tiedostot, joissa on virheitä",
11917
+ sv: "Filer med fel",
11918
+ en: "Files with errors",
11919
+ },
11920
+ },
11921
+ ];
11922
+ this.kick = debounce(() => {
11923
+ this.tick = Date.now();
11924
+ }, 30); // will trigger re-render
11385
11925
  /**
11386
11926
  * Private functions
11387
11927
  */
11388
11928
  this.listenForActionEvents = () => {
11389
- this.element.addEventListener("duetEditableItemAction", (e) => {
11929
+ this.element.addEventListener("duetActionEvent", (e) => {
11390
11930
  const detail = e.detail;
11391
- const { action, keyName, originalEvent } = detail;
11931
+ const { action, id, originalEvent } = detail;
11932
+ console.log(e);
11392
11933
  switch (action) {
11393
11934
  case "delete":
11394
- this.onDelete(keyName, originalEvent);
11935
+ this.onDelete(id, originalEvent);
11395
11936
  break;
11396
11937
  case "cancel":
11397
- this.onCancel(keyName, originalEvent);
11938
+ this.onCancel(id, originalEvent);
11398
11939
  break;
11399
11940
  // code block
11400
11941
  }
@@ -11451,24 +11992,6 @@ let DuetUpload$1 = class extends H {
11451
11992
  return "none";
11452
11993
  }
11453
11994
  };
11454
- this.convertToDuetEditableTableItems = () => {
11455
- // we're always recreating the map - in order to force an update down stream.
11456
- const itemData = new Map();
11457
- //walk the files Map and convert to DuetEditableTableItemData
11458
- this.files.forEach((data, key, _originalMap) => {
11459
- const group = this.getGroupFromItemData(data);
11460
- const item = this.getItemHTMLFromItemData(data, group);
11461
- itemData.set(key, {
11462
- uid: data.uid,
11463
- item,
11464
- group,
11465
- });
11466
- });
11467
- return itemData;
11468
- };
11469
- this.kick = debounce(() => {
11470
- this.tick = Date.now();
11471
- }, 30); // will trigger re-render
11472
11995
  this.genHashName = () => Date.now().toString(36) + Math.random();
11473
11996
  this.updateValueInMap = (item, key, value, kick = true) => {
11474
11997
  const fileItem = this.files.get(item);
@@ -11529,7 +12052,6 @@ let DuetUpload$1 = class extends H {
11529
12052
  this.nativeInput.value = "";
11530
12053
  };
11531
12054
  this.startUpload = async (ev, metaData = undefined) => {
11532
- await this.setFocus();
11533
12055
  this.metaData = metaData;
11534
12056
  this.nativeInput.click();
11535
12057
  this.onUpload(ev, metaData);
@@ -11592,9 +12114,18 @@ let DuetUpload$1 = class extends H {
11592
12114
  fileMaxReached: isTotalFileAmountAboveMax,
11593
12115
  };
11594
12116
  };
12117
+ this.getItemFromUID = (uid) => {
12118
+ for (const [key, value] of this.files.entries()) {
12119
+ if (value.uid === uid) {
12120
+ return { value, key };
12121
+ }
12122
+ }
12123
+ return null;
12124
+ };
11595
12125
  this.onDelete = (key, ev) => {
11596
- const deletedItem = this.files.get(key);
11597
- this.files.delete(key);
12126
+ const retrievedKey = this.getItemFromUID(key).key;
12127
+ const deletedItem = this.files.get(retrievedKey);
12128
+ this.files.delete(retrievedKey);
11598
12129
  this.validateTotals();
11599
12130
  this.kick();
11600
12131
  this.duetDelete.emit({
@@ -11608,8 +12139,9 @@ let DuetUpload$1 = class extends H {
11608
12139
  this.resetFormFields();
11609
12140
  };
11610
12141
  this.onCancel = (key, ev) => {
11611
- const cancelledItem = this.files.get(key);
11612
- this.files.delete(key);
12142
+ const retrievedKey = this.getItemFromUID(key).key;
12143
+ const cancelledItem = this.files.get(retrievedKey);
12144
+ this.files.delete(retrievedKey);
11613
12145
  if (!this.external) {
11614
12146
  const { xhr } = cancelledItem;
11615
12147
  xhr.abort();
@@ -11659,6 +12191,79 @@ let DuetUpload$1 = class extends H {
11659
12191
  data: { files: this.files },
11660
12192
  });
11661
12193
  };
12194
+ /**
12195
+ * @description This functions return sorted map items byg condition which are:
12196
+ */
12197
+ this.filterMap = () => {
12198
+ const all = [...this.files.values()];
12199
+ const inprogress = [];
12200
+ const failure = [];
12201
+ const success = [];
12202
+ all.forEach(data => {
12203
+ const group = this.getGroupFromItemData(data);
12204
+ const item = this.getItemHTMLFromItemData(data, group);
12205
+ if (group === this.DefaultGroups.success) {
12206
+ success.push({
12207
+ uid: data.uid,
12208
+ item,
12209
+ group,
12210
+ });
12211
+ }
12212
+ else if (group === this.DefaultGroups.inprogress) {
12213
+ inprogress.push({
12214
+ uid: data.uid,
12215
+ item,
12216
+ group,
12217
+ });
12218
+ }
12219
+ else if (group === this.DefaultGroups.failure) {
12220
+ failure.push({
12221
+ uid: data.uid,
12222
+ item,
12223
+ group,
12224
+ });
12225
+ }
12226
+ else if (data.group) {
12227
+ inprogress.push({
12228
+ uid: data.uid,
12229
+ item,
12230
+ group: data.group,
12231
+ });
12232
+ }
12233
+ });
12234
+ return {
12235
+ inprogress,
12236
+ failure,
12237
+ success,
12238
+ };
12239
+ };
12240
+ this.getColumns = (group) => {
12241
+ return [
12242
+ {
12243
+ sort_order: 1,
12244
+ direction: 1,
12245
+ index: 0,
12246
+ key: group.id,
12247
+ label: group.label,
12248
+ },
12249
+ ];
12250
+ };
12251
+ this.getActions = (id) => {
12252
+ return this.actions.filter(item => item.map.includes(id));
12253
+ };
12254
+ this.renderEditableTableGroups = () => {
12255
+ const filteredItems = this.filterMap();
12256
+ const EditableTables = this.groups.map(group => {
12257
+ const currentItems = filteredItems[group.id];
12258
+ if (!(currentItems === null || currentItems === void 0 ? void 0 : currentItems.length)) {
12259
+ return;
12260
+ }
12261
+ return (h$1("duet-table", { variation: "plain", breakpoint: "none", role: "log", margin: this.hideGroups ? "none" : "auto" }, h$1("table", { class: "duet-upload-editable-table" }, h$1("thead", { class: "duet-upload-editable-table-header" }, h$1("tr", null, h$1("th", { class: {
12262
+ "duet-upload-editable-table-header-hidden": this.hideGroups,
12263
+ } }, !this.hideGroups ? (getLocaleString(group.label)) : (h$1("duet-visually-hidden", null, getLocaleString(group.label)))))), h$1("tbody", null, h$1("tr", null, h$1("td", { class: "duet-upload-editable-table-data" }, h$1("duet-editable-table", { breakpoint: "none", variation: "plain", groupId: group.id, columns: this.getColumns(group), actions: this.getActions(group.id), margin: "none", rows: currentItems })))))));
12264
+ });
12265
+ return EditableTables;
12266
+ };
11662
12267
  }
11663
12268
  watchValidHandler(newValue, oldValue) {
11664
12269
  if (newValue !== oldValue) {
@@ -11682,6 +12287,68 @@ let DuetUpload$1 = class extends H {
11682
12287
  // listen to the events from the component
11683
12288
  this.verifyValidity();
11684
12289
  }
12290
+ /**
12291
+ * Sets focus on the specified `duet-input`. Use this method instead of the global
12292
+ * `input.focus()`.
12293
+ */
12294
+ async setFocus(options) {
12295
+ if (this.nativeInput) {
12296
+ this.nativeInput.focus(options);
12297
+ }
12298
+ return;
12299
+ }
12300
+ /**
12301
+ * Method for invoking the upload sequence
12302
+ */
12303
+ async upload(metaData = undefined) {
12304
+ await this.setFocus();
12305
+ this.metaData = metaData;
12306
+ this.nativeInput.click();
12307
+ return;
12308
+ }
12309
+ /**
12310
+ * Method for forcing a render of the upload list, element.files can be changed externally
12311
+ * But it will only rerender on a new Map or a top Level change - this can be used to update
12312
+ * the tabular data if the automatic re-render is no sufficient
12313
+ */
12314
+ async refresh() {
12315
+ this.kick();
12316
+ await this.setFocus();
12317
+ }
12318
+ /**
12319
+ * Get list of files, divided in errors and valid sections
12320
+ */
12321
+ async getFiles() {
12322
+ if (!this.files || this.files.size === 0) {
12323
+ return false;
12324
+ }
12325
+ return this.getFilesAsArray();
12326
+ }
12327
+ /**
12328
+ * Convenience method for updating the value of a key:value inside an item in the files attribute
12329
+ */
12330
+ async updateValue(item, key, value) {
12331
+ this.updateValueInMap(item, key, value);
12332
+ }
12333
+ /**
12334
+ * render() function
12335
+ * Always the last one in the class.
12336
+ */
12337
+ render() {
12338
+ const identifier = this.identifier || this.uploadId;
12339
+ let caption = this.description.replace(/{maxfiles}/g, this.maxFiles.toString());
12340
+ caption = caption.replace(/{maxbytes}/g, `${Math.floor(this.maxBytes / 1024 / 1024)} MB`);
12341
+ caption = caption.replace(/{filetypes}/g, this.allowedExtensions.split(",").join(", "));
12342
+ return (h$1(Host, { class: { "duet-m-0": this.margin === "none" } }, h$1("duet-fieldset", { label: this.label, caption: caption }, h$1("slot", { name: "header" }), !this.files.size && (h$1("duet-label", { part: this.identifier ? `${this.identifier}-empty-state` : "duet-upload-empty-state", theme: this.theme === "turva" ? "turva" : "default", size: "small", class: {
12343
+ "duet-upload-filelist-empty": !this.files.size,
12344
+ "duet-upload-filelist": true,
12345
+ "duet-upload-filelist-filled": this.files.size,
12346
+ }, id: this.labelId, for: identifier }, this.fileListEmpty)), !!this.files.size && h$1("slot", { name: "fileheader" }), !!this.files.size && (h$1("duet-upload-aria-status", { invalid: this.getFilesAsArray().invalid.length, valid: this.getFilesAsArray().valid.length, inprogress: this.filesInProgress.size, total: this.files.size, statusMessageLabel: this.internalStatusMessageLabel })), !!this.files.size && this.renderEditableTableGroups(), !!this.files.size && h$1("slot", { name: "filefooter" }), h$1("duet-spacer", { size: "large" }), !this.hideButton && (h$1("duet-button", { id: this.buttonId, onClick: this.startUpload, "accessible-controls": identifier, disabled: this.fileMaxReached, "accessible-label": this.accessibleButtonLabel, "accessible-owns": identifier, size: "small", variation: "secondary", fixed: true, icon: "action-add-circle", part: this.identifier ? `${this.identifier}-button-upload` : "duet-upload-button-upload" }, this.buttonLabel)), h$1("duet-spacer", { size: "medium" }), (this.fileMaxReached || this.bytesMaxReached) && (h$1("duet-alert", { part: this.identifier ? `${this.identifier}-error-notification` : "duet-upload-error-notification" }, this.fileMaxReached && getI18nError("duet-upload-301"), this.bytesMaxReached && getI18nError("duet-upload-202"))), h$1("duet-spacer", { size: "medium" }), h$1("duet-visually-hidden", null, h$1("input", { ref: input => {
12347
+ this.nativeInput = input;
12348
+ }, accept: !this.limitSelection ? undefined : `${this.allowedMimetypes},${this.allowedExtensions}`, onBlur: this.onBlur, onFocus: this.onFocus, onChange: e => this.onChange(e), type: "file", class: {
12349
+ "duet-upload": true,
12350
+ }, disabled: this.disabled, "aria-hidden": "true", required: this.required, name: this.name, id: this.identifier, multiple: this.multiple, capture: "user" })))));
12351
+ }
11685
12352
  /**
11686
12353
  * XHR request utilities
11687
12354
  */
@@ -11803,68 +12470,6 @@ let DuetUpload$1 = class extends H {
11803
12470
  component: "duet-upload",
11804
12471
  });
11805
12472
  }
11806
- /**
11807
- * Sets focus on the specified `duet-input`. Use this method instead of the global
11808
- * `input.focus()`.
11809
- */
11810
- async setFocus(options) {
11811
- if (this.nativeInput) {
11812
- this.nativeInput.focus(options);
11813
- }
11814
- return;
11815
- }
11816
- /**
11817
- * Method for invoking the upload sequence
11818
- */
11819
- async upload(metaData = undefined) {
11820
- await this.setFocus();
11821
- this.metaData = metaData;
11822
- this.nativeInput.click();
11823
- return;
11824
- }
11825
- /**
11826
- * Method for forcing a render of the upload list, element.files can be changed externally
11827
- * But it will only rerender on a new Map or a top Level change - this can be used to update
11828
- * the tabular data if the automatic re-render is no sufficient
11829
- */
11830
- async refresh() {
11831
- this.kick();
11832
- await this.setFocus();
11833
- }
11834
- /**
11835
- * Get list of files, divided in errors and valid sections
11836
- */
11837
- async getFiles() {
11838
- if (!this.files || this.files.size === 0) {
11839
- return false;
11840
- }
11841
- return this.getFilesAsArray();
11842
- }
11843
- /**
11844
- * Convenience method for updating the value of a key:value inside an item in the files attribute
11845
- */
11846
- async updateValue(item, key, value) {
11847
- this.updateValueInMap(item, key, value);
11848
- }
11849
- /**
11850
- * render() function
11851
- * Always the last one in the class.
11852
- */
11853
- render() {
11854
- const identifier = this.identifier || this.uploadId;
11855
- let caption = this.description.replace(/{maxfiles}/g, this.maxFiles.toString());
11856
- caption = caption.replace(/{maxbytes}/g, `${Math.floor(this.maxBytes / 1024 / 1024)} MB`);
11857
- caption = caption.replace(/{filetypes}/g, this.allowedExtensions.split(",").join(", "));
11858
- return (h$1(Host, { class: { "duet-m-0": this.margin === "none" } }, h$1("duet-fieldset", { label: this.label, caption: caption }, h$1("slot", { name: "header" }), !this.files.size && (h$1("duet-label", { part: this.identifier ? `${this.identifier}-empty-state` : "duet-upload-empty-state", theme: this.theme === "turva" ? "turva" : "default", size: "small", class: {
11859
- "duet-upload-filelist-empty": !this.files.size,
11860
- "duet-upload-filelist": true,
11861
- "duet-upload-filelist-filled": this.files.size,
11862
- }, id: this.labelId, for: identifier }, this.fileListEmpty)), !!this.files.size && h$1("slot", { name: "fileheader" }), !!this.files.size && (h$1("duet-upload-aria-status", { invalid: this.getFilesAsArray().invalid.length, valid: this.getFilesAsArray().valid.length, inprogress: this.filesInProgress.size, total: this.files.size, statusMessageLabel: this.internalStatusMessageLabel })), !!this.files.size && (h$1("duet-editable-table", { part: this.identifier ? `${this.identifier}-editable-table` : "duet-upload-editable-table", "aria-live": "polite", "aria-relevant": "removals", accessibleRole: "log", id: this.editableTableId, groups: this.groups, actions: this.actions, hideGroups: this.hideGroups, alignment: this.alignment, items: this.convertToDuetEditableTableItems() })), !!this.files.size && h$1("slot", { name: "filefooter" }), h$1("duet-spacer", { size: "large" }), !this.hideButton && (h$1("duet-button", { id: this.buttonId, onClick: this.startUpload, "accessible-controls": identifier, disabled: this.fileMaxReached, "accessible-label": this.accessibleButtonLabel, "accessible-owns": identifier, size: "small", variation: "secondary", fixed: true, icon: "action-add-circle", part: this.identifier ? `${this.identifier}-button-upload` : "duet-upload-button-upload" }, this.buttonLabel)), h$1("duet-spacer", { size: "medium" }), (this.fileMaxReached || this.bytesMaxReached) && (h$1("duet-alert", { part: this.identifier ? `${this.identifier}-error-notification` : "duet-upload-error-notification" }, this.fileMaxReached && getI18nError("duet-upload-301"), this.bytesMaxReached && getI18nError("duet-upload-202"))), h$1("duet-spacer", { size: "medium" }), h$1("duet-visually-hidden", null, h$1("input", { ref: input => {
11863
- this.nativeInput = input;
11864
- }, accept: !this.limitSelection ? undefined : `${this.allowedMimetypes},${this.allowedExtensions}`, onBlur: this.onBlur, onFocus: this.onFocus, onChange: e => this.onChange(e), type: "file", class: {
11865
- "duet-upload": true,
11866
- }, disabled: this.disabled, "aria-hidden": "true", required: this.required, name: this.name, id: this.identifier, multiple: this.multiple, capture: "user" })))));
11867
- }
11868
12473
  get element() { return this; }
11869
12474
  static get watchers() { return {
11870
12475
  "valid": ["watchValidHandler"]
@@ -11983,11 +12588,12 @@ let DuetVisuallyHidden$1 = class extends H {
11983
12588
  };
11984
12589
 
11985
12590
  globalScripts();
12591
+ const DuetActionButton = /*@__PURE__*/proxyCustomElement(DuetActionButton$1, [1,"duet-action-button",{"theme":[1025],"iconName":[1,"icon-name"],"iconColor":[1,"icon-color"],"iconSize":[1,"icon-size"],"actionName":[1,"action-name"],"actionId":[1,"action-id"],"actionMeta":[1,"action-meta"],"disabled":[4],"color":[513],"background":[1],"ariaDescribedBy":[1,"accessible-described-by"],"ariaDescription":[1,"accessible-description"],"ariaLabelsDefaults":[16],"ariaLabels":[16],"ariaControls":[1,"accessible-controls"],"numbersStore":[32]}]);
11986
12592
  const DuetAlert = /*@__PURE__*/proxyCustomElement(DuetAlert$1, [1,"duet-alert",{"theme":[1025],"accessibleLabelDefaults":[1,"accessible-label-default"],"accessibleLabel":[1,"accessible-label"],"announcements":[4],"icon":[1],"autoDismiss":[2,"auto-dismiss"],"margin":[1],"padding":[1],"variation":[1],"dismissible":[4],"isDismissed":[32],"timeoutID":[32]}]);
11987
12593
  const DuetBadge = /*@__PURE__*/proxyCustomElement(DuetBadge$1, [1,"duet-badge",{"theme":[1025],"variation":[1],"margin":[1]}]);
11988
12594
  const DuetBreadcrumb = /*@__PURE__*/proxyCustomElement(DuetBreadcrumb$1, [1,"duet-breadcrumb",{"theme":[1025],"href":[1025],"icon":[1025],"accessibleLabel":[1,"accessible-label"]}]);
11989
12595
  const DuetBreadcrumbs = /*@__PURE__*/proxyCustomElement(DuetBreadcrumbs$1, [1,"duet-breadcrumbs",{"theme":[1025],"children":[32]}]);
11990
- const DuetButton = /*@__PURE__*/proxyCustomElement(DuetButton$1, [1,"duet-button",{"accessibleLabel":[1,"accessible-label"],"accessibleControls":[1,"accessible-controls"],"accessibleActiveDescendant":[1,"accessible-active-descendant"],"accessibleOwns":[1,"accessible-owns"],"accessibleDescribedBy":[1,"accessible-described-by"],"accessibleExpanded":[4,"accessible-expanded"],"accessiblePressed":[4,"accessible-pressed"],"loading":[4],"variation":[1],"negative":[4],"theme":[1025],"margin":[1],"padding":[1],"wrapping":[1],"expand":[4],"fixed":[4],"disabled":[516],"name":[1],"value":[1],"identifier":[1],"submit":[516],"external":[4],"language":[1],"accessibleLabelExternalDefaults":[1,"accessible-label-external-default"],"accessibleLabelExternal":[1,"accessible-label-external"],"icon":[1],"color":[1],"iconRight":[4,"icon-right"],"iconSize":[1,"icon-size"],"size":[1],"iconOnly":[4,"icon-only"],"url":[513]}]);
12596
+ const DuetButton = /*@__PURE__*/proxyCustomElement(DuetButton$1, [1,"duet-button",{"accessibleLabel":[1,"accessible-label"],"accessibleControls":[1,"accessible-controls"],"accessiblePopup":[1,"accessible-popup"],"accessibleActiveDescendant":[1,"accessible-active-descendant"],"accessibleOwns":[1,"accessible-owns"],"accessibleDescribedBy":[1,"accessible-described-by"],"accessibleExpanded":[4,"accessible-expanded"],"accessiblePressed":[4,"accessible-pressed"],"loading":[4],"variation":[1],"negative":[4],"theme":[1025],"margin":[1],"padding":[1],"centerText":[4,"center-text"],"wrapping":[1],"expand":[4],"fixed":[4],"disabled":[516],"name":[1],"value":[1],"identifier":[1],"submit":[516],"external":[4],"language":[1],"accessibleLabelExternalDefaults":[1,"accessible-label-external-default"],"accessibleLabelExternal":[1,"accessible-label-external"],"icon":[1],"color":[1],"iconRight":[4,"icon-right"],"iconSize":[1,"icon-size"],"size":[1],"iconOnly":[4,"icon-only"],"url":[513]}]);
11991
12597
  const DuetCaption = /*@__PURE__*/proxyCustomElement(DuetCaption$1, [1,"duet-caption",{"theme":[1025],"margin":[1],"selected":[4],"size":[1]}]);
11992
12598
  const DuetCard = /*@__PURE__*/proxyCustomElement(DuetCard$1, [1,"duet-card",{"accessibleLabel":[1,"accessible-label"],"heading":[1],"secondaryHeading":[1,"secondary-heading"],"variation":[1],"collapsible":[4],"open":[1540],"headingLevel":[1,"heading-level"],"icon":[1],"image":[1],"background":[1],"padding":[1],"margin":[1],"theme":[1025],"url":[1]}]);
11993
12599
  const DuetCheckbox = /*@__PURE__*/proxyCustomElement(DuetCheckbox$1, [2,"duet-checkbox",{"accessibleActiveDescendant":[1,"accessible-active-descendant"],"margin":[1],"accessibleControls":[1,"accessible-controls"],"accessibleIndex":[1,"accessible-index"],"accessibleOwns":[1,"accessible-owns"],"accessibleDescribedBy":[1,"accessible-described-by"],"required":[4],"theme":[1025],"disabled":[516],"identifier":[1],"label":[1],"labelHidden":[4,"label-hidden"],"name":[1],"role":[1],"checked":[1540],"value":[1537]}]);
@@ -11997,9 +12603,7 @@ const DuetCollapsible = /*@__PURE__*/proxyCustomElement(DuetCollapsible$1, [1,"d
11997
12603
  const DuetCookieConsent = /*@__PURE__*/proxyCustomElement(DuetCookieConsent$1, [1,"duet-cookie-consent",{"accessibleLabel":[1,"accessible-label"],"theme":[1025]}]);
11998
12604
  const DuetDatePicker = /*@__PURE__*/proxyCustomElement(DuetDatePicker$1, [2,"duet-date-picker",{"theme":[1025],"expand":[4],"name":[1],"identifier":[1],"label":[1],"caption":[1],"margin":[1],"language":[1],"placeholderDefaults":[1,"placeholder-default"],"placeholder":[1],"echoPlaceholder":[1540,"echo-placeholder"],"disabled":[516],"error":[1],"labelHidden":[4,"label-hidden"],"role":[1],"accessibleActiveDescendant":[1,"accessible-active-descendant"],"accessibleControls":[1,"accessible-controls"],"accessibleOwns":[1,"accessible-owns"],"accessibleDescribedBy":[1,"accessible-described-by"],"required":[4],"direction":[1],"tooltip":[1],"tooltipDirection":[1,"tooltip-direction"],"value":[1537],"min":[1],"max":[1],"validity":[1040],"open":[32],"focusedDay":[32],"inputValue":[32]},[[4,"click","handleDocumentClick"]]]);
11999
12605
  const DuetDivider = /*@__PURE__*/proxyCustomElement(DuetDivider$1, [1,"duet-divider",{"theme":[1025],"margin":[1]}]);
12000
- const DuetEditableTable = /*@__PURE__*/proxyCustomElement(DuetEditableTable$1, [1,"duet-editable-table",{"items":[1040],"alignment":[1],"groupsLabelDefaults":[16],"actionLabelDefaults":[16],"groups":[1],"actions":[1],"hideGroups":[4,"hide-table-labels"],"accessibleRole":[1,"accessible-role"],"theme":[1025],"tick":[32]}]);
12001
- const DuetEditableTableButton = /*@__PURE__*/proxyCustomElement(DuetEditableTableButton$1, [2,"duet-editable-table-button",{"theme":[1025],"actions":[16],"uid":[1],"group":[1],"keyName":[1,"key-name"],"isHovering":[32]}]);
12002
- const DuetEditableTableItem = /*@__PURE__*/proxyCustomElement(DuetEditableTableItem$1, [1,"duet-editable-table-item",{"theme":[1025],"actions":[16],"groupId":[1,"group-id"],"alignment":[1],"keyName":[1,"key-name"],"data":[1040],"isHovering":[32]}]);
12606
+ const DuetEditableTable = /*@__PURE__*/proxyCustomElement(DuetEditableTable$1, [6,"duet-editable-table",{"margin":[1],"variation":[1],"sticky":[4],"stickyDistance":[1,"sticky-distance"],"breakpoint":[1],"actions":[1040],"columns":[1040],"rows":[1040],"sortable":[4],"groupId":[1,"group-id"],"theme":[1025],"accessibleRole":[1,"accessible-role"]}]);
12003
12607
  const DuetEmptyState = /*@__PURE__*/proxyCustomElement(DuetEmptyState$1, [1,"duet-empty-state",{"theme":[1025],"icon":[1],"size":[1]}]);
12004
12608
  const DuetFieldset = /*@__PURE__*/proxyCustomElement(DuetFieldset$1, [1,"duet-fieldset",{"theme":[1025],"margin":[1],"caption":[1],"label":[1],"error":[1],"labelHidden":[4,"label-hidden"],"hasTooltip":[32]}]);
12005
12609
  const DuetFooter = /*@__PURE__*/proxyCustomElement(DuetFooter$1, [1,"duet-footer",{"theme":[1025],"variation":[1],"margin":[1],"logoHref":[1,"logo-href"],"language":[1025],"items":[8],"accessibleLabelExternalDefaults":[1,"accessible-label-external-default"],"accessibleLabelExternal":[1,"accessible-label-external"],"menu":[8],"processedItems":[32],"processedMenu":[32]}]);
@@ -12020,13 +12624,15 @@ const DuetModal = /*@__PURE__*/proxyCustomElement(DuetModal$1, [1,"duet-modal",{
12020
12624
  const DuetNotification = /*@__PURE__*/proxyCustomElement(DuetNotification$1, [1,"duet-notification",{"language":[1],"accessibleLabelUnreadDefaults":[16],"accessibleLabelUnread":[1,"accessible-label-unread"],"url":[1],"date":[1],"highlight":[4],"external":[4],"theme":[1025]}]);
12021
12625
  const DuetNotificationDrawer = /*@__PURE__*/proxyCustomElement(DuetNotificationDrawer$1, [1,"duet-notification-drawer",{"icon":[1],"label":[1],"language":[1],"accessibleLabelNotificationsDefaults":[1,"accessible-label-notification-default"],"accessibleLabelNotifications":[1,"accessible-label-notifications"],"badge":[4],"theme":[1025],"direction":[1],"isOpen":[32],"hasNotifications":[32]},[[6,"focus","handleClickFocusOutside"],[6,"click","handleClickFocusOutside"]]]);
12022
12626
  const DuetNumberInput = /*@__PURE__*/proxyCustomElement(DuetNumberInput$1, [2,"duet-number-input",{"language":[1025],"locale":[1],"unit":[1],"accessibleActiveDescendant":[1,"accessible-active-descendant"],"accessibleControls":[1,"accessible-controls"],"accessibleOwns":[1,"accessible-owns"],"accessibleDescribedBy":[1,"accessible-described-by"],"accessibleLiveDefaults":[1,"accessible-live-default"],"accessibleLive":[1,"accessible-live"],"accessibleLiveEnabled":[4,"accessible-live-enabled"],"accessibleAddDefaults":[1,"accessible-add-default"],"accessibleAdd":[1,"accessible-add"],"accessibleSubtractDefaults":[1,"accessible-subtract-defaults"],"accessibleSubtract":[1,"accessible-subtract"],"theme":[1025],"margin":[1],"expand":[4],"identifier":[1],"min":[2],"labelDefaults":[1,"label-default"],"label":[1],"labelHidden":[4,"label-hidden"],"max":[2],"name":[1],"error":[1],"tooltip":[1],"step":[2],"rounding":[4],"role":[1],"disabled":[516],"required":[4],"value":[1025],"focusedValue":[32]}]);
12627
+ const DuetPagination = /*@__PURE__*/proxyCustomElement(DuetPagination$1, [1,"duet-pagination",{"theme":[1025],"jumpString":[1,"jump-string"],"variation":[1],"accessibleLabelsDefaults":[16],"accessibleLabels":[16],"take":[1026],"visibleItems":[1026,"visible-items"],"total":[1026],"ariaControls":[1,"accessible-controls"],"current":[1026],"numbersStore":[32],"totalPages":[32],"internalSectionIndex":[32]}]);
12023
12628
  const DuetParagraph = /*@__PURE__*/proxyCustomElement(DuetParagraph$1, [1,"duet-paragraph",{"theme":[1025],"margin":[1],"size":[1],"weight":[1],"variation":[1],"color":[1]}]);
12024
12629
  const DuetProgress = /*@__PURE__*/proxyCustomElement(DuetProgress$1, [0,"duet-progress",{"accessibleDescribedBy":[1,"accessible-described-by"],"accessibleLabel":[1,"accessible-label"],"accessibleLabelUploadDefaults":[1,"accessible-label-upload-defaults"],"accessibleLabelUpload":[1,"accessible-label-upload"],"progress":[1538],"caption":[1],"height":[1],"theme":[1025]}]);
12025
12630
  const DuetRadio = /*@__PURE__*/proxyCustomElement(DuetRadio$1, [2,"duet-radio",{"accessibleActiveDescendant":[1,"accessible-active-descendant"],"accessibleIndex":[1,"accessible-index"],"margin":[1],"accessibleControls":[1,"accessible-controls"],"accessibleOwns":[1,"accessible-owns"],"accessibleDescribedBy":[1,"accessible-described-by"],"theme":[1025],"disabled":[516],"required":[4],"blockEvents":[4,"block-events"],"identifier":[1],"label":[1],"name":[1],"role":[1],"groupDisabled":[4,"group-disabled"],"groupDirection":[1,"group-direction"],"groupResponsive":[4,"group-responsive"],"checked":[1540],"value":[1537]}]);
12026
12631
  const DuetRadioGroup = /*@__PURE__*/proxyCustomElement(DuetRadioGroup$1, [6,"duet-radio-group",{"direction":[1],"margin":[1],"theme":[1025],"error":[1],"tooltip":[1],"tooltipDirection":[1,"tooltip-direction"],"name":[1],"label":[1],"labelHidden":[4,"label-hidden"],"caption":[1],"responsive":[4],"value":[1537],"disabled":[4]}]);
12027
12632
  const DuetRangeSlider = /*@__PURE__*/proxyCustomElement(DuetRangeSlider$1, [2,"duet-range-slider",{"theme":[1025],"margin":[1],"expand":[4],"identifier":[1],"name":[1],"required":[4],"disabled":[516],"accessibleActiveDescendant":[1,"accessible-active-descendant"],"accessibleControls":[1,"accessible-controls"],"accessibleOwns":[1,"accessible-owns"],"accessibleDescribedBy":[1,"accessible-described-by"],"min":[2],"label":[1],"labelHidden":[4,"label-hidden"],"unit":[1],"max":[2],"step":[2],"locale":[1],"value":[1026],"debounce":[2]}]);
12633
+ const DuetRangeStepper = /*@__PURE__*/proxyCustomElement(DuetRangeStepper$1, [1,"duet-range-stepper",{"theme":[1025],"stepIndex":[1026,"step-index"],"stepSize":[2,"step-size"],"total":[2],"ariaLabelsDefaults":[16],"ariaLabels":[16],"ariaControls":[1,"accessible-controls"]}]);
12028
12634
  const DuetScrollable = /*@__PURE__*/proxyCustomElement(DuetScrollable$1, [1,"duet-scrollable",{"theme":[1025],"identifier":[1],"selected":[1026],"tablistAtStart":[32],"isTabContentSmallerThanWrapper":[32],"tablistAtEnd":[32],"childrenData":[32]}]);
12029
- const DuetSelect = /*@__PURE__*/proxyCustomElement(DuetSelect$1, [2,"duet-select",{"accessibleActiveDescendant":[1,"accessible-active-descendant"],"accessibleDescribedBy":[1,"accessible-described-by"],"margin":[1],"accessibleControls":[1,"accessible-controls"],"accessibleOwns":[1,"accessible-owns"],"error":[1],"expand":[4],"value":[1537],"theme":[1025],"labelHidden":[4,"label-hidden"],"identifier":[1],"name":[1],"placeholder":[1],"caption":[1],"echoPlaceholder":[4,"echo-placeholder"],"items":[1],"disabled":[516],"required":[4],"label":[1],"role":[1],"tooltip":[1],"tooltipDirection":[1,"tooltip-direction"],"processedItems":[32]}]);
12635
+ const DuetSelect = /*@__PURE__*/proxyCustomElement(DuetSelect$1, [2,"duet-select",{"variation":[1],"accessibleActiveDescendant":[1,"accessible-active-descendant"],"accessibleDescribedBy":[1,"accessible-described-by"],"margin":[1],"accessibleControls":[1,"accessible-controls"],"accessibleOwns":[1,"accessible-owns"],"error":[1],"expand":[4],"value":[1537],"theme":[1025],"labelHidden":[4,"label-hidden"],"identifier":[1],"name":[1],"placeholder":[1],"caption":[1],"echoPlaceholder":[4,"echo-placeholder"],"items":[1],"disabled":[516],"required":[4],"label":[1],"role":[1],"tooltip":[1],"tooltipDirection":[1,"tooltip-direction"],"processedItems":[32]}]);
12030
12636
  const DuetSpacer = /*@__PURE__*/proxyCustomElement(DuetSpacer$1, [1,"duet-spacer",{"size":[1],"direction":[1],"breakpoint":[1]}]);
12031
12637
  const DuetSpinner = /*@__PURE__*/proxyCustomElement(DuetSpinner$1, [1,"duet-spinner",{"accessibleLabel":[1,"accessible-label"],"color":[1],"size":[1],"theme":[1025]}]);
12032
12638
  const DuetStep = /*@__PURE__*/proxyCustomElement(DuetStep$1, [6,"duet-step",{"theme":[1025],"heading":[1],"headingLevel":[1,"heading-level"],"stepIndex":[2,"step-index"],"state":[1],"roundedTop":[4,"rounded-top"],"roundedBottom":[4,"rounded-bottom"]}]);
@@ -12038,13 +12644,14 @@ const DuetTextarea = /*@__PURE__*/proxyCustomElement(DuetTextarea$1, [2,"duet-te
12038
12644
  const DuetToggle = /*@__PURE__*/proxyCustomElement(DuetToggle$1, [2,"duet-toggle",{"theme":[1025],"margin":[1],"accessibleActiveDescendant":[1,"accessible-active-descendant"],"accessibleControls":[1,"accessible-controls"],"accessibleOwns":[1,"accessible-owns"],"accessibleDescribedBy":[1,"accessible-described-by"],"label":[1],"required":[4],"disabled":[516],"checked":[1540],"value":[1537],"identifier":[1],"name":[1],"role":[1]}]);
12039
12645
  const DuetTooltip = /*@__PURE__*/proxyCustomElement(DuetTooltip$1, [1,"duet-tooltip",{"theme":[1025],"language":[1025],"accessibleLabelDefault":[1,"accessible-label-default"],"accessibleLabel":[1,"accessible-label"],"accessibleInputLabel":[1,"accessible-input-label"],"accessibleCloseLabelDefault":[1,"accessible-close-label-default"],"accessibleCloseLabel":[1,"accessible-close-label"],"label":[1],"breakpoint":[1],"direction":[1],"positionVertical":[513,"position-vertical"],"positionHorizontal":[513,"position-horizontal"],"active":[1540],"openDown":[32]},[[9,"scroll","onScroll"],[4,"click","handleDocumentClick"]]]);
12040
12646
  const DuetTray = /*@__PURE__*/proxyCustomElement(DuetTray$1, [1,"duet-tray",{"language":[1025],"accessibleCloseLabelDefaults":[1,"accessible-close-label-default"],"accessibleCloseLabel":[1,"accessible-close-label"],"accessibleOpenLabelDefaults":[1,"accessible-open-label-default"],"accessibleOpenLabel":[1,"accessible-open-label"],"theme":[1025],"active":[516],"autoHide":[4,"auto-hide"],"responsive":[4],"expanded":[32],"hiddenState":[32]},[[9,"scroll","getFrame"],[16,"click","handleBodyClick"]]]);
12041
- const DuetUpload = /*@__PURE__*/proxyCustomElement(DuetUpload$1, [1,"duet-upload",{"accessibleActiveDescendant":[1,"accessible-active-descendant"],"accessibleDescribedBy":[1,"accessible-described-by"],"accessibleControls":[1,"accessible-controls"],"accessibleOwns":[1,"accessible-owns"],"external":[4],"hideButton":[4,"hide-upload-button"],"actions":[1],"uri":[1],"showLinks":[4,"show-links"],"caption":[1],"statusLabelDefaults":[1,"status-label-default"],"statusMessageLabel":[1,"status-message-label"],"buttonLabelDefaults":[1,"button-label-default"],"buttonLabel":[1,"button-label"],"accessibleButtonLabel":[1,"accessible-button-label"],"theme":[1025],"disabled":[516],"identifier":[1],"margin":[1],"required":[4],"groups":[1],"alignment":[1],"hideGroups":[4,"hide-table-labels"],"files":[1040],"valid":[1540],"labelDefaults":[1,"label-default"],"label":[1],"descriptionDefaults":[1,"description-default"],"description":[1],"fileListEmptyDefaults":[1,"list-empty-default"],"fileListEmpty":[1,"file-list-empty"],"error":[1],"name":[1],"maxBytes":[2,"max-bytes"],"maxBytesTotal":[2,"max-bytes-total"],"maxFiles":[2,"max-files"],"allowedExtensions":[1,"allowed-extensions"],"allowedMimetypes":[1,"allowed-mimetypes"],"multiple":[4],"limitSelection":[4,"limit-selection"],"value":[1025],"tick":[32]}]);
12647
+ const DuetUpload = /*@__PURE__*/proxyCustomElement(DuetUpload$1, [1,"duet-upload",{"accessibleActiveDescendant":[1,"accessible-active-descendant"],"accessibleDescribedBy":[1,"accessible-described-by"],"accessibleControls":[1,"accessible-controls"],"accessibleOwns":[1,"accessible-owns"],"external":[4],"hideButton":[4,"hide-upload-button"],"actions":[16],"uri":[1],"showLinks":[4,"show-links"],"caption":[1],"statusLabelDefaults":[1,"status-label-default"],"statusMessageLabel":[1,"status-message-label"],"buttonLabelDefaults":[1,"button-label-default"],"buttonLabel":[1,"button-label"],"accessibleButtonLabel":[1,"accessible-button-label"],"theme":[1025],"disabled":[516],"identifier":[1],"margin":[1],"required":[4],"alignment":[1],"hideGroups":[4,"hide-table-labels"],"files":[1040],"valid":[1540],"labelDefaults":[1,"label-default"],"label":[1],"descriptionDefaults":[1,"description-default"],"description":[1],"fileListEmptyDefaults":[1,"list-empty-default"],"fileListEmpty":[1,"file-list-empty"],"error":[1],"name":[1],"maxBytes":[2,"max-bytes"],"maxBytesTotal":[2,"max-bytes-total"],"maxFiles":[2,"max-files"],"allowedExtensions":[1,"allowed-extensions"],"allowedMimetypes":[1,"allowed-mimetypes"],"multiple":[4],"limitSelection":[4,"limit-selection"],"value":[1025],"groups":[16],"tick":[32]}]);
12042
12648
  const DuetUploadAriaStatus = /*@__PURE__*/proxyCustomElement(DuetUploadAriaStatus$1, [1,"duet-upload-aria-status",{"statusMessageLabel":[16],"accessibleAriaLive":[1,"accessible-aria-live"],"valid":[2],"total":[2],"invalid":[2],"inprogress":[2],"statusMessage":[32]}]);
12043
12649
  const DuetVisuallyHidden = /*@__PURE__*/proxyCustomElement(DuetVisuallyHidden$1, [1,"duet-visually-hidden"]);
12044
12650
  const defineCustomElements = (opts) => {
12045
12651
  if (typeof customElements !== 'undefined') {
12046
12652
  [
12047
- DuetAlert,
12653
+ DuetActionButton,
12654
+ DuetAlert,
12048
12655
  DuetBadge,
12049
12656
  DuetBreadcrumb,
12050
12657
  DuetBreadcrumbs,
@@ -12059,8 +12666,6 @@ const defineCustomElements = (opts) => {
12059
12666
  DuetDatePicker,
12060
12667
  DuetDivider,
12061
12668
  DuetEditableTable,
12062
- DuetEditableTableButton,
12063
- DuetEditableTableItem,
12064
12669
  DuetEmptyState,
12065
12670
  DuetFieldset,
12066
12671
  DuetFooter,
@@ -12081,11 +12686,13 @@ const defineCustomElements = (opts) => {
12081
12686
  DuetNotification,
12082
12687
  DuetNotificationDrawer,
12083
12688
  DuetNumberInput,
12689
+ DuetPagination,
12084
12690
  DuetParagraph,
12085
12691
  DuetProgress,
12086
12692
  DuetRadio,
12087
12693
  DuetRadioGroup,
12088
12694
  DuetRangeSlider,
12695
+ DuetRangeStepper,
12089
12696
  DuetScrollable,
12090
12697
  DuetSelect,
12091
12698
  DuetSpacer,
@@ -12502,4 +13109,4 @@ const shadowCss = /*#__PURE__*/Object.freeze({
12502
13109
  scopeCss: scopeCss
12503
13110
  });
12504
13111
 
12505
- export { DuetAlert, DuetBadge, DuetBreadcrumb, DuetBreadcrumbs, DuetButton, DuetCaption, DuetCard, DuetCheckbox, DuetChoice, DuetChoiceGroup, DuetCollapsible, DuetCookieConsent, DuetDatePicker, DuetDivider, DuetEditableTable, DuetEditableTableButton, DuetEditableTableItem, DuetEmptyState, DuetFieldset, DuetFooter, DuetGrid, DuetGridItem, DuetHeader, DuetHeading, DuetHero, DuetIcon, DuetInput, DuetLabel, DuetLayout, DuetLink, DuetList, DuetListItem, DuetLogo, DuetModal, DuetNotification, DuetNotificationDrawer, DuetNumberInput, DuetParagraph, DuetProgress, DuetRadio, DuetRadioGroup, DuetRangeSlider, DuetScrollable, DuetSelect, DuetSpacer, DuetSpinner, DuetStep, DuetStepper, DuetTab, DuetTabGroup, DuetTable, DuetTextarea, DuetToggle, DuetTooltip, DuetTray, DuetUpload, DuetUploadAriaStatus, DuetVisuallyHidden, defineCustomElements, setAssetPath, setPlatformOptions };
13112
+ export { DuetActionButton, DuetAlert, DuetBadge, DuetBreadcrumb, DuetBreadcrumbs, DuetButton, DuetCaption, DuetCard, DuetCheckbox, DuetChoice, DuetChoiceGroup, DuetCollapsible, DuetCookieConsent, DuetDatePicker, DuetDivider, DuetEditableTable, DuetEmptyState, DuetFieldset, DuetFooter, DuetGrid, DuetGridItem, DuetHeader, DuetHeading, DuetHero, DuetIcon, DuetInput, DuetLabel, DuetLayout, DuetLink, DuetList, DuetListItem, DuetLogo, DuetModal, DuetNotification, DuetNotificationDrawer, DuetNumberInput, DuetPagination, DuetParagraph, DuetProgress, DuetRadio, DuetRadioGroup, DuetRangeSlider, DuetRangeStepper, DuetScrollable, DuetSelect, DuetSpacer, DuetSpinner, DuetStep, DuetStepper, DuetTab, DuetTabGroup, DuetTable, DuetTextarea, DuetToggle, DuetTooltip, DuetTray, DuetUpload, DuetUploadAriaStatus, DuetVisuallyHidden, defineCustomElements, setAssetPath, setPlatformOptions };