motion 12.20.2 β 12.20.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +53 -58
- package/package.json +3 -3
package/README.md
CHANGED
|
@@ -1,97 +1,92 @@
|
|
|
1
1
|
<p align="center">
|
|
2
|
-
|
|
2
|
+
<img width="100" height="100" alt="Motion logo" src="https://github.com/user-attachments/assets/00d6d1c3-72c4-4c2f-a664-69da13182ffc" />
|
|
3
3
|
</p>
|
|
4
4
|
<h1 align="center">Motion</h1>
|
|
5
|
+
<h3 align="center">
|
|
6
|
+
An open source animation library for JavaScript, React and Vue
|
|
7
|
+
</h3>
|
|
5
8
|
|
|
6
9
|
<br>
|
|
7
10
|
|
|
8
|
-
|
|
9
|
-
<a href="https://www.npmjs.com/package/framer-motion" target="_blank">
|
|
10
|
-
<img src="https://img.shields.io/npm/v/framer-motion.svg?style=flat-square" />
|
|
11
|
-
</a>
|
|
12
|
-
<a href="https://www.npmjs.com/package/framer-motion" target="_blank">
|
|
13
|
-
<img src="https://img.shields.io/npm/dm/framer-motion.svg?style=flat-square" />
|
|
14
|
-
</a>
|
|
15
|
-
<a href="https://twitter.com/motiondotdev" target="_blank">
|
|
16
|
-
<img src="https://img.shields.io/twitter/follow/framer.svg?style=social&label=Follow" />
|
|
17
|
-
</a>
|
|
18
|
-
</p>
|
|
11
|
+
Motion is an animation library and suite of developer tools for making beautiful animations.
|
|
19
12
|
|
|
20
|
-
|
|
21
|
-
<hr>
|
|
22
|
-
<br>
|
|
13
|
+
It's the only library with first-class APIs for JS, React and Vue. It's also the only library with a **hybrid engine**, combining the power of JS animations with the performance of native browser APIs.
|
|
23
14
|
|
|
24
|
-
|
|
15
|
+
## π¦ Flavours
|
|
25
16
|
|
|
26
|
-
|
|
17
|
+
### JavaScript
|
|
27
18
|
|
|
28
|
-
|
|
19
|
+
```javascript
|
|
20
|
+
import { animate } from "motion"
|
|
29
21
|
|
|
30
|
-
|
|
31
|
-
<motion.div animate={{ x: 0 }} />
|
|
22
|
+
animate("#box", { x: 100 })
|
|
32
23
|
```
|
|
33
24
|
|
|
34
|
-
|
|
25
|
+
Get started with [JavaScript](https://motion.dev/docs/quick-start).
|
|
35
26
|
|
|
36
|
-
|
|
37
|
-
- [Keyframes](https://motion.dev/docs/react-animation#keyframes)
|
|
38
|
-
- [Layout animations](https://motion.dev/docs/react-layout-animations)
|
|
39
|
-
- [Shared layout animations](https://motion.dev/docs/react-layout-animations#shared-layout-animations)
|
|
40
|
-
- [Gestures (drag/tap/hover)](https://motion.dev/docs/react-gestures)
|
|
41
|
-
- [Scroll animations](https://motion.dev/docs/react-scroll-animations)
|
|
42
|
-
- [SVG paths](https://motion.dev/docs/react-animation#svg-line-drawing)
|
|
43
|
-
- [Exit animations](https://motion.dev/docs/react-animation#exit-animations)
|
|
44
|
-
- [Server-side rendering](https://motion.dev/docs/react-motion-component#server-side-rendering)
|
|
45
|
-
- [Independent transforms](https://motion.dev/docs/react-motion-component#style)
|
|
46
|
-
- [Orchestrate animations across components](https://motion.dev/docs/react-animation#orchestration)
|
|
47
|
-
- [CSS variables](https://motion.dev/docs/react-animation#css-variables)
|
|
27
|
+
### React
|
|
48
28
|
|
|
49
|
-
|
|
29
|
+
```bash
|
|
30
|
+
npm install motion
|
|
31
|
+
```
|
|
50
32
|
|
|
51
|
-
|
|
33
|
+
```jsx
|
|
34
|
+
import { motion } from "motion/react"
|
|
52
35
|
|
|
53
|
-
|
|
36
|
+
function Component() {
|
|
37
|
+
return <motion.div animate={{ x: 100 }} />
|
|
38
|
+
}
|
|
39
|
+
```
|
|
54
40
|
|
|
55
|
-
|
|
41
|
+
Get started with [Motion for React](https://motion.dev/docs/react-quick-start).
|
|
56
42
|
|
|
57
|
-
|
|
58
|
-
|
|
43
|
+
### Vue
|
|
44
|
+
|
|
45
|
+
```html
|
|
46
|
+
<script>
|
|
47
|
+
import { motion } from "motion-v"
|
|
48
|
+
</script>
|
|
49
|
+
|
|
50
|
+
<template> <motion.div :animate={{ x: 100 }} /> </template>
|
|
59
51
|
```
|
|
60
52
|
|
|
61
|
-
|
|
53
|
+
Get started with [Motion for Vue](https://motion.dev/docs/vue).
|
|
62
54
|
|
|
63
|
-
|
|
55
|
+
## π¨ Studio
|
|
64
56
|
|
|
65
|
-
|
|
66
|
-
import { animate } from "motion"
|
|
57
|
+

|
|
67
58
|
|
|
68
|
-
|
|
69
|
-
```
|
|
59
|
+
Motion Studio is a versatile suite of developer tools allowing you to:
|
|
70
60
|
|
|
71
|
-
|
|
61
|
+
- Visually edit CSS and Motion easing curves in VS Code
|
|
62
|
+
- Generate CSS springs with LLMs
|
|
63
|
+
- Load Motion docs into your LLM
|
|
72
64
|
|
|
73
|
-
|
|
65
|
+
Get started with [Motion Studio](https://motion.dev/docs/tools-quick-start).
|
|
74
66
|
|
|
75
|
-
|
|
67
|
+
## π Examples
|
|
76
68
|
|
|
77
|
-
|
|
78
|
-
import { motion } from "motion/react"
|
|
69
|
+
[Motion Examples](https://examples.motion.dev) offers 100s of free and Motion+ examples for beginners and advanced users alike. Easy copy/paste code to kickstart your next project.
|
|
79
70
|
|
|
80
|
-
|
|
81
|
-
return <motion.div animate={{ opacity: isVisible ? 1 : 0 }} />
|
|
82
|
-
}
|
|
83
|
-
```
|
|
71
|
+
## β‘οΈ Motion+
|
|
84
72
|
|
|
85
|
-
[
|
|
73
|
+
[Motion+](https://motion.dev/plus) is a one-time fee, lifetime membership that unlocks over 100 premium examples, early access, powerful Studio tools, a private Discord, and exclusive APIs like:
|
|
86
74
|
|
|
87
|
-
|
|
75
|
+
- Cursor
|
|
76
|
+
- Ticker
|
|
77
|
+
- AnimateNumber
|
|
78
|
+
- splitText
|
|
88
79
|
|
|
89
|
-
|
|
80
|
+
[Get Motion+](https://motion.dev/plus)
|
|
90
81
|
|
|
91
|
-
|
|
82
|
+
## π©π»ββοΈ License
|
|
92
83
|
|
|
93
84
|
- Motion is MIT licensed.
|
|
94
85
|
|
|
86
|
+
## π Contribute
|
|
87
|
+
|
|
88
|
+
- Want to contribute to Motion? Our [contributing guide](https://github.com/motiondivision/motion/blob/master/CONTRIBUTING.md) has you covered.
|
|
89
|
+
|
|
95
90
|
## β¨ Sponsors
|
|
96
91
|
|
|
97
92
|
Motion is sustainable thanks to the kind support of its sponsors.
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "motion",
|
|
3
|
-
"version": "12.20.
|
|
3
|
+
"version": "12.20.3",
|
|
4
4
|
"description": "An animation library for JavaScript and React.",
|
|
5
5
|
"main": "dist/cjs/index.js",
|
|
6
6
|
"module": "dist/es/index.mjs",
|
|
@@ -76,7 +76,7 @@
|
|
|
76
76
|
"postpublish": "git push --tags"
|
|
77
77
|
},
|
|
78
78
|
"dependencies": {
|
|
79
|
-
"framer-motion": "^12.20.
|
|
79
|
+
"framer-motion": "^12.20.3",
|
|
80
80
|
"tslib": "^2.4.0"
|
|
81
81
|
},
|
|
82
82
|
"peerDependencies": {
|
|
@@ -95,5 +95,5 @@
|
|
|
95
95
|
"optional": true
|
|
96
96
|
}
|
|
97
97
|
},
|
|
98
|
-
"gitHead": "
|
|
98
|
+
"gitHead": "3e3203f3f75d61eb393b3ba4fe3f0ec1a5eae59d"
|
|
99
99
|
}
|