@eva/plugin-transition 1.3.0-alpha.0 → 2.0.0-beta.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.
Files changed (240) hide show
  1. package/dist/EVA.plugin.transition.js +57 -274
  2. package/dist/EVA.plugin.transition.min.js +1 -1
  3. package/dist/packages/eva.js/lib/core/Component.d.ts +35 -0
  4. package/dist/packages/eva.js/lib/core/Component.d.ts.map +1 -0
  5. package/dist/packages/eva.js/lib/core/ComponentObserver.d.ts +22 -0
  6. package/dist/packages/eva.js/lib/core/ComponentObserver.d.ts.map +1 -0
  7. package/dist/packages/eva.js/lib/core/GameObject.d.ts +31 -0
  8. package/dist/packages/eva.js/lib/core/GameObject.d.ts.map +1 -0
  9. package/dist/packages/eva.js/lib/core/System.d.ts +30 -0
  10. package/dist/packages/eva.js/lib/core/System.d.ts.map +1 -0
  11. package/dist/packages/eva.js/lib/core/Transform.d.ts +51 -0
  12. package/dist/packages/eva.js/lib/core/Transform.d.ts.map +1 -0
  13. package/dist/packages/eva.js/lib/core/observer.d.ts +23 -0
  14. package/dist/packages/eva.js/lib/core/observer.d.ts.map +1 -0
  15. package/dist/packages/eva.js/lib/decorators/ide.d.ts +2 -0
  16. package/dist/packages/eva.js/lib/decorators/ide.d.ts.map +1 -0
  17. package/dist/packages/eva.js/lib/decorators/system.d.ts +11 -0
  18. package/dist/packages/eva.js/lib/decorators/system.d.ts.map +1 -0
  19. package/dist/packages/eva.js/lib/game/Game.d.ts +72 -0
  20. package/dist/packages/eva.js/lib/game/Game.d.ts.map +1 -0
  21. package/dist/packages/eva.js/lib/game/Scene.d.ts +12 -0
  22. package/dist/packages/eva.js/lib/game/Scene.d.ts.map +1 -0
  23. package/dist/packages/eva.js/lib/game/Ticker.d.ts +25 -0
  24. package/dist/packages/eva.js/lib/game/Ticker.d.ts.map +1 -0
  25. package/dist/packages/eva.js/lib/index.d.ts +26 -0
  26. package/dist/packages/eva.js/lib/index.d.ts.map +1 -0
  27. package/dist/packages/eva.js/lib/loader/Progress.d.ts +21 -0
  28. package/dist/packages/eva.js/lib/loader/Progress.d.ts.map +1 -0
  29. package/dist/packages/eva.js/lib/loader/Resource.d.ts +99 -0
  30. package/dist/packages/eva.js/lib/loader/Resource.d.ts.map +1 -0
  31. package/dist/packages/eva.js/lib/loader/resourceLoader.d.ts +14 -0
  32. package/dist/packages/eva.js/lib/loader/resourceLoader.d.ts.map +1 -0
  33. package/dist/packages/eva.js/lib/timeline/index.d.ts +40 -0
  34. package/dist/packages/eva.js/lib/timeline/index.d.ts.map +1 -0
  35. package/dist/packages/eva.js/lib/timeline/utils.d.ts +2 -0
  36. package/dist/packages/eva.js/lib/timeline/utils.d.ts.map +1 -0
  37. package/dist/packages/plugin-a11y/lib/A11y.d.ts +26 -0
  38. package/dist/packages/plugin-a11y/lib/A11y.d.ts.map +1 -0
  39. package/dist/packages/plugin-a11y/lib/A11ySystem.d.ts +54 -0
  40. package/dist/packages/plugin-a11y/lib/A11ySystem.d.ts.map +1 -0
  41. package/dist/packages/plugin-a11y/lib/constant.d.ts +34 -0
  42. package/dist/packages/plugin-a11y/lib/constant.d.ts.map +1 -0
  43. package/dist/packages/plugin-a11y/lib/index.d.ts +4 -0
  44. package/dist/packages/plugin-a11y/lib/index.d.ts.map +1 -0
  45. package/dist/packages/plugin-a11y/lib/utils.d.ts +6 -0
  46. package/dist/packages/plugin-a11y/lib/utils.d.ts.map +1 -0
  47. package/dist/packages/plugin-evax/lib/EvaXComponent.d.ts +20 -0
  48. package/dist/packages/plugin-evax/lib/EvaXComponent.d.ts.map +1 -0
  49. package/dist/packages/plugin-evax/lib/EvaXSystem.d.ts +33 -0
  50. package/dist/packages/plugin-evax/lib/EvaXSystem.d.ts.map +1 -0
  51. package/dist/packages/plugin-evax/lib/index.d.ts +10 -0
  52. package/dist/packages/plugin-evax/lib/index.d.ts.map +1 -0
  53. package/dist/packages/plugin-evax/lib/utils.d.ts +3 -0
  54. package/dist/packages/plugin-evax/lib/utils.d.ts.map +1 -0
  55. package/dist/packages/plugin-matterjs/lib/BodiesFactory.d.ts +31 -0
  56. package/dist/packages/plugin-matterjs/lib/BodiesFactory.d.ts.map +1 -0
  57. package/dist/packages/plugin-matterjs/lib/Physics.d.ts +32 -0
  58. package/dist/packages/plugin-matterjs/lib/Physics.d.ts.map +1 -0
  59. package/dist/packages/plugin-matterjs/lib/PhysicsEngine.d.ts +35 -0
  60. package/dist/packages/plugin-matterjs/lib/PhysicsEngine.d.ts.map +1 -0
  61. package/dist/packages/plugin-matterjs/lib/PhysicsSystem.d.ts +32 -0
  62. package/dist/packages/plugin-matterjs/lib/PhysicsSystem.d.ts.map +1 -0
  63. package/dist/packages/plugin-matterjs/lib/index.d.ts +5 -0
  64. package/dist/packages/plugin-matterjs/lib/index.d.ts.map +1 -0
  65. package/dist/packages/plugin-matterjs/lib/matter.d.ts +3 -0
  66. package/dist/packages/plugin-matterjs/lib/matter.d.ts.map +1 -0
  67. package/dist/packages/plugin-renderer/lib/Renderer.d.ts +19 -0
  68. package/dist/packages/plugin-renderer/lib/Renderer.d.ts.map +1 -0
  69. package/dist/packages/plugin-renderer/lib/System.d.ts +40 -0
  70. package/dist/packages/plugin-renderer/lib/System.d.ts.map +1 -0
  71. package/dist/packages/plugin-renderer/lib/Transform.d.ts +28 -0
  72. package/dist/packages/plugin-renderer/lib/Transform.d.ts.map +1 -0
  73. package/dist/packages/plugin-renderer/lib/compressedTexture/ability.d.ts +20 -0
  74. package/dist/packages/plugin-renderer/lib/compressedTexture/ability.d.ts.map +1 -0
  75. package/dist/packages/plugin-renderer/lib/compressedTexture/fix/loader.d.ts +2 -0
  76. package/dist/packages/plugin-renderer/lib/compressedTexture/fix/loader.d.ts.map +1 -0
  77. package/dist/packages/plugin-renderer/lib/compressedTexture/index.d.ts +7 -0
  78. package/dist/packages/plugin-renderer/lib/compressedTexture/index.d.ts.map +1 -0
  79. package/dist/packages/plugin-renderer/lib/index.d.ts +8 -0
  80. package/dist/packages/plugin-renderer/lib/index.d.ts.map +1 -0
  81. package/dist/packages/plugin-renderer/lib/manager/ContainerManager.d.ts +18 -0
  82. package/dist/packages/plugin-renderer/lib/manager/ContainerManager.d.ts.map +1 -0
  83. package/dist/packages/plugin-renderer/lib/manager/RendererManager.d.ts +17 -0
  84. package/dist/packages/plugin-renderer/lib/manager/RendererManager.d.ts.map +1 -0
  85. package/dist/packages/plugin-renderer/lib/mixin.d.ts +2 -0
  86. package/dist/packages/plugin-renderer/lib/mixin.d.ts.map +1 -0
  87. package/dist/packages/plugin-renderer-dragonbone/lib/component.d.ts +26 -0
  88. package/dist/packages/plugin-renderer-dragonbone/lib/component.d.ts.map +1 -0
  89. package/dist/packages/plugin-renderer-dragonbone/lib/db.d.ts +3 -0
  90. package/dist/packages/plugin-renderer-dragonbone/lib/db.d.ts.map +1 -0
  91. package/dist/packages/plugin-renderer-dragonbone/lib/engine.d.ts +10 -0
  92. package/dist/packages/plugin-renderer-dragonbone/lib/engine.d.ts.map +1 -0
  93. package/dist/packages/plugin-renderer-dragonbone/lib/index.d.ts +4 -0
  94. package/dist/packages/plugin-renderer-dragonbone/lib/index.d.ts.map +1 -0
  95. package/dist/packages/plugin-renderer-dragonbone/lib/system.d.ts +24 -0
  96. package/dist/packages/plugin-renderer-dragonbone/lib/system.d.ts.map +1 -0
  97. package/dist/packages/plugin-renderer-event/lib/component.d.ts +52 -0
  98. package/dist/packages/plugin-renderer-event/lib/component.d.ts.map +1 -0
  99. package/dist/packages/plugin-renderer-event/lib/index.d.ts +5 -0
  100. package/dist/packages/plugin-renderer-event/lib/index.d.ts.map +1 -0
  101. package/dist/packages/plugin-renderer-event/lib/system.d.ts +19 -0
  102. package/dist/packages/plugin-renderer-event/lib/system.d.ts.map +1 -0
  103. package/dist/packages/plugin-renderer-graphics/lib/component.d.ts +8 -0
  104. package/dist/packages/plugin-renderer-graphics/lib/component.d.ts.map +1 -0
  105. package/dist/packages/plugin-renderer-graphics/lib/index.d.ts +4 -0
  106. package/dist/packages/plugin-renderer-graphics/lib/index.d.ts.map +1 -0
  107. package/dist/packages/plugin-renderer-graphics/lib/system.d.ts +12 -0
  108. package/dist/packages/plugin-renderer-graphics/lib/system.d.ts.map +1 -0
  109. package/dist/packages/plugin-renderer-img/lib/component.d.ts +10 -0
  110. package/dist/packages/plugin-renderer-img/lib/component.d.ts.map +1 -0
  111. package/dist/packages/plugin-renderer-img/lib/index.d.ts +4 -0
  112. package/dist/packages/plugin-renderer-img/lib/index.d.ts.map +1 -0
  113. package/dist/packages/plugin-renderer-img/lib/system.d.ts +18 -0
  114. package/dist/packages/plugin-renderer-img/lib/system.d.ts.map +1 -0
  115. package/dist/packages/plugin-renderer-lottie/lib/Lottie.d.ts +27 -0
  116. package/dist/packages/plugin-renderer-lottie/lib/Lottie.d.ts.map +1 -0
  117. package/dist/packages/plugin-renderer-lottie/lib/LottieSystem.d.ts +18 -0
  118. package/dist/packages/plugin-renderer-lottie/lib/LottieSystem.d.ts.map +1 -0
  119. package/dist/packages/plugin-renderer-lottie/lib/index.d.ts +3 -0
  120. package/dist/packages/plugin-renderer-lottie/lib/index.d.ts.map +1 -0
  121. package/dist/packages/plugin-renderer-lottie/lib/lottie-pixi.d.ts +180 -0
  122. package/dist/packages/plugin-renderer-lottie/lib/lottie-pixi.d.ts.map +1 -0
  123. package/dist/packages/plugin-renderer-lottie/lib/types.d.ts +18 -0
  124. package/dist/packages/plugin-renderer-lottie/lib/types.d.ts.map +1 -0
  125. package/dist/packages/plugin-renderer-lottie/lib/utils.d.ts +2 -0
  126. package/dist/packages/plugin-renderer-lottie/lib/utils.d.ts.map +1 -0
  127. package/dist/packages/plugin-renderer-mask/lib/component.d.ts +33 -0
  128. package/dist/packages/plugin-renderer-mask/lib/component.d.ts.map +1 -0
  129. package/dist/packages/plugin-renderer-mask/lib/index.d.ts +4 -0
  130. package/dist/packages/plugin-renderer-mask/lib/index.d.ts.map +1 -0
  131. package/dist/packages/plugin-renderer-mask/lib/system.d.ts +31 -0
  132. package/dist/packages/plugin-renderer-mask/lib/system.d.ts.map +1 -0
  133. package/dist/packages/plugin-renderer-nine-patch/lib/component.d.ts +22 -0
  134. package/dist/packages/plugin-renderer-nine-patch/lib/component.d.ts.map +1 -0
  135. package/dist/packages/plugin-renderer-nine-patch/lib/index.d.ts +4 -0
  136. package/dist/packages/plugin-renderer-nine-patch/lib/index.d.ts.map +1 -0
  137. package/dist/packages/plugin-renderer-nine-patch/lib/system.d.ts +19 -0
  138. package/dist/packages/plugin-renderer-nine-patch/lib/system.d.ts.map +1 -0
  139. package/dist/packages/plugin-renderer-render/lib/component.d.ts +17 -0
  140. package/dist/packages/plugin-renderer-render/lib/component.d.ts.map +1 -0
  141. package/dist/packages/plugin-renderer-render/lib/index.d.ts +4 -0
  142. package/dist/packages/plugin-renderer-render/lib/index.d.ts.map +1 -0
  143. package/dist/packages/plugin-renderer-render/lib/system.d.ts +17 -0
  144. package/dist/packages/plugin-renderer-render/lib/system.d.ts.map +1 -0
  145. package/dist/packages/plugin-renderer-spine/lib/Spine.d.ts +4 -0
  146. package/dist/packages/plugin-renderer-spine/lib/Spine.d.ts.map +1 -0
  147. package/dist/packages/plugin-renderer-spine/lib/SpineSystem.d.ts +5 -0
  148. package/dist/packages/plugin-renderer-spine/lib/SpineSystem.d.ts.map +1 -0
  149. package/dist/packages/plugin-renderer-spine/lib/index.d.ts +4 -0
  150. package/dist/packages/plugin-renderer-spine/lib/index.d.ts.map +1 -0
  151. package/dist/packages/plugin-renderer-sprite/lib/component.d.ts +12 -0
  152. package/dist/packages/plugin-renderer-sprite/lib/component.d.ts.map +1 -0
  153. package/dist/packages/plugin-renderer-sprite/lib/index.d.ts +4 -0
  154. package/dist/packages/plugin-renderer-sprite/lib/index.d.ts.map +1 -0
  155. package/dist/packages/plugin-renderer-sprite/lib/system.d.ts +17 -0
  156. package/dist/packages/plugin-renderer-sprite/lib/system.d.ts.map +1 -0
  157. package/dist/packages/plugin-renderer-sprite-animation/lib/component.d.ts +31 -0
  158. package/dist/packages/plugin-renderer-sprite-animation/lib/component.d.ts.map +1 -0
  159. package/dist/packages/plugin-renderer-sprite-animation/lib/index.d.ts +4 -0
  160. package/dist/packages/plugin-renderer-sprite-animation/lib/index.d.ts.map +1 -0
  161. package/dist/packages/plugin-renderer-sprite-animation/lib/system.d.ts +31 -0
  162. package/dist/packages/plugin-renderer-sprite-animation/lib/system.d.ts.map +1 -0
  163. package/dist/packages/plugin-renderer-test/lib/component.d.ts +20 -0
  164. package/dist/packages/plugin-renderer-test/lib/component.d.ts.map +1 -0
  165. package/dist/packages/plugin-renderer-test/lib/index.d.ts +4 -0
  166. package/dist/packages/plugin-renderer-test/lib/index.d.ts.map +1 -0
  167. package/dist/packages/plugin-renderer-test/lib/system.d.ts +21 -0
  168. package/dist/packages/plugin-renderer-test/lib/system.d.ts.map +1 -0
  169. package/dist/packages/plugin-renderer-test/lib/system2.d.ts +12 -0
  170. package/dist/packages/plugin-renderer-test/lib/system2.d.ts.map +1 -0
  171. package/dist/packages/plugin-renderer-text/lib/component.d.ts +43 -0
  172. package/dist/packages/plugin-renderer-text/lib/component.d.ts.map +1 -0
  173. package/dist/packages/plugin-renderer-text/lib/index.d.ts +4 -0
  174. package/dist/packages/plugin-renderer-text/lib/index.d.ts.map +1 -0
  175. package/dist/packages/plugin-renderer-text/lib/system.d.ts +22 -0
  176. package/dist/packages/plugin-renderer-text/lib/system.d.ts.map +1 -0
  177. package/dist/packages/plugin-renderer-tiling-sprite/lib/component.d.ts +20 -0
  178. package/dist/packages/plugin-renderer-tiling-sprite/lib/component.d.ts.map +1 -0
  179. package/dist/packages/plugin-renderer-tiling-sprite/lib/index.d.ts +4 -0
  180. package/dist/packages/plugin-renderer-tiling-sprite/lib/index.d.ts.map +1 -0
  181. package/dist/packages/plugin-renderer-tiling-sprite/lib/system.d.ts +18 -0
  182. package/dist/packages/plugin-renderer-tiling-sprite/lib/system.d.ts.map +1 -0
  183. package/dist/packages/plugin-sound/lib/Sound.d.ts +44 -0
  184. package/dist/packages/plugin-sound/lib/Sound.d.ts.map +1 -0
  185. package/dist/packages/plugin-sound/lib/SoundSystem.d.ts +37 -0
  186. package/dist/packages/plugin-sound/lib/SoundSystem.d.ts.map +1 -0
  187. package/dist/packages/plugin-sound/lib/index.d.ts +3 -0
  188. package/dist/packages/plugin-sound/lib/index.d.ts.map +1 -0
  189. package/dist/packages/plugin-stats/lib/Stats.d.ts +19 -0
  190. package/dist/packages/plugin-stats/lib/Stats.d.ts.map +1 -0
  191. package/dist/packages/plugin-stats/lib/StatsComponent.d.ts +7 -0
  192. package/dist/packages/plugin-stats/lib/StatsComponent.d.ts.map +1 -0
  193. package/dist/packages/plugin-stats/lib/StatsSystem.d.ts +28 -0
  194. package/dist/packages/plugin-stats/lib/StatsSystem.d.ts.map +1 -0
  195. package/dist/packages/plugin-stats/lib/hooks/BaseHooks.d.ts +18 -0
  196. package/dist/packages/plugin-stats/lib/hooks/BaseHooks.d.ts.map +1 -0
  197. package/dist/packages/plugin-stats/lib/hooks/GLHook.d.ts +11 -0
  198. package/dist/packages/plugin-stats/lib/hooks/GLHook.d.ts.map +1 -0
  199. package/dist/packages/plugin-stats/lib/hooks/TextureHook.d.ts +16 -0
  200. package/dist/packages/plugin-stats/lib/hooks/TextureHook.d.ts.map +1 -0
  201. package/dist/packages/plugin-stats/lib/index.d.ts +9 -0
  202. package/dist/packages/plugin-stats/lib/index.d.ts.map +1 -0
  203. package/dist/packages/plugin-transition/lib/Animation.d.ts +38 -0
  204. package/dist/packages/plugin-transition/lib/Animation.d.ts.map +1 -0
  205. package/dist/{plugin-transition.d.ts → packages/plugin-transition/lib/component.d.ts} +7 -16
  206. package/dist/packages/plugin-transition/lib/component.d.ts.map +1 -0
  207. package/dist/packages/plugin-transition/lib/index.d.ts +3 -0
  208. package/dist/packages/plugin-transition/lib/index.d.ts.map +1 -0
  209. package/dist/packages/plugin-transition/lib/system.d.ts +6 -0
  210. package/dist/packages/plugin-transition/lib/system.d.ts.map +1 -0
  211. package/dist/packages/renderer-adapter/lib/Application.d.ts +3 -0
  212. package/dist/packages/renderer-adapter/lib/Application.d.ts.map +1 -0
  213. package/dist/packages/renderer-adapter/lib/Container.d.ts +5 -0
  214. package/dist/packages/renderer-adapter/lib/Container.d.ts.map +1 -0
  215. package/dist/packages/renderer-adapter/lib/Graphics.d.ts +5 -0
  216. package/dist/packages/renderer-adapter/lib/Graphics.d.ts.map +1 -0
  217. package/dist/packages/renderer-adapter/lib/NinePatch.d.ts +5 -0
  218. package/dist/packages/renderer-adapter/lib/NinePatch.d.ts.map +1 -0
  219. package/dist/packages/renderer-adapter/lib/Sprite.d.ts +9 -0
  220. package/dist/packages/renderer-adapter/lib/Sprite.d.ts.map +1 -0
  221. package/dist/packages/renderer-adapter/lib/SpriteAnimation.d.ts +14 -0
  222. package/dist/packages/renderer-adapter/lib/SpriteAnimation.d.ts.map +1 -0
  223. package/dist/packages/renderer-adapter/lib/Text.d.ts +6 -0
  224. package/dist/packages/renderer-adapter/lib/Text.d.ts.map +1 -0
  225. package/dist/packages/renderer-adapter/lib/TilingSprite.d.ts +9 -0
  226. package/dist/packages/renderer-adapter/lib/TilingSprite.d.ts.map +1 -0
  227. package/dist/packages/renderer-adapter/lib/index.d.ts +9 -0
  228. package/dist/packages/renderer-adapter/lib/index.d.ts.map +1 -0
  229. package/dist/packages/spine-base/lib/Spine.d.ts +32 -0
  230. package/dist/packages/spine-base/lib/Spine.d.ts.map +1 -0
  231. package/dist/packages/spine-base/lib/SpineData.d.ts +5 -0
  232. package/dist/packages/spine-base/lib/SpineData.d.ts.map +1 -0
  233. package/dist/packages/spine-base/lib/SpineSystem.d.ts +20 -0
  234. package/dist/packages/spine-base/lib/SpineSystem.d.ts.map +1 -0
  235. package/dist/packages/spine-base/lib/TexCache.d.ts +10 -0
  236. package/dist/packages/spine-base/lib/TexCache.d.ts.map +1 -0
  237. package/dist/packages/spine-base/lib/index.d.ts +4 -0
  238. package/dist/packages/spine-base/lib/index.d.ts.map +1 -0
  239. package/dist/plugin-transition.cjs.prod.js +1 -1
  240. package/package.json +2 -2
@@ -1,40 +1,31 @@
1
- this.EVA = this.EVA || {};
2
- this.EVA.plugin = this.EVA.plugin || {};
3
-
4
- this.EVA.plugin.transition = function (exports, eva_js) {
1
+ window.EVA = window.EVA || {};
2
+ window.EVA.plugin = window.EVA.plugin || {};
3
+ var _EVA_IIFE_transition = function (exports, eva_js) {
5
4
  'use strict';
6
-
7
- var _extendStatics = function extendStatics(d, b) {
8
- _extendStatics = Object.setPrototypeOf || {
5
+ var extendStatics = function (d, b) {
6
+ extendStatics = Object.setPrototypeOf || {
9
7
  __proto__: []
10
8
  } instanceof Array && function (d, b) {
11
9
  d.__proto__ = b;
12
10
  } || function (d, b) {
13
- for (var p in b) {
14
- if (b.hasOwnProperty(p)) d[p] = b[p];
15
- }
11
+ for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p];
16
12
  };
17
-
18
- return _extendStatics(d, b);
13
+ return extendStatics(d, b);
19
14
  };
20
-
21
15
  function __extends(d, b) {
22
- _extendStatics(d, b);
23
-
16
+ extendStatics(d, b);
24
17
  function __() {
25
18
  this.constructor = d;
26
19
  }
27
-
28
20
  d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __());
29
21
  }
30
-
31
22
  function __values(o) {
32
23
  var s = typeof Symbol === "function" && Symbol.iterator,
33
- m = s && o[s],
34
- i = 0;
24
+ m = s && o[s],
25
+ i = 0;
35
26
  if (m) return m.call(o);
36
27
  if (o && typeof o.length === "number") return {
37
- next: function next() {
28
+ next: function () {
38
29
  if (o && i >= o.length) o = void 0;
39
30
  return {
40
31
  value: o && o[i++],
@@ -44,187 +35,168 @@ this.EVA.plugin.transition = function (exports, eva_js) {
44
35
  };
45
36
  throw new TypeError(s ? "Object is not iterable." : "Symbol.iterator is not defined.");
46
37
  }
47
-
48
38
  var Easing = {
49
39
  Linear: {
50
- None: function None(amount) {
40
+ None: function (amount) {
51
41
  return amount;
52
42
  }
53
43
  },
54
44
  Quadratic: {
55
- In: function In(amount) {
45
+ In: function (amount) {
56
46
  return amount * amount;
57
47
  },
58
- Out: function Out(amount) {
48
+ Out: function (amount) {
59
49
  return amount * (2 - amount);
60
50
  },
61
- InOut: function InOut(amount) {
51
+ InOut: function (amount) {
62
52
  if ((amount *= 2) < 1) {
63
53
  return 0.5 * amount * amount;
64
54
  }
65
-
66
55
  return -0.5 * (--amount * (amount - 2) - 1);
67
56
  }
68
57
  },
69
58
  Cubic: {
70
- In: function In(amount) {
59
+ In: function (amount) {
71
60
  return amount * amount * amount;
72
61
  },
73
- Out: function Out(amount) {
62
+ Out: function (amount) {
74
63
  return --amount * amount * amount + 1;
75
64
  },
76
- InOut: function InOut(amount) {
65
+ InOut: function (amount) {
77
66
  if ((amount *= 2) < 1) {
78
67
  return 0.5 * amount * amount * amount;
79
68
  }
80
-
81
69
  return 0.5 * ((amount -= 2) * amount * amount + 2);
82
70
  }
83
71
  },
84
72
  Quartic: {
85
- In: function In(amount) {
73
+ In: function (amount) {
86
74
  return amount * amount * amount * amount;
87
75
  },
88
- Out: function Out(amount) {
76
+ Out: function (amount) {
89
77
  return 1 - --amount * amount * amount * amount;
90
78
  },
91
- InOut: function InOut(amount) {
79
+ InOut: function (amount) {
92
80
  if ((amount *= 2) < 1) {
93
81
  return 0.5 * amount * amount * amount * amount;
94
82
  }
95
-
96
83
  return -0.5 * ((amount -= 2) * amount * amount * amount - 2);
97
84
  }
98
85
  },
99
86
  Quintic: {
100
- In: function In(amount) {
87
+ In: function (amount) {
101
88
  return amount * amount * amount * amount * amount;
102
89
  },
103
- Out: function Out(amount) {
90
+ Out: function (amount) {
104
91
  return --amount * amount * amount * amount * amount + 1;
105
92
  },
106
- InOut: function InOut(amount) {
93
+ InOut: function (amount) {
107
94
  if ((amount *= 2) < 1) {
108
95
  return 0.5 * amount * amount * amount * amount * amount;
109
96
  }
110
-
111
97
  return 0.5 * ((amount -= 2) * amount * amount * amount * amount + 2);
112
98
  }
113
99
  },
114
100
  Sinusoidal: {
115
- In: function In(amount) {
101
+ In: function (amount) {
116
102
  return 1 - Math.cos(amount * Math.PI / 2);
117
103
  },
118
- Out: function Out(amount) {
104
+ Out: function (amount) {
119
105
  return Math.sin(amount * Math.PI / 2);
120
106
  },
121
- InOut: function InOut(amount) {
107
+ InOut: function (amount) {
122
108
  return 0.5 * (1 - Math.cos(Math.PI * amount));
123
109
  }
124
110
  },
125
111
  Exponential: {
126
- In: function In(amount) {
112
+ In: function (amount) {
127
113
  return amount === 0 ? 0 : Math.pow(1024, amount - 1);
128
114
  },
129
- Out: function Out(amount) {
115
+ Out: function (amount) {
130
116
  return amount === 1 ? 1 : 1 - Math.pow(2, -10 * amount);
131
117
  },
132
- InOut: function InOut(amount) {
118
+ InOut: function (amount) {
133
119
  if (amount === 0) {
134
120
  return 0;
135
121
  }
136
-
137
122
  if (amount === 1) {
138
123
  return 1;
139
124
  }
140
-
141
125
  if ((amount *= 2) < 1) {
142
126
  return 0.5 * Math.pow(1024, amount - 1);
143
127
  }
144
-
145
128
  return 0.5 * (-Math.pow(2, -10 * (amount - 1)) + 2);
146
129
  }
147
130
  },
148
131
  Circular: {
149
- In: function In(amount) {
132
+ In: function (amount) {
150
133
  return 1 - Math.sqrt(1 - amount * amount);
151
134
  },
152
- Out: function Out(amount) {
135
+ Out: function (amount) {
153
136
  return Math.sqrt(1 - --amount * amount);
154
137
  },
155
- InOut: function InOut(amount) {
138
+ InOut: function (amount) {
156
139
  if ((amount *= 2) < 1) {
157
140
  return -0.5 * (Math.sqrt(1 - amount * amount) - 1);
158
141
  }
159
-
160
142
  return 0.5 * (Math.sqrt(1 - (amount -= 2) * amount) + 1);
161
143
  }
162
144
  },
163
145
  Elastic: {
164
- In: function In(amount) {
146
+ In: function (amount) {
165
147
  if (amount === 0) {
166
148
  return 0;
167
149
  }
168
-
169
150
  if (amount === 1) {
170
151
  return 1;
171
152
  }
172
-
173
153
  return -Math.pow(2, 10 * (amount - 1)) * Math.sin((amount - 1.1) * 5 * Math.PI);
174
154
  },
175
- Out: function Out(amount) {
155
+ Out: function (amount) {
176
156
  if (amount === 0) {
177
157
  return 0;
178
158
  }
179
-
180
159
  if (amount === 1) {
181
160
  return 1;
182
161
  }
183
-
184
162
  return Math.pow(2, -10 * amount) * Math.sin((amount - 0.1) * 5 * Math.PI) + 1;
185
163
  },
186
- InOut: function InOut(amount) {
164
+ InOut: function (amount) {
187
165
  if (amount === 0) {
188
166
  return 0;
189
167
  }
190
-
191
168
  if (amount === 1) {
192
169
  return 1;
193
170
  }
194
-
195
171
  amount *= 2;
196
-
197
172
  if (amount < 1) {
198
173
  return -0.5 * Math.pow(2, 10 * (amount - 1)) * Math.sin((amount - 1.1) * 5 * Math.PI);
199
174
  }
200
-
201
175
  return 0.5 * Math.pow(2, -10 * (amount - 1)) * Math.sin((amount - 1.1) * 5 * Math.PI) + 1;
202
176
  }
203
177
  },
204
178
  Back: {
205
- In: function In(amount) {
179
+ In: function (amount) {
206
180
  var s = 1.70158;
207
181
  return amount * amount * ((s + 1) * amount - s);
208
182
  },
209
- Out: function Out(amount) {
183
+ Out: function (amount) {
210
184
  var s = 1.70158;
211
185
  return --amount * amount * ((s + 1) * amount + s) + 1;
212
186
  },
213
- InOut: function InOut(amount) {
187
+ InOut: function (amount) {
214
188
  var s = 1.70158 * 1.525;
215
-
216
189
  if ((amount *= 2) < 1) {
217
190
  return 0.5 * (amount * amount * ((s + 1) * amount - s));
218
191
  }
219
-
220
192
  return 0.5 * ((amount -= 2) * amount * ((s + 1) * amount + s) + 2);
221
193
  }
222
194
  },
223
195
  Bounce: {
224
- In: function In(amount) {
196
+ In: function (amount) {
225
197
  return 1 - Easing.Bounce.Out(1 - amount);
226
198
  },
227
- Out: function Out(amount) {
199
+ Out: function (amount) {
228
200
  if (amount < 1 / 2.75) {
229
201
  return 7.5625 * amount * amount;
230
202
  } else if (amount < 2 / 2.75) {
@@ -235,19 +207,17 @@ this.EVA.plugin.transition = function (exports, eva_js) {
235
207
  return 7.5625 * (amount -= 2.625 / 2.75) * amount + 0.984375;
236
208
  }
237
209
  },
238
- InOut: function InOut(amount) {
210
+ InOut: function (amount) {
239
211
  if (amount < 0.5) {
240
212
  return Easing.Bounce.In(amount * 2) * 0.5;
241
213
  }
242
-
243
214
  return Easing.Bounce.Out(amount * 2 - 1) * 0.5 + 0.5;
244
215
  }
245
216
  }
246
217
  };
247
218
  var now;
248
-
249
219
  if (typeof self === 'undefined' && typeof process !== 'undefined' && process.hrtime) {
250
- now = function now() {
220
+ now = function () {
251
221
  var time = process.hrtime();
252
222
  return time[0] * 1000 + time[1] / 1000000;
253
223
  };
@@ -256,135 +226,108 @@ this.EVA.plugin.transition = function (exports, eva_js) {
256
226
  } else if (Date.now !== undefined) {
257
227
  now = Date.now;
258
228
  } else {
259
- now = function now() {
229
+ now = function () {
260
230
  return new Date().getTime();
261
231
  };
262
232
  }
263
-
264
233
  var now$1 = now;
265
-
266
234
  var Group = function () {
267
235
  function Group() {
268
236
  this._tweens = {};
269
237
  this._tweensAddedDuringUpdate = {};
270
238
  }
271
-
272
239
  Group.prototype.getAll = function () {
273
240
  var _this = this;
274
-
275
241
  return Object.keys(this._tweens).map(function (tweenId) {
276
242
  return _this._tweens[tweenId];
277
243
  });
278
244
  };
279
-
280
245
  Group.prototype.removeAll = function () {
281
246
  this._tweens = {};
282
247
  };
283
-
284
248
  Group.prototype.add = function (tween) {
285
249
  this._tweens[tween.getId()] = tween;
286
250
  this._tweensAddedDuringUpdate[tween.getId()] = tween;
287
251
  };
288
-
289
252
  Group.prototype.remove = function (tween) {
290
253
  delete this._tweens[tween.getId()];
291
254
  delete this._tweensAddedDuringUpdate[tween.getId()];
292
255
  };
293
-
294
256
  Group.prototype.update = function (time, preserve) {
295
257
  if (time === void 0) {
296
258
  time = now$1();
297
259
  }
298
-
299
260
  if (preserve === void 0) {
300
261
  preserve = false;
301
262
  }
302
-
303
263
  var tweenIds = Object.keys(this._tweens);
304
-
305
264
  if (tweenIds.length === 0) {
306
265
  return false;
307
266
  }
308
-
309
267
  while (tweenIds.length > 0) {
310
268
  this._tweensAddedDuringUpdate = {};
311
-
312
269
  for (var i = 0; i < tweenIds.length; i++) {
313
270
  var tween = this._tweens[tweenIds[i]];
314
271
  var autoStart = !preserve;
315
-
316
272
  if (tween && tween.update(time, autoStart) === false && !preserve) {
317
273
  delete this._tweens[tweenIds[i]];
318
274
  }
319
275
  }
320
-
321
276
  tweenIds = Object.keys(this._tweensAddedDuringUpdate);
322
277
  }
323
-
324
278
  return true;
325
279
  };
326
-
327
280
  return Group;
328
281
  }();
329
-
330
282
  var Interpolation = {
331
- Linear: function Linear(v, k) {
283
+ Linear: function (v, k) {
332
284
  var m = v.length - 1;
333
285
  var f = m * k;
334
286
  var i = Math.floor(f);
335
287
  var fn = Interpolation.Utils.Linear;
336
-
337
288
  if (k < 0) {
338
289
  return fn(v[0], v[1], f);
339
290
  }
340
-
341
291
  if (k > 1) {
342
292
  return fn(v[m], v[m - 1], m - f);
343
293
  }
344
-
345
294
  return fn(v[i], v[i + 1 > m ? m : i + 1], f - i);
346
295
  },
347
- Bezier: function Bezier(v, k) {
296
+ Bezier: function (v, k) {
348
297
  var b = 0;
349
298
  var n = v.length - 1;
350
299
  var pw = Math.pow;
351
300
  var bn = Interpolation.Utils.Bernstein;
352
-
353
301
  for (var i = 0; i <= n; i++) {
354
302
  b += pw(1 - k, n - i) * pw(k, i) * v[i] * bn(n, i);
355
303
  }
356
-
357
304
  return b;
358
305
  },
359
- CatmullRom: function CatmullRom(v, k) {
306
+ CatmullRom: function (v, k) {
360
307
  var m = v.length - 1;
361
308
  var f = m * k;
362
309
  var i = Math.floor(f);
363
310
  var fn = Interpolation.Utils.CatmullRom;
364
-
365
311
  if (v[0] === v[m]) {
366
312
  if (k < 0) {
367
313
  i = Math.floor(f = m * (1 + k));
368
314
  }
369
-
370
315
  return fn(v[(i - 1 + m) % m], v[i], v[(i + 1) % m], v[(i + 2) % m], f - i);
371
316
  } else {
372
317
  if (k < 0) {
373
318
  return v[0] - (fn(v[0], v[0], v[1], v[1], -f) - v[0]);
374
319
  }
375
-
376
320
  if (k > 1) {
377
321
  return v[m] - (fn(v[m], v[m], v[m - 1], v[m - 1], f - m) - v[m]);
378
322
  }
379
-
380
323
  return fn(v[i ? i - 1 : 0], v[i], v[m < i + 1 ? m : i + 1], v[m < i + 2 ? m : i + 2], f - i);
381
324
  }
382
325
  },
383
326
  Utils: {
384
- Linear: function Linear(p0, p1, t) {
327
+ Linear: function (p0, p1, t) {
385
328
  return (p1 - p0) * t + p0;
386
329
  },
387
- Bernstein: function Bernstein(n, i) {
330
+ Bernstein: function (n, i) {
388
331
  var fc = Interpolation.Utils.Factorial;
389
332
  return fc(n) / fc(i) / fc(n - i);
390
333
  },
@@ -392,20 +335,17 @@ this.EVA.plugin.transition = function (exports, eva_js) {
392
335
  var a = [1];
393
336
  return function (n) {
394
337
  var s = 1;
395
-
396
338
  if (a[n]) {
397
339
  return a[n];
398
340
  }
399
-
400
341
  for (var i = n; i > 1; i--) {
401
342
  s *= i;
402
343
  }
403
-
404
344
  a[n] = s;
405
345
  return s;
406
346
  };
407
347
  }(),
408
- CatmullRom: function CatmullRom(p0, p1, p2, p3, t) {
348
+ CatmullRom: function (p0, p1, p2, p3, t) {
409
349
  var v0 = (p2 - p0) * 0.5;
410
350
  var v1 = (p3 - p1) * 0.5;
411
351
  var t2 = t * t;
@@ -414,26 +354,20 @@ this.EVA.plugin.transition = function (exports, eva_js) {
414
354
  }
415
355
  }
416
356
  };
417
-
418
357
  var Sequence = function () {
419
358
  function Sequence() {}
420
-
421
359
  Sequence.nextId = function () {
422
360
  return Sequence._nextId++;
423
361
  };
424
-
425
362
  Sequence._nextId = 0;
426
363
  return Sequence;
427
364
  }();
428
-
429
365
  var mainGroup = new Group();
430
-
431
366
  var Tween = function () {
432
367
  function Tween(_object, _group) {
433
368
  if (_group === void 0) {
434
369
  _group = mainGroup;
435
370
  }
436
-
437
371
  this._object = _object;
438
372
  this._group = _group;
439
373
  this._isPaused = false;
@@ -457,105 +391,79 @@ this.EVA.plugin.transition = function (exports, eva_js) {
457
391
  this._isChainStopped = false;
458
392
  this._goToEnd = false;
459
393
  }
460
-
461
394
  Tween.prototype.getId = function () {
462
395
  return this._id;
463
396
  };
464
-
465
397
  Tween.prototype.isPlaying = function () {
466
398
  return this._isPlaying;
467
399
  };
468
-
469
400
  Tween.prototype.isPaused = function () {
470
401
  return this._isPaused;
471
402
  };
472
-
473
403
  Tween.prototype.to = function (properties, duration) {
474
404
  this._valuesEnd = Object.create(properties);
475
-
476
405
  if (duration !== undefined) {
477
406
  this._duration = duration;
478
407
  }
479
-
480
408
  return this;
481
409
  };
482
-
483
410
  Tween.prototype.duration = function (d) {
484
411
  this._duration = d;
485
412
  return this;
486
413
  };
487
-
488
414
  Tween.prototype.start = function (time) {
489
415
  if (this._isPlaying) {
490
416
  return this;
491
417
  }
492
-
493
418
  this._group && this._group.add(this);
494
419
  this._repeat = this._initialRepeat;
495
-
496
420
  if (this._reversed) {
497
421
  this._reversed = false;
498
-
499
422
  for (var property in this._valuesStartRepeat) {
500
423
  this._swapEndStartRepeatValues(property);
501
-
502
424
  this._valuesStart[property] = this._valuesStartRepeat[property];
503
425
  }
504
426
  }
505
-
506
427
  this._isPlaying = true;
507
428
  this._isPaused = false;
508
429
  this._onStartCallbackFired = false;
509
430
  this._isChainStopped = false;
510
431
  this._startTime = time !== undefined ? typeof time === 'string' ? now$1() + parseFloat(time) : time : now$1();
511
432
  this._startTime += this._delayTime;
512
-
513
433
  this._setupProperties(this._object, this._valuesStart, this._valuesEnd, this._valuesStartRepeat);
514
-
515
434
  return this;
516
435
  };
517
-
518
436
  Tween.prototype._setupProperties = function (_object, _valuesStart, _valuesEnd, _valuesStartRepeat) {
519
437
  for (var property in _valuesEnd) {
520
438
  var startValue = _object[property];
521
439
  var startValueIsArray = Array.isArray(startValue);
522
440
  var propType = startValueIsArray ? 'array' : typeof startValue;
523
441
  var isInterpolationList = !startValueIsArray && Array.isArray(_valuesEnd[property]);
524
-
525
442
  if (propType === 'undefined' || propType === 'function') {
526
443
  continue;
527
444
  }
528
-
529
445
  if (isInterpolationList) {
530
446
  var endValues = _valuesEnd[property];
531
-
532
447
  if (endValues.length === 0) {
533
448
  continue;
534
449
  }
535
-
536
450
  endValues = endValues.map(this._handleRelativeValue.bind(this, startValue));
537
451
  _valuesEnd[property] = [startValue].concat(endValues);
538
452
  }
539
-
540
453
  if ((propType === 'object' || startValueIsArray) && startValue && !isInterpolationList) {
541
454
  _valuesStart[property] = startValueIsArray ? [] : {};
542
-
543
455
  for (var prop in startValue) {
544
456
  _valuesStart[property][prop] = startValue[prop];
545
457
  }
546
-
547
458
  _valuesStartRepeat[property] = startValueIsArray ? [] : {};
548
-
549
459
  this._setupProperties(startValue, _valuesStart[property], _valuesEnd[property], _valuesStartRepeat[property]);
550
460
  } else {
551
461
  if (typeof _valuesStart[property] === 'undefined') {
552
462
  _valuesStart[property] = startValue;
553
463
  }
554
-
555
464
  if (!startValueIsArray) {
556
465
  _valuesStart[property] *= 1.0;
557
466
  }
558
-
559
467
  if (isInterpolationList) {
560
468
  _valuesStartRepeat[property] = _valuesEnd[property].slice().reverse();
561
469
  } else {
@@ -564,293 +472,231 @@ this.EVA.plugin.transition = function (exports, eva_js) {
564
472
  }
565
473
  }
566
474
  };
567
-
568
475
  Tween.prototype.stop = function () {
569
476
  if (!this._isChainStopped) {
570
477
  this._isChainStopped = true;
571
478
  this.stopChainedTweens();
572
479
  }
573
-
574
480
  if (!this._isPlaying) {
575
481
  return this;
576
482
  }
577
-
578
483
  this._group && this._group.remove(this);
579
484
  this._isPlaying = false;
580
485
  this._isPaused = false;
581
-
582
486
  if (this._onStopCallback) {
583
487
  this._onStopCallback(this._object);
584
488
  }
585
-
586
489
  return this;
587
490
  };
588
-
589
491
  Tween.prototype.end = function () {
590
492
  this._goToEnd = true;
591
493
  this.update(Infinity);
592
494
  return this;
593
495
  };
594
-
595
496
  Tween.prototype.pause = function (time) {
596
497
  if (time === void 0) {
597
498
  time = now$1();
598
499
  }
599
-
600
500
  if (this._isPaused || !this._isPlaying) {
601
501
  return this;
602
502
  }
603
-
604
503
  this._isPaused = true;
605
504
  this._pauseStart = time;
606
505
  this._group && this._group.remove(this);
607
506
  return this;
608
507
  };
609
-
610
508
  Tween.prototype.resume = function (time) {
611
509
  if (time === void 0) {
612
510
  time = now$1();
613
511
  }
614
-
615
512
  if (!this._isPaused || !this._isPlaying) {
616
513
  return this;
617
514
  }
618
-
619
515
  this._isPaused = false;
620
516
  this._startTime += time - this._pauseStart;
621
517
  this._pauseStart = 0;
622
518
  this._group && this._group.add(this);
623
519
  return this;
624
520
  };
625
-
626
521
  Tween.prototype.stopChainedTweens = function () {
627
522
  for (var i = 0, numChainedTweens = this._chainedTweens.length; i < numChainedTweens; i++) {
628
523
  this._chainedTweens[i].stop();
629
524
  }
630
-
631
525
  return this;
632
526
  };
633
-
634
527
  Tween.prototype.group = function (group) {
635
528
  this._group = group;
636
529
  return this;
637
530
  };
638
-
639
531
  Tween.prototype.delay = function (amount) {
640
532
  this._delayTime = amount;
641
533
  return this;
642
534
  };
643
-
644
535
  Tween.prototype.repeat = function (times) {
645
536
  this._initialRepeat = times;
646
537
  this._repeat = times;
647
538
  return this;
648
539
  };
649
-
650
540
  Tween.prototype.repeatDelay = function (amount) {
651
541
  this._repeatDelayTime = amount;
652
542
  return this;
653
543
  };
654
-
655
544
  Tween.prototype.yoyo = function (yoyo) {
656
545
  this._yoyo = yoyo;
657
546
  return this;
658
547
  };
659
-
660
548
  Tween.prototype.easing = function (easingFunction) {
661
549
  this._easingFunction = easingFunction;
662
550
  return this;
663
551
  };
664
-
665
552
  Tween.prototype.interpolation = function (interpolationFunction) {
666
553
  this._interpolationFunction = interpolationFunction;
667
554
  return this;
668
555
  };
669
-
670
556
  Tween.prototype.chain = function () {
671
557
  var tweens = [];
672
-
673
558
  for (var _i = 0; _i < arguments.length; _i++) {
674
559
  tweens[_i] = arguments[_i];
675
560
  }
676
-
677
561
  this._chainedTweens = tweens;
678
562
  return this;
679
563
  };
680
-
681
564
  Tween.prototype.onStart = function (callback) {
682
565
  this._onStartCallback = callback;
683
566
  return this;
684
567
  };
685
-
686
568
  Tween.prototype.onUpdate = function (callback) {
687
569
  this._onUpdateCallback = callback;
688
570
  return this;
689
571
  };
690
-
691
572
  Tween.prototype.onRepeat = function (callback) {
692
573
  this._onRepeatCallback = callback;
693
574
  return this;
694
575
  };
695
-
696
576
  Tween.prototype.onComplete = function (callback) {
697
577
  this._onCompleteCallback = callback;
698
578
  return this;
699
579
  };
700
-
701
580
  Tween.prototype.onStop = function (callback) {
702
581
  this._onStopCallback = callback;
703
582
  return this;
704
583
  };
705
-
706
584
  Tween.prototype.update = function (time, autoStart) {
707
585
  if (time === void 0) {
708
586
  time = now$1();
709
587
  }
710
-
711
588
  if (autoStart === void 0) {
712
589
  autoStart = true;
713
590
  }
714
-
715
591
  if (this._isPaused) return true;
716
592
  var property;
717
593
  var elapsed;
718
594
  var endTime = this._startTime + this._duration;
719
-
720
595
  if (!this._goToEnd && !this._isPlaying) {
721
596
  if (time > endTime) return false;
722
597
  if (autoStart) this.start(time);
723
598
  }
724
-
725
599
  this._goToEnd = false;
726
-
727
600
  if (time < this._startTime) {
728
601
  return true;
729
602
  }
730
-
731
603
  if (this._onStartCallbackFired === false) {
732
604
  if (this._onStartCallback) {
733
605
  this._onStartCallback(this._object);
734
606
  }
735
-
736
607
  this._onStartCallbackFired = true;
737
608
  }
738
-
739
609
  elapsed = (time - this._startTime) / this._duration;
740
610
  elapsed = this._duration === 0 || elapsed > 1 ? 1 : elapsed;
741
-
742
611
  var value = this._easingFunction(elapsed);
743
-
744
612
  this._updateProperties(this._object, this._valuesStart, this._valuesEnd, value);
745
-
746
613
  if (this._onUpdateCallback) {
747
614
  this._onUpdateCallback(this._object, elapsed);
748
615
  }
749
-
750
616
  if (elapsed === 1) {
751
617
  if (this._repeat > 0) {
752
618
  if (isFinite(this._repeat)) {
753
619
  this._repeat--;
754
620
  }
755
-
756
621
  for (property in this._valuesStartRepeat) {
757
622
  if (!this._yoyo && typeof this._valuesEnd[property] === 'string') {
758
623
  this._valuesStartRepeat[property] = this._valuesStartRepeat[property] + parseFloat(this._valuesEnd[property]);
759
624
  }
760
-
761
625
  if (this._yoyo) {
762
626
  this._swapEndStartRepeatValues(property);
763
627
  }
764
-
765
628
  this._valuesStart[property] = this._valuesStartRepeat[property];
766
629
  }
767
-
768
630
  if (this._yoyo) {
769
631
  this._reversed = !this._reversed;
770
632
  }
771
-
772
633
  if (this._repeatDelayTime !== undefined) {
773
634
  this._startTime = time + this._repeatDelayTime;
774
635
  } else {
775
636
  this._startTime = time + this._delayTime;
776
637
  }
777
-
778
638
  if (this._onRepeatCallback) {
779
639
  this._onRepeatCallback(this._object);
780
640
  }
781
-
782
641
  return true;
783
642
  } else {
784
643
  if (this._onCompleteCallback) {
785
644
  this._onCompleteCallback(this._object);
786
645
  }
787
-
788
646
  for (var i = 0, numChainedTweens = this._chainedTweens.length; i < numChainedTweens; i++) {
789
647
  this._chainedTweens[i].start(this._startTime + this._duration);
790
648
  }
791
-
792
649
  this._isPlaying = false;
793
650
  return false;
794
651
  }
795
652
  }
796
-
797
653
  return true;
798
654
  };
799
-
800
655
  Tween.prototype._updateProperties = function (_object, _valuesStart, _valuesEnd, value) {
801
656
  for (var property in _valuesEnd) {
802
657
  if (_valuesStart[property] === undefined) {
803
658
  continue;
804
659
  }
805
-
806
660
  var start = _valuesStart[property] || 0;
807
661
  var end = _valuesEnd[property];
808
662
  var startIsArray = Array.isArray(_object[property]);
809
663
  var endIsArray = Array.isArray(end);
810
664
  var isInterpolationList = !startIsArray && endIsArray;
811
-
812
665
  if (isInterpolationList) {
813
666
  _object[property] = this._interpolationFunction(end, value);
814
667
  } else if (typeof end === 'object' && end) {
815
668
  this._updateProperties(_object[property], start, end, value);
816
669
  } else {
817
670
  end = this._handleRelativeValue(start, end);
818
-
819
671
  if (typeof end === 'number') {
820
672
  _object[property] = start + (end - start) * value;
821
673
  }
822
674
  }
823
675
  }
824
676
  };
825
-
826
677
  Tween.prototype._handleRelativeValue = function (start, end) {
827
678
  if (typeof end !== 'string') {
828
679
  return end;
829
680
  }
830
-
831
681
  if (end.charAt(0) === '+' || end.charAt(0) === '-') {
832
682
  return start + parseFloat(end);
833
683
  } else {
834
684
  return parseFloat(end);
835
685
  }
836
686
  };
837
-
838
687
  Tween.prototype._swapEndStartRepeatValues = function (property) {
839
688
  var tmp = this._valuesStartRepeat[property];
840
689
  var endValue = this._valuesEnd[property];
841
-
842
690
  if (typeof endValue === 'string') {
843
691
  this._valuesStartRepeat[property] = this._valuesStartRepeat[property] + parseFloat(endValue);
844
692
  } else {
845
693
  this._valuesStartRepeat[property] = this._valuesEnd[property];
846
694
  }
847
-
848
695
  this._valuesEnd[property] = tmp;
849
696
  };
850
-
851
697
  return Tween;
852
698
  }();
853
-
699
+ Sequence.nextId;
854
700
  var TWEEN = mainGroup;
855
701
  TWEEN.getAll.bind(TWEEN);
856
702
  TWEEN.removeAll.bind(TWEEN);
@@ -865,11 +711,10 @@ this.EVA.plugin.transition = function (exports, eva_js) {
865
711
  'bounce-in': Easing.Bounce.In,
866
712
  'bounce-out': Easing.Bounce.Out,
867
713
  'bounce-in-out': Easing.Bounce.InOut,
868
- none: function none(p) {
714
+ none: function (p) {
869
715
  return ~~p;
870
716
  }
871
717
  };
872
-
873
718
  var Animation = function () {
874
719
  function Animation(timelines, tweenGroup) {
875
720
  this.tweens = [];
@@ -881,15 +726,12 @@ this.EVA.plugin.transition = function (exports, eva_js) {
881
726
  this.timelines = timelines;
882
727
  this.tweenGroup = tweenGroup;
883
728
  }
884
-
885
729
  Animation.prototype.on = function (eventName, callback) {
886
730
  if (!this.callbacks[eventName]) {
887
731
  this.callbacks.set(eventName, []);
888
732
  }
889
-
890
733
  this.callbacks.get(eventName).push(callback);
891
734
  };
892
-
893
735
  Animation.prototype.emit = function (eventName) {
894
736
  var callbacks = this.callbacks.get(eventName);
895
737
  if (!callbacks || !callbacks.length) return;
@@ -897,7 +739,6 @@ this.EVA.plugin.transition = function (exports, eva_js) {
897
739
  return fn();
898
740
  });
899
741
  };
900
-
901
742
  Animation.prototype.checkFinish = function () {
902
743
  if (++this.finishCount == this.tweens.length) {
903
744
  if (++this.currIteration == this.iteration) {
@@ -908,48 +749,37 @@ this.EVA.plugin.transition = function (exports, eva_js) {
908
749
  }
909
750
  }
910
751
  };
911
-
912
752
  Animation.prototype.getObjectCache = function (component, name) {
913
753
  var key = "" + component.gameObject.id + component.name;
914
-
915
754
  if (!this.objectCache[key]) {
916
755
  this.objectCache[key] = {};
917
756
  }
918
-
919
757
  if (this.objectCache[key][name]) {
920
758
  return this.objectCache[key][name];
921
759
  }
922
-
923
760
  var keys = name.split('.');
924
761
  var keyIndex = keys.length - 1;
925
762
  var property = component;
926
-
927
763
  for (var i = 0; i < keyIndex; i++) {
928
764
  property = property[keys[i]];
929
765
  }
930
-
931
766
  this.objectCache[key][name] = {
932
767
  property: property,
933
768
  key: keys[keyIndex]
934
769
  };
935
770
  return this.objectCache[key][name];
936
771
  };
937
-
938
772
  Animation.prototype.doAnim = function (_a) {
939
773
  var component = _a.component,
940
- name = _a.name,
941
- value = _a.value;
942
-
774
+ name = _a.name,
775
+ value = _a.value;
943
776
  var _b = this.getObjectCache(component, name),
944
- property = _b.property,
945
- key = _b.key;
946
-
777
+ property = _b.property,
778
+ key = _b.key;
947
779
  property[key] = value;
948
780
  };
949
-
950
781
  Animation.prototype.init = function () {
951
782
  var _this = this;
952
-
953
783
  this.checkFinishFunc = this.checkFinish.bind(this);
954
784
  var lastTween;
955
785
  this.timelines.forEach(function (timeline, i) {
@@ -967,37 +797,30 @@ this.EVA.plugin.transition = function (exports, eva_js) {
967
797
  value: props.value
968
798
  });
969
799
  });
970
-
971
800
  if (j === 0) {
972
801
  _this.tweens[i] = tween;
973
802
  } else {
974
803
  lastTween.chain(tween);
975
804
  }
976
-
977
805
  lastTween = tween;
978
806
  }
979
-
980
807
  lastTween && lastTween.onComplete(function () {
981
808
  return _this.checkFinishFunc();
982
809
  });
983
810
  });
984
811
  };
985
-
986
812
  Animation.prototype.play = function (iteration, currentTime) {
987
813
  if (iteration === void 0) {
988
814
  iteration = 1;
989
815
  }
990
-
991
816
  this.currentTime = currentTime;
992
817
  this.stoped = false;
993
818
  this.start();
994
819
  this.currIteration = 0;
995
820
  this.iteration = iteration;
996
821
  };
997
-
998
822
  Animation.prototype.start = function () {
999
823
  var _this = this;
1000
-
1001
824
  this.finishCount = 0;
1002
825
  this.tweens.length = 0;
1003
826
  this.init();
@@ -1005,30 +828,24 @@ this.EVA.plugin.transition = function (exports, eva_js) {
1005
828
  return tween.start(_this.currentTime);
1006
829
  });
1007
830
  };
1008
-
1009
831
  Animation.prototype.pause = function () {
1010
832
  var _this = this;
1011
-
1012
833
  this.tweens.forEach(function (tween) {
1013
834
  return tween.pause(_this.currentTime);
1014
835
  });
1015
836
  };
1016
-
1017
837
  Animation.prototype.resume = function () {
1018
838
  var _this = this;
1019
-
1020
839
  this.tweens.forEach(function (tween) {
1021
840
  return tween.resume(_this.currentTime);
1022
841
  });
1023
842
  };
1024
-
1025
843
  Animation.prototype.stop = function () {
1026
844
  this.stoped = true;
1027
845
  this.tweens.forEach(function (tween) {
1028
846
  return tween.stop();
1029
847
  });
1030
848
  };
1031
-
1032
849
  Animation.prototype.destroy = function () {
1033
850
  this.stop();
1034
851
  this.tweens = null;
@@ -1037,25 +854,19 @@ this.EVA.plugin.transition = function (exports, eva_js) {
1037
854
  this.callbacks.clear();
1038
855
  this.callbacks = null;
1039
856
  };
1040
-
1041
857
  return Animation;
1042
858
  }();
1043
-
1044
859
  var Animation$1 = Animation;
1045
-
1046
860
  var Transition = function (_super) {
1047
861
  __extends(Transition, _super);
1048
-
1049
862
  function Transition() {
1050
863
  var _this = _super !== null && _super.apply(this, arguments) || this;
1051
-
1052
864
  _this.animations = {};
1053
865
  _this.group = {};
1054
866
  _this.currentTime = 0;
1055
867
  _this.needPlay = [];
1056
868
  return _this;
1057
869
  }
1058
-
1059
870
  Transition.prototype.init = function (_a) {
1060
871
  var group = (_a === void 0 ? {
1061
872
  group: {}
@@ -1063,22 +874,18 @@ this.EVA.plugin.transition = function (exports, eva_js) {
1063
874
  this.group = group;
1064
875
  this.tweenGroup = new Group();
1065
876
  };
1066
-
1067
877
  Transition.prototype.awake = function () {
1068
878
  for (var name_1 in this.group) {
1069
879
  this.newAnimation(name_1);
1070
880
  }
1071
881
  };
1072
-
1073
882
  Transition.prototype.play = function (name, iteration) {
1074
883
  if (!name) {
1075
884
  name = Object.keys(this.group)[0];
1076
885
  }
1077
-
1078
886
  if (name && !this.animations[name] && this.group[name]) {
1079
887
  this.newAnimation(name);
1080
888
  }
1081
-
1082
889
  if (name && this.animations[name]) {
1083
890
  this.needPlay.push({
1084
891
  name: name,
@@ -1086,10 +893,8 @@ this.EVA.plugin.transition = function (exports, eva_js) {
1086
893
  });
1087
894
  }
1088
895
  };
1089
-
1090
896
  Transition.prototype.stop = function (name) {
1091
897
  var _a, _b;
1092
-
1093
898
  if (!name) {
1094
899
  for (var key in this.animations) {
1095
900
  (_a = this.animations[key]) === null || _a === void 0 ? void 0 : _a.stop();
@@ -1098,50 +903,37 @@ this.EVA.plugin.transition = function (exports, eva_js) {
1098
903
  (_b = this.animations[name]) === null || _b === void 0 ? void 0 : _b.stop();
1099
904
  }
1100
905
  };
1101
-
1102
906
  Transition.prototype.onPause = function () {
1103
907
  var _a;
1104
-
1105
908
  for (var key in this.animations) {
1106
909
  (_a = this.animations[key]) === null || _a === void 0 ? void 0 : _a.pause();
1107
910
  }
1108
911
  };
1109
-
1110
912
  Transition.prototype.onResume = function () {
1111
913
  var _a;
1112
-
1113
914
  for (var key in this.animations) {
1114
915
  (_a = this.animations[key]) === null || _a === void 0 ? void 0 : _a.resume();
1115
916
  }
1116
917
  };
1117
-
1118
918
  Transition.prototype.onDestroy = function () {
1119
919
  var _a;
1120
-
1121
920
  for (var key in this.animations) {
1122
921
  (_a = this.animations[key]) === null || _a === void 0 ? void 0 : _a.destroy();
1123
922
  }
1124
-
1125
923
  this.tweenGroup.removeAll();
1126
924
  this.tweenGroup = null;
1127
925
  this.group = null;
1128
926
  this.animations = null;
1129
927
  this.removeAllListeners();
1130
928
  };
1131
-
1132
929
  Transition.prototype.update = function (e) {
1133
930
  var e_1, _a;
1134
-
1135
931
  var _b;
1136
-
1137
932
  this.currentTime = e.time;
1138
-
1139
933
  for (var key in this.animations) {
1140
934
  this.animations[key].currentTime = e.time;
1141
935
  }
1142
-
1143
936
  this.tweenGroup.update(e.time);
1144
-
1145
937
  try {
1146
938
  for (var _c = __values(this.needPlay), _d = _c.next(); !_d.done; _d = _c.next()) {
1147
939
  var play = _d.value;
@@ -1158,40 +950,30 @@ this.EVA.plugin.transition = function (exports, eva_js) {
1158
950
  if (e_1) throw e_1.error;
1159
951
  }
1160
952
  }
1161
-
1162
953
  this.needPlay.length = 0;
1163
954
  };
1164
-
1165
955
  Transition.prototype.newAnimation = function (name) {
1166
956
  var _this = this;
1167
-
1168
957
  var animation = new Animation$1(this.group[name], this.tweenGroup);
1169
958
  animation.on('finish', function () {
1170
959
  return _this.emit('finish', name);
1171
960
  });
1172
961
  this.animations[name] = animation;
1173
962
  };
1174
-
1175
963
  Transition.componentName = 'Transition';
1176
964
  return Transition;
1177
965
  }(eva_js.Component);
1178
-
1179
966
  var Transition$1 = Transition;
1180
-
1181
967
  var TransitionSystem = function (_super) {
1182
968
  __extends(TransitionSystem, _super);
1183
-
1184
969
  function TransitionSystem() {
1185
970
  var _this = _super !== null && _super.apply(this, arguments) || this;
1186
-
1187
971
  _this.name = 'transition';
1188
972
  return _this;
1189
973
  }
1190
-
1191
974
  TransitionSystem.systemName = 'transition';
1192
975
  return TransitionSystem;
1193
976
  }(eva_js.System);
1194
-
1195
977
  var TransitionSystem$1 = TransitionSystem;
1196
978
  exports.Transition = Transition$1;
1197
979
  exports.TransitionSystem = TransitionSystem$1;
@@ -1200,3 +982,4 @@ this.EVA.plugin.transition = function (exports, eva_js) {
1200
982
  });
1201
983
  return exports;
1202
984
  }({}, EVA);
985
+ window.EVA.plugin.transition = window.EVA.plugin.transition || _EVA_IIFE_transition;