@windmorph/react 0.0.0-stage → 0.1.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/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,115 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { hasVisibleFocusWithin } from "../../utils/focus-visible.js";
|
|
3
|
+
import { useEffect } from "react";
|
|
4
|
+
import { useReducedMotion } from "motion/react";
|
|
5
|
+
//#region src/components/navigation/use-hide-on-scroll.ts
|
|
6
|
+
/** How long after the last scroll event the scroll counts as ended where `scrollend` is missing. */
|
|
7
|
+
const SCROLL_END_FALLBACK_MS = 150;
|
|
8
|
+
/**
|
|
9
|
+
* Hides a bottom bar while the page scrolls down and brings it back on any scroll up
|
|
10
|
+
* (M3: "Scrolling downward can hide the navigation bar; scrolling upward reveals it"). The
|
|
11
|
+
* offset, 0 down to minus the bar's height, follows the scroll distance like a top app
|
|
12
|
+
* bar's `enter-always`, and is written to `--m3-nav-bar-offset`, which the sticky bar uses
|
|
13
|
+
* as its `bottom`, so nothing re-renders while scrolling. Under reduced motion the bar
|
|
14
|
+
* stays put.
|
|
15
|
+
*
|
|
16
|
+
* When the scroll ends with the bar part-hidden, it settles shown or hidden, whichever is
|
|
17
|
+
* nearer, on the default effects spring (`data-settling`; 2026-10-15), as Compose's
|
|
18
|
+
* exit-always bottom bars snap, so it never rests half off the screen.
|
|
19
|
+
*
|
|
20
|
+
* Fully hidden, the bar is `inert`, so Tab and screen readers skip its destinations until
|
|
21
|
+
* it comes back. While keyboard focus is on one of its items it stays on screen (WCAG
|
|
22
|
+
* 2.4.11 Focus Not Obscured), and focusing a partly hidden bar brings it back. Other focus
|
|
23
|
+
* in it (an item pressed with a pointer) doesn't hold it on screen, but the bar isn't made
|
|
24
|
+
* `inert` until focus leaves it, so that focus never drops to the page (2026-10-15).
|
|
25
|
+
*/
|
|
26
|
+
function useHideOnScroll(enabled, barRef, scrollRef) {
|
|
27
|
+
const reducedMotion = useReducedMotion();
|
|
28
|
+
const active = enabled && !reducedMotion;
|
|
29
|
+
useEffect(() => {
|
|
30
|
+
const bar = barRef.current;
|
|
31
|
+
if (!bar) return;
|
|
32
|
+
if (!active) {
|
|
33
|
+
bar.style.removeProperty("--m3-nav-bar-offset");
|
|
34
|
+
return;
|
|
35
|
+
}
|
|
36
|
+
const scroller = scrollRef?.current;
|
|
37
|
+
const target = scroller ?? window;
|
|
38
|
+
const position = () => Math.max(0, scroller ? scroller.scrollTop : window.scrollY);
|
|
39
|
+
let last = position();
|
|
40
|
+
let offset = 0;
|
|
41
|
+
let frame = 0;
|
|
42
|
+
let endTimer;
|
|
43
|
+
let isInert = false;
|
|
44
|
+
const setOffset = (value) => {
|
|
45
|
+
offset = value;
|
|
46
|
+
bar.style.setProperty("--m3-nav-bar-offset", `${offset}px`);
|
|
47
|
+
syncInert();
|
|
48
|
+
};
|
|
49
|
+
const syncInert = () => {
|
|
50
|
+
const height = bar.offsetHeight;
|
|
51
|
+
const inert = height > 0 && -offset >= height - .5 && !bar.contains(document.activeElement);
|
|
52
|
+
if (inert !== isInert) {
|
|
53
|
+
isInert = inert;
|
|
54
|
+
bar.toggleAttribute("inert", inert);
|
|
55
|
+
}
|
|
56
|
+
};
|
|
57
|
+
const update = () => {
|
|
58
|
+
frame = 0;
|
|
59
|
+
const scroll = position();
|
|
60
|
+
const delta = scroll - last;
|
|
61
|
+
last = scroll;
|
|
62
|
+
const height = bar.offsetHeight;
|
|
63
|
+
setOffset(hasVisibleFocusWithin(bar) ? 0 : Math.min(0, Math.max(-height, offset - delta)));
|
|
64
|
+
};
|
|
65
|
+
const settle = () => {
|
|
66
|
+
clearTimeout(endTimer);
|
|
67
|
+
if (frame) {
|
|
68
|
+
cancelAnimationFrame(frame);
|
|
69
|
+
update();
|
|
70
|
+
}
|
|
71
|
+
const height = bar.offsetHeight;
|
|
72
|
+
if (offset >= 0 || offset <= -height) return;
|
|
73
|
+
bar.toggleAttribute("data-settling", true);
|
|
74
|
+
setOffset(-offset > height / 2 ? -height : 0);
|
|
75
|
+
};
|
|
76
|
+
const onScroll = () => {
|
|
77
|
+
bar.removeAttribute("data-settling");
|
|
78
|
+
if (!frame) frame = requestAnimationFrame(update);
|
|
79
|
+
if (!("onscrollend" in window)) {
|
|
80
|
+
clearTimeout(endTimer);
|
|
81
|
+
endTimer = setTimeout(settle, SCROLL_END_FALLBACK_MS);
|
|
82
|
+
}
|
|
83
|
+
};
|
|
84
|
+
const onSettled = (event) => {
|
|
85
|
+
if (event.target === bar) bar.removeAttribute("data-settling");
|
|
86
|
+
};
|
|
87
|
+
const onFocusOut = () => requestAnimationFrame(syncInert);
|
|
88
|
+
update();
|
|
89
|
+
target.addEventListener("scroll", onScroll, { passive: true });
|
|
90
|
+
target.addEventListener("scrollend", settle);
|
|
91
|
+
bar.addEventListener("focusin", onScroll);
|
|
92
|
+
bar.addEventListener("focusout", onFocusOut);
|
|
93
|
+
bar.addEventListener("transitionend", onSettled);
|
|
94
|
+
return () => {
|
|
95
|
+
target.removeEventListener("scroll", onScroll);
|
|
96
|
+
target.removeEventListener("scrollend", settle);
|
|
97
|
+
bar.removeEventListener("focusin", onScroll);
|
|
98
|
+
bar.removeEventListener("focusout", onFocusOut);
|
|
99
|
+
bar.removeEventListener("transitionend", onSettled);
|
|
100
|
+
cancelAnimationFrame(frame);
|
|
101
|
+
clearTimeout(endTimer);
|
|
102
|
+
if (isInert) bar.removeAttribute("inert");
|
|
103
|
+
bar.removeAttribute("data-settling");
|
|
104
|
+
bar.style.removeProperty("--m3-nav-bar-offset");
|
|
105
|
+
};
|
|
106
|
+
}, [
|
|
107
|
+
active,
|
|
108
|
+
barRef,
|
|
109
|
+
scrollRef
|
|
110
|
+
]);
|
|
111
|
+
}
|
|
112
|
+
//#endregion
|
|
113
|
+
export { useHideOnScroll };
|
|
114
|
+
|
|
115
|
+
//# sourceMappingURL=use-hide-on-scroll.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-hide-on-scroll.js","names":[],"sources":["../../../src/components/navigation/use-hide-on-scroll.ts"],"sourcesContent":["'use client';\n\nimport { useReducedMotion } from 'motion/react';\nimport { useEffect, type RefObject } from 'react';\nimport { hasVisibleFocusWithin } from '../../utils/focus-visible';\n\n/** How long after the last scroll event the scroll counts as ended where `scrollend` is missing. */\nconst SCROLL_END_FALLBACK_MS = 150;\n\n/**\n * Hides a bottom bar while the page scrolls down and brings it back on any scroll up\n * (M3: \"Scrolling downward can hide the navigation bar; scrolling upward reveals it\"). The\n * offset, 0 down to minus the bar's height, follows the scroll distance like a top app\n * bar's `enter-always`, and is written to `--m3-nav-bar-offset`, which the sticky bar uses\n * as its `bottom`, so nothing re-renders while scrolling. Under reduced motion the bar\n * stays put.\n *\n * When the scroll ends with the bar part-hidden, it settles shown or hidden, whichever is\n * nearer, on the default effects spring (`data-settling`; 2026-10-15), as Compose's\n * exit-always bottom bars snap, so it never rests half off the screen.\n *\n * Fully hidden, the bar is `inert`, so Tab and screen readers skip its destinations until\n * it comes back. While keyboard focus is on one of its items it stays on screen (WCAG\n * 2.4.11 Focus Not Obscured), and focusing a partly hidden bar brings it back. Other focus\n * in it (an item pressed with a pointer) doesn't hold it on screen, but the bar isn't made\n * `inert` until focus leaves it, so that focus never drops to the page (2026-10-15).\n */\nexport function useHideOnScroll(\n enabled: boolean,\n barRef: RefObject<HTMLElement | null>,\n scrollRef?: RefObject<HTMLElement | null>,\n) {\n const reducedMotion = useReducedMotion();\n const active = enabled && !reducedMotion;\n useEffect(() => {\n const bar = barRef.current;\n if (!bar) return;\n if (!active) {\n bar.style.removeProperty('--m3-nav-bar-offset');\n return;\n }\n const scroller = scrollRef?.current;\n const target: HTMLElement | Window = scroller ?? window;\n const position = () => Math.max(0, scroller ? scroller.scrollTop : window.scrollY);\n let last = position();\n let offset = 0;\n let frame = 0;\n let endTimer: ReturnType<typeof setTimeout> | undefined;\n let isInert = false;\n const setOffset = (value: number) => {\n offset = value;\n bar.style.setProperty('--m3-nav-bar-offset', `${offset}px`);\n syncInert();\n };\n const syncInert = () => {\n const height = bar.offsetHeight;\n const offScreen = height > 0 && -offset >= height - 0.5;\n const inert = offScreen && !bar.contains(document.activeElement);\n if (inert !== isInert) {\n isInert = inert;\n bar.toggleAttribute('inert', inert);\n }\n };\n const update = () => {\n frame = 0;\n const scroll = position();\n const delta = scroll - last;\n last = scroll;\n const height = bar.offsetHeight;\n setOffset(hasVisibleFocusWithin(bar) ? 0 : Math.min(0, Math.max(-height, offset - delta)));\n };\n const settle = () => {\n clearTimeout(endTimer);\n // An instant scroll ends in the frame of its last scroll event, before that frame's\n // update has run: apply it first, or the bar settles from the old offset and the\n // update then leaves it part-hidden (2026-10-17).\n if (frame) {\n cancelAnimationFrame(frame);\n update();\n }\n const height = bar.offsetHeight;\n if (offset >= 0 || offset <= -height) return;\n bar.toggleAttribute('data-settling', true);\n setOffset(-offset > height / 2 ? -height : 0);\n };\n const onScroll = () => {\n bar.removeAttribute('data-settling');\n if (!frame) frame = requestAnimationFrame(update);\n if (!('onscrollend' in window)) {\n clearTimeout(endTimer);\n endTimer = setTimeout(settle, SCROLL_END_FALLBACK_MS);\n }\n };\n const onSettled = (event: TransitionEvent) => {\n if (event.target === bar) bar.removeAttribute('data-settling');\n };\n // Focus leaving a hidden bar makes it inert then.\n const onFocusOut = () => requestAnimationFrame(syncInert);\n update();\n target.addEventListener('scroll', onScroll, { passive: true });\n target.addEventListener('scrollend', settle);\n bar.addEventListener('focusin', onScroll);\n bar.addEventListener('focusout', onFocusOut);\n bar.addEventListener('transitionend', onSettled);\n return () => {\n target.removeEventListener('scroll', onScroll);\n target.removeEventListener('scrollend', settle);\n bar.removeEventListener('focusin', onScroll);\n bar.removeEventListener('focusout', onFocusOut);\n bar.removeEventListener('transitionend', onSettled);\n cancelAnimationFrame(frame);\n clearTimeout(endTimer);\n if (isInert) bar.removeAttribute('inert');\n bar.removeAttribute('data-settling');\n bar.style.removeProperty('--m3-nav-bar-offset');\n };\n }, [active, barRef, scrollRef]);\n}\n"],"mappings":";;;;;;AAOA,MAAM,yBAAyB;;;;;;;;;;;;;;;;;;;AAoB/B,SAAgB,gBACd,SACA,QACA,WACA;CACA,MAAM,gBAAgB,iBAAiB;CACvC,MAAM,SAAS,WAAW,CAAC;CAC3B,gBAAgB;EACd,MAAM,MAAM,OAAO;EACnB,IAAI,CAAC,KAAK;EACV,IAAI,CAAC,QAAQ;GACX,IAAI,MAAM,eAAe,qBAAqB;GAC9C;EACF;EACA,MAAM,WAAW,WAAW;EAC5B,MAAM,SAA+B,YAAY;EACjD,MAAM,iBAAiB,KAAK,IAAI,GAAG,WAAW,SAAS,YAAY,OAAO,OAAO;EACjF,IAAI,OAAO,SAAS;EACpB,IAAI,SAAS;EACb,IAAI,QAAQ;EACZ,IAAI;EACJ,IAAI,UAAU;EACd,MAAM,aAAa,UAAkB;GACnC,SAAS;GACT,IAAI,MAAM,YAAY,uBAAuB,GAAG,OAAO,GAAG;GAC1D,UAAU;EACZ;EACA,MAAM,kBAAkB;GACtB,MAAM,SAAS,IAAI;GAEnB,MAAM,QADY,SAAS,KAAK,CAAC,UAAU,SAAS,MACzB,CAAC,IAAI,SAAS,SAAS,aAAa;GAC/D,IAAI,UAAU,SAAS;IACrB,UAAU;IACV,IAAI,gBAAgB,SAAS,KAAK;GACpC;EACF;EACA,MAAM,eAAe;GACnB,QAAQ;GACR,MAAM,SAAS,SAAS;GACxB,MAAM,QAAQ,SAAS;GACvB,OAAO;GACP,MAAM,SAAS,IAAI;GACnB,UAAU,sBAAsB,GAAG,IAAI,IAAI,KAAK,IAAI,GAAG,KAAK,IAAI,CAAC,QAAQ,SAAS,KAAK,CAAC,CAAC;EAC3F;EACA,MAAM,eAAe;GACnB,aAAa,QAAQ;GAIrB,IAAI,OAAO;IACT,qBAAqB,KAAK;IAC1B,OAAO;GACT;GACA,MAAM,SAAS,IAAI;GACnB,IAAI,UAAU,KAAK,UAAU,CAAC,QAAQ;GACtC,IAAI,gBAAgB,iBAAiB,IAAI;GACzC,UAAU,CAAC,SAAS,SAAS,IAAI,CAAC,SAAS,CAAC;EAC9C;EACA,MAAM,iBAAiB;GACrB,IAAI,gBAAgB,eAAe;GACnC,IAAI,CAAC,OAAO,QAAQ,sBAAsB,MAAM;GAChD,IAAI,EAAE,iBAAiB,SAAS;IAC9B,aAAa,QAAQ;IACrB,WAAW,WAAW,QAAQ,sBAAsB;GACtD;EACF;EACA,MAAM,aAAa,UAA2B;GAC5C,IAAI,MAAM,WAAW,KAAK,IAAI,gBAAgB,eAAe;EAC/D;EAEA,MAAM,mBAAmB,sBAAsB,SAAS;EACxD,OAAO;EACP,OAAO,iBAAiB,UAAU,UAAU,EAAE,SAAS,KAAK,CAAC;EAC7D,OAAO,iBAAiB,aAAa,MAAM;EAC3C,IAAI,iBAAiB,WAAW,QAAQ;EACxC,IAAI,iBAAiB,YAAY,UAAU;EAC3C,IAAI,iBAAiB,iBAAiB,SAAS;EAC/C,aAAa;GACX,OAAO,oBAAoB,UAAU,QAAQ;GAC7C,OAAO,oBAAoB,aAAa,MAAM;GAC9C,IAAI,oBAAoB,WAAW,QAAQ;GAC3C,IAAI,oBAAoB,YAAY,UAAU;GAC9C,IAAI,oBAAoB,iBAAiB,SAAS;GAClD,qBAAqB,KAAK;GAC1B,aAAa,QAAQ;GACrB,IAAI,SAAS,IAAI,gBAAgB,OAAO;GACxC,IAAI,gBAAgB,eAAe;GACnC,IAAI,MAAM,eAAe,qBAAqB;EAChD;CACF,GAAG;EAAC;EAAQ;EAAQ;CAAS,CAAC;AAChC"}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
//#region src/components/navigation/use-item-arrow-keys.ts
|
|
2
|
+
const isUsable = (element) => !element.hasAttribute("disabled") && element.getAttribute("aria-disabled") !== "true";
|
|
3
|
+
/**
|
|
4
|
+
* Arrow-key focus movement between navigation items (M3 rail: "Use arrows to move between
|
|
5
|
+
* navigation items"). Up / Down (or Left / Right along a bar, mirrored right to left) move
|
|
6
|
+
* focus to the previous or next item, wrapping, and Home / End to the first or last. Focus
|
|
7
|
+
* moves without choosing a destination; Tab keeps working as usual.
|
|
8
|
+
*/
|
|
9
|
+
function onItemArrowKeys(orientation) {
|
|
10
|
+
return (event) => {
|
|
11
|
+
if (event.altKey || event.ctrlKey || event.metaKey || event.shiftKey) return;
|
|
12
|
+
const list = event.currentTarget;
|
|
13
|
+
const rtl = getComputedStyle(list).direction === "rtl";
|
|
14
|
+
const previousKey = orientation === "vertical" ? "ArrowUp" : rtl ? "ArrowRight" : "ArrowLeft";
|
|
15
|
+
const nextKey = orientation === "vertical" ? "ArrowDown" : rtl ? "ArrowLeft" : "ArrowRight";
|
|
16
|
+
if (![
|
|
17
|
+
previousKey,
|
|
18
|
+
nextKey,
|
|
19
|
+
"Home",
|
|
20
|
+
"End"
|
|
21
|
+
].includes(event.key)) return;
|
|
22
|
+
const items = [...list.querySelectorAll("[data-nav-item]")].filter(isUsable);
|
|
23
|
+
if (items.length === 0) return;
|
|
24
|
+
const index = items.findIndex((item) => item.contains(document.activeElement));
|
|
25
|
+
if (index === -1) return;
|
|
26
|
+
let target;
|
|
27
|
+
if (event.key === "Home") target = items[0];
|
|
28
|
+
else if (event.key === "End") target = items[items.length - 1];
|
|
29
|
+
else target = items[(index + (event.key === nextKey ? 1 : -1) + items.length) % items.length];
|
|
30
|
+
event.preventDefault();
|
|
31
|
+
target.focus();
|
|
32
|
+
};
|
|
33
|
+
}
|
|
34
|
+
//#endregion
|
|
35
|
+
export { onItemArrowKeys };
|
|
36
|
+
|
|
37
|
+
//# sourceMappingURL=use-item-arrow-keys.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-item-arrow-keys.js","names":[],"sources":["../../../src/components/navigation/use-item-arrow-keys.ts"],"sourcesContent":["import type { KeyboardEvent } from 'react';\n\nconst isUsable = (element: HTMLElement) =>\n !element.hasAttribute('disabled') && element.getAttribute('aria-disabled') !== 'true';\n\n/**\n * Arrow-key focus movement between navigation items (M3 rail: \"Use arrows to move between\n * navigation items\"). Up / Down (or Left / Right along a bar, mirrored right to left) move\n * focus to the previous or next item, wrapping, and Home / End to the first or last. Focus\n * moves without choosing a destination; Tab keeps working as usual.\n */\nexport function onItemArrowKeys(orientation: 'vertical' | 'horizontal') {\n return (event: KeyboardEvent<HTMLElement>) => {\n if (event.altKey || event.ctrlKey || event.metaKey || event.shiftKey) return;\n const list = event.currentTarget;\n const rtl = getComputedStyle(list).direction === 'rtl';\n const previousKey = orientation === 'vertical' ? 'ArrowUp' : rtl ? 'ArrowRight' : 'ArrowLeft';\n const nextKey = orientation === 'vertical' ? 'ArrowDown' : rtl ? 'ArrowLeft' : 'ArrowRight';\n if (![previousKey, nextKey, 'Home', 'End'].includes(event.key)) return;\n const items = [...list.querySelectorAll<HTMLElement>('[data-nav-item]')].filter(isUsable);\n if (items.length === 0) return;\n const index = items.findIndex((item) => item.contains(document.activeElement));\n if (index === -1) return;\n let target: HTMLElement;\n if (event.key === 'Home') target = items[0]!;\n else if (event.key === 'End') target = items[items.length - 1]!;\n else {\n const step = event.key === nextKey ? 1 : -1;\n target = items[(index + step + items.length) % items.length]!;\n }\n event.preventDefault();\n target.focus();\n };\n}\n"],"mappings":";AAEA,MAAM,YAAY,YAChB,CAAC,QAAQ,aAAa,UAAU,KAAK,QAAQ,aAAa,eAAe,MAAM;;;;;;;AAQjF,SAAgB,gBAAgB,aAAwC;CACtE,QAAQ,UAAsC;EAC5C,IAAI,MAAM,UAAU,MAAM,WAAW,MAAM,WAAW,MAAM,UAAU;EACtE,MAAM,OAAO,MAAM;EACnB,MAAM,MAAM,iBAAiB,IAAI,CAAC,CAAC,cAAc;EACjD,MAAM,cAAc,gBAAgB,aAAa,YAAY,MAAM,eAAe;EAClF,MAAM,UAAU,gBAAgB,aAAa,cAAc,MAAM,cAAc;EAC/E,IAAI,CAAC;GAAC;GAAa;GAAS;GAAQ;EAAK,CAAC,CAAC,SAAS,MAAM,GAAG,GAAG;EAChE,MAAM,QAAQ,CAAC,GAAG,KAAK,iBAA8B,iBAAiB,CAAC,CAAC,CAAC,OAAO,QAAQ;EACxF,IAAI,MAAM,WAAW,GAAG;EACxB,MAAM,QAAQ,MAAM,WAAW,SAAS,KAAK,SAAS,SAAS,aAAa,CAAC;EAC7E,IAAI,UAAU,IAAI;EAClB,IAAI;EACJ,IAAI,MAAM,QAAQ,QAAQ,SAAS,MAAM;OACpC,IAAI,MAAM,QAAQ,OAAO,SAAS,MAAM,MAAM,SAAS;OAG1D,SAAS,OAAO,SADH,MAAM,QAAQ,UAAU,IAAI,MACV,MAAM,UAAU,MAAM;EAEvD,MAAM,eAAe;EACrB,OAAO,MAAM;CACf;AACF"}
|
|
@@ -0,0 +1,61 @@
|
|
|
1
|
+
"use client";
|
|
2
|
+
import { useLayoutEffect, useRef } from "react";
|
|
3
|
+
//#region src/components/navigation/use-rail-item-morph.ts
|
|
4
|
+
/** A CSS time (`500ms`, `.5s`) in ms; 0 for anything else. */
|
|
5
|
+
function toMs(value) {
|
|
6
|
+
const time = value.trim();
|
|
7
|
+
const amount = parseFloat(time);
|
|
8
|
+
if (Number.isNaN(amount)) return 0;
|
|
9
|
+
return time.endsWith("ms") ? amount : time.endsWith("s") ? amount * 1e3 : 0;
|
|
10
|
+
}
|
|
11
|
+
/** Each item's pill and its icon's top, relative to the rail. */
|
|
12
|
+
function measure(rail) {
|
|
13
|
+
const railTop = rail.getBoundingClientRect().top;
|
|
14
|
+
const tops = /* @__PURE__ */ new Map();
|
|
15
|
+
for (const pill of rail.querySelectorAll("[data-nav-item] [data-slot=\"pill\"]")) {
|
|
16
|
+
const icon = pill.querySelector("[data-slot=\"icon\"]");
|
|
17
|
+
if (icon) tops.set(pill, icon.getBoundingClientRect().top - railTop);
|
|
18
|
+
}
|
|
19
|
+
return tops;
|
|
20
|
+
}
|
|
21
|
+
/**
|
|
22
|
+
* Moves the rail's item pills from where their icons were to where they are as the rail
|
|
23
|
+
* expands or collapses, on the default spatial spring, as Compose's rail lerps each icon
|
|
24
|
+
* between its top and start positions (`NavigationItem.kt`; 2026-10-17). The items' heights
|
|
25
|
+
* and gaps spring in CSS (64 → 48px and 4 → 0px, `itemMinHeight` / `itemVerticalSpacedBy`),
|
|
26
|
+
* but the switch between an icon above its label and beside it moved every icon in one
|
|
27
|
+
* frame. Only the pills move (the `translate` property), never the rail's root; nothing
|
|
28
|
+
* moves under reduced motion, where the spatial spring is 0ms.
|
|
29
|
+
*
|
|
30
|
+
* Call `capture` while rendering the switch (the DOM still shows the old layout); the
|
|
31
|
+
* layout effect then plays the move from the captured positions.
|
|
32
|
+
*/
|
|
33
|
+
function useRailItemMorph(railRef, mode) {
|
|
34
|
+
const before = useRef(null);
|
|
35
|
+
const capture = () => {
|
|
36
|
+
if (railRef.current) before.current = measure(railRef.current);
|
|
37
|
+
};
|
|
38
|
+
useLayoutEffect(() => {
|
|
39
|
+
const rail = railRef.current;
|
|
40
|
+
const from = before.current;
|
|
41
|
+
before.current = null;
|
|
42
|
+
if (!rail || !from || typeof rail.animate !== "function") return;
|
|
43
|
+
const style = getComputedStyle(rail);
|
|
44
|
+
const duration = toMs(style.getPropertyValue("--md-sys-motion-spring-spatial-default-duration"));
|
|
45
|
+
if (duration <= 0) return;
|
|
46
|
+
const easing = style.getPropertyValue("--md-sys-motion-spring-spatial-default-easing").trim();
|
|
47
|
+
for (const [pill, top] of measure(rail)) {
|
|
48
|
+
const old = from.get(pill);
|
|
49
|
+
if (old === void 0 || Math.abs(old - top) < .5) continue;
|
|
50
|
+
pill.animate([{ translate: `0 ${old - top}px` }, { translate: "0 0" }], {
|
|
51
|
+
duration,
|
|
52
|
+
easing: easing || "ease"
|
|
53
|
+
});
|
|
54
|
+
}
|
|
55
|
+
}, [railRef, mode]);
|
|
56
|
+
return capture;
|
|
57
|
+
}
|
|
58
|
+
//#endregion
|
|
59
|
+
export { useRailItemMorph };
|
|
60
|
+
|
|
61
|
+
//# sourceMappingURL=use-rail-item-morph.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"use-rail-item-morph.js","names":[],"sources":["../../../src/components/navigation/use-rail-item-morph.ts"],"sourcesContent":["'use client';\n\nimport { useLayoutEffect, useRef, type RefObject } from 'react';\n\n/** A CSS time (`500ms`, `.5s`) in ms; 0 for anything else. */\nfunction toMs(value: string) {\n const time = value.trim();\n const amount = parseFloat(time);\n if (Number.isNaN(amount)) return 0;\n return time.endsWith('ms') ? amount : time.endsWith('s') ? amount * 1000 : 0;\n}\n\n/** Each item's pill and its icon's top, relative to the rail. */\nfunction measure(rail: HTMLElement) {\n const railTop = rail.getBoundingClientRect().top;\n const tops = new Map<HTMLElement, number>();\n for (const pill of rail.querySelectorAll<HTMLElement>('[data-nav-item] [data-slot=\"pill\"]')) {\n const icon = pill.querySelector('[data-slot=\"icon\"]');\n if (icon) tops.set(pill, icon.getBoundingClientRect().top - railTop);\n }\n return tops;\n}\n\n/**\n * Moves the rail's item pills from where their icons were to where they are as the rail\n * expands or collapses, on the default spatial spring, as Compose's rail lerps each icon\n * between its top and start positions (`NavigationItem.kt`; 2026-10-17). The items' heights\n * and gaps spring in CSS (64 → 48px and 4 → 0px, `itemMinHeight` / `itemVerticalSpacedBy`),\n * but the switch between an icon above its label and beside it moved every icon in one\n * frame. Only the pills move (the `translate` property), never the rail's root; nothing\n * moves under reduced motion, where the spatial spring is 0ms.\n *\n * Call `capture` while rendering the switch (the DOM still shows the old layout); the\n * layout effect then plays the move from the captured positions.\n */\nexport function useRailItemMorph(railRef: RefObject<HTMLElement | null>, mode: boolean) {\n const before = useRef<Map<HTMLElement, number> | null>(null);\n const capture = () => {\n if (railRef.current) before.current = measure(railRef.current);\n };\n useLayoutEffect(() => {\n const rail = railRef.current;\n const from = before.current;\n before.current = null;\n if (!rail || !from || typeof rail.animate !== 'function') return;\n const style = getComputedStyle(rail);\n const duration = toMs(\n style.getPropertyValue('--md-sys-motion-spring-spatial-default-duration'),\n );\n if (duration <= 0) return;\n const easing = style.getPropertyValue('--md-sys-motion-spring-spatial-default-easing').trim();\n for (const [pill, top] of measure(rail)) {\n const old = from.get(pill);\n if (old === undefined || Math.abs(old - top) < 0.5) continue;\n pill.animate([{ translate: `0 ${old - top}px` }, { translate: '0 0' }], {\n duration,\n easing: easing || 'ease',\n });\n }\n }, [railRef, mode]);\n return capture;\n}\n"],"mappings":";;;;AAKA,SAAS,KAAK,OAAe;CAC3B,MAAM,OAAO,MAAM,KAAK;CACxB,MAAM,SAAS,WAAW,IAAI;CAC9B,IAAI,OAAO,MAAM,MAAM,GAAG,OAAO;CACjC,OAAO,KAAK,SAAS,IAAI,IAAI,SAAS,KAAK,SAAS,GAAG,IAAI,SAAS,MAAO;AAC7E;;AAGA,SAAS,QAAQ,MAAmB;CAClC,MAAM,UAAU,KAAK,sBAAsB,CAAC,CAAC;CAC7C,MAAM,uBAAO,IAAI,IAAyB;CAC1C,KAAK,MAAM,QAAQ,KAAK,iBAA8B,sCAAoC,GAAG;EAC3F,MAAM,OAAO,KAAK,cAAc,sBAAoB;EACpD,IAAI,MAAM,KAAK,IAAI,MAAM,KAAK,sBAAsB,CAAC,CAAC,MAAM,OAAO;CACrE;CACA,OAAO;AACT;;;;;;;;;;;;;AAcA,SAAgB,iBAAiB,SAAwC,MAAe;CACtF,MAAM,SAAS,OAAwC,IAAI;CAC3D,MAAM,gBAAgB;EACpB,IAAI,QAAQ,SAAS,OAAO,UAAU,QAAQ,QAAQ,OAAO;CAC/D;CACA,sBAAsB;EACpB,MAAM,OAAO,QAAQ;EACrB,MAAM,OAAO,OAAO;EACpB,OAAO,UAAU;EACjB,IAAI,CAAC,QAAQ,CAAC,QAAQ,OAAO,KAAK,YAAY,YAAY;EAC1D,MAAM,QAAQ,iBAAiB,IAAI;EACnC,MAAM,WAAW,KACf,MAAM,iBAAiB,iDAAiD,CAC1E;EACA,IAAI,YAAY,GAAG;EACnB,MAAM,SAAS,MAAM,iBAAiB,+CAA+C,CAAC,CAAC,KAAK;EAC5F,KAAK,MAAM,CAAC,MAAM,QAAQ,QAAQ,IAAI,GAAG;GACvC,MAAM,MAAM,KAAK,IAAI,IAAI;GACzB,IAAI,QAAQ,KAAA,KAAa,KAAK,IAAI,MAAM,GAAG,IAAI,IAAK;GACpD,KAAK,QAAQ,CAAC,EAAE,WAAW,KAAK,MAAM,IAAI,IAAI,GAAG,EAAE,WAAW,MAAM,CAAC,GAAG;IACtE;IACA,QAAQ,UAAU;GACpB,CAAC;EACH;CACF,GAAG,CAAC,SAAS,IAAI,CAAC;CAClB,OAAO;AACT"}
|
|
@@ -0,0 +1,95 @@
|
|
|
1
|
+
import { ComponentPropsWithRef } from "react";
|
|
2
|
+
//#region src/components/progress/ProgressIndicator.d.ts
|
|
3
|
+
type Naming = {
|
|
4
|
+
/** Names the indicator ("Loading messages"). Required unless `aria-labelledby` is set. */
|
|
5
|
+
'aria-label': string;
|
|
6
|
+
/** The id of the visible text that names the indicator. Required unless `aria-label` is set. */
|
|
7
|
+
'aria-labelledby'?: string;
|
|
8
|
+
} | {
|
|
9
|
+
/** Names the indicator ("Loading messages"). Required unless `aria-labelledby` is set. */
|
|
10
|
+
'aria-label'?: string;
|
|
11
|
+
/** The id of the visible text that names the indicator. Required unless `aria-label` is set. */
|
|
12
|
+
'aria-labelledby': string;
|
|
13
|
+
};
|
|
14
|
+
interface SharedOwnProps {
|
|
15
|
+
/** Progress from 0 to 1; leave it out for an indeterminate indicator. */
|
|
16
|
+
value?: number;
|
|
17
|
+
/** The M3 Expressive wavy indicator. @default false */
|
|
18
|
+
wavy?: boolean;
|
|
19
|
+
/**
|
|
20
|
+
* Thickness of the active indicator in px. The spec's thick configuration is 8 (with the
|
|
21
|
+
* track); the indicator grows to fit, keeping room for the wave. @default 4
|
|
22
|
+
*/
|
|
23
|
+
thickness?: number;
|
|
24
|
+
/** Thickness of the track in px. @default the same as `thickness` */
|
|
25
|
+
trackThickness?: number;
|
|
26
|
+
/**
|
|
27
|
+
* Draw the track (and the linear stop dot). Remove it inside a button, colouring the
|
|
28
|
+
* indicator like the button's label: `classNames={{ indicator: 'stroke-current' }}`.
|
|
29
|
+
* @default true
|
|
30
|
+
*/
|
|
31
|
+
track?: boolean;
|
|
32
|
+
}
|
|
33
|
+
export interface LinearProgressIndicatorClassNames {
|
|
34
|
+
/** The outer element, which carries the `progressbar` role. */
|
|
35
|
+
root?: string;
|
|
36
|
+
/** The track: the line behind the active indicator. */
|
|
37
|
+
track?: string;
|
|
38
|
+
/** The active indicator, the line that shows progress. */
|
|
39
|
+
indicator?: string;
|
|
40
|
+
/** The stop dot at the end of a determinate track. */
|
|
41
|
+
stop?: string;
|
|
42
|
+
}
|
|
43
|
+
interface LinearOwnProps extends SharedOwnProps {
|
|
44
|
+
/** The dot at the end of a determinate track (Compose draws it). @default true */
|
|
45
|
+
stopIndicator?: boolean;
|
|
46
|
+
/** Classes for each part, by slot. `classNames.root` is merged with `className`. */
|
|
47
|
+
classNames?: LinearProgressIndicatorClassNames;
|
|
48
|
+
}
|
|
49
|
+
export type LinearProgressIndicatorProps = LinearOwnProps & Naming & Omit<ComponentPropsWithRef<'div'>, keyof LinearOwnProps | 'aria-label' | 'aria-labelledby' | 'children' | 'role'>;
|
|
50
|
+
/**
|
|
51
|
+
* M3 linear progress indicator: determinate (`value`) or indeterminate, flat or wavy, with a
|
|
52
|
+
* stop dot at the end of a determinate track. 240px wide by default; set the width with
|
|
53
|
+
* `className` (`w-full`). `thickness` and `trackThickness` set the strokes (4px by default).
|
|
54
|
+
* A wavy determinate indicator flattens below 10% and above 95%. It mirrors in right-to-left
|
|
55
|
+
* layouts. When `value` arrives on an indeterminate indicator, the moving line eases into it.
|
|
56
|
+
*
|
|
57
|
+
* @example
|
|
58
|
+
* <LinearProgressIndicator value={0.4} wavy aria-label="Uploading" className="w-full" />
|
|
59
|
+
*/
|
|
60
|
+
export declare function LinearProgressIndicator({ value, wavy, thickness, trackThickness, track: showTrack, stopIndicator: showStop, classNames, className, style, ref, ...rest }: LinearProgressIndicatorProps): import("react").JSX.Element;
|
|
61
|
+
export interface CircularProgressIndicatorClassNames {
|
|
62
|
+
/** The outer element, which carries the `progressbar` role. */
|
|
63
|
+
root?: string;
|
|
64
|
+
/** The track: the ring behind the active indicator. */
|
|
65
|
+
track?: string;
|
|
66
|
+
/** The active indicator, the arc that shows progress. */
|
|
67
|
+
indicator?: string;
|
|
68
|
+
}
|
|
69
|
+
interface CircularOwnProps extends SharedOwnProps {
|
|
70
|
+
/**
|
|
71
|
+
* The diameter in px. The spec: circular indicators "can range from 24dp to 240dp"; values
|
|
72
|
+
* outside that range are clamped. The strokes keep their `thickness`; the ring and its wave
|
|
73
|
+
* grow (more waves of the same length, as in Compose).
|
|
74
|
+
* @default 40, or 48 when wavy, plus any extra thickness
|
|
75
|
+
*/
|
|
76
|
+
size?: number;
|
|
77
|
+
/** Classes for each part, by slot. `classNames.root` is merged with `className`. */
|
|
78
|
+
classNames?: CircularProgressIndicatorClassNames;
|
|
79
|
+
}
|
|
80
|
+
export type CircularProgressIndicatorProps = CircularOwnProps & Naming & Omit<ComponentPropsWithRef<'div'>, keyof CircularOwnProps | 'aria-label' | 'aria-labelledby' | 'children' | 'role'>;
|
|
81
|
+
/**
|
|
82
|
+
* M3 circular progress indicator: determinate (`value`) or indeterminate, flat (40px) or wavy
|
|
83
|
+
* (48px), drawn clockwise from 12 o'clock over a track. A wavy indicator's wave travels
|
|
84
|
+
* around the ring. `thickness` and `trackThickness` set the strokes (4px by default); the spec's
|
|
85
|
+
* thick configuration (8px) makes it 44px, or 52px wavy. `size` sets the diameter (24–240px).
|
|
86
|
+
* It isn't mirrored in right-to-left
|
|
87
|
+
* layouts. For short waits, {@link LoadingIndicator} is recommended.
|
|
88
|
+
*
|
|
89
|
+
* @example
|
|
90
|
+
* <CircularProgressIndicator value={0.7} wavy aria-label="Downloading" />
|
|
91
|
+
* <CircularProgressIndicator aria-label="Loading" />
|
|
92
|
+
*/
|
|
93
|
+
export declare function CircularProgressIndicator({ value, wavy, size: sizeProp, thickness, trackThickness, track: showTrack, classNames, className, style, ref, ...rest }: CircularProgressIndicatorProps): import("react").JSX.Element;
|
|
94
|
+
//#endregion
|
|
95
|
+
//# sourceMappingURL=ProgressIndicator.d.ts.map
|