@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,377 @@
|
|
|
1
|
+
import { tv } from "../../utils/tv.js";
|
|
2
|
+
//#region src/components/dialog/dialog-styles.ts
|
|
3
|
+
/** The dialog root's placement, inline so it wins over consumer layout classes. */
|
|
4
|
+
const DIALOG_ROOT_STYLE = {
|
|
5
|
+
position: "fixed",
|
|
6
|
+
inset: 0
|
|
7
|
+
};
|
|
8
|
+
/** Variant definitions for {@link Dialog} and its parts. */
|
|
9
|
+
const dialogStyles = tv({
|
|
10
|
+
slots: {
|
|
11
|
+
scrim: [
|
|
12
|
+
"fixed inset-0 z-(--md-sys-z-scrim) bg-scrim/32 opacity-100",
|
|
13
|
+
"[transition-property:opacity]",
|
|
14
|
+
"[transition-duration:var(--md-sys-motion-spring-effects-slow-duration)]",
|
|
15
|
+
"[transition-timing-function:var(--md-sys-motion-spring-effects-slow-easing)]",
|
|
16
|
+
"starting:opacity-0",
|
|
17
|
+
"data-exiting:opacity-0",
|
|
18
|
+
"data-exiting:[transition-duration:var(--md-sys-motion-duration-short-3)]",
|
|
19
|
+
"data-exiting:[transition-timing-function:var(--md-sys-motion-easing-linear)]"
|
|
20
|
+
],
|
|
21
|
+
root: "z-(--md-sys-z-dialog)",
|
|
22
|
+
positioner: "fixed inset-0 z-(--md-sys-z-dialog) flex p-[24px] medium:p-[56px]",
|
|
23
|
+
motion: [
|
|
24
|
+
"flex max-h-full max-w-full",
|
|
25
|
+
"[--m3-dialog-corner:var(--md-comp-dialog-container-shape,var(--md-sys-shape-corner-extra-large))]",
|
|
26
|
+
"[--m3-dialog-open-clip:inset(-32px_round_calc(var(--m3-dialog-corner)_+_32px))]",
|
|
27
|
+
"[--m3-dialog-enter-clip:inset(0_0_100%_round_var(--m3-dialog-corner))]",
|
|
28
|
+
"[--m3-dialog-exit-clip:inset(0_0_65%_round_var(--m3-dialog-corner))]",
|
|
29
|
+
"[--m3-dialog-slide:0_-50px] [--m3-dialog-scale-origin:center]",
|
|
30
|
+
"translate-none opacity-100 [clip-path:var(--m3-dialog-open-clip)]",
|
|
31
|
+
"starting:[translate:var(--m3-dialog-slide)] starting:opacity-0",
|
|
32
|
+
"starting:[clip-path:var(--m3-dialog-enter-clip)]",
|
|
33
|
+
"data-exiting:[translate:var(--m3-dialog-slide)] data-exiting:opacity-0",
|
|
34
|
+
"data-exiting:[clip-path:var(--m3-dialog-exit-clip)]",
|
|
35
|
+
"motion-reduce:data-exiting:translate-none",
|
|
36
|
+
"motion-reduce:data-exiting:[clip-path:var(--m3-dialog-open-clip)]",
|
|
37
|
+
"[transition-property:opacity,translate,clip-path] motion-reduce:[transition-property:opacity]",
|
|
38
|
+
"[transition-duration:var(--md-sys-motion-spring-effects-fast-duration),var(--md-sys-motion-spring-spatial-default-duration),var(--md-sys-motion-spring-spatial-default-duration)]",
|
|
39
|
+
"[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing),var(--md-sys-motion-spring-spatial-default-easing),var(--md-sys-motion-spring-spatial-default-easing)]",
|
|
40
|
+
"data-exiting:[transition-duration:var(--md-sys-motion-duration-short-1),var(--md-sys-motion-duration-short-3),var(--md-sys-motion-duration-short-3)]",
|
|
41
|
+
"data-exiting:[transition-timing-function:var(--md-sys-motion-easing-linear),var(--md-sys-motion-easing-emphasized-accelerate),var(--md-sys-motion-easing-emphasized-accelerate)]",
|
|
42
|
+
"data-exiting:[transition-delay:var(--md-sys-motion-duration-short-2),0s,0s]",
|
|
43
|
+
"motion-reduce:data-exiting:[transition-delay:0s]",
|
|
44
|
+
"motion-reduce:data-exiting:[transition-duration:var(--md-sys-motion-duration-short-3)]"
|
|
45
|
+
],
|
|
46
|
+
parts: "",
|
|
47
|
+
panel: [
|
|
48
|
+
"flex max-h-full min-w-[min(280px,calc(100vw-48px))] max-w-[560px] flex-col p-[24px]",
|
|
49
|
+
"rounded-[var(--_md-comp-dialog-container-shape)] bg-[var(--_md-comp-dialog-container-color)]",
|
|
50
|
+
"text-on-surface shadow-[shadow:var(--_md-comp-dialog-container-elevation)]",
|
|
51
|
+
"outline-none",
|
|
52
|
+
"forced-colors:outline-solid forced-colors:outline-1 forced-colors:outline-[CanvasText]"
|
|
53
|
+
],
|
|
54
|
+
icon: ["mx-auto inline-flex pb-[16px] [&>svg]:size-[24px]", "text-[color:var(--_md-comp-dialog-with-icon-icon-color)]"],
|
|
55
|
+
title: ["pb-[16px] text-headline-small font-brand", "text-[color:var(--_md-comp-dialog-headline-color)]"],
|
|
56
|
+
header: "",
|
|
57
|
+
headerButton: "",
|
|
58
|
+
close: "[--md-comp-icon-button-icon-color:var(--md-sys-color-on-surface)]",
|
|
59
|
+
content: [
|
|
60
|
+
"min-h-0 flex-1 overflow-y-auto pb-[24px] text-body-medium",
|
|
61
|
+
"text-[color:var(--_md-comp-dialog-supporting-text-color)]",
|
|
62
|
+
"focus-ring"
|
|
63
|
+
],
|
|
64
|
+
actions: ["flex flex-wrap-reverse items-center justify-end gap-[8px] [--m3-dialog-actions-stack:1]", "data-stacked:flex-wrap"]
|
|
65
|
+
},
|
|
66
|
+
variants: {
|
|
67
|
+
hasIcon: {
|
|
68
|
+
true: { title: "text-center" },
|
|
69
|
+
false: { title: "text-start" }
|
|
70
|
+
},
|
|
71
|
+
placement: {
|
|
72
|
+
center: { positioner: "items-center justify-center" },
|
|
73
|
+
top: {
|
|
74
|
+
positioner: "items-start justify-center",
|
|
75
|
+
motion: "[--m3-dialog-scale-origin:top]"
|
|
76
|
+
},
|
|
77
|
+
bottom: {
|
|
78
|
+
positioner: "items-end justify-center",
|
|
79
|
+
motion: [
|
|
80
|
+
"[--m3-dialog-enter-clip:inset(100%_0_0_round_var(--m3-dialog-corner))]",
|
|
81
|
+
"[--m3-dialog-exit-clip:inset(65%_0_0_round_var(--m3-dialog-corner))]",
|
|
82
|
+
"[--m3-dialog-slide:0_50px] [--m3-dialog-scale-origin:bottom]"
|
|
83
|
+
]
|
|
84
|
+
},
|
|
85
|
+
start: {
|
|
86
|
+
positioner: "items-center justify-start",
|
|
87
|
+
motion: [
|
|
88
|
+
"[--m3-dialog-enter-clip:inset(0_100%_0_0_round_var(--m3-dialog-corner))]",
|
|
89
|
+
"[--m3-dialog-exit-clip:inset(0_65%_0_0_round_var(--m3-dialog-corner))]",
|
|
90
|
+
"[--m3-dialog-slide:-50px_0] [--m3-dialog-scale-origin:left]",
|
|
91
|
+
"rtl:[--m3-dialog-enter-clip:inset(0_0_0_100%_round_var(--m3-dialog-corner))]",
|
|
92
|
+
"rtl:[--m3-dialog-exit-clip:inset(0_0_0_65%_round_var(--m3-dialog-corner))]",
|
|
93
|
+
"rtl:[--m3-dialog-slide:50px_0] rtl:[--m3-dialog-scale-origin:right]"
|
|
94
|
+
]
|
|
95
|
+
},
|
|
96
|
+
end: {
|
|
97
|
+
positioner: "items-center justify-end",
|
|
98
|
+
motion: [
|
|
99
|
+
"[--m3-dialog-enter-clip:inset(0_0_0_100%_round_var(--m3-dialog-corner))]",
|
|
100
|
+
"[--m3-dialog-exit-clip:inset(0_0_0_65%_round_var(--m3-dialog-corner))]",
|
|
101
|
+
"[--m3-dialog-slide:50px_0] [--m3-dialog-scale-origin:right]",
|
|
102
|
+
"rtl:[--m3-dialog-enter-clip:inset(0_100%_0_0_round_var(--m3-dialog-corner))]",
|
|
103
|
+
"rtl:[--m3-dialog-exit-clip:inset(0_65%_0_0_round_var(--m3-dialog-corner))]",
|
|
104
|
+
"rtl:[--m3-dialog-slide:-50px_0] rtl:[--m3-dialog-scale-origin:left]"
|
|
105
|
+
]
|
|
106
|
+
}
|
|
107
|
+
},
|
|
108
|
+
fullScreen: {
|
|
109
|
+
never: {
|
|
110
|
+
headerButton: "hidden",
|
|
111
|
+
parts: [
|
|
112
|
+
"motion-safe:*:starting:opacity-0 motion-safe:data-exiting:*:opacity-0",
|
|
113
|
+
"*:[transition-property:opacity]",
|
|
114
|
+
"*:[transition-duration:var(--md-sys-motion-spring-effects-default-duration)]",
|
|
115
|
+
"*:[transition-timing-function:var(--md-sys-motion-spring-effects-default-easing)]",
|
|
116
|
+
"*:[transition-delay:var(--md-sys-motion-duration-short-1)]",
|
|
117
|
+
"*:data-[slot=actions]:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]",
|
|
118
|
+
"*:data-[slot=actions]:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing)]",
|
|
119
|
+
"*:data-[slot=actions]:[transition-delay:var(--md-sys-motion-duration-short-3)]",
|
|
120
|
+
"data-exiting:*:[transition-duration:var(--md-sys-motion-duration-short-2)]",
|
|
121
|
+
"data-exiting:*:[transition-timing-function:var(--md-sys-motion-easing-linear)]",
|
|
122
|
+
"data-exiting:*:[transition-delay:0s] data-exiting:*:data-[slot=actions]:[transition-delay:0s]",
|
|
123
|
+
"data-exiting:*:data-[slot=actions]:[transition-duration:var(--md-sys-motion-duration-short-2)]",
|
|
124
|
+
"data-exiting:*:data-[slot=actions]:[transition-timing-function:var(--md-sys-motion-easing-linear)]"
|
|
125
|
+
]
|
|
126
|
+
},
|
|
127
|
+
always: {
|
|
128
|
+
positioner: "p-0 medium:p-0",
|
|
129
|
+
motion: [
|
|
130
|
+
"size-full [--m3-dialog-slide:0_48px]",
|
|
131
|
+
"[--m3-dialog-open-clip:none] [--m3-dialog-enter-clip:none] [--m3-dialog-exit-clip:none]",
|
|
132
|
+
"[transition-duration:var(--md-sys-motion-spring-effects-slow-duration),var(--md-sys-motion-spring-spatial-slow-duration),var(--md-sys-motion-spring-spatial-slow-duration)]",
|
|
133
|
+
"[transition-timing-function:var(--md-sys-motion-spring-effects-slow-easing),var(--md-sys-motion-spring-spatial-slow-easing),var(--md-sys-motion-spring-spatial-slow-easing)]",
|
|
134
|
+
"data-exiting:[transition-delay:0s]",
|
|
135
|
+
"data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]",
|
|
136
|
+
"data-exiting:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing)]"
|
|
137
|
+
],
|
|
138
|
+
panel: ["size-full max-h-none max-w-none rounded-none p-0 shadow-none", "bg-surface-container-high"],
|
|
139
|
+
header: "flex h-[56px] shrink-0 items-center gap-[4px] ps-[4px] pe-[12px]",
|
|
140
|
+
title: "min-w-0 flex-1 truncate ps-[4px] pb-0 text-start text-title-large",
|
|
141
|
+
content: "px-[24px] pt-[24px]",
|
|
142
|
+
actions: "hidden"
|
|
143
|
+
},
|
|
144
|
+
compact: {
|
|
145
|
+
positioner: "max-medium:p-0",
|
|
146
|
+
motion: [
|
|
147
|
+
"max-medium:size-full max-medium:[--m3-dialog-slide:0_48px]",
|
|
148
|
+
"max-medium:[--m3-dialog-open-clip:none] max-medium:[--m3-dialog-enter-clip:none]",
|
|
149
|
+
"max-medium:[--m3-dialog-exit-clip:none]",
|
|
150
|
+
"max-medium:[transition-duration:var(--md-sys-motion-spring-effects-slow-duration),var(--md-sys-motion-spring-spatial-slow-duration),var(--md-sys-motion-spring-spatial-slow-duration)]",
|
|
151
|
+
"max-medium:[transition-timing-function:var(--md-sys-motion-spring-effects-slow-easing),var(--md-sys-motion-spring-spatial-slow-easing),var(--md-sys-motion-spring-spatial-slow-easing)]",
|
|
152
|
+
"max-medium:data-exiting:[transition-delay:0s]",
|
|
153
|
+
"max-medium:data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]",
|
|
154
|
+
"max-medium:data-exiting:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing)]"
|
|
155
|
+
],
|
|
156
|
+
parts: [
|
|
157
|
+
"medium:motion-safe:*:starting:opacity-0 medium:motion-safe:data-exiting:*:opacity-0",
|
|
158
|
+
"medium:*:[transition-property:opacity]",
|
|
159
|
+
"medium:*:[transition-duration:var(--md-sys-motion-spring-effects-default-duration)]",
|
|
160
|
+
"medium:*:[transition-timing-function:var(--md-sys-motion-spring-effects-default-easing)]",
|
|
161
|
+
"medium:*:[transition-delay:var(--md-sys-motion-duration-short-1)]",
|
|
162
|
+
"medium:*:data-[slot=actions]:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]",
|
|
163
|
+
"medium:*:data-[slot=actions]:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing)]",
|
|
164
|
+
"medium:*:data-[slot=actions]:[transition-delay:var(--md-sys-motion-duration-short-3)]",
|
|
165
|
+
"medium:data-exiting:*:[transition-duration:var(--md-sys-motion-duration-short-2)]",
|
|
166
|
+
"medium:data-exiting:*:[transition-timing-function:var(--md-sys-motion-easing-linear)]",
|
|
167
|
+
"medium:data-exiting:*:[transition-delay:0s]",
|
|
168
|
+
"medium:data-exiting:*:data-[slot=actions]:[transition-delay:0s]",
|
|
169
|
+
"medium:data-exiting:*:data-[slot=actions]:[transition-duration:var(--md-sys-motion-duration-short-2)]",
|
|
170
|
+
"medium:data-exiting:*:data-[slot=actions]:[transition-timing-function:var(--md-sys-motion-easing-linear)]"
|
|
171
|
+
],
|
|
172
|
+
panel: [
|
|
173
|
+
"max-medium:size-full max-medium:max-h-none max-medium:max-w-none",
|
|
174
|
+
"max-medium:rounded-none max-medium:p-0 max-medium:shadow-none",
|
|
175
|
+
"max-medium:bg-surface-container-high"
|
|
176
|
+
],
|
|
177
|
+
header: ["max-medium:flex max-medium:h-[56px] max-medium:shrink-0 max-medium:items-center", "max-medium:gap-[4px] max-medium:ps-[4px] max-medium:pe-[12px]"],
|
|
178
|
+
headerButton: "medium:hidden",
|
|
179
|
+
title: ["max-medium:min-w-0 max-medium:flex-1 max-medium:truncate max-medium:ps-[4px]", "max-medium:pb-0 max-medium:text-start max-medium:text-title-large"],
|
|
180
|
+
content: "max-medium:px-[24px] max-medium:pt-[24px]",
|
|
181
|
+
actions: "max-medium:hidden"
|
|
182
|
+
}
|
|
183
|
+
},
|
|
184
|
+
/** Full screen without a header action: the actions form a 56px bottom bar. */
|
|
185
|
+
bottomBar: {
|
|
186
|
+
true: {},
|
|
187
|
+
false: {}
|
|
188
|
+
},
|
|
189
|
+
/** A divider under the full-screen header. */
|
|
190
|
+
divider: {
|
|
191
|
+
true: {},
|
|
192
|
+
false: {}
|
|
193
|
+
},
|
|
194
|
+
/** The basic dialog's optional dividers above and below `DialogContent`. */
|
|
195
|
+
dividers: {
|
|
196
|
+
true: {},
|
|
197
|
+
false: {}
|
|
198
|
+
},
|
|
199
|
+
/** A container transform from a trigger (`origin`) into the full-screen dialog. */
|
|
200
|
+
origin: {
|
|
201
|
+
true: {},
|
|
202
|
+
false: {}
|
|
203
|
+
},
|
|
204
|
+
/**
|
|
205
|
+
* The basic dialog's enter and exit: `reveal`, the M3 dialog motion above, or `scale`,
|
|
206
|
+
* the original pop (see the compound variants). Full-screen dialogs ignore it.
|
|
207
|
+
*/
|
|
208
|
+
transition: {
|
|
209
|
+
reveal: {},
|
|
210
|
+
scale: {}
|
|
211
|
+
},
|
|
212
|
+
/** No enter or exit motion: the dialog, its parts and the scrim appear and go at once. */
|
|
213
|
+
instant: {
|
|
214
|
+
true: {
|
|
215
|
+
scrim: "[transition-property:none]!",
|
|
216
|
+
motion: "[transition-property:none]!",
|
|
217
|
+
panel: "[transition-property:none]!",
|
|
218
|
+
parts: "*:[transition-property:none]!"
|
|
219
|
+
},
|
|
220
|
+
false: {}
|
|
221
|
+
}
|
|
222
|
+
},
|
|
223
|
+
compoundVariants: [
|
|
224
|
+
{
|
|
225
|
+
fullScreen: "always",
|
|
226
|
+
bottomBar: true,
|
|
227
|
+
class: { actions: "flex h-[56px] shrink-0 flex-nowrap px-[24px] [--m3-dialog-actions-stack:0]" }
|
|
228
|
+
},
|
|
229
|
+
{
|
|
230
|
+
fullScreen: "compact",
|
|
231
|
+
bottomBar: true,
|
|
232
|
+
class: { actions: "max-medium:flex max-medium:h-[56px] max-medium:shrink-0 max-medium:flex-nowrap max-medium:px-[24px] max-medium:[--m3-dialog-actions-stack:0]" }
|
|
233
|
+
},
|
|
234
|
+
{
|
|
235
|
+
fullScreen: "always",
|
|
236
|
+
divider: true,
|
|
237
|
+
class: { header: "border-b border-outline-variant" }
|
|
238
|
+
},
|
|
239
|
+
{
|
|
240
|
+
fullScreen: "compact",
|
|
241
|
+
divider: true,
|
|
242
|
+
class: { header: "max-medium:border-b max-medium:border-outline-variant" }
|
|
243
|
+
},
|
|
244
|
+
{
|
|
245
|
+
fullScreen: "never",
|
|
246
|
+
dividers: true,
|
|
247
|
+
class: { content: "-mx-[24px] mb-[24px] border-y border-outline-variant px-[24px] py-[8px]" }
|
|
248
|
+
},
|
|
249
|
+
{
|
|
250
|
+
fullScreen: "compact",
|
|
251
|
+
dividers: true,
|
|
252
|
+
class: { content: ["medium:-mx-[24px] medium:mb-[24px] medium:border-y medium:border-outline-variant", "medium:px-[24px] medium:py-[8px]"] }
|
|
253
|
+
},
|
|
254
|
+
{
|
|
255
|
+
fullScreen: "never",
|
|
256
|
+
transition: "scale",
|
|
257
|
+
class: {
|
|
258
|
+
scrim: [
|
|
259
|
+
"[transition-duration:var(--md-sys-motion-spring-effects-default-duration)]",
|
|
260
|
+
"[transition-timing-function:var(--md-sys-motion-spring-effects-default-easing)]",
|
|
261
|
+
"data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]",
|
|
262
|
+
"data-exiting:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing)]"
|
|
263
|
+
],
|
|
264
|
+
motion: [
|
|
265
|
+
"[--m3-dialog-slide:0_0] [--m3-dialog-open-clip:none]",
|
|
266
|
+
"[--m3-dialog-enter-clip:none] [--m3-dialog-exit-clip:none]",
|
|
267
|
+
"origin-(--m3-dialog-scale-origin) scale-none starting:scale-90 data-exiting:scale-95",
|
|
268
|
+
"motion-reduce:data-exiting:scale-none",
|
|
269
|
+
"[transition-property:opacity,scale] motion-reduce:[transition-property:opacity]",
|
|
270
|
+
"[transition-duration:var(--md-sys-motion-spring-effects-default-duration),var(--md-sys-motion-spring-spatial-default-duration)]",
|
|
271
|
+
"[transition-timing-function:var(--md-sys-motion-spring-effects-default-easing),var(--md-sys-motion-spring-spatial-default-easing)]",
|
|
272
|
+
"data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration),var(--md-sys-motion-spring-spatial-fast-duration)]",
|
|
273
|
+
"data-exiting:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing),var(--md-sys-motion-spring-spatial-fast-easing)]",
|
|
274
|
+
"data-exiting:[transition-delay:0s]"
|
|
275
|
+
]
|
|
276
|
+
}
|
|
277
|
+
},
|
|
278
|
+
{
|
|
279
|
+
fullScreen: "compact",
|
|
280
|
+
transition: "scale",
|
|
281
|
+
class: {
|
|
282
|
+
scrim: [
|
|
283
|
+
"medium:[transition-duration:var(--md-sys-motion-spring-effects-default-duration)]",
|
|
284
|
+
"medium:[transition-timing-function:var(--md-sys-motion-spring-effects-default-easing)]",
|
|
285
|
+
"medium:data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]",
|
|
286
|
+
"medium:data-exiting:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing)]"
|
|
287
|
+
],
|
|
288
|
+
motion: [
|
|
289
|
+
"medium:[--m3-dialog-slide:0_0] medium:[--m3-dialog-open-clip:none]",
|
|
290
|
+
"medium:[--m3-dialog-enter-clip:none] medium:[--m3-dialog-exit-clip:none]",
|
|
291
|
+
"medium:origin-(--m3-dialog-scale-origin) medium:scale-none",
|
|
292
|
+
"medium:starting:scale-90 medium:data-exiting:scale-95",
|
|
293
|
+
"medium:motion-reduce:data-exiting:scale-none",
|
|
294
|
+
"medium:[transition-property:opacity,scale]",
|
|
295
|
+
"medium:motion-reduce:[transition-property:opacity]",
|
|
296
|
+
"medium:[transition-duration:var(--md-sys-motion-spring-effects-default-duration),var(--md-sys-motion-spring-spatial-default-duration)]",
|
|
297
|
+
"medium:[transition-timing-function:var(--md-sys-motion-spring-effects-default-easing),var(--md-sys-motion-spring-spatial-default-easing)]",
|
|
298
|
+
"medium:data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration),var(--md-sys-motion-spring-spatial-fast-duration)]",
|
|
299
|
+
"medium:data-exiting:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing),var(--md-sys-motion-spring-spatial-fast-easing)]",
|
|
300
|
+
"medium:data-exiting:[transition-delay:0s]"
|
|
301
|
+
]
|
|
302
|
+
}
|
|
303
|
+
},
|
|
304
|
+
{
|
|
305
|
+
fullScreen: "always",
|
|
306
|
+
origin: true,
|
|
307
|
+
class: {
|
|
308
|
+
motion: [
|
|
309
|
+
"[--m3-dialog-slide:0_0] [--m3-dialog-open-clip:inset(0_round_0)]",
|
|
310
|
+
"[--m3-dialog-enter-clip:var(--m3-dialog-origin)] [--m3-dialog-exit-clip:var(--m3-dialog-origin)]",
|
|
311
|
+
"[transition-duration:var(--md-sys-motion-spring-effects-fast-duration),var(--md-sys-motion-spring-spatial-slow-duration),var(--md-sys-motion-spring-spatial-slow-duration)]",
|
|
312
|
+
"[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing),var(--md-sys-motion-spring-spatial-slow-easing),var(--md-sys-motion-spring-spatial-slow-easing)]",
|
|
313
|
+
"data-exiting:[transition-duration:var(--md-sys-motion-duration-short-2),var(--md-sys-motion-duration-medium-1),var(--md-sys-motion-duration-medium-1)]",
|
|
314
|
+
"data-exiting:[transition-timing-function:var(--md-sys-motion-easing-linear),var(--md-sys-motion-easing-emphasized-accelerate),var(--md-sys-motion-easing-emphasized-accelerate)]",
|
|
315
|
+
"data-exiting:[transition-delay:var(--md-sys-motion-duration-short-3),0s,0s]",
|
|
316
|
+
"motion-reduce:data-exiting:[transition-delay:0s]"
|
|
317
|
+
],
|
|
318
|
+
panel: [
|
|
319
|
+
"[transition-property:background-color] motion-reduce:[transition-property:none]",
|
|
320
|
+
"[transition-duration:var(--md-sys-motion-spring-effects-slow-duration)]",
|
|
321
|
+
"[transition-timing-function:var(--md-sys-motion-spring-effects-slow-easing)]",
|
|
322
|
+
"starting:bg-(--m3-dialog-origin-color) motion-safe:data-exiting:bg-(--m3-dialog-origin-color)",
|
|
323
|
+
"data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]",
|
|
324
|
+
"*:[transition-property:opacity] *:starting:opacity-0 data-exiting:*:opacity-0",
|
|
325
|
+
"*:[transition-duration:var(--md-sys-motion-spring-effects-slow-duration)]",
|
|
326
|
+
"*:[transition-timing-function:var(--md-sys-motion-spring-effects-slow-easing)]"
|
|
327
|
+
]
|
|
328
|
+
}
|
|
329
|
+
},
|
|
330
|
+
{
|
|
331
|
+
fullScreen: "compact",
|
|
332
|
+
origin: true,
|
|
333
|
+
class: {
|
|
334
|
+
motion: [
|
|
335
|
+
"max-medium:[--m3-dialog-slide:0_0] max-medium:[--m3-dialog-open-clip:inset(0_round_0)]",
|
|
336
|
+
"max-medium:[--m3-dialog-enter-clip:var(--m3-dialog-origin)]",
|
|
337
|
+
"max-medium:[--m3-dialog-exit-clip:var(--m3-dialog-origin)]",
|
|
338
|
+
"max-medium:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration),var(--md-sys-motion-spring-spatial-slow-duration),var(--md-sys-motion-spring-spatial-slow-duration)]",
|
|
339
|
+
"max-medium:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing),var(--md-sys-motion-spring-spatial-slow-easing),var(--md-sys-motion-spring-spatial-slow-easing)]",
|
|
340
|
+
"max-medium:data-exiting:[transition-duration:var(--md-sys-motion-duration-short-2),var(--md-sys-motion-duration-medium-1),var(--md-sys-motion-duration-medium-1)]",
|
|
341
|
+
"max-medium:data-exiting:[transition-timing-function:var(--md-sys-motion-easing-linear),var(--md-sys-motion-easing-emphasized-accelerate),var(--md-sys-motion-easing-emphasized-accelerate)]",
|
|
342
|
+
"max-medium:data-exiting:[transition-delay:var(--md-sys-motion-duration-short-3),0s,0s]",
|
|
343
|
+
"max-medium:motion-reduce:data-exiting:[transition-duration:var(--md-sys-motion-duration-short-3)]",
|
|
344
|
+
"max-medium:motion-reduce:data-exiting:[transition-delay:0s]"
|
|
345
|
+
],
|
|
346
|
+
panel: [
|
|
347
|
+
"max-medium:[transition-property:background-color]",
|
|
348
|
+
"max-medium:motion-reduce:[transition-property:none]",
|
|
349
|
+
"max-medium:[transition-duration:var(--md-sys-motion-spring-effects-slow-duration)]",
|
|
350
|
+
"max-medium:[transition-timing-function:var(--md-sys-motion-spring-effects-slow-easing)]",
|
|
351
|
+
"max-medium:starting:bg-(--m3-dialog-origin-color)",
|
|
352
|
+
"max-medium:motion-safe:data-exiting:bg-(--m3-dialog-origin-color)",
|
|
353
|
+
"max-medium:data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]",
|
|
354
|
+
"max-medium:*:[transition-property:opacity] max-medium:*:starting:opacity-0",
|
|
355
|
+
"max-medium:data-exiting:*:opacity-0",
|
|
356
|
+
"max-medium:*:[transition-duration:var(--md-sys-motion-spring-effects-slow-duration)]",
|
|
357
|
+
"max-medium:*:[transition-timing-function:var(--md-sys-motion-spring-effects-slow-easing)]"
|
|
358
|
+
]
|
|
359
|
+
}
|
|
360
|
+
}
|
|
361
|
+
],
|
|
362
|
+
defaultVariants: {
|
|
363
|
+
dividers: false,
|
|
364
|
+
origin: false,
|
|
365
|
+
instant: false,
|
|
366
|
+
transition: "reveal",
|
|
367
|
+
hasIcon: false,
|
|
368
|
+
fullScreen: "never",
|
|
369
|
+
placement: "center",
|
|
370
|
+
bottomBar: false,
|
|
371
|
+
divider: false
|
|
372
|
+
}
|
|
373
|
+
});
|
|
374
|
+
//#endregion
|
|
375
|
+
export { DIALOG_ROOT_STYLE, dialogStyles };
|
|
376
|
+
|
|
377
|
+
//# sourceMappingURL=dialog-styles.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dialog-styles.js","names":[],"sources":["../../../src/components/dialog/dialog-styles.ts"],"sourcesContent":["import { tv, type VariantProps } from '../../utils/tv';\n\n/*\n * Values follow Compose Material 3 (AlertDialog.kt and DialogTokens): 280–560px wide (the\n * minimum capped by the window's 24px margins), 24px padding, 28px corners,\n * surface-container-high at elevation 3, a 24px secondary icon and the title 16px apart, the\n * title centred when there is an icon, 24px below the supporting text, 8px between actions,\n * and stacked actions with the confirming action on top. Optional dividers above and below\n * the content are 1px `outline-variant`. The scrim is `scrim` at 32% (M3).\n *\n * Motion (2026-10-14): Compose has no dialog motion of its own (the platform animates\n * windows), so the basic dialog follows the M3 dialog enter and exit as Material Web encodes\n * it, mapped onto the M3 Expressive springs (spatial for movement and size, effects for\n * opacity). Entering, the dialog slides 50px away from the window edge it sits against\n * (downward when centred), its container grows from that edge from 0 to its full size (a\n * clip on a library-owned wrapper, so text is never shown outside the container and the\n * spec's 0 start is kept), and it fades in on the fast effects spring while the scrim fades\n * in on the slow one; the headline, icon and supporting text fade in after 50ms and the\n * actions after 150ms. Leaving follows the reference's close timing exactly, on M3's\n * emphasized-accelerate easing and duration tokens: the parts fade out over 100ms, the\n * dialog slides back 50px and its container shrinks to 35% over 150ms (slow at first, so\n * it is still moving and shrinking until it is gone), the container fades out from 100ms to\n * 150ms, and the scrim fades out over 150ms. Reduced motion keeps only the\n * fades of the dialog and the scrim; `instant` turns all of it off.\n * The positioner keeps 24px from the window's edges on compact windows and the spec's 56px\n * on wider ones, and `placement` aligns the dialog in it.\n *\n * Full-screen dialogs follow the M3 dialog spec's full-screen type: the panel fills the\n * window on `surface-container-high` with no corners, elevation or padding; a 56px header\n * holds the `on-surface` close icon button, the `title-large` headline and the confirming\n * text button (with an optional `outline-variant` divider), and the content is padded 24px\n * at the top and sides. With a header action `DialogActions` are hidden; without one they\n * form a 56px bottom action bar. The panel slides up 48px and fades in on the slow springs\n * (the spec's speed for full-screen animations), or, with an `origin`, grows out of it (a\n * container transform). `fullScreen: 'compact'` applies all of this only below 600px (the M3\n * compact window class) and is a basic dialog otherwise.\n *\n * The basic dialog's container colour, corners and shadow, and the icon, title and supporting\n * text colours, come from the dialog's component tokens (`dialog-tokens.ts`,\n * `--md-comp-dialog-*`); the panel carries `data-tokens=\"md-comp-dialog\"`, and the parts read\n * one private variable each. A full-screen panel keeps its own `surface-container-high`. A\n * consumer class (`bg-surface-container`) still wins. Every class is written out in full.\n */\n\n/** The dialog root's placement, inline so it wins over consumer layout classes. */\nexport const DIALOG_ROOT_STYLE = { position: 'fixed', inset: 0 } as const;\n\n/** Variant definitions for {@link Dialog} and its parts. */\nexport const dialogStyles = tv({\n slots: {\n scrim: [\n 'fixed inset-0 z-(--md-sys-z-scrim) bg-scrim/32 opacity-100',\n '[transition-property:opacity]',\n '[transition-duration:var(--md-sys-motion-spring-effects-slow-duration)]',\n '[transition-timing-function:var(--md-sys-motion-spring-effects-slow-easing)]',\n 'starting:opacity-0',\n 'data-exiting:opacity-0',\n 'data-exiting:[transition-duration:var(--md-sys-motion-duration-short-3)]',\n 'data-exiting:[transition-timing-function:var(--md-sys-motion-easing-linear)]',\n ],\n // The dialog's outermost element, which takes the consumer's `className` and `style`. It\n // covers the window through an inline `position: fixed; inset: 0` (`DIALOG_ROOT_STYLE`),\n // which a consumer class can't move: a layout class such as `static` or `absolute top-24`\n // never puts the dialog in the page's flow or out of the window.\n root: 'z-(--md-sys-z-dialog)',\n positioner: 'fixed inset-0 z-(--md-sys-z-dialog) flex p-[24px] medium:p-[56px]',\n /*\n * The library-owned wrapper that moves: it slides 50px (`--m3-dialog-slide`), its clip\n * grows the container (`--m3-dialog-enter-clip` → `--m3-dialog-open-clip`, which rests\n * 32px outside the panel so the shadow shows, its corners concentric with the panel's\n * `--m3-dialog-corner`) and it fades. Leaving, the clip shrinks to 35%\n * (`--m3-dialog-exit-clip`) and the fade waits 100ms for the parts to fade first. The\n * exit uses the reference's curves rather than springs (2026-10-14): the slide and shrink\n * run 150ms on emphasized-accelerate, which never overshoots and keeps moving until the\n * fade (50ms, linear, after 100ms) has ended. A spring front-loads the motion: the\n * expressive spatial one overshot past 50px and below 35%, and the critically damped\n * effects one finished shrinking before the fade, leaving a still 35% box fading. The\n * clip's sides open from the panel's edges to the shadow's 32px together with its corner\n * radius, so the growing edge keeps the panel's corners on every frame.\n */\n motion: [\n 'flex max-h-full max-w-full',\n '[--m3-dialog-corner:var(--md-comp-dialog-container-shape,var(--md-sys-shape-corner-extra-large))]',\n '[--m3-dialog-open-clip:inset(-32px_round_calc(var(--m3-dialog-corner)_+_32px))]',\n '[--m3-dialog-enter-clip:inset(0_0_100%_round_var(--m3-dialog-corner))]',\n '[--m3-dialog-exit-clip:inset(0_0_65%_round_var(--m3-dialog-corner))]',\n '[--m3-dialog-slide:0_-50px] [--m3-dialog-scale-origin:center]',\n 'translate-none opacity-100 [clip-path:var(--m3-dialog-open-clip)]',\n 'starting:[translate:var(--m3-dialog-slide)] starting:opacity-0',\n 'starting:[clip-path:var(--m3-dialog-enter-clip)]',\n 'data-exiting:[translate:var(--m3-dialog-slide)] data-exiting:opacity-0',\n 'data-exiting:[clip-path:var(--m3-dialog-exit-clip)]',\n 'motion-reduce:data-exiting:translate-none',\n 'motion-reduce:data-exiting:[clip-path:var(--m3-dialog-open-clip)]',\n '[transition-property:opacity,translate,clip-path] motion-reduce:[transition-property:opacity]',\n '[transition-duration:var(--md-sys-motion-spring-effects-fast-duration),var(--md-sys-motion-spring-spatial-default-duration),var(--md-sys-motion-spring-spatial-default-duration)]',\n '[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing),var(--md-sys-motion-spring-spatial-default-easing),var(--md-sys-motion-spring-spatial-default-easing)]',\n 'data-exiting:[transition-duration:var(--md-sys-motion-duration-short-1),var(--md-sys-motion-duration-short-3),var(--md-sys-motion-duration-short-3)]',\n 'data-exiting:[transition-timing-function:var(--md-sys-motion-easing-linear),var(--md-sys-motion-easing-emphasized-accelerate),var(--md-sys-motion-easing-emphasized-accelerate)]',\n 'data-exiting:[transition-delay:var(--md-sys-motion-duration-short-2),0s,0s]',\n 'motion-reduce:data-exiting:[transition-delay:0s]',\n 'motion-reduce:data-exiting:[transition-duration:var(--md-sys-motion-duration-short-3)]',\n ],\n /*\n * Classes for the panel that stagger its parts (its children): every part fades in after\n * 50ms on the default effects spring (the headline, icon and supporting text, and any\n * custom child), and the actions (`data-slot=\"actions\"`) after 150ms on the fast one.\n * Leaving, they all fade out at once on the fast spring. Basic dialogs only (see the\n * `fullScreen` variants); reduced motion leaves the parts to the wrapper's fade.\n */\n parts: '',\n panel: [\n 'flex max-h-full min-w-[min(280px,calc(100vw-48px))] max-w-[560px] flex-col p-[24px]',\n 'rounded-[var(--_md-comp-dialog-container-shape)] bg-[var(--_md-comp-dialog-container-color)]',\n 'text-on-surface shadow-[shadow:var(--_md-comp-dialog-container-elevation)]',\n 'outline-none',\n // Forced colours drop the fill and shadow, so the panel draws its edge instead.\n 'forced-colors:outline-solid forced-colors:outline-1 forced-colors:outline-[CanvasText]',\n ],\n icon: [\n 'mx-auto inline-flex pb-[16px] [&>svg]:size-[24px]',\n 'text-[color:var(--_md-comp-dialog-with-icon-icon-color)]',\n ],\n title: [\n 'pb-[16px] text-headline-small font-brand',\n 'text-[color:var(--_md-comp-dialog-headline-color)]',\n ],\n header: '',\n headerButton: '',\n close: '[--md-comp-icon-button-icon-color:var(--md-sys-color-on-surface)]',\n content: [\n 'min-h-0 flex-1 overflow-y-auto pb-[24px] text-body-medium',\n 'text-[color:var(--_md-comp-dialog-supporting-text-color)]',\n 'focus-ring',\n ],\n // Stacked (`data-stacked`, set by `DialogActions` when they don't fit on one line), the\n // buttons are rendered confirming action first and wrap forwards instead of in reverse:\n // the same picture, sizes included, in focus order. The custom property tells it\n // whether the layout lets them stack.\n actions: [\n 'flex flex-wrap-reverse items-center justify-end gap-[8px] [--m3-dialog-actions-stack:1]',\n 'data-stacked:flex-wrap',\n ],\n },\n variants: {\n hasIcon: {\n true: { title: 'text-center' },\n false: { title: 'text-start' },\n },\n /*\n * The dialog enters from the window edge it sits against (the spec's enter and exit\n * pattern): it slides 50px away from that edge while its container grows away from it,\n * and leaves the same way back. Centred or at the top it slides down and grows downward\n * (the reference motion), at the bottom it slides up and grows upward, and at the start\n * or end it moves and grows along the x axis, mirrored in right-to-left layouts.\n */\n placement: {\n center: { positioner: 'items-center justify-center' },\n top: {\n positioner: 'items-start justify-center',\n motion: '[--m3-dialog-scale-origin:top]',\n },\n bottom: {\n positioner: 'items-end justify-center',\n motion: [\n '[--m3-dialog-enter-clip:inset(100%_0_0_round_var(--m3-dialog-corner))]',\n '[--m3-dialog-exit-clip:inset(65%_0_0_round_var(--m3-dialog-corner))]',\n '[--m3-dialog-slide:0_50px] [--m3-dialog-scale-origin:bottom]',\n ],\n },\n start: {\n positioner: 'items-center justify-start',\n motion: [\n '[--m3-dialog-enter-clip:inset(0_100%_0_0_round_var(--m3-dialog-corner))]',\n '[--m3-dialog-exit-clip:inset(0_65%_0_0_round_var(--m3-dialog-corner))]',\n '[--m3-dialog-slide:-50px_0] [--m3-dialog-scale-origin:left]',\n 'rtl:[--m3-dialog-enter-clip:inset(0_0_0_100%_round_var(--m3-dialog-corner))]',\n 'rtl:[--m3-dialog-exit-clip:inset(0_0_0_65%_round_var(--m3-dialog-corner))]',\n 'rtl:[--m3-dialog-slide:50px_0] rtl:[--m3-dialog-scale-origin:right]',\n ],\n },\n end: {\n positioner: 'items-center justify-end',\n motion: [\n '[--m3-dialog-enter-clip:inset(0_0_0_100%_round_var(--m3-dialog-corner))]',\n '[--m3-dialog-exit-clip:inset(0_0_0_65%_round_var(--m3-dialog-corner))]',\n '[--m3-dialog-slide:50px_0] [--m3-dialog-scale-origin:right]',\n 'rtl:[--m3-dialog-enter-clip:inset(0_100%_0_0_round_var(--m3-dialog-corner))]',\n 'rtl:[--m3-dialog-exit-clip:inset(0_65%_0_0_round_var(--m3-dialog-corner))]',\n 'rtl:[--m3-dialog-slide:-50px_0] rtl:[--m3-dialog-scale-origin:left]',\n ],\n },\n },\n fullScreen: {\n never: {\n headerButton: 'hidden',\n parts: [\n 'motion-safe:*:starting:opacity-0 motion-safe:data-exiting:*:opacity-0',\n '*:[transition-property:opacity]',\n '*:[transition-duration:var(--md-sys-motion-spring-effects-default-duration)]',\n '*:[transition-timing-function:var(--md-sys-motion-spring-effects-default-easing)]',\n '*:[transition-delay:var(--md-sys-motion-duration-short-1)]',\n '*:data-[slot=actions]:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]',\n '*:data-[slot=actions]:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing)]',\n '*:data-[slot=actions]:[transition-delay:var(--md-sys-motion-duration-short-3)]',\n 'data-exiting:*:[transition-duration:var(--md-sys-motion-duration-short-2)]',\n 'data-exiting:*:[transition-timing-function:var(--md-sys-motion-easing-linear)]',\n 'data-exiting:*:[transition-delay:0s] data-exiting:*:data-[slot=actions]:[transition-delay:0s]',\n 'data-exiting:*:data-[slot=actions]:[transition-duration:var(--md-sys-motion-duration-short-2)]',\n 'data-exiting:*:data-[slot=actions]:[transition-timing-function:var(--md-sys-motion-easing-linear)]',\n ],\n },\n /*\n * Full screen keeps its own motion: the dialog slides up 48px as it fades in on the slow\n * springs (the spec's speed for full-screen motion) with no clip, and slides back down\n * as it fades out on the fast ones, its parts fading with it.\n */\n always: {\n positioner: 'p-0 medium:p-0',\n motion: [\n 'size-full [--m3-dialog-slide:0_48px]',\n '[--m3-dialog-open-clip:none] [--m3-dialog-enter-clip:none] [--m3-dialog-exit-clip:none]',\n '[transition-duration:var(--md-sys-motion-spring-effects-slow-duration),var(--md-sys-motion-spring-spatial-slow-duration),var(--md-sys-motion-spring-spatial-slow-duration)]',\n '[transition-timing-function:var(--md-sys-motion-spring-effects-slow-easing),var(--md-sys-motion-spring-spatial-slow-easing),var(--md-sys-motion-spring-spatial-slow-easing)]',\n 'data-exiting:[transition-delay:0s]',\n 'data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]',\n 'data-exiting:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing)]',\n ],\n panel: [\n 'size-full max-h-none max-w-none rounded-none p-0 shadow-none',\n 'bg-surface-container-high',\n ],\n header: 'flex h-[56px] shrink-0 items-center gap-[4px] ps-[4px] pe-[12px]',\n title: 'min-w-0 flex-1 truncate ps-[4px] pb-0 text-start text-title-large',\n content: 'px-[24px] pt-[24px]',\n actions: 'hidden',\n },\n compact: {\n positioner: 'max-medium:p-0',\n motion: [\n 'max-medium:size-full max-medium:[--m3-dialog-slide:0_48px]',\n 'max-medium:[--m3-dialog-open-clip:none] max-medium:[--m3-dialog-enter-clip:none]',\n 'max-medium:[--m3-dialog-exit-clip:none]',\n 'max-medium:[transition-duration:var(--md-sys-motion-spring-effects-slow-duration),var(--md-sys-motion-spring-spatial-slow-duration),var(--md-sys-motion-spring-spatial-slow-duration)]',\n 'max-medium:[transition-timing-function:var(--md-sys-motion-spring-effects-slow-easing),var(--md-sys-motion-spring-spatial-slow-easing),var(--md-sys-motion-spring-spatial-slow-easing)]',\n 'max-medium:data-exiting:[transition-delay:0s]',\n 'max-medium:data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]',\n 'max-medium:data-exiting:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing)]',\n ],\n parts: [\n 'medium:motion-safe:*:starting:opacity-0 medium:motion-safe:data-exiting:*:opacity-0',\n 'medium:*:[transition-property:opacity]',\n 'medium:*:[transition-duration:var(--md-sys-motion-spring-effects-default-duration)]',\n 'medium:*:[transition-timing-function:var(--md-sys-motion-spring-effects-default-easing)]',\n 'medium:*:[transition-delay:var(--md-sys-motion-duration-short-1)]',\n 'medium:*:data-[slot=actions]:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]',\n 'medium:*:data-[slot=actions]:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing)]',\n 'medium:*:data-[slot=actions]:[transition-delay:var(--md-sys-motion-duration-short-3)]',\n 'medium:data-exiting:*:[transition-duration:var(--md-sys-motion-duration-short-2)]',\n 'medium:data-exiting:*:[transition-timing-function:var(--md-sys-motion-easing-linear)]',\n 'medium:data-exiting:*:[transition-delay:0s]',\n 'medium:data-exiting:*:data-[slot=actions]:[transition-delay:0s]',\n 'medium:data-exiting:*:data-[slot=actions]:[transition-duration:var(--md-sys-motion-duration-short-2)]',\n 'medium:data-exiting:*:data-[slot=actions]:[transition-timing-function:var(--md-sys-motion-easing-linear)]',\n ],\n panel: [\n 'max-medium:size-full max-medium:max-h-none max-medium:max-w-none',\n 'max-medium:rounded-none max-medium:p-0 max-medium:shadow-none',\n 'max-medium:bg-surface-container-high',\n ],\n header: [\n 'max-medium:flex max-medium:h-[56px] max-medium:shrink-0 max-medium:items-center',\n 'max-medium:gap-[4px] max-medium:ps-[4px] max-medium:pe-[12px]',\n ],\n headerButton: 'medium:hidden',\n title: [\n 'max-medium:min-w-0 max-medium:flex-1 max-medium:truncate max-medium:ps-[4px]',\n 'max-medium:pb-0 max-medium:text-start max-medium:text-title-large',\n ],\n content: 'max-medium:px-[24px] max-medium:pt-[24px]',\n actions: 'max-medium:hidden',\n },\n },\n /** Full screen without a header action: the actions form a 56px bottom bar. */\n bottomBar: { true: {}, false: {} },\n /** A divider under the full-screen header. */\n divider: { true: {}, false: {} },\n /** The basic dialog's optional dividers above and below `DialogContent`. */\n dividers: { true: {}, false: {} },\n /** A container transform from a trigger (`origin`) into the full-screen dialog. */\n origin: { true: {}, false: {} },\n /**\n * The basic dialog's enter and exit: `reveal`, the M3 dialog motion above, or `scale`,\n * the original pop (see the compound variants). Full-screen dialogs ignore it.\n */\n transition: { reveal: {}, scale: {} },\n /** No enter or exit motion: the dialog, its parts and the scrim appear and go at once. */\n instant: {\n true: {\n scrim: '[transition-property:none]!',\n motion: '[transition-property:none]!',\n panel: '[transition-property:none]!',\n parts: '*:[transition-property:none]!',\n },\n false: {},\n },\n },\n compoundVariants: [\n {\n fullScreen: 'always',\n bottomBar: true,\n class: {\n actions: 'flex h-[56px] shrink-0 flex-nowrap px-[24px] [--m3-dialog-actions-stack:0]',\n },\n },\n {\n fullScreen: 'compact',\n bottomBar: true,\n class: {\n actions:\n 'max-medium:flex max-medium:h-[56px] max-medium:shrink-0 max-medium:flex-nowrap max-medium:px-[24px] max-medium:[--m3-dialog-actions-stack:0]',\n },\n },\n {\n fullScreen: 'always',\n divider: true,\n class: { header: 'border-b border-outline-variant' },\n },\n {\n fullScreen: 'compact',\n divider: true,\n class: { header: 'max-medium:border-b max-medium:border-outline-variant' },\n },\n /*\n * Dividers run the panel's full width, 1px `outline-variant`, with 8px between them and\n * the content; the body keeps 24px to the actions below the bottom one.\n */\n {\n fullScreen: 'never',\n dividers: true,\n class: {\n content: '-mx-[24px] mb-[24px] border-y border-outline-variant px-[24px] py-[8px]',\n },\n },\n {\n fullScreen: 'compact',\n dividers: true,\n class: {\n content: [\n 'medium:-mx-[24px] medium:mb-[24px] medium:border-y medium:border-outline-variant',\n 'medium:px-[24px] medium:py-[8px]',\n ],\n },\n },\n /*\n * `transition=\"scale\"`, the library's original pop (an extension beyond the M3 dialog\n * motion): the scrim fades on the default effects spring, and the dialog fades in while it\n * scales up from 90% on the default springs, then fades out while it scales to 95% on the\n * fast ones. No clip, no slide, no staggered parts. It scales from the edge it sits\n * against (`--m3-dialog-scale-origin`: the centre for `center`, the top, bottom, start or\n * end edge otherwise). Reduced motion keeps only the fades. Basic dialogs only (from 600px\n * for `compact`).\n */\n {\n fullScreen: 'never',\n transition: 'scale',\n class: {\n scrim: [\n '[transition-duration:var(--md-sys-motion-spring-effects-default-duration)]',\n '[transition-timing-function:var(--md-sys-motion-spring-effects-default-easing)]',\n 'data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]',\n 'data-exiting:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing)]',\n ],\n motion: [\n '[--m3-dialog-slide:0_0] [--m3-dialog-open-clip:none]',\n '[--m3-dialog-enter-clip:none] [--m3-dialog-exit-clip:none]',\n 'origin-(--m3-dialog-scale-origin) scale-none starting:scale-90 data-exiting:scale-95',\n 'motion-reduce:data-exiting:scale-none',\n '[transition-property:opacity,scale] motion-reduce:[transition-property:opacity]',\n '[transition-duration:var(--md-sys-motion-spring-effects-default-duration),var(--md-sys-motion-spring-spatial-default-duration)]',\n '[transition-timing-function:var(--md-sys-motion-spring-effects-default-easing),var(--md-sys-motion-spring-spatial-default-easing)]',\n 'data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration),var(--md-sys-motion-spring-spatial-fast-duration)]',\n 'data-exiting:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing),var(--md-sys-motion-spring-spatial-fast-easing)]',\n 'data-exiting:[transition-delay:0s]',\n ],\n },\n },\n {\n fullScreen: 'compact',\n transition: 'scale',\n class: {\n scrim: [\n 'medium:[transition-duration:var(--md-sys-motion-spring-effects-default-duration)]',\n 'medium:[transition-timing-function:var(--md-sys-motion-spring-effects-default-easing)]',\n 'medium:data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]',\n 'medium:data-exiting:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing)]',\n ],\n motion: [\n 'medium:[--m3-dialog-slide:0_0] medium:[--m3-dialog-open-clip:none]',\n 'medium:[--m3-dialog-enter-clip:none] medium:[--m3-dialog-exit-clip:none]',\n 'medium:origin-(--m3-dialog-scale-origin) medium:scale-none',\n 'medium:starting:scale-90 medium:data-exiting:scale-95',\n 'medium:motion-reduce:data-exiting:scale-none',\n 'medium:[transition-property:opacity,scale]',\n 'medium:motion-reduce:[transition-property:opacity]',\n 'medium:[transition-duration:var(--md-sys-motion-spring-effects-default-duration),var(--md-sys-motion-spring-spatial-default-duration)]',\n 'medium:[transition-timing-function:var(--md-sys-motion-spring-effects-default-easing),var(--md-sys-motion-spring-spatial-default-easing)]',\n 'medium:data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration),var(--md-sys-motion-spring-spatial-fast-duration)]',\n 'medium:data-exiting:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing),var(--md-sys-motion-spring-spatial-fast-easing)]',\n 'medium:data-exiting:[transition-delay:0s]',\n ],\n },\n },\n /*\n * Container transform (the spec: \"Use a container transform pattern to transition a FAB\n * into a full-screen dialog\"): the clip starts on the origin's box and corners\n * (`--m3-dialog-origin`, measured by the dialog) and opens to the window on the slow\n * spatial spring, while the container colour moves from the origin's\n * (`--m3-dialog-origin-color`) and the content fades in. Leaving collapses back into the\n * origin on emphasized-accelerate over 250ms (2026-10-15), as the basic exit avoids\n * springs: the fast spatial spring collapsed the clip past the origin to nothing and\n * regrew it while still visible. The container stays opaque for the first 60% and fades\n * over the last 100ms, linear, ending with the collapse (2026-10-17, after Material\n * Components' container transform, whose return fades from 60% to 90%), so it is seen going\n * back into the origin. Reduced motion keeps only the fades (the dialog's and its content's).\n */\n {\n fullScreen: 'always',\n origin: true,\n class: {\n motion: [\n '[--m3-dialog-slide:0_0] [--m3-dialog-open-clip:inset(0_round_0)]',\n '[--m3-dialog-enter-clip:var(--m3-dialog-origin)] [--m3-dialog-exit-clip:var(--m3-dialog-origin)]',\n '[transition-duration:var(--md-sys-motion-spring-effects-fast-duration),var(--md-sys-motion-spring-spatial-slow-duration),var(--md-sys-motion-spring-spatial-slow-duration)]',\n '[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing),var(--md-sys-motion-spring-spatial-slow-easing),var(--md-sys-motion-spring-spatial-slow-easing)]',\n 'data-exiting:[transition-duration:var(--md-sys-motion-duration-short-2),var(--md-sys-motion-duration-medium-1),var(--md-sys-motion-duration-medium-1)]',\n 'data-exiting:[transition-timing-function:var(--md-sys-motion-easing-linear),var(--md-sys-motion-easing-emphasized-accelerate),var(--md-sys-motion-easing-emphasized-accelerate)]',\n // Full screen's exit starts every transition at once; the fade waits here.\n 'data-exiting:[transition-delay:var(--md-sys-motion-duration-short-3),0s,0s]',\n 'motion-reduce:data-exiting:[transition-delay:0s]',\n ],\n panel: [\n '[transition-property:background-color] motion-reduce:[transition-property:none]',\n '[transition-duration:var(--md-sys-motion-spring-effects-slow-duration)]',\n '[transition-timing-function:var(--md-sys-motion-spring-effects-slow-easing)]',\n 'starting:bg-(--m3-dialog-origin-color) motion-safe:data-exiting:bg-(--m3-dialog-origin-color)',\n 'data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]',\n '*:[transition-property:opacity] *:starting:opacity-0 data-exiting:*:opacity-0',\n '*:[transition-duration:var(--md-sys-motion-spring-effects-slow-duration)]',\n '*:[transition-timing-function:var(--md-sys-motion-spring-effects-slow-easing)]',\n ],\n },\n },\n {\n fullScreen: 'compact',\n origin: true,\n class: {\n motion: [\n 'max-medium:[--m3-dialog-slide:0_0] max-medium:[--m3-dialog-open-clip:inset(0_round_0)]',\n 'max-medium:[--m3-dialog-enter-clip:var(--m3-dialog-origin)]',\n 'max-medium:[--m3-dialog-exit-clip:var(--m3-dialog-origin)]',\n 'max-medium:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration),var(--md-sys-motion-spring-spatial-slow-duration),var(--md-sys-motion-spring-spatial-slow-duration)]',\n 'max-medium:[transition-timing-function:var(--md-sys-motion-spring-effects-fast-easing),var(--md-sys-motion-spring-spatial-slow-easing),var(--md-sys-motion-spring-spatial-slow-easing)]',\n 'max-medium:data-exiting:[transition-duration:var(--md-sys-motion-duration-short-2),var(--md-sys-motion-duration-medium-1),var(--md-sys-motion-duration-medium-1)]',\n 'max-medium:data-exiting:[transition-timing-function:var(--md-sys-motion-easing-linear),var(--md-sys-motion-easing-emphasized-accelerate),var(--md-sys-motion-easing-emphasized-accelerate)]',\n 'max-medium:data-exiting:[transition-delay:var(--md-sys-motion-duration-short-3),0s,0s]',\n // The breakpoint outranks the base reduced-motion exit: restate it, so the fade\n // keeps its duration and starts at once while the spatial springs are instant.\n 'max-medium:motion-reduce:data-exiting:[transition-duration:var(--md-sys-motion-duration-short-3)]',\n 'max-medium:motion-reduce:data-exiting:[transition-delay:0s]',\n ],\n panel: [\n 'max-medium:[transition-property:background-color]',\n 'max-medium:motion-reduce:[transition-property:none]',\n 'max-medium:[transition-duration:var(--md-sys-motion-spring-effects-slow-duration)]',\n 'max-medium:[transition-timing-function:var(--md-sys-motion-spring-effects-slow-easing)]',\n 'max-medium:starting:bg-(--m3-dialog-origin-color)',\n 'max-medium:motion-safe:data-exiting:bg-(--m3-dialog-origin-color)',\n 'max-medium:data-exiting:[transition-duration:var(--md-sys-motion-spring-effects-fast-duration)]',\n 'max-medium:*:[transition-property:opacity] max-medium:*:starting:opacity-0',\n 'max-medium:data-exiting:*:opacity-0',\n 'max-medium:*:[transition-duration:var(--md-sys-motion-spring-effects-slow-duration)]',\n 'max-medium:*:[transition-timing-function:var(--md-sys-motion-spring-effects-slow-easing)]',\n ],\n },\n },\n ],\n defaultVariants: {\n dividers: false,\n origin: false,\n instant: false,\n transition: 'reveal',\n hasIcon: false,\n fullScreen: 'never',\n placement: 'center',\n bottomBar: false,\n divider: false,\n },\n});\n\n/**\n * The variants of {@link dialogStyles}, for building on its styles. They are the recipe's keys, not\n * component props: their names (`hasIcon`, `isOpen`…) follow the classes and may change.\n */\nexport type DialogStyleProps = VariantProps<typeof dialogStyles>;\n"],"mappings":";;;AA6CA,MAAa,oBAAoB;CAAE,UAAU;CAAS,OAAO;AAAE;;AAG/D,MAAa,eAAe,GAAG;CAC7B,OAAO;EACL,OAAO;GACL;GACA;GACA;GACA;GACA;GACA;GACA;GACA;EACF;EAKA,MAAM;EACN,YAAY;EAeZ,QAAQ;GACN;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;GACA;EACF;EAQA,OAAO;EACP,OAAO;GACL;GACA;GACA;GACA;GAEA;EACF;EACA,MAAM,CACJ,qDACA,0DACF;EACA,OAAO,CACL,4CACA,oDACF;EACA,QAAQ;EACR,cAAc;EACd,OAAO;EACP,SAAS;GACP;GACA;GACA;EACF;EAKA,SAAS,CACP,2FACA,wBACF;CACF;CACA,UAAU;EACR,SAAS;GACP,MAAM,EAAE,OAAO,cAAc;GAC7B,OAAO,EAAE,OAAO,aAAa;EAC/B;EAQA,WAAW;GACT,QAAQ,EAAE,YAAY,8BAA8B;GACpD,KAAK;IACH,YAAY;IACZ,QAAQ;GACV;GACA,QAAQ;IACN,YAAY;IACZ,QAAQ;KACN;KACA;KACA;IACF;GACF;GACA,OAAO;IACL,YAAY;IACZ,QAAQ;KACN;KACA;KACA;KACA;KACA;KACA;IACF;GACF;GACA,KAAK;IACH,YAAY;IACZ,QAAQ;KACN;KACA;KACA;KACA;KACA;KACA;IACF;GACF;EACF;EACA,YAAY;GACV,OAAO;IACL,cAAc;IACd,OAAO;KACL;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;IACF;GACF;GAMA,QAAQ;IACN,YAAY;IACZ,QAAQ;KACN;KACA;KACA;KACA;KACA;KACA;KACA;IACF;IACA,OAAO,CACL,gEACA,2BACF;IACA,QAAQ;IACR,OAAO;IACP,SAAS;IACT,SAAS;GACX;GACA,SAAS;IACP,YAAY;IACZ,QAAQ;KACN;KACA;KACA;KACA;KACA;KACA;KACA;KACA;IACF;IACA,OAAO;KACL;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;IACF;IACA,OAAO;KACL;KACA;KACA;IACF;IACA,QAAQ,CACN,mFACA,+DACF;IACA,cAAc;IACd,OAAO,CACL,gFACA,mEACF;IACA,SAAS;IACT,SAAS;GACX;EACF;;EAEA,WAAW;GAAE,MAAM,CAAC;GAAG,OAAO,CAAC;EAAE;;EAEjC,SAAS;GAAE,MAAM,CAAC;GAAG,OAAO,CAAC;EAAE;;EAE/B,UAAU;GAAE,MAAM,CAAC;GAAG,OAAO,CAAC;EAAE;;EAEhC,QAAQ;GAAE,MAAM,CAAC;GAAG,OAAO,CAAC;EAAE;;;;;EAK9B,YAAY;GAAE,QAAQ,CAAC;GAAG,OAAO,CAAC;EAAE;;EAEpC,SAAS;GACP,MAAM;IACJ,OAAO;IACP,QAAQ;IACR,OAAO;IACP,OAAO;GACT;GACA,OAAO,CAAC;EACV;CACF;CACA,kBAAkB;EAChB;GACE,YAAY;GACZ,WAAW;GACX,OAAO,EACL,SAAS,6EACX;EACF;EACA;GACE,YAAY;GACZ,WAAW;GACX,OAAO,EACL,SACE,+IACJ;EACF;EACA;GACE,YAAY;GACZ,SAAS;GACT,OAAO,EAAE,QAAQ,kCAAkC;EACrD;EACA;GACE,YAAY;GACZ,SAAS;GACT,OAAO,EAAE,QAAQ,wDAAwD;EAC3E;EAKA;GACE,YAAY;GACZ,UAAU;GACV,OAAO,EACL,SAAS,0EACX;EACF;EACA;GACE,YAAY;GACZ,UAAU;GACV,OAAO,EACL,SAAS,CACP,oFACA,kCACF,EACF;EACF;EAUA;GACE,YAAY;GACZ,YAAY;GACZ,OAAO;IACL,OAAO;KACL;KACA;KACA;KACA;IACF;IACA,QAAQ;KACN;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;IACF;GACF;EACF;EACA;GACE,YAAY;GACZ,YAAY;GACZ,OAAO;IACL,OAAO;KACL;KACA;KACA;KACA;IACF;IACA,QAAQ;KACN;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;IACF;GACF;EACF;EAcA;GACE,YAAY;GACZ,QAAQ;GACR,OAAO;IACL,QAAQ;KACN;KACA;KACA;KACA;KACA;KACA;KAEA;KACA;IACF;IACA,OAAO;KACL;KACA;KACA;KACA;KACA;KACA;KACA;KACA;IACF;GACF;EACF;EACA;GACE,YAAY;GACZ,QAAQ;GACR,OAAO;IACL,QAAQ;KACN;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KAGA;KACA;IACF;IACA,OAAO;KACL;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;KACA;IACF;GACF;EACF;CACF;CACA,iBAAiB;EACf,UAAU;EACV,QAAQ;EACR,SAAS;EACT,YAAY;EACZ,SAAS;EACT,YAAY;EACZ,WAAW;EACX,WAAW;EACX,SAAS;CACX;AACF,CAAC"}
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
import { ComponentTokenSet } from "../../tokens/component.js";
|
|
2
|
+
import "../../index.js";
|
|
3
|
+
//#region src/components/dialog/dialog-tokens.d.ts
|
|
4
|
+
/** The tokens of {@link Dialog}: `--md-comp-dialog-<part>`. */
|
|
5
|
+
export declare const dialogTokenSet: ComponentTokenSet<"container-color" | "container-shape" | "supporting-text-color" | "container-elevation" | "with-icon-icon-color" | "headline-color">;
|
|
6
|
+
//#endregion
|
|
7
|
+
//# sourceMappingURL=dialog-tokens.d.ts.map
|
|
@@ -0,0 +1,57 @@
|
|
|
1
|
+
import { color, corner, defineComponentTokens, elevation } from "../../tokens/component.js";
|
|
2
|
+
//#region src/components/dialog/dialog-tokens.ts
|
|
3
|
+
/** The tokens of {@link Dialog}: `--md-comp-dialog-<part>`. */
|
|
4
|
+
const dialogTokenSet = defineComponentTokens({
|
|
5
|
+
name: "md-comp-dialog",
|
|
6
|
+
tokens: {
|
|
7
|
+
"container-color": {
|
|
8
|
+
value: color("surface-container-high"),
|
|
9
|
+
description: "The panel.",
|
|
10
|
+
compose: "DialogTokens.ContainerColor",
|
|
11
|
+
paints: { property: "background-color" }
|
|
12
|
+
},
|
|
13
|
+
"container-shape": {
|
|
14
|
+
value: corner("extra-large"),
|
|
15
|
+
description: "The panel's corners.",
|
|
16
|
+
compose: "DialogTokens.ContainerShape",
|
|
17
|
+
paints: { property: "border-top-left-radius" }
|
|
18
|
+
},
|
|
19
|
+
"container-elevation": {
|
|
20
|
+
value: elevation(3),
|
|
21
|
+
description: "The panel's shadow.",
|
|
22
|
+
compose: "DialogTokens.ContainerElevation",
|
|
23
|
+
paints: { property: "box-shadow" }
|
|
24
|
+
},
|
|
25
|
+
"headline-color": {
|
|
26
|
+
value: color("on-surface"),
|
|
27
|
+
description: "The title (`DialogTitle`, or the full-screen header's).",
|
|
28
|
+
compose: "DialogTokens.HeadlineColor",
|
|
29
|
+
paints: {
|
|
30
|
+
property: "color",
|
|
31
|
+
slot: "title"
|
|
32
|
+
}
|
|
33
|
+
},
|
|
34
|
+
"supporting-text-color": {
|
|
35
|
+
value: color("on-surface-variant"),
|
|
36
|
+
description: "The supporting text (`DialogContent`).",
|
|
37
|
+
compose: "DialogTokens.SupportingTextColor",
|
|
38
|
+
paints: {
|
|
39
|
+
property: "color",
|
|
40
|
+
slot: "content"
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
"with-icon-icon-color": {
|
|
44
|
+
value: color("secondary"),
|
|
45
|
+
description: "The icon above the title (`icon`).",
|
|
46
|
+
compose: "DialogTokens.IconColor",
|
|
47
|
+
paints: {
|
|
48
|
+
property: "color",
|
|
49
|
+
slot: "icon"
|
|
50
|
+
}
|
|
51
|
+
}
|
|
52
|
+
}
|
|
53
|
+
});
|
|
54
|
+
//#endregion
|
|
55
|
+
export { dialogTokenSet };
|
|
56
|
+
|
|
57
|
+
//# sourceMappingURL=dialog-tokens.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"dialog-tokens.js","names":[],"sources":["../../../src/components/dialog/dialog-tokens.ts"],"sourcesContent":["import { color, corner, defineComponentTokens, elevation } from '../../tokens/component';\n\n/*\n * Dialog's component tokens, M3's `md.comp.dialog.*` names (checked against m3.material.io's\n * token tables, 2026-10-14), with Compose's DialogTokens defaults. The panel carries\n * `data-tokens=\"md-comp-dialog\"`, and `dialog-styles.ts` reads one private variable per part\n * (the icon, title and content inherit them). A full-screen dialog keeps its own container\n * (M3's separate full-screen set, not exposed): the window-filling `surface-container-high`\n * with no corners or shadow. The actions are text buttons with their own tokens, and the\n * dividers and the scrim stay classes.\n */\n\n/** The tokens of {@link Dialog}: `--md-comp-dialog-<part>`. */\nexport const dialogTokenSet = defineComponentTokens({\n name: 'md-comp-dialog',\n tokens: {\n 'container-color': {\n value: color('surface-container-high'),\n description: 'The panel.',\n compose: 'DialogTokens.ContainerColor',\n paints: { property: 'background-color' },\n },\n 'container-shape': {\n value: corner('extra-large'),\n description: \"The panel's corners.\",\n compose: 'DialogTokens.ContainerShape',\n paints: { property: 'border-top-left-radius' },\n },\n 'container-elevation': {\n value: elevation(3),\n description: \"The panel's shadow.\",\n compose: 'DialogTokens.ContainerElevation',\n paints: { property: 'box-shadow' },\n },\n 'headline-color': {\n value: color('on-surface'),\n description: \"The title (`DialogTitle`, or the full-screen header's).\",\n compose: 'DialogTokens.HeadlineColor',\n paints: { property: 'color', slot: 'title' },\n },\n 'supporting-text-color': {\n value: color('on-surface-variant'),\n description: 'The supporting text (`DialogContent`).',\n compose: 'DialogTokens.SupportingTextColor',\n paints: { property: 'color', slot: 'content' },\n },\n 'with-icon-icon-color': {\n value: color('secondary'),\n description: 'The icon above the title (`icon`).',\n compose: 'DialogTokens.IconColor',\n paints: { property: 'color', slot: 'icon' },\n },\n },\n});\n"],"mappings":";;;AAaA,MAAa,iBAAiB,sBAAsB;CAClD,MAAM;CACN,QAAQ;EACN,mBAAmB;GACjB,OAAO,MAAM,wBAAwB;GACrC,aAAa;GACb,SAAS;GACT,QAAQ,EAAE,UAAU,mBAAmB;EACzC;EACA,mBAAmB;GACjB,OAAO,OAAO,aAAa;GAC3B,aAAa;GACb,SAAS;GACT,QAAQ,EAAE,UAAU,yBAAyB;EAC/C;EACA,uBAAuB;GACrB,OAAO,UAAU,CAAC;GAClB,aAAa;GACb,SAAS;GACT,QAAQ,EAAE,UAAU,aAAa;EACnC;EACA,kBAAkB;GAChB,OAAO,MAAM,YAAY;GACzB,aAAa;GACb,SAAS;GACT,QAAQ;IAAE,UAAU;IAAS,MAAM;GAAQ;EAC7C;EACA,yBAAyB;GACvB,OAAO,MAAM,oBAAoB;GACjC,aAAa;GACb,SAAS;GACT,QAAQ;IAAE,UAAU;IAAS,MAAM;GAAU;EAC/C;EACA,wBAAwB;GACtB,OAAO,MAAM,WAAW;GACxB,aAAa;GACb,SAAS;GACT,QAAQ;IAAE,UAAU;IAAS,MAAM;GAAO;EAC5C;CACF;AACF,CAAC"}
|
|
@@ -0,0 +1,59 @@
|
|
|
1
|
+
import { DividerInset, DividerOrientation } from "./divider-styles.js";
|
|
2
|
+
import { ComponentPropsWithRef, ReactNode } from "react";
|
|
3
|
+
//#region src/components/divider/Divider.d.ts
|
|
4
|
+
export interface DividerProps extends Omit<ComponentPropsWithRef<'div'>, 'children'> {
|
|
5
|
+
/**
|
|
6
|
+
* A full-width horizontal line, or a vertical line the full height of a flex row.
|
|
7
|
+
* @default "horizontal"
|
|
8
|
+
*/
|
|
9
|
+
orientation?: DividerOrientation;
|
|
10
|
+
/** Leave 16px at the start, or at both ends. @default "none" */
|
|
11
|
+
inset?: DividerInset;
|
|
12
|
+
/**
|
|
13
|
+
* M3 dividers are decorative, so by default the line is hidden from assistive tech
|
|
14
|
+
* (`role="none"`). Set `decorative={false}` where the line marks a real break between
|
|
15
|
+
* groups of content, to expose it as a `separator`. @default true
|
|
16
|
+
*/
|
|
17
|
+
decorative?: boolean;
|
|
18
|
+
}
|
|
19
|
+
/**
|
|
20
|
+
* M3 divider: a 1px `outline-variant` line, horizontal (full width) or vertical (full
|
|
21
|
+
* height of a flex row), optionally inset. It's decorative (M3: "Dividers are decorative
|
|
22
|
+
* elements") unless `decorative={false}` makes it a `separator`.
|
|
23
|
+
*
|
|
24
|
+
* @example
|
|
25
|
+
* <Divider />
|
|
26
|
+
* <Divider orientation="vertical" inset="middle" />
|
|
27
|
+
*/
|
|
28
|
+
export declare function Divider({ orientation, inset, decorative, className, ...rest }: DividerProps): import("react").JSX.Element;
|
|
29
|
+
export interface LabeledDividerClassNames {
|
|
30
|
+
/** The wrapper around the line and the text. */
|
|
31
|
+
root?: string;
|
|
32
|
+
/** The line. */
|
|
33
|
+
divider?: string;
|
|
34
|
+
/** The supporting text. */
|
|
35
|
+
label?: string;
|
|
36
|
+
}
|
|
37
|
+
export interface LabeledDividerProps extends Omit<ComponentPropsWithRef<'div'>, 'children'> {
|
|
38
|
+
/** The supporting text below the line, e.g. a section's name. */
|
|
39
|
+
children: ReactNode;
|
|
40
|
+
/** Leave 16px at the start, or at both ends, of the line and the text. @default "none" */
|
|
41
|
+
inset?: DividerInset;
|
|
42
|
+
/**
|
|
43
|
+
* The line is hidden from assistive tech, not the text; `decorative={false}` exposes it
|
|
44
|
+
* as a `separator`. @default true
|
|
45
|
+
*/
|
|
46
|
+
decorative?: boolean;
|
|
47
|
+
/** Classes for each part, by slot. `classNames.root` is merged with `className`. */
|
|
48
|
+
classNames?: LabeledDividerClassNames;
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* M3 divider with supporting text: a horizontal divider with a short text 4px below it,
|
|
52
|
+
* 8px clear at the end and below, such as the name of the section that follows.
|
|
53
|
+
*
|
|
54
|
+
* @example
|
|
55
|
+
* <LabeledDivider inset="start">Earlier this week</LabeledDivider>
|
|
56
|
+
*/
|
|
57
|
+
export declare function LabeledDivider({ children, inset, decorative, classNames, className, ...rest }: LabeledDividerProps): import("react").JSX.Element;
|
|
58
|
+
//#endregion
|
|
59
|
+
//# sourceMappingURL=Divider.d.ts.map
|
|
@@ -0,0 +1,53 @@
|
|
|
1
|
+
import { cn } from "../../utils/cn.js";
|
|
2
|
+
import { mergeDataTokens } from "../../utils/merge-data-tokens.js";
|
|
3
|
+
import { dividerStyles, labeledDividerStyles } from "./divider-styles.js";
|
|
4
|
+
import { jsx, jsxs } from "react/jsx-runtime";
|
|
5
|
+
//#region src/components/divider/Divider.tsx
|
|
6
|
+
/**
|
|
7
|
+
* M3 divider: a 1px `outline-variant` line, horizontal (full width) or vertical (full
|
|
8
|
+
* height of a flex row), optionally inset. It's decorative (M3: "Dividers are decorative
|
|
9
|
+
* elements") unless `decorative={false}` makes it a `separator`.
|
|
10
|
+
*
|
|
11
|
+
* @example
|
|
12
|
+
* <Divider />
|
|
13
|
+
* <Divider orientation="vertical" inset="middle" />
|
|
14
|
+
*/
|
|
15
|
+
function Divider({ orientation = "horizontal", inset, decorative = true, className, ...rest }) {
|
|
16
|
+
return /* @__PURE__ */ jsx("div", {
|
|
17
|
+
...rest,
|
|
18
|
+
"data-tokens": mergeDataTokens("md-comp-divider", rest),
|
|
19
|
+
role: decorative ? "none" : "separator",
|
|
20
|
+
"aria-orientation": decorative || orientation === "horizontal" ? void 0 : "vertical",
|
|
21
|
+
className: dividerStyles({
|
|
22
|
+
orientation,
|
|
23
|
+
inset,
|
|
24
|
+
class: className
|
|
25
|
+
})
|
|
26
|
+
});
|
|
27
|
+
}
|
|
28
|
+
/**
|
|
29
|
+
* M3 divider with supporting text: a horizontal divider with a short text 4px below it,
|
|
30
|
+
* 8px clear at the end and below, such as the name of the section that follows.
|
|
31
|
+
*
|
|
32
|
+
* @example
|
|
33
|
+
* <LabeledDivider inset="start">Earlier this week</LabeledDivider>
|
|
34
|
+
*/
|
|
35
|
+
function LabeledDivider({ children, inset, decorative = true, classNames, className, ...rest }) {
|
|
36
|
+
const styles = labeledDividerStyles({ inset });
|
|
37
|
+
return /* @__PURE__ */ jsxs("div", {
|
|
38
|
+
...rest,
|
|
39
|
+
className: styles.root({ class: cn(classNames?.root, className) }),
|
|
40
|
+
children: [/* @__PURE__ */ jsx(Divider, {
|
|
41
|
+
inset,
|
|
42
|
+
decorative,
|
|
43
|
+
className: classNames?.divider
|
|
44
|
+
}), /* @__PURE__ */ jsx("div", {
|
|
45
|
+
className: styles.label({ class: classNames?.label }),
|
|
46
|
+
children
|
|
47
|
+
})]
|
|
48
|
+
});
|
|
49
|
+
}
|
|
50
|
+
//#endregion
|
|
51
|
+
export { Divider, LabeledDivider };
|
|
52
|
+
|
|
53
|
+
//# sourceMappingURL=Divider.js.map
|