@duetds/components 6.5.3 → 6.6.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 (510) hide show
  1. package/hydrate/index.js +170 -21
  2. package/lib/cjs/duet-action-button.cjs.entry.js +1 -1
  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 +1 -1
  8. package/lib/cjs/duet-caption_4.cjs.entry.js +4 -2
  9. package/lib/cjs/duet-card.cjs.entry.js +1 -1
  10. package/lib/cjs/duet-checkbox.cjs.entry.js +1 -1
  11. package/lib/cjs/duet-checkmark.cjs.entry.js +38 -0
  12. package/lib/cjs/duet-choice_2.cjs.entry.js +8 -2
  13. package/lib/cjs/duet-collapsible.cjs.entry.js +1 -1
  14. package/lib/cjs/duet-combobox.cjs.entry.js +1 -1
  15. package/lib/cjs/duet-cookie-consent.cjs.entry.js +1 -1
  16. package/lib/cjs/duet-date-picker.cjs.entry.js +2 -2
  17. package/lib/cjs/duet-divider_2.cjs.entry.js +1 -1
  18. package/lib/cjs/duet-editable-table_3.cjs.entry.js +2 -2
  19. package/lib/cjs/duet-empty-state.cjs.entry.js +1 -1
  20. package/lib/cjs/duet-fieldset.cjs.entry.js +1 -1
  21. package/lib/cjs/duet-footer.cjs.entry.js +1 -1
  22. package/lib/cjs/duet-grid_2.cjs.entry.js +1 -1
  23. package/lib/cjs/duet-header_2.cjs.entry.js +1 -1
  24. package/lib/cjs/duet-hero.cjs.entry.js +1 -1
  25. package/lib/cjs/duet-icon.cjs.entry.js +4 -2
  26. package/lib/cjs/duet-input_2.cjs.entry.js +1 -1
  27. package/lib/cjs/duet-layout.cjs.entry.js +1 -1
  28. package/lib/cjs/duet-list_2.cjs.entry.js +1 -1
  29. package/lib/cjs/duet-menu-bar-button.cjs.entry.js +1 -1
  30. package/lib/cjs/duet-menu-bar-dropdown-link.cjs.entry.js +1 -1
  31. package/lib/cjs/duet-menu-bar-dropdown.cjs.entry.js +1 -1
  32. package/lib/cjs/duet-menu-bar-link.cjs.entry.js +1 -1
  33. package/lib/cjs/duet-menu-bar.cjs.entry.js +1 -1
  34. package/lib/cjs/duet-modal.cjs.entry.js +2 -2
  35. package/lib/cjs/duet-multiselect.cjs.entry.js +1 -1
  36. package/lib/cjs/duet-nav.cjs.entry.js +2 -2
  37. package/lib/cjs/duet-notification_2.cjs.entry.js +1 -1
  38. package/lib/cjs/duet-number-input.cjs.entry.js +1 -1
  39. package/lib/cjs/duet-page-heading.cjs.entry.js +41 -0
  40. package/lib/cjs/duet-pagination_2.cjs.entry.js +11 -5
  41. package/lib/cjs/duet-progress.cjs.entry.js +1 -1
  42. package/lib/cjs/duet-radio_2.cjs.entry.js +1 -1
  43. package/lib/cjs/duet-range-slider.cjs.entry.js +1 -1
  44. package/lib/cjs/duet-scrollable_3.cjs.entry.js +33 -7
  45. package/lib/cjs/duet-section-layout.cjs.entry.js +1 -1
  46. package/lib/cjs/duet-select.cjs.entry.js +1 -1
  47. package/lib/cjs/duet-slideout-lang.cjs.entry.js +1 -1
  48. package/lib/cjs/duet-slideout-link.cjs.entry.js +1 -1
  49. package/lib/cjs/duet-slideout-panel-dropdown.cjs.entry.js +1 -1
  50. package/lib/cjs/duet-slideout-panel.cjs.entry.js +16 -5
  51. package/lib/cjs/duet-slideout.cjs.entry.js +3 -3
  52. package/lib/cjs/duet-step_2.cjs.entry.js +1 -1
  53. package/lib/cjs/duet-submenu-bar-dropdown-link.cjs.entry.js +1 -1
  54. package/lib/cjs/duet-submenu-bar-dropdown.cjs.entry.js +1 -1
  55. package/lib/cjs/duet-submenu-bar-link.cjs.entry.js +1 -1
  56. package/lib/cjs/duet-submenu-bar.cjs.entry.js +1 -1
  57. package/lib/cjs/duet-textarea.cjs.entry.js +1 -1
  58. package/lib/cjs/duet-toggle.cjs.entry.js +1 -1
  59. package/lib/cjs/duet-toolbar-dropdown-link.cjs.entry.js +1 -1
  60. package/lib/cjs/duet-toolbar-dropdown.cjs.entry.js +1 -1
  61. package/lib/cjs/duet-toolbar-link.cjs.entry.js +1 -1
  62. package/lib/cjs/duet-toolbar.cjs.entry.js +1 -1
  63. package/lib/cjs/duet-tooltip.cjs.entry.js +1 -1
  64. package/lib/cjs/duet-tray.cjs.entry.js +1 -1
  65. package/lib/cjs/duet-upload-aria-status.cjs.entry.js +1 -1
  66. package/lib/cjs/duet-visually-hidden.cjs.entry.js +1 -1
  67. package/lib/cjs/duet.cjs.js +2 -2
  68. package/lib/cjs/{focus-utils-ed2dad1b.js → focus-utils-995144a1.js} +1 -1
  69. package/lib/cjs/{index-9ee8fef8.js → index-7924dfe2.js} +1 -1
  70. package/lib/cjs/loader.cjs.js +2 -2
  71. package/lib/collection/collection-manifest.json +2 -0
  72. package/lib/collection/components/duet-choice/duet-checkmark.css +74 -0
  73. package/lib/collection/components/duet-choice/duet-checkmark.js +142 -0
  74. package/lib/collection/components/duet-choice/duet-choice.js +22 -0
  75. package/lib/collection/components/duet-icon/duet-icon.css +121 -2
  76. package/lib/collection/components/duet-icon/duet-icon.js +20 -0
  77. package/lib/collection/components/duet-link/duet-link.css +37 -0
  78. package/lib/collection/components/duet-link/duet-link.js +20 -0
  79. package/lib/collection/components/duet-nav/duet-nav.js +6 -1
  80. package/lib/collection/components/duet-page-heading/duet-page-heading.css +205 -0
  81. package/lib/collection/components/duet-page-heading/duet-page-heading.js +113 -0
  82. package/lib/collection/components/duet-pagination/duet-pagination.js +10 -4
  83. package/lib/collection/components/duet-slideout/duet-slideout.css +0 -3
  84. package/lib/collection/components/duet-slideout-panel/duet-slideout-panel.css +1 -8
  85. package/lib/collection/components/duet-slideout-panel/duet-slideout-panel.js +35 -2
  86. package/lib/collection/components/duet-tab/duet-tab.js +18 -0
  87. package/lib/collection/components/duet-tab-group/duet-tab-group.css +140 -0
  88. package/lib/collection/components/duet-tab-group/duet-tab-group.js +31 -6
  89. package/lib/collection/components/duet-table/duet-table.js +1 -1
  90. package/lib/dist-custom-elements/duet-action-button.js +1 -1
  91. package/lib/dist-custom-elements/duet-alert.js +1 -1
  92. package/lib/dist-custom-elements/duet-badge.js +1 -1
  93. package/lib/dist-custom-elements/duet-breadcrumb.js +2 -2
  94. package/lib/dist-custom-elements/duet-breadcrumbs.js +2 -2
  95. package/lib/dist-custom-elements/duet-button.js +1 -1
  96. package/lib/dist-custom-elements/duet-caption.js +1 -1
  97. package/lib/dist-custom-elements/duet-card.js +3 -3
  98. package/lib/dist-custom-elements/duet-checkbox.js +1 -1
  99. package/lib/dist-custom-elements/duet-checkmark.d.ts +11 -0
  100. package/lib/dist-custom-elements/duet-checkmark.js +9 -0
  101. package/lib/dist-custom-elements/duet-choice-group.js +6 -6
  102. package/lib/dist-custom-elements/duet-choice.js +13 -6
  103. package/lib/dist-custom-elements/duet-collapsible.js +2 -2
  104. package/lib/dist-custom-elements/duet-combobox.js +2 -2
  105. package/lib/dist-custom-elements/duet-cookie-consent.js +6 -6
  106. package/lib/dist-custom-elements/duet-date-picker.js +10 -10
  107. package/lib/dist-custom-elements/duet-divider.js +1 -1
  108. package/lib/dist-custom-elements/duet-editable-table.js +1 -1
  109. package/lib/dist-custom-elements/duet-empty-state.js +1 -1
  110. package/lib/dist-custom-elements/duet-fieldset.js +1 -1
  111. package/lib/dist-custom-elements/duet-footer.js +4 -4
  112. package/lib/dist-custom-elements/duet-grid-item.js +1 -1
  113. package/lib/dist-custom-elements/duet-grid.js +1 -1
  114. package/lib/dist-custom-elements/duet-header.js +8 -8
  115. package/lib/dist-custom-elements/duet-heading.js +1 -1
  116. package/lib/dist-custom-elements/duet-hero.js +9 -9
  117. package/lib/dist-custom-elements/duet-icon.js +1 -1
  118. package/lib/dist-custom-elements/duet-input.js +1 -1
  119. package/lib/dist-custom-elements/duet-label.js +1 -1
  120. package/lib/dist-custom-elements/duet-layout.js +1 -1
  121. package/lib/dist-custom-elements/duet-link.js +1 -1
  122. package/lib/dist-custom-elements/duet-list-item.js +1 -1
  123. package/lib/dist-custom-elements/duet-list.js +1 -1
  124. package/lib/dist-custom-elements/duet-logo.js +1 -1
  125. package/lib/dist-custom-elements/duet-menu-bar-button.js +2 -2
  126. package/lib/dist-custom-elements/duet-menu-bar-dropdown-link.js +2 -2
  127. package/lib/dist-custom-elements/duet-menu-bar-dropdown.js +2 -2
  128. package/lib/dist-custom-elements/duet-menu-bar-link.js +2 -2
  129. package/lib/dist-custom-elements/duet-menu-bar.js +2 -2
  130. package/lib/dist-custom-elements/duet-modal.js +7 -7
  131. package/lib/dist-custom-elements/duet-multiselect.js +8 -8
  132. package/lib/dist-custom-elements/duet-nav.js +2 -2
  133. package/lib/dist-custom-elements/duet-notification-drawer.js +4 -4
  134. package/lib/dist-custom-elements/duet-notification.js +2 -2
  135. package/lib/dist-custom-elements/duet-number-input.js +9 -9
  136. package/lib/dist-custom-elements/duet-page-heading.d.ts +11 -0
  137. package/lib/dist-custom-elements/duet-page-heading.js +65 -0
  138. package/lib/dist-custom-elements/duet-pagination.js +17 -11
  139. package/lib/dist-custom-elements/duet-paragraph.js +1 -1
  140. package/lib/dist-custom-elements/duet-progress.js +1 -1
  141. package/lib/dist-custom-elements/duet-radio-group.js +6 -6
  142. package/lib/dist-custom-elements/duet-radio.js +1 -1
  143. package/lib/dist-custom-elements/duet-range-slider.js +2 -2
  144. package/lib/dist-custom-elements/duet-range-stepper.js +4 -4
  145. package/lib/dist-custom-elements/duet-scrollable.js +1 -1
  146. package/lib/dist-custom-elements/duet-section-layout.js +1 -1
  147. package/lib/dist-custom-elements/duet-select.js +1 -1
  148. package/lib/dist-custom-elements/duet-slideout-lang.js +3 -3
  149. package/lib/dist-custom-elements/duet-slideout-link.js +2 -2
  150. package/lib/dist-custom-elements/duet-slideout-panel-dropdown.js +2 -2
  151. package/lib/dist-custom-elements/duet-slideout-panel.js +16 -5
  152. package/lib/dist-custom-elements/duet-slideout.js +3 -3
  153. package/lib/dist-custom-elements/duet-spacer.js +1 -1
  154. package/lib/dist-custom-elements/duet-spinner.js +1 -1
  155. package/lib/dist-custom-elements/duet-step.js +4 -4
  156. package/lib/dist-custom-elements/duet-stepper.js +2 -2
  157. package/lib/dist-custom-elements/duet-submenu-bar-dropdown-link.js +2 -2
  158. package/lib/dist-custom-elements/duet-submenu-bar-dropdown.js +2 -2
  159. package/lib/dist-custom-elements/duet-submenu-bar-link.js +2 -2
  160. package/lib/dist-custom-elements/duet-submenu-bar.js +2 -2
  161. package/lib/dist-custom-elements/duet-tab-group.js +46 -15
  162. package/lib/dist-custom-elements/duet-tab.js +3 -1
  163. package/lib/dist-custom-elements/duet-table.js +1 -1
  164. package/lib/dist-custom-elements/duet-textarea.js +8 -8
  165. package/lib/dist-custom-elements/duet-toggle.js +2 -2
  166. package/lib/dist-custom-elements/duet-toolbar-dropdown-link.js +2 -2
  167. package/lib/dist-custom-elements/duet-toolbar-dropdown.js +2 -2
  168. package/lib/dist-custom-elements/duet-toolbar-link.js +2 -2
  169. package/lib/dist-custom-elements/duet-toolbar.js +1 -1
  170. package/lib/dist-custom-elements/duet-tooltip.js +1 -1
  171. package/lib/dist-custom-elements/duet-tray.js +3 -3
  172. package/lib/dist-custom-elements/duet-upload-aria-status.js +1 -1
  173. package/lib/dist-custom-elements/duet-upload.js +18 -18
  174. package/lib/dist-custom-elements/duet-visually-hidden.js +1 -1
  175. package/lib/dist-custom-elements/index.d.ts +2 -0
  176. package/lib/dist-custom-elements/index.js +3 -1
  177. package/lib/dist-custom-elements/{p-e41dcc90.js → p-090c4f84.js} +1 -1
  178. package/lib/dist-custom-elements/{p-1c1d12e6.js → p-0b3c5fd3.js} +4 -4
  179. package/lib/dist-custom-elements/{p-c8062b13.js → p-0b46cf7c.js} +1 -1
  180. package/lib/dist-custom-elements/{p-c4833a6d.js → p-1b40f099.js} +2 -2
  181. package/lib/dist-custom-elements/{p-4385956a.js → p-1edc6268.js} +1 -1
  182. package/lib/dist-custom-elements/{p-b1567b3c.js → p-25e3ecf6.js} +1 -1
  183. package/lib/dist-custom-elements/{p-6fc347ac.js → p-2bed378b.js} +1 -1
  184. package/lib/dist-custom-elements/{p-2cc693bd.js → p-2e8d4cbb.js} +3 -3
  185. package/lib/dist-custom-elements/{p-a9df186e.js → p-31869282.js} +2 -2
  186. package/lib/dist-custom-elements/{p-fdfff09b.js → p-47c90993.js} +1 -1
  187. package/lib/dist-custom-elements/{p-65ff709e.js → p-4da5814e.js} +7 -4
  188. package/lib/dist-custom-elements/{p-12b2209e.js → p-4f601182.js} +2 -2
  189. package/lib/dist-custom-elements/{p-19f6ccfd.js → p-505b1084.js} +2 -2
  190. package/lib/dist-custom-elements/{p-f0e97570.js → p-5243162f.js} +1 -1
  191. package/lib/dist-custom-elements/{p-2973295e.js → p-58d5e801.js} +1 -1
  192. package/lib/dist-custom-elements/{p-2799f459.js → p-5bd12ce0.js} +2 -2
  193. package/lib/dist-custom-elements/{p-0f583b14.js → p-62024326.js} +1 -1
  194. package/lib/dist-custom-elements/{p-47157a1e.js → p-73fbb616.js} +1 -1
  195. package/lib/dist-custom-elements/{p-a3118d10.js → p-7cd9c98d.js} +1 -1
  196. package/lib/dist-custom-elements/{p-fd3b1d69.js → p-7fdcbaf8.js} +8 -8
  197. package/lib/dist-custom-elements/p-83dc78d3.js +186 -0
  198. package/lib/dist-custom-elements/{p-b33885be.js → p-94317ac7.js} +1 -1
  199. package/lib/dist-custom-elements/{p-3f4b8d49.js → p-9aaafcd5.js} +6 -6
  200. package/lib/dist-custom-elements/{p-f51c6f0d.js → p-a0db949c.js} +5 -5
  201. package/lib/dist-custom-elements/{p-51525197.js → p-c1c93be7.js} +7 -7
  202. package/lib/dist-custom-elements/{p-e9433706.js → p-c1eea28e.js} +1 -1
  203. package/lib/dist-custom-elements/{p-c58ed6c1.js → p-d2842398.js} +1 -1
  204. package/lib/dist-custom-elements/{p-29ac3d37.js → p-dab5118b.js} +1 -1
  205. package/lib/dist-custom-elements/p-db1a354c.js +54 -0
  206. package/lib/dist-custom-elements/{p-637de545.js → p-dc195b26.js} +3 -3
  207. package/lib/dist-custom-elements/{p-018af97c.js → p-ee73ac71.js} +1 -1
  208. package/lib/dist-custom-elements/{p-70525432.js → p-f3d819f9.js} +2 -2
  209. package/lib/duet/duet.esm.js +1 -1
  210. package/lib/duet/duet.js +1 -1
  211. package/lib/duet/p-0ae5fcca.entry.js +4 -0
  212. package/lib/duet/{p-7e39a550.system.entry.js → p-0f74b52f.system.entry.js} +1 -1
  213. package/lib/duet/{p-15910757.system.entry.js → p-1153165c.system.entry.js} +1 -1
  214. package/lib/duet/{p-ee4e7bff.system.entry.js → p-123a086a.system.entry.js} +1 -1
  215. package/lib/duet/{p-f8bdcad4.entry.js → p-13177687.entry.js} +1 -1
  216. package/lib/duet/{p-b20bff64.entry.js → p-1490ab5a.entry.js} +1 -1
  217. package/lib/duet/{p-df40670a.system.entry.js → p-16172210.system.entry.js} +1 -1
  218. package/lib/duet/p-1908e8bc.system.entry.js +4 -0
  219. package/lib/duet/{p-d57020ab.entry.js → p-1bf30e42.entry.js} +1 -1
  220. package/lib/duet/{p-f58e2c75.system.entry.js → p-1ff8518c.system.entry.js} +1 -1
  221. package/lib/duet/{p-dfe588e8.system.entry.js → p-20e0e96a.system.entry.js} +1 -1
  222. package/lib/duet/{p-bbc717af.entry.js → p-21a8e0eb.entry.js} +1 -1
  223. package/lib/duet/{p-af8dbf72.entry.js → p-221ca56a.entry.js} +1 -1
  224. package/lib/duet/{p-a4054eae.entry.js → p-22d0724c.entry.js} +1 -1
  225. package/lib/duet/p-23a53ae7.entry.js +4 -0
  226. package/lib/duet/{p-ca5373cf.entry.js → p-24179e4c.entry.js} +1 -1
  227. package/lib/duet/p-28fc49de.js +4 -0
  228. package/lib/duet/{p-e0c48a7d.entry.js → p-2a48131b.entry.js} +1 -1
  229. package/lib/duet/{p-a7ec9aa4.system.js → p-2a7f92fa.system.js} +1 -1
  230. package/lib/duet/{p-0eed7e9d.entry.js → p-2cd36122.entry.js} +1 -1
  231. package/lib/duet/{p-12014f2b.system.entry.js → p-2dc966c6.system.entry.js} +1 -1
  232. package/lib/duet/{p-cce6bb84.entry.js → p-31497c7f.entry.js} +1 -1
  233. package/lib/duet/p-32b5532c.entry.js +4 -0
  234. package/lib/duet/{p-183db4fd.entry.js → p-36aed263.entry.js} +1 -1
  235. package/lib/duet/{p-05ff4ff2.entry.js → p-36b14352.entry.js} +1 -1
  236. package/lib/duet/{p-6989d392.system.entry.js → p-3a44e66a.system.entry.js} +1 -1
  237. package/lib/duet/{p-1fcb57c4.system.entry.js → p-3ae2bc39.system.entry.js} +1 -1
  238. package/lib/duet/{p-aa9f3fc8.entry.js → p-3c5b1adb.entry.js} +1 -1
  239. package/lib/duet/{p-e82cc5a7.entry.js → p-3cb7c2b8.entry.js} +1 -1
  240. package/lib/duet/{p-ea09c830.system.entry.js → p-3d2a830f.system.entry.js} +1 -1
  241. package/lib/duet/{p-1d3b7252.entry.js → p-3d82f269.entry.js} +1 -1
  242. package/lib/duet/{p-052545fb.system.entry.js → p-3e0a6231.system.entry.js} +1 -1
  243. package/lib/duet/p-3fb428e9.system.entry.js +4 -0
  244. package/lib/duet/{p-9cbc891f.system.entry.js → p-4578d79a.system.entry.js} +1 -1
  245. package/lib/duet/{p-69ab5590.system.entry.js → p-45f6cac0.system.entry.js} +1 -1
  246. package/lib/duet/{p-10525faa.system.entry.js → p-49bc849e.system.entry.js} +1 -1
  247. package/lib/duet/{p-c0d2e97b.entry.js → p-4bb30628.entry.js} +1 -1
  248. package/lib/duet/{p-24ec796f.system.entry.js → p-4eda4e90.system.entry.js} +1 -1
  249. package/lib/duet/{p-36ad1015.system.entry.js → p-4fdb8a65.system.entry.js} +1 -1
  250. package/lib/duet/{p-08cc78bf.entry.js → p-533787dd.entry.js} +1 -1
  251. package/lib/duet/{p-f888deb6.system.entry.js → p-53ca7657.system.entry.js} +1 -1
  252. package/lib/duet/{p-ae1e4397.system.entry.js → p-53fb3b65.system.entry.js} +1 -1
  253. package/lib/duet/{p-dcf65419.entry.js → p-5710f613.entry.js} +1 -1
  254. package/lib/duet/{p-5831b7b3.system.entry.js → p-58c3a641.system.entry.js} +1 -1
  255. package/lib/duet/{p-72bda1b3.entry.js → p-59bb59f1.entry.js} +1 -1
  256. package/lib/duet/{p-006b7cf2.entry.js → p-5f10cf32.entry.js} +1 -1
  257. package/lib/duet/{p-4be58c8b.system.entry.js → p-5f1ed8ac.system.entry.js} +1 -1
  258. package/lib/duet/{p-94f0387e.entry.js → p-5fac76f8.entry.js} +1 -1
  259. package/lib/duet/{p-d2ffedfa.system.entry.js → p-63913eab.system.entry.js} +1 -1
  260. package/lib/duet/{p-2bea974a.system.entry.js → p-6973b44c.system.entry.js} +1 -1
  261. package/lib/duet/{p-43abf083.entry.js → p-6be424b0.entry.js} +1 -1
  262. package/lib/duet/{p-4bb8d188.system.entry.js → p-6cdea556.system.entry.js} +1 -1
  263. package/lib/duet/{p-11eec0c4.system.entry.js → p-6cf47dac.system.entry.js} +1 -1
  264. package/lib/duet/{p-d9859e96.js → p-707fc6cf.js} +1 -1
  265. package/lib/duet/{p-ce35d050.system.entry.js → p-7090f15a.system.entry.js} +1 -1
  266. package/lib/duet/{p-8e69027d.system.entry.js → p-711fb114.system.entry.js} +1 -1
  267. package/lib/duet/{p-edd23a3b.entry.js → p-714c2b56.entry.js} +1 -1
  268. package/lib/duet/{p-c2f44fde.entry.js → p-72d7785c.entry.js} +1 -1
  269. package/lib/duet/{p-5e02b923.entry.js → p-7420063a.entry.js} +1 -1
  270. package/lib/duet/p-75019a0f.entry.js +4 -0
  271. package/lib/duet/p-7526cac0.system.js +4 -0
  272. package/lib/duet/{p-11c83814.system.entry.js → p-75817145.system.entry.js} +1 -1
  273. package/lib/duet/{p-5058dcff.system.entry.js → p-75c291a0.system.entry.js} +1 -1
  274. package/lib/duet/{p-08f3c955.entry.js → p-76669675.entry.js} +1 -1
  275. package/lib/duet/{p-3179dcc4.entry.js → p-78bdcfdd.entry.js} +1 -1
  276. package/lib/duet/{p-a1dc9c9e.system.entry.js → p-7f52cc01.system.entry.js} +1 -1
  277. package/lib/duet/{p-d76aa87f.system.entry.js → p-80515ee1.system.entry.js} +1 -1
  278. package/lib/duet/{p-ecc8c5f4.system.entry.js → p-8143f9b5.system.entry.js} +1 -1
  279. package/lib/duet/p-8280a9fe.entry.js +4 -0
  280. package/lib/duet/{p-5b7cbc4d.entry.js → p-84327fb5.entry.js} +1 -1
  281. package/lib/duet/{p-a5a6751e.system.entry.js → p-8dad489b.system.entry.js} +1 -1
  282. package/lib/duet/{p-b0428a5d.system.entry.js → p-8ffe50ff.system.entry.js} +1 -1
  283. package/lib/duet/{p-b6753d6e.entry.js → p-91203227.entry.js} +1 -1
  284. package/lib/duet/{p-95a4082f.entry.js → p-934dc718.entry.js} +1 -1
  285. package/lib/duet/p-95c34866.system.entry.js +4 -0
  286. package/lib/duet/{p-9b949b28.entry.js → p-96f06f5b.entry.js} +1 -1
  287. package/lib/duet/{p-5ec490da.system.entry.js → p-9807e8a6.system.entry.js} +1 -1
  288. package/lib/duet/{p-80ffbd1c.entry.js → p-9933a4cd.entry.js} +1 -1
  289. package/lib/duet/{p-ae39acbe.entry.js → p-9b4aec27.entry.js} +1 -1
  290. package/lib/duet/{p-36e6b035.entry.js → p-9e24f4b5.entry.js} +1 -1
  291. package/lib/duet/{p-61fe36d3.entry.js → p-9ebaf967.entry.js} +1 -1
  292. package/lib/duet/{p-0d24350f.entry.js → p-a14705b2.entry.js} +1 -1
  293. package/lib/duet/p-a1f24860.entry.js +4 -0
  294. package/lib/duet/{p-466341b7.entry.js → p-a302c770.entry.js} +1 -1
  295. package/lib/duet/{p-dc1e280d.entry.js → p-a46504b6.entry.js} +1 -1
  296. package/lib/duet/{p-f7cefa5d.system.entry.js → p-a4c9a9ad.system.entry.js} +1 -1
  297. package/lib/duet/{p-09c3fee3.entry.js → p-a563600c.entry.js} +1 -1
  298. package/lib/duet/{p-79ff1a6a.entry.js → p-a69cbaf1.entry.js} +1 -1
  299. package/lib/duet/{p-04103703.system.entry.js → p-a7886157.system.entry.js} +1 -1
  300. package/lib/duet/{p-4a7c0c4f.entry.js → p-a9bbe66f.entry.js} +1 -1
  301. package/lib/duet/p-aa2ce92b.system.entry.js +4 -0
  302. package/lib/duet/{p-3bfd250e.entry.js → p-ad35ad40.entry.js} +1 -1
  303. package/lib/duet/p-b33f7ad2.entry.js +4 -0
  304. package/lib/duet/p-b5ff7b05.system.entry.js +4 -0
  305. package/lib/duet/{p-74a742c9.system.entry.js → p-b6a10dd8.system.entry.js} +1 -1
  306. package/lib/duet/{p-25f8b35d.entry.js → p-b883c31c.entry.js} +1 -1
  307. package/lib/duet/{p-1f5b0f23.system.entry.js → p-b9c37a63.system.entry.js} +1 -1
  308. package/lib/duet/{p-cd33c4cd.entry.js → p-bbe654c7.entry.js} +1 -1
  309. package/lib/duet/p-bcbfe8f2.entry.js +4 -0
  310. package/lib/duet/{p-5e110a00.system.entry.js → p-c0b2021e.system.entry.js} +1 -1
  311. package/lib/duet/{p-9ad584d2.entry.js → p-c0de302a.entry.js} +1 -1
  312. package/lib/duet/{p-055cffab.system.entry.js → p-c0f70bd0.system.entry.js} +1 -1
  313. package/lib/duet/{p-5fff98bf.entry.js → p-c1f19d12.entry.js} +1 -1
  314. package/lib/duet/{p-dc87c6ce.system.entry.js → p-c3604035.system.entry.js} +1 -1
  315. package/lib/duet/{p-b63f60f6.system.entry.js → p-c3d3e73a.system.entry.js} +1 -1
  316. package/lib/duet/{p-d3f8e957.system.entry.js → p-c5559214.system.entry.js} +1 -1
  317. package/lib/duet/{p-a9ba6306.system.js → p-c6acd578.system.js} +1 -1
  318. package/lib/duet/{p-f4b19481.system.entry.js → p-c7201ad9.system.entry.js} +1 -1
  319. package/lib/duet/{p-107abf9a.system.entry.js → p-c816445d.system.entry.js} +1 -1
  320. package/lib/duet/{p-ebfb519a.entry.js → p-c996eaa2.entry.js} +1 -1
  321. package/lib/duet/{p-b77e364d.entry.js → p-c9defd29.entry.js} +1 -1
  322. package/lib/duet/{p-35d9ede4.system.entry.js → p-ce1551ed.system.entry.js} +1 -1
  323. package/lib/duet/{p-bdbf8bca.entry.js → p-ce2d5f1f.entry.js} +1 -1
  324. package/lib/duet/{p-fc6de9c4.system.entry.js → p-ce4d2c6a.system.entry.js} +1 -1
  325. package/lib/duet/{p-9bc15874.entry.js → p-d0516946.entry.js} +1 -1
  326. package/lib/duet/{p-c81e306c.system.entry.js → p-d547f6fe.system.entry.js} +1 -1
  327. package/lib/duet/{p-285a5c7a.system.entry.js → p-d60301f1.system.entry.js} +1 -1
  328. package/lib/duet/{p-acf4057a.entry.js → p-deaf017e.entry.js} +1 -1
  329. package/lib/duet/{p-3783db99.system.entry.js → p-df736b00.system.entry.js} +1 -1
  330. package/lib/duet/p-e272e778.system.entry.js +4 -0
  331. package/lib/duet/{p-68986f07.system.entry.js → p-e5762e3e.system.entry.js} +2 -2
  332. package/lib/duet/p-ea3468e2.system.entry.js +4 -0
  333. package/lib/duet/p-ea80c358.entry.js +4 -0
  334. package/lib/duet/{p-cd514cf6.system.entry.js → p-ecaf90fd.system.entry.js} +1 -1
  335. package/lib/duet/{p-debdd0e0.system.entry.js → p-ecf5724b.system.entry.js} +1 -1
  336. package/lib/duet/{p-1ca17c3d.system.entry.js → p-edc1fa35.system.entry.js} +1 -1
  337. package/lib/duet/{p-cfd2206f.system.entry.js → p-ef076528.system.entry.js} +1 -1
  338. package/lib/duet/{p-b3f3bca8.system.entry.js → p-ef76d461.system.entry.js} +1 -1
  339. package/lib/duet/{p-6410c967.entry.js → p-f02d7e7d.entry.js} +1 -1
  340. package/lib/duet/{p-4aa4735d.entry.js → p-f1a7e606.entry.js} +1 -1
  341. package/lib/duet/p-f34f65af.entry.js +4 -0
  342. package/lib/duet/{p-4faaf699.entry.js → p-f8a68dfd.entry.js} +1 -1
  343. package/lib/duet/{p-29f2cb57.system.entry.js → p-fc98f0fe.system.entry.js} +1 -1
  344. package/lib/duet/{p-577f5a55.entry.js → p-fcbdd6a3.entry.js} +1 -1
  345. package/lib/duet/{p-51dae606.system.entry.js → p-feaa6888.system.entry.js} +1 -1
  346. package/lib/esm/duet-action-button.entry.js +1 -1
  347. package/lib/esm/duet-alert.entry.js +1 -1
  348. package/lib/esm/duet-badge.entry.js +1 -1
  349. package/lib/esm/duet-breadcrumb.entry.js +1 -1
  350. package/lib/esm/duet-breadcrumbs.entry.js +1 -1
  351. package/lib/esm/duet-button_2.entry.js +1 -1
  352. package/lib/esm/duet-caption_4.entry.js +4 -2
  353. package/lib/esm/duet-card.entry.js +1 -1
  354. package/lib/esm/duet-checkbox.entry.js +1 -1
  355. package/lib/esm/duet-checkmark.entry.js +34 -0
  356. package/lib/esm/duet-choice_2.entry.js +8 -2
  357. package/lib/esm/duet-collapsible.entry.js +1 -1
  358. package/lib/esm/duet-combobox.entry.js +1 -1
  359. package/lib/esm/duet-cookie-consent.entry.js +1 -1
  360. package/lib/esm/duet-date-picker.entry.js +2 -2
  361. package/lib/esm/duet-divider_2.entry.js +1 -1
  362. package/lib/esm/duet-editable-table_3.entry.js +2 -2
  363. package/lib/esm/duet-empty-state.entry.js +1 -1
  364. package/lib/esm/duet-fieldset.entry.js +1 -1
  365. package/lib/esm/duet-footer.entry.js +1 -1
  366. package/lib/esm/duet-grid_2.entry.js +1 -1
  367. package/lib/esm/duet-header_2.entry.js +1 -1
  368. package/lib/esm/duet-hero.entry.js +1 -1
  369. package/lib/esm/duet-icon.entry.js +4 -2
  370. package/lib/esm/duet-input_2.entry.js +1 -1
  371. package/lib/esm/duet-layout.entry.js +1 -1
  372. package/lib/esm/duet-list_2.entry.js +1 -1
  373. package/lib/esm/duet-menu-bar-button.entry.js +1 -1
  374. package/lib/esm/duet-menu-bar-dropdown-link.entry.js +1 -1
  375. package/lib/esm/duet-menu-bar-dropdown.entry.js +1 -1
  376. package/lib/esm/duet-menu-bar-link.entry.js +1 -1
  377. package/lib/esm/duet-menu-bar.entry.js +1 -1
  378. package/lib/esm/duet-modal.entry.js +2 -2
  379. package/lib/esm/duet-multiselect.entry.js +1 -1
  380. package/lib/esm/duet-nav.entry.js +2 -2
  381. package/lib/esm/duet-notification_2.entry.js +1 -1
  382. package/lib/esm/duet-number-input.entry.js +1 -1
  383. package/lib/esm/duet-page-heading.entry.js +37 -0
  384. package/lib/esm/duet-pagination_2.entry.js +11 -5
  385. package/lib/esm/duet-progress.entry.js +1 -1
  386. package/lib/esm/duet-radio_2.entry.js +1 -1
  387. package/lib/esm/duet-range-slider.entry.js +1 -1
  388. package/lib/esm/duet-scrollable_3.entry.js +33 -7
  389. package/lib/esm/duet-section-layout.entry.js +1 -1
  390. package/lib/esm/duet-select.entry.js +1 -1
  391. package/lib/esm/duet-slideout-lang.entry.js +1 -1
  392. package/lib/esm/duet-slideout-link.entry.js +1 -1
  393. package/lib/esm/duet-slideout-panel-dropdown.entry.js +1 -1
  394. package/lib/esm/duet-slideout-panel.entry.js +16 -5
  395. package/lib/esm/duet-slideout.entry.js +3 -3
  396. package/lib/esm/duet-step_2.entry.js +1 -1
  397. package/lib/esm/duet-submenu-bar-dropdown-link.entry.js +1 -1
  398. package/lib/esm/duet-submenu-bar-dropdown.entry.js +1 -1
  399. package/lib/esm/duet-submenu-bar-link.entry.js +1 -1
  400. package/lib/esm/duet-submenu-bar.entry.js +1 -1
  401. package/lib/esm/duet-textarea.entry.js +1 -1
  402. package/lib/esm/duet-toggle.entry.js +1 -1
  403. package/lib/esm/duet-toolbar-dropdown-link.entry.js +1 -1
  404. package/lib/esm/duet-toolbar-dropdown.entry.js +1 -1
  405. package/lib/esm/duet-toolbar-link.entry.js +1 -1
  406. package/lib/esm/duet-toolbar.entry.js +1 -1
  407. package/lib/esm/duet-tooltip.entry.js +1 -1
  408. package/lib/esm/duet-tray.entry.js +1 -1
  409. package/lib/esm/duet-upload-aria-status.entry.js +1 -1
  410. package/lib/esm/duet-visually-hidden.entry.js +1 -1
  411. package/lib/esm/duet.js +2 -2
  412. package/lib/esm/{focus-utils-9717e725.js → focus-utils-0619fdea.js} +1 -1
  413. package/lib/esm/{index-e394f675.js → index-11a2e0a0.js} +1 -1
  414. package/lib/esm/loader.js +2 -2
  415. package/lib/esm-es5/duet-action-button.entry.js +1 -1
  416. package/lib/esm-es5/duet-alert.entry.js +1 -1
  417. package/lib/esm-es5/duet-badge.entry.js +1 -1
  418. package/lib/esm-es5/duet-breadcrumb.entry.js +1 -1
  419. package/lib/esm-es5/duet-breadcrumbs.entry.js +1 -1
  420. package/lib/esm-es5/duet-button_2.entry.js +1 -1
  421. package/lib/esm-es5/duet-caption_4.entry.js +1 -1
  422. package/lib/esm-es5/duet-card.entry.js +1 -1
  423. package/lib/esm-es5/duet-checkbox.entry.js +1 -1
  424. package/lib/esm-es5/duet-checkmark.entry.js +4 -0
  425. package/lib/esm-es5/duet-choice_2.entry.js +1 -1
  426. package/lib/esm-es5/duet-collapsible.entry.js +1 -1
  427. package/lib/esm-es5/duet-combobox.entry.js +1 -1
  428. package/lib/esm-es5/duet-cookie-consent.entry.js +1 -1
  429. package/lib/esm-es5/duet-date-picker.entry.js +1 -1
  430. package/lib/esm-es5/duet-divider_2.entry.js +1 -1
  431. package/lib/esm-es5/duet-editable-table_3.entry.js +1 -1
  432. package/lib/esm-es5/duet-empty-state.entry.js +1 -1
  433. package/lib/esm-es5/duet-fieldset.entry.js +1 -1
  434. package/lib/esm-es5/duet-footer.entry.js +1 -1
  435. package/lib/esm-es5/duet-grid_2.entry.js +1 -1
  436. package/lib/esm-es5/duet-header_2.entry.js +1 -1
  437. package/lib/esm-es5/duet-hero.entry.js +1 -1
  438. package/lib/esm-es5/duet-icon.entry.js +2 -2
  439. package/lib/esm-es5/duet-input_2.entry.js +1 -1
  440. package/lib/esm-es5/duet-layout.entry.js +1 -1
  441. package/lib/esm-es5/duet-list_2.entry.js +1 -1
  442. package/lib/esm-es5/duet-menu-bar-button.entry.js +1 -1
  443. package/lib/esm-es5/duet-menu-bar-dropdown-link.entry.js +1 -1
  444. package/lib/esm-es5/duet-menu-bar-dropdown.entry.js +1 -1
  445. package/lib/esm-es5/duet-menu-bar-link.entry.js +1 -1
  446. package/lib/esm-es5/duet-menu-bar.entry.js +1 -1
  447. package/lib/esm-es5/duet-modal.entry.js +2 -2
  448. package/lib/esm-es5/duet-multiselect.entry.js +2 -2
  449. package/lib/esm-es5/duet-nav.entry.js +1 -1
  450. package/lib/esm-es5/duet-notification_2.entry.js +1 -1
  451. package/lib/esm-es5/duet-number-input.entry.js +2 -2
  452. package/lib/esm-es5/duet-page-heading.entry.js +4 -0
  453. package/lib/esm-es5/duet-pagination_2.entry.js +1 -1
  454. package/lib/esm-es5/duet-progress.entry.js +1 -1
  455. package/lib/esm-es5/duet-radio_2.entry.js +1 -1
  456. package/lib/esm-es5/duet-range-slider.entry.js +1 -1
  457. package/lib/esm-es5/duet-scrollable_3.entry.js +2 -2
  458. package/lib/esm-es5/duet-section-layout.entry.js +1 -1
  459. package/lib/esm-es5/duet-select.entry.js +1 -1
  460. package/lib/esm-es5/duet-slideout-lang.entry.js +1 -1
  461. package/lib/esm-es5/duet-slideout-link.entry.js +1 -1
  462. package/lib/esm-es5/duet-slideout-panel-dropdown.entry.js +1 -1
  463. package/lib/esm-es5/duet-slideout-panel.entry.js +1 -1
  464. package/lib/esm-es5/duet-slideout.entry.js +1 -1
  465. package/lib/esm-es5/duet-step_2.entry.js +1 -1
  466. package/lib/esm-es5/duet-submenu-bar-dropdown-link.entry.js +1 -1
  467. package/lib/esm-es5/duet-submenu-bar-dropdown.entry.js +1 -1
  468. package/lib/esm-es5/duet-submenu-bar-link.entry.js +1 -1
  469. package/lib/esm-es5/duet-submenu-bar.entry.js +1 -1
  470. package/lib/esm-es5/duet-textarea.entry.js +1 -1
  471. package/lib/esm-es5/duet-toggle.entry.js +1 -1
  472. package/lib/esm-es5/duet-toolbar-dropdown-link.entry.js +1 -1
  473. package/lib/esm-es5/duet-toolbar-dropdown.entry.js +1 -1
  474. package/lib/esm-es5/duet-toolbar-link.entry.js +1 -1
  475. package/lib/esm-es5/duet-toolbar.entry.js +1 -1
  476. package/lib/esm-es5/duet-tooltip.entry.js +1 -1
  477. package/lib/esm-es5/duet-tray.entry.js +1 -1
  478. package/lib/esm-es5/duet-upload-aria-status.entry.js +1 -1
  479. package/lib/esm-es5/duet-visually-hidden.entry.js +1 -1
  480. package/lib/esm-es5/duet.js +1 -1
  481. package/lib/esm-es5/{focus-utils-9717e725.js → focus-utils-0619fdea.js} +1 -1
  482. package/lib/esm-es5/{index-e394f675.js → index-11a2e0a0.js} +1 -1
  483. package/lib/esm-es5/loader.js +1 -1
  484. package/lib/types/components/duet-choice/duet-checkmark.d.ts +34 -0
  485. package/lib/types/components/duet-choice/duet-choice.d.ts +4 -0
  486. package/lib/types/components/duet-icon/duet-icon.d.ts +4 -0
  487. package/lib/types/components/duet-link/duet-link.d.ts +4 -0
  488. package/lib/types/components/duet-nav/duet-nav.d.ts +5 -0
  489. package/lib/types/components/duet-page-heading/duet-page-heading.d.ts +32 -0
  490. package/lib/types/components/duet-slideout-panel/duet-slideout-panel.d.ts +5 -1
  491. package/lib/types/components/duet-tab/duet-tab.d.ts +4 -0
  492. package/lib/types/components/duet-tab-group/duet-tab-group.d.ts +4 -1
  493. package/lib/types/components.d.ts +128 -1
  494. package/package.json +5 -5
  495. package/lib/dist-custom-elements/p-ff814bad.js +0 -183
  496. package/lib/duet/p-0e4288ad.entry.js +0 -4
  497. package/lib/duet/p-111468b4.system.js +0 -4
  498. package/lib/duet/p-1d86c33e.entry.js +0 -4
  499. package/lib/duet/p-20077ae5.entry.js +0 -4
  500. package/lib/duet/p-5c66df7c.entry.js +0 -4
  501. package/lib/duet/p-609cd028.system.entry.js +0 -4
  502. package/lib/duet/p-6d3a3fd0.js +0 -4
  503. package/lib/duet/p-98ae2cb9.entry.js +0 -4
  504. package/lib/duet/p-a77d4c37.system.entry.js +0 -4
  505. package/lib/duet/p-b0e1180e.system.entry.js +0 -4
  506. package/lib/duet/p-b4659570.entry.js +0 -4
  507. package/lib/duet/p-c41c7735.system.entry.js +0 -4
  508. package/lib/duet/p-d86cf803.entry.js +0 -4
  509. package/lib/duet/p-d9aa697b.entry.js +0 -4
  510. package/lib/duet/p-feb0de52.system.entry.js +0 -4
@@ -1,4 +1,4 @@
1
1
  var __awaiter=this&&this.__awaiter||function(t,e,o,i){function s(t){return t instanceof o?t:new o((function(e){e(t)}))}return new(o||(o=Promise))((function(o,c){function n(t){try{r(i.next(t))}catch(e){c(e)}}function u(t){try{r(i["throw"](t))}catch(e){c(e)}}function r(t){t.done?o(t.value):s(t.value).then(n,u)}r((i=i.apply(t,e||[])).next())}))};var __generator=this&&this.__generator||function(t,e){var o={label:0,sent:function(){if(c[0]&1)throw c[1];return c[1]},trys:[],ops:[]},i,s,c,n;return n={next:u(0),throw:u(1),return:u(2)},typeof Symbol==="function"&&(n[Symbol.iterator]=function(){return this}),n;function u(t){return function(e){return r([t,e])}}function r(n){if(i)throw new TypeError("Generator is already executing.");while(o)try{if(i=1,s&&(c=n[0]&2?s["return"]:n[0]?s["throw"]||((c=s["return"])&&c.call(s),0):s.next)&&!(c=c.call(s,n[1])).done)return c;if(s=0,c)n=[n[0]&2,c.value];switch(n[0]){case 0:case 1:c=n;break;case 4:o.label++;return{value:n[1],done:false};case 5:o.label++;s=n[1];n=[0];continue;case 7:n=o.ops.pop();o.trys.pop();continue;default:if(!(c=o.trys,c=c.length>0&&c[c.length-1])&&(n[0]===6||n[0]===2)){o=0;continue}if(n[0]===3&&(!c||n[1]>c[0]&&n[1]<c[3])){o.label=n[1];break}if(n[0]===6&&o.label<c[1]){o.label=c[1];c=n;break}if(c&&o.label<c[2]){o.label=c[2];o.ops.push(n);break}if(c[2])o.ops.pop();o.trys.pop();continue}n=e.call(t,o)}catch(u){n=[6,u];s=0}finally{i=c=0}if(n[0]&5)throw n[1];return{value:n[0]?n[1]:void 0,done:true}}};
2
2
  /*!
3
3
  * Built with Duet Design System
4
- */import{h,F as Fragment,r as registerInstance,c as createEvent,H as Host,g as getElement}from"./index-e394f675.js";import{i as inheritGlobalTheme}from"./themeable-component-cb76be7c.js";import{d as debounce}from"./js-utils-fa98b8cd.js";import{j as isEnterKey,f as isEscapeKey,o as isTabKey,b as isArrowUpKey,c as isArrowDownKey}from"./keyboard-utils-d237bd5a.js";import{g as getLocaleString,a as getLanguage}from"./language-utils-bf701d37.js";import{p as parsePossibleJSON}from"./string-utils-5954f458.js";var SelectSingle=function(t){var e=t.item,o=t.search,i=o===void 0?"":o,s=t.selected;var c=i!==""?new RegExp("("+i.split(" ").join("|")+")","gi"):undefined;return h(Fragment,null,s&&h("duet-icon",{class:"option-icon",name:"messaging-checked",size:"xx-small",margin:"none"}),c?h("span",{class:"option-container","aria-hidden":"true"},h("span",{innerHTML:e.name.replace(c,'<span class="highlight">$&</span>')})):e.name,e.tags&&h("span",{class:"option-tags"},e.tags.join(", ")))};var DuetComboBoxSelect=function(t){var e=t.item,o=t.active,i=t.total,s=t.selected,c=t.label,n=c===void 0?undefined:c,u=t.clickHandler,r=u===void 0?function(t){t.preventDefault()}:u,b=t.keyHandler,l=b===void 0?function(t){t.preventDefault()}:b,a=t.search;return h("li",{class:{"list-item":true,option:true,active:o,selected:s},id:o?"active_item":"","data-index":e.id,"aria-selected":o?"true":undefined,"aria-current":s?"true":undefined,role:"option","aria-label":n||"".concat(e.name,", (").concat(e.id+1," of ").concat(i,")")},h("a",{tabindex:"-1",onClick:function(t){return r(t)},onKeyUp:function(t){return l(t)},class:"option-link","aria-label":n||"".concat(e.name,", (").concat(e.id+1," of ").concat(i,")"),"aria-hidden":"true"},h(SelectSingle,{item:e,search:a,selected:s})))};var duetComboboxCss='.sc-duet-combobox-h{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;position:relative;width:auto;font-family:"localtapiola-sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";color:#00294d}.sc-duet-combobox-h a.sc-duet-combobox{color:#00294d;transition:none}.duet-theme-turva.sc-duet-combobox-h{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-theme-turva.sc-duet-combobox-h a.sc-duet-combobox{color:#171c3a}.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.option.sc-duet-combobox .option-tags.sc-duet-combobox{color:#747475}.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.option.selected.sc-duet-combobox{background:#f4cfd6}.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.active.sc-duet-combobox,.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:focus,.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:hover{color:white;background:#c60c30}.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.active.sc-duet-combobox .option-tags.sc-duet-combobox,.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:focus .option-tags.sc-duet-combobox,.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:hover .option-tags.sc-duet-combobox{color:white}.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.active.sc-duet-combobox a.sc-duet-combobox,.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:focus a.sc-duet-combobox,.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:hover a.sc-duet-combobox{color:white}.duet-combobox-list.sc-duet-combobox{position:absolute;top:calc(100% - 12px);height:0;overflow:hidden;background:white;border-radius:0 4px;box-shadow:0 2px 10px 0 rgba(0, 41, 77, 0.1);opacity:0}.duet-combobox-list.open.sc-duet-combobox{z-index:700;display:block;height:auto;opacity:1}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox{max-height:200px;padding:0.75rem 0;margin:0;overflow-y:scroll;font-weight:600;list-style:none;cursor:pointer;scroll-behavior:smooth}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox{padding:4px 0}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:not(.selected){padding-left:16px}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:not(.selected) .highlight.sc-duet-combobox{text-decoration:underline}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.option.sc-duet-combobox .option-link.sc-duet-combobox{display:block;width:100%}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.option.sc-duet-combobox .option-tags.sc-duet-combobox{float:right;padding-right:0.875rem;font-weight:400;color:#909599}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.option-link.sc-duet-combobox{display:block;width:100%}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.selected.sc-duet-combobox{padding-left:0;background:#cde5f1}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.selected.option.sc-duet-combobox .option-icon.sc-duet-combobox{padding:0 8px 0 8px}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.selected.option.sc-duet-combobox .option-tags.sc-duet-combobox{color:#909599}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.active.sc-duet-combobox,.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:focus,.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:hover{color:white;background:#0077b3}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.active.sc-duet-combobox .option-tags.sc-duet-combobox,.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:focus .option-tags.sc-duet-combobox,.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:hover .option-tags.sc-duet-combobox{color:white}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.active.sc-duet-combobox a.sc-duet-combobox,.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:focus a.sc-duet-combobox,.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:hover a.sc-duet-combobox{color:white}';var DuetCombobox=function(){function t(t){var e=this;registerInstance(this,t);this.duetChange=createEvent(this,"duetChange",3);this.resizeObserver=new ResizeObserver(debounce((function(t){var o,i;if((t===null||t===void 0?void 0:t.length)===1){var s=(i=(o=t[0])===null||o===void 0?void 0:o.target)===null||i===void 0?void 0:i.getBoundingClientRect().width;e.listContainer.style.width="".concat(s+1,"px")}}),100));this.processedItems=null;this.inputWidth=0;this.inputValue="";this.selectionMsg="";this.listOpen=false;this.selectedItems=new Set;this.activeItem=undefined;this.accessibleLabelDefaults={en:{heading:"Select:",item:"{name}, ({current} of {total})",itemFiltered:"{name}, ({current} of {total}, {hiddenItems} filtered)"},fi:{heading:"Valitse:",item:"{name}, ({current}/{total})",itemFiltered:"{name}, ({current}/{total}, {hiddenItems} suodatettu)"},sv:{heading:"Välj:",item:"{name}, ({current} av {total})",itemFiltered:"{name}, ({current} av {total}, {hiddenItems} filtrerade)"}};this.accessibleLabels=getLocaleString(parsePossibleJSON(this.accessibleLabelDefaults),getLanguage());this.theme="";this.force=false;this.items=undefined;this.formatter=function(t){return t&&t.name?t.name:""};this.value=undefined;this.minCharacters=1}t.prototype.activeItemHandler=function(t){this.input.accessibleActiveDescendant=this.listOpen&&(t||t===0)?"active_item":""};t.prototype.handleDocumentClick=function(t){var e=this;var o=t.composedPath();var i=o.every((function(t){return t!==e.element}));if(i){this.updateInputText(true);this.listOpen=false}};t.prototype.formatItem=function(t){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){return[2,this.formatter(t)]}))}))};t.prototype.componentWillLoad=function(){inheritGlobalTheme(this)};t.prototype.connectedCallback=function(){var t=this;this.items=this.processedItems=parsePossibleJSON(this.items);this.input=this.element.querySelector("duet-input");this.input.addEventListener("duetChange",this.updateInputValue.bind(this));this.input.addEventListener("click",(function(){t.inputValue.length>=t.minCharacters?t.listOpen=true:t.listOpen=false}));this.element.addEventListener("keydown",this.handleInputKeyDownEvent.bind(this));this.input.accessibleAutocomplete="list";this.input.accessibleControls="duet-combobox-list-element"};t.prototype.disconnectedCallback=function(){var t=this;this.input.removeEventListener("duetChange",this.updateInputValue.bind(this));this.input.removeEventListener("click",(function(){return t.inputValue.length?t.listOpen=true:t.listOpen=false}));this.element.removeEventListener("keydown",this.handleInputKeyDownEvent.bind(this));this.listElement.removeEventListener("click",(function(t){t.stopPropagation()}));this.resizeObserver.disconnect()};t.prototype.componentDidLoad=function(){this.resizeObserver.observe(this.input);this.listElement.addEventListener("click",(function(t){t.stopPropagation()}))};t.prototype.onListClick=function(t,e){t.preventDefault();this.updateSelectedItems(e.id);this.listOpen=false;return this.listOpen};t.prototype.shouldListBeFiltered=function(){var t=this;if(this.selectedItems.size&&this.input.value===this.inputValue){var e=this.items.filter((function(e){return t.selectedItems.has(e.id)}));return!(this.formatter(e).toLowerCase()===this.input.value.toLowerCase())}return true};t.prototype.returnFilteredOrNonFiltered=function(){return this.processedItems?this.shouldListBeFiltered()?this.getFilteredItems():this.sortFilteredItems(this.processedItems):[]};t.prototype.updateSelectedItems=function(t){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:this.selectedItems.clear();if(this.selectedItems){if(this.selectedItems.has(t)){this.selectedItems.delete(t)}else{this.selectedItems.add(t)}}return[4,this.updateInputText()];case 1:e.sent();return[2]}}))}))};t.prototype.updateInputText=function(t){if(t===void 0){t=false}return __awaiter(this,void 0,void 0,(function(){var e,o,i;var s=this;return __generator(this,(function(c){switch(c.label){case 0:e=this.selectedItems.size===0?[]:this.items.filter((function(t){return s.selectedItems.has(t.id)}));if(!(this.selectedItems.size===1))return[3,3];this.input.value="";o=this.input;return[4,this.formatItem(e[0])];case 1:o.value=c.sent();this.input.scrollLeft=this.input.scrollWidth;this.activeItem=undefined;i=this;return[4,this.formatItem(e[0])];case 2:i.value=c.sent();this.duetChange.emit({value:e[0].value,item:e[0],component:"duet-combobox"});c.label=3;case 3:if(t&&this.selectedItems.size===0){if(this.force){this.inputValue="";this.input.value=""}this.activeItem=undefined}this.listOpen=false;return[2]}}))}))};t.prototype.updateInputValue=function(t){var e;this.inputValue=t.detail.value;this.listOpen=String(this.inputValue).length>=this.minCharacters&&((e=this.getFilteredItems())===null||e===void 0?void 0:e.length)>0};t.prototype.handleInputKeyDownEvent=function(t){this.input.accessibleActiveDescendant=undefined;if(isEnterKey(t)){t.preventDefault();this.selectActiveItem();this.updateInputText(false);this.listOpen=false;return}if(isEscapeKey(t)||isTabKey(t)){this.updateInputText(true);this.listOpen=false;return}var e=this.activeItem;if(isArrowUpKey(t)){t.preventDefault();e=this.activeItem-1}else if(isArrowDownKey(t)){t.preventDefault();e=this.listOpen?this.activeItem+1:this.activeItem;this.listOpen=true}if(isArrowDownKey(t)||isArrowUpKey(t)){var o=this.shouldListBeFiltered()?this.getFilteredItems():this.processedItems;if(e<0||!e){e=0}if(e>=o.length){e=o.length-1}this.input.accessibleActiveDescendant="active_item";this.activeItem=e;this.scrollToActive()}this.announceActive();return};t.prototype.selectActiveItem=function(){if(this.activeItem===undefined){return}var t=this.returnFilteredOrNonFiltered();var e=t[this.activeItem];this.updateSelectedItems(e.id)};t.prototype.announceActive=function(t){if(!t){t=this.returnFilteredOrNonFiltered()}if(this.activeItem===undefined||this.activeItem===-1){return}var e=t[this.activeItem];this.selectionMsg=structuredClone(this.formatLabel(e,t.length,this.items.length))};t.prototype.scrollToActive=function(){var t=this.listElement.querySelector(".active");if(t){t.scrollIntoView({behavior:"smooth",block:"center"})}};t.prototype.formatLabel=function(t,e,o){if(!t||o===undefined){return""}var i=e===o?this.accessibleLabels.item:this.accessibleLabels.itemFiltered;return i.replace("{name}",String(t.name)).replace("{current}",String(this.activeItem+1)).replace("{total}",String(e)).replace("{hiddenItems}",String(o-e))};t.prototype.getFilteredItems=function(){var t=this;var e=this.processedItems.filter((function(e){var o,i,s,c;return((o=String(e.value))===null||o===void 0?void 0:o.toLowerCase().startsWith((i=t.inputValue)===null||i===void 0?void 0:i.toLowerCase()))||((s=String(e.name))===null||s===void 0?void 0:s.toLowerCase().startsWith((c=t.inputValue)===null||c===void 0?void 0:c.toLowerCase()))||t.selectedItems.has(e.id)}));return this.sortFilteredItems(e)};t.prototype.sortFilteredItems=function(t){var e=this;if(t.length>0){t.filter((function(t){return e.selectedItems.has(t.id)})).forEach((function(e){var o=t.indexOf(e);t.splice(o,1);t.unshift(e)}))}return t};t.prototype.render=function(){var t;var e=this;var o=this.returnFilteredOrNonFiltered();return h(Host,{role:"combobox","aria-expanded":this.listOpen?"true":"false","aria-owns":"duet-combobox-list-element","aria-haspopup":"listbox",class:(t={"duet-combobox":true},t["duet-theme-".concat(this.theme)]=true,t)},h("slot",null),h("div",{role:"list",class:{"duet-combobox-list":true,open:this.listOpen},ref:function(t){return e.listContainer=t}},h("ul",{class:{"duet-combobox-listbox-open":this.listOpen,"duet-combobox-listbox":true},role:"listbox",ref:function(t){return e.listElement=t},id:"duet-combobox-list-element"},o.map((function(t,i){return h(DuetComboBoxSelect,{item:t,active:i===e.activeItem,selected:e.selectedItems.has(t.id),search:e.inputValue,total:o.length,clickHandler:function(o){return e.onListClick(o,t)},label:e.formatLabel(t,e.returnFilteredOrNonFiltered().length,e.items.length)})})))))};Object.defineProperty(t.prototype,"element",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{activeItem:["activeItemHandler"]}},enumerable:false,configurable:true});return t}();DuetCombobox.style=duetComboboxCss;export{DuetCombobox as duet_combobox};
4
+ */import{h,F as Fragment,r as registerInstance,c as createEvent,H as Host,g as getElement}from"./index-11a2e0a0.js";import{i as inheritGlobalTheme}from"./themeable-component-cb76be7c.js";import{d as debounce}from"./js-utils-fa98b8cd.js";import{j as isEnterKey,f as isEscapeKey,o as isTabKey,b as isArrowUpKey,c as isArrowDownKey}from"./keyboard-utils-d237bd5a.js";import{g as getLocaleString,a as getLanguage}from"./language-utils-bf701d37.js";import{p as parsePossibleJSON}from"./string-utils-5954f458.js";var SelectSingle=function(t){var e=t.item,o=t.search,i=o===void 0?"":o,s=t.selected;var c=i!==""?new RegExp("("+i.split(" ").join("|")+")","gi"):undefined;return h(Fragment,null,s&&h("duet-icon",{class:"option-icon",name:"messaging-checked",size:"xx-small",margin:"none"}),c?h("span",{class:"option-container","aria-hidden":"true"},h("span",{innerHTML:e.name.replace(c,'<span class="highlight">$&</span>')})):e.name,e.tags&&h("span",{class:"option-tags"},e.tags.join(", ")))};var DuetComboBoxSelect=function(t){var e=t.item,o=t.active,i=t.total,s=t.selected,c=t.label,n=c===void 0?undefined:c,u=t.clickHandler,r=u===void 0?function(t){t.preventDefault()}:u,b=t.keyHandler,l=b===void 0?function(t){t.preventDefault()}:b,a=t.search;return h("li",{class:{"list-item":true,option:true,active:o,selected:s},id:o?"active_item":"","data-index":e.id,"aria-selected":o?"true":undefined,"aria-current":s?"true":undefined,role:"option","aria-label":n||"".concat(e.name,", (").concat(e.id+1," of ").concat(i,")")},h("a",{tabindex:"-1",onClick:function(t){return r(t)},onKeyUp:function(t){return l(t)},class:"option-link","aria-label":n||"".concat(e.name,", (").concat(e.id+1," of ").concat(i,")"),"aria-hidden":"true"},h(SelectSingle,{item:e,search:a,selected:s})))};var duetComboboxCss='.sc-duet-combobox-h{box-sizing:border-box;padding:0;margin:0;background:transparent;border:0;-moz-appearance:none;-webkit-appearance:none;appearance:none;position:relative;width:auto;font-family:"localtapiola-sans", -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif, "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol";color:#00294d}.sc-duet-combobox-h a.sc-duet-combobox{color:#00294d;transition:none}.duet-theme-turva.sc-duet-combobox-h{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-theme-turva.sc-duet-combobox-h a.sc-duet-combobox{color:#171c3a}.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.option.sc-duet-combobox .option-tags.sc-duet-combobox{color:#747475}.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.option.selected.sc-duet-combobox{background:#f4cfd6}.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.active.sc-duet-combobox,.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:focus,.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:hover{color:white;background:#c60c30}.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.active.sc-duet-combobox .option-tags.sc-duet-combobox,.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:focus .option-tags.sc-duet-combobox,.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:hover .option-tags.sc-duet-combobox{color:white}.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.active.sc-duet-combobox a.sc-duet-combobox,.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:focus a.sc-duet-combobox,.duet-theme-turva.sc-duet-combobox-h .duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:hover a.sc-duet-combobox{color:white}.duet-combobox-list.sc-duet-combobox{position:absolute;top:calc(100% - 12px);height:0;overflow:hidden;background:white;border-radius:0 4px;box-shadow:0 2px 10px 0 rgba(0, 41, 77, 0.1);opacity:0}.duet-combobox-list.open.sc-duet-combobox{z-index:700;display:block;height:auto;opacity:1}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox{max-height:200px;padding:0.75rem 0;margin:0;overflow-y:scroll;font-weight:600;list-style:none;cursor:pointer;scroll-behavior:smooth}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox{padding:4px 0}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:not(.selected){padding-left:16px}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:not(.selected) .highlight.sc-duet-combobox{text-decoration:underline}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.option.sc-duet-combobox .option-link.sc-duet-combobox{display:block;width:100%}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.option.sc-duet-combobox .option-tags.sc-duet-combobox{float:right;padding-right:0.875rem;font-weight:400;color:#909599}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.option-link.sc-duet-combobox{display:block;width:100%}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.selected.sc-duet-combobox{padding-left:0;background:#cde5f1}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.selected.option.sc-duet-combobox .option-icon.sc-duet-combobox{padding:0 8px 0 8px}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.selected.option.sc-duet-combobox .option-tags.sc-duet-combobox{color:#909599}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.active.sc-duet-combobox,.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:focus,.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:hover{color:white;background:#0077b3}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.active.sc-duet-combobox .option-tags.sc-duet-combobox,.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:focus .option-tags.sc-duet-combobox,.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:hover .option-tags.sc-duet-combobox{color:white}.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.active.sc-duet-combobox a.sc-duet-combobox,.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:focus a.sc-duet-combobox,.duet-combobox-list.sc-duet-combobox .duet-combobox-listbox.sc-duet-combobox .list-item.sc-duet-combobox:hover a.sc-duet-combobox{color:white}';var DuetCombobox=function(){function t(t){var e=this;registerInstance(this,t);this.duetChange=createEvent(this,"duetChange",3);this.resizeObserver=new ResizeObserver(debounce((function(t){var o,i;if((t===null||t===void 0?void 0:t.length)===1){var s=(i=(o=t[0])===null||o===void 0?void 0:o.target)===null||i===void 0?void 0:i.getBoundingClientRect().width;e.listContainer.style.width="".concat(s+1,"px")}}),100));this.processedItems=null;this.inputWidth=0;this.inputValue="";this.selectionMsg="";this.listOpen=false;this.selectedItems=new Set;this.activeItem=undefined;this.accessibleLabelDefaults={en:{heading:"Select:",item:"{name}, ({current} of {total})",itemFiltered:"{name}, ({current} of {total}, {hiddenItems} filtered)"},fi:{heading:"Valitse:",item:"{name}, ({current}/{total})",itemFiltered:"{name}, ({current}/{total}, {hiddenItems} suodatettu)"},sv:{heading:"Välj:",item:"{name}, ({current} av {total})",itemFiltered:"{name}, ({current} av {total}, {hiddenItems} filtrerade)"}};this.accessibleLabels=getLocaleString(parsePossibleJSON(this.accessibleLabelDefaults),getLanguage());this.theme="";this.force=false;this.items=undefined;this.formatter=function(t){return t&&t.name?t.name:""};this.value=undefined;this.minCharacters=1}t.prototype.activeItemHandler=function(t){this.input.accessibleActiveDescendant=this.listOpen&&(t||t===0)?"active_item":""};t.prototype.handleDocumentClick=function(t){var e=this;var o=t.composedPath();var i=o.every((function(t){return t!==e.element}));if(i){this.updateInputText(true);this.listOpen=false}};t.prototype.formatItem=function(t){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){return[2,this.formatter(t)]}))}))};t.prototype.componentWillLoad=function(){inheritGlobalTheme(this)};t.prototype.connectedCallback=function(){var t=this;this.items=this.processedItems=parsePossibleJSON(this.items);this.input=this.element.querySelector("duet-input");this.input.addEventListener("duetChange",this.updateInputValue.bind(this));this.input.addEventListener("click",(function(){t.inputValue.length>=t.minCharacters?t.listOpen=true:t.listOpen=false}));this.element.addEventListener("keydown",this.handleInputKeyDownEvent.bind(this));this.input.accessibleAutocomplete="list";this.input.accessibleControls="duet-combobox-list-element"};t.prototype.disconnectedCallback=function(){var t=this;this.input.removeEventListener("duetChange",this.updateInputValue.bind(this));this.input.removeEventListener("click",(function(){return t.inputValue.length?t.listOpen=true:t.listOpen=false}));this.element.removeEventListener("keydown",this.handleInputKeyDownEvent.bind(this));this.listElement.removeEventListener("click",(function(t){t.stopPropagation()}));this.resizeObserver.disconnect()};t.prototype.componentDidLoad=function(){this.resizeObserver.observe(this.input);this.listElement.addEventListener("click",(function(t){t.stopPropagation()}))};t.prototype.onListClick=function(t,e){t.preventDefault();this.updateSelectedItems(e.id);this.listOpen=false;return this.listOpen};t.prototype.shouldListBeFiltered=function(){var t=this;if(this.selectedItems.size&&this.input.value===this.inputValue){var e=this.items.filter((function(e){return t.selectedItems.has(e.id)}));return!(this.formatter(e).toLowerCase()===this.input.value.toLowerCase())}return true};t.prototype.returnFilteredOrNonFiltered=function(){return this.processedItems?this.shouldListBeFiltered()?this.getFilteredItems():this.sortFilteredItems(this.processedItems):[]};t.prototype.updateSelectedItems=function(t){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){switch(e.label){case 0:this.selectedItems.clear();if(this.selectedItems){if(this.selectedItems.has(t)){this.selectedItems.delete(t)}else{this.selectedItems.add(t)}}return[4,this.updateInputText()];case 1:e.sent();return[2]}}))}))};t.prototype.updateInputText=function(t){if(t===void 0){t=false}return __awaiter(this,void 0,void 0,(function(){var e,o,i;var s=this;return __generator(this,(function(c){switch(c.label){case 0:e=this.selectedItems.size===0?[]:this.items.filter((function(t){return s.selectedItems.has(t.id)}));if(!(this.selectedItems.size===1))return[3,3];this.input.value="";o=this.input;return[4,this.formatItem(e[0])];case 1:o.value=c.sent();this.input.scrollLeft=this.input.scrollWidth;this.activeItem=undefined;i=this;return[4,this.formatItem(e[0])];case 2:i.value=c.sent();this.duetChange.emit({value:e[0].value,item:e[0],component:"duet-combobox"});c.label=3;case 3:if(t&&this.selectedItems.size===0){if(this.force){this.inputValue="";this.input.value=""}this.activeItem=undefined}this.listOpen=false;return[2]}}))}))};t.prototype.updateInputValue=function(t){var e;this.inputValue=t.detail.value;this.listOpen=String(this.inputValue).length>=this.minCharacters&&((e=this.getFilteredItems())===null||e===void 0?void 0:e.length)>0};t.prototype.handleInputKeyDownEvent=function(t){this.input.accessibleActiveDescendant=undefined;if(isEnterKey(t)){t.preventDefault();this.selectActiveItem();this.updateInputText(false);this.listOpen=false;return}if(isEscapeKey(t)||isTabKey(t)){this.updateInputText(true);this.listOpen=false;return}var e=this.activeItem;if(isArrowUpKey(t)){t.preventDefault();e=this.activeItem-1}else if(isArrowDownKey(t)){t.preventDefault();e=this.listOpen?this.activeItem+1:this.activeItem;this.listOpen=true}if(isArrowDownKey(t)||isArrowUpKey(t)){var o=this.shouldListBeFiltered()?this.getFilteredItems():this.processedItems;if(e<0||!e){e=0}if(e>=o.length){e=o.length-1}this.input.accessibleActiveDescendant="active_item";this.activeItem=e;this.scrollToActive()}this.announceActive();return};t.prototype.selectActiveItem=function(){if(this.activeItem===undefined){return}var t=this.returnFilteredOrNonFiltered();var e=t[this.activeItem];this.updateSelectedItems(e.id)};t.prototype.announceActive=function(t){if(!t){t=this.returnFilteredOrNonFiltered()}if(this.activeItem===undefined||this.activeItem===-1){return}var e=t[this.activeItem];this.selectionMsg=structuredClone(this.formatLabel(e,t.length,this.items.length))};t.prototype.scrollToActive=function(){var t=this.listElement.querySelector(".active");if(t){t.scrollIntoView({behavior:"smooth",block:"center"})}};t.prototype.formatLabel=function(t,e,o){if(!t||o===undefined){return""}var i=e===o?this.accessibleLabels.item:this.accessibleLabels.itemFiltered;return i.replace("{name}",String(t.name)).replace("{current}",String(this.activeItem+1)).replace("{total}",String(e)).replace("{hiddenItems}",String(o-e))};t.prototype.getFilteredItems=function(){var t=this;var e=this.processedItems.filter((function(e){var o,i,s,c;return((o=String(e.value))===null||o===void 0?void 0:o.toLowerCase().startsWith((i=t.inputValue)===null||i===void 0?void 0:i.toLowerCase()))||((s=String(e.name))===null||s===void 0?void 0:s.toLowerCase().startsWith((c=t.inputValue)===null||c===void 0?void 0:c.toLowerCase()))||t.selectedItems.has(e.id)}));return this.sortFilteredItems(e)};t.prototype.sortFilteredItems=function(t){var e=this;if(t.length>0){t.filter((function(t){return e.selectedItems.has(t.id)})).forEach((function(e){var o=t.indexOf(e);t.splice(o,1);t.unshift(e)}))}return t};t.prototype.render=function(){var t;var e=this;var o=this.returnFilteredOrNonFiltered();return h(Host,{role:"combobox","aria-expanded":this.listOpen?"true":"false","aria-owns":"duet-combobox-list-element","aria-haspopup":"listbox",class:(t={"duet-combobox":true},t["duet-theme-".concat(this.theme)]=true,t)},h("slot",null),h("div",{role:"list",class:{"duet-combobox-list":true,open:this.listOpen},ref:function(t){return e.listContainer=t}},h("ul",{class:{"duet-combobox-listbox-open":this.listOpen,"duet-combobox-listbox":true},role:"listbox",ref:function(t){return e.listElement=t},id:"duet-combobox-list-element"},o.map((function(t,i){return h(DuetComboBoxSelect,{item:t,active:i===e.activeItem,selected:e.selectedItems.has(t.id),search:e.inputValue,total:o.length,clickHandler:function(o){return e.onListClick(o,t)},label:e.formatLabel(t,e.returnFilteredOrNonFiltered().length,e.items.length)})})))))};Object.defineProperty(t.prototype,"element",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(t,"watchers",{get:function(){return{activeItem:["activeItemHandler"]}},enumerable:false,configurable:true});return t}();DuetCombobox.style=duetComboboxCss;export{DuetCombobox as duet_combobox};
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * Built with Duet Design System
3
3
  */
4
- import{r as registerInstance,c as createEvent,h,H as Host,g as getElement}from"./index-e394f675.js";import{i as inheritGlobalTheme}from"./themeable-component-cb76be7c.js";var duetCookieConsentCss='*,*::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:fixed;right:0;bottom:0;left:0;z-index:950;display:block;width:100%;box-shadow:0 2px 20px 0 rgba(0, 0, 0, 0.2)}@media (min-width: 48em){:host{right:28px;bottom:28px;left:auto;width:25rem}}: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}.duet-cookie-consent{padding:20px;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;color:white !important;background-color:rgba(0, 21, 39, 0.9)}@supports (-webkit-backdrop-filter: none) or (backdrop-filter: none){.duet-cookie-consent{background:rgba(0, 21, 39, 0.8);-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px)}}.duet-cookie-consent.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";background-color:rgba(12, 14, 29, 0.9)}@supports (-webkit-backdrop-filter: none) or (backdrop-filter: none){.duet-cookie-consent.duet-theme-turva{background:rgba(12, 14, 29, 0.8)}}@media (min-width: 48em){.duet-cookie-consent{padding:20px;border-radius:4px}}.duet-cookie-consent-content{display:flex;align-items:center;max-width:1110px;margin:0 auto}.duet-cookie-consent-content .expand{flex:1}::slotted(a){font-weight:600;color:white !important;text-decoration:underline;white-space:nowrap}::slotted(a[target=_blank]){padding-right:16px;background:url("data:image/svg+xml;base64,PHN2ZyBmaWxsPSIjZmZmIiB2aWV3Qm94PSIwIDAgMjQgMjQiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTEwLjUgMmExLjUgMS41IDAgMDEuMTQgM0gzLjc1Yy0uMzggMC0uNy4yOC0uNzQuNjVsLS4wMS4xdjE0LjVjMCAuMzguMjguNy42NS43NGwuMS4wMWgxNC41Yy4zOCAwIC43LS4yOC43NC0uNjVsLjAxLS4xdi02Ljg5YTEuNSAxLjUgMCAwMTMgMHY2Ljg5QTMuNzUgMy43NSAwIDAxMTguMjUgMjRIMy43NUEzLjc1IDMuNzUgMCAwMTAgMjAuMjVWNS43NUEzLjc1IDMuNzUgMCAwMTMuNzUgMnptMTItMmMuNzggMCAxLjQyLjYgMS41IDEuMzZWNy41YTEuNSAxLjUgMCAwMS0zIC4xNFY1LjEybC01LjQ0IDUuNDRhMS41IDEuNSAwIDAxLTIuMjItMmwuMS0uMTJMMTguODggM0gxNi41QTEuNSAxLjUgMCAwMTE1IDEuNjRWMS41YzAtLjc4LjYtMS40MiAxLjM2LTEuNWguMTR6Ii8+PC9zdmc+") no-repeat right 50%;background-size:12px 10px}::slotted(a:focus){outline:0;box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}.duet-theme-turva ::slotted(a:focus){outline:0;box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}';var DuetCookieConsent=function(){function e(e){var t=this;registerInstance(this,e);this.duetCookieConsent=createEvent(this,"duetCookieConsent",7);this.handleClick=function(e){e.preventDefault();t.duetCookieConsent.emit({component:"duet-cookie-consent"})};this.accessibleLabel="Hyväksyn evästeiden käytön";this.theme=""}e.prototype.componentWillLoad=function(){inheritGlobalTheme(this)};e.prototype.render=function(){return h(Host,{tabindex:"0"},h("div",{class:{"duet-cookie-consent":true,"duet-theme-turva":this.theme==="turva"}},h("div",{class:"duet-cookie-consent-content"},h("div",{class:"expand"},h("slot",null)),h("duet-spacer",{size:"large",direction:"horizontal"}),h("div",null,h("duet-button",{variation:"negative",size:"small",onClick:this.handleClick,margin:"none","aria-label":this.accessibleLabel,theme:this.theme},"OK")))))};Object.defineProperty(e.prototype,"element",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();DuetCookieConsent.style=duetCookieConsentCss;export{DuetCookieConsent as duet_cookie_consent};
4
+ import{r as registerInstance,c as createEvent,h,H as Host,g as getElement}from"./index-11a2e0a0.js";import{i as inheritGlobalTheme}from"./themeable-component-cb76be7c.js";var duetCookieConsentCss='*,*::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:fixed;right:0;bottom:0;left:0;z-index:950;display:block;width:100%;box-shadow:0 2px 20px 0 rgba(0, 0, 0, 0.2)}@media (min-width: 48em){:host{right:28px;bottom:28px;left:auto;width:25rem}}: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}.duet-cookie-consent{padding:20px;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;color:white !important;background-color:rgba(0, 21, 39, 0.9)}@supports (-webkit-backdrop-filter: none) or (backdrop-filter: none){.duet-cookie-consent{background:rgba(0, 21, 39, 0.8);-webkit-backdrop-filter:blur(4px);backdrop-filter:blur(4px)}}.duet-cookie-consent.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";background-color:rgba(12, 14, 29, 0.9)}@supports (-webkit-backdrop-filter: none) or (backdrop-filter: none){.duet-cookie-consent.duet-theme-turva{background:rgba(12, 14, 29, 0.8)}}@media (min-width: 48em){.duet-cookie-consent{padding:20px;border-radius:4px}}.duet-cookie-consent-content{display:flex;align-items:center;max-width:1110px;margin:0 auto}.duet-cookie-consent-content .expand{flex:1}::slotted(a){font-weight:600;color:white !important;text-decoration:underline;white-space:nowrap}::slotted(a[target=_blank]){padding-right:16px;background:url("data:image/svg+xml;base64,PHN2ZyBmaWxsPSIjZmZmIiB2aWV3Qm94PSIwIDAgMjQgMjQiIHhtbG5zPSJodHRwOi8vd3d3LnczLm9yZy8yMDAwL3N2ZyI+PHBhdGggZD0iTTEwLjUgMmExLjUgMS41IDAgMDEuMTQgM0gzLjc1Yy0uMzggMC0uNy4yOC0uNzQuNjVsLS4wMS4xdjE0LjVjMCAuMzguMjguNy42NS43NGwuMS4wMWgxNC41Yy4zOCAwIC43LS4yOC43NC0uNjVsLjAxLS4xdi02Ljg5YTEuNSAxLjUgMCAwMTMgMHY2Ljg5QTMuNzUgMy43NSAwIDAxMTguMjUgMjRIMy43NUEzLjc1IDMuNzUgMCAwMTAgMjAuMjVWNS43NUEzLjc1IDMuNzUgMCAwMTMuNzUgMnptMTItMmMuNzggMCAxLjQyLjYgMS41IDEuMzZWNy41YTEuNSAxLjUgMCAwMS0zIC4xNFY1LjEybC01LjQ0IDUuNDRhMS41IDEuNSAwIDAxLTIuMjItMmwuMS0uMTJMMTguODggM0gxNi41QTEuNSAxLjUgMCAwMTE1IDEuNjRWMS41YzAtLjc4LjYtMS40MiAxLjM2LTEuNWguMTR6Ii8+PC9zdmc+") no-repeat right 50%;background-size:12px 10px}::slotted(a:focus){outline:0;box-shadow:0 0 0 4px rgba(0, 119, 179, 0.3), 0 0 0 1px #0077b3}.duet-theme-turva ::slotted(a:focus){outline:0;box-shadow:0 0 0 4px rgba(23, 28, 58, 0.2), 0 0 0 1px #171c3a}';var DuetCookieConsent=function(){function e(e){var t=this;registerInstance(this,e);this.duetCookieConsent=createEvent(this,"duetCookieConsent",7);this.handleClick=function(e){e.preventDefault();t.duetCookieConsent.emit({component:"duet-cookie-consent"})};this.accessibleLabel="Hyväksyn evästeiden käytön";this.theme=""}e.prototype.componentWillLoad=function(){inheritGlobalTheme(this)};e.prototype.render=function(){return h(Host,{tabindex:"0"},h("div",{class:{"duet-cookie-consent":true,"duet-theme-turva":this.theme==="turva"}},h("div",{class:"duet-cookie-consent-content"},h("div",{class:"expand"},h("slot",null)),h("duet-spacer",{size:"large",direction:"horizontal"}),h("div",null,h("duet-button",{variation:"negative",size:"small",onClick:this.handleClick,margin:"none","aria-label":this.accessibleLabel,theme:this.theme},"OK")))))};Object.defineProperty(e.prototype,"element",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();DuetCookieConsent.style=duetCookieConsentCss;export{DuetCookieConsent as duet_cookie_consent};
@@ -1,4 +1,4 @@
1
1
  var __awaiter=this&&this.__awaiter||function(e,t,a,i){function n(e){return e instanceof a?e:new a((function(t){t(e)}))}return new(a||(a=Promise))((function(a,r){function o(e){try{s(i.next(e))}catch(t){r(t)}}function d(e){try{s(i["throw"](e))}catch(t){r(t)}}function s(e){e.done?a(e.value):n(e.value).then(o,d)}s((i=i.apply(e,t||[])).next())}))};var __generator=this&&this.__generator||function(e,t){var a={label:0,sent:function(){if(r[0]&1)throw r[1];return r[1]},trys:[],ops:[]},i,n,r,o;return o={next:d(0),throw:d(1),return:d(2)},typeof Symbol==="function"&&(o[Symbol.iterator]=function(){return this}),o;function d(e){return function(t){return s([e,t])}}function s(o){if(i)throw new TypeError("Generator is already executing.");while(a)try{if(i=1,n&&(r=o[0]&2?n["return"]:o[0]?n["throw"]||((r=n["return"])&&r.call(n),0):n.next)&&!(r=r.call(n,o[1])).done)return r;if(n=0,r)o=[o[0]&2,r.value];switch(o[0]){case 0:case 1:r=o;break;case 4:a.label++;return{value:o[1],done:false};case 5:a.label++;n=o[1];o=[0];continue;case 7:o=a.ops.pop();a.trys.pop();continue;default:if(!(r=a.trys,r=r.length>0&&r[r.length-1])&&(o[0]===6||o[0]===2)){a=0;continue}if(o[0]===3&&(!r||o[1]>r[0]&&o[1]<r[3])){a.label=o[1];break}if(o[0]===6&&a.label<r[1]){a.label=r[1];r=o;break}if(r&&a.label<r[2]){a.label=r[2];a.ops.push(o);break}if(r[2])a.ops.pop();a.trys.pop();continue}o=t.call(e,a)}catch(d){o=[6,d];n=0}finally{i=r=0}if(o[0]&5)throw o[1];return{value:o[0]?o[1]:void 0,done:true}}};
2
2
  /*!
3
3
  * Built with Duet Design System
4
- */import{h,r as registerInstance,c as createEvent,H as Host,g as getElement}from"./index-e394f675.js";import{i as inheritGlobalTheme}from"./themeable-component-cb76be7c.js";import{c as createID}from"./create-id-981107da.js";import{F as FocusGuard}from"./focus-utils-9717e725.js";import{a as getLanguage,g as getLocaleString}from"./language-utils-bf701d37.js";import"./string-utils-5954f458.js";var formatOptionsShort={day:"numeric",month:"long"};var formatOptionsLong={day:"numeric",month:"long",year:"numeric"};var i18n={fi:{buttonLabel:"Valitse päivämäärä",prevMonthLabel:"Edellinen kuukausi",nextMonthLabel:"Seuraava kuukausi",monthSelectLabel:"Kuukausi",yearSelectLabel:"Vuosi",closeLabel:"Sulje ikkuna",selected:"Valittu päivämäärä on",keyboardInstruction:"Voit navigoida päivämääriä nuolinäppäimillä",dayLabels:["Maanantai","Tiistai","Keskiviikko","Torstai","Perjantai","Lauantai","Sunnuntai"],monthLabels:["Tammikuu","Helmikuu","Maaliskuu","Huhtikuu","Toukokuu","Kesäkuu","Heinäkuu","Elokuu","Syyskuu","Lokakuu","Marraskuu","Joulukuu"],monthLabelsShort:["Tammi","Helmi","Maalis","Huhti","Touko","Kesä","Heinä","Elo","Syys","Loka","Marras","Joulu"],formatterShort:new Intl.DateTimeFormat("fi-FI",formatOptionsShort),formatterLong:new Intl.DateTimeFormat("fi-FI",formatOptionsLong)},en:{buttonLabel:"Choose date",prevMonthLabel:"Previous month",nextMonthLabel:"Next month",monthSelectLabel:"Month",yearSelectLabel:"Year",closeLabel:"Close window",selected:"Selected date is",keyboardInstruction:"You can use arrow keys to navigate dates",dayLabels:["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],monthLabels:["January","February","March","April","May","June","July","August","September","October","November","December"],monthLabelsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],formatterShort:new Intl.DateTimeFormat("en-GB",formatOptionsShort),formatterLong:new Intl.DateTimeFormat("en-GB",formatOptionsLong)},sv:{buttonLabel:"Välj datum",prevMonthLabel:"Föregående månad",nextMonthLabel:"Nästa månad",monthSelectLabel:"Månad",yearSelectLabel:"År",closeLabel:"Stäng fönstret",selected:"Valt datum är",keyboardInstruction:"Använd piltangenterna för att navigera i kalender",dayLabels:["Måndag","Tisdag","Onsdag","Torsdag","Fredag","Lördag","Söndag"],monthLabels:["Januari","Februari","Mars","April","Maj","Juni","Juli","Augusti","September","Oktober","November","December"],monthLabelsShort:["Jan","Feb","Mars","April","Maj","Juni","Juli","Aug","Sep","Okt","Nov","Dec"],formatterShort:new Intl.DateTimeFormat("sv-SE",formatOptionsShort),formatterLong:new Intl.DateTimeFormat("sv-SE",formatOptionsLong)}};var formDate={title:"form-date",tags:"form date calendar date picker",svg:'<svg fill="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" role="img"><path d="M2.25 24A2.252 2.252 0 0 1 0 21.75V5.25A2.252 2.252 0 0 1 2.25 3H6V.75a.75.75 0 0 1 1.5 0V3h9V.75a.75.75 0 0 1 1.5 0V3h3.75A2.252 2.252 0 0 1 24 5.25v16.5A2.252 2.252 0 0 1 21.75 24zm-.75-2.25c0 .414.336.75.75.75h19.5a.75.75 0 0 0 .75-.75V10.5h-21zM22.5 9V5.25a.75.75 0 0 0-.75-.75H18V6a.75.75 0 0 1-1.5 0V4.5h-9V6A.75.75 0 0 1 6 6V4.5H2.25a.75.75 0 0 0-.75.75V9z"/><circle cx="5.625" cy="13.875" r="1.125"/><circle cx="5.625" cy="19.125" r="1.125"/><circle cx="12" cy="13.875" r="1.125"/><circle cx="12" cy="19.125" r="1.125"/><circle cx="18.375" cy="13.875" r="1.125"/><path d="M18.375 20.25c-.62 0-1.125-.505-1.125-1.125a1.127 1.127 0 0 1 1.171-1.122l.027.003a1.118 1.118 0 0 1 1.052 1.12c0 .619-.505 1.124-1.125 1.124z"/></svg>'};var DatePickerInput=function(e){var t=e.onClick,a=e.placeholder,i=e.name,n=e.inputLabel,r=e.value,o=e.valueAsDate,d=e.formattedValue,s=e.language,u=e.identifier,c=e.theme,l=e.disabled,p=e.error,f=e.role,m=e.required,b=e.tooltip,g=e.tooltipDirection,v=e.labelHidden,y=e.buttonRef,k=e.inputRef,D=e.onInput,x=e.onBlur,w=e.onFocus,S=e.accessibleActiveDescendant,M=e.accessibleControls,I=e.accessibleOwns,F=e.accessibleDescribedBy,O=e.echoPlaceholder,T=e.caption;var L=i18n[s],A=L.buttonLabel,E=L.selected,Y=L.formatterLong;return h("div",{class:{"duet-theme-turva":c==="turva","duet-date-input":true}},h("duet-input",{label:n,value:d,placeholder:a,id:u,disabled:l,theme:c,error:p,role:f,required:m,tooltip:b,tooltipDirection:g,margin:"none",component:"date",labelHidden:v,accessibleAutocomplete:"none",onDuetInput:D,onDuetFocus:w,onDuetBlur:x,autoComplete:"off",disallowPattern:"[^0-9\\.\\-\\/]",expand:true,ref:k,accessibleActiveDescendant:S,accessibleControls:M,accessibleOwns:I,accessibleDescribedBy:F,echoPlaceholder:O,caption:T},h("button",{class:{"duet-date-button":true,"duet-no-label":v},onClick:t,disabled:l,ref:y,type:"button"},h("duet-icon",{icon:formDate.svg,margin:"none",size:"small",color:"currentColor"}),h("duet-visually-hidden",null,A,o&&h("span",null,", ",E," ",Y.format(o))))),h("input",{type:"hidden",name:i,value:r}))};var DATE_FORMAT=/^(\d{1,2})[\.\-\/](\d{1,2})[\.\-\/](\d{4})$/;var ISO_DATE_FORMAT=/^(\d{4})-(\d{2})-(\d{2})$/;var DATE_OUTPUT_FORMAT="dd.mm.yyyy";var DATE_ISO_OUTPUT_FORMAT="YYYY-MM-DD";function createDate(e,t,a){var i=parseInt(a,10);var n=parseInt(t,10);var r=parseInt(e,10);var o=Number.isInteger(r)&&Number.isInteger(n)&&Number.isInteger(i)&&n>0&&n<=12&&i>0&&i<=31&&r>0;if(o){return new Date(r,n-1,i)}}function parseDate(e){if(!e){return}var t=e.match(DATE_FORMAT);if(t){return createDate(t[3],t[2],t[1])}}function parseISODate(e){if(!e){return}var t=e.match(ISO_DATE_FORMAT);if(t){return createDate(t[1],t[2],t[3])}}function formatDate(e,t){if(!e){return""}var a=e.getDate().toString(10);var i=(e.getMonth()+1).toString(10);var n=e.getFullYear().toString(10);if(e.getDate()<10){a="0".concat(a)}if(e.getMonth()<9){i="0".concat(i)}return t.replace(/MM/i,i).replace(/YYYY/i,n).replace(/DD/i,a)}function printDate(e){return formatDate(e,DATE_OUTPUT_FORMAT)}function printISODate(e){return formatDate(e,DATE_ISO_OUTPUT_FORMAT)}function isEqual(e,t){if(e==null||t==null){return false}return e.getFullYear()===t.getFullYear()&&e.getMonth()===t.getMonth()&&e.getDate()===t.getDate()}function addDays(e,t){var a=new Date(e);a.setDate(a.getDate()+t);return a}function startOfWeek(e,t){if(t===void 0){t=1}var a=new Date(e);var i=a.getDay();var n=(i<t?7:0)+i-t;a.setDate(a.getDate()-n);return a}function endOfWeek(e,t){if(t===void 0){t=1}var a=new Date(e);var i=a.getDay();var n=(i<t?-7:0)+6-(i-t);a.setDate(a.getDate()+n);return a}function startOfMonth(e){return new Date(e.getFullYear(),e.getMonth(),1)}function endOfMonth(e){return new Date(e.getFullYear(),e.getMonth()+1,0)}function setMonth(e,t){var a=new Date(e);a.setMonth(t);return a}function setYear(e,t){var a=new Date(e);a.setFullYear(t);return a}function inRange(e,t,a){return clamp(e,t,a)===e}function clamp(e,t,a){var i=e.getTime();if(t&&t instanceof Date&&i<t.getTime()){return t}if(a&&a instanceof Date&&i>a.getTime()){return a}return e}function getDaysInRange(e,t){var a=[];var i=e;while(!isEqual(i,t)){a.push(i);i=addDays(i,1)}a.push(i);return a}function getViewOfMonth(e,t){if(t===void 0){t=1}var a=startOfWeek(startOfMonth(e),t);var i=endOfWeek(endOfMonth(e),t);return getDaysInRange(a,i)}var DatePickerDay=function(e){var t=e.focusedDay,a=e.today,i=e.day,n=e.language,r=e.onDaySelect,o=e.onKeyboardNavigation,d=e.ref,s=e.inRange,u=e.isSelected;var c=isEqual(i,a);var l=isEqual(i,t);var p=i.getMonth()!==t.getMonth();var f=!s;var m=i18n[n].formatterShort;function b(e){r(e,i)}return h("button",{class:{"duet-date-table-button":true,outside:f,disabled:p,today:c},tabIndex:l?0:-1,onClick:b,onKeyDown:o,"aria-disabled":f||p,"aria-pressed":u?"true":"false",type:"button",ref:d},h("span",{"aria-hidden":"true"},i.getDate()),h("duet-visually-hidden",null,m.format(i)))};function range(e,t){var a=[];for(var i=e;i<=t;i++){a.push(i)}return a}function chunk(e,t){var a=[];for(var i=0;i<e.length;i+=t){a.push(e.slice(i,i+t))}return a}function parseShortcut(e){var t;var a=e.trim().split("+");var i=a.pop();return[((t=a[0])===null||t===void 0?void 0:t.toLowerCase())==="shift",i]}function createShortcuts(e){var t=Object.keys(e).map((function(t){return[parseShortcut(t),e[t]]}));return function e(a){if(!(a instanceof KeyboardEvent)){return}var i=t.find((function(e){var t=e[0],i=t[0],n=t[1];return(n.toUpperCase()===a.key.toUpperCase()||n===a.code)&&i===a.shiftKey}));if(i){i[1](a);a.preventDefault()}}}var DatePickerMonth=function(e){var t=e.selectedDate,a=e.focusedDate,i=e.labelledById,n=e.theme,r=e.language,o=e.min,d=e.max,s=e.onDateSelect,u=e.onKeyboardNavigation,c=e.focusedDayRef,l=e.onFocusEnter,p=e.onFocusExit;var f=i18n[r].dayLabels;var m=new Date;var b=getViewOfMonth(a);function g(e){var t=e.currentTarget;var a=e.relatedTarget;if(a&&!t.contains(a)){p(e)}}return h("table",{class:{"duet-date-table":true,"duet-theme-turva":n==="turva"},"aria-labelledby":i,onFocusin:l,onFocusout:g},h("thead",null,h("tr",null,f.map((function(e){return h("th",{scope:"col"},h("span",{"aria-hidden":"true"},e.substr(0,2)),h("duet-visually-hidden",null,e))})))),h("tbody",null,chunk(b,7).map((function(e){return h("tr",{class:"duet-date-table-row"},e.map((function(e){return h("td",{class:"duet-date-table-cell"},h(DatePickerDay,{day:e,today:m,language:r,focusedDay:a,inRange:inRange(e,o,d),isSelected:isEqual(e,t),onDaySelect:s,onKeyboardNavigation:u,ref:function(t){if(t&&isEqual(e,a)){c(t)}}}))})))}))))};var 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}';var DuetDatePicker=function(){function e(e){var t=this;registerInstance(this,e);this.duetChange=createEvent(this,"duetChange",7);this.duetBlur=createEvent(this,"duetBlur",7);this.duetFocus=createEvent(this,"duetFocus",7);this.monthSelectId=createID("DuetDatePicker");this.yearSelectId=createID("DuetDatePicker");this.dialogLabelId=createID("DuetDatePicker");this.initialTouchX=null;this.initialTouchY=null;this.focusTarget=null;this.enableActiveFocus=function(){t.focusTarget="day-button"};this.disableActiveFocus=function(){t.focusTarget=null};this.toggleOpen=function(e){e.preventDefault();t.open?t.hide(false):t.show()};this.handleBlur=function(e){e.stopPropagation();t.duetBlur.emit({component:"duet-date-picker"})};this.handleFocus=function(e){e.stopPropagation();t.duetFocus.emit({component:"duet-date-picker"})};this.handleTouchStart=function(e){var a=e.changedTouches[0];t.initialTouchX=a.pageX;t.initialTouchY=a.pageY};this.handleTouchMove=function(e){e.preventDefault()};this.handleTouchEnd=function(e){var a=e.changedTouches[0];var i=a.pageX-t.initialTouchX;var n=a.pageY-t.initialTouchY;var r=70;var o=Math.abs(i)>=r&&Math.abs(n)<=r;var d=Math.abs(n)>=r&&Math.abs(i)<=r&&n>0;if(o){t.addMonths(i<0?1:-1)}else if(d){t.hide();e.preventDefault()}t.initialTouchY=null;t.initialTouchX=null};this.handleNextMonthClick=function(e){e.preventDefault();t.addMonths(1)};this.handlePreviousMonthClick=function(e){e.preventDefault();t.addMonths(-1)};this.handleEscKey=createShortcuts({Escape:function(){return t.hide()},Esc:function(){return t.hide()}});this.handleKeyboardNavigation=createShortcuts({ArrowRight:function(){return t.addDays(1)},Right:function(){return t.addDays(1)},ArrowLeft:function(){return t.addDays(-1)},Left:function(){return t.addDays(-1)},ArrowDown:function(){return t.addDays(7)},Down:function(){return t.addDays(7)},ArrowUp:function(){return t.addDays(-7)},Up:function(){return t.addDays(-7)},Home:function(){return t.startOfWeek()},End:function(){return t.endOfWeek()},PageUp:function(){return t.addMonths(-1)},PageDown:function(){return t.addMonths(1)},"Shift+PageUp":function(){return t.addYears(-1)},"Shift+PageDown":function(){return t.addYears(1)}});this.handleDaySelect=function(e,a){var i=parseISODate(t.min);var n=parseISODate(t.max);t.determineValidity(a);if(inRange(a,i,n)){t.setValue(a);t.hide()}};this.handleMonthSelect=function(e){t.setMonth(parseInt(e.target.value,10))};this.handleYearSelect=function(e){t.setYear(parseInt(e.target.value,10))};this.handleInputChange=function(e){t.inputValue=e.detail.value;var a=parseDate(t.inputValue);t.determineValidity(a);if(a||t.inputValue===""){t.setValue(a)}};this.open=false;this.focusedDay=new Date;this.inputValue="";this.theme="";this.expand=false;this.name="";this.identifier="";this.label="";this.caption=undefined;this.margin="auto";this.language=getLanguage();this.placeholderDefaults={fi:"pp.kk.vvvv",en:"dd.mm.yyyy",sv:"dd.mm.åååå"};this.placeholder=getLocaleString(this.placeholderDefaults,this.language);this.echoPlaceholder=false;this.disabled=false;this.error="";this.labelHidden=false;this.role=undefined;this.accessibleActiveDescendant=undefined;this.accessibleControls=undefined;this.accessibleOwns=undefined;this.accessibleDescribedBy=undefined;this.required=false;this.direction="right";this.tooltip="";this.tooltipDirection="auto";this.value="";this.min="";this.max="";this.incrementYears=10;this.validity=undefined}e.prototype.updateValidity=function(){this.determineValidity(parseISODate(this.value))};e.prototype.updateInternalValue=function(){var e=parseISODate(this.value);var t=parseDate(this.inputValue);if(!e){this.inputValue=""}else if(!isEqual(e,t)){this.inputValue=printDate(e)}};e.prototype.componentWillLoad=function(){inheritGlobalTheme(this);this.determineValidity(parseISODate(this.value));this.updateInternalValue()};e.prototype.componentDidUpdate=function(){switch(this.focusTarget){case"toggle-button":this.datePickerButton.focus();this.focusTarget=null;break;case"day-button":this.focusedDayNode.focus();break;case"month-select":this.monthSelectNode.focus();this.focusTarget=null;break}};e.prototype.setFocus=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.datePickerInput.setFocus(e);return[2]}))}))};e.prototype.show=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this.open=true;this.focusTarget="month-select";this.setFocusedDay(parseISODate(this.value)||new Date);return[2]}))}))};e.prototype.hide=function(e){if(e===void 0){e=true}return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.open=false;if(e){this.focusTarget="toggle-button"}return[2]}))}))};e.prototype.addDays=function(e){this.setFocusedDay(addDays(this.focusedDay,e))};e.prototype.addMonths=function(e){this.setMonth(this.focusedDay.getMonth()+e)};e.prototype.addYears=function(e){this.setYear(this.focusedDay.getFullYear()+e)};e.prototype.startOfWeek=function(){this.setFocusedDay(startOfWeek(this.focusedDay))};e.prototype.endOfWeek=function(){this.setFocusedDay(endOfWeek(this.focusedDay))};e.prototype.setMonth=function(e){var t=setMonth(startOfMonth(this.focusedDay),e);var a=endOfMonth(t);var i=setMonth(this.focusedDay,e);this.setFocusedDay(clamp(i,t,a))};e.prototype.setYear=function(e){var t=setYear(startOfMonth(this.focusedDay),e);var a=endOfMonth(t);var i=setYear(this.focusedDay,e);this.setFocusedDay(clamp(i,t,a))};e.prototype.setFocusedDay=function(e){this.focusedDay=clamp(e,parseISODate(this.min),parseISODate(this.max))};e.prototype.determineValidity=function(e){var t,a;var i=(a=(t=this.datePickerInput)===null||t===void 0?void 0:t.value)!==null&&a!==void 0?a:"";var n=i!==""&&e==null;var r=this.required&&e==null;var o=e?!inRange(e,null,parseISODate(this.max)):false;var d=e?!inRange(e,parseISODate(this.min)):false;this.validity={patternMismatch:false,customError:false,stepMismatch:false,tooLong:false,tooShort:false,typeMismatch:false,valueMissing:r,badInput:n,rangeUnderflow:d,rangeOverflow:o,valid:!(r||n||d||o)}};e.prototype.setValue=function(e){var t=printISODate(e);if(t===this.value){return}this.value=t;this.duetChange.emit({component:"duet-date-picker",value:this.value,valueAsDate:e})};e.prototype.handleDocumentClick=function(e){var t=this;if(!this.open){return}var a=e.composedPath().every((function(e){return e!==t.dialogWrapperNode&&e!==t.datePickerButton}));if(a){this.hide(false)}};e.prototype.render=function(){var e=this;var t=parseISODate(this.value);var a=(t||this.focusedDay).getFullYear();var i=this.focusedDay.getMonth();var n=this.focusedDay.getFullYear();var r=i18n[this.language];var o=parseISODate(this.min);var d=parseISODate(this.max);var s=o!=null&&o.getMonth()===i&&o.getFullYear()===n;var u=d!=null&&d.getMonth()===i&&d.getFullYear()===n;var c=a-this.incrementYears;var l=a+this.incrementYears;if(o){c=Math.max(c,o.getFullYear())}if(d){l=Math.min(l,d.getFullYear())}return h(Host,{class:{"duet-expand":this.expand,"duet-m-0":this.margin==="none"}},h("div",{class:"duet-date"},h(DatePickerInput,{value:this.value,valueAsDate:t,formattedValue:this.inputValue,language:this.language,onInput:this.handleInputChange,onBlur:this.handleBlur,onFocus:this.handleFocus,onClick:this.toggleOpen,name:this.name,disabled:this.disabled,error:this.error,role:this.role,required:this.required,theme:this.theme,tooltip:this.tooltip,tooltipDirection:this.tooltipDirection,labelHidden:this.labelHidden,placeholder:this.placeholder,inputLabel:this.label,identifier:this.identifier,buttonRef:function(t){return e.datePickerButton=t},inputRef:function(t){return e.datePickerInput=t},accessibleActiveDescendant:this.accessibleActiveDescendant,accessibleControls:this.accessibleControls,accessibleOwns:this.accessibleOwns,accessibleDescribedBy:this.accessibleDescribedBy,echoPlaceholder:this.echoPlaceholder,caption:this.caption})),h("div",{class:{"duet-theme-turva":this.theme==="turva","duet-date-dialog":true,left:this.direction==="left",error:!!this.error,active:this.open},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(FocusGuard,{moveFocusTo:this.focusedDayNode}),h("div",{class:"duet-date-dialog-wrapper",onKeyDown:this.handleEscKey,ref:function(t){return e.dialogWrapperNode=t}},h("duet-visually-hidden",{"aria-live":"polite"},r.keyboardInstruction),h("div",{class:"duet-date-dialog-mobile-header"},h("duet-label",{margin:"none"},this.label),h("button",{class:"duet-date-picker-close",ref:function(t){return e.closeButtonNode=t},onClick:function(){return e.hide()},type:"button"},h("duet-icon",{name:"navigation-close-small",margin:"none",color:"currentColor",size:"xx-small"}),h("duet-visually-hidden",null,r.closeLabel))),h("div",{class:"duet-date-dialog-header"},h("div",{class:"duet-date-dialog-dropdowns"},h("duet-visually-hidden",null,h("h2",{id:this.dialogLabelId,"aria-live":"polite","aria-atomic":"true"},r.monthLabels[i]," ",this.focusedDay.getFullYear())),h("duet-visually-hidden",null,h("label",{htmlFor:this.monthSelectId},r.monthSelectLabel)),h("div",{class:"duet-date-dialog-select"},h("select",{id:this.monthSelectId,class:"duet-date-month-select",ref:function(t){return e.monthSelectNode=t},onChange:this.handleMonthSelect},r.monthLabels.map((function(e,t){return h("option",{key:e,value:t,selected:t===i,disabled:!inRange(new Date(n,t,1),o?startOfMonth(o):null,d?endOfMonth(d):null)},e)}))),h("div",{class:"duet-date-dialog-select-label","aria-hidden":"true"},h("span",null,r.monthLabelsShort[i]),h("duet-icon",{name:"action-arrow-down-small",color:"currentColor",margin:"none",size:"xxx-small"}))),h("duet-visually-hidden",null,h("label",{htmlFor:this.yearSelectId},r.yearSelectLabel)),h("div",{class:"duet-date-dialog-select"},h("select",{id:this.yearSelectId,class:"duet-date-year-select",onChange:this.handleYearSelect},range(c,l).map((function(e){return h("option",{key:e,selected:e===n},e)}))),h("div",{class:"duet-date-dialog-select-label","aria-hidden":"true"},h("span",null,this.focusedDay.getFullYear()),h("duet-icon",{name:"action-arrow-down-small",color:"currentColor",margin:"none",size:"xxx-small"})))),h("div",{class:"duet-date-dialog-buttons"},h("duet-action-button",{class:"duet-date-dialog-prev",onClick:this.handlePreviousMonthClick,disabled:s,"icon-name":"action-arrow-left-small"},r.prevMonthLabel),h("duet-action-button",{class:"duet-date-dialog-next",onClick:this.handleNextMonthClick,disabled:u,"icon-name":"action-arrow-right-small"},r.nextMonthLabel))),h(DatePickerMonth,{selectedDate:t,focusedDate:this.focusedDay,onDateSelect:this.handleDaySelect,onKeyboardNavigation:this.handleKeyboardNavigation,labelledById:this.dialogLabelId,language:this.language,theme:this.theme,min:o,max:d,focusedDayRef:function(t){return e.focusedDayNode=t},onFocusEnter:this.enableActiveFocus,onFocusExit:this.disableActiveFocus})),h(FocusGuard,{moveFocusTo:this.closeButtonNode})))};Object.defineProperty(e.prototype,"element",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{min:["updateValidity"],max:["updateValidity"],value:["updateValidity","updateInternalValue"],required:["updateValidity"]}},enumerable:false,configurable:true});return e}();DuetDatePicker.style=duetDatePickerCss;export{DuetDatePicker as duet_date_picker};
4
+ */import{h,r as registerInstance,c as createEvent,H as Host,g as getElement}from"./index-11a2e0a0.js";import{i as inheritGlobalTheme}from"./themeable-component-cb76be7c.js";import{c as createID}from"./create-id-981107da.js";import{F as FocusGuard}from"./focus-utils-0619fdea.js";import{a as getLanguage,g as getLocaleString}from"./language-utils-bf701d37.js";import"./string-utils-5954f458.js";var formatOptionsShort={day:"numeric",month:"long"};var formatOptionsLong={day:"numeric",month:"long",year:"numeric"};var i18n={fi:{buttonLabel:"Valitse päivämäärä",prevMonthLabel:"Edellinen kuukausi",nextMonthLabel:"Seuraava kuukausi",monthSelectLabel:"Kuukausi",yearSelectLabel:"Vuosi",closeLabel:"Sulje ikkuna",selected:"Valittu päivämäärä on",keyboardInstruction:"Voit navigoida päivämääriä nuolinäppäimillä",dayLabels:["Maanantai","Tiistai","Keskiviikko","Torstai","Perjantai","Lauantai","Sunnuntai"],monthLabels:["Tammikuu","Helmikuu","Maaliskuu","Huhtikuu","Toukokuu","Kesäkuu","Heinäkuu","Elokuu","Syyskuu","Lokakuu","Marraskuu","Joulukuu"],monthLabelsShort:["Tammi","Helmi","Maalis","Huhti","Touko","Kesä","Heinä","Elo","Syys","Loka","Marras","Joulu"],formatterShort:new Intl.DateTimeFormat("fi-FI",formatOptionsShort),formatterLong:new Intl.DateTimeFormat("fi-FI",formatOptionsLong)},en:{buttonLabel:"Choose date",prevMonthLabel:"Previous month",nextMonthLabel:"Next month",monthSelectLabel:"Month",yearSelectLabel:"Year",closeLabel:"Close window",selected:"Selected date is",keyboardInstruction:"You can use arrow keys to navigate dates",dayLabels:["Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday"],monthLabels:["January","February","March","April","May","June","July","August","September","October","November","December"],monthLabelsShort:["Jan","Feb","Mar","Apr","May","Jun","Jul","Aug","Sep","Oct","Nov","Dec"],formatterShort:new Intl.DateTimeFormat("en-GB",formatOptionsShort),formatterLong:new Intl.DateTimeFormat("en-GB",formatOptionsLong)},sv:{buttonLabel:"Välj datum",prevMonthLabel:"Föregående månad",nextMonthLabel:"Nästa månad",monthSelectLabel:"Månad",yearSelectLabel:"År",closeLabel:"Stäng fönstret",selected:"Valt datum är",keyboardInstruction:"Använd piltangenterna för att navigera i kalender",dayLabels:["Måndag","Tisdag","Onsdag","Torsdag","Fredag","Lördag","Söndag"],monthLabels:["Januari","Februari","Mars","April","Maj","Juni","Juli","Augusti","September","Oktober","November","December"],monthLabelsShort:["Jan","Feb","Mars","April","Maj","Juni","Juli","Aug","Sep","Okt","Nov","Dec"],formatterShort:new Intl.DateTimeFormat("sv-SE",formatOptionsShort),formatterLong:new Intl.DateTimeFormat("sv-SE",formatOptionsLong)}};var formDate={title:"form-date",tags:"form date calendar date picker",svg:'<svg fill="currentColor" viewBox="0 0 24 24" xmlns="http://www.w3.org/2000/svg" role="img"><path d="M2.25 24A2.252 2.252 0 0 1 0 21.75V5.25A2.252 2.252 0 0 1 2.25 3H6V.75a.75.75 0 0 1 1.5 0V3h9V.75a.75.75 0 0 1 1.5 0V3h3.75A2.252 2.252 0 0 1 24 5.25v16.5A2.252 2.252 0 0 1 21.75 24zm-.75-2.25c0 .414.336.75.75.75h19.5a.75.75 0 0 0 .75-.75V10.5h-21zM22.5 9V5.25a.75.75 0 0 0-.75-.75H18V6a.75.75 0 0 1-1.5 0V4.5h-9V6A.75.75 0 0 1 6 6V4.5H2.25a.75.75 0 0 0-.75.75V9z"/><circle cx="5.625" cy="13.875" r="1.125"/><circle cx="5.625" cy="19.125" r="1.125"/><circle cx="12" cy="13.875" r="1.125"/><circle cx="12" cy="19.125" r="1.125"/><circle cx="18.375" cy="13.875" r="1.125"/><path d="M18.375 20.25c-.62 0-1.125-.505-1.125-1.125a1.127 1.127 0 0 1 1.171-1.122l.027.003a1.118 1.118 0 0 1 1.052 1.12c0 .619-.505 1.124-1.125 1.124z"/></svg>'};var DatePickerInput=function(e){var t=e.onClick,a=e.placeholder,i=e.name,n=e.inputLabel,r=e.value,o=e.valueAsDate,d=e.formattedValue,s=e.language,u=e.identifier,c=e.theme,l=e.disabled,p=e.error,f=e.role,m=e.required,b=e.tooltip,g=e.tooltipDirection,v=e.labelHidden,y=e.buttonRef,k=e.inputRef,D=e.onInput,x=e.onBlur,w=e.onFocus,S=e.accessibleActiveDescendant,M=e.accessibleControls,I=e.accessibleOwns,F=e.accessibleDescribedBy,O=e.echoPlaceholder,T=e.caption;var L=i18n[s],A=L.buttonLabel,E=L.selected,Y=L.formatterLong;return h("div",{class:{"duet-theme-turva":c==="turva","duet-date-input":true}},h("duet-input",{label:n,value:d,placeholder:a,id:u,disabled:l,theme:c,error:p,role:f,required:m,tooltip:b,tooltipDirection:g,margin:"none",component:"date",labelHidden:v,accessibleAutocomplete:"none",onDuetInput:D,onDuetFocus:w,onDuetBlur:x,autoComplete:"off",disallowPattern:"[^0-9\\.\\-\\/]",expand:true,ref:k,accessibleActiveDescendant:S,accessibleControls:M,accessibleOwns:I,accessibleDescribedBy:F,echoPlaceholder:O,caption:T},h("button",{class:{"duet-date-button":true,"duet-no-label":v},onClick:t,disabled:l,ref:y,type:"button"},h("duet-icon",{icon:formDate.svg,margin:"none",size:"small",color:"currentColor"}),h("duet-visually-hidden",null,A,o&&h("span",null,", ",E," ",Y.format(o))))),h("input",{type:"hidden",name:i,value:r}))};var DATE_FORMAT=/^(\d{1,2})[\.\-\/](\d{1,2})[\.\-\/](\d{4})$/;var ISO_DATE_FORMAT=/^(\d{4})-(\d{2})-(\d{2})$/;var DATE_OUTPUT_FORMAT="dd.mm.yyyy";var DATE_ISO_OUTPUT_FORMAT="YYYY-MM-DD";function createDate(e,t,a){var i=parseInt(a,10);var n=parseInt(t,10);var r=parseInt(e,10);var o=Number.isInteger(r)&&Number.isInteger(n)&&Number.isInteger(i)&&n>0&&n<=12&&i>0&&i<=31&&r>0;if(o){return new Date(r,n-1,i)}}function parseDate(e){if(!e){return}var t=e.match(DATE_FORMAT);if(t){return createDate(t[3],t[2],t[1])}}function parseISODate(e){if(!e){return}var t=e.match(ISO_DATE_FORMAT);if(t){return createDate(t[1],t[2],t[3])}}function formatDate(e,t){if(!e){return""}var a=e.getDate().toString(10);var i=(e.getMonth()+1).toString(10);var n=e.getFullYear().toString(10);if(e.getDate()<10){a="0".concat(a)}if(e.getMonth()<9){i="0".concat(i)}return t.replace(/MM/i,i).replace(/YYYY/i,n).replace(/DD/i,a)}function printDate(e){return formatDate(e,DATE_OUTPUT_FORMAT)}function printISODate(e){return formatDate(e,DATE_ISO_OUTPUT_FORMAT)}function isEqual(e,t){if(e==null||t==null){return false}return e.getFullYear()===t.getFullYear()&&e.getMonth()===t.getMonth()&&e.getDate()===t.getDate()}function addDays(e,t){var a=new Date(e);a.setDate(a.getDate()+t);return a}function startOfWeek(e,t){if(t===void 0){t=1}var a=new Date(e);var i=a.getDay();var n=(i<t?7:0)+i-t;a.setDate(a.getDate()-n);return a}function endOfWeek(e,t){if(t===void 0){t=1}var a=new Date(e);var i=a.getDay();var n=(i<t?-7:0)+6-(i-t);a.setDate(a.getDate()+n);return a}function startOfMonth(e){return new Date(e.getFullYear(),e.getMonth(),1)}function endOfMonth(e){return new Date(e.getFullYear(),e.getMonth()+1,0)}function setMonth(e,t){var a=new Date(e);a.setMonth(t);return a}function setYear(e,t){var a=new Date(e);a.setFullYear(t);return a}function inRange(e,t,a){return clamp(e,t,a)===e}function clamp(e,t,a){var i=e.getTime();if(t&&t instanceof Date&&i<t.getTime()){return t}if(a&&a instanceof Date&&i>a.getTime()){return a}return e}function getDaysInRange(e,t){var a=[];var i=e;while(!isEqual(i,t)){a.push(i);i=addDays(i,1)}a.push(i);return a}function getViewOfMonth(e,t){if(t===void 0){t=1}var a=startOfWeek(startOfMonth(e),t);var i=endOfWeek(endOfMonth(e),t);return getDaysInRange(a,i)}var DatePickerDay=function(e){var t=e.focusedDay,a=e.today,i=e.day,n=e.language,r=e.onDaySelect,o=e.onKeyboardNavigation,d=e.ref,s=e.inRange,u=e.isSelected;var c=isEqual(i,a);var l=isEqual(i,t);var p=i.getMonth()!==t.getMonth();var f=!s;var m=i18n[n].formatterShort;function b(e){r(e,i)}return h("button",{class:{"duet-date-table-button":true,outside:f,disabled:p,today:c},tabIndex:l?0:-1,onClick:b,onKeyDown:o,"aria-disabled":f||p,"aria-pressed":u?"true":"false",type:"button",ref:d},h("span",{"aria-hidden":"true"},i.getDate()),h("duet-visually-hidden",null,m.format(i)))};function range(e,t){var a=[];for(var i=e;i<=t;i++){a.push(i)}return a}function chunk(e,t){var a=[];for(var i=0;i<e.length;i+=t){a.push(e.slice(i,i+t))}return a}function parseShortcut(e){var t;var a=e.trim().split("+");var i=a.pop();return[((t=a[0])===null||t===void 0?void 0:t.toLowerCase())==="shift",i]}function createShortcuts(e){var t=Object.keys(e).map((function(t){return[parseShortcut(t),e[t]]}));return function e(a){if(!(a instanceof KeyboardEvent)){return}var i=t.find((function(e){var t=e[0],i=t[0],n=t[1];return(n.toUpperCase()===a.key.toUpperCase()||n===a.code)&&i===a.shiftKey}));if(i){i[1](a);a.preventDefault()}}}var DatePickerMonth=function(e){var t=e.selectedDate,a=e.focusedDate,i=e.labelledById,n=e.theme,r=e.language,o=e.min,d=e.max,s=e.onDateSelect,u=e.onKeyboardNavigation,c=e.focusedDayRef,l=e.onFocusEnter,p=e.onFocusExit;var f=i18n[r].dayLabels;var m=new Date;var b=getViewOfMonth(a);function g(e){var t=e.currentTarget;var a=e.relatedTarget;if(a&&!t.contains(a)){p(e)}}return h("table",{class:{"duet-date-table":true,"duet-theme-turva":n==="turva"},"aria-labelledby":i,onFocusin:l,onFocusout:g},h("thead",null,h("tr",null,f.map((function(e){return h("th",{scope:"col"},h("span",{"aria-hidden":"true"},e.substr(0,2)),h("duet-visually-hidden",null,e))})))),h("tbody",null,chunk(b,7).map((function(e){return h("tr",{class:"duet-date-table-row"},e.map((function(e){return h("td",{class:"duet-date-table-cell"},h(DatePickerDay,{day:e,today:m,language:r,focusedDay:a,inRange:inRange(e,o,d),isSelected:isEqual(e,t),onDaySelect:s,onKeyboardNavigation:u,ref:function(t){if(t&&isEqual(e,a)){c(t)}}}))})))}))))};var 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}';var DuetDatePicker=function(){function e(e){var t=this;registerInstance(this,e);this.duetChange=createEvent(this,"duetChange",7);this.duetBlur=createEvent(this,"duetBlur",7);this.duetFocus=createEvent(this,"duetFocus",7);this.monthSelectId=createID("DuetDatePicker");this.yearSelectId=createID("DuetDatePicker");this.dialogLabelId=createID("DuetDatePicker");this.initialTouchX=null;this.initialTouchY=null;this.focusTarget=null;this.enableActiveFocus=function(){t.focusTarget="day-button"};this.disableActiveFocus=function(){t.focusTarget=null};this.toggleOpen=function(e){e.preventDefault();t.open?t.hide(false):t.show()};this.handleBlur=function(e){e.stopPropagation();t.duetBlur.emit({component:"duet-date-picker"})};this.handleFocus=function(e){e.stopPropagation();t.duetFocus.emit({component:"duet-date-picker"})};this.handleTouchStart=function(e){var a=e.changedTouches[0];t.initialTouchX=a.pageX;t.initialTouchY=a.pageY};this.handleTouchMove=function(e){e.preventDefault()};this.handleTouchEnd=function(e){var a=e.changedTouches[0];var i=a.pageX-t.initialTouchX;var n=a.pageY-t.initialTouchY;var r=70;var o=Math.abs(i)>=r&&Math.abs(n)<=r;var d=Math.abs(n)>=r&&Math.abs(i)<=r&&n>0;if(o){t.addMonths(i<0?1:-1)}else if(d){t.hide();e.preventDefault()}t.initialTouchY=null;t.initialTouchX=null};this.handleNextMonthClick=function(e){e.preventDefault();t.addMonths(1)};this.handlePreviousMonthClick=function(e){e.preventDefault();t.addMonths(-1)};this.handleEscKey=createShortcuts({Escape:function(){return t.hide()},Esc:function(){return t.hide()}});this.handleKeyboardNavigation=createShortcuts({ArrowRight:function(){return t.addDays(1)},Right:function(){return t.addDays(1)},ArrowLeft:function(){return t.addDays(-1)},Left:function(){return t.addDays(-1)},ArrowDown:function(){return t.addDays(7)},Down:function(){return t.addDays(7)},ArrowUp:function(){return t.addDays(-7)},Up:function(){return t.addDays(-7)},Home:function(){return t.startOfWeek()},End:function(){return t.endOfWeek()},PageUp:function(){return t.addMonths(-1)},PageDown:function(){return t.addMonths(1)},"Shift+PageUp":function(){return t.addYears(-1)},"Shift+PageDown":function(){return t.addYears(1)}});this.handleDaySelect=function(e,a){var i=parseISODate(t.min);var n=parseISODate(t.max);t.determineValidity(a);if(inRange(a,i,n)){t.setValue(a);t.hide()}};this.handleMonthSelect=function(e){t.setMonth(parseInt(e.target.value,10))};this.handleYearSelect=function(e){t.setYear(parseInt(e.target.value,10))};this.handleInputChange=function(e){t.inputValue=e.detail.value;var a=parseDate(t.inputValue);t.determineValidity(a);if(a||t.inputValue===""){t.setValue(a)}};this.open=false;this.focusedDay=new Date;this.inputValue="";this.theme="";this.expand=false;this.name="";this.identifier="";this.label="";this.caption=undefined;this.margin="auto";this.language=getLanguage();this.placeholderDefaults={fi:"pp.kk.vvvv",en:"dd.mm.yyyy",sv:"dd.mm.åååå"};this.placeholder=getLocaleString(this.placeholderDefaults,this.language);this.echoPlaceholder=false;this.disabled=false;this.error="";this.labelHidden=false;this.role=undefined;this.accessibleActiveDescendant=undefined;this.accessibleControls=undefined;this.accessibleOwns=undefined;this.accessibleDescribedBy=undefined;this.required=false;this.direction="right";this.tooltip="";this.tooltipDirection="auto";this.value="";this.min="";this.max="";this.incrementYears=10;this.validity=undefined}e.prototype.updateValidity=function(){this.determineValidity(parseISODate(this.value))};e.prototype.updateInternalValue=function(){var e=parseISODate(this.value);var t=parseDate(this.inputValue);if(!e){this.inputValue=""}else if(!isEqual(e,t)){this.inputValue=printDate(e)}};e.prototype.componentWillLoad=function(){inheritGlobalTheme(this);this.determineValidity(parseISODate(this.value));this.updateInternalValue()};e.prototype.componentDidUpdate=function(){switch(this.focusTarget){case"toggle-button":this.datePickerButton.focus();this.focusTarget=null;break;case"day-button":this.focusedDayNode.focus();break;case"month-select":this.monthSelectNode.focus();this.focusTarget=null;break}};e.prototype.setFocus=function(e){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.datePickerInput.setFocus(e);return[2]}))}))};e.prototype.show=function(){return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(e){this.open=true;this.focusTarget="month-select";this.setFocusedDay(parseISODate(this.value)||new Date);return[2]}))}))};e.prototype.hide=function(e){if(e===void 0){e=true}return __awaiter(this,void 0,void 0,(function(){return __generator(this,(function(t){this.open=false;if(e){this.focusTarget="toggle-button"}return[2]}))}))};e.prototype.addDays=function(e){this.setFocusedDay(addDays(this.focusedDay,e))};e.prototype.addMonths=function(e){this.setMonth(this.focusedDay.getMonth()+e)};e.prototype.addYears=function(e){this.setYear(this.focusedDay.getFullYear()+e)};e.prototype.startOfWeek=function(){this.setFocusedDay(startOfWeek(this.focusedDay))};e.prototype.endOfWeek=function(){this.setFocusedDay(endOfWeek(this.focusedDay))};e.prototype.setMonth=function(e){var t=setMonth(startOfMonth(this.focusedDay),e);var a=endOfMonth(t);var i=setMonth(this.focusedDay,e);this.setFocusedDay(clamp(i,t,a))};e.prototype.setYear=function(e){var t=setYear(startOfMonth(this.focusedDay),e);var a=endOfMonth(t);var i=setYear(this.focusedDay,e);this.setFocusedDay(clamp(i,t,a))};e.prototype.setFocusedDay=function(e){this.focusedDay=clamp(e,parseISODate(this.min),parseISODate(this.max))};e.prototype.determineValidity=function(e){var t,a;var i=(a=(t=this.datePickerInput)===null||t===void 0?void 0:t.value)!==null&&a!==void 0?a:"";var n=i!==""&&e==null;var r=this.required&&e==null;var o=e?!inRange(e,null,parseISODate(this.max)):false;var d=e?!inRange(e,parseISODate(this.min)):false;this.validity={patternMismatch:false,customError:false,stepMismatch:false,tooLong:false,tooShort:false,typeMismatch:false,valueMissing:r,badInput:n,rangeUnderflow:d,rangeOverflow:o,valid:!(r||n||d||o)}};e.prototype.setValue=function(e){var t=printISODate(e);if(t===this.value){return}this.value=t;this.duetChange.emit({component:"duet-date-picker",value:this.value,valueAsDate:e})};e.prototype.handleDocumentClick=function(e){var t=this;if(!this.open){return}var a=e.composedPath().every((function(e){return e!==t.dialogWrapperNode&&e!==t.datePickerButton}));if(a){this.hide(false)}};e.prototype.render=function(){var e=this;var t=parseISODate(this.value);var a=(t||this.focusedDay).getFullYear();var i=this.focusedDay.getMonth();var n=this.focusedDay.getFullYear();var r=i18n[this.language];var o=parseISODate(this.min);var d=parseISODate(this.max);var s=o!=null&&o.getMonth()===i&&o.getFullYear()===n;var u=d!=null&&d.getMonth()===i&&d.getFullYear()===n;var c=a-this.incrementYears;var l=a+this.incrementYears;if(o){c=Math.max(c,o.getFullYear())}if(d){l=Math.min(l,d.getFullYear())}return h(Host,{class:{"duet-expand":this.expand,"duet-m-0":this.margin==="none"}},h("div",{class:"duet-date"},h(DatePickerInput,{value:this.value,valueAsDate:t,formattedValue:this.inputValue,language:this.language,onInput:this.handleInputChange,onBlur:this.handleBlur,onFocus:this.handleFocus,onClick:this.toggleOpen,name:this.name,disabled:this.disabled,error:this.error,role:this.role,required:this.required,theme:this.theme,tooltip:this.tooltip,tooltipDirection:this.tooltipDirection,labelHidden:this.labelHidden,placeholder:this.placeholder,inputLabel:this.label,identifier:this.identifier,buttonRef:function(t){return e.datePickerButton=t},inputRef:function(t){return e.datePickerInput=t},accessibleActiveDescendant:this.accessibleActiveDescendant,accessibleControls:this.accessibleControls,accessibleOwns:this.accessibleOwns,accessibleDescribedBy:this.accessibleDescribedBy,echoPlaceholder:this.echoPlaceholder,caption:this.caption})),h("div",{class:{"duet-theme-turva":this.theme==="turva","duet-date-dialog":true,left:this.direction==="left",error:!!this.error,active:this.open},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(FocusGuard,{moveFocusTo:this.focusedDayNode}),h("div",{class:"duet-date-dialog-wrapper",onKeyDown:this.handleEscKey,ref:function(t){return e.dialogWrapperNode=t}},h("duet-visually-hidden",{"aria-live":"polite"},r.keyboardInstruction),h("div",{class:"duet-date-dialog-mobile-header"},h("duet-label",{margin:"none"},this.label),h("button",{class:"duet-date-picker-close",ref:function(t){return e.closeButtonNode=t},onClick:function(){return e.hide()},type:"button"},h("duet-icon",{name:"navigation-close-small",margin:"none",color:"currentColor",size:"xx-small"}),h("duet-visually-hidden",null,r.closeLabel))),h("div",{class:"duet-date-dialog-header"},h("div",{class:"duet-date-dialog-dropdowns"},h("duet-visually-hidden",null,h("h2",{id:this.dialogLabelId,"aria-live":"polite","aria-atomic":"true"},r.monthLabels[i]," ",this.focusedDay.getFullYear())),h("duet-visually-hidden",null,h("label",{htmlFor:this.monthSelectId},r.monthSelectLabel)),h("div",{class:"duet-date-dialog-select"},h("select",{id:this.monthSelectId,class:"duet-date-month-select",ref:function(t){return e.monthSelectNode=t},onChange:this.handleMonthSelect},r.monthLabels.map((function(e,t){return h("option",{key:e,value:t,selected:t===i,disabled:!inRange(new Date(n,t,1),o?startOfMonth(o):null,d?endOfMonth(d):null)},e)}))),h("div",{class:"duet-date-dialog-select-label","aria-hidden":"true"},h("span",null,r.monthLabelsShort[i]),h("duet-icon",{name:"action-arrow-down-small",color:"currentColor",margin:"none",size:"xxx-small"}))),h("duet-visually-hidden",null,h("label",{htmlFor:this.yearSelectId},r.yearSelectLabel)),h("div",{class:"duet-date-dialog-select"},h("select",{id:this.yearSelectId,class:"duet-date-year-select",onChange:this.handleYearSelect},range(c,l).map((function(e){return h("option",{key:e,selected:e===n},e)}))),h("div",{class:"duet-date-dialog-select-label","aria-hidden":"true"},h("span",null,this.focusedDay.getFullYear()),h("duet-icon",{name:"action-arrow-down-small",color:"currentColor",margin:"none",size:"xxx-small"})))),h("div",{class:"duet-date-dialog-buttons"},h("duet-action-button",{class:"duet-date-dialog-prev",onClick:this.handlePreviousMonthClick,disabled:s,"icon-name":"action-arrow-left-small"},r.prevMonthLabel),h("duet-action-button",{class:"duet-date-dialog-next",onClick:this.handleNextMonthClick,disabled:u,"icon-name":"action-arrow-right-small"},r.nextMonthLabel))),h(DatePickerMonth,{selectedDate:t,focusedDate:this.focusedDay,onDateSelect:this.handleDaySelect,onKeyboardNavigation:this.handleKeyboardNavigation,labelledById:this.dialogLabelId,language:this.language,theme:this.theme,min:o,max:d,focusedDayRef:function(t){return e.focusedDayNode=t},onFocusEnter:this.enableActiveFocus,onFocusExit:this.disableActiveFocus})),h(FocusGuard,{moveFocusTo:this.closeButtonNode})))};Object.defineProperty(e.prototype,"element",{get:function(){return getElement(this)},enumerable:false,configurable:true});Object.defineProperty(e,"watchers",{get:function(){return{min:["updateValidity"],max:["updateValidity"],value:["updateValidity","updateInternalValue"],required:["updateValidity"]}},enumerable:false,configurable:true});return e}();DuetDatePicker.style=duetDatePickerCss;export{DuetDatePicker as duet_date_picker};
@@ -1,4 +1,4 @@
1
1
  /*!
2
2
  * Built with Duet Design System
3
3
  */
4
- import{r as registerInstance,h,g as getElement,H as Host}from"./index-e394f675.js";import{i as inheritGlobalTheme}from"./themeable-component-cb76be7c.js";import{g as getColorByName}from"./token-utils-b531747a.js";import"./tokens.module-d3321092.js";var duetDividerCss="*,*::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-divider{-webkit-user-select:none;user-select:none;display:block;width:100%;height:1px;margin-top:36px !important;margin-bottom:28px;background:#e1e3e6}.duet-divider.duet-p-0{padding:0 !important}.duet-divider.duet-m-0{margin:0 !important}.duet-divider.duet-m-s{margin-bottom:16px !important;margin-top:0 !important}.duet-divider.duet-theme-turva{background:#e4e4e6}";var DuetDivider=function(){function e(e){registerInstance(this,e);this.theme="";this.margin="auto";this.color=""}e.prototype.componentWillLoad=function(){inheritGlobalTheme(this)};e.prototype.render=function(){var e=getColorByName(this.color);return h("div",{class:{"duet-m-0":this.margin==="none","duet-m-s":this.margin==="small","duet-divider":true,"duet-theme-turva":this.theme==="turva"},style:{background:e}})};Object.defineProperty(e.prototype,"element",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();DuetDivider.style=duetDividerCss;var duetSpacerCss=":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:12px;min-width:12px;height:12px}@media (min-width: 36em){:host{width:16px;min-width:16px;height:16px}}:host(.duet-spacer-horizontal){display:inline-block;height:100% !important}:host(.duet-spacer-horizontal.xx-small){width:4px;min-width:4px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.xx-small){width:4px;min-width:4px}}:host(.duet-spacer-horizontal.x-small){width:4px;min-width:4px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.x-small){width:8px;min-width:8px}}:host(.duet-spacer-horizontal.small){width:8px;min-width:8px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.small){width:12px;min-width:12px}}:host(.duet-spacer-horizontal.medium){height:100%}:host(.duet-spacer-horizontal.large){width:16px;min-width:16px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.large){width:20px;min-width:20px}}:host(.duet-spacer-horizontal.x-large){width:20px;min-width:20px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.x-large){width:28px;min-width:28px}}:host(.duet-spacer-horizontal.xx-large){width:28px;min-width:28px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.xx-large){width:36px;min-width:36px}}:host(.duet-spacer-horizontal.xxx-large){width:36px;min-width:36px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.xxx-large){width:48px;min-width:48px}}:host(.duet-spacer-horizontal.xxxx-large){width:48px;min-width:48px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.xxxx-large){width:72px;min-width:72px}}:host(.duet-spacer-vertical.xx-small){width:100%;height:4px;min-height:4px}:host(.duet-spacer-vertical.x-small){width:100%;height:4px;min-height:4px}@media (min-width: 36em){:host(.duet-spacer-vertical.x-small){height:8px;min-height:8px}}:host(.duet-spacer-vertical.small){width:100%;height:8px;min-height:8px}@media (min-width: 36em){:host(.duet-spacer-vertical.small){height:12px;min-height:12px}}:host(.duet-spacer-vertical.medium){width:100%}:host(.duet-spacer-vertical.large){width:100%;height:16px;min-height:16px}@media (min-width: 36em){:host(.duet-spacer-vertical.large){height:20px;min-height:20px}}:host(.duet-spacer-vertical.x-large){width:100%;height:20px;min-height:20px}@media (min-width: 36em){:host(.duet-spacer-vertical.x-large){height:28px;min-height:28px}}:host(.duet-spacer-vertical.xx-large){width:100%;height:28px;min-height:28px}@media (min-width: 36em){:host(.duet-spacer-vertical.xx-large){height:36px;min-height:36px}}:host(.duet-spacer-vertical.xxx-large){width:100%;height:36px;min-height:36px}@media (min-width: 36em){:host(.duet-spacer-vertical.xxx-large){height:48px;min-height:48px}}:host(.duet-spacer-vertical.xxxx-large){width:100%;height:48px;min-height:48px}@media (min-width: 36em){:host(.duet-spacer-vertical.xxxx-large){height:72px;min-height:72px}}:host(.duet-spacer-xx-small){display:none}@media (max-width: 22.5em){:host(.duet-spacer-xx-small){display:block}}:host(.duet-spacer-x-small){display:none}@media (max-width: 35.9375em){:host(.duet-spacer-x-small){display:block}}:host(.duet-spacer-small){display:none}@media (min-width: 36em){:host(.duet-spacer-small){display:block}}:host(.duet-spacer-medium){display:none}@media (min-width: 48em){:host(.duet-spacer-medium){display:block}}:host(.duet-spacer-large){display:none}@media (min-width: 62em){:host(.duet-spacer-large){display:block}}:host(.duet-spacer-x-large){display:none}@media (min-width: 64.0625em){:host(.duet-spacer-x-large){display:block}}:host(.duet-spacer-xx-large){display:none}@media (min-width: 76.25em){:host(.duet-spacer-xx-large){display:block}}";var DuetSpacer=function(){function e(e){registerInstance(this,e);this.size="medium";this.direction="vertical";this.breakpoint=""}e.prototype.render=function(){var e;return h(Host,{class:(e={"duet-spacer":true,"duet-spacer-xx-small":this.breakpoint==="xx-small","duet-spacer-x-small":this.breakpoint==="x-small","duet-spacer-small":this.breakpoint==="small","duet-spacer-medium":this.breakpoint==="medium","duet-spacer-large":this.breakpoint==="large","duet-spacer-x-large":this.breakpoint==="x-large","duet-spacer-xx-large":this.breakpoint==="xx-large"},e[this.size]=true,e["duet-spacer-".concat(this.direction)]=true,e)})};return e}();DuetSpacer.style=duetSpacerCss;export{DuetDivider as duet_divider,DuetSpacer as duet_spacer};
4
+ import{r as registerInstance,h,g as getElement,H as Host}from"./index-11a2e0a0.js";import{i as inheritGlobalTheme}from"./themeable-component-cb76be7c.js";import{g as getColorByName}from"./token-utils-b531747a.js";import"./tokens.module-d3321092.js";var duetDividerCss="*,*::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-divider{-webkit-user-select:none;user-select:none;display:block;width:100%;height:1px;margin-top:36px !important;margin-bottom:28px;background:#e1e3e6}.duet-divider.duet-p-0{padding:0 !important}.duet-divider.duet-m-0{margin:0 !important}.duet-divider.duet-m-s{margin-bottom:16px !important;margin-top:0 !important}.duet-divider.duet-theme-turva{background:#e4e4e6}";var DuetDivider=function(){function e(e){registerInstance(this,e);this.theme="";this.margin="auto";this.color=""}e.prototype.componentWillLoad=function(){inheritGlobalTheme(this)};e.prototype.render=function(){var e=getColorByName(this.color);return h("div",{class:{"duet-m-0":this.margin==="none","duet-m-s":this.margin==="small","duet-divider":true,"duet-theme-turva":this.theme==="turva"},style:{background:e}})};Object.defineProperty(e.prototype,"element",{get:function(){return getElement(this)},enumerable:false,configurable:true});return e}();DuetDivider.style=duetDividerCss;var duetSpacerCss=":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:12px;min-width:12px;height:12px}@media (min-width: 36em){:host{width:16px;min-width:16px;height:16px}}:host(.duet-spacer-horizontal){display:inline-block;height:100% !important}:host(.duet-spacer-horizontal.xx-small){width:4px;min-width:4px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.xx-small){width:4px;min-width:4px}}:host(.duet-spacer-horizontal.x-small){width:4px;min-width:4px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.x-small){width:8px;min-width:8px}}:host(.duet-spacer-horizontal.small){width:8px;min-width:8px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.small){width:12px;min-width:12px}}:host(.duet-spacer-horizontal.medium){height:100%}:host(.duet-spacer-horizontal.large){width:16px;min-width:16px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.large){width:20px;min-width:20px}}:host(.duet-spacer-horizontal.x-large){width:20px;min-width:20px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.x-large){width:28px;min-width:28px}}:host(.duet-spacer-horizontal.xx-large){width:28px;min-width:28px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.xx-large){width:36px;min-width:36px}}:host(.duet-spacer-horizontal.xxx-large){width:36px;min-width:36px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.xxx-large){width:48px;min-width:48px}}:host(.duet-spacer-horizontal.xxxx-large){width:48px;min-width:48px;height:100%}@media (min-width: 36em){:host(.duet-spacer-horizontal.xxxx-large){width:72px;min-width:72px}}:host(.duet-spacer-vertical.xx-small){width:100%;height:4px;min-height:4px}:host(.duet-spacer-vertical.x-small){width:100%;height:4px;min-height:4px}@media (min-width: 36em){:host(.duet-spacer-vertical.x-small){height:8px;min-height:8px}}:host(.duet-spacer-vertical.small){width:100%;height:8px;min-height:8px}@media (min-width: 36em){:host(.duet-spacer-vertical.small){height:12px;min-height:12px}}:host(.duet-spacer-vertical.medium){width:100%}:host(.duet-spacer-vertical.large){width:100%;height:16px;min-height:16px}@media (min-width: 36em){:host(.duet-spacer-vertical.large){height:20px;min-height:20px}}:host(.duet-spacer-vertical.x-large){width:100%;height:20px;min-height:20px}@media (min-width: 36em){:host(.duet-spacer-vertical.x-large){height:28px;min-height:28px}}:host(.duet-spacer-vertical.xx-large){width:100%;height:28px;min-height:28px}@media (min-width: 36em){:host(.duet-spacer-vertical.xx-large){height:36px;min-height:36px}}:host(.duet-spacer-vertical.xxx-large){width:100%;height:36px;min-height:36px}@media (min-width: 36em){:host(.duet-spacer-vertical.xxx-large){height:48px;min-height:48px}}:host(.duet-spacer-vertical.xxxx-large){width:100%;height:48px;min-height:48px}@media (min-width: 36em){:host(.duet-spacer-vertical.xxxx-large){height:72px;min-height:72px}}:host(.duet-spacer-xx-small){display:none}@media (max-width: 22.5em){:host(.duet-spacer-xx-small){display:block}}:host(.duet-spacer-x-small){display:none}@media (max-width: 35.9375em){:host(.duet-spacer-x-small){display:block}}:host(.duet-spacer-small){display:none}@media (min-width: 36em){:host(.duet-spacer-small){display:block}}:host(.duet-spacer-medium){display:none}@media (min-width: 48em){:host(.duet-spacer-medium){display:block}}:host(.duet-spacer-large){display:none}@media (min-width: 62em){:host(.duet-spacer-large){display:block}}:host(.duet-spacer-x-large){display:none}@media (min-width: 64.0625em){:host(.duet-spacer-x-large){display:block}}:host(.duet-spacer-xx-large){display:none}@media (min-width: 76.25em){:host(.duet-spacer-xx-large){display:block}}";var DuetSpacer=function(){function e(e){registerInstance(this,e);this.size="medium";this.direction="vertical";this.breakpoint=""}e.prototype.render=function(){var e;return h(Host,{class:(e={"duet-spacer":true,"duet-spacer-xx-small":this.breakpoint==="xx-small","duet-spacer-x-small":this.breakpoint==="x-small","duet-spacer-small":this.breakpoint==="small","duet-spacer-medium":this.breakpoint==="medium","duet-spacer-large":this.breakpoint==="large","duet-spacer-x-large":this.breakpoint==="x-large","duet-spacer-xx-large":this.breakpoint==="xx-large"},e[this.size]=true,e["duet-spacer-".concat(this.direction)]=true,e)})};return e}();DuetSpacer.style=duetSpacerCss;export{DuetDivider as duet_divider,DuetSpacer as duet_spacer};