@hanzogui/animation-helpers 3.0.6 → 4.3.1
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.cjs +12 -10
- package/dist/cjs/index.native.js +12 -10
- package/dist/cjs/index.native.js.map +1 -1
- package/dist/cjs/normalizeTransition.cjs +93 -42
- package/dist/cjs/normalizeTransition.native.js +123 -68
- package/dist/cjs/normalizeTransition.native.js.map +1 -1
- package/dist/cjs/types.cjs +7 -5
- package/dist/cjs/types.native.js +7 -5
- package/dist/cjs/types.native.js.map +1 -1
- package/dist/esm/normalizeTransition.mjs +81 -32
- package/dist/esm/normalizeTransition.mjs.map +1 -1
- package/dist/esm/normalizeTransition.native.js +111 -58
- package/dist/esm/normalizeTransition.native.js.map +1 -1
- package/package.json +1 -1
package/dist/cjs/index.cjs
CHANGED
|
@@ -3,20 +3,22 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
3
3
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
4
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
5
|
var __export = (target, all) => {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
6
|
+
for (var name in all) __defProp(target, name, {
|
|
7
|
+
get: all[name],
|
|
8
|
+
enumerable: true
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
var __copyProps = (to, from, except, desc) => {
|
|
12
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
13
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
13
14
|
get: () => from[key],
|
|
14
15
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
15
16
|
});
|
|
16
|
-
|
|
17
|
-
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
18
20
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
19
|
-
value:
|
|
21
|
+
value: true
|
|
20
22
|
}), mod);
|
|
21
23
|
var index_exports = {};
|
|
22
24
|
__export(index_exports, {
|
package/dist/cjs/index.native.js
CHANGED
|
@@ -5,20 +5,22 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
5
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
6
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
7
|
var __export = (target, all) => {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
8
|
+
for (var name in all) __defProp(target, name, {
|
|
9
|
+
get: all[name],
|
|
10
|
+
enumerable: true
|
|
11
|
+
});
|
|
12
|
+
};
|
|
13
|
+
var __copyProps = (to, from, except, desc) => {
|
|
14
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
15
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
15
16
|
get: () => from[key],
|
|
16
17
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
17
18
|
});
|
|
18
|
-
|
|
19
|
-
|
|
19
|
+
}
|
|
20
|
+
return to;
|
|
21
|
+
};
|
|
20
22
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
21
|
-
value:
|
|
23
|
+
value: true
|
|
22
24
|
}), mod);
|
|
23
25
|
var index_exports = {};
|
|
24
26
|
__export(index_exports, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["__toCommonJS","mod","__copyProps","__defProp","value","index_exports","__export","getAnimatedProperties","import_normalizeTransition","getAnimationConfigsForKeys","getAnimationForProperty","getEffectiveAnimation","hasAnimation","normalizeTransition","module","exports"],"sources":["../../src/index.ts"],"sourcesContent":[null],"mappings":"
|
|
1
|
+
{"version":3,"names":["__toCommonJS","mod","__copyProps","__defProp","value","index_exports","__export","getAnimatedProperties","import_normalizeTransition","getAnimationConfigsForKeys","getAnimationForProperty","getEffectiveAnimation","hasAnimation","normalizeTransition","module","exports"],"sources":["../../src/index.ts"],"sourcesContent":[null],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,YAAA,GAAAC,GAAA,IAAAC,WAAA,CAAAC,SAAA;EAAAC,KAAA;AAAA,IAAAH,GAAA;AAAA,IAAAI,aAAA;AAAAC,QAAA,CAAAD,aAAA;EAAAE,qBAAA,EAAAA,CAAA,KAAAC,0BAAA,CAAAD,qBAAA;EAAAE,0BAAA,EAAAA,CAAA,KAAAD,0BAAA,CAAAC,0BAAA;EAAAC,uBAAA,EAAAA,CAAA,KAAAF,0BAAA,CAAAE,uBAAA;EAAAC,qBAAA,EAAAA,CAAA,KAAAH,0BAAA,CAAAG,qBAAA;EAAAC,YAAA,EAAAA,CAAA,KAAAJ,0BAAA,CAAAI,YAAA;EAAAC,mBAAA,EAAAA,CAAA,KAAAL,0BAAA,CAAAK;AAAA;AAAAC,MAAA,CAAAC,OAAA,GAAAf,YAAA,CAAAK,aAOO","ignoreList":[]}
|
|
@@ -3,20 +3,22 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
3
3
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
4
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
5
|
var __export = (target, all) => {
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
6
|
+
for (var name in all) __defProp(target, name, {
|
|
7
|
+
get: all[name],
|
|
8
|
+
enumerable: true
|
|
9
|
+
});
|
|
10
|
+
};
|
|
11
|
+
var __copyProps = (to, from, except, desc) => {
|
|
12
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
13
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
13
14
|
get: () => from[key],
|
|
14
15
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
15
16
|
});
|
|
16
|
-
|
|
17
|
-
|
|
17
|
+
}
|
|
18
|
+
return to;
|
|
19
|
+
};
|
|
18
20
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
19
|
-
value:
|
|
21
|
+
value: true
|
|
20
22
|
}), mod);
|
|
21
23
|
var normalizeTransition_exports = {};
|
|
22
24
|
__export(normalizeTransition_exports, {
|
|
@@ -33,28 +35,46 @@ function isSpringConfigKey(key) {
|
|
|
33
35
|
return SPRING_CONFIG_KEYS.has(key);
|
|
34
36
|
}
|
|
35
37
|
function normalizeTransition(transition) {
|
|
36
|
-
if (!transition)
|
|
37
|
-
|
|
38
|
-
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
38
|
+
if (!transition) {
|
|
39
|
+
return {
|
|
40
|
+
default: null,
|
|
41
|
+
enter: null,
|
|
42
|
+
exit: null,
|
|
43
|
+
delay: void 0,
|
|
44
|
+
properties: {}
|
|
45
|
+
};
|
|
46
|
+
}
|
|
47
|
+
if (typeof transition === "string") {
|
|
48
|
+
return {
|
|
49
|
+
default: transition,
|
|
50
|
+
enter: null,
|
|
51
|
+
exit: null,
|
|
52
|
+
delay: void 0,
|
|
53
|
+
properties: {}
|
|
54
|
+
};
|
|
55
|
+
}
|
|
50
56
|
if (Array.isArray(transition)) {
|
|
51
|
-
const [defaultAnimation, configObj] = transition
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
let delay
|
|
55
|
-
|
|
56
|
-
|
|
57
|
-
if (configObj && typeof configObj
|
|
57
|
+
const [defaultAnimation, configObj] = transition;
|
|
58
|
+
const properties = {};
|
|
59
|
+
const springConfig = {};
|
|
60
|
+
let delay;
|
|
61
|
+
let enter = null;
|
|
62
|
+
let exit = null;
|
|
63
|
+
if (configObj && typeof configObj === "object") {
|
|
64
|
+
for (const [key, value] of Object.entries(configObj)) {
|
|
65
|
+
if (key === "delay" && typeof value === "number") {
|
|
66
|
+
delay = value;
|
|
67
|
+
} else if (key === "enter" && typeof value === "string") {
|
|
68
|
+
enter = value;
|
|
69
|
+
} else if (key === "exit" && typeof value === "string") {
|
|
70
|
+
exit = value;
|
|
71
|
+
} else if (isSpringConfigKey(key) && value !== void 0) {
|
|
72
|
+
springConfig[key] = value;
|
|
73
|
+
} else if (value !== void 0) {
|
|
74
|
+
properties[key] = value;
|
|
75
|
+
}
|
|
76
|
+
}
|
|
77
|
+
}
|
|
58
78
|
return {
|
|
59
79
|
default: defaultAnimation,
|
|
60
80
|
enter,
|
|
@@ -64,14 +84,28 @@ function normalizeTransition(transition) {
|
|
|
64
84
|
config: Object.keys(springConfig).length > 0 ? springConfig : void 0
|
|
65
85
|
};
|
|
66
86
|
}
|
|
67
|
-
if (typeof transition
|
|
68
|
-
const properties = {}
|
|
69
|
-
|
|
70
|
-
let defaultAnimation = null
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
for (const [key, value] of Object.entries(transition))
|
|
87
|
+
if (typeof transition === "object") {
|
|
88
|
+
const properties = {};
|
|
89
|
+
const springConfig = {};
|
|
90
|
+
let defaultAnimation = null;
|
|
91
|
+
let enter = null;
|
|
92
|
+
let exit = null;
|
|
93
|
+
let delay;
|
|
94
|
+
for (const [key, value] of Object.entries(transition)) {
|
|
95
|
+
if (key === "default" && typeof value === "string") {
|
|
96
|
+
defaultAnimation = value;
|
|
97
|
+
} else if (key === "enter" && typeof value === "string") {
|
|
98
|
+
enter = value;
|
|
99
|
+
} else if (key === "exit" && typeof value === "string") {
|
|
100
|
+
exit = value;
|
|
101
|
+
} else if (key === "delay" && typeof value === "number") {
|
|
102
|
+
delay = value;
|
|
103
|
+
} else if (isSpringConfigKey(key) && value !== void 0) {
|
|
104
|
+
springConfig[key] = value;
|
|
105
|
+
} else if (value !== void 0) {
|
|
106
|
+
properties[key] = value;
|
|
107
|
+
}
|
|
108
|
+
}
|
|
75
109
|
return {
|
|
76
110
|
default: defaultAnimation,
|
|
77
111
|
enter,
|
|
@@ -91,7 +125,10 @@ function normalizeTransition(transition) {
|
|
|
91
125
|
}
|
|
92
126
|
function getAnimationForProperty(normalized, property) {
|
|
93
127
|
const propertyAnimation = normalized.properties[property];
|
|
94
|
-
|
|
128
|
+
if (propertyAnimation !== void 0) {
|
|
129
|
+
return propertyAnimation;
|
|
130
|
+
}
|
|
131
|
+
return normalized.default;
|
|
95
132
|
}
|
|
96
133
|
function hasAnimation(normalized) {
|
|
97
134
|
return normalized.default !== null || normalized.enter !== null || normalized.exit !== null || Object.keys(normalized.properties).length > 0;
|
|
@@ -100,14 +137,28 @@ function getAnimatedProperties(normalized) {
|
|
|
100
137
|
return Object.keys(normalized.properties);
|
|
101
138
|
}
|
|
102
139
|
function getEffectiveAnimation(normalized, state) {
|
|
103
|
-
|
|
140
|
+
if (state === "enter" && normalized.enter) {
|
|
141
|
+
return normalized.enter;
|
|
142
|
+
}
|
|
143
|
+
if (state === "exit" && normalized.exit) {
|
|
144
|
+
return normalized.exit;
|
|
145
|
+
}
|
|
146
|
+
return normalized.default;
|
|
104
147
|
}
|
|
105
148
|
function getAnimationConfigsForKeys(normalized, animations, keys, defaultAnimation) {
|
|
106
149
|
const result = /* @__PURE__ */new Map();
|
|
107
150
|
for (const key of keys) {
|
|
108
151
|
const propAnimation = normalized.properties[key];
|
|
109
152
|
let animationValue = null;
|
|
110
|
-
typeof propAnimation
|
|
153
|
+
if (typeof propAnimation === "string") {
|
|
154
|
+
animationValue = animations[propAnimation] ?? null;
|
|
155
|
+
} else if (propAnimation && typeof propAnimation === "object" && propAnimation.type) {
|
|
156
|
+
animationValue = animations[propAnimation.type] ?? null;
|
|
157
|
+
}
|
|
158
|
+
if (animationValue === null) {
|
|
159
|
+
animationValue = defaultAnimation;
|
|
160
|
+
}
|
|
161
|
+
result.set(key, animationValue);
|
|
111
162
|
}
|
|
112
163
|
return result;
|
|
113
164
|
}
|
|
@@ -5,20 +5,22 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
5
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
6
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
7
|
var __export = (target, all) => {
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
8
|
+
for (var name in all) __defProp(target, name, {
|
|
9
|
+
get: all[name],
|
|
10
|
+
enumerable: true
|
|
11
|
+
});
|
|
12
|
+
};
|
|
13
|
+
var __copyProps = (to, from, except, desc) => {
|
|
14
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
15
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
15
16
|
get: () => from[key],
|
|
16
17
|
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
17
18
|
});
|
|
18
|
-
|
|
19
|
-
|
|
19
|
+
}
|
|
20
|
+
return to;
|
|
21
|
+
};
|
|
20
22
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
21
|
-
value:
|
|
23
|
+
value: true
|
|
22
24
|
}), mod);
|
|
23
25
|
var normalizeTransition_exports = {};
|
|
24
26
|
__export(normalizeTransition_exports, {
|
|
@@ -33,50 +35,69 @@ module.exports = __toCommonJS(normalizeTransition_exports);
|
|
|
33
35
|
function _type_of(obj) {
|
|
34
36
|
"@swc/helpers - typeof";
|
|
35
37
|
|
|
36
|
-
return obj && typeof Symbol
|
|
38
|
+
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
37
39
|
}
|
|
38
40
|
var SPRING_CONFIG_KEYS = /* @__PURE__ */new Set(["stiffness", "damping", "mass", "tension", "friction", "velocity", "overshootClamping", "duration", "bounciness", "speed"]);
|
|
39
41
|
function isSpringConfigKey(key) {
|
|
40
42
|
return SPRING_CONFIG_KEYS.has(key);
|
|
41
43
|
}
|
|
42
44
|
function normalizeTransition(transition) {
|
|
43
|
-
if (!transition)
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
|
|
45
|
+
if (!transition) {
|
|
46
|
+
return {
|
|
47
|
+
default: null,
|
|
48
|
+
enter: null,
|
|
49
|
+
exit: null,
|
|
50
|
+
delay: void 0,
|
|
51
|
+
properties: {}
|
|
52
|
+
};
|
|
53
|
+
}
|
|
54
|
+
if (typeof transition === "string") {
|
|
55
|
+
return {
|
|
56
|
+
default: transition,
|
|
57
|
+
enter: null,
|
|
58
|
+
exit: null,
|
|
59
|
+
delay: void 0,
|
|
60
|
+
properties: {}
|
|
61
|
+
};
|
|
62
|
+
}
|
|
57
63
|
if (Array.isArray(transition)) {
|
|
58
|
-
var [defaultAnimation, configObj] = transition
|
|
59
|
-
|
|
60
|
-
|
|
61
|
-
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
if (configObj && (typeof configObj
|
|
65
|
-
var _iteratorNormalCompletion =
|
|
66
|
-
_didIteratorError =
|
|
64
|
+
var [defaultAnimation, configObj] = transition;
|
|
65
|
+
var properties = {};
|
|
66
|
+
var springConfig = {};
|
|
67
|
+
var delay;
|
|
68
|
+
var enter = null;
|
|
69
|
+
var exit = null;
|
|
70
|
+
if (configObj && (typeof configObj === "undefined" ? "undefined" : _type_of(configObj)) === "object") {
|
|
71
|
+
var _iteratorNormalCompletion = true,
|
|
72
|
+
_didIteratorError = false,
|
|
67
73
|
_iteratorError = void 0;
|
|
68
74
|
try {
|
|
69
|
-
for (var _iterator = Object.entries(configObj)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion =
|
|
75
|
+
for (var _iterator = Object.entries(configObj)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
|
|
70
76
|
var [key, value] = _step.value;
|
|
71
|
-
key === "delay" && typeof value
|
|
77
|
+
if (key === "delay" && typeof value === "number") {
|
|
78
|
+
delay = value;
|
|
79
|
+
} else if (key === "enter" && typeof value === "string") {
|
|
80
|
+
enter = value;
|
|
81
|
+
} else if (key === "exit" && typeof value === "string") {
|
|
82
|
+
exit = value;
|
|
83
|
+
} else if (isSpringConfigKey(key) && value !== void 0) {
|
|
84
|
+
springConfig[key] = value;
|
|
85
|
+
} else if (value !== void 0) {
|
|
86
|
+
properties[key] = value;
|
|
87
|
+
}
|
|
72
88
|
}
|
|
73
89
|
} catch (err) {
|
|
74
|
-
_didIteratorError =
|
|
90
|
+
_didIteratorError = true;
|
|
91
|
+
_iteratorError = err;
|
|
75
92
|
} finally {
|
|
76
93
|
try {
|
|
77
|
-
!_iteratorNormalCompletion && _iterator.return != null
|
|
94
|
+
if (!_iteratorNormalCompletion && _iterator.return != null) {
|
|
95
|
+
_iterator.return();
|
|
96
|
+
}
|
|
78
97
|
} finally {
|
|
79
|
-
if (_didIteratorError)
|
|
98
|
+
if (_didIteratorError) {
|
|
99
|
+
throw _iteratorError;
|
|
100
|
+
}
|
|
80
101
|
}
|
|
81
102
|
}
|
|
82
103
|
}
|
|
@@ -89,28 +110,45 @@ function normalizeTransition(transition) {
|
|
|
89
110
|
config: Object.keys(springConfig).length > 0 ? springConfig : void 0
|
|
90
111
|
};
|
|
91
112
|
}
|
|
92
|
-
if ((typeof transition
|
|
93
|
-
var properties1 = {}
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
97
|
-
|
|
98
|
-
|
|
99
|
-
|
|
100
|
-
_didIteratorError1 =
|
|
113
|
+
if ((typeof transition === "undefined" ? "undefined" : _type_of(transition)) === "object") {
|
|
114
|
+
var properties1 = {};
|
|
115
|
+
var springConfig1 = {};
|
|
116
|
+
var defaultAnimation1 = null;
|
|
117
|
+
var enter1 = null;
|
|
118
|
+
var exit1 = null;
|
|
119
|
+
var delay1;
|
|
120
|
+
var _iteratorNormalCompletion1 = true,
|
|
121
|
+
_didIteratorError1 = false,
|
|
101
122
|
_iteratorError1 = void 0;
|
|
102
123
|
try {
|
|
103
|
-
for (var _iterator1 = Object.entries(transition)[Symbol.iterator](), _step1; !(_iteratorNormalCompletion1 = (_step1 = _iterator1.next()).done); _iteratorNormalCompletion1 =
|
|
124
|
+
for (var _iterator1 = Object.entries(transition)[Symbol.iterator](), _step1; !(_iteratorNormalCompletion1 = (_step1 = _iterator1.next()).done); _iteratorNormalCompletion1 = true) {
|
|
104
125
|
var [key1, value1] = _step1.value;
|
|
105
|
-
key1 === "default" && typeof value1
|
|
126
|
+
if (key1 === "default" && typeof value1 === "string") {
|
|
127
|
+
defaultAnimation1 = value1;
|
|
128
|
+
} else if (key1 === "enter" && typeof value1 === "string") {
|
|
129
|
+
enter1 = value1;
|
|
130
|
+
} else if (key1 === "exit" && typeof value1 === "string") {
|
|
131
|
+
exit1 = value1;
|
|
132
|
+
} else if (key1 === "delay" && typeof value1 === "number") {
|
|
133
|
+
delay1 = value1;
|
|
134
|
+
} else if (isSpringConfigKey(key1) && value1 !== void 0) {
|
|
135
|
+
springConfig1[key1] = value1;
|
|
136
|
+
} else if (value1 !== void 0) {
|
|
137
|
+
properties1[key1] = value1;
|
|
138
|
+
}
|
|
106
139
|
}
|
|
107
140
|
} catch (err) {
|
|
108
|
-
_didIteratorError1 =
|
|
141
|
+
_didIteratorError1 = true;
|
|
142
|
+
_iteratorError1 = err;
|
|
109
143
|
} finally {
|
|
110
144
|
try {
|
|
111
|
-
!_iteratorNormalCompletion1 && _iterator1.return != null
|
|
145
|
+
if (!_iteratorNormalCompletion1 && _iterator1.return != null) {
|
|
146
|
+
_iterator1.return();
|
|
147
|
+
}
|
|
112
148
|
} finally {
|
|
113
|
-
if (_didIteratorError1)
|
|
149
|
+
if (_didIteratorError1) {
|
|
150
|
+
throw _iteratorError1;
|
|
151
|
+
}
|
|
114
152
|
}
|
|
115
153
|
}
|
|
116
154
|
return {
|
|
@@ -132,7 +170,10 @@ function normalizeTransition(transition) {
|
|
|
132
170
|
}
|
|
133
171
|
function getAnimationForProperty(normalized, property) {
|
|
134
172
|
var propertyAnimation = normalized.properties[property];
|
|
135
|
-
|
|
173
|
+
if (propertyAnimation !== void 0) {
|
|
174
|
+
return propertyAnimation;
|
|
175
|
+
}
|
|
176
|
+
return normalized.default;
|
|
136
177
|
}
|
|
137
178
|
function hasAnimation(normalized) {
|
|
138
179
|
return normalized.default !== null || normalized.enter !== null || normalized.exit !== null || Object.keys(normalized.properties).length > 0;
|
|
@@ -141,34 +182,48 @@ function getAnimatedProperties(normalized) {
|
|
|
141
182
|
return Object.keys(normalized.properties);
|
|
142
183
|
}
|
|
143
184
|
function getEffectiveAnimation(normalized, state) {
|
|
144
|
-
|
|
185
|
+
if (state === "enter" && normalized.enter) {
|
|
186
|
+
return normalized.enter;
|
|
187
|
+
}
|
|
188
|
+
if (state === "exit" && normalized.exit) {
|
|
189
|
+
return normalized.exit;
|
|
190
|
+
}
|
|
191
|
+
return normalized.default;
|
|
145
192
|
}
|
|
146
193
|
function getAnimationConfigsForKeys(normalized, animations, keys, defaultAnimation) {
|
|
147
|
-
var result = /* @__PURE__ */new Map()
|
|
148
|
-
|
|
149
|
-
_didIteratorError =
|
|
194
|
+
var result = /* @__PURE__ */new Map();
|
|
195
|
+
var _iteratorNormalCompletion = true,
|
|
196
|
+
_didIteratorError = false,
|
|
150
197
|
_iteratorError = void 0;
|
|
151
198
|
try {
|
|
152
|
-
for (var _iterator = keys[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion =
|
|
153
|
-
var key = _step.value
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
if (typeof propAnimation
|
|
199
|
+
for (var _iterator = keys[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
|
|
200
|
+
var key = _step.value;
|
|
201
|
+
var propAnimation = normalized.properties[key];
|
|
202
|
+
var animationValue = null;
|
|
203
|
+
if (typeof propAnimation === "string") {
|
|
157
204
|
var _animations_propAnimation;
|
|
158
205
|
animationValue = (_animations_propAnimation = animations[propAnimation]) !== null && _animations_propAnimation !== void 0 ? _animations_propAnimation : null;
|
|
159
|
-
} else if (propAnimation && (typeof propAnimation
|
|
206
|
+
} else if (propAnimation && (typeof propAnimation === "undefined" ? "undefined" : _type_of(propAnimation)) === "object" && propAnimation.type) {
|
|
160
207
|
var _animations_propAnimation_type;
|
|
161
208
|
animationValue = (_animations_propAnimation_type = animations[propAnimation.type]) !== null && _animations_propAnimation_type !== void 0 ? _animations_propAnimation_type : null;
|
|
162
209
|
}
|
|
163
|
-
animationValue === null
|
|
210
|
+
if (animationValue === null) {
|
|
211
|
+
animationValue = defaultAnimation;
|
|
212
|
+
}
|
|
213
|
+
result.set(key, animationValue);
|
|
164
214
|
}
|
|
165
215
|
} catch (err) {
|
|
166
|
-
_didIteratorError =
|
|
216
|
+
_didIteratorError = true;
|
|
217
|
+
_iteratorError = err;
|
|
167
218
|
} finally {
|
|
168
219
|
try {
|
|
169
|
-
!_iteratorNormalCompletion && _iterator.return != null
|
|
220
|
+
if (!_iteratorNormalCompletion && _iterator.return != null) {
|
|
221
|
+
_iterator.return();
|
|
222
|
+
}
|
|
170
223
|
} finally {
|
|
171
|
-
if (_didIteratorError)
|
|
224
|
+
if (_didIteratorError) {
|
|
225
|
+
throw _iteratorError;
|
|
226
|
+
}
|
|
172
227
|
}
|
|
173
228
|
}
|
|
174
229
|
return result;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["__toCommonJS","mod","__copyProps","__defProp","value","normalizeTransition_exports","__export","getAnimatedProperties","getAnimationConfigsForKeys","getAnimationForProperty","getEffectiveAnimation","hasAnimation","normalizeTransition","module","exports","_type_of","obj","Symbol","constructor","SPRING_CONFIG_KEYS","Set","isSpringConfigKey","key","has","transition","default","enter","exit","delay","properties","Array","isArray","defaultAnimation","configObj","springConfig","_iteratorNormalCompletion","_didIteratorError","_iteratorError","_iterator","Object","entries","iterator","_step","next","done","err","return","config","keys","length","properties1","springConfig1","defaultAnimation1","enter1","exit1","delay1","_iteratorNormalCompletion1","_didIteratorError1","_iteratorError1","_iterator1","_step1","key1","value1"],"sources":["../../src/normalizeTransition.ts"],"sourcesContent":[null],"mappings":"
|
|
1
|
+
{"version":3,"names":["__toCommonJS","mod","__copyProps","__defProp","value","normalizeTransition_exports","__export","getAnimatedProperties","getAnimationConfigsForKeys","getAnimationForProperty","getEffectiveAnimation","hasAnimation","normalizeTransition","module","exports","_type_of","obj","Symbol","constructor","SPRING_CONFIG_KEYS","Set","isSpringConfigKey","key","has","transition","default","enter","exit","delay","properties","Array","isArray","defaultAnimation","configObj","springConfig","_iteratorNormalCompletion","_didIteratorError","_iteratorError","_iterator","Object","entries","iterator","_step","next","done","err","return","config","keys","length","properties1","springConfig1","defaultAnimation1","enter1","exit1","delay1","_iteratorNormalCompletion1","_didIteratorError1","_iteratorError1","_iterator1","_step1","key1","value1"],"sources":["../../src/normalizeTransition.ts"],"sourcesContent":[null],"mappings":";;;;;;;;;;;;;;;;;;;;;AAAA,IAAAA,YAAA,GAAAC,GAAA,IAAAC,WAAA,CAAAC,SAAA;EAAAC,KAAA;AAAA,IAAAH,GAAA;AAAA,IAAAI,2BAAA;AAAAC,QAAA,CAAAD,2BAAA;EAAAE,qBAAA,EAAAA,CAAA,KAAAA,qBAAA;EAAAC,0BAAA,EAAAA,CAAA,KAAAA,0BAAA;EAAAC,uBAAA,EAAAA,CAAA,KAAAA,uBAAA;EAAAC,qBAAA,EAAAA,CAAA,KAAAA,qBAAA;EAAAC,YAAA,EAAAA,CAAA,KAAAA,YAAA;EAAAC,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BAAA;QACL,KAASK,IAAA,EAAAC,MAAA,IAAAF,MAAA,CAAAxD,KAAA;QACT,IAAOyD,IAAA,yBAAAC,MAAA;UACDV,iBAAA,GAAAU,MAAA;QACN,OAAO,IAAAD,IAAA,uBAAAC,MAAA;UACPT,MAAY,GAACS,MAAA;QACf,WAAAD,IAAA,sBAAAC,MAAA;UACFR,KAAA,GAAAQ,MAAA;QAUO,CAAS,UAAAD,IAAA,YACd,WACAC,MAAA,KACiC;UAE3BP,MAAA,GAAAO,MAAA;QACF,WAAAzC,iBAAiC,CAAAwC,IAAA,KAAAC,MAAA;UACnCX,aAAO,CAAAU,IAAA,IAAAC,MAAA;QACT,WAAAA,MAAA;UAGOZ,WAAW,CAAAW,IAAA,IAAAC,MAAA;QACpB;MAKO;IACL,SACEjB,GAAA;MAKJY,kBAAA;MAMOC,eAAS,GAAAb,GAAA;IACd,UAAO;MACT;QAUO,IAAS,CAAAW,0BACd,IACAG,UACe,CAAAb,MAAA;UACXa,UAAU,CAAAb,MAAW;QACvB;MACF;QACI,IAAAW,kBAAoB;UACtB,MAAOC,eAAW;QACpB;MACA;IACF;IAYO,OAAS;MAMdjC,OAAM,EAAA2B,iBAAS;MAEf1B,KAAA,EAAW2B,MAAA;MACT1B,IAAM,EAAA2B,KAAA;MACN1B,KAAI,EAAA2B,MAAA;MAEJ1B,UAAW,EAAAqB,WAAA;MACTH,MAAA,EAAAR,MAAA,CAAAS,IAAiB,CAAAG,aAAW,EAAAF,MAAa,OAAKE,aAAA;IAChD;EAKE;EAA4D,OAC9D;IAGA1B,OAAI;IACFC,KAAA;IACFC,IAAA;IAEAC,KAAA,EAAO,KAAI;IACbC,UAAA;EAEA;AACF","ignoreList":[]}
|
package/dist/cjs/types.cjs
CHANGED
|
@@ -3,14 +3,16 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
3
3
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
4
4
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
5
5
|
var __copyProps = (to, from, except, desc) => {
|
|
6
|
-
if (from && typeof from
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
6
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
7
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
8
|
+
get: () => from[key],
|
|
9
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
10
|
+
});
|
|
11
|
+
}
|
|
10
12
|
return to;
|
|
11
13
|
};
|
|
12
14
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
13
|
-
value:
|
|
15
|
+
value: true
|
|
14
16
|
}), mod);
|
|
15
17
|
var types_exports = {};
|
|
16
18
|
module.exports = __toCommonJS(types_exports);
|
package/dist/cjs/types.native.js
CHANGED
|
@@ -5,14 +5,16 @@ var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
|
5
5
|
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
6
|
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
7
7
|
var __copyProps = (to, from, except, desc) => {
|
|
8
|
-
if (from && typeof from
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
8
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
9
|
+
for (let key of __getOwnPropNames(from)) if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
|
|
10
|
+
get: () => from[key],
|
|
11
|
+
enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
|
|
12
|
+
});
|
|
13
|
+
}
|
|
12
14
|
return to;
|
|
13
15
|
};
|
|
14
16
|
var __toCommonJS = mod => __copyProps(__defProp({}, "__esModule", {
|
|
15
|
-
value:
|
|
17
|
+
value: true
|
|
16
18
|
}), mod);
|
|
17
19
|
var types_exports = {};
|
|
18
20
|
module.exports = __toCommonJS(types_exports);
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["__toCommonJS","mod","__copyProps","__defProp","value","types_exports"],"sources":["../../src/types.ts"],"sourcesContent":[null],"mappings":"
|
|
1
|
+
{"version":3,"names":["__toCommonJS","mod","__copyProps","__defProp","value","types_exports"],"sources":["../../src/types.ts"],"sourcesContent":[null],"mappings":";;;;;;;;;;;;;;;AAAA,IAAAA,YAAA,GAAAC,GAAA,IAAAC,WAAA,CAAAC,SAAA;EAAAC,KAAA;AAAA,IAAAH,GAAA;AAAA,IAAAI,aAAA","ignoreList":[]}
|
|
@@ -3,28 +3,46 @@ function isSpringConfigKey(key) {
|
|
|
3
3
|
return SPRING_CONFIG_KEYS.has(key);
|
|
4
4
|
}
|
|
5
5
|
function normalizeTransition(transition) {
|
|
6
|
-
if (!transition)
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
6
|
+
if (!transition) {
|
|
7
|
+
return {
|
|
8
|
+
default: null,
|
|
9
|
+
enter: null,
|
|
10
|
+
exit: null,
|
|
11
|
+
delay: void 0,
|
|
12
|
+
properties: {}
|
|
13
|
+
};
|
|
14
|
+
}
|
|
15
|
+
if (typeof transition === "string") {
|
|
16
|
+
return {
|
|
17
|
+
default: transition,
|
|
18
|
+
enter: null,
|
|
19
|
+
exit: null,
|
|
20
|
+
delay: void 0,
|
|
21
|
+
properties: {}
|
|
22
|
+
};
|
|
23
|
+
}
|
|
20
24
|
if (Array.isArray(transition)) {
|
|
21
|
-
const [defaultAnimation, configObj] = transition
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
let delay
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
if (configObj && typeof configObj
|
|
25
|
+
const [defaultAnimation, configObj] = transition;
|
|
26
|
+
const properties = {};
|
|
27
|
+
const springConfig = {};
|
|
28
|
+
let delay;
|
|
29
|
+
let enter = null;
|
|
30
|
+
let exit = null;
|
|
31
|
+
if (configObj && typeof configObj === "object") {
|
|
32
|
+
for (const [key, value] of Object.entries(configObj)) {
|
|
33
|
+
if (key === "delay" && typeof value === "number") {
|
|
34
|
+
delay = value;
|
|
35
|
+
} else if (key === "enter" && typeof value === "string") {
|
|
36
|
+
enter = value;
|
|
37
|
+
} else if (key === "exit" && typeof value === "string") {
|
|
38
|
+
exit = value;
|
|
39
|
+
} else if (isSpringConfigKey(key) && value !== void 0) {
|
|
40
|
+
springConfig[key] = value;
|
|
41
|
+
} else if (value !== void 0) {
|
|
42
|
+
properties[key] = value;
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
}
|
|
28
46
|
return {
|
|
29
47
|
default: defaultAnimation,
|
|
30
48
|
enter,
|
|
@@ -34,14 +52,28 @@ function normalizeTransition(transition) {
|
|
|
34
52
|
config: Object.keys(springConfig).length > 0 ? springConfig : void 0
|
|
35
53
|
};
|
|
36
54
|
}
|
|
37
|
-
if (typeof transition
|
|
38
|
-
const properties = {}
|
|
39
|
-
|
|
40
|
-
let defaultAnimation = null
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
for (const [key, value] of Object.entries(transition))
|
|
55
|
+
if (typeof transition === "object") {
|
|
56
|
+
const properties = {};
|
|
57
|
+
const springConfig = {};
|
|
58
|
+
let defaultAnimation = null;
|
|
59
|
+
let enter = null;
|
|
60
|
+
let exit = null;
|
|
61
|
+
let delay;
|
|
62
|
+
for (const [key, value] of Object.entries(transition)) {
|
|
63
|
+
if (key === "default" && typeof value === "string") {
|
|
64
|
+
defaultAnimation = value;
|
|
65
|
+
} else if (key === "enter" && typeof value === "string") {
|
|
66
|
+
enter = value;
|
|
67
|
+
} else if (key === "exit" && typeof value === "string") {
|
|
68
|
+
exit = value;
|
|
69
|
+
} else if (key === "delay" && typeof value === "number") {
|
|
70
|
+
delay = value;
|
|
71
|
+
} else if (isSpringConfigKey(key) && value !== void 0) {
|
|
72
|
+
springConfig[key] = value;
|
|
73
|
+
} else if (value !== void 0) {
|
|
74
|
+
properties[key] = value;
|
|
75
|
+
}
|
|
76
|
+
}
|
|
45
77
|
return {
|
|
46
78
|
default: defaultAnimation,
|
|
47
79
|
enter,
|
|
@@ -61,7 +93,10 @@ function normalizeTransition(transition) {
|
|
|
61
93
|
}
|
|
62
94
|
function getAnimationForProperty(normalized, property) {
|
|
63
95
|
const propertyAnimation = normalized.properties[property];
|
|
64
|
-
|
|
96
|
+
if (propertyAnimation !== void 0) {
|
|
97
|
+
return propertyAnimation;
|
|
98
|
+
}
|
|
99
|
+
return normalized.default;
|
|
65
100
|
}
|
|
66
101
|
function hasAnimation(normalized) {
|
|
67
102
|
return normalized.default !== null || normalized.enter !== null || normalized.exit !== null || Object.keys(normalized.properties).length > 0;
|
|
@@ -70,14 +105,28 @@ function getAnimatedProperties(normalized) {
|
|
|
70
105
|
return Object.keys(normalized.properties);
|
|
71
106
|
}
|
|
72
107
|
function getEffectiveAnimation(normalized, state) {
|
|
73
|
-
|
|
108
|
+
if (state === "enter" && normalized.enter) {
|
|
109
|
+
return normalized.enter;
|
|
110
|
+
}
|
|
111
|
+
if (state === "exit" && normalized.exit) {
|
|
112
|
+
return normalized.exit;
|
|
113
|
+
}
|
|
114
|
+
return normalized.default;
|
|
74
115
|
}
|
|
75
116
|
function getAnimationConfigsForKeys(normalized, animations, keys, defaultAnimation) {
|
|
76
117
|
const result = /* @__PURE__ */new Map();
|
|
77
118
|
for (const key of keys) {
|
|
78
119
|
const propAnimation = normalized.properties[key];
|
|
79
120
|
let animationValue = null;
|
|
80
|
-
typeof propAnimation
|
|
121
|
+
if (typeof propAnimation === "string") {
|
|
122
|
+
animationValue = animations[propAnimation] ?? null;
|
|
123
|
+
} else if (propAnimation && typeof propAnimation === "object" && propAnimation.type) {
|
|
124
|
+
animationValue = animations[propAnimation.type] ?? null;
|
|
125
|
+
}
|
|
126
|
+
if (animationValue === null) {
|
|
127
|
+
animationValue = defaultAnimation;
|
|
128
|
+
}
|
|
129
|
+
result.set(key, animationValue);
|
|
81
130
|
}
|
|
82
131
|
return result;
|
|
83
132
|
}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["SPRING_CONFIG_KEYS","Set","isSpringConfigKey","key","has","normalizeTransition","transition","default","enter","exit","delay","properties","Array","isArray","defaultAnimation","configObj","springConfig","value","Object","entries","config","keys","length","getAnimationForProperty","normalized","property","propertyAnimation","hasAnimation","getAnimatedProperties","getEffectiveAnimation","state","getAnimationConfigsForKeys","animations","result","Map","propAnimation","animationValue","type","set"],"sources":["../../src/normalizeTransition.ts"],"sourcesContent":[null],"mappings":"AAOA,MAAMA,kBAAA,GAAkC,mBAAIC,GAAA,CAAI,CAC9C,aACA,WACA,QACA,WACA,YACA,YACA,qBACA,YACA,cACA,QACD;AAKD,SAASC,kBAAkBC,GAAA,EAAwC;EACjE,OAAOH,kBAAA,CAAmBI,GAAA,CAAID,GAAG;AACnC;AAcO,SAASE,oBACdC,UAAA,EACsB;EAEtB,IAAI,CAACA,UAAA,
|
|
1
|
+
{"version":3,"names":["SPRING_CONFIG_KEYS","Set","isSpringConfigKey","key","has","normalizeTransition","transition","default","enter","exit","delay","properties","Array","isArray","defaultAnimation","configObj","springConfig","value","Object","entries","config","keys","length","getAnimationForProperty","normalized","property","propertyAnimation","hasAnimation","getAnimatedProperties","getEffectiveAnimation","state","getAnimationConfigsForKeys","animations","result","Map","propAnimation","animationValue","type","set"],"sources":["../../src/normalizeTransition.ts"],"sourcesContent":[null],"mappings":"AAOA,MAAMA,kBAAA,GAAkC,mBAAIC,GAAA,CAAI,CAC9C,aACA,WACA,QACA,WACA,YACA,YACA,qBACA,YACA,cACA,QACD;AAKD,SAASC,kBAAkBC,GAAA,EAAwC;EACjE,OAAOH,kBAAA,CAAmBI,GAAA,CAAID,GAAG;AACnC;AAcO,SAASE,oBACdC,UAAA,EACsB;EAEtB,IAAI,CAACA,UAAA,EAAY;IACf,OAAO;MACLC,OAAA,EAAS;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A,cAAA,GAAiBtB,gBAAA;IACnB;IAEAmB,MAAA,CAAOK,GAAA,CAAInC,GAAA,EAAKiC,cAAc;EAChC;EAEA,OAAOH,MAAA;AACT","ignoreList":[]}
|
|
@@ -1,50 +1,69 @@
|
|
|
1
1
|
function _type_of(obj) {
|
|
2
2
|
"@swc/helpers - typeof";
|
|
3
3
|
|
|
4
|
-
return obj && typeof Symbol
|
|
4
|
+
return obj && typeof Symbol !== "undefined" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
5
5
|
}
|
|
6
6
|
var SPRING_CONFIG_KEYS = /* @__PURE__ */new Set(["stiffness", "damping", "mass", "tension", "friction", "velocity", "overshootClamping", "duration", "bounciness", "speed"]);
|
|
7
7
|
function isSpringConfigKey(key) {
|
|
8
8
|
return SPRING_CONFIG_KEYS.has(key);
|
|
9
9
|
}
|
|
10
10
|
function normalizeTransition(transition) {
|
|
11
|
-
if (!transition)
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
|
|
20
|
-
|
|
21
|
-
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
11
|
+
if (!transition) {
|
|
12
|
+
return {
|
|
13
|
+
default: null,
|
|
14
|
+
enter: null,
|
|
15
|
+
exit: null,
|
|
16
|
+
delay: void 0,
|
|
17
|
+
properties: {}
|
|
18
|
+
};
|
|
19
|
+
}
|
|
20
|
+
if (typeof transition === "string") {
|
|
21
|
+
return {
|
|
22
|
+
default: transition,
|
|
23
|
+
enter: null,
|
|
24
|
+
exit: null,
|
|
25
|
+
delay: void 0,
|
|
26
|
+
properties: {}
|
|
27
|
+
};
|
|
28
|
+
}
|
|
25
29
|
if (Array.isArray(transition)) {
|
|
26
|
-
var [defaultAnimation, configObj] = transition
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
if (configObj && (typeof configObj
|
|
33
|
-
var _iteratorNormalCompletion =
|
|
34
|
-
_didIteratorError =
|
|
30
|
+
var [defaultAnimation, configObj] = transition;
|
|
31
|
+
var properties = {};
|
|
32
|
+
var springConfig = {};
|
|
33
|
+
var delay;
|
|
34
|
+
var enter = null;
|
|
35
|
+
var exit = null;
|
|
36
|
+
if (configObj && (typeof configObj === "undefined" ? "undefined" : _type_of(configObj)) === "object") {
|
|
37
|
+
var _iteratorNormalCompletion = true,
|
|
38
|
+
_didIteratorError = false,
|
|
35
39
|
_iteratorError = void 0;
|
|
36
40
|
try {
|
|
37
|
-
for (var _iterator = Object.entries(configObj)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion =
|
|
41
|
+
for (var _iterator = Object.entries(configObj)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
|
|
38
42
|
var [key, value] = _step.value;
|
|
39
|
-
key === "delay" && typeof value
|
|
43
|
+
if (key === "delay" && typeof value === "number") {
|
|
44
|
+
delay = value;
|
|
45
|
+
} else if (key === "enter" && typeof value === "string") {
|
|
46
|
+
enter = value;
|
|
47
|
+
} else if (key === "exit" && typeof value === "string") {
|
|
48
|
+
exit = value;
|
|
49
|
+
} else if (isSpringConfigKey(key) && value !== void 0) {
|
|
50
|
+
springConfig[key] = value;
|
|
51
|
+
} else if (value !== void 0) {
|
|
52
|
+
properties[key] = value;
|
|
53
|
+
}
|
|
40
54
|
}
|
|
41
55
|
} catch (err) {
|
|
42
|
-
_didIteratorError =
|
|
56
|
+
_didIteratorError = true;
|
|
57
|
+
_iteratorError = err;
|
|
43
58
|
} finally {
|
|
44
59
|
try {
|
|
45
|
-
!_iteratorNormalCompletion && _iterator.return != null
|
|
60
|
+
if (!_iteratorNormalCompletion && _iterator.return != null) {
|
|
61
|
+
_iterator.return();
|
|
62
|
+
}
|
|
46
63
|
} finally {
|
|
47
|
-
if (_didIteratorError)
|
|
64
|
+
if (_didIteratorError) {
|
|
65
|
+
throw _iteratorError;
|
|
66
|
+
}
|
|
48
67
|
}
|
|
49
68
|
}
|
|
50
69
|
}
|
|
@@ -57,28 +76,45 @@ function normalizeTransition(transition) {
|
|
|
57
76
|
config: Object.keys(springConfig).length > 0 ? springConfig : void 0
|
|
58
77
|
};
|
|
59
78
|
}
|
|
60
|
-
if ((typeof transition
|
|
61
|
-
var properties1 = {}
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
66
|
-
|
|
67
|
-
|
|
68
|
-
_didIteratorError1 =
|
|
79
|
+
if ((typeof transition === "undefined" ? "undefined" : _type_of(transition)) === "object") {
|
|
80
|
+
var properties1 = {};
|
|
81
|
+
var springConfig1 = {};
|
|
82
|
+
var defaultAnimation1 = null;
|
|
83
|
+
var enter1 = null;
|
|
84
|
+
var exit1 = null;
|
|
85
|
+
var delay1;
|
|
86
|
+
var _iteratorNormalCompletion1 = true,
|
|
87
|
+
_didIteratorError1 = false,
|
|
69
88
|
_iteratorError1 = void 0;
|
|
70
89
|
try {
|
|
71
|
-
for (var _iterator1 = Object.entries(transition)[Symbol.iterator](), _step1; !(_iteratorNormalCompletion1 = (_step1 = _iterator1.next()).done); _iteratorNormalCompletion1 =
|
|
90
|
+
for (var _iterator1 = Object.entries(transition)[Symbol.iterator](), _step1; !(_iteratorNormalCompletion1 = (_step1 = _iterator1.next()).done); _iteratorNormalCompletion1 = true) {
|
|
72
91
|
var [key1, value1] = _step1.value;
|
|
73
|
-
key1 === "default" && typeof value1
|
|
92
|
+
if (key1 === "default" && typeof value1 === "string") {
|
|
93
|
+
defaultAnimation1 = value1;
|
|
94
|
+
} else if (key1 === "enter" && typeof value1 === "string") {
|
|
95
|
+
enter1 = value1;
|
|
96
|
+
} else if (key1 === "exit" && typeof value1 === "string") {
|
|
97
|
+
exit1 = value1;
|
|
98
|
+
} else if (key1 === "delay" && typeof value1 === "number") {
|
|
99
|
+
delay1 = value1;
|
|
100
|
+
} else if (isSpringConfigKey(key1) && value1 !== void 0) {
|
|
101
|
+
springConfig1[key1] = value1;
|
|
102
|
+
} else if (value1 !== void 0) {
|
|
103
|
+
properties1[key1] = value1;
|
|
104
|
+
}
|
|
74
105
|
}
|
|
75
106
|
} catch (err) {
|
|
76
|
-
_didIteratorError1 =
|
|
107
|
+
_didIteratorError1 = true;
|
|
108
|
+
_iteratorError1 = err;
|
|
77
109
|
} finally {
|
|
78
110
|
try {
|
|
79
|
-
!_iteratorNormalCompletion1 && _iterator1.return != null
|
|
111
|
+
if (!_iteratorNormalCompletion1 && _iterator1.return != null) {
|
|
112
|
+
_iterator1.return();
|
|
113
|
+
}
|
|
80
114
|
} finally {
|
|
81
|
-
if (_didIteratorError1)
|
|
115
|
+
if (_didIteratorError1) {
|
|
116
|
+
throw _iteratorError1;
|
|
117
|
+
}
|
|
82
118
|
}
|
|
83
119
|
}
|
|
84
120
|
return {
|
|
@@ -100,7 +136,10 @@ function normalizeTransition(transition) {
|
|
|
100
136
|
}
|
|
101
137
|
function getAnimationForProperty(normalized, property) {
|
|
102
138
|
var propertyAnimation = normalized.properties[property];
|
|
103
|
-
|
|
139
|
+
if (propertyAnimation !== void 0) {
|
|
140
|
+
return propertyAnimation;
|
|
141
|
+
}
|
|
142
|
+
return normalized.default;
|
|
104
143
|
}
|
|
105
144
|
function hasAnimation(normalized) {
|
|
106
145
|
return normalized.default !== null || normalized.enter !== null || normalized.exit !== null || Object.keys(normalized.properties).length > 0;
|
|
@@ -109,34 +148,48 @@ function getAnimatedProperties(normalized) {
|
|
|
109
148
|
return Object.keys(normalized.properties);
|
|
110
149
|
}
|
|
111
150
|
function getEffectiveAnimation(normalized, state) {
|
|
112
|
-
|
|
151
|
+
if (state === "enter" && normalized.enter) {
|
|
152
|
+
return normalized.enter;
|
|
153
|
+
}
|
|
154
|
+
if (state === "exit" && normalized.exit) {
|
|
155
|
+
return normalized.exit;
|
|
156
|
+
}
|
|
157
|
+
return normalized.default;
|
|
113
158
|
}
|
|
114
159
|
function getAnimationConfigsForKeys(normalized, animations, keys, defaultAnimation) {
|
|
115
|
-
var result = /* @__PURE__ */new Map()
|
|
116
|
-
|
|
117
|
-
_didIteratorError =
|
|
160
|
+
var result = /* @__PURE__ */new Map();
|
|
161
|
+
var _iteratorNormalCompletion = true,
|
|
162
|
+
_didIteratorError = false,
|
|
118
163
|
_iteratorError = void 0;
|
|
119
164
|
try {
|
|
120
|
-
for (var _iterator = keys[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion =
|
|
121
|
-
var key = _step.value
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
if (typeof propAnimation
|
|
165
|
+
for (var _iterator = keys[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = true) {
|
|
166
|
+
var key = _step.value;
|
|
167
|
+
var propAnimation = normalized.properties[key];
|
|
168
|
+
var animationValue = null;
|
|
169
|
+
if (typeof propAnimation === "string") {
|
|
125
170
|
var _animations_propAnimation;
|
|
126
171
|
animationValue = (_animations_propAnimation = animations[propAnimation]) !== null && _animations_propAnimation !== void 0 ? _animations_propAnimation : null;
|
|
127
|
-
} else if (propAnimation && (typeof propAnimation
|
|
172
|
+
} else if (propAnimation && (typeof propAnimation === "undefined" ? "undefined" : _type_of(propAnimation)) === "object" && propAnimation.type) {
|
|
128
173
|
var _animations_propAnimation_type;
|
|
129
174
|
animationValue = (_animations_propAnimation_type = animations[propAnimation.type]) !== null && _animations_propAnimation_type !== void 0 ? _animations_propAnimation_type : null;
|
|
130
175
|
}
|
|
131
|
-
animationValue === null
|
|
176
|
+
if (animationValue === null) {
|
|
177
|
+
animationValue = defaultAnimation;
|
|
178
|
+
}
|
|
179
|
+
result.set(key, animationValue);
|
|
132
180
|
}
|
|
133
181
|
} catch (err) {
|
|
134
|
-
_didIteratorError =
|
|
182
|
+
_didIteratorError = true;
|
|
183
|
+
_iteratorError = err;
|
|
135
184
|
} finally {
|
|
136
185
|
try {
|
|
137
|
-
!_iteratorNormalCompletion && _iterator.return != null
|
|
186
|
+
if (!_iteratorNormalCompletion && _iterator.return != null) {
|
|
187
|
+
_iterator.return();
|
|
188
|
+
}
|
|
138
189
|
} finally {
|
|
139
|
-
if (_didIteratorError)
|
|
190
|
+
if (_didIteratorError) {
|
|
191
|
+
throw _iteratorError;
|
|
192
|
+
}
|
|
140
193
|
}
|
|
141
194
|
}
|
|
142
195
|
return result;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"names":["_type_of","obj","Symbol","constructor","SPRING_CONFIG_KEYS","Set","isSpringConfigKey","key","has","normalizeTransition","transition","default","enter","exit","delay","properties","Array","isArray","defaultAnimation","configObj","springConfig","_iteratorNormalCompletion","_didIteratorError","_iteratorError","_iterator","Object","entries","iterator","_step","next","done","value","err","return","config","keys","length","properties1","springConfig1","defaultAnimation1","enter1","exit1","delay1","_iteratorNormalCompletion1","_didIteratorError1","_iteratorError1","_iterator1","_step1","key1","value1"],"sources":["../../src/normalizeTransition.ts"],"sourcesContent":[null],"mappings":"AAOA,SAAMA,SAAAC,GAAA;EACJ;;EACA,OAAAA,GAAA,WAAAC,MAAA,
|
|
1
|
+
{"version":3,"names":["_type_of","obj","Symbol","constructor","SPRING_CONFIG_KEYS","Set","isSpringConfigKey","key","has","normalizeTransition","transition","default","enter","exit","delay","properties","Array","isArray","defaultAnimation","configObj","springConfig","_iteratorNormalCompletion","_didIteratorError","_iteratorError","_iterator","Object","entries","iterator","_step","next","done","value","err","return","config","keys","length","properties1","springConfig1","defaultAnimation1","enter1","exit1","delay1","_iteratorNormalCompletion1","_didIteratorError1","_iteratorError1","_iterator1","_step1","key1","value1","getAnimationForProperty","normalized","property"],"sources":["../../src/normalizeTransition.ts"],"sourcesContent":[null],"mappings":"AAOA,SAAMA,SAAAC,GAAA;EACJ;;EACA,OAAAA,GAAA,WAAAC,MAAA,oBAAAD,GAAA,CAAAE,WAAA,KAAAD,MAAA,qBAAAD,GAAA;AAAA;A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