@eunomia/elements 1.0.0-beta.4 → 1.0.0-beta.6
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/README.md +1 -1
- package/dist/breakpoints.d.ts +37 -10
- package/dist/breakpoints.js +38 -10
- package/dist/cdn/components/chunks/{chunk-MMLIPCOY.js → chunk-22D3SRFR.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-4MXL6PZC.js → chunk-2Y2EU2CI.js} +28 -28
- package/dist/cdn/components/chunks/chunk-3MTUVMM5.js +1 -0
- package/dist/cdn/components/chunks/chunk-4PI6RDUS.js +1 -0
- package/dist/cdn/components/chunks/chunk-5GKM5DIB.js +1 -0
- package/dist/cdn/components/chunks/chunk-624VJYNA.js +1 -0
- package/dist/cdn/components/chunks/{chunk-5XJLIHAU.js → chunk-7KKWYPHY.js} +4 -2
- package/dist/cdn/components/chunks/chunk-A3X4KD2X.js +1 -0
- package/dist/cdn/components/chunks/chunk-BKZGTCMF.js +1 -0
- package/dist/cdn/components/chunks/{chunk-GW3VP2L7.js → chunk-BO3JOEWM.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-NHFWATVN.js → chunk-BQFJR2UP.js} +5 -5
- package/dist/cdn/components/chunks/chunk-EUWUDCBZ.js +1 -0
- package/dist/cdn/components/chunks/{chunk-P32B7BFD.js → chunk-FF3I7C3C.js} +15 -15
- package/dist/cdn/components/chunks/{chunk-74AOAB4X.js → chunk-FOILAXLL.js} +6 -5
- package/dist/cdn/components/chunks/{chunk-E4IS25H7.js → chunk-G5SBDQQ3.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-LGLQ36QB.js → chunk-GDBPWZN6.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-S2UCEWNG.js → chunk-JYIIWN2P.js} +13 -11
- package/dist/cdn/components/chunks/{chunk-EOWBYZV7.js → chunk-KDN4O5W2.js} +26 -13
- package/dist/cdn/components/chunks/chunk-KSZRQRN4.js +1 -0
- package/dist/cdn/components/chunks/{chunk-PED5ATYN.js → chunk-L2ADCEN7.js} +1 -1
- package/dist/cdn/components/chunks/chunk-LMVW522V.js +1 -0
- package/dist/cdn/components/chunks/{chunk-5XJGYXW7.js → chunk-MOMYII3P.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-SIHZFOTK.js → chunk-MQQ4BGVJ.js} +5 -5
- package/dist/cdn/components/chunks/{chunk-A4EQSU36.js → chunk-O7PHBLH2.js} +1 -1
- package/dist/cdn/components/chunks/chunk-PD62MBOJ.js +1 -0
- package/dist/cdn/components/chunks/{chunk-KBH5PCUO.js → chunk-PE4DAXHQ.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-GSJEJLFA.js → chunk-PMPSJG5V.js} +7 -7
- package/dist/cdn/components/chunks/{chunk-5EVP7YNE.js → chunk-PPCHQG7P.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-EJIX2D4Z.js → chunk-QZ5SHR3I.js} +15 -11
- package/dist/cdn/components/chunks/chunk-RS7TWEMQ.js +1 -0
- package/dist/cdn/components/chunks/chunk-SMTIDNGW.js +1 -0
- package/dist/cdn/components/chunks/{chunk-YGUJJ25C.js → chunk-SZYEBMG6.js} +11 -10
- package/dist/cdn/components/chunks/chunk-UDVB4LAE.js +56 -0
- package/dist/cdn/components/chunks/{chunk-UAGCQF23.js → chunk-UYZR4JXZ.js} +17 -12
- package/dist/cdn/components/chunks/chunk-VG6NAAIV.js +1 -0
- package/dist/cdn/components/chunks/chunk-VJCNHMQZ.js +10 -0
- package/dist/cdn/components/chunks/chunk-VOTRXBDS.js +38 -0
- package/dist/cdn/components/chunks/{chunk-BMQOI7HX.js → chunk-VYFR364B.js} +128 -74
- package/dist/cdn/components/chunks/{chunk-IJ5WFMK4.js → chunk-XDPRWUKN.js} +7 -6
- package/dist/cdn/components/chunks/{chunk-XH6NREVZ.js → chunk-YITWLCD3.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-BQHYZB2W.js → chunk-ZBN4HTWP.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-RJCJXB7Y.js → chunk-ZKZV2YG5.js} +18 -18
- package/dist/cdn/components/eun-alert.js +24 -16
- package/dist/cdn/components/eun-animate.js +12 -6
- package/dist/cdn/components/eun-badge.js +7 -7
- package/dist/cdn/components/eun-breadcrumb.js +25 -41
- package/dist/cdn/components/eun-button.js +1 -1
- package/dist/cdn/components/eun-calendar.js +68 -66
- package/dist/cdn/components/eun-card.js +67 -13
- package/dist/cdn/components/eun-carousel.js +66 -35
- package/dist/cdn/components/eun-check-card.js +13 -6
- package/dist/cdn/components/eun-checkbox-list.js +4 -4
- package/dist/cdn/components/eun-checkbox.js +1 -1
- package/dist/cdn/components/eun-chip.js +1 -1
- package/dist/cdn/components/eun-collapse.js +87 -39
- package/dist/cdn/components/eun-color-picker.js +54 -53
- package/dist/cdn/components/eun-counter.js +14 -13
- package/dist/cdn/components/eun-date-picker.js +66 -63
- package/dist/cdn/components/eun-description-list.js +152 -0
- package/dist/cdn/components/eun-divider.js +1 -1
- package/dist/cdn/components/eun-drawer.js +26 -12
- package/dist/cdn/components/eun-dropdown-button.js +1 -1
- package/dist/cdn/components/eun-dropdown-item.js +6 -5
- package/dist/cdn/components/eun-fab.js +20 -19
- package/dist/cdn/components/eun-icon.js +1 -1
- package/dist/cdn/components/eun-image-card.js +79 -22
- package/dist/cdn/components/eun-image-carousel.js +92 -47
- package/dist/cdn/components/eun-infinite-list.js +23 -11
- package/dist/cdn/components/eun-input-file.js +14 -13
- package/dist/cdn/components/eun-input-phone.js +26 -26
- package/dist/cdn/components/eun-input.js +1 -1
- package/dist/cdn/components/eun-label.js +4 -4
- package/dist/cdn/components/eun-link.js +174 -27
- package/dist/cdn/components/eun-loader.js +1 -1
- package/dist/cdn/components/eun-modal.js +29 -22
- package/dist/cdn/components/eun-pagination.js +17 -12
- package/dist/cdn/components/eun-password-strength.js +6 -2
- package/dist/cdn/components/eun-progress-bar.js +13 -5
- package/dist/cdn/components/eun-radio-card.js +16 -9
- package/dist/cdn/components/eun-radio-list.js +4 -4
- package/dist/cdn/components/eun-radio.js +1 -1
- package/dist/cdn/components/eun-scheduler-event-editor.js +8 -8
- package/dist/cdn/components/eun-scheduler-event.js +1 -1
- package/dist/cdn/components/eun-scheduler.js +42 -42
- package/dist/cdn/components/eun-search.js +21 -20
- package/dist/cdn/components/eun-select.js +12 -11
- package/dist/cdn/components/eun-sidebar.js +34 -20
- package/dist/cdn/components/eun-skeleton.js +1 -1
- package/dist/cdn/components/eun-slider.js +15 -14
- package/dist/cdn/components/eun-sliding-card.js +8 -4
- package/dist/cdn/components/eun-step.js +17 -6
- package/dist/cdn/components/eun-stepper.js +17 -6
- package/dist/cdn/components/eun-switch.js +10 -8
- package/dist/cdn/components/eun-tab-group.js +22 -17
- package/dist/cdn/components/eun-tab-panel.js +11 -3
- package/dist/cdn/components/eun-tab.js +1 -1
- package/dist/cdn/components/eun-table-action-bar.js +1 -1
- package/dist/cdn/components/eun-table.js +572 -31
- package/dist/cdn/components/eun-tag.js +13 -7
- package/dist/cdn/components/eun-textarea.js +24 -24
- package/dist/cdn/components/eun-time-picker.js +21 -19
- package/dist/cdn/components/eun-toast.js +36 -16
- package/dist/cdn/components/eun-toggle-group.js +64 -37
- package/dist/cdn/components/eun-toggle-item.js +24 -21
- package/dist/cdn/components/eun-toggle.js +12 -10
- package/dist/cdn/components/eun-toolbar.js +62 -52
- package/dist/cdn/components/eun-tooltip.js +30 -14
- package/dist/cdn/styles/breakpoints.scss +8 -0
- package/dist/cdn/styles/eunomia-grid.scss +6 -0
- package/dist/cdn/styles/eunomia-themes.css +1 -1
- package/dist/cdn/styles/themes/eunomia-theme.css +1 -1
- package/dist/cdn/styles/themes/eunomia-theme.scss +4 -3
- package/dist/cdn/styles/themes/mixins/eunomia-a11y-color.mixin.scss +34 -1
- package/dist/cdn/styles/themes/mixins/eunomia-neutrals.mixin.scss +4 -0
- package/dist/cdn/styles/themes/mixins/eunomia-states.mixin.scss +36 -12
- package/dist/cdn/styles/themes/prebuilt-themes/eunomia/eunomia-dark.mixin.scss +10 -10
- package/dist/cdn/styles/themes/prebuilt-themes/eunomia/eunomia.mixin.scss +10 -10
- package/dist/cdn/styles/themes/prebuilt-themes/eunomia/eunomia.theme.css +1 -1
- package/dist/cdn/styles/themes/prebuilt-themes/eunomia/eunomia.theme.scss +3 -2
- package/dist/cdn/styles/themes/prebuilt-themes/fire/eunomia-fire-dark.mixin.scss +10 -10
- package/dist/cdn/styles/themes/prebuilt-themes/fire/eunomia-fire.mixin.scss +10 -10
- package/dist/cdn/styles/themes/prebuilt-themes/fire/eunomia-fire.theme.css +1 -1
- package/dist/cdn/styles/themes/prebuilt-themes/fire/eunomia-fire.theme.scss +3 -2
- package/dist/cdn/styles/themes/prebuilt-themes/forest/eunomia-forest-dark.mixin.scss +10 -10
- package/dist/cdn/styles/themes/prebuilt-themes/forest/eunomia-forest.mixin.scss +10 -10
- package/dist/cdn/styles/themes/prebuilt-themes/forest/eunomia-forest.theme.css +1 -1
- package/dist/cdn/styles/themes/prebuilt-themes/forest/eunomia-forest.theme.scss +3 -2
- package/dist/cdn/styles/themes/prebuilt-themes/gold/eunomia-gold-dark.mixin.scss +10 -10
- package/dist/cdn/styles/themes/prebuilt-themes/gold/eunomia-gold.mixin.scss +10 -10
- package/dist/cdn/styles/themes/prebuilt-themes/gold/eunomia-gold.theme.css +1 -1
- package/dist/cdn/styles/themes/prebuilt-themes/gold/eunomia-gold.theme.scss +3 -2
- package/dist/cdn/styles/themes/prebuilt-themes/ocean/eunomia-ocean-dark.mixin.scss +10 -10
- package/dist/cdn/styles/themes/prebuilt-themes/ocean/eunomia-ocean.mixin.scss +10 -10
- package/dist/cdn/styles/themes/prebuilt-themes/ocean/eunomia-ocean.theme.css +1 -1
- package/dist/cdn/styles/themes/prebuilt-themes/ocean/eunomia-ocean.theme.scss +3 -2
- package/dist/cdn/styles/themes/prebuilt-themes/salmon/eunomia-salmon-dark.mixin.scss +10 -10
- package/dist/cdn/styles/themes/prebuilt-themes/salmon/eunomia-salmon.mixin.scss +10 -10
- package/dist/cdn/styles/themes/prebuilt-themes/salmon/eunomia-salmon.theme.css +1 -1
- package/dist/cdn/styles/themes/prebuilt-themes/salmon/eunomia-salmon.theme.scss +3 -2
- package/dist/cdn/styles/themes/prebuilt-themes/violet/eunomia-violet-dark.mixin.scss +10 -10
- package/dist/cdn/styles/themes/prebuilt-themes/violet/eunomia-violet.mixin.scss +10 -10
- package/dist/cdn/styles/themes/prebuilt-themes/violet/eunomia-violet.theme.css +1 -1
- package/dist/cdn/styles/themes/prebuilt-themes/violet/eunomia-violet.theme.scss +3 -2
- package/dist/cdn/styles/tools/indexes/eunomia-media-queries.index.scss +1 -3
- package/dist/cdn/styles/tools/indexes/eunomia-tools.index.scss +1 -0
- package/dist/cdn/styles/tools/mixins/layout/eunomia-grid.mixin.scss +117 -53
- package/dist/cdn/styles/tools/mixins/media-queries/eunomia-media-queries.mixin.scss +69 -0
- package/dist/cdn/styles/tools/mixins/settings/eunomia-alpha.mixin.scss +28 -4
- package/dist/cdn/styles/tools/mixins/settings/eunomia-motion.mixin.scss +9 -0
- package/dist/cdn/styles/tools/variables/eunomia.breakpoints.scss +4 -0
- package/dist/components/action/button/button.d.ts +51 -19
- package/dist/components/action/button/button.js +107 -24
- package/dist/components/action/button/button.styles.js +115 -62
- package/dist/components/action/dropdown-button/dropdown-button.d.ts +10 -10
- package/dist/components/action/dropdown-button/dropdown-button.js +18 -17
- package/dist/components/action/dropdown-button/dropdown-button.styles.js +3 -2
- package/dist/components/action/dropdown-button/dropdown-item.js +5 -6
- package/dist/components/action/dropdown-button/dropdown-item.styles.js +3 -2
- package/dist/components/action/fab/fab.d.ts +7 -6
- package/dist/components/action/fab/fab.js +11 -8
- package/dist/components/action/fab/fab.styles.js +18 -17
- package/dist/components/action/link/link.d.ts +72 -9
- package/dist/components/action/link/link.js +183 -23
- package/dist/components/action/link/link.styles.js +146 -10
- package/dist/components/action/shared-styles/button-palette.styles.d.ts +3 -3
- package/dist/components/action/shared-styles/button-palette.styles.js +29 -29
- package/dist/components/action/toggle/toggle-group.d.ts +17 -5
- package/dist/components/action/toggle/toggle-group.js +46 -19
- package/dist/components/action/toggle/toggle-group.styles.d.ts +4 -1
- package/dist/components/action/toggle/toggle-group.styles.js +56 -27
- package/dist/components/action/toggle/toggle-item.d.ts +4 -4
- package/dist/components/action/toggle/toggle-item.js +2 -2
- package/dist/components/action/toggle/toggle-item.styles.js +20 -17
- package/dist/components/action/toggle/toggle.d.ts +2 -0
- package/dist/components/action/toggle/toggle.js +2 -0
- package/dist/components/action/toggle/toggle.styles.d.ts +2 -0
- package/dist/components/action/toggle/toggle.styles.js +12 -8
- package/dist/components/alert/alert/alert.d.ts +2 -0
- package/dist/components/alert/alert/alert.js +2 -0
- package/dist/components/alert/alert/alert.styles.js +23 -13
- package/dist/components/alert/drawer/drawer.d.ts +3 -1
- package/dist/components/alert/drawer/drawer.js +5 -3
- package/dist/components/alert/drawer/drawer.styles.js +25 -9
- package/dist/components/alert/modal/modal.d.ts +11 -9
- package/dist/components/alert/modal/modal.js +15 -13
- package/dist/components/alert/modal/modal.styles.js +16 -7
- package/dist/components/alert/toast/toast.d.ts +2 -0
- package/dist/components/alert/toast/toast.js +2 -0
- package/dist/components/alert/toast/toast.styles.js +37 -15
- package/dist/components/content/badge/badge.d.ts +6 -6
- package/dist/components/content/badge/badge.js +4 -4
- package/dist/components/content/badge/badge.styles.js +4 -4
- package/dist/components/content/card/card.d.ts +39 -7
- package/dist/components/content/card/card.js +71 -7
- package/dist/components/content/card/card.styles.js +58 -11
- package/dist/components/content/card/image-card.d.ts +62 -7
- package/dist/components/content/card/image-card.js +121 -11
- package/dist/components/content/card/image-card.styles.js +66 -15
- package/dist/components/content/card/sliding-card.d.ts +4 -1
- package/dist/components/content/card/sliding-card.js +3 -0
- package/dist/components/content/card/sliding-card.styles.js +5 -1
- package/dist/components/content/collapse/collapse.d.ts +39 -12
- package/dist/components/content/collapse/collapse.js +65 -25
- package/dist/components/content/collapse/collapse.styles.d.ts +10 -1
- package/dist/components/content/collapse/collapse.styles.js +69 -18
- package/dist/components/content/description-list/description-list.d.ts +87 -0
- package/dist/components/content/description-list/description-list.js +107 -0
- package/dist/components/content/description-list/description-list.styles.d.ts +1 -0
- package/dist/components/content/description-list/description-list.styles.js +185 -0
- package/dist/components/content/icon/icon.d.ts +14 -2
- package/dist/components/content/icon/icon.js +54 -22
- package/dist/components/content/icon/icon.style.d.ts +2 -0
- package/dist/components/content/icon/icon.style.js +8 -2
- package/dist/components/content/image-carousel/image-carousel.d.ts +30 -19
- package/dist/components/content/image-carousel/image-carousel.js +48 -45
- package/dist/components/content/image-carousel/image-carousel.styles.js +69 -30
- package/dist/components/content/password-strength/password-strength.styles.js +5 -1
- package/dist/components/content/progress-bar/progress-bar.styles.js +12 -4
- package/dist/components/content/shared-styles/card-link.styles.js +5 -3
- package/dist/components/content/shared-styles/tone-surface.styles.d.ts +5 -0
- package/dist/components/content/shared-styles/tone-surface.styles.js +19 -14
- package/dist/components/content/tag/tag.d.ts +4 -0
- package/dist/components/content/tag/tag.js +4 -0
- package/dist/components/content/tag/tag.styles.js +14 -4
- package/dist/components/content/tooltip/tooltip.d.ts +3 -2
- package/dist/components/content/tooltip/tooltip.js +9 -16
- package/dist/components/content/tooltip/tooltip.styles.js +25 -7
- package/dist/components/form/checkbox/check-card.d.ts +4 -1
- package/dist/components/form/checkbox/check-card.js +4 -1
- package/dist/components/form/checkbox/check-card.styles.js +13 -4
- package/dist/components/form/checkbox/checkbox-list.d.ts +4 -1
- package/dist/components/form/checkbox/checkbox-list.js +11 -7
- package/dist/components/form/checkbox/checkbox.d.ts +4 -1
- package/dist/components/form/checkbox/checkbox.js +4 -1
- package/dist/components/form/checkbox/checkbox.styles.js +2 -2
- package/dist/components/form/color-picker/color-picker.d.ts +10 -4
- package/dist/components/form/color-picker/color-picker.js +23 -25
- package/dist/components/form/color-picker/color-picker.styles.js +6 -5
- package/dist/components/form/counter/counter.d.ts +7 -4
- package/dist/components/form/counter/counter.js +8 -5
- package/dist/components/form/counter/counter.styles.js +10 -9
- package/dist/components/form/date-picker/date-picker.d.ts +40 -36
- package/dist/components/form/date-picker/date-picker.js +35 -45
- package/dist/components/form/date-picker/date-picker.styles.js +13 -10
- package/dist/components/form/input/input.d.ts +10 -4
- package/dist/components/form/input/input.js +12 -6
- package/dist/components/form/input-file/input-file.d.ts +4 -1
- package/dist/components/form/input-file/input-file.js +8 -5
- package/dist/components/form/input-file/input-file.styles.js +3 -2
- package/dist/components/form/input-phone/input-phone.d.ts +11 -5
- package/dist/components/form/input-phone/input-phone.js +16 -20
- package/dist/components/form/input-phone/input-phone.styles.js +16 -16
- package/dist/components/form/label/label.styles.js +3 -3
- package/dist/components/form/radio/radio-card.d.ts +5 -2
- package/dist/components/form/radio/radio-card.js +5 -2
- package/dist/components/form/radio/radio-card.styles.js +14 -5
- package/dist/components/form/radio/radio-list.d.ts +5 -2
- package/dist/components/form/radio/radio-list.js +14 -10
- package/dist/components/form/radio/radio.d.ts +5 -2
- package/dist/components/form/radio/radio.js +5 -2
- package/dist/components/form/radio/radio.styles.js +4 -4
- package/dist/components/form/search/search.d.ts +2 -1
- package/dist/components/form/search/search.js +6 -15
- package/dist/components/form/search/search.styles.js +8 -7
- package/dist/components/form/select/select.d.ts +12 -5
- package/dist/components/form/select/select.js +18 -21
- package/dist/components/form/select/select.styles.js +3 -2
- package/dist/components/form/shared-styles/card.styles.js +5 -4
- package/dist/components/form/shared-styles/field.styles.js +21 -11
- package/dist/components/form/shared-styles/form-labels.styles.js +1 -1
- package/dist/components/form/slider/slider.d.ts +4 -1
- package/dist/components/form/slider/slider.js +5 -2
- package/dist/components/form/slider/slider.styles.js +8 -7
- package/dist/components/form/switch/switch.d.ts +4 -1
- package/dist/components/form/switch/switch.js +4 -1
- package/dist/components/form/switch/switch.styles.js +7 -5
- package/dist/components/form/textarea/textarea.d.ts +10 -4
- package/dist/components/form/textarea/textarea.js +18 -12
- package/dist/components/form/time-picker/time-picker-columns.styles.js +4 -2
- package/dist/components/form/time-picker/time-picker-list.styles.js +2 -1
- package/dist/components/form/time-picker/time-picker.d.ts +9 -5
- package/dist/components/form/time-picker/time-picker.js +25 -29
- package/dist/components/form/time-picker/time-picker.styles.js +9 -8
- package/dist/components/layout/animate/animate.d.ts +41 -11
- package/dist/components/layout/animate/animate.js +48 -16
- package/dist/components/layout/animate/animate.styles.js +9 -16
- package/dist/components/layout/infinite-list/infinite-list.d.ts +33 -10
- package/dist/components/layout/infinite-list/infinite-list.js +115 -18
- package/dist/components/layout/infinite-list/infinite-list.styles.d.ts +3 -0
- package/dist/components/layout/infinite-list/infinite-list.styles.js +17 -5
- package/dist/components/loader/loader/loader.styles.js +3 -1
- package/dist/components/navigation/breadcrumb/breadcrumb.d.ts +31 -45
- package/dist/components/navigation/breadcrumb/breadcrumb.js +111 -77
- package/dist/components/navigation/breadcrumb/breadcrumb.styles.d.ts +3 -0
- package/dist/components/navigation/breadcrumb/breadcrumb.styles.js +22 -26
- package/dist/components/navigation/carousel/carousel.d.ts +30 -10
- package/dist/components/navigation/carousel/carousel.js +37 -18
- package/dist/components/navigation/carousel/carousel.styles.js +60 -20
- package/dist/components/navigation/pagination/pagination.styles.js +8 -3
- package/dist/components/navigation/sidebar/sidebar.d.ts +2 -0
- package/dist/components/navigation/sidebar/sidebar.js +2 -0
- package/dist/components/navigation/sidebar/sidebar.styles.js +27 -11
- package/dist/components/navigation/stepper/step.styles.js +16 -5
- package/dist/components/navigation/stepper/stepper.styles.js +16 -5
- package/dist/components/navigation/tabs/tab/tab.d.ts +11 -0
- package/dist/components/navigation/tabs/tab/tab.js +11 -0
- package/dist/components/navigation/tabs/tab/tab.styles.js +22 -16
- package/dist/components/navigation/tabs/tab-group/tab-group.js +7 -8
- package/dist/components/navigation/tabs/tab-group/tab-group.styles.js +19 -14
- package/dist/components/navigation/tabs/tab-panel/tab-panel.d.ts +4 -0
- package/dist/components/navigation/tabs/tab-panel/tab-panel.js +4 -0
- package/dist/components/navigation/tabs/tab-panel/tab-panel.styles.js +18 -1
- package/dist/components/navigation/toolbar/toolbar.d.ts +17 -49
- package/dist/components/navigation/toolbar/toolbar.js +23 -71
- package/dist/components/navigation/toolbar/toolbar.styles.js +59 -36
- package/dist/events/table-row-click.event.d.ts +5 -4
- package/dist/events/table-row-click.event.js +10 -5
- package/dist/features/scheduler/calendar/calendar.d.ts +12 -12
- package/dist/features/scheduler/calendar/calendar.js +15 -14
- package/dist/features/scheduler/calendar/calendar.styles.js +8 -6
- package/dist/features/scheduler/scheduler/scheduler.d.ts +7 -7
- package/dist/features/scheduler/scheduler/scheduler.js +21 -35
- package/dist/features/scheduler/scheduler/scheduler.styles.js +6 -4
- package/dist/features/scheduler/scheduler-event/scheduler-event.d.ts +12 -8
- package/dist/features/scheduler/scheduler-event/scheduler-event.js +9 -7
- package/dist/features/scheduler/scheduler-event/scheduler-event.styles.js +16 -10
- package/dist/features/scheduler/scheduler-event-editor/scheduler-event-editor.js +5 -5
- package/dist/features/scheduler/shared/scheduler-event-popover.js +2 -2
- package/dist/features/scheduler/shared/scheduler-hour-grid.d.ts +2 -2
- package/dist/features/scheduler/shared/scheduler-hour-grid.js +3 -3
- package/dist/features/scheduler/shared/scheduler-hour-grid.styles.js +3 -3
- package/dist/features/scheduler/shared/scheduler-month-view.d.ts +3 -3
- package/dist/features/scheduler/shared/scheduler-month-view.js +2 -2
- package/dist/features/scheduler/shared/scheduler-month-view.styles.js +2 -2
- package/dist/features/scheduler/shared/scheduler-year-view.styles.js +2 -2
- package/dist/features/table/table/table-native.styles.d.ts +28 -0
- package/dist/features/table/table/table-native.styles.js +502 -0
- package/dist/features/table/table/table.d.ts +342 -294
- package/dist/features/table/table/table.js +820 -546
- package/dist/features/table/table/table.styles.js +31 -17
- package/dist/features/table/table/table.types.d.ts +18 -23
- package/dist/features/table/table/table.utils.d.ts +6 -36
- package/dist/features/table/table/table.utils.js +16 -65
- package/dist/features/table/table-action-bar/table-action-bar.d.ts +33 -16
- package/dist/features/table/table-action-bar/table-action-bar.js +18 -25
- package/dist/features/table/table-action-bar/table-action-bar.styles.js +15 -3
- package/dist/i18n/en.d.ts +34 -0
- package/dist/i18n/en.js +34 -0
- package/dist/i18n/fr.js +38 -0
- package/dist/index.d.ts +7 -13
- package/dist/index.js +6 -10
- package/dist/jsx.d.ts +1 -1
- package/dist/mixins/button.mixin.d.ts +10 -9
- package/dist/mixins/button.mixin.js +14 -6
- package/dist/mixins/card-link.mixin.d.ts +3 -2
- package/dist/mixins/card-link.mixin.js +12 -5
- package/dist/mixins/check.mixin.js +4 -5
- package/dist/mixins/disabled.mixin.d.ts +3 -3
- package/dist/mixins/disabled.mixin.js +10 -5
- package/dist/mixins/field-appearance.mixin.d.ts +19 -0
- package/dist/mixins/{field-variant.mixin.js → field-appearance.mixin.js} +11 -11
- package/dist/mixins/form.mixin.d.ts +17 -1
- package/dist/mixins/form.mixin.js +80 -25
- package/dist/mixins/radio.mixin.js +4 -5
- package/dist/mixins/validators.mixin.d.ts +7 -1
- package/dist/mixins/validators.mixin.js +36 -17
- package/dist/ssr/animate-ssr.css +27 -72
- package/dist/ssr/button-ssr.css +319 -0
- package/dist/ssr/card-ssr.css +184 -0
- package/dist/ssr/description-list-ssr.css +150 -0
- package/dist/ssr/links-ssr.css +35 -0
- package/dist/ssr/overlay-ssr.css +0 -41
- package/dist/ssr/rich-text.css +38 -0
- package/dist/ssr/sidebar-ssr.css +0 -38
- package/dist/ssr/table-ssr.css +472 -0
- package/dist/ssr/tag-ssr.css +197 -0
- package/dist/ssr/toolbar-ssr.css +77 -39
- package/dist/types/variant.type.d.ts +26 -10
- package/dist/utils/drag-drop.utils.js +18 -2
- package/dist/utils/dropdown-menu.utils.d.ts +2 -2
- package/dist/utils/dropdown-menu.utils.js +4 -14
- package/dist/utils/light-dom-styles.utils.d.ts +14 -0
- package/dist/utils/light-dom-styles.utils.js +37 -0
- package/dist/utils/media.styles.d.ts +19 -0
- package/dist/utils/media.styles.js +23 -0
- package/dist/utils/motion.utils.d.ts +40 -0
- package/dist/utils/motion.utils.js +51 -0
- package/dist/utils/navigation.utils.d.ts +14 -0
- package/dist/utils/navigation.utils.js +33 -0
- package/dist/utils/new-tab-anchor.controller.d.ts +44 -0
- package/dist/utils/new-tab-anchor.controller.js +102 -0
- package/dist/utils/severity-icon.utils.d.ts +1 -1
- package/dist/utils/severity-icon.utils.js +1 -1
- package/dist/utils/theme-generator.utils.d.ts +9 -2
- package/dist/utils/theme-generator.utils.js +62 -21
- package/package.json +24 -29
- package/styles/breakpoints.scss +8 -0
- package/styles/eunomia-grid.scss +6 -0
- package/styles/themes/eunomia-theme.scss +4 -3
- package/styles/themes/mixins/eunomia-a11y-color.mixin.scss +34 -1
- package/styles/themes/mixins/eunomia-neutrals.mixin.scss +4 -0
- package/styles/themes/mixins/eunomia-states.mixin.scss +36 -12
- package/styles/themes/prebuilt-themes/eunomia/eunomia-dark.mixin.scss +10 -10
- package/styles/themes/prebuilt-themes/eunomia/eunomia.mixin.scss +10 -10
- package/styles/themes/prebuilt-themes/eunomia/eunomia.theme.scss +3 -2
- package/styles/themes/prebuilt-themes/fire/eunomia-fire-dark.mixin.scss +10 -10
- package/styles/themes/prebuilt-themes/fire/eunomia-fire.mixin.scss +10 -10
- package/styles/themes/prebuilt-themes/fire/eunomia-fire.theme.scss +3 -2
- package/styles/themes/prebuilt-themes/forest/eunomia-forest-dark.mixin.scss +10 -10
- package/styles/themes/prebuilt-themes/forest/eunomia-forest.mixin.scss +10 -10
- package/styles/themes/prebuilt-themes/forest/eunomia-forest.theme.scss +3 -2
- package/styles/themes/prebuilt-themes/gold/eunomia-gold-dark.mixin.scss +10 -10
- package/styles/themes/prebuilt-themes/gold/eunomia-gold.mixin.scss +10 -10
- package/styles/themes/prebuilt-themes/gold/eunomia-gold.theme.scss +3 -2
- package/styles/themes/prebuilt-themes/ocean/eunomia-ocean-dark.mixin.scss +10 -10
- package/styles/themes/prebuilt-themes/ocean/eunomia-ocean.mixin.scss +10 -10
- package/styles/themes/prebuilt-themes/ocean/eunomia-ocean.theme.scss +3 -2
- package/styles/themes/prebuilt-themes/salmon/eunomia-salmon-dark.mixin.scss +10 -10
- package/styles/themes/prebuilt-themes/salmon/eunomia-salmon.mixin.scss +10 -10
- package/styles/themes/prebuilt-themes/salmon/eunomia-salmon.theme.scss +3 -2
- package/styles/themes/prebuilt-themes/violet/eunomia-violet-dark.mixin.scss +10 -10
- package/styles/themes/prebuilt-themes/violet/eunomia-violet.mixin.scss +10 -10
- package/styles/themes/prebuilt-themes/violet/eunomia-violet.theme.scss +3 -2
- package/styles/tools/indexes/eunomia-media-queries.index.scss +1 -3
- package/styles/tools/indexes/eunomia-tools.index.scss +1 -0
- package/styles/tools/mixins/layout/eunomia-grid.mixin.scss +117 -53
- package/styles/tools/mixins/media-queries/eunomia-media-queries.mixin.scss +69 -0
- package/styles/tools/mixins/settings/eunomia-alpha.mixin.scss +28 -4
- package/styles/tools/mixins/settings/eunomia-motion.mixin.scss +9 -0
- package/styles/tools/variables/eunomia.breakpoints.scss +4 -0
- package/dist/cdn/components/chunks/chunk-2JLDJFYD.js +0 -48
- package/dist/cdn/components/chunks/chunk-A6KGFALA.js +0 -132
- package/dist/cdn/components/chunks/chunk-ATH2OAMU.js +0 -1
- package/dist/cdn/components/chunks/chunk-BKHD4S57.js +0 -1
- package/dist/cdn/components/chunks/chunk-CEDHJUUH.js +0 -1
- package/dist/cdn/components/chunks/chunk-D2M4BV5Y.js +0 -328
- package/dist/cdn/components/chunks/chunk-E74CM7UG.js +0 -66
- package/dist/cdn/components/chunks/chunk-EST3M4AO.js +0 -1
- package/dist/cdn/components/chunks/chunk-GU6BVMFJ.js +0 -1
- package/dist/cdn/components/chunks/chunk-KVYUNKUO.js +0 -27
- package/dist/cdn/components/chunks/chunk-OAULRKHQ.js +0 -38
- package/dist/cdn/components/chunks/chunk-PCM7D3YF.js +0 -84
- package/dist/cdn/components/chunks/chunk-T4PTHUYF.js +0 -10
- package/dist/cdn/components/chunks/chunk-T7WABJEJ.js +0 -1
- package/dist/cdn/components/chunks/chunk-VRGRCYIO.js +0 -1
- package/dist/cdn/components/chunks/chunk-X2AUBZD2.js +0 -30
- package/dist/cdn/components/chunks/chunk-XSMCT4DF.js +0 -1
- package/dist/cdn/components/eun-breadcrumb-item.js +0 -93
- package/dist/cdn/components/eun-table-cell.js +0 -1
- package/dist/cdn/components/eun-table-column.js +0 -1
- package/dist/cdn/components/eun-table-header.js +0 -1
- package/dist/cdn/components/eun-table-item.js +0 -1
- package/dist/cdn/components/eun-table-skeleton-row.js +0 -1
- package/dist/cdn/styles/tools/mixins/media-queries/eunomia-device.mixin.scss +0 -14
- package/dist/cdn/styles/tools/mixins/media-queries/eunomia-gte.mixin.scss +0 -26
- package/dist/cdn/styles/tools/mixins/media-queries/eunomia-lte.mixin.scss +0 -26
- package/dist/components/navigation/breadcrumb/breadcrumb-item.d.ts +0 -77
- package/dist/components/navigation/breadcrumb/breadcrumb-item.js +0 -130
- package/dist/components/navigation/breadcrumb/breadcrumb-item.styles.d.ts +0 -6
- package/dist/components/navigation/breadcrumb/breadcrumb-item.styles.js +0 -78
- package/dist/features/table/native-table.css +0 -276
- package/dist/features/table/shared-styles/table-row.styles.d.ts +0 -7
- package/dist/features/table/shared-styles/table-row.styles.js +0 -47
- package/dist/features/table/shared-styles/table-shared.styles.d.ts +0 -23
- package/dist/features/table/shared-styles/table-shared.styles.js +0 -33
- package/dist/features/table/table-cell/table-cell.d.ts +0 -59
- package/dist/features/table/table-cell/table-cell.js +0 -73
- package/dist/features/table/table-cell/table-cell.styles.d.ts +0 -1
- package/dist/features/table/table-cell/table-cell.styles.js +0 -46
- package/dist/features/table/table-column/table-column.d.ts +0 -73
- package/dist/features/table/table-column/table-column.js +0 -89
- package/dist/features/table/table-column/table-column.styles.d.ts +0 -1
- package/dist/features/table/table-column/table-column.styles.js +0 -51
- package/dist/features/table/table-header/table-header.d.ts +0 -102
- package/dist/features/table/table-header/table-header.js +0 -165
- package/dist/features/table/table-header/table-header.styles.d.ts +0 -1
- package/dist/features/table/table-header/table-header.styles.js +0 -147
- package/dist/features/table/table-item/table-item.d.ts +0 -179
- package/dist/features/table/table-item/table-item.js +0 -291
- package/dist/features/table/table-item/table-item.styles.d.ts +0 -1
- package/dist/features/table/table-item/table-item.styles.js +0 -404
- package/dist/features/table/table-managed/table-managed.d.ts +0 -19
- package/dist/features/table/table-managed/table-managed.js +0 -128
- package/dist/features/table/table-skeleton-row/table-skeleton-row.d.ts +0 -46
- package/dist/features/table/table-skeleton-row/table-skeleton-row.js +0 -110
- package/dist/features/table/table-skeleton-row/table-skeleton-row.styles.d.ts +0 -12
- package/dist/features/table/table-skeleton-row/table-skeleton-row.styles.js +0 -65
- package/dist/mixins/field-variant.mixin.d.ts +0 -22
- package/dist/mixins/table-row.mixin.d.ts +0 -37
- package/dist/mixins/table-row.mixin.js +0 -103
- package/styles/tools/mixins/media-queries/eunomia-device.mixin.scss +0 -14
- package/styles/tools/mixins/media-queries/eunomia-gte.mixin.scss +0 -26
- package/styles/tools/mixins/media-queries/eunomia-lte.mixin.scss +0 -26
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as m}from"./chunks/chunk-
|
|
1
|
+
import{a as m}from"./chunks/chunk-FF3I7C3C.js";import{a as u}from"./chunks/chunk-UP4M7TER.js";import{a as c}from"./chunks/chunk-PPCHQG7P.js";import{a as d}from"./chunks/chunk-O7PHBLH2.js";import"./chunks/chunk-SGM2X2TC.js";import{a as t,f as i,h as n,j as a,n as s,p as o,r as p,u as l}from"./chunks/chunk-YITWLCD3.js";var f=n`
|
|
2
2
|
:host {
|
|
3
3
|
display: inline-flex;
|
|
4
4
|
font-family: var(--eun-font-family, "Mulish", sans-serif);
|
|
@@ -72,11 +72,17 @@ import{a as m}from"./chunks/chunk-P32B7BFD.js";import{a as u}from"./chunks/chunk
|
|
|
72
72
|
color: var(--tag-color, var(--_fg));
|
|
73
73
|
border: var(--_borderWidth) solid var(--tag-border-color, var(--_bd));
|
|
74
74
|
border-radius: var(--tag-border-radius, var(--_radius));
|
|
75
|
-
padding: max(
|
|
76
|
-
|
|
77
|
-
|
|
75
|
+
padding: max(
|
|
76
|
+
0px,
|
|
77
|
+
calc(var(--tag-padding-block, var(--_padV)) - var(--_borderWidth))
|
|
78
|
+
)
|
|
79
|
+
max(
|
|
80
|
+
0px,
|
|
81
|
+
calc(var(--tag-padding-inline, var(--_padH)) - var(--_borderWidth))
|
|
82
|
+
);
|
|
83
|
+
font-size: var(--tag-font-size, var(--_fontSize));
|
|
78
84
|
gap: var(--tag-gap, var(--_gap));
|
|
79
|
-
font-weight: var(--eun-font-weight-m, 500);
|
|
85
|
+
font-weight: var(--tag-font-weight, var(--eun-font-weight-m, 500));
|
|
80
86
|
--icon-color: var(--tag-color, var(--_fg));
|
|
81
87
|
}
|
|
82
88
|
|
|
@@ -87,7 +93,7 @@ import{a as m}from"./chunks/chunk-P32B7BFD.js";import{a as u}from"./chunks/chunk
|
|
|
87
93
|
slot[name="icon"].hidden {
|
|
88
94
|
display: none;
|
|
89
95
|
}
|
|
90
|
-
`,
|
|
96
|
+
`,v=[m,f];var h="eun-tag",e=class extends l{constructor(){super(...arguments);this.color="medium";this.appearance="default";this.hideIcon=!1;this.iconOnly=!1;this.rounded=!1;this.fixedColor=!1;this.uppercase=!1;this.handleIconSlotChange=()=>{this.requestUpdate()}}getIconName(){return u(this.icon,this.severity,"severity")}shouldHideIcon(){return this.hideIcon?!0:this.iconSlotEls.length>0||this.iconOnly||this.severity?!1:!this.icon}render(){let r=this.shouldHideIcon();return o`
|
|
91
97
|
<div id="tag">
|
|
92
98
|
<slot
|
|
93
99
|
name="icon"
|
|
@@ -104,4 +110,4 @@ import{a as m}from"./chunks/chunk-P32B7BFD.js";import{a as u}from"./chunks/chunk
|
|
|
104
110
|
</slot>
|
|
105
111
|
<slot></slot>
|
|
106
112
|
</div>
|
|
107
|
-
`}};e.styles=
|
|
113
|
+
`}};e.styles=v,t([a({reflect:!0})],e.prototype,"color",2),t([a({reflect:!0})],e.prototype,"severity",2),t([a({reflect:!0})],e.prototype,"appearance",2),t([a()],e.prototype,"icon",2),t([a({reflect:!0})],e.prototype,"size",2),t([a({type:Boolean,attribute:"hide-icon"})],e.prototype,"hideIcon",2),t([a({type:Boolean,attribute:"icon-only",reflect:!0})],e.prototype,"iconOnly",2),t([a({type:Boolean,reflect:!0})],e.prototype,"rounded",2),t([a({type:Boolean,reflect:!0,attribute:"fixed-color"})],e.prototype,"fixedColor",2),t([a({type:Boolean,reflect:!0})],e.prototype,"uppercase",2),t([s({slot:"icon"})],e.prototype,"iconSlotEls",2),e=t([i(h)],e);export{e as EunomiaTag,h as EunomiaTagTagName};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as q}from"./chunks/chunk-
|
|
1
|
+
import{a as q}from"./chunks/chunk-G5SBDQQ3.js";import{a as X}from"./chunks/chunk-L74LXUGL.js";import{a as W}from"./chunks/chunk-UYZR4JXZ.js";import{a as U}from"./chunks/chunk-4PI6RDUS.js";import{a as G}from"./chunks/chunk-BO3JOEWM.js";import{a as S,c as z,d as j,e as K,f as C}from"./chunks/chunk-VOTRXBDS.js";import{a as F}from"./chunks/chunk-YYCEPZUN.js";import{a as N,b as y,c as w,d as A,e as V,f as R,g as O}from"./chunks/chunk-GDBPWZN6.js";import{a as B}from"./chunks/chunk-RS7TWEMQ.js";import{a as v}from"./chunks/chunk-PPCHQG7P.js";import{a as P}from"./chunks/chunk-O7PHBLH2.js";import"./chunks/chunk-SGM2X2TC.js";import"./chunks/chunk-KSZRQRN4.js";import{a as c,f as I,h as D,j as u,k as E,l as k,p as f,r as b,u as _}from"./chunks/chunk-YITWLCD3.js";var ae=D`
|
|
2
2
|
#field {
|
|
3
3
|
resize: vertical;
|
|
4
4
|
min-height: 6rem;
|
|
@@ -153,8 +153,8 @@ import{a as q}from"./chunks/chunk-E4IS25H7.js";import{a as W}from"./chunks/chunk
|
|
|
153
153
|
#char-count[data-exceeded] {
|
|
154
154
|
color: var(--_errorColor);
|
|
155
155
|
}
|
|
156
|
-
`,Y=[W,
|
|
157
|
-
`);if(
|
|
156
|
+
`,Y=[W,ae];var re="eun-textarea",H={bold:"STRONG",italic:"EM",underline:"U"},T={bold:()=>document.createElement("strong"),italic:()=>document.createElement("em"),underline:()=>document.createElement("u")},se={b:"bold",i:"italic",u:"underline"};function ce(n){return!(n.ctrlKey||n.metaKey)||n.altKey?null:se[n.key.toLowerCase()]??null}function J(n,l){let e=l;for(;e&&e.parentNode!==n;)e=e.parentNode;return e}function m(n){let l=n.getRootNode();return l instanceof ShadowRoot&&typeof l.getSelection=="function"?l.getSelection():window.getSelection()}function $(n){let l=m(n);if(!l||!l.rangeCount)return null;let e=l.getRangeAt(0);return e.collapsed||!n.contains(e.commonAncestorContainer)?null:e}function ne(n,l){let e=document.createRange();e.selectNodeContents(l),n.removeAllRanges(),n.addRange(e)}function Q(n){let l=m(n);if(!l||!l.rangeCount)return null;let e=l.getRangeAt(0);return!e.collapsed||!n.contains(e.commonAncestorContainer)?null:e}function de(n){return!n.bold&&!n.italic&&!n.underline&&!n.color&&!n.highlight}var x="\u200B";function ue(n){let l=[];if(n.bold&&l.push(T.bold()),n.italic&&l.push(T.italic()),n.underline&&l.push(T.underline()),n.color){let e=y(n.color),t=document.createElement("span");t.setAttribute("data-color",n.color),t.style.color=e?.text??"inherit",l.push(t)}if(n.highlight){let e=y(n.highlight),t=document.createElement("span");t.setAttribute("data-highlight",n.highlight),t.style.backgroundColor=e?.highlight??"transparent",l.push(t)}if(!l.length)return null;for(let e=0;e<l.length-1;e+=1)l[e].appendChild(l[e+1]);return l[l.length-1].appendChild(document.createTextNode(x)),l[0]}function he(n,l){let e=l;for(;e.parentNode&&e.parentNode!==n&&e.parentNode.childNodes.length===1;)e=e.parentNode;return e}function Z(n,l){let e=he(n,l),t=e.parentNode,i=Array.from(t.childNodes).indexOf(e);t.removeChild(e);let o=document.createRange();return o.setStart(t,i),o.collapse(!0),o}function ee(n,l,e,t){let i=l,o=e;for(;;){let a=i.parentNode;if(!a||a===n)break;let r=i.nodeType===Node.TEXT_NODE?i.textContent?.length??0:i.childNodes.length;if(!(t?o===0:o===r))break;let h=Array.from(a.childNodes).indexOf(i);i=a,o=t?h:h+1}return{container:i,offset:o}}function le(n,l){let e=ee(n,l.startContainer,l.startOffset,!0),t=ee(n,l.endContainer,l.endOffset,!1);l.setStart(e.container,e.offset),l.setEnd(t.container,t.offset)}function oe(n,l){n.querySelectorAll("*").forEach(e=>{if(!l(e))return;let t=e.parentNode;if(t){for(;e.firstChild;)t.insertBefore(e.firstChild,e);t.removeChild(e)}})}function pe(n,l,e){let t=m(n),i=$(n);if(!t||!i)return!1;le(n,i);let o=H[l],a=i.extractContents();oe(a,d=>d.tagName===o);let r=a;if(e){let d=T[l]();d.appendChild(a),r=d}return i.insertNode(r),ne(t,r),!0}function fe(n,l,e){let t=m(n),i=$(n);if(!t||!i)return!1;le(n,i);let o=l==="color"?"color":"highlight",a=i.extractContents();oe(a,d=>d.tagName==="SPAN"&&d.hasAttribute(`data-${o}`));let r=a;if(e){let d=y(e),h=document.createElement("span");h.setAttribute(`data-${o}`,e),h.style.cssText=l==="color"?`color: ${d?.text??"inherit"}`:`background-color: ${d?.highlight??"transparent"}`,h.appendChild(a),r=h}return i.insertNode(r),ne(t,r),!0}function te(n){let l=m(n);if(!l||!l.anchorNode||!n.contains(l.anchorNode))return[];let e=new Set,t=l.anchorNode;for(;t&&t!==n;){if(t instanceof HTMLElement){let i=Object.entries(H).find(([,o])=>o===t.tagName)?.[0];i&&e.add(i)}t=t.parentNode}return Array.from(e)}function ie(n,l){let e=m(n);if(!e||!e.anchorNode||!n.contains(e.anchorNode))return null;let t=e.anchorNode;for(;t&&t!==n;){if(t instanceof HTMLElement){let i=l==="color"?t.getAttribute("data-color"):t.getAttribute("data-highlight");if(i)return i}t=t.parentNode}return null}var ge=B(K(_)),me=U(G(j(q(z(ge))))),s=class extends me{constructor(){super(...arguments);this.formatting=!1;this.formatToolbarLabel="Text formatting";this.formatBoldLabel="Bold";this.formatItalicLabel="Italic";this.formatUnderlineLabel="Underline";this.formatAlignLabel="Text alignment";this.formatAlignStartLabel="Align left";this.formatAlignCenterLabel="Center";this.formatAlignEndLabel="Align right";this.formatAlignJustifyLabel="Justify";this.formatTextColorLabel="Text color";this.formatHighlightLabel="Highlight";this.formatColorClearLabel="Default";this.colorLabels=Object.fromEntries(N.map(e=>[e.name,e.label]));this.autocomplete="off";this.emptyValueLabel="No value set";this.confirmLabel="Save";this.cancelLabel="Cancel";this.openPicker=null;this.activeTextColor=null;this.activeHighlight=null;this.previousActiveFormats=[];this.pendingMarks={bold:!1,italic:!1,underline:!1,color:null,highlight:null};this.pendingCaretNode=null;this.handleHostFocus=()=>{this.fieldEl?.focus()};this.checkLocalValidators=()=>this.formatting?this.checkEditableValidators():X(this.fieldEl,["valueMissing","tooShort","tooLong"]);this.handleEditableInput=()=>{let e=this.fieldEl;if(!(e instanceof HTMLDivElement))return;let t=O(e);this.lastSyncedValue=t,this.value=t,this.resizeEditableField(),this.dispatchEvent(new F(this.value)),this.syncToolbarToSelection()};this.handleEditableBeforeInput=e=>{if(this.maxlength===void 0)return;let t=this.fieldEl;if(!(t instanceof HTMLDivElement)||!e.inputType.startsWith("insert"))return;let i=m(t);!(i&&!i.isCollapsed)&&(t.textContent?.length??0)>=this.maxlength&&e.preventDefault()};this.handleEditablePaste=e=>{let t=this.fieldEl;if(!(t instanceof HTMLDivElement))return;e.preventDefault();let i=e.clipboardData?.getData("text/plain")??"";if(!i)return;let o=m(t);if(!o||!o.rangeCount)return;let a=o.getRangeAt(0);a.deleteContents();let r=i.split(`
|
|
157
|
+
`);if(r.length===1){let d=document.createTextNode(r[0]);a.insertNode(d),a.setStartAfter(d),a.collapse(!0)}else{let d=J(t,a.startContainer),h=a.cloneRange();d&&h.setEndAfter(d.lastChild??d);let p=h.extractContents();a.insertNode(document.createTextNode(r[0]));let g=d;for(let M=1;M<r.length;M+=1){let L=document.createElement("p");L.textContent=r[M],g?.after(L),g=L}g?.appendChild(p),g&&a.selectNodeContents(g),a.collapse(!1)}o.removeAllRanges(),o.addRange(a),this.handleEditableInput()};this.handleEditableKeydown=e=>{let t=this.fieldEl;if(!(t instanceof HTMLDivElement))return;let i=ce(e);if(i){e.preventDefault();let g=te(t).includes(i);this.applyFormat(i,!g);return}if(e.key!=="Enter")return;e.preventDefault();let o=m(t);if(!o||!o.rangeCount)return;let a=o.getRangeAt(0);a.deleteContents();let r=J(t,a.startContainer);if(!r)return;r.hasChildNodes()||r.appendChild(document.createElement("br"));let d=a.cloneRange();d.setEndAfter(r.lastChild??r);let h=d.extractContents();r.hasChildNodes()||r.appendChild(document.createElement("br"));let p=document.createElement("p");p.appendChild(h),p.hasChildNodes()||p.appendChild(document.createElement("br")),r.after(p),a.selectNodeContents(p),a.collapse(!0),o.removeAllRanges(),o.addRange(a),this.handleEditableInput()};this.handleSelectionChange=()=>{this.cleanupAbandonedPendingMarker(),this.syncToolbarToSelection()};this.handleOutsideClick=e=>{e.composedPath().some(o=>o instanceof HTMLElement&&o.classList.contains("color-picker"))||this.closeColorPicker()}}get defaultValue(){return super.defaultValue}set defaultValue(e){super.defaultValue=e}connectedCallback(){super.connectedCallback?.(),this.addEventListener("focus",this.handleHostFocus)}disconnectedCallback(){this.removeEventListener("focus",this.handleHostFocus),document.removeEventListener("click",this.handleOutsideClick,{capture:!0}),super.disconnectedCallback?.()}firstUpdated(){this.formatting&&this.fieldEl instanceof HTMLDivElement?(R(this.fieldEl,this.value??""),this.lastSyncedValue=this.value,this.resizeEditableField()):this.resizeToContent()}updated(e){if(super.updated(e),e.has("editing")&&this.editing&&this.fieldEl?.focus(),!this.formatting){(e.has("value")||e.has("editing"))&&this.resizeToContent();return}(e.has("editing")&&this.editing||e.has("formatting")&&this.formatting||e.has("value")&&this.value!==this.lastSyncedValue)&&this.fieldEl instanceof HTMLDivElement&&this.fieldEl instanceof HTMLDivElement&&(R(this.fieldEl,this.value??""),this.lastSyncedValue=this.value),(e.has("value")||e.has("editing"))&&this.resizeEditableField()}checkEditableValidators(){let e=A(this.value??"");return this.minlength!==void 0&&e>0&&e<this.minlength?{validity:{tooShort:!0},message:this.validationDictionary.validation.tooShort(this.minlength,e)}:this.maxlength!==void 0&&e>this.maxlength?{validity:{tooLong:!0},message:this.validationDictionary.validation.tooLong(this.maxlength,e)}:{validity:{}}}getFocusAnchor(){return this.fieldEl??void 0}focus(){super.focus?.(),this.fieldEl?.focus()}resizeToContent(){let e=this.fieldEl;if(!e||this.rows!==void 0)return;e.style.height="";let t=e.clientHeight;e.style.height="0px";let i=e.scrollHeight;e.style.height=i>t?`${i}px`:""}resizeEditableField(){let e=this.fieldEl;if(!e||!(e instanceof HTMLDivElement))return;if(this.rows===void 0){e.style.height="",e.style.overflowY="";return}let t=parseFloat(getComputedStyle(e).lineHeight)||20;e.style.height=`${t*this.rows}px`,e.style.overflowY="auto"}handleInput(e){this.value=e.target.value,this.resizeToContent(),this.dispatchEvent(new F(this.value))}syncToolbarToSelection(){if(!(!this.formatting||!this.fieldEl)){if(this.toolbarEl){let e=te(this.fieldEl);this.previousActiveFormats=e,this.toolbarEl.value=e}this.activeTextColor=ie(this.fieldEl,"color"),this.activeHighlight=ie(this.fieldEl,"highlight")}}cleanupAbandonedPendingMarker(){let e=this.fieldEl,t=this.pendingCaretNode;if(!t||!(e instanceof HTMLDivElement))return;let i=m(e),o=i?.rangeCount?i.getRangeAt(0):null;o&&o.collapsed&&o.startContainer===t||(t.data===x?Z(e,t):t.data=t.data.replace(x,""),this.pendingCaretNode=null,this.pendingMarks={bold:!1,italic:!1,underline:!1,color:null,highlight:null})}updatePendingMarker(e,t){let i=t,o=this.pendingCaretNode,a=!!o&&t.startContainer===o;if(a&&o.data===x?(i=Z(e,o),this.pendingCaretNode=null):a&&(o.data=o.data.replace(x,""),this.pendingCaretNode=null),de(this.pendingMarks))return;let r=ue(this.pendingMarks);if(!r)return;i.insertNode(r);let h=document.createTreeWalker(r,NodeFilter.SHOW_TEXT).nextNode();if(!h)return;this.pendingCaretNode=h;let p=m(e);if(!p)return;let g=document.createRange();g.setStart(h,h.data.length),g.collapse(!0),p.removeAllRanges(),p.addRange(g)}applyFormat(e,t){let i=this.fieldEl;if(!(i instanceof HTMLDivElement))return;if($(i)){if(!pe(i,e,t))return;this.handleEditableInput(),this.updateComplete.then(()=>{i.focus(),this.syncToolbarToSelection()});return}let a=Q(i);a&&(this.pendingMarks={...this.pendingMarks,[e]:t},this.updatePendingMarker(i,a),i.focus(),this.syncToolbarToSelection())}handleToolbarChange(e){e.stopPropagation();let i=e.target.value;Object.keys(H).forEach(o=>{let a=this.previousActiveFormats.includes(o),r=i.includes(o);a!==r&&this.applyFormat(o,r)}),this.previousActiveFormats=i}handleAlignChange(e){e.stopPropagation();let t=this.fieldEl;if(!(t instanceof HTMLDivElement))return;let[i]=e.target.value;t.style.textAlign=i==="start"?"":i,this.handleEditableInput(),this.updateComplete.then(()=>t.focus())}toggleColorPicker(e){if(this.openPicker===e){this.closeColorPicker();return}this.openPicker=e,document.addEventListener("click",this.handleOutsideClick,{capture:!0})}closeColorPicker(){this.openPicker!==null&&(this.openPicker=null,document.removeEventListener("click",this.handleOutsideClick,{capture:!0}))}selectColor(e,t){let i=this.fieldEl;if(i instanceof HTMLDivElement)if($(i))fe(i,e,t)&&this.handleEditableInput();else{let a=Q(i);a&&(this.pendingMarks={...this.pendingMarks,[e]:t},this.updatePendingMarker(i,a),this.syncToolbarToSelection())}this.closeColorPicker(),this.updateComplete.then(()=>this.fieldEl?.focus())}renderToolbar(){let e=this.disabled||this.readonly,t=w(this.value??"").align;return f`
|
|
158
158
|
<div
|
|
159
159
|
id="toolbar-groups"
|
|
160
160
|
@mousedown=${i=>i.preventDefault()}
|
|
@@ -213,21 +213,21 @@ import{a as q}from"./chunks/chunk-E4IS25H7.js";import{a as W}from"./chunks/chunk
|
|
|
213
213
|
${this.renderColorPicker("color",this.formatTextColorLabel,"format_color_text")}
|
|
214
214
|
${this.renderColorPicker("highlight",this.formatHighlightLabel,"format_color_fill")}
|
|
215
215
|
</div>
|
|
216
|
-
`}renderColorPicker(e,t,i){let
|
|
216
|
+
`}renderColorPicker(e,t,i){let o=this.disabled||this.readonly,a=this.openPicker===e,r=e==="color"?this.activeTextColor:this.activeHighlight,d=r?y(r):void 0,h=e==="color"?d?.text:d?.highlight;return f`
|
|
217
217
|
<div class="color-picker">
|
|
218
218
|
<button
|
|
219
219
|
type="button"
|
|
220
220
|
class="color-picker-trigger"
|
|
221
221
|
aria-haspopup="true"
|
|
222
|
-
aria-expanded=${
|
|
222
|
+
aria-expanded=${a?"true":"false"}
|
|
223
223
|
aria-label=${t}
|
|
224
|
-
?disabled=${
|
|
224
|
+
?disabled=${o}
|
|
225
225
|
style=${h?`--_border-indicator-color: ${h}`:""}
|
|
226
226
|
@click=${()=>this.toggleColorPicker(e)}
|
|
227
227
|
>
|
|
228
228
|
<eun-icon name=${i} size="18"></eun-icon>
|
|
229
229
|
</button>
|
|
230
|
-
${
|
|
230
|
+
${a?f`
|
|
231
231
|
<div
|
|
232
232
|
class="color-picker-panel"
|
|
233
233
|
role="menu"
|
|
@@ -238,16 +238,16 @@ import{a as q}from"./chunks/chunk-E4IS25H7.js";import{a as W}from"./chunks/chunk
|
|
|
238
238
|
type="button"
|
|
239
239
|
class="color-swatch clear"
|
|
240
240
|
role="menuitemradio"
|
|
241
|
-
aria-checked=${
|
|
241
|
+
aria-checked=${r===null?"true":"false"}
|
|
242
242
|
aria-label=${this.formatColorClearLabel}
|
|
243
243
|
@click=${()=>this.selectColor(e,null)}
|
|
244
244
|
></button>
|
|
245
|
-
${N.map(p=>
|
|
245
|
+
${N.map(p=>f`
|
|
246
246
|
<button
|
|
247
247
|
type="button"
|
|
248
248
|
class="color-swatch"
|
|
249
249
|
role="menuitemradio"
|
|
250
|
-
aria-checked=${
|
|
250
|
+
aria-checked=${r===p.name?"true":"false"}
|
|
251
251
|
aria-label=${this.colorLabels[p.name]??p.label}
|
|
252
252
|
style="--_swatch-bg: ${e==="color"?p.text:p.highlight}"
|
|
253
253
|
@click=${()=>this.selectColor(e,p.name)}
|
|
@@ -256,11 +256,11 @@ import{a as q}from"./chunks/chunk-E4IS25H7.js";import{a as W}from"./chunks/chunk
|
|
|
256
256
|
</div>
|
|
257
257
|
`:b}
|
|
258
258
|
</div>
|
|
259
|
-
`}renderCharCount(){let e=this.formatting?A(this.value??""):this.value?.length??0,t=this.maxlength!==void 0&&e>this.maxlength;return
|
|
259
|
+
`}renderCharCount(){let e=this.formatting?A(this.value??""):this.value?.length??0,t=this.maxlength!==void 0&&e>this.maxlength;return f`
|
|
260
260
|
<span id="char-count" ?data-exceeded=${t}
|
|
261
261
|
>${e}/${this.maxlength}</span
|
|
262
262
|
>
|
|
263
|
-
`}renderReadonlyDisplay(){let e=!!this.value?.trim().length,t=this.formatting?w(this.value??"").align:void 0;return
|
|
263
|
+
`}renderReadonlyDisplay(){let e=!!this.value?.trim().length,t=this.formatting?w(this.value??"").align:void 0;return f`
|
|
264
264
|
<div
|
|
265
265
|
id="readonly-display"
|
|
266
266
|
role="button"
|
|
@@ -270,12 +270,12 @@ import{a as q}from"./chunks/chunk-E4IS25H7.js";import{a as W}from"./chunks/chunk
|
|
|
270
270
|
@click=${this.startEdit}
|
|
271
271
|
@keydown=${i=>(i.key==="Enter"||i.key===" ")&&this.startEdit()}
|
|
272
272
|
>
|
|
273
|
-
${e&&this.formatting?V(this.value):
|
|
273
|
+
${e&&this.formatting?V(this.value):f`<span
|
|
274
274
|
class=${P({"plain-value":!0,empty:!e})}
|
|
275
275
|
>${e?this.value:this.emptyValueLabel}</span
|
|
276
276
|
>`}
|
|
277
277
|
</div>
|
|
278
|
-
`}renderNativeField(e){return
|
|
278
|
+
`}renderNativeField(e){return f`
|
|
279
279
|
<textarea
|
|
280
280
|
id="field"
|
|
281
281
|
rows=${v(this.rows)}
|
|
@@ -287,7 +287,7 @@ import{a as q}from"./chunks/chunk-E4IS25H7.js";import{a as W}from"./chunks/chunk
|
|
|
287
287
|
?required=${this.required}
|
|
288
288
|
minlength=${v(this.minlength)}
|
|
289
289
|
maxlength=${v(this.maxlength)}
|
|
290
|
-
aria-invalid=${
|
|
290
|
+
aria-invalid=${this.showError}
|
|
291
291
|
aria-label=${v(this.label)}
|
|
292
292
|
aria-describedby=${e||b}
|
|
293
293
|
@input=${this.handleInput}
|
|
@@ -296,7 +296,7 @@ import{a as q}from"./chunks/chunk-E4IS25H7.js";import{a as W}from"./chunks/chunk
|
|
|
296
296
|
@click=${this.handleSelectionChange}
|
|
297
297
|
@focus=${this.handleSelectionChange}
|
|
298
298
|
></textarea>
|
|
299
|
-
`}renderEditableField(e){let t=this.disabled||this.readonly;return
|
|
299
|
+
`}renderEditableField(e){let t=this.disabled||this.readonly;return f`
|
|
300
300
|
<div
|
|
301
301
|
id="field"
|
|
302
302
|
contenteditable=${t?"false":"true"}
|
|
@@ -304,7 +304,7 @@ import{a as q}from"./chunks/chunk-E4IS25H7.js";import{a as W}from"./chunks/chunk
|
|
|
304
304
|
role="textbox"
|
|
305
305
|
aria-multiline="true"
|
|
306
306
|
aria-required=${this.required?"true":b}
|
|
307
|
-
aria-invalid=${
|
|
307
|
+
aria-invalid=${this.showError}
|
|
308
308
|
aria-label=${v(this.label)}
|
|
309
309
|
aria-describedby=${e||b}
|
|
310
310
|
@beforeinput=${this.handleEditableBeforeInput}
|
|
@@ -316,13 +316,13 @@ import{a as q}from"./chunks/chunk-E4IS25H7.js";import{a as W}from"./chunks/chunk
|
|
|
316
316
|
@click=${this.handleSelectionChange}
|
|
317
317
|
@focus=${this.handleSelectionChange}
|
|
318
318
|
></div>
|
|
319
|
-
${!this.value&&this.placeholder?
|
|
320
|
-
`}renderField(e){let t=[e?"description":null,this.maxlength!==void 0?"char-count":null].filter(i=>!!i).join(" ");return
|
|
319
|
+
${!this.value&&this.placeholder?f`<span id="editable-placeholder">${this.placeholder}</span>`:b}
|
|
320
|
+
`}renderField(e){let t=[e?"description":null,this.maxlength!==void 0?"char-count":null].filter(i=>!!i).join(" ");return f`
|
|
321
321
|
${this.formatting?this.renderToolbar():b}
|
|
322
322
|
<div id="field-wrapper">
|
|
323
323
|
${this.formatting?this.renderEditableField(t):this.renderNativeField(t)}
|
|
324
324
|
</div>
|
|
325
|
-
${
|
|
325
|
+
${S(this.readonlyAvailable,()=>f`
|
|
326
326
|
<div id="edit-actions">
|
|
327
327
|
<eun-button
|
|
328
328
|
class="confirm"
|
|
@@ -336,7 +336,7 @@ import{a as q}from"./chunks/chunk-E4IS25H7.js";import{a as W}from"./chunks/chunk
|
|
|
336
336
|
<eun-button
|
|
337
337
|
class="cancel"
|
|
338
338
|
size="s"
|
|
339
|
-
|
|
339
|
+
color="critical"
|
|
340
340
|
appearance="flat"
|
|
341
341
|
rounded
|
|
342
342
|
type="button"
|
|
@@ -345,14 +345,14 @@ import{a as q}from"./chunks/chunk-E4IS25H7.js";import{a as W}from"./chunks/chunk
|
|
|
345
345
|
>
|
|
346
346
|
</div>
|
|
347
347
|
`)}
|
|
348
|
-
`}render(){let e=this.readonlyAvailable&&!this.editing,t=this.renderDescription(),i=this.maxlength!==void 0&&!e;return
|
|
348
|
+
`}render(){let e=this.readonlyAvailable&&!this.editing,t=this.renderDescription(),i=this.maxlength!==void 0&&!e;return f`
|
|
349
349
|
<div id="wrapper">
|
|
350
350
|
${this.renderFormLabels(e?void 0:"field")}
|
|
351
351
|
${e?this.renderReadonlyDisplay():this.renderField(t!==b)}
|
|
352
|
-
${
|
|
352
|
+
${S(t!==b||i,()=>f`
|
|
353
353
|
<div id="description-row">
|
|
354
354
|
${t} ${i?this.renderCharCount():b}
|
|
355
355
|
</div>
|
|
356
356
|
`)}
|
|
357
357
|
</div>
|
|
358
|
-
`}};s.styles=[Y,C.base,C.errorMessages,C.hintMessages],c([u({attribute:"default-value"})],s.prototype,"defaultValue",1),c([u()],s.prototype,"placeholder",2),c([u({type:Number,reflect:!0})],s.prototype,"rows",2),c([u({type:Boolean,reflect:!0})],s.prototype,"formatting",2),c([u({attribute:"format-toolbar-label"})],s.prototype,"formatToolbarLabel",2),c([u({attribute:"format-bold-label"})],s.prototype,"formatBoldLabel",2),c([u({attribute:"format-italic-label"})],s.prototype,"formatItalicLabel",2),c([u({attribute:"format-underline-label"})],s.prototype,"formatUnderlineLabel",2),c([u({attribute:"format-align-label"})],s.prototype,"formatAlignLabel",2),c([u({attribute:"format-align-start-label"})],s.prototype,"formatAlignStartLabel",2),c([u({attribute:"format-align-center-label"})],s.prototype,"formatAlignCenterLabel",2),c([u({attribute:"format-align-end-label"})],s.prototype,"formatAlignEndLabel",2),c([u({attribute:"format-align-justify-label"})],s.prototype,"formatAlignJustifyLabel",2),c([u({attribute:"format-text-color-label"})],s.prototype,"formatTextColorLabel",2),c([u({attribute:"format-highlight-label"})],s.prototype,"formatHighlightLabel",2),c([u({attribute:"format-color-clear-label"})],s.prototype,"formatColorClearLabel",2),c([u({attribute:!1})],s.prototype,"colorLabels",2),c([u()],s.prototype,"autocomplete",2),c([u({type:Number})],s.prototype,"minlength",2),c([u({type:Number})],s.prototype,"maxlength",2),c([u({attribute:"empty-value-label"})],s.prototype,"emptyValueLabel",2),c([u({attribute:"confirm-label"})],s.prototype,"confirmLabel",2),c([u({attribute:"cancel-label"})],s.prototype,"cancelLabel",2),c([E()],s.prototype,"openPicker",2),c([E()],s.prototype,"activeTextColor",2),c([E()],s.prototype,"activeHighlight",2),c([k("#field")],s.prototype,"fieldEl",2),c([k("#toolbar")],s.prototype,"toolbarEl",2),s=c([I(
|
|
358
|
+
`}};s.styles=[Y,C.base,C.errorMessages,C.hintMessages],c([u({attribute:"default-value"})],s.prototype,"defaultValue",1),c([u()],s.prototype,"placeholder",2),c([u({type:Number,reflect:!0})],s.prototype,"rows",2),c([u({type:Boolean,reflect:!0})],s.prototype,"formatting",2),c([u({attribute:"format-toolbar-label"})],s.prototype,"formatToolbarLabel",2),c([u({attribute:"format-bold-label"})],s.prototype,"formatBoldLabel",2),c([u({attribute:"format-italic-label"})],s.prototype,"formatItalicLabel",2),c([u({attribute:"format-underline-label"})],s.prototype,"formatUnderlineLabel",2),c([u({attribute:"format-align-label"})],s.prototype,"formatAlignLabel",2),c([u({attribute:"format-align-start-label"})],s.prototype,"formatAlignStartLabel",2),c([u({attribute:"format-align-center-label"})],s.prototype,"formatAlignCenterLabel",2),c([u({attribute:"format-align-end-label"})],s.prototype,"formatAlignEndLabel",2),c([u({attribute:"format-align-justify-label"})],s.prototype,"formatAlignJustifyLabel",2),c([u({attribute:"format-text-color-label"})],s.prototype,"formatTextColorLabel",2),c([u({attribute:"format-highlight-label"})],s.prototype,"formatHighlightLabel",2),c([u({attribute:"format-color-clear-label"})],s.prototype,"formatColorClearLabel",2),c([u({attribute:!1})],s.prototype,"colorLabels",2),c([u()],s.prototype,"autocomplete",2),c([u({type:Number})],s.prototype,"minlength",2),c([u({type:Number})],s.prototype,"maxlength",2),c([u({attribute:"empty-value-label"})],s.prototype,"emptyValueLabel",2),c([u({attribute:"confirm-label"})],s.prototype,"confirmLabel",2),c([u({attribute:"cancel-label"})],s.prototype,"cancelLabel",2),c([E()],s.prototype,"openPicker",2),c([E()],s.prototype,"activeTextColor",2),c([E()],s.prototype,"activeHighlight",2),c([k("#field")],s.prototype,"fieldEl",2),c([k("#toolbar")],s.prototype,"toolbarEl",2),s=c([I(re)],s);export{s as EunomiaTextarea,re as EunomiaTextareaTagName};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as
|
|
1
|
+
import{a as Q,b as $,c as X,d as ee,e as te,f as ie,g as D,h as E,i as oe,j as H,k as re,m as h,o as I,p as ne,q as ae,r as se,s as le}from"./chunks/chunk-JYIIWN2P.js";import"./chunks/chunk-VJCNHMQZ.js";import{a as W}from"./chunks/chunk-LK5BJ4SH.js";import{a as Z}from"./chunks/chunk-UYZR4JXZ.js";import{b as J,c as T}from"./chunks/chunk-624VJYNA.js";import{a as A}from"./chunks/chunk-LYYQAALT.js";import{a as G}from"./chunks/chunk-4PI6RDUS.js";import{a as Y}from"./chunks/chunk-BO3JOEWM.js";import{b as B,c as j,d as U,e as q,f as C}from"./chunks/chunk-VOTRXBDS.js";import{a as P}from"./chunks/chunk-YYCEPZUN.js";import{a as N}from"./chunks/chunk-RS7TWEMQ.js";import{b as R}from"./chunks/chunk-BKZGTCMF.js";import"./chunks/chunk-PPCHQG7P.js";import"./chunks/chunk-SD2H5UDZ.js";import{a as _}from"./chunks/chunk-O7PHBLH2.js";import"./chunks/chunk-SGM2X2TC.js";import{a as K}from"./chunks/chunk-LMVW522V.js";import"./chunks/chunk-KSZRQRN4.js";import{a as r,f as z,h as x,j as s,k as M,l as b,p as d,r as k,u as V}from"./chunks/chunk-YITWLCD3.js";var he=x`
|
|
2
2
|
:host {
|
|
3
3
|
display: block;
|
|
4
4
|
width: 100%;
|
|
@@ -18,8 +18,8 @@ import{a as G,b as T,c as W,d as Z,e as J,f as Q,g as $,h as E,i as X,j as D,k a
|
|
|
18
18
|
outline: 1px solid transparent;
|
|
19
19
|
box-sizing: border-box;
|
|
20
20
|
transition:
|
|
21
|
-
border-color
|
|
22
|
-
outline-color
|
|
21
|
+
border-color var(--eun-duration-s, 150ms) var(--eun-easing-default, ease),
|
|
22
|
+
outline-color var(--eun-duration-s, 150ms) var(--eun-easing-default, ease);
|
|
23
23
|
}
|
|
24
24
|
:host(:not([aria-readonly="true"]))
|
|
25
25
|
#field-wrapper:hover:not(:has(:disabled)) {
|
|
@@ -45,22 +45,22 @@ import{a as G,b as T,c as W,d as Z,e as J,f as Q,g as $,h as E,i as X,j as D,k a
|
|
|
45
45
|
:host([aria-invalid="true"]) #field-wrapper:focus-within {
|
|
46
46
|
outline-color: var(--_errorColor);
|
|
47
47
|
}
|
|
48
|
-
:host([
|
|
48
|
+
:host([appearance="flat"]) {
|
|
49
49
|
--_background: var(--field-background, var(--eun-content-hover, #edeff0));
|
|
50
50
|
}
|
|
51
|
-
:host([
|
|
51
|
+
:host([appearance="flat"]) #field-wrapper {
|
|
52
52
|
border-color: transparent;
|
|
53
53
|
}
|
|
54
|
-
:host([
|
|
54
|
+
:host([appearance="flat"][aria-invalid="true"]) #field-wrapper {
|
|
55
55
|
box-shadow: inset 0 0 0 var(--eun-border-width-m, 1.5px) var(--_errorColor);
|
|
56
56
|
}
|
|
57
|
-
:host([
|
|
57
|
+
:host([appearance="underline"]) #field-wrapper {
|
|
58
58
|
border: none;
|
|
59
59
|
outline: none;
|
|
60
60
|
border-bottom: var(--eun-border-width-m, 1.5px) solid var(--_borderColor);
|
|
61
61
|
border-radius: 0;
|
|
62
62
|
}
|
|
63
|
-
:host([
|
|
63
|
+
:host([appearance="underline"]) #field-wrapper:focus-within {
|
|
64
64
|
outline: none;
|
|
65
65
|
}
|
|
66
66
|
.segment-group {
|
|
@@ -110,7 +110,8 @@ import{a as G,b as T,c as W,d as Z,e as J,f as Q,g as $,h as E,i as X,j as D,k a
|
|
|
110
110
|
color: var(--_iconColor);
|
|
111
111
|
outline: 2px solid transparent;
|
|
112
112
|
cursor: pointer;
|
|
113
|
-
transition: outline
|
|
113
|
+
transition: outline var(--eun-duration-m, 200ms)
|
|
114
|
+
var(--eun-easing-out, ease-out);
|
|
114
115
|
}
|
|
115
116
|
#clock-trigger:hover:not(:disabled) {
|
|
116
117
|
color: var(--_textColor);
|
|
@@ -179,7 +180,7 @@ import{a as G,b as T,c as W,d as Z,e as J,f as Q,g as $,h as E,i as X,j as D,k a
|
|
|
179
180
|
#modal-time .modal-footer {
|
|
180
181
|
padding: var(--eun-space-m);
|
|
181
182
|
}
|
|
182
|
-
`,
|
|
183
|
+
`,ue=[Z,he],fe=x`
|
|
183
184
|
@supports (anchor-name: --a) {
|
|
184
185
|
#clock-popover:popover-open {
|
|
185
186
|
position-try-fallbacks: --eun-time-picker-above;
|
|
@@ -191,7 +192,7 @@ import{a as G,b as T,c as W,d as Z,e as J,f as Q,g as $,h as E,i as X,j as D,k a
|
|
|
191
192
|
bottom: calc(anchor(top) + 4px);
|
|
192
193
|
}
|
|
193
194
|
}
|
|
194
|
-
`,
|
|
195
|
+
`,de=fe;var ve=x`
|
|
195
196
|
.tp-list {
|
|
196
197
|
display: flex;
|
|
197
198
|
flex-direction: column;
|
|
@@ -213,7 +214,8 @@ import{a as G,b as T,c as W,d as Z,e as J,f as Q,g as $,h as E,i as X,j as D,k a
|
|
|
213
214
|
font-variant-numeric: tabular-nums;
|
|
214
215
|
text-align: start;
|
|
215
216
|
cursor: pointer;
|
|
216
|
-
transition: background-color
|
|
217
|
+
transition: background-color var(--eun-duration-s, 150ms)
|
|
218
|
+
var(--eun-easing-default, ease);
|
|
217
219
|
}
|
|
218
220
|
.tp-list-item:hover:not(:disabled) {
|
|
219
221
|
background-color: var(
|
|
@@ -241,20 +243,20 @@ import{a as G,b as T,c as W,d as Z,e as J,f as Q,g as $,h as E,i as X,j as D,k a
|
|
|
241
243
|
cursor: not-allowed;
|
|
242
244
|
opacity: 0.4;
|
|
243
245
|
}
|
|
244
|
-
`,
|
|
246
|
+
`,ce=ve;var be=1440;function pe(u){let{format:g,hour:e,minute:t,locale:i,disabled:n=!1,onPick:c}=u,p=Math.max(1,Math.round(u.stepMinutes)),w=new Intl.DateTimeFormat(i,{hour:"numeric",minute:"2-digit",hourCycle:g===12?"h12":"h23"}),f=[];for(let a=0;a<be;a+=p){let l=Math.floor(a/60),m=a%60;f.push({hour24:l,minute:m,text:w.format(new Date(2e3,0,1,l,m)),selected:l===e&&m===t})}let F=f.findIndex(a=>a.selected),O=F===-1?0:F,v=(a,l)=>{let m=a.querySelectorAll('[role="option"]'),S=Math.min(Math.max(l,0),m.length-1);m[S]?.focus()},me=a=>{let l=a.currentTarget,m=Array.from(l.querySelectorAll('[role="option"]')),S=m.indexOf(document.activeElement),y=S===-1?O:S;switch(a.key){case"ArrowDown":a.preventDefault(),v(l,y+1);break;case"ArrowUp":a.preventDefault(),v(l,y-1);break;case"PageDown":a.preventDefault(),v(l,y+5);break;case"PageUp":a.preventDefault(),v(l,y-5);break;case"Home":a.preventDefault(),v(l,0);break;case"End":a.preventDefault(),v(l,m.length-1);break;case"Enter":case" ":{a.preventDefault();let L=f[y];L&&c(L.hour24,L.minute);break}default:break}};return d`
|
|
245
247
|
<div
|
|
246
248
|
class="tp-list"
|
|
247
249
|
role="listbox"
|
|
248
250
|
aria-label=${u.ariaLabel??"Time"}
|
|
249
251
|
aria-disabled=${n?"true":"false"}
|
|
250
|
-
@keydown=${
|
|
252
|
+
@keydown=${me}
|
|
251
253
|
>
|
|
252
254
|
${f.map((a,l)=>d`
|
|
253
255
|
<button
|
|
254
256
|
type="button"
|
|
255
257
|
role="option"
|
|
256
|
-
class=${
|
|
257
|
-
tabindex=${n?"-1":l===
|
|
258
|
+
class=${_({"tp-list-item":!0,selected:a.selected})}
|
|
259
|
+
tabindex=${n?"-1":l===O?"0":"-1"}
|
|
258
260
|
aria-selected=${a.selected?"true":"false"}
|
|
259
261
|
?disabled=${n}
|
|
260
262
|
@click=${()=>c(a.hour24,a.minute)}
|
|
@@ -263,7 +265,7 @@ import{a as G,b as T,c as W,d as Z,e as J,f as Q,g as $,h as E,i as X,j as D,k a
|
|
|
263
265
|
</button>
|
|
264
266
|
`)}
|
|
265
267
|
</div>
|
|
266
|
-
`}var
|
|
268
|
+
`}var ge="eun-time-picker",ye=N(q(V)),xe=K(W(G(Y(U(j(ye)))))),o=class extends xe{constructor(){super(...arguments);this.stepMinute=1;this.mobileMode="wheel";this.panelMode="columns";this.listStepMinutes=30;this.noAnimation=!1;this.applyLabel="Apply";this.cancelLabel="Cancel";this.ariaLabelClock="Open clock";this.hourPlaceholder="hh";this.minutePlaceholder="mm";this.hideTimezoneLabel=!1;this.isOpen=!1;this.isModalOpen=!1;this.stagingValue=null;this.segments={hour:"",minute:"",period:""};this.checkLocalValidators=()=>{let e=this.resolvedHourFormat();if(Me(this.segments)&&!E(this.segments,e))return{validity:{badInput:!0},message:this.dictionary.validation.invalidTime};if(this.value){let{hour:t,minute:i}=h(this.value,this.timezone),n=re({hour:t,minute:i},H(this.minTime),H(this.maxTime));if(!n.valid)return n.violation==="min"?{validity:{rangeUnderflow:!0},message:this.dictionary.timePicker.mustBeAtOrAfter(this.minTime??"")}:{validity:{rangeOverflow:!0},message:this.dictionary.timePicker.mustBeAtOrBefore(this.maxTime??"")}}return{validity:{}}};this.handleHourColumnChange=e=>{let{minute:t}=h(this.displaySource,this.timezone);this.commitAdjustment(e,t)};this.handleMinuteColumnChange=e=>{let{hour:t}=h(this.displaySource,this.timezone);this.commitAdjustment(t,e)};this.handlePeriodColumnChange=e=>{let{hour:t,minute:i}=h(this.displaySource,this.timezone),{hour:n}=$(t);this.commitAdjustment(X(n,e),i)};this.handleTriggerClick=()=>{if(!(this.disabled||this.readonly)){if(this.resetStaging(),this.panelMode!=="list"&&this.isMobileViewport()){this.isModalOpen=!0;return}this.updateComplete.then(()=>{let e=this.popoverEl;if(!e)return;let t=this.popoverAnimation!==void 0;this.popoverAnimation?.cancel(),this.popoverAnimation=void 0;let i=!e.matches(":popover-open");i&&e.showPopover(),(i||t)&&this.playPopoverOpenAnimation(e)})}};this.handlePopoverToggle=e=>{if(e.newState==="open"){this.isOpen=!0,this.fieldWrapperEl&&this.popoverEl&&this.anchorFloatingElement(this.fieldWrapperEl,this.popoverEl,{forceFallback:A}),this.observeAnchorVisibility(this.fieldWrapperEl,()=>this.closePopover()),this.updateComplete.then(()=>this.panelMode==="list"?this.focusListSelection():this.focusFirstSpinbutton());return}this.isOpen=!1,this.unanchorFloatingElement(),this.unobserveAnchorVisibility(),this.triggerEl?.focus()};this.handleModalConfirm=()=>{this.commitStaged(),this.isModalOpen=!1};this.handleModalCancel=()=>{this.isModalOpen=!1};this.handleListPick=(e,t)=>{this.commitAdjustment(e,t),this.closePopover()};this.handlePeriodSegmentClick=()=>{this.setPeriodSegment(ee(this.segments.period||"AM"))};this.handlePeriodSegmentKeydown=e=>{switch(e.key){case"ArrowUp":case"ArrowDown":case"Enter":case" ":e.preventDefault(),this.handlePeriodSegmentClick();break;case"a":case"A":e.preventDefault(),this.setPeriodSegment("AM");break;case"p":case"P":e.preventDefault(),this.setPeriodSegment("PM");break;case"ArrowLeft":e.preventDefault(),this.focusPreviousSegment("period");break;case"ArrowRight":e.preventDefault(),this.focusNextSegment("period");break;default:break}}}get defaultValue(){return super.defaultValue}set defaultValue(e){super.defaultValue=e}willUpdate(e){let t=e.has("segments")||e.has("minTime")||e.has("maxTime");if(e.has("value")||e.has("timezone")||e.has("hourFormat")||e.has("locale")){let i=this.resolvedHourFormat();if(this.value){let n=h(this.value,this.timezone);this.segments=D(n.hour,n.minute,i)}else this.segments=D(null,null,i);t=!0}t&&this.checkValidity(this.value??null),super.willUpdate(e)}updated(e){super.updated(e),B(e)&&this.setAttribute("aria-invalid",String(this.showError))}getFocusAnchor(){return this.firstSegmentEl??void 0}focus(){super.focus?.(),this.firstSegmentEl?.focus()}isMobileViewport(){return window.matchMedia(R("tablet")).matches}resolvedHourFormat(){return Q(this.locale,this.hourFormat)}get displaySource(){return this.stagingValue??this.value??new Date}resetStaging(){this.stagingValue=this.value??null}commitStaged(){this.value=this.stagingValue,this.dispatchEvent(new P(this.value))}commitAdjustment(e,t){let i=I(this.displaySource,this.timezone,e,t);this.stagingValue=i,!this.isModalOpen&&(this.value=i,this.dispatchEvent(new P(this.value)))}commitTypedTime(e,t){this.value=I(this.value??new Date,this.timezone,e,t),this.dispatchEvent(new P(this.value)),(this.isOpen||this.isModalOpen)&&this.resetStaging()}commitSegmentGroupIfComplete(e){let t=this.resolvedHourFormat();if(!oe(e,t))return;let i=E(e,t);i&&this.commitTypedTime(i.hour,i.minute)}popoverAnimationDuration(e){return this.noAnimation||window.matchMedia("(prefers-reduced-motion: reduce)").matches?0:J(e,"--time-picker-panel-transition-duration","m",200)}playPopoverOpenAnimation(e){e.style.removeProperty("pointer-events");let t=this.popoverAnimationDuration(e);t!==0&&(this.popoverAnimation=e.animate([{opacity:0,transform:"scaleY(0.01)"},{opacity:1,transform:"scaleY(1)"}],{duration:t,easing:T(e),fill:"forwards"}))}closePopover(){let e=this.popoverEl;this.popoverAnimation?.cancel(),this.popoverAnimation=void 0,e?.matches(":popover-open")&&this.playPopoverCloseAnimation(e)}playPopoverCloseAnimation(e){e.style.pointerEvents="none";let t=this.popoverAnimationDuration(e);if(t===0){e.hidePopover();return}let i=e.animate([{opacity:1,transform:"scaleY(1)"},{opacity:0,transform:"scaleY(0.01)"}],{duration:t,easing:T(e),fill:"forwards"});this.popoverAnimation=i,i.finished.then(()=>{this.popoverAnimation===i&&(this.popoverAnimation=void 0),e.hidePopover()}).catch(()=>{})}focusFirstSpinbutton(){(this.isModalOpen?this.shadowRoot:this.popoverEl)?.querySelector('[role="spinbutton"]')?.focus({preventScroll:!0})}focusListSelection(){let e=this.popoverEl?.querySelector('[role="option"][aria-selected="true"]')??this.popoverEl?.querySelector('[role="option"]');e?.focus({preventScroll:!0}),e?.scrollIntoView({block:"center",behavior:this.noAnimation?"instant":"smooth"})}visibleSegmentOrder(){let e=te(this.resolvedHourFormat());return ie(this.locale).filter(t=>e.includes(t))}focusPreviousSegment(e){let t=this.visibleSegmentOrder(),i=t.indexOf(e);i<=0||this.focusSegment(t[i-1])}focusNextSegment(e){let t=this.visibleSegmentOrder(),i=t.indexOf(e);i===-1||i>=t.length-1||this.focusSegment(t[i+1])}focusSegment(e){this.shadowRoot?.querySelector(`.segment-${e}`)?.focus()}handleSegmentInput(e,t){let i=e.target,n=i.value.replace(/\D/g,"").slice(0,2);i.value=n;let c={...this.segments,[t]:n};this.segments=c,n.length===2&&this.focusNextSegment(t),this.commitSegmentGroupIfComplete(c)}handleSegmentKeydown(e,t){let i=e.target;e.key==="Backspace"&&i.value===""||e.key==="ArrowLeft"?(e.preventDefault(),this.focusPreviousSegment(t)):e.key==="ArrowRight"?(e.preventDefault(),this.focusNextSegment(t)):e.key==="ArrowUp"?(e.preventDefault(),this.adjustSegment(t,1)):e.key==="ArrowDown"&&(e.preventDefault(),this.adjustSegment(t,-1))}adjustSegment(e,t){let i=this.resolvedHourFormat(),n=e==="hour"?i===12?{min:1,max:12}:{min:0,max:23}:{min:0,max:59},c=Number(this.segments[e]),p;if(this.segments[e]===""||Number.isNaN(c)){let f=h(this.displaySource,this.timezone);p=e==="hour"?i===12?$(f.hour).hour:f.hour:f.minute}else p=c+t,p>n.max?p=n.min:p<n.min&&(p=n.max);let w={...this.segments,[e]:String(p).padStart(2,"0")};this.segments=w,this.commitSegmentGroupIfComplete(w)}setPeriodSegment(e){if(this.disabled||this.readonly)return;let t={...this.segments,period:e};this.segments=t,this.commitSegmentGroupIfComplete(t)}renderSegment(e){return e==="period"?d`
|
|
267
269
|
<button
|
|
268
270
|
type="button"
|
|
269
271
|
class="segment segment-period"
|
|
@@ -317,7 +319,7 @@ import{a as G,b as T,c as W,d as Z,e as J,f as Q,g as $,h as E,i as X,j as D,k a
|
|
|
317
319
|
<eun-icon name="access_time" size="16"></eun-icon>
|
|
318
320
|
</button>
|
|
319
321
|
</div>
|
|
320
|
-
`}renderTimezoneLabel(){if(this.hideTimezoneLabel||!this.timezone||
|
|
322
|
+
`}renderTimezoneLabel(){if(this.hideTimezoneLabel||!this.timezone||ne(this.timezone))return k;let e=ae(this.value??new Date,this.timezone,{locale:this.locale});return d`<p id="timezone-label">${e}</p>`}renderPanelContent(e){let t=this.resolvedHourFormat(),i=h(this.displaySource,this.timezone),n=i.hour<12?"AM":"PM";return se({visual:e,format:t,hour:i.hour,minute:i.minute,period:n,stepMinute:this.stepMinute,disabled:this.disabled,noAnimation:this.noAnimation,ariaLabelGroup:this.dictionary.timePicker.time,ariaLabelHour:this.dictionary.timePicker.hour,ariaLabelMinute:this.dictionary.timePicker.minute,ariaLabelPeriod:this.dictionary.timePicker.amPm,onHourChange:this.handleHourColumnChange,onMinuteChange:this.handleMinuteColumnChange,onPeriodChange:this.handlePeriodColumnChange})}renderListPanelContent(){let e=this.resolvedHourFormat(),t=h(this.displaySource,this.timezone);return pe({format:e,hour:t.hour,minute:t.minute,locale:this.locale,stepMinutes:this.listStepMinutes,disabled:this.disabled,ariaLabel:this.label??this.dictionary.timePicker.time,onPick:this.handleListPick})}formatModalPreview(){if(!this.stagingValue)return this.dictionary.timePicker.selectATime;let e=this.resolvedHourFormat();return new Intl.DateTimeFormat(this.locale,{hour:"numeric",minute:"2-digit",hourCycle:e===12?"h12":"h23",timeZone:this.timezone}).format(this.stagingValue)}render(){return d`
|
|
321
323
|
<div id="wrapper">
|
|
322
324
|
${this.renderFormLabels("clock-trigger")} ${this.renderField()}
|
|
323
325
|
${this.renderTimezoneLabel()} ${this.renderDescription()}
|
|
@@ -356,4 +358,4 @@ import{a as G,b as T,c as W,d as Z,e as J,f as Q,g as $,h as E,i as X,j as D,k a
|
|
|
356
358
|
</eun-button>
|
|
357
359
|
</div>
|
|
358
360
|
</eun-modal>
|
|
359
|
-
`}};o.styles=[
|
|
361
|
+
`}};o.styles=[ue,...A?[]:[de],le,ce,C.base,C.errorMessages,C.hintMessages],r([s()],o.prototype,"timezone",2),r([s({type:Number,attribute:"hour-format"})],o.prototype,"hourFormat",2),r([s({type:Number,attribute:"step-minute"})],o.prototype,"stepMinute",2),r([s({attribute:"min-time"})],o.prototype,"minTime",2),r([s({attribute:"max-time"})],o.prototype,"maxTime",2),r([s({attribute:"mobile-mode"})],o.prototype,"mobileMode",2),r([s({attribute:"panel-mode"})],o.prototype,"panelMode",2),r([s({type:Number,attribute:"list-step-minutes"})],o.prototype,"listStepMinutes",2),r([s({type:Boolean,reflect:!0,attribute:"no-animation"})],o.prototype,"noAnimation",2),r([s({attribute:"apply-label"})],o.prototype,"applyLabel",2),r([s({attribute:"cancel-label"})],o.prototype,"cancelLabel",2),r([s({attribute:"aria-label-clock"})],o.prototype,"ariaLabelClock",2),r([s({attribute:"hour-placeholder"})],o.prototype,"hourPlaceholder",2),r([s({attribute:"minute-placeholder"})],o.prototype,"minutePlaceholder",2),r([s({type:Boolean,attribute:"hide-timezone-label"})],o.prototype,"hideTimezoneLabel",2),r([s({attribute:"default-value",converter:{fromAttribute:e=>we(e),toAttribute:e=>e?Se(e):null}})],o.prototype,"defaultValue",1),r([M()],o.prototype,"isOpen",2),r([M()],o.prototype,"isModalOpen",2),r([M()],o.prototype,"stagingValue",2),r([M()],o.prototype,"segments",2),r([b("#clock-trigger")],o.prototype,"triggerEl",2),r([b("#clock-popover")],o.prototype,"popoverEl",2),r([b("#field-wrapper")],o.prototype,"fieldWrapperEl",2),r([b("#modal-time")],o.prototype,"modalEl",2),r([b(".segment")],o.prototype,"firstSegmentEl",2),o=r([z(ge)],o);function Me(u){return u.hour!==""||u.minute!==""||u.period!==""}function we(u){if(!u)return null;let g=new Date(u);return Number.isNaN(g.getTime())?null:g}function Se(u){return u?u.toISOString():""}export{o as EunomiaTimePicker,ge as EunomiaTimePickerTagName};
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk-
|
|
1
|
+
import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk-GDBPWZN6.js";import{a as y}from"./chunks/chunk-UP4M7TER.js";import{a as b}from"./chunks/chunk-PPCHQG7P.js";import{a as h}from"./chunks/chunk-O7PHBLH2.js";import"./chunks/chunk-SGM2X2TC.js";import{a as i,f,h as g,j as a,n as d,p as s,r as p,u as m}from"./chunks/chunk-YITWLCD3.js";var c=new Map;function S(r){let n=getComputedStyle(r).getPropertyValue("--toast-stack-gap").trim(),t=Number.parseFloat(n);return Number.isNaN(t)?8:t}function k(r){let n=c.get(r);if(!n||n.length===0)return;let t=0;for(let o=n.length-1;o>=0;o-=1){let l=n[o];l.el.style.setProperty("--_toastStackOffset",`${t}px`);let C=l.el.getBoundingClientRect().height;t+=C+S(l.el)}}function u(r,n){let t=c.get(r)??[];t.some(o=>o.el===n)||(t.push({position:r,el:n}),c.set(r,t)),k(r)}function v(r,n){let t=c.get(r);if(!t)return;let o=t.findIndex(l=>l.el===n);if(o!==-1){if(t.splice(o,1),t.length===0){c.delete(r);return}k(r)}}var T=g`
|
|
2
2
|
:host {
|
|
3
3
|
position: fixed;
|
|
4
4
|
display: block;
|
|
@@ -10,14 +10,17 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
10
10
|
z-index: var(--toast-z-index, 2147483000);
|
|
11
11
|
font-family: var(--eun-font-family, "Mulish", sans-serif);
|
|
12
12
|
--_gapEdge: var(--toast-viewport-gap, var(--eun-space-m, 16px));
|
|
13
|
-
--_transitionDuration: var(
|
|
13
|
+
--_transitionDuration: var(
|
|
14
|
+
--toast-transition-duration,
|
|
15
|
+
var(--eun-duration-xl, 300ms)
|
|
16
|
+
);
|
|
14
17
|
--_baseX: var(--_enterX, 0px);
|
|
15
18
|
--_baseY: var(--_enterY, 0px);
|
|
16
19
|
visibility: hidden;
|
|
17
20
|
opacity: 0;
|
|
18
21
|
transition:
|
|
19
|
-
opacity var(--_transitionDuration) ease,
|
|
20
|
-
transform var(--_transitionDuration) ease,
|
|
22
|
+
opacity var(--_transitionDuration) var(--eun-easing-default, ease),
|
|
23
|
+
transform var(--_transitionDuration) var(--eun-easing-default, ease),
|
|
21
24
|
visibility 0s linear var(--_transitionDuration);
|
|
22
25
|
}
|
|
23
26
|
|
|
@@ -27,8 +30,8 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
27
30
|
--_baseX: 0px;
|
|
28
31
|
--_baseY: 0px;
|
|
29
32
|
transition:
|
|
30
|
-
opacity var(--_transitionDuration) ease,
|
|
31
|
-
transform var(--_transitionDuration) ease,
|
|
33
|
+
opacity var(--_transitionDuration) var(--eun-easing-default, ease),
|
|
34
|
+
transform var(--_transitionDuration) var(--eun-easing-default, ease),
|
|
32
35
|
visibility 0s linear 0s;
|
|
33
36
|
}
|
|
34
37
|
|
|
@@ -122,25 +125,25 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
122
125
|
--_titleColor: var(--eun-text-color, #071621);
|
|
123
126
|
}
|
|
124
127
|
:host([severity="info"]) {
|
|
125
|
-
--_background: var(--eun-color-info-
|
|
128
|
+
--_background: var(--eun-color-info-alpha-5, #097faf0d);
|
|
126
129
|
--_backgroundFilled: var(--eun-color-info-100, #097faf);
|
|
127
130
|
--_borderColor: var(--eun-color-info-100, #097faf);
|
|
128
131
|
--_titleColor: var(--eun-color-info-100, #097faf);
|
|
129
132
|
}
|
|
130
133
|
:host([severity="success"]) {
|
|
131
|
-
--_background: var(--eun-color-success-
|
|
134
|
+
--_background: var(--eun-color-success-alpha-5, #1a99480d);
|
|
132
135
|
--_backgroundFilled: var(--eun-color-success-100, #1a9948);
|
|
133
136
|
--_borderColor: var(--eun-color-success-100, #1a9948);
|
|
134
137
|
--_titleColor: var(--eun-color-success-100, #1a9948);
|
|
135
138
|
}
|
|
136
139
|
:host([severity="warning"]) {
|
|
137
|
-
--_background: var(--eun-color-warning-
|
|
140
|
+
--_background: var(--eun-color-warning-alpha-5, #c852070d);
|
|
138
141
|
--_backgroundFilled: var(--eun-color-warning-100, #c85207);
|
|
139
142
|
--_borderColor: var(--eun-color-warning-100, #c85207);
|
|
140
143
|
--_titleColor: var(--eun-color-warning-100, #c85207);
|
|
141
144
|
}
|
|
142
145
|
:host([severity="critical"]) {
|
|
143
|
-
--_background: var(--eun-color-critical-
|
|
146
|
+
--_background: var(--eun-color-critical-alpha-5, #aa00140d);
|
|
144
147
|
--_backgroundFilled: var(--eun-color-critical-100, #aa0014);
|
|
145
148
|
--_borderColor: var(--eun-color-critical-100, #aa0014);
|
|
146
149
|
--_titleColor: var(--eun-color-critical-100, #aa0014);
|
|
@@ -166,8 +169,13 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
166
169
|
/* Every appearance carries the same border box (transparent unless
|
|
167
170
|
drawn), taken out of the padding, so switching appearance or adding a
|
|
168
171
|
--toast-border-* never changes the size. */
|
|
169
|
-
border: var(--_bw) solid
|
|
170
|
-
|
|
172
|
+
border: var(--_bw) solid
|
|
173
|
+
var(--toast-border-color, var(--_frame, transparent));
|
|
174
|
+
padding: var(
|
|
175
|
+
--toast-padding,
|
|
176
|
+
var(--toast-padding-block, max(0px, calc(var(--eun-space-m, 16px) - var(--_bw))))
|
|
177
|
+
var(--toast-padding-inline, max(0px, calc(var(--eun-space-m, 16px) - var(--_bw))))
|
|
178
|
+
);
|
|
171
179
|
border-radius: var(--toast-border-radius, var(--eun-border-radius-m, 8px));
|
|
172
180
|
box-shadow: var(
|
|
173
181
|
--toast-shadow,
|
|
@@ -200,7 +208,10 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
200
208
|
}
|
|
201
209
|
:host([appearance="outline"]) #toast {
|
|
202
210
|
--_frame: var(--_borderColor);
|
|
203
|
-
background: var(
|
|
211
|
+
background: var(
|
|
212
|
+
--toast-background-color,
|
|
213
|
+
var(--eun-surface-color, #ffffff)
|
|
214
|
+
);
|
|
204
215
|
}
|
|
205
216
|
:host([appearance="fill"]) #toast {
|
|
206
217
|
background: var(--toast-background-color, var(--_backgroundFilled));
|
|
@@ -219,14 +230,20 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
219
230
|
}
|
|
220
231
|
|
|
221
232
|
slot[name="icon"] {
|
|
222
|
-
--icon-color: var(
|
|
233
|
+
--icon-color: var(
|
|
234
|
+
--toast-icon-color,
|
|
235
|
+
var(--toast-color, var(--_titleColor))
|
|
236
|
+
);
|
|
223
237
|
grid-column: 1;
|
|
224
238
|
grid-row: 1;
|
|
225
239
|
align-self: center;
|
|
226
240
|
display: flex;
|
|
227
241
|
}
|
|
228
242
|
:host([appearance="fill"]) slot[name="icon"] {
|
|
229
|
-
--icon-color: var(
|
|
243
|
+
--icon-color: var(
|
|
244
|
+
--toast-icon-color,
|
|
245
|
+
var(--toast-color, var(--_onFilled, #fff))
|
|
246
|
+
);
|
|
230
247
|
}
|
|
231
248
|
|
|
232
249
|
#description,
|
|
@@ -267,7 +284,10 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
267
284
|
|
|
268
285
|
:host([closeable]) #toast {
|
|
269
286
|
padding-right: calc(
|
|
270
|
-
var(
|
|
287
|
+
var(
|
|
288
|
+
--toast-padding,
|
|
289
|
+
var(--toast-padding-inline, max(0px, calc(var(--eun-space-s, 8px) - var(--_bw))))
|
|
290
|
+
) +
|
|
271
291
|
var(--eun-space-l, 32px)
|
|
272
292
|
);
|
|
273
293
|
}
|