fast-vue-multi-pages 1.0.24 → 1.0.26
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.
@@ -11,27 +11,28 @@ class FastVueMultiAnimate {
|
|
11
11
|
static startValueAnimate(animateCode, animateConfig) {
|
12
12
|
this.clearAnimate(animateCode);
|
13
13
|
let params = ValueAnimateConfig.newParam(animateConfig);
|
14
|
+
let animObj = {
|
15
|
+
value: params.from,
|
16
|
+
};
|
14
17
|
const anime = require('animejs');
|
15
|
-
this.animateMap[animateCode] = anime({
|
16
|
-
targets:
|
17
|
-
value: params.from,
|
18
|
-
},
|
18
|
+
this.animateMap[animateCode] = anime.default({
|
19
|
+
targets: animObj,
|
19
20
|
value: params.to,
|
20
21
|
easing: params.easing,
|
21
22
|
duration: params.duration,
|
22
23
|
delay: params.delay,
|
23
|
-
_params: params,
|
24
24
|
update: function () {
|
25
|
-
|
25
|
+
params.update(animObj.value);
|
26
26
|
},
|
27
27
|
changeBegin: function (anim) {
|
28
|
-
|
28
|
+
params.changeBegin(anim);
|
29
29
|
},
|
30
30
|
begin: function (anim) {
|
31
|
-
|
31
|
+
params.begin(anim);
|
32
32
|
},
|
33
33
|
complete: function (anim) {
|
34
|
-
|
34
|
+
params.complete(anim);
|
35
|
+
FastVueMultiAnimate.clearAnimate(animateCode);
|
35
36
|
}
|
36
37
|
});
|
37
38
|
}
|
@@ -13,27 +13,28 @@ define(["require", "exports"], function (require, exports) {
|
|
13
13
|
FastVueMultiAnimate.startValueAnimate = function (animateCode, animateConfig) {
|
14
14
|
this.clearAnimate(animateCode);
|
15
15
|
var params = ValueAnimateConfig.newParam(animateConfig);
|
16
|
+
var animObj = {
|
17
|
+
value: params.from,
|
18
|
+
};
|
16
19
|
var anime = require('animejs');
|
17
|
-
this.animateMap[animateCode] = anime({
|
18
|
-
targets:
|
19
|
-
value: params.from,
|
20
|
-
},
|
20
|
+
this.animateMap[animateCode] = anime.default({
|
21
|
+
targets: animObj,
|
21
22
|
value: params.to,
|
22
23
|
easing: params.easing,
|
23
24
|
duration: params.duration,
|
24
25
|
delay: params.delay,
|
25
|
-
_params: params,
|
26
26
|
update: function () {
|
27
|
-
|
27
|
+
params.update(animObj.value);
|
28
28
|
},
|
29
29
|
changeBegin: function (anim) {
|
30
|
-
|
30
|
+
params.changeBegin(anim);
|
31
31
|
},
|
32
32
|
begin: function (anim) {
|
33
|
-
|
33
|
+
params.begin(anim);
|
34
34
|
},
|
35
35
|
complete: function (anim) {
|
36
|
-
|
36
|
+
params.complete(anim);
|
37
|
+
FastVueMultiAnimate.clearAnimate(animateCode);
|
37
38
|
}
|
38
39
|
});
|
39
40
|
};
|