material 3.9.0 → 3.10.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/NOTICE +3 -1
- package/README.md +5 -5
- package/dist/components/badge/index.d.ts +167 -3
- package/dist/components/bottom-app-bar/index.d.ts +141 -4
- package/dist/components/bottom-sheet/index.d.ts +114 -2
- package/dist/components/button/index.d.ts +10 -5
- package/dist/components/button-group/button-group.js +1 -0
- package/dist/components/button-group/config.js +9 -6
- package/dist/components/button-group/index.d.ts +250 -6
- package/dist/components/card/api.js +19 -0
- package/dist/components/card/index.d.ts +326 -5
- package/dist/components/carousel/features/slides.js +17 -7
- package/dist/components/carousel/index.d.ts +102 -3
- package/dist/components/checkbox/index.d.ts +217 -5
- package/dist/components/chips/chip/chip.js +4 -3
- package/dist/components/chips/index.d.ts +343 -3
- package/dist/components/datepicker/datepicker.js +62 -84
- package/dist/components/datepicker/index.d.ts +313 -2
- package/dist/components/datepicker/render.js +25 -21
- package/dist/components/datepicker/utils.js +65 -110
- package/dist/components/dialog/features.js +1 -1
- package/dist/components/dialog/index.d.ts +333 -3
- package/dist/components/divider/index.d.ts +96 -3
- package/dist/components/drawer/features/items.js +10 -2
- package/dist/components/drawer/index.d.ts +196 -3
- package/dist/components/extended-fab/index.d.ts +224 -2
- package/dist/components/fab/index.d.ts +183 -2
- package/dist/components/fab-menu/index.d.ts +106 -6
- package/dist/components/icon-button/index.d.ts +11 -4
- package/dist/components/list/features/anatomy.js +25 -6
- package/dist/components/list/features/selection.js +30 -2
- package/dist/components/list/index.d.ts +299 -6
- package/dist/components/loading-indicator/index.d.ts +91 -3
- package/dist/components/menu/features/controller.js +2 -0
- package/dist/components/menu/index.d.ts +10 -6
- package/dist/components/menu/inner.d.ts +2 -2
- package/dist/components/menu/on-demand.d.ts +5 -9
- package/dist/components/menu/types.d.ts +12 -7
- package/dist/components/navigation-bar/index.d.ts +70 -2
- package/dist/components/navigation-rail/index.d.ts +98 -2
- package/dist/components/progress/index.d.ts +9 -2
- package/dist/components/progress/types.d.ts +5 -5
- package/dist/components/radios/index.d.ts +158 -3
- package/dist/components/search/features/states.js +20 -39
- package/dist/components/search/features/structure.js +24 -4
- package/dist/components/search/features/suggestions.js +4 -0
- package/dist/components/search/index.d.ts +255 -2
- package/dist/components/select/index.d.ts +252 -6
- package/dist/components/side-sheet/index.d.ts +104 -2
- package/dist/components/slider/index.d.ts +236 -2
- package/dist/components/snackbar/api.js +26 -0
- package/dist/components/snackbar/constants.d.ts +4 -0
- package/dist/components/snackbar/constants.js +3 -1
- package/dist/components/snackbar/index.d.ts +215 -4
- package/dist/components/split-button/index.d.ts +10 -3
- package/dist/components/split-button/types.d.ts +3 -3
- package/dist/components/switch/index.d.ts +190 -3
- package/dist/components/tabs/index.d.ts +454 -12
- package/dist/components/tabs/index.js +1 -1
- package/dist/components/tabs/responsive-legacy.js +65 -0
- package/dist/components/tabs/responsive.d.ts +7 -32
- package/dist/components/tabs/responsive.js +4 -63
- package/dist/components/tabs/tabs.js +1 -0
- package/dist/components/text-field/config.js +3 -4
- package/dist/components/text-field/features/field.js +61 -0
- package/dist/components/text-field/features/leading-icon.js +12 -45
- package/dist/components/text-field/features/prefix-text.js +6 -40
- package/dist/components/text-field/features/suffix-text.js +6 -40
- package/dist/components/text-field/index.d.ts +338 -3
- package/dist/components/timepicker/constants.d.ts +4 -4
- package/dist/components/timepicker/constants.js +2 -2
- package/dist/components/timepicker/dial.js +30 -3
- package/dist/components/timepicker/index.d.ts +279 -5
- package/dist/components/timepicker/render.js +15 -9
- package/dist/components/toolbar/index.d.ts +145 -6
- package/dist/components/tooltip/index.d.ts +155 -3
- package/dist/components/top-app-bar/index.d.ts +92 -5
- package/dist/core/canvas/index.d.ts +172 -5
- package/dist/core/canvas/utils.js +3 -13
- package/dist/core/compose/cleanup.d.ts +1 -1
- package/dist/core/compose/features/icon-opt-in.js +5 -0
- package/dist/core/compose/features/icon-slot.js +100 -0
- package/dist/core/compose/features/textinput.js +2 -0
- package/dist/core/compose/features/track.js +4 -0
- package/dist/core/compose/index.d.ts +741 -8
- package/dist/core/config/component.d.ts +1 -4
- package/dist/core/dom/create.d.ts +1 -4
- package/dist/core/dom/index.d.ts +233 -12
- package/dist/core/index.d.ts +93 -14
- package/dist/core/navigation/destinations.d.ts +6 -6
- package/dist/core/shapes/index.d.ts +286 -6
- package/dist/core/state/index.d.ts +98 -5
- package/dist/core/theme/index.d.ts +80 -4
- package/dist/core/utils/index.d.ts +95 -9
- package/dist/core/utils/mobile.d.ts +2 -2
- package/dist/elements/adapter.d.ts +3 -3
- package/dist/elements/css/bottom-sheet.css +1 -1
- package/dist/elements/css/button-group.css +1 -1
- package/dist/elements/css/button.css +1 -1
- package/dist/elements/css/datepicker.css +1 -1
- package/dist/elements/css/dialog.css +1 -1
- package/dist/elements/css/drawer.css +1 -1
- package/dist/elements/css/icon-button.css +1 -1
- package/dist/elements/css/list.css +1 -1
- package/dist/elements/css/menu.css +1 -1
- package/dist/elements/css/side-sheet.css +1 -1
- package/dist/elements/css/snackbar.css +1 -1
- package/dist/elements/css/text-field.css +1 -1
- package/dist/elements/css/timepicker.css +1 -1
- package/dist/elements/css/toolbar.css +1 -1
- package/dist/elements/datepicker.js +1 -0
- package/dist/elements/define.d.ts +3 -3
- package/dist/elements/define.js +12 -1
- package/dist/elements/drawer.js +2 -0
- package/dist/elements/index.d.ts +3974 -107
- 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 +2 -2
- package/dist/elements/preupgrade/button.css +2 -2
- package/dist/elements/preupgrade/card.css +1 -1
- 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 +2 -2
- package/dist/elements/preupgrade/extended-fab.css +1 -1
- package/dist/elements/preupgrade/fab-menu.css +1 -1
- package/dist/elements/preupgrade/fab.css +1 -1
- package/dist/elements/preupgrade/icon-button.css +2 -2
- package/dist/elements/preupgrade/list.css +2 -2
- 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 +2 -2
- 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 +2 -2
- 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/snackbar.js +2 -0
- package/dist/elements/styles.d.ts +7 -7
- package/dist/elements/styles.js +15 -15
- package/dist/elements/text-field.js +2 -0
- package/dist/index.d.ts +78 -4
- package/dist/react/create.d.ts +2 -6
- package/dist/react/index.d.ts +106 -52
- package/dist/react/jsx.d.ts +49 -49
- package/dist/solid/create.d.ts +2 -7
- package/dist/solid/index.d.ts +106 -52
- package/dist/solid/jsx.d.ts +51 -50
- package/dist/styles/badge.css +1 -1
- package/dist/styles/base-lite.css +2 -2
- package/dist/styles/base.css +2 -2
- package/dist/styles/bottom-app-bar.css +1 -1
- package/dist/styles/bottom-sheet.css +2 -2
- package/dist/styles/button-group.css +2 -2
- package/dist/styles/button.css +2 -2
- 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 +2 -2
- package/dist/styles/dialog.css +2 -2
- package/dist/styles/divider.css +1 -1
- package/dist/styles/drawer.css +2 -2
- package/dist/styles/extended-fab.css +1 -1
- package/dist/styles/fab-menu.css +1 -1
- package/dist/styles/fab.css +1 -1
- package/dist/styles/icon-button.css +2 -2
- package/dist/styles/list.css +2 -2
- package/dist/styles/loading-indicator.css +1 -1
- package/dist/styles/menu.css +2 -2
- 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 +2 -2
- package/dist/styles/slider.css +1 -1
- package/dist/styles/snackbar.css +2 -2
- 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 +2 -2
- package/dist/styles/timepicker.css +2 -2
- package/dist/styles/toolbar.css +2 -2
- 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/runtime.d.ts +6 -10
- package/dist/theme/vendor/contrast/contrast.js +1 -16
- package/dist/theme/vendor/dislike/dislike_analyzer.js +1 -16
- package/dist/theme/vendor/dynamiccolor/color_spec_2021.js +1 -16
- package/dist/theme/vendor/dynamiccolor/color_spec_2025.js +1 -16
- package/dist/theme/vendor/dynamiccolor/contrast_curve.js +1 -16
- package/dist/theme/vendor/dynamiccolor/dynamic_color.d.ts +2 -2
- package/dist/theme/vendor/dynamiccolor/dynamic_color.js +1 -16
- package/dist/theme/vendor/dynamiccolor/dynamic_scheme.d.ts +2 -2
- package/dist/theme/vendor/dynamiccolor/dynamic_scheme.js +1 -16
- package/dist/theme/vendor/dynamiccolor/material_dynamic_colors.js +1 -16
- package/dist/theme/vendor/dynamiccolor/spec_2025.js +1 -16
- package/dist/theme/vendor/dynamiccolor/spec_extensions.js +1 -16
- package/dist/theme/vendor/dynamiccolor/tone_delta_pair.js +1 -16
- package/dist/theme/vendor/dynamiccolor/variant.js +1 -16
- package/dist/theme/vendor/hct/cam16.js +1 -16
- package/dist/theme/vendor/hct/hct.js +1 -16
- package/dist/theme/vendor/hct/hct_solver.js +1 -16
- package/dist/theme/vendor/hct/viewing_conditions.js +1 -16
- package/dist/theme/vendor/palettes/tonal_palette.d.ts +6 -9
- package/dist/theme/vendor/palettes/tonal_palette.js +1 -16
- package/dist/theme/vendor/quantize/lab_point_provider.js +1 -16
- package/dist/theme/vendor/quantize/quantizer_celebi.js +1 -16
- package/dist/theme/vendor/quantize/quantizer_map.js +1 -16
- package/dist/theme/vendor/quantize/quantizer_wsmeans.js +1 -16
- package/dist/theme/vendor/quantize/quantizer_wu.js +1 -16
- package/dist/theme/vendor/score/score.js +1 -16
- package/dist/theme/vendor/temperature/temperature_cache.js +1 -16
- package/dist/theme/vendor/utils/color_utils.js +1 -16
- package/dist/theme/vendor/utils/image_utils.js +1 -16
- package/dist/theme/vendor/utils/math_utils.js +1 -16
- package/dist/theme/vendor/utils/string_utils.js +1 -16
- 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/index.d.ts +188 -53
- package/package.json +5 -1
- package/src/styles/abstract/_functions.scss +22 -1
- package/src/styles/abstract/_variables.scss +0 -2
- package/src/styles/base/_tokens.scss +12 -0
- package/src/styles/components/_bottom-sheet.scss +1 -0
- package/src/styles/components/_button-group.scss +9 -5
- package/src/styles/components/_button.scss +9 -12
- package/src/styles/components/_datepicker.scss +2 -1
- package/src/styles/components/_dialog.scss +1 -0
- package/src/styles/components/_drawer.scss +33 -65
- package/src/styles/components/_icon-button.scss +32 -33
- package/src/styles/components/_list.scss +19 -5
- package/src/styles/components/_menu.scss +1 -0
- package/src/styles/components/_side-sheet.scss +1 -0
- package/src/styles/components/_snackbar.scss +1 -0
- package/src/styles/components/_text-field.scss +17 -109
- package/src/styles/components/_timepicker.scss +19 -5
- package/src/styles/components/_toolbar.scss +4 -4
- package/src/styles/elements/_button-group.scss +17 -4
- package/src/styles/elements/_button.scss +3 -2
- package/src/styles/elements/_drawer.scss +2 -1
- package/src/styles/elements/_field.scss +25 -14
- package/src/styles/elements/_icon-button.scss +8 -3
- package/src/styles/elements/_list.scss +3 -2
- package/src/styles/elements/_text-field.scss +71 -47
- package/dist/components/badge/badge.d.ts +0 -7
- package/dist/components/badge/types.d.ts +0 -152
- package/dist/components/bottom-app-bar/bottom-app-bar.d.ts +0 -12
- package/dist/components/bottom-app-bar/types.d.ts +0 -124
- package/dist/components/bottom-sheet/bottom-sheet.d.ts +0 -7
- package/dist/components/bottom-sheet/types.d.ts +0 -100
- package/dist/components/button/button.d.ts +0 -7
- package/dist/components/button-group/button-group.d.ts +0 -7
- package/dist/components/button-group/types.d.ts +0 -227
- package/dist/components/card/card.d.ts +0 -7
- package/dist/components/card/content.d.ts +0 -22
- package/dist/components/card/types.d.ts +0 -272
- package/dist/components/carousel/carousel.d.ts +0 -4
- package/dist/components/carousel/types.d.ts +0 -81
- package/dist/components/checkbox/checkbox.d.ts +0 -8
- package/dist/components/checkbox/types.d.ts +0 -199
- package/dist/components/chips/chips.d.ts +0 -7
- package/dist/components/chips/factories.d.ts +0 -9
- package/dist/components/chips/types.d.ts +0 -304
- package/dist/components/datepicker/datepicker.d.ts +0 -7
- package/dist/components/datepicker/types.d.ts +0 -300
- package/dist/components/datepicker/types.js +0 -17
- package/dist/components/dialog/dialog.d.ts +0 -8
- package/dist/components/dialog/types.d.ts +0 -311
- package/dist/components/divider/config.d.ts +0 -43
- package/dist/components/divider/divider.d.ts +0 -7
- package/dist/components/divider/types.d.ts +0 -43
- package/dist/components/drawer/drawer.d.ts +0 -7
- package/dist/components/drawer/types.d.ts +0 -179
- package/dist/components/extended-fab/extended-fab.d.ts +0 -7
- package/dist/components/extended-fab/types.d.ts +0 -208
- package/dist/components/fab/fab.d.ts +0 -7
- package/dist/components/fab/types.d.ts +0 -168
- package/dist/components/fab-menu/fab-menu.d.ts +0 -8
- package/dist/components/fab-menu/types.d.ts +0 -91
- package/dist/components/icon-button/icon-button.d.ts +0 -7
- package/dist/components/index.d.ts +0 -82
- package/dist/components/list/features/listbox.d.ts +0 -16
- package/dist/components/list/list.d.ts +0 -7
- package/dist/components/list/types.d.ts +0 -257
- package/dist/components/loading-indicator/features/renderer.d.ts +0 -28
- package/dist/components/loading-indicator/loading-indicator.d.ts +0 -7
- package/dist/components/loading-indicator/types.d.ts +0 -53
- package/dist/components/menu/menu.d.ts +0 -7
- package/dist/components/navigation-bar/navigation-bar.d.ts +0 -3
- package/dist/components/navigation-bar/types.d.ts +0 -59
- package/dist/components/navigation-rail/navigation-rail.d.ts +0 -3
- package/dist/components/navigation-rail/types.d.ts +0 -87
- package/dist/components/progress/progress.d.ts +0 -7
- package/dist/components/radios/radios.d.ts +0 -7
- package/dist/components/radios/types.d.ts +0 -144
- package/dist/components/search/search.d.ts +0 -7
- package/dist/components/search/types.d.ts +0 -235
- package/dist/components/select/select.d.ts +0 -7
- package/dist/components/select/types.d.ts +0 -232
- package/dist/components/side-sheet/side-sheet.d.ts +0 -7
- package/dist/components/side-sheet/types.d.ts +0 -91
- package/dist/components/slider/slider.d.ts +0 -7
- package/dist/components/slider/types.d.ts +0 -218
- package/dist/components/snackbar/snackbar.d.ts +0 -9
- package/dist/components/snackbar/types.d.ts +0 -180
- package/dist/components/split-button/split-button.d.ts +0 -7
- package/dist/components/switch/switch.d.ts +0 -7
- package/dist/components/switch/types.d.ts +0 -171
- package/dist/components/tabs/indicator.d.ts +0 -44
- package/dist/components/tabs/tab.d.ts +0 -7
- package/dist/components/tabs/tabs.d.ts +0 -7
- package/dist/components/tabs/types.d.ts +0 -304
- package/dist/components/tabs/utils.d.ts +0 -46
- package/dist/components/text-field/features/trailing-icon.d.ts +0 -54
- package/dist/components/text-field/text-field.d.ts +0 -7
- package/dist/components/text-field/types.d.ts +0 -261
- package/dist/components/timepicker/timepicker.d.ts +0 -3
- package/dist/components/timepicker/types.d.ts +0 -258
- package/dist/components/toolbar/toolbar.d.ts +0 -8
- package/dist/components/toolbar/types.d.ts +0 -129
- package/dist/components/tooltip/tooltip.d.ts +0 -7
- package/dist/components/tooltip/types.d.ts +0 -137
- package/dist/components/top-app-bar/top-app-bar.d.ts +0 -7
- package/dist/components/top-app-bar/types.d.ts +0 -80
- package/dist/core/canvas/animation.d.ts +0 -20
- package/dist/core/canvas/drawing.d.ts +0 -67
- package/dist/core/canvas/resize.d.ts +0 -8
- package/dist/core/canvas/utils.d.ts +0 -62
- package/dist/core/compose/base.d.ts +0 -18
- package/dist/core/compose/features/badge.d.ts +0 -27
- package/dist/core/compose/features/checkable.d.ts +0 -33
- package/dist/core/compose/features/debounce.d.ts +0 -45
- package/dist/core/compose/features/disabled.d.ts +0 -26
- package/dist/core/compose/features/events.d.ts +0 -31
- package/dist/core/compose/features/index.d.ts +0 -34
- package/dist/core/compose/features/input.d.ts +0 -54
- package/dist/core/compose/features/lifecycle.d.ts +0 -41
- package/dist/core/compose/features/position.d.ts +0 -36
- package/dist/core/compose/features/ripple.d.ts +0 -35
- package/dist/core/compose/features/size.d.ts +0 -12
- package/dist/core/compose/features/style.d.ts +0 -11
- package/dist/core/compose/features/textinput.d.ts +0 -66
- package/dist/core/compose/features/textlabel.d.ts +0 -34
- package/dist/core/compose/features/throttle.d.ts +0 -38
- package/dist/core/compose/features/track.d.ts +0 -24
- package/dist/core/compose/features/variant.d.ts +0 -12
- package/dist/core/compose/features/withEvents.d.ts +0 -27
- package/dist/core/compose/pipe.d.ts +0 -55
- package/dist/core/compose/utils/type-guards.d.ts +0 -17
- package/dist/core/config.d.ts +0 -72
- package/dist/core/dom/attributes.d.ts +0 -34
- package/dist/core/dom/classes.d.ts +0 -29
- package/dist/core/dom/events.d.ts +0 -43
- package/dist/core/dom/focus.d.ts +0 -15
- package/dist/core/dom/html.d.ts +0 -16
- package/dist/core/dom/layer.d.ts +0 -57
- package/dist/core/dom/roving.d.ts +0 -18
- package/dist/core/shapes/cubic.d.ts +0 -45
- package/dist/core/shapes/material.d.ts +0 -131
- package/dist/core/shapes/polygon.d.ts +0 -38
- package/dist/core/state/events.d.ts +0 -25
- package/dist/core/state/store.d.ts +0 -60
- package/dist/core/theme/shape.d.ts +0 -5
- package/dist/core/theme/tokens.d.ts +0 -67
- package/dist/core/utils/background.d.ts +0 -13
- package/dist/core/utils/color.d.ts +0 -6
- package/dist/core/utils/object.d.ts +0 -11
- package/dist/core/utils/performance.d.ts +0 -32
- package/dist/core/utils/theme.d.ts +0 -17
- package/dist/core/utils/url.d.ts +0 -6
- package/dist/elements/badge.d.ts +0 -57
- package/dist/elements/bottom-app-bar.d.ts +0 -66
- package/dist/elements/bottom-sheet.d.ts +0 -107
- package/dist/elements/button-group.d.ts +0 -142
- package/dist/elements/button.d.ts +0 -101
- package/dist/elements/card.d.ts +0 -69
- package/dist/elements/carousel.d.ts +0 -119
- package/dist/elements/checkbox.d.ts +0 -97
- package/dist/elements/chips.d.ts +0 -126
- package/dist/elements/datepicker.d.ts +0 -131
- package/dist/elements/dialog.d.ts +0 -101
- package/dist/elements/divider.d.ts +0 -52
- package/dist/elements/drawer.d.ts +0 -119
- package/dist/elements/extended-fab.d.ts +0 -97
- package/dist/elements/fab-menu.d.ts +0 -102
- package/dist/elements/fab.d.ts +0 -71
- package/dist/elements/list.d.ts +0 -127
- package/dist/elements/loading-indicator.d.ts +0 -47
- package/dist/elements/menu.d.ts +0 -144
- package/dist/elements/navigation-bar.d.ts +0 -104
- package/dist/elements/navigation-rail.d.ts +0 -145
- package/dist/elements/progress.d.ts +0 -87
- package/dist/elements/radios.d.ts +0 -92
- package/dist/elements/search.d.ts +0 -202
- package/dist/elements/select.d.ts +0 -119
- package/dist/elements/side-sheet.d.ts +0 -86
- package/dist/elements/slider.d.ts +0 -160
- package/dist/elements/snackbar.d.ts +0 -87
- package/dist/elements/split-button.d.ts +0 -87
- package/dist/elements/switch.d.ts +0 -98
- package/dist/elements/tabs.d.ts +0 -76
- package/dist/elements/text-field.d.ts +0 -170
- package/dist/elements/timepicker.d.ts +0 -148
- package/dist/elements/toolbar.d.ts +0 -98
- package/dist/elements/tooltip.d.ts +0 -75
- package/dist/elements/top-app-bar.d.ts +0 -60
- package/dist/react/badge.d.ts +0 -4
- package/dist/react/bottom-app-bar.d.ts +0 -5
- package/dist/react/bottom-sheet.d.ts +0 -4
- package/dist/react/button-group-item.d.ts +0 -3
- package/dist/react/button-group.d.ts +0 -7
- package/dist/react/button.d.ts +0 -5
- package/dist/react/card.d.ts +0 -4
- package/dist/react/carousel-item.d.ts +0 -3
- package/dist/react/carousel.d.ts +0 -4
- package/dist/react/checkbox.d.ts +0 -4
- package/dist/react/chip.d.ts +0 -3
- package/dist/react/chips.d.ts +0 -4
- package/dist/react/datepicker.d.ts +0 -4
- package/dist/react/dialog.d.ts +0 -7
- package/dist/react/divider.d.ts +0 -4
- package/dist/react/drawer-item.d.ts +0 -3
- package/dist/react/drawer.d.ts +0 -4
- package/dist/react/extended-fab.d.ts +0 -4
- package/dist/react/fab-menu-item.d.ts +0 -3
- package/dist/react/fab-menu.d.ts +0 -6
- package/dist/react/fab.d.ts +0 -4
- package/dist/react/icon-button.d.ts +0 -4
- package/dist/react/list-item.d.ts +0 -3
- package/dist/react/list.d.ts +0 -4
- package/dist/react/loading-indicator.d.ts +0 -4
- package/dist/react/menu-item.d.ts +0 -3
- package/dist/react/menu.d.ts +0 -4
- package/dist/react/navigation-bar-item.d.ts +0 -3
- package/dist/react/navigation-bar.d.ts +0 -4
- package/dist/react/navigation-rail-item.d.ts +0 -3
- package/dist/react/navigation-rail.d.ts +0 -4
- package/dist/react/progress.d.ts +0 -4
- package/dist/react/radio.d.ts +0 -3
- package/dist/react/radios.d.ts +0 -4
- package/dist/react/search-suggestion.d.ts +0 -3
- package/dist/react/search.d.ts +0 -4
- package/dist/react/select-option.d.ts +0 -3
- package/dist/react/select.d.ts +0 -6
- package/dist/react/side-sheet.d.ts +0 -4
- package/dist/react/slider.d.ts +0 -4
- package/dist/react/snackbar.d.ts +0 -7
- package/dist/react/split-button.d.ts +0 -7
- package/dist/react/switch.d.ts +0 -4
- package/dist/react/tab.d.ts +0 -3
- package/dist/react/tabs.d.ts +0 -7
- package/dist/react/text-field.d.ts +0 -4
- package/dist/react/timepicker.d.ts +0 -4
- package/dist/react/toolbar.d.ts +0 -5
- package/dist/react/tooltip.d.ts +0 -4
- package/dist/react/top-app-bar.d.ts +0 -4
- package/dist/solid/badge.d.ts +0 -4
- package/dist/solid/bottom-app-bar.d.ts +0 -5
- package/dist/solid/bottom-sheet.d.ts +0 -4
- package/dist/solid/button-group-item.d.ts +0 -3
- package/dist/solid/button-group.d.ts +0 -7
- package/dist/solid/button.d.ts +0 -5
- package/dist/solid/card.d.ts +0 -4
- package/dist/solid/carousel-item.d.ts +0 -3
- package/dist/solid/carousel.d.ts +0 -4
- package/dist/solid/checkbox.d.ts +0 -4
- package/dist/solid/chip.d.ts +0 -3
- package/dist/solid/chips.d.ts +0 -4
- package/dist/solid/datepicker.d.ts +0 -4
- package/dist/solid/dialog.d.ts +0 -7
- package/dist/solid/divider.d.ts +0 -4
- package/dist/solid/drawer-item.d.ts +0 -3
- package/dist/solid/drawer.d.ts +0 -4
- package/dist/solid/extended-fab.d.ts +0 -4
- package/dist/solid/fab-menu-item.d.ts +0 -3
- package/dist/solid/fab-menu.d.ts +0 -6
- package/dist/solid/fab.d.ts +0 -4
- package/dist/solid/icon-button.d.ts +0 -4
- package/dist/solid/list-item.d.ts +0 -3
- package/dist/solid/list.d.ts +0 -4
- package/dist/solid/loading-indicator.d.ts +0 -4
- package/dist/solid/menu-item.d.ts +0 -3
- package/dist/solid/menu.d.ts +0 -4
- package/dist/solid/navigation-bar-item.d.ts +0 -3
- package/dist/solid/navigation-bar.d.ts +0 -4
- package/dist/solid/navigation-rail-item.d.ts +0 -3
- package/dist/solid/navigation-rail.d.ts +0 -4
- package/dist/solid/progress.d.ts +0 -4
- package/dist/solid/radio.d.ts +0 -3
- package/dist/solid/radios.d.ts +0 -4
- package/dist/solid/search-suggestion.d.ts +0 -3
- package/dist/solid/search.d.ts +0 -4
- package/dist/solid/select-option.d.ts +0 -3
- package/dist/solid/select.d.ts +0 -6
- package/dist/solid/side-sheet.d.ts +0 -4
- package/dist/solid/slider.d.ts +0 -4
- package/dist/solid/snackbar.d.ts +0 -7
- package/dist/solid/split-button.d.ts +0 -7
- package/dist/solid/switch.d.ts +0 -4
- package/dist/solid/tab.d.ts +0 -3
- package/dist/solid/tabs.d.ts +0 -7
- package/dist/solid/text-field.d.ts +0 -4
- package/dist/solid/timepicker.d.ts +0 -4
- package/dist/solid/toolbar.d.ts +0 -5
- package/dist/solid/tooltip.d.ts +0 -4
- package/dist/solid/top-app-bar.d.ts +0 -4
- package/dist/vue/badge.d.ts +0 -4
- package/dist/vue/bottom-app-bar.d.ts +0 -5
- package/dist/vue/bottom-sheet.d.ts +0 -4
- package/dist/vue/button-group-item.d.ts +0 -3
- package/dist/vue/button-group.d.ts +0 -7
- package/dist/vue/button.d.ts +0 -5
- package/dist/vue/card.d.ts +0 -4
- package/dist/vue/carousel-item.d.ts +0 -3
- package/dist/vue/carousel.d.ts +0 -4
- package/dist/vue/checkbox.d.ts +0 -4
- package/dist/vue/chip.d.ts +0 -3
- package/dist/vue/chips.d.ts +0 -4
- package/dist/vue/create.d.ts +0 -73
- package/dist/vue/datepicker.d.ts +0 -4
- package/dist/vue/dialog.d.ts +0 -7
- package/dist/vue/divider.d.ts +0 -4
- package/dist/vue/drawer-item.d.ts +0 -3
- package/dist/vue/drawer.d.ts +0 -4
- package/dist/vue/extended-fab.d.ts +0 -4
- package/dist/vue/fab-menu-item.d.ts +0 -3
- package/dist/vue/fab-menu.d.ts +0 -6
- package/dist/vue/fab.d.ts +0 -4
- package/dist/vue/icon-button.d.ts +0 -4
- package/dist/vue/list-item.d.ts +0 -3
- package/dist/vue/list.d.ts +0 -4
- package/dist/vue/loading-indicator.d.ts +0 -4
- package/dist/vue/menu-item.d.ts +0 -3
- package/dist/vue/menu.d.ts +0 -4
- package/dist/vue/navigation-bar-item.d.ts +0 -3
- package/dist/vue/navigation-bar.d.ts +0 -4
- package/dist/vue/navigation-rail-item.d.ts +0 -3
- package/dist/vue/navigation-rail.d.ts +0 -4
- package/dist/vue/progress.d.ts +0 -4
- package/dist/vue/radio.d.ts +0 -3
- package/dist/vue/radios.d.ts +0 -4
- package/dist/vue/search-suggestion.d.ts +0 -3
- package/dist/vue/search.d.ts +0 -4
- package/dist/vue/select-option.d.ts +0 -3
- package/dist/vue/select.d.ts +0 -6
- package/dist/vue/side-sheet.d.ts +0 -4
- package/dist/vue/slider.d.ts +0 -4
- package/dist/vue/snackbar.d.ts +0 -7
- package/dist/vue/split-button.d.ts +0 -7
- package/dist/vue/switch.d.ts +0 -4
- package/dist/vue/tab.d.ts +0 -3
- package/dist/vue/tabs.d.ts +0 -7
- package/dist/vue/text-field.d.ts +0 -4
- package/dist/vue/timepicker.d.ts +0 -4
- package/dist/vue/toolbar.d.ts +0 -5
- package/dist/vue/tooltip.d.ts +0 -4
- package/dist/vue/top-app-bar.d.ts +0 -4
|
@@ -1,38 +0,0 @@
|
|
|
1
|
-
import { BaseComponent, ElementComponent } from "../component.js";
|
|
2
|
-
/** Configuration for throttled event handlers */
|
|
3
|
-
export interface ThrottleConfig {
|
|
4
|
-
/** Event handlers with throttle settings */
|
|
5
|
-
throttledEvents?: Record<string, {
|
|
6
|
-
handler: (event: Event) => void;
|
|
7
|
-
wait: number;
|
|
8
|
-
options?: {
|
|
9
|
-
leading?: boolean;
|
|
10
|
-
trailing?: boolean;
|
|
11
|
-
};
|
|
12
|
-
}>;
|
|
13
|
-
}
|
|
14
|
-
/** Component with throttled event capabilities */
|
|
15
|
-
export interface ThrottleComponent extends BaseComponent {
|
|
16
|
-
/**
|
|
17
|
-
* Adds a throttled event listener
|
|
18
|
-
* @param event
|
|
19
|
-
* @param handler
|
|
20
|
-
* @param wait
|
|
21
|
-
* @param options
|
|
22
|
-
*/
|
|
23
|
-
addThrottledEvent: (event: string, handler: (event: Event) => void, wait: number, options?: {
|
|
24
|
-
leading?: boolean;
|
|
25
|
-
trailing?: boolean;
|
|
26
|
-
}) => ThrottleComponent;
|
|
27
|
-
/**
|
|
28
|
-
* Removes a throttled event listener
|
|
29
|
-
* @param event
|
|
30
|
-
*/
|
|
31
|
-
removeThrottledEvent: (event: string) => ThrottleComponent;
|
|
32
|
-
}
|
|
33
|
-
/**
|
|
34
|
-
* Adds throttled event handling capabilities to a component
|
|
35
|
-
* @param config
|
|
36
|
-
*/
|
|
37
|
-
export declare const withThrottle: <T extends ThrottleConfig & object>(config?: T) => <C extends ElementComponent>(component: C) => C & ThrottleComponent;
|
|
38
|
-
export default withThrottle;
|
|
@@ -1,24 +0,0 @@
|
|
|
1
|
-
import { BaseComponent, ElementComponent } from "../component.js";
|
|
2
|
-
/** Configuration for track feature */
|
|
3
|
-
export interface TrackConfig {
|
|
4
|
-
/** CSS class prefix */
|
|
5
|
-
prefix: string;
|
|
6
|
-
/** Component name for class generation */
|
|
7
|
-
componentName: string;
|
|
8
|
-
/** Custom icon HTML or 'none' */
|
|
9
|
-
icon?: string;
|
|
10
|
-
/** Icon HTML shown in the unselected handle, which then grows to 24dp: M3's "icon on selected and unselected switch" configuration. */
|
|
11
|
-
unselectedIcon?: string;
|
|
12
|
-
}
|
|
13
|
-
/** Component with track and thumb elements */
|
|
14
|
-
export interface TrackComponent extends BaseComponent {
|
|
15
|
-
/** Track element */
|
|
16
|
-
track: HTMLElement;
|
|
17
|
-
/** Thumb element */
|
|
18
|
-
thumb: HTMLElement;
|
|
19
|
-
}
|
|
20
|
-
/**
|
|
21
|
-
* Adds track and thumb elements to a component
|
|
22
|
-
* @param config
|
|
23
|
-
*/
|
|
24
|
-
export declare const withTrack: <T extends TrackConfig>(config: T) => <C extends ElementComponent>(component: C) => C & TrackComponent;
|
|
@@ -1,12 +0,0 @@
|
|
|
1
|
-
import { ElementComponent } from "../component.js";
|
|
2
|
-
/** Configuration for variant feature */
|
|
3
|
-
export interface VariantConfig {
|
|
4
|
-
variant?: string;
|
|
5
|
-
prefix?: string;
|
|
6
|
-
componentName?: string;
|
|
7
|
-
}
|
|
8
|
-
/**
|
|
9
|
-
* Adds a variant class to a component
|
|
10
|
-
* @param config
|
|
11
|
-
*/
|
|
12
|
-
export declare const withVariant: <T extends VariantConfig & object>(config: T) => <C extends ElementComponent>(component: C) => C;
|
|
@@ -1,27 +0,0 @@
|
|
|
1
|
-
import { BaseComponent, ElementComponent } from "../component.js";
|
|
2
|
-
/** Event manager interface */
|
|
3
|
-
export interface EnhancedEventManager {
|
|
4
|
-
/** Add an event listener */
|
|
5
|
-
on: (event: string, handler: Function) => EnhancedEventManager;
|
|
6
|
-
/** Remove an event listener */
|
|
7
|
-
off: (event: string, handler: Function) => EnhancedEventManager;
|
|
8
|
-
/** Add multiple event listeners at once */
|
|
9
|
-
addListeners: (listeners: Record<string, Function>) => EnhancedEventManager;
|
|
10
|
-
/** Remove multiple event listeners at once */
|
|
11
|
-
removeListeners: (listeners: Record<string, Function>) => EnhancedEventManager;
|
|
12
|
-
/** One-time event handler */
|
|
13
|
-
once: (event: string, handler: Function) => EnhancedEventManager;
|
|
14
|
-
/** Clean up all event listeners */
|
|
15
|
-
destroy: () => void;
|
|
16
|
-
}
|
|
17
|
-
/** Component with enhanced event capabilities */
|
|
18
|
-
export interface EnhancedEventComponent extends BaseComponent {
|
|
19
|
-
events: EnhancedEventManager;
|
|
20
|
-
on(event: string, handler: Function): this;
|
|
21
|
-
off(event: string, handler: Function): this;
|
|
22
|
-
}
|
|
23
|
-
/**
|
|
24
|
-
* Adds enhanced event handling capabilities to a component
|
|
25
|
-
* @param target
|
|
26
|
-
*/
|
|
27
|
-
export declare const withEvents: (target?: HTMLElement) => <C extends ElementComponent>(component: C) => C & EnhancedEventComponent;
|
|
@@ -1,55 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Performs left-to-right function composition.
|
|
3
|
-
* @param fns
|
|
4
|
-
*/
|
|
5
|
-
export declare function pipe<A, B>(f1: (arg: A) => B): (x: A) => B;
|
|
6
|
-
export declare function pipe<A, B, C>(f1: (arg: A) => B, f2: (arg: B) => C): (x: A) => C;
|
|
7
|
-
export declare function pipe<A, B, C, D>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D): (x: A) => D;
|
|
8
|
-
export declare function pipe<A, B, C, D, E>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E): (x: A) => E;
|
|
9
|
-
export declare function pipe<A, B, C, D, E, F>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F): (x: A) => F;
|
|
10
|
-
export declare function pipe<A, B, C, D, E, F, G>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F, f6: (arg: F) => G): (x: A) => G;
|
|
11
|
-
export declare function pipe<A, B, C, D, E, F, G, H>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F, f6: (arg: F) => G, f7: (arg: G) => H): (x: A) => H;
|
|
12
|
-
export declare function pipe<A, B, C, D, E, F, G, H, I>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F, f6: (arg: F) => G, f7: (arg: G) => H, f8: (arg: H) => I): (x: A) => I;
|
|
13
|
-
export declare function pipe<A, B, C, D, E, F, G, H, I, J>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F, f6: (arg: F) => G, f7: (arg: G) => H, f8: (arg: H) => I, f9: (arg: I) => J): (x: A) => J;
|
|
14
|
-
export declare function pipe<A, B, C, D, E, F, G, H, I, J, K>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F, f6: (arg: F) => G, f7: (arg: G) => H, f8: (arg: H) => I, f9: (arg: I) => J, f10: (arg: J) => K): (x: A) => K;
|
|
15
|
-
export declare function pipe<A, B, C, D, E, F, G, H, I, J, K, L>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F, f6: (arg: F) => G, f7: (arg: G) => H, f8: (arg: H) => I, f9: (arg: I) => J, f10: (arg: J) => K, f11: (arg: K) => L): (x: A) => L;
|
|
16
|
-
export declare function pipe<A, B, C, D, E, F, G, H, I, J, K, L, M>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F, f6: (arg: F) => G, f7: (arg: G) => H, f8: (arg: H) => I, f9: (arg: I) => J, f10: (arg: J) => K, f11: (arg: K) => L, f12: (arg: L) => M): (x: A) => M;
|
|
17
|
-
export declare function pipe<A, B, C, D, E, F, G, H, I, J, K, L, M, N>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F, f6: (arg: F) => G, f7: (arg: G) => H, f8: (arg: H) => I, f9: (arg: I) => J, f10: (arg: J) => K, f11: (arg: K) => L, f12: (arg: L) => M, f13: (arg: M) => N): (x: A) => N;
|
|
18
|
-
export declare function pipe<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F, f6: (arg: F) => G, f7: (arg: G) => H, f8: (arg: H) => I, f9: (arg: I) => J, f10: (arg: J) => K, f11: (arg: K) => L, f12: (arg: L) => M, f13: (arg: M) => N, f14: (arg: N) => O): (x: A) => O;
|
|
19
|
-
export declare function pipe<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F, f6: (arg: F) => G, f7: (arg: G) => H, f8: (arg: H) => I, f9: (arg: I) => J, f10: (arg: J) => K, f11: (arg: K) => L, f12: (arg: L) => M, f13: (arg: M) => N, f14: (arg: N) => O, f15: (arg: O) => P): (x: A) => P;
|
|
20
|
-
export declare function pipe<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F, f6: (arg: F) => G, f7: (arg: G) => H, f8: (arg: H) => I, f9: (arg: I) => J, f10: (arg: J) => K, f11: (arg: K) => L, f12: (arg: L) => M, f13: (arg: M) => N, f14: (arg: N) => O, f15: (arg: O) => P, f16: (arg: P) => Q): (x: A) => Q;
|
|
21
|
-
export declare function pipe<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F, f6: (arg: F) => G, f7: (arg: G) => H, f8: (arg: H) => I, f9: (arg: I) => J, f10: (arg: J) => K, f11: (arg: K) => L, f12: (arg: L) => M, f13: (arg: M) => N, f14: (arg: N) => O, f15: (arg: O) => P, f16: (arg: P) => Q, f17: (arg: Q) => R): (x: A) => R;
|
|
22
|
-
export declare function pipe<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F, f6: (arg: F) => G, f7: (arg: G) => H, f8: (arg: H) => I, f9: (arg: I) => J, f10: (arg: J) => K, f11: (arg: K) => L, f12: (arg: L) => M, f13: (arg: M) => N, f14: (arg: N) => O, f15: (arg: O) => P, f16: (arg: P) => Q, f17: (arg: Q) => R, f18: (arg: R) => S): (x: A) => S;
|
|
23
|
-
export declare function pipe<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F, f6: (arg: F) => G, f7: (arg: G) => H, f8: (arg: H) => I, f9: (arg: I) => J, f10: (arg: J) => K, f11: (arg: K) => L, f12: (arg: L) => M, f13: (arg: M) => N, f14: (arg: N) => O, f15: (arg: O) => P, f16: (arg: P) => Q, f17: (arg: Q) => R, f18: (arg: R) => S, f19: (arg: S) => T): (x: A) => T;
|
|
24
|
-
export declare function pipe<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U>(f1: (arg: A) => B, f2: (arg: B) => C, f3: (arg: C) => D, f4: (arg: D) => E, f5: (arg: E) => F, f6: (arg: F) => G, f7: (arg: G) => H, f8: (arg: H) => I, f9: (arg: I) => J, f10: (arg: J) => K, f11: (arg: K) => L, f12: (arg: L) => M, f13: (arg: M) => N, f14: (arg: N) => O, f15: (arg: O) => P, f16: (arg: P) => Q, f17: (arg: Q) => R, f18: (arg: R) => S, f19: (arg: S) => T, f20: (arg: T) => U): (x: A) => U;
|
|
25
|
-
export declare function pipe<T>(...fns: Array<(arg: T) => T>): (x: T) => T;
|
|
26
|
-
/**
|
|
27
|
-
* Performs right-to-left function composition.
|
|
28
|
-
* @param fns
|
|
29
|
-
*/
|
|
30
|
-
export declare function compose<A, B>(f1: (arg: A) => B): (x: A) => B;
|
|
31
|
-
export declare function compose<A, B, C>(f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => C;
|
|
32
|
-
export declare function compose<A, B, C, D>(f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => D;
|
|
33
|
-
export declare function compose<A, B, C, D, E>(f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => E;
|
|
34
|
-
export declare function compose<A, B, C, D, E, F>(f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => F;
|
|
35
|
-
export declare function compose<A, B, C, D, E, F, G>(f6: (arg: F) => G, f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => G;
|
|
36
|
-
export declare function compose<A, B, C, D, E, F, G, H>(f7: (arg: G) => H, f6: (arg: F) => G, f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => H;
|
|
37
|
-
export declare function compose<A, B, C, D, E, F, G, H, I>(f8: (arg: H) => I, f7: (arg: G) => H, f6: (arg: F) => G, f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => I;
|
|
38
|
-
export declare function compose<A, B, C, D, E, F, G, H, I, J>(f9: (arg: I) => J, f8: (arg: H) => I, f7: (arg: G) => H, f6: (arg: F) => G, f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => J;
|
|
39
|
-
export declare function compose<A, B, C, D, E, F, G, H, I, J, K>(f10: (arg: J) => K, f9: (arg: I) => J, f8: (arg: H) => I, f7: (arg: G) => H, f6: (arg: F) => G, f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => K;
|
|
40
|
-
export declare function compose<A, B, C, D, E, F, G, H, I, J, K, L>(f11: (arg: K) => L, f10: (arg: J) => K, f9: (arg: I) => J, f8: (arg: H) => I, f7: (arg: G) => H, f6: (arg: F) => G, f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => L;
|
|
41
|
-
export declare function compose<A, B, C, D, E, F, G, H, I, J, K, L, M>(f12: (arg: L) => M, f11: (arg: K) => L, f10: (arg: J) => K, f9: (arg: I) => J, f8: (arg: H) => I, f7: (arg: G) => H, f6: (arg: F) => G, f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => M;
|
|
42
|
-
export declare function compose<A, B, C, D, E, F, G, H, I, J, K, L, M, N>(f13: (arg: M) => N, f12: (arg: L) => M, f11: (arg: K) => L, f10: (arg: J) => K, f9: (arg: I) => J, f8: (arg: H) => I, f7: (arg: G) => H, f6: (arg: F) => G, f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => N;
|
|
43
|
-
export declare function compose<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O>(f14: (arg: N) => O, f13: (arg: M) => N, f12: (arg: L) => M, f11: (arg: K) => L, f10: (arg: J) => K, f9: (arg: I) => J, f8: (arg: H) => I, f7: (arg: G) => H, f6: (arg: F) => G, f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => O;
|
|
44
|
-
export declare function compose<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P>(f15: (arg: O) => P, f14: (arg: N) => O, f13: (arg: M) => N, f12: (arg: L) => M, f11: (arg: K) => L, f10: (arg: J) => K, f9: (arg: I) => J, f8: (arg: H) => I, f7: (arg: G) => H, f6: (arg: F) => G, f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => P;
|
|
45
|
-
export declare function compose<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q>(f16: (arg: P) => Q, f15: (arg: O) => P, f14: (arg: N) => O, f13: (arg: M) => N, f12: (arg: L) => M, f11: (arg: K) => L, f10: (arg: J) => K, f9: (arg: I) => J, f8: (arg: H) => I, f7: (arg: G) => H, f6: (arg: F) => G, f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => Q;
|
|
46
|
-
export declare function compose<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R>(f17: (arg: Q) => R, f16: (arg: P) => Q, f15: (arg: O) => P, f14: (arg: N) => O, f13: (arg: M) => N, f12: (arg: L) => M, f11: (arg: K) => L, f10: (arg: J) => K, f9: (arg: I) => J, f8: (arg: H) => I, f7: (arg: G) => H, f6: (arg: F) => G, f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => R;
|
|
47
|
-
export declare function compose<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S>(f18: (arg: R) => S, f17: (arg: Q) => R, f16: (arg: P) => Q, f15: (arg: O) => P, f14: (arg: N) => O, f13: (arg: M) => N, f12: (arg: L) => M, f11: (arg: K) => L, f10: (arg: J) => K, f9: (arg: I) => J, f8: (arg: H) => I, f7: (arg: G) => H, f6: (arg: F) => G, f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => S;
|
|
48
|
-
export declare function compose<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T>(f19: (arg: S) => T, f18: (arg: R) => S, f17: (arg: Q) => R, f16: (arg: P) => Q, f15: (arg: O) => P, f14: (arg: N) => O, f13: (arg: M) => N, f12: (arg: L) => M, f11: (arg: K) => L, f10: (arg: J) => K, f9: (arg: I) => J, f8: (arg: H) => I, f7: (arg: G) => H, f6: (arg: F) => G, f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => T;
|
|
49
|
-
export declare function compose<A, B, C, D, E, F, G, H, I, J, K, L, M, N, O, P, Q, R, S, T, U>(f20: (arg: T) => U, f19: (arg: S) => T, f18: (arg: R) => S, f17: (arg: Q) => R, f16: (arg: P) => Q, f15: (arg: O) => P, f14: (arg: N) => O, f13: (arg: M) => N, f12: (arg: L) => M, f11: (arg: K) => L, f10: (arg: J) => K, f9: (arg: I) => J, f8: (arg: H) => I, f7: (arg: G) => H, f6: (arg: F) => G, f5: (arg: E) => F, f4: (arg: D) => E, f3: (arg: C) => D, f2: (arg: B) => C, f1: (arg: A) => B): (x: A) => U;
|
|
50
|
-
export declare function compose<T>(...fns: Array<(arg: T) => T>): (x: T) => T;
|
|
51
|
-
/**
|
|
52
|
-
* Creates a function that applies transformations to an object with shared context.
|
|
53
|
-
* @param transformers
|
|
54
|
-
*/
|
|
55
|
-
export declare const transform: <T, C = Record<string, unknown>>(...transformers: Array<(obj: T, context: C) => Partial<T>>) => (obj: T, context?: C) => T;
|
|
@@ -1,17 +0,0 @@
|
|
|
1
|
-
/** Utility functions for type checking component capabilities */
|
|
2
|
-
import { ElementComponent } from "../component.js";
|
|
3
|
-
/** Interface for components with lifecycle */
|
|
4
|
-
export interface ComponentWithLifecycle extends ElementComponent {
|
|
5
|
-
lifecycle: {
|
|
6
|
-
destroy: () => void;
|
|
7
|
-
[key: string]: unknown;
|
|
8
|
-
};
|
|
9
|
-
}
|
|
10
|
-
/** Interface for components with emit method */
|
|
11
|
-
export interface ComponentWithEmit extends ElementComponent {
|
|
12
|
-
emit: (event: string, data: unknown) => unknown;
|
|
13
|
-
}
|
|
14
|
-
/** Type guard to check if component has lifecycle */
|
|
15
|
-
export declare function hasLifecycle(component: object): component is ComponentWithLifecycle;
|
|
16
|
-
/** Type guard to check if component has emit method */
|
|
17
|
-
export declare function hasEmit(component: object): component is ComponentWithEmit;
|
package/dist/core/config.d.ts
DELETED
|
@@ -1,72 +0,0 @@
|
|
|
1
|
-
/** Library prefix used for all components */
|
|
2
|
-
export declare const PREFIX = "mtrl";
|
|
3
|
-
/**
|
|
4
|
-
* Gets a prefixed component class name
|
|
5
|
-
* @param type
|
|
6
|
-
*/
|
|
7
|
-
export declare const getComponentClass: (type: string) => string;
|
|
8
|
-
/**
|
|
9
|
-
* Gets a BEM modifier class name
|
|
10
|
-
* @param baseClass
|
|
11
|
-
* @param modifier
|
|
12
|
-
*/
|
|
13
|
-
export declare const getModifierClass: (baseClass: string, modifier: string) => string;
|
|
14
|
-
/**
|
|
15
|
-
* Gets a BEM element class name
|
|
16
|
-
* @param baseClass
|
|
17
|
-
* @param element
|
|
18
|
-
*/
|
|
19
|
-
export declare const getElementClass: (baseClass: string, element: string) => string;
|
|
20
|
-
/** Theme configuration interface */
|
|
21
|
-
export interface ThemeConfig {
|
|
22
|
-
/** Theme name */
|
|
23
|
-
name: string;
|
|
24
|
-
/** Theme CSS variables */
|
|
25
|
-
variables: Record<string, string>;
|
|
26
|
-
/** Theme variants */
|
|
27
|
-
variants: Record<string, unknown>;
|
|
28
|
-
}
|
|
29
|
-
/** Component configuration interface */
|
|
30
|
-
export interface ComponentConfig {
|
|
31
|
-
prefix: string;
|
|
32
|
-
type: string;
|
|
33
|
-
baseClass: string;
|
|
34
|
-
getClass: () => string;
|
|
35
|
-
getModifierClass: (modifier: string) => string;
|
|
36
|
-
getElementClass: (element: string) => string;
|
|
37
|
-
withTheme: (theme: string) => ThemedComponentConfig;
|
|
38
|
-
withVariants: (...variants: string[]) => VariantComponentConfig;
|
|
39
|
-
withStates: (...states: string[]) => StateComponentConfig;
|
|
40
|
-
}
|
|
41
|
-
/** Themed component configuration interface */
|
|
42
|
-
export interface ThemedComponentConfig extends ComponentConfig {
|
|
43
|
-
theme: string;
|
|
44
|
-
getThemeClass: (variant: string) => string;
|
|
45
|
-
getCssVariables: () => Record<string, string>;
|
|
46
|
-
}
|
|
47
|
-
/** Variant component configuration interface */
|
|
48
|
-
export interface VariantComponentConfig extends ComponentConfig {
|
|
49
|
-
variants: string[];
|
|
50
|
-
hasVariant: (variant: string) => boolean;
|
|
51
|
-
getVariantClass: (variant: string) => string | null;
|
|
52
|
-
}
|
|
53
|
-
/** State component configuration interface */
|
|
54
|
-
export interface StateComponentConfig extends ComponentConfig {
|
|
55
|
-
states: string[];
|
|
56
|
-
getStateClass: (state: string) => string | null;
|
|
57
|
-
}
|
|
58
|
-
/** CSS class generation utilities */
|
|
59
|
-
export declare const classNames: {
|
|
60
|
-
/**
|
|
61
|
-
* Creates a BEM-style class name
|
|
62
|
-
* @param block
|
|
63
|
-
* @param element
|
|
64
|
-
* @param modifier
|
|
65
|
-
*/
|
|
66
|
-
bem: (block: string, element?: string, modifier?: string) => string;
|
|
67
|
-
/**
|
|
68
|
-
* Joins class names, filtering out falsy values
|
|
69
|
-
* @param classes
|
|
70
|
-
*/
|
|
71
|
-
join: (...classes: (string | undefined | null | false)[]) => string;
|
|
72
|
-
};
|
|
@@ -1,34 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Set attributes on an element with performance optimizations
|
|
3
|
-
* @param element
|
|
4
|
-
* @param attributes
|
|
5
|
-
*/
|
|
6
|
-
export declare const setAttributes: <E extends HTMLElement | SVGElement>(element: E, attributes?: object) => E;
|
|
7
|
-
/**
|
|
8
|
-
* Remove attributes from an element
|
|
9
|
-
* @param element
|
|
10
|
-
* @param attributes
|
|
11
|
-
*/
|
|
12
|
-
export declare const removeAttributes: (element: HTMLElement, attributes?: string[]) => HTMLElement;
|
|
13
|
-
/**
|
|
14
|
-
* Batch attribute operations for better performance when setting many attributes
|
|
15
|
-
* @param element
|
|
16
|
-
*/
|
|
17
|
-
export declare const batchAttributes: (element: HTMLElement, operations: Array<{
|
|
18
|
-
action: "set" | "remove";
|
|
19
|
-
key: string;
|
|
20
|
-
value?: unknown;
|
|
21
|
-
}>) => HTMLElement;
|
|
22
|
-
/**
|
|
23
|
-
* Check if element has attribute
|
|
24
|
-
* @param element
|
|
25
|
-
* @param attribute
|
|
26
|
-
*/
|
|
27
|
-
export declare const hasAttribute: (element: HTMLElement, attribute: string) => boolean;
|
|
28
|
-
/**
|
|
29
|
-
* Get attribute value with default
|
|
30
|
-
* @param element
|
|
31
|
-
* @param attribute
|
|
32
|
-
* @param defaultValue
|
|
33
|
-
*/
|
|
34
|
-
export declare const getAttribute: (element: HTMLElement, attribute: string, defaultValue?: string) => string;
|
|
@@ -1,29 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Normalize classes to array of unique strings with optimization and caching
|
|
3
|
-
* @param classes
|
|
4
|
-
*/
|
|
5
|
-
export declare const normalizeClasses: (...classes: (string | string[])[]) => string[];
|
|
6
|
-
/**
|
|
7
|
-
* Add prefixed classes to element with optimizations
|
|
8
|
-
* @param element
|
|
9
|
-
* @param classes
|
|
10
|
-
*/
|
|
11
|
-
export declare const addClass: (element: HTMLElement, ...classes: (string | string[])[]) => HTMLElement;
|
|
12
|
-
/**
|
|
13
|
-
* Remove prefixed classes from element with optimizations
|
|
14
|
-
* @param element
|
|
15
|
-
* @param classes
|
|
16
|
-
*/
|
|
17
|
-
export declare const removeClass: (element: HTMLElement, ...classes: (string | string[])[]) => HTMLElement;
|
|
18
|
-
/**
|
|
19
|
-
* Toggle prefixed classes on element with optimizations
|
|
20
|
-
* @param element
|
|
21
|
-
* @param classes
|
|
22
|
-
*/
|
|
23
|
-
export declare const toggleClass: (element: HTMLElement, ...classes: (string | string[])[]) => HTMLElement;
|
|
24
|
-
/**
|
|
25
|
-
* Check if element has all specified prefixed classes with optimizations
|
|
26
|
-
* @param element
|
|
27
|
-
* @param classes
|
|
28
|
-
*/
|
|
29
|
-
export declare const hasClass: (element: HTMLElement, ...classes: (string | string[])[]) => boolean;
|
|
@@ -1,43 +0,0 @@
|
|
|
1
|
-
/** Event manager interface for handling DOM events */
|
|
2
|
-
export interface EventManager {
|
|
3
|
-
/**
|
|
4
|
-
* Add an event listener with options
|
|
5
|
-
* @param event
|
|
6
|
-
* @param handler
|
|
7
|
-
* @param options
|
|
8
|
-
*/
|
|
9
|
-
on: <T extends Event>(event: string, handler: (e: T) => void, options?: AddEventListenerOptions) => EventManager;
|
|
10
|
-
/**
|
|
11
|
-
* Remove an event listener
|
|
12
|
-
* @param event
|
|
13
|
-
* @param handler
|
|
14
|
-
*/
|
|
15
|
-
off: <T extends Event>(event: string, handler: (e: T) => void) => EventManager;
|
|
16
|
-
/** Temporarily disable all event listeners */
|
|
17
|
-
pause: () => EventManager;
|
|
18
|
-
/** Re-enable all event listeners */
|
|
19
|
-
resume: () => EventManager;
|
|
20
|
-
/** Remove all event listeners and clean up */
|
|
21
|
-
destroy: () => void;
|
|
22
|
-
/** Get all active handlers */
|
|
23
|
-
getHandlers: () => Map<string, HandlerInfo>;
|
|
24
|
-
/**
|
|
25
|
-
* Check if a specific handler exists
|
|
26
|
-
* @param event
|
|
27
|
-
* @param handler
|
|
28
|
-
*/
|
|
29
|
-
hasHandler: <T extends Event>(event: string, handler: (e: T) => void) => boolean;
|
|
30
|
-
}
|
|
31
|
-
/** Handler information */
|
|
32
|
-
interface HandlerInfo {
|
|
33
|
-
original: EventListener;
|
|
34
|
-
enhanced: EventListener;
|
|
35
|
-
event: string;
|
|
36
|
-
options: AddEventListenerOptions;
|
|
37
|
-
}
|
|
38
|
-
/**
|
|
39
|
-
* Creates an event manager to handle DOM events with enhanced functionality.
|
|
40
|
-
* @param element
|
|
41
|
-
*/
|
|
42
|
-
export declare const createEventManager: (element: HTMLElement) => EventManager;
|
|
43
|
-
export {};
|
package/dist/core/dom/focus.d.ts
DELETED
|
@@ -1,15 +0,0 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* The focused element as seen from a node's own root: the shadow root it lives in, or the document.
|
|
3
|
-
* @param node
|
|
4
|
-
*/
|
|
5
|
-
export declare const activeElementOf: (node: Node) => Element | null;
|
|
6
|
-
/** The element that really has focus, looked for through open shadow roots: where focus goes back to after an overlay closes, when the overlay may sit in another root than whatever opened it. */
|
|
7
|
-
export declare const deepActiveElement: () => Element | null;
|
|
8
|
-
/** The tab stops in a container, in the order Tab reaches them: through slots to what is assigned to them and into shadow roots, which is where the content of a web component sits. */
|
|
9
|
-
export declare const tabStops: (container: Element) => HTMLElement[];
|
|
10
|
-
/**
|
|
11
|
-
* Keeps Tab inside a modal: from its last tab stop to its first, and Shift+Tab from the first (or the modal itself) to the last.
|
|
12
|
-
* @param container
|
|
13
|
-
* @param event
|
|
14
|
-
*/
|
|
15
|
-
export declare const wrapTab: (container: HTMLElement, event: KeyboardEvent) => void;
|
package/dist/core/dom/html.d.ts
DELETED
|
@@ -1,16 +0,0 @@
|
|
|
1
|
-
/** A value the browser's Trusted Types API accepts for innerHTML. */
|
|
2
|
-
export interface TrustedHTMLLike {
|
|
3
|
-
toString(): string;
|
|
4
|
-
}
|
|
5
|
-
/** Markup a component accepts: a string, or a TrustedHTML from a policy. */
|
|
6
|
-
export type HTMLInput = string | TrustedHTMLLike;
|
|
7
|
-
export interface HTMLPolicy {
|
|
8
|
-
/** Called with every markup string before it is written. */
|
|
9
|
-
sanitize: (html: string) => HTMLInput;
|
|
10
|
-
}
|
|
11
|
-
/** Sets the policy every component's markup goes through, or clears it with null. */
|
|
12
|
-
export declare const configureHTML: (next: HTMLPolicy | null) => void;
|
|
13
|
-
/** The policy in force, if any. */
|
|
14
|
-
export declare const getHTMLPolicy: () => HTMLPolicy | null;
|
|
15
|
-
/** Writes markup into an element, through the policy when one is set. */
|
|
16
|
-
export declare const setHTML: (element: Element, html: HTMLInput | null | undefined) => void;
|
package/dist/core/dom/layer.d.ts
DELETED
|
@@ -1,57 +0,0 @@
|
|
|
1
|
-
/** How an element is promoted to the browser's top layer: */
|
|
2
|
-
export type TopLayerKind = "popover-auto" | "popover-manual" | "modal";
|
|
3
|
-
export interface TopLayerOptions {
|
|
4
|
-
kind: TopLayerKind;
|
|
5
|
-
}
|
|
6
|
-
type Layered = Omit<HTMLElement, "showPopover"> & Partial<Pick<HTMLDialogElement & HTMLElement, "showModal" | "close" | "open" | "showPopover">>;
|
|
7
|
-
/**
|
|
8
|
-
* Whether the browser can show an element of this kind in the top layer: `showPopover` for the popovers, `HTMLDialogElement.prototype.showModal` for a modal.
|
|
9
|
-
* @param kind
|
|
10
|
-
*/
|
|
11
|
-
export declare const supportsTopLayer: (kind: TopLayerKind) => boolean;
|
|
12
|
-
/**
|
|
13
|
-
* Shows an element in the top layer, above everything else on the page whatever its z-index and whatever clips or transforms its ancestors.
|
|
14
|
-
* @param element
|
|
15
|
-
* @param options
|
|
16
|
-
*/
|
|
17
|
-
export declare const showInTopLayer: (element: Layered, { kind }: TopLayerOptions) => boolean;
|
|
18
|
-
/**
|
|
19
|
-
* Takes an element out of the top layer.
|
|
20
|
-
* @param element
|
|
21
|
-
*/
|
|
22
|
-
export declare const hideFromTopLayer: (element: Layered) => void;
|
|
23
|
-
/**
|
|
24
|
-
* Reports the closes the browser makes on its own: a light dismiss or Escape for `popover="auto"` (a `toggle` event to `closed`), Escape or a form for a modal dialog (its `close` event, which follows an uncanceled `cancel`).
|
|
25
|
-
* @param element
|
|
26
|
-
* @param callback
|
|
27
|
-
*/
|
|
28
|
-
export declare const onTopLayerClose: (element: HTMLElement, callback: () => void) => (() => void);
|
|
29
|
-
/** A modal outside the top layer: makes everything but `keep` inert, as showModal() does for a top-layer dialog. */
|
|
30
|
-
export declare const inertOutside: (keep: Element) => (() => void);
|
|
31
|
-
/** What eventsFrom returns: see there. */
|
|
32
|
-
export interface EventsFrom {
|
|
33
|
-
/** Whether the event's dispatch began after the call */
|
|
34
|
-
after: (event: Event) => boolean;
|
|
35
|
-
/** Releases the marker. */
|
|
36
|
-
stop: () => void;
|
|
37
|
-
}
|
|
38
|
-
/**
|
|
39
|
-
* Tells the events that came after this call from the one that was already on its way: "the event that opened an overlay never dismisses it".
|
|
40
|
-
* @param element
|
|
41
|
-
*/
|
|
42
|
-
export declare const eventsFrom: (element: HTMLElement) => EventsFrom;
|
|
43
|
-
/** A modal's place in the Escape stack: see onModalEscape. */
|
|
44
|
-
export interface ModalEscape {
|
|
45
|
-
/** True for the rest of the task the modal opened in, for the one event the marker cannot number: the `cancel` the browser sends the topmost modal `<dialog>` for the key press that opened it, when the page stopped that key press before it reached the window. */
|
|
46
|
-
opening: boolean;
|
|
47
|
-
/** Takes the modal off the stack. */
|
|
48
|
-
stop: () => void;
|
|
49
|
-
}
|
|
50
|
-
/**
|
|
51
|
-
* Escape for a modal, handled as a key press.
|
|
52
|
-
* @param element
|
|
53
|
-
* @param escape
|
|
54
|
-
* @param d
|
|
55
|
-
*/
|
|
56
|
-
export declare const onModalEscape: (element: HTMLElement, escape: () => void, d?: (() => unknown) | false) => ModalEscape;
|
|
57
|
-
export {};
|
|
@@ -1,18 +0,0 @@
|
|
|
1
|
-
/** Whether the arrow keys, Home and End belong to an element: a text input, a textarea or editable content, where they move the caret. */
|
|
2
|
-
export declare const isTextEditable: (element: EventTarget | null | undefined) => boolean;
|
|
3
|
-
export interface RovingOptions {
|
|
4
|
-
/** The composite: it receives the key and focus listeners. */
|
|
5
|
-
container: HTMLElement;
|
|
6
|
-
/** The focus targets in order. */
|
|
7
|
-
targets: () => HTMLElement[];
|
|
8
|
-
/** Whether Up and Down move focus instead of Left and Right. */
|
|
9
|
-
vertical?: () => boolean;
|
|
10
|
-
}
|
|
11
|
-
export interface Roving {
|
|
12
|
-
/** Puts the one tab stop back on the current target, or the first enabled one. */
|
|
13
|
-
sync(): void;
|
|
14
|
-
/** Removes the listeners. */
|
|
15
|
-
destroy(): void;
|
|
16
|
-
}
|
|
17
|
-
/** A roving tab index over a composite's focus targets (the WAI-ARIA toolbar pattern): one tab stop, kept on the target focused last; the arrow keys along the layout, Left and Right following the reading direction; Home and End to the ends. */
|
|
18
|
-
export declare const createRoving: ({ container, targets, vertical }: RovingOptions) => Roving;
|
|
@@ -1,45 +0,0 @@
|
|
|
1
|
-
/** A cubic Bézier: anchor 0, control 0, control 1, anchor 1 */
|
|
2
|
-
export type Cubic = readonly [
|
|
3
|
-
number,
|
|
4
|
-
number,
|
|
5
|
-
number,
|
|
6
|
-
number,
|
|
7
|
-
number,
|
|
8
|
-
number,
|
|
9
|
-
number,
|
|
10
|
-
number
|
|
11
|
-
];
|
|
12
|
-
/** A 2D point */
|
|
13
|
-
export type Point = readonly [
|
|
14
|
-
number,
|
|
15
|
-
number
|
|
16
|
-
];
|
|
17
|
-
/** Below this distance two points are the same point */
|
|
18
|
-
export declare const DISTANCE_EPSILON = 0.0001;
|
|
19
|
-
export declare const lerp: (start: number, stop: number, fraction: number) => number;
|
|
20
|
-
export declare const distance: (x: number, y: number) => number;
|
|
21
|
-
/** Unit vector in the direction of (x, y) */
|
|
22
|
-
export declare const direction: (x: number, y: number) => Point;
|
|
23
|
-
export declare const rotate90: ([x, y]: Point) => Point;
|
|
24
|
-
export declare const dot: (a: Point, b: Point) => number;
|
|
25
|
-
/** A straight segment expressed as a cubic */
|
|
26
|
-
export declare const straightLine: (x0: number, y0: number, x1: number, y1: number) => Cubic;
|
|
27
|
-
/** A circular arc from (x0, y0) to (x1, y1) around (centerX, centerY), approximated by one cubic; the arc must be under 180 degrees. */
|
|
28
|
-
export declare const circularArc: (centerX: number, centerY: number, x0: number, y0: number, x1: number, y1: number) => Cubic;
|
|
29
|
-
export declare const pointOnCurve: (c: Cubic, t: number) => Point;
|
|
30
|
-
/** Splits a cubic at `t` into two that together trace it (de Casteljau) */
|
|
31
|
-
export declare const splitCubic: (c: Cubic, t: number) => [
|
|
32
|
-
Cubic,
|
|
33
|
-
Cubic
|
|
34
|
-
];
|
|
35
|
-
export declare const reverseCubic: (c: Cubic) => Cubic;
|
|
36
|
-
export declare const zeroLength: (c: Cubic) => boolean;
|
|
37
|
-
export type PointTransformer = (x: number, y: number) => Point;
|
|
38
|
-
export declare const transformCubic: (c: Cubic, f: PointTransformer) => Cubic;
|
|
39
|
-
/** The bounding box of a cubic as [left, top, right, bottom]. */
|
|
40
|
-
export declare const cubicBounds: (c: Cubic) => [
|
|
41
|
-
number,
|
|
42
|
-
number,
|
|
43
|
-
number,
|
|
44
|
-
number
|
|
45
|
-
];
|