@windmorph/react 0.0.0-stage → 0.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +21 -0
- package/NOTICE +23 -0
- package/README.md +149 -2
- package/dist/cli.d.ts +1 -0
- package/dist/cli.js +112 -0
- package/dist/cli.js.map +1 -0
- package/dist/components/app-bar/AppBarItems.js +23 -0
- package/dist/components/app-bar/AppBarItems.js.map +1 -0
- package/dist/components/app-bar/TopAppBar.d.ts +89 -0
- package/dist/components/app-bar/TopAppBar.js +103 -0
- package/dist/components/app-bar/TopAppBar.js.map +1 -0
- package/dist/components/app-bar/app-bar-styles.d.ts +280 -0
- package/dist/components/app-bar/app-bar-styles.js +142 -0
- package/dist/components/app-bar/app-bar-styles.js.map +1 -0
- package/dist/components/app-bar/app-bar-tokens.d.ts +7 -0
- package/dist/components/app-bar/app-bar-tokens.js +64 -0
- package/dist/components/app-bar/app-bar-tokens.js.map +1 -0
- package/dist/components/app-bar/use-app-bar-scroll.d.ts +6 -0
- package/dist/components/app-bar/use-app-bar-scroll.js +139 -0
- package/dist/components/app-bar/use-app-bar-scroll.js.map +1 -0
- package/dist/components/autocomplete/Autocomplete.d.ts +142 -0
- package/dist/components/autocomplete/Autocomplete.js +284 -0
- package/dist/components/autocomplete/Autocomplete.js.map +1 -0
- package/dist/components/badge/Badge.d.ts +71 -0
- package/dist/components/badge/Badge.js +72 -0
- package/dist/components/badge/Badge.js.map +1 -0
- package/dist/components/badge/badge-styles.d.ts +100 -0
- package/dist/components/badge/badge-styles.js +43 -0
- package/dist/components/badge/badge-styles.js.map +1 -0
- package/dist/components/badge/badge-tokens.d.ts +7 -0
- package/dist/components/badge/badge-tokens.js +40 -0
- package/dist/components/badge/badge-tokens.js.map +1 -0
- package/dist/components/button/Button.d.ts +91 -0
- package/dist/components/button/Button.js +96 -0
- package/dist/components/button/Button.js.map +1 -0
- package/dist/components/button/ButtonContext.d.ts +30 -0
- package/dist/components/button/ButtonContext.js +18 -0
- package/dist/components/button/ButtonContext.js.map +1 -0
- package/dist/components/button/DensityZeroButtons.js +25 -0
- package/dist/components/button/DensityZeroButtons.js.map +1 -0
- package/dist/components/button/button-pending.d.ts +10 -0
- package/dist/components/button/button-pending.js +166 -0
- package/dist/components/button/button-pending.js.map +1 -0
- package/dist/components/button/button-styles.d.ts +216 -0
- package/dist/components/button/button-styles.js +199 -0
- package/dist/components/button/button-styles.js.map +1 -0
- package/dist/components/button/button-tokens.d.ts +10 -0
- package/dist/components/button/button-tokens.js +257 -0
- package/dist/components/button/button-tokens.js.map +1 -0
- package/dist/components/button/connected-shapes.js +152 -0
- package/dist/components/button/connected-shapes.js.map +1 -0
- package/dist/components/card/Card.d.ts +60 -0
- package/dist/components/card/Card.js +69 -0
- package/dist/components/card/Card.js.map +1 -0
- package/dist/components/card/card-styles.d.ts +42 -0
- package/dist/components/card/card-styles.js +64 -0
- package/dist/components/card/card-styles.js.map +1 -0
- package/dist/components/card/card-tokens.d.ts +7 -0
- package/dist/components/card/card-tokens.js +84 -0
- package/dist/components/card/card-tokens.js.map +1 -0
- package/dist/components/carousel/Carousel.d.ts +124 -0
- package/dist/components/carousel/Carousel.js +387 -0
- package/dist/components/carousel/Carousel.js.map +1 -0
- package/dist/components/carousel/carousel-keylines.js +486 -0
- package/dist/components/carousel/carousel-keylines.js.map +1 -0
- package/dist/components/carousel/carousel-press-area.js +35 -0
- package/dist/components/carousel/carousel-press-area.js.map +1 -0
- package/dist/components/carousel/carousel-styles.d.ts +188 -0
- package/dist/components/carousel/carousel-styles.js +116 -0
- package/dist/components/carousel/carousel-styles.js.map +1 -0
- package/dist/components/carousel/carousel-tokens.d.ts +7 -0
- package/dist/components/carousel/carousel-tokens.js +18 -0
- package/dist/components/carousel/carousel-tokens.js.map +1 -0
- package/dist/components/checkbox/Checkbox.d.ts +78 -0
- package/dist/components/checkbox/Checkbox.js +77 -0
- package/dist/components/checkbox/Checkbox.js.map +1 -0
- package/dist/components/checkbox/checkbox-box.js +34 -0
- package/dist/components/checkbox/checkbox-box.js.map +1 -0
- package/dist/components/checkbox/checkbox-styles.d.ts +100 -0
- package/dist/components/checkbox/checkbox-styles.js +54 -0
- package/dist/components/checkbox/checkbox-styles.js.map +1 -0
- package/dist/components/checkbox/checkbox-tokens.d.ts +7 -0
- package/dist/components/checkbox/checkbox-tokens.js +41 -0
- package/dist/components/checkbox/checkbox-tokens.js.map +1 -0
- package/dist/components/chip/Chip.d.ts +171 -0
- package/dist/components/chip/Chip.js +348 -0
- package/dist/components/chip/Chip.js.map +1 -0
- package/dist/components/chip/ChipSet.d.ts +70 -0
- package/dist/components/chip/ChipSet.js +198 -0
- package/dist/components/chip/ChipSet.js.map +1 -0
- package/dist/components/chip/chip-styles.d.ts +263 -0
- package/dist/components/chip/chip-styles.js +360 -0
- package/dist/components/chip/chip-styles.js.map +1 -0
- package/dist/components/chip/chip-tokens.d.ts +13 -0
- package/dist/components/chip/chip-tokens.js +185 -0
- package/dist/components/chip/chip-tokens.js.map +1 -0
- package/dist/components/date-picker/CalendarGrid.js +94 -0
- package/dist/components/date-picker/CalendarGrid.js.map +1 -0
- package/dist/components/date-picker/CompactDateDialog.js +63 -0
- package/dist/components/date-picker/CompactDateDialog.js.map +1 -0
- package/dist/components/date-picker/DateField.d.ts +161 -0
- package/dist/components/date-picker/DateField.js +393 -0
- package/dist/components/date-picker/DateField.js.map +1 -0
- package/dist/components/date-picker/DateInput.d.ts +20 -0
- package/dist/components/date-picker/DateInput.js +99 -0
- package/dist/components/date-picker/DateInput.js.map +1 -0
- package/dist/components/date-picker/DatePicker.d.ts +165 -0
- package/dist/components/date-picker/DatePicker.js +492 -0
- package/dist/components/date-picker/DatePicker.js.map +1 -0
- package/dist/components/date-picker/PickerDialog.d.ts +121 -0
- package/dist/components/date-picker/PickerDialog.js +161 -0
- package/dist/components/date-picker/PickerDialog.js.map +1 -0
- package/dist/components/date-picker/calendar-parts.js +141 -0
- package/dist/components/date-picker/calendar-parts.js.map +1 -0
- package/dist/components/date-picker/date-format.js +72 -0
- package/dist/components/date-picker/date-format.js.map +1 -0
- package/dist/components/date-picker/date-picker-styles.d.ts +247 -0
- package/dist/components/date-picker/date-picker-styles.js +163 -0
- package/dist/components/date-picker/date-picker-styles.js.map +1 -0
- package/dist/components/date-picker/date-picker-tokens.d.ts +7 -0
- package/dist/components/date-picker/date-picker-tokens.js +104 -0
- package/dist/components/date-picker/date-picker-tokens.js.map +1 -0
- package/dist/components/date-picker/picker-dialog-context.js +8 -0
- package/dist/components/date-picker/picker-dialog-context.js.map +1 -0
- package/dist/components/date-picker/picker-dialog-styles.d.ts +95 -0
- package/dist/components/date-picker/picker-dialog-styles.js +57 -0
- package/dist/components/date-picker/picker-dialog-styles.js.map +1 -0
- package/dist/components/date-picker/picker-icons.js +24 -0
- package/dist/components/date-picker/picker-icons.js.map +1 -0
- package/dist/components/date-picker/use-media-query.js +21 -0
- package/dist/components/date-picker/use-media-query.js.map +1 -0
- package/dist/components/date-picker/use-size-transform.js +62 -0
- package/dist/components/date-picker/use-size-transform.js.map +1 -0
- package/dist/components/date-picker/use-view-exit.js +68 -0
- package/dist/components/date-picker/use-view-exit.js.map +1 -0
- package/dist/components/dialog/Dialog.d.ts +267 -0
- package/dist/components/dialog/Dialog.js +521 -0
- package/dist/components/dialog/Dialog.js.map +1 -0
- package/dist/components/dialog/dialog-styles.d.ts +335 -0
- package/dist/components/dialog/dialog-styles.js +377 -0
- package/dist/components/dialog/dialog-styles.js.map +1 -0
- package/dist/components/dialog/dialog-tokens.d.ts +7 -0
- package/dist/components/dialog/dialog-tokens.js +57 -0
- package/dist/components/dialog/dialog-tokens.js.map +1 -0
- package/dist/components/divider/Divider.d.ts +59 -0
- package/dist/components/divider/Divider.js +53 -0
- package/dist/components/divider/Divider.js.map +1 -0
- package/dist/components/divider/divider-styles.d.ts +90 -0
- package/dist/components/divider/divider-styles.js +66 -0
- package/dist/components/divider/divider-styles.js.map +1 -0
- package/dist/components/divider/divider-tokens.d.ts +7 -0
- package/dist/components/divider/divider-tokens.js +16 -0
- package/dist/components/divider/divider-tokens.js.map +1 -0
- package/dist/components/fab/Fab.d.ts +130 -0
- package/dist/components/fab/Fab.js +137 -0
- package/dist/components/fab/Fab.js.map +1 -0
- package/dist/components/fab/FabTooltip.js +36 -0
- package/dist/components/fab/FabTooltip.js.map +1 -0
- package/dist/components/fab/fab-styles.d.ts +286 -0
- package/dist/components/fab/fab-styles.js +131 -0
- package/dist/components/fab/fab-styles.js.map +1 -0
- package/dist/components/fab/fab-tokens.d.ts +12 -0
- package/dist/components/fab/fab-tokens.js +105 -0
- package/dist/components/fab/fab-tokens.js.map +1 -0
- package/dist/components/fab-menu/FabMenu.d.ts +156 -0
- package/dist/components/fab-menu/FabMenu.js +291 -0
- package/dist/components/fab-menu/FabMenu.js.map +1 -0
- package/dist/components/fab-menu/fab-menu-stagger.js +51 -0
- package/dist/components/fab-menu/fab-menu-stagger.js.map +1 -0
- package/dist/components/fab-menu/fab-menu-styles.d.ts +166 -0
- package/dist/components/fab-menu/fab-menu-styles.js +107 -0
- package/dist/components/fab-menu/fab-menu-styles.js.map +1 -0
- package/dist/components/fab-menu/fab-menu-tokens.d.ts +7 -0
- package/dist/components/fab-menu/fab-menu-tokens.js +120 -0
- package/dist/components/fab-menu/fab-menu-tokens.js.map +1 -0
- package/dist/components/icon-button/IconButton.d.ts +125 -0
- package/dist/components/icon-button/IconButton.js +112 -0
- package/dist/components/icon-button/IconButton.js.map +1 -0
- package/dist/components/icon-button/icon-button-styles.d.ts +217 -0
- package/dist/components/icon-button/icon-button-styles.js +244 -0
- package/dist/components/icon-button/icon-button-styles.js.map +1 -0
- package/dist/components/icon-button/icon-button-tokens.d.ts +11 -0
- package/dist/components/icon-button/icon-button-tokens.js +215 -0
- package/dist/components/icon-button/icon-button-tokens.js.map +1 -0
- package/dist/components/list/List.d.ts +265 -0
- package/dist/components/list/List.js +1386 -0
- package/dist/components/list/List.js.map +1 -0
- package/dist/components/list/ListMedia.d.ts +88 -0
- package/dist/components/list/ListMedia.js +132 -0
- package/dist/components/list/ListMedia.js.map +1 -0
- package/dist/components/list/list-styles.d.ts +375 -0
- package/dist/components/list/list-styles.js +220 -0
- package/dist/components/list/list-styles.js.map +1 -0
- package/dist/components/list/list-tokens.d.ts +7 -0
- package/dist/components/list/list-tokens.js +92 -0
- package/dist/components/list/list-tokens.js.map +1 -0
- package/dist/components/loading-indicator/LoadingIndicator.d.ts +65 -0
- package/dist/components/loading-indicator/LoadingIndicator.js +92 -0
- package/dist/components/loading-indicator/LoadingIndicator.js.map +1 -0
- package/dist/components/loading-indicator/lazy-loading-indicator.js +25 -0
- package/dist/components/loading-indicator/lazy-loading-indicator.js.map +1 -0
- package/dist/components/loading-indicator/loading-indicator-frames.js +149 -0
- package/dist/components/loading-indicator/loading-indicator-frames.js.map +1 -0
- package/dist/components/loading-indicator/loading-indicator-styles.d.ts +36 -0
- package/dist/components/loading-indicator/loading-indicator-styles.js +22 -0
- package/dist/components/loading-indicator/loading-indicator-styles.js.map +1 -0
- package/dist/components/loading-indicator/loading-indicator-tokens.d.ts +7 -0
- package/dist/components/loading-indicator/loading-indicator-tokens.js +44 -0
- package/dist/components/loading-indicator/loading-indicator-tokens.js.map +1 -0
- package/dist/components/menu/Menu.d.ts +215 -0
- package/dist/components/menu/Menu.js +715 -0
- package/dist/components/menu/Menu.js.map +1 -0
- package/dist/components/menu/menu-styles.d.ts +354 -0
- package/dist/components/menu/menu-styles.js +219 -0
- package/dist/components/menu/menu-styles.js.map +1 -0
- package/dist/components/menu/menu-tokens.d.ts +7 -0
- package/dist/components/menu/menu-tokens.js +93 -0
- package/dist/components/menu/menu-tokens.js.map +1 -0
- package/dist/components/menu/menu-trigger.d.ts +51 -0
- package/dist/components/menu/menu-trigger.js +100 -0
- package/dist/components/menu/menu-trigger.js.map +1 -0
- package/dist/components/menu/use-reveal-entering.js +42 -0
- package/dist/components/menu/use-reveal-entering.js.map +1 -0
- package/dist/components/navigation/NavItem.d.ts +54 -0
- package/dist/components/navigation/NavItem.js +182 -0
- package/dist/components/navigation/NavItem.js.map +1 -0
- package/dist/components/navigation/NavigationBar.d.ts +64 -0
- package/dist/components/navigation/NavigationBar.js +121 -0
- package/dist/components/navigation/NavigationBar.js.map +1 -0
- package/dist/components/navigation/NavigationRail.d.ts +91 -0
- package/dist/components/navigation/NavigationRail.js +285 -0
- package/dist/components/navigation/NavigationRail.js.map +1 -0
- package/dist/components/navigation/nav-item-styles.d.ts +190 -0
- package/dist/components/navigation/nav-item-styles.js +123 -0
- package/dist/components/navigation/nav-item-styles.js.map +1 -0
- package/dist/components/navigation/navigation-styles.d.ts +239 -0
- package/dist/components/navigation/navigation-styles.js +134 -0
- package/dist/components/navigation/navigation-styles.js.map +1 -0
- package/dist/components/navigation/navigation-tokens.d.ts +9 -0
- package/dist/components/navigation/navigation-tokens.js +114 -0
- package/dist/components/navigation/navigation-tokens.js.map +1 -0
- package/dist/components/navigation/use-hide-on-scroll.js +115 -0
- package/dist/components/navigation/use-hide-on-scroll.js.map +1 -0
- package/dist/components/navigation/use-item-arrow-keys.js +37 -0
- package/dist/components/navigation/use-item-arrow-keys.js.map +1 -0
- package/dist/components/navigation/use-rail-item-morph.js +61 -0
- package/dist/components/navigation/use-rail-item-morph.js.map +1 -0
- package/dist/components/progress/ProgressIndicator.d.ts +95 -0
- package/dist/components/progress/ProgressIndicator.js +426 -0
- package/dist/components/progress/ProgressIndicator.js.map +1 -0
- package/dist/components/progress/progress-geometry.js +285 -0
- package/dist/components/progress/progress-geometry.js.map +1 -0
- package/dist/components/progress/progress-styles.d.ts +81 -0
- package/dist/components/progress/progress-styles.js +43 -0
- package/dist/components/progress/progress-styles.js.map +1 -0
- package/dist/components/progress/progress-tokens.d.ts +7 -0
- package/dist/components/progress/progress-tokens.js +39 -0
- package/dist/components/progress/progress-tokens.js.map +1 -0
- package/dist/components/pull-to-refresh/PullToRefresh.d.ts +94 -0
- package/dist/components/pull-to-refresh/PullToRefresh.js +395 -0
- package/dist/components/pull-to-refresh/PullToRefresh.js.map +1 -0
- package/dist/components/pull-to-refresh/pull-to-refresh-math.js +37 -0
- package/dist/components/pull-to-refresh/pull-to-refresh-math.js.map +1 -0
- package/dist/components/pull-to-refresh/pull-to-refresh-styles.d.ts +53 -0
- package/dist/components/pull-to-refresh/pull-to-refresh-styles.js +14 -0
- package/dist/components/pull-to-refresh/pull-to-refresh-styles.js.map +1 -0
- package/dist/components/radio/RadioGroup.d.ts +121 -0
- package/dist/components/radio/RadioGroup.js +163 -0
- package/dist/components/radio/RadioGroup.js.map +1 -0
- package/dist/components/radio/radio-ring.js +21 -0
- package/dist/components/radio/radio-ring.js.map +1 -0
- package/dist/components/radio/radio-styles.d.ts +155 -0
- package/dist/components/radio/radio-styles.js +60 -0
- package/dist/components/radio/radio-styles.js.map +1 -0
- package/dist/components/radio/radio-tokens.d.ts +7 -0
- package/dist/components/radio/radio-tokens.js +31 -0
- package/dist/components/radio/radio-tokens.js.map +1 -0
- package/dist/components/search/SearchAppBar.d.ts +45 -0
- package/dist/components/search/SearchAppBar.js +61 -0
- package/dist/components/search/SearchAppBar.js.map +1 -0
- package/dist/components/search/SearchBar.d.ts +147 -0
- package/dist/components/search/SearchBar.js +412 -0
- package/dist/components/search/SearchBar.js.map +1 -0
- package/dist/components/search/search-styles.d.ts +243 -0
- package/dist/components/search/search-styles.js +143 -0
- package/dist/components/search/search-styles.js.map +1 -0
- package/dist/components/search/search-tokens.d.ts +9 -0
- package/dist/components/search/search-tokens.js +70 -0
- package/dist/components/search/search-tokens.js.map +1 -0
- package/dist/components/select/Select.d.ts +187 -0
- package/dist/components/select/Select.js +319 -0
- package/dist/components/select/Select.js.map +1 -0
- package/dist/components/select/field-shell.d.ts +29 -0
- package/dist/components/select/field-shell.js +135 -0
- package/dist/components/select/field-shell.js.map +1 -0
- package/dist/components/select/option-list.d.ts +81 -0
- package/dist/components/select/option-list.js +291 -0
- package/dist/components/select/option-list.js.map +1 -0
- package/dist/components/select/search-list.js +135 -0
- package/dist/components/select/search-list.js.map +1 -0
- package/dist/components/select/selection-cap.js +30 -0
- package/dist/components/select/selection-cap.js.map +1 -0
- package/dist/components/sheet/BottomSheet.d.ts +154 -0
- package/dist/components/sheet/BottomSheet.js +442 -0
- package/dist/components/sheet/BottomSheet.js.map +1 -0
- package/dist/components/sheet/SheetTrigger.d.ts +25 -0
- package/dist/components/sheet/SheetTrigger.js +46 -0
- package/dist/components/sheet/SheetTrigger.js.map +1 -0
- package/dist/components/sheet/SideSheet.d.ts +139 -0
- package/dist/components/sheet/SideSheet.js +289 -0
- package/dist/components/sheet/SideSheet.js.map +1 -0
- package/dist/components/sheet/bottom-sheet-gesture.js +30 -0
- package/dist/components/sheet/bottom-sheet-gesture.js.map +1 -0
- package/dist/components/sheet/lazy-bottom-sheet.js +33 -0
- package/dist/components/sheet/lazy-bottom-sheet.js.map +1 -0
- package/dist/components/sheet/sheet-gesture.js +48 -0
- package/dist/components/sheet/sheet-gesture.js.map +1 -0
- package/dist/components/sheet/sheet-icons.js +31 -0
- package/dist/components/sheet/sheet-icons.js.map +1 -0
- package/dist/components/sheet/sheet-settle.js +58 -0
- package/dist/components/sheet/sheet-settle.js.map +1 -0
- package/dist/components/sheet/sheet-styles.d.ts +312 -0
- package/dist/components/sheet/sheet-styles.js +229 -0
- package/dist/components/sheet/sheet-styles.js.map +1 -0
- package/dist/components/sheet/sheet-tokens.d.ts +12 -0
- package/dist/components/sheet/sheet-tokens.js +115 -0
- package/dist/components/sheet/sheet-tokens.js.map +1 -0
- package/dist/components/sheet/side-swipe-gesture.js +22 -0
- package/dist/components/sheet/side-swipe-gesture.js.map +1 -0
- package/dist/components/sheet/use-peek-inert.js +32 -0
- package/dist/components/sheet/use-peek-inert.js.map +1 -0
- package/dist/components/sheet/use-side-swipe.js +174 -0
- package/dist/components/sheet/use-side-swipe.js.map +1 -0
- package/dist/components/slider/Slider.d.ts +129 -0
- package/dist/components/slider/Slider.js +295 -0
- package/dist/components/slider/Slider.js.map +1 -0
- package/dist/components/slider/slider-geometry.js +138 -0
- package/dist/components/slider/slider-geometry.js.map +1 -0
- package/dist/components/slider/slider-styles.d.ts +133 -0
- package/dist/components/slider/slider-styles.js +97 -0
- package/dist/components/slider/slider-styles.js.map +1 -0
- package/dist/components/slider/slider-tokens.d.ts +7 -0
- package/dist/components/slider/slider-tokens.js +66 -0
- package/dist/components/slider/slider-tokens.js.map +1 -0
- package/dist/components/slider/use-touch-track.js +138 -0
- package/dist/components/slider/use-touch-track.js.map +1 -0
- package/dist/components/snackbar/Snackbar.d.ts +96 -0
- package/dist/components/snackbar/Snackbar.js +253 -0
- package/dist/components/snackbar/Snackbar.js.map +1 -0
- package/dist/components/snackbar/snackbar-state.d.ts +58 -0
- package/dist/components/snackbar/snackbar-state.js +73 -0
- package/dist/components/snackbar/snackbar-state.js.map +1 -0
- package/dist/components/snackbar/snackbar-styles.d.ts +109 -0
- package/dist/components/snackbar/snackbar-styles.js +67 -0
- package/dist/components/snackbar/snackbar-styles.js.map +1 -0
- package/dist/components/snackbar/snackbar-tokens.d.ts +7 -0
- package/dist/components/snackbar/snackbar-tokens.js +54 -0
- package/dist/components/snackbar/snackbar-tokens.js.map +1 -0
- package/dist/components/split-button/SplitButton.d.ts +109 -0
- package/dist/components/split-button/SplitButton.js +195 -0
- package/dist/components/split-button/SplitButton.js.map +1 -0
- package/dist/components/split-button/split-button-styles.d.ts +214 -0
- package/dist/components/split-button/split-button-styles.js +164 -0
- package/dist/components/split-button/split-button-styles.js.map +1 -0
- package/dist/components/split-button/split-button-tokens.d.ts +7 -0
- package/dist/components/split-button/split-button-tokens.js +36 -0
- package/dist/components/split-button/split-button-tokens.js.map +1 -0
- package/dist/components/switch/Switch.d.ts +82 -0
- package/dist/components/switch/Switch.js +165 -0
- package/dist/components/switch/Switch.js.map +1 -0
- package/dist/components/switch/switch-styles.d.ts +96 -0
- package/dist/components/switch/switch-styles.js +68 -0
- package/dist/components/switch/switch-styles.js.map +1 -0
- package/dist/components/switch/switch-thumb.js +41 -0
- package/dist/components/switch/switch-thumb.js.map +1 -0
- package/dist/components/switch/switch-tokens.d.ts +7 -0
- package/dist/components/switch/switch-tokens.js +78 -0
- package/dist/components/switch/switch-tokens.js.map +1 -0
- package/dist/components/tabs/Tabs.d.ts +120 -0
- package/dist/components/tabs/Tabs.js +346 -0
- package/dist/components/tabs/Tabs.js.map +1 -0
- package/dist/components/tabs/tabs-styles.d.ts +198 -0
- package/dist/components/tabs/tabs-styles.js +99 -0
- package/dist/components/tabs/tabs-styles.js.map +1 -0
- package/dist/components/tabs/tabs-tokens.d.ts +7 -0
- package/dist/components/tabs/tabs-tokens.js +121 -0
- package/dist/components/tabs/tabs-tokens.js.map +1 -0
- package/dist/components/text-field/TextField.d.ts +175 -0
- package/dist/components/text-field/TextField.js +250 -0
- package/dist/components/text-field/TextField.js.map +1 -0
- package/dist/components/text-field/text-field-styles.d.ts +252 -0
- package/dist/components/text-field/text-field-styles.js +209 -0
- package/dist/components/text-field/text-field-styles.js.map +1 -0
- package/dist/components/text-field/text-field-tokens.d.ts +7 -0
- package/dist/components/text-field/text-field-tokens.js +177 -0
- package/dist/components/text-field/text-field-tokens.js.map +1 -0
- package/dist/components/time-picker/TimePicker.d.ts +142 -0
- package/dist/components/time-picker/TimePicker.js +700 -0
- package/dist/components/time-picker/TimePicker.js.map +1 -0
- package/dist/components/time-picker/time-picker-styles.d.ts +175 -0
- package/dist/components/time-picker/time-picker-styles.js +112 -0
- package/dist/components/time-picker/time-picker-styles.js.map +1 -0
- package/dist/components/time-picker/time-picker-tokens.d.ts +7 -0
- package/dist/components/time-picker/time-picker-tokens.js +86 -0
- package/dist/components/time-picker/time-picker-tokens.js.map +1 -0
- package/dist/components/toolbar/Toolbar.d.ts +209 -0
- package/dist/components/toolbar/Toolbar.js +282 -0
- package/dist/components/toolbar/Toolbar.js.map +1 -0
- package/dist/components/toolbar/toolbar-styles.d.ts +403 -0
- package/dist/components/toolbar/toolbar-styles.js +253 -0
- package/dist/components/toolbar/toolbar-styles.js.map +1 -0
- package/dist/components/toolbar/toolbar-tokens.d.ts +27 -0
- package/dist/components/toolbar/toolbar-tokens.js +117 -0
- package/dist/components/toolbar/toolbar-tokens.js.map +1 -0
- package/dist/components/toolbar/use-toolbar-scroll-expansion.d.ts +56 -0
- package/dist/components/toolbar/use-toolbar-scroll-expansion.js +86 -0
- package/dist/components/toolbar/use-toolbar-scroll-expansion.js.map +1 -0
- package/dist/components/tooltip/Tooltip.d.ts +131 -0
- package/dist/components/tooltip/Tooltip.js +388 -0
- package/dist/components/tooltip/Tooltip.js.map +1 -0
- package/dist/components/tooltip/lazy-tooltip.js +35 -0
- package/dist/components/tooltip/lazy-tooltip.js.map +1 -0
- package/dist/components/tooltip/tooltip-placement.d.ts +16 -0
- package/dist/components/tooltip/tooltip-placement.js +14 -0
- package/dist/components/tooltip/tooltip-placement.js.map +1 -0
- package/dist/components/tooltip/tooltip-styles.d.ts +142 -0
- package/dist/components/tooltip/tooltip-styles.js +81 -0
- package/dist/components/tooltip/tooltip-styles.js.map +1 -0
- package/dist/components/tooltip/tooltip-tokens.d.ts +9 -0
- package/dist/components/tooltip/tooltip-tokens.js +72 -0
- package/dist/components/tooltip/tooltip-tokens.js.map +1 -0
- package/dist/components/tooltip/tooltip-trigger.d.ts +42 -0
- package/dist/components/tooltip/tooltip-trigger.js +115 -0
- package/dist/components/tooltip/tooltip-trigger.js.map +1 -0
- package/dist/composites/button-group/ButtonGroup.d.ts +116 -0
- package/dist/composites/button-group/ButtonGroup.js +270 -0
- package/dist/composites/button-group/ButtonGroup.js.map +1 -0
- package/dist/composites/button-group/button-group-styles.d.ts +73 -0
- package/dist/composites/button-group/button-group-styles.js +87 -0
- package/dist/composites/button-group/button-group-styles.js.map +1 -0
- package/dist/composites/button-group/lazy-overflow-menu.js +43 -0
- package/dist/composites/button-group/lazy-overflow-menu.js.map +1 -0
- package/dist/composites/button-group/overflow-menu-list.js +26 -0
- package/dist/composites/button-group/overflow-menu-list.js.map +1 -0
- package/dist/composites/button-group/use-overflow.js +75 -0
- package/dist/composites/button-group/use-overflow.js.map +1 -0
- package/dist/composites/button-group/use-press-expansion.js +155 -0
- package/dist/composites/button-group/use-press-expansion.js.map +1 -0
- package/dist/index.d.ts +142 -0
- package/dist/index.js +136 -0
- package/dist/motion/get-m3-spring.d.ts +6 -0
- package/dist/motion/get-m3-spring.js +10 -0
- package/dist/motion/get-m3-spring.js.map +1 -0
- package/dist/motion/reduced-motion.js +19 -0
- package/dist/motion/reduced-motion.js.map +1 -0
- package/dist/motion/use-m3-spring.d.ts +13 -0
- package/dist/motion/use-m3-spring.js +22 -0
- package/dist/motion/use-m3-spring.js.map +1 -0
- package/dist/next/NextRouterProvider.d.ts +13 -0
- package/dist/next/NextRouterProvider.js +26 -0
- package/dist/next/NextRouterProvider.js.map +1 -0
- package/dist/next/get-theme-from-cookies.d.ts +32 -0
- package/dist/next/get-theme-from-cookies.js +27 -0
- package/dist/next/get-theme-from-cookies.js.map +1 -0
- package/dist/next/navigation-guard.d.ts +30 -0
- package/dist/next/navigation-guard.js +68 -0
- package/dist/next/navigation-guard.js.map +1 -0
- package/dist/next.d.ts +5 -0
- package/dist/next.js +5 -0
- package/dist/primitives/ButtonBase.d.ts +115 -0
- package/dist/primitives/ButtonBase.js +231 -0
- package/dist/primitives/ButtonBase.js.map +1 -0
- package/dist/primitives/DomDirectionLocale.d.ts +18 -0
- package/dist/primitives/DomDirectionLocale.js +28 -0
- package/dist/primitives/DomDirectionLocale.js.map +1 -0
- package/dist/primitives/Field.d.ts +50 -0
- package/dist/primitives/Field.js +74 -0
- package/dist/primitives/Field.js.map +1 -0
- package/dist/primitives/IconFaces.js +23 -0
- package/dist/primitives/IconFaces.js.map +1 -0
- package/dist/primitives/Overlay.d.ts +39 -0
- package/dist/primitives/Overlay.js +86 -0
- package/dist/primitives/Overlay.js.map +1 -0
- package/dist/primitives/SelectionControl.d.ts +55 -0
- package/dist/primitives/SelectionControl.js +58 -0
- package/dist/primitives/SelectionControl.js.map +1 -0
- package/dist/primitives/Surface.d.ts +123 -0
- package/dist/primitives/Surface.js +68 -0
- package/dist/primitives/Surface.js.map +1 -0
- package/dist/primitives/ToolbarContext.js +12 -0
- package/dist/primitives/ToolbarContext.js.map +1 -0
- package/dist/primitives/TouchTarget.d.ts +14 -0
- package/dist/primitives/TouchTarget.js +20 -0
- package/dist/primitives/TouchTarget.js.map +1 -0
- package/dist/primitives/TriggerContext.d.ts +34 -0
- package/dist/primitives/TriggerContext.js +24 -0
- package/dist/primitives/TriggerContext.js.map +1 -0
- package/dist/primitives/hidden-input-focus.js +27 -0
- package/dist/primitives/hidden-input-focus.js.map +1 -0
- package/dist/primitives/icon-faces-styles.d.ts +9 -0
- package/dist/primitives/icon-faces-styles.js +45 -0
- package/dist/primitives/icon-faces-styles.js.map +1 -0
- package/dist/primitives/locale-with-direction.d.ts +9 -0
- package/dist/primitives/locale-with-direction.js +17 -0
- package/dist/primitives/locale-with-direction.js.map +1 -0
- package/dist/primitives/morph-path.d.ts +25 -0
- package/dist/primitives/morph-path.js +38 -0
- package/dist/primitives/morph-path.js.map +1 -0
- package/dist/primitives/selection-control-styles.d.ts +54 -0
- package/dist/primitives/selection-control-styles.js +44 -0
- package/dist/primitives/selection-control-styles.js.map +1 -0
- package/dist/primitives/use-m3-interaction.d.ts +51 -0
- package/dist/primitives/use-m3-interaction.js +149 -0
- package/dist/primitives/use-m3-interaction.js.map +1 -0
- package/dist/primitives/use-m3-morph.d.ts +18 -0
- package/dist/primitives/use-m3-morph.js +36 -0
- package/dist/primitives/use-m3-morph.js.map +1 -0
- package/dist/primitives/use-presence.d.ts +19 -0
- package/dist/primitives/use-presence.js +37 -0
- package/dist/primitives/use-presence.js.map +1 -0
- package/dist/primitives.d.ts +36 -0
- package/dist/primitives.js +34 -0
- package/dist/shapes/corner-rounding.d.ts +13 -0
- package/dist/shapes/corner-rounding.js +18 -0
- package/dist/shapes/corner-rounding.js.map +1 -0
- package/dist/shapes/cubic.d.ts +52 -0
- package/dist/shapes/cubic.js +189 -0
- package/dist/shapes/cubic.js.map +1 -0
- package/dist/shapes/feature-mapping.js +80 -0
- package/dist/shapes/feature-mapping.js.map +1 -0
- package/dist/shapes/features.d.ts +23 -0
- package/dist/shapes/features.js +82 -0
- package/dist/shapes/features.js.map +1 -0
- package/dist/shapes/float-mapping.js +65 -0
- package/dist/shapes/float-mapping.js.map +1 -0
- package/dist/shapes/generated/material-shape-path-record.d.ts +11 -0
- package/dist/shapes/generated/material-shape-path-record.js +48 -0
- package/dist/shapes/generated/material-shape-path-record.js.map +1 -0
- package/dist/shapes/generated/material-shape-paths.d.ts +78 -0
- package/dist/shapes/generated/material-shape-paths.js +218 -0
- package/dist/shapes/generated/material-shape-paths.js.map +1 -0
- package/dist/shapes/mask.d.ts +14 -0
- package/dist/shapes/mask.js +24 -0
- package/dist/shapes/mask.js.map +1 -0
- package/dist/shapes/material-shapes.d.ts +11 -0
- package/dist/shapes/material-shapes.js +250 -0
- package/dist/shapes/material-shapes.js.map +1 -0
- package/dist/shapes/morph.d.ts +25 -0
- package/dist/shapes/morph.js +97 -0
- package/dist/shapes/morph.js.map +1 -0
- package/dist/shapes/path.d.ts +33 -0
- package/dist/shapes/path.js +47 -0
- package/dist/shapes/path.js.map +1 -0
- package/dist/shapes/point.d.ts +28 -0
- package/dist/shapes/point.js +103 -0
- package/dist/shapes/point.js.map +1 -0
- package/dist/shapes/polygon-measure.js +140 -0
- package/dist/shapes/polygon-measure.js.map +1 -0
- package/dist/shapes/rounded-polygon.d.ts +44 -0
- package/dist/shapes/rounded-polygon.js +278 -0
- package/dist/shapes/rounded-polygon.js.map +1 -0
- package/dist/shapes/shape-path.d.ts +15 -0
- package/dist/shapes/shapes.d.ts +53 -0
- package/dist/shapes/shapes.js +171 -0
- package/dist/shapes/shapes.js.map +1 -0
- package/dist/styles/generated/components.css +710 -0
- package/dist/styles/generated/theme.css +247 -0
- package/dist/styles/generated/themes.css +3361 -0
- package/dist/styles/generated/tokens.css +284 -0
- package/dist/styles/styles.css +15 -0
- package/dist/styles/utilities.css +283 -0
- package/dist/styles.compiled.css +2 -0
- package/dist/theme/ThemeProvider.d.ts +72 -0
- package/dist/theme/ThemeProvider.js +144 -0
- package/dist/theme/ThemeProvider.js.map +1 -0
- package/dist/theme/ThemeScope.d.ts +32 -0
- package/dist/theme/ThemeScope.js +67 -0
- package/dist/theme/ThemeScope.js.map +1 -0
- package/dist/theme/ThemeScript.d.ts +26 -0
- package/dist/theme/ThemeScript.js +44 -0
- package/dist/theme/ThemeScript.js.map +1 -0
- package/dist/theme/context.d.ts +32 -0
- package/dist/theme/context.js +47 -0
- package/dist/theme/context.js.map +1 -0
- package/dist/theme/create-theme.d.ts +60 -0
- package/dist/theme/create-theme.js +47 -0
- package/dist/theme/create-theme.js.map +1 -0
- package/dist/theme/css.js +54 -0
- package/dist/theme/css.js.map +1 -0
- package/dist/theme/parse-palettes.js +40 -0
- package/dist/theme/parse-palettes.js.map +1 -0
- package/dist/theme/scheme.d.ts +6 -0
- package/dist/theme/scheme.js +118 -0
- package/dist/theme/scheme.js.map +1 -0
- package/dist/theme/state.d.ts +38 -0
- package/dist/theme/state.js +93 -0
- package/dist/theme/state.js.map +1 -0
- package/dist/theme/storage.js +21 -0
- package/dist/theme/storage.js.map +1 -0
- package/dist/tokens/breakpoints.d.ts +15 -0
- package/dist/tokens/breakpoints.js +16 -0
- package/dist/tokens/breakpoints.js.map +1 -0
- package/dist/tokens/color.d.ts +104 -0
- package/dist/tokens/color.js +147 -0
- package/dist/tokens/color.js.map +1 -0
- package/dist/tokens/component.d.ts +110 -0
- package/dist/tokens/component.js +67 -0
- package/dist/tokens/component.js.map +1 -0
- package/dist/tokens/density.d.ts +20 -0
- package/dist/tokens/density.js +27 -0
- package/dist/tokens/density.js.map +1 -0
- package/dist/tokens/elevation.d.ts +44 -0
- package/dist/tokens/elevation.js +45 -0
- package/dist/tokens/elevation.js.map +1 -0
- package/dist/tokens/motion.d.ts +79 -0
- package/dist/tokens/motion.js +126 -0
- package/dist/tokens/motion.js.map +1 -0
- package/dist/tokens/shape.d.ts +22 -0
- package/dist/tokens/shape.js +22 -0
- package/dist/tokens/shape.js.map +1 -0
- package/dist/tokens/spring-velocity.d.ts +19 -0
- package/dist/tokens/spring-velocity.js +44 -0
- package/dist/tokens/spring-velocity.js.map +1 -0
- package/dist/tokens/state.d.ts +18 -0
- package/dist/tokens/state.js +19 -0
- package/dist/tokens/state.js.map +1 -0
- package/dist/tokens/typography.d.ts +64 -0
- package/dist/tokens/typography.js +60 -0
- package/dist/tokens/typography.js.map +1 -0
- package/dist/tokens/z-index.d.ts +17 -0
- package/dist/tokens/z-index.js +18 -0
- package/dist/tokens/z-index.js.map +1 -0
- package/dist/utils/announce.js +51 -0
- package/dist/utils/announce.js.map +1 -0
- package/dist/utils/assert-collection-children.js +26 -0
- package/dist/utils/assert-collection-children.js.map +1 -0
- package/dist/utils/closed-by.d.ts +9 -0
- package/dist/utils/closed-by.js +12 -0
- package/dist/utils/closed-by.js.map +1 -0
- package/dist/utils/cn.d.ts +31 -0
- package/dist/utils/cn.js +37 -0
- package/dist/utils/cn.js.map +1 -0
- package/dist/utils/composite-keys.js +32 -0
- package/dist/utils/composite-keys.js.map +1 -0
- package/dist/utils/focus-visible.js +14 -0
- package/dist/utils/focus-visible.js.map +1 -0
- package/dist/utils/focus.js +51 -0
- package/dist/utils/focus.js.map +1 -0
- package/dist/utils/focusable-disabled.js +12 -0
- package/dist/utils/focusable-disabled.js.map +1 -0
- package/dist/utils/keep-pressed-in-place.d.ts +60 -0
- package/dist/utils/keep-pressed-in-place.js +127 -0
- package/dist/utils/keep-pressed-in-place.js.map +1 -0
- package/dist/utils/load-on-demand.js +111 -0
- package/dist/utils/load-on-demand.js.map +1 -0
- package/dist/utils/merge-data-tokens.d.ts +9 -0
- package/dist/utils/merge-data-tokens.js +15 -0
- package/dist/utils/merge-data-tokens.js.map +1 -0
- package/dist/utils/natural-size.js +53 -0
- package/dist/utils/natural-size.js.map +1 -0
- package/dist/utils/nearest-reveal.js +28 -0
- package/dist/utils/nearest-reveal.js.map +1 -0
- package/dist/utils/placement.js +14 -0
- package/dist/utils/placement.js.map +1 -0
- package/dist/utils/radio-group-keys.js +74 -0
- package/dist/utils/radio-group-keys.js.map +1 -0
- package/dist/utils/rendered-description.js +17 -0
- package/dist/utils/rendered-description.js.map +1 -0
- package/dist/utils/root-props.d.ts +103 -0
- package/dist/utils/root-props.js +51 -0
- package/dist/utils/root-props.js.map +1 -0
- package/dist/utils/search.d.ts +11 -0
- package/dist/utils/search.js +18 -0
- package/dist/utils/search.js.map +1 -0
- package/dist/utils/shortcut.js +20 -0
- package/dist/utils/shortcut.js.map +1 -0
- package/dist/utils/split-data-attributes.d.ts +12 -0
- package/dist/utils/split-data-attributes.js +20 -0
- package/dist/utils/split-data-attributes.js.map +1 -0
- package/dist/utils/toolbar-keys.js +28 -0
- package/dist/utils/toolbar-keys.js.map +1 -0
- package/dist/utils/tv.d.ts +7 -0
- package/dist/utils/tv.js +9 -0
- package/dist/utils/tv.js.map +1 -0
- package/dist/utils/typeahead.js +64 -0
- package/dist/utils/typeahead.js.map +1 -0
- package/dist/utils/warn-once.js +30 -0
- package/dist/utils/warn-once.js.map +1 -0
- package/dist/vendor/material-color-utilities/blend/blend.js +88 -0
- package/dist/vendor/material-color-utilities/blend/blend.js.map +1 -0
- package/dist/vendor/material-color-utilities/contrast/contrast.js +131 -0
- package/dist/vendor/material-color-utilities/contrast/contrast.js.map +1 -0
- package/dist/vendor/material-color-utilities/dislike/dislike_analyzer.js +58 -0
- package/dist/vendor/material-color-utilities/dislike/dislike_analyzer.js.map +1 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/color_spec_2021.js +620 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/color_spec_2021.js.map +1 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/color_spec_2025.js +786 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/color_spec_2025.js.map +1 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/contrast_curve.js +59 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/contrast_curve.js.map +1 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/dynamic_color.js +420 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/dynamic_color.js.map +1 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/dynamic_scheme.js +701 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/dynamic_scheme.js.map +1 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/material_dynamic_colors.js +374 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/material_dynamic_colors.js.map +1 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/tone_delta_pair.js +65 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/tone_delta_pair.js.map +1 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/variant.js +38 -0
- package/dist/vendor/material-color-utilities/dynamiccolor/variant.js.map +1 -0
- package/dist/vendor/material-color-utilities/hct/cam16.js +309 -0
- package/dist/vendor/material-color-utilities/hct/cam16.js.map +1 -0
- package/dist/vendor/material-color-utilities/hct/hct.js +148 -0
- package/dist/vendor/material-color-utilities/hct/hct.js.map +1 -0
- package/dist/vendor/material-color-utilities/hct/hct_solver.js +660 -0
- package/dist/vendor/material-color-utilities/hct/hct_solver.js.map +1 -0
- package/dist/vendor/material-color-utilities/hct/viewing_conditions.js +117 -0
- package/dist/vendor/material-color-utilities/hct/viewing_conditions.js.map +1 -0
- package/dist/vendor/material-color-utilities/index.js +51 -0
- package/dist/vendor/material-color-utilities/index.js.map +1 -0
- package/dist/vendor/material-color-utilities/palettes/core_palette.js +22 -0
- package/dist/vendor/material-color-utilities/palettes/core_palette.js.map +1 -0
- package/dist/vendor/material-color-utilities/palettes/tonal_palette.js +134 -0
- package/dist/vendor/material-color-utilities/palettes/tonal_palette.js.map +1 -0
- package/dist/vendor/material-color-utilities/scheme/scheme.js +21 -0
- package/dist/vendor/material-color-utilities/scheme/scheme.js.map +1 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_android.js +21 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_android.js.map +1 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_content.js +22 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_content.js.map +1 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_expressive.js +38 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_expressive.js.map +1 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_fidelity.js +22 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_fidelity.js.map +1 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_fruit_salad.js +22 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_fruit_salad.js.map +1 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_monochrome.js +22 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_monochrome.js.map +1 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_neutral.js +36 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_neutral.js.map +1 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_rainbow.js +22 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_rainbow.js.map +1 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_tonal_spot.js +41 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_tonal_spot.js.map +1 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_vibrant.js +39 -0
- package/dist/vendor/material-color-utilities/scheme/scheme_vibrant.js.map +1 -0
- package/dist/vendor/material-color-utilities/score/score.js +115 -0
- package/dist/vendor/material-color-utilities/score/score.js.map +1 -0
- package/dist/vendor/material-color-utilities/temperature/temperature_cache.js +227 -0
- package/dist/vendor/material-color-utilities/temperature/temperature_cache.js.map +1 -0
- package/dist/vendor/material-color-utilities/utils/color_utils.js +246 -0
- package/dist/vendor/material-color-utilities/utils/color_utils.js.map +1 -0
- package/dist/vendor/material-color-utilities/utils/image_utils.js +21 -0
- package/dist/vendor/material-color-utilities/utils/image_utils.js.map +1 -0
- package/dist/vendor/material-color-utilities/utils/math_utils.js +119 -0
- package/dist/vendor/material-color-utilities/utils/math_utils.js.map +1 -0
- package/dist/vendor/material-color-utilities/utils/string_utils.js +74 -0
- package/dist/vendor/material-color-utilities/utils/string_utils.js.map +1 -0
- package/dist/vendor/material-color-utilities/utils/theme_utils.js +24 -0
- package/dist/vendor/material-color-utilities/utils/theme_utils.js.map +1 -0
- package/package.json +114 -3
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import "../dynamiccolor/variant.js";
|
|
2
|
+
import "../dynamiccolor/dynamic_scheme.js";
|
|
3
|
+
//#region ../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/scheme/scheme_fidelity.js
|
|
4
|
+
/**
|
|
5
|
+
* @license
|
|
6
|
+
* Copyright 2023 Google LLC
|
|
7
|
+
*
|
|
8
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9
|
+
* you may not use this file except in compliance with the License.
|
|
10
|
+
* You may obtain a copy of the License at
|
|
11
|
+
*
|
|
12
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
13
|
+
*
|
|
14
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
15
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
16
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
17
|
+
* See the License for the specific language governing permissions and
|
|
18
|
+
* limitations under the License.
|
|
19
|
+
*/
|
|
20
|
+
//#endregion
|
|
21
|
+
|
|
22
|
+
//# sourceMappingURL=scheme_fidelity.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scheme_fidelity.js","names":[],"sources":["../../../../../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/scheme/scheme_fidelity.js"],"sourcesContent":["/**\n * @license\n * Copyright 2023 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { DynamicScheme } from '../dynamiccolor/dynamic_scheme';\nimport { Variant } from '../dynamiccolor/variant.js';\n/**\n * A scheme that places the source color in `Scheme.primaryContainer`.\n *\n * Primary Container is the source color, adjusted for color relativity.\n * It maintains constant appearance in light mode and dark mode.\n * This adds ~5 tone in light mode, and subtracts ~5 tone in dark mode.\n * Tertiary Container is the complement to the source color, using\n * `TemperatureCache`. It also maintains constant appearance.\n */\nexport class SchemeFidelity extends DynamicScheme {\n constructor(sourceColorHct, isDark, contrastLevel, specVersion = DynamicScheme.DEFAULT_SPEC_VERSION, platform = DynamicScheme.DEFAULT_PLATFORM) {\n super({\n sourceColorHct,\n variant: Variant.FIDELITY,\n contrastLevel,\n isDark,\n platform,\n specVersion,\n });\n }\n}\n//# sourceMappingURL=scheme_fidelity.js.map"],"ignoreList":[0],"mappings":""}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import "../dynamiccolor/variant.js";
|
|
2
|
+
import "../dynamiccolor/dynamic_scheme.js";
|
|
3
|
+
//#region ../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/scheme/scheme_fruit_salad.js
|
|
4
|
+
/**
|
|
5
|
+
* @license
|
|
6
|
+
* Copyright 2022 Google LLC
|
|
7
|
+
*
|
|
8
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9
|
+
* you may not use this file except in compliance with the License.
|
|
10
|
+
* You may obtain a copy of the License at
|
|
11
|
+
*
|
|
12
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
13
|
+
*
|
|
14
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
15
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
16
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
17
|
+
* See the License for the specific language governing permissions and
|
|
18
|
+
* limitations under the License.
|
|
19
|
+
*/
|
|
20
|
+
//#endregion
|
|
21
|
+
|
|
22
|
+
//# sourceMappingURL=scheme_fruit_salad.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scheme_fruit_salad.js","names":[],"sources":["../../../../../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/scheme/scheme_fruit_salad.js"],"sourcesContent":["/**\n * @license\n * Copyright 2022 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { DynamicScheme } from '../dynamiccolor/dynamic_scheme';\nimport { Variant } from '../dynamiccolor/variant.js';\n/**\n * A playful theme - the source color's hue does not appear in the theme.\n */\nexport class SchemeFruitSalad extends DynamicScheme {\n constructor(sourceColorHct, isDark, contrastLevel, specVersion = DynamicScheme.DEFAULT_SPEC_VERSION, platform = DynamicScheme.DEFAULT_PLATFORM) {\n super({\n sourceColorHct,\n variant: Variant.FRUIT_SALAD,\n contrastLevel,\n isDark,\n platform,\n specVersion,\n });\n }\n}\n//# sourceMappingURL=scheme_fruit_salad.js.map"],"ignoreList":[0],"mappings":""}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import "../dynamiccolor/variant.js";
|
|
2
|
+
import "../dynamiccolor/dynamic_scheme.js";
|
|
3
|
+
//#region ../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/scheme/scheme_monochrome.js
|
|
4
|
+
/**
|
|
5
|
+
* @license
|
|
6
|
+
* Copyright 2022 Google LLC
|
|
7
|
+
*
|
|
8
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9
|
+
* you may not use this file except in compliance with the License.
|
|
10
|
+
* You may obtain a copy of the License at
|
|
11
|
+
*
|
|
12
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
13
|
+
*
|
|
14
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
15
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
16
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
17
|
+
* See the License for the specific language governing permissions and
|
|
18
|
+
* limitations under the License.
|
|
19
|
+
*/
|
|
20
|
+
//#endregion
|
|
21
|
+
|
|
22
|
+
//# sourceMappingURL=scheme_monochrome.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scheme_monochrome.js","names":[],"sources":["../../../../../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/scheme/scheme_monochrome.js"],"sourcesContent":["/**\n * @license\n * Copyright 2022 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { DynamicScheme } from '../dynamiccolor/dynamic_scheme';\nimport { Variant } from '../dynamiccolor/variant.js';\n/** A Dynamic Color theme that is grayscale. */\nexport class SchemeMonochrome extends DynamicScheme {\n constructor(sourceColorHct, isDark, contrastLevel, specVersion = DynamicScheme.DEFAULT_SPEC_VERSION, platform = DynamicScheme.DEFAULT_PLATFORM) {\n super({\n sourceColorHct,\n variant: Variant.MONOCHROME,\n contrastLevel,\n isDark,\n platform,\n specVersion,\n });\n }\n}\n//# sourceMappingURL=scheme_monochrome.js.map"],"ignoreList":[0],"mappings":""}
|
|
@@ -0,0 +1,36 @@
|
|
|
1
|
+
import { Variant } from "../dynamiccolor/variant.js";
|
|
2
|
+
import { DynamicScheme } from "../dynamiccolor/dynamic_scheme.js";
|
|
3
|
+
//#region ../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/scheme/scheme_neutral.js
|
|
4
|
+
/**
|
|
5
|
+
* @license
|
|
6
|
+
* Copyright 2022 Google LLC
|
|
7
|
+
*
|
|
8
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9
|
+
* you may not use this file except in compliance with the License.
|
|
10
|
+
* You may obtain a copy of the License at
|
|
11
|
+
*
|
|
12
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
13
|
+
*
|
|
14
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
15
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
16
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
17
|
+
* See the License for the specific language governing permissions and
|
|
18
|
+
* limitations under the License.
|
|
19
|
+
*/
|
|
20
|
+
/** A Dynamic Color theme that is near grayscale. */
|
|
21
|
+
var SchemeNeutral = class extends DynamicScheme {
|
|
22
|
+
constructor(sourceColorHct, isDark, contrastLevel, specVersion = DynamicScheme.DEFAULT_SPEC_VERSION, platform = DynamicScheme.DEFAULT_PLATFORM) {
|
|
23
|
+
super({
|
|
24
|
+
sourceColorHct,
|
|
25
|
+
variant: Variant.NEUTRAL,
|
|
26
|
+
contrastLevel,
|
|
27
|
+
isDark,
|
|
28
|
+
platform,
|
|
29
|
+
specVersion
|
|
30
|
+
});
|
|
31
|
+
}
|
|
32
|
+
};
|
|
33
|
+
//#endregion
|
|
34
|
+
export { SchemeNeutral };
|
|
35
|
+
|
|
36
|
+
//# sourceMappingURL=scheme_neutral.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scheme_neutral.js","names":[],"sources":["../../../../../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/scheme/scheme_neutral.js"],"sourcesContent":["/**\n * @license\n * Copyright 2022 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { DynamicScheme } from '../dynamiccolor/dynamic_scheme';\nimport { Variant } from '../dynamiccolor/variant.js';\n/** A Dynamic Color theme that is near grayscale. */\nexport class SchemeNeutral extends DynamicScheme {\n constructor(sourceColorHct, isDark, contrastLevel, specVersion = DynamicScheme.DEFAULT_SPEC_VERSION, platform = DynamicScheme.DEFAULT_PLATFORM) {\n super({\n sourceColorHct,\n variant: Variant.NEUTRAL,\n contrastLevel,\n isDark,\n platform,\n specVersion,\n });\n }\n}\n//# sourceMappingURL=scheme_neutral.js.map"],"ignoreList":[0],"mappings":";;;;;;;;;;;;;;;;;;;;AAmBA,IAAa,gBAAb,cAAmC,cAAc;CAC7C,YAAY,gBAAgB,QAAQ,eAAe,cAAc,cAAc,sBAAsB,WAAW,cAAc,kBAAkB;EAC5I,MAAM;GACF;GACA,SAAS,QAAQ;GACjB;GACA;GACA;GACA;EACJ,CAAC;CACL;AACJ"}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
import "../dynamiccolor/variant.js";
|
|
2
|
+
import "../dynamiccolor/dynamic_scheme.js";
|
|
3
|
+
//#region ../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/scheme/scheme_rainbow.js
|
|
4
|
+
/**
|
|
5
|
+
* @license
|
|
6
|
+
* Copyright 2022 Google LLC
|
|
7
|
+
*
|
|
8
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9
|
+
* you may not use this file except in compliance with the License.
|
|
10
|
+
* You may obtain a copy of the License at
|
|
11
|
+
*
|
|
12
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
13
|
+
*
|
|
14
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
15
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
16
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
17
|
+
* See the License for the specific language governing permissions and
|
|
18
|
+
* limitations under the License.
|
|
19
|
+
*/
|
|
20
|
+
//#endregion
|
|
21
|
+
|
|
22
|
+
//# sourceMappingURL=scheme_rainbow.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scheme_rainbow.js","names":[],"sources":["../../../../../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/scheme/scheme_rainbow.js"],"sourcesContent":["/**\n * @license\n * Copyright 2022 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { DynamicScheme } from '../dynamiccolor/dynamic_scheme';\nimport { Variant } from '../dynamiccolor/variant.js';\n/**\n * A playful theme - the source color's hue does not appear in the theme.\n */\nexport class SchemeRainbow extends DynamicScheme {\n constructor(sourceColorHct, isDark, contrastLevel, specVersion = DynamicScheme.DEFAULT_SPEC_VERSION, platform = DynamicScheme.DEFAULT_PLATFORM) {\n super({\n sourceColorHct,\n variant: Variant.RAINBOW,\n contrastLevel,\n isDark,\n platform,\n specVersion,\n });\n }\n}\n//# sourceMappingURL=scheme_rainbow.js.map"],"ignoreList":[0],"mappings":""}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import { Variant } from "../dynamiccolor/variant.js";
|
|
2
|
+
import { DynamicScheme } from "../dynamiccolor/dynamic_scheme.js";
|
|
3
|
+
//#region ../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/scheme/scheme_tonal_spot.js
|
|
4
|
+
/**
|
|
5
|
+
* @license
|
|
6
|
+
* Copyright 2022 Google LLC
|
|
7
|
+
*
|
|
8
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9
|
+
* you may not use this file except in compliance with the License.
|
|
10
|
+
* You may obtain a copy of the License at
|
|
11
|
+
*
|
|
12
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
13
|
+
*
|
|
14
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
15
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
16
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
17
|
+
* See the License for the specific language governing permissions and
|
|
18
|
+
* limitations under the License.
|
|
19
|
+
*/
|
|
20
|
+
/**
|
|
21
|
+
* A Dynamic Color theme with low to medium colorfulness and a Tertiary
|
|
22
|
+
* TonalPalette with a hue related to the source color.
|
|
23
|
+
*
|
|
24
|
+
* The default Material You theme on Android 12 and 13.
|
|
25
|
+
*/
|
|
26
|
+
var SchemeTonalSpot = class extends DynamicScheme {
|
|
27
|
+
constructor(sourceColorHct, isDark, contrastLevel, specVersion = DynamicScheme.DEFAULT_SPEC_VERSION, platform = DynamicScheme.DEFAULT_PLATFORM) {
|
|
28
|
+
super({
|
|
29
|
+
sourceColorHct,
|
|
30
|
+
variant: Variant.TONAL_SPOT,
|
|
31
|
+
contrastLevel,
|
|
32
|
+
isDark,
|
|
33
|
+
platform,
|
|
34
|
+
specVersion
|
|
35
|
+
});
|
|
36
|
+
}
|
|
37
|
+
};
|
|
38
|
+
//#endregion
|
|
39
|
+
export { SchemeTonalSpot };
|
|
40
|
+
|
|
41
|
+
//# sourceMappingURL=scheme_tonal_spot.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scheme_tonal_spot.js","names":[],"sources":["../../../../../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/scheme/scheme_tonal_spot.js"],"sourcesContent":["/**\n * @license\n * Copyright 2022 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { DynamicScheme } from '../dynamiccolor/dynamic_scheme';\nimport { Variant } from '../dynamiccolor/variant.js';\n/**\n * A Dynamic Color theme with low to medium colorfulness and a Tertiary\n * TonalPalette with a hue related to the source color.\n *\n * The default Material You theme on Android 12 and 13.\n */\nexport class SchemeTonalSpot extends DynamicScheme {\n constructor(sourceColorHct, isDark, contrastLevel, specVersion = DynamicScheme.DEFAULT_SPEC_VERSION, platform = DynamicScheme.DEFAULT_PLATFORM) {\n super({\n sourceColorHct,\n variant: Variant.TONAL_SPOT,\n contrastLevel,\n isDark,\n platform,\n specVersion,\n });\n }\n}\n//# sourceMappingURL=scheme_tonal_spot.js.map"],"ignoreList":[0],"mappings":";;;;;;;;;;;;;;;;;;;;;;;;;AAwBA,IAAa,kBAAb,cAAqC,cAAc;CAC/C,YAAY,gBAAgB,QAAQ,eAAe,cAAc,cAAc,sBAAsB,WAAW,cAAc,kBAAkB;EAC5I,MAAM;GACF;GACA,SAAS,QAAQ;GACjB;GACA;GACA;GACA;EACJ,CAAC;CACL;AACJ"}
|
|
@@ -0,0 +1,39 @@
|
|
|
1
|
+
import { Variant } from "../dynamiccolor/variant.js";
|
|
2
|
+
import { DynamicScheme } from "../dynamiccolor/dynamic_scheme.js";
|
|
3
|
+
//#region ../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/scheme/scheme_vibrant.js
|
|
4
|
+
/**
|
|
5
|
+
* @license
|
|
6
|
+
* Copyright 2022 Google LLC
|
|
7
|
+
*
|
|
8
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9
|
+
* you may not use this file except in compliance with the License.
|
|
10
|
+
* You may obtain a copy of the License at
|
|
11
|
+
*
|
|
12
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
13
|
+
*
|
|
14
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
15
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
16
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
17
|
+
* See the License for the specific language governing permissions and
|
|
18
|
+
* limitations under the License.
|
|
19
|
+
*/
|
|
20
|
+
/**
|
|
21
|
+
* A Dynamic Color theme that maxes out colorfulness at each position in the
|
|
22
|
+
* Primary Tonal Palette.
|
|
23
|
+
*/
|
|
24
|
+
var SchemeVibrant = class extends DynamicScheme {
|
|
25
|
+
constructor(sourceColorHct, isDark, contrastLevel, specVersion = DynamicScheme.DEFAULT_SPEC_VERSION, platform = DynamicScheme.DEFAULT_PLATFORM) {
|
|
26
|
+
super({
|
|
27
|
+
sourceColorHct,
|
|
28
|
+
variant: Variant.VIBRANT,
|
|
29
|
+
contrastLevel,
|
|
30
|
+
isDark,
|
|
31
|
+
platform,
|
|
32
|
+
specVersion
|
|
33
|
+
});
|
|
34
|
+
}
|
|
35
|
+
};
|
|
36
|
+
//#endregion
|
|
37
|
+
export { SchemeVibrant };
|
|
38
|
+
|
|
39
|
+
//# sourceMappingURL=scheme_vibrant.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"scheme_vibrant.js","names":[],"sources":["../../../../../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/scheme/scheme_vibrant.js"],"sourcesContent":["/**\n * @license\n * Copyright 2022 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { DynamicScheme } from '../dynamiccolor/dynamic_scheme';\nimport { Variant } from '../dynamiccolor/variant.js';\n/**\n * A Dynamic Color theme that maxes out colorfulness at each position in the\n * Primary Tonal Palette.\n */\nexport class SchemeVibrant extends DynamicScheme {\n constructor(sourceColorHct, isDark, contrastLevel, specVersion = DynamicScheme.DEFAULT_SPEC_VERSION, platform = DynamicScheme.DEFAULT_PLATFORM) {\n super({\n sourceColorHct,\n variant: Variant.VIBRANT,\n contrastLevel,\n isDark,\n platform,\n specVersion,\n });\n }\n}\n//# sourceMappingURL=scheme_vibrant.js.map"],"ignoreList":[0],"mappings":";;;;;;;;;;;;;;;;;;;;;;;AAsBA,IAAa,gBAAb,cAAmC,cAAc;CAC7C,YAAY,gBAAgB,QAAQ,eAAe,cAAc,cAAc,sBAAsB,WAAW,cAAc,kBAAkB;EAC5I,MAAM;GACF;GACA,SAAS,QAAQ;GACjB;GACA;GACA;GACA;EACJ,CAAC;CACL;AACJ"}
|
|
@@ -0,0 +1,115 @@
|
|
|
1
|
+
import { differenceDegrees, sanitizeDegreesInt } from "../utils/math_utils.js";
|
|
2
|
+
import { Hct } from "../hct/hct.js";
|
|
3
|
+
//#region ../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/score/score.js
|
|
4
|
+
/**
|
|
5
|
+
* @license
|
|
6
|
+
* Copyright 2021 Google LLC
|
|
7
|
+
*
|
|
8
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
9
|
+
* you may not use this file except in compliance with the License.
|
|
10
|
+
* You may obtain a copy of the License at
|
|
11
|
+
*
|
|
12
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
13
|
+
*
|
|
14
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
15
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
16
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
17
|
+
* See the License for the specific language governing permissions and
|
|
18
|
+
* limitations under the License.
|
|
19
|
+
*/
|
|
20
|
+
const SCORE_OPTION_DEFAULTS = {
|
|
21
|
+
desired: 4,
|
|
22
|
+
fallbackColorARGB: 4282549748,
|
|
23
|
+
filter: true
|
|
24
|
+
};
|
|
25
|
+
function compare(a, b) {
|
|
26
|
+
if (a.score > b.score) return -1;
|
|
27
|
+
else if (a.score < b.score) return 1;
|
|
28
|
+
return 0;
|
|
29
|
+
}
|
|
30
|
+
/**
|
|
31
|
+
* Given a large set of colors, remove colors that are unsuitable for a UI
|
|
32
|
+
* theme, and rank the rest based on suitability.
|
|
33
|
+
*
|
|
34
|
+
* Enables use of a high cluster count for image quantization, thus ensuring
|
|
35
|
+
* colors aren't muddied, while curating the high cluster count to a much
|
|
36
|
+
* smaller number of appropriate choices.
|
|
37
|
+
*/
|
|
38
|
+
var Score = class Score {
|
|
39
|
+
constructor() {}
|
|
40
|
+
/**
|
|
41
|
+
* Given a map with keys of colors and values of how often the color appears,
|
|
42
|
+
* rank the colors based on suitability for being used for a UI theme.
|
|
43
|
+
*
|
|
44
|
+
* @param colorsToPopulation map with keys of colors and values of how often
|
|
45
|
+
* the color appears, usually from a source image.
|
|
46
|
+
* @param {ScoreOptions} options optional parameters.
|
|
47
|
+
* @return Colors sorted by suitability for a UI theme. The most suitable
|
|
48
|
+
* color is the first item, the least suitable is the last. There will
|
|
49
|
+
* always be at least one color returned. If all the input colors
|
|
50
|
+
* were not suitable for a theme, a default fallback color will be
|
|
51
|
+
* provided, Google Blue.
|
|
52
|
+
*/
|
|
53
|
+
static score(colorsToPopulation, options) {
|
|
54
|
+
const { desired, fallbackColorARGB, filter } = {
|
|
55
|
+
...SCORE_OPTION_DEFAULTS,
|
|
56
|
+
...options
|
|
57
|
+
};
|
|
58
|
+
const colorsHct = [];
|
|
59
|
+
const huePopulation = new Array(360).fill(0);
|
|
60
|
+
let populationSum = 0;
|
|
61
|
+
for (const [argb, population] of colorsToPopulation.entries()) {
|
|
62
|
+
const hct = Hct.fromInt(argb);
|
|
63
|
+
colorsHct.push(hct);
|
|
64
|
+
const hue = Math.floor(hct.hue);
|
|
65
|
+
huePopulation[hue] += population;
|
|
66
|
+
populationSum += population;
|
|
67
|
+
}
|
|
68
|
+
const hueExcitedProportions = new Array(360).fill(0);
|
|
69
|
+
for (let hue = 0; hue < 360; hue++) {
|
|
70
|
+
const proportion = huePopulation[hue] / populationSum;
|
|
71
|
+
for (let i = hue - 14; i < hue + 16; i++) {
|
|
72
|
+
const neighborHue = sanitizeDegreesInt(i);
|
|
73
|
+
hueExcitedProportions[neighborHue] += proportion;
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
const scoredHct = new Array();
|
|
77
|
+
for (const hct of colorsHct) {
|
|
78
|
+
const proportion = hueExcitedProportions[sanitizeDegreesInt(Math.round(hct.hue))];
|
|
79
|
+
if (filter && (hct.chroma < Score.CUTOFF_CHROMA || proportion <= Score.CUTOFF_EXCITED_PROPORTION)) continue;
|
|
80
|
+
const proportionScore = proportion * 100 * Score.WEIGHT_PROPORTION;
|
|
81
|
+
const chromaWeight = hct.chroma < Score.TARGET_CHROMA ? Score.WEIGHT_CHROMA_BELOW : Score.WEIGHT_CHROMA_ABOVE;
|
|
82
|
+
const score = proportionScore + (hct.chroma - Score.TARGET_CHROMA) * chromaWeight;
|
|
83
|
+
scoredHct.push({
|
|
84
|
+
hct,
|
|
85
|
+
score
|
|
86
|
+
});
|
|
87
|
+
}
|
|
88
|
+
scoredHct.sort(compare);
|
|
89
|
+
const chosenColors = [];
|
|
90
|
+
for (let differenceDegrees$1 = 90; differenceDegrees$1 >= 15; differenceDegrees$1--) {
|
|
91
|
+
chosenColors.length = 0;
|
|
92
|
+
for (const { hct } of scoredHct) {
|
|
93
|
+
if (!chosenColors.find((chosenHct) => {
|
|
94
|
+
return differenceDegrees(hct.hue, chosenHct.hue) < differenceDegrees$1;
|
|
95
|
+
})) chosenColors.push(hct);
|
|
96
|
+
if (chosenColors.length >= desired) break;
|
|
97
|
+
}
|
|
98
|
+
if (chosenColors.length >= desired) break;
|
|
99
|
+
}
|
|
100
|
+
const colors = [];
|
|
101
|
+
if (chosenColors.length === 0) colors.push(fallbackColorARGB);
|
|
102
|
+
for (const chosenHct of chosenColors) colors.push(chosenHct.toInt());
|
|
103
|
+
return colors;
|
|
104
|
+
}
|
|
105
|
+
};
|
|
106
|
+
Score.TARGET_CHROMA = 48;
|
|
107
|
+
Score.WEIGHT_PROPORTION = .7;
|
|
108
|
+
Score.WEIGHT_CHROMA_ABOVE = .3;
|
|
109
|
+
Score.WEIGHT_CHROMA_BELOW = .1;
|
|
110
|
+
Score.CUTOFF_CHROMA = 5;
|
|
111
|
+
Score.CUTOFF_EXCITED_PROPORTION = .01;
|
|
112
|
+
//#endregion
|
|
113
|
+
export { Score };
|
|
114
|
+
|
|
115
|
+
//# sourceMappingURL=score.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"score.js","names":["math.sanitizeDegreesInt","differenceDegrees","math.differenceDegrees"],"sources":["../../../../../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/score/score.js"],"sourcesContent":["/**\n * @license\n * Copyright 2021 Google LLC\n *\n * Licensed under the Apache License, Version 2.0 (the \"License\");\n * you may not use this file except in compliance with the License.\n * You may obtain a copy of the License at\n *\n * http://www.apache.org/licenses/LICENSE-2.0\n *\n * Unless required by applicable law or agreed to in writing, software\n * distributed under the License is distributed on an \"AS IS\" BASIS,\n * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.\n * See the License for the specific language governing permissions and\n * limitations under the License.\n */\nimport { Hct } from '../hct/hct.js';\nimport * as math from '../utils/math_utils.js';\nconst SCORE_OPTION_DEFAULTS = {\n desired: 4,\n fallbackColorARGB: 0xff4285f4,\n filter: true, // Avoid unsuitable colors.\n};\nfunction compare(a, b) {\n if (a.score > b.score) {\n return -1;\n }\n else if (a.score < b.score) {\n return 1;\n }\n return 0;\n}\n/**\n * Given a large set of colors, remove colors that are unsuitable for a UI\n * theme, and rank the rest based on suitability.\n *\n * Enables use of a high cluster count for image quantization, thus ensuring\n * colors aren't muddied, while curating the high cluster count to a much\n * smaller number of appropriate choices.\n */\nexport class Score {\n constructor() { }\n /**\n * Given a map with keys of colors and values of how often the color appears,\n * rank the colors based on suitability for being used for a UI theme.\n *\n * @param colorsToPopulation map with keys of colors and values of how often\n * the color appears, usually from a source image.\n * @param {ScoreOptions} options optional parameters.\n * @return Colors sorted by suitability for a UI theme. The most suitable\n * color is the first item, the least suitable is the last. There will\n * always be at least one color returned. If all the input colors\n * were not suitable for a theme, a default fallback color will be\n * provided, Google Blue.\n */\n static score(colorsToPopulation, options) {\n const { desired, fallbackColorARGB, filter } = { ...SCORE_OPTION_DEFAULTS, ...options };\n // Get the HCT color for each Argb value, while finding the per hue count and\n // total count.\n const colorsHct = [];\n const huePopulation = new Array(360).fill(0);\n let populationSum = 0;\n for (const [argb, population] of colorsToPopulation.entries()) {\n const hct = Hct.fromInt(argb);\n colorsHct.push(hct);\n const hue = Math.floor(hct.hue);\n huePopulation[hue] += population;\n populationSum += population;\n }\n // Hues with more usage in neighboring 30 degree slice get a larger number.\n const hueExcitedProportions = new Array(360).fill(0.0);\n for (let hue = 0; hue < 360; hue++) {\n const proportion = huePopulation[hue] / populationSum;\n for (let i = hue - 14; i < hue + 16; i++) {\n const neighborHue = math.sanitizeDegreesInt(i);\n hueExcitedProportions[neighborHue] += proportion;\n }\n }\n // Scores each HCT color based on usage and chroma, while optionally\n // filtering out values that do not have enough chroma or usage.\n const scoredHct = new Array();\n for (const hct of colorsHct) {\n const hue = math.sanitizeDegreesInt(Math.round(hct.hue));\n const proportion = hueExcitedProportions[hue];\n if (filter && (hct.chroma < Score.CUTOFF_CHROMA || proportion <= Score.CUTOFF_EXCITED_PROPORTION)) {\n continue;\n }\n const proportionScore = proportion * 100.0 * Score.WEIGHT_PROPORTION;\n const chromaWeight = hct.chroma < Score.TARGET_CHROMA ? Score.WEIGHT_CHROMA_BELOW : Score.WEIGHT_CHROMA_ABOVE;\n const chromaScore = (hct.chroma - Score.TARGET_CHROMA) * chromaWeight;\n const score = proportionScore + chromaScore;\n scoredHct.push({ hct, score });\n }\n // Sorted so that colors with higher scores come first.\n scoredHct.sort(compare);\n // Iterates through potential hue differences in degrees in order to select\n // the colors with the largest distribution of hues possible. Starting at\n // 90 degrees(maximum difference for 4 colors) then decreasing down to a\n // 15 degree minimum.\n const chosenColors = [];\n for (let differenceDegrees = 90; differenceDegrees >= 15; differenceDegrees--) {\n chosenColors.length = 0;\n for (const { hct } of scoredHct) {\n const duplicateHue = chosenColors.find(chosenHct => {\n return math.differenceDegrees(hct.hue, chosenHct.hue) < differenceDegrees;\n });\n if (!duplicateHue) {\n chosenColors.push(hct);\n }\n if (chosenColors.length >= desired)\n break;\n }\n if (chosenColors.length >= desired)\n break;\n }\n const colors = [];\n if (chosenColors.length === 0) {\n colors.push(fallbackColorARGB);\n }\n for (const chosenHct of chosenColors) {\n colors.push(chosenHct.toInt());\n }\n return colors;\n }\n}\nScore.TARGET_CHROMA = 48.0; // A1 Chroma\nScore.WEIGHT_PROPORTION = 0.7;\nScore.WEIGHT_CHROMA_ABOVE = 0.3;\nScore.WEIGHT_CHROMA_BELOW = 0.1;\nScore.CUTOFF_CHROMA = 5.0;\nScore.CUTOFF_EXCITED_PROPORTION = 0.01;\n//# sourceMappingURL=score.js.map"],"ignoreList":[0],"mappings":";;;;;;;;;;;;;;;;;;;AAkBA,MAAM,wBAAwB;CAC1B,SAAS;CACT,mBAAmB;CACnB,QAAQ;AACZ;AACA,SAAS,QAAQ,GAAG,GAAG;CACnB,IAAI,EAAE,QAAQ,EAAE,OACZ,OAAO;MAEN,IAAI,EAAE,QAAQ,EAAE,OACjB,OAAO;CAEX,OAAO;AACX;;;;;;;;;AASA,IAAa,QAAb,MAAa,MAAM;CACf,cAAc,CAAE;;;;;;;;;;;;;;CAchB,OAAO,MAAM,oBAAoB,SAAS;EACtC,MAAM,EAAE,SAAS,mBAAmB,WAAW;GAAE,GAAG;GAAuB,GAAG;EAAQ;EAGtF,MAAM,YAAY,CAAC;EACnB,MAAM,gBAAgB,IAAI,MAAM,GAAG,CAAC,CAAC,KAAK,CAAC;EAC3C,IAAI,gBAAgB;EACpB,KAAK,MAAM,CAAC,MAAM,eAAe,mBAAmB,QAAQ,GAAG;GAC3D,MAAM,MAAM,IAAI,QAAQ,IAAI;GAC5B,UAAU,KAAK,GAAG;GAClB,MAAM,MAAM,KAAK,MAAM,IAAI,GAAG;GAC9B,cAAc,QAAQ;GACtB,iBAAiB;EACrB;EAEA,MAAM,wBAAwB,IAAI,MAAM,GAAG,CAAC,CAAC,KAAK,CAAG;EACrD,KAAK,IAAI,MAAM,GAAG,MAAM,KAAK,OAAO;GAChC,MAAM,aAAa,cAAc,OAAO;GACxC,KAAK,IAAI,IAAI,MAAM,IAAI,IAAI,MAAM,IAAI,KAAK;IACtC,MAAM,cAAcA,mBAAwB,CAAC;IAC7C,sBAAsB,gBAAgB;GAC1C;EACJ;EAGA,MAAM,YAAY,IAAI,MAAM;EAC5B,KAAK,MAAM,OAAO,WAAW;GAEzB,MAAM,aAAa,sBADPA,mBAAwB,KAAK,MAAM,IAAI,GAAG,CACX;GAC3C,IAAI,WAAW,IAAI,SAAS,MAAM,iBAAiB,cAAc,MAAM,4BACnE;GAEJ,MAAM,kBAAkB,aAAa,MAAQ,MAAM;GACnD,MAAM,eAAe,IAAI,SAAS,MAAM,gBAAgB,MAAM,sBAAsB,MAAM;GAE1F,MAAM,QAAQ,mBADO,IAAI,SAAS,MAAM,iBAAiB;GAEzD,UAAU,KAAK;IAAE;IAAK;GAAM,CAAC;EACjC;EAEA,UAAU,KAAK,OAAO;EAKtB,MAAM,eAAe,CAAC;EACtB,KAAK,IAAIC,sBAAoB,IAAIA,uBAAqB,IAAI,uBAAqB;GAC3E,aAAa,SAAS;GACtB,KAAK,MAAM,EAAE,SAAS,WAAW;IAI7B,IAAI,CAHiB,aAAa,MAAK,cAAa;KAChD,OAAOC,kBAAuB,IAAI,KAAK,UAAU,GAAG,IAAID;IAC5D,CACgB,GACZ,aAAa,KAAK,GAAG;IAEzB,IAAI,aAAa,UAAU,SACvB;GACR;GACA,IAAI,aAAa,UAAU,SACvB;EACR;EACA,MAAM,SAAS,CAAC;EAChB,IAAI,aAAa,WAAW,GACxB,OAAO,KAAK,iBAAiB;EAEjC,KAAK,MAAM,aAAa,cACpB,OAAO,KAAK,UAAU,MAAM,CAAC;EAEjC,OAAO;CACX;AACJ;AACA,MAAM,gBAAgB;AACtB,MAAM,oBAAoB;AAC1B,MAAM,sBAAsB;AAC5B,MAAM,sBAAsB;AAC5B,MAAM,gBAAgB;AACtB,MAAM,4BAA4B"}
|
|
@@ -0,0 +1,227 @@
|
|
|
1
|
+
import { sanitizeDegreesDouble, sanitizeDegreesInt } from "../utils/math_utils.js";
|
|
2
|
+
import { labFromArgb } from "../utils/color_utils.js";
|
|
3
|
+
import { Hct } from "../hct/hct.js";
|
|
4
|
+
//#region ../../node_modules/.pnpm/@material+material-color-utilities@0.4.0/node_modules/@material/material-color-utilities/temperature/temperature_cache.js
|
|
5
|
+
/**
|
|
6
|
+
* @license
|
|
7
|
+
* Copyright 2023 Google LLC
|
|
8
|
+
*
|
|
9
|
+
* Licensed under the Apache License, Version 2.0 (the "License");
|
|
10
|
+
* you may not use this file except in compliance with the License.
|
|
11
|
+
* You may obtain a copy of the License at
|
|
12
|
+
*
|
|
13
|
+
* http://www.apache.org/licenses/LICENSE-2.0
|
|
14
|
+
*
|
|
15
|
+
* Unless required by applicable law or agreed to in writing, software
|
|
16
|
+
* distributed under the License is distributed on an "AS IS" BASIS,
|
|
17
|
+
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
|
|
18
|
+
* See the License for the specific language governing permissions and
|
|
19
|
+
* limitations under the License.
|
|
20
|
+
*/
|
|
21
|
+
/**
|
|
22
|
+
* Design utilities using color temperature theory.
|
|
23
|
+
*
|
|
24
|
+
* Analogous colors, complementary color, and cache to efficiently, lazily,
|
|
25
|
+
* generate data for calculations when needed.
|
|
26
|
+
*/
|
|
27
|
+
var TemperatureCache = class TemperatureCache {
|
|
28
|
+
constructor(input) {
|
|
29
|
+
this.input = input;
|
|
30
|
+
this.hctsByTempCache = [];
|
|
31
|
+
this.hctsByHueCache = [];
|
|
32
|
+
this.tempsByHctCache = /* @__PURE__ */ new Map();
|
|
33
|
+
this.inputRelativeTemperatureCache = -1;
|
|
34
|
+
this.complementCache = null;
|
|
35
|
+
}
|
|
36
|
+
get hctsByTemp() {
|
|
37
|
+
if (this.hctsByTempCache.length > 0) return this.hctsByTempCache;
|
|
38
|
+
const hcts = this.hctsByHue.concat([this.input]);
|
|
39
|
+
const temperaturesByHct = this.tempsByHct;
|
|
40
|
+
hcts.sort((a, b) => temperaturesByHct.get(a) - temperaturesByHct.get(b));
|
|
41
|
+
this.hctsByTempCache = hcts;
|
|
42
|
+
return hcts;
|
|
43
|
+
}
|
|
44
|
+
get warmest() {
|
|
45
|
+
return this.hctsByTemp[this.hctsByTemp.length - 1];
|
|
46
|
+
}
|
|
47
|
+
get coldest() {
|
|
48
|
+
return this.hctsByTemp[0];
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* A set of colors with differing hues, equidistant in temperature.
|
|
52
|
+
*
|
|
53
|
+
* In art, this is usually described as a set of 5 colors on a color wheel
|
|
54
|
+
* divided into 12 sections. This method allows provision of either of those
|
|
55
|
+
* values.
|
|
56
|
+
*
|
|
57
|
+
* Behavior is undefined when [count] or [divisions] is 0.
|
|
58
|
+
* When divisions < count, colors repeat.
|
|
59
|
+
*
|
|
60
|
+
* [count] The number of colors to return, includes the input color.
|
|
61
|
+
* [divisions] The number of divisions on the color wheel.
|
|
62
|
+
*/
|
|
63
|
+
analogous(count = 5, divisions = 12) {
|
|
64
|
+
const startHue = Math.round(this.input.hue);
|
|
65
|
+
const startHct = this.hctsByHue[startHue];
|
|
66
|
+
let lastTemp = this.relativeTemperature(startHct);
|
|
67
|
+
const allColors = [startHct];
|
|
68
|
+
let absoluteTotalTempDelta = 0;
|
|
69
|
+
for (let i = 0; i < 360; i++) {
|
|
70
|
+
const hue = sanitizeDegreesInt(startHue + i);
|
|
71
|
+
const hct = this.hctsByHue[hue];
|
|
72
|
+
const temp = this.relativeTemperature(hct);
|
|
73
|
+
const tempDelta = Math.abs(temp - lastTemp);
|
|
74
|
+
lastTemp = temp;
|
|
75
|
+
absoluteTotalTempDelta += tempDelta;
|
|
76
|
+
}
|
|
77
|
+
let hueAddend = 1;
|
|
78
|
+
const tempStep = absoluteTotalTempDelta / divisions;
|
|
79
|
+
let totalTempDelta = 0;
|
|
80
|
+
lastTemp = this.relativeTemperature(startHct);
|
|
81
|
+
while (allColors.length < divisions) {
|
|
82
|
+
const hue = sanitizeDegreesInt(startHue + hueAddend);
|
|
83
|
+
const hct = this.hctsByHue[hue];
|
|
84
|
+
const temp = this.relativeTemperature(hct);
|
|
85
|
+
const tempDelta = Math.abs(temp - lastTemp);
|
|
86
|
+
totalTempDelta += tempDelta;
|
|
87
|
+
const desiredTotalTempDeltaForIndex = allColors.length * tempStep;
|
|
88
|
+
let indexSatisfied = totalTempDelta >= desiredTotalTempDeltaForIndex;
|
|
89
|
+
let indexAddend = 1;
|
|
90
|
+
while (indexSatisfied && allColors.length < divisions) {
|
|
91
|
+
allColors.push(hct);
|
|
92
|
+
const desiredTotalTempDeltaForIndex = (allColors.length + indexAddend) * tempStep;
|
|
93
|
+
indexSatisfied = totalTempDelta >= desiredTotalTempDeltaForIndex;
|
|
94
|
+
indexAddend++;
|
|
95
|
+
}
|
|
96
|
+
lastTemp = temp;
|
|
97
|
+
hueAddend++;
|
|
98
|
+
if (hueAddend > 360) {
|
|
99
|
+
while (allColors.length < divisions) allColors.push(hct);
|
|
100
|
+
break;
|
|
101
|
+
}
|
|
102
|
+
}
|
|
103
|
+
const answers = [this.input];
|
|
104
|
+
const increaseHueCount = Math.floor((count - 1) / 2);
|
|
105
|
+
for (let i = 1; i < increaseHueCount + 1; i++) {
|
|
106
|
+
let index = 0 - i;
|
|
107
|
+
while (index < 0) index = allColors.length + index;
|
|
108
|
+
if (index >= allColors.length) index = index % allColors.length;
|
|
109
|
+
answers.splice(0, 0, allColors[index]);
|
|
110
|
+
}
|
|
111
|
+
const decreaseHueCount = count - increaseHueCount - 1;
|
|
112
|
+
for (let i = 1; i < decreaseHueCount + 1; i++) {
|
|
113
|
+
let index = i;
|
|
114
|
+
while (index < 0) index = allColors.length + index;
|
|
115
|
+
if (index >= allColors.length) index = index % allColors.length;
|
|
116
|
+
answers.push(allColors[index]);
|
|
117
|
+
}
|
|
118
|
+
return answers;
|
|
119
|
+
}
|
|
120
|
+
/**
|
|
121
|
+
* A color that complements the input color aesthetically.
|
|
122
|
+
*
|
|
123
|
+
* In art, this is usually described as being across the color wheel.
|
|
124
|
+
* History of this shows intent as a color that is just as cool-warm as the
|
|
125
|
+
* input color is warm-cool.
|
|
126
|
+
*/
|
|
127
|
+
get complement() {
|
|
128
|
+
if (this.complementCache != null) return this.complementCache;
|
|
129
|
+
const coldestHue = this.coldest.hue;
|
|
130
|
+
const coldestTemp = this.tempsByHct.get(this.coldest);
|
|
131
|
+
const warmestHue = this.warmest.hue;
|
|
132
|
+
const range = this.tempsByHct.get(this.warmest) - coldestTemp;
|
|
133
|
+
const startHueIsColdestToWarmest = TemperatureCache.isBetween(this.input.hue, coldestHue, warmestHue);
|
|
134
|
+
const startHue = startHueIsColdestToWarmest ? warmestHue : coldestHue;
|
|
135
|
+
const endHue = startHueIsColdestToWarmest ? coldestHue : warmestHue;
|
|
136
|
+
const directionOfRotation = 1;
|
|
137
|
+
let smallestError = 1e3;
|
|
138
|
+
let answer = this.hctsByHue[Math.round(this.input.hue)];
|
|
139
|
+
const complementRelativeTemp = 1 - this.inputRelativeTemperature;
|
|
140
|
+
for (let hueAddend = 0; hueAddend <= 360; hueAddend += 1) {
|
|
141
|
+
const hue = sanitizeDegreesDouble(startHue + directionOfRotation * hueAddend);
|
|
142
|
+
if (!TemperatureCache.isBetween(hue, startHue, endHue)) continue;
|
|
143
|
+
const possibleAnswer = this.hctsByHue[Math.round(hue)];
|
|
144
|
+
const relativeTemp = (this.tempsByHct.get(possibleAnswer) - coldestTemp) / range;
|
|
145
|
+
const error = Math.abs(complementRelativeTemp - relativeTemp);
|
|
146
|
+
if (error < smallestError) {
|
|
147
|
+
smallestError = error;
|
|
148
|
+
answer = possibleAnswer;
|
|
149
|
+
}
|
|
150
|
+
}
|
|
151
|
+
this.complementCache = answer;
|
|
152
|
+
return this.complementCache;
|
|
153
|
+
}
|
|
154
|
+
/**
|
|
155
|
+
* Temperature relative to all colors with the same chroma and tone.
|
|
156
|
+
* Value on a scale from 0 to 1.
|
|
157
|
+
*/
|
|
158
|
+
relativeTemperature(hct) {
|
|
159
|
+
const range = this.tempsByHct.get(this.warmest) - this.tempsByHct.get(this.coldest);
|
|
160
|
+
const differenceFromColdest = this.tempsByHct.get(hct) - this.tempsByHct.get(this.coldest);
|
|
161
|
+
if (range === 0) return .5;
|
|
162
|
+
return differenceFromColdest / range;
|
|
163
|
+
}
|
|
164
|
+
/** Relative temperature of the input color. See [relativeTemperature]. */
|
|
165
|
+
get inputRelativeTemperature() {
|
|
166
|
+
if (this.inputRelativeTemperatureCache >= 0) return this.inputRelativeTemperatureCache;
|
|
167
|
+
this.inputRelativeTemperatureCache = this.relativeTemperature(this.input);
|
|
168
|
+
return this.inputRelativeTemperatureCache;
|
|
169
|
+
}
|
|
170
|
+
/** A Map with keys of HCTs in [hctsByTemp], values of raw temperature. */
|
|
171
|
+
get tempsByHct() {
|
|
172
|
+
if (this.tempsByHctCache.size > 0) return this.tempsByHctCache;
|
|
173
|
+
const allHcts = this.hctsByHue.concat([this.input]);
|
|
174
|
+
const temperaturesByHct = /* @__PURE__ */ new Map();
|
|
175
|
+
for (const e of allHcts) temperaturesByHct.set(e, TemperatureCache.rawTemperature(e));
|
|
176
|
+
this.tempsByHctCache = temperaturesByHct;
|
|
177
|
+
return temperaturesByHct;
|
|
178
|
+
}
|
|
179
|
+
/**
|
|
180
|
+
* HCTs for all hues, with the same chroma/tone as the input.
|
|
181
|
+
* Sorted ascending, hue 0 to 360.
|
|
182
|
+
*/
|
|
183
|
+
get hctsByHue() {
|
|
184
|
+
if (this.hctsByHueCache.length > 0) return this.hctsByHueCache;
|
|
185
|
+
const hcts = [];
|
|
186
|
+
for (let hue = 0; hue <= 360; hue += 1) {
|
|
187
|
+
const colorAtHue = Hct.from(hue, this.input.chroma, this.input.tone);
|
|
188
|
+
hcts.push(colorAtHue);
|
|
189
|
+
}
|
|
190
|
+
this.hctsByHueCache = hcts;
|
|
191
|
+
return this.hctsByHueCache;
|
|
192
|
+
}
|
|
193
|
+
/** Determines if an angle is between two other angles, rotating clockwise. */
|
|
194
|
+
static isBetween(angle, a, b) {
|
|
195
|
+
if (a < b) return a <= angle && angle <= b;
|
|
196
|
+
return a <= angle || angle <= b;
|
|
197
|
+
}
|
|
198
|
+
/**
|
|
199
|
+
* Value representing cool-warm factor of a color.
|
|
200
|
+
* Values below 0 are considered cool, above, warm.
|
|
201
|
+
*
|
|
202
|
+
* Color science has researched emotion and harmony, which art uses to select
|
|
203
|
+
* colors. Warm-cool is the foundation of analogous and complementary colors.
|
|
204
|
+
* See:
|
|
205
|
+
* - Li-Chen Ou's Chapter 19 in Handbook of Color Psychology (2015).
|
|
206
|
+
* - Josef Albers' Interaction of Color chapters 19 and 21.
|
|
207
|
+
*
|
|
208
|
+
* Implementation of Ou, Woodcock and Wright's algorithm, which uses
|
|
209
|
+
* L*a*b* / LCH color space.
|
|
210
|
+
* Return value has these properties:
|
|
211
|
+
* - Values below 0 are cool, above 0 are warm.
|
|
212
|
+
* - Lower bound: -0.52 - (chroma ^ 1.07 / 20). L*a*b* chroma is infinite.
|
|
213
|
+
* Assuming max of 130 chroma, -9.66.
|
|
214
|
+
* - Upper bound: -0.52 + (chroma ^ 1.07 / 20). L*a*b* chroma is infinite.
|
|
215
|
+
* Assuming max of 130 chroma, 8.61.
|
|
216
|
+
*/
|
|
217
|
+
static rawTemperature(color) {
|
|
218
|
+
const lab = labFromArgb(color.toInt());
|
|
219
|
+
const hue = sanitizeDegreesDouble(Math.atan2(lab[2], lab[1]) * 180 / Math.PI);
|
|
220
|
+
const chroma = Math.sqrt(lab[1] * lab[1] + lab[2] * lab[2]);
|
|
221
|
+
return -.5 + .02 * Math.pow(chroma, 1.07) * Math.cos(sanitizeDegreesDouble(hue - 50) * Math.PI / 180);
|
|
222
|
+
}
|
|
223
|
+
};
|
|
224
|
+
//#endregion
|
|
225
|
+
export { TemperatureCache };
|
|
226
|
+
|
|
227
|
+
//# sourceMappingURL=temperature_cache.js.map
|