@micromag/element-audio 0.4.21 → 0.4.25
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/es/index.js +5 -1
- package/package.json +4 -4
package/es/index.js
CHANGED
|
@@ -8,7 +8,7 @@ import { useDimensionObserver, useMediaCurrentTime, useMediaReady, useMediaDurat
|
|
|
8
8
|
import _toConsumableArray from '@babel/runtime/helpers/toConsumableArray';
|
|
9
9
|
import { useGesture } from '@use-gesture/react';
|
|
10
10
|
import { useIntl } from 'react-intl';
|
|
11
|
-
import { useSpring } from '@react-spring/core';
|
|
11
|
+
import { useSpringRef, useSpring } from '@react-spring/core';
|
|
12
12
|
import { animated } from '@react-spring/web';
|
|
13
13
|
import { getContrastingColor } from '@micromag/core/utils';
|
|
14
14
|
|
|
@@ -406,8 +406,12 @@ function AudioWave(_ref) {
|
|
|
406
406
|
|
|
407
407
|
// Linear animation for progress bar
|
|
408
408
|
|
|
409
|
+
// In react-spring v10, useSpring(fn) without deps resets the spring on every render
|
|
410
|
+
// via a layout effect. Passing a SpringRef prevents this reset behavior.
|
|
411
|
+
var springRef = useSpringRef();
|
|
409
412
|
var _useSpring = useSpring(function () {
|
|
410
413
|
return {
|
|
414
|
+
ref: springRef,
|
|
411
415
|
x: 0,
|
|
412
416
|
config: {
|
|
413
417
|
duration: 0
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@micromag/element-audio",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.25",
|
|
4
4
|
"private": false,
|
|
5
5
|
"description": "",
|
|
6
6
|
"keywords": [
|
|
@@ -61,8 +61,8 @@
|
|
|
61
61
|
},
|
|
62
62
|
"dependencies": {
|
|
63
63
|
"@babel/runtime": "^7.28.6",
|
|
64
|
-
"@micromag/core": "^0.4.
|
|
65
|
-
"@micromag/element-closed-captions": "^0.4.
|
|
64
|
+
"@micromag/core": "^0.4.25",
|
|
65
|
+
"@micromag/element-closed-captions": "^0.4.25",
|
|
66
66
|
"@react-spring/core": "^10.0.3",
|
|
67
67
|
"@react-spring/web": "^10.0.3",
|
|
68
68
|
"@use-gesture/react": "^10.3.0",
|
|
@@ -75,5 +75,5 @@
|
|
|
75
75
|
"access": "public",
|
|
76
76
|
"registry": "https://registry.npmjs.org/"
|
|
77
77
|
},
|
|
78
|
-
"gitHead": "
|
|
78
|
+
"gitHead": "01f62fcaf9ea405d162fdc26e36479d9f307f640"
|
|
79
79
|
}
|