motion-dom 12.20.3 → 12.22.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 +25 -0
- package/dist/es/index.mjs +1 -0
- package/dist/es/utils/stagger.mjs +26 -0
- package/dist/index.d.ts +291 -279
- package/dist/motion-dom.dev.js +25 -0
- package/dist/motion-dom.js +1 -1
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -1,230 +1,230 @@
|
|
|
1
1
|
import { Box, Easing, EasingFunction, BezierDefinition, Point, BoundingBox, Axis } from 'motion-utils';
|
|
2
2
|
|
|
3
3
|
interface SVGAttributes {
|
|
4
|
-
accentHeight?:
|
|
4
|
+
accentHeight?: AnyResolvedKeyframe | undefined;
|
|
5
5
|
accumulate?: "none" | "sum" | undefined;
|
|
6
6
|
additive?: "replace" | "sum" | undefined;
|
|
7
7
|
alignmentBaseline?: "auto" | "baseline" | "before-edge" | "text-before-edge" | "middle" | "central" | "after-edge" | "text-after-edge" | "ideographic" | "alphabetic" | "hanging" | "mathematical" | "inherit" | undefined;
|
|
8
8
|
allowReorder?: "no" | "yes" | undefined;
|
|
9
|
-
alphabetic?:
|
|
10
|
-
amplitude?:
|
|
9
|
+
alphabetic?: AnyResolvedKeyframe | undefined;
|
|
10
|
+
amplitude?: AnyResolvedKeyframe | undefined;
|
|
11
11
|
arabicForm?: "initial" | "medial" | "terminal" | "isolated" | undefined;
|
|
12
|
-
ascent?:
|
|
12
|
+
ascent?: AnyResolvedKeyframe | undefined;
|
|
13
13
|
attributeName?: string | undefined;
|
|
14
14
|
attributeType?: string | undefined;
|
|
15
15
|
autoReverse?: boolean | undefined;
|
|
16
|
-
azimuth?:
|
|
17
|
-
baseFrequency?:
|
|
18
|
-
baselineShift?:
|
|
19
|
-
baseProfile?:
|
|
20
|
-
bbox?:
|
|
21
|
-
begin?:
|
|
22
|
-
bias?:
|
|
23
|
-
by?:
|
|
24
|
-
calcMode?:
|
|
25
|
-
capHeight?:
|
|
26
|
-
clip?:
|
|
16
|
+
azimuth?: AnyResolvedKeyframe | undefined;
|
|
17
|
+
baseFrequency?: AnyResolvedKeyframe | undefined;
|
|
18
|
+
baselineShift?: AnyResolvedKeyframe | undefined;
|
|
19
|
+
baseProfile?: AnyResolvedKeyframe | undefined;
|
|
20
|
+
bbox?: AnyResolvedKeyframe | undefined;
|
|
21
|
+
begin?: AnyResolvedKeyframe | undefined;
|
|
22
|
+
bias?: AnyResolvedKeyframe | undefined;
|
|
23
|
+
by?: AnyResolvedKeyframe | undefined;
|
|
24
|
+
calcMode?: AnyResolvedKeyframe | undefined;
|
|
25
|
+
capHeight?: AnyResolvedKeyframe | undefined;
|
|
26
|
+
clip?: AnyResolvedKeyframe | undefined;
|
|
27
27
|
clipPath?: string | undefined;
|
|
28
|
-
clipPathUnits?:
|
|
29
|
-
clipRule?:
|
|
30
|
-
colorInterpolation?:
|
|
28
|
+
clipPathUnits?: AnyResolvedKeyframe | undefined;
|
|
29
|
+
clipRule?: AnyResolvedKeyframe | undefined;
|
|
30
|
+
colorInterpolation?: AnyResolvedKeyframe | undefined;
|
|
31
31
|
colorInterpolationFilters?: "auto" | "sRGB" | "linearRGB" | "inherit" | undefined;
|
|
32
|
-
colorProfile?:
|
|
33
|
-
colorRendering?:
|
|
34
|
-
contentScriptType?:
|
|
35
|
-
contentStyleType?:
|
|
36
|
-
cursor?:
|
|
37
|
-
cx?:
|
|
38
|
-
cy?:
|
|
32
|
+
colorProfile?: AnyResolvedKeyframe | undefined;
|
|
33
|
+
colorRendering?: AnyResolvedKeyframe | undefined;
|
|
34
|
+
contentScriptType?: AnyResolvedKeyframe | undefined;
|
|
35
|
+
contentStyleType?: AnyResolvedKeyframe | undefined;
|
|
36
|
+
cursor?: AnyResolvedKeyframe | undefined;
|
|
37
|
+
cx?: AnyResolvedKeyframe | undefined;
|
|
38
|
+
cy?: AnyResolvedKeyframe | undefined;
|
|
39
39
|
d?: string | undefined;
|
|
40
|
-
decelerate?:
|
|
41
|
-
descent?:
|
|
42
|
-
diffuseConstant?:
|
|
43
|
-
direction?:
|
|
44
|
-
display?:
|
|
45
|
-
divisor?:
|
|
46
|
-
dominantBaseline?:
|
|
47
|
-
dur?:
|
|
48
|
-
dx?:
|
|
49
|
-
dy?:
|
|
50
|
-
edgeMode?:
|
|
51
|
-
elevation?:
|
|
52
|
-
enableBackground?:
|
|
53
|
-
end?:
|
|
54
|
-
exponent?:
|
|
40
|
+
decelerate?: AnyResolvedKeyframe | undefined;
|
|
41
|
+
descent?: AnyResolvedKeyframe | undefined;
|
|
42
|
+
diffuseConstant?: AnyResolvedKeyframe | undefined;
|
|
43
|
+
direction?: AnyResolvedKeyframe | undefined;
|
|
44
|
+
display?: AnyResolvedKeyframe | undefined;
|
|
45
|
+
divisor?: AnyResolvedKeyframe | undefined;
|
|
46
|
+
dominantBaseline?: AnyResolvedKeyframe | undefined;
|
|
47
|
+
dur?: AnyResolvedKeyframe | undefined;
|
|
48
|
+
dx?: AnyResolvedKeyframe | undefined;
|
|
49
|
+
dy?: AnyResolvedKeyframe | undefined;
|
|
50
|
+
edgeMode?: AnyResolvedKeyframe | undefined;
|
|
51
|
+
elevation?: AnyResolvedKeyframe | undefined;
|
|
52
|
+
enableBackground?: AnyResolvedKeyframe | undefined;
|
|
53
|
+
end?: AnyResolvedKeyframe | undefined;
|
|
54
|
+
exponent?: AnyResolvedKeyframe | undefined;
|
|
55
55
|
externalResourcesRequired?: boolean | undefined;
|
|
56
56
|
fill?: string | undefined;
|
|
57
|
-
fillOpacity?:
|
|
57
|
+
fillOpacity?: AnyResolvedKeyframe | undefined;
|
|
58
58
|
fillRule?: "nonzero" | "evenodd" | "inherit" | undefined;
|
|
59
59
|
filter?: string | undefined;
|
|
60
|
-
filterRes?:
|
|
61
|
-
filterUnits?:
|
|
62
|
-
floodColor?:
|
|
63
|
-
floodOpacity?:
|
|
60
|
+
filterRes?: AnyResolvedKeyframe | undefined;
|
|
61
|
+
filterUnits?: AnyResolvedKeyframe | undefined;
|
|
62
|
+
floodColor?: AnyResolvedKeyframe | undefined;
|
|
63
|
+
floodOpacity?: AnyResolvedKeyframe | undefined;
|
|
64
64
|
focusable?: boolean | "auto" | undefined;
|
|
65
65
|
fontFamily?: string | undefined;
|
|
66
|
-
fontSize?:
|
|
67
|
-
fontSizeAdjust?:
|
|
68
|
-
fontStretch?:
|
|
69
|
-
fontStyle?:
|
|
70
|
-
fontVariant?:
|
|
71
|
-
fontWeight?:
|
|
72
|
-
format?:
|
|
73
|
-
fr?:
|
|
74
|
-
from?:
|
|
75
|
-
fx?:
|
|
76
|
-
fy?:
|
|
77
|
-
g1?:
|
|
78
|
-
g2?:
|
|
79
|
-
glyphName?:
|
|
80
|
-
glyphOrientationHorizontal?:
|
|
81
|
-
glyphOrientationVertical?:
|
|
82
|
-
glyphRef?:
|
|
66
|
+
fontSize?: AnyResolvedKeyframe | undefined;
|
|
67
|
+
fontSizeAdjust?: AnyResolvedKeyframe | undefined;
|
|
68
|
+
fontStretch?: AnyResolvedKeyframe | undefined;
|
|
69
|
+
fontStyle?: AnyResolvedKeyframe | undefined;
|
|
70
|
+
fontVariant?: AnyResolvedKeyframe | undefined;
|
|
71
|
+
fontWeight?: AnyResolvedKeyframe | undefined;
|
|
72
|
+
format?: AnyResolvedKeyframe | undefined;
|
|
73
|
+
fr?: AnyResolvedKeyframe | undefined;
|
|
74
|
+
from?: AnyResolvedKeyframe | undefined;
|
|
75
|
+
fx?: AnyResolvedKeyframe | undefined;
|
|
76
|
+
fy?: AnyResolvedKeyframe | undefined;
|
|
77
|
+
g1?: AnyResolvedKeyframe | undefined;
|
|
78
|
+
g2?: AnyResolvedKeyframe | undefined;
|
|
79
|
+
glyphName?: AnyResolvedKeyframe | undefined;
|
|
80
|
+
glyphOrientationHorizontal?: AnyResolvedKeyframe | undefined;
|
|
81
|
+
glyphOrientationVertical?: AnyResolvedKeyframe | undefined;
|
|
82
|
+
glyphRef?: AnyResolvedKeyframe | undefined;
|
|
83
83
|
gradientTransform?: string | undefined;
|
|
84
84
|
gradientUnits?: string | undefined;
|
|
85
|
-
hanging?:
|
|
86
|
-
horizAdvX?:
|
|
87
|
-
horizOriginX?:
|
|
85
|
+
hanging?: AnyResolvedKeyframe | undefined;
|
|
86
|
+
horizAdvX?: AnyResolvedKeyframe | undefined;
|
|
87
|
+
horizOriginX?: AnyResolvedKeyframe | undefined;
|
|
88
88
|
href?: string | undefined;
|
|
89
|
-
ideographic?:
|
|
90
|
-
imageRendering?:
|
|
91
|
-
in2?:
|
|
89
|
+
ideographic?: AnyResolvedKeyframe | undefined;
|
|
90
|
+
imageRendering?: AnyResolvedKeyframe | undefined;
|
|
91
|
+
in2?: AnyResolvedKeyframe | undefined;
|
|
92
92
|
in?: string | undefined;
|
|
93
|
-
intercept?:
|
|
94
|
-
k1?:
|
|
95
|
-
k2?:
|
|
96
|
-
k3?:
|
|
97
|
-
k4?:
|
|
98
|
-
k?:
|
|
99
|
-
kernelMatrix?:
|
|
100
|
-
kernelUnitLength?:
|
|
101
|
-
kerning?:
|
|
102
|
-
keyPoints?:
|
|
103
|
-
keySplines?:
|
|
104
|
-
keyTimes?:
|
|
105
|
-
lengthAdjust?:
|
|
106
|
-
letterSpacing?:
|
|
107
|
-
lightingColor?:
|
|
108
|
-
limitingConeAngle?:
|
|
109
|
-
local?:
|
|
93
|
+
intercept?: AnyResolvedKeyframe | undefined;
|
|
94
|
+
k1?: AnyResolvedKeyframe | undefined;
|
|
95
|
+
k2?: AnyResolvedKeyframe | undefined;
|
|
96
|
+
k3?: AnyResolvedKeyframe | undefined;
|
|
97
|
+
k4?: AnyResolvedKeyframe | undefined;
|
|
98
|
+
k?: AnyResolvedKeyframe | undefined;
|
|
99
|
+
kernelMatrix?: AnyResolvedKeyframe | undefined;
|
|
100
|
+
kernelUnitLength?: AnyResolvedKeyframe | undefined;
|
|
101
|
+
kerning?: AnyResolvedKeyframe | undefined;
|
|
102
|
+
keyPoints?: AnyResolvedKeyframe | undefined;
|
|
103
|
+
keySplines?: AnyResolvedKeyframe | undefined;
|
|
104
|
+
keyTimes?: AnyResolvedKeyframe | undefined;
|
|
105
|
+
lengthAdjust?: AnyResolvedKeyframe | undefined;
|
|
106
|
+
letterSpacing?: AnyResolvedKeyframe | undefined;
|
|
107
|
+
lightingColor?: AnyResolvedKeyframe | undefined;
|
|
108
|
+
limitingConeAngle?: AnyResolvedKeyframe | undefined;
|
|
109
|
+
local?: AnyResolvedKeyframe | undefined;
|
|
110
110
|
markerEnd?: string | undefined;
|
|
111
|
-
markerHeight?:
|
|
111
|
+
markerHeight?: AnyResolvedKeyframe | undefined;
|
|
112
112
|
markerMid?: string | undefined;
|
|
113
113
|
markerStart?: string | undefined;
|
|
114
|
-
markerUnits?:
|
|
115
|
-
markerWidth?:
|
|
114
|
+
markerUnits?: AnyResolvedKeyframe | undefined;
|
|
115
|
+
markerWidth?: AnyResolvedKeyframe | undefined;
|
|
116
116
|
mask?: string | undefined;
|
|
117
|
-
maskContentUnits?:
|
|
118
|
-
maskUnits?:
|
|
119
|
-
mathematical?:
|
|
120
|
-
mode?:
|
|
121
|
-
numOctaves?:
|
|
122
|
-
offset?:
|
|
123
|
-
opacity?:
|
|
124
|
-
operator?:
|
|
125
|
-
order?:
|
|
126
|
-
orient?:
|
|
127
|
-
orientation?:
|
|
128
|
-
origin?:
|
|
129
|
-
overflow?:
|
|
130
|
-
overlinePosition?:
|
|
131
|
-
overlineThickness?:
|
|
132
|
-
paintOrder?:
|
|
133
|
-
panose1?:
|
|
117
|
+
maskContentUnits?: AnyResolvedKeyframe | undefined;
|
|
118
|
+
maskUnits?: AnyResolvedKeyframe | undefined;
|
|
119
|
+
mathematical?: AnyResolvedKeyframe | undefined;
|
|
120
|
+
mode?: AnyResolvedKeyframe | undefined;
|
|
121
|
+
numOctaves?: AnyResolvedKeyframe | undefined;
|
|
122
|
+
offset?: AnyResolvedKeyframe | undefined;
|
|
123
|
+
opacity?: AnyResolvedKeyframe | undefined;
|
|
124
|
+
operator?: AnyResolvedKeyframe | undefined;
|
|
125
|
+
order?: AnyResolvedKeyframe | undefined;
|
|
126
|
+
orient?: AnyResolvedKeyframe | undefined;
|
|
127
|
+
orientation?: AnyResolvedKeyframe | undefined;
|
|
128
|
+
origin?: AnyResolvedKeyframe | undefined;
|
|
129
|
+
overflow?: AnyResolvedKeyframe | undefined;
|
|
130
|
+
overlinePosition?: AnyResolvedKeyframe | undefined;
|
|
131
|
+
overlineThickness?: AnyResolvedKeyframe | undefined;
|
|
132
|
+
paintOrder?: AnyResolvedKeyframe | undefined;
|
|
133
|
+
panose1?: AnyResolvedKeyframe | undefined;
|
|
134
134
|
path?: string | undefined;
|
|
135
|
-
pathLength?:
|
|
135
|
+
pathLength?: AnyResolvedKeyframe | undefined;
|
|
136
136
|
patternContentUnits?: string | undefined;
|
|
137
|
-
patternTransform?:
|
|
137
|
+
patternTransform?: AnyResolvedKeyframe | undefined;
|
|
138
138
|
patternUnits?: string | undefined;
|
|
139
|
-
pointerEvents?:
|
|
139
|
+
pointerEvents?: AnyResolvedKeyframe | undefined;
|
|
140
140
|
points?: string | undefined;
|
|
141
|
-
pointsAtX?:
|
|
142
|
-
pointsAtY?:
|
|
143
|
-
pointsAtZ?:
|
|
141
|
+
pointsAtX?: AnyResolvedKeyframe | undefined;
|
|
142
|
+
pointsAtY?: AnyResolvedKeyframe | undefined;
|
|
143
|
+
pointsAtZ?: AnyResolvedKeyframe | undefined;
|
|
144
144
|
preserveAlpha?: boolean | undefined;
|
|
145
145
|
preserveAspectRatio?: string | undefined;
|
|
146
|
-
primitiveUnits?:
|
|
147
|
-
r?:
|
|
148
|
-
radius?:
|
|
149
|
-
refX?:
|
|
150
|
-
refY?:
|
|
151
|
-
renderingIntent?:
|
|
152
|
-
repeatCount?:
|
|
153
|
-
repeatDur?:
|
|
154
|
-
requiredExtensions?:
|
|
155
|
-
requiredFeatures?:
|
|
156
|
-
restart?:
|
|
146
|
+
primitiveUnits?: AnyResolvedKeyframe | undefined;
|
|
147
|
+
r?: AnyResolvedKeyframe | undefined;
|
|
148
|
+
radius?: AnyResolvedKeyframe | undefined;
|
|
149
|
+
refX?: AnyResolvedKeyframe | undefined;
|
|
150
|
+
refY?: AnyResolvedKeyframe | undefined;
|
|
151
|
+
renderingIntent?: AnyResolvedKeyframe | undefined;
|
|
152
|
+
repeatCount?: AnyResolvedKeyframe | undefined;
|
|
153
|
+
repeatDur?: AnyResolvedKeyframe | undefined;
|
|
154
|
+
requiredExtensions?: AnyResolvedKeyframe | undefined;
|
|
155
|
+
requiredFeatures?: AnyResolvedKeyframe | undefined;
|
|
156
|
+
restart?: AnyResolvedKeyframe | undefined;
|
|
157
157
|
result?: string | undefined;
|
|
158
|
-
rotate?:
|
|
159
|
-
rx?:
|
|
160
|
-
ry?:
|
|
161
|
-
scale?:
|
|
162
|
-
seed?:
|
|
163
|
-
shapeRendering?:
|
|
164
|
-
slope?:
|
|
165
|
-
spacing?:
|
|
166
|
-
specularConstant?:
|
|
167
|
-
specularExponent?:
|
|
168
|
-
speed?:
|
|
158
|
+
rotate?: AnyResolvedKeyframe | undefined;
|
|
159
|
+
rx?: AnyResolvedKeyframe | undefined;
|
|
160
|
+
ry?: AnyResolvedKeyframe | undefined;
|
|
161
|
+
scale?: AnyResolvedKeyframe | undefined;
|
|
162
|
+
seed?: AnyResolvedKeyframe | undefined;
|
|
163
|
+
shapeRendering?: AnyResolvedKeyframe | undefined;
|
|
164
|
+
slope?: AnyResolvedKeyframe | undefined;
|
|
165
|
+
spacing?: AnyResolvedKeyframe | undefined;
|
|
166
|
+
specularConstant?: AnyResolvedKeyframe | undefined;
|
|
167
|
+
specularExponent?: AnyResolvedKeyframe | undefined;
|
|
168
|
+
speed?: AnyResolvedKeyframe | undefined;
|
|
169
169
|
spreadMethod?: string | undefined;
|
|
170
|
-
startOffset?:
|
|
171
|
-
stdDeviation?:
|
|
172
|
-
stemh?:
|
|
173
|
-
stemv?:
|
|
174
|
-
stitchTiles?:
|
|
170
|
+
startOffset?: AnyResolvedKeyframe | undefined;
|
|
171
|
+
stdDeviation?: AnyResolvedKeyframe | undefined;
|
|
172
|
+
stemh?: AnyResolvedKeyframe | undefined;
|
|
173
|
+
stemv?: AnyResolvedKeyframe | undefined;
|
|
174
|
+
stitchTiles?: AnyResolvedKeyframe | undefined;
|
|
175
175
|
stopColor?: string | undefined;
|
|
176
|
-
stopOpacity?:
|
|
177
|
-
strikethroughPosition?:
|
|
178
|
-
strikethroughThickness?:
|
|
179
|
-
string?:
|
|
176
|
+
stopOpacity?: AnyResolvedKeyframe | undefined;
|
|
177
|
+
strikethroughPosition?: AnyResolvedKeyframe | undefined;
|
|
178
|
+
strikethroughThickness?: AnyResolvedKeyframe | undefined;
|
|
179
|
+
string?: AnyResolvedKeyframe | undefined;
|
|
180
180
|
stroke?: string | undefined;
|
|
181
|
-
strokeDasharray?:
|
|
182
|
-
strokeDashoffset?:
|
|
181
|
+
strokeDasharray?: AnyResolvedKeyframe | undefined;
|
|
182
|
+
strokeDashoffset?: AnyResolvedKeyframe | undefined;
|
|
183
183
|
strokeLinecap?: "butt" | "round" | "square" | "inherit" | undefined;
|
|
184
184
|
strokeLinejoin?: "miter" | "round" | "bevel" | "inherit" | undefined;
|
|
185
|
-
strokeMiterlimit?:
|
|
186
|
-
strokeOpacity?:
|
|
187
|
-
strokeWidth?:
|
|
188
|
-
surfaceScale?:
|
|
189
|
-
systemLanguage?:
|
|
190
|
-
tableValues?:
|
|
191
|
-
targetX?:
|
|
192
|
-
targetY?:
|
|
185
|
+
strokeMiterlimit?: AnyResolvedKeyframe | undefined;
|
|
186
|
+
strokeOpacity?: AnyResolvedKeyframe | undefined;
|
|
187
|
+
strokeWidth?: AnyResolvedKeyframe | undefined;
|
|
188
|
+
surfaceScale?: AnyResolvedKeyframe | undefined;
|
|
189
|
+
systemLanguage?: AnyResolvedKeyframe | undefined;
|
|
190
|
+
tableValues?: AnyResolvedKeyframe | undefined;
|
|
191
|
+
targetX?: AnyResolvedKeyframe | undefined;
|
|
192
|
+
targetY?: AnyResolvedKeyframe | undefined;
|
|
193
193
|
textAnchor?: string | undefined;
|
|
194
|
-
textDecoration?:
|
|
195
|
-
textLength?:
|
|
196
|
-
textRendering?:
|
|
197
|
-
to?:
|
|
194
|
+
textDecoration?: AnyResolvedKeyframe | undefined;
|
|
195
|
+
textLength?: AnyResolvedKeyframe | undefined;
|
|
196
|
+
textRendering?: AnyResolvedKeyframe | undefined;
|
|
197
|
+
to?: AnyResolvedKeyframe | undefined;
|
|
198
198
|
transform?: string | undefined;
|
|
199
|
-
u1?:
|
|
200
|
-
u2?:
|
|
201
|
-
underlinePosition?:
|
|
202
|
-
underlineThickness?:
|
|
203
|
-
unicode?:
|
|
204
|
-
unicodeBidi?:
|
|
205
|
-
unicodeRange?:
|
|
206
|
-
unitsPerEm?:
|
|
207
|
-
vAlphabetic?:
|
|
199
|
+
u1?: AnyResolvedKeyframe | undefined;
|
|
200
|
+
u2?: AnyResolvedKeyframe | undefined;
|
|
201
|
+
underlinePosition?: AnyResolvedKeyframe | undefined;
|
|
202
|
+
underlineThickness?: AnyResolvedKeyframe | undefined;
|
|
203
|
+
unicode?: AnyResolvedKeyframe | undefined;
|
|
204
|
+
unicodeBidi?: AnyResolvedKeyframe | undefined;
|
|
205
|
+
unicodeRange?: AnyResolvedKeyframe | undefined;
|
|
206
|
+
unitsPerEm?: AnyResolvedKeyframe | undefined;
|
|
207
|
+
vAlphabetic?: AnyResolvedKeyframe | undefined;
|
|
208
208
|
values?: string | undefined;
|
|
209
|
-
vectorEffect?:
|
|
209
|
+
vectorEffect?: AnyResolvedKeyframe | undefined;
|
|
210
210
|
version?: string | undefined;
|
|
211
|
-
vertAdvY?:
|
|
212
|
-
vertOriginX?:
|
|
213
|
-
vertOriginY?:
|
|
214
|
-
vHanging?:
|
|
215
|
-
vIdeographic?:
|
|
211
|
+
vertAdvY?: AnyResolvedKeyframe | undefined;
|
|
212
|
+
vertOriginX?: AnyResolvedKeyframe | undefined;
|
|
213
|
+
vertOriginY?: AnyResolvedKeyframe | undefined;
|
|
214
|
+
vHanging?: AnyResolvedKeyframe | undefined;
|
|
215
|
+
vIdeographic?: AnyResolvedKeyframe | undefined;
|
|
216
216
|
viewBox?: string | undefined;
|
|
217
|
-
viewTarget?:
|
|
218
|
-
visibility?:
|
|
219
|
-
vMathematical?:
|
|
220
|
-
widths?:
|
|
221
|
-
wordSpacing?:
|
|
222
|
-
writingMode?:
|
|
223
|
-
x1?:
|
|
224
|
-
x2?:
|
|
225
|
-
x?:
|
|
217
|
+
viewTarget?: AnyResolvedKeyframe | undefined;
|
|
218
|
+
visibility?: AnyResolvedKeyframe | undefined;
|
|
219
|
+
vMathematical?: AnyResolvedKeyframe | undefined;
|
|
220
|
+
widths?: AnyResolvedKeyframe | undefined;
|
|
221
|
+
wordSpacing?: AnyResolvedKeyframe | undefined;
|
|
222
|
+
writingMode?: AnyResolvedKeyframe | undefined;
|
|
223
|
+
x1?: AnyResolvedKeyframe | undefined;
|
|
224
|
+
x2?: AnyResolvedKeyframe | undefined;
|
|
225
|
+
x?: AnyResolvedKeyframe | undefined;
|
|
226
226
|
xChannelSelector?: string | undefined;
|
|
227
|
-
xHeight?:
|
|
227
|
+
xHeight?: AnyResolvedKeyframe | undefined;
|
|
228
228
|
xlinkActuate?: string | undefined;
|
|
229
229
|
xlinkArcrole?: string | undefined;
|
|
230
230
|
xlinkHref?: string | undefined;
|
|
@@ -237,11 +237,11 @@ interface SVGAttributes {
|
|
|
237
237
|
xmlns?: string | undefined;
|
|
238
238
|
xmlnsXlink?: string | undefined;
|
|
239
239
|
xmlSpace?: string | undefined;
|
|
240
|
-
y1?:
|
|
241
|
-
y2?:
|
|
242
|
-
y?:
|
|
240
|
+
y1?: AnyResolvedKeyframe | undefined;
|
|
241
|
+
y2?: AnyResolvedKeyframe | undefined;
|
|
242
|
+
y?: AnyResolvedKeyframe | undefined;
|
|
243
243
|
yChannelSelector?: string | undefined;
|
|
244
|
-
z?:
|
|
244
|
+
z?: AnyResolvedKeyframe | undefined;
|
|
245
245
|
zoomAndPan?: string | undefined;
|
|
246
246
|
}
|
|
247
247
|
|
|
@@ -272,13 +272,14 @@ interface WithRender {
|
|
|
272
272
|
measureViewportBox: () => Box;
|
|
273
273
|
}
|
|
274
274
|
|
|
275
|
+
type AnyResolvedKeyframe = string | number;
|
|
275
276
|
interface ProgressTimeline {
|
|
276
277
|
currentTime: null | {
|
|
277
278
|
value: number;
|
|
278
279
|
};
|
|
279
280
|
cancel?: VoidFunction;
|
|
280
281
|
}
|
|
281
|
-
interface ValueAnimationOptionsWithRenderContext<V extends
|
|
282
|
+
interface ValueAnimationOptionsWithRenderContext<V extends AnyResolvedKeyframe = number> extends ValueAnimationOptions<V> {
|
|
282
283
|
KeyframeResolver?: typeof KeyframeResolver;
|
|
283
284
|
motionValue?: MotionValue<V>;
|
|
284
285
|
element?: WithRender;
|
|
@@ -352,14 +353,14 @@ interface KeyframeGenerator<V> {
|
|
|
352
353
|
next: (t: number) => AnimationState<V>;
|
|
353
354
|
toString: () => string;
|
|
354
355
|
}
|
|
355
|
-
interface DOMValueAnimationOptions<V extends
|
|
356
|
+
interface DOMValueAnimationOptions<V extends AnyResolvedKeyframe = number> extends ValueAnimationTransition<V> {
|
|
356
357
|
element: HTMLElement | SVGElement;
|
|
357
358
|
keyframes: ValueKeyframesDefinition;
|
|
358
359
|
name: string;
|
|
359
360
|
pseudoElement?: string;
|
|
360
361
|
allowFlatten?: boolean;
|
|
361
362
|
}
|
|
362
|
-
interface ValueAnimationOptions<V extends
|
|
363
|
+
interface ValueAnimationOptions<V extends AnyResolvedKeyframe = number> extends ValueAnimationTransition {
|
|
363
364
|
keyframes: V[];
|
|
364
365
|
element?: any;
|
|
365
366
|
name?: string;
|
|
@@ -567,11 +568,13 @@ interface AnimationOrchestrationOptions {
|
|
|
567
568
|
when?: false | "beforeChildren" | "afterChildren" | string;
|
|
568
569
|
/**
|
|
569
570
|
* When using variants, children animations will start after this duration
|
|
570
|
-
* (in seconds). You can add the `transition` property to both the `
|
|
571
|
+
* (in seconds). You can add the `transition` property to both the `motion.div` and the
|
|
572
|
+
* `variant` directly. Adding it to the `variant` generally offers more flexibility,
|
|
573
|
+
* as it allows you to customize the delay per visual state.
|
|
571
574
|
*
|
|
572
575
|
* @public
|
|
573
576
|
*/
|
|
574
|
-
delayChildren?: number
|
|
577
|
+
delayChildren?: number | DynamicOption<number>;
|
|
575
578
|
/**
|
|
576
579
|
* When using variants, animations of child components can be staggered by this
|
|
577
580
|
* duration (in seconds).
|
|
@@ -582,7 +585,7 @@ interface AnimationOrchestrationOptions {
|
|
|
582
585
|
*
|
|
583
586
|
* The calculated stagger delay will be added to `delayChildren`.
|
|
584
587
|
*
|
|
585
|
-
* @
|
|
588
|
+
* @deprecated - Use `delayChildren: stagger(interval)` instead.
|
|
586
589
|
*/
|
|
587
590
|
staggerChildren?: number;
|
|
588
591
|
/**
|
|
@@ -591,7 +594,7 @@ interface AnimationOrchestrationOptions {
|
|
|
591
594
|
* A value of `1` staggers from the first to the last while `-1`
|
|
592
595
|
* staggers from the last to the first.
|
|
593
596
|
*
|
|
594
|
-
* @
|
|
597
|
+
* @deprecated - Use `delayChildren: stagger(interval, { from: "last" })` instead.
|
|
595
598
|
*/
|
|
596
599
|
staggerDirection?: number;
|
|
597
600
|
}
|
|
@@ -650,14 +653,14 @@ type SVGPathTransitions = {
|
|
|
650
653
|
type SVGTransitions = {
|
|
651
654
|
[K in keyof Omit<SVGAttributes, "from">]: ValueTransition;
|
|
652
655
|
};
|
|
653
|
-
|
|
656
|
+
interface VariableTransitions {
|
|
654
657
|
[key: `--${string}`]: ValueTransition;
|
|
655
|
-
}
|
|
658
|
+
}
|
|
656
659
|
type StyleTransitions = {
|
|
657
660
|
[K in keyof CSSStyleDeclarationWithTransform]?: ValueTransition;
|
|
658
661
|
};
|
|
659
|
-
type ValueKeyframe<T extends
|
|
660
|
-
type UnresolvedValueKeyframe<T extends
|
|
662
|
+
type ValueKeyframe<T extends AnyResolvedKeyframe = AnyResolvedKeyframe> = T;
|
|
663
|
+
type UnresolvedValueKeyframe<T extends AnyResolvedKeyframe = AnyResolvedKeyframe> = ValueKeyframe<T> | null;
|
|
661
664
|
type ResolvedValueKeyframe = ValueKeyframe | ValueKeyframe[];
|
|
662
665
|
type ValueKeyframesDefinition = ValueKeyframe | ValueKeyframe[] | UnresolvedValueKeyframe[];
|
|
663
666
|
type StyleKeyframesDefinition = {
|
|
@@ -666,9 +669,9 @@ type StyleKeyframesDefinition = {
|
|
|
666
669
|
type SVGKeyframesDefinition = {
|
|
667
670
|
[K in keyof Omit<SVGAttributes, "from">]?: ValueKeyframesDefinition;
|
|
668
671
|
};
|
|
669
|
-
|
|
672
|
+
interface VariableKeyframesDefinition {
|
|
670
673
|
[key: `--${string}`]: ValueKeyframesDefinition;
|
|
671
|
-
}
|
|
674
|
+
}
|
|
672
675
|
type SVGForcedAttrKeyframesDefinition = {
|
|
673
676
|
[K in keyof SVGForcedAttrProperties]?: ValueKeyframesDefinition;
|
|
674
677
|
};
|
|
@@ -679,7 +682,7 @@ type DOMKeyframesDefinition = StyleKeyframesDefinition & SVGKeyframesDefinition
|
|
|
679
682
|
interface Target extends DOMKeyframesDefinition {
|
|
680
683
|
}
|
|
681
684
|
type CSSPropertyKeys = {
|
|
682
|
-
[K in keyof CSSStyleDeclaration as K extends string ? CSSStyleDeclaration[K] extends
|
|
685
|
+
[K in keyof CSSStyleDeclaration as K extends string ? CSSStyleDeclaration[K] extends AnyResolvedKeyframe ? K : never : never]: CSSStyleDeclaration[K];
|
|
683
686
|
};
|
|
684
687
|
interface CSSStyleDeclarationWithTransform extends Omit<CSSPropertyKeys, "direction" | "transition" | "x" | "y" | "z"> {
|
|
685
688
|
x: number | string;
|
|
@@ -715,28 +718,28 @@ type AnimationOptions = ValueAnimationWithDynamicDelay | (ValueAnimationWithDyna
|
|
|
715
718
|
layout?: ValueTransition;
|
|
716
719
|
});
|
|
717
720
|
interface TransformProperties {
|
|
718
|
-
x?:
|
|
719
|
-
y?:
|
|
720
|
-
z?:
|
|
721
|
-
translateX?:
|
|
722
|
-
translateY?:
|
|
723
|
-
translateZ?:
|
|
724
|
-
rotate?:
|
|
725
|
-
rotateX?:
|
|
726
|
-
rotateY?:
|
|
727
|
-
rotateZ?:
|
|
728
|
-
scale?:
|
|
729
|
-
scaleX?:
|
|
730
|
-
scaleY?:
|
|
731
|
-
scaleZ?:
|
|
732
|
-
skew?:
|
|
733
|
-
skewX?:
|
|
734
|
-
skewY?:
|
|
735
|
-
originX?:
|
|
736
|
-
originY?:
|
|
737
|
-
originZ?:
|
|
738
|
-
perspective?:
|
|
739
|
-
transformPerspective?:
|
|
721
|
+
x?: AnyResolvedKeyframe;
|
|
722
|
+
y?: AnyResolvedKeyframe;
|
|
723
|
+
z?: AnyResolvedKeyframe;
|
|
724
|
+
translateX?: AnyResolvedKeyframe;
|
|
725
|
+
translateY?: AnyResolvedKeyframe;
|
|
726
|
+
translateZ?: AnyResolvedKeyframe;
|
|
727
|
+
rotate?: AnyResolvedKeyframe;
|
|
728
|
+
rotateX?: AnyResolvedKeyframe;
|
|
729
|
+
rotateY?: AnyResolvedKeyframe;
|
|
730
|
+
rotateZ?: AnyResolvedKeyframe;
|
|
731
|
+
scale?: AnyResolvedKeyframe;
|
|
732
|
+
scaleX?: AnyResolvedKeyframe;
|
|
733
|
+
scaleY?: AnyResolvedKeyframe;
|
|
734
|
+
scaleZ?: AnyResolvedKeyframe;
|
|
735
|
+
skew?: AnyResolvedKeyframe;
|
|
736
|
+
skewX?: AnyResolvedKeyframe;
|
|
737
|
+
skewY?: AnyResolvedKeyframe;
|
|
738
|
+
originX?: AnyResolvedKeyframe;
|
|
739
|
+
originY?: AnyResolvedKeyframe;
|
|
740
|
+
originZ?: AnyResolvedKeyframe;
|
|
741
|
+
perspective?: AnyResolvedKeyframe;
|
|
742
|
+
transformPerspective?: AnyResolvedKeyframe;
|
|
740
743
|
}
|
|
741
744
|
interface SVGForcedAttrProperties {
|
|
742
745
|
attrX?: number;
|
|
@@ -767,7 +770,7 @@ interface MotionValueEventCallbacks<V> {
|
|
|
767
770
|
destroy: () => void;
|
|
768
771
|
}
|
|
769
772
|
interface ResolvedValues$1 {
|
|
770
|
-
[key: string]:
|
|
773
|
+
[key: string]: AnyResolvedKeyframe;
|
|
771
774
|
}
|
|
772
775
|
interface Owner {
|
|
773
776
|
current: HTMLElement | unknown;
|
|
@@ -975,16 +978,16 @@ declare class MotionValue<V = any> {
|
|
|
975
978
|
}
|
|
976
979
|
declare function motionValue<V>(init: V, options?: MotionValueOptions): MotionValue<V>;
|
|
977
980
|
|
|
978
|
-
type UnresolvedKeyframes<T extends
|
|
979
|
-
type ResolvedKeyframes<T extends
|
|
981
|
+
type UnresolvedKeyframes<T extends AnyResolvedKeyframe> = Array<T | null>;
|
|
982
|
+
type ResolvedKeyframes<T extends AnyResolvedKeyframe> = Array<T>;
|
|
980
983
|
declare function flushKeyframeResolvers(): void;
|
|
981
|
-
type OnKeyframesResolved<T extends
|
|
982
|
-
declare class KeyframeResolver<T extends
|
|
984
|
+
type OnKeyframesResolved<T extends AnyResolvedKeyframe> = (resolvedKeyframes: ResolvedKeyframes<T>, finalKeyframe: T, forced: boolean) => void;
|
|
985
|
+
declare class KeyframeResolver<T extends AnyResolvedKeyframe = any> {
|
|
983
986
|
name?: string;
|
|
984
987
|
element?: WithRender;
|
|
985
988
|
finalKeyframe?: T;
|
|
986
989
|
suspendedScrollY?: number;
|
|
987
|
-
protected unresolvedKeyframes: UnresolvedKeyframes<
|
|
990
|
+
protected unresolvedKeyframes: UnresolvedKeyframes<AnyResolvedKeyframe>;
|
|
988
991
|
private motionValue?;
|
|
989
992
|
private onComplete;
|
|
990
993
|
state: "pending" | "scheduled" | "complete";
|
|
@@ -999,7 +1002,7 @@ declare class KeyframeResolver<T extends string | number = any> {
|
|
|
999
1002
|
* to resolve its keyframes.
|
|
1000
1003
|
*/
|
|
1001
1004
|
needsMeasurement: boolean;
|
|
1002
|
-
constructor(unresolvedKeyframes: UnresolvedKeyframes<
|
|
1005
|
+
constructor(unresolvedKeyframes: UnresolvedKeyframes<AnyResolvedKeyframe>, onComplete: OnKeyframesResolved<T>, name?: string, motionValue?: MotionValue<T>, element?: WithRender, isAsync?: boolean);
|
|
1003
1006
|
scheduleResolve(): void;
|
|
1004
1007
|
readKeyframes(): void;
|
|
1005
1008
|
setFinalKeyframe(): void;
|
|
@@ -1026,8 +1029,8 @@ declare class WithPromise {
|
|
|
1026
1029
|
then(onResolve: VoidFunction, onReject?: VoidFunction): Promise<void>;
|
|
1027
1030
|
}
|
|
1028
1031
|
|
|
1029
|
-
type OptionsWithoutKeyframes<T extends
|
|
1030
|
-
declare class AsyncMotionValueAnimation<T extends
|
|
1032
|
+
type OptionsWithoutKeyframes<T extends AnyResolvedKeyframe> = Omit<ValueAnimationOptions<T>, "keyframes">;
|
|
1033
|
+
declare class AsyncMotionValueAnimation<T extends AnyResolvedKeyframe> extends WithPromise implements AnimationPlaybackControls {
|
|
1031
1034
|
private createdAt;
|
|
1032
1035
|
private resolvedAt;
|
|
1033
1036
|
private _animation;
|
|
@@ -1148,14 +1151,14 @@ declare class JSAnimation<T extends number | string> extends WithPromise impleme
|
|
|
1148
1151
|
}
|
|
1149
1152
|
declare function animateValue<T extends number | string>(options: ValueAnimationOptions<T>): JSAnimation<T>;
|
|
1150
1153
|
|
|
1151
|
-
interface NativeAnimationOptions<V extends
|
|
1154
|
+
interface NativeAnimationOptions<V extends AnyResolvedKeyframe = number> extends DOMValueAnimationOptions<V> {
|
|
1152
1155
|
pseudoElement?: string;
|
|
1153
1156
|
startTime?: number;
|
|
1154
1157
|
}
|
|
1155
1158
|
/**
|
|
1156
1159
|
* NativeAnimation implements AnimationPlaybackControls for the browser's Web Animations API.
|
|
1157
1160
|
*/
|
|
1158
|
-
declare class NativeAnimation<T extends
|
|
1161
|
+
declare class NativeAnimation<T extends AnyResolvedKeyframe> extends WithPromise implements AnimationPlaybackControlsWithThen {
|
|
1159
1162
|
/**
|
|
1160
1163
|
* The interfaced Web Animation API animation
|
|
1161
1164
|
*/
|
|
@@ -1203,8 +1206,8 @@ declare class NativeAnimation<T extends string | number> extends WithPromise imp
|
|
|
1203
1206
|
attachTimeline({ timeline, observe }: TimelineWithFallback): VoidFunction;
|
|
1204
1207
|
}
|
|
1205
1208
|
|
|
1206
|
-
type NativeAnimationOptionsExtended<T extends
|
|
1207
|
-
declare class NativeAnimationExtended<T extends
|
|
1209
|
+
type NativeAnimationOptionsExtended<T extends AnyResolvedKeyframe> = NativeAnimationOptions & ValueAnimationOptions<T> & NativeAnimationOptions;
|
|
1210
|
+
declare class NativeAnimationExtended<T extends AnyResolvedKeyframe> extends NativeAnimation<T> {
|
|
1208
1211
|
options: NativeAnimationOptionsExtended<T>;
|
|
1209
1212
|
constructor(options: NativeAnimationOptionsExtended<T>);
|
|
1210
1213
|
/**
|
|
@@ -1218,7 +1221,7 @@ declare class NativeAnimationExtended<T extends string | number> extends NativeA
|
|
|
1218
1221
|
updateMotionValue(value?: T): void;
|
|
1219
1222
|
}
|
|
1220
1223
|
|
|
1221
|
-
declare class NativeAnimationWrapper<T extends
|
|
1224
|
+
declare class NativeAnimationWrapper<T extends AnyResolvedKeyframe> extends NativeAnimation<T> {
|
|
1222
1225
|
constructor(animation: Animation);
|
|
1223
1226
|
}
|
|
1224
1227
|
|
|
@@ -1227,18 +1230,18 @@ declare function getAnimationMap(element: Element): Map<any, any>;
|
|
|
1227
1230
|
|
|
1228
1231
|
type CSSVariableName = `--${string}`;
|
|
1229
1232
|
type CSSVariableToken = `var(${CSSVariableName})`;
|
|
1230
|
-
declare const isCSSVariableName: (key?:
|
|
1233
|
+
declare const isCSSVariableName: (key?: AnyResolvedKeyframe | null) => key is `--${string}`;
|
|
1231
1234
|
declare const isCSSVariableToken: (value?: string) => value is `var(--${string})`;
|
|
1232
1235
|
|
|
1233
1236
|
declare function parseCSSVariable(current: string): string[] | undefined[];
|
|
1234
|
-
declare function getVariableValue(current: CSSVariableToken, element: Element, depth?: number):
|
|
1237
|
+
declare function getVariableValue(current: CSSVariableToken, element: Element, depth?: number): AnyResolvedKeyframe | undefined;
|
|
1235
1238
|
|
|
1236
1239
|
declare function getValueTransition(transition: any, key: string): any;
|
|
1237
1240
|
|
|
1238
1241
|
declare function inertia({ keyframes, velocity, power, timeConstant, bounceDamping, bounceStiffness, modifyTarget, min, max, restDelta, restSpeed, }: ValueAnimationOptions<number>): KeyframeGenerator<number>;
|
|
1239
1242
|
|
|
1240
1243
|
declare function defaultEasing(values: any[], easing?: EasingFunction): EasingFunction[];
|
|
1241
|
-
declare function keyframes<T extends
|
|
1244
|
+
declare function keyframes<T extends AnyResolvedKeyframe>({ duration, keyframes: keyframeValues, times, ease, }: ValueAnimationOptions<T>): KeyframeGenerator<T>;
|
|
1242
1245
|
|
|
1243
1246
|
declare function spring(optionsOrVisualDuration?: ValueAnimationOptions<number> | number, bounce?: number): KeyframeGenerator<number>;
|
|
1244
1247
|
declare namespace spring {
|
|
@@ -1263,12 +1266,12 @@ declare function createGeneratorEasing(options: Transition, scale: number | unde
|
|
|
1263
1266
|
|
|
1264
1267
|
declare function isGenerator(type?: AnimationGeneratorType): type is GeneratorFactory;
|
|
1265
1268
|
|
|
1266
|
-
declare class DOMKeyframesResolver<T extends
|
|
1269
|
+
declare class DOMKeyframesResolver<T extends AnyResolvedKeyframe> extends KeyframeResolver<T> {
|
|
1267
1270
|
name: string;
|
|
1268
1271
|
element?: WithRender;
|
|
1269
1272
|
private removedTransforms?;
|
|
1270
1273
|
private measuredOrigin?;
|
|
1271
|
-
constructor(unresolvedKeyframes: UnresolvedKeyframes<
|
|
1274
|
+
constructor(unresolvedKeyframes: UnresolvedKeyframes<AnyResolvedKeyframe>, onComplete: OnKeyframesResolved<T>, name?: string, motionValue?: MotionValue<T>, element?: WithRender);
|
|
1272
1275
|
readKeyframes(): void;
|
|
1273
1276
|
resolveNoneKeyframes(): void;
|
|
1274
1277
|
measureInitialState(): void;
|
|
@@ -1307,7 +1310,7 @@ declare function startWaapiAnimation(element: Element, valueName: string, keyfra
|
|
|
1307
1310
|
|
|
1308
1311
|
declare const supportsPartialKeyframes: () => boolean;
|
|
1309
1312
|
|
|
1310
|
-
declare function supportsBrowserAnimation<T extends
|
|
1313
|
+
declare function supportsBrowserAnimation<T extends AnyResolvedKeyframe>(options: ValueAnimationOptionsWithRenderContext<T>): any;
|
|
1311
1314
|
|
|
1312
1315
|
/**
|
|
1313
1316
|
* A list of values that can be hardware-accelerated.
|
|
@@ -1318,7 +1321,7 @@ declare const generateLinearEasing: (easing: EasingFunction, duration: number, r
|
|
|
1318
1321
|
|
|
1319
1322
|
declare class MotionValueState {
|
|
1320
1323
|
latest: {
|
|
1321
|
-
[name: string]:
|
|
1324
|
+
[name: string]: AnyResolvedKeyframe;
|
|
1322
1325
|
};
|
|
1323
1326
|
private values;
|
|
1324
1327
|
set(name: string, value: MotionValue, render?: VoidFunction, computed?: MotionValue, useDefaultValueType?: boolean): () => void;
|
|
@@ -1588,7 +1591,7 @@ interface EventInfo {
|
|
|
1588
1591
|
* A generic set of string/number values
|
|
1589
1592
|
*/
|
|
1590
1593
|
interface ResolvedValues {
|
|
1591
|
-
[key: string]:
|
|
1594
|
+
[key: string]: AnyResolvedKeyframe;
|
|
1592
1595
|
}
|
|
1593
1596
|
type AnimationDefinition = VariantLabels | TargetAndTransition | TargetResolver;
|
|
1594
1597
|
/**
|
|
@@ -1759,7 +1762,7 @@ interface MotionNodeAnimationOptions {
|
|
|
1759
1762
|
* Variants allow you to define animation states and organise them by name. They allow
|
|
1760
1763
|
* you to control animations throughout a component tree by switching a single `animate` prop.
|
|
1761
1764
|
*
|
|
1762
|
-
* Using `transition` options like `delayChildren` and `
|
|
1765
|
+
* Using `transition` options like `delayChildren` and `when`, you can orchestrate
|
|
1763
1766
|
* when children animations play relative to their parent.
|
|
1764
1767
|
|
|
1765
1768
|
*
|
|
@@ -2520,7 +2523,7 @@ declare const readTransformValue: (instance: HTMLElement, name: string) => numbe
|
|
|
2520
2523
|
|
|
2521
2524
|
declare function getComputedStyle(element: HTMLElement | SVGElement, name: string): string;
|
|
2522
2525
|
|
|
2523
|
-
declare function setStyle(element: HTMLElement | SVGElement, name: string, value:
|
|
2526
|
+
declare function setStyle(element: HTMLElement | SVGElement, name: string, value: AnyResolvedKeyframe): void;
|
|
2524
2527
|
|
|
2525
2528
|
declare const positionalKeys: Set<string>;
|
|
2526
2529
|
|
|
@@ -2678,15 +2681,15 @@ declare const mixLinearColor: (from: number, to: number, v: number) => number;
|
|
|
2678
2681
|
declare const mixColor: (from: Color | string, to: Color | string) => (p: number) => string | Color;
|
|
2679
2682
|
|
|
2680
2683
|
type MixableArray = Array<number | RGBA | HSLA | string>;
|
|
2681
|
-
|
|
2682
|
-
[key: string]:
|
|
2683
|
-
}
|
|
2684
|
-
declare function getMixer<T>(a: T): ((from: string | Color, to: string | Color) => (p: number) => string | Color) | ((origin:
|
|
2684
|
+
interface MixableObject {
|
|
2685
|
+
[key: string]: AnyResolvedKeyframe | RGBA | HSLA;
|
|
2686
|
+
}
|
|
2687
|
+
declare function getMixer<T>(a: T): ((from: string | Color, to: string | Color) => (p: number) => string | Color) | ((origin: AnyResolvedKeyframe, target: AnyResolvedKeyframe) => Function) | typeof mixArray | typeof mixObject;
|
|
2685
2688
|
declare function mixArray(a: MixableArray, b: MixableArray): (p: number) => (string | number | RGBA | HSLA)[];
|
|
2686
2689
|
declare function mixObject(a: MixableObject, b: MixableObject): (v: number) => {
|
|
2687
|
-
[x: string]:
|
|
2690
|
+
[x: string]: AnyResolvedKeyframe | RGBA | HSLA;
|
|
2688
2691
|
};
|
|
2689
|
-
declare const mixComplex: (origin:
|
|
2692
|
+
declare const mixComplex: (origin: AnyResolvedKeyframe, target: AnyResolvedKeyframe) => Function;
|
|
2690
2693
|
|
|
2691
2694
|
declare function mixImmediate<T>(a: T, b: T): (p: number) => T;
|
|
2692
2695
|
|
|
@@ -2700,6 +2703,15 @@ declare const invisibleValues: Set<string>;
|
|
|
2700
2703
|
*/
|
|
2701
2704
|
declare function mixVisibility(origin: string, target: string): (p: number) => string;
|
|
2702
2705
|
|
|
2706
|
+
type StaggerOrigin = "first" | "last" | "center" | number;
|
|
2707
|
+
type StaggerOptions = {
|
|
2708
|
+
startDelay?: number;
|
|
2709
|
+
from?: StaggerOrigin;
|
|
2710
|
+
ease?: Easing;
|
|
2711
|
+
};
|
|
2712
|
+
declare function getOriginIndex(from: StaggerOrigin, total: number): number;
|
|
2713
|
+
declare function stagger(duration?: number, { startDelay, from, ease }?: StaggerOptions): DynamicOption<number>;
|
|
2714
|
+
|
|
2703
2715
|
/**
|
|
2704
2716
|
* Add the ability for test suites to manually set support flags
|
|
2705
2717
|
* to better test more environments.
|
|
@@ -2863,8 +2875,8 @@ declare function mapValue<O>(inputValue: MotionValue<number>, inputRange: MapInp
|
|
|
2863
2875
|
*
|
|
2864
2876
|
* @public
|
|
2865
2877
|
*/
|
|
2866
|
-
declare function springValue<T extends
|
|
2867
|
-
declare function attachSpring<T extends
|
|
2878
|
+
declare function springValue<T extends AnyResolvedKeyframe>(source: T | MotionValue<T>, options?: SpringOptions): MotionValue<T>;
|
|
2879
|
+
declare function attachSpring<T extends AnyResolvedKeyframe>(value: MotionValue<T>, source: T | MotionValue<T>, options?: SpringOptions): VoidFunction | undefined;
|
|
2868
2880
|
|
|
2869
2881
|
type TransformInputRange = number[];
|
|
2870
2882
|
type SingleTransformer<I, O> = (input: I) => O;
|
|
@@ -2923,22 +2935,22 @@ declare const rgba: {
|
|
|
2923
2935
|
};
|
|
2924
2936
|
|
|
2925
2937
|
declare function test(v: any): boolean;
|
|
2926
|
-
type ComplexValues = Array<CSSVariableToken |
|
|
2927
|
-
|
|
2938
|
+
type ComplexValues = Array<CSSVariableToken | AnyResolvedKeyframe | Color>;
|
|
2939
|
+
interface ValueIndexes {
|
|
2928
2940
|
color: number[];
|
|
2929
2941
|
number: number[];
|
|
2930
2942
|
var: number[];
|
|
2931
|
-
}
|
|
2943
|
+
}
|
|
2932
2944
|
interface ComplexValueInfo {
|
|
2933
2945
|
values: ComplexValues;
|
|
2934
2946
|
split: string[];
|
|
2935
2947
|
indexes: ValueIndexes;
|
|
2936
2948
|
types: Array<keyof ValueIndexes>;
|
|
2937
2949
|
}
|
|
2938
|
-
declare function analyseComplexValue(value:
|
|
2939
|
-
declare function parseComplexValue(v:
|
|
2940
|
-
declare function createTransformer(source:
|
|
2941
|
-
declare function getAnimatableNone$1(v:
|
|
2950
|
+
declare function analyseComplexValue(value: AnyResolvedKeyframe): ComplexValueInfo;
|
|
2951
|
+
declare function parseComplexValue(v: AnyResolvedKeyframe): ComplexValues;
|
|
2952
|
+
declare function createTransformer(source: AnyResolvedKeyframe): (v: Array<CSSVariableToken | Color | number | string>) => string;
|
|
2953
|
+
declare function getAnimatableNone$1(v: AnyResolvedKeyframe): string;
|
|
2942
2954
|
declare const complex: {
|
|
2943
2955
|
test: typeof test;
|
|
2944
2956
|
parse: typeof parseComplexValue;
|
|
@@ -2949,27 +2961,27 @@ declare const complex: {
|
|
|
2949
2961
|
/**
|
|
2950
2962
|
* A list of value types commonly used for dimensions
|
|
2951
2963
|
*/
|
|
2952
|
-
declare const dimensionValueTypes: (
|
|
2964
|
+
declare const dimensionValueTypes: ({
|
|
2953
2965
|
test: (v: number) => boolean;
|
|
2954
2966
|
parse: typeof parseFloat;
|
|
2955
2967
|
transform: (v: number) => number;
|
|
2956
2968
|
} | {
|
|
2957
|
-
test: (v:
|
|
2969
|
+
test: (v: AnyResolvedKeyframe) => boolean;
|
|
2958
2970
|
parse: typeof parseFloat;
|
|
2959
2971
|
transform: (v: string | number) => string;
|
|
2960
|
-
})[];
|
|
2972
|
+
} | ValueType)[];
|
|
2961
2973
|
/**
|
|
2962
2974
|
* Tests a dimensional value against the list of dimension ValueTypes
|
|
2963
2975
|
*/
|
|
2964
|
-
declare const findDimensionValueType: (v: any) =>
|
|
2976
|
+
declare const findDimensionValueType: (v: any) => {
|
|
2965
2977
|
test: (v: number) => boolean;
|
|
2966
2978
|
parse: typeof parseFloat;
|
|
2967
2979
|
transform: (v: number) => number;
|
|
2968
2980
|
} | {
|
|
2969
|
-
test: (v:
|
|
2981
|
+
test: (v: AnyResolvedKeyframe) => boolean;
|
|
2970
2982
|
parse: typeof parseFloat;
|
|
2971
2983
|
transform: (v: string | number) => string;
|
|
2972
|
-
} | undefined;
|
|
2984
|
+
} | ValueType | undefined;
|
|
2973
2985
|
|
|
2974
2986
|
interface ValueTypeMap {
|
|
2975
2987
|
[key: string]: ValueType;
|
|
@@ -3006,34 +3018,34 @@ declare const scale: {
|
|
|
3006
3018
|
};
|
|
3007
3019
|
|
|
3008
3020
|
declare const degrees: {
|
|
3009
|
-
test: (v:
|
|
3021
|
+
test: (v: AnyResolvedKeyframe) => boolean;
|
|
3010
3022
|
parse: typeof parseFloat;
|
|
3011
3023
|
transform: (v: number | string) => string;
|
|
3012
3024
|
};
|
|
3013
3025
|
declare const percent: {
|
|
3014
|
-
test: (v:
|
|
3026
|
+
test: (v: AnyResolvedKeyframe) => boolean;
|
|
3015
3027
|
parse: typeof parseFloat;
|
|
3016
3028
|
transform: (v: number | string) => string;
|
|
3017
3029
|
};
|
|
3018
3030
|
declare const px: {
|
|
3019
|
-
test: (v:
|
|
3031
|
+
test: (v: AnyResolvedKeyframe) => boolean;
|
|
3020
3032
|
parse: typeof parseFloat;
|
|
3021
3033
|
transform: (v: number | string) => string;
|
|
3022
3034
|
};
|
|
3023
3035
|
declare const vh: {
|
|
3024
|
-
test: (v:
|
|
3036
|
+
test: (v: AnyResolvedKeyframe) => boolean;
|
|
3025
3037
|
parse: typeof parseFloat;
|
|
3026
3038
|
transform: (v: number | string) => string;
|
|
3027
3039
|
};
|
|
3028
3040
|
declare const vw: {
|
|
3029
|
-
test: (v:
|
|
3041
|
+
test: (v: AnyResolvedKeyframe) => boolean;
|
|
3030
3042
|
parse: typeof parseFloat;
|
|
3031
3043
|
transform: (v: number | string) => string;
|
|
3032
3044
|
};
|
|
3033
3045
|
declare const progressPercentage: {
|
|
3034
3046
|
parse: (v: string) => number;
|
|
3035
3047
|
transform: (v: number) => string;
|
|
3036
|
-
test: (v:
|
|
3048
|
+
test: (v: AnyResolvedKeyframe) => boolean;
|
|
3037
3049
|
};
|
|
3038
3050
|
|
|
3039
3051
|
/**
|
|
@@ -3046,24 +3058,24 @@ declare function getAnimatableNone(key: string, value: string): any;
|
|
|
3046
3058
|
/**
|
|
3047
3059
|
* Tests a value against the list of ValueTypes
|
|
3048
3060
|
*/
|
|
3049
|
-
declare const findValueType: (v: any) =>
|
|
3061
|
+
declare const findValueType: (v: any) => {
|
|
3050
3062
|
test: (v: number) => boolean;
|
|
3051
3063
|
parse: typeof parseFloat;
|
|
3052
3064
|
transform: (v: number) => number;
|
|
3053
3065
|
} | {
|
|
3054
|
-
test: (v:
|
|
3066
|
+
test: (v: AnyResolvedKeyframe) => boolean;
|
|
3055
3067
|
parse: typeof parseFloat;
|
|
3056
3068
|
transform: (v: string | number) => string;
|
|
3057
|
-
} | {
|
|
3069
|
+
} | ValueType | {
|
|
3058
3070
|
test: (v: any) => boolean;
|
|
3059
3071
|
parse: (v: any) => RGBA | HSLA;
|
|
3060
3072
|
transform: (v: string | RGBA | HSLA) => string;
|
|
3061
3073
|
getAnimatableNone: (v: string) => string;
|
|
3062
3074
|
} | {
|
|
3063
3075
|
test: (v: any) => boolean;
|
|
3064
|
-
parse: (v:
|
|
3065
|
-
createTransformer: (source:
|
|
3066
|
-
getAnimatableNone: (v:
|
|
3076
|
+
parse: (v: AnyResolvedKeyframe) => ComplexValues;
|
|
3077
|
+
createTransformer: (source: AnyResolvedKeyframe) => (v: (string | number | Color)[]) => string;
|
|
3078
|
+
getAnimatableNone: (v: AnyResolvedKeyframe) => string;
|
|
3067
3079
|
} | undefined;
|
|
3068
3080
|
|
|
3069
3081
|
/**
|
|
@@ -3122,4 +3134,4 @@ declare const sync: Batcher;
|
|
|
3122
3134
|
*/
|
|
3123
3135
|
declare const cancelSync: Record<string, (process: Process) => void>;
|
|
3124
3136
|
|
|
3125
|
-
export { type AcceptedAnimations, type ActiveStatsBuffer, type AnimationDefinition, type AnimationGeneratorName, type AnimationGeneratorType, type AnimationOptions, type AnimationOrchestrationOptions, type AnimationPlaybackControls, type AnimationPlaybackControlsWithThen, type AnimationPlaybackLifecycles, type AnimationPlaybackOptions, type AnimationScope, type AnimationState, AsyncMotionValueAnimation, type Batcher, type CSSStyleDeclarationWithTransform, type CSSVariableName, type CSSVariableToken, type CancelProcess, type Color, type ComplexValueInfo, type ComplexValues, type DOMKeyframesDefinition, DOMKeyframesResolver, type DOMValueAnimationOptions, type DecayOptions, type DragElastic, type DragHandler, type DraggableProps, type DurationSpringOptions, type DynamicOption, type ElementOrSelector, type EventInfo, type EventOptions, type FrameData, type FrameStats, type GeneratorFactory, type GeneratorFactoryFunction, GroupAnimation, GroupAnimationWithThen, type GroupedAnimations, type HSLA, type InactiveStatsBuffer, type InertiaOptions, type InterpolateOptions, JSAnimation, type KeyframeGenerator, type KeyframeOptions, KeyframeResolver, type LegacyAnimationControls, type MapInputRange, type Mixer, type MixerFactory, type MotionNodeAdvancedOptions, type MotionNodeAnimationOptions, type MotionNodeDragHandlers, type MotionNodeDraggableOptions, type MotionNodeEventOptions, type MotionNodeFocusHandlers, type MotionNodeHoverHandlers, type MotionNodeLayoutOptions, type MotionNodeOptions, type MotionNodePanHandlers, type MotionNodeTapHandlers, type MotionNodeViewportOptions, MotionValue, type MotionValueEventCallbacks, type MotionValueOptions, type MultiTransformer, NativeAnimation, NativeAnimationExtended, type NativeAnimationOptions, type NativeAnimationOptionsExtended, NativeAnimationWrapper, type NumberMap, type OnHoverEndEvent, type OnHoverStartEvent, type OnKeyframesResolved, type OnPressEndEvent, type OnPressStartEvent, type Owner, type PanHandler, type PanInfo, type PassiveEffect, type PointerEventOptions, type PressGestureInfo, type Process, type ProgressTimeline, type RGBA, type RepeatType, type ResolvedConstraints, type ResolvedElastic, type ResolvedKeyframes, type ResolvedValueKeyframe, type ResolvedValues, type SVGAttributes, type SVGForcedAttrKeyframesDefinition, type SVGForcedAttrProperties, type SVGForcedAttrTransitions, type SVGKeyframesDefinition, type SVGPathKeyframesDefinition, type SVGPathProperties, type SVGPathTransitions, type SVGTransitions, type Schedule, type SelectorCache, type SingleTransformer, type Spring, type SpringOptions, type StartAnimation, type Stats, type StatsBuffer, type StatsRecording, type StatsSummary, type Step, type StepId, type Steps, type StyleKeyframesDefinition, type StyleTransitions, type Subscriber, type Summary, type TapHandlers, type TapInfo, type Target, type TargetAndTransition, type TargetResolver, type TimelineWithFallback, type TransformInputRange, type TransformOptions, type TransformProperties, type TransformTemplate, type Transformer, type Transition, type TransitionWithValueOverrides, type Tween, type UnresolvedKeyframes, type UnresolvedValueKeyframe, type ValueAnimationOptions, type ValueAnimationOptionsWithRenderContext, type ValueAnimationTransition, type ValueAnimationWithDynamicDelay, type ValueIndexes, type ValueKeyframe, type ValueKeyframesDefinition, type ValueTransformer, type ValueTransition, type ValueType, type ValueTypeMap, type VariableKeyframesDefinition, type VariableTransitions, type Variant, type VariantLabels, type Variants, type VelocityOptions, type ViewTransitionAnimationDefinition, ViewTransitionBuilder, type ViewTransitionOptions, type ViewTransitionTarget, type ViewTransitionTargetDefinition, type ViewportEventHandler, type ViewportOptions, type WithQuerySelectorAll, acceleratedValues, activeAnimations, addAttrValue, addStyleValue, alpha, analyseComplexValue, animateValue, animateView, animationMapKey, applyPxDefaults, attachSpring, attrEffect, calcGeneratorDuration, cancelFrame, cancelMicrotask, cancelSync, collectMotionValues, color, complex, convertOffsetToTimes, createGeneratorEasing, createRenderBatcher, cubicBezierAsString, defaultEasing, defaultOffset, defaultTransformValue, defaultValueTypes, degrees, dimensionValueTypes, fillOffset, fillWildcards, findDimensionValueType, findValueType, flushKeyframeResolvers, frame, frameData, frameSteps, generateLinearEasing, getAnimatableNone, getAnimationMap, getComputedStyle, getDefaultValueType, getMixer, getValueAsType, getValueTransition, getVariableValue, hex, hover, hsla, hslaToRgba, inertia, interpolate, invisibleValues, isCSSVariableName, isCSSVariableToken, isDragActive, isDragging, isGenerator, isHTMLElement, isMotionValue, isNodeOrChild, isPrimaryPointer, isSVGElement, isSVGSVGElement, isWaapiSupportedEasing, keyframes, mapEasingToNativeEasing, mapValue, maxGeneratorDuration, microtask, mix, mixArray, mixColor, mixComplex, mixImmediate, mixLinearColor, mixNumber, mixObject, mixVisibility, motionValue, number, numberValueTypes, observeTimeline, parseCSSVariable, parseValueFromTransform, percent, positionalKeys, press, progressPercentage, propEffect, px, readTransformValue, recordStats, resize, resolveElements, rgbUnit, rgba, scale, setDragLock, setStyle, spring, springValue, startWaapiAnimation, statsBuffer, styleEffect, supportedWaapiEasing, supportsBrowserAnimation, supportsFlags, supportsLinearEasing, supportsPartialKeyframes, supportsScrollTimeline, svgEffect, sync, testValueType, time, transform, transformPropOrder, transformProps, transformValue, transformValueTypes, vh, vw };
|
|
3137
|
+
export { type AcceptedAnimations, type ActiveStatsBuffer, type AnimationDefinition, type AnimationGeneratorName, type AnimationGeneratorType, type AnimationOptions, type AnimationOrchestrationOptions, type AnimationPlaybackControls, type AnimationPlaybackControlsWithThen, type AnimationPlaybackLifecycles, type AnimationPlaybackOptions, type AnimationScope, type AnimationState, type AnyResolvedKeyframe, AsyncMotionValueAnimation, type Batcher, type CSSStyleDeclarationWithTransform, type CSSVariableName, type CSSVariableToken, type CancelProcess, type Color, type ComplexValueInfo, type ComplexValues, type DOMKeyframesDefinition, DOMKeyframesResolver, type DOMValueAnimationOptions, type DecayOptions, type DragElastic, type DragHandler, type DraggableProps, type DurationSpringOptions, type DynamicOption, type ElementOrSelector, type EventInfo, type EventOptions, type FrameData, type FrameStats, type GeneratorFactory, type GeneratorFactoryFunction, GroupAnimation, GroupAnimationWithThen, type GroupedAnimations, type HSLA, type InactiveStatsBuffer, type InertiaOptions, type InterpolateOptions, JSAnimation, type KeyframeGenerator, type KeyframeOptions, KeyframeResolver, type LegacyAnimationControls, type MapInputRange, type Mixer, type MixerFactory, type MotionNodeAdvancedOptions, type MotionNodeAnimationOptions, type MotionNodeDragHandlers, type MotionNodeDraggableOptions, type MotionNodeEventOptions, type MotionNodeFocusHandlers, type MotionNodeHoverHandlers, type MotionNodeLayoutOptions, type MotionNodeOptions, type MotionNodePanHandlers, type MotionNodeTapHandlers, type MotionNodeViewportOptions, MotionValue, type MotionValueEventCallbacks, type MotionValueOptions, type MultiTransformer, NativeAnimation, NativeAnimationExtended, type NativeAnimationOptions, type NativeAnimationOptionsExtended, NativeAnimationWrapper, type NumberMap, type OnHoverEndEvent, type OnHoverStartEvent, type OnKeyframesResolved, type OnPressEndEvent, type OnPressStartEvent, type Owner, type PanHandler, type PanInfo, type PassiveEffect, type PointerEventOptions, type PressGestureInfo, type Process, type ProgressTimeline, type RGBA, type RepeatType, type ResolvedConstraints, type ResolvedElastic, type ResolvedKeyframes, type ResolvedValueKeyframe, type ResolvedValues, type SVGAttributes, type SVGForcedAttrKeyframesDefinition, type SVGForcedAttrProperties, type SVGForcedAttrTransitions, type SVGKeyframesDefinition, type SVGPathKeyframesDefinition, type SVGPathProperties, type SVGPathTransitions, type SVGTransitions, type Schedule, type SelectorCache, type SingleTransformer, type Spring, type SpringOptions, type StaggerOptions, type StaggerOrigin, type StartAnimation, type Stats, type StatsBuffer, type StatsRecording, type StatsSummary, type Step, type StepId, type Steps, type StyleKeyframesDefinition, type StyleTransitions, type Subscriber, type Summary, type TapHandlers, type TapInfo, type Target, type TargetAndTransition, type TargetResolver, type TimelineWithFallback, type TransformInputRange, type TransformOptions, type TransformProperties, type TransformTemplate, type Transformer, type Transition, type TransitionWithValueOverrides, type Tween, type UnresolvedKeyframes, type UnresolvedValueKeyframe, type ValueAnimationOptions, type ValueAnimationOptionsWithRenderContext, type ValueAnimationTransition, type ValueAnimationWithDynamicDelay, type ValueIndexes, type ValueKeyframe, type ValueKeyframesDefinition, type ValueTransformer, type ValueTransition, type ValueType, type ValueTypeMap, type VariableKeyframesDefinition, type VariableTransitions, type Variant, type VariantLabels, type Variants, type VelocityOptions, type ViewTransitionAnimationDefinition, ViewTransitionBuilder, type ViewTransitionOptions, type ViewTransitionTarget, type ViewTransitionTargetDefinition, type ViewportEventHandler, type ViewportOptions, type WithQuerySelectorAll, acceleratedValues, activeAnimations, addAttrValue, addStyleValue, alpha, analyseComplexValue, animateValue, animateView, animationMapKey, applyPxDefaults, attachSpring, attrEffect, calcGeneratorDuration, cancelFrame, cancelMicrotask, cancelSync, collectMotionValues, color, complex, convertOffsetToTimes, createGeneratorEasing, createRenderBatcher, cubicBezierAsString, defaultEasing, defaultOffset, defaultTransformValue, defaultValueTypes, degrees, dimensionValueTypes, fillOffset, fillWildcards, findDimensionValueType, findValueType, flushKeyframeResolvers, frame, frameData, frameSteps, generateLinearEasing, getAnimatableNone, getAnimationMap, getComputedStyle, getDefaultValueType, getMixer, getOriginIndex, getValueAsType, getValueTransition, getVariableValue, hex, hover, hsla, hslaToRgba, inertia, interpolate, invisibleValues, isCSSVariableName, isCSSVariableToken, isDragActive, isDragging, isGenerator, isHTMLElement, isMotionValue, isNodeOrChild, isPrimaryPointer, isSVGElement, isSVGSVGElement, isWaapiSupportedEasing, keyframes, mapEasingToNativeEasing, mapValue, maxGeneratorDuration, microtask, mix, mixArray, mixColor, mixComplex, mixImmediate, mixLinearColor, mixNumber, mixObject, mixVisibility, motionValue, number, numberValueTypes, observeTimeline, parseCSSVariable, parseValueFromTransform, percent, positionalKeys, press, progressPercentage, propEffect, px, readTransformValue, recordStats, resize, resolveElements, rgbUnit, rgba, scale, setDragLock, setStyle, spring, springValue, stagger, startWaapiAnimation, statsBuffer, styleEffect, supportedWaapiEasing, supportsBrowserAnimation, supportsFlags, supportsLinearEasing, supportsPartialKeyframes, supportsScrollTimeline, svgEffect, sync, testValueType, time, transform, transformPropOrder, transformProps, transformValue, transformValueTypes, vh, vw };
|