material 3.2.6 → 3.3.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/README.md +1 -1
- package/dist/components/badge/badge.d.ts +0 -59
- package/dist/components/badge/constants.d.ts +0 -15
- package/dist/components/badge/index.d.ts +0 -6
- package/dist/components/badge/types.d.ts +0 -244
- package/dist/components/bottom-app-bar/bottom-app-bar.d.ts +0 -10
- package/dist/components/bottom-app-bar/constants.d.ts +0 -9
- package/dist/components/bottom-app-bar/index.d.ts +0 -4
- package/dist/components/bottom-app-bar/types.d.ts +0 -76
- package/dist/components/bottom-sheet/bottom-sheet.d.ts +0 -21
- package/dist/components/bottom-sheet/constants.d.ts +0 -29
- package/dist/components/bottom-sheet/types.d.ts +0 -89
- package/dist/components/button/button.d.ts +0 -62
- package/dist/components/button/constants.d.ts +0 -41
- package/dist/components/button/index.d.ts +0 -4
- package/dist/components/button/types.d.ts +0 -347
- package/dist/components/button-group/button-group.d.ts +0 -51
- package/dist/components/button-group/constants.d.ts +0 -83
- package/dist/components/button-group/index.d.ts +0 -10
- package/dist/components/button-group/types.d.ts +0 -234
- package/dist/components/card/card.d.ts +0 -64
- package/dist/components/card/constants.d.ts +0 -33
- package/dist/components/card/content.d.ts +0 -86
- package/dist/components/card/index.d.ts +0 -66
- package/dist/components/card/types.d.ts +0 -366
- package/dist/components/carousel/carousel.d.ts +0 -22
- package/dist/components/carousel/constants.d.ts +0 -16
- package/dist/components/carousel/types.d.ts +0 -29
- package/dist/components/checkbox/checkbox.d.ts +0 -61
- package/dist/components/checkbox/constants.d.ts +0 -33
- package/dist/components/checkbox/index.d.ts +0 -25
- package/dist/components/checkbox/types.d.ts +0 -206
- package/dist/components/chips/chips.d.ts +0 -14
- package/dist/components/chips/constants.d.ts +0 -1
- package/dist/components/chips/factories.d.ts +0 -4
- package/dist/components/chips/types.d.ts +0 -278
- package/dist/components/datepicker/constants.d.ts +0 -56
- package/dist/components/datepicker/datepicker.d.ts +0 -5
- package/dist/components/datepicker/types.d.ts +12 -257
- package/dist/components/dialog/constants.d.ts +0 -65
- package/dist/components/dialog/dialog.d.ts +0 -86
- package/dist/components/dialog/index.d.ts +0 -12
- package/dist/components/dialog/types.d.ts +0 -511
- package/dist/components/divider/config.d.ts +0 -130
- package/dist/components/divider/constants.d.ts +0 -27
- package/dist/components/divider/divider.d.ts +0 -36
- package/dist/components/divider/index.d.ts +0 -29
- package/dist/components/divider/types.d.ts +0 -126
- package/dist/components/drawer/constants.d.ts +0 -53
- package/dist/components/drawer/drawer.d.ts +0 -56
- package/dist/components/drawer/index.d.ts +0 -4
- package/dist/components/drawer/types.d.ts +0 -200
- package/dist/components/extended-fab/config.js +3 -2
- package/dist/components/extended-fab/constants.d.ts +0 -46
- package/dist/components/extended-fab/extended-fab.d.ts +0 -58
- package/dist/components/extended-fab/index.d.ts +1 -35
- package/dist/components/extended-fab/types.d.ts +2 -654
- package/dist/components/fab/config.js +3 -2
- package/dist/components/fab/constants.d.ts +0 -40
- package/dist/components/fab/fab.d.ts +0 -42
- package/dist/components/fab/index.d.ts +1 -34
- package/dist/components/fab/types.d.ts +2 -543
- package/dist/components/fab-menu/constants.d.ts +0 -22
- package/dist/components/fab-menu/fab-menu.d.ts +0 -36
- package/dist/components/fab-menu/types.d.ts +0 -80
- package/dist/components/icon-button/constants.d.ts +0 -90
- package/dist/components/icon-button/icon-button.d.ts +0 -83
- package/dist/components/icon-button/index.d.ts +0 -44
- package/dist/components/icon-button/types.d.ts +0 -314
- package/dist/components/index.d.ts +0 -9
- package/dist/components/list/constants.d.ts +0 -47
- package/dist/components/list/index.d.ts +0 -1
- package/dist/components/list/list.d.ts +0 -26
- package/dist/components/list/types.d.ts +0 -263
- package/dist/components/loading-indicator/constants.d.ts +0 -35
- package/dist/components/loading-indicator/features/renderer.d.ts +0 -14
- package/dist/components/loading-indicator/loading-indicator.d.ts +0 -6
- package/dist/components/loading-indicator/types.d.ts +0 -35
- package/dist/components/menu/constants.d.ts +0 -79
- package/dist/components/menu/index.d.ts +0 -25
- package/dist/components/menu/inner.d.ts +0 -3
- package/dist/components/menu/menu.d.ts +0 -26
- package/dist/components/menu/types.d.ts +0 -423
- package/dist/components/navigation-bar/navigation-bar.d.ts +0 -7
- package/dist/components/navigation-bar/types.d.ts +0 -25
- package/dist/components/navigation-rail/constants.d.ts +0 -2
- package/dist/components/navigation-rail/navigation-rail.d.ts +0 -5
- package/dist/components/navigation-rail/types.d.ts +0 -22
- package/dist/components/progress/constants.d.ts +24 -56
- package/dist/components/progress/progress.d.ts +0 -21
- package/dist/components/progress/types.d.ts +0 -251
- package/dist/components/radios/constants.d.ts +0 -22
- package/dist/components/radios/radios.d.ts +0 -5
- package/dist/components/radios/types.d.ts +0 -142
- package/dist/components/search/constants.d.ts +0 -59
- package/dist/components/search/search.d.ts +0 -32
- package/dist/components/search/types.d.ts +0 -159
- package/dist/components/select/constants.d.ts +0 -60
- package/dist/components/select/index.d.ts +0 -22
- package/dist/components/select/select.d.ts +0 -33
- package/dist/components/select/types.d.ts +0 -241
- package/dist/components/side-sheet/constants.d.ts +0 -28
- package/dist/components/side-sheet/side-sheet.d.ts +0 -21
- package/dist/components/side-sheet/types.d.ts +0 -82
- package/dist/components/slider/constants.d.ts +0 -86
- package/dist/components/slider/slider.d.ts +0 -16
- package/dist/components/slider/types.d.ts +0 -184
- package/dist/components/snackbar/constants.d.ts +0 -73
- package/dist/components/snackbar/snackbar.d.ts +0 -13
- package/dist/components/snackbar/types.d.ts +0 -147
- package/dist/components/split-button/constants.d.ts +0 -33
- package/dist/components/split-button/split-button.d.ts +0 -21
- package/dist/components/split-button/types.d.ts +0 -81
- package/dist/components/switch/constants.d.ts +0 -49
- package/dist/components/switch/switch.d.ts +0 -5
- package/dist/components/switch/types.d.ts +0 -80
- package/dist/components/tabs/constants.d.ts +0 -76
- package/dist/components/tabs/indicator.d.ts +0 -27
- package/dist/components/tabs/responsive.d.ts +0 -30
- package/dist/components/tabs/tab.d.ts +0 -13
- package/dist/components/tabs/tabs.d.ts +0 -24
- package/dist/components/tabs/types.d.ts +0 -335
- package/dist/components/tabs/utils.d.ts +0 -66
- package/dist/components/text-field/constants.d.ts +0 -82
- package/dist/components/text-field/features/trailing-icon.d.ts +0 -61
- package/dist/components/text-field/text-field.d.ts +0 -33
- package/dist/components/text-field/types.d.ts +0 -123
- package/dist/components/timepicker/constants.d.ts +0 -88
- package/dist/components/timepicker/types.d.ts +0 -268
- package/dist/components/toolbar/constants.d.ts +0 -27
- package/dist/components/toolbar/toolbar.d.ts +0 -25
- package/dist/components/toolbar/types.d.ts +0 -102
- package/dist/components/tooltip/constants.d.ts +0 -58
- package/dist/components/tooltip/tooltip.d.ts +0 -5
- package/dist/components/tooltip/types.d.ts +0 -140
- package/dist/components/top-app-bar/constants.d.ts +0 -41
- package/dist/components/top-app-bar/index.d.ts +0 -4
- package/dist/components/top-app-bar/top-app-bar.d.ts +0 -10
- package/dist/components/top-app-bar/types.d.ts +0 -94
- package/dist/core/canvas/animation.d.ts +0 -13
- package/dist/core/canvas/drawing.d.ts +18 -55
- package/dist/core/canvas/index.d.ts +0 -4
- package/dist/core/canvas/resize.d.ts +0 -13
- package/dist/core/canvas/utils.d.ts +0 -62
- package/dist/core/compose/base.d.ts +0 -22
- package/dist/core/compose/cleanup.d.ts +0 -2
- package/dist/core/compose/component.d.ts +0 -31
- package/dist/core/compose/features/badge.d.ts +0 -25
- package/dist/core/compose/features/checkable.d.ts +0 -36
- package/dist/core/compose/features/debounce.d.ts +0 -57
- package/dist/core/compose/features/disabled.d.ts +0 -31
- package/dist/core/compose/features/events.d.ts +0 -38
- package/dist/core/compose/features/icon.d.ts +0 -49
- package/dist/core/compose/features/input.d.ts +0 -82
- package/dist/core/compose/features/lifecycle.d.ts +0 -36
- package/dist/core/compose/features/position.d.ts +0 -27
- package/dist/core/compose/features/ripple.d.ts +0 -29
- package/dist/core/compose/features/size.d.ts +0 -9
- package/dist/core/compose/features/style.d.ts +0 -9
- package/dist/core/compose/features/text.d.ts +0 -45
- package/dist/core/compose/features/textinput.d.ts +0 -88
- package/dist/core/compose/features/textlabel.d.ts +0 -44
- package/dist/core/compose/features/throttle.d.ts +0 -54
- package/dist/core/compose/features/track.d.ts +0 -34
- package/dist/core/compose/features/variant.d.ts +0 -9
- package/dist/core/compose/features/withEvents.d.ts +0 -30
- package/dist/core/compose/index.d.ts +0 -4
- package/dist/core/compose/pipe.d.ts +0 -55
- package/dist/core/compose/utils/type-guards.d.ts +0 -15
- package/dist/core/config/component.d.ts +0 -45
- package/dist/core/config/global.d.ts +0 -43
- package/dist/core/config.d.ts +0 -59
- package/dist/core/dom/attributes.d.ts +0 -41
- package/dist/core/dom/classes.d.ts +0 -49
- package/dist/core/dom/create.d.ts +0 -98
- package/dist/core/dom/events.d.ts +0 -52
- package/dist/core/dom/focus.d.ts +0 -32
- package/dist/core/dom/html.d.ts +0 -24
- package/dist/core/dom/layer.d.ts +0 -98
- package/dist/core/dom/roving.d.ts +0 -19
- package/dist/core/index.d.ts +0 -9
- package/dist/core/navigation/destinations.d.ts +0 -23
- package/dist/core/shapes/cubic.d.ts +24 -19
- package/dist/core/shapes/material.d.ts +0 -64
- package/dist/core/shapes/polygon.d.ts +6 -16
- package/dist/core/state/emitter.d.ts +0 -36
- package/dist/core/state/events.d.ts +0 -29
- package/dist/core/state/store.d.ts +0 -70
- package/dist/core/theme/index.d.ts +0 -3
- package/dist/core/theme/shape.d.ts +0 -7
- package/dist/core/theme/tokens.d.ts +48 -32
- package/dist/core/utils/background.d.ts +0 -29
- package/dist/core/utils/color.d.ts +0 -13
- package/dist/core/utils/index.d.ts +0 -11
- package/dist/core/utils/mobile.d.ts +0 -31
- package/dist/core/utils/object.d.ts +0 -11
- package/dist/core/utils/performance.d.ts +0 -70
- package/dist/core/utils/theme.d.ts +0 -36
- package/dist/core/utils/url.d.ts +0 -17
- package/dist/elements/adapter.d.ts +13 -62
- package/dist/elements/badge.d.ts +0 -17
- package/dist/elements/bottom-app-bar.d.ts +7 -17
- package/dist/elements/bottom-sheet.d.ts +9 -38
- package/dist/elements/button-group.d.ts +0 -31
- package/dist/elements/button.d.ts +24 -18
- package/dist/elements/button.js +12 -0
- package/dist/elements/card.d.ts +12 -24
- package/dist/elements/card.js +3 -2
- package/dist/elements/carousel.d.ts +5 -29
- package/dist/elements/checkbox.d.ts +5 -15
- package/dist/elements/chips.d.ts +0 -33
- package/dist/elements/css/extended-fab.css +1 -1
- package/dist/elements/css/extended-fab.js +1 -1
- package/dist/elements/css/fab-menu.css +1 -1
- package/dist/elements/css/fab-menu.js +1 -1
- package/dist/elements/css/fab.css +1 -1
- package/dist/elements/css/fab.js +1 -1
- package/dist/elements/css/hosts/extended-fab.css +1 -1
- package/dist/elements/css/hosts/fab.css +1 -1
- package/dist/elements/datepicker.d.ts +4 -48
- package/dist/elements/define.d.ts +3 -161
- package/dist/elements/dialog.d.ts +8 -39
- package/dist/elements/divider.d.ts +0 -14
- package/dist/elements/drawer.d.ts +0 -35
- package/dist/elements/extended-fab.d.ts +10 -18
- package/dist/elements/extended-fab.js +3 -1
- package/dist/elements/fab-menu.d.ts +5 -30
- package/dist/elements/fab.d.ts +8 -17
- package/dist/elements/fab.js +3 -1
- package/dist/elements/floating-placement.js +1 -0
- package/dist/elements/icon-button.d.ts +5 -26
- package/dist/elements/index.d.ts +0 -16
- package/dist/elements/list.d.ts +0 -34
- package/dist/elements/loading-indicator.d.ts +4 -13
- package/dist/elements/menu.d.ts +5 -51
- package/dist/elements/navigation-bar.d.ts +4 -29
- package/dist/elements/navigation-rail.d.ts +8 -49
- package/dist/elements/preupgrade/badge.css +1 -1
- package/dist/elements/preupgrade/bottom-app-bar.css +1 -1
- package/dist/elements/preupgrade/bottom-sheet.css +1 -1
- package/dist/elements/preupgrade/button-group.css +1 -1
- package/dist/elements/preupgrade/button.css +2 -2
- package/dist/elements/preupgrade/card.css +2 -2
- package/dist/elements/preupgrade/carousel.css +1 -1
- package/dist/elements/preupgrade/checkbox.css +1 -1
- package/dist/elements/preupgrade/chips.css +1 -1
- package/dist/elements/preupgrade/datepicker.css +1 -1
- package/dist/elements/preupgrade/dialog.css +1 -1
- package/dist/elements/preupgrade/divider.css +1 -1
- package/dist/elements/preupgrade/drawer.css +1 -1
- package/dist/elements/preupgrade/extended-fab.css +2 -2
- package/dist/elements/preupgrade/fab-menu.css +1 -1
- package/dist/elements/preupgrade/fab.css +2 -2
- package/dist/elements/preupgrade/icon-button.css +1 -1
- package/dist/elements/preupgrade/list.css +1 -1
- package/dist/elements/preupgrade/loading-indicator.css +1 -1
- package/dist/elements/preupgrade/menu.css +1 -1
- package/dist/elements/preupgrade/navigation-bar.css +1 -1
- package/dist/elements/preupgrade/navigation-rail.css +1 -1
- package/dist/elements/preupgrade/progress.css +1 -1
- package/dist/elements/preupgrade/radios.css +1 -1
- package/dist/elements/preupgrade/search.css +1 -1
- package/dist/elements/preupgrade/select.css +1 -1
- package/dist/elements/preupgrade/side-sheet.css +1 -1
- package/dist/elements/preupgrade/slider.css +1 -1
- package/dist/elements/preupgrade/snackbar.css +1 -1
- package/dist/elements/preupgrade/split-button.css +1 -1
- package/dist/elements/preupgrade/switch.css +1 -1
- package/dist/elements/preupgrade/tabs.css +1 -1
- package/dist/elements/preupgrade/text-field.css +1 -1
- package/dist/elements/preupgrade/timepicker.css +1 -1
- package/dist/elements/preupgrade/toolbar.css +1 -1
- package/dist/elements/preupgrade/tooltip.css +1 -1
- package/dist/elements/preupgrade/top-app-bar.css +1 -1
- package/dist/elements/preupgrade.css +2 -2
- package/dist/elements/preupgrade.d.ts +0 -1
- package/dist/elements/preupgrade.js +1 -1
- package/dist/elements/progress.d.ts +0 -15
- package/dist/elements/radios.d.ts +0 -22
- package/dist/elements/search.d.ts +5 -53
- package/dist/elements/select.d.ts +0 -31
- package/dist/elements/side-sheet.d.ts +7 -29
- package/dist/elements/slider.d.ts +3 -22
- package/dist/elements/snackbar.d.ts +4 -28
- package/dist/elements/split-button.d.ts +0 -30
- package/dist/elements/styles.d.ts +0 -63
- package/dist/elements/switch.d.ts +5 -17
- package/dist/elements/tabs.d.ts +0 -22
- package/dist/elements/text-field.d.ts +4 -38
- package/dist/elements/timepicker.d.ts +4 -44
- package/dist/elements/toolbar.d.ts +8 -25
- package/dist/elements/tooltip.d.ts +4 -30
- package/dist/elements/top-app-bar.d.ts +7 -23
- package/dist/index.d.ts +0 -11
- package/dist/package.json +1 -1
- package/dist/react/create.d.ts +0 -42
- package/dist/react/index.d.ts +0 -6
- package/dist/react/jsx.d.ts +0 -13
- package/dist/solid/create.d.ts +0 -48
- package/dist/solid/index.d.ts +0 -6
- package/dist/solid/jsx.d.ts +1 -10
- package/dist/ssr/index.d.ts +0 -49
- package/dist/ssr/solid.d.ts +0 -4
- package/dist/ssr/svelte.d.ts +0 -4
- package/dist/ssr/vue.d.ts +0 -4
- package/dist/styles/badge.css +1 -1
- package/dist/styles/base.css +1 -1
- package/dist/styles/bottom-app-bar.css +1 -1
- package/dist/styles/bottom-sheet.css +1 -1
- package/dist/styles/button-group.css +1 -1
- package/dist/styles/button.css +1 -1
- package/dist/styles/card.css +1 -1
- package/dist/styles/carousel.css +1 -1
- package/dist/styles/checkbox.css +1 -1
- package/dist/styles/chips.css +1 -1
- package/dist/styles/contrast.css +1 -1
- package/dist/styles/datepicker.css +1 -1
- package/dist/styles/dialog.css +1 -1
- package/dist/styles/divider.css +1 -1
- package/dist/styles/drawer.css +1 -1
- package/dist/styles/extended-fab.css +2 -2
- package/dist/styles/fab-menu.css +2 -2
- package/dist/styles/fab.css +2 -2
- package/dist/styles/icon-button.css +1 -1
- package/dist/styles/list.css +1 -1
- package/dist/styles/loading-indicator.css +1 -1
- package/dist/styles/menu.css +1 -1
- package/dist/styles/navigation-bar.css +1 -1
- package/dist/styles/navigation-rail.css +1 -1
- package/dist/styles/progress.css +1 -1
- package/dist/styles/radios.css +1 -1
- package/dist/styles/search.css +1 -1
- package/dist/styles/select.css +1 -1
- package/dist/styles/side-sheet.css +1 -1
- package/dist/styles/slider.css +1 -1
- package/dist/styles/snackbar.css +1 -1
- package/dist/styles/split-button.css +1 -1
- package/dist/styles/switch.css +1 -1
- package/dist/styles/tabs.css +1 -1
- package/dist/styles/text-field.css +1 -1
- package/dist/styles/timepicker.css +1 -1
- package/dist/styles/toolbar.css +1 -1
- package/dist/styles/tooltip.css +1 -1
- package/dist/styles/top-app-bar.css +1 -1
- package/dist/styles/typography.css +1 -1
- package/dist/styles/utilities.css +1 -1
- package/dist/styles.css +2 -2
- package/dist/svelte/Button.svelte +5 -4
- package/dist/svelte/runtime.d.ts +8 -62
- package/dist/themes/autumn-contrast.css +1 -1
- package/dist/themes/autumn.css +1 -1
- package/dist/themes/baseline-contrast.css +1 -1
- package/dist/themes/baseline.css +1 -1
- package/dist/themes/brownbeige-contrast.css +1 -1
- package/dist/themes/brownbeige.css +1 -1
- package/dist/themes/content-contrast.css +1 -1
- package/dist/themes/content.css +1 -1
- package/dist/themes/desert-contrast.css +1 -1
- package/dist/themes/desert.css +1 -1
- package/dist/themes/expressive-contrast.css +1 -1
- package/dist/themes/expressive.css +1 -1
- package/dist/themes/fidelity-contrast.css +1 -1
- package/dist/themes/fidelity.css +1 -1
- package/dist/themes/forest-contrast.css +1 -1
- package/dist/themes/forest.css +1 -1
- package/dist/themes/fruit-salad-contrast.css +1 -1
- package/dist/themes/fruit-salad.css +1 -1
- package/dist/themes/highcontrast-contrast.css +1 -1
- package/dist/themes/highcontrast.css +1 -1
- package/dist/themes/monochrome-contrast.css +1 -1
- package/dist/themes/monochrome.css +1 -1
- package/dist/themes/neutral-contrast.css +1 -1
- package/dist/themes/neutral.css +1 -1
- package/dist/themes/ocean-contrast.css +1 -1
- package/dist/themes/ocean.css +1 -1
- package/dist/themes/rainbow-contrast.css +1 -1
- package/dist/themes/rainbow.css +1 -1
- package/dist/themes/sageivory-contrast.css +1 -1
- package/dist/themes/sageivory.css +1 -1
- package/dist/themes/spring-contrast.css +1 -1
- package/dist/themes/spring.css +1 -1
- package/dist/themes/summer-contrast.css +1 -1
- package/dist/themes/summer.css +1 -1
- package/dist/themes/sunset-contrast.css +1 -1
- package/dist/themes/sunset.css +1 -1
- package/dist/themes/tealcaramel-contrast.css +1 -1
- package/dist/themes/tealcaramel.css +1 -1
- package/dist/themes/vibrant-contrast.css +1 -1
- package/dist/themes/vibrant.css +1 -1
- package/dist/vue/create.d.ts +15 -58
- package/dist/vue/index.d.ts +0 -6
- package/package.json +1 -1
- package/src/styles/abstract/_floating-placement.scss +12 -0
- package/src/styles/components/_extended-fab.scss +34 -8
- package/src/styles/components/_fab-menu.scss +58 -8
- package/src/styles/components/_fab.scss +34 -8
- package/src/styles/elements/_button.scss +27 -5
- package/src/styles/elements/_card.scss +14 -0
- package/src/styles/elements/_extended-fab.scss +2 -0
- package/src/styles/elements/_fab.scss +2 -0
- package/dist/components/badge/api.d.ts +0 -41
- package/dist/components/badge/config.d.ts +0 -631
- package/dist/components/badge/features.d.ts +0 -38
- package/dist/components/bottom-app-bar/config.d.ts +0 -16
- package/dist/components/bottom-sheet/api.d.ts +0 -44
- package/dist/components/bottom-sheet/config.d.ts +0 -547
- package/dist/components/bottom-sheet/features/drag.d.ts +0 -35
- package/dist/components/bottom-sheet/features/index.d.ts +0 -3
- package/dist/components/bottom-sheet/features/state.d.ts +0 -31
- package/dist/components/bottom-sheet/features/structure.d.ts +0 -26
- package/dist/components/button/api.d.ts +0 -68
- package/dist/components/button/config.d.ts +0 -594
- package/dist/components/button/features/progress.d.ts +0 -43
- package/dist/components/button/features/toggle.d.ts +0 -43
- package/dist/components/button-group/config.d.ts +0 -147
- package/dist/components/card/api.d.ts +0 -24
- package/dist/components/card/config.d.ts +0 -635
- package/dist/components/card/features.d.ts +0 -124
- package/dist/components/carousel/api.d.ts +0 -20
- package/dist/components/carousel/arrangement.d.ts +0 -23
- package/dist/components/carousel/config.d.ts +0 -540
- package/dist/components/carousel/features/index.d.ts +0 -2
- package/dist/components/carousel/features/scroll.d.ts +0 -20
- package/dist/components/carousel/features/slides.d.ts +0 -18
- package/dist/components/carousel/keylines.d.ts +0 -68
- package/dist/components/carousel/strategy.d.ts +0 -36
- package/dist/components/checkbox/api.d.ts +0 -7
- package/dist/components/checkbox/config.d.ts +0 -568
- package/dist/components/chips/api.d.ts +0 -62
- package/dist/components/chips/chip/chip.d.ts +0 -4
- package/dist/components/chips/chip/constants.d.ts +0 -38
- package/dist/components/chips/chip/index.d.ts +0 -1
- package/dist/components/chips/config.d.ts +0 -583
- package/dist/components/chips/features/chip-items.d.ts +0 -39
- package/dist/components/chips/features/container.d.ts +0 -75
- package/dist/components/chips/features/controller.d.ts +0 -61
- package/dist/components/chips/features/dom.d.ts +0 -24
- package/dist/components/chips/features/index.d.ts +0 -4
- package/dist/components/chips/schema.d.ts +0 -35
- package/dist/components/datepicker/api.d.ts +0 -7
- package/dist/components/datepicker/config.d.ts +0 -542
- package/dist/components/datepicker/render.d.ts +0 -3
- package/dist/components/datepicker/utils.d.ts +0 -84
- package/dist/components/dialog/api.d.ts +0 -66
- package/dist/components/dialog/config.d.ts +0 -583
- package/dist/components/dialog/features.d.ts +0 -42
- package/dist/components/divider/features.d.ts +0 -6
- package/dist/components/drawer/api.d.ts +0 -55
- package/dist/components/drawer/config.d.ts +0 -620
- package/dist/components/drawer/features/headline.d.ts +0 -27
- package/dist/components/drawer/features/index.d.ts +0 -3
- package/dist/components/drawer/features/items.d.ts +0 -32
- package/dist/components/drawer/features/state.d.ts +0 -22
- package/dist/components/extended-fab/api.d.ts +0 -96
- package/dist/components/extended-fab/config.d.ts +0 -600
- package/dist/components/fab/api.d.ts +0 -74
- package/dist/components/fab/config.d.ts +0 -596
- package/dist/components/fab-menu/config.d.ts +0 -11
- package/dist/components/fab-menu/stagger.d.ts +0 -10
- package/dist/components/icon-button/api.d.ts +0 -84
- package/dist/components/icon-button/config.d.ts +0 -624
- package/dist/components/icon-button/features/toggle.d.ts +0 -133
- package/dist/components/list/api.d.ts +0 -156
- package/dist/components/list/config.d.ts +0 -625
- package/dist/components/list/features/anatomy.d.ts +0 -6
- package/dist/components/list/features/index.d.ts +0 -2
- package/dist/components/list/features/renderer.d.ts +0 -8
- package/dist/components/list/features/selection.d.ts +0 -3
- package/dist/components/loading-indicator/api.d.ts +0 -14
- package/dist/components/loading-indicator/config.d.ts +0 -557
- package/dist/components/loading-indicator/features/motion.d.ts +0 -22
- package/dist/components/menu/api.d.ts +0 -63
- package/dist/components/menu/config.d.ts +0 -576
- package/dist/components/menu/features/controller.d.ts +0 -15
- package/dist/components/menu/features/index.d.ts +0 -5
- package/dist/components/menu/features/keyboard.d.ts +0 -23
- package/dist/components/menu/features/layer.d.ts +0 -15
- package/dist/components/menu/features/loader.d.ts +0 -35
- package/dist/components/menu/features/opener.d.ts +0 -16
- package/dist/components/menu/features/position.d.ts +0 -18
- package/dist/components/menu/features/registry.d.ts +0 -37
- package/dist/components/menu/features/submenu.d.ts +0 -28
- package/dist/components/menu/features/tasks.d.ts +0 -9
- package/dist/components/navigation-bar/config.d.ts +0 -2
- package/dist/components/navigation-rail/config.d.ts +0 -2
- package/dist/components/progress/api.d.ts +0 -81
- package/dist/components/progress/config.d.ts +0 -620
- package/dist/components/progress/features/canvas.d.ts +0 -60
- package/dist/components/progress/features/circular.d.ts +0 -19
- package/dist/components/progress/features/colors.d.ts +0 -17
- package/dist/components/progress/features/index.d.ts +0 -8
- package/dist/components/progress/features/linear.d.ts +0 -25
- package/dist/components/progress/features/motion.d.ts +0 -43
- package/dist/components/progress/features/resize-observer.d.ts +0 -5
- package/dist/components/progress/features/state.d.ts +0 -44
- package/dist/components/radios/api.d.ts +0 -37
- package/dist/components/radios/config.d.ts +0 -568
- package/dist/components/radios/radio.d.ts +0 -26
- package/dist/components/search/api.d.ts +0 -63
- package/dist/components/search/config.d.ts +0 -657
- package/dist/components/search/features/index.d.ts +0 -4
- package/dist/components/search/features/input.d.ts +0 -93
- package/dist/components/search/features/states.d.ts +0 -111
- package/dist/components/search/features/structure.d.ts +0 -16
- package/dist/components/search/features/suggestions.d.ts +0 -60
- package/dist/components/select/api.d.ts +0 -8
- package/dist/components/select/config.d.ts +0 -18
- package/dist/components/select/features.d.ts +0 -14
- package/dist/components/side-sheet/api.d.ts +0 -34
- package/dist/components/side-sheet/config.d.ts +0 -547
- package/dist/components/side-sheet/features/index.d.ts +0 -2
- package/dist/components/side-sheet/features/state.d.ts +0 -28
- package/dist/components/side-sheet/features/structure.d.ts +0 -21
- package/dist/components/slider/api.d.ts +0 -65
- package/dist/components/slider/config.d.ts +0 -605
- package/dist/components/slider/features/axis.d.ts +0 -42
- package/dist/components/slider/features/controller.d.ts +0 -528
- package/dist/components/slider/features/dom.d.ts +0 -22
- package/dist/components/slider/features/handlers.d.ts +0 -16
- package/dist/components/slider/features/index.d.ts +0 -5
- package/dist/components/slider/features/range.d.ts +0 -14
- package/dist/components/slider/features/states.d.ts +0 -76
- package/dist/components/slider/features/tracks.d.ts +0 -50
- package/dist/components/snackbar/api.d.ts +0 -7
- package/dist/components/snackbar/config.d.ts +0 -596
- package/dist/components/snackbar/features.d.ts +0 -26
- package/dist/components/snackbar/layer.d.ts +0 -23
- package/dist/components/snackbar/position.d.ts +0 -16
- package/dist/components/snackbar/queue.d.ts +0 -15
- package/dist/components/split-button/api.d.ts +0 -14
- package/dist/components/split-button/config.d.ts +0 -553
- package/dist/components/split-button/features/buttons.d.ts +0 -8
- package/dist/components/split-button/features/menu.d.ts +0 -10
- package/dist/components/switch/api.d.ts +0 -7
- package/dist/components/switch/config.d.ts +0 -558
- package/dist/components/switch/features.d.ts +0 -63
- package/dist/components/tabs/api.d.ts +0 -54
- package/dist/components/tabs/config.d.ts +0 -31
- package/dist/components/tabs/features.d.ts +0 -131
- package/dist/components/tabs/scroll-indicators.d.ts +0 -18
- package/dist/components/tabs/state.d.ts +0 -48
- package/dist/components/text-field/api.d.ts +0 -29
- package/dist/components/text-field/config.d.ts +0 -560
- package/dist/components/text-field/features/counter.d.ts +0 -29
- package/dist/components/text-field/features/density.d.ts +0 -28
- package/dist/components/text-field/features/error.d.ts +0 -55
- package/dist/components/text-field/features/field.d.ts +0 -37
- package/dist/components/text-field/features/index.d.ts +0 -20
- package/dist/components/text-field/features/leading-icon.d.ts +0 -68
- package/dist/components/text-field/features/placement.d.ts +0 -30
- package/dist/components/text-field/features/prefix-text.d.ts +0 -67
- package/dist/components/text-field/features/required.d.ts +0 -33
- package/dist/components/text-field/features/suffix-text.d.ts +0 -67
- package/dist/components/text-field/features/supporting-text.d.ts +0 -59
- package/dist/components/timepicker/api.d.ts +0 -26
- package/dist/components/timepicker/config.d.ts +0 -570
- package/dist/components/timepicker/dial.d.ts +0 -35
- package/dist/components/timepicker/render.d.ts +0 -9
- package/dist/components/timepicker/utils.d.ts +0 -55
- package/dist/components/toolbar/config.d.ts +0 -19
- package/dist/components/tooltip/api.d.ts +0 -18
- package/dist/components/tooltip/config.d.ts +0 -563
- package/dist/components/top-app-bar/config.d.ts +0 -16
- package/dist/core/compose/features/constants.d.ts +0 -8
- package/dist/core/dom/direction.d.ts +0 -16
- package/dist/core/dom/form-value.d.ts +0 -24
- package/dist/core/dom/utils.d.ts +0 -33
- package/dist/core/navigation/ripple.d.ts +0 -2
- package/dist/core/utils/attributes.d.ts +0 -29
- package/dist/core/utils/validate.d.ts +0 -73
- package/dist/core/utils/warn.d.ts +0 -16
- package/dist/elements/form-button.d.ts +0 -29
- package/dist/elements/lifecycle.d.ts +0 -4
- package/dist/elements/sheet.d.ts +0 -44
- package/dist/react/shadow.d.ts +0 -2
- package/dist/solid/shadow.d.ts +0 -3
- package/dist/vue/shadow.d.ts +0 -7
|
@@ -1,129 +1,40 @@
|
|
|
1
1
|
import type { BadgeComponent } from "../badge/index.js";
|
|
2
2
|
import type { ButtonComponent } from "../button/types.js";
|
|
3
3
|
import type { ForwardedEventPayload } from "../../core/dom/index.js";
|
|
4
|
-
/**
|
|
5
|
-
* Button methods the tab delegates to; each one is checked before use
|
|
6
|
-
*/
|
|
7
4
|
export type TabButton = Partial<Pick<ButtonComponent, 'getValue' | 'setValue' | 'getText' | 'setText' | 'getIcon' | 'setIcon'>>;
|
|
8
5
|
import { TabIndicator } from "./indicator.js";
|
|
9
|
-
/**
|
|
10
|
-
* Available tabs variants
|
|
11
|
-
*/
|
|
12
6
|
export type TabsVariant = 'primary' | 'secondary';
|
|
13
|
-
/**
|
|
14
|
-
* Available tabs states
|
|
15
|
-
*/
|
|
16
7
|
export type TabStates = 'active' | 'inactive' | 'disabled';
|
|
17
|
-
/**
|
|
18
|
-
* Configuration for the tab indicator
|
|
19
|
-
* @category Components
|
|
20
|
-
*/
|
|
21
8
|
export interface IndicatorConfig {
|
|
22
|
-
/** Height of the indicator in pixels */
|
|
23
9
|
height?: number;
|
|
24
|
-
/**
|
|
25
|
-
* Width strategy for the indicator
|
|
26
|
-
* - 'fixed': Uses a fixed width defined by fixedWidth
|
|
27
|
-
* - 'dynamic': Uses half the tab width
|
|
28
|
-
* - 'content': Uses the text content width
|
|
29
|
-
* - 'auto': Adapts based on variant (primary: text width, secondary: full tab width)
|
|
30
|
-
*/
|
|
31
10
|
widthStrategy?: 'fixed' | 'dynamic' | 'content' | 'auto';
|
|
32
|
-
/** Fixed width in pixels (when using fixed strategy) */
|
|
33
11
|
fixedWidth?: number;
|
|
34
|
-
/** Animation duration in milliseconds */
|
|
35
12
|
animationDuration?: number;
|
|
36
|
-
/** Animation timing function */
|
|
37
13
|
animationTiming?: string;
|
|
38
|
-
/** Custom color for the indicator */
|
|
39
14
|
color?: string;
|
|
40
|
-
/** Whether the indicator shows; hide() and show() change it later */
|
|
41
15
|
visible?: boolean;
|
|
42
|
-
/** Tab variant (primary or secondary) */
|
|
43
16
|
variant?: string;
|
|
44
17
|
}
|
|
45
|
-
/**
|
|
46
|
-
* Tab change event data interface
|
|
47
|
-
* @category Events
|
|
48
|
-
*/
|
|
49
18
|
export interface TabChangeEventData {
|
|
50
|
-
/**
|
|
51
|
-
* The tab component that was activated
|
|
52
|
-
*/
|
|
53
19
|
tab: TabComponent;
|
|
54
|
-
/**
|
|
55
|
-
* The value of the activated tab, as `TabComponent.getValue()` returns it.
|
|
56
|
-
* A group emits `change` only when a tab is selected, so this is a string
|
|
57
|
-
* even though `TabsComponent.getValue()` is `string | null` when none is.
|
|
58
|
-
*/
|
|
59
20
|
value: string;
|
|
60
21
|
}
|
|
61
|
-
/**
|
|
62
|
-
* Events a single tab emits, and what each hands its handler.
|
|
63
|
-
*
|
|
64
|
-
* `click` is not the DOM click. The tab re-emits the payload its button
|
|
65
|
-
* already forwarded (`{ event, element, originalEvent }`). `focus` and `blur`
|
|
66
|
-
* are the native events from the button element.
|
|
67
|
-
*/
|
|
68
22
|
export interface TabEvents {
|
|
69
23
|
click: (payload: ForwardedEventPayload<MouseEvent, HTMLElement>) => void;
|
|
70
24
|
focus: (event: FocusEvent) => void;
|
|
71
25
|
blur: (event: FocusEvent) => void;
|
|
72
26
|
}
|
|
73
|
-
/**
|
|
74
|
-
* Events a tabs group emits. A click or a key selects a tab and emits
|
|
75
|
-
* `change`; selecting from code does not.
|
|
76
|
-
*/
|
|
77
27
|
export interface TabsEvents {
|
|
78
28
|
change: (event: TabChangeEventData) => void;
|
|
79
29
|
}
|
|
80
|
-
/**
|
|
81
|
-
* Configuration interface for a single Tab
|
|
82
|
-
* @category Components
|
|
83
|
-
*/
|
|
84
30
|
export interface TabConfig {
|
|
85
|
-
/**
|
|
86
|
-
* Id of the tab group this tab belongs to. Set by the group when it builds
|
|
87
|
-
* its tabs; a tab created on its own gets an empty one, which still yields
|
|
88
|
-
* a stable id. It is what makes tab ids unique across tablists.
|
|
89
|
-
* @internal
|
|
90
|
-
*/
|
|
91
31
|
groupId?: string;
|
|
92
|
-
/**
|
|
93
|
-
* Accessible name for a tab with an icon and no text, which otherwise has
|
|
94
|
-
* none.
|
|
95
|
-
*/
|
|
96
32
|
ariaLabel?: string;
|
|
97
|
-
/**
|
|
98
|
-
* Tab state that determines if it's the active destination
|
|
99
|
-
* @default 'inactive'
|
|
100
|
-
*/
|
|
101
33
|
state?: TabStates | string;
|
|
102
|
-
/**
|
|
103
|
-
* Whether the tab is initially disabled
|
|
104
|
-
* @default false
|
|
105
|
-
*/
|
|
106
34
|
disabled?: boolean;
|
|
107
|
-
/**
|
|
108
|
-
* Initial tab text content (label)
|
|
109
|
-
* @example 'Home'
|
|
110
|
-
*/
|
|
111
35
|
text?: string;
|
|
112
|
-
/**
|
|
113
|
-
* Initial tab icon HTML content.
|
|
114
|
-
* Markup (HTML). Not sanitized by default: see Markup and sanitizing.
|
|
115
|
-
* @example '<svg>...</svg>'
|
|
116
|
-
*/
|
|
117
36
|
icon?: string;
|
|
118
|
-
/**
|
|
119
|
-
* Badge text or value to display (if applicable)
|
|
120
|
-
* @example '5'
|
|
121
|
-
*/
|
|
122
37
|
badge?: string | number;
|
|
123
|
-
/**
|
|
124
|
-
* Badge configuration object
|
|
125
|
-
* Pass additional options for the badge component
|
|
126
|
-
*/
|
|
127
38
|
badgeConfig?: {
|
|
128
39
|
variant?: string;
|
|
129
40
|
color?: string;
|
|
@@ -131,335 +42,89 @@ export interface TabConfig {
|
|
|
131
42
|
position?: string;
|
|
132
43
|
max?: number;
|
|
133
44
|
};
|
|
134
|
-
/**
|
|
135
|
-
* Icon size in pixels or other CSS units
|
|
136
|
-
* @default '24px'
|
|
137
|
-
*/
|
|
138
45
|
iconSize?: string;
|
|
139
|
-
/**
|
|
140
|
-
* Additional CSS classes to add to the tab
|
|
141
|
-
* @example 'home-tab main-navigation'
|
|
142
|
-
*/
|
|
143
46
|
class?: string;
|
|
144
|
-
/**
|
|
145
|
-
* Tab value attribute for identifying the selected tab
|
|
146
|
-
*/
|
|
147
47
|
value?: string;
|
|
148
|
-
/**
|
|
149
|
-
* Whether to enable ripple effect
|
|
150
|
-
* @default true
|
|
151
|
-
*/
|
|
152
48
|
ripple?: boolean;
|
|
153
|
-
/**
|
|
154
|
-
* Component prefix for class names
|
|
155
|
-
* @default 'mtrl'
|
|
156
|
-
*/
|
|
157
49
|
prefix?: string;
|
|
158
|
-
/**
|
|
159
|
-
* Component name used in class generation
|
|
160
|
-
*/
|
|
161
50
|
componentName?: string;
|
|
162
|
-
/**
|
|
163
|
-
* Ripple effect configuration
|
|
164
|
-
*/
|
|
165
51
|
rippleConfig?: {
|
|
166
|
-
/** How long, in milliseconds, a released wave lingers before it is removed */
|
|
167
52
|
duration?: number;
|
|
168
53
|
};
|
|
169
|
-
/**
|
|
170
|
-
* Variant of the tab
|
|
171
|
-
*/
|
|
172
54
|
variant?: string;
|
|
173
55
|
}
|
|
174
|
-
/**
|
|
175
|
-
* Configuration interface for the Tabs component
|
|
176
|
-
* @category Components
|
|
177
|
-
*/
|
|
178
56
|
export interface TabsConfig {
|
|
179
|
-
/**
|
|
180
|
-
* Id for this tab group, used to build each tab's element id as
|
|
181
|
-
* `tab-<groupId>-<value>` and to find panels as
|
|
182
|
-
* `tabpanel-<groupId>-<value>`; a value with characters outside
|
|
183
|
-
* `[A-Za-z0-9_-]` gets a derived id instead (`tabIdFor`, `tabPanelIdFor`,
|
|
184
|
-
* The group id itself is not encoded: keep a pinned one to
|
|
185
|
-
* `[A-Za-z0-9_]` (generated ones are), or `tabIdFor("a-b", "c")` and
|
|
186
|
-
* `tabIdFor("a", "b-c")` coincide and a space makes an unsafe id. Allocated
|
|
187
|
-
* automatically when omitted; pin it when a page needs ids that survive a
|
|
188
|
-
* re-render.
|
|
189
|
-
*/
|
|
190
57
|
groupId?: string;
|
|
191
|
-
/**
|
|
192
|
-
* Whether an arrow key also selects the tab it moves to. By default it only
|
|
193
|
-
* moves focus, and Space or Enter selects, as m3.material.io's tabs
|
|
194
|
-
* accessibility guidance has it: "Don't use Space/Enter for navigating tabs".
|
|
195
|
-
* @default false
|
|
196
|
-
*/
|
|
197
58
|
autoActivate?: boolean;
|
|
198
|
-
/**
|
|
199
|
-
* Tabs variant (primary or secondary)
|
|
200
|
-
* @default 'primary'
|
|
201
|
-
*/
|
|
202
59
|
variant?: TabsVariant | string;
|
|
203
|
-
/**
|
|
204
|
-
* Initial tabs to create
|
|
205
|
-
*/
|
|
206
60
|
tabs?: TabConfig[];
|
|
207
|
-
/**
|
|
208
|
-
* Whether to show the divider
|
|
209
|
-
* @default true
|
|
210
|
-
*/
|
|
211
61
|
showDivider?: boolean;
|
|
212
|
-
/**
|
|
213
|
-
* Whether to enable horizontal scrolling
|
|
214
|
-
* @default true
|
|
215
|
-
*/
|
|
216
62
|
scrollable?: boolean;
|
|
217
|
-
/**
|
|
218
|
-
* Additional CSS classes for the container
|
|
219
|
-
*/
|
|
220
63
|
class?: string;
|
|
221
|
-
/**
|
|
222
|
-
* Component prefix for class names
|
|
223
|
-
* @default 'mtrl'
|
|
224
|
-
*/
|
|
225
64
|
prefix?: string;
|
|
226
|
-
/**
|
|
227
|
-
* Event handlers registered when the tabs are created. A group emits
|
|
228
|
-
* `change` only.
|
|
229
|
-
*/
|
|
230
65
|
on?: Partial<TabsEvents>;
|
|
231
|
-
/**
|
|
232
|
-
* Tab indicator configuration
|
|
233
|
-
*/
|
|
234
66
|
indicator?: IndicatorConfig;
|
|
235
67
|
}
|
|
236
|
-
/**
|
|
237
|
-
* Icon API interface for managing tab icons
|
|
238
|
-
* @category Components
|
|
239
|
-
*/
|
|
240
68
|
export interface IconAPI {
|
|
241
|
-
/**
|
|
242
|
-
* Sets the icon HTML content
|
|
243
|
-
* @param html - HTML string for the icon
|
|
244
|
-
* @returns The icon API for chaining
|
|
245
|
-
*/
|
|
246
69
|
setIcon: (html: string) => IconAPI;
|
|
247
|
-
/**
|
|
248
|
-
* Gets the current icon HTML content
|
|
249
|
-
* @returns HTML string for the icon
|
|
250
|
-
*/
|
|
251
70
|
getIcon: () => string;
|
|
252
|
-
/**
|
|
253
|
-
* Gets the icon DOM element
|
|
254
|
-
* @returns The icon element or null if not present
|
|
255
|
-
*/
|
|
256
71
|
getElement: () => HTMLElement | null;
|
|
257
72
|
}
|
|
258
|
-
/**
|
|
259
|
-
* Text API interface for managing tab text
|
|
260
|
-
* @category Components
|
|
261
|
-
*/
|
|
262
73
|
export interface TextAPI {
|
|
263
|
-
/**
|
|
264
|
-
* Sets the text content
|
|
265
|
-
* @param content - Text content
|
|
266
|
-
* @returns The text API for chaining
|
|
267
|
-
*/
|
|
268
74
|
setText: (content: string) => TextAPI;
|
|
269
|
-
/**
|
|
270
|
-
* Gets the current text content
|
|
271
|
-
* @returns Tab text content
|
|
272
|
-
*/
|
|
273
75
|
getText: () => string;
|
|
274
|
-
/**
|
|
275
|
-
* Gets the text DOM element
|
|
276
|
-
* @returns The text element or null if not present
|
|
277
|
-
*/
|
|
278
76
|
getElement: () => HTMLElement | null;
|
|
279
77
|
}
|
|
280
|
-
/**
|
|
281
|
-
* Tab component interface
|
|
282
|
-
* @category Components
|
|
283
|
-
*/
|
|
284
78
|
export interface TabComponent {
|
|
285
|
-
/** The tab's DOM element */
|
|
286
79
|
element: HTMLElement;
|
|
287
|
-
/** The button the tab is built on */
|
|
288
80
|
button?: TabButton;
|
|
289
|
-
/**
|
|
290
|
-
* The tab's badge component, or `undefined`. **It may be undefined until
|
|
291
|
-
* the badge is shown**, whatever the `badge` option said: the contract
|
|
292
|
-
* (3.0.0) is that a tab creates its badge no later than when it shows it,
|
|
293
|
-
* so that a later release can create it only then. Today it exists from
|
|
294
|
-
* the first `setBadge()`, or from creation with the `badge` option. To set,
|
|
295
|
-
* read, show or hide the badge, use `setBadge()`, `getBadge()`,
|
|
296
|
-
* `showBadge()` and `hideBadge()`, which work whether it exists yet or not;
|
|
297
|
-
* check this for `undefined` before reading it.
|
|
298
|
-
*/
|
|
299
81
|
badge?: BadgeComponent | undefined;
|
|
300
|
-
/** Gets a class name with the component's prefix */
|
|
301
82
|
getClass: (name: string) => string;
|
|
302
|
-
/** Gets the tab's value attribute */
|
|
303
83
|
getValue: () => string;
|
|
304
|
-
/** Sets the tab's value attribute */
|
|
305
84
|
setValue: (value: string) => TabComponent;
|
|
306
|
-
/** Activates the tab (sets active state) */
|
|
307
85
|
activate: () => TabComponent;
|
|
308
|
-
/** Deactivates the tab (sets inactive state) */
|
|
309
86
|
deactivate: () => TabComponent;
|
|
310
|
-
/** Checks if the tab is active */
|
|
311
87
|
isActive: () => boolean;
|
|
312
|
-
/** Enables the tab (removes disabled attribute) */
|
|
313
88
|
enable: () => TabComponent;
|
|
314
|
-
/** Disables the tab (adds disabled attribute) */
|
|
315
89
|
disable: () => TabComponent;
|
|
316
|
-
/** Whether the tab is disabled */
|
|
317
90
|
isDisabled: () => boolean;
|
|
318
|
-
/** Sets the tab's text content */
|
|
319
91
|
setText: (content: string) => TabComponent;
|
|
320
|
-
/** Gets the tab's text content */
|
|
321
92
|
getText: () => string;
|
|
322
|
-
/** Sets the tab's icon */
|
|
323
93
|
setIcon: (icon: string) => TabComponent;
|
|
324
|
-
/** Gets the tab's icon HTML content */
|
|
325
94
|
getIcon: () => string;
|
|
326
|
-
/** Sets the tab's badge */
|
|
327
95
|
setBadge: (content: string | number) => TabComponent;
|
|
328
|
-
/** Gets the tab's badge content */
|
|
329
96
|
getBadge: () => string;
|
|
330
|
-
/** Shows the tab's badge */
|
|
331
97
|
showBadge: () => TabComponent;
|
|
332
|
-
/** Hides the tab's badge */
|
|
333
98
|
hideBadge: () => TabComponent;
|
|
334
|
-
/**
|
|
335
|
-
* Gets the badge component instance, or `undefined`: it may not exist
|
|
336
|
-
* until the badge is shown (see `badge`)
|
|
337
|
-
*/
|
|
338
99
|
getBadgeComponent: () => BadgeComponent | undefined;
|
|
339
|
-
/** Updates the tab's layout style based on content */
|
|
340
100
|
updateLayoutStyle: () => void;
|
|
341
|
-
/**
|
|
342
|
-
* Adds an event listener to the tab.
|
|
343
|
-
* Declared on the component, not picked off the events feature: `Pick`
|
|
344
|
-
* rebinds a polymorphic `this`.
|
|
345
|
-
* @param event - One of the events in {@link TabEvents}
|
|
346
|
-
* @param handler - Receives the payload declared for that event
|
|
347
|
-
* @returns The tab for chaining
|
|
348
|
-
*/
|
|
349
101
|
on: <K extends keyof TabEvents>(event: K, handler: TabEvents[K]) => TabComponent;
|
|
350
|
-
/**
|
|
351
|
-
* Removes an event listener from the tab
|
|
352
|
-
* @param event - One of the events in {@link TabEvents}
|
|
353
|
-
* @param handler - The same handler that was passed to `on`
|
|
354
|
-
* @returns The tab for chaining
|
|
355
|
-
*/
|
|
356
102
|
off: <K extends keyof TabEvents>(event: K, handler: TabEvents[K]) => TabComponent;
|
|
357
|
-
/** Destroys the tab component and cleans up resources */
|
|
358
103
|
destroy: () => void;
|
|
359
|
-
/** API for managing disabled state */
|
|
360
104
|
disabled?: {
|
|
361
105
|
enable: () => void;
|
|
362
106
|
disable: () => void;
|
|
363
107
|
isDisabled: () => boolean;
|
|
364
108
|
};
|
|
365
|
-
/** API for managing component lifecycle */
|
|
366
109
|
lifecycle?: {
|
|
367
110
|
destroy: () => void;
|
|
368
111
|
};
|
|
369
112
|
}
|
|
370
|
-
/**
|
|
371
|
-
* Tabs component interface
|
|
372
|
-
* @category Components
|
|
373
|
-
*/
|
|
374
113
|
export interface TabsComponent {
|
|
375
|
-
/**
|
|
376
|
-
* Container element
|
|
377
|
-
*/
|
|
378
114
|
element: HTMLElement;
|
|
379
|
-
/**
|
|
380
|
-
* Gets a class name with the component's prefix
|
|
381
|
-
* @param name - Base class name
|
|
382
|
-
* @returns Prefixed class name
|
|
383
|
-
*/
|
|
384
115
|
getClass: (name: string) => string;
|
|
385
|
-
/**
|
|
386
|
-
* Creates and adds a new tab to the tabs component
|
|
387
|
-
* @param config - Tab configuration
|
|
388
|
-
* @returns The created tab component
|
|
389
|
-
*/
|
|
390
116
|
addTab: (config: TabConfig) => TabComponent;
|
|
391
|
-
/**
|
|
392
|
-
* Adds a pre-created tab to the tabs component
|
|
393
|
-
* @param tab - Tab component to add
|
|
394
|
-
* @returns Tabs component for chaining
|
|
395
|
-
*/
|
|
396
117
|
add: (tab: TabComponent) => TabsComponent;
|
|
397
|
-
/**
|
|
398
|
-
* Gets all tabs in the container
|
|
399
|
-
* @returns Array of tab components
|
|
400
|
-
*/
|
|
401
118
|
getTabs: () => TabComponent[];
|
|
402
|
-
/**
|
|
403
|
-
* Gets the active tab
|
|
404
|
-
* @returns Active tab or null if none
|
|
405
|
-
*/
|
|
406
119
|
getActiveTab: () => TabComponent | null;
|
|
407
|
-
/** Reads the current model value without changing selection. */
|
|
408
120
|
getValue: () => string | null;
|
|
409
|
-
/**
|
|
410
|
-
* Gets the indicator component
|
|
411
|
-
* @returns Tab indicator component
|
|
412
|
-
*/
|
|
413
121
|
getIndicator?: () => TabIndicator;
|
|
414
|
-
/**
|
|
415
|
-
* Sets a tab as active. Silent: only a click or a key emits `change`
|
|
416
|
-
* @param tabOrValue - Tab component or tab value
|
|
417
|
-
* @returns Tabs component for chaining
|
|
418
|
-
*/
|
|
419
122
|
setActiveTab: (tabOrValue: TabComponent | string) => TabsComponent;
|
|
420
|
-
/**
|
|
421
|
-
* Removes a tab from the container
|
|
422
|
-
* @param tabOrValue - Tab component or tab value
|
|
423
|
-
* @returns Tabs component for chaining
|
|
424
|
-
*/
|
|
425
123
|
removeTab: (tabOrValue: TabComponent | string) => TabsComponent;
|
|
426
|
-
/**
|
|
427
|
-
* Adds an event listener.
|
|
428
|
-
* Declared on the component, not picked off the events feature: `Pick`
|
|
429
|
-
* rebinds a polymorphic `this`.
|
|
430
|
-
* @param event - One of the events in {@link TabsEvents}
|
|
431
|
-
* @param handler - Receives the payload declared for that event
|
|
432
|
-
* @returns Tabs component for chaining
|
|
433
|
-
*/
|
|
434
124
|
on: <K extends keyof TabsEvents>(event: K, handler: TabsEvents[K]) => TabsComponent;
|
|
435
|
-
/**
|
|
436
|
-
* Removes an event listener
|
|
437
|
-
* @param event - One of the events in {@link TabsEvents}
|
|
438
|
-
* @param handler - The same handler that was passed to `on`
|
|
439
|
-
* @returns Tabs component for chaining
|
|
440
|
-
*/
|
|
441
125
|
off: <K extends keyof TabsEvents>(event: K, handler: TabsEvents[K]) => TabsComponent;
|
|
442
|
-
/**
|
|
443
|
-
* Emit one of the group's own events ({@link TabsEvents}), with its payload:
|
|
444
|
-
* the names and payloads `on` and `off` accept.
|
|
445
|
-
* @param event - One of the events in {@link TabsEvents}
|
|
446
|
-
* @param data - The payload declared for that event
|
|
447
|
-
* @returns Tabs component for chaining
|
|
448
|
-
*/
|
|
449
126
|
emit?<K extends keyof TabsEvents>(event: K, data: Parameters<TabsEvents[K]>[0]): this;
|
|
450
|
-
/**
|
|
451
|
-
* Destroys the tabs component and all tabs
|
|
452
|
-
*/
|
|
453
127
|
destroy: () => void;
|
|
454
|
-
/**
|
|
455
|
-
* Activation handler shared by the component's click and keyboard paths.
|
|
456
|
-
* Use setActiveTab() to select a tab from application code.
|
|
457
|
-
* @internal
|
|
458
|
-
*/
|
|
459
128
|
handleTabClick: (event: Event | null, tab: TabComponent) => void;
|
|
460
|
-
/**
|
|
461
|
-
* Scroll container owned by the scrollable feature.
|
|
462
|
-
* @internal
|
|
463
|
-
*/
|
|
464
129
|
scrollContainer?: HTMLElement;
|
|
465
130
|
}
|
|
@@ -1,7 +1,4 @@
|
|
|
1
1
|
import { TabComponent } from "./types.js";
|
|
2
|
-
/**
|
|
3
|
-
* Tabs members read by these helpers; each one is checked before use
|
|
4
|
-
*/
|
|
5
2
|
interface TabsHost {
|
|
6
3
|
element?: HTMLElement;
|
|
7
4
|
tabs?: TabComponent[];
|
|
@@ -10,78 +7,15 @@ interface TabsHost {
|
|
|
10
7
|
setActiveTab?: (tabOrValue: TabComponent | string) => unknown;
|
|
11
8
|
handleTabClick?: (event: Event | null, tab: TabComponent) => void;
|
|
12
9
|
}
|
|
13
|
-
/**
|
|
14
|
-
* Gets the active tab from a component
|
|
15
|
-
* @param component - Component with tabs
|
|
16
|
-
* @returns Active tab or null
|
|
17
|
-
*/
|
|
18
10
|
export declare function getActiveTab(component: TabsHost): TabComponent | null;
|
|
19
|
-
/**
|
|
20
|
-
* A fresh id for a tab group, so two tablists can share tab values.
|
|
21
|
-
*
|
|
22
|
-
* A tab's id was `tab-<value>`, which meant two groups on one page
|
|
23
|
-
* with a value in common produced duplicate ids -- and, because panels were
|
|
24
|
-
* resolved across the whole document, each group showed and hid the other's
|
|
25
|
-
* panels. The group id is what makes both unique.
|
|
26
|
-
*/
|
|
27
11
|
export declare function allocateTabsGroupId(): string;
|
|
28
|
-
/**
|
|
29
|
-
* A tab's element id within its group: `tab-<groupId>-<value>` for a value of
|
|
30
|
-
* `[A-Za-z0-9_-]`, and `tabx-<groupId>-<encoded value>` otherwise.
|
|
31
|
-
*/
|
|
32
12
|
export declare const tabIdFor: (groupId: string, value: string) => string;
|
|
33
|
-
/**
|
|
34
|
-
* The panel id a group looks for when a page does not label its panels:
|
|
35
|
-
* `tabpanel-<groupId>-<value>`, or `tabpanelx-<groupId>-<encoded value>` for a
|
|
36
|
-
* value with other characters, as {@link tabIdFor} derives the tab's.
|
|
37
|
-
*/
|
|
38
13
|
export declare const tabPanelIdFor: (groupId: string, value: string) => string;
|
|
39
|
-
/**
|
|
40
|
-
* Records a tab's value and group on its element: the value as `data-value`,
|
|
41
|
-
* which the panel lookup reads instead of parsing the id.
|
|
42
|
-
*/
|
|
43
14
|
export declare function registerTab(element: HTMLElement, groupId: string, value: string): void;
|
|
44
|
-
/**
|
|
45
|
-
* The panel registered to a tab, or null.
|
|
46
|
-
*
|
|
47
|
-
* A page registers a panel either by labelling it with the tab's own id, or
|
|
48
|
-
* by giving it the conventional id, {@link tabPanelIdFor} of the tab's group
|
|
49
|
-
* and value. Both are keyed on the group, so a panel can only ever belong to
|
|
50
|
-
* one group.
|
|
51
|
-
*/
|
|
52
15
|
export declare function findRegisteredPanel(tab: HTMLElement): HTMLElement | null;
|
|
53
|
-
/**
|
|
54
|
-
* Points a tab's `aria-controls` at its panel, and only at one that exists.
|
|
55
|
-
*
|
|
56
|
-
* A tab whose panel the page never supplied carries no `aria-controls` rather
|
|
57
|
-
* than a reference resolving to nothing. Panels added after the tabs are
|
|
58
|
-
* linked when this runs again, which is why it cannot be decided once at
|
|
59
|
-
* creation.
|
|
60
|
-
*/
|
|
61
16
|
export declare function syncTabControls(element: HTMLElement): void;
|
|
62
|
-
/**
|
|
63
|
-
* Updates tab panels based on active tab
|
|
64
|
-
* @param component - Component with tabs
|
|
65
|
-
*/
|
|
66
17
|
export declare function updateTabPanels(component: TabsHost): void;
|
|
67
|
-
/**
|
|
68
|
-
* Gives the tablist a single tab stop: the active tab, or the first enabled
|
|
69
|
-
* one when none is active. Every other tab takes tabindex -1 and is reached
|
|
70
|
-
* with the arrow keys (WAI-ARIA tabs pattern).
|
|
71
|
-
* @param component - Tabs component
|
|
72
|
-
*/
|
|
73
18
|
export declare function syncTabStops(component: TabsHost): void;
|
|
74
|
-
/**
|
|
75
|
-
* Sets up keyboard navigation for tabs.
|
|
76
|
-
*
|
|
77
|
-
* The arrows, Home and End move focus between the enabled tabs, and the tab stop
|
|
78
|
-
* with it; Space or Enter, through the native button, selects the focused tab.
|
|
79
|
-
* That is m3.material.io's model ("Don't use Space/Enter for navigating tabs")
|
|
80
|
-
* and material-web's default. `autoActivate` selects on every move instead. When
|
|
81
|
-
* focus leaves the tablist, the tab stop returns to the selected tab.
|
|
82
|
-
* @param component - Tabs component
|
|
83
|
-
* @param options - `autoActivate`: select the tab an arrow key moves to
|
|
84
|
-
*/
|
|
85
19
|
export declare function setupKeyboardNavigation(component: TabsHost, options?: {
|
|
86
20
|
autoActivate?: boolean;
|
|
87
21
|
}): void;
|
|
@@ -1,151 +1,69 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* TextField variant constants
|
|
3
|
-
* @category Components
|
|
4
|
-
*/
|
|
5
1
|
declare const TEXT_FIELD_VARIANTS: {
|
|
6
|
-
/** Filled variant with background and animated label */
|
|
7
2
|
readonly FILLED: "filled";
|
|
8
|
-
/** Outlined variant with border and animated label */
|
|
9
3
|
readonly OUTLINED: "outlined";
|
|
10
4
|
};
|
|
11
|
-
/**
|
|
12
|
-
* TextField state constants
|
|
13
|
-
* @category Components
|
|
14
|
-
*/
|
|
15
5
|
declare const TEXT_FIELD_STATES: {
|
|
16
|
-
/** TextField is active (focused) */
|
|
17
6
|
readonly ACTIVE: "active";
|
|
18
|
-
/** TextField is inactive (not focused) */
|
|
19
7
|
readonly INACTIVE: "inactive";
|
|
20
|
-
/** TextField is disabled */
|
|
21
8
|
readonly DISABLED: "disabled";
|
|
22
9
|
};
|
|
23
|
-
/**
|
|
24
|
-
* TextField type constants
|
|
25
|
-
* @category Components
|
|
26
|
-
*/
|
|
27
10
|
declare const TEXT_FIELD_TYPES: {
|
|
28
|
-
/** Standard text input */
|
|
29
11
|
readonly TEXT: "text";
|
|
30
|
-
/** Password input with obscured characters */
|
|
31
12
|
readonly PASSWORD: "password";
|
|
32
|
-
/** Email input with email validation */
|
|
33
13
|
readonly EMAIL: "email";
|
|
34
|
-
/** Numeric input */
|
|
35
14
|
readonly NUMBER: "number";
|
|
36
|
-
/** Telephone number input */
|
|
37
15
|
readonly TEL: "tel";
|
|
38
|
-
/** URL input with URL validation */
|
|
39
16
|
readonly URL: "url";
|
|
40
|
-
/** Search input */
|
|
41
17
|
readonly SEARCH: "search";
|
|
42
|
-
/** Multiline text input (textarea) */
|
|
43
18
|
readonly MULTILINE: "multiline";
|
|
44
19
|
};
|
|
45
|
-
/**
|
|
46
|
-
* TextField event constants
|
|
47
|
-
* @category Components
|
|
48
|
-
*/
|
|
49
20
|
declare const TEXT_FIELD_EVENTS: {
|
|
50
|
-
/** Emitted on native input change; setValue() is silent */
|
|
51
21
|
readonly CHANGE: "change";
|
|
52
|
-
/** Fired during input */
|
|
53
22
|
readonly INPUT: "input";
|
|
54
|
-
/** Fired when text field receives focus */
|
|
55
23
|
readonly FOCUS: "focus";
|
|
56
|
-
/** Fired when text field loses focus */
|
|
57
24
|
readonly BLUR: "blur";
|
|
58
|
-
/** Fired when the trailing icon button is activated (`trailingIconLabel`) */
|
|
59
25
|
readonly TRAILING: "trailing";
|
|
60
|
-
/** Legacy name, not emitted; listen for keydown on the input and check key === "Enter" */
|
|
61
26
|
readonly ENTER: "enter";
|
|
62
|
-
/** Native input event only; not emitted through on() */
|
|
63
27
|
readonly KEYDOWN: "keydown";
|
|
64
|
-
/** Native input event only; not emitted through on() */
|
|
65
28
|
readonly KEYUP: "keyup";
|
|
66
29
|
};
|
|
67
|
-
/**
|
|
68
|
-
* TextField density constants
|
|
69
|
-
* @category Components
|
|
70
|
-
*/
|
|
71
30
|
declare const TEXT_FIELD_DENSITY: {
|
|
72
|
-
/** Default density (56px height) */
|
|
73
31
|
readonly DEFAULT: "default";
|
|
74
|
-
/** Compact density (40px height) */
|
|
75
32
|
readonly COMPACT: "compact";
|
|
76
33
|
};
|
|
77
|
-
/**
|
|
78
|
-
* Default text field configuration values
|
|
79
|
-
* @category Components
|
|
80
|
-
*/
|
|
81
34
|
declare const TEXT_FIELD_DEFAULTS: {
|
|
82
|
-
/** Default input type */
|
|
83
35
|
readonly TYPE: "text";
|
|
84
|
-
/** Default visual variant */
|
|
85
36
|
readonly VARIANT: "filled";
|
|
86
|
-
/** Default density level */
|
|
87
37
|
readonly DENSITY: "default";
|
|
88
|
-
/** Default disabled state */
|
|
89
38
|
readonly DISABLED: false;
|
|
90
|
-
/** Default required state */
|
|
91
39
|
readonly REQUIRED: false;
|
|
92
|
-
/** Default error state */
|
|
93
40
|
readonly ERROR: false;
|
|
94
|
-
/** Default label floating behavior (always floats on focus) */
|
|
95
41
|
readonly FLOAT_LABEL: true;
|
|
96
|
-
/** Default animation duration in milliseconds */
|
|
97
42
|
readonly ANIMATION_DURATION: 150;
|
|
98
43
|
};
|
|
99
|
-
/**
|
|
100
|
-
* CSS class names used by the text field component
|
|
101
|
-
* @category Components
|
|
102
|
-
*/
|
|
103
44
|
declare const TEXT_FIELD_CLASSES: {
|
|
104
|
-
/** Root element class */
|
|
105
45
|
readonly ROOT: "text-field";
|
|
106
|
-
/** Input element class */
|
|
107
46
|
readonly INPUT: "text-field__input";
|
|
108
|
-
/** Label element class */
|
|
109
47
|
readonly LABEL: "text-field__label";
|
|
110
|
-
/** Reserved slot; the current component has no separate container element. */
|
|
111
48
|
readonly CONTAINER: "text-field__container";
|
|
112
|
-
/** Filled variant class */
|
|
113
49
|
readonly FILLED: "text-field--filled";
|
|
114
|
-
/** Outlined variant class */
|
|
115
50
|
readonly OUTLINED: "text-field--outlined";
|
|
116
|
-
/** Focused state class */
|
|
117
51
|
readonly FOCUSED: "text-field--focused";
|
|
118
|
-
/** Disabled state class */
|
|
119
52
|
readonly DISABLED: "text-field--disabled";
|
|
120
|
-
/** Error state class */
|
|
121
53
|
readonly ERROR: "text-field--error";
|
|
122
|
-
/** Required indicator class */
|
|
123
54
|
readonly REQUIRED: "text-field--required";
|
|
124
|
-
/** Supporting text class */
|
|
125
55
|
readonly SUPPORTING_TEXT: "text-field__helper";
|
|
126
|
-
/** Supporting text error class */
|
|
127
56
|
readonly SUPPORTING_TEXT_ERROR: "text-field__helper--error";
|
|
128
|
-
/** Leading icon class */
|
|
129
57
|
readonly LEADING_ICON: "text-field__leading-icon";
|
|
130
|
-
/** Trailing icon class */
|
|
131
58
|
readonly TRAILING_ICON: "text-field__trailing-icon";
|
|
132
|
-
/** Prefix text class */
|
|
133
59
|
readonly PREFIX_TEXT: "text-field__prefix";
|
|
134
|
-
/** Suffix text class */
|
|
135
60
|
readonly SUFFIX_TEXT: "text-field__suffix";
|
|
136
|
-
/** Outline of the outlined variant, drawn in three segments */
|
|
137
61
|
readonly OUTLINE: "text-field__outline";
|
|
138
|
-
/** Outline segment before the label (start corner) */
|
|
139
62
|
readonly OUTLINE_LEADING: "text-field__outline-leading";
|
|
140
|
-
/** Outline segment the floating label sits in */
|
|
141
63
|
readonly OUTLINE_NOTCH: "text-field__outline-notch";
|
|
142
|
-
/** Outline segment after the label */
|
|
143
64
|
readonly OUTLINE_TRAILING: "text-field__outline-trailing";
|
|
144
|
-
/** Outline whose notch is open around the floating label */
|
|
145
65
|
readonly OUTLINE_NOTCHED: "text-field__outline--notched";
|
|
146
|
-
/** Outlined field laid out right to left, from its computed direction */
|
|
147
66
|
readonly RTL: "text-field--rtl";
|
|
148
|
-
/** Multiline class */
|
|
149
67
|
readonly MULTILINE: "text-field--multiline";
|
|
150
68
|
};
|
|
151
69
|
export { TEXT_FIELD_VARIANTS, TEXT_FIELD_STATES, TEXT_FIELD_TYPES, TEXT_FIELD_EVENTS, TEXT_FIELD_DENSITY, TEXT_FIELD_DEFAULTS, TEXT_FIELD_CLASSES, };
|