framer-motion 7.4.0 → 7.5.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/dist/cjs/index.js +4 -4
- package/dist/es/render/utils/motion-values.mjs +1 -1
- package/dist/es/utils/use-animation-frame.mjs +2 -2
- package/dist/es/value/index.mjs +1 -1
- package/dist/framer-motion.dev.js +4 -4
- package/dist/framer-motion.js +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/projection.dev.js +2 -2
- package/dist/size-rollup-dom-animation.js +1 -1
- package/dist/size-rollup-dom-max.js +1 -1
- package/dist/size-rollup-motion.js +1 -1
- package/package.json +2 -2
package/dist/cjs/index.js
CHANGED
|
@@ -2245,7 +2245,7 @@ class MotionValue {
|
|
|
2245
2245
|
* This will be replaced by the build step with the latest version number.
|
|
2246
2246
|
* When MotionValues are provided to motion components, warn if versions are mixed.
|
|
2247
2247
|
*/
|
|
2248
|
-
this.version = "7.
|
|
2248
|
+
this.version = "7.5.0";
|
|
2249
2249
|
/**
|
|
2250
2250
|
* Duration, in milliseconds, since last updating frame.
|
|
2251
2251
|
*
|
|
@@ -4221,7 +4221,7 @@ function updateMotionValuesFromProps(element, next, prev) {
|
|
|
4221
4221
|
* and warn against mismatches.
|
|
4222
4222
|
*/
|
|
4223
4223
|
if (process.env.NODE_ENV === "development") {
|
|
4224
|
-
warnOnce(nextValue.version === "7.
|
|
4224
|
+
warnOnce(nextValue.version === "7.5.0", `Attempting to mix Framer Motion versions ${nextValue.version} with 7.5.0 may not work as expected.`);
|
|
4225
4225
|
}
|
|
4226
4226
|
}
|
|
4227
4227
|
else if (isMotionValue(prevValue)) {
|
|
@@ -7856,10 +7856,10 @@ function useAnimationFrame(callback) {
|
|
|
7856
7856
|
React.useEffect(() => {
|
|
7857
7857
|
if (isStatic)
|
|
7858
7858
|
return;
|
|
7859
|
-
const provideTimeSinceStart = ({ timestamp }) => {
|
|
7859
|
+
const provideTimeSinceStart = ({ timestamp, delta }) => {
|
|
7860
7860
|
if (!initialTimestamp.current)
|
|
7861
7861
|
initialTimestamp.current = timestamp;
|
|
7862
|
-
callback(timestamp - initialTimestamp.current);
|
|
7862
|
+
callback(timestamp - initialTimestamp.current, delta);
|
|
7863
7863
|
};
|
|
7864
7864
|
sync__default["default"].update(provideTimeSinceStart, true);
|
|
7865
7865
|
return () => sync.cancelSync.update(provideTimeSinceStart);
|
|
@@ -22,7 +22,7 @@ function updateMotionValuesFromProps(element, next, prev) {
|
|
|
22
22
|
* and warn against mismatches.
|
|
23
23
|
*/
|
|
24
24
|
if (process.env.NODE_ENV === "development") {
|
|
25
|
-
warnOnce(nextValue.version === "7.
|
|
25
|
+
warnOnce(nextValue.version === "7.5.0", `Attempting to mix Framer Motion versions ${nextValue.version} with 7.5.0 may not work as expected.`);
|
|
26
26
|
}
|
|
27
27
|
}
|
|
28
28
|
else if (isMotionValue(prevValue)) {
|
|
@@ -8,10 +8,10 @@ function useAnimationFrame(callback) {
|
|
|
8
8
|
useEffect(() => {
|
|
9
9
|
if (isStatic)
|
|
10
10
|
return;
|
|
11
|
-
const provideTimeSinceStart = ({ timestamp }) => {
|
|
11
|
+
const provideTimeSinceStart = ({ timestamp, delta }) => {
|
|
12
12
|
if (!initialTimestamp.current)
|
|
13
13
|
initialTimestamp.current = timestamp;
|
|
14
|
-
callback(timestamp - initialTimestamp.current);
|
|
14
|
+
callback(timestamp - initialTimestamp.current, delta);
|
|
15
15
|
};
|
|
16
16
|
sync.update(provideTimeSinceStart, true);
|
|
17
17
|
return () => cancelSync.update(provideTimeSinceStart);
|
package/dist/es/value/index.mjs
CHANGED
|
@@ -24,7 +24,7 @@ class MotionValue {
|
|
|
24
24
|
* This will be replaced by the build step with the latest version number.
|
|
25
25
|
* When MotionValues are provided to motion components, warn if versions are mixed.
|
|
26
26
|
*/
|
|
27
|
-
this.version = "7.
|
|
27
|
+
this.version = "7.5.0";
|
|
28
28
|
/**
|
|
29
29
|
* Duration, in milliseconds, since last updating frame.
|
|
30
30
|
*
|
|
@@ -3413,7 +3413,7 @@
|
|
|
3413
3413
|
* This will be replaced by the build step with the latest version number.
|
|
3414
3414
|
* When MotionValues are provided to motion components, warn if versions are mixed.
|
|
3415
3415
|
*/
|
|
3416
|
-
this.version = "7.
|
|
3416
|
+
this.version = "7.5.0";
|
|
3417
3417
|
/**
|
|
3418
3418
|
* Duration, in milliseconds, since last updating frame.
|
|
3419
3419
|
*
|
|
@@ -5389,7 +5389,7 @@
|
|
|
5389
5389
|
* and warn against mismatches.
|
|
5390
5390
|
*/
|
|
5391
5391
|
{
|
|
5392
|
-
warnOnce(nextValue.version === "7.
|
|
5392
|
+
warnOnce(nextValue.version === "7.5.0", `Attempting to mix Framer Motion versions ${nextValue.version} with 7.5.0 may not work as expected.`);
|
|
5393
5393
|
}
|
|
5394
5394
|
}
|
|
5395
5395
|
else if (isMotionValue(prevValue)) {
|
|
@@ -9605,10 +9605,10 @@
|
|
|
9605
9605
|
React.useEffect(() => {
|
|
9606
9606
|
if (isStatic)
|
|
9607
9607
|
return;
|
|
9608
|
-
const provideTimeSinceStart = ({ timestamp }) => {
|
|
9608
|
+
const provideTimeSinceStart = ({ timestamp, delta }) => {
|
|
9609
9609
|
if (!initialTimestamp.current)
|
|
9610
9610
|
initialTimestamp.current = timestamp;
|
|
9611
|
-
callback(timestamp - initialTimestamp.current);
|
|
9611
|
+
callback(timestamp - initialTimestamp.current, delta);
|
|
9612
9612
|
};
|
|
9613
9613
|
sync.update(provideTimeSinceStart, true);
|
|
9614
9614
|
return () => cancelSync.update(provideTimeSinceStart);
|