@shortfuse/materialdesignweb 0.8.0 → 0.9.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/README.md +50 -198
- package/bin/mdw-css.js +1 -1
- package/components/Badge.js +15 -5
- package/components/Body.js +7 -0
- package/components/BottomAppBar.js +7 -10
- package/components/BottomSheet.js +472 -0
- package/components/Box.js +11 -49
- package/components/Button.js +81 -82
- package/components/Card.js +74 -62
- package/components/Checkbox.js +15 -25
- package/components/CheckboxIcon.js +19 -31
- package/components/Chip.js +18 -13
- package/components/Dialog.js +70 -100
- package/components/DialogActions.js +4 -0
- package/components/Display.js +64 -0
- package/components/Divider.js +5 -0
- package/components/Fab.js +94 -17
- package/components/FabContainer.js +57 -0
- package/components/FilterChip.js +43 -32
- package/components/Grid.js +187 -0
- package/components/Headline.js +9 -28
- package/components/Icon.js +80 -71
- package/components/IconButton.js +77 -120
- package/components/Input.js +745 -86
- package/components/InputChip.js +193 -0
- package/components/Label.js +7 -0
- package/components/List.js +11 -5
- package/components/ListItem.js +92 -23
- package/components/ListOption.js +143 -65
- package/components/Listbox.js +57 -17
- package/components/Menu.js +39 -27
- package/components/MenuItem.js +49 -36
- package/components/NavBar.js +66 -21
- package/components/NavBarItem.js +5 -0
- package/components/NavDrawer.js +33 -16
- package/components/NavDrawerItem.js +7 -4
- package/components/NavItem.js +61 -34
- package/components/NavRail.js +32 -21
- package/components/NavRailItem.js +10 -2
- package/components/Page.js +119 -0
- package/components/Pane.js +24 -0
- package/components/Popup.js +23 -8
- package/components/Progress.js +25 -5
- package/components/Radio.js +8 -7
- package/components/RadioIcon.js +24 -15
- package/components/Ripple.js +25 -7
- package/components/Root.js +225 -0
- package/components/Scrim.js +95 -0
- package/components/Search.js +30 -25
- package/components/SegmentedButton.js +53 -40
- package/components/SegmentedButtonGroup.js +15 -12
- package/components/Select.js +19 -10
- package/components/Shape.js +10 -66
- package/components/SideSheet.js +337 -0
- package/components/Slider.js +93 -36
- package/components/Snackbar.js +52 -20
- package/components/SnackbarContainer.js +51 -0
- package/components/Surface.js +20 -10
- package/components/Switch.js +21 -18
- package/components/SwitchIcon.js +62 -33
- package/components/Tab.js +78 -38
- package/components/TabContent.js +33 -12
- package/components/TabList.js +95 -34
- package/components/TabPanel.js +10 -1
- package/components/Table.js +151 -0
- package/components/TextArea.js +48 -16
- package/components/Title.js +8 -9
- package/components/Tooltip.js +51 -22
- package/components/TopAppBar.js +71 -78
- package/constants/shapes.js +36 -0
- package/constants/typography.js +127 -0
- package/core/Composition.js +391 -201
- package/core/CompositionAdapter.js +35 -18
- package/core/CustomElement.js +634 -254
- package/core/css.js +117 -12
- package/core/customTypes.js +161 -49
- package/core/dom.js +18 -11
- package/core/jsonMergePatch.js +27 -11
- package/core/observe.js +308 -256
- package/core/optimizations.js +9 -9
- package/core/template.js +14 -57
- package/dist/CustomElement.min.js +2 -0
- package/dist/CustomElement.min.js.map +7 -0
- package/dist/core/CustomElement.min.js +2 -0
- package/dist/core/CustomElement.min.js.map +7 -0
- package/dist/index.min.js +85 -115
- package/dist/index.min.js.map +4 -4
- package/dist/meta.json +1 -1
- package/dom/HTMLOptionsCollectionProxy.js +108 -0
- package/{theming/themableMixinLoader.js → loaders/palette.js} +4 -3
- package/loaders/theme.js +12 -0
- package/mixins/AriaReflectorMixin.js +64 -15
- package/mixins/AriaToolbarMixin.js +6 -0
- package/mixins/ControlMixin.js +79 -33
- package/mixins/DelegatesFocusMixin.js +62 -0
- package/mixins/DensityMixin.js +7 -3
- package/mixins/ElevationMixin.js +61 -0
- package/mixins/FlexableMixin.js +87 -39
- package/mixins/FormAssociatedMixin.js +76 -10
- package/mixins/HyperlinkMixin.js +76 -0
- package/mixins/InputMixin.js +227 -32
- package/mixins/KeyboardNavMixin.js +11 -7
- package/mixins/NavigationListenerMixin.js +33 -0
- package/mixins/PopupMixin.js +216 -219
- package/mixins/RTLObserverMixin.js +2 -0
- package/mixins/ResizeObserverMixin.js +18 -4
- package/mixins/RippleMixin.js +11 -7
- package/mixins/ScrollListenerMixin.js +14 -2
- package/mixins/SemiStickyMixin.js +51 -98
- package/mixins/ShapeMaskedMixin.js +125 -0
- package/mixins/ShapeMixin.js +30 -203
- package/mixins/StateMixin.js +74 -34
- package/mixins/TextFieldMixin.js +128 -145
- package/mixins/ThemableMixin.js +57 -56
- package/mixins/TooltipTriggerMixin.js +305 -359
- package/mixins/TouchTargetMixin.js +5 -2
- package/mixins/TypographyMixin.js +128 -0
- package/package.json +125 -81
- package/services/rtl.js +10 -0
- package/services/svgAlias.js +17 -0
- package/{theming/index.js → services/theme.js} +25 -176
- package/types/bin/mdw-css.d.ts +3 -0
- package/types/bin/mdw-css.d.ts.map +1 -0
- package/types/components/Badge.d.ts +39 -0
- package/types/components/Badge.d.ts.map +1 -0
- package/types/components/Body.d.ts +29 -0
- package/types/components/Body.d.ts.map +1 -0
- package/types/components/BottomAppBar.d.ts +72 -0
- package/types/components/BottomAppBar.d.ts.map +1 -0
- package/types/components/BottomSheet.d.ts +135 -0
- package/types/components/BottomSheet.d.ts.map +1 -0
- package/types/components/Box.d.ts +16 -0
- package/types/components/Box.d.ts.map +1 -0
- package/types/components/Button.d.ts +245 -0
- package/types/components/Button.d.ts.map +1 -0
- package/types/components/Card.d.ts +147 -0
- package/types/components/Card.d.ts.map +1 -0
- package/types/components/Checkbox.d.ts +207 -0
- package/types/components/Checkbox.d.ts.map +1 -0
- package/types/components/CheckboxIcon.d.ts +44 -0
- package/types/components/CheckboxIcon.d.ts.map +1 -0
- package/types/components/Chip.d.ts +248 -0
- package/types/components/Chip.d.ts.map +1 -0
- package/types/components/Dialog.d.ts +103 -0
- package/types/components/Dialog.d.ts.map +1 -0
- package/types/components/DialogActions.d.ts +4 -0
- package/types/components/DialogActions.d.ts.map +1 -0
- package/types/components/Display.d.ts +46 -0
- package/types/components/Display.d.ts.map +1 -0
- package/types/components/Divider.d.ts +10 -0
- package/types/components/Divider.d.ts.map +1 -0
- package/types/components/Fab.d.ts +273 -0
- package/types/components/Fab.d.ts.map +1 -0
- package/types/components/FabContainer.d.ts +10 -0
- package/types/components/FabContainer.d.ts.map +1 -0
- package/types/components/FilterChip.d.ts +256 -0
- package/types/components/FilterChip.d.ts.map +1 -0
- package/types/components/Grid.d.ts +38 -0
- package/types/components/Grid.d.ts.map +1 -0
- package/types/components/Headline.d.ts +46 -0
- package/types/components/Headline.d.ts.map +1 -0
- package/types/components/Icon.d.ts +55 -0
- package/types/components/Icon.d.ts.map +1 -0
- package/types/components/IconButton.d.ts +284 -0
- package/types/components/IconButton.d.ts.map +1 -0
- package/types/components/Input.d.ts +2528 -0
- package/types/components/Input.d.ts.map +1 -0
- package/types/components/InputChip.d.ts +85 -0
- package/types/components/InputChip.d.ts.map +1 -0
- package/types/components/Label.d.ts +29 -0
- package/types/components/Label.d.ts.map +1 -0
- package/types/components/List.d.ts +35 -0
- package/types/components/List.d.ts.map +1 -0
- package/types/components/ListItem.d.ts +124 -0
- package/types/components/ListItem.d.ts.map +1 -0
- package/types/components/ListOption.d.ts +158 -0
- package/types/components/ListOption.d.ts.map +1 -0
- package/types/components/Listbox.d.ts +763 -0
- package/types/components/Listbox.d.ts.map +1 -0
- package/types/components/Menu.d.ts +130 -0
- package/types/components/Menu.d.ts.map +1 -0
- package/types/components/MenuItem.d.ts +232 -0
- package/types/components/MenuItem.d.ts.map +1 -0
- package/types/components/NavBar.d.ts +20 -0
- package/types/components/NavBar.d.ts.map +1 -0
- package/types/components/NavBarItem.d.ts +97 -0
- package/types/components/NavBarItem.d.ts.map +1 -0
- package/types/components/NavDrawer.d.ts +107 -0
- package/types/components/NavDrawer.d.ts.map +1 -0
- package/types/components/NavDrawerItem.d.ts +97 -0
- package/types/components/NavDrawerItem.d.ts.map +1 -0
- package/types/components/NavItem.d.ts +99 -0
- package/types/components/NavItem.d.ts.map +1 -0
- package/types/components/NavRail.d.ts +108 -0
- package/types/components/NavRail.d.ts.map +1 -0
- package/types/components/NavRailItem.d.ts +97 -0
- package/types/components/NavRailItem.d.ts.map +1 -0
- package/types/components/Page.d.ts +25 -0
- package/types/components/Page.d.ts.map +1 -0
- package/types/components/Pane.d.ts +44 -0
- package/types/components/Pane.d.ts.map +1 -0
- package/types/components/Popup.d.ts +78 -0
- package/types/components/Popup.d.ts.map +1 -0
- package/types/components/Progress.d.ts +21 -0
- package/types/components/Progress.d.ts.map +1 -0
- package/types/components/Radio.d.ts +201 -0
- package/types/components/Radio.d.ts.map +1 -0
- package/types/components/RadioIcon.d.ts +46 -0
- package/types/components/RadioIcon.d.ts.map +1 -0
- package/types/components/Ripple.d.ts +35 -0
- package/types/components/Ripple.d.ts.map +1 -0
- package/types/components/Root.d.ts +68 -0
- package/types/components/Root.d.ts.map +1 -0
- package/types/components/Scrim.d.ts +6 -0
- package/types/components/Scrim.d.ts.map +1 -0
- package/types/components/Search.d.ts +516 -0
- package/types/components/Search.d.ts.map +1 -0
- package/types/components/SegmentedButton.d.ts +252 -0
- package/types/components/SegmentedButton.d.ts.map +1 -0
- package/types/components/SegmentedButtonGroup.d.ts +43 -0
- package/types/components/SegmentedButtonGroup.d.ts.map +1 -0
- package/types/components/Select.d.ts +158 -0
- package/types/components/Select.d.ts.map +1 -0
- package/types/components/Shape.d.ts +10 -0
- package/types/components/Shape.d.ts.map +1 -0
- package/types/components/SideSheet.d.ts +111 -0
- package/types/components/SideSheet.d.ts.map +1 -0
- package/types/components/Slider.d.ts +203 -0
- package/types/components/Slider.d.ts.map +1 -0
- package/types/components/Snackbar.d.ts +73 -0
- package/types/components/Snackbar.d.ts.map +1 -0
- package/types/components/SnackbarContainer.d.ts +6 -0
- package/types/components/SnackbarContainer.d.ts.map +1 -0
- package/types/components/Surface.d.ts +45 -0
- package/types/components/Surface.d.ts.map +1 -0
- package/types/components/Switch.d.ts +187 -0
- package/types/components/Switch.d.ts.map +1 -0
- package/types/components/SwitchIcon.d.ts +61 -0
- package/types/components/SwitchIcon.d.ts.map +1 -0
- package/types/components/Tab.d.ts +139 -0
- package/types/components/Tab.d.ts.map +1 -0
- package/types/components/TabContent.d.ts +124 -0
- package/types/components/TabContent.d.ts.map +1 -0
- package/types/components/TabList.d.ts +1111 -0
- package/types/components/TabList.d.ts.map +1 -0
- package/types/components/TabPanel.d.ts +28 -0
- package/types/components/TabPanel.d.ts.map +1 -0
- package/types/components/Table.d.ts +25 -0
- package/types/components/Table.d.ts.map +1 -0
- package/types/components/TextArea.d.ts +201 -0
- package/types/components/TextArea.d.ts.map +1 -0
- package/types/components/Title.d.ts +46 -0
- package/types/components/Title.d.ts.map +1 -0
- package/types/components/Tooltip.d.ts +49 -0
- package/types/components/Tooltip.d.ts.map +1 -0
- package/types/components/TopAppBar.d.ts +129 -0
- package/types/components/TopAppBar.d.ts.map +1 -0
- package/types/constants/colorKeywords.d.ts +2 -0
- package/types/constants/colorKeywords.d.ts.map +1 -0
- package/types/constants/shapes.d.ts +38 -0
- package/types/constants/shapes.d.ts.map +1 -0
- package/types/constants/typography.d.ts +212 -0
- package/types/constants/typography.d.ts.map +1 -0
- package/types/core/Composition.d.ts +260 -0
- package/types/core/Composition.d.ts.map +1 -0
- package/types/core/CompositionAdapter.d.ts +114 -0
- package/types/core/CompositionAdapter.d.ts.map +1 -0
- package/types/core/CustomElement.d.ts +304 -0
- package/types/core/CustomElement.d.ts.map +1 -0
- package/types/core/css.d.ts +44 -0
- package/types/core/css.d.ts.map +1 -0
- package/types/core/customTypes.d.ts +22 -0
- package/types/core/customTypes.d.ts.map +1 -0
- package/types/core/dom.d.ts +32 -0
- package/types/core/dom.d.ts.map +1 -0
- package/types/core/jsonMergePatch.d.ts +31 -0
- package/types/core/jsonMergePatch.d.ts.map +1 -0
- package/types/core/observe.d.ts +114 -0
- package/types/core/observe.d.ts.map +1 -0
- package/types/core/optimizations.d.ts +7 -0
- package/types/core/optimizations.d.ts.map +1 -0
- package/types/core/template.d.ts +47 -0
- package/types/core/template.d.ts.map +1 -0
- package/types/core/uid.d.ts +6 -0
- package/types/core/uid.d.ts.map +1 -0
- package/types/dom/HTMLOptionsCollectionProxy.d.ts +18 -0
- package/types/dom/HTMLOptionsCollectionProxy.d.ts.map +1 -0
- package/types/index.d.ts +88 -0
- package/types/index.d.ts.map +1 -0
- package/types/loaders/palette.d.ts +2 -0
- package/types/loaders/palette.d.ts.map +1 -0
- package/types/loaders/theme.d.ts +2 -0
- package/types/loaders/theme.d.ts.map +1 -0
- package/types/mixins/AriaReflectorMixin.d.ts +31 -0
- package/types/mixins/AriaReflectorMixin.d.ts.map +1 -0
- package/types/mixins/AriaToolbarMixin.d.ts +34 -0
- package/types/mixins/AriaToolbarMixin.d.ts.map +1 -0
- package/types/mixins/ControlMixin.d.ts +124 -0
- package/types/mixins/ControlMixin.d.ts.map +1 -0
- package/types/mixins/DelegatesFocusMixin.d.ts +13 -0
- package/types/mixins/DelegatesFocusMixin.d.ts.map +1 -0
- package/types/mixins/DensityMixin.d.ts +8 -0
- package/types/mixins/DensityMixin.d.ts.map +1 -0
- package/types/mixins/ElevationMixin.d.ts +32 -0
- package/types/mixins/ElevationMixin.d.ts.map +1 -0
- package/types/mixins/FlexableMixin.d.ts +14 -0
- package/types/mixins/FlexableMixin.d.ts.map +1 -0
- package/types/mixins/FormAssociatedMixin.d.ts +123 -0
- package/types/mixins/FormAssociatedMixin.d.ts.map +1 -0
- package/types/mixins/HyperlinkMixin.d.ts +25 -0
- package/types/mixins/HyperlinkMixin.d.ts.map +1 -0
- package/types/mixins/InputMixin.d.ts +173 -0
- package/types/mixins/InputMixin.d.ts.map +1 -0
- package/types/mixins/KeyboardNavMixin.d.ts +46 -0
- package/types/mixins/KeyboardNavMixin.d.ts.map +1 -0
- package/types/mixins/NavigationListenerMixin.d.ts +8 -0
- package/types/mixins/NavigationListenerMixin.d.ts.map +1 -0
- package/types/mixins/PopupMixin.d.ts +98 -0
- package/types/mixins/PopupMixin.d.ts.map +1 -0
- package/types/mixins/RTLObserverMixin.d.ts +8 -0
- package/types/mixins/RTLObserverMixin.d.ts.map +1 -0
- package/types/mixins/ResizeObserverMixin.d.ts +13 -0
- package/types/mixins/ResizeObserverMixin.d.ts.map +1 -0
- package/types/mixins/RippleMixin.d.ts +94 -0
- package/types/mixins/RippleMixin.d.ts.map +1 -0
- package/types/mixins/ScrollListenerMixin.d.ts +46 -0
- package/types/mixins/ScrollListenerMixin.d.ts.map +1 -0
- package/types/mixins/SemiStickyMixin.d.ts +50 -0
- package/types/mixins/SemiStickyMixin.d.ts.map +1 -0
- package/types/mixins/ShapeMaskedMixin.d.ts +12 -0
- package/types/mixins/ShapeMaskedMixin.d.ts.map +1 -0
- package/types/mixins/ShapeMixin.d.ts +39 -0
- package/types/mixins/ShapeMixin.d.ts.map +1 -0
- package/types/mixins/StateMixin.d.ts +29 -0
- package/types/mixins/StateMixin.d.ts.map +1 -0
- package/types/mixins/TextFieldMixin.d.ts +153 -0
- package/types/mixins/TextFieldMixin.d.ts.map +1 -0
- package/types/mixins/ThemableMixin.d.ts +10 -0
- package/types/mixins/ThemableMixin.d.ts.map +1 -0
- package/types/mixins/TooltipTriggerMixin.d.ts +114 -0
- package/types/mixins/TooltipTriggerMixin.d.ts.map +1 -0
- package/types/mixins/TouchTargetMixin.d.ts +6 -0
- package/types/mixins/TouchTargetMixin.d.ts.map +1 -0
- package/types/mixins/TypographyMixin.d.ts +20 -0
- package/types/mixins/TypographyMixin.d.ts.map +1 -0
- package/types/services/rtl.d.ts +3 -0
- package/types/services/rtl.d.ts.map +1 -0
- package/types/services/svgAlias.d.ts +13 -0
- package/types/services/svgAlias.d.ts.map +1 -0
- package/types/services/theme.d.ts +45 -0
- package/types/services/theme.d.ts.map +1 -0
- package/types/utils/cli.d.ts +3 -0
- package/types/utils/cli.d.ts.map +1 -0
- package/types/utils/function.d.ts +3 -0
- package/types/utils/function.d.ts.map +1 -0
- package/types/utils/jsx-runtime.d.ts +20 -0
- package/types/utils/jsx-runtime.d.ts.map +1 -0
- package/types/utils/material-color/blend.d.ts +34 -0
- package/types/utils/material-color/blend.d.ts.map +1 -0
- package/types/utils/material-color/hct/Cam16.d.ts +142 -0
- package/types/utils/material-color/hct/Cam16.d.ts.map +1 -0
- package/types/utils/material-color/hct/Hct.d.ts +93 -0
- package/types/utils/material-color/hct/Hct.d.ts.map +1 -0
- package/types/utils/material-color/hct/ViewingConditions.d.ts +69 -0
- package/types/utils/material-color/hct/ViewingConditions.d.ts.map +1 -0
- package/types/utils/material-color/hct/hctSolver.d.ts +30 -0
- package/types/utils/material-color/hct/hctSolver.d.ts.map +1 -0
- package/types/utils/material-color/helper.d.ts +8 -0
- package/types/utils/material-color/helper.d.ts.map +1 -0
- package/types/utils/material-color/palettes/CorePalette.d.ts +75 -0
- package/types/utils/material-color/palettes/CorePalette.d.ts.map +1 -0
- package/types/utils/material-color/palettes/TonalPalette.d.ts +38 -0
- package/types/utils/material-color/palettes/TonalPalette.d.ts.map +1 -0
- package/types/utils/material-color/scheme/Scheme.d.ts +264 -0
- package/types/utils/material-color/scheme/Scheme.d.ts.map +1 -0
- package/types/utils/material-color/utils/color.d.ts +172 -0
- package/types/utils/material-color/utils/color.d.ts.map +1 -0
- package/types/utils/material-color/utils/math.d.ts +94 -0
- package/types/utils/material-color/utils/math.d.ts.map +1 -0
- package/types/utils/pixelmatch.d.ts +22 -0
- package/types/utils/pixelmatch.d.ts.map +1 -0
- package/types/utils/popup.d.ts +106 -0
- package/types/utils/popup.d.ts.map +1 -0
- package/types/utils/searchParams.d.ts +3 -0
- package/types/utils/searchParams.d.ts.map +1 -0
- package/types/utils/svg.d.ts +7 -0
- package/types/utils/svg.d.ts.map +1 -0
- package/utils/jsx-runtime.js +9 -4
- package/utils/material-color/scheme/Scheme.js +1 -1
- package/utils/pixelmatch.js +363 -0
- package/utils/popup.js +86 -10
- package/utils/searchParams.js +22 -0
- package/components/Button.md +0 -61
- package/components/ExtendedFab.js +0 -32
- package/components/Layout.js +0 -504
- package/components/Nav.js +0 -38
- package/core/DomAdapter.js +0 -586
- package/core/ICustomElement.d.ts +0 -291
- package/core/ICustomElement.js +0 -1
- package/core/test.js +0 -126
- package/core/typings.d.ts +0 -142
- package/core/typings.js +0 -1
- package/mixins/SurfaceMixin.js +0 -127
- package/theming/loader.js +0 -22
- /package/{utils/color_keywords.js → constants/colorKeywords.js} +0 -0
|
@@ -0,0 +1,29 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Manages interactive state flags (disabled, focused, hovered, pressed, touch)
|
|
3
|
+
* and derived state expressions used by components.
|
|
4
|
+
* @param {typeof import('../core/CustomElement.js').default} Base
|
|
5
|
+
*/
|
|
6
|
+
export default function StateMixin(Base: typeof import("../core/CustomElement.js").default): typeof import("../core/CustomElement.js").default & import("../core/CustomElement.js").Class<{
|
|
7
|
+
disabled: boolean;
|
|
8
|
+
focused: boolean;
|
|
9
|
+
hovered: boolean;
|
|
10
|
+
pressed: boolean;
|
|
11
|
+
_lastInteraction: "key" | "mouse" | "touch" | "pen";
|
|
12
|
+
_hovered: boolean;
|
|
13
|
+
_focused: boolean;
|
|
14
|
+
_focusedSynthetic: boolean;
|
|
15
|
+
_keyPressed: boolean;
|
|
16
|
+
_keyReleased: boolean;
|
|
17
|
+
_pointerPressed: boolean;
|
|
18
|
+
stateLayer: boolean;
|
|
19
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
20
|
+
disabledState: boolean;
|
|
21
|
+
hoveredState: boolean;
|
|
22
|
+
focusedState: boolean;
|
|
23
|
+
pressedState: boolean;
|
|
24
|
+
touchedState: boolean;
|
|
25
|
+
pointedState: boolean;
|
|
26
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
27
|
+
stateTargetElement: HTMLElement;
|
|
28
|
+
}, any[]>;
|
|
29
|
+
//# sourceMappingURL=StateMixin.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"StateMixin.d.ts","sourceRoot":"","sources":["../../mixins/StateMixin.js"],"names":[],"mappings":"AAIA;;;;GAIG;AACH,yCAFW,cAAc,0BAA0B,EAAE,OAAO;;;;;;;;;;;;;;;;;;;;;;UAyO3D"}
|
|
@@ -0,0 +1,153 @@
|
|
|
1
|
+
/** @typedef {import('../core/CustomElement.js').default} CustomElement */
|
|
2
|
+
/**
|
|
3
|
+
* Composes a text field with label, supporting text, icons and control wiring.
|
|
4
|
+
* @param {ReturnType<import('./ControlMixin.js').default>} Base
|
|
5
|
+
*/
|
|
6
|
+
export default function TextFieldMixin(Base: ReturnType<typeof import("./ControlMixin.js").default>): typeof import("../core/CustomElement.js").default & import("../core/CustomElement.js").Class<{
|
|
7
|
+
disabled: boolean;
|
|
8
|
+
focused: boolean;
|
|
9
|
+
hovered: boolean;
|
|
10
|
+
pressed: boolean;
|
|
11
|
+
_lastInteraction: "key" | "mouse" | "touch" | "pen";
|
|
12
|
+
_hovered: boolean;
|
|
13
|
+
_focused: boolean;
|
|
14
|
+
_focusedSynthetic: boolean;
|
|
15
|
+
_keyPressed: boolean;
|
|
16
|
+
_keyReleased: boolean;
|
|
17
|
+
_pointerPressed: boolean;
|
|
18
|
+
stateLayer: boolean;
|
|
19
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
20
|
+
disabledState: boolean;
|
|
21
|
+
hoveredState: boolean;
|
|
22
|
+
focusedState: boolean;
|
|
23
|
+
pressedState: boolean;
|
|
24
|
+
touchedState: boolean;
|
|
25
|
+
pointedState: boolean;
|
|
26
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
27
|
+
stateTargetElement: HTMLElement;
|
|
28
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
29
|
+
color: string;
|
|
30
|
+
ink: string;
|
|
31
|
+
typeStyle: string;
|
|
32
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
33
|
+
shapeTop: boolean;
|
|
34
|
+
shapeBottom: boolean;
|
|
35
|
+
shapeStart: boolean;
|
|
36
|
+
shapeEnd: boolean;
|
|
37
|
+
shapeStyle: string;
|
|
38
|
+
outlined: boolean;
|
|
39
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
40
|
+
density: number;
|
|
41
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
42
|
+
delegatesFocus: boolean;
|
|
43
|
+
}, any[]> & {
|
|
44
|
+
formAssociated: true;
|
|
45
|
+
} & import("../core/CustomElement.js").Class<{
|
|
46
|
+
_ipcListener: EventListener;
|
|
47
|
+
_ipcTarget: EventTarget;
|
|
48
|
+
_files: FileList;
|
|
49
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
50
|
+
ariaControls: string;
|
|
51
|
+
autocomplete: string;
|
|
52
|
+
name: string;
|
|
53
|
+
readOnly: boolean;
|
|
54
|
+
formNoValidate: boolean;
|
|
55
|
+
defaultChecked: boolean;
|
|
56
|
+
_checkedDirty: boolean;
|
|
57
|
+
_checked: boolean;
|
|
58
|
+
required: boolean;
|
|
59
|
+
type: string;
|
|
60
|
+
_defaultValue: string;
|
|
61
|
+
_value: string;
|
|
62
|
+
_valueDirty: boolean;
|
|
63
|
+
_userInteracted: boolean;
|
|
64
|
+
_invalid: boolean;
|
|
65
|
+
_badInput: boolean;
|
|
66
|
+
_validationMessage: string;
|
|
67
|
+
_formDisabled: boolean;
|
|
68
|
+
_formReset: boolean;
|
|
69
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
70
|
+
erroredState: boolean;
|
|
71
|
+
defaultValue: string;
|
|
72
|
+
_valueBehavior: "default" | "value" | "default/on" | "filename";
|
|
73
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
74
|
+
_onSetValue(value: string): void;
|
|
75
|
+
_onSetChecked(checked: boolean): void;
|
|
76
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
77
|
+
value: string;
|
|
78
|
+
checked: boolean;
|
|
79
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
80
|
+
form: HTMLFormElement;
|
|
81
|
+
validity: ValidityState;
|
|
82
|
+
validationMessage: string;
|
|
83
|
+
willValidate: boolean;
|
|
84
|
+
labels: NodeList;
|
|
85
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
86
|
+
disabledState: boolean;
|
|
87
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
88
|
+
checkValidity(): boolean;
|
|
89
|
+
reportValidity(): boolean;
|
|
90
|
+
setCustomValidity(error: string): void;
|
|
91
|
+
_notifyRadioChange(key: string, value: string): void;
|
|
92
|
+
refreshFormAssociation(): void;
|
|
93
|
+
formAssociatedCallback(form: HTMLFormElement | null): void;
|
|
94
|
+
formIPCEvent(event: CustomEvent<[string, string]>): void;
|
|
95
|
+
formDisabledCallback(disabled: boolean): void;
|
|
96
|
+
formResetCallback(): void;
|
|
97
|
+
formStateRestoreCallback(state: string | FormData, mode: "autocomplete" | "restore"): void;
|
|
98
|
+
_updateFormAssociatedValue(): void;
|
|
99
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
100
|
+
ariaLabel: string;
|
|
101
|
+
_slotInnerText: string;
|
|
102
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
103
|
+
focusableOnDisabled: boolean;
|
|
104
|
+
controlTagName: string;
|
|
105
|
+
controlVoidElement: boolean;
|
|
106
|
+
_slotMutationObserver: any;
|
|
107
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
108
|
+
_onControlValue(value: string): void;
|
|
109
|
+
onValueChangingContentAttribute(): void;
|
|
110
|
+
focus(options?: FocusOptions): void;
|
|
111
|
+
click(): void;
|
|
112
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
113
|
+
stateTargetElement: HTMLElement;
|
|
114
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
115
|
+
checkValidity(): boolean;
|
|
116
|
+
reportValidity(): boolean;
|
|
117
|
+
setCustomValidity(error: string): void;
|
|
118
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
119
|
+
_computedAriaLabel: string;
|
|
120
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
121
|
+
_computedAriaLabelledby: never;
|
|
122
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
123
|
+
/** Show an internal visual state layer element */
|
|
124
|
+
stateLayer: boolean;
|
|
125
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
126
|
+
type: string;
|
|
127
|
+
icon: string;
|
|
128
|
+
iconVariation: string;
|
|
129
|
+
label: string;
|
|
130
|
+
filled: boolean;
|
|
131
|
+
outlined: boolean;
|
|
132
|
+
inputPrefix: string;
|
|
133
|
+
inputSuffix: string;
|
|
134
|
+
trailingIcon: string;
|
|
135
|
+
trailingIconInk: string;
|
|
136
|
+
trailingIconLabel: string;
|
|
137
|
+
supporting: string;
|
|
138
|
+
error: string;
|
|
139
|
+
placeholder: string;
|
|
140
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
141
|
+
erroredState: boolean;
|
|
142
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
143
|
+
computePlaceholder: () => string;
|
|
144
|
+
shouldShowSupporting: () => boolean;
|
|
145
|
+
computeSupportingText: () => string;
|
|
146
|
+
populatedState: () => boolean;
|
|
147
|
+
_showLabelText: never;
|
|
148
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
149
|
+
_shapeShapeTop: never;
|
|
150
|
+
computedIconVariation: () => string;
|
|
151
|
+
}, any[]>;
|
|
152
|
+
export type CustomElement = import("../core/CustomElement.js").default;
|
|
153
|
+
//# sourceMappingURL=TextFieldMixin.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TextFieldMixin.d.ts","sourceRoot":"","sources":["../../mixins/TextFieldMixin.js"],"names":[],"mappings":"AAIA,0EAA0E;AAE1E;;;GAGG;AACH,6CAFW,UAAU,CAAC,0CAAmC,CAAC;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;IAOpD,kDAAkD;;;;;;;;;;;;;;;;;;;;;;;;;;;;UAkvBvD;4BA7vBa,OAAO,0BAA0B,EAAE,OAAO"}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Adds theming attributes (`color`, `ink`, `typeStyle`) that map to CSS tokens.
|
|
3
|
+
* @param {typeof import('../core/CustomElement.js').default} Base
|
|
4
|
+
*/
|
|
5
|
+
export default function ThemableMixin(Base: typeof import("../core/CustomElement.js").default): typeof import("../core/CustomElement.js").default & import("../core/CustomElement.js").Class<{
|
|
6
|
+
color: string;
|
|
7
|
+
ink: string;
|
|
8
|
+
typeStyle: string;
|
|
9
|
+
}, any[]>;
|
|
10
|
+
//# sourceMappingURL=ThemableMixin.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"ThemableMixin.d.ts","sourceRoot":"","sources":["../../mixins/ThemableMixin.js"],"names":[],"mappings":"AAwCA;;;GAGG;AACH,4CAFW,cAAc,0BAA0B,EAAE,OAAO;;;;UAmG3D"}
|
|
@@ -0,0 +1,114 @@
|
|
|
1
|
+
/** @typedef {import('../components/Tooltip.js').default} Tooltip */
|
|
2
|
+
/**
|
|
3
|
+
* Adds tooltip scheduling, positioning, and show/hide behavior for host elements.
|
|
4
|
+
* @param {ReturnType<import('./StateMixin.js').default>} Base
|
|
5
|
+
*/
|
|
6
|
+
export default function TooltipTriggerMixin(Base: ReturnType<typeof import("./StateMixin.js").default>): typeof import("../index.js").CustomElement & import("../core/CustomElement.js").Class<{
|
|
7
|
+
disabled: boolean;
|
|
8
|
+
focused: boolean;
|
|
9
|
+
hovered: boolean;
|
|
10
|
+
pressed: boolean;
|
|
11
|
+
_lastInteraction: "key" | "mouse" | "touch" | "pen";
|
|
12
|
+
_hovered: boolean;
|
|
13
|
+
_focused: boolean;
|
|
14
|
+
_focusedSynthetic: boolean;
|
|
15
|
+
_keyPressed: boolean;
|
|
16
|
+
_keyReleased: boolean;
|
|
17
|
+
_pointerPressed: boolean;
|
|
18
|
+
stateLayer: boolean;
|
|
19
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
20
|
+
disabledState: boolean;
|
|
21
|
+
hoveredState: boolean;
|
|
22
|
+
focusedState: boolean;
|
|
23
|
+
pressedState: boolean;
|
|
24
|
+
touchedState: boolean;
|
|
25
|
+
pointedState: boolean;
|
|
26
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
27
|
+
stateTargetElement: HTMLElement;
|
|
28
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
29
|
+
/** Idle delay before showing tooltip for mouse (ms) */
|
|
30
|
+
TOOLTIP_MOUSE_IDLE_MS: number;
|
|
31
|
+
/** Idle delay before showing tooltip for touch (ms) */
|
|
32
|
+
TOOLTIP_TOUCH_IDLE_MS: number;
|
|
33
|
+
/** Timer id used for tooltip show/hide debouncing */
|
|
34
|
+
/** @type {any} */
|
|
35
|
+
_idleDebounce: any;
|
|
36
|
+
/** Parents being observed for layout changes */
|
|
37
|
+
/** @type {HTMLElement[]} */
|
|
38
|
+
_watchedParents: HTMLElement[];
|
|
39
|
+
/** ResizeObserver used to track tooltip/anchor size changes */
|
|
40
|
+
/** @type {ResizeObserver} */
|
|
41
|
+
_resizeObserver: ResizeObserver;
|
|
42
|
+
/** IntersectionObserver used to detect occlusion */
|
|
43
|
+
/** @type {IntersectionObserver} */
|
|
44
|
+
_intersectObserver: IntersectionObserver;
|
|
45
|
+
/** Bound scroll listener attached to parent elements */
|
|
46
|
+
_parentScrollListener: any;
|
|
47
|
+
/** Slot id to use when cloning tooltip content */
|
|
48
|
+
tooltipSlotId: string;
|
|
49
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
50
|
+
tooltip: string;
|
|
51
|
+
autoTooltip: boolean;
|
|
52
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
53
|
+
cancelShowTooltip(): void;
|
|
54
|
+
/** @param {'mouse'|'touch'|'keyboard'} type */
|
|
55
|
+
scheduleHideTooltip(type: "mouse" | "touch" | "keyboard"): void;
|
|
56
|
+
/** @param {'mouse'|'touch'|'keyboard'} type */
|
|
57
|
+
scheduleShowTooltip(type: "mouse" | "touch" | "keyboard"): void;
|
|
58
|
+
showTooltip(): void;
|
|
59
|
+
hideTooltip(cancelSchedule?: boolean): void;
|
|
60
|
+
/**
|
|
61
|
+
* TODO: Throttle multiple calls
|
|
62
|
+
* @param {DOMRect} [domRect]
|
|
63
|
+
* @return {void}
|
|
64
|
+
*/
|
|
65
|
+
updateTooltipPosition(domRect?: DOMRect): void;
|
|
66
|
+
recloneTooltip(): void;
|
|
67
|
+
closeIfNotHovered(): void;
|
|
68
|
+
}, any[]>;
|
|
69
|
+
export type Tooltip = typeof import("../index.js").CustomElement & import("../core/CustomElement.js").Class<{
|
|
70
|
+
_ariaRole: string;
|
|
71
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
72
|
+
_onConnectAriaValues: Map<import("./AriaReflectorMixin.js").StringKeyOfARIAMixin<keyof ARIAMixin>, ARIAMixin[import("./AriaReflectorMixin.js").StringKeyOfARIAMixin<keyof ARIAMixin>]>;
|
|
73
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
74
|
+
readAriaProperty(name: keyof HTMLElement & keyof ElementInternals): string | ShadowRoot | Element | readonly Element[];
|
|
75
|
+
updateAriaProperty<K extends StringKeyOfARIAMixin<keyof ARIAMixin>>(name: K, value: ARIAMixin[K]): void;
|
|
76
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
77
|
+
disabled: boolean;
|
|
78
|
+
focused: boolean;
|
|
79
|
+
hovered: boolean;
|
|
80
|
+
pressed: boolean;
|
|
81
|
+
_lastInteraction: "key" | "mouse" | "touch" | "pen";
|
|
82
|
+
_hovered: boolean;
|
|
83
|
+
_focused: boolean;
|
|
84
|
+
_focusedSynthetic: boolean;
|
|
85
|
+
_keyPressed: boolean;
|
|
86
|
+
_keyReleased: boolean;
|
|
87
|
+
_pointerPressed: boolean;
|
|
88
|
+
stateLayer: boolean;
|
|
89
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
90
|
+
disabledState: boolean;
|
|
91
|
+
hoveredState: boolean;
|
|
92
|
+
focusedState: boolean;
|
|
93
|
+
pressedState: boolean;
|
|
94
|
+
touchedState: boolean;
|
|
95
|
+
pointedState: boolean;
|
|
96
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
97
|
+
stateTargetElement: HTMLElement;
|
|
98
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
99
|
+
color: string;
|
|
100
|
+
ink: string;
|
|
101
|
+
typeStyle: string;
|
|
102
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
103
|
+
shapeTop: boolean;
|
|
104
|
+
shapeBottom: boolean;
|
|
105
|
+
shapeStart: boolean;
|
|
106
|
+
shapeEnd: boolean;
|
|
107
|
+
shapeStyle: string;
|
|
108
|
+
outlined: boolean;
|
|
109
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
110
|
+
_ariaRole: string;
|
|
111
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
112
|
+
open: boolean;
|
|
113
|
+
}, any[]>;
|
|
114
|
+
//# sourceMappingURL=TooltipTriggerMixin.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TooltipTriggerMixin.d.ts","sourceRoot":"","sources":["../../mixins/TooltipTriggerMixin.js"],"names":[],"mappings":"AAIA,oEAAoE;AAEpE;;;GAGG;AACH,kDAFW,UAAU,CAAC,wCAAiC,CAAC;;;;;;;;;;;;;;;;;;;;;;;IAKlD,uDAAuD;;IAEvD,uDAAuD;;IAEvD,qDAAqD;IACrD,kBAAkB;mBAAP,GAAG;IAEd,gDAAgD;IAChD,4BAA4B;qBAAjB,WAAW,EAAE;IAExB,+DAA+D;IAC/D,6BAA6B;qBAAlB,cAAc;IAEzB,oDAAoD;IACpD,mCAAmC;wBAAxB,oBAAoB;IAE/B,wDAAwD;;IAExD,kDAAkD;;;;;;;IAoBlD,+CAA+C;8BAAnC,OAAO,GAAC,OAAO,GAAC,UAAU;IAyBtC,+CAA+C;8BAAnC,OAAO,GAAC,OAAO,GAAC,UAAU;;;IAkEtC;;;;OAIG;oCAFQ,OAAO,GACN,IAAI;;;UAyLrB"}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Provides a visually hidden touch target area to meet touch size recommendations.
|
|
3
|
+
* @param {typeof import('../core/CustomElement.js').default} Base
|
|
4
|
+
*/
|
|
5
|
+
export default function TouchTargetMixin(Base: typeof import("../core/CustomElement.js").default): typeof import("../core/CustomElement.js").default;
|
|
6
|
+
//# sourceMappingURL=TouchTargetMixin.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TouchTargetMixin.d.ts","sourceRoot":"","sources":["../../mixins/TouchTargetMixin.js"],"names":[],"mappings":"AAAA;;;GAGG;AACH,+CAFW,cAAc,0BAA0B,EAAE,OAAO,qDAmC3D"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Provides typographic padding and leading helpers for text content.
|
|
3
|
+
* @param {typeof import('../core/CustomElement.js').default} Base
|
|
4
|
+
*/
|
|
5
|
+
export default function TypographyMixin(Base: typeof import("../core/CustomElement.js").default): typeof import("../core/CustomElement.js").default & import("../core/CustomElement.js").Class<{
|
|
6
|
+
delegatesFocus: boolean;
|
|
7
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
8
|
+
textPadding: string;
|
|
9
|
+
textPaddingTop: string;
|
|
10
|
+
textLeading: string;
|
|
11
|
+
textPaddingBottom: string;
|
|
12
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
13
|
+
_computedTextPaddingTop: string;
|
|
14
|
+
_computedTextPaddingBottom: string;
|
|
15
|
+
_computedTextLeading: string;
|
|
16
|
+
}, any[]> & import("../core/CustomElement.js").Class<{
|
|
17
|
+
_beforeStyle: string;
|
|
18
|
+
_afterStyle: string;
|
|
19
|
+
}, any[]>;
|
|
20
|
+
//# sourceMappingURL=TypographyMixin.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"TypographyMixin.d.ts","sourceRoot":"","sources":["../../mixins/TypographyMixin.js"],"names":[],"mappings":"AAcA;;;GAGG;AACH,8CAFW,cAAc,0BAA0B,EAAE,OAAO;;;;;;;;;;;;;;UA+G3D"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"rtl.d.ts","sourceRoot":"","sources":["../../services/rtl.js"],"names":[],"mappings":"AAIA,qBAAqB;AACrB,oCADa,IAAI,CAKhB"}
|
|
@@ -0,0 +1,13 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @param {string} name
|
|
3
|
+
* @param {string} path
|
|
4
|
+
* @param {string} [viewBox]
|
|
5
|
+
*/
|
|
6
|
+
export function addSVGAlias(name: string, path: string, viewBox?: string): void;
|
|
7
|
+
/** @type {Map<string, {path:string, viewBox:string}>} */
|
|
8
|
+
export const svgAliasMap: Map<string, {
|
|
9
|
+
path: string;
|
|
10
|
+
viewBox: string;
|
|
11
|
+
}>;
|
|
12
|
+
export const unaliased: Set<any>;
|
|
13
|
+
//# sourceMappingURL=svgAlias.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"svgAlias.d.ts","sourceRoot":"","sources":["../../services/svgAlias.js"],"names":[],"mappings":"AAIA;;;;GAIG;AACH,kCAJW,MAAM,QACN,MAAM,YACN,MAAM,QAShB;AAhBD,yDAAyD;AACzD,0BADW,GAAG,CAAC,MAAM,EAAE;IAAC,IAAI,EAAC,MAAM,CAAC;IAAC,OAAO,EAAC,MAAM,CAAA;CAAC,CAAC,CAChB;AACrC,iCAAmC"}
|
|
@@ -0,0 +1,45 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @param {typeof TYPOGRAPHY_DEFAULT} config
|
|
3
|
+
* @return {string}
|
|
4
|
+
*/
|
|
5
|
+
export function generateTypographyCSS(config?: typeof TYPOGRAPHY_DEFAULT): string;
|
|
6
|
+
/** @return {string} */
|
|
7
|
+
export function generateTypographyGlobalCSS(): string;
|
|
8
|
+
/**
|
|
9
|
+
* @param {typeof SHAPE_ROUNDED_DEFAULT} [config]
|
|
10
|
+
* @return {string}
|
|
11
|
+
*/
|
|
12
|
+
export function generateShapeCSS(config?: typeof SHAPE_ROUNDED_DEFAULT): string;
|
|
13
|
+
/**
|
|
14
|
+
* @param {ThemeOptions} options
|
|
15
|
+
* @return {string}
|
|
16
|
+
*/
|
|
17
|
+
export function generateColorCSS({ color, custom, lightness }: ThemeOptions): string;
|
|
18
|
+
/**
|
|
19
|
+
* @param {ThemeOptions} options
|
|
20
|
+
* @return {void}
|
|
21
|
+
*/
|
|
22
|
+
export function setupTheme({ color, custom, lightness }: ThemeOptions): void;
|
|
23
|
+
/**
|
|
24
|
+
* @param {URLSearchParams} searchParams
|
|
25
|
+
* @return {ThemeOptions}
|
|
26
|
+
*/
|
|
27
|
+
export function themeOptionsFromSearchParams(searchParams: URLSearchParams): ThemeOptions;
|
|
28
|
+
/**
|
|
29
|
+
* @param {ThemeOptions} options
|
|
30
|
+
* @return {string}
|
|
31
|
+
*/
|
|
32
|
+
export function generateThemeCSS({ color, custom, lightness }: ThemeOptions): string;
|
|
33
|
+
export const PALETTES: string[];
|
|
34
|
+
export const TYPE_STYLES: string[];
|
|
35
|
+
export type ThemeOptions = {
|
|
36
|
+
color?: string;
|
|
37
|
+
/**
|
|
38
|
+
* Map()
|
|
39
|
+
*/
|
|
40
|
+
custom?: Iterable<[string, string?]>;
|
|
41
|
+
lightness?: "auto" | "light" | "dark";
|
|
42
|
+
};
|
|
43
|
+
import { TYPOGRAPHY_DEFAULT } from '../constants/typography.js';
|
|
44
|
+
import { SHAPE_ROUNDED_DEFAULT } from '../constants/shapes.js';
|
|
45
|
+
//# sourceMappingURL=theme.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"theme.d.ts","sourceRoot":"","sources":["../../services/theme.js"],"names":[],"mappings":"AA2FA;;;GAGG;AACH,+CAHW,OAAO,kBAAkB,GACxB,MAAM,CAoGjB;AAED,uBAAuB;AACvB,+CADa,MAAM,CAalB;AAED;;;GAGG;AACH,0CAHW,OAAO,qBAAqB,GAC3B,MAAM,CAsBjB;AAaD;;;GAGG;AACH,+DAHW,YAAY,GACX,MAAM,CAWjB;AAED;;;GAGG;AACH,yDAHW,YAAY,GACX,IAAI,CAiBf;AAED;;;GAGG;AACH,2DAHW,eAAe,GACd,YAAY,CAWvB;AAED;;;GAGG;AACH,+DAHW,YAAY,GACX,MAAM,CAqBjB;AA3TD,gCAME;AAEF,mCAME;;YAIQ,MAAM;;;;aACN,QAAQ,CAAC,CAAC,MAAM,EAAC,MAAM,CAAC,CAAC,CAAC;gBAC1B,MAAM,GAAC,OAAO,GAAC,MAAM;;mCAxBI,4BAA4B;sCADzB,wBAAwB"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"cli.d.ts","sourceRoot":"","sources":["../../utils/cli.js"],"names":[],"mappings":"AAAA,gCAAgC;AAChC,mCADa,eAAe,CAU3B"}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"function.d.ts","sourceRoot":"","sources":["../../utils/function.js"],"names":[],"mappings":"AAAA,qBAAqB;AAErB,wBAFa,IAAI,CAEQ"}
|
|
@@ -0,0 +1,20 @@
|
|
|
1
|
+
/** eslint-env browser */
|
|
2
|
+
export const FRAGMENT_TAG: "$FRAGMENT";
|
|
3
|
+
/**
|
|
4
|
+
* @param {string} tagName
|
|
5
|
+
* @param {{ children?: DocumentFragment|string } & Record<string, any>} attrs
|
|
6
|
+
* @return {HTMLElement|DocumentFragment}
|
|
7
|
+
*/
|
|
8
|
+
export function jsx(tagName: string, attrs?: {
|
|
9
|
+
children?: DocumentFragment | string;
|
|
10
|
+
} & Record<string, any>): HTMLElement | DocumentFragment;
|
|
11
|
+
/**
|
|
12
|
+
* @param {string} tagName
|
|
13
|
+
* @param {Record<string, any> & { children: HTMLElement[], style:string|CSSStyleDeclaration }} attrs
|
|
14
|
+
* @return {HTMLElement|DocumentFragment}
|
|
15
|
+
*/
|
|
16
|
+
export function jsxs(tagName: string, attrs: Record<string, any> & {
|
|
17
|
+
children: HTMLElement[];
|
|
18
|
+
style: string | CSSStyleDeclaration;
|
|
19
|
+
}): HTMLElement | DocumentFragment;
|
|
20
|
+
//# sourceMappingURL=jsx-runtime.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"jsx-runtime.d.ts","sourceRoot":"","sources":["../../utils/jsx-runtime.js"],"names":[],"mappings":"AAAA,yBAAyB;AAEzB,2BAA4B,WAAW,CAAC;AAsDxC;;;;GAIG;AACH,6BAJW,MAAM,UACN;IAAE,QAAQ,CAAC,EAAE,gBAAgB,GAAC,MAAM,CAAA;CAAE,GAAG,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAC3D,WAAW,GAAC,gBAAgB,CA2CvC;AA/FD;;;;GAIG;AACH,8BAJW,MAAM,SACN,MAAM,CAAC,MAAM,EAAE,GAAG,CAAC,GAAG;IAAE,QAAQ,EAAE,WAAW,EAAE,CAAC;IAAC,KAAK,EAAC,MAAM,GAAC,mBAAmB,CAAA;CAAE,GAClF,WAAW,GAAC,gBAAgB,CA4CvC"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Functions for blending in HCT and CAM16.
|
|
3
|
+
*/
|
|
4
|
+
/**
|
|
5
|
+
* Blend the design color's HCT hue towards the key color's HCT
|
|
6
|
+
* hue, in a way that leaves the original color recognizable and
|
|
7
|
+
* recognizably shifted towards the key color.
|
|
8
|
+
* @param {number} designColor ARGB representation of an arbitrary color.
|
|
9
|
+
* @param {number} sourceColor ARGB representation of the main theme color.
|
|
10
|
+
* @return {number} The design color with a hue shifted towards the
|
|
11
|
+
* system's color, a slightly warmer/cooler variant of the design
|
|
12
|
+
* color's hue.
|
|
13
|
+
*/
|
|
14
|
+
export function harmonize(designColor: number, sourceColor: number): number;
|
|
15
|
+
/**
|
|
16
|
+
* Blend in CAM16-UCS space.
|
|
17
|
+
* @param {number} from ARGB representation of color
|
|
18
|
+
* @param {number} to ARGB representation of color
|
|
19
|
+
* @param {number} amount how much blending to perform; 0.0 >= and <= 1.0
|
|
20
|
+
* @return {number} from, blended towards to. Hue, chroma, and tone will
|
|
21
|
+
* change.
|
|
22
|
+
*/
|
|
23
|
+
export function cam16Ucs(from: number, to: number, amount: number): number;
|
|
24
|
+
/**
|
|
25
|
+
* Blends hue from one color into another. The chroma and tone of
|
|
26
|
+
* the original color are maintained.
|
|
27
|
+
* @param {number} from ARGB representation of color
|
|
28
|
+
* @param {number} to ARGB representation of color
|
|
29
|
+
* @param {number} amount how much blending to perform; 0.0 >= and <= 1.0
|
|
30
|
+
* @return {number} from, with a hue blended towards to. Chroma and tone
|
|
31
|
+
* are constant.
|
|
32
|
+
*/
|
|
33
|
+
export function hctHue(from: number, to: number, amount: number): number;
|
|
34
|
+
//# sourceMappingURL=blend.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"blend.d.ts","sourceRoot":"","sources":["../../../utils/material-color/blend.js"],"names":[],"mappings":"AAsBA;;GAEG;AAEH;;;;;;;;;GASG;AACH,uCANW,MAAM,eACN,MAAM,GACL,MAAM,CAcjB;AAED;;;;;;;GAOG;AACH,+BANW,MAAM,MACN,MAAM,UACN,MAAM,GACL,MAAM,CAgBjB;AAED;;;;;;;;GAQG;AACH,6BANW,MAAM,MACN,MAAM,UACN,MAAM,GACL,MAAM,CAajB"}
|
|
@@ -0,0 +1,142 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* CAM16, a color appearance model. Colors are not just defined by their hex
|
|
3
|
+
* code, but rather, a hex code and viewing conditions.
|
|
4
|
+
*
|
|
5
|
+
* CAM16 instances also have coordinates in the CAM16-UCS space, called J*, a*,
|
|
6
|
+
* b*, or jstar, astar, bstar in code. CAM16-UCS is included in the CAM16
|
|
7
|
+
* specification, and should be used when measuring distances between colors.
|
|
8
|
+
*
|
|
9
|
+
* In traditional color spaces, a color can be identified solely by the
|
|
10
|
+
* observer's measurement of the color. Color appearance models such as CAM16
|
|
11
|
+
* also use information about the environment where the color was
|
|
12
|
+
* observed, known as the viewing conditions.
|
|
13
|
+
*
|
|
14
|
+
* For example, white under the traditional assumption of a midday sun white
|
|
15
|
+
* point is accurately measured as a slightly chromatic blue by CAM16. (roughly,
|
|
16
|
+
* hue 203, chroma 3, lightness 100)
|
|
17
|
+
*/
|
|
18
|
+
export default class Cam16 {
|
|
19
|
+
/**
|
|
20
|
+
* @param {number} argb ARGB representation of a color.
|
|
21
|
+
* @return {Cam16} CAM16 color, assuming the color was viewed in default viewing
|
|
22
|
+
* conditions.
|
|
23
|
+
*/
|
|
24
|
+
static fromInt(argb: number): Cam16;
|
|
25
|
+
/**
|
|
26
|
+
* @param {number} argb ARGB representation of a color.
|
|
27
|
+
* @param {ViewingConditions} viewingConditions Information about the environment where the color
|
|
28
|
+
* was observed.
|
|
29
|
+
* @return {Cam16} CAM16 color.
|
|
30
|
+
*/
|
|
31
|
+
static fromIntInViewingConditions(argb: number, viewingConditions: ViewingConditions): Cam16;
|
|
32
|
+
/**
|
|
33
|
+
* @param {number} j CAM16 lightness
|
|
34
|
+
* @param {number} c CAM16 chroma
|
|
35
|
+
* @param {number} h CAM16 hue
|
|
36
|
+
* @return {Cam16}
|
|
37
|
+
*/
|
|
38
|
+
static fromJch(j: number, c: number, h: number): Cam16;
|
|
39
|
+
/**
|
|
40
|
+
* @param {number} j CAM16 lightness
|
|
41
|
+
* @param {number} c CAM16 chroma
|
|
42
|
+
* @param {number} h CAM16 hue
|
|
43
|
+
* @param {ViewingConditions} viewingConditions Information about the environment where the color
|
|
44
|
+
* was observed.
|
|
45
|
+
*/
|
|
46
|
+
static fromJchInViewingConditions(j: number, c: number, h: number, viewingConditions: ViewingConditions): Cam16;
|
|
47
|
+
/**
|
|
48
|
+
* @param {number} jstar CAM16-UCS lightness.
|
|
49
|
+
* @param {number} astar CAM16-UCS a dimension. Like a* in L*a*b*, it is a Cartesian
|
|
50
|
+
* coordinate on the Y axis.
|
|
51
|
+
* @param {number} bstar CAM16-UCS b dimension. Like a* in L*a*b*, it is a Cartesian
|
|
52
|
+
* coordinate on the X axis.
|
|
53
|
+
* @return {Cam16}
|
|
54
|
+
*/
|
|
55
|
+
static fromUcs(jstar: number, astar: number, bstar: number): Cam16;
|
|
56
|
+
/**
|
|
57
|
+
* @param {number} jstar CAM16-UCS lightness.
|
|
58
|
+
* @param {number} astar CAM16-UCS a dimension. Like a* in L*a*b*, it is a Cartesian
|
|
59
|
+
* coordinate on the Y axis.
|
|
60
|
+
* @param {number} bstar CAM16-UCS b dimension. Like a* in L*a*b*, it is a Cartesian
|
|
61
|
+
* coordinate on the X axis.
|
|
62
|
+
* @param {ViewingConditions} viewingConditions Information about the environment where the color
|
|
63
|
+
* was observed.
|
|
64
|
+
*/
|
|
65
|
+
static fromUcsInViewingConditions(jstar: number, astar: number, bstar: number, viewingConditions: ViewingConditions): Cam16;
|
|
66
|
+
/**
|
|
67
|
+
* Given color expressed in XYZ and viewed in [viewingConditions], convert to
|
|
68
|
+
* CAM16.
|
|
69
|
+
* @param {number} x
|
|
70
|
+
* @param {number} y
|
|
71
|
+
* @param {number} z
|
|
72
|
+
* @param {ViewingConditions} viewingConditions
|
|
73
|
+
* @return {Cam16}
|
|
74
|
+
*/
|
|
75
|
+
static fromXyzInViewingConditions(x: number, y: number, z: number, viewingConditions: ViewingConditions): Cam16;
|
|
76
|
+
/**
|
|
77
|
+
* All of the CAM16 dimensions can be calculated from 3 of the dimensions, in
|
|
78
|
+
* the following combinations:
|
|
79
|
+
* - {j or q} and {c, m, or s} and hue
|
|
80
|
+
* - jstar, astar, bstar
|
|
81
|
+
* Prefer using a static method that constructs from 3 of those dimensions.
|
|
82
|
+
* This constructor is intended for those methods to use to return all
|
|
83
|
+
* possible dimensions.
|
|
84
|
+
* @param {number} hue
|
|
85
|
+
* @param {number} chroma informally, colorfulness / color intensity. like saturation
|
|
86
|
+
* in HSL, except perceptually accurate.
|
|
87
|
+
* @param {number} j lightness
|
|
88
|
+
* @param {number} q brightness; ratio of lightness to white point's lightness
|
|
89
|
+
* @param {number} m colorfulness
|
|
90
|
+
* @param {number} s saturation; ratio of chroma to white point's chroma
|
|
91
|
+
* @param {number} jstar CAM16-UCS J coordinate
|
|
92
|
+
* @param {number} astar CAM16-UCS a coordinate
|
|
93
|
+
* @param {number} bstar CAM16-UCS b coordinate
|
|
94
|
+
*/
|
|
95
|
+
constructor(hue: number, chroma: number, j: number, q: number, m: number, s: number, jstar: number, astar: number, bstar: number);
|
|
96
|
+
/** @readonly */
|
|
97
|
+
readonly hue: number;
|
|
98
|
+
/** @readonly */
|
|
99
|
+
readonly chroma: number;
|
|
100
|
+
/** @readonly */
|
|
101
|
+
readonly j: number;
|
|
102
|
+
/** @readonly */
|
|
103
|
+
readonly q: number;
|
|
104
|
+
/** @readonly */
|
|
105
|
+
readonly m: number;
|
|
106
|
+
/** @readonly */
|
|
107
|
+
readonly s: number;
|
|
108
|
+
/** @readonly */
|
|
109
|
+
readonly jstar: number;
|
|
110
|
+
/** @readonly */
|
|
111
|
+
readonly astar: number;
|
|
112
|
+
/** @readonly */
|
|
113
|
+
readonly bstar: number;
|
|
114
|
+
/**
|
|
115
|
+
* CAM16 instances also have coordinates in the CAM16-UCS space, called J*,
|
|
116
|
+
* a*, b*, or jstar, astar, bstar in code. CAM16-UCS is included in the CAM16
|
|
117
|
+
* specification, and is used to measure distances between colors.
|
|
118
|
+
* @param {Cam16} other
|
|
119
|
+
* @return {number}
|
|
120
|
+
*/
|
|
121
|
+
distance(other: Cam16): number;
|
|
122
|
+
/**
|
|
123
|
+
* @return {number} ARGB representation of color, assuming the color was viewed in
|
|
124
|
+
* default viewing conditions, which are near-identical to the default
|
|
125
|
+
* viewing conditions for sRGB.
|
|
126
|
+
*/
|
|
127
|
+
toInt(): number;
|
|
128
|
+
/**
|
|
129
|
+
* @param {ViewingConditions} viewingConditions Information about the environment where the color
|
|
130
|
+
* will be viewed.
|
|
131
|
+
* @return {number} ARGB representation of color
|
|
132
|
+
*/
|
|
133
|
+
viewed(viewingConditions: ViewingConditions): number;
|
|
134
|
+
/**
|
|
135
|
+
* XYZ representation of CAM16 seen in [viewingConditions].
|
|
136
|
+
* @param {ViewingConditions} viewingConditions
|
|
137
|
+
* @return {number[]}
|
|
138
|
+
*/
|
|
139
|
+
xyzInViewingConditions(viewingConditions: ViewingConditions): number[];
|
|
140
|
+
}
|
|
141
|
+
import ViewingConditions from './ViewingConditions.js';
|
|
142
|
+
//# sourceMappingURL=Cam16.d.ts.map
|