@designsystem-se/af 39.2.2 → 39.2.3

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 (196) hide show
  1. package/components/digi-expandable-accordion.js +18 -11
  2. package/components/digi-expandable-faq-item.js +21 -14
  3. package/components/digi-info-card.js +3 -3
  4. package/custom-elements.json +1 -1
  5. package/dist/cjs/badge-notification-shape.enum-CEyEo2G5.js +8 -0
  6. package/dist/cjs/button-size.enum-DgyvMkwE.js +7 -0
  7. package/dist/cjs/{button-variation.enum-ngMqFLdW.js → button-variation.enum-DkUalo9f.js} +0 -6
  8. package/dist/cjs/{calendar-week-view-heading-level.enum-BI2f9bbk.js → calendar-week-view-heading-level.enum-NEkm5SUq.js} +0 -7
  9. package/dist/cjs/digi-arbetsformedlingen.cjs.js +1 -1
  10. package/dist/cjs/digi-badge-notification.cjs.entry.js +65 -0
  11. package/dist/cjs/digi-button.cjs.entry.js +131 -0
  12. package/dist/cjs/{digi-badge-notification_8.cjs.entry.js → digi-calendar-week-view.cjs.entry.js} +72 -645
  13. package/dist/cjs/{digi-calendar-datepicker.cjs.entry.js → digi-calendar_19.cjs.entry.js} +1613 -56
  14. package/dist/cjs/digi-code-block_3.cjs.entry.js +8 -13
  15. package/dist/cjs/digi-code-example.cjs.entry.js +4 -3
  16. package/dist/cjs/digi-dialog.cjs.entry.js +8 -13
  17. package/dist/cjs/digi-footer.cjs.entry.js +7 -12
  18. package/dist/cjs/digi-form-error-list.cjs.entry.js +7 -12
  19. package/dist/cjs/digi-form-file-upload.cjs.entry.js +9 -10
  20. package/dist/cjs/digi-form-input-search.cjs.entry.js +5 -6
  21. package/dist/cjs/digi-form-receipt.cjs.entry.js +7 -12
  22. package/dist/cjs/digi-form-select-filter.cjs.entry.js +8 -13
  23. package/dist/cjs/digi-header-navigation.cjs.entry.js +7 -12
  24. package/dist/cjs/digi-header.cjs.entry.js +7 -12
  25. package/dist/cjs/digi-info-card.cjs.entry.js +3 -3
  26. package/dist/cjs/digi-navigation-pagination.cjs.entry.js +7 -12
  27. package/dist/cjs/digi-notification-alert.cjs.entry.js +7 -12
  28. package/dist/cjs/digi-notification-error-page.cjs.entry.js +7 -12
  29. package/dist/cjs/digi-tablist-panel.cjs.entry.js +20 -0
  30. package/dist/cjs/digi-tablist.cjs.entry.js +312 -0
  31. package/dist/cjs/digi-title-logo.cjs.entry.js +7 -12
  32. package/dist/cjs/digi-tools-feedback.cjs.entry.js +9 -14
  33. package/dist/cjs/{form-input-type.enum-DvF_MTHK.js → form-input-type.enum-CCCcY8gv.js} +7 -0
  34. package/dist/cjs/{form-file-upload-variation.enum-xcEOoggr.js → form-validation-message-variation.enum-DgkifAnP.js} +7 -0
  35. package/dist/cjs/index-Cn1hHaSy.js +16 -40
  36. package/dist/cjs/{index-Bdlw-Iuy.js → index-DUQtADgG.js} +189 -19
  37. package/dist/cjs/index.cjs.js +64 -69
  38. package/dist/cjs/loader.cjs.js +1 -1
  39. package/dist/cjs/{typography-variation.enum-BDSt7CVI.js → typography-variation.enum-CVUvogxJ.js} +86 -0
  40. package/dist/collection/components/_expandable/expandable-accordion/expandable-accordion.js +18 -11
  41. package/dist/collection/components/_expandable/expandable-faq-item/expandable-faq-item.js +21 -14
  42. package/dist/collection/components/_info-card/info-card/info-card.js +5 -5
  43. package/dist/collection/design-tokens/components/_logo.variables.scss +0 -2
  44. package/dist/digi-arbetsformedlingen/digi-arbetsformedlingen.esm.js +1 -1
  45. package/dist/digi-arbetsformedlingen/index.esm.js +1 -1
  46. package/dist/digi-arbetsformedlingen/p-0230ec9b.entry.js +1 -0
  47. package/dist/digi-arbetsformedlingen/p-0394e694.entry.js +1 -0
  48. package/dist/digi-arbetsformedlingen/p-04bbbd14.entry.js +1 -0
  49. package/dist/digi-arbetsformedlingen/p-0cf25433.entry.js +1 -0
  50. package/dist/digi-arbetsformedlingen/p-17824a0b.entry.js +1 -0
  51. package/dist/digi-arbetsformedlingen/p-25815f15.entry.js +1 -0
  52. package/dist/digi-arbetsformedlingen/p-3d4ac22e.entry.js +1 -0
  53. package/dist/digi-arbetsformedlingen/p-4aefce1e.entry.js +1 -0
  54. package/dist/digi-arbetsformedlingen/p-5ee5766d.entry.js +1 -0
  55. package/dist/digi-arbetsformedlingen/p-870a00f8.entry.js +1 -0
  56. package/dist/digi-arbetsformedlingen/p-88dc2ed4.entry.js +1 -0
  57. package/dist/digi-arbetsformedlingen/p-9n7Okhf1.js +1 -0
  58. package/dist/digi-arbetsformedlingen/p-C6S1HfeA.js +1 -0
  59. package/dist/digi-arbetsformedlingen/p-C7xgnp99.js +1 -0
  60. package/dist/digi-arbetsformedlingen/p-CKoZU0-H.js +1 -0
  61. package/dist/digi-arbetsformedlingen/p-Cnyfh_8_.js +1 -0
  62. package/dist/digi-arbetsformedlingen/{p-DwNlf6Sh.js → p-DH_-wpLB.js} +1 -1
  63. package/dist/digi-arbetsformedlingen/p-Zivp2NJB.js +1 -0
  64. package/dist/digi-arbetsformedlingen/p-a29b6fff.entry.js +1 -0
  65. package/dist/digi-arbetsformedlingen/{p-375ea6f8.entry.js → p-ace2e5fd.entry.js} +1 -1
  66. package/dist/digi-arbetsformedlingen/p-b411a549.entry.js +1 -0
  67. package/dist/digi-arbetsformedlingen/p-b7712996.entry.js +1 -0
  68. package/dist/digi-arbetsformedlingen/p-bfccf413.entry.js +1 -0
  69. package/dist/digi-arbetsformedlingen/p-cdd65abb.entry.js +1 -0
  70. package/dist/digi-arbetsformedlingen/p-d4406627.entry.js +1 -0
  71. package/dist/digi-arbetsformedlingen/p-dd95c75e.entry.js +1 -0
  72. package/dist/digi-arbetsformedlingen/p-e5396b1e.entry.js +1 -0
  73. package/dist/digi-arbetsformedlingen/p-e7c10f6a.entry.js +1 -0
  74. package/dist/digi-arbetsformedlingen/p-f91295ac.entry.js +1 -0
  75. package/dist/digi-arbetsformedlingen/p-ffb4fac6.entry.js +1 -0
  76. package/dist/digi-arbetsformedlingen/p-y5Nm4oWF.js +1 -0
  77. package/dist/esm/badge-notification-shape.enum-CKoZU0-H.js +8 -0
  78. package/dist/esm/button-size.enum-C7xgnp99.js +7 -0
  79. package/dist/esm/{button-variation.enum-BMQm4N5I.js → button-variation.enum-y5Nm4oWF.js} +1 -7
  80. package/dist/esm/{calendar-week-view-heading-level.enum-BBOpiDGx.js → calendar-week-view-heading-level.enum-DH_-wpLB.js} +1 -8
  81. package/dist/esm/digi-arbetsformedlingen.js +1 -1
  82. package/dist/esm/digi-badge-notification.entry.js +63 -0
  83. package/dist/esm/digi-button.entry.js +129 -0
  84. package/dist/esm/{digi-badge-notification_8.entry.js → digi-calendar-week-view.entry.js} +6 -572
  85. package/dist/esm/{digi-calendar-datepicker.entry.js → digi-calendar_19.entry.js} +1557 -18
  86. package/dist/esm/digi-code-block_3.entry.js +7 -12
  87. package/dist/esm/digi-code-example.entry.js +2 -1
  88. package/dist/esm/digi-dialog.entry.js +7 -12
  89. package/dist/esm/digi-footer.entry.js +7 -12
  90. package/dist/esm/digi-form-error-list.entry.js +7 -12
  91. package/dist/esm/digi-form-file-upload.entry.js +1 -2
  92. package/dist/esm/digi-form-input-search.entry.js +1 -2
  93. package/dist/esm/digi-form-receipt.entry.js +7 -12
  94. package/dist/esm/digi-form-select-filter.entry.js +7 -12
  95. package/dist/esm/digi-header-navigation.entry.js +7 -12
  96. package/dist/esm/digi-header.entry.js +7 -12
  97. package/dist/esm/digi-info-card.entry.js +3 -3
  98. package/dist/esm/digi-navigation-pagination.entry.js +7 -12
  99. package/dist/esm/digi-notification-alert.entry.js +7 -12
  100. package/dist/esm/digi-notification-error-page.entry.js +7 -12
  101. package/dist/esm/digi-tablist-panel.entry.js +18 -0
  102. package/dist/esm/digi-tablist.entry.js +310 -0
  103. package/dist/esm/digi-title-logo.entry.js +7 -12
  104. package/dist/esm/digi-tools-feedback.entry.js +7 -12
  105. package/dist/esm/{form-input-type.enum-BSJH8Lpg.js → form-input-type.enum-C6S1HfeA.js} +8 -1
  106. package/dist/esm/{form-file-upload-variation.enum-BfyJgcLA.js → form-validation-message-variation.enum-9n7Okhf1.js} +8 -1
  107. package/dist/esm/index-BnKuq1L7.js +16 -40
  108. package/dist/esm/{index-B1Je6g2n.js → index-Cnyfh_8_.js} +170 -3
  109. package/dist/esm/index.js +7 -12
  110. package/dist/esm/loader.js +1 -1
  111. package/dist/esm/{typography-variation.enum-4smNltRI.js → typography-variation.enum-Zivp2NJB.js} +87 -1
  112. package/dist/types/components/_info-card/info-card/info-card.d.ts +2 -2
  113. package/dist/types/components.d.ts +4 -4
  114. package/hydrate/index.js +42 -28
  115. package/hydrate/index.mjs +42 -28
  116. package/package.json +1 -1
  117. package/dist/cjs/digi-calendar_2.cjs.entry.js +0 -490
  118. package/dist/cjs/digi-expandable-accordion.cjs.entry.js +0 -121
  119. package/dist/cjs/digi-expandable-faq-item.cjs.entry.js +0 -119
  120. package/dist/cjs/digi-form-input.cjs.entry.js +0 -205
  121. package/dist/cjs/digi-form-label_3.cjs.entry.js +0 -147
  122. package/dist/cjs/digi-form-select_2.cjs.entry.js +0 -201
  123. package/dist/cjs/digi-icon-chevron-down.cjs.entry.js +0 -28
  124. package/dist/cjs/digi-icon-validation-error_2.cjs.entry.js +0 -51
  125. package/dist/cjs/digi-typography-heading-jumbo.cjs.entry.js +0 -46
  126. package/dist/cjs/digi-util-keydown-handler.cjs.entry.js +0 -81
  127. package/dist/cjs/expandable-accordion-header-level.enum-CjL9V3Kt.js +0 -11
  128. package/dist/cjs/expandable-faq-item-variation.enum-aKkYAQgd.js +0 -18
  129. package/dist/cjs/form-input-search-variation.enum-VVfvlVeM.js +0 -8
  130. package/dist/cjs/form-input-variation.enum-kpoXNUuI.js +0 -29
  131. package/dist/cjs/form-select-variation.enum-e6wjWyaS.js +0 -16
  132. package/dist/cjs/form-validation-message-variation.enum-BA5nmCiw.js +0 -8
  133. package/dist/cjs/index-Snltmefx.js +0 -174
  134. package/dist/cjs/index-r0sb9TCr.js +0 -66
  135. package/dist/cjs/typography-heading-jumbo-variation.enum-Di1Jeh0G.js +0 -17
  136. package/dist/digi-arbetsformedlingen/p-037a35bd.entry.js +0 -1
  137. package/dist/digi-arbetsformedlingen/p-0f7e995a.entry.js +0 -1
  138. package/dist/digi-arbetsformedlingen/p-26f6a310.entry.js +0 -1
  139. package/dist/digi-arbetsformedlingen/p-3239fb1a.entry.js +0 -1
  140. package/dist/digi-arbetsformedlingen/p-3b42582a.entry.js +0 -1
  141. package/dist/digi-arbetsformedlingen/p-3c1f9629.entry.js +0 -1
  142. package/dist/digi-arbetsformedlingen/p-4384644b.entry.js +0 -1
  143. package/dist/digi-arbetsformedlingen/p-4ddcae7b.entry.js +0 -1
  144. package/dist/digi-arbetsformedlingen/p-4smNltRI.js +0 -1
  145. package/dist/digi-arbetsformedlingen/p-569c628c.entry.js +0 -1
  146. package/dist/digi-arbetsformedlingen/p-668d38d9.entry.js +0 -1
  147. package/dist/digi-arbetsformedlingen/p-66f34ca5.entry.js +0 -1
  148. package/dist/digi-arbetsformedlingen/p-6931825c.entry.js +0 -1
  149. package/dist/digi-arbetsformedlingen/p-6cb1c6ea.entry.js +0 -1
  150. package/dist/digi-arbetsformedlingen/p-71a8478d.entry.js +0 -1
  151. package/dist/digi-arbetsformedlingen/p-7688502e.entry.js +0 -1
  152. package/dist/digi-arbetsformedlingen/p-91265ee0.entry.js +0 -1
  153. package/dist/digi-arbetsformedlingen/p-9a4eecde.entry.js +0 -1
  154. package/dist/digi-arbetsformedlingen/p-9df345c4.entry.js +0 -1
  155. package/dist/digi-arbetsformedlingen/p-B8hpiXmh.js +0 -1
  156. package/dist/digi-arbetsformedlingen/p-BBOpiDGx.js +0 -1
  157. package/dist/digi-arbetsformedlingen/p-BMQm4N5I.js +0 -1
  158. package/dist/digi-arbetsformedlingen/p-BSJH8Lpg.js +0 -1
  159. package/dist/digi-arbetsformedlingen/p-BfyJgcLA.js +0 -1
  160. package/dist/digi-arbetsformedlingen/p-BixPaBHw.js +0 -1
  161. package/dist/digi-arbetsformedlingen/p-BvWKyXb_.js +0 -1
  162. package/dist/digi-arbetsformedlingen/p-C6B2KRZo.js +0 -1
  163. package/dist/digi-arbetsformedlingen/p-CgSR-RTl.js +0 -1
  164. package/dist/digi-arbetsformedlingen/p-DCS1KcvC.js +0 -1
  165. package/dist/digi-arbetsformedlingen/p-DNjGvZvz.js +0 -1
  166. package/dist/digi-arbetsformedlingen/p-DfWZa2Wv.js +0 -1
  167. package/dist/digi-arbetsformedlingen/p-a9a1bf57.entry.js +0 -1
  168. package/dist/digi-arbetsformedlingen/p-beebbc90.entry.js +0 -1
  169. package/dist/digi-arbetsformedlingen/p-c7ade486.entry.js +0 -1
  170. package/dist/digi-arbetsformedlingen/p-d065e751.entry.js +0 -1
  171. package/dist/digi-arbetsformedlingen/p-d07a1377.entry.js +0 -1
  172. package/dist/digi-arbetsformedlingen/p-d0b3c35b.entry.js +0 -1
  173. package/dist/digi-arbetsformedlingen/p-d150094c.entry.js +0 -1
  174. package/dist/digi-arbetsformedlingen/p-df8efa59.entry.js +0 -1
  175. package/dist/digi-arbetsformedlingen/p-e2b0b070.entry.js +0 -1
  176. package/dist/digi-arbetsformedlingen/p-e7b311da.entry.js +0 -1
  177. package/dist/digi-arbetsformedlingen/p-xwICssEK.js +0 -1
  178. package/dist/esm/digi-calendar_2.entry.js +0 -487
  179. package/dist/esm/digi-expandable-accordion.entry.js +0 -119
  180. package/dist/esm/digi-expandable-faq-item.entry.js +0 -117
  181. package/dist/esm/digi-form-input.entry.js +0 -203
  182. package/dist/esm/digi-form-label_3.entry.js +0 -143
  183. package/dist/esm/digi-form-select_2.entry.js +0 -198
  184. package/dist/esm/digi-icon-chevron-down.entry.js +0 -26
  185. package/dist/esm/digi-icon-validation-error_2.entry.js +0 -48
  186. package/dist/esm/digi-typography-heading-jumbo.entry.js +0 -44
  187. package/dist/esm/digi-util-keydown-handler.entry.js +0 -79
  188. package/dist/esm/expandable-accordion-header-level.enum-DwNlf6Sh.js +0 -11
  189. package/dist/esm/expandable-faq-item-variation.enum-C6B2KRZo.js +0 -18
  190. package/dist/esm/form-input-search-variation.enum-BvWKyXb_.js +0 -8
  191. package/dist/esm/form-input-variation.enum-DfWZa2Wv.js +0 -29
  192. package/dist/esm/form-select-variation.enum-DCS1KcvC.js +0 -16
  193. package/dist/esm/form-validation-message-variation.enum-B8hpiXmh.js +0 -8
  194. package/dist/esm/index-BixPaBHw.js +0 -170
  195. package/dist/esm/index-BsIL3T_0.js +0 -63
  196. package/dist/esm/typography-heading-jumbo-variation.enum-DNjGvZvz.js +0 -17
@@ -1,26 +1,27 @@
1
1
  import { r as registerInstance, c as createEvent, h, a as Host, d as getElement } from './index-BnKuq1L7.js';
2
+ import { r as randomIdGenerator } from './randomIdGenerator.util-BGaIliX6.js';
3
+ import { d as detectClickOutside } from './detectClickOutside.util-ROzp1Ej2.js';
4
+ import { d as detectFocusOutside } from './detectFocusOutside.util-aFLLVVle.js';
5
+ import { l as logger } from './logger.util-DdB9j8uV.js';
2
6
  import { _ as _t } from './text-DsO1BTml.js';
3
- import './calendar-week-view-heading-level.enum-BBOpiDGx.js';
4
- import { C as CalendarDatepickerValidation } from './typography-variation.enum-4smNltRI.js';
7
+ import { r as requiredArgs, t as toDate, a as toInteger, g as getUTCISOWeek, b as getUTCWeek, s as startOfUTCISOWeek, c as startOfUTCWeek, d as getUTCWeekYear, l as locale, e as longFormatters, i as isProtectedWeekYearToken, f as throwProtectedError, h as isProtectedDayOfYearToken, j as subMilliseconds, k as getTimezoneOffsetInMilliseconds, m as isValid } from './index-Cnyfh_8_.js';
8
+ import './badge-notification-shape.enum-CKoZU0-H.js';
9
+ import { C as CalendarDatepickerValidation, h as FormInputValidation, E as ExpandableAccordionHeaderLevel, d as ExpandableFaqItemHeadingLevel, e as ExpandableFaqItemVariation, g as FormInputMode, i as FormInputVariation, s as FormSelectVariation, r as FormSelectValidation, J as TypographyHeadingJumboLevel, K as TypographyHeadingJumboVariation } from './typography-variation.enum-Zivp2NJB.js';
5
10
  import './badge-status-variation.enum-C0A-p3cU.js';
6
- import './button-variation.enum-BMQm4N5I.js';
11
+ import './button-size.enum-C7xgnp99.js';
7
12
  import './button-type.enum-DShzaNrQ.js';
13
+ import './button-variation.enum-y5Nm4oWF.js';
14
+ import './calendar-week-view-heading-level.enum-DH_-wpLB.js';
8
15
  import './bar-chart-variation.enum-DPeoHh1J.js';
9
16
  import './code-example-variation.enum-DGI7Jkg2.js';
10
17
  import './code-variation.enum-qc6KRZue.js';
11
- import './expandable-accordion-header-level.enum-DwNlf6Sh.js';
12
- import './expandable-faq-item-variation.enum-C6B2KRZo.js';
13
18
  import './expandable-faq-variation.enum-CES5gUEo.js';
14
19
  import './footer-card-variation.enum-DzSu1-K0.js';
15
20
  import './form-checkbox-variation.enum-6-MpaVf8.js';
16
- import './form-file-upload-variation.enum-BfyJgcLA.js';
17
- import './form-input-search-variation.enum-BvWKyXb_.js';
18
- import './form-input-type.enum-BSJH8Lpg.js';
19
- import { a as FormInputValidation } from './form-input-variation.enum-DfWZa2Wv.js';
21
+ import { c as FormValidationMessageVariation } from './form-validation-message-variation.enum-9n7Okhf1.js';
22
+ import { b as FormInputType, a as FormInputButtonVariation } from './form-input-type.enum-C6S1HfeA.js';
20
23
  import './form-radiogroup-validation.enum-DcnvI7UR.js';
21
- import './form-select-variation.enum-DCS1KcvC.js';
22
24
  import './form-textarea-variation.enum-DogB9kfH.js';
23
- import './form-validation-message-variation.enum-B8hpiXmh.js';
24
25
  import './info-card-multi-type.enum-CkIb3cUS.js';
25
26
  import './info-card-variation.enum-_ycZeBN4.js';
26
27
  import './layout-container-max-width.enum-CuhrrYGE.js';
@@ -46,15 +47,10 @@ import './tag-size.enum-bQJ38En_.js';
46
47
  import './tools-feedback-banner-type.enum-DrVSK7Ws.js';
47
48
  import './tools-feedback-rating-variation.enum-CAmn5qzb.js';
48
49
  import './tools-theme-provider.brand.enum-DpDyNuVC.js';
49
- import './typography-heading-jumbo-variation.enum-DNjGvZvz.js';
50
50
  import './typography-meta-variation.enum-CHxBAbI8.js';
51
51
  import './typography-time-variation.enum-rhVqmQwC.js';
52
52
  import './util-breakpoint-observer-breakpoints.enum-DPq588Q4.js';
53
- import { r as randomIdGenerator } from './randomIdGenerator.util-BGaIliX6.js';
54
- import { d as detectClickOutside } from './detectClickOutside.util-ROzp1Ej2.js';
55
- import { r as requiredArgs, t as toDate, i as isValid } from './index-BixPaBHw.js';
56
- import { t as toInteger, g as getUTCISOWeek, a as getUTCWeek, o as startOfUTCISOWeek, p as startOfUTCWeek, c as getUTCWeekYear, l as locale, e as longFormatters, i as isProtectedWeekYearToken, f as throwProtectedError, h as isProtectedDayOfYearToken, s as subMilliseconds, d as getTimezoneOffsetInMilliseconds } from './index-B1Je6g2n.js';
57
- import { i as isBefore, a as isAfter } from './index-BsIL3T_0.js';
53
+ import { K as KEY_CODE, k as keyboardHandler } from './keyboardHandler.util-CflatMTG.js';
58
54
  import './detectClosest.util-DwBvm-Nc.js';
59
55
 
60
56
  function assign(target, dirtyObject) {
@@ -73,6 +69,66 @@ function assign(target, dirtyObject) {
73
69
  return target;
74
70
  }
75
71
 
72
+ /**
73
+ * @name isAfter
74
+ * @category Common Helpers
75
+ * @summary Is the first date after the second one?
76
+ *
77
+ * @description
78
+ * Is the first date after the second one?
79
+ *
80
+ * ### v2.0.0 breaking changes:
81
+ *
82
+ * - [Changes that are common for the whole library](https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#Common-Changes).
83
+ *
84
+ * @param {Date|Number} date - the date that should be after the other one to return true
85
+ * @param {Date|Number} dateToCompare - the date to compare with
86
+ * @returns {Boolean} the first date is after the second date
87
+ * @throws {TypeError} 2 arguments required
88
+ *
89
+ * @example
90
+ * // Is 10 July 1989 after 11 February 1987?
91
+ * var result = isAfter(new Date(1989, 6, 10), new Date(1987, 1, 11))
92
+ * //=> true
93
+ */
94
+
95
+ function isAfter(dirtyDate, dirtyDateToCompare) {
96
+ requiredArgs(2, arguments);
97
+ var date = toDate(dirtyDate);
98
+ var dateToCompare = toDate(dirtyDateToCompare);
99
+ return date.getTime() > dateToCompare.getTime();
100
+ }
101
+
102
+ /**
103
+ * @name isBefore
104
+ * @category Common Helpers
105
+ * @summary Is the first date before the second one?
106
+ *
107
+ * @description
108
+ * Is the first date before the second one?
109
+ *
110
+ * ### v2.0.0 breaking changes:
111
+ *
112
+ * - [Changes that are common for the whole library](https://github.com/date-fns/date-fns/blob/master/docs/upgradeGuide.md#Common-Changes).
113
+ *
114
+ * @param {Date|Number} date - the date that should be before the other one to return true
115
+ * @param {Date|Number} dateToCompare - the date to compare with
116
+ * @returns {Boolean} the first date is before the second date
117
+ * @throws {TypeError} 2 arguments required
118
+ *
119
+ * @example
120
+ * // Is 10 July 1989 before 11 February 1987?
121
+ * var result = isBefore(new Date(1989, 6, 10), new Date(1987, 1, 11))
122
+ * //=> false
123
+ */
124
+
125
+ function isBefore(dirtyDate, dirtyDateToCompare) {
126
+ requiredArgs(2, arguments);
127
+ var date = toDate(dirtyDate);
128
+ var dateToCompare = toDate(dirtyDateToCompare);
129
+ return date.getTime() < dateToCompare.getTime();
130
+ }
131
+
76
132
  // See issue: https://github.com/date-fns/date-fns/issues/376
77
133
 
78
134
  function setUTCDay(dirtyDate, dirtyDay, dirtyOptions) {
@@ -2177,6 +2233,460 @@ function cleanEscapedString(input) {
2177
2233
  return input.match(escapedStringRegExp)[1].replace(doubleQuoteRegExp, "'");
2178
2234
  }
2179
2235
 
2236
+ const calendarCss = () => `.sc-digi-calendar-h{--digi--calendar--display:inline-block;--digi--calendar--header--font-family:var(--digi--global--typography--font-family--default);--digi--calendar--header--font-weight:var(--digi--global--typography--font-weight--semibold);--digi--calendar--header--display:flex;--digi--calendar--header--align-items:center;--digi--calendar--header--justify-content:space-between;--digi--calendar--header--text-align:center;--digi--calendar--header--button--padding:var(--digi--gutter--medium) var(--digi--gutter--largest);--digi--calendar--header--button--background:transparent;--digi--calendar--header--button--box-shadow:none;--digi--calendar--header--button--background--hover:var(--digi--color--background--interactive--hover--secondary);--digi--calendar--table--border-spacing:0;--digi--calendar--table--border-collapse:collapse;--digi--calendar--table--font-family:var(--digi--global--typography--font-family--default);--digi--calendar--table--font-weight:var(--digi--global--typography--font-weight--semibold);--digi--calendar--table-header--padding:var(--digi--gutter--larger) 0;--digi--calendar--table-header--font-weight-normal:var(--digi--typography--body--font-weight--desktop);--digi--calendar--date--border-color:none;--digi--calendar--date--box-shadow:none;--digi--calendar--date--background-color:var(--digi--color--background--interactive--default--secondary);--digi--calendar--date--background-color--hover:var(--digi--color--background--interactive--hover--secondary);--digi--calendar--date--padding:var(--digi--gutter--large);--digi--calendar--date--color:var(--digi--color--text--primary);--digi--calendar--date--focused--background-color:var(--digi--color--background--interactive--hover--secondary);--digi--calendar--date--today--circle-border:2px solid var(--digi--color--marking--indication--secondary);--digi--calendar--date--today--circle-margin:10%;--digi--calendar--date--selected--color:var(--digi--color--text--interactive--secondary);--digi--calendar--date--selected--background-color:var(--digi--color--background--interactive--selected--primary);--digi--calendar--date--not-selectable-strike--color:var(--digi--color--marking--indication--tertiary);--digi--calendar--week--font-style:italic;--digi--calendar--week--font-size:var(--digi--global--typography--font-size--small);--digi--calendar--week--border-color:var(--digi--color--divider--primary);--digi--calendar--week--border-width:var(--digi--border-width--primary)}.sc-digi-calendar-h .digi-calendar.sc-digi-calendar{display:var(--digi--calendar--display);background:var(--digi--calendar--header--button--background);padding:0px 1px 3px 1px;overflow:hidden;max-width:23.4375rem}.sc-digi-calendar-h .digi-calendar--hide.sc-digi-calendar{--digi--calendar--display:none}.sc-digi-calendar-h .digi-calendar__header.sc-digi-calendar{display:var(--digi--calendar--header--display);align-items:var(--digi--calendar--header--align-items);justify-content:var(--digi--calendar--header--justify-content);text-align:var(--digi--calendar--header--text-align);font-size:var(--digi--global--typography--font-size--base);font-family:var(--digi--calendar--header--font-family);font-weight:var(--digi--calendar--header--font-weight)}.sc-digi-calendar-h .digi-calendar__header--year-select.sc-digi-calendar{display:inherit;justify-content:center;margin:0 auto}.sc-digi-calendar-h .digi-calendar__header--year-select.sc-digi-calendar digi-form-select.sc-digi-calendar:first-child{margin-right:var(--digi--padding--smaller)}.sc-digi-calendar-h .digi-calendar__header--year-select.sc-digi-calendar digi-form-select.sc-digi-calendar:last-child{width:5rem}.sc-digi-calendar-h .digi-calendar__header--year-select.sc-digi-calendar digi-form-select.sc-digi-calendar select.sc-digi-calendar{padding-inline-end:2rem}.sc-digi-calendar-h .digi-calendar__header--month-step.sc-digi-calendar{flex:auto;display:inherit;align-items:inherit;justify-content:inherit}.sc-digi-calendar-h .digi-calendar__header--month-step.sc-digi-calendar .digi-calendar__month-select-name.sc-digi-calendar{padding-inline:var(--digi--padding--smaller)}.sc-digi-calendar-h .digi-calendar__header--month-step.sc-digi-calendar .digi-calendar__month-select-button.sc-digi-calendar{font-family:inherit;font-size:inherit;font-weight:inherit;color:var(--digi--calendar--date--color);display:flex;align-items:center;background:var(--digi--calendar--header--button--background);border:var(--digi--calendar--date--box-shadow);padding:var(--digi--calendar--header--button--padding)}.sc-digi-calendar-h .digi-calendar__header--month-step.sc-digi-calendar .digi-calendar__month-select-button.sc-digi-calendar:last-child{border-radius:0 4px 0 0}.sc-digi-calendar-h .digi-calendar__header--month-step.sc-digi-calendar .digi-calendar__month-select-button.sc-digi-calendar:first-child{border-radius:4px 0 0 0}.sc-digi-calendar-h .digi-calendar__header--month-step.sc-digi-calendar .digi-calendar__month-select-button.sc-digi-calendar:focus-visible:not(.digi-calendar__date--not-selectable),.sc-digi-calendar-h .digi-calendar__header--month-step.sc-digi-calendar .digi-calendar__month-select-button.sc-digi-calendar:active:not(.digi-calendar__date--not-selectable){--digi--calendar--header--button--background:var(--digi--calendar--header--button--background--hover);text-decoration:underline;cursor:pointer}@media (any-hover: hover){.sc-digi-calendar-h .digi-calendar__header--month-step.sc-digi-calendar .digi-calendar__month-select-button.sc-digi-calendar:hover:not(.digi-calendar__date--not-selectable){--digi--calendar--header--button--background:var(--digi--calendar--header--button--background--hover);text-decoration:underline;cursor:pointer}}.sc-digi-calendar-h .digi-calendar__header--month-step.sc-digi-calendar .digi-calendar__month-select-button.sc-digi-calendar:focus-visible{outline:2px solid black;outline-offset:-3px;box-shadow:0px 0px 0px 5px inset white}.sc-digi-calendar-h .digi-calendar__table.sc-digi-calendar{border-collapse:var(--digi--calendar--table--border-collapse);border-spacing:var(--digi--calendar--table--border-spacing);font-family:var(--digi--calendar--table--font-family);table-layout:fixed;margin-bottom:var(--digi--margin--medium)}.sc-digi-calendar-h .digi-calendar__table.sc-digi-calendar th.sc-digi-calendar{text-align:center}.sc-digi-calendar-h .digi-calendar__table-header-week.sc-digi-calendar{font-style:italic;padding:var(--digi--calendar--table-header--padding);font-weight:var(--digi--calendar--table-header--font-weight-normal);width:50px}.sc-digi-calendar-h .digi-calendar__table-header.sc-digi-calendar{padding:var(--digi--calendar--table-header--padding);font-weight:var(--digi--calendar--table--font-weight);width:46px}.sc-digi-calendar-h .digi-calendar__td-week.sc-digi-calendar{border-right:var(--digi--calendar--week--border-width) solid var(--digi--calendar--week--border-color)}.sc-digi-calendar-h .digi-calendar__td.sc-digi-calendar{text-align:right}.sc-digi-calendar-h .digi-calendar__date--week-number.sc-digi-calendar{font-style:var(--digi--calendar--week--font-style);font-size:var(--digi--calendar--week--font-size);display:table-cell;text-align:center}.sc-digi-calendar-h .digi-calendar__date--week-number.sc-digi-calendar:hover{cursor:default}.sc-digi-calendar-h .digi-calendar__date.sc-digi-calendar{position:relative;padding:var(--digi--calendar--date--padding);color:var(--digi--calendar--date--color);background-color:var(--digi--calendar--date--background-color);border-color:var(--digi--calendar--date--border-color);border-radius:var(--digi--border-radius--secondary);font-family:inherit;font-size:inherit;font-weight:inherit;text-align:center;border:none;width:44px;height:44px}.sc-digi-calendar-h .digi-calendar__date--disabled.sc-digi-calendar{--digi--calendar--date--color:transparent;pointer-events:none}.sc-digi-calendar-h .digi-calendar__date--today.sc-digi-calendar{position:relative}.sc-digi-calendar-h .digi-calendar__date--today.sc-digi-calendar::after{display:block;content:" ";position:absolute;top:var(--digi--calendar--date--today--circle-margin);bottom:var(--digi--calendar--date--today--circle-margin);left:var(--digi--calendar--date--today--circle-margin);right:var(--digi--calendar--date--today--circle-margin);border:var(--digi--calendar--date--today--circle-border);border-radius:50%}.sc-digi-calendar-h .digi-calendar__date--today.digi-calendar__date--selected.sc-digi-calendar::after{border-color:var(--digi--color--icon--secondary)}@media (any-hover: hover){.sc-digi-calendar-h .digi-calendar__date.sc-digi-calendar:hover:not(.digi-calendar__date--not-selectable){cursor:pointer}.sc-digi-calendar-h .digi-calendar__date.sc-digi-calendar:hover:not(.digi-calendar__date--not-selectable):not(.digi-calendar__date--selected){--digi--calendar--date--box-shadow:var(--digi--calendar--date--box-shadow--hover);--digi--calendar--date--background-color:var(--digi--calendar--date--background-color--hover)}.sc-digi-calendar-h .digi-calendar__date.sc-digi-calendar:hover:not(.digi-calendar__date--not-selectable) span.sc-digi-calendar{text-decoration:underline}}.sc-digi-calendar-h .digi-calendar__date--selected.sc-digi-calendar{--digi--calendar--date--background-color:var(--digi--calendar--date--selected--background-color);--digi--calendar--date--color:var(--digi--calendar--date--selected--color)}.sc-digi-calendar-h .digi-calendar__date--selected.sc-digi-calendar:hover{--digi--calendar--date--background-color:var(--digi--calendar--date--selected--background-color)}.sc-digi-calendar-h .digi-calendar__date--selected.sc-digi-calendar:hover span.sc-digi-calendar{text-decoration:none}.sc-digi-calendar-h .digi-calendar__date--selected.sc-digi-calendar:focus-visible{outline:2px solid black;outline-offset:-3px;box-shadow:0px 0px 0px 5px inset white}.sc-digi-calendar-h .digi-calendar__date--not-selectable.sc-digi-calendar{cursor:not-allowed}.sc-digi-calendar-h .digi-calendar__date--not-selectable.sc-digi-calendar::after{display:block;content:" ";width:0px;height:100%;border:1px solid #757575;transform:rotate(-45deg);position:absolute;top:0%;left:50%}.sc-digi-calendar-h .digi-calendar__date--focused.sc-digi-calendar:focus-visible:not(.digi-calendar__date--selected):not(.digi-calendar__date--not-selectable){--digi--calendar--date--background-color:var(--digi--calendar--date--focused--background-color);outline:2px solid black;outline-offset:-3px;box-shadow:0px 0px 0px 5px inset white}.sc-digi-calendar-s digi-form-label{border:0;clip:rect(1px, 1px, 1px, 1px);-webkit-clip-path:inset(50%);clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;white-space:nowrap}`;
2237
+
2238
+ const Calendar = class {
2239
+ constructor(hostRef) {
2240
+ registerInstance(this, hostRef);
2241
+ this.afOnDateSelectedChange = createEvent(this, "afOnDateSelectedChange", 7);
2242
+ this.afOnFocusOutside = createEvent(this, "afOnFocusOutside", 7);
2243
+ this.afOnClickOutside = createEvent(this, "afOnClickOutside", 7);
2244
+ this.afOnDirty = createEvent(this, "afOnDirty", 7);
2245
+ this.selectedDates = [];
2246
+ this.dirty = false;
2247
+ /**
2248
+ * Prefix för komponentens 'id'-attribut. Ex. 'my-cool-id' genererar 'my-cool-id-calendar'. Ges inget värde genereras ett slumpmässigt.
2249
+ * @en Prefix for the component's 'id' attribute. Example: 'my-cool-id' generates 'my-cool-id-calendar'. Defaults to random string.
2250
+ */
2251
+ this.afId = randomIdGenerator('digi-calendar');
2252
+ /**
2253
+ * Visa veckonummer i kalender
2254
+ * @en Show week number in the calendar
2255
+ */
2256
+ this.afShowWeekNumber = false;
2257
+ /**
2258
+ * Valda datum i kalendern
2259
+ * @en Selected dates in calendar
2260
+ */
2261
+ this.afSelectedDates = [];
2262
+ /**
2263
+ * Visar eller döljer kalendern.
2264
+ * @en Toggle calendar hide/show.
2265
+ */
2266
+ this.afActive = true;
2267
+ /**
2268
+ * Sätt denna till true för att tillåta val av flera datum
2269
+ * @en Set this to true to be able to allow selection of multiple dates
2270
+ */
2271
+ this.afMultipleDates = false;
2272
+ /**
2273
+ * Sätt denna till true för att visa väljare för år
2274
+ * @en Set this to true to be show year selector
2275
+ */
2276
+ this.afYearSelect = false;
2277
+ this.activeCalendar = [];
2278
+ }
2279
+ focusedDateChanged() {
2280
+ this.drawCalendar(this.focusedDate);
2281
+ }
2282
+ afOpenCalendarToChangeHandler() {
2283
+ this.determineFocusedDate();
2284
+ }
2285
+ afShowWeekNumberChangeHandler() {
2286
+ this.drawCalendar(this.focusedDate);
2287
+ }
2288
+ afSelectedDateChangeHandler() {
2289
+ this.afSelectedDates = isValid(this.afSelectedDate)
2290
+ ? [this.afSelectedDate]
2291
+ : [];
2292
+ }
2293
+ afSelectedDatesChangeHandler() {
2294
+ if (this.afSelectedDates.length > 0) {
2295
+ if (this.afMultipleDates) {
2296
+ const invalidDate = this.afSelectedDates.find((date) => !isValid(date));
2297
+ if (invalidDate === undefined) {
2298
+ this.selectedDates = this.afSelectedDates;
2299
+ this.determineFocusedDate();
2300
+ }
2301
+ }
2302
+ else if (isValid(this.afSelectedDates[0])) {
2303
+ this.selectedDates = [this.afSelectedDates[0]];
2304
+ this.determineFocusedDate();
2305
+ }
2306
+ }
2307
+ else {
2308
+ this.selectedDates = [];
2309
+ }
2310
+ }
2311
+ focusoutHandler(e) {
2312
+ const target = e.target;
2313
+ const selector = `#${this.afId}-calendar`;
2314
+ if (detectFocusOutside(target, selector)) {
2315
+ this.afOnFocusOutside.emit(e);
2316
+ }
2317
+ }
2318
+ clickHandler(e) {
2319
+ const target = e.target;
2320
+ const selector = `#${this.afId}-calendar`;
2321
+ if (detectClickOutside(target, selector)) {
2322
+ this.afOnClickOutside.emit(e);
2323
+ }
2324
+ }
2325
+ determineFocusedDate() {
2326
+ if (this.dirty) {
2327
+ return; // Don't change focused date if user has already interacted with the calendar
2328
+ }
2329
+ else if (this.afOpenCalendarTo && isValid(this.afOpenCalendarTo)) {
2330
+ this.focusedDate = this.afOpenCalendarTo;
2331
+ }
2332
+ else if (this.selectedDates.length > 0) {
2333
+ this.focusedDate = this.selectedDates[0];
2334
+ }
2335
+ else {
2336
+ this.focusedDate = new Date();
2337
+ }
2338
+ }
2339
+ drawCalendar(focusedDate) {
2340
+ const date = {
2341
+ year: focusedDate.getFullYear(),
2342
+ month: focusedDate.getMonth()
2343
+ };
2344
+ this.lastWeekOfPreviousMonth = this.getWeekDays(this.getLastDayOfPrevMonth(date));
2345
+ this.firstWeekOfNextMonth = this.getWeekDays(this.getFirstDayOfNextMonth(date));
2346
+ this.weeksBetween = this.getWeeksBetween(this.getLastDayOfPrevMonth(date), this.getFirstDayOfNextMonth(date));
2347
+ this.weekDaysbetween = this.getWeekdaysOfMonth(this.weeksBetween);
2348
+ this.activeCalendar = this.appendFirstWeekOfNextMonth()
2349
+ ? [
2350
+ this.lastWeekOfPreviousMonth,
2351
+ ...this.weekDaysbetween,
2352
+ this.appendFirstWeekOfNextMonth()
2353
+ ]
2354
+ : [this.lastWeekOfPreviousMonth, ...this.weekDaysbetween];
2355
+ this.appendFirstWeekOfNextMonth();
2356
+ if (this.afShowWeekNumber) {
2357
+ this.activeCalendar.forEach((el, i) => {
2358
+ this.activeCalendar[i].unshift(this.getWeekNumbers(el[0]));
2359
+ });
2360
+ }
2361
+ }
2362
+ appendFirstWeekOfNextMonth() {
2363
+ const lastArray = JSON.stringify(this.weekDaysbetween.slice(-1)[0]);
2364
+ const stringFirstweek = JSON.stringify(this.firstWeekOfNextMonth);
2365
+ if (!this.firstWeekOfNextMonth.some((date) => this.isSameMonth(date, this.focusedDate))) {
2366
+ return;
2367
+ }
2368
+ else if (lastArray !== stringFirstweek) {
2369
+ return this.firstWeekOfNextMonth;
2370
+ }
2371
+ }
2372
+ getLastDayOfPrevMonth(date) {
2373
+ return new Date(date.year, date.month, 0);
2374
+ }
2375
+ getWeekDays(date) {
2376
+ const today = date || new Date();
2377
+ const week = [];
2378
+ const dayOffset = today.getDay(); // 0=söndag
2379
+ for (let i = 1; i <= 7; i++) {
2380
+ week.push(new Date(today.getFullYear(), today.getMonth(), today.getDate() - dayOffset + i));
2381
+ }
2382
+ return week;
2383
+ }
2384
+ getFirstDayOfNextMonth(date) {
2385
+ return new Date(date.year, date.month + 1, 1);
2386
+ }
2387
+ getWeeksBetween(lastDayOfPrevMonth, firstDayOnNextMonth) {
2388
+ const week = 7 * 24 * 60 * 60 * 1000;
2389
+ const d1ms = lastDayOfPrevMonth.getTime();
2390
+ const d2ms = firstDayOnNextMonth.getTime();
2391
+ const diff = Math.abs(d2ms - d1ms);
2392
+ return Math.floor(diff / week);
2393
+ }
2394
+ getWeekdaysOfMonth(weeksBetween) {
2395
+ let weeks = [];
2396
+ for (let i = 1; i <= weeksBetween; i++) {
2397
+ weeks = [...weeks, this.getWeekDays(this.getUpcoming(i))];
2398
+ }
2399
+ return weeks;
2400
+ }
2401
+ getUpcoming(weeks) {
2402
+ return new Date(this.focusedDate.getFullYear(), this.focusedDate.getMonth(), 7 * weeks);
2403
+ }
2404
+ onDirty() {
2405
+ if (!this.dirty) {
2406
+ this.dirty = true;
2407
+ this.afOnDirty.emit(this.dirty);
2408
+ }
2409
+ }
2410
+ selectDateHandler(dateSelected) {
2411
+ this.onDirty();
2412
+ if (!this.isDateSelectable(dateSelected))
2413
+ return;
2414
+ if (this.isDateSelected(dateSelected)) {
2415
+ this.selectedDates = this.afMultipleDates
2416
+ ? this.selectedDates.filter((d) => {
2417
+ return !this.isSameDate(d, dateSelected);
2418
+ })
2419
+ : [];
2420
+ }
2421
+ else {
2422
+ this.selectedDates = this.afMultipleDates
2423
+ ? [...this.selectedDates, dateSelected]
2424
+ : [dateSelected];
2425
+ }
2426
+ this.focusedDate = new Date(dateSelected);
2427
+ this.afOnDateSelectedChange.emit(this.selectedDates);
2428
+ }
2429
+ getMonthName(monthNumber) {
2430
+ return new Date(1992, monthNumber, 1)
2431
+ .toLocaleDateString(_t.locale, {
2432
+ month: 'short'
2433
+ })
2434
+ .replace('.', '');
2435
+ }
2436
+ getFullMonthName(monthNumber) {
2437
+ return new Date(this.focusedDate.getFullYear(), monthNumber, 1).toLocaleDateString(_t.locale, {
2438
+ month: 'long',
2439
+ year: 'numeric'
2440
+ });
2441
+ }
2442
+ // Get the week number of a specific date. Taken from https://weeknumber.com/how-to/javascript
2443
+ getWeekNumbers(dateInput) {
2444
+ const date = new Date(dateInput);
2445
+ date.getTime();
2446
+ date.setHours(0, 0, 0, 0);
2447
+ date.setDate(date.getDate() + 3 - ((date.getDay() + 6) % 7));
2448
+ const week1 = new Date(date.getFullYear(), 0, 4);
2449
+ return (1 +
2450
+ Math.round(((date.getTime() - week1.getTime()) / 86400000 -
2451
+ 3 +
2452
+ ((week1.getDay() + 6) % 7)) /
2453
+ 7));
2454
+ }
2455
+ isSameMonth(date, currentDate) {
2456
+ if (date instanceof Date && date instanceof Date) {
2457
+ return (`${date.getFullYear()}${date.getMonth()}` ===
2458
+ `${currentDate.getFullYear()}${currentDate.getMonth()}`);
2459
+ }
2460
+ return false;
2461
+ }
2462
+ isSameDate(date, newDate) {
2463
+ return this.getDateString(date) === this.getDateString(newDate);
2464
+ }
2465
+ getDateString(date) {
2466
+ return `${date.getDate()}${date.getMonth()}${date.getFullYear()}`;
2467
+ }
2468
+ isDateSelected(date) {
2469
+ return !!this.selectedDates.find((d) => this.isSameDate(date, d));
2470
+ }
2471
+ isDateSelectable(date) {
2472
+ if (this.afMinDate && this.isBefore(date, this.afMinDate))
2473
+ return false;
2474
+ if (this.afMaxDate && this.isAfter(date, this.afMaxDate))
2475
+ return false;
2476
+ return true;
2477
+ }
2478
+ isBefore(a, b) {
2479
+ return isBefore(this.dateWithoutTime(a), this.dateWithoutTime(b));
2480
+ }
2481
+ isAfter(a, b) {
2482
+ return isAfter(this.dateWithoutTime(a), this.dateWithoutTime(b));
2483
+ }
2484
+ dateWithoutTime(date) {
2485
+ return new Date(date.getFullYear(), date.getMonth(), date.getDate());
2486
+ }
2487
+ isInAnotherMonth(date) {
2488
+ return !this.isSameMonth(date, this.focusedDate);
2489
+ }
2490
+ subtractMonth() {
2491
+ this.onDirty();
2492
+ const month = new Date(this.focusedDate);
2493
+ const currentDay = month.getDate();
2494
+ month.setMonth(month.getMonth() - 1, 1);
2495
+ const lastDayOfPrevMonth = new Date(month.getFullYear(), month.getMonth() + 1, 0).getDate();
2496
+ month.setDate(Math.min(currentDay, lastDayOfPrevMonth));
2497
+ this.focusedDate = month;
2498
+ }
2499
+ addMonth() {
2500
+ this.onDirty();
2501
+ const month = new Date(this.focusedDate);
2502
+ const currentDay = month.getDate();
2503
+ month.setMonth(month.getMonth() + 1, 1);
2504
+ const lastDayOfNextMonth = new Date(month.getFullYear(), month.getMonth() + 1, 0).getDate();
2505
+ month.setDate(Math.min(currentDay, lastDayOfNextMonth));
2506
+ this.focusedDate = month;
2507
+ }
2508
+ getCurrent(date) {
2509
+ return this.isSameDate(date, new Date()) ? 'date' : null;
2510
+ }
2511
+ setTabIndex(date) {
2512
+ return this.isFocused(date) ? 0 : -1;
2513
+ }
2514
+ navigateHandler(e, daysToAdd) {
2515
+ !!e.detail && e.detail.preventDefault();
2516
+ if (e.detail.key === 'Tab') {
2517
+ return;
2518
+ }
2519
+ this.onDirty();
2520
+ const date = new Date(e.detail.target.dataset.date);
2521
+ const newDate = new Date(date.setDate(date.getDate() + daysToAdd));
2522
+ this.focusedDate = newDate;
2523
+ this.resetFocus();
2524
+ }
2525
+ resetFocus() {
2526
+ setTimeout(() => {
2527
+ const dates = this._tbody.querySelectorAll('.digi-calendar__date');
2528
+ if (dates.length <= 0) {
2529
+ logger.warn(`Could not find an element with data-date attribute matching navigated date.`, this._tbody);
2530
+ return;
2531
+ }
2532
+ Array.from(dates).map((date) => {
2533
+ const d = date;
2534
+ d.tabIndex = -1;
2535
+ d.classList.remove('digi-calendar__date--focused');
2536
+ if (d.dataset.date === this.getFullDate(this.focusedDate)) {
2537
+ d.focus();
2538
+ d.tabIndex = 0;
2539
+ d.classList.add('digi-calendar__date--focused');
2540
+ }
2541
+ });
2542
+ }, 100);
2543
+ }
2544
+ getFullDate(date) {
2545
+ return date.toLocaleString(_t.locale, {
2546
+ day: 'numeric',
2547
+ month: 'numeric',
2548
+ year: 'numeric'
2549
+ });
2550
+ }
2551
+ getDateName(date) {
2552
+ return date.toLocaleString(_t.locale, {
2553
+ year: 'numeric',
2554
+ month: 'long',
2555
+ day: 'numeric'
2556
+ });
2557
+ }
2558
+ isFocused(date) {
2559
+ if (this.dirty) {
2560
+ return this.isSameDate(date, this.focusedDate);
2561
+ }
2562
+ if (this.afOpenCalendarTo) {
2563
+ return this.isSameDate(date, this.afOpenCalendarTo);
2564
+ }
2565
+ return this.isSameMonth(date, new Date())
2566
+ ? this.isSameDate(date, new Date())
2567
+ : this.isSameMonth(date, this.focusedDate) && date.getDate() === 1;
2568
+ }
2569
+ ariaPressed(date) {
2570
+ return this.selectedDates.length > 0 &&
2571
+ !!this.selectedDates.find((d) => this.isSameDate(d, date))
2572
+ ? 'true'
2573
+ : 'false';
2574
+ }
2575
+ selectMonth(evt) {
2576
+ this.onDirty();
2577
+ const tempDate = new Date(this.focusedDate);
2578
+ const selectedMonth = parseInt(evt.target.value, 10);
2579
+ const currentDay = tempDate.getDate();
2580
+ tempDate.setMonth(selectedMonth, 1);
2581
+ const lastDayOfSelectedMonth = new Date(tempDate.getFullYear(), selectedMonth + 1, 0).getDate();
2582
+ tempDate.setDate(Math.min(currentDay, lastDayOfSelectedMonth));
2583
+ this.focusedDate = tempDate;
2584
+ }
2585
+ selectYear(evt) {
2586
+ this.onDirty();
2587
+ const selectedYear = parseInt(evt.target.value, 10);
2588
+ // Skydda mot ogiltiga datum som 29 februari
2589
+ const day = Math.min(this.focusedDate.getDate(), new Date(selectedYear, this.focusedDate.getMonth() + 1, 0).getDate());
2590
+ const newDate = new Date(selectedYear, this.focusedDate.getMonth(), day);
2591
+ this.focusedDate = newDate;
2592
+ }
2593
+ earliestSelectableYear() {
2594
+ if (this.afMinDate)
2595
+ return this.afMinDate.getFullYear();
2596
+ return 1900;
2597
+ }
2598
+ latestSelectableYear() {
2599
+ if (this.afMaxDate)
2600
+ return this.afMaxDate.getFullYear();
2601
+ return new Date(Date.now()).getFullYear() + 10;
2602
+ }
2603
+ allSelectableYears() {
2604
+ const allYears = [];
2605
+ let currentYear = this.earliestSelectableYear();
2606
+ while (currentYear <= this.latestSelectableYear()) {
2607
+ allYears.push(currentYear++);
2608
+ }
2609
+ return allYears;
2610
+ }
2611
+ componentWillLoad() {
2612
+ var _a;
2613
+ if (isValid(this.afSelectedDate)) {
2614
+ this.selectedDates = [this.afSelectedDate];
2615
+ }
2616
+ else if (((_a = this.afSelectedDates) === null || _a === void 0 ? void 0 : _a.length) > 0) {
2617
+ const valid = this.afSelectedDates.filter((d) => isValid(d));
2618
+ if (valid.length > 0)
2619
+ this.selectedDates = valid;
2620
+ }
2621
+ this.determineFocusedDate();
2622
+ this.drawCalendar(this.focusedDate);
2623
+ }
2624
+ async componentDidLoad() {
2625
+ if (isValid(this.afSelectedDate))
2626
+ this.selectedDates = [this.afSelectedDate];
2627
+ else
2628
+ this.afSelectedDatesChangeHandler();
2629
+ await customElements.whenDefined('digi-form-select');
2630
+ }
2631
+ cssDateModifiers(date) {
2632
+ const shownMonth = this.focusedDate.getMonth();
2633
+ return {
2634
+ 'digi-calendar__date--today': this.isSameDate(date, new Date()) && !this.isInAnotherMonth(date),
2635
+ 'digi-calendar__date--disabled': this.isInAnotherMonth(date),
2636
+ 'digi-calendar__date--focused': this.isFocused(date),
2637
+ 'digi-calendar__date--selected': this.isDateSelected(date) && date.getMonth() === shownMonth,
2638
+ 'digi-calendar__date--not-selectable': !this.isInAnotherMonth(date) && !this.isDateSelectable(date)
2639
+ };
2640
+ }
2641
+ render() {
2642
+ return (h("div", { key: '1077a770af823d9e0c0f59cdc6f1fef2a49d761a', class: {
2643
+ 'digi-calendar': true,
2644
+ 'digi-calendar--hide': !this.afActive
2645
+ }, id: `${this.afId}-calendar` }, this.afYearSelect && (h("div", { key: 'cd7dfa8e20efd08afa590cd4e177ddb4c41455d8', class: "digi-calendar__header" }, h("div", { key: 'd1e6e956713de7fe417253be0fc1ec3aea9748b0', class: "digi-calendar__header--year-select" }, h("digi-form-select", { key: 'cf34feec9ed25e0251effe86b3ce393918a32eda', afLabel: _t.calendar.month, "af-variation": "small", afValue: this.focusedDate.getMonth().toString(), onAfOnSelect: (evt) => {
2646
+ this.selectMonth(evt);
2647
+ } }, _t.calendar.months.map((month, index) => {
2648
+ return h("option", { value: index }, month);
2649
+ })), h("digi-form-select", { key: 'ddcd90917d6dba315f8018c4311c852f3471d3c0', afLabel: _t.calendar.year, "af-variation": "small", afValue: this.focusedDate.getFullYear().toString(), onAfOnSelect: (evt) => {
2650
+ this.selectYear(evt);
2651
+ } }, this.allSelectableYears().map((year) => (h("option", { value: year.toString() }, year))))))), !this.afYearSelect && (h("div", { key: '814648caa21619240a5904a809c95024398e9741', class: "digi-calendar__header" }, h("div", { key: 'd3dc54a4d0172d503bff66e5171846f433755c4b', class: "digi-calendar__header--month-step" }, h("button", { key: '7725160aab267e5cdd70618613b2f485d5b7dd7f', class: "digi-calendar__month-select-button", type: "button", "aria-label": this.getFullMonthName(this.focusedDate.getMonth() - 1) +
2652
+ ', ' + _t.calendar.previousMonth, onClick: () => this.subtractMonth() }, h("digi-icon-chevron-left", { key: 'e8d1dc80011cb7e79ce6af893df2fd4601d92c74', slot: "icon", "aria-hidden": "true" }), h("span", { key: 'ae56dadf565d819f8e89804596dbe38119fb592e', class: "digi-calendar__month-select-name" }, this.getMonthName(this.focusedDate.getMonth() - 1))), h("div", { key: '257ac7d346e084390aba658eb7329cab913e3463', class: "digi-calendar__month" }, this.getFullMonthName(this.focusedDate.getMonth())), h("button", { key: '0c483763c0420f1c172c78364d2ce931ffcd116d', class: "digi-calendar__month-select-button", type: "button", "aria-label": this.getFullMonthName(this.focusedDate.getMonth() + 1) +
2653
+ ', ' + _t.calendar.nextMonth, onClick: () => this.addMonth() }, h("span", { key: 'de4617285a713bd9baa375a99f81bb027768c947', class: "digi-calendar__month-select-name" }, this.getMonthName(this.focusedDate.getMonth() + 1)), h("digi-icon-chevron-right", { key: '8d6252fcdd7a035ce8fe4e6f4cb468ce7935aeba', slot: "icon", "aria-hidden": "true" }))))), h("digi-util-keydown-handler", { key: '5080246278db71745444dcd40d0722a64e8c80b5', onAfOnDown: (e) => this.navigateHandler(e, 7), onAfOnUp: (e) => this.navigateHandler(e, -7), onAfOnLeft: (e) => this.navigateHandler(e, -1), onAfOnRight: (e) => this.navigateHandler(e, 1) }, h("table", { key: '9052f9c8135d95110f927c6a5a949fbd63daec7a', role: "grid", class: "digi-calendar__table" }, h("thead", { key: '428467866c49e65d348db796a006611542aabc02' }, h("tr", { key: '260024069438dadff553bc3391a37bbb533b5d11', role: "row" }, this.afShowWeekNumber && (h("th", { key: '2c22102011ade9125e61416ac78eaed16dec2e26', role: "columnheader", abbr: _t.calendar.week, class: "digi-calendar__table-header-week" }, _t.calendar.week.toLowerCase())), Object.keys(_t.calendar.weekdays).map((day) => (h("th", { role: "columnheader", "aria-label": _t.calendar.weekdays[day], abbr: _t.calendar.weekdays[day], class: "digi-calendar__table-header" }, _t.calendar.weekdays_short[day].toLowerCase()))))), h("tbody", { key: 'cbe3d290919c35ad27799c17e6b6236557dbe126', ref: (el) => (this._tbody = el) }, this.activeCalendar.map((week) => {
2654
+ return (h("tr", null, week.map((day, i) => {
2655
+ if (this.afShowWeekNumber && i === 0) {
2656
+ return (h("th", { role: "rowheader", "aria-label": _t.calendar.week + ' ' + day, class: "digi-calendar__td-week digi-calendar__date--week-number", id: 'digi-calendar__week-' + day }, day));
2657
+ }
2658
+ else {
2659
+ return this.isInAnotherMonth(day) ? (h("td", null)) : (h("td", { role: "gridcell", class: "digi-calendar__td" }, h("button", { key: this.getFullDate(day), type: "button", class: Object.assign(Object.assign({}, this.cssDateModifiers(day)), { 'digi-calendar__date': true }), onClick: () => this.selectDateHandler(day), "aria-current": this.isSameDate(day, new Date()) ? 'date' : null, "aria-label": `
2660
+ ${!this.isDateSelectable(day)
2661
+ ? _t.calendar.disabledDate
2662
+ : ''} ${this.getDateName(day)}
2663
+ `, "aria-disabled": !this.isDateSelectable(day) ? 'true' : null, tabindex: this.setTabIndex(day), "data-date": this.getFullDate(day), "aria-pressed": this.isDateSelectable(day)
2664
+ ? this.ariaPressed(day)
2665
+ : null }, h("span", { "aria-hidden": "true" }, day.getDate()))));
2666
+ }
2667
+ })));
2668
+ })))), h("slot", { key: 'e97e8147fc91a3b401665eeeb8db6be7036f678b', name: "calendar-footer" })));
2669
+ }
2670
+ static get watchers() { return {
2671
+ "focusedDate": [{
2672
+ "focusedDateChanged": 0
2673
+ }],
2674
+ "afOpenCalendarTo": [{
2675
+ "afOpenCalendarToChangeHandler": 0
2676
+ }],
2677
+ "afShowWeekNumber": [{
2678
+ "afShowWeekNumberChangeHandler": 0
2679
+ }],
2680
+ "afSelectedDate": [{
2681
+ "afSelectedDateChangeHandler": 0
2682
+ }],
2683
+ "afSelectedDates": [{
2684
+ "afSelectedDatesChangeHandler": 0
2685
+ }]
2686
+ }; }
2687
+ };
2688
+ Calendar.style = calendarCss();
2689
+
2180
2690
  const calendarDatepickerCss = () => `.sc-digi-calendar-datepicker:root{--digi--grayscale--0:#ffffff;--digi--grayscale--100:#f4f4f4;--digi--grayscale--1000:#000000;--digi--grayscale--200:#ededed;--digi--grayscale--300:#e4e4e4;--digi--grayscale--400:#dddddd;--digi--grayscale--50:#fbfbfb;--digi--grayscale--500:#cacaca;--digi--grayscale--600:#acacac;--digi--grayscale--700:#757575;--digi--grayscale--800:#5c5c5c;--digi--grayscale--900:#333333;--digi--misc--transparent:#ffffff00;--digi--sentiment--error--200:#fdeded;--digi--sentiment--error--500:#da0000;--digi--sentiment--error--700:#c7311a;--digi--sentiment--informative--200:#e9e9ff;--digi--sentiment--informative--500:#0a4dd1;--digi--sentiment--informative--700:#0058a3;--digi--sentiment--success--200:#e9f6ec;--digi--sentiment--success--500:#008a20;--digi--sentiment--success--700:#02703c;--digi--sentiment--warning--200:#fff398;--digi--sentiment--warning--50:#fffbdd;--digi--sentiment--warning--500:#ffe200;--digi--sentiment--warning--700:#ffc108;--digi--sentiment--warning--900:#664d00;--digi--animation--duration--base:var(--digi--global--animation--duration--base);--digi--animation--duration--small:var(--digi--global--animation--duration--short);--digi--animation--duration--large:var(--digi--global--animation--duration--longer);--digi--animation--duration--reduced:var(--digi--global--animation--duration--shortest);--digi--animation--duration--sweep:var(--digi--global--animation--duration--longest);--digi--animation--rotation--45:var(--digi--global--animation--rotation--smallest-2);--digi--animation--rotation--90:var(--digi--global--animation--rotation--smallest);--digi--animation--rotation--135:var(--digi--global--animation--rotation--smaller);--digi--animation--rotation--180:var(--digi--global--animation--rotation--small);--digi--animation--rotation--225:var(--digi--global--animation--rotation--base);--digi--animation--rotation--270:var(--digi--global--animation--rotation--large);--digi--animation--rotation--315:var(--digi--global--animation--rotation--larger);--digi--animation--rotation--360:var(--digi--global--animation--rotation--largest);--digi--global--animation--duration--base:0.3s;--digi--global--animation--duration--short:0.2s;--digi--global--animation--duration--shorter:0.1s;--digi--global--animation--duration--shortest:0.01s;--digi--global--animation--duration--long:0.4s;--digi--global--animation--duration--longer:0.5s;--digi--global--animation--duration--longest:4s;--digi--global--animation--rotation--smallest-2:0deg;--digi--global--animation--rotation--smallest:45deg;--digi--global--animation--rotation--smaller:90deg;--digi--global--animation--rotation--small:135deg;--digi--global--animation--rotation--base:180deg;--digi--global--animation--rotation--large:225deg;--digi--global--animation--rotation--larger:270deg;--digi--global--animation--rotation--largest:315deg;--digi--global--animation--rotation--largest-2:360deg;--digi--global--border-radius--base:6px;--digi--global--border-radius--small:4px;--digi--global--border-radius--smaller:3px;--digi--global--border-radius--smallest:2px;--digi--global--border-radius--smallest-2:1px;--digi--global--border-radius--smallest-3:0px;--digi--global--border-radius--large:8px;--digi--global--border-radius--larger:16px;--digi--global--border-radius--largest:32px;--digi--global--border-radius--largest-2:64px;--digi--global--border-width--base:2px;--digi--global--border-width--small:1px;--digi--global--border-width--smaller:0px;--digi--global--border-width--large:4px;--digi--global--border-width--larger:6px;--digi--global--border-width--largest:8px;--digi--global--border-width--largest-2:10px;--digi--global--border-style--solid:solid;--digi--global--border-style--none:none;--digi--global--border-style--dashed:dashed;--digi--global--spacing--base:16px;--digi--global--spacing--small:14px;--digi--global--spacing--smaller:12px;--digi--global--spacing--smallest:10px;--digi--global--spacing--smallest-2:8px;--digi--global--spacing--smallest-3:6px;--digi--global--spacing--smallest-4:4px;--digi--global--spacing--smallest-5:3px;--digi--global--spacing--smallest-6:2px;--digi--global--spacing--smallest-7:1px;--digi--global--spacing--large:18px;--digi--global--spacing--larger:20px;--digi--global--spacing---:22px;--digi--global--spacing--largest-2:24px;--digi--global--spacing--largest-3:28px;--digi--global--spacing--largest-4:32px;--digi--global--spacing--largest-5:40px;--digi--global--spacing--largest-6:48px;--digi--global--spacing--largest-7:56px;--digi--global--spacing--largest-8:64px;--digi--global--spacing--largest:22px;--digi--global--spacing--largest-3-5:30px;--digi--global--spacing--largest-9:72px;--digi--global--spacing--largest-10:80px;--digi--global--breakpoint--smallest-3:374px;--digi--global--breakpoint--smallest-2:375px;--digi--global--breakpoint--smallest:575px;--digi--global--breakpoint--smaller:576px;--digi--global--breakpoint--small:767px;--digi--global--breakpoint--medium:768px;--digi--global--breakpoint--large:991px;--digi--global--breakpoint--larger:992px;--digi--global--breakpoint--largest:1199px;--digi--global--breakpoint--largest-2:1200px;--digi--global--breakpoint--largest-3:1399px;--digi--global--breakpoint--largest-4:1400px;--digi--global--size--smaller:auto;--digi--global--size--small:36rem;--digi--global--size--base:48rem;--digi--global--size--large:62rem;--digi--global--size--larger:75rem;--digi--global--size--largest:87.5rem;--digi--global--text-width--small:31rem;--digi--global--text-width--base:35rem;--digi--global--text-width--large:40rem;--digi--global--text-width--larger:44rem;--digi--global--text-width--largest:48rem;--digi--global--text-width--largest-2:53rem;--digi--global--text-width--largest-3:61rem;--digi--global--text-width--largest-4:70rem;--digi--global--typography--line-height--base:1.5;--digi--global--typography--line-height--small:1;--digi--global--typography--line-height--large:2;--digi--global--typography--font-size--base:1rem;--digi--global--typography--font-size--small:0.875rem;--digi--global--typography--font-size--smaller:0.75rem;--digi--global--typography--font-size--large:1.125rem;--digi--global--typography--font-size--larger:1.25rem;--digi--global--typography--font-size--largest:1.375rem;--digi--global--typography--font-size--largest-2:1.5rem;--digi--global--typography--font-size--largest-3:1.75rem;--digi--global--typography--font-size--largest-4:2rem;--digi--global--typography--font-size--largest-5:2.25rem;--digi--global--typography--font-size--interaction-small:0.875rem;--digi--global--typography--font-size--interaction-medium:1rem;--digi--global--typography--font-size--interaction-large:1.125rem;--digi--global--typography--font-size--largest-6:2.5rem;--digi--global--typography--font-weight--regular:400;--digi--global--typography--font-weight--light:300;--digi--global--typography--font-weight--semibold:600;--digi--global--typography--font-weight--bold:700;--digi--global--typography--font-family--default:'Open Sans';--digi--global--typography--font-family--mono:Consolas, Monaco, 'Andale Mono', 'Ubuntu Mono', monospace;--digi--global--typography--text-decoration--default:none;--digi--global--typography--text-decoration--link:underline;--digi--border-radius--primary:var(--digi--global--border-radius--smallest-3);--digi--border-radius--secondary:var(--digi--global--border-radius--base);--digi--border-radius--tertiary:var(--digi--global--border-radius--smaller);--digi--border-radius--complementary-1:var(--digi--global--border-radius--largest);--digi--border-radius--complementary-2:var(--digi--global--border-radius--largest-2);--digi--border-radius--button:var(--digi--global--border-radius--base);--digi--border-radius--input:var(--digi--global--border-radius--smallest-3);--digi--border-radius--input-search:var(--digi--global--border-radius--base);--digi--border-radius--complementary-3:var(--digi--global--border-radius--larger);--digi--border-width--primary:var(--digi--global--border-width--small);--digi--border-width--secondary:var(--digi--global--border-width--base);--digi--border-width--complementary-1:var(--digi--global--border-width--largest);--digi--border-width--complementary-2:var(--digi--global--border-width--largest-2);--digi--border-width--input-regular:var(--digi--global--border-width--small);--digi--border-width--input-validation:var(--digi--global--border-width--base);--digi--border-width--button:var(--digi--global--border-width--small);--digi--border-style--primary:var(--digi--global--border-style--solid);--digi--border-style--secondary:var(--digi--global--border-style--none);--digi--padding--medium:var(--digi--global--spacing--base);--digi--padding--smaller:var(--digi--global--spacing--smallest-2);--digi--padding--small:var(--digi--global--spacing--smaller);--digi--padding--large:var(--digi--global--spacing--largest-2);--digi--padding--larger:var(--digi--global--spacing--largest-3);--digi--padding--largest:var(--digi--global--spacing--largest-4);--digi--padding--largest-2:var(--digi--global--spacing--largest-5);--digi--padding--largest-3:var(--digi--global--spacing--largest-6);--digi--margin--smaller:var(--digi--global--spacing--smallest-2);--digi--margin--small:var(--digi--global--spacing--smallest);--digi--margin--medium:var(--digi--global--spacing--base);--digi--margin--large:var(--digi--global--spacing--largest-2);--digi--margin--larger:var(--digi--global--spacing--largest-3);--digi--margin--largest:var(--digi--global--spacing--largest-4);--digi--margin--h1-small:var(--digi--global--spacing--base);--digi--margin--h1-medium:var(--digi--global--spacing--largest-2);--digi--margin--h1-large:var(--digi--global--spacing--largest-4);--digi--margin--h2-small:var(--digi--global--spacing--base);--digi--margin--h2-large:var(--digi--global--spacing--base);--digi--margin--h3-small:var(--digi--global--spacing--smallest-2);--digi--margin--h3-large:var(--digi--global--spacing--smallest-2);--digi--margin--h4-h6-small:var(--digi--global--spacing--smallest-2);--digi--margin--h4-h6-large:var(--digi--global--spacing--smallest-2);--digi--margin--text-small:var(--digi--global--spacing--largest-2);--digi--margin--text-large:var(--digi--global--spacing--largest-2);--digi--gutter--largest-3:var(--digi--global--spacing--largest-2);--digi--gutter--largest-2:var(--digi--global--spacing--larger);--digi--gutter--largest:var(--digi--global--spacing--base);--digi--gutter--larger:var(--digi--global--spacing--smaller);--digi--gutter--large:var(--digi--global--spacing--smallest);--digi--gutter--medium:var(--digi--global--spacing--smallest-2);--digi--gutter--small:var(--digi--global--spacing--smallest-3);--digi--gutter--smaller:var(--digi--global--spacing--smallest-4);--digi--gutter--smallest:var(--digi--global--spacing--smallest-5);--digi--gutter--smallest-2:var(--digi--global--spacing--smallest-6);--digi--gutter--smallest-3:var(--digi--global--spacing--smallest-7);--digi--gutter--button-block-small:var(--digi--global--spacing--smallest-3);--digi--gutter--button-block-medium:var(--digi--global--spacing--smallest-2);--digi--gutter--button-block-large:var(--digi--global--spacing--smallest);--digi--gutter--button-inline-small:var(--digi--global--spacing--smallest-2);--digi--gutter--button-inline-medium:var(--digi--global--spacing--base);--digi--gutter--button-inline-large:var(--digi--global--spacing--largest-2);--digi--gutter--icon:var(--digi--global--spacing--smallest);--digi--breakpoint--small-below:var(--digi--global--breakpoint--smallest);--digi--breakpoint--small:var(--digi--global--breakpoint--smaller);--digi--breakpoint--medium-below:var(--digi--global--breakpoint--small);--digi--breakpoint--medium:var(--digi--global--breakpoint--medium);--digi--breakpoint--large-below:var(--digi--global--breakpoint--large);--digi--breakpoint--large:var(--digi--global--breakpoint--larger);--digi--breakpoint--x-large-below:var(--digi--global--breakpoint--largest);--digi--breakpoint--x-large:var(--digi--global--breakpoint--largest-2);--digi--breakpoint--xx-large-below:var(--digi--global--breakpoint--largest-3);--digi--breakpoint--xx-large:var(--digi--global--breakpoint--largest-4);--digi--container-width--smaller:var(--digi--global--size--smaller);--digi--container-width--small:var(--digi--global--size--small);--digi--container-width--base:var(--digi--global--size--base);--digi--container-width--medium:var(--digi--global--size--base);--digi--container-width--large:var(--digi--global--size--large);--digi--container-width--larger:var(--digi--global--size--larger);--digi--container-width--largest:var(--digi--global--size--largest);--digi--container-gutter--smaller:var(--digi--global--spacing--base);--digi--container-gutter--small:var(--digi--global--spacing--large);--digi--container-gutter--base:var(--digi--global--spacing--base);--digi--container-gutter--medium:var(--digi--global--spacing--largest-2);--digi--container-gutter--large:var(--digi--global--spacing--base);--digi--container-gutter--larger:var(--digi--global--spacing--largest-3-5);--digi--container-gutter--largest:var(--digi--global--spacing--largest-5);--digi--paragraph-width--medium:var(--digi--global--text-width--base);--digi--paragraph-width--large:var(--digi--global--text-width--large);--digi--input-height--small:var(--digi--global--spacing--largest-4);--digi--input-height--medium:var(--digi--global--spacing--largest-5);--digi--input-height--large:var(--digi--global--spacing--largest-6);--digi--typography--body--font-size--desktop:var(--digi--global--typography--font-size--base);--digi--typography--body--font-size--desktop-large:var(--digi--global--typography--font-size--large);--digi--typography--body--font-size--mobile:var(--digi--global--typography--font-size--base);--digi--typography--body--font-weight--desktop:var(--digi--global--typography--font-weight--regular);--digi--typography--body--font-weight--desktop-large:var(--digi--global--typography--font-weight--regular);--digi--typography--body--font-weight--mobile:var(--digi--global--typography--font-weight--regular);--digi--typography--body--line-height--desktop:var(--digi--global--typography--line-height--base);--digi--typography--body--line-height--desktop-large:var(--digi--global--typography--line-height--base);--digi--typography--body--line-height--mobile:var(--digi--global--typography--line-height--base);--digi--typography--body--text-decoration--desktop:var(--digi--global--typography--text-decoration--default);--digi--typography--body--text-decoration--desktop-large:var(--digi--global--typography--text-decoration--default);--digi--typography--body--text-decoration--mobile:var(--digi--global--typography--text-decoration--default);--digi--typography--description--font-size--desktop:var(--digi--global--typography--font-size--base);--digi--typography--description--font-size--desktop-large:var(--digi--global--typography--font-size--large);--digi--typography--description--font-weight--desktop:var(--digi--global--typography--font-weight--semibold);--digi--typography--heading-1--font-size--desktop:var(--digi--global--typography--font-size--largest-4);--digi--typography--heading-1--font-size--desktop-large:var(--digi--global--typography--font-size--largest-6);--digi--typography--heading-1--font-size--mobile:var(--digi--global--typography--font-size--largest-3);--digi--typography--heading-1--font-weight--desktop:var(--digi--global--typography--font-weight--semibold);--digi--typography--heading-1--font-weight--desktop-large:var(--digi--global--typography--font-weight--semibold);--digi--typography--heading-1--font-weight--mobile:var(--digi--global--typography--font-weight--semibold);--digi--typography--heading-1--line-height--desktop:var(--digi--global--typography--line-height--base);--digi--typography--heading-1--line-height--desktop-large:var(--digi--global--typography--line-height--base);--digi--typography--heading-1--line-height--mobile:var(--digi--global--typography--line-height--base);--digi--typography--heading-1--text-decoration--desktop:var(--digi--global--typography--text-decoration--default);--digi--typography--heading-1--text-decoration--desktop-large:var(--digi--global--typography--text-decoration--default);--digi--typography--heading-1--text-decoration--mobile:var(--digi--global--typography--text-decoration--default);--digi--typography--heading-2--font-size--desktop:var(--digi--global--typography--font-size--largest-2);--digi--typography--heading-2--font-size--desktop-large:var(--digi--global--typography--font-size--largest-3);--digi--typography--heading-2--font-size--mobile:var(--digi--global--typography--font-size--largest);--digi--typography--heading-2--font-weight--desktop:var(--digi--global--typography--font-weight--semibold);--digi--typography--heading-2--font-weight--desktop-large:var(--digi--global--typography--font-weight--semibold);--digi--typography--heading-2--font-weight--mobile:var(--digi--global--typography--font-weight--semibold);--digi--typography--heading-2--line-height--desktop:var(--digi--global--typography--line-height--base);--digi--typography--heading-2--line-height--desktop-large:var(--digi--global--typography--line-height--base);--digi--typography--heading-2--line-height--mobile:var(--digi--global--typography--line-height--base);--digi--typography--heading-2--text-decoration--desktop:var(--digi--global--typography--text-decoration--default);--digi--typography--heading-2--text-decoration--desktop-large:var(--digi--global--typography--text-decoration--default);--digi--typography--heading-2--text-decoration--mobile:var(--digi--global--typography--text-decoration--default);--digi--typography--heading-3--font-size--desktop:var(--digi--global--typography--font-size--larger);--digi--typography--heading-3--font-size--desktop-large:var(--digi--global--typography--font-size--largest);--digi--typography--heading-3--font-size--mobile:var(--digi--global--typography--font-size--large);--digi--typography--heading-3--font-weight--desktop:var(--digi--global--typography--font-weight--semibold);--digi--typography--heading-3--font-weight--desktop-large:var(--digi--global--typography--font-weight--semibold);--digi--typography--heading-3--font-weight--mobile:var(--digi--global--typography--font-weight--semibold);--digi--typography--heading-3--line-height--desktop:var(--digi--global--typography--line-height--base);--digi--typography--heading-3--line-height--desktop-large:var(--digi--global--typography--line-height--base);--digi--typography--heading-3--line-height--mobile:var(--digi--global--typography--line-height--base);--digi--typography--heading-3--text-decoration--desktop:var(--digi--global--typography--text-decoration--default);--digi--typography--heading-3--text-decoration--desktop-large:var(--digi--global--typography--text-decoration--default);--digi--typography--heading-3--text-decoration--mobile:var(--digi--global--typography--text-decoration--default);--digi--typography--heading-4--font-size--desktop:var(--digi--global--typography--font-size--base);--digi--typography--heading-4--font-size--desktop-large:var(--digi--global--typography--font-size--large);--digi--typography--heading-4--font-size--mobile:var(--digi--global--typography--font-size--base);--digi--typography--heading-4--font-weight--desktop:var(--digi--global--typography--font-weight--semibold);--digi--typography--heading-4--font-weight--desktop-large:var(--digi--global--typography--font-weight--semibold);--digi--typography--heading-4--font-weight--mobile:var(--digi--global--typography--font-weight--semibold);--digi--typography--heading-4--line-height--desktop:var(--digi--global--typography--line-height--base);--digi--typography--heading-4--line-height--desktop-large:var(--digi--global--typography--line-height--base);--digi--typography--heading-4--line-height--mobile:var(--digi--global--typography--line-height--base);--digi--typography--heading-4--text-decoration--desktop:var(--digi--global--typography--text-decoration--default);--digi--typography--heading-4--text-decoration--desktop-large:var(--digi--global--typography--text-decoration--default);--digi--typography--heading-4--text-decoration--mobile:var(--digi--global--typography--text-decoration--default);--digi--typography--heading-jumbo--font-size--desktop:var(--digi--global--typography--font-size--largest-4);--digi--typography--heading-jumbo--font-size--desktop-large:var(--digi--global--typography--font-size--largest-6);--digi--typography--heading-jumbo--font-weight--desktop:var(--digi--global--typography--font-weight--semibold);--digi--typography--input--font-size--desktop-large:var(--digi--global--typography--font-size--large);--digi--typography--label--font-size--desktop:var(--digi--global--typography--font-size--base);--digi--typography--label--font-weight--desktop:var(--digi--global--typography--font-weight--semibold);--digi--typography--label--font-weight--mobile:var(--digi--global--typography--font-weight--semibold);--digi--typography--label--line-height--desktop:var(--digi--global--typography--line-height--base);--digi--typography--label-description--font-size--desktop:var(--digi--global--typography--font-size--base);--digi--typography--label-description--line-height--desktop:var(--digi--global--typography--line-height--base);--digi--typography--link--font-size--desktop:var(--digi--global--typography--font-size--base);--digi--typography--link--font-size--desktop-large:var(--digi--global--typography--font-size--large);--digi--typography--link--font-size--mobile:var(--digi--global--typography--font-size--base);--digi--typography--link--font-weight--desktop:var(--digi--global--typography--font-weight--regular);--digi--typography--link--font-weight--desktop-large:var(--digi--global--typography--font-weight--regular);--digi--typography--link--font-weight--mobile:var(--digi--global--typography--font-weight--regular);--digi--typography--link--line-height--desktop:var(--digi--global--typography--line-height--base);--digi--typography--link--line-height--desktop-large:var(--digi--global--typography--line-height--base);--digi--typography--link--line-height--mobile:var(--digi--global--typography--line-height--base);--digi--typography--link--text-decoration--desktop:var(--digi--global--typography--text-decoration--link);--digi--typography--link--text-decoration--desktop-large:var(--digi--global--typography--text-decoration--link);--digi--typography--link--text-decoration--mobile:var(--digi--global--typography--text-decoration--link);--digi--typography--link-bold--font-weight--desktop:var(--digi--global--typography--font-weight--semibold);--digi--typography--preamble--font-size--desktop:var(--digi--global--typography--font-size--base);--digi--typography--preamble--font-size--mobile:var(--digi--global--typography--font-size--base);--digi--typography--preamble--font-weight--desktop:var(--digi--global--typography--font-weight--semibold);--digi--typography--preamble--line-height--mobile:var(--digi--global--typography--line-height--base);--digi--typography--preamble--line-height--desktop:var(--digi--global--typography--line-height--base);--digi--typography--accordion--font-size--desktop:var(--digi--global--typography--font-size--base);--digi--typography--accordion--font-size--mobile:var(--digi--global--typography--font-size--base);--digi--typography--accordion--font-weight--desktop:var(--digi--global--typography--font-weight--semibold);--digi--typography--tag--font-size--desktop:var(--digi--global--typography--font-size--small);--digi--typography--tag--font-size--mobile:var(--digi--global--typography--font-size--small);--digi--typography--tag--font-weight--desktop:var(--digi--global--typography--font-weight--regular);--digi--typography--breadcrumbs--font-size--desktop:var(--digi--global--typography--font-size--small);--digi--typography--breadcrumbs--text-decoration--desktop:var(--digi--global--typography--text-decoration--default);--digi--typography--title-logo--font-size--desktop:var(--digi--global--typography--font-size--largest-5);--digi--typography--title-logo--font-size--desktop-large:var(--digi--global--typography--font-size--largest-5);--digi--typography--title-logo--font-size--mobile:var(--digi--global--typography--font-size--largest-3);--digi--typography--title-logo--font-weight--desktop:var(--digi--global--typography--font-weight--bold);--digi--typography--button--font-size--desktop:var(--digi--global--typography--font-size--base);--digi--typography--button--font-size--desktop-large:var(--digi--global--typography--font-size--large);--digi--typography--button--font-weight--desktop:var(--digi--global--typography--font-weight--semibold);--digi--color--amethyst--500:#822998;--digi--color--jade--100:#bddfda;--digi--color--jade--200:#7fc1b6;--digi--color--jade--400:#379d8d;--digi--color--jade--50:#ddeeec;--digi--color--jade--500:#058470;--digi--color--jade--600:#046a5a;--digi--color--jade--700:#035548;--digi--color--jade--900:#02372f;--digi--color--leaf--100:#f1f7e5;--digi--color--leaf--200:#ddebc1;--digi--color--leaf--400:#aace65;--digi--color--leaf--500:#95c23e;--digi--color--leaf--600:#779b32;--digi--color--pear--500:#b7ee4a;--digi--color--pear--600:#a7d943;--digi--color--rose--100:#f4cada;--digi--color--rose--200:#e997b7;--digi--color--rose--400:#dd5c8e;--digi--color--rose--50:#f9e4ec;--digi--color--rose--500:#d43372;--digi--color--rose--600:#bd2e65;--digi--color--rose--700:#882149;--digi--color--rose--900:#54172e;--digi--color--sapphire--500:#1616b2;--digi--color--stratos--100:#dddde9;--digi--color--stratos--400:#33337b;--digi--color--stratos--500:#00005a;--digi--color--stratos--600:#000048;--digi--color--water--200:#f1f8fe;--digi--color--water--500:#bdd3e7;--digi--color--water--700:#0058a3;--digi--color--background--brand-primary--light--af18:var(--digi--color--stratos--500);--digi--color--background--interactive--default--input-elements--light--af18:var(--digi--grayscale--0);--digi--color--background--interactive--default--pop-out--light--af18:var(--digi--color--leaf--100);--digi--color--background--interactive--default--primary--light--af18:var(--digi--color--stratos--500);--digi--color--background--interactive--default--primary-inverted--light--af18:var(--digi--color--leaf--500);--digi--color--background--interactive--default--quaternary--light--af18:var(--digi--grayscale--100);--digi--color--background--interactive--default--secondary--light--af18:var(--digi--grayscale--0);--digi--color--background--interactive--default--secondary-inverted--light--af18:var(--digi--misc--transparent);--digi--color--background--interactive--default--tertiary--light--af18:var(--digi--grayscale--200);--digi--color--background--interactive--hover--inverted--light--af18:var(--digi--color--pear--500);--digi--color--background--interactive--hover--primary--light--af18:var(--digi--color--water--700);--digi--color--background--interactive--hover--quarternary--light--af18:var(--digi--grayscale--200);--digi--color--background--interactive--hover--secondary--light--af18:var(--digi--color--water--500);--digi--color--background--interactive--hover--tertiary--light--af18:var(--digi--color--sapphire--500);--digi--color--background--interactive--selected--on-menu-minus-button--light--af18:var(--digi--color--leaf--200);--digi--color--background--interactive--selected--primary--light--af18:var(--digi--sentiment--success--500);--digi--color--background--interactive--selected--secondary--light--af18:var(--digi--color--stratos--500);--digi--color--background--interactive--selected--tertiary--light--af18:var(--digi--grayscale--200);--digi--color--background--interactive--validation--error--light--af18:var(--digi--sentiment--error--200);--digi--color--background--interactive--validation--success--light--af18:var(--digi--sentiment--success--200);--digi--color--background--interactive--validation--warning--light--af18:var(--digi--sentiment--warning--50);--digi--color--background--notification--light--af18:var(--digi--sentiment--error--500);--digi--color--background--pop-out--light--af18:var(--digi--color--leaf--100);--digi--color--background--primary--light--af18:var(--digi--grayscale--0);--digi--color--background--secondary--light--af18:var(--digi--grayscale--100);--digi--color--background--secondary-accent--light--af18:var(--digi--grayscale--400);--digi--color--background--secondary-muted--light--af18:var(--digi--grayscale--50);--digi--color--background--sentiment--beta--primary--light--af18:var(--digi--color--rose--500);--digi--color--background--sentiment--beta--secondary--light--af18:var(--digi--color--rose--100);--digi--color--background--sentiment--error--primary--light--af18:var(--digi--sentiment--error--500);--digi--color--background--sentiment--error--secondary--light--af18:var(--digi--sentiment--error--700);--digi--color--background--sentiment--error--tertiary--light--af18:var(--digi--sentiment--error--200);--digi--color--background--sentiment--info--primary--light--af18:var(--digi--sentiment--informative--500);--digi--color--background--sentiment--info--secondary--light--af18:var(--digi--sentiment--informative--700);--digi--color--background--sentiment--info--tertiary--light--af18:var(--digi--sentiment--informative--200);--digi--color--background--sentiment--neutral--primary--light--af18:var(--digi--grayscale--700);--digi--color--background--sentiment--neutral--secondary--light--af18:var(--digi--grayscale--400);--digi--color--background--sentiment--neutral--tertiary--light--af18:var(--digi--grayscale--900);--digi--color--background--sentiment--success--primary--light--af18:var(--digi--sentiment--success--500);--digi--color--background--sentiment--success--secondary--light--af18:var(--digi--sentiment--success--700);--digi--color--background--sentiment--success--tertiary--light--af18:var(--digi--sentiment--success--200);--digi--color--background--sentiment--warning--primary--light--af18:var(--digi--sentiment--warning--500);--digi--color--background--sentiment--warning--quarternary--light--af18:var(--digi--sentiment--warning--50);--digi--color--background--sentiment--warning--secondary--light--af18:var(--digi--sentiment--warning--700);--digi--color--background--sentiment--warning--tertiary--light--af18:var(--digi--sentiment--warning--200);--digi--color--background--transparent--light--af18:var(--digi--misc--transparent);--digi--color--border--accent--primary--light--af18:var(--digi--color--stratos--500);--digi--color--border--accent--secondary--light--af18:var(--digi--color--leaf--500);--digi--color--border--interactive--default--inverted--light--af18:var(--digi--color--leaf--500);--digi--color--border--interactive--default--on-input--light--af18:var(--digi--grayscale--900);--digi--color--border--interactive--default--on-input-nuance--light--af18:var(--digi--grayscale--800);--digi--color--border--interactive--default--primary--light--af18:var(--digi--color--stratos--500);--digi--color--border--interactive--hover--inverted--light--af18:var(--digi--color--pear--500);--digi--color--border--interactive--hover--primary--light--af18:var(--digi--color--water--700);--digi--color--border--interactive--hover--secondary--light--af18:var(--digi--color--stratos--500);--digi--color--border--interactive--selected--primary--light--af18:var(--digi--sentiment--success--500);--digi--color--border--interactive--selected--secondary--light--af18:var(--digi--color--stratos--500);--digi--color--border--interactive--validation--error--light--af18:var(--digi--sentiment--error--500);--digi--color--border--interactive--validation--success--light--af18:var(--digi--sentiment--success--500);--digi--color--border--interactive--validation--warning--light--af18:var(--digi--sentiment--warning--900);--digi--color--border--notification--light--af18:var(--digi--grayscale--0);--digi--color--border--sentiment--error--light--af18:var(--digi--sentiment--error--500);--digi--color--border--sentiment--info--light--af18:var(--digi--sentiment--informative--500);--digi--color--border--sentiment--success--light--af18:var(--digi--sentiment--success--500);--digi--color--border--sentiment--warning--light--af18:var(--digi--sentiment--warning--500);--digi--color--border--transparent--light--af18:var(--digi--misc--transparent);--digi--color--divider--cta--light--af18:var(--digi--color--sapphire--500);--digi--color--divider--on-brand-primary--light--af18:var(--digi--color--stratos--400);--digi--color--divider--primary--light--af18:var(--digi--grayscale--400);--digi--color--divider--secondary--light--af18:var(--digi--grayscale--200);--digi--color--icon--brand-primary--light--af18:var(--digi--color--stratos--500);--digi--color--icon--brand-secondary--light--af18:var(--digi--color--leaf--500);--digi--color--icon--cta--light--af18:var(--digi--color--sapphire--500);--digi--color--icon--primary--light--af18:var(--digi--grayscale--900);--digi--color--icon--secondary--light--af18:var(--digi--grayscale--0);--digi--color--icon--validation--error--light--af18:var(--digi--sentiment--error--500);--digi--color--icon--validation--success--light--af18:var(--digi--sentiment--success--500);--digi--color--icon--validation--warning--light--af18:var(--digi--sentiment--warning--500);--digi--color--infographic--background--light--af18:var(--digi--grayscale--0);--digi--color--infographic--brand--primary--light--af18:var(--digi--color--leaf--500);--digi--color--infographic--brand--primary-alt--light--af18:var(--digi--color--leaf--500);--digi--color--infographic--brand--secondary--light--af18:var(--digi--color--leaf--200);--digi--color--infographic--brand--secondary-alt--light--af18:var(--digi--color--leaf--200);--digi--color--infographic--lineart--light--af18:var(--digi--grayscale--900);--digi--color--logotype--primary--symbol--light--af18:var(--digi--color--leaf--500);--digi--color--logotype--primary--text--light--af18:var(--digi--color--stratos--500);--digi--color--logotype--secondary--symbol--light--af18:#1db920;--digi--color--logotype--secondary--text--light--af18:var(--digi--grayscale--0);--digi--color--marking--indication--primary--light--af18:var(--digi--sentiment--success--500);--digi--color--marking--indication--secondary--light--af18:var(--digi--color--stratos--500);--digi--color--marking--indication--tertiary--light--af18:var(--digi--grayscale--700);--digi--color--marking--navigation--level-active--light--af18:var(--digi--color--leaf--200);--digi--color--marking--navigation--level-inactive--light--af18:var(--digi--grayscale--100);--digi--color--marking--navigation--selected--light--af18:var(--digi--color--leaf--500);--digi--color--misc--skeleton--light--af18:var(--digi--grayscale--400);--digi--color--misc--spinner-path--light--af18:var(--digi--grayscale--400);--digi--color--text--description--light--af18:var(--digi--grayscale--800);--digi--color--text--interactive--brand-primary--light--af18:var(--digi--color--stratos--500);--digi--color--text--interactive--brand-secondary--light--af18:var(--digi--color--leaf--500);--digi--color--text--interactive--primary--light--af18:var(--digi--color--sapphire--500);--digi--color--text--interactive--secondary--light--af18:var(--digi--grayscale--0);--digi--color--text--interactive--tertiary--light--af18:var(--digi--grayscale--900);--digi--color--text--interactive--visited--light--af18:var(--digi--color--amethyst--500);--digi--color--text--primary--light--af18:var(--digi--grayscale--900);--digi--color--text--secondary--light--af18:var(--digi--grayscale--0);--digi--amethyst--500:#822998;--digi--granskott--150:#f2faf2;--digi--granskott--200:#ebf8eb;--digi--granskott--250:#ddf4dd;--digi--granskott--300:#cbecc9;--digi--granskott--350:#ace4ad;--digi--granskott--650:#1db920;--digi--granskott--700:#02a704;--digi--granskott--750:#018903;--digi--granskott--800:#016503;--digi--natthimmel--200:#e9f6fd;--digi--natthimmel--250:#ddf1fc;--digi--natthimmel--300:#c9e9fa;--digi--natthimmel--350:#abdef7;--digi--natthimmel--700:#043982;--digi--natthimmel--800:#091d54;--digi--natthimmel--900:#071744;--digi--norrsken--400:#aaf5ab;--digi--norrsken--500:#67ee6a;--digi--rallarros--300:#f8ddf5;--digi--rallarros--500:#ce1cbd;--digi--sapphire--500:#1616b2;--digi--color--background--brand-primary--light:var(--digi--natthimmel--800);--digi--color--background--interactive--default--input-elements--light:var(--digi--grayscale--0);--digi--color--background--interactive--default--pop-out--light:var(--digi--granskott--150);--digi--color--background--interactive--default--primary--light:var(--digi--natthimmel--800);--digi--color--background--interactive--default--primary-inverted--light:var(--digi--norrsken--500);--digi--color--background--interactive--default--quaternary--light:var(--digi--grayscale--100);--digi--color--background--interactive--default--secondary--light:var(--digi--grayscale--0);--digi--color--background--interactive--default--secondary-inverted--light:var(--digi--misc--transparent);--digi--color--background--interactive--default--tertiary--light:var(--digi--grayscale--200);--digi--color--background--interactive--hover--inverted--light:var(--digi--norrsken--400);--digi--color--background--interactive--hover--primary--light:var(--digi--natthimmel--700);--digi--color--background--interactive--hover--quarternary--light:var(--digi--grayscale--200);--digi--color--background--interactive--hover--secondary--light:var(--digi--natthimmel--250);--digi--color--background--interactive--hover--tertiary--light:var(--digi--sapphire--500);--digi--color--background--interactive--selected--on-menu-minus-button--light:var(--digi--granskott--350);--digi--color--background--interactive--selected--primary--light:var(--digi--sentiment--success--500);--digi--color--background--interactive--selected--secondary--light:var(--digi--natthimmel--800);--digi--color--background--interactive--selected--tertiary--light:var(--digi--grayscale--200);--digi--color--background--interactive--validation--error--light:var(--digi--sentiment--error--200);--digi--color--background--interactive--validation--success--light:var(--digi--sentiment--success--200);--digi--color--background--interactive--validation--warning--light:var(--digi--sentiment--warning--50);--digi--color--background--notification--light:var(--digi--sentiment--error--500);--digi--color--background--pop-out--light:var(--digi--granskott--200);--digi--color--background--primary--light:var(--digi--grayscale--0);--digi--color--background--secondary--light:var(--digi--grayscale--100);--digi--color--background--secondary-accent--light:var(--digi--grayscale--400);--digi--color--background--secondary-muted--light:var(--digi--grayscale--50);--digi--color--background--sentiment--beta--primary--light:var(--digi--rallarros--500);--digi--color--background--sentiment--beta--secondary--light:var(--digi--rallarros--300);--digi--color--background--sentiment--error--primary--light:var(--digi--sentiment--error--500);--digi--color--background--sentiment--error--secondary--light:var(--digi--sentiment--error--700);--digi--color--background--sentiment--error--tertiary--light:var(--digi--sentiment--error--200);--digi--color--background--sentiment--info--primary--light:var(--digi--sentiment--informative--500);--digi--color--background--sentiment--info--secondary--light:var(--digi--sentiment--informative--700);--digi--color--background--sentiment--info--tertiary--light:var(--digi--sentiment--informative--200);--digi--color--background--sentiment--neutral--primary--light:var(--digi--grayscale--700);--digi--color--background--sentiment--neutral--secondary--light:var(--digi--grayscale--400);--digi--color--background--sentiment--neutral--tertiary--light:var(--digi--grayscale--900);--digi--color--background--sentiment--success--primary--light:var(--digi--sentiment--success--500);--digi--color--background--sentiment--success--secondary--light:var(--digi--sentiment--success--700);--digi--color--background--sentiment--success--tertiary--light:var(--digi--sentiment--success--200);--digi--color--background--sentiment--warning--primary--light:var(--digi--sentiment--warning--500);--digi--color--background--sentiment--warning--quarternary--light:var(--digi--sentiment--warning--50);--digi--color--background--sentiment--warning--secondary--light:var(--digi--sentiment--warning--700);--digi--color--background--sentiment--warning--tertiary--light:var(--digi--sentiment--warning--200);--digi--color--background--transparent--light:var(--digi--misc--transparent);--digi--color--border--accent--primary--light:var(--digi--natthimmel--800);--digi--color--border--accent--secondary--light:var(--digi--granskott--700);--digi--color--border--interactive--default--inverted--light:var(--digi--norrsken--500);--digi--color--border--interactive--default--on-input--light:var(--digi--grayscale--900);--digi--color--border--interactive--default--on-input-nuance--light:var(--digi--grayscale--800);--digi--color--border--interactive--default--primary--light:var(--digi--natthimmel--800);--digi--color--border--interactive--hover--inverted--light:var(--digi--norrsken--400);--digi--color--border--interactive--hover--primary--light:var(--digi--natthimmel--700);--digi--color--border--interactive--hover--secondary--light:var(--digi--natthimmel--800);--digi--color--border--interactive--selected--primary--light:var(--digi--sentiment--success--500);--digi--color--border--interactive--selected--secondary--light:var(--digi--natthimmel--800);--digi--color--border--interactive--validation--error--light:var(--digi--sentiment--error--500);--digi--color--border--interactive--validation--success--light:var(--digi--sentiment--success--500);--digi--color--border--interactive--validation--warning--light:var(--digi--sentiment--warning--900);--digi--color--border--notification--light:var(--digi--grayscale--0);--digi--color--border--sentiment--error--light:var(--digi--sentiment--error--500);--digi--color--border--sentiment--info--light:var(--digi--sentiment--informative--500);--digi--color--border--sentiment--success--light:var(--digi--sentiment--success--500);--digi--color--border--sentiment--warning--light:var(--digi--sentiment--warning--500);--digi--color--border--transparent--light:var(--digi--misc--transparent);--digi--color--divider--cta--light:var(--digi--sapphire--500);--digi--color--divider--on-brand-primary--light:var(--digi--natthimmel--350);--digi--color--divider--primary--light:var(--digi--grayscale--400);--digi--color--divider--secondary--light:var(--digi--grayscale--200);--digi--color--icon--brand-primary--light:var(--digi--natthimmel--800);--digi--color--icon--brand-secondary--light:var(--digi--norrsken--500);--digi--color--icon--cta--light:var(--digi--sapphire--500);--digi--color--icon--primary--light:var(--digi--grayscale--900);--digi--color--icon--secondary--light:var(--digi--grayscale--0);--digi--color--icon--validation--error--light:var(--digi--sentiment--error--500);--digi--color--icon--validation--success--light:var(--digi--sentiment--success--500);--digi--color--icon--validation--warning--light:var(--digi--sentiment--warning--500);--digi--color--infographic--background--light:var(--digi--grayscale--0);--digi--color--infographic--brand--primary--light:var(--digi--granskott--700);--digi--color--infographic--brand--primary-alt--light:var(--digi--granskott--700);--digi--color--infographic--brand--secondary--light:var(--digi--granskott--300);--digi--color--infographic--brand--secondary-alt--light:var(--digi--granskott--300);--digi--color--infographic--lineart--light:var(--digi--grayscale--900);--digi--color--logotype--primary--symbol--light:var(--digi--granskott--700);--digi--color--logotype--primary--text--light:var(--digi--natthimmel--800);--digi--color--logotype--secondary--symbol--light:#1db920;--digi--color--logotype--secondary--text--light:var(--digi--grayscale--0);--digi--color--marking--indication--primary--light:var(--digi--sentiment--success--500);--digi--color--marking--indication--secondary--light:var(--digi--natthimmel--800);--digi--color--marking--indication--tertiary--light:var(--digi--grayscale--700);--digi--color--marking--navigation--level-active--light:var(--digi--granskott--350);--digi--color--marking--navigation--level-inactive--light:var(--digi--grayscale--100);--digi--color--marking--navigation--selected--light:var(--digi--granskott--700);--digi--color--misc--skeleton--light:var(--digi--grayscale--400);--digi--color--misc--spinner-path--light:var(--digi--grayscale--400);--digi--color--text--description--light:var(--digi--grayscale--800);--digi--color--text--interactive--brand-primary--light:var(--digi--natthimmel--800);--digi--color--text--interactive--brand-secondary--light:var(--digi--norrsken--500);--digi--color--text--interactive--primary--light:var(--digi--sapphire--500);--digi--color--text--interactive--secondary--light:var(--digi--grayscale--0);--digi--color--text--interactive--tertiary--light:var(--digi--grayscale--900);--digi--color--text--interactive--visited--light:var(--digi--amethyst--500);--digi--color--text--primary--light:var(--digi--grayscale--900);--digi--color--text--secondary--light:var(--digi--grayscale--0);--digi--color--background--brand-primary:var(--digi--color--background--brand-primary--light);--digi--color--background--interactive--default--input-elements:var(--digi--color--background--interactive--default--input-elements--light);--digi--color--background--interactive--default--pop-out:var(--digi--color--background--interactive--default--pop-out--light);--digi--color--background--interactive--default--primary:var(--digi--color--background--interactive--default--primary--light);--digi--color--background--interactive--default--primary-inverted:var(--digi--color--background--interactive--default--primary-inverted--light);--digi--color--background--interactive--default--quaternary:var(--digi--color--background--interactive--default--quaternary--light);--digi--color--background--interactive--default--secondary:var(--digi--color--background--interactive--default--secondary--light);--digi--color--background--interactive--default--secondary-inverted:var(--digi--color--background--interactive--default--secondary-inverted--light);--digi--color--background--interactive--default--tertiary:var(--digi--color--background--interactive--default--tertiary--light);--digi--color--background--interactive--hover--inverted:var(--digi--color--background--interactive--hover--inverted--light);--digi--color--background--interactive--hover--primary:var(--digi--color--background--interactive--hover--primary--light);--digi--color--background--interactive--hover--quarternary:var(--digi--color--background--interactive--hover--quarternary--light);--digi--color--background--interactive--hover--secondary:var(--digi--color--background--interactive--hover--secondary--light);--digi--color--background--interactive--hover--tertiary:var(--digi--color--background--interactive--hover--tertiary--light);--digi--color--background--interactive--selected--on-menu-minus-button:var(--digi--color--background--interactive--selected--on-menu-minus-button--light);--digi--color--background--interactive--selected--primary:var(--digi--color--background--interactive--selected--primary--light);--digi--color--background--interactive--selected--secondary:var(--digi--color--background--interactive--selected--secondary--light);--digi--color--background--interactive--selected--tertiary:var(--digi--color--background--interactive--selected--tertiary--light);--digi--color--background--interactive--validation--error:var(--digi--color--background--interactive--validation--error--light);--digi--color--background--interactive--validation--success:var(--digi--color--background--interactive--validation--success--light);--digi--color--background--interactive--validation--warning:var(--digi--color--background--interactive--validation--warning--light);--digi--color--background--notification:var(--digi--color--background--notification--light);--digi--color--background--pop-out:var(--digi--color--background--pop-out--light);--digi--color--background--primary:var(--digi--color--background--primary--light);--digi--color--background--secondary:var(--digi--color--background--secondary--light);--digi--color--background--secondary-accent:var(--digi--color--background--secondary-accent--light);--digi--color--background--secondary-muted:var(--digi--color--background--secondary-muted--light);--digi--color--background--sentiment--beta--primary:var(--digi--color--background--sentiment--beta--primary--light);--digi--color--background--sentiment--beta--secondary:var(--digi--color--background--sentiment--beta--secondary--light);--digi--color--background--sentiment--error--primary:var(--digi--color--background--sentiment--error--primary--light);--digi--color--background--sentiment--error--secondary:var(--digi--color--background--sentiment--error--secondary--light);--digi--color--background--sentiment--error--tertiary:var(--digi--color--background--sentiment--error--tertiary--light);--digi--color--background--sentiment--info--primary:var(--digi--color--background--sentiment--info--primary--light);--digi--color--background--sentiment--info--secondary:var(--digi--color--background--sentiment--info--secondary--light);--digi--color--background--sentiment--info--tertiary:var(--digi--color--background--sentiment--info--tertiary--light);--digi--color--background--sentiment--neutral--primary:var(--digi--color--background--sentiment--neutral--primary--light);--digi--color--background--sentiment--neutral--secondary:var(--digi--color--background--sentiment--neutral--secondary--light);--digi--color--background--sentiment--neutral--tertiary:var(--digi--color--background--sentiment--neutral--tertiary--light);--digi--color--background--sentiment--success--primary:var(--digi--color--background--sentiment--success--primary--light);--digi--color--background--sentiment--success--secondary:var(--digi--color--background--sentiment--success--secondary--light);--digi--color--background--sentiment--success--tertiary:var(--digi--color--background--sentiment--success--tertiary--light);--digi--color--background--sentiment--warning--primary:var(--digi--color--background--sentiment--warning--primary--light);--digi--color--background--sentiment--warning--quarternary:var(--digi--color--background--sentiment--warning--quarternary--light);--digi--color--background--sentiment--warning--secondary:var(--digi--color--background--sentiment--warning--secondary--light);--digi--color--background--sentiment--warning--tertiary:var(--digi--color--background--sentiment--warning--tertiary--light);--digi--color--background--transparent:var(--digi--color--background--transparent--light);--digi--color--border--accent--primary:var(--digi--color--border--accent--primary--light);--digi--color--border--accent--secondary:var(--digi--color--border--accent--secondary--light);--digi--color--border--interactive--default--inverted:var(--digi--color--border--interactive--default--inverted--light);--digi--color--border--interactive--default--on-input:var(--digi--color--border--interactive--default--on-input--light);--digi--color--border--interactive--default--on-input-nuance:var(--digi--color--border--interactive--default--on-input-nuance--light);--digi--color--border--interactive--default--primary:var(--digi--color--border--interactive--default--primary--light);--digi--color--border--interactive--hover--inverted:var(--digi--color--border--interactive--hover--inverted--light);--digi--color--border--interactive--hover--primary:var(--digi--color--border--interactive--hover--primary--light);--digi--color--border--interactive--hover--secondary:var(--digi--color--border--interactive--hover--secondary--light);--digi--color--border--interactive--selected--primary:var(--digi--color--border--interactive--selected--primary--light);--digi--color--border--interactive--selected--secondary:var(--digi--color--border--interactive--selected--secondary--light);--digi--color--border--interactive--validation--error:var(--digi--color--border--interactive--validation--error--light);--digi--color--border--interactive--validation--success:var(--digi--color--border--interactive--validation--success--light);--digi--color--border--interactive--validation--warning:var(--digi--color--border--interactive--validation--warning--light);--digi--color--border--notification:var(--digi--color--border--notification--light);--digi--color--border--sentiment--error:var(--digi--color--border--sentiment--error--light);--digi--color--border--sentiment--info:var(--digi--color--border--sentiment--info--light);--digi--color--border--sentiment--success:var(--digi--color--border--sentiment--success--light);--digi--color--border--sentiment--warning:var(--digi--color--border--sentiment--warning--light);--digi--color--border--transparent:var(--digi--color--border--transparent--light);--digi--color--divider--cta:var(--digi--color--divider--cta--light);--digi--color--divider--on-brand-primary:var(--digi--color--divider--on-brand-primary--light);--digi--color--divider--primary:var(--digi--color--divider--primary--light);--digi--color--divider--secondary:var(--digi--color--divider--secondary--light);--digi--color--icon--brand-primary:var(--digi--color--icon--brand-primary--light);--digi--color--icon--brand-secondary:var(--digi--color--icon--brand-secondary--light);--digi--color--icon--cta:var(--digi--color--icon--cta--light);--digi--color--icon--primary:var(--digi--color--icon--primary--light);--digi--color--icon--secondary:var(--digi--color--icon--secondary--light);--digi--color--icon--validation--error:var(--digi--color--icon--validation--error--light);--digi--color--icon--validation--success:var(--digi--color--icon--validation--success--light);--digi--color--icon--validation--warning:var(--digi--color--icon--validation--warning--light);--digi--color--infographic--background:var(--digi--color--infographic--background--light);--digi--color--infographic--brand--primary:var(--digi--color--infographic--brand--primary--light);--digi--color--infographic--brand--primary-alt:var(--digi--color--infographic--brand--primary-alt--light);--digi--color--infographic--brand--secondary:var(--digi--color--infographic--brand--secondary--light);--digi--color--infographic--brand--secondary-alt:var(--digi--color--infographic--brand--secondary-alt--light);--digi--color--infographic--lineart:var(--digi--color--infographic--lineart--light);--digi--color--logotype--primary--symbol:var(--digi--color--logotype--primary--symbol--light);--digi--color--logotype--primary--text:var(--digi--color--logotype--primary--text--light);--digi--color--logotype--secondary--symbol:var(--digi--color--logotype--secondary--symbol--light);--digi--color--logotype--secondary--text:var(--digi--color--logotype--secondary--text--light);--digi--color--marking--indication--primary:var(--digi--color--marking--indication--primary--light);--digi--color--marking--indication--secondary:var(--digi--color--marking--indication--secondary--light);--digi--color--marking--indication--tertiary:var(--digi--color--marking--indication--tertiary--light);--digi--color--marking--navigation--level-active:var(--digi--color--marking--navigation--level-active--light);--digi--color--marking--navigation--level-inactive:var(--digi--color--marking--navigation--level-inactive--light);--digi--color--marking--navigation--selected:var(--digi--color--marking--navigation--selected--light);--digi--color--misc--skeleton:var(--digi--color--misc--skeleton--light);--digi--color--misc--spinner-path:var(--digi--color--misc--spinner-path--light);--digi--color--text--description:var(--digi--color--text--description--light);--digi--color--text--interactive--brand-primary:var(--digi--color--text--interactive--brand-primary--light);--digi--color--text--interactive--brand-secondary:var(--digi--color--text--interactive--brand-secondary--light);--digi--color--text--interactive--primary:var(--digi--color--text--interactive--primary--light);--digi--color--text--interactive--secondary:var(--digi--color--text--interactive--secondary--light);--digi--color--text--interactive--tertiary:var(--digi--color--text--interactive--tertiary--light);--digi--color--text--interactive--visited:var(--digi--color--text--interactive--visited--light);--digi--color--text--primary:var(--digi--color--text--primary--light);--digi--color--text--secondary:var(--digi--color--text--secondary--light)}body.sc-digi-calendar-datepicker{font-size:1rem;font-family:"Open Sans", Arial, sans-serif}.sc-digi-calendar-datepicker-h{--digi--datepicker--max-width:18.75rem;--digi--datepicker--border-radius:0.25rem;--digi--datepicker--calendar--max-width:20.25rem;--digi--datepicker--calendar--show-week--max-width:23.375rem;--digi--datepicker--calendar-shadow:0 0.125rem 0.375rem 0 rgba(0, 0, 0, 0.7);--digi--datepicker--calendar--background-color:var(--digi--color--background--interactive--default--secondary);--digi--datepicker--input-icon--width:0.875rem;--digi--datepicker--input-icon--horizontal-padding:0.75rem;--digi--datepicker--input-icon--vertical-padding:var(--digi--global--spacing--smallest-2);--digi--datepicker--input--inline-start:var(--digi--gutter--medium);--digi--datepicker--input--inline-end:calc(var(--digi--datepicker--input-icon--width) + var(--digi--datepicker--input-icon--horizontal-padding) * 2);box-sizing:content-box}.sc-digi-calendar-datepicker-h .digi-calendar-datepicker.sc-digi-calendar-datepicker{position:relative;pointer-events:none}.sc-digi-calendar-datepicker-h .digi-calendar-datepicker__input-field.sc-digi-calendar-datepicker{position:relative;max-width:var(--digi--datepicker--max-width);pointer-events:auto}.sc-digi-calendar-datepicker-h .digi-calendar-datepicker__input-field.sc-digi-calendar-datepicker .digi-calendar-datepicker__inactive.sc-digi-calendar-datepicker{--digi--form-input--background--empty:var(--digi--datepicker--input--inactive-background)}.sc-digi-calendar-datepicker-h .digi-calendar-datepicker__input-field.sc-digi-calendar-datepicker .digi-calendar-datepicker__input-button.sc-digi-calendar-datepicker{background:var(--digi--color--background--primary);height:var(--digi--form-input--height--medium);color:inherit;border:1px solid var(--digi--color--border--interactive--default--on-input);border-left:none;padding:0;font:inherit;outline:inherit;cursor:pointer}.sc-digi-calendar-datepicker-h .digi-calendar-datepicker__input-field.sc-digi-calendar-datepicker .digi-calendar-datepicker__input-button.sc-digi-calendar-datepicker .digi-calendar-datepicker__button-icon.sc-digi-calendar-datepicker{box-sizing:content-box;width:var(--digi--datepicker--input-icon--width);padding:var(--digi--datepicker--input-icon--vertical-padding) var(--digi--datepicker--input-icon--horizontal-padding)}.sc-digi-calendar-datepicker-h .digi-calendar-datepicker__input-field.sc-digi-calendar-datepicker .digi-calendar-datepicker__input-button.sc-digi-calendar-datepicker svg.sc-digi-calendar-datepicker{color:var(--digi--color--icon--brand-primary)}.sc-digi-calendar-datepicker-h .digi-calendar-datepicker__input-field.sc-digi-calendar-datepicker .digi-calendar-datepicker__input-button.sc-digi-calendar-datepicker:focus-visible{outline:2px solid black;outline-offset:2px;box-shadow:0px 0px 0px 5px white}.sc-digi-calendar-datepicker-h .digi-calendar-datepicker__input-field.sc-digi-calendar-datepicker .digi-calendar-datepicker__input-button.sc-digi-calendar-datepicker:hover,.sc-digi-calendar-datepicker-h .digi-calendar-datepicker__input-field.sc-digi-calendar-datepicker .digi-calendar-datepicker__input-button.sc-digi-calendar-datepicker:focus{background:var(--digi--color--background--interactive--hover--secondary)}.sc-digi-calendar-datepicker-h .digi-calendar-datepicker__calendar.sc-digi-calendar-datepicker{max-width:var(--digi--datepicker--calendar--max-width);height:0px;border-radius:var(--digi--datepicker--border-radius);overflow:hidden;z-index:1}.sc-digi-calendar-datepicker-h .digi-calendar-datepicker__show-week-numbers.sc-digi-calendar-datepicker .digi-calendar-datepicker__calendar.sc-digi-calendar-datepicker{max-width:var(--digi--datepicker--calendar--show-week--max-width)}.sc-digi-calendar-datepicker-h .digi-calendar-datepicker__show-calendar.sc-digi-calendar-datepicker .digi-calendar-datepicker__calendar.sc-digi-calendar-datepicker{height:auto;background-color:var(--digi--datepicker--calendar--background-color);box-shadow:var(--digi--datepicker--calendar-shadow);position:absolute;top:var(--digi--datepicker--calendar--popup-top);left:0;pointer-events:auto}.sc-digi-calendar-datepicker-h .digi-calendar-datepicker__input-component.sc-digi-calendar-datepicker{--digi--form-input--padding:0 var(--digi--datepicker--input--inline-end) 0 var(--digi--datepicker--input--inline-start)}.sc-digi-calendar-datepicker-h .digi-calendar-datepicker__selected-date-alert.sc-digi-calendar-datepicker{border:0;clip:rect(1px, 1px, 1px, 1px);-webkit-clip-path:inset(50%);clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;white-space:nowrap}.sc-digi-calendar-datepicker-h .digi-calendar-datepicker__sr-instructions.sc-digi-calendar-datepicker{border:0;clip:rect(1px, 1px, 1px, 1px);-webkit-clip-path:inset(50%);clip-path:inset(50%);height:1px;margin:-1px;overflow:hidden;padding:0;position:absolute;width:1px;white-space:nowrap}`;
2181
2691
 
2182
2692
  const CalendarDatepicker = class {
@@ -2665,4 +3175,1033 @@ const CalendarDatepicker = class {
2665
3175
  };
2666
3176
  CalendarDatepicker.style = calendarDatepickerCss();
2667
3177
 
2668
- export { CalendarDatepicker as digi_calendar_datepicker };
3178
+ const expandableAccordionCss = () => `.sc-digi-expandable-accordion-h{--digi--expandable-accordion--header--toggle-icon--transition:ease-in-out var(--digi--animation--duration--base) all;--digi--expandable-accordion--header--font-size:var(--digi--typography--accordion--font-size--desktop);--digi--expandable-accordion--header--font-size--small:var(--digi--typography--accordion--font-size--mobile);--digi--expandable-accordion--header--font-weight:var(--digi--typography--accordion--font-weight--desktop);--digi--expandable-accordion--icon--size:0.875rem;--digi--expandable-accordion--icon--margin-right:var(--digi--margin--medium);--digi--expandable-accordion--border-bottom-width:var(--digi--border-width--secondary);--digi--expandable-accordion--border-bottom-color:var(--digi--color--divider--cta);--digi--expandable-accordion--content--padding:var(--digi--padding--medium) 0;--digi--expandable-accordion--content--transition:ease-in-out var(--digi--animation--duration--base) height;display:block}.sc-digi-expandable-accordion-h .digi-expandable-accordion.sc-digi-expandable-accordion::after{content:"";display:block;max-width:var(--digi--paragraph-width--medium);border-bottom-width:var(--digi--expandable-accordion--border-bottom-width);border-bottom-color:var(--digi--expandable-accordion--border-bottom-color);border-bottom-style:solid;margin-top:calc(var(--digi--expandable-accordion--border-bottom-width) * -1)}.sc-digi-expandable-accordion-h .digi-expandable-accordion--fullwidth.sc-digi-expandable-accordion::after{content:"";display:block;max-width:none;border-bottom-width:var(--digi--expandable-accordion--border-bottom-width);border-bottom-style:solid;margin-top:calc(var(--digi--expandable-accordion--border-bottom-width) * -1)}.digi-expandable-accordion__header.sc-digi-expandable-accordion{display:flex;align-items:center}.digi-expandable-accordion--variation-primary.sc-digi-expandable-accordion .digi-expandable-accordion__header.sc-digi-expandable-accordion{max-width:var(--digi--paragraph-width--medium);border-bottom-width:var(--digi--expandable-accordion--border-bottom-width);border-bottom-color:var(--digi--expandable-accordion--border-bottom-color);border-bottom-style:solid}.digi-expandable-accordion--fullwidth.sc-digi-expandable-accordion .digi-expandable-accordion__header.sc-digi-expandable-accordion{max-width:none}.digi-expandable-accordion__toggle-icon.sc-digi-expandable-accordion{transition:var(--digi--expandable-accordion--header--toggle-icon--transition)}.digi-expandable-accordion--expanded-true.sc-digi-expandable-accordion .digi-expandable-accordion__toggle-icon.sc-digi-expandable-accordion{transform:rotate(-180deg)}.digi-expandable-accordion__heading.sc-digi-expandable-accordion{margin:0;flex:1}.digi-expandable-accordion__heading-text.sc-digi-expandable-accordion{max-width:var(--digi--paragraph-width--medium)}.digi-expandable-accordion__button.sc-digi-expandable-accordion{font-family:var(--digi--global--typography--font-family--default);font-size:var(--digi--expandable-accordion--header--font-size--small);font-weight:var(--digi--expandable-accordion--header--font-weight);width:100%;display:flex;gap:var(--digi--expandable-accordion--icon--margin-right);align-items:center;text-align:start;cursor:pointer;border:none}@media (min-width: 48rem){.digi-expandable-accordion__button.sc-digi-expandable-accordion{font-size:var(--digi--expandable-accordion--header--font-size)}}.digi-expandable-accordion--variation-primary.sc-digi-expandable-accordion .digi-expandable-accordion__button.sc-digi-expandable-accordion{color:var(--digi--color--text--primary);background-color:transparent;padding:var(--digi--expandable-accordion--content--padding)}.digi-expandable-accordion--variation-primary.sc-digi-expandable-accordion .digi-expandable-accordion__button.sc-digi-expandable-accordion:focus-visible{outline:2px solid black;outline-offset:2px;box-shadow:0px 0px 0px 5px white}.digi-expandable-accordion--variation-primary.sc-digi-expandable-accordion .digi-expandable-accordion__button.sc-digi-expandable-accordion:hover{text-decoration:underline}.digi-expandable-accordion--fullwidth.sc-digi-expandable-accordion .digi-expandable-accordion__button.sc-digi-expandable-accordion{max-width:none}.digi-expandable-accordion__content.sc-digi-expandable-accordion{overflow-y:hidden}.digi-expandable-accordion--expanded-false.sc-digi-expandable-accordion .digi-expandable-accordion__content.sc-digi-expandable-accordion{height:0}.digi-expandable-accordion--variation-primary.sc-digi-expandable-accordion .digi-expandable-accordion__content.sc-digi-expandable-accordion>div.sc-digi-expandable-accordion{padding:var(--digi--expandable-accordion--content--padding)}.digi-expandable-accordion--variation-primary.digi-expandable-accordion--animation-true.sc-digi-expandable-accordion .digi-expandable-accordion__content.sc-digi-expandable-accordion{transition:var(--digi--expandable-accordion--content--transition)}.digi-expandable-accordion__toggle-inside.sc-digi-expandable-accordion{text-align:center;--digi--button--color--background--function--hover:var(--digi--color--background--primary)}@keyframes heightAnim{from{height:0%}to{height:100%}}`;
3179
+
3180
+ const ExpandableAccordion = class {
3181
+ constructor(hostRef) {
3182
+ registerInstance(this, hostRef);
3183
+ this.afOnClick = createEvent(this, "afOnClick", 7);
3184
+ /**
3185
+ * Sätter utfällbar rubrik. 'h2' är förvalt.
3186
+ * @en Set heading level. Default is 'h2'
3187
+ */
3188
+ this.afHeadingLevel = ExpandableAccordionHeaderLevel.H2;
3189
+ /**
3190
+ * Gör så att komponenten tar upp 100% i bredd av ytan den befinner sig i.
3191
+ * @en Makes the component take up 100% of the width of the surface it is in.
3192
+ */
3193
+ this.afFullWidth = false;
3194
+ /**
3195
+ * Sätter läge på rubriken om den ska vara expanderad eller ej.
3196
+ * @en Sets the state of the accordion to expanded or not.
3197
+ */
3198
+ this.afExpanded = false;
3199
+ /**
3200
+ * Ställer in ifall komponenten ska ha en animation vid utfällning. Animation är påslagen som standard.
3201
+ * @en Sets the state of the animation for the accordion's expanded area. Animation is on as default.
3202
+ */
3203
+ this.afAnimation = true;
3204
+ /**
3205
+ * Sätter attributet 'id'. Om inget väljs så skapas ett slumpmässigt id.
3206
+ * @en Set id attribute. Defaults to random string.
3207
+ */
3208
+ this.afId = randomIdGenerator('digi-expandable-accordion');
3209
+ /**
3210
+ * Sätter texten som visas på knappen som expanderar komponenten. Om inget väljs så används "Visa"
3211
+ * @en Sets the text on the button that expands the component. Defaults to "Visa".
3212
+ */
3213
+ this.afExpandText = _t.show;
3214
+ /**
3215
+ * Sätter texten som visas på knappen som kollapsar komponenten. Om inget väljs så används "Dölj"
3216
+ * @en Sets the text on the button that collapses the component. Defaults to "Dölj".
3217
+ */
3218
+ this.afCollapseText = _t.hide;
3219
+ }
3220
+ get cssModifiers() {
3221
+ return {
3222
+ [`digi-expandable-accordion--expanded-${!!this.afExpanded}`]: true,
3223
+ [`digi-expandable-accordion--animation-${!!this.afAnimation}`]: true,
3224
+ [`digi-expandable-accordion--variation-primary`]: true,
3225
+ [`digi-expandable-accordion--fullwidth`]: this.afFullWidth
3226
+ };
3227
+ }
3228
+ /**
3229
+ * Hämtar en höjden till innehållet i Utfällbar yta och animera innehållet.
3230
+ * @en Gets a height to the content for expandable and animate the content.
3231
+ */
3232
+ componentDidLoad() {
3233
+ const content = this.hostElement.querySelector(`#${this.afId}-content`);
3234
+ if (!this.afExpanded) {
3235
+ content.style.visibility = 'hidden';
3236
+ }
3237
+ else {
3238
+ content.style.overflowY = 'inherit';
3239
+ content.style.height = 'auto';
3240
+ }
3241
+ content.addEventListener('transitionend', () => {
3242
+ if (!this.afExpanded) {
3243
+ content.style.visibility = 'hidden';
3244
+ content.style.height = '0px';
3245
+ }
3246
+ else {
3247
+ content.style.height = 'auto';
3248
+ content.style.overflowY = 'inherit';
3249
+ }
3250
+ });
3251
+ }
3252
+ animateContentHeight() {
3253
+ const content = this.hostElement.querySelector(`#${this.afId}-content`);
3254
+ const sectionHeight = content.firstElementChild
3255
+ .offsetHeight;
3256
+ if (!this.afExpanded && content.style.height === 'auto') {
3257
+ content.style.height = sectionHeight + 'px';
3258
+ setTimeout(() => {
3259
+ content.style.height = '0';
3260
+ content.style.overflowY = 'hidden';
3261
+ });
3262
+ return;
3263
+ }
3264
+ if (this.afExpanded) {
3265
+ content.style.height = sectionHeight + 'px';
3266
+ content.style.visibility = 'visible';
3267
+ if (!this.afAnimation) {
3268
+ setTimeout(() => {
3269
+ content.style.height = 'auto';
3270
+ content.style.overflowY = 'inherit';
3271
+ });
3272
+ }
3273
+ }
3274
+ else {
3275
+ content.style.height = '0px';
3276
+ }
3277
+ }
3278
+ clickToggleHandler(e, resetFocus = false) {
3279
+ e.preventDefault();
3280
+ this.afExpanded = !this.afExpanded;
3281
+ if (resetFocus) {
3282
+ this._button.focus();
3283
+ }
3284
+ this.afOnClick.emit(e);
3285
+ }
3286
+ render() {
3287
+ return (h("article", { key: '2616819e45750577fb23f430d41b2787ca2210a5', "aria-expanded": this.afExpanded ? 'true' : 'false', class: Object.assign({ 'digi-expandable-accordion': true }, this.cssModifiers) }, h("header", { key: 'c77c15183eb4bba670ea2299d5dc3c19e243ea42', class: "digi-expandable-accordion__header" }, h(this.afHeadingLevel, { key: '20dc16774240b6d258eec3d94d4b5d9b9d0a735c', class: "digi-expandable-accordion__heading" }, h("button", { key: '23c45158f203517166cd4c5efe8801b849ea04e0', type: "button", class: "digi-expandable-accordion__button", onClick: (e) => this.clickToggleHandler(e), "aria-expanded": this.afExpanded ? 'true' : 'false', "aria-controls": `${this.afId}-content`, ref: (el) => (this._button = el) }, h("digi-icon-chevron-down", { key: 'bd48367111a6aac92061bda052ffb6708d4f3967', class: "digi-expandable-accordion__toggle-icon" }), h("div", { key: '2e419d3fd48aa8fd31f33012b541a0fd86e60d78', class: "digi-expandable-accordion__heading-text" }, this.afHeading)))), h("section", { key: 'a28657a14024836c9bb1c7e825c573ed6c598eca', class: "digi-expandable-accordion__content", id: `${this.afId}-content` }, h("div", { key: 'e13b9e653c1714adefd5401300789ed89d4cc1b3' }, h("digi-typography", { key: '335442cf9f97ec3f821ab2ca296e1539b24354cf' }, h("slot", { key: '05da2edf48d9259187bb72bf73a6c60ec9077bc0' }))))));
3288
+ }
3289
+ get hostElement() { return getElement(this); }
3290
+ static get watchers() { return {
3291
+ "afExpanded": [{
3292
+ "animateContentHeight": 0
3293
+ }]
3294
+ }; }
3295
+ };
3296
+ ExpandableAccordion.style = expandableAccordionCss();
3297
+
3298
+ const expandableFaqItemCss = () => `.sc-digi-expandable-faq-item-h{--digi--expandable-faq-item--header--background-color--primary:var(--digi--color--background--pop-out);--digi--expandable-faq-item--header--background-color--secondary:var(--digi--color--background--secondary);--digi--expandable-faq-item--header--background-color--tertiary:var(--digi--color--background--primary);--digi--expandable-faq-item--header--toggle-icon--transition:ease-in-out var(--digi--animation--duration--base) all;--digi--expandable-faq-item--content--transition:ease-in-out var(--digi--animation--duration--base) height;--digi--expandable-faq-item--icon--size:0.875rem;--digi--expandable-faq-item--icon--margin-right:var(--digi--margin--medium);--digi--expandable-faq-item--header--font-size:var(--digi--typography--preamble--font-size--desktop);--digi--expandable-faq-item--header--font-weight:var(--digi--typography--preamble--font-weight--desktop);--digi--expandable-faq-item--border-width:var(--digi--border-width--secondary);--digi--expandable-faq-item--border-bottom-width:var(--digi--border-width--secondary);--digi--expandable-faq-item--content--padding:var(--digi--gutter--largest-2);display:block}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item--primary.sc-digi-expandable-faq-item{--BACKGROUND:var(--digi--expandable-faq-item--header--background-color--primary)}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item--secondary.sc-digi-expandable-faq-item{--BACKGROUND:var(--digi--expandable-faq-item--header--background-color--secondary)}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item--tertiary.sc-digi-expandable-faq-item{--BACKGROUND:var(--digi--expandable-faq-item--header--background-color--tertiary)}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item.sc-digi-expandable-faq-item{margin-bottom:var(--digi--global--spacing--smallest-4);font-family:var(--digi--global--typography--font-family--default)}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item--expanded.sc-digi-expandable-faq-item{border-bottom-color:var(--BACKGROUND)}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__header.sc-digi-expandable-faq-item{background-color:var(--BACKGROUND);width:100%;max-width:calc(var(--digi--paragraph-width--medium) + var(--digi--padding--largest-2))}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__header.sc-digi-expandable-faq-item .digi-expandable-faq-item--fullwidth.sc-digi-expandable-faq-item{max-width:none}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__header-text.sc-digi-expandable-faq-item{max-width:var(--digi--paragraph-width--medium)}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__header.sc-digi-expandable-faq-item h1.sc-digi-expandable-faq-item,.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__header.sc-digi-expandable-faq-item h2.sc-digi-expandable-faq-item,.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__header.sc-digi-expandable-faq-item h3.sc-digi-expandable-faq-item,.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__header.sc-digi-expandable-faq-item h4.sc-digi-expandable-faq-item,.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__header.sc-digi-expandable-faq-item h5.sc-digi-expandable-faq-item,.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__header.sc-digi-expandable-faq-item h6.sc-digi-expandable-faq-item{margin:0}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__header--toggle-icon.sc-digi-expandable-faq-item{margin-right:var(--digi--expandable-faq-item--icon--margin-right);transition:var(--digi--expandable-faq-item--header--toggle-icon--transition)}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__header--toggle-icon--expanded.sc-digi-expandable-faq-item{transform:rotate(-180deg)}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__header--toggle-icon.sc-digi-expandable-faq-item-s>[slot^=icon],.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__header--toggle-icon .sc-digi-expandable-faq-item-s>[slot^=icon]{--digi--icon--width:var(--digi--expandable-faq-item--icon--size);--digi--icon--height:var(--digi--expandable-faq-item--icon--size)}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item--fullwidth.sc-digi-expandable-faq-item .digi-expandable-faq-item__header.sc-digi-expandable-faq-item{max-width:none}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__button.sc-digi-expandable-faq-item{color:var(--digi--color--text--primary);background-color:var(--BACKGROUND);border:none;border-radius:0;padding:var(--digi--expandable-faq-item--content--padding);font-size:var(--digi--expandable-faq-item--header--font-size);font-weight:var(--digi--expandable-faq-item--header--font-weight);width:100%;display:flex;align-items:center;text-align:left;cursor:pointer;font-family:var(--digi--global--typography--font-family--default)}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__button.sc-digi-expandable-faq-item:hover{text-decoration:underline}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__button.sc-digi-expandable-faq-item:focus-visible{outline:2px solid black;outline-offset:2px;box-shadow:0px 0px 0px 5px white}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__content.sc-digi-expandable-faq-item{overflow-y:hidden}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__content.sc-digi-expandable-faq-item>div.sc-digi-expandable-faq-item{padding:var(--digi--expandable-faq-item--content--padding);box-sizing:border-box;max-width:var(--digi--paragraph-width--medium)}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__content--animation.sc-digi-expandable-faq-item{transition:var(--digi--expandable-faq-item--content--transition)}.sc-digi-expandable-faq-item-h .digi-expandable-faq-item__content--hidden.sc-digi-expandable-faq-item{height:0}`;
3299
+
3300
+ const ExpandableFaqItem = class {
3301
+ constructor(hostRef) {
3302
+ registerInstance(this, hostRef);
3303
+ this.afOnClick = createEvent(this, "afOnClick", 7);
3304
+ /**
3305
+ * Sätter rubriknivå. 'h3' är förvalt.
3306
+ * @en Set heading level. Default is 'h3'
3307
+ */
3308
+ this.afHeadingLevel = ExpandableFaqItemHeadingLevel.H3;
3309
+ /**
3310
+ * Gör så att komponenten tar upp 100% i bredd av ytan den befinner sig i.
3311
+ * @en Makes the component take up 100% of the width of the surface it is in.
3312
+ */
3313
+ this.afFullWidth = false;
3314
+ /**
3315
+ * Sätter läge på FAQ-frågan om den ska vara expanderad eller ej.
3316
+ * @en Sets the state of the FAQ item to expanded or not.
3317
+ */
3318
+ this.afExpanded = false;
3319
+ /**
3320
+ * Sätter variant. Kan vara 'Primary' eller 'Secondary'
3321
+ * @en Set variation. Can be 'Primary' or 'Secondary'
3322
+ */
3323
+ this.afVariation = ExpandableFaqItemVariation.PRIMARY;
3324
+ /**
3325
+ * Ställer in ifall komponenten ska ha en animation vid utfällning. Animation är påslagen som standard.
3326
+ * @en Sets the state of the animation for the accordion's expanded area. Animation is on as default.
3327
+ */
3328
+ this.afAnimation = true;
3329
+ /**
3330
+ * Sätter attributet 'id'. Om inget väljs så skapas ett slumpmässigt id.
3331
+ * @en Set id attribute. Defaults to random string.
3332
+ */
3333
+ this.afId = randomIdGenerator('digi-expandable-faq-item');
3334
+ }
3335
+ get cssModifiers() {
3336
+ return {
3337
+ 'digi-expandable-faq-item--expanded': this.afExpanded,
3338
+ 'digi-expandable-faq-item--fullwidth': this.afFullWidth,
3339
+ 'digi-expandable-faq-item--primary': this.afVariation === ExpandableFaqItemVariation.PRIMARY,
3340
+ 'digi-expandable-faq-item--secondary': this.afVariation === ExpandableFaqItemVariation.SECONDARY,
3341
+ 'digi-expandable-faq-item--tertiary': this.afVariation === ExpandableFaqItemVariation.TERTIARY
3342
+ };
3343
+ }
3344
+ /**
3345
+ * Hämtar en höjden till innehållet i vanliga frågor och svar och animera innehållet.
3346
+ * @en Gets a height to the content for FAQ and animate the content.
3347
+ */
3348
+ componentDidLoad() {
3349
+ const content = this.hostElement.querySelector(`#${this.afId}-content`);
3350
+ if (!this.afExpanded) {
3351
+ content.style.visibility = 'hidden';
3352
+ }
3353
+ else {
3354
+ content.style.height = 'auto';
3355
+ content.style.overflowY = 'inherit';
3356
+ }
3357
+ content.addEventListener('transitionend', () => {
3358
+ if (!this.afExpanded) {
3359
+ content.style.visibility = 'hidden';
3360
+ content.style.height = '0px';
3361
+ }
3362
+ else {
3363
+ content.style.height = 'auto';
3364
+ content.style.overflowY = 'inherit';
3365
+ }
3366
+ });
3367
+ }
3368
+ animateContentHeight() {
3369
+ const content = this.hostElement.querySelector(`#${this.afId}-content`);
3370
+ const sectionHeight = content.firstElementChild
3371
+ .offsetHeight;
3372
+ if (!this.afExpanded && content.style.height === 'auto') {
3373
+ content.style.height = sectionHeight + 'px';
3374
+ setTimeout(() => {
3375
+ content.style.height = '0';
3376
+ content.style.overflowY = 'hidden';
3377
+ });
3378
+ return;
3379
+ }
3380
+ if (this.afExpanded) {
3381
+ content.style.height = sectionHeight + 'px';
3382
+ content.style.visibility = 'visible';
3383
+ if (!this.afAnimation) {
3384
+ setTimeout(() => {
3385
+ content.style.height = 'auto';
3386
+ content.style.overflowY = 'inherit';
3387
+ });
3388
+ }
3389
+ }
3390
+ else {
3391
+ content.style.height = '0px';
3392
+ }
3393
+ }
3394
+ render() {
3395
+ return (h("article", { key: 'e0931c4256d2c4162911fe232132b6179968425f', "aria-expanded": this.afExpanded ? 'true' : 'false', class: Object.assign({ 'digi-expandable-faq-item': true }, this.cssModifiers) }, h("header", { key: '8f6befff5c82c63d5d1f10755f444791f17dafb7', class: "digi-expandable-faq-item__header" }, h(this.afHeadingLevel, { key: 'b9d58dcd28eb430d7b84365ba1bba99d3e86ebc9' }, h("button", { key: 'b2c20566cc84a2b4cbcbe2dcc2a35e44e8f0fcc9', type: "button", class: "digi-expandable-faq-item__button", onClick: (e) => {
3396
+ e.preventDefault();
3397
+ this.afExpanded = !this.afExpanded;
3398
+ this.afOnClick.emit(e);
3399
+ }, "aria-expanded": this.afExpanded ? 'true' : 'false', "aria-controls": `${this.afId}-content` }, h("digi-icon-chevron-down", { key: '40e0a896b3d7d44bf282e8462a24c43060a29eff', class: {
3400
+ 'digi-expandable-faq-item__header--toggle-icon': true,
3401
+ 'digi-expandable-faq-item__header--toggle-icon--expanded': this.afExpanded
3402
+ } }), h("div", { key: 'f58aa361553f3063bf1e5171f8d320e6cb8189c6', class: "digi-expandable-faq-item__header-text" }, this.afHeading)))), h("section", { key: 'b4d0dd00a3e6fe9e8367ef5a6f197696de55f4fd', class: {
3403
+ 'digi-expandable-faq-item__content': true,
3404
+ 'digi-expandable-faq-item__content--animation': this.afAnimation,
3405
+ 'digi-expandable-faq-item__content--hidden': !this.afExpanded
3406
+ }, id: `${this.afId}-content` }, h("div", { key: 'e9a9147164d3934584cd5da5cfc8080ba9374c76' }, h("digi-typography", { key: '398a0c4e0aa1092db5f4a2e3182218ebbe0c3624' }, h("slot", { key: 'be924dc541b7c41b19b4392d3a988b492144d585' }))))));
3407
+ }
3408
+ get hostElement() { return getElement(this); }
3409
+ static get watchers() { return {
3410
+ "afExpanded": [{
3411
+ "animateContentHeight": 0
3412
+ }]
3413
+ }; }
3414
+ };
3415
+ ExpandableFaqItem.style = expandableFaqItemCss();
3416
+
3417
+ const formInputCss = () => `.sc-digi-form-input-h{--digi--form-input--height--small:var(--digi--input-height--small);--digi--form-input--height--medium:var(--digi--input-height--medium);--digi--form-input--height--large:var(--digi--input-height--large);--digi--form-input--border-radius:var(--digi--border-radius--input);--digi--form-input--padding:0 var(--digi--gutter--medium);--digi--form-input--background--empty:var(--digi--color--background--interactive--default--input-elements);--digi--form-input--background--neutral:var(--digi--color--background--interactive--default--input-elements);--digi--form-input--background--success:var(--digi--color--background--interactive--validation--success);--digi--form-input--background--warning:var(--digi--color--background--interactive--validation--warning);--digi--form-input--background--error:var(--digi--color--background--interactive--validation--error);--digi--form-input--border--neutral:var(--digi--border-width--input-regular) solid;--digi--form-input--border--error:var(--digi--border-width--input-validation) solid;--digi--form-input--border--success:var(--digi--border-width--input-validation) solid;--digi--form-input--border--warning:var(--digi--border-width--input-validation) solid;--digi--form-input--border-color--neutral:var(--digi--color--border--interactive--default--on-input);--digi--form-input--border-color--success:var(--digi--color--border--interactive--validation--success);--digi--form-input--border-color--warning:var(--digi--color--border--interactive--validation--warning);--digi--form-input--border-color--error:var(--digi--color--border--interactive--validation--error)}.sc-digi-form-input-h .digi-form-input.sc-digi-form-input{display:flex;flex-direction:column;gap:0.4em}.sc-digi-form-input-h .digi-form-input--small.sc-digi-form-input{--HEIGHT:var(--digi--form-input--height--small)}.sc-digi-form-input-h .digi-form-input--medium.sc-digi-form-input{--HEIGHT:var(--digi--form-input--height--medium)}.sc-digi-form-input-h .digi-form-input--large.sc-digi-form-input{--HEIGHT:var(--digi--form-input--height--large)}.sc-digi-form-input-h .digi-form-input--neutral.sc-digi-form-input{--BORDER:var(--digi--form-input--border--neutral);--BORDER-COLOR:var(--digi--form-input--border-color--neutral);--BACKGROUND:var(--digi--form-input--background--neutral)}.sc-digi-form-input-h .digi-form-input--empty.sc-digi-form-input:not(:focus-within){--BACKGROUND:var(--digi--form-input--background--empty)}.sc-digi-form-input-h .digi-form-input--success.sc-digi-form-input{--BORDER:var(--digi--form-input--border--success);--BORDER-COLOR:var(--digi--form-input--border-color--success);--BACKGROUND:var(--digi--form-input--background--success)}.sc-digi-form-input-h .digi-form-input--warning.sc-digi-form-input{--BORDER:var(--digi--form-input--border--warning);--BORDER-COLOR:var(--digi--form-input--border-color--warning);--BACKGROUND:var(--digi--form-input--background--warning)}.sc-digi-form-input-h .digi-form-input--error.sc-digi-form-input{--BORDER:var(--digi--form-input--border--error);--BORDER-COLOR:var(--digi--form-input--border-color--error);--BACKGROUND:var(--digi--form-input--background--error)}.digi-form-input__input-wrapper.sc-digi-form-input{position:relative;display:flex}.digi-form-input__input-wrapper.sc-digi-form-input-s>[slot^=button] button,.digi-form-input__input-wrapper .sc-digi-form-input-s>[slot^=button] button{--MIN-HEIGHT:100%}.digi-form-input--button-variation-primary .digi-form-input__input-wrapper.sc-digi-form-input-s>[slot^=button] button,.digi-form-input__input-wrapper .sc-digi-form-input-s>[slot^=button] button{border-start-start-radius:0;border-end-start-radius:0}.digi-form-input--button-variation-secondary.digi-form-input--has-button-true.sc-digi-form-input .digi-form-input__input-wrapper.sc-digi-form-input{gap:var(--digi--gutter--medium);flex-wrap:wrap}.digi-form-input__input.sc-digi-form-input{flex:1;height:var(--HEIGHT);font-family:var(--digi--global--typography--font-family--default);font-size:var(--digi--typography--body--font-size--desktop);padding:var(--digi--form-input--padding);color:var(--digi--color--text--primary);background:var(--BACKGROUND);border:var(--BORDER);border-color:var(--BORDER-COLOR);border-radius:var(--digi--form-input--border-radius);box-sizing:border-box}.digi-form-input__input.sc-digi-form-input:focus-visible{outline:2px solid black;outline-offset:2px;box-shadow:0px 0px 0px 5px white}.digi-form-input--button-variation-primary.digi-form-input--has-button-true.sc-digi-form-input .digi-form-input__input.sc-digi-form-input{border-end-end-radius:0;border-start-end-radius:0}`;
3418
+
3419
+ const FormInput = class {
3420
+ constructor(hostRef) {
3421
+ registerInstance(this, hostRef);
3422
+ this.afOnChange = createEvent(this, "afOnChange", 7);
3423
+ this.afOnBlur = createEvent(this, "afOnBlur", 7);
3424
+ this.afOnKeyup = createEvent(this, "afOnKeyup", 7);
3425
+ this.afOnFocus = createEvent(this, "afOnFocus", 7);
3426
+ this.afOnFocusout = createEvent(this, "afOnFocusout", 7);
3427
+ this.afOnInput = createEvent(this, "afOnInput", 7);
3428
+ this.afOnDirty = createEvent(this, "afOnDirty", 7);
3429
+ this.afOnTouched = createEvent(this, "afOnTouched", 7);
3430
+ this.afOnReady = createEvent(this, "afOnReady", 3);
3431
+ this.hasActiveValidationMessage = false;
3432
+ this.dirty = false;
3433
+ this.touched = false;
3434
+ /**
3435
+ * Sätter attributet 'type'.
3436
+ * @en Input type attribute
3437
+ */
3438
+ this.afType = FormInputType.TEXT;
3439
+ /**
3440
+ * Sätter attributet 'inputmode'.
3441
+ * @en Inputmode type attribute
3442
+ */
3443
+ this.afInputmode = FormInputMode.DEFAULT;
3444
+ /**
3445
+ * Layout för hur inmatningsfältet ska visas då det finns en knapp
3446
+ * @en Input layout when there is a button
3447
+ */
3448
+ this.afButtonVariation = FormInputButtonVariation.PRIMARY;
3449
+ /**
3450
+ * Sätter variant. Kan vara 'small', 'medium' eller 'large'
3451
+ * @en Set input variation.
3452
+ */
3453
+ this.afVariation = FormInputVariation.MEDIUM;
3454
+ /**
3455
+ * Sätter attributet 'id'. Om inget väljs så skapas ett slumpmässigt id.
3456
+ * @en Input id attribute. Defaults to random string.
3457
+ */
3458
+ this.afId = randomIdGenerator('digi-form-input');
3459
+ /**
3460
+ * Sätt denna till true om formuläret innehåller fler obligatoriska fält än valfria.
3461
+ * @en Set this to true if the form contains more required fields than optional fields.
3462
+ */
3463
+ this.afAnnounceIfOptional = false;
3464
+ /**
3465
+ * Sätter valideringsstatus. Kan vara 'success', 'error', 'warning', 'neutral' eller ingenting.
3466
+ * @en Set input validation status
3467
+ */
3468
+ this.afValidation = FormInputValidation.NEUTRAL;
3469
+ /**
3470
+ * Om värdet är true får felmeddelandet attributet role="alert".
3471
+ * Om felet visas tillsammans med flera andra fel (till exempel efter servervalidering) ska värdet sättas till false.
3472
+ * @en If the value is true, the error message gets the attribute role="alert".
3473
+ * If the error is shown together with multiple errors (for example after server-side validation), the value should be set to false.
3474
+ */
3475
+ this.afErrorMessageIsAlert = true;
3476
+ }
3477
+ onValueChanged(value) {
3478
+ this.afValue = value;
3479
+ }
3480
+ onAfValueChanged(value) {
3481
+ this.value = value;
3482
+ if (this._input && this._input.value !== String(value !== null && value !== void 0 ? value : '')) {
3483
+ this._input.value = String(value !== null && value !== void 0 ? value : '');
3484
+ }
3485
+ }
3486
+ get errorMessageIsAlert() {
3487
+ return (this.afErrorMessageIsAlert !== false &&
3488
+ this.afErrorMessageIsAlert !== 'false');
3489
+ }
3490
+ afValidationTextWatch() {
3491
+ this.setActiveValidationMessage();
3492
+ }
3493
+ /**
3494
+ * Hämtar en referens till inputelementet. Bra för att t.ex. sätta fokus programmatiskt.
3495
+ * @en Returns a reference to the input element. Handy for setting focus programmatically.
3496
+ */
3497
+ async afMGetFormControlElement() {
3498
+ return this._input;
3499
+ }
3500
+ /**
3501
+ * Lyssnar på om fokus sätts på custom-elementet och propagerar ner det till själva input-elementet.
3502
+ * @en Listens for when focus is set on the custom element and propagates it down to the actual input element.
3503
+ */
3504
+ focusOnInput() {
3505
+ this._input.focus();
3506
+ }
3507
+ componentWillLoad() {
3508
+ this.afValue ? (this.value = this.afValue) : (this.afValue = this.value);
3509
+ this.setActiveValidationMessage();
3510
+ this.setHasButton();
3511
+ }
3512
+ componentWillUpdate() {
3513
+ this.setHasButton();
3514
+ }
3515
+ componentDidLoad() {
3516
+ this.afOnReady.emit();
3517
+ }
3518
+ setActiveValidationMessage() {
3519
+ this.hasActiveValidationMessage = !!this.afValidationText;
3520
+ }
3521
+ get cssModifiers() {
3522
+ return {
3523
+ 'digi-form-input--small': this.afVariation === FormInputVariation.SMALL,
3524
+ 'digi-form-input--medium': this.afVariation === FormInputVariation.MEDIUM,
3525
+ 'digi-form-input--large': this.afVariation === FormInputVariation.LARGE,
3526
+ 'digi-form-input--neutral': this.afValidation === FormInputValidation.NEUTRAL,
3527
+ 'digi-form-input--success': this.afValidation === FormInputValidation.SUCCESS,
3528
+ 'digi-form-input--error': this.afValidation === FormInputValidation.ERROR,
3529
+ 'digi-form-input--warning': this.afValidation === FormInputValidation.WARNING,
3530
+ [`digi-form-input--button-variation-${this.afButtonVariation}`]: !!this.afButtonVariation,
3531
+ [`digi-form-input--has-button-${this.hasButton}`]: true,
3532
+ 'digi-form-input--empty': !this.afValue &&
3533
+ (!this.afValidation ||
3534
+ this.afValidation === FormInputValidation.NEUTRAL)
3535
+ };
3536
+ }
3537
+ blurHandler(e) {
3538
+ const trimableTypes = [
3539
+ FormInputType.TEXT,
3540
+ FormInputType.EMAIL,
3541
+ FormInputType.SEARCH,
3542
+ FormInputType.TEL,
3543
+ FormInputType.URL
3544
+ ];
3545
+ const shouldTrim = this.afTrimValue && trimableTypes.includes(this.afType);
3546
+ if (shouldTrim && typeof e.target.value === 'string') {
3547
+ const trimmedValue = e.target.value.trim();
3548
+ if (trimmedValue !== e.target.value) {
3549
+ this.afValue = this.value = trimmedValue;
3550
+ if (this._input) {
3551
+ this._input.value = trimmedValue;
3552
+ }
3553
+ // Emittar afOnInput så Angulars value accessor får det trimmade värdet
3554
+ this.afOnInput.emit(e);
3555
+ }
3556
+ }
3557
+ if (!this.touched) {
3558
+ this.afOnTouched.emit(e);
3559
+ this.touched = true;
3560
+ }
3561
+ this.afOnBlur.emit(e);
3562
+ }
3563
+ changeHandler(e) {
3564
+ this.setActiveValidationMessage();
3565
+ this.afOnChange.emit(e);
3566
+ }
3567
+ focusHandler(e) {
3568
+ this.afOnFocus.emit(e);
3569
+ }
3570
+ focusoutHandler(e) {
3571
+ this.afOnFocusout.emit(e);
3572
+ }
3573
+ keyupHandler(e) {
3574
+ this.afOnKeyup.emit(e);
3575
+ }
3576
+ inputHandler(e) {
3577
+ this.afValue = this.value =
3578
+ this.afType === FormInputType.NUMBER
3579
+ ? parseFloat(e.target.value)
3580
+ : e.target.value;
3581
+ if (!this.dirty) {
3582
+ this.afOnDirty.emit(e);
3583
+ this.dirty = true;
3584
+ }
3585
+ this.setActiveValidationMessage();
3586
+ this.afOnInput.emit(e);
3587
+ }
3588
+ setHasButton() {
3589
+ this.hasButton = !!this.hostElement.querySelector('[slot="button"]');
3590
+ }
3591
+ render() {
3592
+ return (h(Host, { key: '2739bdd7385125581d7ea9c25a3610f5950c6a74', tabindex: -1 }, h("div", { key: '7e261c1e2fc4f37f4ddda861872a470c89181e16', class: Object.assign({ 'digi-form-input': true }, this.cssModifiers) }, h("digi-form-label", { key: '7e8fd283dedf0a851c714331ae640f7c74176bde', class: "digi-form-input__label", afFor: this.afId, afLabel: this.afLabel, afDescription: this.afLabelDescription, afRequired: this.afRequired, afAnnounceIfOptional: this.afAnnounceIfOptional, afRequiredText: this.afRequiredText, afAnnounceIfOptionalText: this.afAnnounceIfOptionalText }), h("div", { key: '68d715181c180ebaf957dfb46afb63b19b8a8188', class: "digi-form-input__input-wrapper" }, h("input", Object.assign({ key: 'e25ab871e988f9e8bd0837f75403e85f7423805f', class: "digi-form-input__input", ref: (el) => (this._input = el), onBlur: (e) => this.blurHandler(e), onChange: (e) => this.changeHandler(e), onFocus: (e) => this.focusHandler(e), onFocusout: (e) => this.focusoutHandler(e), onKeyUp: (e) => this.keyupHandler(e), onInput: (e) => this.inputHandler(e), "aria-activedescendant": this.afAriaActivedescendant, "aria-describedby": `${this.afAriaDescribedby} ${this.afId}--validation-message`, "aria-labelledby": this.afAriaLabelledby, "aria-autocomplete": this.afAriaAutocomplete, "aria-invalid": this.afValidation === FormInputValidation.ERROR
3593
+ ? 'true'
3594
+ : 'false', "aria-controls": this.afAriaControls, autocomplete: this.afAutocomplete, autofocus: this.afAutofocus ? this.afAutofocus : null, maxLength: this.afMaxlength, minLength: this.afMinlength, max: this.afMax, min: this.afMin, step: this.afStep, list: this.afList, role: this.afRole, dirName: this.afDirname, required: this.afRequired, id: this.afId, name: this.afName, type: this.afType, value: this.afValue }, (this.afInputmode == FormInputMode.DEFAULT
3595
+ ? {}
3596
+ : { inputmode: this.afInputmode }))), h("slot", { key: 'c14ae079a53099fc3928bcf3ac7f5517c20b0f36', name: "button" })), h("div", { key: '75d6afa176cd8620e31c384e169b3c84a3bb584d', class: "digi-form-input__footer" }, h("div", { key: '81029d425aae06e3c72c08afe982f2ff1a7bb81d', class: "digi-form-input__validation", "aria-atomic": "true", role: this.errorMessageIsAlert ? 'alert' : null, id: `${this.afId}--validation-message` }, this.hasActiveValidationMessage &&
3597
+ this.afValidation != FormInputValidation.NEUTRAL && (h("digi-form-validation-message", { key: '9a8fec12db8c78a037a9b70194b32814d7641dad', class: "digi-form-input__validation-message", "af-variation": this.afValidation }, this.afValidationText)))))));
3598
+ }
3599
+ get hostElement() { return getElement(this); }
3600
+ static get watchers() { return {
3601
+ "value": [{
3602
+ "onValueChanged": 0
3603
+ }],
3604
+ "afValue": [{
3605
+ "onAfValueChanged": 0
3606
+ }],
3607
+ "afValidationText": [{
3608
+ "afValidationTextWatch": 0
3609
+ }]
3610
+ }; }
3611
+ };
3612
+ FormInput.style = formInputCss();
3613
+
3614
+ const formLabelCss = () => `.sc-digi-form-label-h .digi-form-label.sc-digi-form-label{font-family:var(--digi--global--typography--font-family--default);font-size:var(--digi--typography--label--font-size--desktop);color:var(--digi--color--text--primary);display:flex;flex-direction:column}.sc-digi-form-label-h .digi-form-label__label--label.sc-digi-form-label{font-weight:var(--digi--typography--label--font-weight--desktop)}.sc-digi-form-label-h .digi-form-label__label--label.sc-digi-form-label,.sc-digi-form-label-h .digi-form-label__label--description.sc-digi-form-label{line-height:var(--digi--typography--label--line-height--desktop);cursor:pointer;display:block}.sc-digi-form-label-h .digi-form-label__label-group.sc-digi-form-label{display:inline-flex;align-items:center;gap:var(--digi--gutter--icon)}.sc-digi-form-label-h .digi-form-label__description.sc-digi-form-label{max-width:var(--digi--paragraph-width--medium);line-height:var(--digi--typography--label-description--line-height--desktop);font-size:var(--digi--typography--label-description--font-size--desktop)}`;
3615
+
3616
+ const FormLabel = class {
3617
+ constructor(hostRef) {
3618
+ registerInstance(this, hostRef);
3619
+ /**
3620
+ * Sätter attributet 'id'. Om inget väljs så skapas ett slumpmässigt id.
3621
+ * @en Set id attribute. Defaults to random string.
3622
+ */
3623
+ this.afId = randomIdGenerator('digi-form-label');
3624
+ /**
3625
+ * Sätt denna till true om formuläret innehåller fler obligatoriska fält än valfria.
3626
+ * @en Set this to true if the form contains more required fields than optional fields.
3627
+ */
3628
+ this.afAnnounceIfOptional = false;
3629
+ /**
3630
+ * Sätter text för afRequired.
3631
+ * @en Set text for afRequired.
3632
+ */
3633
+ this.afRequiredText = _t.required.toLowerCase();
3634
+ /**
3635
+ * Sätter text för afAnnounceIfOptional.
3636
+ * @en Set text for afAnnounceIfOptional.
3637
+ */
3638
+ this.afAnnounceIfOptionalText = _t.optional.toLowerCase();
3639
+ }
3640
+ componentWillLoad() {
3641
+ this.setLabelText();
3642
+ this.validateFor();
3643
+ this.handleSlotVisibility();
3644
+ }
3645
+ validateFor() {
3646
+ if (this.afFor == null) {
3647
+ logger.warn(`digi-form-label must have a for attribute. Please add a for attribute using af-for`, this.hostElement);
3648
+ }
3649
+ }
3650
+ setLabelText() {
3651
+ this.labelText = `${this.afLabel} ${this.requiredText}`;
3652
+ if (!this.afLabel) {
3653
+ logger.warn(`digi-form-label must have a label. Please add a label using af-label`, this.hostElement);
3654
+ }
3655
+ }
3656
+ handleSlotVisibility() {
3657
+ this.hasActionSlot = !!this.hostElement.querySelector('[slot="actions"]');
3658
+ }
3659
+ get requiredText() {
3660
+ if (this.afRequired && !this.afAnnounceIfOptional) {
3661
+ return this.afRequiredText ? ` (${this.afRequiredText})` : '';
3662
+ }
3663
+ else if (!this.afRequired && this.afAnnounceIfOptional) {
3664
+ return this.afAnnounceIfOptionalText
3665
+ ? ` (${this.afAnnounceIfOptionalText})`
3666
+ : '';
3667
+ }
3668
+ else {
3669
+ return '';
3670
+ }
3671
+ }
3672
+ render() {
3673
+ return (h("div", { key: 'ac9aec4d1d20cc37694af578a97a16a17291c9f3', class: "digi-form-label" }, h("div", { key: 'bf27c3012d1973798095e6b832572fc20863c5f1', class: "digi-form-label__label-group" }, this.afFor && this.afLabel && (h("label", { key: '75435e49548e4fa27330a35b033689a0ed9e99a7', class: "digi-form-label__label", htmlFor: this.afFor, id: this.afId }, h("span", { key: '0527ddcebbd2a1b215f42eaed06ba7fc28633d43', class: "digi-form-label__label--label" }, this.labelText), this.afDescription && (h("span", { key: '8a3b3e6a0ec0a97adb0760b390f0ddb34b3e0b87', class: "digi-form-label__label--description" }, this.afDescription)))), this.hasActionSlot && (h("div", { key: 'f2e6ad691a5cbc57b990416097454a393da35c01', class: "digi-form-label__actions" }, h("slot", { key: '1fab5cca94da7ad0f2b617db7f713d3b4d17c52d', name: "actions" }))))));
3674
+ }
3675
+ get hostElement() { return getElement(this); }
3676
+ static get watchers() { return {
3677
+ "afFor": [{
3678
+ "validateFor": 0
3679
+ }],
3680
+ "afLabel": [{
3681
+ "setLabelText": 0
3682
+ }],
3683
+ "afRequired": [{
3684
+ "setLabelText": 0
3685
+ }],
3686
+ "afAnnounceIfOptional": [{
3687
+ "setLabelText": 0
3688
+ }]
3689
+ }; }
3690
+ };
3691
+ FormLabel.style = formLabelCss();
3692
+
3693
+ const formSelectCss = () => `.sc-digi-form-select-h{--digi--form-select--background--empty:var(--digi--color--background--interactive--default--secondary);--digi--form-select--background--neutral:var(--digi--color--background--interactive--default--secondary);--digi--form-select--background--success:var(--digi--color--background--interactive--validation--success);--digi--form-select--background--warning:var(--digi--color--background--interactive--validation--warning);--digi--form-select--background--error:var(--digi--color--background--interactive--validation--error);--digi--form-select--border-color--neutral:var(--digi--color--border--interactive--default--on-input);--digi--form-select--border-color--success:var(--digi--color--border--interactive--validation--success);--digi--form-select--border-color--warning:var(--digi--color--border--interactive--validation--warning);--digi--form-select--border-color--error:var(--digi--color--border--interactive--validation--error);--digi--form-select--select-wrapper--position:relative;--digi--form-select--select--height--small:var(--digi--input-height--small);--digi--form-select--select--height--medium:var(--digi--input-height--medium);--digi--form-select--select--height--large:var(--digi--input-height--large);--digi--form-select--select--border-radius:var(--digi--border-radius--input);--digi--form-select--select--padding:0 var(--digi--gutter--medium);--digi--form-select--select--padding--inline-end:var(--digi--padding--large);--digi--form-select--select--border-width--neutral:var(--digi--border-width--input-regular);--digi--form-select--select--border-width--success:var(--digi--border-width--input-validation);--digi--form-select--select--border-width--error:var(--digi--border-width--input-validation);--digi--form-select--select--border-width--warning:var(--digi--border-width--input-validation);--digi--form-select--select--width:100%;--digi--form-select--select--font-size:var(--digi--typography--body--font-size--desktop);--digi--form-select--select-option--font-size:var(--digi--typography--body--font-size--desktop);--digi--form-select--label--margin-bottom:var(--digi--gutter--medium);--digi--form-select--icon--inline-end:0.75rem;--digi--form-select--icon--top:50%;--digi--form-select--icon--transform:translateY(-50%);--digi--form-select--icon--color:var(--digi--color--icon--primary);--digi--form-select--footer--margin-top:var(--digi--gutter--medium)}.sc-digi-form-select-h .digi-form-select.sc-digi-form-select{display:flex;flex-direction:column;gap:0.4em}.sc-digi-form-select-h .digi-form-select--neutral.sc-digi-form-select{--BORDER-WIDTH:var(--digi--form-select--select--border-width--neutral);--BORDER-COLOR:var(--digi--form-select--border-color--neutral);--BACKGROUND:var(--digi--form-select--background--neutral)}.sc-digi-form-select-h .digi-form-select--success.sc-digi-form-select{--BORDER-WIDTH:var(--digi--form-select--select--border-width--success);--BORDER-COLOR:var(--digi--form-select--border-color--success);--BACKGROUND:var(--digi--form-select--background--success)}.sc-digi-form-select-h .digi-form-select--warning.sc-digi-form-select{--BORDER-WIDTH:var(--digi--form-select--select--border-width--warning);--BORDER-COLOR:var(--digi--form-select--border-color--warning);--BACKGROUND:var(--digi--form-select--background--warning)}.sc-digi-form-select-h .digi-form-select--error.sc-digi-form-select{--BORDER-WIDTH:var(--digi--form-select--select--border-width--error);--BORDER-COLOR:var(--digi--form-select--border-color--error);--BACKGROUND:var(--digi--form-select--background--error)}.sc-digi-form-select-h .digi-form-select--small.sc-digi-form-select{--HEIGHT:var(--digi--form-select--select--height--small)}.sc-digi-form-select-h .digi-form-select--medium.sc-digi-form-select{--HEIGHT:var(--digi--form-select--select--height--medium)}.sc-digi-form-select-h .digi-form-select--large.sc-digi-form-select{--HEIGHT:var(--digi--form-select--select--height--large)}.sc-digi-form-select-h .digi-form-select--empty.sc-digi-form-select:not(:focus-within){--BACKGROUND:var(--digi--form-select--background--empty)}.sc-digi-form-select-h .digi-form-select__select.sc-digi-form-select{appearance:none;width:var(--digi--form-select--select--width);padding:var(--digi--form-select--select--padding);padding-inline-end:var(--digi--form-select--select--padding--inline-end);height:var(--HEIGHT);border:var(--BORDER-WIDTH) solid;border-radius:var(--digi--form-select--select--border-radius);border-color:var(--BORDER-COLOR);cursor:pointer;font-size:var(--digi--form-select--select--font-size);color:var(--digi--color--text--primary);background:var(--BACKGROUND);font-family:var(--digi--global--typography--font-family--default)}.sc-digi-form-select-h .digi-form-select__select-wrapper.sc-digi-form-select{position:var(--digi--form-select--select-wrapper--position)}.sc-digi-form-select-h .digi-form-select__select-option.sc-digi-form-select{font-size:var(--digi--form-select--select-option--font-size)}@media (min-width: 48rem){.sc-digi-form-select-h .digi-form-select__select-option.sc-digi-form-select{--digi--form-select--select-option--font-size:var(--digi--typography--font-size--l)}}.sc-digi-form-select-h .digi-form-select__select.sc-digi-form-select::-ms-expand{display:none}.sc-digi-form-select-h .digi-form-select__select.sc-digi-form-select:focus-visible{outline:2px solid black;outline-offset:2px;box-shadow:0px 0px 0px 5px white}.sc-digi-form-select-h .digi-form-select__icon.sc-digi-form-select{position:absolute;inset-inline-end:var(--digi--form-select--icon--inline-end);inset-block-start:var(--digi--form-select--icon--top);transform:var(--digi--form-select--icon--transform);pointer-events:none;color:var(--digi--form-select--icon--color)}.digi-form-select--neutral.sc-digi-form-select .digi-form-select__footer.sc-digi-form-select{position:absolute}`;
3694
+
3695
+ const FormSelect = class {
3696
+ constructor(hostRef) {
3697
+ registerInstance(this, hostRef);
3698
+ this.afOnChange = createEvent(this, "afOnChange", 7);
3699
+ this.afOnSelect = createEvent(this, "afOnSelect", 7);
3700
+ this.afOnFocus = createEvent(this, "afOnFocus", 7);
3701
+ this.afOnFocusout = createEvent(this, "afOnFocusout", 7);
3702
+ this.afOnBlur = createEvent(this, "afOnBlur", 7);
3703
+ this.afOnDirty = createEvent(this, "afOnDirty", 7);
3704
+ this.afOnReady = createEvent(this, "afOnReady", 3);
3705
+ this.optionItems = [];
3706
+ this.dirty = false;
3707
+ this.touched = false;
3708
+ this.hasPlaceholder = false;
3709
+ /**
3710
+ * Normalt betonas ett obligatoriskt fält visuellt och semantiskt.
3711
+ * Detta vänder på det och betonar fältet om det inte krävs.
3712
+ * Ställ in detta till sant om ditt formulär innehåller fler obligatoriska fält än inte.
3713
+ * @en Normally a required field is visually and semantically emphasized.
3714
+ * This flips that and emphasizes the field if it is not required.
3715
+ * Set this to true if your form contains more required fields than not.
3716
+ */
3717
+ this.afAnnounceIfOptional = false;
3718
+ /**
3719
+ * Sätter ett id attribut.
3720
+ * @en Sets an id attribute. Standard är slumpmässig sträng.
3721
+ */
3722
+ this.afId = randomIdGenerator('digi-form-select');
3723
+ /**
3724
+ * Sätter väljarens storlek.
3725
+ * @en Set select input size.
3726
+ */
3727
+ this.afVariation = FormSelectVariation.MEDIUM;
3728
+ /**
3729
+ * Sätter väljarens validering
3730
+ * @en Set select validation
3731
+ */
3732
+ this.afValidation = FormSelectValidation.NEUTRAL;
3733
+ /**
3734
+ * Om värdet är true får felmeddelandet attributet role="alert".
3735
+ * Om felet visas tillsammans med flera andra fel (till exempel efter servervalidering) ska värdet sättas till false.
3736
+ * @en If the value is true, the error message gets the attribute role="alert".
3737
+ * If the error is shown together with multiple errors (for example after server-side validation), the value should be set to false.
3738
+ */
3739
+ this.afErrorMessageIsAlert = true;
3740
+ }
3741
+ onValueChanged(value) {
3742
+ this.afValue = value;
3743
+ }
3744
+ onAfValueChanged(value) {
3745
+ this.value = value;
3746
+ }
3747
+ get errorMessageIsAlert() {
3748
+ return (this.afErrorMessageIsAlert !== false &&
3749
+ this.afErrorMessageIsAlert !== 'false');
3750
+ }
3751
+ getOptions() {
3752
+ this.checkIfPlaceholder();
3753
+ const options = Array.from(this.hostElement.querySelectorAll('option')).filter((el) => { var _a; return !((_a = this._select) === null || _a === void 0 ? void 0 : _a.contains(el)); });
3754
+ const updatedOptionItems = options.map((el) => ({
3755
+ value: el.value,
3756
+ text: el.text
3757
+ }));
3758
+ if (JSON.stringify(updatedOptionItems) === JSON.stringify(this.optionItems)) {
3759
+ return;
3760
+ }
3761
+ this.optionItems = updatedOptionItems;
3762
+ }
3763
+ checkIfPlaceholder() {
3764
+ this.hasPlaceholder = !!this.afPlaceholder;
3765
+ }
3766
+ componentWillLoad() {
3767
+ this.afValue ? (this.value = this.afValue) : (this.afValue = this.value);
3768
+ }
3769
+ componentDidLoad() {
3770
+ this.optionsObserver = new MutationObserver(() => this.getOptions());
3771
+ this.optionsObserver.observe(this.hostElement, {
3772
+ childList: true,
3773
+ subtree: true
3774
+ });
3775
+ this.getOptions();
3776
+ this.afOnReady.emit();
3777
+ }
3778
+ disconnectedCallback() {
3779
+ var _a;
3780
+ (_a = this.optionsObserver) === null || _a === void 0 ? void 0 : _a.disconnect();
3781
+ }
3782
+ /**
3783
+ * Returnerar en referens till formulärkontrollelementet.
3784
+ * @en Returns a reference to the form control element.
3785
+ */
3786
+ async afMGetFormControlElement() {
3787
+ return this._select;
3788
+ }
3789
+ /**
3790
+ * Lyssnar på om fokus sätts på custom-elementet och propagerar ner det till själva select-elementet.
3791
+ * @en Listens for when focus is set on the custom element and propagates it down to the actual select element.
3792
+ */
3793
+ focusOnInput() {
3794
+ var _a;
3795
+ (_a = this._select) === null || _a === void 0 ? void 0 : _a.focus();
3796
+ }
3797
+ get cssModifiers() {
3798
+ return {
3799
+ 'digi-form-select--small': this.afVariation === FormSelectVariation.SMALL,
3800
+ 'digi-form-select--medium': this.afVariation === FormSelectVariation.MEDIUM,
3801
+ 'digi-form-select--large': this.afVariation === FormSelectVariation.LARGE,
3802
+ 'digi-form-select--neutral': this.afValidation === FormSelectValidation.NEUTRAL,
3803
+ 'digi-form-select--success': this.afValidation === FormSelectValidation.SUCCESS,
3804
+ 'digi-form-select--warning': this.afValidation === FormSelectValidation.WARNING,
3805
+ 'digi-form-select--error': this.afValidation === FormSelectValidation.ERROR,
3806
+ 'digi-form-select--empty': !this.afValue &&
3807
+ (!this.afValidation ||
3808
+ this.afValidation === FormSelectValidation.NEUTRAL)
3809
+ };
3810
+ }
3811
+ changeHandler(e) {
3812
+ if (!this.dirty) {
3813
+ this.afOnDirty.emit(e);
3814
+ this.dirty = true;
3815
+ }
3816
+ this.value = this.afValue = e.target.value;
3817
+ this.afOnChange.emit(e);
3818
+ }
3819
+ selectHandler(e) {
3820
+ this.value = this.afValue = e.target.value;
3821
+ this.afOnSelect.emit(e);
3822
+ }
3823
+ focusHandler(e) {
3824
+ this.afOnFocus.emit(e);
3825
+ }
3826
+ focusoutHandler(e) {
3827
+ this.afOnFocusout.emit(e);
3828
+ }
3829
+ blurHandler(e) {
3830
+ this.afOnBlur.emit(e);
3831
+ }
3832
+ getSelectedItem(option) {
3833
+ return this.afValue == option.value;
3834
+ }
3835
+ showValidation() {
3836
+ return !this.afDisableValidation &&
3837
+ this.afValidation !== FormSelectValidation.NEUTRAL &&
3838
+ this.afValidationText
3839
+ ? true
3840
+ : false;
3841
+ }
3842
+ render() {
3843
+ return (h(Host, { key: 'b40fb54f41ae0b739a943d600624889b604865b2', tabindex: -1 }, h("div", { key: 'e753b10a46503f6711b35dd1d30b8be59296cc0b', class: Object.assign({ 'digi-form-select': true }, this.cssModifiers) }, h("div", { key: 'a820eb5ffec3ac101febd080add2ddf9aa537c21', class: "digi-form-select__label-group" }, h("digi-form-label", { key: 'ad8616ae6b48a6e10c2827a7d00d51daa44129ec', afFor: this.afId, afLabel: this.afLabel, afId: `${this.afId}-label`, afDescription: this.afDescription, afRequired: this.afRequired, afAnnounceIfOptional: this.afAnnounceIfOptional, afRequiredText: this.afRequiredText, afAnnounceIfOptionalText: this.afAnnounceIfOptionalText })), h("div", { key: 'ffe072a753cfe6a7f6afd300e34f8aff9ec4fc2a', class: "digi-form-select__select-wrapper" }, h("select", { key: '204dbc6361c6fb0a0ae0265cdd05db1888380c6d', class: "digi-form-select__select", name: this.afName, id: this.afId, "aria-label": this.afAriaLabel, "aria-invalid": this.afValidation === FormSelectValidation.ERROR
3844
+ ? 'true'
3845
+ : 'false', "aria-describedby": `${this.afId}--validation-message`, ref: (el) => (this._select = el), required: this.afRequired ? this.afRequired : null, onFocus: (e) => this.focusHandler(e), onFocusout: (e) => this.focusoutHandler(e), onBlur: (e) => this.blurHandler(e), onChange: (e) => this.changeHandler(e), onInput: (e) => this.selectHandler(e), autoFocus: this.afAutofocus ? this.afAutofocus : null }, this.hasPlaceholder && (h("option", { key: '0f4675533c05c4e6a2f3dd7b502676aa6354c001', class: {
3846
+ 'digi-form-select__select-option': true,
3847
+ 'digi-form-select__select-option--initial-value': true
3848
+ }, disabled: true, selected: !this.afValue, value: "" }, this.afPlaceholder)), this.optionItems.map((option, index) => {
3849
+ return (h("option", { key: index, class: "digi-form-select__select-option", value: option.value, selected: this.getSelectedItem(option) }, option.text));
3850
+ })), h("digi-icon-input-select-marker", { key: '13c14346d06dbf9d67bedfcb45300ee0cd7921e4', class: "digi-form-select__icon", slot: "icon" })), h("div", { key: '9a88dda5d1d981016bb17a053d913eadd89e5e07', hidden: true }, h("slot", { key: '9b6cc012b2c0fead2a1e70441abebbb28364b450' })), h("div", { key: '1f13d6ddaf2a9d78a7c66c242bfe5ac35cf2c961', class: "digi-form-select__footer" }, h("div", { key: '6ba7c2aea4196e0e1b646e22ca9d14be65540ccb', "aria-atomic": "true", role: this.errorMessageIsAlert ? 'alert' : null, id: `${this.afId}--validation-message` }, this.showValidation() && (h("digi-form-validation-message", { key: 'eee53a1c30af8d43e8f60d3c85764f65d335e9ec', "af-variation": this.afValidation }, this.afValidationText)))))));
3851
+ }
3852
+ get hostElement() { return getElement(this); }
3853
+ static get watchers() { return {
3854
+ "value": [{
3855
+ "onValueChanged": 0
3856
+ }],
3857
+ "afValue": [{
3858
+ "onAfValueChanged": 0
3859
+ }]
3860
+ }; }
3861
+ };
3862
+ FormSelect.style = formSelectCss();
3863
+
3864
+ const formValidationMessageCss = () => `.sc-digi-form-validation-message-h{--digi--form-validation-message--icon-color--success:var(--digi--color--icon--validation--success);--digi--form-validation-message--icon-color--warning:var(--digi--color--icon--validation--warning);--digi--form-validation-message--icon-color--error:var(--digi--color--icon--validation--error)}.sc-digi-form-validation-message-h .digi-form-validation-message.sc-digi-form-validation-message{display:flex;flex-wrap:wrap;align-items:center}.sc-digi-form-validation-message-h .digi-form-validation-message--success.sc-digi-form-validation-message{--ICON-COLOR:var(--digi--form-validation-message--icon-color--success)}.sc-digi-form-validation-message-h .digi-form-validation-message--warning.sc-digi-form-validation-message{--ICON-COLOR:var(--digi--form-validation-message--icon-color--warning)}.sc-digi-form-validation-message-h .digi-form-validation-message--error.sc-digi-form-validation-message{--ICON-COLOR:var(--digi--form-validation-message--icon-color--error)}.sc-digi-form-validation-message-h .digi-form-validation-message__icon.sc-digi-form-validation-message{color:var(--ICON-COLOR);margin-inline-end:var(--digi--gutter--icon)}.sc-digi-form-validation-message-h .digi-form-validation-message__icon.sc-digi-form-validation-message>*.sc-digi-form-validation-message{--digi--icon--width:1.25em;--digi--icon--height:1.25em;--digi--icon--color:var(--ICON-COLOR);display:flex}.sc-digi-form-validation-message-h .digi-form-validation-message__icon.sc-digi-form-validation-message .warning.sc-digi-form-validation-message{top:3px;position:relative}.sc-digi-form-validation-message-h .digi-form-validation-message__text.sc-digi-form-validation-message{flex:1;font-family:var(--digi--global--typography--font-family--default);font-size:var(--digi--typography--tag--font-size--desktop);color:var(--digi--color--text--primary)}`;
3865
+
3866
+ const FormValidationMessage = class {
3867
+ constructor(hostRef) {
3868
+ registerInstance(this, hostRef);
3869
+ /**
3870
+ * Sätter valideringsstatus. Kan vara 'success', 'error' eller 'warning'.
3871
+ * @en Set validation status
3872
+ */
3873
+ this.afVariation = FormValidationMessageVariation.SUCCESS;
3874
+ }
3875
+ get cssModifiers() {
3876
+ return {
3877
+ 'digi-form-validation-message--success': this.afVariation === FormValidationMessageVariation.SUCCESS,
3878
+ 'digi-form-validation-message--error': this.afVariation === FormValidationMessageVariation.ERROR,
3879
+ 'digi-form-validation-message--warning': this.afVariation === FormValidationMessageVariation.WARNING
3880
+ };
3881
+ }
3882
+ get icon() {
3883
+ switch (this.afVariation) {
3884
+ case FormValidationMessageVariation.SUCCESS:
3885
+ return h("digi-icon-validation-success", null);
3886
+ case FormValidationMessageVariation.ERROR:
3887
+ return h("digi-icon-validation-error", null);
3888
+ case FormValidationMessageVariation.WARNING:
3889
+ return h("digi-icon-validation-warning", { class: "warning" });
3890
+ }
3891
+ }
3892
+ render() {
3893
+ return (h("div", { key: '5c89cb2cfe7085ec0203814f2c7a43c9fe518db4', class: Object.assign({ 'digi-form-validation-message': true }, this.cssModifiers) }, h("div", { key: 'cb85b6a6e02b081710f80ad7bbbe96e182d8c353', class: "digi-form-validation-message__icon", "aria-hidden": "true" }, this.icon), h("span", { key: '9b1689dcad19fd3f033c679f496a1c94348f393b', class: "digi-form-validation-message__text" }, h("slot", { key: '794c1b1c0771cae8c0b19bd7123f7f5bc28e99b7' }))));
3894
+ }
3895
+ get hostElement() { return getElement(this); }
3896
+ };
3897
+ FormValidationMessage.style = formValidationMessageCss();
3898
+
3899
+ const iconCalendarAltCss = () => `.sc-digi-icon-calendar-alt-h{--digi--icon--color:var(--digi--color--icon--primary);--digi--icon--width:initial;--digi--icon--height:auto;display:flex;min-height:1.4em;align-items:center}.sc-digi-icon-calendar-alt-h svg.sc-digi-icon-calendar-alt{color:var(--digi--icon--color);max-width:var(--digi--icon--width);max-height:var(--digi--icon--height);width:var(--digi--icon--width, auto);height:var(--digi--icon--height, auto)}`;
3900
+
3901
+ const IconCalendarAlt = class {
3902
+ constructor(hostRef) {
3903
+ registerInstance(this, hostRef);
3904
+ /**
3905
+ * För att dölja ikonen för skärmläsare. Default är satt till true.
3906
+ * @en Hides the icon for screen readers. Default is set to true.
3907
+ */
3908
+ this.afSvgAriaHidden = true;
3909
+ this.titleId = randomIdGenerator('icontitle');
3910
+ }
3911
+ render() {
3912
+ return (h("svg", { key: '51b9d922462d3ad108545dbe7df4bf805334b0ef', class: "digi-icon-calendar-alt", width: "22", height: "26", viewBox: "0 0 22 26", "aria-hidden": this.afSvgAriaHidden ? 'true' : 'false', "aria-labelledby": this.afSvgAriaLabelledby
3913
+ ? this.afSvgAriaLabelledby
3914
+ : this.afTitle
3915
+ ? this.titleId
3916
+ : undefined, xmlns: "http://www.w3.org/2000/svg" }, this.afTitle && h("title", { key: '0cf10651a3b238c59bc9f342cec98ff7c2a967e7', id: this.titleId }, this.afTitle), this.afDesc && h("desc", { key: 'a7826ce588a9bd9580c3f45a20834ff4e66a3620' }, this.afDesc), h("path", { key: '0854e6fc47b9a773f3d902e557535765d973252a', class: "digi-icon-calendar-alt__shape", d: "M21.41 8.125H.59a.601.601 0 01-.59-.61V5.689C0 4.341 1.056 3.25 2.357 3.25h2.357V.61c0-.336.265-.61.59-.61h1.964c.324 0 .59.274.59.61v2.64h6.285V.61c0-.336.265-.61.59-.61h1.963c.325 0 .59.274.59.61v2.64h2.357C20.944 3.25 22 4.342 22 5.688v1.828c0 .335-.265.609-.59.609zM.59 9.75h20.82c.325 0 .59.274.59.61v13.203C22 24.907 20.944 26 19.643 26H2.357C1.056 26 0 24.908 0 23.562V10.36c0-.335.265-.609.59-.609zm5.696 10.36a.601.601 0 00-.59-.61H3.732a.601.601 0 00-.59.61v2.03c0 .336.266.61.59.61h1.964c.325 0 .59-.274.59-.61v-2.03zm0-6.5a.601.601 0 00-.59-.61H3.732a.601.601 0 00-.59.61v2.03c0 .336.266.61.59.61h1.964c.325 0 .59-.274.59-.61v-2.03zm6.285 6.5a.601.601 0 00-.589-.61h-1.964a.601.601 0 00-.59.61v2.03c0 .336.266.61.59.61h1.964c.324 0 .59-.274.59-.61v-2.03zm0-6.5a.601.601 0 00-.589-.61h-1.964a.601.601 0 00-.59.61v2.03c0 .336.266.61.59.61h1.964c.324 0 .59-.274.59-.61v-2.03zm6.286 6.5a.601.601 0 00-.59-.61h-1.963a.601.601 0 00-.59.61v2.03c0 .336.265.61.59.61h1.964c.324 0 .59-.274.59-.61v-2.03zm0-6.5a.601.601 0 00-.59-.61h-1.963a.601.601 0 00-.59.61v2.03c0 .336.265.61.59.61h1.964c.324 0 .59-.274.59-.61v-2.03z", fill: "currentColor", "fill-rule": "nonzero" })));
3917
+ }
3918
+ };
3919
+ IconCalendarAlt.style = iconCalendarAltCss();
3920
+
3921
+ const iconChevronDownCss = () => `.sc-digi-icon-chevron-down-h{--digi--icon--color:var(--digi--color--icon--primary);--digi--icon--width:initial;--digi--icon--height:auto;display:flex;min-height:1.4em;align-items:center}.sc-digi-icon-chevron-down-h svg.sc-digi-icon-chevron-down{color:var(--digi--icon--color);max-width:var(--digi--icon--width);max-height:var(--digi--icon--height);width:var(--digi--icon--width, auto);height:var(--digi--icon--height, auto)}`;
3922
+
3923
+ const IconChevronDown = class {
3924
+ constructor(hostRef) {
3925
+ registerInstance(this, hostRef);
3926
+ /**
3927
+ * För att dölja ikonen för skärmläsare. Default är satt till true.
3928
+ * @en Hides the icon for screen readers. Default is set to true.
3929
+ */
3930
+ this.afSvgAriaHidden = true;
3931
+ this.titleId = randomIdGenerator('icontitle');
3932
+ }
3933
+ render() {
3934
+ return (h("svg", { key: '14c50bb9ce94f2ae7e6b89e99417668515a0e1fa', class: "digi-icon-chevron-down", width: "14", height: "8", viewBox: "0 0 14 8", xmlns: "http://www.w3.org/2000/svg", "aria-hidden": this.afSvgAriaHidden ? 'true' : 'false', "aria-labelledby": this.afSvgAriaLabelledby
3935
+ ? this.afSvgAriaLabelledby
3936
+ : this.afTitle
3937
+ ? this.titleId
3938
+ : undefined }, this.afTitle && h("title", { key: '4692fea634337c2e89e5eeac67c707c84f919563', id: this.titleId }, this.afTitle), this.afDesc && h("desc", { key: '3948943affb34ebc1967aeb54389b0c3230e6daf' }, this.afDesc), h("path", { key: '252f72d574b43e0d794341fa05f5a2cf39cedb4d', class: "digi-icon-chevron-down__shape", d: "M1 1l6.074 6L13 1.147", stroke: "currentColor", "stroke-width": "2", fill: "none", "fill-rule": "evenodd" })));
3939
+ }
3940
+ };
3941
+ IconChevronDown.style = iconChevronDownCss();
3942
+
3943
+ const iconChevronLeftCss = () => `.sc-digi-icon-chevron-left-h{--digi--icon--color:var(--digi--color--icon--primary);--digi--icon--width:initial;--digi--icon--height:auto;display:flex;min-height:1.4em;align-items:center}.sc-digi-icon-chevron-left-h svg.sc-digi-icon-chevron-left{color:var(--digi--icon--color);max-width:var(--digi--icon--width);max-height:var(--digi--icon--height);width:var(--digi--icon--width, auto);height:var(--digi--icon--height, auto)}`;
3944
+
3945
+ const IconChevronLeft = class {
3946
+ constructor(hostRef) {
3947
+ registerInstance(this, hostRef);
3948
+ /**
3949
+ * För att dölja ikonen för skärmläsare. Default är satt till true.
3950
+ * @en Hides the icon for screen readers. Default is set to true.
3951
+ */
3952
+ this.afSvgAriaHidden = true;
3953
+ this.titleId = randomIdGenerator('icontitle');
3954
+ }
3955
+ render() {
3956
+ return (h("svg", { key: 'def846a254699c1487c6650595a307d69570b03b', class: "digi-icon-chevron-left", width: "9", height: "14", viewBox: "0 0 9 14", xmlns: "http://www.w3.org/2000/svg", "aria-hidden": this.afSvgAriaHidden ? 'true' : 'false', "aria-labelledby": this.afSvgAriaLabelledby
3957
+ ? this.afSvgAriaLabelledby
3958
+ : this.afTitle
3959
+ ? this.titleId
3960
+ : undefined }, this.afTitle && h("title", { key: '07e54926302b1524b1040b2a807060670448c0f8', id: this.titleId }, this.afTitle), this.afDesc && h("desc", { key: 'af3cae8cfe1b8451e4698e1ec43aeb52122d0f81' }, this.afDesc), h("path", { key: 'd98281b3481fbbc3853c5a34d1fdd35f58b0056c', class: "digi-icon-chevron-left__shape", d: "M8 13L2 6.926 7.853 1", stroke: "currentColor", "stroke-width": "2", fill: "none", "fill-rule": "evenodd" })));
3961
+ }
3962
+ };
3963
+ IconChevronLeft.style = iconChevronLeftCss();
3964
+
3965
+ const iconChevronRightCss = () => `.sc-digi-icon-chevron-right-h{--digi--icon--color:var(--digi--color--icon--primary);--digi--icon--width:initial;--digi--icon--height:auto;display:flex;min-height:1.4em;align-items:center}.sc-digi-icon-chevron-right-h svg.sc-digi-icon-chevron-right{color:var(--digi--icon--color);max-width:var(--digi--icon--width);max-height:var(--digi--icon--height);width:var(--digi--icon--width, auto);height:var(--digi--icon--height, auto)}`;
3966
+
3967
+ const IconChevronRight = class {
3968
+ constructor(hostRef) {
3969
+ registerInstance(this, hostRef);
3970
+ /**
3971
+ * För att dölja ikonen för skärmläsare. Default är satt till true.
3972
+ * @en Hides the icon for screen readers. Default is set to true.
3973
+ */
3974
+ this.afSvgAriaHidden = true;
3975
+ this.titleId = randomIdGenerator('icontitle');
3976
+ }
3977
+ render() {
3978
+ return (h("svg", { key: '8a7349c8865c737830b6af0e3ea9aa7c6bd50f6f', class: "digi-icon-chevron-right", width: "9", height: "14", viewBox: "0 0 9 14", xmlns: "http://www.w3.org/2000/svg", "aria-hidden": this.afSvgAriaHidden ? 'true' : 'false', "aria-labelledby": this.afSvgAriaLabelledby
3979
+ ? this.afSvgAriaLabelledby
3980
+ : this.afTitle
3981
+ ? this.titleId
3982
+ : undefined }, this.afTitle && h("title", { key: '83176271f8248b1ad42e1e5baf2f31ddc244cb0a', id: this.titleId }, this.afTitle), this.afDesc && h("desc", { key: 'c22c051704141e87412e98ab3733afab36bf0bf3' }, this.afDesc), h("path", { key: '5f3f04a5512ca21c49e25797401bf68ac726c9d7', class: "digi-icon-chevron-right__shape", d: "M1 13l6-6.074L1.147 1", stroke: "currentColor", "stroke-width": "2", fill: "none", "fill-rule": "evenodd" })));
3983
+ }
3984
+ };
3985
+ IconChevronRight.style = iconChevronRightCss();
3986
+
3987
+ const iconInputSelectMarkerCss = () => `.sc-digi-icon-input-select-marker-h{--digi--icon--color:var(--digi--color--icon--primary);--digi--icon--width:initial;--digi--icon--height:auto;display:flex;min-height:1.4em;align-items:center}.sc-digi-icon-input-select-marker-h svg.sc-digi-icon-input-select-marker{color:var(--digi--icon--color);max-width:var(--digi--icon--width);max-height:var(--digi--icon--height);width:var(--digi--icon--width, auto);height:var(--digi--icon--height, auto)}`;
3988
+
3989
+ const IconInputSelectMarker = class {
3990
+ constructor(hostRef) {
3991
+ registerInstance(this, hostRef);
3992
+ /**
3993
+ * För att dölja ikonen för skärmläsare. Default är satt till true.
3994
+ * @en Hides the icon for screen readers. Default is set to true.
3995
+ */
3996
+ this.afSvgAriaHidden = true;
3997
+ this.titleId = randomIdGenerator('icon-input-select-marker');
3998
+ }
3999
+ render() {
4000
+ return (h("svg", { key: '3a27d862f015acdf222435b2abcf67f1a6c312f7', class: "digi-icon-input-select-marker", width: "14", height: "8", viewBox: "0 0 14 8", xmlns: "http://www.w3.org/2000/svg", "aria-hidden": this.afSvgAriaHidden ? 'true' : 'false', "aria-labelledby": this.afSvgAriaLabelledby
4001
+ ? this.afSvgAriaLabelledby
4002
+ : this.afTitle
4003
+ ? this.titleId
4004
+ : undefined }, this.afTitle && h("title", { key: '88b3c6625077baef962e3851804f50700191b43a', id: this.titleId }, this.afTitle), this.afDesc && h("desc", { key: 'fd1b1225f6bfbc57e34126608b3fd91143253758' }, this.afDesc), h("path", { key: 'e83bfd8eef85f4e2f5c5171dd1d08a44d611fdea', d: "M1 1l6.074 6L13 1.147", stroke: "currentColor", "stroke-width": "2", fill: "none", "fill-rule": "evenodd" })));
4005
+ }
4006
+ };
4007
+ IconInputSelectMarker.style = iconInputSelectMarkerCss();
4008
+
4009
+ const iconValidationErrorCss = () => `.sc-digi-icon-validation-error-h{--digi--icon--color:var(--digi--color--icon--primary);--digi--icon--width:initial;--digi--icon--height:auto;display:flex;min-height:1.4em;align-items:center}.sc-digi-icon-validation-error-h svg.sc-digi-icon-validation-error{color:var(--digi--icon--color);max-width:var(--digi--icon--width);max-height:var(--digi--icon--height);width:var(--digi--icon--width, auto);height:var(--digi--icon--height, auto)}`;
4010
+
4011
+ const IconValidationError = class {
4012
+ constructor(hostRef) {
4013
+ registerInstance(this, hostRef);
4014
+ /**
4015
+ * För att dölja ikonen för skärmläsare. Default är satt till true.
4016
+ * @en Hides the icon for screen readers. Default is set to true.
4017
+ */
4018
+ this.afSvgAriaHidden = true;
4019
+ this.titleId = randomIdGenerator('icontitle');
4020
+ }
4021
+ render() {
4022
+ return (h("svg", { key: 'b20fb61395f90adad2b9e5be72d3e2ea3c5a3feb', class: "digi-icon-validation-error", width: "48", height: "48", viewBox: "0 0 48 48", xmlns: "http://www.w3.org/2000/svg", "aria-hidden": this.afSvgAriaHidden ? 'true' : 'false', "aria-labelledby": this.afSvgAriaLabelledby
4023
+ ? this.afSvgAriaLabelledby
4024
+ : this.afTitle
4025
+ ? this.titleId
4026
+ : undefined }, this.afTitle && h("title", { key: '5e08a1b947d534b913fff06e02109b53c607a0be', id: this.titleId }, this.afTitle), this.afDesc && h("desc", { key: 'f016b92eb4957943a5308d12db1ce2f1b73fae3f' }, this.afDesc), h("path", { key: 'f5ba662eeb6689959a6990ae2e880edc42670490', class: "digi-icon-validation-error__shape", d: "M34.4328058,0 C35.5494848,0 36.5900526,0.609146757 37.1483921,1.58958113 L47.5812454,19.9104189 C48.1395849,20.8909496 48.1395849,22.1090504 47.5812454,23.0895811 L37.1483921,41.4104189 C36.5900526,42.3908532 35.5494848,43 34.4328058,43 L13.5671942,43 C12.4505152,43 11.4099474,42.3908532 10.8516079,41.4104189 L0.41875464,23.0895811 C-0.13958488,22.1090504 -0.13958488,20.8909496 0.41875464,19.9104189 L10.8516079,1.58958113 C11.4099474,0.609146757 12.4505152,0 13.5671942,0 Z M18.6736823,12.3728178 C18.2711762,11.964729 17.6203819,11.964729 17.2178757,12.3728178 L15.2825964,14.334939 C14.8800903,14.7430278 14.8800903,15.4028485 15.2825964,15.8109373 L20.6089616,21.2111779 L15.2825964,26.6114185 C14.8800903,27.0195074 14.8800903,27.6793281 15.2825964,28.0874169 L17.2178757,30.049538 C17.6203819,30.4576269 18.2711762,30.4576269 18.6736823,30.049538 L24.0000475,24.6492974 L29.3264127,30.049538 C29.7289188,30.4576269 30.3797132,30.4576269 30.7822193,30.049538 L32.7174986,28.0874169 C33.1200048,27.6793281 33.1200048,27.0195074 32.7174986,26.6114185 L27.3911334,21.2111779 L32.7174986,15.8109373 C33.1200048,15.4028485 33.1200048,14.7430278 32.7174986,14.334939 L30.7822193,12.3728178 C30.3797132,11.964729 29.7289188,11.964729 29.3264127,12.3728178 L24.0000475,17.7730584 Z", fill: "currentColor", "fill-rule": "nonzero" })));
4027
+ }
4028
+ };
4029
+ IconValidationError.style = iconValidationErrorCss();
4030
+
4031
+ const iconValidationSuccessCss = () => `.sc-digi-icon-validation-success-h{--digi--icon--color:var(--digi--color--icon--primary);--digi--icon--width:initial;--digi--icon--height:auto;display:flex;min-height:1.4em;align-items:center}.sc-digi-icon-validation-success-h svg.sc-digi-icon-validation-success{color:var(--digi--icon--color);max-width:var(--digi--icon--width);max-height:var(--digi--icon--height);width:var(--digi--icon--width, auto);height:var(--digi--icon--height, auto)}`;
4032
+
4033
+ const IconCheckCircle = class {
4034
+ constructor(hostRef) {
4035
+ registerInstance(this, hostRef);
4036
+ /**
4037
+ * För att dölja ikonen för skärmläsare. Default är satt till true.
4038
+ * @en Hides the icon for screen readers. Default is set to true.
4039
+ */
4040
+ this.afSvgAriaHidden = true;
4041
+ this.titleId = randomIdGenerator('icontitle');
4042
+ }
4043
+ render() {
4044
+ return (h("svg", { key: '1c9dcaf014e400504cbce24f69c67bdbb1dc0361', class: "digi-icon-validation-success", width: "25", height: "25", viewBox: "0 0 25 25", "aria-hidden": this.afSvgAriaHidden ? 'true' : 'false', "aria-labelledby": this.afSvgAriaLabelledby
4045
+ ? this.afSvgAriaLabelledby
4046
+ : this.afTitle
4047
+ ? this.titleId
4048
+ : undefined, xmlns: "http://www.w3.org/2000/svg" }, this.afTitle && h("title", { key: 'ed5b4d39b987b025d99ef2ce2153a8de749f587e', id: this.titleId }, this.afTitle), this.afDesc && h("desc", { key: '7c5175b745577dd9076170ba83fa00f8cc03c4a2' }, this.afDesc), h("path", { key: 'f9cb601de2dfbf7959b2b43023692e111f1fbf91', class: "digi-icon-validation-success__shape", d: "M25 12.5C25 19.404 19.404 25 12.5 25S0 19.404 0 12.5 5.596 0 12.5 0 25 5.596 25 12.5zm-13.946 6.619l9.274-9.275a.806.806 0 000-1.14l-1.14-1.14a.806.806 0 00-1.14 0l-7.564 7.563-3.531-3.531a.807.807 0 00-1.14 0l-1.141 1.14a.806.806 0 000 1.14l5.242 5.243a.806.806 0 001.14 0z", fill: "currentColor", "fill-rule": "nonzero" })));
4049
+ }
4050
+ };
4051
+ IconCheckCircle.style = iconValidationSuccessCss();
4052
+
4053
+ const iconValidationWarningCss = () => `.sc-digi-icon-validation-warning-h{--digi--icon--color:var(--digi--color--icon--primary);--digi--icon--width:initial;--digi--icon--height:auto;display:flex;min-height:1.4em;align-items:center}.sc-digi-icon-validation-warning-h svg.sc-digi-icon-validation-warning{color:var(--digi--icon--color);max-width:var(--digi--icon--width);max-height:var(--digi--icon--height);width:var(--digi--icon--width, auto);height:var(--digi--icon--height, auto)}`;
4054
+
4055
+ const IconValidationWarning = class {
4056
+ constructor(hostRef) {
4057
+ registerInstance(this, hostRef);
4058
+ /**
4059
+ * För att dölja ikonen för skärmläsare. Default är satt till true.
4060
+ * @en Hides the icon for screen readers. Default is set to true.
4061
+ */
4062
+ this.afSvgAriaHidden = true;
4063
+ this.titleId = randomIdGenerator('icontitle');
4064
+ }
4065
+ render() {
4066
+ return (h("div", { key: '7017a09730cca2dafe42548b11d18e34a693f81b' }, h("svg", { key: 'd56b196f88aaf6dd87bb416e422d399667e80202', class: "digi-icon-validation-warning", width: "18", height: "18", viewBox: "0 0 18 18", xmlns: "http://www.w3.org/2000/svg", "aria-hidden": this.afSvgAriaHidden ? 'true' : 'false', "aria-labelledby": this.afSvgAriaLabelledby
4067
+ ? this.afSvgAriaLabelledby
4068
+ : this.afTitle
4069
+ ? this.titleId
4070
+ : undefined }, this.afTitle && h("title", { key: '25751b0fd552d8dcabc3402345ba8528126dd973', id: this.titleId }, this.afTitle), this.afDesc && h("desc", { key: '41476cbdf1b92dd9b7c44d8791481a5cf00186ca' }, this.afDesc), h("g", { key: '6607df5c4713e5680fcaa2e9ea29b7cab5064e3d', fill: "none", "fill-rule": "evenodd" }, h("circle", { key: 'c87e6472093671bc2f1f6b3d7eb0b34f512468c1', cx: "9", cy: "9", r: "6.75", fill: "#333" }), h("path", { key: '17b79d3e780ecbb2394b38586388ea457c65a2f7', d: "m18 9c0 4.9717-4.0298 9-9 9-4.9702 0-9-4.0283-9-9 0-4.9688 4.0298-9 9-9 4.9702 0 9 4.0312 9 9zm-9 1.8145c-0.92196 0-1.6694 0.7474-1.6694 1.6694 0 0.92196 0.7474 1.6694 1.6694 1.6694s1.6694-0.7474 1.6694-1.6694c0-0.92196-0.7474-1.6694-1.6694-1.6694zm-1.3157-1.065c0.012593 0.23095 0.20355 0.41175 0.43483 0.41175h1.7618c0.23128 0 0.42224-0.1808 0.43483-0.41175l0.2692-4.9355c0.013609-0.24946-0.18501-0.45922-0.43483-0.45922h-2.3002c-0.24982 0-0.4484 0.20976-0.43479 0.45922l0.2692 4.9355z", fill: "#FFE200" })))));
4071
+ }
4072
+ };
4073
+ IconValidationWarning.style = iconValidationWarningCss();
4074
+
4075
+ const typographyCss = () => `digi-typography{--digi--typography--h1--margin--small:var(--digi--margin--h1-small);--digi--typography--h1--margin--medium:var(--digi--margin--h1-medium);--digi--typography--h1--margin--large:var(--digi--margin--h1-large);--digi--typography--h2--margin--small:var(--digi--margin--h2-small);--digi--typography--h2--margin--large:var(--digi--margin--h2-large);--digi--typography--h3--margin--small:var(--digi--margin--h3-small);--digi--typography--h3--margin--large:var(--digi--margin--h3-large);--digi--typography--h4--margin--small:var(--digi--margin--h4-h6-small);--digi--typography--h4--margin--large:var(--digi--margin--h4-h6-large);--digi--typography--h5--margin--small:var(--digi--margin--h4-h6-small);--digi--typography--h6--margin--large:var(--digi--margin--h4-h6-large);--digi--typography--paragraph--margin--small:var(--digi--margin--text-small);--digi--typography--paragraph--margin--large:var(--digi--margin--text-large);--digi--typography--paragraph--margin-top:initial;--digi--typography--color--text:var(--digi--color--text--primary);--digi--typography--text-decoration-thickness--hover:0.156em;--digi--typography--text-decoration-thickness--default:0.05em;--digi--typography--text-underline-offset:3px;font-family:var(--digi--global--typography--font-family--default);color:var(--digi--typography--color--text);font-size:var(--FONT-SIZE--BODY);line-height:var(--LINE-HEIGHT--BODY);font-weight:var(--FONT-WEIGHT--BODY);text-decoration:var(--TEXT-DECORATION--BODY);--FONT-SIZE--BODY:var(--digi--typography--body--font-size--mobile);--LINE-HEIGHT--BODY:var(--digi--typography--body--line-height--mobile);--FONT-WEIGHT--BODY:var(--digi--typography--body--font-weight--mobile);--TEXT-DECORATION--BODY:var( --digi--typography--body--text-decoration--mobile );--MARGIN--BODY:var(--digi--typography--paragraph--margin--small);--FONT-SIZE--LINK:var(--digi--typography--link--font-size--mobile);--LINE-HEIGHT--LINK:var(--digi--typography--link--line-height--mobile);--FONT-WEIGHT--LINK:var(--digi--typography--link--font-weight--mobile);--TEXT-DECORATION--LINK:var( --digi--typography--link--text-decoration--mobile );--FONT-SIZE--HEADING-1:var(--digi--typography--heading-1--font-size--mobile);--LINE-HEIGHT--HEADING-1:var( --digi--typography--heading-1--line-height--mobile );--FONT-WEIGHT--HEADING-1:var( --digi--typography--heading-1--font-weight--mobile );--TEXT-DECORATION--HEADING-1:var( --digi--typography--heading-1--text-decoration--mobile );--MARGIN--HEADING-1:var(--digi--typography--h1--margin--small);--FONT-SIZE--HEADING-2:var(--digi--typography--heading-2--font-size--mobile);--LINE-HEIGHT--HEADING-2:var( --digi--typography--heading-2--line-height--mobile );--FONT-WEIGHT--HEADING-2:var( --digi--typography--heading-2--font-weight--mobile );--TEXT-DECORATION--HEADING-2:var( --digi--typography--heading-2--text-decoration--mobile );--MARGIN--HEADING-2:var(--digi--typography--h2--margin--small);--FONT-SIZE--HEADING-3:var(--digi--typography--heading-3--font-size--mobile);--LINE-HEIGHT--HEADING-3:var( --digi--typography--heading-3--line-height--mobile );--FONT-WEIGHT--HEADING-3:var( --digi--typography--heading-3--font-weight--mobile );--TEXT-DECORATION--HEADING-3:var( --digi--typography--heading-3--text-decoration--mobile );--MARGIN--HEADING-3:var(--digi--typography--h3--margin--small);--FONT-SIZE--HEADING-4:var(--digi--typography--heading-4--font-size--mobile);--LINE-HEIGHT--HEADING-4:var( --digi--typography--heading-4--line-height--mobile );--FONT-WEIGHT--HEADING-4:var( --digi--typography--heading-4--font-weight--mobile );--TEXT-DECORATION--HEADING-4:var( --digi--typography--heading-4--text-decoration--mobile );--MARGIN--HEADING-4:var(--digi--typography--h4--margin--small);--FONT-SIZE--HEADING-5:var(--digi--typography--heading-4--font-size--mobile);--LINE-HEIGHT--HEADING-5:var( --digi--typography--heading-4--line-height--mobile );--FONT-WEIGHT--HEADING-5:var( --digi--typography--heading-4--font-weight--mobile );--TEXT-DECORATION--HEADING-5:var( --digi--typography--heading-4--text-decoration--mobile );--MARGIN--HEADING-5:var(--digi--typography--h4--margin--small);--FONT-SIZE--HEADING-6:var(--digi--typography--heading-4--font-size--mobile);--LINE-HEIGHT--HEADING-6:var( --digi--typography--heading-4--line-height--mobile );--FONT-WEIGHT--HEADING-6:var( --digi--typography--heading-4--font-weight--mobile );--TEXT-DECORATION--HEADING-6:var( --digi--typography--heading-4--text-decoration--mobile );--MARGIN--HEADING-6:var(--digi--typography--h4--margin--small)}@media (min-width: 61.9375rem){digi-typography{--FONT-SIZE--BODY:var(--digi--typography--body--font-size--desktop);--LINE-HEIGHT--BODY:var(--digi--typography--body--line-height--desktop);--FONT-WEIGHT--BODY:var(--digi--typography--body--font-weight--desktop);--TEXT-DECORATION--BODY:var( --digi--typography--body--text-decoration--desktop );--MARGIN--BODY:var(--digi--typography--paragraph--margin--small);--FONT-SIZE--LINK:var(--digi--typography--link--font-size--desktop);--LINE-HEIGHT--LINK:var(--digi--typography--link--line-height--desktop);--FONT-WEIGHT--LINK:var(--digi--typography--link--font-weight--desktop);--TEXT-DECORATION--LINK:var( --digi--typography--link--text-decoration--desktop );--FONT-SIZE--HEADING-1:var( --digi--typography--heading-1--font-size--desktop );--LINE-HEIGHT--HEADING-1:var( --digi--typography--heading-1--line-height--desktop );--FONT-WEIGHT--HEADING-1:var( --digi--typography--heading-1--font-weight--desktop );--TEXT-DECORATION--HEADING-1:var( --digi--typography--heading-1--text-decoration--desktop );--MARGIN--HEADING-1:var(--digi--typography--h1--margin--medium);--FONT-SIZE--HEADING-2:var( --digi--typography--heading-2--font-size--desktop );--LINE-HEIGHT--HEADING-2:var( --digi--typography--heading-2--line-height--desktop );--FONT-WEIGHT--HEADING-2:var( --digi--typography--heading-2--font-weight--desktop );--TEXT-DECORATION--HEADING-2:var( --digi--typography--heading-2--text-decoration--desktop );--MARGIN--HEADING-2:var(--digi--typography--h2--margin--small);--FONT-SIZE--HEADING-3:var( --digi--typography--heading-3--font-size--desktop );--LINE-HEIGHT--HEADING-3:var( --digi--typography--heading-3--line-height--desktop );--FONT-WEIGHT--HEADING-3:var( --digi--typography--heading-3--font-weight--desktop );--TEXT-DECORATION--HEADING-3:var( --digi--typography--heading-3--text-decoration--desktop );--MARGIN--HEADING-3:var(--digi--typography--h3--margin--small);--FONT-SIZE--HEADING-4:var( --digi--typography--heading-4--font-size--desktop );--LINE-HEIGHT--HEADING-4:var( --digi--typography--heading-4--line-height--desktop );--FONT-WEIGHT--HEADING-4:var( --digi--typography--heading-4--font-weight--desktop );--TEXT-DECORATION--HEADING-4:var( --digi--typography--heading-4--text-decoration--desktop );--MARGIN--HEADING-4:var(--digi--typography--h4--margin--small);--FONT-SIZE--HEADING-5:var( --digi--typography--heading-4--font-size--desktop );--LINE-HEIGHT--HEADING-5:var( --digi--typography--heading-4--line-height--desktop );--FONT-WEIGHT--HEADING-5:var( --digi--typography--heading-4--font-weight--desktop );--TEXT-DECORATION--HEADING-5:var( --digi--typography--heading-4--text-decoration--desktop );--MARGIN--HEADING-5:var(--digi--typography--h5--margin--small);--FONT-SIZE--HEADING-6:var( --digi--typography--heading-4--font-size--desktop );--LINE-HEIGHT--HEADING-6:var( --digi--typography--heading-4--line-height--desktop );--FONT-WEIGHT--HEADING-6:var( --digi--typography--heading-4--font-weight--desktop );--TEXT-DECORATION--HEADING-6:var( --digi--typography--heading-4--text-decoration--desktop );--MARGIN--HEADING-6:var(--digi--typography--h6--margin--small)}}digi-typography h1,digi-typography h2,digi-typography h3,digi-typography h4,digi-typography h5,digi-typography h6{margin-top:0;}digi-typography h1,digi-typography .digi-h1{font-size:var(--FONT-SIZE--HEADING-1);line-height:var(--LINE-HEIGHT--HEADING-1);font-weight:var(--FONT-WEIGHT--HEADING-1);text-decoration:var(--TEXT-DECORATION--HEADING-1);margin-bottom:var(--MARGIN--HEADING-1)}digi-typography h2,digi-typography .digi-h2{font-size:var(--FONT-SIZE--HEADING-2);line-height:var(--LINE-HEIGHT--HEADING-2);font-weight:var(--FONT-WEIGHT--HEADING-2);text-decoration:var(--TEXT-DECORATION--HEADING-2);margin-bottom:var(--MARGIN--HEADING-2)}digi-typography h3,digi-typography .digi-h3{font-size:var(--FONT-SIZE--HEADING-3);line-height:var(--LINE-HEIGHT--HEADING-3);font-weight:var(--FONT-WEIGHT--HEADING-3);text-decoration:var(--TEXT-DECORATION--HEADING-3);margin-bottom:var(--MARGIN--HEADING-3)}digi-typography h4,digi-typography .digi-h4{font-size:var(--FONT-SIZE--HEADING-4);line-height:var(--LINE-HEIGHT--HEADING-4);font-weight:var(--FONT-WEIGHT--HEADING-4);text-decoration:var(--TEXT-DECORATION--HEADING-4);margin-bottom:var(--MARGIN--HEADING-4)}digi-typography h5,digi-typography .digi-h5{font-size:var(--FONT-SIZE--HEADING-5);line-height:var(--LINE-HEIGHT--HEADING-5);font-weight:var(--FONT-WEIGHT--HEADING-5);text-decoration:var(--TEXT-DECORATION--HEADING-5);margin-bottom:var(--MARGIN--HEADING-5)}digi-typography h6,digi-typography .digi-h6{font-size:var(--FONT-SIZE--HEADING-6);line-height:var(--LINE-HEIGHT--HEADING-6);font-weight:var(--FONT-WEIGHT--HEADING-6);text-decoration:var(--TEXT-DECORATION--HEADING-6);margin-bottom:var(--MARGIN--HEADING-6)}digi-typography p,digi-typography blockquote{font-size:var(--FONT-SIZE--BODY);line-height:var(--LINE-HEIGHT--BODY);font-weight:var(--FONT-WEIGHT--BODY);text-decoration:var(--TEXT-DECORATION--BODY);margin-top:initial;margin-bottom:var(--MARGIN--BODY);max-width:var(--digi--paragraph-width--medium)}digi-typography p:last-child,digi-typography blockquote:last-child{margin-bottom:0}digi-typography blockquote{margin-inline:0}digi-typography digi-typography-preamble{display:block;margin-bottom:var(--MARGIN--BODY)}digi-typography digi-typography-preamble:last-child{margin-bottom:0}digi-typography ul,digi-typography ol,digi-typography dl{font-size:var(--FONT-SIZE--BODY);line-height:var(--LINE-HEIGHT--BODY);font-weight:var(--FONT-WEIGHT--BODY);text-decoration:var(--TEXT-DECORATION--BODY);max-width:var(--digi--paragraph-width--medium);margin-bottom:var(--MARGIN--BODY)}digi-typography ul,digi-typography ol{margin:0 0 var(--MARGIN--BODY) 0;padding-inline-start:1.5rem}digi-typography ul li,digi-typography ol li{margin-top:initial;margin-bottom:0.5rem;box-sizing:border-box;width:100%;padding-left:0}digi-typography ul li:last-child,digi-typography ol li:last-child{margin-bottom:0}digi-typography a{font-size:1em;line-height:var(--LINE-HEIGHT--LINK);font-weight:inherit;text-decoration:var(--TEXT-DECORATION--LINK);color:var(--digi--color--text--interactive--primary);text-decoration-thickness:var(--digi--typography--text-decoration-thickness--default);text-underline-offset:var(--digi--typography--text-underline-offset)}digi-typography a:hover{text-decoration:var(--TEXT-DECORATION--LINK);text-decoration-thickness:var(--digi--typography--text-decoration-thickness--hover)}digi-typography a:focus-visible{outline:2px solid black;outline-offset:2px;box-shadow:0px 0px 0px 5px white}digi-typography a:visited{color:var(--digi--color--text--interactive--visited)}digi-typography .digi-typography--hide-visited a:visited{color:var(--digi--color--text--interactive--primary)}digi-typography strong{font-weight:var(--digi--typography--label--font-weight--desktop)}`;
4076
+
4077
+ const Typography = class {
4078
+ constructor(hostRef) {
4079
+ registerInstance(this, hostRef);
4080
+ }
4081
+ get cssModifiers() {
4082
+ return {
4083
+ 'digi-typography--hide-visited': this.hideVisitedColor
4084
+ };
4085
+ }
4086
+ render() {
4087
+ return (h("div", { key: '2b78d2c69b94e258feb4c99d5835cc58507d7886', class: Object.assign({ 'digi-typography': true }, this.cssModifiers) }, h("slot", { key: '1f952d99d2331fb09a1b6d549a6ea97440302346' })));
4088
+ }
4089
+ };
4090
+ Typography.style = typographyCss();
4091
+
4092
+ const typographyHeadingJumboCss = () => `.sc-digi-typography-heading-jumbo-h{display:block}.sc-digi-typography-heading-jumbo-h .digi-typography-heading-jumbo.sc-digi-typography-heading-jumbo{font-size:var(--digi--typography--heading-jumbo--font-size--desktop);font-family:var(--digi--global--typography--font-family--default);color:var(--digi--color--text--primary);font-weight:var(--digi--typography--heading-jumbo--font-weight--desktop)}@media (min-width: 61.9375rem){.sc-digi-typography-heading-jumbo-h .digi-typography-heading-jumbo.sc-digi-typography-heading-jumbo{font-size:var(--digi--typography--heading-jumbo--font-size--desktop-large)}}.sc-digi-typography-heading-jumbo-h .digi-typography-heading-jumbo--secondary.sc-digi-typography-heading-jumbo{color:var(--digi--grayscale--0)}.sc-digi-typography-heading-jumbo-h .digi-typography-heading-jumbo.sc-digi-typography-heading-jumbo::after{content:"";width:11.875rem;height:0.4375rem;background:var(--digi--color--border--accent--primary);display:block;margin-top:var(--digi--padding--small)}@media (min-width: 61.9375rem){.sc-digi-typography-heading-jumbo-h .digi-typography-heading-jumbo.sc-digi-typography-heading-jumbo::after{width:13.75rem;margin-top:var(--digi--margin--h2-large);height:0.625rem}}.sc-digi-typography-heading-jumbo-h .digi-typography-heading-jumbo--secondary.sc-digi-typography-heading-jumbo::after{background:var(--digi--color--border--accent--secondary)}digi-typography .sc-digi-typography-heading-jumbo-h .digi-typography-heading-jumbo.sc-digi-typography-heading-jumbo{margin-bottom:var(--digi--margin--medium)}`;
4093
+
4094
+ const TypographyHeadingJumbo = class {
4095
+ constructor(hostRef) {
4096
+ registerInstance(this, hostRef);
4097
+ /**
4098
+ * Rubrikens text
4099
+ * @en The heading text
4100
+ */
4101
+ this.afText = '';
4102
+ /**
4103
+ * Sätt rubrikens vikt. 'h1' är förvalt.
4104
+ * @en Set heading level. Default is 'h1'
4105
+ */
4106
+ this.afLevel = TypographyHeadingJumboLevel.H1;
4107
+ /**
4108
+ * Sätt språk inuti rubrik-elementet. 'sv' (svenska) är förvalt.
4109
+ * @en Set language inside of title element. Defaults to 'sv' (swedish).
4110
+ */
4111
+ this.afLang = 'sv';
4112
+ }
4113
+ /**
4114
+ * Lyssnar på om fokus sätts på custom-elementet och propagerar ner det till själva rubrik-elementet.
4115
+ * @en Listens for when focus is set on the custom element and propagates it down to the actual heading element.
4116
+ */
4117
+ focusOnHeading() {
4118
+ this.headingElement.focus();
4119
+ }
4120
+ get cssModifiers() {
4121
+ return {
4122
+ 'digi-typography-heading-jumbo--primary': this.afVariation === TypographyHeadingJumboVariation.PRIMARY,
4123
+ 'digi-typography-heading-jumbo--secondary': this.afVariation === TypographyHeadingJumboVariation.SECONDARY
4124
+ };
4125
+ }
4126
+ render() {
4127
+ return (h(this.afLevel, { key: 'b63f9447d1ccefc73fcd3ac26562ed4d9f106f3c', ref: (el) => (this.headingElement = el), class: Object.assign({ 'digi-typography-heading-jumbo': true }, this.cssModifiers), lang: this.afLang, tabindex: -1 }, this.afText));
4128
+ }
4129
+ };
4130
+ TypographyHeadingJumbo.style = typographyHeadingJumboCss();
4131
+
4132
+ const UtilKeydownHandler = class {
4133
+ constructor(hostRef) {
4134
+ registerInstance(this, hostRef);
4135
+ this.afOnEsc = createEvent(this, "afOnEsc", 7);
4136
+ this.afOnEnter = createEvent(this, "afOnEnter", 7);
4137
+ this.afOnTab = createEvent(this, "afOnTab", 7);
4138
+ this.afOnSpace = createEvent(this, "afOnSpace", 7);
4139
+ this.afOnShiftTab = createEvent(this, "afOnShiftTab", 7);
4140
+ this.afOnUp = createEvent(this, "afOnUp", 7);
4141
+ this.afOnDown = createEvent(this, "afOnDown", 7);
4142
+ this.afOnLeft = createEvent(this, "afOnLeft", 7);
4143
+ this.afOnRight = createEvent(this, "afOnRight", 7);
4144
+ this.afOnHome = createEvent(this, "afOnHome", 7);
4145
+ this.afOnEnd = createEvent(this, "afOnEnd", 7);
4146
+ this.afOnKeyDown = createEvent(this, "afOnKeyDown", 7);
4147
+ }
4148
+ keydownHandler(e) {
4149
+ const key = keyboardHandler(e);
4150
+ switch (key) {
4151
+ case KEY_CODE.SHIFT_TAB:
4152
+ this.afOnShiftTab.emit(e);
4153
+ break;
4154
+ case KEY_CODE.DOWN_ARROW:
4155
+ this.afOnDown.emit(e);
4156
+ this.afOnKeyDown.emit(e);
4157
+ break;
4158
+ case KEY_CODE.UP_ARROW:
4159
+ this.afOnUp.emit(e);
4160
+ this.afOnKeyDown.emit(e);
4161
+ break;
4162
+ case KEY_CODE.LEFT_ARROW:
4163
+ this.afOnLeft.emit(e);
4164
+ this.afOnKeyDown.emit(e);
4165
+ break;
4166
+ case KEY_CODE.RIGHT_ARROW:
4167
+ this.afOnRight.emit(e);
4168
+ this.afOnKeyDown.emit(e);
4169
+ break;
4170
+ case KEY_CODE.ENTER:
4171
+ this.afOnEnter.emit(e);
4172
+ this.afOnKeyDown.emit(e);
4173
+ break;
4174
+ case KEY_CODE.ESCAPE:
4175
+ this.afOnEsc.emit(e);
4176
+ this.afOnKeyDown.emit(e);
4177
+ break;
4178
+ case KEY_CODE.TAB:
4179
+ this.afOnTab.emit(e);
4180
+ this.afOnKeyDown.emit(e);
4181
+ break;
4182
+ case KEY_CODE.SPACE:
4183
+ this.afOnSpace.emit(e);
4184
+ this.afOnKeyDown.emit(e);
4185
+ break;
4186
+ case KEY_CODE.HOME:
4187
+ this.afOnHome.emit(e);
4188
+ this.afOnKeyDown.emit(e);
4189
+ break;
4190
+ case KEY_CODE.END:
4191
+ this.afOnEnd.emit(e);
4192
+ this.afOnKeyDown.emit(e);
4193
+ break;
4194
+ case KEY_CODE.ANY:
4195
+ this.afOnKeyDown.emit(e);
4196
+ break;
4197
+ default:
4198
+ this.afOnKeyDown.emit(e);
4199
+ return;
4200
+ }
4201
+ }
4202
+ render() {
4203
+ return h("slot", { key: 'c0a9e056eb5e48ce215370d38ee65a62ca2e33d9' });
4204
+ }
4205
+ };
4206
+
4207
+ export { Calendar as digi_calendar, CalendarDatepicker as digi_calendar_datepicker, ExpandableAccordion as digi_expandable_accordion, ExpandableFaqItem as digi_expandable_faq_item, FormInput as digi_form_input, FormLabel as digi_form_label, FormSelect as digi_form_select, FormValidationMessage as digi_form_validation_message, IconCalendarAlt as digi_icon_calendar_alt, IconChevronDown as digi_icon_chevron_down, IconChevronLeft as digi_icon_chevron_left, IconChevronRight as digi_icon_chevron_right, IconInputSelectMarker as digi_icon_input_select_marker, IconValidationError as digi_icon_validation_error, IconCheckCircle as digi_icon_validation_success, IconValidationWarning as digi_icon_validation_warning, Typography as digi_typography, TypographyHeadingJumbo as digi_typography_heading_jumbo, UtilKeydownHandler as digi_util_keydown_handler };