@statistikzh/leu 0.24.2 → 0.26.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.release-please-manifest.json +1 -1
- package/.storybook/main.ts +18 -53
- package/.storybook/manager.ts +1 -4
- package/.storybook/preview.ts +23 -16
- package/.storybook/theme.ts +1 -1
- package/CHANGELOG.md +21 -0
- package/CONTRIBUTING.md +19 -8
- package/dist/Accordion-B04QkmHz.js +241 -0
- package/dist/Accordion.d.ts +44 -44
- package/dist/Accordion.js +2 -249
- package/dist/Button-BgNUxmo_.d.ts +99 -0
- package/dist/Button-BkhqVjug.js +564 -0
- package/dist/Button.d.ts +2 -85
- package/dist/Button.js +5 -504
- package/dist/ButtonGroup-B8U9fDvM.js +88 -0
- package/dist/ButtonGroup.d.ts +19 -19
- package/dist/ButtonGroup.js +6 -101
- package/dist/ChartWrapper-CSMFwz9e.js +158 -0
- package/dist/ChartWrapper.d.ts +26 -26
- package/dist/ChartWrapper.js +3 -163
- package/dist/Checkbox-Dd1QLpfn.js +198 -0
- package/dist/Checkbox.d.ts +35 -27
- package/dist/Checkbox.js +4 -157
- package/dist/CheckboxGroup-Bz2eWEFL.js +81 -0
- package/dist/CheckboxGroup.d.ts +18 -18
- package/dist/CheckboxGroup.js +5 -82
- package/dist/Chip-DLKM9P7v.d.ts +18 -0
- package/dist/Chip-XAQIIsXq.js +171 -0
- package/dist/Chip.d.ts +2 -18
- package/dist/Chip.js +2 -166
- package/dist/ChipGroup-DLqfK2kn.js +125 -0
- package/dist/ChipGroup-Ta8Ht4jc.d.ts +42 -0
- package/dist/ChipGroup.d.ts +2 -43
- package/dist/ChipGroup.js +3 -132
- package/dist/ChipLink-BAxyQO2M.d.ts +17 -0
- package/dist/ChipLink.d.ts +2 -18
- package/dist/ChipLink.js +28 -28
- package/dist/ChipRemovable-DBjwt0CH.d.ts +25 -0
- package/dist/ChipRemovable.d.ts +2 -26
- package/dist/ChipRemovable.js +42 -43
- package/dist/ChipSelectable-CMJNcE4U.d.ts +32 -0
- package/dist/ChipSelectable.d.ts +2 -33
- package/dist/ChipSelectable.js +63 -72
- package/dist/Dialog-DHuXR_oo.js +241 -0
- package/dist/Dialog.d.ts +28 -28
- package/dist/Dialog.js +3 -240
- package/dist/Dropdown-DtFTePbc.js +155 -0
- package/dist/Dropdown.d.ts +39 -41
- package/dist/Dropdown.js +9 -157
- package/dist/FileInput-b8sbLDPI.js +344 -0
- package/dist/FileInput.d.ts +56 -57
- package/dist/FileInput.js +7 -383
- package/dist/FormAssociatedMixin-Cc74LjbC.d.ts +22 -0
- package/dist/FormAssociatedMixin-DLPvFtbT.js +58 -0
- package/dist/Icon-C_yYuynf.js +186 -0
- package/dist/Icon-Op80LrrO.d.ts +151 -0
- package/dist/Icon.d.ts +2 -4
- package/dist/Icon.js +2 -188
- package/dist/Input-D2THgo7c.d.ts +169 -0
- package/dist/Input-DEOVocTa.js +610 -0
- package/dist/Input.d.ts +2 -166
- package/dist/Input.js +4 -626
- package/dist/LeuElement-BeFrgKes.js +46 -0
- package/dist/LeuElement-pJFU18Xm.d.ts +11 -0
- package/dist/Menu-BeqqtCw6.js +136 -0
- package/dist/Menu-CQdx1ef3.d.ts +43 -0
- package/dist/Menu.d.ts +2 -44
- package/dist/Menu.js +4 -157
- package/dist/MenuItem-DVg8-1Bq.js +219 -0
- package/dist/MenuItem-QcgnRk_7.d.ts +63 -0
- package/dist/MenuItem.d.ts +2 -64
- package/dist/MenuItem.js +3 -227
- package/dist/Message-BhknWvAF.js +252 -0
- package/dist/Message.d.ts +53 -53
- package/dist/Message.js +3 -267
- package/dist/Pagination-CqkHh-Vd.d.ts +76 -0
- package/dist/Pagination-DJI5MIi_.js +226 -0
- package/dist/Pagination.d.ts +2 -76
- package/dist/Pagination.js +7 -240
- package/dist/Placeholder-BJybFwSg.js +95 -0
- package/dist/Placeholder.d.ts +15 -15
- package/dist/Placeholder.js +2 -89
- package/dist/Popup-Btgm2a3D.d.ts +61 -0
- package/dist/Popup-DNlm_9AA.js +195 -0
- package/dist/Popup.d.ts +2 -62
- package/dist/Popup.js +2 -233
- package/dist/ProgressBar-B0wYj1KF.js +167 -0
- package/dist/ProgressBar.d.ts +21 -21
- package/dist/ProgressBar.js +2 -165
- package/dist/Radio-DMCL8c4D.js +160 -0
- package/dist/Radio.d.ts +22 -22
- package/dist/Radio.js +2 -151
- package/dist/RadioGroup-CM6IyBlq.js +171 -0
- package/dist/RadioGroup.d.ts +35 -35
- package/dist/RadioGroup.js +3 -182
- package/dist/Range-B72rtfln.js +496 -0
- package/dist/Range.d.ts +112 -112
- package/dist/Range.js +2 -586
- package/dist/ScrollTop-BFAqBVDR.js +130 -0
- package/dist/ScrollTop.d.ts +21 -21
- package/dist/ScrollTop.js +6 -134
- package/dist/Select-vxl3BvD4.js +618 -0
- package/dist/Select.d.ts +130 -132
- package/dist/Select.js +10 -675
- package/dist/Spinner-CrM1enM0.d.ts +14 -0
- package/dist/Spinner-DDTqijTO.js +56 -0
- package/dist/Spinner.d.ts +2 -14
- package/dist/Spinner.js +2 -52
- package/dist/Table-BgCxfBcm.js +392 -0
- package/dist/Table.d.ts +61 -63
- package/dist/Table.js +8 -427
- package/dist/Tag-DK2KkPIQ.js +76 -0
- package/dist/Tag.d.ts +8 -8
- package/dist/Tag.js +2 -74
- package/dist/VisuallyHidden-OeQvhxYn.d.ts +13 -0
- package/dist/VisuallyHidden-pll3amXE.js +29 -0
- package/dist/VisuallyHidden.d.ts +2 -13
- package/dist/VisuallyHidden.js +2 -25
- package/dist/decorate-DwpAc4D0.js +9 -0
- package/dist/hasSlotController-DSBCVzPD.js +38 -0
- package/dist/hasSlotController-DWPyZ52b.d.ts +19 -0
- package/dist/index.d.ts +33 -30
- package/dist/index.js +35 -45
- package/dist/leu-accordion.d.ts +7 -10
- package/dist/leu-accordion.js +4 -8
- package/dist/leu-button-group.d.ts +7 -10
- package/dist/leu-button-group.js +8 -12
- package/dist/leu-button.d.ts +7 -11
- package/dist/leu-button.js +7 -11
- package/dist/leu-chart-wrapper.d.ts +7 -12
- package/dist/leu-chart-wrapper.js +5 -9
- package/dist/leu-checkbox-group.d.ts +7 -10
- package/dist/leu-checkbox-group.js +7 -10
- package/dist/leu-checkbox.d.ts +7 -11
- package/dist/leu-checkbox.js +6 -8
- package/dist/leu-chip-group.d.ts +7 -12
- package/dist/leu-chip-group.js +5 -10
- package/dist/leu-chip-link.d.ts +7 -11
- package/dist/leu-chip-link.js +5 -8
- package/dist/leu-chip-removable.d.ts +7 -12
- package/dist/leu-chip-removable.js +6 -9
- package/dist/leu-chip-selectable.d.ts +7 -11
- package/dist/leu-chip-selectable.js +5 -8
- package/dist/leu-dialog.d.ts +7 -13
- package/dist/leu-dialog.js +5 -11
- package/dist/leu-dropdown.d.ts +7 -18
- package/dist/leu-dropdown.js +11 -17
- package/dist/leu-file-input.d.ts +7 -13
- package/dist/leu-file-input.js +9 -13
- package/dist/leu-icon.d.ts +7 -10
- package/dist/leu-icon.js +4 -7
- package/dist/leu-input.d.ts +7 -12
- package/dist/leu-input.js +6 -12
- package/dist/leu-menu-item.d.ts +7 -11
- package/dist/leu-menu-item.js +5 -9
- package/dist/leu-menu.d.ts +7 -12
- package/dist/leu-menu.js +6 -10
- package/dist/leu-message.d.ts +7 -11
- package/dist/leu-message.js +5 -10
- package/dist/leu-pagination.d.ts +7 -13
- package/dist/leu-pagination.js +9 -14
- package/dist/leu-placeholder.d.ts +7 -10
- package/dist/leu-placeholder.js +4 -5
- package/dist/leu-popup.d.ts +7 -11
- package/dist/leu-popup.js +4 -8
- package/dist/leu-progress-bar.d.ts +7 -10
- package/dist/leu-progress-bar.js +4 -8
- package/dist/leu-radio-group.d.ts +7 -10
- package/dist/leu-radio-group.js +5 -9
- package/dist/leu-radio.d.ts +7 -10
- package/dist/leu-radio.js +4 -7
- package/dist/leu-range.d.ts +7 -10
- package/dist/leu-range.js +4 -9
- package/dist/leu-scroll-top.d.ts +7 -12
- package/dist/leu-scroll-top.js +8 -13
- package/dist/leu-select.d.ts +7 -19
- package/dist/leu-select.js +12 -19
- package/dist/leu-spinner.d.ts +7 -10
- package/dist/leu-spinner.js +4 -5
- package/dist/leu-table.d.ts +7 -14
- package/dist/leu-table.js +10 -17
- package/dist/leu-tag.d.ts +7 -10
- package/dist/leu-tag.js +4 -7
- package/dist/leu-visually-hidden.d.ts +7 -10
- package/dist/leu-visually-hidden.js +4 -5
- package/dist/utils-hfk5Nwy8.js +28 -0
- package/dist/vscode.html-custom-data.json +7 -8
- package/dist/vue/index.d.ts +5 -9
- package/dist/web-types.json +18 -24
- package/eslint.config.mjs +79 -0
- package/package.json +44 -60
- package/scripts/generate-component/templates/stories/[name].stories.ts +1 -1
- package/src/components/accordion/Accordion.ts +1 -1
- package/src/components/button/Button.ts +76 -5
- package/src/components/button/button.css +37 -9
- package/src/components/button/stories/button.stories.ts +23 -0
- package/src/components/button/test/button.test.ts +214 -9
- package/src/components/button-group/ButtonGroup.ts +1 -6
- package/src/components/button-group/stories/button-group.stories.ts +1 -1
- package/src/components/chart-wrapper/ChartWrapper.ts +1 -1
- package/src/components/chart-wrapper/stories/chart-wrapper.stories.ts +1 -1
- package/src/components/checkbox/Checkbox.ts +76 -12
- package/src/components/checkbox/CheckboxGroup.ts +1 -1
- package/src/components/checkbox/checkbox.css +4 -0
- package/src/components/checkbox/stories/checkbox.stories.ts +26 -3
- package/src/components/checkbox/test/checkbox.test.ts +147 -3
- package/src/components/chip/Chip.ts +1 -1
- package/src/components/chip/ChipGroup.ts +2 -2
- package/src/components/chip/stories/chip-removable.stories.ts +1 -1
- package/src/components/chip/test/chip-removable.test.ts +2 -2
- package/src/components/dialog/Dialog.ts +1 -1
- package/src/components/dialog/stories/dialog.stories.ts +0 -2
- package/src/components/dropdown/Dropdown.ts +1 -1
- package/src/components/dropdown/stories/dropdown.stories.ts +1 -1
- package/src/components/file-input/FileInput.ts +18 -20
- package/src/components/file-input/stories/file-input.stories.ts +2 -2
- package/src/components/file-input/test/file-input.test.ts +14 -1
- package/src/components/icon/Icon.ts +1 -1
- package/src/components/input/Input.ts +18 -7
- package/src/components/input/stories/input.stories.ts +24 -21
- package/src/components/menu/Menu.ts +4 -4
- package/src/components/menu/MenuItem.ts +1 -1
- package/src/components/menu/stories/menu-item.stories.ts +0 -2
- package/src/components/message/Message.ts +1 -1
- package/src/components/message/stories/message.stories.ts +2 -2
- package/src/components/pagination/Pagination.ts +1 -1
- package/src/components/pagination/stories/pagination.stories.ts +3 -3
- package/src/components/pagination/test/pagination.test.ts +1 -1
- package/src/components/placeholder/Placeholder.ts +1 -1
- package/src/components/placeholder/stories/placeholder.stories.ts +1 -1
- package/src/components/popup/Popup.ts +1 -1
- package/src/components/progress-bar/ProgressBar.ts +1 -1
- package/src/components/progress-bar/stories/progress-bar.stories.ts +1 -1
- package/src/components/radio/Radio.ts +1 -1
- package/src/components/radio/RadioGroup.ts +5 -5
- package/src/components/range/Range.ts +1 -1
- package/src/components/range/stories/range.stories.ts +2 -2
- package/src/components/scroll-top/ScrollTop.ts +1 -1
- package/src/components/select/Select.ts +2 -5
- package/src/components/spinner/Spinner.ts +1 -1
- package/src/components/table/Table.ts +1 -1
- package/src/components/tag/Tag.ts +1 -1
- package/src/components/tag/stories/tag.stories.ts +1 -1
- package/src/components/visually-hidden/VisuallyHidden.ts +1 -1
- package/src/docs/contributing.mdx +1 -1
- package/src/docs/installation.mdx +1 -1
- package/src/docs/theme.mdx +1 -1
- package/src/docs/usage.mdx +1 -1
- package/src/global.d.ts +1 -1
- package/src/lib/LeuElement.ts +1 -1
- package/src/lib/mixins/FormAssociatedMixin.ts +115 -0
- package/src/lib/styleMap.ts +1 -1
- package/tsdown.config.ts +35 -0
- package/web-test-runner.config.mjs +20 -2
- package/.eslintrc.json +0 -57
- package/dist/Icon.d-itcQ94ym.d.ts +0 -151
- package/dist/LeuElement-BfXSO7MN.js +0 -42
- package/dist/LeuElement.d-BevHqLUu.d.ts +0 -10
- package/dist/_tslib-CNEFicEt.js +0 -30
- package/dist/components/accordion/Accordion.d.ts +0 -49
- package/dist/components/accordion/Accordion.d.ts.map +0 -1
- package/dist/components/accordion/leu-accordion.d.ts +0 -8
- package/dist/components/accordion/leu-accordion.d.ts.map +0 -1
- package/dist/components/accordion/stories/accordion.stories.d.ts +0 -26
- package/dist/components/accordion/stories/accordion.stories.d.ts.map +0 -1
- package/dist/components/accordion/test/accordion.test.d.ts +0 -2
- package/dist/components/accordion/test/accordion.test.d.ts.map +0 -1
- package/dist/components/button/Button.d.ts +0 -81
- package/dist/components/button/Button.d.ts.map +0 -1
- package/dist/components/button/leu-button.d.ts +0 -8
- package/dist/components/button/leu-button.d.ts.map +0 -1
- package/dist/components/button/stories/button.stories.d.ts +0 -19
- package/dist/components/button/stories/button.stories.d.ts.map +0 -1
- package/dist/components/button/test/button.test.d.ts +0 -3
- package/dist/components/button/test/button.test.d.ts.map +0 -1
- package/dist/components/button-group/ButtonGroup.d.ts +0 -25
- package/dist/components/button-group/ButtonGroup.d.ts.map +0 -1
- package/dist/components/button-group/leu-button-group.d.ts +0 -8
- package/dist/components/button-group/leu-button-group.d.ts.map +0 -1
- package/dist/components/button-group/stories/button-group.stories.d.ts +0 -15
- package/dist/components/button-group/stories/button-group.stories.d.ts.map +0 -1
- package/dist/components/button-group/test/button-group.test.d.ts +0 -3
- package/dist/components/button-group/test/button-group.test.d.ts.map +0 -1
- package/dist/components/chart-wrapper/ChartWrapper.d.ts +0 -34
- package/dist/components/chart-wrapper/ChartWrapper.d.ts.map +0 -1
- package/dist/components/chart-wrapper/leu-chart-wrapper.d.ts +0 -8
- package/dist/components/chart-wrapper/leu-chart-wrapper.d.ts.map +0 -1
- package/dist/components/chart-wrapper/stories/chart-wrapper.stories.d.ts +0 -47
- package/dist/components/chart-wrapper/stories/chart-wrapper.stories.d.ts.map +0 -1
- package/dist/components/chart-wrapper/test/chart-wrapper.test.d.ts +0 -2
- package/dist/components/chart-wrapper/test/chart-wrapper.test.d.ts.map +0 -1
- package/dist/components/checkbox/Checkbox.d.ts +0 -28
- package/dist/components/checkbox/Checkbox.d.ts.map +0 -1
- package/dist/components/checkbox/CheckboxGroup.d.ts +0 -22
- package/dist/components/checkbox/CheckboxGroup.d.ts.map +0 -1
- package/dist/components/checkbox/leu-checkbox-group.d.ts +0 -8
- package/dist/components/checkbox/leu-checkbox-group.d.ts.map +0 -1
- package/dist/components/checkbox/leu-checkbox.d.ts +0 -8
- package/dist/components/checkbox/leu-checkbox.d.ts.map +0 -1
- package/dist/components/checkbox/stories/checkbox-group.stories.d.ts +0 -29
- package/dist/components/checkbox/stories/checkbox-group.stories.d.ts.map +0 -1
- package/dist/components/checkbox/stories/checkbox.stories.d.ts +0 -22
- package/dist/components/checkbox/stories/checkbox.stories.d.ts.map +0 -1
- package/dist/components/checkbox/test/checkbox-group.test.d.ts +0 -3
- package/dist/components/checkbox/test/checkbox-group.test.d.ts.map +0 -1
- package/dist/components/checkbox/test/checkbox.test.d.ts +0 -2
- package/dist/components/checkbox/test/checkbox.test.d.ts.map +0 -1
- package/dist/components/chip/Chip.d.ts +0 -15
- package/dist/components/chip/Chip.d.ts.map +0 -1
- package/dist/components/chip/ChipGroup.d.ts +0 -38
- package/dist/components/chip/ChipGroup.d.ts.map +0 -1
- package/dist/components/chip/ChipLink.d.ts +0 -13
- package/dist/components/chip/ChipLink.d.ts.map +0 -1
- package/dist/components/chip/ChipRemovable.d.ts +0 -21
- package/dist/components/chip/ChipRemovable.d.ts.map +0 -1
- package/dist/components/chip/ChipSelectable.d.ts +0 -28
- package/dist/components/chip/ChipSelectable.d.ts.map +0 -1
- package/dist/components/chip/exports.d.ts +0 -5
- package/dist/components/chip/exports.d.ts.map +0 -1
- package/dist/components/chip/leu-chip-group.d.ts +0 -8
- package/dist/components/chip/leu-chip-group.d.ts.map +0 -1
- package/dist/components/chip/leu-chip-link.d.ts +0 -8
- package/dist/components/chip/leu-chip-link.d.ts.map +0 -1
- package/dist/components/chip/leu-chip-removable.d.ts +0 -8
- package/dist/components/chip/leu-chip-removable.d.ts.map +0 -1
- package/dist/components/chip/leu-chip-selectable.d.ts +0 -8
- package/dist/components/chip/leu-chip-selectable.d.ts.map +0 -1
- package/dist/components/chip/stories/chip-group.stories.d.ts +0 -40
- package/dist/components/chip/stories/chip-group.stories.d.ts.map +0 -1
- package/dist/components/chip/stories/chip-link.stories.d.ts +0 -27
- package/dist/components/chip/stories/chip-link.stories.d.ts.map +0 -1
- package/dist/components/chip/stories/chip-removable.stories.d.ts +0 -21
- package/dist/components/chip/stories/chip-removable.stories.d.ts.map +0 -1
- package/dist/components/chip/stories/chip-selectable.stories.d.ts +0 -35
- package/dist/components/chip/stories/chip-selectable.stories.d.ts.map +0 -1
- package/dist/components/chip/test/chip-group.test.d.ts +0 -4
- package/dist/components/chip/test/chip-group.test.d.ts.map +0 -1
- package/dist/components/chip/test/chip-link.test.d.ts +0 -2
- package/dist/components/chip/test/chip-link.test.d.ts.map +0 -1
- package/dist/components/chip/test/chip-removable.test.d.ts +0 -2
- package/dist/components/chip/test/chip-removable.test.d.ts.map +0 -1
- package/dist/components/chip/test/chip-selectable.test.d.ts +0 -2
- package/dist/components/chip/test/chip-selectable.test.d.ts.map +0 -1
- package/dist/components/chip/test/chip.test.d.ts +0 -2
- package/dist/components/chip/test/chip.test.d.ts.map +0 -1
- package/dist/components/dialog/Dialog.d.ts +0 -29
- package/dist/components/dialog/Dialog.d.ts.map +0 -1
- package/dist/components/dialog/leu-dialog.d.ts +0 -8
- package/dist/components/dialog/leu-dialog.d.ts.map +0 -1
- package/dist/components/dialog/stories/dialog.stories.d.ts +0 -19
- package/dist/components/dialog/stories/dialog.stories.d.ts.map +0 -1
- package/dist/components/dialog/test/dialog.test.d.ts +0 -2
- package/dist/components/dialog/test/dialog.test.d.ts.map +0 -1
- package/dist/components/dropdown/Dropdown.d.ts +0 -40
- package/dist/components/dropdown/Dropdown.d.ts.map +0 -1
- package/dist/components/dropdown/leu-dropdown.d.ts +0 -8
- package/dist/components/dropdown/leu-dropdown.d.ts.map +0 -1
- package/dist/components/dropdown/stories/dropdown.stories.d.ts +0 -25
- package/dist/components/dropdown/stories/dropdown.stories.d.ts.map +0 -1
- package/dist/components/dropdown/test/dropdown.test.d.ts +0 -2
- package/dist/components/dropdown/test/dropdown.test.d.ts.map +0 -1
- package/dist/components/file-input/FileInput.d.ts +0 -62
- package/dist/components/file-input/FileInput.d.ts.map +0 -1
- package/dist/components/file-input/leu-file-input.d.ts +0 -8
- package/dist/components/file-input/leu-file-input.d.ts.map +0 -1
- package/dist/components/file-input/stories/file-input.stories.d.ts +0 -34
- package/dist/components/file-input/stories/file-input.stories.d.ts.map +0 -1
- package/dist/components/file-input/test/file-input.test.d.ts +0 -2
- package/dist/components/file-input/test/file-input.test.d.ts.map +0 -1
- package/dist/components/icon/Icon.d.ts +0 -20
- package/dist/components/icon/Icon.d.ts.map +0 -1
- package/dist/components/icon/leu-icon.d.ts +0 -8
- package/dist/components/icon/leu-icon.d.ts.map +0 -1
- package/dist/components/icon/paths.d.ts +0 -127
- package/dist/components/icon/paths.d.ts.map +0 -1
- package/dist/components/icon/stories/icon.stories.d.ts +0 -32
- package/dist/components/icon/stories/icon.stories.d.ts.map +0 -1
- package/dist/components/icon/test/icon.test.d.ts +0 -2
- package/dist/components/icon/test/icon.test.d.ts.map +0 -1
- package/dist/components/input/Input.d.ts +0 -163
- package/dist/components/input/Input.d.ts.map +0 -1
- package/dist/components/input/leu-input.d.ts +0 -8
- package/dist/components/input/leu-input.d.ts.map +0 -1
- package/dist/components/input/stories/input.stories.d.ts +0 -35
- package/dist/components/input/stories/input.stories.d.ts.map +0 -1
- package/dist/components/input/test/input.test.d.ts +0 -2
- package/dist/components/input/test/input.test.d.ts.map +0 -1
- package/dist/components/menu/Menu.d.ts +0 -39
- package/dist/components/menu/Menu.d.ts.map +0 -1
- package/dist/components/menu/MenuItem.d.ts +0 -61
- package/dist/components/menu/MenuItem.d.ts.map +0 -1
- package/dist/components/menu/leu-menu-item.d.ts +0 -8
- package/dist/components/menu/leu-menu-item.d.ts.map +0 -1
- package/dist/components/menu/leu-menu.d.ts +0 -8
- package/dist/components/menu/leu-menu.d.ts.map +0 -1
- package/dist/components/menu/stories/menu-item.stories.d.ts +0 -24
- package/dist/components/menu/stories/menu-item.stories.d.ts.map +0 -1
- package/dist/components/menu/stories/menu.stories.d.ts +0 -26
- package/dist/components/menu/stories/menu.stories.d.ts.map +0 -1
- package/dist/components/menu/test/menu-item.test.d.ts +0 -3
- package/dist/components/menu/test/menu-item.test.d.ts.map +0 -1
- package/dist/components/menu/test/menu.test.d.ts +0 -4
- package/dist/components/menu/test/menu.test.d.ts.map +0 -1
- package/dist/components/message/Message.d.ts +0 -59
- package/dist/components/message/Message.d.ts.map +0 -1
- package/dist/components/message/leu-message.d.ts +0 -8
- package/dist/components/message/leu-message.d.ts.map +0 -1
- package/dist/components/message/stories/message.stories.d.ts +0 -179
- package/dist/components/message/stories/message.stories.d.ts.map +0 -1
- package/dist/components/message/test/message.test.d.ts +0 -2
- package/dist/components/message/test/message.test.d.ts.map +0 -1
- package/dist/components/pagination/Pagination.d.ts +0 -72
- package/dist/components/pagination/Pagination.d.ts.map +0 -1
- package/dist/components/pagination/leu-pagination.d.ts +0 -8
- package/dist/components/pagination/leu-pagination.d.ts.map +0 -1
- package/dist/components/pagination/stories/pagination.stories.d.ts +0 -25
- package/dist/components/pagination/stories/pagination.stories.d.ts.map +0 -1
- package/dist/components/pagination/test/pagination.test.d.ts +0 -2
- package/dist/components/pagination/test/pagination.test.d.ts.map +0 -1
- package/dist/components/placeholder/Placeholder.d.ts +0 -23
- package/dist/components/placeholder/Placeholder.d.ts.map +0 -1
- package/dist/components/placeholder/leu-placeholder.d.ts +0 -8
- package/dist/components/placeholder/leu-placeholder.d.ts.map +0 -1
- package/dist/components/placeholder/stories/placeholder.stories.d.ts +0 -27
- package/dist/components/placeholder/stories/placeholder.stories.d.ts.map +0 -1
- package/dist/components/placeholder/test/placeholder.test.d.ts +0 -2
- package/dist/components/placeholder/test/placeholder.test.d.ts.map +0 -1
- package/dist/components/popup/Popup.d.ts +0 -57
- package/dist/components/popup/Popup.d.ts.map +0 -1
- package/dist/components/popup/leu-popup.d.ts +0 -8
- package/dist/components/popup/leu-popup.d.ts.map +0 -1
- package/dist/components/popup/stories/popup.stories.d.ts +0 -28
- package/dist/components/popup/stories/popup.stories.d.ts.map +0 -1
- package/dist/components/popup/test/popup.test.d.ts +0 -2
- package/dist/components/popup/test/popup.test.d.ts.map +0 -1
- package/dist/components/progress-bar/ProgressBar.d.ts +0 -25
- package/dist/components/progress-bar/ProgressBar.d.ts.map +0 -1
- package/dist/components/progress-bar/leu-progress-bar.d.ts +0 -8
- package/dist/components/progress-bar/leu-progress-bar.d.ts.map +0 -1
- package/dist/components/progress-bar/stories/progress-bar.stories.d.ts +0 -48
- package/dist/components/progress-bar/stories/progress-bar.stories.d.ts.map +0 -1
- package/dist/components/progress-bar/test/progress-bar.test.d.ts +0 -2
- package/dist/components/progress-bar/test/progress-bar.test.d.ts.map +0 -1
- package/dist/components/radio/Radio.d.ts +0 -24
- package/dist/components/radio/Radio.d.ts.map +0 -1
- package/dist/components/radio/RadioGroup.d.ts +0 -39
- package/dist/components/radio/RadioGroup.d.ts.map +0 -1
- package/dist/components/radio/leu-radio-group.d.ts +0 -8
- package/dist/components/radio/leu-radio-group.d.ts.map +0 -1
- package/dist/components/radio/leu-radio.d.ts +0 -8
- package/dist/components/radio/leu-radio.d.ts.map +0 -1
- package/dist/components/radio/stories/radio-group.stories.d.ts +0 -29
- package/dist/components/radio/stories/radio-group.stories.d.ts.map +0 -1
- package/dist/components/radio/stories/radio.stories.d.ts +0 -22
- package/dist/components/radio/stories/radio.stories.d.ts.map +0 -1
- package/dist/components/radio/test/radio-group.test.d.ts +0 -3
- package/dist/components/radio/test/radio-group.test.d.ts.map +0 -1
- package/dist/components/radio/test/radio.test.d.ts +0 -2
- package/dist/components/radio/test/radio.test.d.ts.map +0 -1
- package/dist/components/range/Range.d.ts +0 -116
- package/dist/components/range/Range.d.ts.map +0 -1
- package/dist/components/range/leu-range.d.ts +0 -8
- package/dist/components/range/leu-range.d.ts.map +0 -1
- package/dist/components/range/stories/range.stories.d.ts +0 -231
- package/dist/components/range/stories/range.stories.d.ts.map +0 -1
- package/dist/components/range/test/range.test.d.ts +0 -2
- package/dist/components/range/test/range.test.d.ts.map +0 -1
- package/dist/components/scroll-top/ScrollTop.d.ts +0 -23
- package/dist/components/scroll-top/ScrollTop.d.ts.map +0 -1
- package/dist/components/scroll-top/leu-scroll-top.d.ts +0 -8
- package/dist/components/scroll-top/leu-scroll-top.d.ts.map +0 -1
- package/dist/components/scroll-top/stories/scroll-top.stories.d.ts +0 -8
- package/dist/components/scroll-top/stories/scroll-top.stories.d.ts.map +0 -1
- package/dist/components/scroll-top/test/scroll-top.test.d.ts +0 -2
- package/dist/components/scroll-top/test/scroll-top.test.d.ts.map +0 -1
- package/dist/components/select/Select.d.ts +0 -145
- package/dist/components/select/Select.d.ts.map +0 -1
- package/dist/components/select/leu-select.d.ts +0 -8
- package/dist/components/select/leu-select.d.ts.map +0 -1
- package/dist/components/select/stories/select.stories.d.ts +0 -23
- package/dist/components/select/stories/select.stories.d.ts.map +0 -1
- package/dist/components/select/test/fixtures.d.ts +0 -2
- package/dist/components/select/test/fixtures.d.ts.map +0 -1
- package/dist/components/select/test/select.test.d.ts +0 -3
- package/dist/components/select/test/select.test.d.ts.map +0 -1
- package/dist/components/spinner/Spinner.d.ts +0 -10
- package/dist/components/spinner/Spinner.d.ts.map +0 -1
- package/dist/components/spinner/leu-spinner.d.ts +0 -8
- package/dist/components/spinner/leu-spinner.d.ts.map +0 -1
- package/dist/components/spinner/stories/spinner.stories.d.ts +0 -16
- package/dist/components/spinner/stories/spinner.stories.d.ts.map +0 -1
- package/dist/components/spinner/test/spinner.test.d.ts +0 -2
- package/dist/components/spinner/test/spinner.test.d.ts.map +0 -1
- package/dist/components/table/Table.d.ts +0 -65
- package/dist/components/table/Table.d.ts.map +0 -1
- package/dist/components/table/leu-table.d.ts +0 -8
- package/dist/components/table/leu-table.d.ts.map +0 -1
- package/dist/components/table/stories/table.stories.d.ts +0 -15
- package/dist/components/table/stories/table.stories.d.ts.map +0 -1
- package/dist/components/table/test/table.test.d.ts +0 -2
- package/dist/components/table/test/table.test.d.ts.map +0 -1
- package/dist/components/tag/Tag.d.ts +0 -13
- package/dist/components/tag/Tag.d.ts.map +0 -1
- package/dist/components/tag/leu-tag.d.ts +0 -8
- package/dist/components/tag/leu-tag.d.ts.map +0 -1
- package/dist/components/tag/stories/tag.stories.d.ts +0 -136
- package/dist/components/tag/stories/tag.stories.d.ts.map +0 -1
- package/dist/components/tag/test/tag.test.d.ts +0 -2
- package/dist/components/tag/test/tag.test.d.ts.map +0 -1
- package/dist/components/visually-hidden/VisuallyHidden.d.ts +0 -9
- package/dist/components/visually-hidden/VisuallyHidden.d.ts.map +0 -1
- package/dist/components/visually-hidden/leu-visually-hidden.d.ts +0 -8
- package/dist/components/visually-hidden/leu-visually-hidden.d.ts.map +0 -1
- package/dist/components/visually-hidden/stories/visually-hidden.stories.d.ts +0 -13
- package/dist/components/visually-hidden/stories/visually-hidden.stories.d.ts.map +0 -1
- package/dist/components/visually-hidden/test/visually-hidden.test.d.ts +0 -2
- package/dist/components/visually-hidden/test/visually-hidden.test.d.ts.map +0 -1
- package/dist/hasSlotController-Bm2tipvG.js +0 -53
- package/dist/hasSlotController.d-emXwVXWF.d.ts +0 -23
- package/dist/index.d.ts.map +0 -1
- package/dist/lib/LeuElement.d.ts +0 -8
- package/dist/lib/LeuElement.d.ts.map +0 -1
- package/dist/lib/a11y.d.ts +0 -11
- package/dist/lib/a11y.d.ts.map +0 -1
- package/dist/lib/hasSlotController.d.ts +0 -20
- package/dist/lib/hasSlotController.d.ts.map +0 -1
- package/dist/lib/styleMap.d.ts +0 -61
- package/dist/lib/styleMap.d.ts.map +0 -1
- package/dist/lib/utils.d.ts +0 -23
- package/dist/lib/utils.d.ts.map +0 -1
- package/dist/styles/style.stories.d.ts +0 -6
- package/dist/styles/style.stories.d.ts.map +0 -1
- package/dist/utils-DBGsNSJW.js +0 -33
- package/rollup.config.js +0 -94
- package/web-dev-server.config.mjs +0 -30
package/dist/Checkbox.d.ts
CHANGED
|
@@ -1,32 +1,40 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import {
|
|
4
|
-
import {
|
|
1
|
+
import { t as LeuElement } from "./LeuElement-pJFU18Xm.js";
|
|
2
|
+
import { t as FormAssociatedMixinType } from "./FormAssociatedMixin-Cc74LjbC.js";
|
|
3
|
+
import { t as LeuIcon } from "./Icon-Op80LrrO.js";
|
|
4
|
+
import { PropertyValues } from "lit";
|
|
5
|
+
import * as lit_html0 from "lit-html";
|
|
5
6
|
|
|
7
|
+
//#region src/components/checkbox/Checkbox.d.ts
|
|
8
|
+
declare const LeuCheckbox_base: (abstract new (...args: any[]) => FormAssociatedMixinType) & typeof LeuElement;
|
|
6
9
|
/**
|
|
7
10
|
* @tagname leu-checkbox
|
|
8
11
|
*/
|
|
9
|
-
declare class LeuCheckbox extends
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
12
|
+
declare class LeuCheckbox extends LeuCheckbox_base {
|
|
13
|
+
static dependencies: {
|
|
14
|
+
"leu-icon": typeof LeuIcon;
|
|
15
|
+
};
|
|
16
|
+
static styles: any[];
|
|
17
|
+
/** @internal */
|
|
18
|
+
static shadowRootOptions: {
|
|
19
|
+
delegatesFocus: boolean;
|
|
20
|
+
clonable?: boolean;
|
|
21
|
+
customElementRegistry?: CustomElementRegistry;
|
|
22
|
+
mode: ShadowRootMode;
|
|
23
|
+
serializable?: boolean;
|
|
24
|
+
slotAssignment?: SlotAssignmentMode;
|
|
25
|
+
};
|
|
26
|
+
required: boolean;
|
|
27
|
+
defaultChecked: boolean;
|
|
28
|
+
protected _checked: boolean;
|
|
29
|
+
set checked(isChecked: boolean);
|
|
30
|
+
get checked(): boolean;
|
|
31
|
+
value: string;
|
|
32
|
+
willUpdate(changedProperties: PropertyValues<this>): void;
|
|
33
|
+
private handleChange;
|
|
34
|
+
private handleInput;
|
|
35
|
+
formResetCallback(): void;
|
|
36
|
+
setFormValue(): void;
|
|
37
|
+
render(): lit_html0.TemplateResult<1>;
|
|
30
38
|
}
|
|
31
|
-
|
|
32
|
-
export { LeuCheckbox };
|
|
39
|
+
//#endregion
|
|
40
|
+
export { LeuCheckbox };
|
package/dist/Checkbox.js
CHANGED
|
@@ -1,158 +1,5 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import {
|
|
5
|
-
import { LeuIcon } from './Icon.js';
|
|
6
|
-
|
|
7
|
-
var css_248z = css`:host {
|
|
8
|
-
--checkbox-color: var(--leu-color-black-40);
|
|
9
|
-
--checkbox-color-disabled: var(--leu-color-black-20);
|
|
10
|
-
--checkbox-color-focus: var(--leu-color-func-cyan);
|
|
11
|
-
|
|
12
|
-
--checkbox-label-color: var(--leu-color-black-100);
|
|
13
|
-
--checkbox-label-color-disabled: var(--checkbox-color-disabled);
|
|
14
|
-
|
|
15
|
-
--checkbox-tick-color: var(--leu-color-black-0);
|
|
16
|
-
|
|
17
|
-
--checkbox-font-regular: var(--leu-font-family-regular);
|
|
18
|
-
|
|
19
|
-
position: relative;
|
|
20
|
-
|
|
21
|
-
display: inline-flex;
|
|
22
|
-
align-items: flex-start;
|
|
23
|
-
gap: 0.5rem;
|
|
24
|
-
|
|
25
|
-
font-family: var(--checkbox-font-regular);
|
|
26
|
-
}
|
|
27
|
-
|
|
28
|
-
.checkbox {
|
|
29
|
-
--_length: 1.5rem;
|
|
30
|
-
-webkit-appearance: none;
|
|
31
|
-
-moz-appearance: none;
|
|
32
|
-
appearance: none;
|
|
33
|
-
cursor: pointer;
|
|
34
|
-
|
|
35
|
-
width: 1.5rem;
|
|
36
|
-
|
|
37
|
-
width: var(--_length);
|
|
38
|
-
height: 1.5rem;
|
|
39
|
-
height: var(--_length);
|
|
40
|
-
margin: 0;
|
|
41
|
-
|
|
42
|
-
border: 2px solid var(--checkbox-color);
|
|
43
|
-
border-radius: 2px;
|
|
44
|
-
|
|
45
|
-
flex: 1 0 1.5rem;
|
|
46
|
-
|
|
47
|
-
flex: 1 0 var(--_length);
|
|
48
|
-
|
|
49
|
-
display: grid;
|
|
50
|
-
align-items: center;
|
|
51
|
-
justify-items: center;
|
|
52
|
-
place-items: center;
|
|
53
|
-
}
|
|
54
|
-
|
|
55
|
-
.checkbox:checked {
|
|
56
|
-
background-color: var(--checkbox-color);
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
.checkbox:checked {
|
|
60
|
-
--checkbox-color: var(--checkbox-color-focus);
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
.checkbox:hover, .checkbox:focus {
|
|
64
|
-
--checkbox-color: var(--checkbox-color-focus);
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
.checkbox:focus-visible {
|
|
68
|
-
outline: 2px solid var(--checkbox-color-focus);
|
|
69
|
-
outline-offset: 2px;
|
|
70
|
-
}
|
|
71
|
-
|
|
72
|
-
.checkbox:disabled {
|
|
73
|
-
--checkbox-color: var(--checkbox-color-disabled);
|
|
74
|
-
cursor: not-allowed;
|
|
75
|
-
}
|
|
76
|
-
|
|
77
|
-
.label {
|
|
78
|
-
cursor: pointer;
|
|
79
|
-
color: var(--checkbox-label-color);
|
|
80
|
-
font-size: 1rem;
|
|
81
|
-
line-height: 1.5;
|
|
82
|
-
}
|
|
83
|
-
|
|
84
|
-
.checkbox:disabled + .label {
|
|
85
|
-
--checkbox-label-color: var(--checkbox-label-color-disabled);
|
|
86
|
-
cursor: not-allowed;
|
|
87
|
-
}
|
|
88
|
-
|
|
89
|
-
.icon {
|
|
90
|
-
position: absolute;
|
|
91
|
-
display: block;
|
|
92
|
-
top: 0;
|
|
93
|
-
left: 0;
|
|
94
|
-
color: var(--checkbox-tick-color);
|
|
95
|
-
pointer-events: none;
|
|
96
|
-
}
|
|
97
|
-
`;
|
|
98
|
-
|
|
99
|
-
/**
|
|
100
|
-
* @tagname leu-checkbox
|
|
101
|
-
*/
|
|
102
|
-
class LeuCheckbox extends LeuElement {
|
|
103
|
-
constructor() {
|
|
104
|
-
super(...arguments);
|
|
105
|
-
this.checked = false;
|
|
106
|
-
this.disabled = false;
|
|
107
|
-
this.value = "";
|
|
108
|
-
this.name = "";
|
|
109
|
-
}
|
|
110
|
-
handleChange(event) {
|
|
111
|
-
this.checked = event.target.checked;
|
|
112
|
-
const customEvent = new CustomEvent(event.type, event);
|
|
113
|
-
this.dispatchEvent(customEvent);
|
|
114
|
-
}
|
|
115
|
-
handleInput(event) {
|
|
116
|
-
this.checked = event.target.checked;
|
|
117
|
-
}
|
|
118
|
-
render() {
|
|
119
|
-
return html `
|
|
120
|
-
<input
|
|
121
|
-
id=${`checkbox-${this.name}`}
|
|
122
|
-
class="checkbox"
|
|
123
|
-
type="checkbox"
|
|
124
|
-
name="${this.name}"
|
|
125
|
-
@change=${this.handleChange}
|
|
126
|
-
@input=${this.handleInput}
|
|
127
|
-
.checked=${this.checked}
|
|
128
|
-
?disabled=${this.disabled}
|
|
129
|
-
.value=${this.value ?? ""}
|
|
130
|
-
/>
|
|
131
|
-
<label for=${`checkbox-${this.name}`} class="label"><slot></slot></label>
|
|
132
|
-
<leu-icon class="icon" name="check"></leu-icon>
|
|
133
|
-
`;
|
|
134
|
-
}
|
|
135
|
-
}
|
|
136
|
-
LeuCheckbox.dependencies = {
|
|
137
|
-
"leu-icon": LeuIcon,
|
|
138
|
-
};
|
|
139
|
-
LeuCheckbox.styles = [LeuElement.styles, css_248z];
|
|
140
|
-
/** @internal */
|
|
141
|
-
LeuCheckbox.shadowRootOptions = {
|
|
142
|
-
...LeuElement.shadowRootOptions,
|
|
143
|
-
delegatesFocus: true,
|
|
144
|
-
};
|
|
145
|
-
__decorate([
|
|
146
|
-
property({ type: Boolean, reflect: true })
|
|
147
|
-
], LeuCheckbox.prototype, "checked", void 0);
|
|
148
|
-
__decorate([
|
|
149
|
-
property({ type: Boolean, reflect: true })
|
|
150
|
-
], LeuCheckbox.prototype, "disabled", void 0);
|
|
151
|
-
__decorate([
|
|
152
|
-
property({ type: String, reflect: true })
|
|
153
|
-
], LeuCheckbox.prototype, "value", void 0);
|
|
154
|
-
__decorate([
|
|
155
|
-
property({ type: String, reflect: true })
|
|
156
|
-
], LeuCheckbox.prototype, "name", void 0);
|
|
157
|
-
|
|
1
|
+
import "./LeuElement-BeFrgKes.js";
|
|
2
|
+
import "./Icon-C_yYuynf.js";
|
|
3
|
+
import "./FormAssociatedMixin-DLPvFtbT.js";
|
|
4
|
+
import { t as LeuCheckbox } from "./Checkbox-Dd1QLpfn.js";
|
|
158
5
|
export { LeuCheckbox };
|
|
@@ -0,0 +1,81 @@
|
|
|
1
|
+
import { t as LeuElement } from "./LeuElement-BeFrgKes.js";
|
|
2
|
+
import { t as __decorate } from "./decorate-DwpAc4D0.js";
|
|
3
|
+
import { t as LeuCheckbox } from "./Checkbox-Dd1QLpfn.js";
|
|
4
|
+
import { css, html } from "lit";
|
|
5
|
+
import { property } from "lit/decorators.js";
|
|
6
|
+
import { classMap } from "lit/directives/class-map.js";
|
|
7
|
+
//#region src/components/checkbox/checkbox-group.css?inline
|
|
8
|
+
var checkbox_group_default = css`:host {
|
|
9
|
+
--group-font-regular: var(--leu-font-family-regular);
|
|
10
|
+
--group-font-black: var(--leu-font-family-black);
|
|
11
|
+
|
|
12
|
+
font-family: var(--group-font-regular);
|
|
13
|
+
}
|
|
14
|
+
|
|
15
|
+
.fieldset {
|
|
16
|
+
display: flex;
|
|
17
|
+
align-items: flex-start;
|
|
18
|
+
flex-wrap: wrap;
|
|
19
|
+
gap: 0.5rem 1rem;
|
|
20
|
+
|
|
21
|
+
border: none;
|
|
22
|
+
padding: 0;
|
|
23
|
+
}
|
|
24
|
+
|
|
25
|
+
.fieldset--vertical {
|
|
26
|
+
flex-direction: column;
|
|
27
|
+
gap: 1rem;
|
|
28
|
+
}
|
|
29
|
+
|
|
30
|
+
.legend {
|
|
31
|
+
font-family: var(--group-font-black);
|
|
32
|
+
font-size: 1.125rem;
|
|
33
|
+
line-height: 1.5;
|
|
34
|
+
|
|
35
|
+
margin-bottom: 0.5rem;
|
|
36
|
+
}
|
|
37
|
+
`;
|
|
38
|
+
//#endregion
|
|
39
|
+
//#region src/components/checkbox/CheckboxGroup.ts
|
|
40
|
+
/**
|
|
41
|
+
*
|
|
42
|
+
* @slot - Place the checkboxes inside the default slot.
|
|
43
|
+
* @tagname leu-checkbox-group
|
|
44
|
+
*/
|
|
45
|
+
var LeuCheckboxGroup = class extends LeuElement {
|
|
46
|
+
constructor(..._args) {
|
|
47
|
+
super(..._args);
|
|
48
|
+
this.orientation = "horizontal";
|
|
49
|
+
this.items = [];
|
|
50
|
+
}
|
|
51
|
+
static {
|
|
52
|
+
this.styles = [LeuElement.styles, checkbox_group_default];
|
|
53
|
+
}
|
|
54
|
+
get value() {
|
|
55
|
+
return this.items.filter((i) => i.checked).map((i) => i.value);
|
|
56
|
+
}
|
|
57
|
+
handleSlotChange() {
|
|
58
|
+
this.items = Array.from(this.querySelectorAll(":scope > *:not([slot])")).filter((el) => el instanceof LeuCheckbox);
|
|
59
|
+
}
|
|
60
|
+
render() {
|
|
61
|
+
return html`
|
|
62
|
+
<fieldset class=${classMap({
|
|
63
|
+
fieldset: "true",
|
|
64
|
+
"fieldset--vertical": this.orientation === "vertical"
|
|
65
|
+
})}>
|
|
66
|
+
${this.label ? html`<legend class="legend">${this.label}</legend>` : html``}
|
|
67
|
+
<slot @slotchange=${this.handleSlotChange}></slot>
|
|
68
|
+
</fieldset>
|
|
69
|
+
`;
|
|
70
|
+
}
|
|
71
|
+
};
|
|
72
|
+
__decorate([property({
|
|
73
|
+
type: String,
|
|
74
|
+
reflect: true
|
|
75
|
+
})], LeuCheckboxGroup.prototype, "orientation", void 0);
|
|
76
|
+
__decorate([property({
|
|
77
|
+
type: String,
|
|
78
|
+
reflect: true
|
|
79
|
+
})], LeuCheckboxGroup.prototype, "label", void 0);
|
|
80
|
+
//#endregion
|
|
81
|
+
export { LeuCheckboxGroup as t };
|
package/dist/CheckboxGroup.d.ts
CHANGED
|
@@ -1,26 +1,26 @@
|
|
|
1
|
-
import
|
|
2
|
-
import * as
|
|
3
|
-
import { L as LeuElement } from './LeuElement.d-BevHqLUu.js';
|
|
1
|
+
import { t as LeuElement } from "./LeuElement-pJFU18Xm.js";
|
|
2
|
+
import * as lit_html0 from "lit-html";
|
|
4
3
|
|
|
4
|
+
//#region src/components/checkbox/CheckboxGroup.d.ts
|
|
5
5
|
/**
|
|
6
6
|
*
|
|
7
7
|
* @slot - Place the checkboxes inside the default slot.
|
|
8
8
|
* @tagname leu-checkbox-group
|
|
9
9
|
*/
|
|
10
10
|
declare class LeuCheckboxGroup extends LeuElement {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
11
|
+
static styles: any[];
|
|
12
|
+
/**
|
|
13
|
+
* Defines how the checkboxes should be aligned.
|
|
14
|
+
*/
|
|
15
|
+
orientation: "horizontal" | "vertical";
|
|
16
|
+
/**
|
|
17
|
+
* The label of the checkbox group
|
|
18
|
+
*/
|
|
19
|
+
label?: string;
|
|
20
|
+
private items;
|
|
21
|
+
get value(): string[];
|
|
22
|
+
private handleSlotChange;
|
|
23
|
+
render(): lit_html0.TemplateResult<1>;
|
|
24
24
|
}
|
|
25
|
-
|
|
26
|
-
export { LeuCheckboxGroup };
|
|
25
|
+
//#endregion
|
|
26
|
+
export { LeuCheckboxGroup };
|
package/dist/CheckboxGroup.js
CHANGED
|
@@ -1,83 +1,6 @@
|
|
|
1
|
-
import
|
|
2
|
-
import
|
|
3
|
-
import
|
|
4
|
-
import
|
|
5
|
-
import {
|
|
6
|
-
import { LeuCheckbox } from './Checkbox.js';
|
|
7
|
-
import './Icon.js';
|
|
8
|
-
|
|
9
|
-
var css_248z = css`:host {
|
|
10
|
-
--group-font-regular: var(--leu-font-family-regular);
|
|
11
|
-
--group-font-black: var(--leu-font-family-black);
|
|
12
|
-
|
|
13
|
-
font-family: var(--group-font-regular);
|
|
14
|
-
}
|
|
15
|
-
|
|
16
|
-
.fieldset {
|
|
17
|
-
display: flex;
|
|
18
|
-
align-items: flex-start;
|
|
19
|
-
flex-wrap: wrap;
|
|
20
|
-
gap: 0.5rem 1rem;
|
|
21
|
-
|
|
22
|
-
border: none;
|
|
23
|
-
padding: 0;
|
|
24
|
-
}
|
|
25
|
-
|
|
26
|
-
.fieldset--vertical {
|
|
27
|
-
flex-direction: column;
|
|
28
|
-
gap: 1rem;
|
|
29
|
-
}
|
|
30
|
-
|
|
31
|
-
.legend {
|
|
32
|
-
font-family: var(--group-font-black);
|
|
33
|
-
font-size: 1.125rem;
|
|
34
|
-
line-height: 1.5;
|
|
35
|
-
|
|
36
|
-
margin-bottom: 0.5rem;
|
|
37
|
-
}
|
|
38
|
-
`;
|
|
39
|
-
|
|
40
|
-
/**
|
|
41
|
-
*
|
|
42
|
-
* @slot - Place the checkboxes inside the default slot.
|
|
43
|
-
* @tagname leu-checkbox-group
|
|
44
|
-
*/
|
|
45
|
-
class LeuCheckboxGroup extends LeuElement {
|
|
46
|
-
constructor() {
|
|
47
|
-
super(...arguments);
|
|
48
|
-
/**
|
|
49
|
-
* Defines how the checkboxes should be aligned.
|
|
50
|
-
*/
|
|
51
|
-
this.orientation = "horizontal";
|
|
52
|
-
this.items = [];
|
|
53
|
-
}
|
|
54
|
-
get value() {
|
|
55
|
-
return this.items.filter((i) => i.checked).map((i) => i.value);
|
|
56
|
-
}
|
|
57
|
-
handleSlotChange() {
|
|
58
|
-
this.items = Array.from(this.querySelectorAll(":scope > *:not([slot])")).filter((el) => el instanceof LeuCheckbox);
|
|
59
|
-
}
|
|
60
|
-
render() {
|
|
61
|
-
const fieldsetClasses = {
|
|
62
|
-
fieldset: "true",
|
|
63
|
-
"fieldset--vertical": this.orientation === "vertical",
|
|
64
|
-
};
|
|
65
|
-
return html `
|
|
66
|
-
<fieldset class=${classMap(fieldsetClasses)}>
|
|
67
|
-
${this.label
|
|
68
|
-
? html `<legend class="legend">${this.label}</legend>`
|
|
69
|
-
: html ``}
|
|
70
|
-
<slot @slotchange=${this.handleSlotChange}></slot>
|
|
71
|
-
</fieldset>
|
|
72
|
-
`;
|
|
73
|
-
}
|
|
74
|
-
}
|
|
75
|
-
LeuCheckboxGroup.styles = [LeuElement.styles, css_248z];
|
|
76
|
-
__decorate([
|
|
77
|
-
property({ type: String, reflect: true })
|
|
78
|
-
], LeuCheckboxGroup.prototype, "orientation", void 0);
|
|
79
|
-
__decorate([
|
|
80
|
-
property({ type: String, reflect: true })
|
|
81
|
-
], LeuCheckboxGroup.prototype, "label", void 0);
|
|
82
|
-
|
|
1
|
+
import "./LeuElement-BeFrgKes.js";
|
|
2
|
+
import "./Icon-C_yYuynf.js";
|
|
3
|
+
import "./FormAssociatedMixin-DLPvFtbT.js";
|
|
4
|
+
import "./Checkbox-Dd1QLpfn.js";
|
|
5
|
+
import { t as LeuCheckboxGroup } from "./CheckboxGroup-Bz2eWEFL.js";
|
|
83
6
|
export { LeuCheckboxGroup };
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
import { t as LeuElement } from "./LeuElement-pJFU18Xm.js";
|
|
2
|
+
|
|
3
|
+
//#region src/components/chip/Chip.d.ts
|
|
4
|
+
declare class LeuChipBase extends LeuElement {
|
|
5
|
+
static styles: any[];
|
|
6
|
+
/** @internal */
|
|
7
|
+
static shadowRootOptions: {
|
|
8
|
+
delegatesFocus: boolean;
|
|
9
|
+
clonable?: boolean;
|
|
10
|
+
customElementRegistry?: CustomElementRegistry;
|
|
11
|
+
mode: ShadowRootMode;
|
|
12
|
+
serializable?: boolean;
|
|
13
|
+
slotAssignment?: SlotAssignmentMode;
|
|
14
|
+
};
|
|
15
|
+
inverted: boolean;
|
|
16
|
+
}
|
|
17
|
+
//#endregion
|
|
18
|
+
export { LeuChipBase as t };
|
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
import { t as LeuElement } from "./LeuElement-BeFrgKes.js";
|
|
2
|
+
import { t as __decorate } from "./decorate-DwpAc4D0.js";
|
|
3
|
+
import { css } from "lit";
|
|
4
|
+
import { property } from "lit/decorators.js";
|
|
5
|
+
//#region src/components/chip/chip.css?inline
|
|
6
|
+
var chip_default = css`:host *::before,
|
|
7
|
+
:host *::after {
|
|
8
|
+
box-sizing: border-box;
|
|
9
|
+
}
|
|
10
|
+
|
|
11
|
+
:host {
|
|
12
|
+
--chip-background-color-default: var(--leu-color-black-transp-10);
|
|
13
|
+
--chip-background-color-hover: var(--leu-color-black-transp-20);
|
|
14
|
+
--chip-background-color-checked: var(--leu-color-black-100);
|
|
15
|
+
--chip-background-color-checked-hover: var(--leu-color-black-transp-80);
|
|
16
|
+
|
|
17
|
+
--chip-color-default: var(--leu-color-black-transp-60);
|
|
18
|
+
--chip-color-hover: var(--leu-color-black-100);
|
|
19
|
+
--chip-color-checked: var(--leu-color-black-0);
|
|
20
|
+
|
|
21
|
+
--chip-radio-border-default: var(--leu-color-black-transp-40);
|
|
22
|
+
--chip-radio-border-checked: var(--leu-color-black-0);
|
|
23
|
+
--chip-radio-background-default: var(--leu-color-black-0);
|
|
24
|
+
--chip-radio-background-checked: var(--leu-color-func-cyan);
|
|
25
|
+
|
|
26
|
+
--chip-font-regular: var(--leu-font-family-regular);
|
|
27
|
+
--chip-font-black: var(--leu-font-family-black);
|
|
28
|
+
|
|
29
|
+
--chip-background-color: var(--chip-background-color-default);
|
|
30
|
+
--chip-color: var(--chip-color-default);
|
|
31
|
+
--chip-radio-border: var(--chip-radio-border-default);
|
|
32
|
+
--chip-radio-background: var(--chip-radio-background-default);
|
|
33
|
+
|
|
34
|
+
--leu-icon-size: 1rem;
|
|
35
|
+
|
|
36
|
+
font-family: var(--chip-font-regular);
|
|
37
|
+
|
|
38
|
+
/* Allow shrinking to achieve text truncation (ellipsis) */
|
|
39
|
+
min-width: 0;
|
|
40
|
+
}
|
|
41
|
+
|
|
42
|
+
:host([inverted]) {
|
|
43
|
+
--chip-background-color: var(--leu-color-black-transp-20);
|
|
44
|
+
--chip-background-color-hover: var(--leu-color-black-transp-40);
|
|
45
|
+
|
|
46
|
+
--chip-color-default: var(--leu-color-black-0);
|
|
47
|
+
--chip-color-hover: var(--leu-color-black-0);
|
|
48
|
+
--chip-color-checked: var(--leu-color-black-0);
|
|
49
|
+
}
|
|
50
|
+
|
|
51
|
+
:host([checked]) {
|
|
52
|
+
--chip-background-color: var(--chip-background-color-checked);
|
|
53
|
+
--chip-color: var(--chip-color-checked);
|
|
54
|
+
--chip-radio-border: var(--chip-radio-border-checked);
|
|
55
|
+
--chip-radio-background: var(--chip-radio-background-checked);
|
|
56
|
+
}
|
|
57
|
+
|
|
58
|
+
.button {
|
|
59
|
+
-webkit-appearance: none;
|
|
60
|
+
-moz-appearance: none;
|
|
61
|
+
appearance: none;
|
|
62
|
+
border: none;
|
|
63
|
+
border-radius: 1rem;
|
|
64
|
+
background-color: var(--chip-background-color);
|
|
65
|
+
padding: 8px 1rem;
|
|
66
|
+
|
|
67
|
+
color: var(--chip-color);
|
|
68
|
+
font-family: inherit;
|
|
69
|
+
font-size: 0.875rem;
|
|
70
|
+
line-height: 1rem;
|
|
71
|
+
|
|
72
|
+
cursor: pointer;
|
|
73
|
+
|
|
74
|
+
display: inline-flex;
|
|
75
|
+
gap: 0.5rem;
|
|
76
|
+
align-items: center;
|
|
77
|
+
|
|
78
|
+
/* Allow shrinking to achieve text truncation (ellipsis) */
|
|
79
|
+
min-width: 0;
|
|
80
|
+
max-width: 100%;
|
|
81
|
+
}
|
|
82
|
+
|
|
83
|
+
.button:hover,
|
|
84
|
+
.button:focus-visible {
|
|
85
|
+
--chip-background-color: var(--chip-background-color-hover);
|
|
86
|
+
--chip-color: var(--chip-color-hover);
|
|
87
|
+
}
|
|
88
|
+
|
|
89
|
+
.button:focus-visible {
|
|
90
|
+
outline: 2px solid var(--leu-color-func-cyan);
|
|
91
|
+
outline-offset: 2px;
|
|
92
|
+
}
|
|
93
|
+
|
|
94
|
+
:host([href]) .button {
|
|
95
|
+
border-radius: 1.25rem;
|
|
96
|
+
padding: 0.5rem 1rem;
|
|
97
|
+
|
|
98
|
+
font-family: var(--chip-font-black);
|
|
99
|
+
font-size: 1.125rem;
|
|
100
|
+
line-height: 1.5rem;
|
|
101
|
+
-webkit-text-decoration: none;
|
|
102
|
+
text-decoration: none;
|
|
103
|
+
}
|
|
104
|
+
|
|
105
|
+
:host([checked]) .button:hover,
|
|
106
|
+
:host([checked]) .button:focus-visible {
|
|
107
|
+
--chip-background-color: var(--chip-background-color-checked-hover);
|
|
108
|
+
--chip-color: var(--chip-color-checked);
|
|
109
|
+
}
|
|
110
|
+
|
|
111
|
+
:host([href][size="large"]) .button {
|
|
112
|
+
border-radius: 1.5rem;
|
|
113
|
+
padding: 0.3125rem 1.5rem;
|
|
114
|
+
|
|
115
|
+
font-size: 2rem;
|
|
116
|
+
line-height: 2.375rem;
|
|
117
|
+
}
|
|
118
|
+
|
|
119
|
+
:host([size="small"]:not([variant="radio"])) .button {
|
|
120
|
+
padding: 0.3125rem 0.75rem;
|
|
121
|
+
|
|
122
|
+
font-size: 0.75rem;
|
|
123
|
+
line-height: 1.25rem;
|
|
124
|
+
}
|
|
125
|
+
|
|
126
|
+
:host([variant="radio"]) .button::before {
|
|
127
|
+
content: "";
|
|
128
|
+
flex: 0 0 1rem;
|
|
129
|
+
width: 1rem;
|
|
130
|
+
height: 1rem;
|
|
131
|
+
background-color: var(--chip-radio-background);
|
|
132
|
+
border: 2px solid var(--chip-radio-border);
|
|
133
|
+
border-radius: 50%;
|
|
134
|
+
}
|
|
135
|
+
|
|
136
|
+
:host([variant="radio"][checked]) .button::before {
|
|
137
|
+
border-width: 3px;
|
|
138
|
+
}
|
|
139
|
+
|
|
140
|
+
.label {
|
|
141
|
+
position: relative;
|
|
142
|
+
top: -0.0625rem;
|
|
143
|
+
|
|
144
|
+
overflow: hidden;
|
|
145
|
+
text-overflow: ellipsis;
|
|
146
|
+
white-space: nowrap;
|
|
147
|
+
}
|
|
148
|
+
`;
|
|
149
|
+
//#endregion
|
|
150
|
+
//#region src/components/chip/Chip.ts
|
|
151
|
+
var LeuChipBase = class extends LeuElement {
|
|
152
|
+
constructor(..._args) {
|
|
153
|
+
super(..._args);
|
|
154
|
+
this.inverted = false;
|
|
155
|
+
}
|
|
156
|
+
static {
|
|
157
|
+
this.styles = [LeuElement.styles, chip_default];
|
|
158
|
+
}
|
|
159
|
+
static {
|
|
160
|
+
this.shadowRootOptions = {
|
|
161
|
+
...LeuElement.shadowRootOptions,
|
|
162
|
+
delegatesFocus: true
|
|
163
|
+
};
|
|
164
|
+
}
|
|
165
|
+
};
|
|
166
|
+
__decorate([property({
|
|
167
|
+
type: Boolean,
|
|
168
|
+
reflect: true
|
|
169
|
+
})], LeuChipBase.prototype, "inverted", void 0);
|
|
170
|
+
//#endregion
|
|
171
|
+
export { LeuChipBase as t };
|
package/dist/Chip.d.ts
CHANGED
|
@@ -1,18 +1,2 @@
|
|
|
1
|
-
import
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
declare class LeuChipBase extends LeuElement {
|
|
5
|
-
static styles: lit.CSSResultGroup[];
|
|
6
|
-
/** @internal */
|
|
7
|
-
static shadowRootOptions: {
|
|
8
|
-
delegatesFocus: boolean;
|
|
9
|
-
mode: ShadowRootMode;
|
|
10
|
-
serializable?: boolean;
|
|
11
|
-
slotAssignment?: SlotAssignmentMode;
|
|
12
|
-
customElements?: CustomElementRegistry;
|
|
13
|
-
registry?: CustomElementRegistry;
|
|
14
|
-
};
|
|
15
|
-
inverted: boolean;
|
|
16
|
-
}
|
|
17
|
-
|
|
18
|
-
export { LeuChipBase };
|
|
1
|
+
import { t as LeuChipBase } from "./Chip-DLKM9P7v.js";
|
|
2
|
+
export { LeuChipBase };
|