@telia-ace/alliance-ui 1.0.0-beta.1
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.
- package/LICENSE.txt +6 -0
- package/README.md +182 -0
- package/dist/check-circle-filled.03dd4fa8.js +5 -0
- package/dist/check-circle-filled.03dd4fa8.js.map +1 -0
- package/dist/chevron-down.ea4a357f.js +5 -0
- package/dist/chevron-down.ea4a357f.js.map +1 -0
- package/dist/close.63145e8b.js +5 -0
- package/dist/close.63145e8b.js.map +1 -0
- package/dist/components/alliance-object-list-head.d.ts +8 -0
- package/dist/components/alliance-object-list-head.js +43 -0
- package/dist/components/alliance-object-list-head.js.map +1 -0
- package/dist/components/alliance-object-list-item.d.ts +6 -0
- package/dist/components/alliance-object-list-item.js +39 -0
- package/dist/components/alliance-object-list-item.js.map +1 -0
- package/dist/components/alliance-object-list-row.d.ts +7 -0
- package/dist/components/alliance-object-list-row.js +64 -0
- package/dist/components/alliance-object-list-row.js.map +1 -0
- package/dist/components/alliance-object-list.d.ts +13 -0
- package/dist/components/alliance-object-list.js +177 -0
- package/dist/components/alliance-object-list.js.map +1 -0
- package/dist/error-filled.e9871460.js +5 -0
- package/dist/error-filled.e9871460.js.map +1 -0
- package/dist/getSvgContent.574747aa.js +14 -0
- package/dist/getSvgContent.574747aa.js.map +1 -0
- package/dist/index.887fae41.js +533 -0
- package/dist/index.887fae41.js.map +1 -0
- package/dist/index.d5c12253.js +212 -0
- package/dist/index.d5c12253.js.map +1 -0
- package/dist/query-assigned-elements.ce962b7d.js +605 -0
- package/dist/query-assigned-elements.ce962b7d.js.map +1 -0
- package/dist/stringCombiner.723baccb.js +50 -0
- package/dist/stringCombiner.723baccb.js.map +1 -0
- package/dist/telia-button-text2.eaccd0fa.js +86 -0
- package/dist/telia-button-text2.eaccd0fa.js.map +1 -0
- package/dist/telia-card-frame2.5a37779b.js +35 -0
- package/dist/telia-card-frame2.5a37779b.js.map +1 -0
- package/dist/telia-divider.234d5cda.js +46 -0
- package/dist/telia-divider.234d5cda.js.map +1 -0
- package/dist/telia-field-assistive-text2.a2e95f9c.js +32 -0
- package/dist/telia-field-assistive-text2.a2e95f9c.js.map +1 -0
- package/dist/telia-field-error2.0224a8ba.js +40 -0
- package/dist/telia-field-error2.0224a8ba.js.map +1 -0
- package/dist/telia-field-valid2.12939372.js +39 -0
- package/dist/telia-field-valid2.12939372.js.map +1 -0
- package/dist/telia-heading2.d678c373.js +70 -0
- package/dist/telia-heading2.d678c373.js.map +1 -0
- package/dist/telia-icon2.d9c217d3.js +68 -0
- package/dist/telia-icon2.d9c217d3.js.map +1 -0
- package/dist/telia-label2.772a27dd.js +36 -0
- package/dist/telia-label2.772a27dd.js.map +1 -0
- package/dist/telia-link2.2dd5d63b.js +51 -0
- package/dist/telia-link2.2dd5d63b.js.map +1 -0
- package/dist/telia-navigation-button2.382f7720.js +44 -0
- package/dist/telia-navigation-button2.382f7720.js.map +1 -0
- package/dist/telia-style-link2.8e4c3e4e.js +55 -0
- package/dist/telia-style-link2.8e4c3e4e.js.map +1 -0
- package/dist/telia-style-navigation-item2.d4c167f1.js +44 -0
- package/dist/telia-style-navigation-item2.d4c167f1.js.map +1 -0
- package/dist/telia-tab-header2.ad6810c2.js +90 -0
- package/dist/telia-tab-header2.ad6810c2.js.map +1 -0
- package/dist/telia-visually-hidden2.eb0b21e9.js +34 -0
- package/dist/telia-visually-hidden2.eb0b21e9.js.map +1 -0
- package/dist/telia-vst2.e5fee7c3.js +41 -0
- package/dist/telia-vst2.e5fee7c3.js.map +1 -0
- package/dist/uniqueId.6afec4c5.js +5 -0
- package/dist/uniqueId.6afec4c5.js.map +1 -0
- package/dist/variables.a6d7935e.js +8 -0
- package/dist/variables.a6d7935e.js.map +1 -0
- package/dist/voca/components/telia-badge.d.ts +1 -0
- package/dist/voca/components/telia-badge.js +35 -0
- package/dist/voca/components/telia-badge.js.map +1 -0
- package/dist/voca/components/telia-button-text.d.ts +1 -0
- package/dist/voca/components/telia-button-text.js +6 -0
- package/dist/voca/components/telia-button-text.js.map +1 -0
- package/dist/voca/components/telia-button.d.ts +1 -0
- package/dist/voca/components/telia-button.js +74 -0
- package/dist/voca/components/telia-button.js.map +1 -0
- package/dist/voca/components/telia-card-frame-link.d.ts +1 -0
- package/dist/voca/components/telia-card-frame-link.js +46 -0
- package/dist/voca/components/telia-card-frame-link.js.map +1 -0
- package/dist/voca/components/telia-card-frame.d.ts +1 -0
- package/dist/voca/components/telia-card-frame.js +4 -0
- package/dist/voca/components/telia-card-frame.js.map +1 -0
- package/dist/voca/components/telia-checkbox.d.ts +1 -0
- package/dist/voca/components/telia-checkbox.js +92 -0
- package/dist/voca/components/telia-checkbox.js.map +1 -0
- package/dist/voca/components/telia-chip-choice.d.ts +1 -0
- package/dist/voca/components/telia-chip-choice.js +68 -0
- package/dist/voca/components/telia-chip-choice.js.map +1 -0
- package/dist/voca/components/telia-chip-filter.d.ts +1 -0
- package/dist/voca/components/telia-chip-filter.js +48 -0
- package/dist/voca/components/telia-chip-filter.js.map +1 -0
- package/dist/voca/components/telia-color-dot.d.ts +1 -0
- package/dist/voca/components/telia-color-dot.js +38 -0
- package/dist/voca/components/telia-color-dot.js.map +1 -0
- package/dist/voca/components/telia-cta-link.d.ts +1 -0
- package/dist/voca/components/telia-cta-link.js +56 -0
- package/dist/voca/components/telia-cta-link.js.map +1 -0
- package/dist/voca/components/telia-date-picker.d.ts +1 -0
- package/dist/voca/components/telia-date-picker.js +528 -0
- package/dist/voca/components/telia-date-picker.js.map +1 -0
- package/dist/voca/components/telia-divider.d.ts +1 -0
- package/dist/voca/components/telia-divider.js +4 -0
- package/dist/voca/components/telia-divider.js.map +1 -0
- package/dist/voca/components/telia-field-assistive-text.d.ts +1 -0
- package/dist/voca/components/telia-field-assistive-text.js +4 -0
- package/dist/voca/components/telia-field-assistive-text.js.map +1 -0
- package/dist/voca/components/telia-field-error.d.ts +1 -0
- package/dist/voca/components/telia-field-error.js +7 -0
- package/dist/voca/components/telia-field-error.js.map +1 -0
- package/dist/voca/components/telia-field-valid.d.ts +1 -0
- package/dist/voca/components/telia-field-valid.js +7 -0
- package/dist/voca/components/telia-field-valid.js.map +1 -0
- package/dist/voca/components/telia-fieldset.d.ts +1 -0
- package/dist/voca/components/telia-fieldset.js +53 -0
- package/dist/voca/components/telia-fieldset.js.map +1 -0
- package/dist/voca/components/telia-focus-trap.d.ts +1 -0
- package/dist/voca/components/telia-focus-trap.js +69 -0
- package/dist/voca/components/telia-focus-trap.js.map +1 -0
- package/dist/voca/components/telia-form.d.ts +1 -0
- package/dist/voca/components/telia-form.js +56 -0
- package/dist/voca/components/telia-form.js.map +1 -0
- package/dist/voca/components/telia-heading.d.ts +1 -0
- package/dist/voca/components/telia-heading.js +4 -0
- package/dist/voca/components/telia-heading.js.map +1 -0
- package/dist/voca/components/telia-icon.d.ts +1 -0
- package/dist/voca/components/telia-icon.js +5 -0
- package/dist/voca/components/telia-icon.js.map +1 -0
- package/dist/voca/components/telia-image.d.ts +1 -0
- package/dist/voca/components/telia-image.js +42 -0
- package/dist/voca/components/telia-image.js.map +1 -0
- package/dist/voca/components/telia-label.d.ts +1 -0
- package/dist/voca/components/telia-label.js +4 -0
- package/dist/voca/components/telia-label.js.map +1 -0
- package/dist/voca/components/telia-link-image.d.ts +1 -0
- package/dist/voca/components/telia-link-image.js +55 -0
- package/dist/voca/components/telia-link-image.js.map +1 -0
- package/dist/voca/components/telia-link.d.ts +1 -0
- package/dist/voca/components/telia-link.js +5 -0
- package/dist/voca/components/telia-link.js.map +1 -0
- package/dist/voca/components/telia-list.d.ts +1 -0
- package/dist/voca/components/telia-list.js +65 -0
- package/dist/voca/components/telia-list.js.map +1 -0
- package/dist/voca/components/telia-logo.d.ts +1 -0
- package/dist/voca/components/telia-logo.js +54 -0
- package/dist/voca/components/telia-logo.js.map +1 -0
- package/dist/voca/components/telia-navigation-button.d.ts +1 -0
- package/dist/voca/components/telia-navigation-button.js +5 -0
- package/dist/voca/components/telia-navigation-button.js.map +1 -0
- package/dist/voca/components/telia-navigation-dropdown.d.ts +1 -0
- package/dist/voca/components/telia-navigation-dropdown.js +68 -0
- package/dist/voca/components/telia-navigation-dropdown.js.map +1 -0
- package/dist/voca/components/telia-navigation-link.d.ts +1 -0
- package/dist/voca/components/telia-navigation-link.js +40 -0
- package/dist/voca/components/telia-navigation-link.js.map +1 -0
- package/dist/voca/components/telia-notification.d.ts +1 -0
- package/dist/voca/components/telia-notification.js +82 -0
- package/dist/voca/components/telia-notification.js.map +1 -0
- package/dist/voca/components/telia-overlay.d.ts +1 -0
- package/dist/voca/components/telia-overlay.js +31 -0
- package/dist/voca/components/telia-overlay.js.map +1 -0
- package/dist/voca/components/telia-p.d.ts +1 -0
- package/dist/voca/components/telia-p.js +45 -0
- package/dist/voca/components/telia-p.js.map +1 -0
- package/dist/voca/components/telia-pictogram.d.ts +1 -0
- package/dist/voca/components/telia-pictogram.js +92 -0
- package/dist/voca/components/telia-pictogram.js.map +1 -0
- package/dist/voca/components/telia-radio-button.d.ts +1 -0
- package/dist/voca/components/telia-radio-button.js +46 -0
- package/dist/voca/components/telia-radio-button.js.map +1 -0
- package/dist/voca/components/telia-select.d.ts +1 -0
- package/dist/voca/components/telia-select.js +114 -0
- package/dist/voca/components/telia-select.js.map +1 -0
- package/dist/voca/components/telia-skeleton.d.ts +1 -0
- package/dist/voca/components/telia-skeleton.js +32 -0
- package/dist/voca/components/telia-skeleton.js.map +1 -0
- package/dist/voca/components/telia-status-badge.d.ts +1 -0
- package/dist/voca/components/telia-status-badge.js +57 -0
- package/dist/voca/components/telia-status-badge.js.map +1 -0
- package/dist/voca/components/telia-style-link.d.ts +1 -0
- package/dist/voca/components/telia-style-link.js +4 -0
- package/dist/voca/components/telia-style-link.js.map +1 -0
- package/dist/voca/components/telia-style-navigation-item.d.ts +1 -0
- package/dist/voca/components/telia-style-navigation-item.js +4 -0
- package/dist/voca/components/telia-style-navigation-item.js.map +1 -0
- package/dist/voca/components/telia-tab-content.d.ts +1 -0
- package/dist/voca/components/telia-tab-content.js +36 -0
- package/dist/voca/components/telia-tab-content.js.map +1 -0
- package/dist/voca/components/telia-tab-header.d.ts +1 -0
- package/dist/voca/components/telia-tab-header.js +6 -0
- package/dist/voca/components/telia-tab-header.js.map +1 -0
- package/dist/voca/components/telia-tab.d.ts +1 -0
- package/dist/voca/components/telia-tab.js +146 -0
- package/dist/voca/components/telia-tab.js.map +1 -0
- package/dist/voca/components/telia-text-input.d.ts +1 -0
- package/dist/voca/components/telia-text-input.js +152 -0
- package/dist/voca/components/telia-text-input.js.map +1 -0
- package/dist/voca/components/telia-text-spacing.d.ts +1 -0
- package/dist/voca/components/telia-text-spacing.js +29 -0
- package/dist/voca/components/telia-text-spacing.js.map +1 -0
- package/dist/voca/components/telia-textarea.d.ts +1 -0
- package/dist/voca/components/telia-textarea.js +111 -0
- package/dist/voca/components/telia-textarea.js.map +1 -0
- package/dist/voca/components/telia-toggle.d.ts +1 -0
- package/dist/voca/components/telia-toggle.js +143 -0
- package/dist/voca/components/telia-toggle.js.map +1 -0
- package/dist/voca/components/telia-visually-hidden.d.ts +1 -0
- package/dist/voca/components/telia-visually-hidden.js +4 -0
- package/dist/voca/components/telia-visually-hidden.js.map +1 -0
- package/dist/voca/foundations/index.d.ts +2 -0
- package/dist/voca/foundations/index.js +15 -0
- package/dist/voca/foundations/index.js.map +1 -0
- package/dist/voca/icons/index.d.ts +1 -0
- package/dist/voca/icons/index.js +336 -0
- package/dist/voca/icons/index.js.map +1 -0
- package/package.json +50 -0
|
@@ -0,0 +1,528 @@
|
|
|
1
|
+
import { p as q, H as K, c as F, h as i, a as $, F as W } from "../../index.887fae41.js";
|
|
2
|
+
import { u as b } from "../../uniqueId.6afec4c5.js";
|
|
3
|
+
import { s as j } from "../../stringCombiner.723baccb.js";
|
|
4
|
+
import { c as E } from "../../chevron-down.ea4a357f.js";
|
|
5
|
+
import { c as J } from "../../close.63145e8b.js";
|
|
6
|
+
import { d as U } from "../../telia-field-assistive-text2.a2e95f9c.js";
|
|
7
|
+
import { d as X } from "../../telia-field-error2.0224a8ba.js";
|
|
8
|
+
import { d as Q } from "../../telia-heading2.d678c373.js";
|
|
9
|
+
import { d as ee } from "../../telia-icon2.d9c217d3.js";
|
|
10
|
+
import { d as te } from "../../telia-label2.772a27dd.js";
|
|
11
|
+
import { d as ae } from "../../telia-vst2.e5fee7c3.js";
|
|
12
|
+
import "../../error-filled.e9871460.js";
|
|
13
|
+
import "../../getSvgContent.574747aa.js";
|
|
14
|
+
const ie = { name: "chevron-right", svg: '<svg viewBox="0 0 64 64" xmlns="http://www.w3.org/2000/svg" fill="currentColor"><path fill-rule="evenodd" clip-rule="evenodd" d="M47.1663 32.0005C47.1667 32.6147 46.9059 33.2001 46.449 33.6106L24.7824 53.1106C23.8931 53.9111 22.5233 53.8391 21.7228 52.9498C20.9223 52.0606 20.9943 50.6907 21.8836 49.8903L41.7613 32.0005L21.8836 14.1106C21.3083 13.5928 21.053 12.8075 21.2138 12.0503C21.3746 11.2932 21.9271 10.6794 22.6632 10.4402C23.3993 10.2009 24.2071 10.3724 24.7824 10.8903L46.449 30.3903C46.9059 30.8008 47.1667 31.3862 47.1663 32.0005Z"/></svg>' }, re = { name: "calendar", svg: '<svg viewBox="0 0 64 64" xmlns="http://www.w3.org/2000/svg" fill="currentColor"><path fill-rule="evenodd" clip-rule="evenodd" d="M58 51.3846V16.9231C57.9973 14.5451 56.0588 12.6181 53.6667 12.6154H49.3333V8.30769C49.3306 5.92975 47.3921 4.00272 45 4H40.6667C38.2746 4.00272 36.3361 5.92975 36.3333 8.30769V12.6154H27.6667V8.30769C27.6639 5.92975 25.7254 4.00272 23.3333 4H19C16.6079 4.00272 14.6694 5.92975 14.6667 8.30769V12.6154H10.3333C7.94123 12.6181 6.00273 14.5451 6 16.9231V51.3846C6.00547 56.1405 9.88247 59.9946 14.6667 60H49.3333C54.1175 59.9946 57.9945 56.1405 58 51.3846ZM44.9999 16.923H40.6666V8.30766H44.9999V16.923ZM23.3333 16.923H18.9999V8.30766H23.3333V16.923ZM49.3334 16.9231H53.6668V24.9852H10.3334V16.9231H14.6668C14.6695 19.301 16.608 21.228 19.0001 21.2307H23.3334C25.7255 21.228 27.664 19.301 27.6668 16.9231H36.3334C36.3362 19.301 38.2747 21.228 40.6668 21.2307H45.0001C47.3922 21.228 49.3307 19.301 49.3334 16.9231ZM10.3334 28.9852V51.3846C10.3362 53.7625 12.2747 55.6896 14.6668 55.6923H49.3334C51.7255 55.6896 53.664 53.7625 53.6668 51.3846V28.9852H10.3334Z"/><path d="M14.6949 35.3069C14.6949 34.2023 15.5957 33.3069 16.7068 33.3069H21.378C22.4891 33.3069 23.3899 34.2024 23.3899 35.3069V36.7091C23.3899 37.8137 22.4891 38.7091 21.378 38.7091H16.7068C15.5957 38.7091 14.6949 37.8137 14.6949 36.7091V35.3069Z"/><path d="M27.7374 35.3069C27.7374 34.2023 28.6381 33.3069 29.7493 33.3069H34.4204C35.5316 33.3069 36.4323 34.2024 36.4323 35.3069V36.7091C36.4323 37.8137 35.5316 38.7091 34.4204 38.7091H29.7493C28.6381 38.7091 27.7374 37.8137 27.7374 36.7091V35.3069Z"/><path d="M40.7798 35.3069C40.7798 34.2023 41.6806 33.3069 42.7917 33.3069H47.4629C48.574 33.3069 49.4748 34.2024 49.4748 35.3069V36.7091C49.4748 37.8137 48.574 38.7091 47.4629 38.7091H42.7917C41.6806 38.7091 40.7798 37.8137 40.7798 36.7091V35.3069Z"/><path d="M14.6949 46.1114C14.6949 45.0068 15.5957 44.1114 16.7068 44.1114H21.378C22.4891 44.1114 23.3899 45.0068 23.3899 46.1114V47.5136C23.3899 48.6181 22.4891 49.5136 21.378 49.5136H16.7068C15.5957 49.5136 14.6949 48.6181 14.6949 47.5136V46.1114Z"/><path d="M27.7374 46.1114C27.7374 45.0068 28.6381 44.1114 29.7493 44.1114H34.4204C35.5316 44.1114 36.4323 45.0068 36.4323 46.1114V47.5136C36.4323 48.6181 35.5316 49.5136 34.4204 49.5136H29.7493C28.6381 49.5136 27.7374 48.6181 27.7374 47.5136V46.1114Z"/><path d="M40.7798 46.1114C40.7798 45.0068 41.6806 44.1114 42.7917 44.1114H47.4629C48.574 44.1114 49.4748 45.0068 49.4748 46.1114V47.5136C49.4748 48.6181 48.574 49.5136 47.4629 49.5136H42.7917C41.6806 49.5136 40.7798 48.6181 40.7798 47.5136V46.1114Z"/></svg>' }, le = { name: "chevron-left", svg: '<svg viewBox="0 0 64 64" xmlns="http://www.w3.org/2000/svg" fill="currentColor"><path fill-rule="evenodd" clip-rule="evenodd" d="M42.1162 49.8902C42.6915 50.4081 42.9468 51.1934 42.786 51.9505C42.6252 52.7076 42.0727 53.3214 41.3366 53.5607C40.6005 53.8 39.7927 53.6284 39.2174 53.1106L17.5508 33.6106C17.0942 33.1999 16.8335 32.6146 16.8335 32.0004C16.8335 31.3863 17.0942 30.801 17.5508 30.3902L39.2174 10.8902C40.1067 10.0898 41.4766 10.1618 42.277 11.0511C43.0775 11.9403 43.0055 13.3102 42.1162 14.1106L22.2385 32.0004L42.1162 49.8902Z"/></svg>' }, oe = /^(\d{4})-(\d{2})-(\d{2})$/;
|
|
15
|
+
var k;
|
|
16
|
+
(function(e) {
|
|
17
|
+
e[e.Sunday = 0] = "Sunday", e[e.Monday = 1] = "Monday", e[e.Tuesday = 2] = "Tuesday", e[e.Wednesday = 3] = "Wednesday", e[e.Thursday = 4] = "Thursday", e[e.Friday = 5] = "Friday", e[e.Saturday = 6] = "Saturday";
|
|
18
|
+
})(k || (k = {}));
|
|
19
|
+
function S(e, t, a) {
|
|
20
|
+
const r = parseInt(a, 10), l = parseInt(t, 10), s = parseInt(e, 10);
|
|
21
|
+
if (Number.isInteger(s) && Number.isInteger(l) && Number.isInteger(r) && l > 0 && l <= 12 && r > 0 && r <= 31 && s > 0)
|
|
22
|
+
return new Date(s, l - 1, r);
|
|
23
|
+
}
|
|
24
|
+
function p(e) {
|
|
25
|
+
if (!e)
|
|
26
|
+
return;
|
|
27
|
+
const t = e.match(oe);
|
|
28
|
+
if (t !== null && t.length)
|
|
29
|
+
return S(t[1], t[2], t[3]);
|
|
30
|
+
}
|
|
31
|
+
function V(e) {
|
|
32
|
+
if (e === void 0)
|
|
33
|
+
return "";
|
|
34
|
+
let t = e.getDate().toString(10), a = (e.getMonth() + 1).toString(10), r = e.getFullYear().toString(10);
|
|
35
|
+
return e.getDate() < 10 && (t = `0${t}`), e.getMonth() < 9 && (a = `0${a}`), `${r}-${a}-${t}`;
|
|
36
|
+
}
|
|
37
|
+
function I(e, t) {
|
|
38
|
+
return e == null || t == null ? !1 : A(e, t) && e.getDate() === t.getDate();
|
|
39
|
+
}
|
|
40
|
+
function A(e, t) {
|
|
41
|
+
return e == null || t == null ? !1 : e.getFullYear() === t.getFullYear() && e.getMonth() === t.getMonth();
|
|
42
|
+
}
|
|
43
|
+
function z(e, t) {
|
|
44
|
+
const a = new Date(e);
|
|
45
|
+
return a.setDate(a.getDate() + t), a;
|
|
46
|
+
}
|
|
47
|
+
function P(e, t = k.Monday) {
|
|
48
|
+
const a = new Date(e), r = a.getDay(), l = (r < t ? 7 : 0) + r - t;
|
|
49
|
+
return a.setDate(a.getDate() - l), a;
|
|
50
|
+
}
|
|
51
|
+
function R(e, t = k.Monday) {
|
|
52
|
+
const a = new Date(e), r = a.getDay(), l = (r < t ? -7 : 0) + 6 - (r - t);
|
|
53
|
+
return a.setDate(a.getDate() + l), a;
|
|
54
|
+
}
|
|
55
|
+
function w(e) {
|
|
56
|
+
return new Date(e.getFullYear(), e.getMonth(), 1);
|
|
57
|
+
}
|
|
58
|
+
function D(e) {
|
|
59
|
+
return new Date(e.getFullYear(), e.getMonth() + 1, 0);
|
|
60
|
+
}
|
|
61
|
+
function H(e, t) {
|
|
62
|
+
const a = new Date(e);
|
|
63
|
+
return a.setMonth(t), a;
|
|
64
|
+
}
|
|
65
|
+
function Y(e, t) {
|
|
66
|
+
const a = new Date(e);
|
|
67
|
+
return a.setFullYear(t), a;
|
|
68
|
+
}
|
|
69
|
+
function C(e, t, a) {
|
|
70
|
+
return M(e, t, a) === e;
|
|
71
|
+
}
|
|
72
|
+
function M(e, t, a) {
|
|
73
|
+
const r = e.getTime();
|
|
74
|
+
return t && t instanceof Date && r < t.getTime() ? t : a && a instanceof Date && r > a.getTime() ? a : e;
|
|
75
|
+
}
|
|
76
|
+
function se(e, t) {
|
|
77
|
+
const a = [];
|
|
78
|
+
let r = e;
|
|
79
|
+
for (; !I(r, t); )
|
|
80
|
+
a.push(r), r = z(r, 1);
|
|
81
|
+
return a.push(r), a;
|
|
82
|
+
}
|
|
83
|
+
function ce(e, t = k.Monday) {
|
|
84
|
+
const a = P(w(e), t), r = R(D(e), t);
|
|
85
|
+
return se(a, r);
|
|
86
|
+
}
|
|
87
|
+
const ne = ({ onClick: e, dateFormatter: t, describedBy: a, localization: r, name: l, formattedValue: s, valueAsDate: c, value: d, identifier: m, disabled: n, readonly: u, required: _, role: f, touched: g, buttonLabel: v, buttonRef: o, inputRef: y, onInput: N, onBlur: O, onFocus: B, makeTouched: T, htmlForm: Z }) => {
|
|
88
|
+
const G = u || n;
|
|
89
|
+
return i(
|
|
90
|
+
W,
|
|
91
|
+
null,
|
|
92
|
+
i("input", { class: {
|
|
93
|
+
"telia-date-picker__input": !0,
|
|
94
|
+
"telia-date-picker__input--touched": g
|
|
95
|
+
}, value: s, id: m, disabled: n, readonly: u, role: f, required: _ ? !0 : void 0, "aria-autocomplete": "none", "aria-describedby": a, onInput: N, onFocus: B, onBlur: (x) => {
|
|
96
|
+
T(), O(x);
|
|
97
|
+
}, autoComplete: "off", ref: y, onInvalid: (x) => {
|
|
98
|
+
T(), x.preventDefault();
|
|
99
|
+
}, form: Z }),
|
|
100
|
+
i("input", { type: "hidden", name: l, value: d }),
|
|
101
|
+
i(
|
|
102
|
+
"div",
|
|
103
|
+
{ class: "telia-date-picker__input-icon-container" },
|
|
104
|
+
i(
|
|
105
|
+
"button",
|
|
106
|
+
{ class: "telia-date-picker__toggle", "aria-label": v, onClick: e, disabled: G, ref: o, type: "button" },
|
|
107
|
+
i("telia-icon", { class: "telia-date-picker__toggle-icon", svg: re.svg, size: "md" }),
|
|
108
|
+
i(
|
|
109
|
+
"span",
|
|
110
|
+
{ class: "telia-date-picker__vhidden" },
|
|
111
|
+
r.buttonLabel,
|
|
112
|
+
c && i(
|
|
113
|
+
"span",
|
|
114
|
+
null,
|
|
115
|
+
", ",
|
|
116
|
+
r.selectedDateMessage,
|
|
117
|
+
" ",
|
|
118
|
+
t.format(c)
|
|
119
|
+
)
|
|
120
|
+
)
|
|
121
|
+
)
|
|
122
|
+
)
|
|
123
|
+
);
|
|
124
|
+
}, de = ({ focusedDay: e, today: t, day: a, onDaySelect: r, onKeyboardNavigation: l, focusedDayRef: s, disabled: c, inRange: d, isSelected: m, dateFormatter: n }) => {
|
|
125
|
+
const u = I(a, t), _ = A(a, e), f = I(a, e), g = !d;
|
|
126
|
+
return i(
|
|
127
|
+
"button",
|
|
128
|
+
{ class: {
|
|
129
|
+
"telia-date-picker__day": !0,
|
|
130
|
+
"is-outside": g,
|
|
131
|
+
"is-today": u,
|
|
132
|
+
"is-month": _,
|
|
133
|
+
"is-disabled": c
|
|
134
|
+
}, tabIndex: f ? 0 : -1, onClick: (o) => {
|
|
135
|
+
r(o, a);
|
|
136
|
+
}, onKeyDown: l, "aria-disabled": c ? "true" : void 0, disabled: g, type: "button", "aria-pressed": m ? "true" : "false", ref: (o) => {
|
|
137
|
+
f && o && s && s(o);
|
|
138
|
+
} },
|
|
139
|
+
i("span", { "aria-hidden": "true" }, a.getDate()),
|
|
140
|
+
i("span", { class: "telia-date-picker__vhidden" }, n.format(a))
|
|
141
|
+
);
|
|
142
|
+
};
|
|
143
|
+
function ue(e, t) {
|
|
144
|
+
const a = [];
|
|
145
|
+
for (let r = 0; r < e.length; r += t)
|
|
146
|
+
a.push(e.slice(r, r + t));
|
|
147
|
+
return a;
|
|
148
|
+
}
|
|
149
|
+
function me(e, t, a) {
|
|
150
|
+
return e.map((r, l) => {
|
|
151
|
+
const s = (l + t) % e.length;
|
|
152
|
+
return a(e[s]);
|
|
153
|
+
});
|
|
154
|
+
}
|
|
155
|
+
const he = ({ selectedDate: e, focusedDate: t, labelledById: a, localization: r, firstDayOfWeek: l, min: s, max: c, dateFormatter: d, isDateDisabled: m, onDateSelect: n, onKeyboardNavigation: u, focusedDayRef: _ }) => {
|
|
156
|
+
const f = new Date(), g = ce(t, l);
|
|
157
|
+
return i(
|
|
158
|
+
"div",
|
|
159
|
+
{ class: "telia-date-picker__table-wrapper" },
|
|
160
|
+
i(
|
|
161
|
+
"table",
|
|
162
|
+
{ class: "telia-date-picker__table", "aria-labelledby": a },
|
|
163
|
+
i(
|
|
164
|
+
"thead",
|
|
165
|
+
null,
|
|
166
|
+
i("tr", null, me(r.dayNames, l, (v) => i(
|
|
167
|
+
"th",
|
|
168
|
+
{ class: "telia-date-picker__table-header", scope: "col" },
|
|
169
|
+
i("span", { "aria-hidden": "true" }, v.substr(0, 2)),
|
|
170
|
+
i("span", { class: "telia-date-picker__vhidden" }, v)
|
|
171
|
+
)))
|
|
172
|
+
),
|
|
173
|
+
i("tbody", null, ue(g, 7).map((v) => i("tr", { class: "telia-date-picker__row" }, v.map((o) => i(
|
|
174
|
+
"td",
|
|
175
|
+
{ class: "telia-date-picker__cell" },
|
|
176
|
+
i(de, { day: o, today: f, focusedDay: t, isSelected: I(o, e), disabled: m(o), inRange: C(o, s, c), onDaySelect: n, dateFormatter: d, onKeyboardNavigation: u, focusedDayRef: _ })
|
|
177
|
+
)))))
|
|
178
|
+
)
|
|
179
|
+
);
|
|
180
|
+
}, pe = {
|
|
181
|
+
buttonLabel: "Choose date",
|
|
182
|
+
placeholder: "YYYY-MM-DD",
|
|
183
|
+
selectedDateMessage: "Selected date is",
|
|
184
|
+
prevMonthLabel: "Previous month",
|
|
185
|
+
nextMonthLabel: "Next month",
|
|
186
|
+
monthSelectLabel: "Month",
|
|
187
|
+
yearSelectLabel: "Year",
|
|
188
|
+
closeLabel: "Close window",
|
|
189
|
+
calendarHeading: "Choose a date",
|
|
190
|
+
dayNames: [
|
|
191
|
+
"Sunday",
|
|
192
|
+
"Monday",
|
|
193
|
+
"Tuesday",
|
|
194
|
+
"Wednesday",
|
|
195
|
+
"Thursday",
|
|
196
|
+
"Friday",
|
|
197
|
+
"Saturday"
|
|
198
|
+
],
|
|
199
|
+
monthNames: [
|
|
200
|
+
"January",
|
|
201
|
+
"February",
|
|
202
|
+
"March",
|
|
203
|
+
"April",
|
|
204
|
+
"May",
|
|
205
|
+
"June",
|
|
206
|
+
"July",
|
|
207
|
+
"August",
|
|
208
|
+
"September",
|
|
209
|
+
"October",
|
|
210
|
+
"November",
|
|
211
|
+
"December"
|
|
212
|
+
],
|
|
213
|
+
monthNamesShort: [
|
|
214
|
+
"Jan",
|
|
215
|
+
"Feb",
|
|
216
|
+
"Mar",
|
|
217
|
+
"Apr",
|
|
218
|
+
"May",
|
|
219
|
+
"Jun",
|
|
220
|
+
"Jul",
|
|
221
|
+
"Aug",
|
|
222
|
+
"Sep",
|
|
223
|
+
"Oct",
|
|
224
|
+
"Nov",
|
|
225
|
+
"Dec"
|
|
226
|
+
],
|
|
227
|
+
locale: "en-GB"
|
|
228
|
+
}, ve = {
|
|
229
|
+
parse: p,
|
|
230
|
+
format: V
|
|
231
|
+
}, fe = (e, t) => {
|
|
232
|
+
const a = [];
|
|
233
|
+
for (var r = e; r <= t; r++)
|
|
234
|
+
a.push(r);
|
|
235
|
+
return a;
|
|
236
|
+
}, ge = '.telia-date-picker{display:flex;flex-direction:column;position:relative}.telia-date-picker__label{order:1}.telia-date-picker__input{border:calc(0.1rem * var(--voca-rem-multiplier)) solid #8c8c90;border-radius:calc(0.2rem * var(--voca-rem-multiplier));background-color:#ffffff;color:#222222;font-family:"TeliaSans", Helvetica, Arial, "Lucida Grande", sans-serif;font-weight:normal;font-size:calc(1.6rem * var(--voca-rem-multiplier));line-height:1.5;-webkit-appearance:none;appearance:none;box-sizing:border-box;display:block;margin:0;padding:calc(1rem * var(--voca-rem-multiplier)) calc(1.2rem * var(--voca-rem-multiplier));width:100%;height:calc(4.6rem * var(--voca-rem-multiplier));margin:calc(0.4rem * var(--voca-rem-multiplier)) 0 0;order:2}.telia-date-picker__input:required{box-shadow:none}.telia-date-picker__input:hover{border:calc(0.2rem * var(--voca-rem-multiplier)) solid #29003e;padding:calc(calc(1rem * var(--voca-rem-multiplier)) - calc(0.1rem * var(--voca-rem-multiplier))) calc(calc(1.2rem * var(--voca-rem-multiplier)) - calc(0.1rem * var(--voca-rem-multiplier)))}.telia-date-picker__input:hover:focus{border:calc(0.1rem * var(--voca-rem-multiplier)) solid #8c8c90}.telia-date-picker__input:focus{outline:solid calc(0.3rem * var(--voca-rem-multiplier)) #0099ff;outline-offset:calc(0.2rem * var(--voca-rem-multiplier));padding:calc(1rem * var(--voca-rem-multiplier)) calc(1.2rem * var(--voca-rem-multiplier))}.telia-date-picker__input:focus:hover{border:calc(0.1rem * var(--voca-rem-multiplier)) solid #8c8c90}.telia-date-picker__input:read-only{border:calc(0.1rem * var(--voca-rem-multiplier)) solid #c8c8cd;background-color:#e8e8ed}.telia-date-picker__input:read-only:hover{border:calc(0.1rem * var(--voca-rem-multiplier)) solid #c8c8cd;padding:calc(1rem * var(--voca-rem-multiplier)) calc(1.2rem * var(--voca-rem-multiplier))}.telia-date-picker__input:disabled{border:calc(0.1rem * var(--voca-rem-multiplier)) solid #c8c8cd;background-color:#dcdce1;color:#606064;cursor:not-allowed;-webkit-text-fill-color:#606064}.telia-date-picker__input:disabled:hover{padding:calc(1rem * var(--voca-rem-multiplier)) calc(1.2rem * var(--voca-rem-multiplier))}.telia-date-picker__input:disabled~.telia-date-picker__label .telia-label{color:#606064;cursor:not-allowed}.telia-date-picker__input:disabled~.telia-date-picker__additional{color:#b0b0b5}.telia-date-picker__input:invalid{box-shadow:none}.telia-date-picker__input--touched:invalid{border:calc(0.1rem * var(--voca-rem-multiplier)) solid #be0040}.telia-date-picker__input--touched:invalid:focus{border:calc(0.1rem * var(--voca-rem-multiplier)) solid #8c8c90}.telia-date-picker__input--touched:invalid:hover:not(:focus){border:calc(0.2rem * var(--voca-rem-multiplier)) solid #be0040;padding:calc(calc(1rem * var(--voca-rem-multiplier)) - calc(0.1rem * var(--voca-rem-multiplier))) calc(calc(1.2rem * var(--voca-rem-multiplier)) - calc(0.1rem * var(--voca-rem-multiplier)))}.telia-date-picker__input-icon-container{align-items:center;display:flex;flex-direction:row;height:calc(4.6rem * var(--voca-rem-multiplier));justify-content:flex-end;margin:calc(-1 * calc(4.6rem * var(--voca-rem-multiplier))) 0 0 calc(100% - calc(1.2rem * var(--voca-rem-multiplier)));order:3}.telia-date-picker__additional{order:5}.telia-date-picker__error{margin:calc(0.4rem * var(--voca-rem-multiplier)) 0 0;order:6}.telia-date-picker__toggle{border:0 solid #8c8c90;border-left:calc(0.1rem * var(--voca-rem-multiplier)) solid #8c8c90;border-top-right-radius:calc(0.2rem * var(--voca-rem-multiplier));border-bottom-right-radius:calc(0.2rem * var(--voca-rem-multiplier));color:#29003e;align-items:center;-moz-appearance:none;-webkit-appearance:none;appearance:none;background:transparent;cursor:pointer;display:flex;height:calc(calc(4.6rem * var(--voca-rem-multiplier)) - calc(0.2rem * var(--voca-rem-multiplier)));justify-content:center;padding:0;-webkit-user-select:none;user-select:none}.telia-date-picker__toggle:focus{outline:solid calc(0.3rem * var(--voca-rem-multiplier)) #0099ff;outline-offset:calc(0.2rem * var(--voca-rem-multiplier))}.telia-date-picker__input:read-only~.telia-date-picker__input-icon-container .telia-date-picker__toggle{border-left:calc(0.1rem * var(--voca-rem-multiplier)) solid #c8c8cd;color:#606064}.telia-date-picker__input:invalid~.telia-date-picker__input-icon-container .telia-date-picker__toggle{color:#be0040}.telia-date-picker__input:disabled~.telia-date-picker__input-icon-container .telia-date-picker__toggle{border-left:calc(0.1rem * var(--voca-rem-multiplier)) solid #c8c8cd;color:#606064;cursor:not-allowed}.telia-date-picker__input:hover~.telia-date-picker__input-icon-container .telia-date-picker__toggle,.telia-date-picker__input:hover:focus~.telia-date-picker__input-icon-container .telia-date-picker__toggle{height:calc(calc(4.6rem * var(--voca-rem-multiplier)) - calc(0.4rem * var(--voca-rem-multiplier)))}.telia-date-picker__toggle-icon{margin:0 calc(1.2rem * var(--voca-rem-multiplier))}.telia-date-picker__dialog-container{order:4}.telia-date-picker__dialog{z-index:300;background-color:rgba(0, 0, 0, 0.24);bottom:0;display:flex;left:0;min-width:calc(32rem * var(--voca-rem-multiplier));opacity:0;position:fixed;right:0;top:0;transform:translateZ(0);transform-origin:bottom center;transition:transform 0.3s ease, opacity 0.3s ease, visibility 0.3s ease;visibility:hidden;width:100%;will-change:transform, opacity, visibility}@media screen and (min-width: 37.5em){.telia-date-picker__dialog{z-index:100;background:none;bottom:auto;position:absolute;right:auto;top:auto;transform:scale(0.96) translateZ(0) translateY(-2rem);transform-origin:top right}}.telia-date-picker__dialog.is-left{left:auto;right:0;width:auto}.telia-date-picker__dialog.is-active{opacity:1;transform:scale(1.0001) translateZ(0) translateY(0);visibility:visible}.telia-date-picker__dialog-content{background-color:#ffffff;border-radius:0;border-top-left-radius:calc(0.2rem * var(--voca-rem-multiplier));border-top-right-radius:calc(0.2rem * var(--voca-rem-multiplier));border-top:calc(0.1rem * var(--voca-rem-multiplier)) solid #606064;bottom:0;display:none;left:0;margin:0;max-width:none;padding:0;position:absolute;transform:translateZ(0) translateY(100%);width:100%}@media screen and (min-width: 37.5em){.telia-date-picker__dialog-content{border:calc(0.1rem * var(--voca-rem-multiplier)) solid #8c8c90;border-radius:calc(0.2rem * var(--voca-rem-multiplier));box-shadow:0 calc(0.8rem * var(--voca-rem-multiplier)) calc(2.4rem * var(--voca-rem-multiplier)) #dcdce1;margin:calc(0.8rem * var(--voca-rem-multiplier)) 0 0 auto;max-width:calc(31rem * var(--voca-rem-multiplier));min-width:calc(29rem * var(--voca-rem-multiplier));padding:0;position:relative;transform:none;transition:none;visibility:visible}}.is-active .telia-date-picker__dialog-content{display:block;transform:translateZ(0) translateY(0)}.telia-date-picker__table-wrapper{margin:calc(1.6rem * var(--voca-rem-multiplier)) 0 calc(2rem * var(--voca-rem-multiplier));padding:0 calc(1.6rem * var(--voca-rem-multiplier)) calc(0.8rem * var(--voca-rem-multiplier))}@media screen and (min-width: 37.5em){.telia-date-picker__table-wrapper{padding:0 calc(2rem * var(--voca-rem-multiplier))}}.telia-date-picker__table{font-family:"TeliaSans", Helvetica, Arial, "Lucida Grande", sans-serif;font-weight:normal;font-size:calc(1rem * var(--voca-rem-multiplier));color:#222222;border-collapse:collapse;border-spacing:0;line-height:1.25;margin:0;padding:0;text-align:center;width:100%}.telia-date-picker__table-header{font-family:"TeliaSans", Helvetica, Arial, "Lucida Grande", sans-serif;font-weight:bold;font-size:calc(1.2rem * var(--voca-rem-multiplier));color:#222222;letter-spacing:calc(0.1rem * var(--voca-rem-multiplier));line-height:1.4;padding-bottom:calc(0.8rem * var(--voca-rem-multiplier));text-decoration:none;text-transform:uppercase}.telia-date-picker__cell{text-align:center}.telia-date-picker__day{font-family:"TeliaSans", Helvetica, Arial, "Lucida Grande", sans-serif;font-weight:normal;font-size:calc(1.4rem * var(--voca-rem-multiplier));color:#222222;-moz-appearance:none;-webkit-appearance:none;appearance:none;background:transparent;border:0;border-radius:50%;cursor:pointer;display:inline-block;font-variant-numeric:tabular-nums;height:calc(3.2rem * var(--voca-rem-multiplier));line-height:calc(1.6rem * var(--voca-rem-multiplier));padding:0 0 calc(0.1rem * var(--voca-rem-multiplier));position:relative;text-align:center;vertical-align:middle;width:calc(3.2rem * var(--voca-rem-multiplier))}.telia-date-picker__day.is-today{font-family:"TeliaSans", Helvetica, Arial, "Lucida Grande", sans-serif;font-weight:500;color:#29003e;border:calc(0.1rem * var(--voca-rem-multiplier)) solid #29003e}.telia-date-picker__day.is-today:hover{background-color:#fbf0ff}.telia-date-picker__day:hover{font-family:"TeliaSans", Helvetica, Arial, "Lucida Grande", sans-serif;font-weight:500;background-color:#edc8ff;color:#29003e}.telia-date-picker__day[aria-pressed=true],.telia-date-picker__day[aria-pressed=true]:hover{font-family:"TeliaSans", Helvetica, Arial, "Lucida Grande", sans-serif;font-weight:bold;background-color:#990ae3;color:#ffffff;box-shadow:none;outline:0}.telia-date-picker__day:focus-visible{outline:none}.telia-date-picker__day:focus{outline:none;}.telia-date-picker__day:focus::before{border-radius:calc(99.9rem * var(--voca-rem-multiplier));box-shadow:0 0 0 calc(0.3rem * var(--voca-rem-multiplier)) #0099ff;bottom:calc(-1 * calc(0.4rem * var(--voca-rem-multiplier)));content:"";display:block;left:calc(-1 * calc(0.4rem * var(--voca-rem-multiplier)));position:absolute;right:calc(-1 * calc(0.4rem * var(--voca-rem-multiplier)));top:calc(-1 * calc(0.4rem * var(--voca-rem-multiplier)));z-index:101}@media screen and (min-width: 37.5em){.telia-date-picker__day:focus::before{z-index:301}}.telia-date-picker__day:not(.is-month){font-family:"TeliaSans", Helvetica, Arial, "Lucida Grande", sans-serif;font-weight:normal;box-shadow:none}.telia-date-picker__day:not(.is-month),.telia-date-picker__day[aria-disabled=true]{color:#b0b0b5;background:transparent;cursor:default}.telia-date-picker__day[aria-disabled=true]{font-family:"TeliaSans", Helvetica, Arial, "Lucida Grande", sans-serif;font-weight:normal;background-color:#e8e8ed;color:#8c8c90}.telia-date-picker__day[aria-disabled=true]:not(.is-today)::before{display:none}.telia-date-picker__day.is-outside{color:#606064;background-color:#e8e8ed;box-shadow:none;cursor:default;opacity:0.6;pointer-events:none}.telia-date-picker__day.is-outside::before{display:none}.telia-date-picker__header{border-bottom:calc(0.1rem * var(--voca-rem-multiplier)) solid #dcdce1;align-items:center;display:flex;justify-content:space-between;padding:calc(3.2rem * var(--voca-rem-multiplier)) calc(1.6rem * var(--voca-rem-multiplier)) calc(0.8rem * var(--voca-rem-multiplier)) calc(calc(1.6rem * var(--voca-rem-multiplier)) - calc(0.8rem * var(--voca-rem-multiplier)));width:100%}@media screen and (min-width: 37.5em){.telia-date-picker__header{padding:calc(3.2rem * var(--voca-rem-multiplier)) calc(2rem * var(--voca-rem-multiplier)) calc(0.8rem * var(--voca-rem-multiplier))}}.telia-date-picker__nav{white-space:nowrap}.telia-date-picker__prev,.telia-date-picker__next{color:#29003e;border:calc(0.1rem * var(--voca-rem-multiplier)) solid #29003e;align-items:center;-moz-appearance:none;-webkit-appearance:none;appearance:none;border-radius:50%;cursor:pointer;display:inline-flex;height:calc(3.2rem * var(--voca-rem-multiplier));justify-content:center;margin-left:calc(0.8rem * var(--voca-rem-multiplier));padding:0;width:calc(3.2rem * var(--voca-rem-multiplier))}.telia-date-picker__prev:hover,.telia-date-picker__next:hover{background-color:#edc8ff}.telia-date-picker__prev:focus,.telia-date-picker__next:focus{box-shadow:0 0 0 calc(0.3rem * var(--voca-rem-multiplier)) #0099ff;outline:none}.telia-date-picker__prev:active:focus,.telia-date-picker__next:active:focus{box-shadow:none}.telia-date-picker__prev:disabled,.telia-date-picker__next:disabled{cursor:default;opacity:0.5}.telia-date-picker__prev-icon{margin:0 auto}.telia-date-picker__next-icon{margin:0 auto}.telia-date-picker__select{display:inline-flex;margin-top:calc(0.4rem * var(--voca-rem-multiplier));position:relative}.telia-date-picker__select select{cursor:pointer;font-size:calc(1rem * var(--voca-rem-multiplier));height:100%;left:0;opacity:0;position:absolute;top:0;width:100%}.telia-date-picker__select select:focus+.telia-date-picker__select-label{box-shadow:0 0 0 calc(0.2rem * var(--voca-rem-multiplier)) #0099ff}.telia-date-picker__select-icon{margin:0 0 0 calc(0.4rem * var(--voca-rem-multiplier))}.telia-date-picker__select-label{font-family:"TeliaSans", Helvetica, Arial, "Lucida Grande", sans-serif;font-weight:bold;font-size:calc(1.6rem * var(--voca-rem-multiplier));color:#222222;border-radius:calc(0.2rem * var(--voca-rem-multiplier));align-items:center;display:flex;line-height:1.25;padding:0 calc(0.4rem * var(--voca-rem-multiplier)) 0 calc(0.8rem * var(--voca-rem-multiplier));pointer-events:none;position:relative;width:100%}.telia-date-picker__mobile{background-color:#fbf0ff;align-items:center;display:flex;justify-content:space-between;overflow:hidden;padding:calc(1.6rem * var(--voca-rem-multiplier)) calc(1.6rem * var(--voca-rem-multiplier));position:relative;text-overflow:ellipsis;white-space:nowrap}@media screen and (min-width: 37.5em){.telia-date-picker__mobile{background-color:transparent;border:0;overflow:visible;padding:0;position:absolute;right:calc(-0.8rem * var(--voca-rem-multiplier));top:calc(-0.8rem * var(--voca-rem-multiplier))}}.telia-date-picker__mobile-heading{color:#29003e;display:inline-block;max-width:84%;overflow:hidden;text-overflow:ellipsis;white-space:nowrap}@media screen and (min-width: 37.5em){.telia-date-picker__mobile-heading{display:none}}.telia-date-picker__close{color:#222222;border-radius:calc(99.9rem * var(--voca-rem-multiplier));align-items:center;-webkit-appearance:none;appearance:none;border:0;cursor:pointer;display:flex;height:calc(2.4rem * var(--voca-rem-multiplier));justify-content:center;padding:0;width:calc(2.4rem * var(--voca-rem-multiplier))}@media screen and (min-width: 37.5em){.telia-date-picker__close{opacity:0}}.telia-date-picker__close:hover{color:#29003e}.telia-date-picker__close:focus{box-shadow:0 0 0 calc(0.3rem * var(--voca-rem-multiplier)) #0099ff;outline:none}@media screen and (min-width: 37.5em){.telia-date-picker__close:focus{opacity:1}}.telia-date-picker__close-icon{margin:0 auto}.telia-date-picker__vhidden{border:0;clip:rect(calc(0.1rem * var(--voca-rem-multiplier)), calc(0.1rem * var(--voca-rem-multiplier)), calc(0.1rem * var(--voca-rem-multiplier)), calc(0.1rem * var(--voca-rem-multiplier)));height:calc(0.1rem * var(--voca-rem-multiplier));overflow:hidden;padding:0;position:absolute;top:0;width:calc(0.1rem * var(--voca-rem-multiplier))}', h = {
|
|
237
|
+
TAB: 9,
|
|
238
|
+
ESC: 27,
|
|
239
|
+
SPACE: 32,
|
|
240
|
+
PAGE_UP: 33,
|
|
241
|
+
PAGE_DOWN: 34,
|
|
242
|
+
END: 35,
|
|
243
|
+
HOME: 36,
|
|
244
|
+
LEFT: 37,
|
|
245
|
+
UP: 38,
|
|
246
|
+
RIGHT: 39,
|
|
247
|
+
DOWN: 40
|
|
248
|
+
};
|
|
249
|
+
function _e(e, t) {
|
|
250
|
+
const a = e.value, r = e.selectionStart, l = a.slice(0, r), s = a.slice(r, a.length), c = l.replace(t, ""), d = s.replace(t, ""), m = c + d, n = c.length;
|
|
251
|
+
return e.value = m, e.selectionStart = e.selectionEnd = n, m;
|
|
252
|
+
}
|
|
253
|
+
const be = /[^0-9\.\/\-]+/g, L = 300, ke = /* @__PURE__ */ q(class extends K {
|
|
254
|
+
constructor() {
|
|
255
|
+
super(), this.__registerHost(), this.vocaChange = F(this, "vocaChange", 7), this.vocaBlur = F(this, "vocaBlur", 7), this.vocaFocus = F(this, "vocaFocus", 7), this.monthSelectId = b("dateMonth"), this.yearSelectId = b("dateYear"), this.dialogLabelId = b("dateLabel"), this.body = document.body, this.initialTouchX = null, this.initialTouchY = null, this.dataTrackingId = "telia-date-picker", this.name = "date", this.additionalId = b("additional"), this.inputId = b("input"), this.disabled = !1, this.direction = "right", this.readonly = !1, this.required = !1, this.value = "", this.min = "", this.max = "", this.yearRange = { past: 10, future: 10 }, this.firstDayOfWeek = k.Monday, this.localization = pe, this.dateAdapter = ve, this.modalOpen = !1, this.isDateDisabled = () => !1, this.errorId = b("error"), this.activeFocus = !1, this.focusedDay = new Date(), this.open = this.modalOpen, this.errorMessageState = "", this.touched = !1, this.enableActiveFocus = () => {
|
|
256
|
+
this.activeFocus = !0;
|
|
257
|
+
}, this.disableActiveFocus = () => {
|
|
258
|
+
this.activeFocus = !1;
|
|
259
|
+
}, this.toggleOpen = (e) => {
|
|
260
|
+
e.preventDefault(), this.open ? this.hide(!1) : this.show();
|
|
261
|
+
}, this.handleEscKey = (e) => {
|
|
262
|
+
e.keyCode === h.ESC && this.hide();
|
|
263
|
+
}, this.handleBlur = (e) => {
|
|
264
|
+
e.stopPropagation(), this.updateErrorState(), this.vocaBlur.emit({
|
|
265
|
+
component: "telia-date-picker"
|
|
266
|
+
});
|
|
267
|
+
}, this.handleFocus = (e) => {
|
|
268
|
+
e.stopPropagation(), this.vocaFocus.emit({
|
|
269
|
+
component: "telia-date-picker"
|
|
270
|
+
});
|
|
271
|
+
}, this.handleTouchStart = (e) => {
|
|
272
|
+
const t = e.changedTouches[0];
|
|
273
|
+
this.initialTouchX = t.pageX, this.initialTouchY = t.pageY;
|
|
274
|
+
}, this.handleTouchEnd = (e) => {
|
|
275
|
+
const t = e.changedTouches[0], a = t.pageX - this.initialTouchX, r = t.pageY - this.initialTouchY, l = 70, s = Math.abs(a) >= l && Math.abs(r) <= l, c = Math.abs(r) >= l && Math.abs(a) <= l && r > 0;
|
|
276
|
+
s ? this.addMonths(a < 0 ? 1 : -1) : c && (this.hide(!1), e.preventDefault()), this.initialTouchY = null, this.initialTouchX = null;
|
|
277
|
+
}, this.handleNextMonthClick = (e) => {
|
|
278
|
+
e.preventDefault(), this.addMonths(1);
|
|
279
|
+
}, this.handlePreviousMonthClick = (e) => {
|
|
280
|
+
e.preventDefault(), this.addMonths(-1);
|
|
281
|
+
}, this.handleFirstFocusableKeydown = (e) => {
|
|
282
|
+
e.keyCode === h.TAB && e.shiftKey && (this.focusedDayNode.focus(), e.preventDefault());
|
|
283
|
+
}, this.handleCloseButtonClick = () => {
|
|
284
|
+
this.hide();
|
|
285
|
+
}, this.handleKeyboardNavigation = (e) => {
|
|
286
|
+
if (e.keyCode === h.TAB && !e.shiftKey) {
|
|
287
|
+
e.preventDefault(), this.firstFocusableElement.focus();
|
|
288
|
+
return;
|
|
289
|
+
}
|
|
290
|
+
var t = !0;
|
|
291
|
+
switch (e.keyCode) {
|
|
292
|
+
case h.RIGHT:
|
|
293
|
+
this.addDays(1);
|
|
294
|
+
break;
|
|
295
|
+
case h.LEFT:
|
|
296
|
+
this.addDays(-1);
|
|
297
|
+
break;
|
|
298
|
+
case h.DOWN:
|
|
299
|
+
this.addDays(7);
|
|
300
|
+
break;
|
|
301
|
+
case h.UP:
|
|
302
|
+
this.addDays(-7);
|
|
303
|
+
break;
|
|
304
|
+
case h.PAGE_UP:
|
|
305
|
+
e.shiftKey ? this.addYears(-1) : this.addMonths(-1);
|
|
306
|
+
break;
|
|
307
|
+
case h.PAGE_DOWN:
|
|
308
|
+
e.shiftKey ? this.addYears(1) : this.addMonths(1);
|
|
309
|
+
break;
|
|
310
|
+
case h.HOME:
|
|
311
|
+
this.startOfWeek();
|
|
312
|
+
break;
|
|
313
|
+
case h.END:
|
|
314
|
+
this.endOfWeek();
|
|
315
|
+
break;
|
|
316
|
+
default:
|
|
317
|
+
t = !1;
|
|
318
|
+
}
|
|
319
|
+
t && (e.preventDefault(), this.enableActiveFocus());
|
|
320
|
+
}, this.handleDaySelect = (e, t) => {
|
|
321
|
+
const a = C(t, p(this.min), p(this.max)), r = !this.isDateDisabled(t);
|
|
322
|
+
a && r ? (this.setValue(t), this.hide()) : this.setFocusedDay(t);
|
|
323
|
+
}, this.handleMonthSelect = (e) => {
|
|
324
|
+
e.stopPropagation(), this.setMonth(parseInt(e.target.value, 10));
|
|
325
|
+
}, this.handleYearSelect = (e) => {
|
|
326
|
+
e.stopPropagation(), this.setYear(parseInt(e.target.value, 10));
|
|
327
|
+
}, this.handleInputChange = () => {
|
|
328
|
+
const e = this.datePickerInput;
|
|
329
|
+
_e(e, be);
|
|
330
|
+
const t = this.dateAdapter.parse(e.value, S);
|
|
331
|
+
(t || e.value === "") && this.setValue(t);
|
|
332
|
+
}, this.processFocusedDayNode = (e) => {
|
|
333
|
+
this.focusedDayNode = e, this.activeFocus && this.open && setTimeout(() => e.focus(), 0);
|
|
334
|
+
}, this.makeTouched = () => {
|
|
335
|
+
this.touched = !0;
|
|
336
|
+
}, this.isValueValid = () => {
|
|
337
|
+
const e = this.datePickerInput.value, t = this.dateAdapter.parse(e, S);
|
|
338
|
+
return t === void 0 || !C(t, p(this.min), p(this.max)) ? !1 : !this.isDateDisabled(t);
|
|
339
|
+
}, this.updateErrorMessage = (e) => {
|
|
340
|
+
var t;
|
|
341
|
+
(t = this.datePickerInput) === null || t === void 0 || t.setCustomValidity(e), this.errorMessageState = e;
|
|
342
|
+
}, this.isValueMissing = () => {
|
|
343
|
+
var e;
|
|
344
|
+
return ((e = this.datePickerInput) === null || e === void 0 ? void 0 : e.value.length) === 0;
|
|
345
|
+
}, this.updateErrorState = () => {
|
|
346
|
+
var e, t, a;
|
|
347
|
+
const r = !!(!((e = this.errorMessageState) === null || e === void 0) && e.length), l = this.required, s = !!(!((t = this.errorMessage) === null || t === void 0) && t.length), c = !!(!((a = this.invalidErrorMessage) === null || a === void 0) && a.length), d = !!this.datePickerInput;
|
|
348
|
+
if (s) {
|
|
349
|
+
this.updateErrorMessage(this.errorMessage), this.makeTouched();
|
|
350
|
+
return;
|
|
351
|
+
}
|
|
352
|
+
if (c && d && !this.isValueValid() && this.updateErrorMessage(this.invalidErrorMessage), l && this.touched && !!this.requiredErrorMessage && this.isValueMissing() && this.updateErrorMessage(this.requiredErrorMessage), r) {
|
|
353
|
+
if (s || c && !this.isValueValid())
|
|
354
|
+
return;
|
|
355
|
+
this.updateErrorMessage("");
|
|
356
|
+
}
|
|
357
|
+
}, this.setToggleRef = (e) => this.datePickerButton = e, this.setTextInputRef = (e) => this.datePickerInput = e, this.setDialogWrapperRef = (e) => this.dialogWrapperNode = e, this.setCloseButtonRef = (e) => this.firstFocusableElement = e, this.setMonthSelectRef = (e) => this.monthSelectNode = e;
|
|
358
|
+
}
|
|
359
|
+
connectedCallback() {
|
|
360
|
+
this.createDateFormatters();
|
|
361
|
+
}
|
|
362
|
+
componentWillLoad() {
|
|
363
|
+
this.updateErrorState(), this.yearRangeChanged(this.yearRange);
|
|
364
|
+
}
|
|
365
|
+
componentDidRender() {
|
|
366
|
+
var e, t;
|
|
367
|
+
this.datePickerInput && ((e = this.datePickerInput) === null || e === void 0 ? void 0 : e.setCustomValidity) && ((t = this.datePickerInput) === null || t === void 0 || t.setCustomValidity(this.errorMessageState));
|
|
368
|
+
}
|
|
369
|
+
yearRangeChanged(e) {
|
|
370
|
+
let t = typeof e == "string" ? JSON.parse(e) : e;
|
|
371
|
+
Object.keys(t).map((a) => {
|
|
372
|
+
t[a] = parseInt(t[a]), t[a] = t[a] < 0 ? t[a] = 0 : t[a];
|
|
373
|
+
}), this.range = t;
|
|
374
|
+
}
|
|
375
|
+
createDateFormatters() {
|
|
376
|
+
this.dateFormatShort = new Intl.DateTimeFormat(this.localization.locale, {
|
|
377
|
+
day: "numeric",
|
|
378
|
+
month: "long"
|
|
379
|
+
}), this.dateFormatLong = new Intl.DateTimeFormat(this.localization.locale, {
|
|
380
|
+
day: "numeric",
|
|
381
|
+
month: "long",
|
|
382
|
+
year: "numeric"
|
|
383
|
+
});
|
|
384
|
+
}
|
|
385
|
+
handleDocumentClick(e) {
|
|
386
|
+
if (!this.open)
|
|
387
|
+
return;
|
|
388
|
+
e.composedPath().every((a) => a !== this.dialogWrapperNode && a !== this.datePickerButton) && this.hide(!1);
|
|
389
|
+
}
|
|
390
|
+
async setFocus() {
|
|
391
|
+
return this.datePickerInput.focus();
|
|
392
|
+
}
|
|
393
|
+
async show() {
|
|
394
|
+
this.open = !0, this.modalOpen = !0, this.setFocusedDay(p(this.value) || new Date());
|
|
395
|
+
let { matches: e } = window.matchMedia("(max-width: 600px)");
|
|
396
|
+
e && (this.body.style.overflowY = "hidden", this.body.style.position = "fixed", this.body.style.width = "100%"), clearTimeout(this.focusTimeoutId), this.focusTimeoutId = setTimeout(() => this.monthSelectNode.focus(), L);
|
|
397
|
+
}
|
|
398
|
+
async hide(e = !0) {
|
|
399
|
+
this.open = !1, this.modalOpen = !1, this.body.style.overflowY === "hidden" && this.body.style.position === "fixed" && (this.body.style.overflowY = "", this.body.style.position = "", this.body.style.width = ""), clearTimeout(this.focusTimeoutId), e && setTimeout(() => this.datePickerButton.focus(), L + 200);
|
|
400
|
+
}
|
|
401
|
+
addDays(e) {
|
|
402
|
+
this.setFocusedDay(z(this.focusedDay, e));
|
|
403
|
+
}
|
|
404
|
+
addMonths(e) {
|
|
405
|
+
this.setMonth(this.focusedDay.getMonth() + e);
|
|
406
|
+
}
|
|
407
|
+
addYears(e) {
|
|
408
|
+
this.setYear(this.focusedDay.getFullYear() + e);
|
|
409
|
+
}
|
|
410
|
+
startOfWeek() {
|
|
411
|
+
this.setFocusedDay(P(this.focusedDay, this.firstDayOfWeek));
|
|
412
|
+
}
|
|
413
|
+
endOfWeek() {
|
|
414
|
+
this.setFocusedDay(R(this.focusedDay, this.firstDayOfWeek));
|
|
415
|
+
}
|
|
416
|
+
setMonth(e) {
|
|
417
|
+
const t = H(w(this.focusedDay), e), a = D(t), r = H(this.focusedDay, e);
|
|
418
|
+
this.setFocusedDay(M(r, t, a));
|
|
419
|
+
}
|
|
420
|
+
setYear(e) {
|
|
421
|
+
const t = Y(w(this.focusedDay), e), a = D(t), r = Y(this.focusedDay, e);
|
|
422
|
+
this.setFocusedDay(M(r, t, a));
|
|
423
|
+
}
|
|
424
|
+
setFocusedDay(e) {
|
|
425
|
+
this.focusedDay = M(e, p(this.min), p(this.max));
|
|
426
|
+
}
|
|
427
|
+
setValue(e) {
|
|
428
|
+
this.value = V(e), this.vocaChange.emit({
|
|
429
|
+
component: "telia-date-picker",
|
|
430
|
+
value: this.value,
|
|
431
|
+
valueAsDate: e
|
|
432
|
+
});
|
|
433
|
+
}
|
|
434
|
+
render() {
|
|
435
|
+
var e;
|
|
436
|
+
const t = !!this.additional, a = !!(!((e = this.errorMessageState) === null || e === void 0) && e.length), r = j({
|
|
437
|
+
[this.additionalId]: t,
|
|
438
|
+
[this.errorId]: a
|
|
439
|
+
}), l = p(this.value), s = l && this.dateAdapter.format(l), c = (l || this.focusedDay).getFullYear(), d = this.focusedDay.getMonth(), m = this.focusedDay.getFullYear(), n = p(this.min), u = p(this.max), _ = n !== void 0 && n.getMonth() === d && n.getFullYear() === m, f = u !== void 0 && u.getMonth() === d && u.getFullYear() === m, g = n !== void 0 ? n.getFullYear() : c - this.range.past, v = u !== void 0 ? u.getFullYear() : c + this.range.future;
|
|
440
|
+
return i($, null, i("telia-vst", { dataTrackingId: this.dataTrackingId }), i("div", { class: "telia-date-picker" }, i(ne, { dateFormatter: this.dateFormatLong, describedBy: r, value: this.value, valueAsDate: l, formattedValue: s, onInput: this.handleInputChange, onBlur: this.handleBlur, onFocus: this.handleFocus, onClick: this.toggleOpen, name: this.name, disabled: this.disabled, readonly: this.readonly, role: this.role, required: this.required, identifier: this.inputId, localization: this.localization, buttonLabel: this.buttonLabel, buttonRef: this.setToggleRef, inputRef: this.setTextInputRef, touched: this.touched, makeTouched: this.makeTouched, htmlForm: this.htmlForm }), i("telia-label", { class: "telia-date-picker__label", htmlFor: this.inputId }, this.required && i("span", { "aria-hidden": "true" }, "* "), this.label), t && i("telia-field-assistive-text", { class: "telia-date-picker__additional", id: this.additionalId }, this.additional), a && i("telia-field-error", { class: "telia-date-picker__error", id: this.errorId }, this.errorMessageState), i("div", { class: "telia-date-picker__dialog-container" }, i("div", { class: {
|
|
441
|
+
"telia-date-picker__dialog": !0,
|
|
442
|
+
"is-left": this.direction === "left",
|
|
443
|
+
"is-active": this.open
|
|
444
|
+
}, role: "dialog", "aria-modal": "true", "aria-hidden": this.open ? "false" : "true", "aria-labelledby": this.dialogLabelId, onTouchStart: this.handleTouchStart, onTouchEnd: this.handleTouchEnd }, i("div", { class: "telia-date-picker__dialog-content", onKeyDown: this.handleEscKey, ref: this.setDialogWrapperRef }, i("div", { class: "telia-date-picker__mobile", onFocusin: this.disableActiveFocus }, i("telia-heading", { tag: "h2", class: "telia-date-picker__mobile-heading", variant: "subsection-100" }, this.localization.calendarHeading), i("button", { class: "telia-date-picker__close", ref: this.setCloseButtonRef, onKeyDown: this.handleFirstFocusableKeydown, onClick: this.handleCloseButtonClick, type: "button" }, i("telia-icon", { class: "telia-date-picker__close-icon", svg: J.svg, size: "sm" }), i("span", { class: "telia-date-picker__vhidden" }, this.localization.closeLabel))), i("div", { class: "telia-date-picker__header", onFocusin: this.disableActiveFocus }, i("div", null, i("h2", { id: this.dialogLabelId, class: "telia-date-picker__vhidden", "aria-live": "polite", "aria-atomic": "true" }, this.localization.monthNames[d], " ", this.focusedDay.getFullYear()), i("label", { htmlFor: this.monthSelectId, class: "telia-date-picker__vhidden" }, this.localization.monthSelectLabel), i("div", { class: "telia-date-picker__select" }, i("select", { id: this.monthSelectId, class: "telia-date-picker__select--month", ref: this.setMonthSelectRef, onChange: this.handleMonthSelect, onInput: (o) => {
|
|
445
|
+
o.stopPropagation();
|
|
446
|
+
} }, this.localization.monthNames.map((o, y) => i("option", { key: o, value: y, selected: y === d, disabled: !C(new Date(m, y, 1), n !== void 0 ? w(n) : null, u !== void 0 ? D(u) : null) }, o))), i("div", { class: "telia-date-picker__select-label", "aria-hidden": "true" }, i("span", null, this.localization.monthNamesShort[d]), i("telia-icon", { class: "telia-date-picker__select-icon", svg: E.svg, size: "sm" }))), i("label", { htmlFor: this.yearSelectId, class: "telia-date-picker__vhidden" }, this.localization.yearSelectLabel), i("div", { class: "telia-date-picker__select" }, i("select", { id: this.yearSelectId, class: "telia-date-picker__select--year", onChange: this.handleYearSelect, onInput: (o) => {
|
|
447
|
+
o.stopPropagation();
|
|
448
|
+
} }, fe(g, v).map((o) => i("option", { key: o, selected: o === m }, o))), i("div", { class: "telia-date-picker__select-label", "aria-hidden": "true" }, i("span", null, this.focusedDay.getFullYear()), i("telia-icon", { class: "telia-date-picker__select-icon", svg: E.svg, size: "sm" })))), i("div", { class: "telia-date-picker__nav" }, i("button", { class: "telia-date-picker__prev", onClick: this.handlePreviousMonthClick, disabled: _, type: "button" }, i("telia-icon", { class: "telia-date-picker__prev-icon", svg: le.svg, size: "sm" }), i("span", { class: "telia-date-picker__vhidden" }, this.localization.prevMonthLabel)), i("button", { class: "telia-date-picker__next", onClick: this.handleNextMonthClick, disabled: f, type: "button" }, i("telia-icon", { class: "telia-date-picker__next-icon", svg: ie.svg, size: "sm" }), i("span", { class: "telia-date-picker__vhidden" }, this.localization.nextMonthLabel)))), i(he, { dateFormatter: this.dateFormatShort, selectedDate: l, focusedDate: this.focusedDay, onDateSelect: this.handleDaySelect, onKeyboardNavigation: this.handleKeyboardNavigation, labelledById: this.dialogLabelId, localization: this.localization, firstDayOfWeek: this.firstDayOfWeek, focusedDayRef: this.processFocusedDayNode, min: n, max: u, isDateDisabled: this.isDateDisabled }))))));
|
|
449
|
+
}
|
|
450
|
+
get element() {
|
|
451
|
+
return this;
|
|
452
|
+
}
|
|
453
|
+
static get watchers() {
|
|
454
|
+
return {
|
|
455
|
+
yearRange: ["yearRangeChanged"],
|
|
456
|
+
localization: ["createDateFormatters"]
|
|
457
|
+
};
|
|
458
|
+
}
|
|
459
|
+
static get style() {
|
|
460
|
+
return ge;
|
|
461
|
+
}
|
|
462
|
+
}, [0, "telia-date-picker", {
|
|
463
|
+
dataTestid: [1, "data-testid"],
|
|
464
|
+
htmlForm: [1, "html-form"],
|
|
465
|
+
name: [1],
|
|
466
|
+
label: [1],
|
|
467
|
+
additional: [1],
|
|
468
|
+
additionalId: [1, "additional-id"],
|
|
469
|
+
inputId: [1, "input-id"],
|
|
470
|
+
disabled: [516],
|
|
471
|
+
role: [1],
|
|
472
|
+
buttonLabel: [1, "button-label"],
|
|
473
|
+
direction: [1],
|
|
474
|
+
readonly: [4],
|
|
475
|
+
required: [4],
|
|
476
|
+
value: [1537],
|
|
477
|
+
min: [1],
|
|
478
|
+
max: [1],
|
|
479
|
+
yearRange: [1, "year-range"],
|
|
480
|
+
firstDayOfWeek: [2, "first-day-of-week"],
|
|
481
|
+
localization: [16],
|
|
482
|
+
dateAdapter: [16],
|
|
483
|
+
modalOpen: [1540, "modal-open"],
|
|
484
|
+
isDateDisabled: [16],
|
|
485
|
+
errorId: [1, "error-id"],
|
|
486
|
+
errorMessage: [1, "error-message"],
|
|
487
|
+
invalidErrorMessage: [1, "invalid-error-message"],
|
|
488
|
+
requiredErrorMessage: [1, "required-error-message"],
|
|
489
|
+
activeFocus: [32],
|
|
490
|
+
focusedDay: [32],
|
|
491
|
+
open: [32],
|
|
492
|
+
errorMessageState: [32],
|
|
493
|
+
touched: [32],
|
|
494
|
+
setFocus: [64],
|
|
495
|
+
show: [64],
|
|
496
|
+
hide: [64]
|
|
497
|
+
}, [[6, "click", "handleDocumentClick"]]]);
|
|
498
|
+
function ye() {
|
|
499
|
+
if (typeof customElements > "u")
|
|
500
|
+
return;
|
|
501
|
+
["telia-date-picker", "telia-field-assistive-text", "telia-field-error", "telia-heading", "telia-icon", "telia-label", "telia-vst"].forEach((t) => {
|
|
502
|
+
switch (t) {
|
|
503
|
+
case "telia-date-picker":
|
|
504
|
+
customElements.get(t) || customElements.define(t, ke);
|
|
505
|
+
break;
|
|
506
|
+
case "telia-field-assistive-text":
|
|
507
|
+
customElements.get(t) || U();
|
|
508
|
+
break;
|
|
509
|
+
case "telia-field-error":
|
|
510
|
+
customElements.get(t) || X();
|
|
511
|
+
break;
|
|
512
|
+
case "telia-heading":
|
|
513
|
+
customElements.get(t) || Q();
|
|
514
|
+
break;
|
|
515
|
+
case "telia-icon":
|
|
516
|
+
customElements.get(t) || ee();
|
|
517
|
+
break;
|
|
518
|
+
case "telia-label":
|
|
519
|
+
customElements.get(t) || te();
|
|
520
|
+
break;
|
|
521
|
+
case "telia-vst":
|
|
522
|
+
customElements.get(t) || ae();
|
|
523
|
+
break;
|
|
524
|
+
}
|
|
525
|
+
});
|
|
526
|
+
}
|
|
527
|
+
ye();
|
|
528
|
+
//# sourceMappingURL=telia-date-picker.js.map
|