@eunomia/elements 1.0.0-beta.3 → 1.0.0-beta.4
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/cdn/components/chunks/{chunk-3LMI7KUA.js → chunk-2JLDJFYD.js} +1 -1
- package/dist/cdn/components/chunks/chunk-4MXL6PZC.js +124 -0
- package/dist/cdn/components/chunks/{chunk-32KRPOPV.js → chunk-5XJGYXW7.js} +6 -6
- package/dist/cdn/components/chunks/{chunk-O2HNWH65.js → chunk-5XJLIHAU.js} +7 -7
- package/dist/cdn/components/chunks/{chunk-5GF2Q3NR.js → chunk-74AOAB4X.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-WYMBUIKX.js → chunk-A6KGFALA.js} +4 -4
- package/dist/cdn/components/chunks/chunk-BMQOI7HX.js +371 -0
- package/dist/cdn/components/chunks/{chunk-LJYTHDZP.js → chunk-D2M4BV5Y.js} +6 -6
- package/dist/cdn/components/chunks/{chunk-NEYBPT3D.js → chunk-EJIX2D4Z.js} +2 -2
- package/dist/cdn/components/chunks/{chunk-BYBUXKXC.js → chunk-EOWBYZV7.js} +2 -2
- package/dist/cdn/components/chunks/chunk-EST3M4AO.js +1 -0
- package/dist/cdn/components/chunks/{chunk-TBKKTJOX.js → chunk-GSJEJLFA.js} +3 -3
- package/dist/cdn/components/chunks/{chunk-5RCCZVFZ.js → chunk-IJ5WFMK4.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-RWONCXTF.js → chunk-KVYUNKUO.js} +2 -2
- package/dist/cdn/components/chunks/chunk-LGLQ36QB.js +16 -0
- package/dist/cdn/components/chunks/{chunk-53QH6MPM.js → chunk-NHFWATVN.js} +1 -1
- package/dist/cdn/components/chunks/chunk-OAULRKHQ.js +38 -0
- package/dist/cdn/components/chunks/chunk-P32B7BFD.js +118 -0
- package/dist/cdn/components/chunks/{chunk-ZPFHTJSS.js → chunk-PCM7D3YF.js} +1 -1
- package/dist/cdn/components/chunks/{chunk-ABYEBP57.js → chunk-PED5ATYN.js} +11 -8
- package/dist/cdn/components/chunks/{chunk-ON42P6FI.js → chunk-RJCJXB7Y.js} +5 -5
- package/dist/cdn/components/chunks/{chunk-5C7YND22.js → chunk-S2UCEWNG.js} +8 -8
- package/dist/cdn/components/chunks/{chunk-EAGGN3ZI.js → chunk-SIHZFOTK.js} +9 -9
- package/dist/cdn/components/chunks/{chunk-6UPI7GHJ.js → chunk-UAGCQF23.js} +7 -7
- package/dist/cdn/components/chunks/{chunk-6IILPCSQ.js → chunk-X2AUBZD2.js} +3 -3
- package/dist/cdn/components/chunks/chunk-YGUJJ25C.js +263 -0
- package/dist/cdn/components/eun-alert.js +65 -45
- package/dist/cdn/components/eun-badge.js +1 -1
- package/dist/cdn/components/eun-breadcrumb-item.js +14 -10
- package/dist/cdn/components/eun-breadcrumb.js +11 -7
- package/dist/cdn/components/eun-button.js +1 -1
- package/dist/cdn/components/eun-calendar.js +16 -16
- package/dist/cdn/components/eun-card.js +21 -12
- package/dist/cdn/components/eun-carousel.js +35 -27
- package/dist/cdn/components/eun-check-card.js +3 -3
- package/dist/cdn/components/eun-checkbox-list.js +3 -3
- package/dist/cdn/components/eun-checkbox.js +1 -1
- package/dist/cdn/components/eun-chip.js +45 -207
- package/dist/cdn/components/eun-collapse.js +13 -12
- package/dist/cdn/components/eun-color-picker.js +12 -12
- package/dist/cdn/components/eun-counter.js +8 -8
- package/dist/cdn/components/eun-date-picker.js +50 -50
- package/dist/cdn/components/eun-drawer.js +3 -3
- package/dist/cdn/components/eun-dropdown-button.js +1 -1
- package/dist/cdn/components/eun-dropdown-item.js +6 -6
- package/dist/cdn/components/eun-fab.js +31 -53
- package/dist/cdn/components/eun-icon.js +1 -1
- package/dist/cdn/components/eun-image-card.js +18 -11
- package/dist/cdn/components/eun-image-carousel.js +16 -16
- package/dist/cdn/components/eun-infinite-list.js +1 -1
- package/dist/cdn/components/eun-input-file.js +12 -12
- package/dist/cdn/components/eun-input-phone.js +13 -13
- 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 +29 -11
- package/dist/cdn/components/eun-loader.js +1 -1
- package/dist/cdn/components/eun-modal.js +6 -6
- package/dist/cdn/components/eun-pagination.js +3 -3
- package/dist/cdn/components/eun-password-strength.js +9 -6
- package/dist/cdn/components/eun-progress-bar.js +13 -13
- package/dist/cdn/components/eun-radio-card.js +2 -2
- package/dist/cdn/components/eun-radio-list.js +1 -1
- package/dist/cdn/components/eun-radio.js +1 -1
- package/dist/cdn/components/eun-scheduler-event-editor.js +2 -2
- package/dist/cdn/components/eun-scheduler-event.js +1 -1
- package/dist/cdn/components/eun-scheduler.js +10 -10
- package/dist/cdn/components/eun-search.js +7 -7
- package/dist/cdn/components/eun-select.js +10 -10
- package/dist/cdn/components/eun-sidebar.js +9 -9
- package/dist/cdn/components/eun-skeleton.js +1 -1
- package/dist/cdn/components/eun-slider.js +8 -8
- package/dist/cdn/components/eun-sliding-card.js +4 -3
- package/dist/cdn/components/eun-step.js +8 -8
- package/dist/cdn/components/eun-stepper.js +8 -8
- package/dist/cdn/components/eun-switch.js +10 -10
- package/dist/cdn/components/eun-tab-group.js +19 -11
- package/dist/cdn/components/eun-tab-panel.js +1 -1
- 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-cell.js +1 -1
- package/dist/cdn/components/eun-table-column.js +1 -1
- package/dist/cdn/components/eun-table-header.js +1 -1
- package/dist/cdn/components/eun-table-item.js +1 -1
- package/dist/cdn/components/eun-table-skeleton-row.js +1 -1
- package/dist/cdn/components/eun-table.js +3 -3
- package/dist/cdn/components/eun-tag.js +34 -126
- package/dist/cdn/components/eun-textarea.js +22 -22
- package/dist/cdn/components/eun-time-picker.js +25 -25
- package/dist/cdn/components/eun-toast.js +40 -36
- package/dist/cdn/components/eun-toggle-group.js +199 -66
- package/dist/cdn/components/eun-toggle-item.js +41 -24
- package/dist/cdn/components/eun-toggle.js +11 -8
- package/dist/cdn/components/eun-toolbar.js +14 -7
- package/dist/cdn/components/eun-tooltip.js +122 -87
- 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 +1 -0
- package/dist/cdn/styles/themes/mixins/eunomia-neutrals.mixin.scss +71 -0
- package/dist/cdn/styles/themes/prebuilt-themes/eunomia/eunomia-dark.mixin.scss +3 -13
- package/dist/cdn/styles/themes/prebuilt-themes/eunomia/eunomia.mixin.scss +3 -13
- package/dist/cdn/styles/themes/prebuilt-themes/eunomia/eunomia.theme.css +1 -1
- package/dist/cdn/styles/themes/prebuilt-themes/eunomia/eunomia.theme.scss +2 -0
- package/dist/cdn/styles/themes/prebuilt-themes/fire/eunomia-fire-dark.mixin.scss +3 -13
- package/dist/cdn/styles/themes/prebuilt-themes/fire/eunomia-fire.mixin.scss +3 -13
- 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 +2 -0
- package/dist/cdn/styles/themes/prebuilt-themes/forest/eunomia-forest-dark.mixin.scss +3 -13
- package/dist/cdn/styles/themes/prebuilt-themes/forest/eunomia-forest.mixin.scss +3 -13
- 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 +2 -0
- package/dist/cdn/styles/themes/prebuilt-themes/gold/eunomia-gold-dark.mixin.scss +3 -13
- package/dist/cdn/styles/themes/prebuilt-themes/gold/eunomia-gold.mixin.scss +3 -13
- 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 +2 -0
- package/dist/cdn/styles/themes/prebuilt-themes/ocean/eunomia-ocean-dark.mixin.scss +3 -13
- package/dist/cdn/styles/themes/prebuilt-themes/ocean/eunomia-ocean.mixin.scss +3 -13
- 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 +2 -0
- package/dist/cdn/styles/themes/prebuilt-themes/salmon/eunomia-salmon-dark.mixin.scss +3 -13
- package/dist/cdn/styles/themes/prebuilt-themes/salmon/eunomia-salmon.mixin.scss +3 -13
- 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 +2 -0
- package/dist/cdn/styles/themes/prebuilt-themes/violet/eunomia-violet-dark.mixin.scss +3 -13
- package/dist/cdn/styles/themes/prebuilt-themes/violet/eunomia-violet.mixin.scss +3 -13
- 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 +2 -0
- package/dist/cdn/styles/tools/indexes/eunomia-tools.index.scss +1 -0
- package/dist/cdn/styles/tools/mixins/settings/eunomia-alpha.mixin.scss +39 -0
- package/dist/cdn/styles/tools/mixins/settings/eunomia-border.mixin.scss +3 -3
- package/dist/cdn/styles/tools/mixins/settings/eunomia-font.mixin.scss +12 -12
- package/dist/cdn/styles/tools/mixins/settings/eunomia-radius.mixin.scss +4 -4
- package/dist/components/action/button/button.d.ts +2 -0
- package/dist/components/action/button/button.js +2 -0
- package/dist/components/action/button/button.styles.js +132 -384
- package/dist/components/action/dropdown-button/dropdown-button.d.ts +7 -0
- package/dist/components/action/dropdown-button/dropdown-button.js +11 -0
- package/dist/components/action/dropdown-button/dropdown-button.styles.js +8 -8
- package/dist/components/action/dropdown-button/dropdown-item.styles.js +6 -6
- package/dist/components/action/fab/fab.d.ts +3 -1
- package/dist/components/action/fab/fab.js +3 -1
- package/dist/components/action/fab/fab.styles.js +26 -49
- package/dist/components/action/link/link.d.ts +50 -0
- package/dist/components/action/link/link.js +69 -1
- package/dist/components/action/link/link.styles.js +19 -2
- package/dist/components/action/shared-styles/button-palette.styles.d.ts +27 -0
- package/dist/components/action/shared-styles/button-palette.styles.js +151 -0
- package/dist/components/action/toggle/toggle-group.d.ts +41 -7
- package/dist/components/action/toggle/toggle-group.js +161 -45
- package/dist/components/action/toggle/toggle-group.styles.d.ts +6 -5
- package/dist/components/action/toggle/toggle-group.styles.js +152 -35
- package/dist/components/action/toggle/toggle-item.styles.js +37 -20
- package/dist/components/action/toggle/toggle.d.ts +1 -1
- package/dist/components/action/toggle/toggle.js +1 -1
- package/dist/components/action/toggle/toggle.styles.d.ts +2 -2
- package/dist/components/action/toggle/toggle.styles.js +13 -10
- package/dist/components/alert/alert/alert.d.ts +4 -3
- package/dist/components/alert/alert/alert.js +4 -3
- package/dist/components/alert/alert/alert.styles.js +57 -36
- package/dist/components/alert/drawer/drawer.styles.js +3 -3
- package/dist/components/alert/modal/modal.styles.js +6 -6
- package/dist/components/alert/toast/toast.d.ts +4 -3
- package/dist/components/alert/toast/toast.js +4 -3
- package/dist/components/alert/toast/toast.styles.js +41 -36
- package/dist/components/content/badge/badge.styles.js +1 -1
- package/dist/components/content/card/card.d.ts +4 -4
- package/dist/components/content/card/card.js +4 -4
- package/dist/components/content/card/card.styles.js +19 -10
- package/dist/components/content/card/image-card.d.ts +1 -1
- package/dist/components/content/card/image-card.js +1 -1
- package/dist/components/content/card/image-card.styles.js +17 -10
- package/dist/components/content/card/sliding-card.styles.js +3 -2
- package/dist/components/content/chip/chip.d.ts +16 -7
- package/dist/components/content/chip/chip.js +18 -6
- package/dist/components/content/chip/chip.styles.d.ts +1 -1
- package/dist/components/content/chip/chip.styles.js +43 -207
- package/dist/components/content/collapse/collapse.styles.js +10 -9
- package/dist/components/content/icon/icon.style.js +1 -1
- package/dist/components/content/image-carousel/image-carousel.styles.js +14 -14
- package/dist/components/content/password-strength/password-strength.styles.js +7 -4
- package/dist/components/content/progress-bar/progress-bar.styles.js +9 -9
- package/dist/components/content/shared-styles/tone-surface.styles.d.ts +31 -0
- package/dist/components/content/shared-styles/tone-surface.styles.js +149 -0
- package/dist/components/content/tag/tag.d.ts +16 -6
- package/dist/components/content/tag/tag.js +19 -6
- package/dist/components/content/tag/tag.styles.d.ts +1 -1
- package/dist/components/content/tag/tag.styles.js +40 -125
- package/dist/components/content/tooltip/tooltip.d.ts +15 -4
- package/dist/components/content/tooltip/tooltip.js +21 -4
- package/dist/components/content/tooltip/tooltip.styles.js +115 -79
- package/dist/components/form/checkbox/check-card.styles.js +2 -2
- package/dist/components/form/checkbox/checkbox-list.d.ts +1 -1
- package/dist/components/form/checkbox/checkbox.d.ts +1 -1
- package/dist/components/form/checkbox/checkbox.styles.js +6 -6
- package/dist/components/form/color-picker/color-picker.d.ts +1 -1
- package/dist/components/form/color-picker/color-picker.styles.js +7 -7
- package/dist/components/form/counter/counter.d.ts +1 -1
- package/dist/components/form/counter/counter.styles.js +7 -7
- package/dist/components/form/date-picker/date-picker-day-grid.styles.js +2 -2
- package/dist/components/form/date-picker/date-picker-grid.styles.js +15 -15
- package/dist/components/form/date-picker/date-picker-month-grid.styles.js +1 -1
- package/dist/components/form/date-picker/date-picker-year-grid.styles.js +1 -1
- package/dist/components/form/date-picker/date-picker.d.ts +1 -1
- package/dist/components/form/date-picker/date-picker.styles.js +12 -12
- package/dist/components/form/input/input.d.ts +1 -1
- package/dist/components/form/input-file/input-file.d.ts +1 -1
- package/dist/components/form/input-file/input-file.styles.js +9 -9
- package/dist/components/form/input-phone/input-phone.d.ts +1 -1
- package/dist/components/form/input-phone/input-phone.styles.js +7 -7
- package/dist/components/form/label/label.styles.js +4 -4
- package/dist/components/form/radio/radio-card.styles.js +1 -1
- package/dist/components/form/radio/radio-list.d.ts +1 -1
- package/dist/components/form/radio/radio.d.ts +1 -1
- package/dist/components/form/radio/radio.styles.js +2 -2
- package/dist/components/form/search/search.styles.js +6 -6
- package/dist/components/form/select/select.d.ts +1 -1
- package/dist/components/form/select/select.styles.js +6 -6
- package/dist/components/form/shared-styles/card.styles.js +1 -1
- package/dist/components/form/shared-styles/field.styles.js +7 -7
- package/dist/components/form/shared-styles/form-labels.styles.js +1 -1
- package/dist/components/form/shared-styles/listbox.styles.js +6 -6
- package/dist/components/form/slider/slider.d.ts +1 -1
- package/dist/components/form/slider/slider.styles.js +6 -6
- package/dist/components/form/switch/switch.d.ts +1 -1
- package/dist/components/form/switch/switch.styles.js +8 -8
- package/dist/components/form/textarea/textarea.d.ts +1 -1
- package/dist/components/form/textarea/textarea.styles.js +6 -6
- package/dist/components/form/time-picker/time-picker-columns.styles.js +6 -6
- package/dist/components/form/time-picker/time-picker-list.styles.js +2 -2
- package/dist/components/form/time-picker/time-picker.d.ts +1 -1
- package/dist/components/form/time-picker/time-picker.styles.js +8 -8
- package/dist/components/loader/loader/loader.styles.js +2 -2
- package/dist/components/loader/skeleton/skeleton.styles.js +8 -5
- package/dist/components/navigation/breadcrumb/breadcrumb-item.d.ts +7 -0
- package/dist/components/navigation/breadcrumb/breadcrumb-item.js +15 -1
- package/dist/components/navigation/breadcrumb/breadcrumb-item.styles.js +3 -3
- package/dist/components/navigation/breadcrumb/breadcrumb.d.ts +1 -0
- package/dist/components/navigation/breadcrumb/breadcrumb.js +7 -1
- package/dist/components/navigation/breadcrumb/breadcrumb.styles.js +3 -3
- package/dist/components/navigation/carousel/carousel.d.ts +40 -6
- package/dist/components/navigation/carousel/carousel.js +61 -12
- package/dist/components/navigation/carousel/carousel.styles.js +19 -7
- package/dist/components/navigation/pagination/pagination.styles.js +3 -3
- package/dist/components/navigation/sidebar/sidebar.styles.js +9 -9
- package/dist/components/navigation/stepper/step.styles.js +8 -8
- package/dist/components/navigation/stepper/stepper.styles.js +8 -8
- package/dist/components/navigation/tabs/tab/tab.styles.js +5 -5
- package/dist/components/navigation/tabs/tab-group/tab-group.d.ts +9 -0
- package/dist/components/navigation/tabs/tab-group/tab-group.js +19 -2
- package/dist/components/navigation/tabs/tab-group/tab-group.styles.js +12 -4
- package/dist/components/navigation/tabs/tab-panel/tab-panel.styles.js +1 -1
- package/dist/components/navigation/toolbar/toolbar.d.ts +2 -0
- package/dist/components/navigation/toolbar/toolbar.js +2 -0
- package/dist/components/navigation/toolbar/toolbar.styles.js +16 -7
- package/dist/features/scheduler/calendar/calendar.js +1 -1
- package/dist/features/scheduler/calendar/calendar.styles.js +3 -3
- package/dist/features/scheduler/scheduler/scheduler.styles.js +2 -2
- package/dist/features/scheduler/scheduler-event/scheduler-event.styles.js +2 -2
- package/dist/features/scheduler/scheduler-event-editor/scheduler-event-editor.styles.js +2 -2
- package/dist/features/scheduler/shared/scheduler-event-popover.styles.js +4 -4
- package/dist/features/scheduler/shared/scheduler-hour-grid.styles.js +1 -1
- package/dist/features/scheduler/shared/scheduler-month-view.styles.js +1 -1
- package/dist/features/scheduler/shared/scheduler-year-view.styles.js +1 -1
- package/dist/features/table/native-table.css +11 -11
- package/dist/features/table/table/table.styles.js +2 -2
- package/dist/features/table/table-action-bar/table-action-bar.styles.js +2 -2
- package/dist/features/table/table-cell/table-cell.styles.js +2 -2
- package/dist/features/table/table-column/table-column.styles.js +3 -3
- package/dist/features/table/table-header/table-header.styles.js +4 -4
- package/dist/features/table/table-item/table-item.styles.js +6 -6
- package/dist/features/table/table-skeleton-row/table-skeleton-row.styles.js +1 -1
- package/dist/index.d.ts +4 -4
- package/dist/index.js +5 -2
- package/dist/jsx.d.ts +18 -5
- package/dist/mixins/button.mixin.d.ts +1 -0
- package/dist/mixins/button.mixin.js +10 -0
- package/dist/mixins/check.mixin.d.ts +1 -1
- package/dist/mixins/editable.mixin.d.ts +1 -1
- package/dist/mixins/form.mixin.d.ts +5 -1
- package/dist/mixins/form.mixin.js +32 -12
- package/dist/mixins/overflow-navigation.mixin.js +2 -1
- package/dist/mixins/radio.mixin.d.ts +1 -1
- package/dist/mixins/validators.mixin.d.ts +9 -3
- package/dist/utils/rich-text.utils.d.ts +33 -0
- package/dist/utils/rich-text.utils.js +140 -49
- package/dist/utils/theme-generator.utils.d.ts +24 -3
- package/dist/utils/theme-generator.utils.js +66 -21
- package/package.json +6 -1
- package/styles/themes/eunomia-theme.scss +1 -0
- package/styles/themes/mixins/eunomia-neutrals.mixin.scss +71 -0
- package/styles/themes/prebuilt-themes/eunomia/eunomia-dark.mixin.scss +3 -13
- package/styles/themes/prebuilt-themes/eunomia/eunomia.mixin.scss +3 -13
- package/styles/themes/prebuilt-themes/eunomia/eunomia.theme.scss +2 -0
- package/styles/themes/prebuilt-themes/fire/eunomia-fire-dark.mixin.scss +3 -13
- package/styles/themes/prebuilt-themes/fire/eunomia-fire.mixin.scss +3 -13
- package/styles/themes/prebuilt-themes/fire/eunomia-fire.theme.scss +2 -0
- package/styles/themes/prebuilt-themes/forest/eunomia-forest-dark.mixin.scss +3 -13
- package/styles/themes/prebuilt-themes/forest/eunomia-forest.mixin.scss +3 -13
- package/styles/themes/prebuilt-themes/forest/eunomia-forest.theme.scss +2 -0
- package/styles/themes/prebuilt-themes/gold/eunomia-gold-dark.mixin.scss +3 -13
- package/styles/themes/prebuilt-themes/gold/eunomia-gold.mixin.scss +3 -13
- package/styles/themes/prebuilt-themes/gold/eunomia-gold.theme.scss +2 -0
- package/styles/themes/prebuilt-themes/ocean/eunomia-ocean-dark.mixin.scss +3 -13
- package/styles/themes/prebuilt-themes/ocean/eunomia-ocean.mixin.scss +3 -13
- package/styles/themes/prebuilt-themes/ocean/eunomia-ocean.theme.scss +2 -0
- package/styles/themes/prebuilt-themes/salmon/eunomia-salmon-dark.mixin.scss +3 -13
- package/styles/themes/prebuilt-themes/salmon/eunomia-salmon.mixin.scss +3 -13
- package/styles/themes/prebuilt-themes/salmon/eunomia-salmon.theme.scss +2 -0
- package/styles/themes/prebuilt-themes/violet/eunomia-violet-dark.mixin.scss +3 -13
- package/styles/themes/prebuilt-themes/violet/eunomia-violet.mixin.scss +3 -13
- package/styles/themes/prebuilt-themes/violet/eunomia-violet.theme.scss +2 -0
- package/styles/tools/indexes/eunomia-tools.index.scss +1 -0
- package/styles/tools/mixins/settings/eunomia-alpha.mixin.scss +39 -0
- package/styles/tools/mixins/settings/eunomia-border.mixin.scss +3 -3
- package/styles/tools/mixins/settings/eunomia-font.mixin.scss +12 -12
- package/styles/tools/mixins/settings/eunomia-radius.mixin.scss +4 -4
- package/dist/cdn/components/chunks/chunk-5TH3P53V.js +0 -16
- package/dist/cdn/components/chunks/chunk-KNM5QHDK.js +0 -38
- package/dist/cdn/components/chunks/chunk-MBF52GEL.js +0 -1
- package/dist/cdn/components/chunks/chunk-Z6PJYSC3.js +0 -622
- package/dist/cdn/components/chunks/chunk-ZKPCO5RB.js +0 -262
|
@@ -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-LGLQ36QB.js";import{a as y}from"./chunks/chunk-UP4M7TER.js";import{a as h}from"./chunks/chunk-A4EQSU36.js";import"./chunks/chunk-SGM2X2TC.js";import{a as b}from"./chunks/chunk-5EVP7YNE.js";import{a as i,f,g,h as a,l as d,n as s,p,s as m}from"./chunks/chunk-XH6NREVZ.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;
|
|
@@ -116,16 +116,10 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
116
116
|
}
|
|
117
117
|
|
|
118
118
|
:host(:not([severity])) {
|
|
119
|
-
--_background: var(
|
|
120
|
-
--toast-background-color,
|
|
121
|
-
var(--eun-color-grey-100, #f7f8fa)
|
|
122
|
-
);
|
|
119
|
+
--_background: var(--eun-color-grey-100, #f7f8fa);
|
|
123
120
|
--_backgroundFilled: var(--_background);
|
|
124
|
-
--_borderColor: var(
|
|
125
|
-
|
|
126
|
-
var(--eun-color-grey-300, #dee0e7)
|
|
127
|
-
);
|
|
128
|
-
--_titleColor: var(--toast-color, var(--eun-text-color, #071621));
|
|
121
|
+
--_borderColor: var(--eun-color-grey-300, #dee0e7);
|
|
122
|
+
--_titleColor: var(--eun-text-color, #071621);
|
|
129
123
|
}
|
|
130
124
|
:host([severity="info"]) {
|
|
131
125
|
--_background: var(--eun-color-info-30, #f0f7fa);
|
|
@@ -152,6 +146,7 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
152
146
|
--_titleColor: var(--eun-color-critical-100, #aa0014);
|
|
153
147
|
}
|
|
154
148
|
:host([severity="neutral"]) {
|
|
149
|
+
--_onFilled: var(--eun-color-grey-0, #ffffff);
|
|
155
150
|
--_background: var(--eun-color-grey-200, #ecedf0);
|
|
156
151
|
--_backgroundFilled: var(--eun-color-grey-700, #484e61);
|
|
157
152
|
--_borderColor: var(--eun-color-grey-700, #484e61);
|
|
@@ -167,8 +162,13 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
167
162
|
row-gap: var(--toast-row-gap, var(--eun-space-s, 8px));
|
|
168
163
|
width: 100%;
|
|
169
164
|
box-sizing: border-box;
|
|
170
|
-
|
|
171
|
-
|
|
165
|
+
--_bw: var(--toast-border-width, var(--eun-border-width-s, 1px));
|
|
166
|
+
/* Every appearance carries the same border box (transparent unless
|
|
167
|
+
drawn), taken out of the padding, so switching appearance or adding a
|
|
168
|
+
--toast-border-* never changes the size. */
|
|
169
|
+
border: var(--_bw) solid var(--toast-border-color, var(--_frame, transparent));
|
|
170
|
+
padding: var(--toast-padding, max(0px, calc(var(--eun-space-m, 16px) - var(--_bw))));
|
|
171
|
+
border-radius: var(--toast-border-radius, var(--eun-border-radius-m, 8px));
|
|
172
172
|
box-shadow: var(
|
|
173
173
|
--toast-shadow,
|
|
174
174
|
var(
|
|
@@ -177,7 +177,7 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
177
177
|
rgba(0, 0, 0, 0.05) 0 4px 6px -2px
|
|
178
178
|
)
|
|
179
179
|
);
|
|
180
|
-
font-size: var(--eun-
|
|
180
|
+
font-size: var(--eun-font-size-s, 14px);
|
|
181
181
|
--_contentColor: var(--toast-content-color, var(--eun-text-color, #071621));
|
|
182
182
|
color: var(--_contentColor);
|
|
183
183
|
}
|
|
@@ -191,42 +191,42 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
191
191
|
:host([appearance="default"]) #toast {
|
|
192
192
|
background: linear-gradient(
|
|
193
193
|
to right,
|
|
194
|
-
var(--_borderColor) 4px,
|
|
195
|
-
var(--eun-surface-color, #ffffff) 4px
|
|
194
|
+
var(--toast-border-color, var(--_borderColor)) 4px,
|
|
195
|
+
var(--toast-background-color, var(--eun-surface-color, #ffffff)) 4px
|
|
196
196
|
);
|
|
197
197
|
}
|
|
198
198
|
:host([appearance="flat"]) #toast {
|
|
199
|
-
background: var(--_background);
|
|
199
|
+
background: var(--toast-background-color, var(--_background));
|
|
200
200
|
}
|
|
201
201
|
:host([appearance="outline"]) #toast {
|
|
202
|
-
|
|
203
|
-
|
|
202
|
+
--_frame: var(--_borderColor);
|
|
203
|
+
background: var(--toast-background-color, var(--eun-surface-color, #ffffff));
|
|
204
204
|
}
|
|
205
205
|
:host([appearance="fill"]) #toast {
|
|
206
|
-
background: var(--_backgroundFilled);
|
|
207
|
-
--_contentColor: var(--toast-content-color, #fff);
|
|
206
|
+
background: var(--toast-background-color, var(--_backgroundFilled));
|
|
207
|
+
--_contentColor: var(--toast-content-color, var(--_onFilled, #fff));
|
|
208
208
|
}
|
|
209
209
|
|
|
210
210
|
#heading {
|
|
211
|
-
color: var(--_titleColor);
|
|
212
|
-
font-weight: var(--eun-
|
|
211
|
+
color: var(--toast-color, var(--_titleColor));
|
|
212
|
+
font-weight: var(--eun-font-weight-l, 700);
|
|
213
213
|
grid-column: 2;
|
|
214
214
|
grid-row: 1;
|
|
215
215
|
align-self: center;
|
|
216
216
|
}
|
|
217
217
|
:host([appearance="fill"]) #heading {
|
|
218
|
-
color: #fff;
|
|
218
|
+
color: var(--toast-color, var(--_onFilled, #fff));
|
|
219
219
|
}
|
|
220
220
|
|
|
221
221
|
slot[name="icon"] {
|
|
222
|
-
--icon-color: var(--toast-icon-color, var(--_titleColor));
|
|
222
|
+
--icon-color: var(--toast-icon-color, var(--toast-color, var(--_titleColor)));
|
|
223
223
|
grid-column: 1;
|
|
224
224
|
grid-row: 1;
|
|
225
225
|
align-self: center;
|
|
226
226
|
display: flex;
|
|
227
227
|
}
|
|
228
228
|
:host([appearance="fill"]) slot[name="icon"] {
|
|
229
|
-
--icon-color: var(--toast-icon-color, #fff);
|
|
229
|
+
--icon-color: var(--toast-icon-color, var(--toast-color, var(--_onFilled, #fff)));
|
|
230
230
|
}
|
|
231
231
|
|
|
232
232
|
#description,
|
|
@@ -244,7 +244,10 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
244
244
|
margin-block-end: 0;
|
|
245
245
|
}
|
|
246
246
|
#rich-text a {
|
|
247
|
-
color: var(--_titleColor);
|
|
247
|
+
color: var(--toast-color, var(--_titleColor));
|
|
248
|
+
}
|
|
249
|
+
:host([appearance="fill"]) #rich-text a {
|
|
250
|
+
color: var(--toast-color, var(--_onFilled, #fff));
|
|
248
251
|
}
|
|
249
252
|
|
|
250
253
|
::slotted([slot="description"]) {
|
|
@@ -255,16 +258,17 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
255
258
|
display: inline-block;
|
|
256
259
|
}
|
|
257
260
|
:host([appearance="fill"]) ::slotted([slot="action"]) {
|
|
258
|
-
--link-color: #fff;
|
|
259
|
-
--link-color-hover: #fff;
|
|
260
|
-
--link-color-visited: #fff;
|
|
261
|
-
--link-color-visited-hover: #fff;
|
|
262
|
-
--button-text: #fff;
|
|
261
|
+
--link-color: var(--_onFilled, #fff);
|
|
262
|
+
--link-color-hover: var(--_onFilled, #fff);
|
|
263
|
+
--link-color-visited: var(--_onFilled, #fff);
|
|
264
|
+
--link-color-visited-hover: var(--_onFilled, #fff);
|
|
265
|
+
--button-text: var(--_onFilled, #fff);
|
|
263
266
|
}
|
|
264
267
|
|
|
265
268
|
:host([closeable]) #toast {
|
|
266
269
|
padding-right: calc(
|
|
267
|
-
var(--toast-padding, var(--eun-space-s, 8px)
|
|
270
|
+
var(--toast-padding, max(0px, calc(var(--eun-space-s, 8px) - var(--_bw)))) +
|
|
271
|
+
var(--eun-space-l, 32px)
|
|
268
272
|
);
|
|
269
273
|
}
|
|
270
274
|
#close-button {
|
|
@@ -273,7 +277,7 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
273
277
|
display: flex;
|
|
274
278
|
top: var(--eun-space-s, 8px);
|
|
275
279
|
right: var(--eun-space-s, 8px);
|
|
276
|
-
--button-text: var(--_titleColor);
|
|
280
|
+
--button-text: var(--toast-color, var(--_titleColor));
|
|
277
281
|
--button-focus-outline: var(
|
|
278
282
|
--toast-focus-outline-color,
|
|
279
283
|
var(--eun-color-primary-500, #3d6fff)
|
|
@@ -282,7 +286,7 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
282
286
|
justify-content: center;
|
|
283
287
|
}
|
|
284
288
|
:host([appearance="fill"]) #close-button {
|
|
285
|
-
--button-text: #fff;
|
|
289
|
+
--button-text: var(--toast-color, var(--_onFilled, #fff));
|
|
286
290
|
}
|
|
287
291
|
|
|
288
292
|
@media (prefers-reduced-motion: reduce) {
|
|
@@ -290,7 +294,7 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
290
294
|
transition-duration: 0.01ms;
|
|
291
295
|
}
|
|
292
296
|
}
|
|
293
|
-
`,E=T;var
|
|
297
|
+
`,E=T;var w="eun-toast",F=600,e=class extends m{constructor(){super(...arguments);this.appearance="default";this.position="top-right";this.hideIcon=!1;this.closeable=!0;this.ariaLabelClose="Close";this.duration=5e3;this.open=!0;this.remainingMs=0;this.deadline=0;this.paused=!1;this.exitDispatched=!1;this.stacked=!1;this.handlePauseStart=()=>{this.isPersistent()||this.timerId===void 0||(this.paused=!0,this.remainingMs=Math.max(this.deadline-Date.now(),0),this.clearTimer())};this.handlePauseEnd=()=>{if(this.paused){if(this.paused=!1,this.remainingMs<=0){this.hide();return}this.armTimer()}};this.handleSlotChange=()=>{this.requestUpdate()};this.handleCloseClick=()=>{this.hide()}}connectedCallback(){super.connectedCallback(),this.open&&(this.setAttribute("entering",""),this.enteringFrameId=requestAnimationFrame(()=>{this.enteringFrameId=requestAnimationFrame(()=>{this.enteringFrameId=void 0,this.removeAttribute("entering")})}))}disconnectedCallback(){this.enteringFrameId!==void 0&&(cancelAnimationFrame(this.enteringFrameId),this.enteringFrameId=void 0),this.clearTimer(),this.clearExitDispatch(),this.leaveStack(),super.disconnectedCallback()}updated(t){if(super.updated(t),t.has("open")){this.open?(this.exitDispatched=!1,this.joinStack(),this.scheduleAutoClose()):(this.clearTimer(),this.leaveStack(),this.armExitDispatch());return}t.has("position")&&this.open&&this.stacked&&(v(t.get("position"),this),u(this.position,this)),(t.has("duration")||t.has("severity"))&&this.open&&!this.paused&&this.scheduleAutoClose()}isFixedPositioned(){return getComputedStyle(this).position==="fixed"}joinStack(){this.isFixedPositioned()&&(this.stacked=!0,u(this.position,this))}leaveStack(){this.stacked&&(this.stacked=!1,v(this.position,this))}show(){this.open=!0}hide(){this.open=!1}isPersistent(){return this.severity==="critical"||this.duration<=0}scheduleAutoClose(){this.clearTimer(),!this.isPersistent()&&(this.remainingMs=this.duration,this.paused=!1,this.armTimer())}armTimer(){this.deadline=Date.now()+this.remainingMs,this.timerId=setTimeout(()=>this.hide(),this.remainingMs)}clearTimer(){this.timerId!==void 0&&(clearTimeout(this.timerId),this.timerId=void 0)}armExitDispatch(){this.clearExitDispatch(),this.exitDispatched=!1;let t=()=>{this.exitDispatched||(this.exitDispatched=!0,this.clearExitDispatch(),this.dispatchEvent(new x))};this.exitTransitionListener=o=>{o.target===this&&o.propertyName==="opacity"&&t()},this.addEventListener("transitionend",this.exitTransitionListener),this.exitFallbackId=setTimeout(t,F)}clearExitDispatch(){this.exitTransitionListener&&(this.removeEventListener("transitionend",this.exitTransitionListener),this.exitTransitionListener=void 0),this.exitFallbackId!==void 0&&(clearTimeout(this.exitFallbackId),this.exitFallbackId=void 0)}getIconName(){return y(this.icon,this.severity,"severity")}shouldHideIcon(){return this.hideIcon?!0:this.iconSlotEls.length>0||this.severity?!1:!this.icon}shouldShowCloseButton(){return this.closeable||this.severity==="critical"}hasDescription(){return!!this.richText||this.descriptionSlotEls.length>0}hasAction(){return this.actionSlotEls.length>0}render(){let t=this.severity==="warning"||this.severity==="critical"?"alert":"status",o=this.shouldHideIcon();return s`
|
|
294
298
|
<div
|
|
295
299
|
id="toast"
|
|
296
300
|
role=${t}
|
|
@@ -336,4 +340,4 @@ import{a as x}from"./chunks/chunk-YQU6RVX4.js";import{e as _}from"./chunks/chunk
|
|
|
336
340
|
<slot name="action" @slotchange=${this.handleSlotChange}></slot>
|
|
337
341
|
</div>
|
|
338
342
|
</div>
|
|
339
|
-
`}};e.styles=E,i([a({reflect:!0})],e.prototype,"severity",2),i([a({reflect:!0})],e.prototype,"appearance",2),i([a({reflect:!0})],e.prototype,"position",2),i([a({reflect:!0})],e.prototype,"slide",2),i([a()],e.prototype,"heading",2),i([a()],e.prototype,"icon",2),i([a({type:Boolean,attribute:"hide-icon"})],e.prototype,"hideIcon",2),i([a({attribute:"rich-text"})],e.prototype,"richText",2),i([a({type:Boolean,reflect:!0})],e.prototype,"closeable",2),i([a({attribute:"aria-label-close"})],e.prototype,"ariaLabelClose",2),i([a({type:Number})],e.prototype,"duration",2),i([a({type:Boolean,reflect:!0})],e.prototype,"open",2),i([d({slot:"description"})],e.prototype,"descriptionSlotEls",2),i([d({slot:"action"})],e.prototype,"actionSlotEls",2),i([d({slot:"icon"})],e.prototype,"iconSlotEls",2),e=i([f(
|
|
343
|
+
`}};e.styles=E,i([a({reflect:!0})],e.prototype,"severity",2),i([a({reflect:!0})],e.prototype,"appearance",2),i([a({reflect:!0})],e.prototype,"position",2),i([a({reflect:!0})],e.prototype,"slide",2),i([a()],e.prototype,"heading",2),i([a()],e.prototype,"icon",2),i([a({type:Boolean,attribute:"hide-icon"})],e.prototype,"hideIcon",2),i([a({attribute:"rich-text"})],e.prototype,"richText",2),i([a({type:Boolean,reflect:!0})],e.prototype,"closeable",2),i([a({attribute:"aria-label-close"})],e.prototype,"ariaLabelClose",2),i([a({type:Number})],e.prototype,"duration",2),i([a({type:Boolean,reflect:!0})],e.prototype,"open",2),i([d({slot:"description"})],e.prototype,"descriptionSlotEls",2),i([d({slot:"action"})],e.prototype,"actionSlotEls",2),i([d({slot:"icon"})],e.prototype,"iconSlotEls",2),e=i([f(w)],e);export{e as EunomiaToast,w as EunomiaToastTagName};
|
|
@@ -1,34 +1,131 @@
|
|
|
1
|
-
import{a as T}from"./chunks/chunk-SD2H5UDZ.js";import{a as
|
|
1
|
+
import{a as $}from"./chunks/chunk-EST3M4AO.js";import{a as T}from"./chunks/chunk-SD2H5UDZ.js";import{a as A}from"./chunks/chunk-YYCEPZUN.js";import{a as _}from"./chunks/chunk-T7WABJEJ.js";import{a as b}from"./chunks/chunk-A4EQSU36.js";import"./chunks/chunk-SGM2X2TC.js";import{a as p}from"./chunks/chunk-5EVP7YNE.js";import{a as s,b as g,c as w,d as y,f as k,g as E,h as c,j as x,l as C,n as d,p as v,s as I}from"./chunks/chunk-XH6NREVZ.js";var R=E`
|
|
2
2
|
:host {
|
|
3
3
|
display: inline-flex;
|
|
4
|
+
width: fit-content;
|
|
5
|
+
max-width: 100%;
|
|
6
|
+
--_arrowsColor: var(
|
|
7
|
+
--toggle-group-arrows-color,
|
|
8
|
+
var(--eun-surface-sunken, #f7f8fa)
|
|
9
|
+
);
|
|
10
|
+
--_arrowsBase: var(
|
|
11
|
+
--toggle-group-arrows-color,
|
|
12
|
+
var(--eun-surface-color, #ffffff)
|
|
13
|
+
);
|
|
4
14
|
font-family: var(--eun-font-family, "Mulish", sans-serif);
|
|
5
|
-
font-size: var(--eun-
|
|
15
|
+
font-size: var(--eun-font-size-s, 14px);
|
|
16
|
+
}
|
|
17
|
+
:host([appearance="outline"]),
|
|
18
|
+
:host([appearance="flat"]) {
|
|
19
|
+
--_arrowsColor: var(
|
|
20
|
+
--toggle-group-arrows-color,
|
|
21
|
+
var(--eun-surface-color, #ffffff)
|
|
22
|
+
);
|
|
23
|
+
}
|
|
24
|
+
:host([full]) {
|
|
25
|
+
display: flex;
|
|
26
|
+
width: 100%;
|
|
6
27
|
}
|
|
7
28
|
:host([disabled]) {
|
|
8
29
|
opacity: 0.5;
|
|
9
30
|
}
|
|
10
|
-
#
|
|
31
|
+
#scrollable-wrapper {
|
|
32
|
+
position: relative;
|
|
33
|
+
min-width: 0;
|
|
34
|
+
}
|
|
35
|
+
:host([full]) #scrollable-wrapper {
|
|
36
|
+
width: 100%;
|
|
37
|
+
}
|
|
38
|
+
#scrollable {
|
|
11
39
|
position: relative;
|
|
40
|
+
box-sizing: border-box;
|
|
12
41
|
display: inline-flex;
|
|
42
|
+
max-width: 100%;
|
|
13
43
|
gap: var(--toggle-group-gap, var(--eun-space-xs, 4px));
|
|
14
44
|
padding: var(--toggle-group-padding, 4px);
|
|
15
45
|
border-radius: var(
|
|
16
46
|
--toggle-group-border-radius,
|
|
17
|
-
var(--eun-
|
|
47
|
+
var(--eun-border-radius-m, 8px)
|
|
18
48
|
);
|
|
19
49
|
background: var(
|
|
20
50
|
--toggle-group-background,
|
|
21
|
-
var(--eun-
|
|
51
|
+
var(--eun-surface-sunken, #f7f8fa)
|
|
22
52
|
);
|
|
23
|
-
border: var(--eun-
|
|
53
|
+
border: var(--eun-border-width-s, 1px) solid
|
|
24
54
|
var(--toggle-group-border-color, var(--eun-color-grey-300, #dee0e7));
|
|
55
|
+
scrollbar-width: none;
|
|
56
|
+
overflow-x: hidden;
|
|
25
57
|
}
|
|
26
|
-
|
|
27
|
-
|
|
58
|
+
#scrollable::-webkit-scrollbar {
|
|
59
|
+
display: none;
|
|
60
|
+
}
|
|
61
|
+
:has(#arrows arrow-container.visible) #scrollable {
|
|
62
|
+
overflow-x: scroll;
|
|
63
|
+
}
|
|
64
|
+
:host([full]) #scrollable {
|
|
65
|
+
width: 100%;
|
|
66
|
+
}
|
|
67
|
+
:host([appearance="outline"]) #scrollable,
|
|
68
|
+
:host([appearance="flat"]) #scrollable {
|
|
28
69
|
padding: 0;
|
|
29
|
-
background: transparent;
|
|
70
|
+
background: var(--toggle-group-background, transparent);
|
|
30
71
|
border: none;
|
|
31
72
|
}
|
|
73
|
+
#arrows {
|
|
74
|
+
position: absolute;
|
|
75
|
+
inset: 0;
|
|
76
|
+
z-index: 2;
|
|
77
|
+
pointer-events: none;
|
|
78
|
+
}
|
|
79
|
+
arrow-container {
|
|
80
|
+
position: absolute;
|
|
81
|
+
top: 0;
|
|
82
|
+
height: 100%;
|
|
83
|
+
opacity: 0;
|
|
84
|
+
min-width: 24px;
|
|
85
|
+
pointer-events: none;
|
|
86
|
+
transition: opacity 0.2s ease;
|
|
87
|
+
display: flex;
|
|
88
|
+
align-items: center;
|
|
89
|
+
}
|
|
90
|
+
arrow-container.visible {
|
|
91
|
+
opacity: 1;
|
|
92
|
+
pointer-events: all;
|
|
93
|
+
cursor: pointer;
|
|
94
|
+
}
|
|
95
|
+
arrow-container:nth-of-type(1) {
|
|
96
|
+
left: 0;
|
|
97
|
+
justify-content: flex-start;
|
|
98
|
+
background:
|
|
99
|
+
linear-gradient(
|
|
100
|
+
90deg,
|
|
101
|
+
var(--_arrowsColor) 0%,
|
|
102
|
+
var(--_arrowsColor) 60%,
|
|
103
|
+
transparent 100%
|
|
104
|
+
),
|
|
105
|
+
linear-gradient(
|
|
106
|
+
90deg,
|
|
107
|
+
var(--_arrowsBase) 0%,
|
|
108
|
+
var(--_arrowsBase) 60%,
|
|
109
|
+
transparent 100%
|
|
110
|
+
);
|
|
111
|
+
}
|
|
112
|
+
arrow-container:nth-of-type(2) {
|
|
113
|
+
right: 0;
|
|
114
|
+
justify-content: flex-end;
|
|
115
|
+
background:
|
|
116
|
+
linear-gradient(
|
|
117
|
+
90deg,
|
|
118
|
+
transparent 0%,
|
|
119
|
+
var(--_arrowsColor) 40%,
|
|
120
|
+
var(--_arrowsColor) 100%
|
|
121
|
+
),
|
|
122
|
+
linear-gradient(
|
|
123
|
+
90deg,
|
|
124
|
+
transparent 0%,
|
|
125
|
+
var(--_arrowsBase) 40%,
|
|
126
|
+
var(--_arrowsBase) 100%
|
|
127
|
+
);
|
|
128
|
+
}
|
|
32
129
|
#indicator {
|
|
33
130
|
position: absolute;
|
|
34
131
|
top: var(--toggle-group-padding, 4px);
|
|
@@ -38,7 +135,7 @@ import{a as T}from"./chunks/chunk-SD2H5UDZ.js";import{a as C}from"./chunks/chunk
|
|
|
38
135
|
opacity: 0;
|
|
39
136
|
z-index: 0;
|
|
40
137
|
border-radius: calc(
|
|
41
|
-
var(--toggle-group-border-radius, var(--eun-
|
|
138
|
+
var(--toggle-group-border-radius, var(--eun-border-radius-m, 8px)) - 3px
|
|
42
139
|
);
|
|
43
140
|
background: var(
|
|
44
141
|
--toggle-group-active-background,
|
|
@@ -66,27 +163,36 @@ import{a as T}from"./chunks/chunk-SD2H5UDZ.js";import{a as C}from"./chunks/chunk
|
|
|
66
163
|
--_hoverBackground: var(--toggle-group-hover-background, transparent);
|
|
67
164
|
--_boxShadow: var(--toggle-group-shadow, none);
|
|
68
165
|
--_boxShadow-hover: var(--toggle-group-shadow-hover, var(--_boxShadow));
|
|
166
|
+
--_variantColorDefault: var(--eun-color-primary-500, #3d6fff);
|
|
167
|
+
--_variantTintDefault: var(--eun-color-primary-transparent, #3d6fff33);
|
|
69
168
|
--_variantColor: var(
|
|
70
169
|
--toggle-group-active-background,
|
|
71
|
-
var(--
|
|
170
|
+
var(--_variantColorDefault)
|
|
171
|
+
);
|
|
172
|
+
--_variantTint: var(--_customTint, var(--_variantTintDefault));
|
|
173
|
+
--_customTint: color-mix(
|
|
174
|
+
in srgb,
|
|
175
|
+
var(--toggle-group-active-background) 15%,
|
|
176
|
+
transparent
|
|
72
177
|
);
|
|
73
|
-
--_variantTint: var(--eun-color-primary-transparent, #3d6fff33);
|
|
74
178
|
position: relative;
|
|
75
179
|
z-index: 1;
|
|
76
180
|
display: inline-flex;
|
|
77
181
|
align-items: center;
|
|
182
|
+
flex-shrink: 0;
|
|
78
183
|
gap: var(--eun-space-xs, 4px);
|
|
79
184
|
font: inherit;
|
|
80
185
|
text-transform: capitalize;
|
|
186
|
+
white-space: nowrap;
|
|
81
187
|
cursor: pointer;
|
|
82
188
|
border: none;
|
|
83
189
|
background: transparent;
|
|
84
190
|
color: var(--toggle-group-color, var(--eun-color-grey-600, #666e8a));
|
|
85
191
|
padding: calc(var(--eun-space-xs, 4px) * 1.5) var(--eun-space-m, 16px);
|
|
86
|
-
font-weight: var(--eun-
|
|
192
|
+
font-weight: var(--eun-font-weight-m, 500);
|
|
87
193
|
outline: 2px solid transparent;
|
|
88
194
|
border-radius: calc(
|
|
89
|
-
var(--toggle-group-border-radius, var(--eun-
|
|
195
|
+
var(--toggle-group-border-radius, var(--eun-border-radius-m, 8px)) - 3px
|
|
90
196
|
);
|
|
91
197
|
box-shadow: var(--_boxShadow);
|
|
92
198
|
transition:
|
|
@@ -94,6 +200,13 @@ import{a as T}from"./chunks/chunk-SD2H5UDZ.js";import{a as C}from"./chunks/chunk
|
|
|
94
200
|
color 0.2s ease-out,
|
|
95
201
|
box-shadow 0.2s ease-out;
|
|
96
202
|
}
|
|
203
|
+
:host([full]) button,
|
|
204
|
+
:host([full]) ::slotted(eun-toggle-item) {
|
|
205
|
+
flex: 1 1 0%;
|
|
206
|
+
}
|
|
207
|
+
:host([full]) button {
|
|
208
|
+
justify-content: center;
|
|
209
|
+
}
|
|
97
210
|
:host(:not([disabled])) button:hover {
|
|
98
211
|
box-shadow: var(--_boxShadow-hover);
|
|
99
212
|
}
|
|
@@ -111,13 +224,15 @@ import{a as T}from"./chunks/chunk-SD2H5UDZ.js";import{a as C}from"./chunks/chunk
|
|
|
111
224
|
button[disabled] {
|
|
112
225
|
cursor: not-allowed;
|
|
113
226
|
}
|
|
114
|
-
:host([appearance="default"]) #
|
|
227
|
+
:host([appearance="default"]) #scrollable:has(#indicator) button.active {
|
|
115
228
|
color: var(
|
|
116
229
|
--toggle-group-active-color,
|
|
117
230
|
var(--eun-color-on-primary-500, #ffffff)
|
|
118
231
|
);
|
|
119
232
|
}
|
|
120
|
-
:host([appearance="default"])
|
|
233
|
+
:host([appearance="default"])
|
|
234
|
+
#scrollable:not(:has(#indicator))
|
|
235
|
+
button.active {
|
|
121
236
|
background: var(
|
|
122
237
|
--toggle-group-active-background,
|
|
123
238
|
var(--eun-color-primary-500, #3d6fff)
|
|
@@ -133,85 +248,103 @@ import{a as T}from"./chunks/chunk-SD2H5UDZ.js";import{a as C}from"./chunks/chunk
|
|
|
133
248
|
}
|
|
134
249
|
|
|
135
250
|
button[data-variant="secondary"] {
|
|
136
|
-
--
|
|
137
|
-
--
|
|
251
|
+
--_variantColorDefault: var(--eun-color-secondary-500, #e5a030);
|
|
252
|
+
--_variantTintDefault: var(--eun-color-secondary-transparent, #e5a03033);
|
|
138
253
|
}
|
|
139
254
|
button[data-variant="critical"] {
|
|
140
|
-
--
|
|
141
|
-
--
|
|
255
|
+
--_variantColorDefault: var(--eun-color-critical-100, #aa0014);
|
|
256
|
+
--_variantTintDefault: var(--eun-color-critical-30, #faf0f1);
|
|
142
257
|
}
|
|
143
258
|
button[data-variant="success"] {
|
|
144
|
-
--
|
|
145
|
-
--
|
|
259
|
+
--_variantColorDefault: var(--eun-color-success-100, #1a9948);
|
|
260
|
+
--_variantTintDefault: var(--eun-color-success-30, #f1f9f4);
|
|
146
261
|
}
|
|
147
262
|
button[data-variant="warning"] {
|
|
148
|
-
--
|
|
149
|
-
--
|
|
263
|
+
--_variantColorDefault: var(--eun-color-warning-100, #c85207);
|
|
264
|
+
--_variantTintDefault: var(--eun-color-warning-30, #fcf5f0);
|
|
150
265
|
}
|
|
151
266
|
:host([appearance="outline"]) button,
|
|
152
267
|
:host([appearance="flat"]) button {
|
|
153
268
|
border-radius: var(
|
|
154
269
|
--toggle-group-border-radius,
|
|
155
|
-
var(--eun-
|
|
270
|
+
var(--eun-border-radius-m, 8px)
|
|
156
271
|
);
|
|
157
272
|
}
|
|
158
273
|
:host([appearance="outline"]) button {
|
|
159
|
-
border: var(--eun-
|
|
274
|
+
border: var(--eun-border-width-s, 1px) solid
|
|
160
275
|
var(--toggle-group-border-color, var(--eun-color-grey-300, #dee0e7));
|
|
161
276
|
}
|
|
162
277
|
:host([appearance="flat"]) button {
|
|
163
|
-
border: var(--eun-
|
|
278
|
+
border: var(--eun-border-width-s, 1px) solid
|
|
279
|
+
var(--toggle-group-border-color, transparent);
|
|
164
280
|
}
|
|
165
281
|
:host([appearance="outline"]) button.active,
|
|
166
282
|
:host([appearance="flat"]) button.active {
|
|
167
283
|
background: var(--_variantTint);
|
|
168
|
-
color: var(--_variantColor);
|
|
169
|
-
font-weight: var(--eun-
|
|
284
|
+
color: var(--toggle-group-active-color, var(--_variantColor));
|
|
285
|
+
font-weight: var(--eun-font-weight-b, 700);
|
|
170
286
|
}
|
|
171
287
|
:host([appearance="outline"]) button.active {
|
|
172
288
|
border-color: var(--_variantColor);
|
|
173
289
|
}
|
|
174
290
|
:host([appearance="outline"]:not([disabled])) button:not(.active):hover,
|
|
175
291
|
:host([appearance="flat"]:not([disabled])) button:not(.active):hover {
|
|
176
|
-
color: var(--_variantColor);
|
|
292
|
+
color: var(--toggle-group-hover-color, var(--_variantColor));
|
|
177
293
|
}
|
|
178
294
|
:host([appearance="outline"]) button:focus-visible,
|
|
179
295
|
:host([appearance="flat"]) button:focus-visible {
|
|
180
296
|
outline-color: var(--_variantColor);
|
|
181
|
-
color: var(--_variantColor);
|
|
182
|
-
}
|
|
183
|
-
`;var
|
|
184
|
-
<div
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
|
|
214
|
-
|
|
215
|
-
|
|
297
|
+
color: var(--toggle-group-hover-color, var(--_variantColor));
|
|
298
|
+
}
|
|
299
|
+
`;var m=28,D="eun-toggle-group",u,h,n=class extends $(_(I)){constructor(){super(...arguments);this.options=[];this.value=[];this.single=!1;this.appearance="default";this.full=!1;w(this,u);w(this,h,!1);this.debounceMoveIndicator=T(()=>this.moveIndicator(!0),50);this.handleSlotChange=()=>{this.settleAndSync(!1)}}get totalCount(){return this.options.length+(this.items?.length??0)}get exclusive(){return this.single||this.totalCount===2}get entries(){let e=Array.from(this.trackEl?.querySelectorAll("button")??[]),t=this.options.map((r,o)=>({value:r.value,disabled:!!this.disabled,element:e[o]})),a=(this.items??[]).map(r=>({value:r.value,disabled:!!this.disabled||!!r.disabled,element:r}));return[...t,...a]}connectedCallback(){super.connectedCallback?.(),y(this,u,new ResizeObserver(this.debounceMoveIndicator)),g(this,u).observe(this)}disconnectedCallback(){g(this,u)?.disconnect(),super.disconnectedCallback?.()}firstUpdated(e){super.firstUpdated(e),this.settleAndSync(!1)}updated(e){super.updated(e),e.has("disabled")&&this.removeAttribute("tabindex"),(e.has("value")||e.has("options")||e.has("single")||e.has("appearance")||e.has("full"))&&this.settleAndSync(!0),e.has("disabled")&&this.disabled&&this.items?.forEach(t=>{t.disabled=!0})}whenItemsReady(){let e=new Set((this.items??[]).filter(t=>!customElements.get(t.tagName.toLowerCase())).map(t=>t.tagName.toLowerCase()));return e.size?Promise.all([...e].map(t=>customElements.whenDefined(t))):Promise.resolve()}settleAndSync(e){this.whenItemsReady().then(()=>{this.seedInitialValue(),this.applyExclusiveDefault(),this.syncItems(),this.refreshIndicator(e),this.updateScroll()})}seedInitialValue(){if(g(this,h)||(y(this,h,!0),this.value.length))return;let e=(this.items??[]).filter(t=>t.checked).map(t=>t.value);e.length&&(this.value=this.exclusive?[e[0]]:e)}applyExclusiveDefault(){if(!this.exclusive||this.value.length)return;let[e]=this.entries;e&&(this.value=[e.value])}activateValue(e){if(!this.disabled){if(this.exclusive){if(this.value[0]===e)return;this.value=[e]}else this.value=this.value.includes(e)?this.value.filter(t=>t!==e):[...this.value,e];this.dispatchEvent(new A(this.value))}}activateItem(e){this.disabled||e.disabled||this.activateValue(e.value)}syncItems(){this.items?.length&&(this.items.forEach(e=>{e.checked=this.value.includes(e.value),e.toggleAttribute("exclusive",this.exclusive),e.setAttribute("appearance",this.appearance),e.toggleAttribute("full",this.full)}),this.exclusive&&this.applyRovingTabindex())}whenItemReady(e){return typeof e.updateComplete?.then=="function"?e.updateComplete:customElements.whenDefined(e.tagName.toLowerCase()).then(()=>e.updateComplete)}applyRovingTabindex(){let e=this.entries,t=Math.max(0,e.findIndex(a=>a.value===this.value[0]));e.forEach((a,r)=>{if(a.element.tagName==="BUTTON")return;let o=a.element,i=r===t?"0":"-1";this.whenItemReady(o).then(()=>{o.setAttribute("tabindex",i)})})}refreshIndicator(e){if(!this.exclusive)return;let t=()=>{this.appearance==="default"&&this.moveIndicator(e),this.revealActive(e)},a=this.entries.find(r=>r.value===this.value[0]);if(a&&a.element.tagName!=="BUTTON"){this.whenItemReady(a.element).then(t);return}t()}revealActive(e){let t=this.trackEl,a=this.entries.find(S=>S.value===this.value[0]);if(!t||!a||t.scrollWidth<=t.clientWidth)return;let r=t.getBoundingClientRect(),o=a.element.getBoundingClientRect(),i=o.left-r.left-t.clientLeft,l=i+o.width,f=0;i<m?f=i-m:l>t.clientWidth-m&&(f=l-(t.clientWidth-m)),f&&t.scrollBy({left:f,behavior:e?"smooth":"instant"})}moveIndicator(e){let t=this.indicatorEl;if(!this.exclusive||!t||!this.trackEl)return;let a=this.entries.find(l=>l.value===this.value[0]);if(!a){t.style.opacity="0";return}let r=this.trackEl.getBoundingClientRect(),o=a.element.getBoundingClientRect(),i=o.left-r.left-this.trackEl.clientLeft+this.trackEl.scrollLeft;e||(t.style.transition="none"),t.style.opacity="1",t.style.width=`${Math.floor(o.width)}px`,t.style.transform=`translateX(${Math.floor(i)}px)`,e||(t.getBoundingClientRect(),t.style.transition="")}exclusiveTabIndex(e,t){let a=this.value[0]===e,r=this.value.length===0;return a||r&&t===0?0:-1}handleKeydown(e){if(this.disabled)return;if(!this.exclusive){let l=e.target;this.items?.includes(l)&&(e.key==="Enter"||e.key===" ")&&(e.preventDefault(),this.activateItem(l));return}let t=this.entries;if(!t.length)return;let a=t.findIndex(l=>l.value===this.value[0]),r,o;switch(e.key){case"ArrowRight":case"ArrowDown":r=1,o=a===-1?0:(a+1)%t.length;break;case"ArrowLeft":case"ArrowUp":r=-1,o=a===-1?t.length-1:(a-1+t.length)%t.length;break;case"Home":r=1,o=0;break;case"End":r=-1,o=t.length-1;break;default:return}e.preventDefault();for(let l=0;l<t.length&&t[o]?.disabled;l+=1)o=(o+r+t.length)%t.length;let i=t[o];!i||i.disabled||(this.activateValue(i.value),i.element.focus())}arrowVisible(e){return this.overflowState?["middle",e==="start"?"end":"start"].includes(String(this.overflowState)):!1}isOnOverflow(){let e=this.trackEl;return!!e&&e.scrollWidth>e.clientWidth}render(){let e=this.exclusive,t=e&&this.appearance==="default";return d`
|
|
300
|
+
<div id="scrollable-wrapper">
|
|
301
|
+
<div
|
|
302
|
+
id="scrollable"
|
|
303
|
+
role=${e?"radiogroup":"group"}
|
|
304
|
+
part="track"
|
|
305
|
+
aria-label=${this.ariaLabel??v}
|
|
306
|
+
aria-disabled=${this.disabled?"true":"false"}
|
|
307
|
+
@keydown=${a=>this.handleKeydown(a)}
|
|
308
|
+
@scroll=${this.updateScroll}
|
|
309
|
+
>
|
|
310
|
+
${t?d`<span
|
|
311
|
+
id="indicator"
|
|
312
|
+
part="indicator"
|
|
313
|
+
aria-hidden="true"
|
|
314
|
+
></span>`:v}
|
|
315
|
+
${this.options.map((a,r)=>{let o=this.value.includes(a.value),i=!!a.icon&&!a.showLabel;return d`
|
|
316
|
+
<button
|
|
317
|
+
type="button"
|
|
318
|
+
class=${b({active:o,"icon-only":i})}
|
|
319
|
+
data-value=${a.value}
|
|
320
|
+
data-variant=${p(a.variant)}
|
|
321
|
+
role=${e?"radio":"checkbox"}
|
|
322
|
+
aria-checked=${o?"true":"false"}
|
|
323
|
+
aria-label=${p(i?a.label:void 0)}
|
|
324
|
+
title=${p(i?a.label:void 0)}
|
|
325
|
+
tabindex=${p(e?this.exclusiveTabIndex(a.value,r):void 0)}
|
|
326
|
+
?disabled=${this.disabled}
|
|
327
|
+
@click=${()=>this.activateValue(a.value)}
|
|
328
|
+
>
|
|
329
|
+
${a.icon?d`<eun-icon name=${a.icon} size="16"></eun-icon>`:v}
|
|
330
|
+
${i?v:a.label}
|
|
331
|
+
</button>
|
|
332
|
+
`})}
|
|
333
|
+
<slot @slotchange=${this.handleSlotChange}></slot>
|
|
334
|
+
</div>
|
|
335
|
+
<div id="arrows">
|
|
336
|
+
<arrow-container
|
|
337
|
+
class=${b({visible:this.arrowVisible("start")})}
|
|
338
|
+
@click=${this.scrollItem("back")}
|
|
339
|
+
>
|
|
340
|
+
<eun-icon name="chevron_left"></eun-icon>
|
|
341
|
+
</arrow-container>
|
|
342
|
+
<arrow-container
|
|
343
|
+
class=${b({visible:this.arrowVisible("end")})}
|
|
344
|
+
@click=${this.scrollItem("front")}
|
|
345
|
+
>
|
|
346
|
+
<eun-icon name="chevron_right"></eun-icon>
|
|
347
|
+
</arrow-container>
|
|
348
|
+
</div>
|
|
216
349
|
</div>
|
|
217
|
-
`}};u=new WeakMap,h=new WeakMap,n.styles=[
|
|
350
|
+
`}};u=new WeakMap,h=new WeakMap,n.styles=[R],s([c({type:Array,reflect:!0})],n.prototype,"options",2),s([c({type:Array,reflect:!0})],n.prototype,"value",2),s([c({type:Boolean,reflect:!0})],n.prototype,"single",2),s([c({reflect:!0})],n.prototype,"appearance",2),s([c({type:Boolean,reflect:!0})],n.prototype,"full",2),s([C()],n.prototype,"items",2),s([x("#scrollable")],n.prototype,"trackEl",2),s([x("#indicator")],n.prototype,"indicatorEl",2),n=s([k(D)],n);export{n as EunomiaToggleGroup,D as EunomiaToggleGroupTagName};
|