-
-
Notifications
You must be signed in to change notification settings - Fork 26
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
5 changed files
with
51 additions
and
142 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
--- | ||
title: MotionConfig | ||
navigation.icon: lucide:settings | ||
--- | ||
|
||
`MotionConfig` Component is used to configure child `Motion` components. | ||
|
||
## Props | ||
|
||
### `transition` | ||
|
||
define the default transition for all child `Motion` components. | ||
|
||
### `reduceMotion` | ||
|
||
default value is `never`. | ||
|
||
`reduceMotion` is used to control the behavior of motion when the user has enabled reduced motion. | ||
|
||
- `never`: Don't reduce motion. | ||
- `always`: Always reduce motion. | ||
- `user`: Reduce motion based on the user's system setting. | ||
|
||
when reduced motion is enabled, transform and layout animations will be disabled. | ||
other animations will persist. | ||
|
||
### `none` | ||
|
||
If using a Content Security Policy with a nonce attribute, passing the same attribute through MotionConfig will allow any style blocks generated by Motion to adhere the the security policy. | ||
|
||
## Reference | ||
|
||
- [Motion-MotionConfig](https://motion.dev/docs/react-motion-config) | ||
- [Content-Security-Policy](https://developer.mozilla.org/en-US/docs/Web/HTTP/Headers/Content-Security-Policy/style-src#unsafe_inline_styles) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters