tsparticles 1.36.0 → 1.37.3

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 (299) hide show
  1. package/Core/Container.d.ts +3 -1
  2. package/Core/Container.js +16 -11
  3. package/Core/InteractionManager.d.ts +1 -0
  4. package/Core/InteractionManager.js +4 -1
  5. package/Core/Particles.d.ts +1 -1
  6. package/Core/Particles.js +3 -1
  7. package/Enums/Modes/ResponsiveMode.d.ts +4 -0
  8. package/Enums/Modes/ResponsiveMode.js +8 -0
  9. package/Enums/Modes/index.d.ts +1 -0
  10. package/Enums/Modes/index.js +1 -0
  11. package/Interactions/External/Attract/index.d.ts +1 -1
  12. package/Interactions/External/Attract/index.js +2 -2
  13. package/Interactions/External/Bounce/index.d.ts +1 -1
  14. package/Interactions/External/Bounce/index.js +2 -2
  15. package/Interactions/External/Bubble/index.d.ts +1 -1
  16. package/Interactions/External/Bubble/index.js +2 -2
  17. package/Interactions/External/Connect/index.d.ts +1 -1
  18. package/Interactions/External/Connect/index.js +2 -2
  19. package/Interactions/External/Grab/index.d.ts +1 -1
  20. package/Interactions/External/Grab/index.js +2 -2
  21. package/Interactions/External/Repulse/index.d.ts +1 -1
  22. package/Interactions/External/Repulse/index.js +2 -2
  23. package/Interactions/External/Trail/index.d.ts +1 -1
  24. package/Interactions/External/Trail/index.js +2 -2
  25. package/Interactions/Particles/Attract/index.d.ts +1 -1
  26. package/Interactions/Particles/Attract/index.js +2 -2
  27. package/Interactions/Particles/Collisions/index.d.ts +1 -1
  28. package/Interactions/Particles/Collisions/index.js +2 -2
  29. package/Interactions/Particles/Links/index.d.ts +2 -2
  30. package/Interactions/Particles/Links/index.js +5 -5
  31. package/Interactions/Particles/Links/plugin.d.ts +1 -1
  32. package/Interactions/Particles/Links/plugin.js +2 -2
  33. package/Options/Classes/FullScreen/FullScreen.js +2 -2
  34. package/Options/Classes/Interactivity/Interactivity.js +1 -1
  35. package/Options/Classes/Options.js +3 -1
  36. package/Options/Classes/Responsive.d.ts +2 -0
  37. package/Options/Classes/Responsive.js +10 -0
  38. package/Options/Interfaces/IResponsive.d.ts +2 -0
  39. package/Plugins/Absorbers/AbsorberInstance.d.ts +2 -1
  40. package/Plugins/Absorbers/AbsorberInstance.js +21 -9
  41. package/Plugins/Absorbers/Options/Classes/AbsorberSize.d.ts +2 -1
  42. package/Plugins/Absorbers/Options/Classes/AbsorberSize.js +6 -4
  43. package/Plugins/Absorbers/Options/Classes/AbsorberSizeLimit.d.ts +9 -0
  44. package/Plugins/Absorbers/Options/Classes/AbsorberSizeLimit.js +21 -0
  45. package/Plugins/Absorbers/Options/Interfaces/IAbsorberSize.d.ts +3 -2
  46. package/Plugins/Absorbers/Options/Interfaces/IAbsorberSizeLimit.d.ts +4 -0
  47. package/Plugins/Absorbers/Options/Interfaces/IAbsorberSizeLimit.js +2 -0
  48. package/Plugins/Absorbers/plugin.d.ts +1 -1
  49. package/Plugins/Absorbers/plugin.js +2 -2
  50. package/Plugins/Emitters/plugin.d.ts +1 -1
  51. package/Plugins/Emitters/plugin.js +2 -2
  52. package/Plugins/PolygonMask/plugin.js +1 -1
  53. package/Shapes/Circle/index.d.ts +1 -1
  54. package/Shapes/Circle/index.js +2 -2
  55. package/Shapes/Image/index.d.ts +1 -1
  56. package/Shapes/Image/index.js +3 -3
  57. package/Shapes/Line/index.d.ts +1 -1
  58. package/Shapes/Line/index.js +2 -2
  59. package/Shapes/Polygon/index.d.ts +3 -3
  60. package/Shapes/Polygon/index.js +7 -7
  61. package/Shapes/Square/index.d.ts +1 -1
  62. package/Shapes/Square/index.js +3 -3
  63. package/Shapes/Star/index.d.ts +1 -1
  64. package/Shapes/Star/index.js +2 -2
  65. package/Shapes/Text/index.d.ts +1 -1
  66. package/Shapes/Text/index.js +2 -2
  67. package/Updaters/Angle/index.d.ts +1 -1
  68. package/Updaters/Angle/index.js +2 -2
  69. package/Updaters/Color/index.d.ts +1 -1
  70. package/Updaters/Color/index.js +2 -2
  71. package/Updaters/Life/index.d.ts +1 -1
  72. package/Updaters/Life/index.js +2 -2
  73. package/Updaters/Opacity/index.d.ts +1 -1
  74. package/Updaters/Opacity/index.js +2 -2
  75. package/Updaters/OutModes/index.d.ts +1 -1
  76. package/Updaters/OutModes/index.js +2 -2
  77. package/Updaters/Roll/index.d.ts +1 -1
  78. package/Updaters/Roll/index.js +2 -2
  79. package/Updaters/Size/index.d.ts +1 -1
  80. package/Updaters/Size/index.js +2 -2
  81. package/Updaters/StrokeColor/index.d.ts +1 -1
  82. package/Updaters/StrokeColor/index.js +2 -2
  83. package/Updaters/Tilt/index.d.ts +1 -1
  84. package/Updaters/Tilt/index.js +2 -2
  85. package/Updaters/Wobble/index.d.ts +1 -1
  86. package/Updaters/Wobble/index.js +2 -2
  87. package/Utils/Plugins.d.ts +2 -2
  88. package/Utils/Plugins.js +4 -4
  89. package/Utils/Utils.d.ts +1 -2
  90. package/browser/Core/Container.d.ts +3 -1
  91. package/browser/Core/Container.js +17 -12
  92. package/browser/Core/InteractionManager.d.ts +1 -0
  93. package/browser/Core/InteractionManager.js +4 -1
  94. package/browser/Core/Particles.d.ts +1 -1
  95. package/browser/Core/Particles.js +3 -1
  96. package/browser/Enums/Modes/ResponsiveMode.d.ts +4 -0
  97. package/browser/Enums/Modes/ResponsiveMode.js +5 -0
  98. package/browser/Enums/Modes/index.d.ts +1 -0
  99. package/browser/Enums/Modes/index.js +1 -0
  100. package/browser/Interactions/External/Attract/index.d.ts +1 -1
  101. package/browser/Interactions/External/Attract/index.js +2 -2
  102. package/browser/Interactions/External/Bounce/index.d.ts +1 -1
  103. package/browser/Interactions/External/Bounce/index.js +2 -2
  104. package/browser/Interactions/External/Bubble/index.d.ts +1 -1
  105. package/browser/Interactions/External/Bubble/index.js +2 -2
  106. package/browser/Interactions/External/Connect/index.d.ts +1 -1
  107. package/browser/Interactions/External/Connect/index.js +2 -2
  108. package/browser/Interactions/External/Grab/index.d.ts +1 -1
  109. package/browser/Interactions/External/Grab/index.js +2 -2
  110. package/browser/Interactions/External/Repulse/index.d.ts +1 -1
  111. package/browser/Interactions/External/Repulse/index.js +2 -2
  112. package/browser/Interactions/External/Trail/index.d.ts +1 -1
  113. package/browser/Interactions/External/Trail/index.js +2 -2
  114. package/browser/Interactions/Particles/Attract/index.d.ts +1 -1
  115. package/browser/Interactions/Particles/Attract/index.js +2 -2
  116. package/browser/Interactions/Particles/Collisions/index.d.ts +1 -1
  117. package/browser/Interactions/Particles/Collisions/index.js +2 -2
  118. package/browser/Interactions/Particles/Links/index.d.ts +2 -2
  119. package/browser/Interactions/Particles/Links/index.js +5 -5
  120. package/browser/Interactions/Particles/Links/plugin.d.ts +1 -1
  121. package/browser/Interactions/Particles/Links/plugin.js +2 -2
  122. package/browser/Options/Classes/FullScreen/FullScreen.js +2 -2
  123. package/browser/Options/Classes/Interactivity/Interactivity.js +1 -1
  124. package/browser/Options/Classes/Options.js +4 -2
  125. package/browser/Options/Classes/Responsive.d.ts +2 -0
  126. package/browser/Options/Classes/Responsive.js +11 -0
  127. package/browser/Options/Interfaces/IResponsive.d.ts +2 -0
  128. package/browser/Plugins/Absorbers/AbsorberInstance.d.ts +2 -1
  129. package/browser/Plugins/Absorbers/AbsorberInstance.js +21 -9
  130. package/browser/Plugins/Absorbers/Options/Classes/AbsorberSize.d.ts +2 -1
  131. package/browser/Plugins/Absorbers/Options/Classes/AbsorberSize.js +6 -4
  132. package/browser/Plugins/Absorbers/Options/Classes/AbsorberSizeLimit.d.ts +9 -0
  133. package/browser/Plugins/Absorbers/Options/Classes/AbsorberSizeLimit.js +17 -0
  134. package/browser/Plugins/Absorbers/Options/Interfaces/IAbsorberSize.d.ts +3 -2
  135. package/browser/Plugins/Absorbers/Options/Interfaces/IAbsorberSizeLimit.d.ts +4 -0
  136. package/browser/Plugins/Absorbers/Options/Interfaces/IAbsorberSizeLimit.js +1 -0
  137. package/browser/Plugins/Absorbers/plugin.d.ts +1 -1
  138. package/browser/Plugins/Absorbers/plugin.js +2 -2
  139. package/browser/Plugins/Emitters/plugin.d.ts +1 -1
  140. package/browser/Plugins/Emitters/plugin.js +2 -2
  141. package/browser/Plugins/PolygonMask/plugin.js +4 -2
  142. package/browser/Shapes/Circle/index.d.ts +1 -1
  143. package/browser/Shapes/Circle/index.js +2 -2
  144. package/browser/Shapes/Image/index.d.ts +1 -1
  145. package/browser/Shapes/Image/index.js +3 -3
  146. package/browser/Shapes/Line/index.d.ts +1 -1
  147. package/browser/Shapes/Line/index.js +2 -2
  148. package/browser/Shapes/Polygon/index.d.ts +3 -3
  149. package/browser/Shapes/Polygon/index.js +7 -7
  150. package/browser/Shapes/Square/index.d.ts +1 -1
  151. package/browser/Shapes/Square/index.js +3 -3
  152. package/browser/Shapes/Star/index.d.ts +1 -1
  153. package/browser/Shapes/Star/index.js +2 -2
  154. package/browser/Shapes/Text/index.d.ts +1 -1
  155. package/browser/Shapes/Text/index.js +2 -2
  156. package/browser/Updaters/Angle/index.d.ts +1 -1
  157. package/browser/Updaters/Angle/index.js +2 -2
  158. package/browser/Updaters/Color/index.d.ts +1 -1
  159. package/browser/Updaters/Color/index.js +2 -2
  160. package/browser/Updaters/Life/index.d.ts +1 -1
  161. package/browser/Updaters/Life/index.js +2 -2
  162. package/browser/Updaters/Opacity/index.d.ts +1 -1
  163. package/browser/Updaters/Opacity/index.js +2 -2
  164. package/browser/Updaters/OutModes/index.d.ts +1 -1
  165. package/browser/Updaters/OutModes/index.js +2 -2
  166. package/browser/Updaters/Roll/index.d.ts +1 -1
  167. package/browser/Updaters/Roll/index.js +2 -2
  168. package/browser/Updaters/Size/index.d.ts +1 -1
  169. package/browser/Updaters/Size/index.js +2 -2
  170. package/browser/Updaters/StrokeColor/index.d.ts +1 -1
  171. package/browser/Updaters/StrokeColor/index.js +2 -2
  172. package/browser/Updaters/Tilt/index.d.ts +1 -1
  173. package/browser/Updaters/Tilt/index.js +2 -2
  174. package/browser/Updaters/Wobble/index.d.ts +1 -1
  175. package/browser/Updaters/Wobble/index.js +2 -2
  176. package/browser/Utils/Plugins.d.ts +2 -2
  177. package/browser/Utils/Plugins.js +4 -4
  178. package/browser/Utils/Utils.d.ts +1 -2
  179. package/browser/full.d.ts +1 -1
  180. package/browser/full.js +9 -9
  181. package/browser/index.js +1 -1
  182. package/browser/index.slim.js +1 -1
  183. package/browser/main.d.ts +10 -6
  184. package/browser/main.js +20 -6
  185. package/browser/slim.d.ts +1 -1
  186. package/browser/slim.js +24 -24
  187. package/esm/Core/Container.d.ts +3 -1
  188. package/esm/Core/Container.js +16 -11
  189. package/esm/Core/InteractionManager.d.ts +1 -0
  190. package/esm/Core/InteractionManager.js +4 -1
  191. package/esm/Core/Particles.d.ts +1 -1
  192. package/esm/Core/Particles.js +3 -1
  193. package/esm/Enums/Modes/ResponsiveMode.d.ts +4 -0
  194. package/esm/Enums/Modes/ResponsiveMode.js +5 -0
  195. package/esm/Enums/Modes/index.d.ts +1 -0
  196. package/esm/Enums/Modes/index.js +1 -0
  197. package/esm/Interactions/External/Attract/index.d.ts +1 -1
  198. package/esm/Interactions/External/Attract/index.js +2 -2
  199. package/esm/Interactions/External/Bounce/index.d.ts +1 -1
  200. package/esm/Interactions/External/Bounce/index.js +2 -2
  201. package/esm/Interactions/External/Bubble/index.d.ts +1 -1
  202. package/esm/Interactions/External/Bubble/index.js +2 -2
  203. package/esm/Interactions/External/Connect/index.d.ts +1 -1
  204. package/esm/Interactions/External/Connect/index.js +2 -2
  205. package/esm/Interactions/External/Grab/index.d.ts +1 -1
  206. package/esm/Interactions/External/Grab/index.js +2 -2
  207. package/esm/Interactions/External/Repulse/index.d.ts +1 -1
  208. package/esm/Interactions/External/Repulse/index.js +2 -2
  209. package/esm/Interactions/External/Trail/index.d.ts +1 -1
  210. package/esm/Interactions/External/Trail/index.js +2 -2
  211. package/esm/Interactions/Particles/Attract/index.d.ts +1 -1
  212. package/esm/Interactions/Particles/Attract/index.js +2 -2
  213. package/esm/Interactions/Particles/Collisions/index.d.ts +1 -1
  214. package/esm/Interactions/Particles/Collisions/index.js +2 -2
  215. package/esm/Interactions/Particles/Links/index.d.ts +2 -2
  216. package/esm/Interactions/Particles/Links/index.js +5 -5
  217. package/esm/Interactions/Particles/Links/plugin.d.ts +1 -1
  218. package/esm/Interactions/Particles/Links/plugin.js +2 -2
  219. package/esm/Options/Classes/FullScreen/FullScreen.js +2 -2
  220. package/esm/Options/Classes/Interactivity/Interactivity.js +1 -1
  221. package/esm/Options/Classes/Options.js +4 -2
  222. package/esm/Options/Classes/Responsive.d.ts +2 -0
  223. package/esm/Options/Classes/Responsive.js +10 -0
  224. package/esm/Options/Interfaces/IResponsive.d.ts +2 -0
  225. package/esm/Plugins/Absorbers/AbsorberInstance.d.ts +2 -1
  226. package/esm/Plugins/Absorbers/AbsorberInstance.js +21 -9
  227. package/esm/Plugins/Absorbers/Options/Classes/AbsorberSize.d.ts +2 -1
  228. package/esm/Plugins/Absorbers/Options/Classes/AbsorberSize.js +6 -4
  229. package/esm/Plugins/Absorbers/Options/Classes/AbsorberSizeLimit.d.ts +9 -0
  230. package/esm/Plugins/Absorbers/Options/Classes/AbsorberSizeLimit.js +17 -0
  231. package/esm/Plugins/Absorbers/Options/Interfaces/IAbsorberSize.d.ts +3 -2
  232. package/esm/Plugins/Absorbers/Options/Interfaces/IAbsorberSizeLimit.d.ts +4 -0
  233. package/esm/Plugins/Absorbers/Options/Interfaces/IAbsorberSizeLimit.js +1 -0
  234. package/esm/Plugins/Absorbers/plugin.d.ts +1 -1
  235. package/esm/Plugins/Absorbers/plugin.js +2 -2
  236. package/esm/Plugins/Emitters/plugin.d.ts +1 -1
  237. package/esm/Plugins/Emitters/plugin.js +2 -2
  238. package/esm/Plugins/PolygonMask/plugin.js +1 -1
  239. package/esm/Shapes/Circle/index.d.ts +1 -1
  240. package/esm/Shapes/Circle/index.js +2 -2
  241. package/esm/Shapes/Image/index.d.ts +1 -1
  242. package/esm/Shapes/Image/index.js +3 -3
  243. package/esm/Shapes/Line/index.d.ts +1 -1
  244. package/esm/Shapes/Line/index.js +2 -2
  245. package/esm/Shapes/Polygon/index.d.ts +3 -3
  246. package/esm/Shapes/Polygon/index.js +7 -7
  247. package/esm/Shapes/Square/index.d.ts +1 -1
  248. package/esm/Shapes/Square/index.js +3 -3
  249. package/esm/Shapes/Star/index.d.ts +1 -1
  250. package/esm/Shapes/Star/index.js +2 -2
  251. package/esm/Shapes/Text/index.d.ts +1 -1
  252. package/esm/Shapes/Text/index.js +2 -2
  253. package/esm/Updaters/Angle/index.d.ts +1 -1
  254. package/esm/Updaters/Angle/index.js +2 -2
  255. package/esm/Updaters/Color/index.d.ts +1 -1
  256. package/esm/Updaters/Color/index.js +2 -2
  257. package/esm/Updaters/Life/index.d.ts +1 -1
  258. package/esm/Updaters/Life/index.js +2 -2
  259. package/esm/Updaters/Opacity/index.d.ts +1 -1
  260. package/esm/Updaters/Opacity/index.js +2 -2
  261. package/esm/Updaters/OutModes/index.d.ts +1 -1
  262. package/esm/Updaters/OutModes/index.js +2 -2
  263. package/esm/Updaters/Roll/index.d.ts +1 -1
  264. package/esm/Updaters/Roll/index.js +2 -2
  265. package/esm/Updaters/Size/index.d.ts +1 -1
  266. package/esm/Updaters/Size/index.js +2 -2
  267. package/esm/Updaters/StrokeColor/index.d.ts +1 -1
  268. package/esm/Updaters/StrokeColor/index.js +2 -2
  269. package/esm/Updaters/Tilt/index.d.ts +1 -1
  270. package/esm/Updaters/Tilt/index.js +2 -2
  271. package/esm/Updaters/Wobble/index.d.ts +1 -1
  272. package/esm/Updaters/Wobble/index.js +2 -2
  273. package/esm/Utils/Plugins.d.ts +2 -2
  274. package/esm/Utils/Plugins.js +4 -4
  275. package/esm/Utils/Utils.d.ts +1 -2
  276. package/esm/full.d.ts +1 -1
  277. package/esm/full.js +9 -9
  278. package/esm/index.js +1 -1
  279. package/esm/index.slim.js +1 -1
  280. package/esm/main.d.ts +7 -6
  281. package/esm/main.js +17 -6
  282. package/esm/slim.d.ts +1 -1
  283. package/esm/slim.js +24 -24
  284. package/full.d.ts +1 -1
  285. package/full.js +9 -9
  286. package/index.js +1 -1
  287. package/index.slim.js +1 -1
  288. package/main.d.ts +7 -6
  289. package/main.js +17 -6
  290. package/package.json +1 -1
  291. package/report.html +2 -2
  292. package/report.slim.html +2 -2
  293. package/slim.d.ts +1 -1
  294. package/slim.js +24 -24
  295. package/tsparticles.js +743 -363
  296. package/tsparticles.min.js +2 -2
  297. package/tsparticles.pathseg.js +2 -2
  298. package/tsparticles.slim.js +539 -284
  299. package/tsparticles.slim.min.js +2 -2
@@ -3,12 +3,12 @@
3
3
  var a = factory();
4
4
  for (var i in a) (typeof exports === "object" ? exports : root)[i] = a[i];
5
5
  }
6
- })(this, (function() {
7
- return (() => {
6
+ })(window, (function() {
7
+ return function() {
8
8
  "use strict";
9
9
  var __webpack_require__ = {};
10
- (() => {
11
- __webpack_require__.d = (exports, definition) => {
10
+ !function() {
11
+ __webpack_require__.d = function(exports, definition) {
12
12
  for (var key in definition) {
13
13
  if (__webpack_require__.o(definition, key) && !__webpack_require__.o(exports, key)) {
14
14
  Object.defineProperty(exports, key, {
@@ -18,12 +18,14 @@
18
18
  }
19
19
  }
20
20
  };
21
- })();
22
- (() => {
23
- __webpack_require__.o = (obj, prop) => Object.prototype.hasOwnProperty.call(obj, prop);
24
- })();
25
- (() => {
26
- __webpack_require__.r = exports => {
21
+ }();
22
+ !function() {
23
+ __webpack_require__.o = function(obj, prop) {
24
+ return Object.prototype.hasOwnProperty.call(obj, prop);
25
+ };
26
+ }();
27
+ !function() {
28
+ __webpack_require__.r = function(exports) {
27
29
  if (typeof Symbol !== "undefined" && Symbol.toStringTag) {
28
30
  Object.defineProperty(exports, Symbol.toStringTag, {
29
31
  value: "Module"
@@ -33,118 +35,337 @@
33
35
  value: true
34
36
  });
35
37
  };
36
- })();
38
+ }();
37
39
  var __webpack_exports__ = {};
38
40
  __webpack_require__.r(__webpack_exports__);
39
41
  __webpack_require__.d(__webpack_exports__, {
40
- AlterType: () => AlterType,
41
- AnimationStatus: () => AnimationStatus,
42
- Circle: () => Circle,
43
- CircleWarp: () => CircleWarp,
44
- ClickMode: () => ClickMode,
45
- CollisionMode: () => CollisionMode,
46
- Constants: () => Constants,
47
- Container: () => Container,
48
- DestroyMode: () => DestroyMode,
49
- DestroyType: () => DestroyType,
50
- DivMode: () => DivMode,
51
- DivType: () => DivType,
52
- EasingType: () => EasingType,
53
- ExternalInteractorBase: () => ExternalInteractorBase,
54
- GradientType: () => GradientType,
55
- HoverMode: () => HoverMode,
56
- InteractivityDetect: () => InteractivityDetect,
57
- InteractorType: () => InteractorType,
58
- Main: () => Main,
59
- MoveDirection: () => MoveDirection,
60
- OrbitType: () => OrbitType,
61
- OutMode: () => OutMode,
62
- OutModeDirection: () => OutModeDirection,
63
- Particle: () => Particle,
64
- ParticlesInteractorBase: () => ParticlesInteractorBase,
65
- Point: () => Point,
66
- Rectangle: () => Rectangle,
67
- RollMode: () => RollMode,
68
- RotateDirection: () => RotateDirection,
69
- ShapeType: () => ShapeType,
70
- SizeMode: () => SizeMode,
71
- StartValueType: () => StartValueType,
72
- ThemeMode: () => ThemeMode,
73
- TiltDirection: () => TiltDirection,
74
- Vector: () => Vector,
75
- alterHsl: () => alterHsl,
76
- animate: () => animate,
77
- areBoundsInside: () => areBoundsInside,
78
- arrayRandomIndex: () => arrayRandomIndex,
79
- calcEasing: () => calcEasing,
80
- calculateBounds: () => calculateBounds,
81
- cancelAnimation: () => cancelAnimation,
82
- circleBounce: () => circleBounce,
83
- circleBounceDataFromParticle: () => circleBounceDataFromParticle,
84
- clamp: () => clamp,
85
- clear: () => clear,
86
- collisionVelocity: () => collisionVelocity,
87
- colorMix: () => colorMix,
88
- colorToHsl: () => colorToHsl,
89
- colorToRgb: () => colorToRgb,
90
- deepExtend: () => deepExtend,
91
- divMode: () => divMode,
92
- divModeExecute: () => divModeExecute,
93
- drawConnectLine: () => drawConnectLine,
94
- drawEllipse: () => drawEllipse,
95
- drawGrabLine: () => drawGrabLine,
96
- drawLinkLine: () => drawLinkLine,
97
- drawLinkTriangle: () => drawLinkTriangle,
98
- drawParticle: () => drawParticle,
99
- drawParticlePlugin: () => drawParticlePlugin,
100
- drawPlugin: () => drawPlugin,
101
- drawShape: () => drawShape,
102
- drawShapeAfterEffect: () => drawShapeAfterEffect,
103
- getDistance: () => getDistance,
104
- getDistances: () => getDistances,
105
- getHslAnimationFromHsl: () => getHslAnimationFromHsl,
106
- getHslFromAnimation: () => getHslFromAnimation,
107
- getLinkColor: () => getLinkColor,
108
- getLinkRandomColor: () => getLinkRandomColor,
109
- getParticleBaseVelocity: () => getParticleBaseVelocity,
110
- getParticleDirectionAngle: () => getParticleDirectionAngle,
111
- getRandomRgbColor: () => getRandomRgbColor,
112
- getRangeMax: () => getRangeMax,
113
- getRangeMin: () => getRangeMin,
114
- getRangeValue: () => getRangeValue,
115
- getStyleFromHsl: () => getStyleFromHsl,
116
- getStyleFromHsv: () => getStyleFromHsv,
117
- getStyleFromRgb: () => getStyleFromRgb,
118
- getValue: () => getValue,
119
- gradient: () => gradient,
120
- hslToHsv: () => hslToHsv,
121
- hslToRgb: () => hslToRgb,
122
- hslaToHsva: () => hslaToHsva,
123
- hslaToRgba: () => hslaToRgba,
124
- hsvToHsl: () => hsvToHsl,
125
- hsvToRgb: () => hsvToRgb,
126
- hsvaToHsla: () => hsvaToHsla,
127
- hsvaToRgba: () => hsvaToRgba,
128
- isDivModeEnabled: () => isDivModeEnabled,
129
- isInArray: () => isInArray,
130
- isPointInside: () => isPointInside,
131
- isSsr: () => isSsr,
132
- itemFromArray: () => itemFromArray,
133
- loadFont: () => loadFont,
134
- mix: () => mix,
135
- pJSDom: () => pJSDom,
136
- paintBase: () => paintBase,
137
- particlesJS: () => particlesJS,
138
- randomInRange: () => randomInRange,
139
- rectBounce: () => rectBounce,
140
- rgbToHsl: () => rgbToHsl,
141
- rgbToHsv: () => rgbToHsv,
142
- rgbaToHsva: () => rgbaToHsva,
143
- setRangeValue: () => setRangeValue,
144
- singleDivModeExecute: () => singleDivModeExecute,
145
- stringToAlpha: () => stringToAlpha,
146
- stringToRgb: () => stringToRgb,
147
- tsParticles: () => tsParticles
42
+ AlterType: function() {
43
+ return AlterType;
44
+ },
45
+ AnimationStatus: function() {
46
+ return AnimationStatus;
47
+ },
48
+ Circle: function() {
49
+ return Circle;
50
+ },
51
+ CircleWarp: function() {
52
+ return CircleWarp;
53
+ },
54
+ ClickMode: function() {
55
+ return ClickMode;
56
+ },
57
+ CollisionMode: function() {
58
+ return CollisionMode;
59
+ },
60
+ Constants: function() {
61
+ return Constants;
62
+ },
63
+ Container: function() {
64
+ return Container;
65
+ },
66
+ DestroyMode: function() {
67
+ return DestroyMode;
68
+ },
69
+ DestroyType: function() {
70
+ return DestroyType;
71
+ },
72
+ DivMode: function() {
73
+ return DivMode;
74
+ },
75
+ DivType: function() {
76
+ return DivType;
77
+ },
78
+ EasingType: function() {
79
+ return EasingType;
80
+ },
81
+ ExternalInteractorBase: function() {
82
+ return ExternalInteractorBase;
83
+ },
84
+ GradientType: function() {
85
+ return GradientType;
86
+ },
87
+ HoverMode: function() {
88
+ return HoverMode;
89
+ },
90
+ InteractivityDetect: function() {
91
+ return InteractivityDetect;
92
+ },
93
+ InteractorType: function() {
94
+ return InteractorType;
95
+ },
96
+ Main: function() {
97
+ return Main;
98
+ },
99
+ MoveDirection: function() {
100
+ return MoveDirection;
101
+ },
102
+ OrbitType: function() {
103
+ return OrbitType;
104
+ },
105
+ OutMode: function() {
106
+ return OutMode;
107
+ },
108
+ OutModeDirection: function() {
109
+ return OutModeDirection;
110
+ },
111
+ Particle: function() {
112
+ return Particle;
113
+ },
114
+ ParticlesInteractorBase: function() {
115
+ return ParticlesInteractorBase;
116
+ },
117
+ Point: function() {
118
+ return Point;
119
+ },
120
+ Rectangle: function() {
121
+ return Rectangle;
122
+ },
123
+ ResponsiveMode: function() {
124
+ return ResponsiveMode;
125
+ },
126
+ RollMode: function() {
127
+ return RollMode;
128
+ },
129
+ RotateDirection: function() {
130
+ return RotateDirection;
131
+ },
132
+ ShapeType: function() {
133
+ return ShapeType;
134
+ },
135
+ SizeMode: function() {
136
+ return SizeMode;
137
+ },
138
+ StartValueType: function() {
139
+ return StartValueType;
140
+ },
141
+ ThemeMode: function() {
142
+ return ThemeMode;
143
+ },
144
+ TiltDirection: function() {
145
+ return TiltDirection;
146
+ },
147
+ Vector: function() {
148
+ return Vector;
149
+ },
150
+ alterHsl: function() {
151
+ return alterHsl;
152
+ },
153
+ animate: function() {
154
+ return animate;
155
+ },
156
+ areBoundsInside: function() {
157
+ return areBoundsInside;
158
+ },
159
+ arrayRandomIndex: function() {
160
+ return arrayRandomIndex;
161
+ },
162
+ calcEasing: function() {
163
+ return calcEasing;
164
+ },
165
+ calculateBounds: function() {
166
+ return calculateBounds;
167
+ },
168
+ cancelAnimation: function() {
169
+ return cancelAnimation;
170
+ },
171
+ circleBounce: function() {
172
+ return circleBounce;
173
+ },
174
+ circleBounceDataFromParticle: function() {
175
+ return circleBounceDataFromParticle;
176
+ },
177
+ clamp: function() {
178
+ return clamp;
179
+ },
180
+ clear: function() {
181
+ return clear;
182
+ },
183
+ collisionVelocity: function() {
184
+ return collisionVelocity;
185
+ },
186
+ colorMix: function() {
187
+ return colorMix;
188
+ },
189
+ colorToHsl: function() {
190
+ return colorToHsl;
191
+ },
192
+ colorToRgb: function() {
193
+ return colorToRgb;
194
+ },
195
+ deepExtend: function() {
196
+ return deepExtend;
197
+ },
198
+ divMode: function() {
199
+ return divMode;
200
+ },
201
+ divModeExecute: function() {
202
+ return divModeExecute;
203
+ },
204
+ drawConnectLine: function() {
205
+ return drawConnectLine;
206
+ },
207
+ drawEllipse: function() {
208
+ return drawEllipse;
209
+ },
210
+ drawGrabLine: function() {
211
+ return drawGrabLine;
212
+ },
213
+ drawLinkLine: function() {
214
+ return drawLinkLine;
215
+ },
216
+ drawLinkTriangle: function() {
217
+ return drawLinkTriangle;
218
+ },
219
+ drawParticle: function() {
220
+ return drawParticle;
221
+ },
222
+ drawParticlePlugin: function() {
223
+ return drawParticlePlugin;
224
+ },
225
+ drawPlugin: function() {
226
+ return drawPlugin;
227
+ },
228
+ drawShape: function() {
229
+ return drawShape;
230
+ },
231
+ drawShapeAfterEffect: function() {
232
+ return drawShapeAfterEffect;
233
+ },
234
+ getDistance: function() {
235
+ return getDistance;
236
+ },
237
+ getDistances: function() {
238
+ return getDistances;
239
+ },
240
+ getHslAnimationFromHsl: function() {
241
+ return getHslAnimationFromHsl;
242
+ },
243
+ getHslFromAnimation: function() {
244
+ return getHslFromAnimation;
245
+ },
246
+ getLinkColor: function() {
247
+ return getLinkColor;
248
+ },
249
+ getLinkRandomColor: function() {
250
+ return getLinkRandomColor;
251
+ },
252
+ getParticleBaseVelocity: function() {
253
+ return getParticleBaseVelocity;
254
+ },
255
+ getParticleDirectionAngle: function() {
256
+ return getParticleDirectionAngle;
257
+ },
258
+ getRandomRgbColor: function() {
259
+ return getRandomRgbColor;
260
+ },
261
+ getRangeMax: function() {
262
+ return getRangeMax;
263
+ },
264
+ getRangeMin: function() {
265
+ return getRangeMin;
266
+ },
267
+ getRangeValue: function() {
268
+ return getRangeValue;
269
+ },
270
+ getStyleFromHsl: function() {
271
+ return getStyleFromHsl;
272
+ },
273
+ getStyleFromHsv: function() {
274
+ return getStyleFromHsv;
275
+ },
276
+ getStyleFromRgb: function() {
277
+ return getStyleFromRgb;
278
+ },
279
+ getValue: function() {
280
+ return getValue;
281
+ },
282
+ gradient: function() {
283
+ return gradient;
284
+ },
285
+ hslToHsv: function() {
286
+ return hslToHsv;
287
+ },
288
+ hslToRgb: function() {
289
+ return hslToRgb;
290
+ },
291
+ hslaToHsva: function() {
292
+ return hslaToHsva;
293
+ },
294
+ hslaToRgba: function() {
295
+ return hslaToRgba;
296
+ },
297
+ hsvToHsl: function() {
298
+ return hsvToHsl;
299
+ },
300
+ hsvToRgb: function() {
301
+ return hsvToRgb;
302
+ },
303
+ hsvaToHsla: function() {
304
+ return hsvaToHsla;
305
+ },
306
+ hsvaToRgba: function() {
307
+ return hsvaToRgba;
308
+ },
309
+ isDivModeEnabled: function() {
310
+ return isDivModeEnabled;
311
+ },
312
+ isInArray: function() {
313
+ return isInArray;
314
+ },
315
+ isPointInside: function() {
316
+ return isPointInside;
317
+ },
318
+ isSsr: function() {
319
+ return isSsr;
320
+ },
321
+ itemFromArray: function() {
322
+ return itemFromArray;
323
+ },
324
+ loadFont: function() {
325
+ return loadFont;
326
+ },
327
+ mix: function() {
328
+ return mix;
329
+ },
330
+ pJSDom: function() {
331
+ return pJSDom;
332
+ },
333
+ paintBase: function() {
334
+ return paintBase;
335
+ },
336
+ particlesJS: function() {
337
+ return particlesJS;
338
+ },
339
+ randomInRange: function() {
340
+ return randomInRange;
341
+ },
342
+ rectBounce: function() {
343
+ return rectBounce;
344
+ },
345
+ rgbToHsl: function() {
346
+ return rgbToHsl;
347
+ },
348
+ rgbToHsv: function() {
349
+ return rgbToHsv;
350
+ },
351
+ rgbaToHsva: function() {
352
+ return rgbaToHsva;
353
+ },
354
+ setRangeValue: function() {
355
+ return setRangeValue;
356
+ },
357
+ singleDivModeExecute: function() {
358
+ return singleDivModeExecute;
359
+ },
360
+ stringToAlpha: function() {
361
+ return stringToAlpha;
362
+ },
363
+ stringToRgb: function() {
364
+ return stringToRgb;
365
+ },
366
+ tsParticles: function() {
367
+ return tsParticles;
368
+ }
148
369
  });
149
370
  const initPjs = main => {
150
371
  const particlesJS = (tagId, options) => main.load(tagId, options);
@@ -162,8 +383,8 @@
162
383
  };
163
384
  const pJSDom = main.dom();
164
385
  return {
165
- particlesJS,
166
- pJSDom
386
+ particlesJS: particlesJS,
387
+ pJSDom: pJSDom
167
388
  };
168
389
  };
169
390
  var MoveDirection;
@@ -263,6 +484,11 @@
263
484
  ThemeMode["dark"] = "dark";
264
485
  ThemeMode["light"] = "light";
265
486
  })(ThemeMode || (ThemeMode = {}));
487
+ var ResponsiveMode;
488
+ (function(ResponsiveMode) {
489
+ ResponsiveMode["screen"] = "screen";
490
+ ResponsiveMode["canvas"] = "canvas";
491
+ })(ResponsiveMode || (ResponsiveMode = {}));
266
492
  var AnimationStatus;
267
493
  (function(AnimationStatus) {
268
494
  AnimationStatus[AnimationStatus["increasing"] = 0] = "increasing";
@@ -463,7 +689,7 @@
463
689
  }
464
690
  function getValue(options) {
465
691
  const random = options.random;
466
- const {enable, minimumValue} = typeof random === "boolean" ? {
692
+ const {enable: enable, minimumValue: minimumValue} = typeof random === "boolean" ? {
467
693
  enable: random,
468
694
  minimumValue: 0
469
695
  } : random;
@@ -473,8 +699,8 @@
473
699
  const dx = pointA.x - pointB.x;
474
700
  const dy = pointA.y - pointB.y;
475
701
  return {
476
- dx,
477
- dy,
702
+ dx: dx,
703
+ dy: dy,
478
704
  distance: Math.sqrt(dx * dx + dy * dy)
479
705
  };
480
706
  }
@@ -1089,7 +1315,7 @@
1089
1315
  }
1090
1316
  const s = !v ? 0 : c / v;
1091
1317
  return {
1092
- h,
1318
+ h: h,
1093
1319
  s: s * 100,
1094
1320
  v: v * 100
1095
1321
  };
@@ -1498,8 +1724,8 @@
1498
1724
  class Range {
1499
1725
  constructor(x, y) {
1500
1726
  this.position = {
1501
- x,
1502
- y
1727
+ x: x,
1728
+ y: y
1503
1729
  };
1504
1730
  }
1505
1731
  }
@@ -1542,8 +1768,8 @@
1542
1768
  constructor(x, y, width, height) {
1543
1769
  super(x, y);
1544
1770
  this.size = {
1545
- height,
1546
- width
1771
+ height: height,
1772
+ width: width
1547
1773
  };
1548
1774
  }
1549
1775
  contains(point) {
@@ -2031,9 +2257,9 @@
2031
2257
  pathGenerators.set(type, pathGenerator);
2032
2258
  }
2033
2259
  }
2034
- static getInteractors(container) {
2260
+ static getInteractors(container, force = false) {
2035
2261
  let res = interactors.get(container);
2036
- if (!res) {
2262
+ if (!res || force) {
2037
2263
  res = [ ...interactorsInitializers.values() ].map((t => t(container)));
2038
2264
  interactors.set(container, res);
2039
2265
  }
@@ -2042,9 +2268,9 @@
2042
2268
  static addInteractor(name, initInteractor) {
2043
2269
  interactorsInitializers.set(name, initInteractor);
2044
2270
  }
2045
- static getUpdaters(container) {
2271
+ static getUpdaters(container, force = false) {
2046
2272
  let res = updaters.get(container);
2047
- if (!res) {
2273
+ if (!res || force) {
2048
2274
  res = [ ...updatersInitializers.values() ].map((t => t(container)));
2049
2275
  updaters.set(container, res);
2050
2276
  }
@@ -4301,21 +4527,21 @@
4301
4527
  const radius = this.getRadius();
4302
4528
  const outModes = this.options.move.outModes, fixHorizontal = outMode => {
4303
4529
  fixOutMode({
4304
- outMode,
4530
+ outMode: outMode,
4305
4531
  checkModes: [ OutMode.bounce, OutMode.bounceHorizontal ],
4306
4532
  coord: pos.x,
4307
4533
  maxCoord: container.canvas.size.width,
4308
4534
  setCb: value => pos.x += value,
4309
- radius
4535
+ radius: radius
4310
4536
  });
4311
4537
  }, fixVertical = outMode => {
4312
4538
  fixOutMode({
4313
- outMode,
4539
+ outMode: outMode,
4314
4540
  checkModes: [ OutMode.bounce, OutMode.bounceVertical ],
4315
4541
  coord: pos.y,
4316
4542
  maxCoord: container.canvas.size.height,
4317
4543
  setCb: value => pos.y += value,
4318
- radius
4544
+ radius: radius
4319
4545
  });
4320
4546
  };
4321
4547
  fixHorizontal((_c = outModes.left) !== null && _c !== void 0 ? _c : outModes.default);
@@ -4397,9 +4623,12 @@
4397
4623
  class InteractionManager {
4398
4624
  constructor(container) {
4399
4625
  this.container = container;
4400
- const interactors = Plugins.getInteractors(container);
4401
4626
  this.externalInteractors = [];
4402
4627
  this.particleInteractors = [];
4628
+ this.init();
4629
+ }
4630
+ init() {
4631
+ const interactors = Plugins.getInteractors(this.container, true);
4403
4632
  for (const interactor of interactors) {
4404
4633
  switch (interactor.type) {
4405
4634
  case InteractorType.External:
@@ -4432,7 +4661,7 @@
4432
4661
  }
4433
4662
  function applyDistance(particle) {
4434
4663
  const initialPosition = particle.initialPosition;
4435
- const {dx, dy} = getDistances(initialPosition, particle.position);
4664
+ const {dx: dx, dy: dy} = getDistances(initialPosition, particle.position);
4436
4665
  const dxFixed = Math.abs(dx), dyFixed = Math.abs(dy);
4437
4666
  const hDistance = particle.retina.maxDistance.horizontal;
4438
4667
  const vDistance = particle.retina.maxDistance.vertical;
@@ -4621,7 +4850,7 @@
4621
4850
  const canvasSize = this.container.canvas.size;
4622
4851
  this.linksColors = new Map;
4623
4852
  this.quadTree = new QuadTree(new Rectangle(-canvasSize.width / 4, -canvasSize.height / 4, canvasSize.width * 3 / 2, canvasSize.height * 3 / 2), 4);
4624
- this.updaters = Plugins.getUpdaters(container);
4853
+ this.updaters = Plugins.getUpdaters(container, true);
4625
4854
  }
4626
4855
  get count() {
4627
4856
  return this.array.length;
@@ -4635,6 +4864,8 @@
4635
4864
  this.freqs.links = new Map;
4636
4865
  this.freqs.triangles = new Map;
4637
4866
  let handled = false;
4867
+ this.updaters = Plugins.getUpdaters(container, true);
4868
+ this.interactionManager.init();
4638
4869
  for (const [, plugin] of container.plugins) {
4639
4870
  if (plugin.particlesInitialization !== undefined) {
4640
4871
  handled = plugin.particlesInitialization();
@@ -5678,7 +5909,7 @@
5678
5909
  }
5679
5910
  class Interactivity {
5680
5911
  constructor() {
5681
- this.detectsOn = InteractivityDetect.canvas;
5912
+ this.detectsOn = InteractivityDetect.window;
5682
5913
  this.events = new Events;
5683
5914
  this.modes = new Modes;
5684
5915
  }
@@ -5746,7 +5977,7 @@
5746
5977
  color: data.cover
5747
5978
  } : data.cover;
5748
5979
  this.cover.load(cover.color !== undefined ? cover : {
5749
- color
5980
+ color: color
5750
5981
  });
5751
5982
  }
5752
5983
  if (data.enable !== undefined) {
@@ -5829,8 +6060,8 @@
5829
6060
  }
5830
6061
  class FullScreen {
5831
6062
  constructor() {
5832
- this.enable = false;
5833
- this.zIndex = -1;
6063
+ this.enable = true;
6064
+ this.zIndex = 0;
5834
6065
  }
5835
6066
  load(data) {
5836
6067
  if (!data) {
@@ -5897,6 +6128,7 @@
5897
6128
  constructor() {
5898
6129
  this.maxWidth = Infinity;
5899
6130
  this.options = {};
6131
+ this.mode = ResponsiveMode.canvas;
5900
6132
  }
5901
6133
  load(data) {
5902
6134
  if (!data) {
@@ -5905,6 +6137,13 @@
5905
6137
  if (data.maxWidth !== undefined) {
5906
6138
  this.maxWidth = data.maxWidth;
5907
6139
  }
6140
+ if (data.mode !== undefined) {
6141
+ if (data.mode === ResponsiveMode.screen) {
6142
+ this.mode = ResponsiveMode.screen;
6143
+ } else {
6144
+ this.mode = ResponsiveMode.canvas;
6145
+ }
6146
+ }
5908
6147
  if (data.options !== undefined) {
5909
6148
  this.options = deepExtend({}, data.options);
5910
6149
  }
@@ -6043,7 +6282,7 @@
6043
6282
  }
6044
6283
  setResponsive(width, pxRatio, defaultOptions) {
6045
6284
  this.load(defaultOptions);
6046
- const responsiveOptions = this.responsive.find((t => t.maxWidth * pxRatio > width));
6285
+ const responsiveOptions = this.responsive.find((t => t.mode === ResponsiveMode.screen && screen ? t.maxWidth * pxRatio > screen.availWidth : t.maxWidth * pxRatio > width));
6047
6286
  this.load(responsiveOptions === null || responsiveOptions === void 0 ? void 0 : responsiveOptions.options);
6048
6287
  return responsiveOptions === null || responsiveOptions === void 0 ? void 0 : responsiveOptions.maxWidth;
6049
6288
  }
@@ -6069,10 +6308,12 @@
6069
6308
  this.zLayers = 100;
6070
6309
  this.pageHidden = false;
6071
6310
  this._sourceOptions = sourceOptions;
6311
+ this._initialSourceOptions = sourceOptions;
6072
6312
  this.retina = new Retina(this);
6073
6313
  this.canvas = new Canvas(this);
6074
6314
  this.particles = new Particles(this);
6075
6315
  this.drawer = new FrameManager(this);
6316
+ this.presets = presets;
6076
6317
  this.pathGenerator = {
6077
6318
  generate: () => {
6078
6319
  const v = Vector.create(0, 0);
@@ -6101,17 +6342,6 @@
6101
6342
  this.density = 1;
6102
6343
  this._options = new Options;
6103
6344
  this.actualOptions = new Options;
6104
- for (const preset of presets) {
6105
- this._options.load(Plugins.getPreset(preset));
6106
- }
6107
- const shapes = Plugins.getSupportedShapes();
6108
- for (const type of shapes) {
6109
- const drawer = Plugins.getShapeDrawer(type);
6110
- if (drawer) {
6111
- this.drawers.set(type, drawer);
6112
- }
6113
- }
6114
- this._options.load(this._sourceOptions);
6115
6345
  this.eventListeners = new EventListeners(this);
6116
6346
  if (typeof IntersectionObserver !== "undefined" && IntersectionObserver) {
6117
6347
  this.intersectionObserver = new IntersectionObserver((entries => this.intersectionManager(entries)));
@@ -6253,6 +6483,7 @@
6253
6483
  this.particles.linksColors = new Map;
6254
6484
  delete this.particles.grabLineColor;
6255
6485
  delete this.particles.linksColor;
6486
+ this._sourceOptions = this._options;
6256
6487
  }
6257
6488
  async loadTheme(name) {
6258
6489
  this.currentTheme = name;
@@ -6366,6 +6597,19 @@
6366
6597
  return false;
6367
6598
  }
6368
6599
  async init() {
6600
+ this._options = new Options;
6601
+ for (const preset of this.presets) {
6602
+ this._options.load(Plugins.getPreset(preset));
6603
+ }
6604
+ const shapes = Plugins.getSupportedShapes();
6605
+ for (const type of shapes) {
6606
+ const drawer = Plugins.getShapeDrawer(type);
6607
+ if (drawer) {
6608
+ this.drawers.set(type, drawer);
6609
+ }
6610
+ }
6611
+ this._options.load(this._initialSourceOptions);
6612
+ this._options.load(this._sourceOptions);
6369
6613
  this.actualOptions = new Options;
6370
6614
  this.actualOptions.load(this._options);
6371
6615
  this.retina.init();
@@ -6452,7 +6696,7 @@
6452
6696
  static async loadOptions(params) {
6453
6697
  var _a, _b, _c;
6454
6698
  const tagId = (_a = params.tagId) !== null && _a !== void 0 ? _a : `tsparticles${Math.floor(Math.random() * 1e4)}`;
6455
- const {options, index} = params;
6699
+ const {options: options, index: index} = params;
6456
6700
  let domContainer = (_b = params.element) !== null && _b !== void 0 ? _b : document.getElementById(tagId);
6457
6701
  if (!domContainer) {
6458
6702
  domContainer = document.createElement("div");
@@ -6502,7 +6746,7 @@
6502
6746
  return newItem;
6503
6747
  }
6504
6748
  static async loadRemoteOptions(params) {
6505
- const {url: jsonUrl, index} = params;
6749
+ const {url: jsonUrl, index: index} = params;
6506
6750
  const url = jsonUrl instanceof Array ? itemFromArray(jsonUrl, index) : jsonUrl;
6507
6751
  if (!url) {
6508
6752
  return;
@@ -6516,13 +6760,13 @@
6516
6760
  return await Loader.loadOptions({
6517
6761
  tagId: params.tagId,
6518
6762
  element: params.element,
6519
- index,
6763
+ index: index,
6520
6764
  options: data
6521
6765
  });
6522
6766
  }
6523
6767
  static load(tagId, options, index) {
6524
6768
  const params = {
6525
- index
6769
+ index: index
6526
6770
  };
6527
6771
  if (typeof tagId === "string") {
6528
6772
  params.tagId = tagId;
@@ -6538,7 +6782,7 @@
6538
6782
  }
6539
6783
  static async set(id, domContainer, options, index) {
6540
6784
  const params = {
6541
- index
6785
+ index: index
6542
6786
  };
6543
6787
  if (typeof id === "string") {
6544
6788
  params.tagId = id;
@@ -6567,8 +6811,8 @@
6567
6811
  }
6568
6812
  return await Loader.loadRemoteOptions({
6569
6813
  tagId: id,
6570
- url,
6571
- index
6814
+ url: url,
6815
+ index: index
6572
6816
  });
6573
6817
  }
6574
6818
  static async setJSON(id, domContainer, jsonUrl, index) {
@@ -6585,9 +6829,9 @@
6585
6829
  }
6586
6830
  return await Loader.loadRemoteOptions({
6587
6831
  tagId: newId,
6588
- url,
6832
+ url: url,
6589
6833
  index: newIndex,
6590
- element
6834
+ element: element
6591
6835
  });
6592
6836
  }
6593
6837
  static setOnClickHandler(callback) {
@@ -6647,34 +6891,45 @@
6647
6891
  domItem(index) {
6648
6892
  return Loader.domItem(index);
6649
6893
  }
6650
- addShape(shape, drawer, init, afterEffect, destroy) {
6894
+ async refresh() {
6895
+ for (const instance of this.dom()) {
6896
+ await instance.refresh();
6897
+ }
6898
+ }
6899
+ async addShape(shape, drawer, init, afterEffect, destroy) {
6651
6900
  let customDrawer;
6652
6901
  if (typeof drawer === "function") {
6653
6902
  customDrawer = {
6654
- afterEffect,
6655
- destroy,
6903
+ afterEffect: afterEffect,
6904
+ destroy: destroy,
6656
6905
  draw: drawer,
6657
- init
6906
+ init: init
6658
6907
  };
6659
6908
  } else {
6660
6909
  customDrawer = drawer;
6661
6910
  }
6662
6911
  Plugins.addShapeDrawer(shape, customDrawer);
6912
+ await this.refresh();
6663
6913
  }
6664
- addPreset(preset, options, override = false) {
6914
+ async addPreset(preset, options, override = false) {
6665
6915
  Plugins.addPreset(preset, options, override);
6916
+ await this.refresh();
6666
6917
  }
6667
- addPlugin(plugin) {
6918
+ async addPlugin(plugin) {
6668
6919
  Plugins.addPlugin(plugin);
6920
+ await this.refresh();
6669
6921
  }
6670
- addPathGenerator(name, generator) {
6922
+ async addPathGenerator(name, generator) {
6671
6923
  Plugins.addPathGenerator(name, generator);
6924
+ await this.refresh();
6672
6925
  }
6673
- addInteractor(name, interactorInitializer) {
6926
+ async addInteractor(name, interactorInitializer) {
6674
6927
  Plugins.addInteractor(name, interactorInitializer);
6928
+ await this.refresh();
6675
6929
  }
6676
- addParticleUpdater(name, updaterInitializer) {
6930
+ async addParticleUpdater(name, updaterInitializer) {
6677
6931
  Plugins.addParticleUpdater(name, updaterInitializer);
6932
+ await this.refresh();
6678
6933
  }
6679
6934
  }
6680
6935
  _Main_initialized = new WeakMap;
@@ -6686,8 +6941,8 @@
6686
6941
  context.arc(0, 0, radius, 0, Math.PI * 2, false);
6687
6942
  }
6688
6943
  }
6689
- function loadCircleShape(tsParticles) {
6690
- tsParticles.addShape("circle", new CircleDrawer);
6944
+ async function loadCircleShape(tsParticles) {
6945
+ await tsParticles.addShape("circle", new CircleDrawer);
6691
6946
  }
6692
6947
  class LifeUpdater {
6693
6948
  constructor(container) {
@@ -6748,8 +7003,8 @@
6748
7003
  life.duration = getRangeValue(lifeOptions.duration.value) * 1e3;
6749
7004
  }
6750
7005
  }
6751
- function loadLifeUpdater(tsParticles) {
6752
- tsParticles.addParticleUpdater("life", (container => new LifeUpdater(container)));
7006
+ async function loadLifeUpdater(tsParticles) {
7007
+ await tsParticles.addParticleUpdater("life", (container => new LifeUpdater(container)));
6753
7008
  }
6754
7009
  class ExternalInteractorBase {
6755
7010
  constructor(container) {
@@ -6791,8 +7046,8 @@
6791
7046
  }
6792
7047
  }
6793
7048
  }
6794
- function loadExternalConnectInteraction(tsParticles) {
6795
- tsParticles.addInteractor("externalConnect", (container => new Connector(container)));
7049
+ async function loadExternalConnectInteraction(tsParticles) {
7050
+ await tsParticles.addInteractor("externalConnect", (container => new Connector(container)));
6796
7051
  }
6797
7052
  function checkDestroy(particle, value, minValue, maxValue) {
6798
7053
  switch (particle.options.opacity.animation.destroy) {
@@ -6903,8 +7158,8 @@
6903
7158
  updateOpacity(particle, delta);
6904
7159
  }
6905
7160
  }
6906
- function loadOpacityUpdater(tsParticles) {
6907
- tsParticles.addParticleUpdater("opacity", (container => new OpacityUpdater(container)));
7161
+ async function loadOpacityUpdater(tsParticles) {
7162
+ await tsParticles.addParticleUpdater("opacity", (container => new OpacityUpdater(container)));
6908
7163
  }
6909
7164
  function loadImage(source) {
6910
7165
  return new Promise(((resolve, reject) => {
@@ -6913,7 +7168,7 @@
6913
7168
  return;
6914
7169
  }
6915
7170
  const image = {
6916
- source,
7171
+ source: source,
6917
7172
  type: source.substr(source.length - 3)
6918
7173
  };
6919
7174
  const img = new Image;
@@ -6932,7 +7187,7 @@
6932
7187
  throw new Error("Error tsParticles - No image.src");
6933
7188
  }
6934
7189
  const image = {
6935
- source,
7190
+ source: source,
6936
7191
  type: source.substr(source.length - 3)
6937
7192
  };
6938
7193
  if (image.type !== "svg") {
@@ -6946,7 +7201,7 @@
6946
7201
  return image;
6947
7202
  }
6948
7203
  function replaceColorSvg(imageShape, color, opacity) {
6949
- const {svgData} = imageShape;
7204
+ const {svgData: svgData} = imageShape;
6950
7205
  if (!svgData) {
6951
7206
  return "";
6952
7207
  }
@@ -7150,8 +7405,8 @@
7150
7405
  const close = (_g = imageData.close) !== null && _g !== void 0 ? _g : particle.close;
7151
7406
  const imageShape = {
7152
7407
  image: imageRes,
7153
- fill,
7154
- close
7408
+ fill: fill,
7409
+ close: close
7155
7410
  };
7156
7411
  particle.image = imageShape.image;
7157
7412
  particle.fill = imageShape.fill;
@@ -7159,10 +7414,10 @@
7159
7414
  }
7160
7415
  }
7161
7416
  _ImageDrawer_images = new WeakMap;
7162
- function loadImageShape(tsParticles) {
7417
+ async function loadImageShape(tsParticles) {
7163
7418
  const imageDrawer = new ImageDrawer;
7164
- tsParticles.addShape("image", imageDrawer);
7165
- tsParticles.addShape("images", imageDrawer);
7419
+ await tsParticles.addShape("image", imageDrawer);
7420
+ await tsParticles.addShape("images", imageDrawer);
7166
7421
  }
7167
7422
  class PolygonDrawerBase {
7168
7423
  getSidesCount(particle) {
@@ -7231,15 +7486,15 @@
7231
7486
  };
7232
7487
  }
7233
7488
  }
7234
- function loadGenericPolygonShape(tsParticles) {
7235
- tsParticles.addShape("polygon", new PolygonDrawer);
7489
+ async function loadGenericPolygonShape(tsParticles) {
7490
+ await tsParticles.addShape("polygon", new PolygonDrawer);
7236
7491
  }
7237
- function loadTriangleShape(tsParticles) {
7238
- tsParticles.addShape("triangle", new TriangleDrawer);
7492
+ async function loadTriangleShape(tsParticles) {
7493
+ await tsParticles.addShape("triangle", new TriangleDrawer);
7239
7494
  }
7240
- function loadPolygonShape(tsParticles) {
7241
- loadGenericPolygonShape(tsParticles);
7242
- loadTriangleShape(tsParticles);
7495
+ async function loadPolygonShape(tsParticles) {
7496
+ await loadGenericPolygonShape(tsParticles);
7497
+ await loadTriangleShape(tsParticles);
7243
7498
  }
7244
7499
  var ProcessBubbleType;
7245
7500
  (function(ProcessBubbleType) {
@@ -7479,8 +7734,8 @@
7479
7734
  }
7480
7735
  }
7481
7736
  }
7482
- function loadExternalBubbleInteraction(tsParticles) {
7483
- tsParticles.addInteractor("externalBubble", (container => new Bubbler(container)));
7737
+ async function loadExternalBubbleInteraction(tsParticles) {
7738
+ await tsParticles.addInteractor("externalBubble", (container => new Bubbler(container)));
7484
7739
  }
7485
7740
  class Attractor extends ExternalInteractorBase {
7486
7741
  constructor(container) {
@@ -7517,7 +7772,7 @@
7517
7772
  const attractOptions = container.actualOptions.interactivity.modes.attract;
7518
7773
  const query = container.particles.quadTree.query(area);
7519
7774
  for (const particle of query) {
7520
- const {dx, dy, distance} = getDistances(particle.position, position);
7775
+ const {dx: dx, dy: dy, distance: distance} = getDistances(particle.position, position);
7521
7776
  const velocity = attractOptions.speed * attractOptions.factor;
7522
7777
  const attractFactor = clamp(calcEasing(1 - distance / attractRadius, attractOptions.easing) * velocity, 0, attractOptions.maxSpeed);
7523
7778
  const normVec = Vector.create(distance === 0 ? velocity : dx / distance * attractFactor, distance === 0 ? velocity : dy / distance * attractFactor);
@@ -7548,8 +7803,8 @@
7548
7803
  return;
7549
7804
  }
7550
7805
  }
7551
- function loadExternalAttractInteraction(tsParticles) {
7552
- tsParticles.addInteractor("externalAttract", (container => new Attractor(container)));
7806
+ async function loadExternalAttractInteraction(tsParticles) {
7807
+ await tsParticles.addInteractor("externalAttract", (container => new Attractor(container)));
7553
7808
  }
7554
7809
  class Grabber extends ExternalInteractorBase {
7555
7810
  constructor(container) {
@@ -7591,8 +7846,8 @@
7591
7846
  }
7592
7847
  }
7593
7848
  }
7594
- function loadExternalGrabInteraction(tsParticles) {
7595
- tsParticles.addInteractor("externalGrab", (container => new Grabber(container)));
7849
+ async function loadExternalGrabInteraction(tsParticles) {
7850
+ await tsParticles.addInteractor("externalGrab", (container => new Grabber(container)));
7596
7851
  }
7597
7852
  class StarDrawer {
7598
7853
  getSidesCount(particle) {
@@ -7614,8 +7869,8 @@
7614
7869
  }
7615
7870
  }
7616
7871
  }
7617
- function loadStarShape(tsParticles) {
7618
- tsParticles.addShape("star", new StarDrawer);
7872
+ async function loadStarShape(tsParticles) {
7873
+ await tsParticles.addShape("star", new StarDrawer);
7619
7874
  }
7620
7875
  class ParticlesInteractorBase {
7621
7876
  constructor(container) {
@@ -7634,7 +7889,7 @@
7634
7889
  if (p1 === p2 || !p2.options.move.attract.enable || p2.destroyed || p2.spawning) {
7635
7890
  continue;
7636
7891
  }
7637
- const pos2 = p2.getPosition(), {dx, dy} = getDistances(pos1, pos2), rotate = p1.options.move.attract.rotate, ax = dx / (rotate.x * 1e3), ay = dy / (rotate.y * 1e3), p1Factor = p2.size.value / p1.size.value, p2Factor = 1 / p1Factor;
7892
+ const pos2 = p2.getPosition(), {dx: dx, dy: dy} = getDistances(pos1, pos2), rotate = p1.options.move.attract.rotate, ax = dx / (rotate.x * 1e3), ay = dy / (rotate.y * 1e3), p1Factor = p2.size.value / p1.size.value, p2Factor = 1 / p1Factor;
7638
7893
  p1.velocity.x -= ax * p1Factor;
7639
7894
  p1.velocity.y -= ay * p1Factor;
7640
7895
  p2.velocity.x += ax * p2Factor;
@@ -7646,8 +7901,8 @@
7646
7901
  }
7647
7902
  reset() {}
7648
7903
  }
7649
- function loadParticlesAttractInteraction(tsParticles) {
7650
- tsParticles.addInteractor("particlesAttract", (container => new Attractor_Attractor(container)));
7904
+ async function loadParticlesAttractInteraction(tsParticles) {
7905
+ await tsParticles.addInteractor("particlesAttract", (container => new Attractor_Attractor(container)));
7651
7906
  }
7652
7907
  const fixFactor = Math.sqrt(2);
7653
7908
  class SquareDrawer {
@@ -7658,10 +7913,10 @@
7658
7913
  context.rect(-radius / fixFactor, -radius / fixFactor, radius * 2 / fixFactor, radius * 2 / fixFactor);
7659
7914
  }
7660
7915
  }
7661
- function loadSquareShape(tsParticles) {
7916
+ async function loadSquareShape(tsParticles) {
7662
7917
  const drawer = new SquareDrawer;
7663
- tsParticles.addShape("edge", drawer);
7664
- tsParticles.addShape("square", drawer);
7918
+ await tsParticles.addShape("edge", drawer);
7919
+ await tsParticles.addShape("square", drawer);
7665
7920
  }
7666
7921
  function updateColorValue(delta, value, valueAnimation, max, decrease) {
7667
7922
  var _a;
@@ -7733,8 +7988,8 @@
7733
7988
  updateStrokeColor(particle, delta);
7734
7989
  }
7735
7990
  }
7736
- function loadStrokeColorUpdater(tsParticles) {
7737
- tsParticles.addParticleUpdater("strokeColor", (container => new StrokeColorUpdater(container)));
7991
+ async function loadStrokeColorUpdater(tsParticles) {
7992
+ await tsParticles.addParticleUpdater("strokeColor", (container => new StrokeColorUpdater(container)));
7738
7993
  }
7739
7994
  function ColorUpdater_updateColorValue(delta, value, valueAnimation, max, decrease) {
7740
7995
  var _a;
@@ -7793,8 +8048,8 @@
7793
8048
  updateColor(particle, delta);
7794
8049
  }
7795
8050
  }
7796
- function loadColorUpdater(tsParticles) {
7797
- tsParticles.addParticleUpdater("color", (container => new ColorUpdater(container)));
8051
+ async function loadColorUpdater(tsParticles) {
8052
+ await tsParticles.addParticleUpdater("color", (container => new ColorUpdater(container)));
7798
8053
  }
7799
8054
  function bounce(p1, p2) {
7800
8055
  circleBounce(circleBounceDataFromParticle(p1), circleBounceDataFromParticle(p2));
@@ -7893,8 +8148,8 @@
7893
8148
  }
7894
8149
  }
7895
8150
  }
7896
- function loadParticlesCollisionsInteraction(tsParticles) {
7897
- tsParticles.addInteractor("particlesCollisions", (container => new Collider(container)));
8151
+ async function loadParticlesCollisionsInteraction(tsParticles) {
8152
+ await tsParticles.addInteractor("particlesCollisions", (container => new Collider(container)));
7898
8153
  }
7899
8154
  function updateAngle(particle, delta) {
7900
8155
  var _a;
@@ -7971,8 +8226,8 @@
7971
8226
  updateAngle(particle, delta);
7972
8227
  }
7973
8228
  }
7974
- function loadAngleUpdater(tsParticles) {
7975
- tsParticles.addParticleUpdater("angle", (container => new AngleUpdater(container)));
8229
+ async function loadAngleUpdater(tsParticles) {
8230
+ await tsParticles.addParticleUpdater("angle", (container => new AngleUpdater(container)));
7976
8231
  }
7977
8232
  function bounceHorizontal(data) {
7978
8233
  if (!(data.outMode === OutMode.bounce || data.outMode === OutMode.bounceHorizontal || data.outMode === "bounceHorizontal" || data.outMode === OutMode.split)) {
@@ -8127,22 +8382,22 @@
8127
8382
  }
8128
8383
  const pos = particle.getPosition(), offset = particle.offset, size = particle.getRadius(), bounds = calculateBounds(pos, size), canvasSize = container.canvas.size;
8129
8384
  bounceHorizontal({
8130
- particle,
8131
- outMode,
8132
- direction,
8133
- bounds,
8134
- canvasSize,
8135
- offset,
8136
- size
8385
+ particle: particle,
8386
+ outMode: outMode,
8387
+ direction: direction,
8388
+ bounds: bounds,
8389
+ canvasSize: canvasSize,
8390
+ offset: offset,
8391
+ size: size
8137
8392
  });
8138
8393
  bounceVertical({
8139
- particle,
8140
- outMode,
8141
- direction,
8142
- bounds,
8143
- canvasSize,
8144
- offset,
8145
- size
8394
+ particle: particle,
8395
+ outMode: outMode,
8396
+ direction: direction,
8397
+ bounds: bounds,
8398
+ canvasSize: canvasSize,
8399
+ offset: offset,
8400
+ size: size
8146
8401
  });
8147
8402
  }
8148
8403
  none(particle, direction) {
@@ -8167,8 +8422,8 @@
8167
8422
  }
8168
8423
  }
8169
8424
  }
8170
- function loadOutModesUpdater(tsParticles) {
8171
- tsParticles.addParticleUpdater("outModes", (container => new OutOfCanvasUpdater(container)));
8425
+ async function loadOutModesUpdater(tsParticles) {
8426
+ await tsParticles.addParticleUpdater("outModes", (container => new OutOfCanvasUpdater(container)));
8172
8427
  }
8173
8428
  class Repulser extends ExternalInteractorBase {
8174
8429
  constructor(container) {
@@ -8218,7 +8473,7 @@
8218
8473
  var _a;
8219
8474
  const container = this.container, query = container.particles.quadTree.query(area), repulseOptions = container.actualOptions.interactivity.modes.repulse;
8220
8475
  for (const particle of query) {
8221
- const {dx, dy, distance} = getDistances(particle.position, position), velocity = ((_a = divRepulse === null || divRepulse === void 0 ? void 0 : divRepulse.speed) !== null && _a !== void 0 ? _a : repulseOptions.speed) * repulseOptions.factor, repulseFactor = clamp(calcEasing(1 - distance / repulseRadius, repulseOptions.easing) * velocity, 0, repulseOptions.maxSpeed), normVec = Vector.create(distance === 0 ? velocity : dx / distance * repulseFactor, distance === 0 ? velocity : dy / distance * repulseFactor);
8476
+ const {dx: dx, dy: dy, distance: distance} = getDistances(particle.position, position), velocity = ((_a = divRepulse === null || divRepulse === void 0 ? void 0 : divRepulse.speed) !== null && _a !== void 0 ? _a : repulseOptions.speed) * repulseOptions.factor, repulseFactor = clamp(calcEasing(1 - distance / repulseRadius, repulseOptions.easing) * velocity, 0, repulseOptions.maxSpeed), normVec = Vector.create(distance === 0 ? velocity : dx / distance * repulseFactor, distance === 0 ? velocity : dy / distance * repulseFactor);
8222
8477
  particle.position.addTo(normVec);
8223
8478
  }
8224
8479
  }
@@ -8240,7 +8495,7 @@
8240
8495
  }
8241
8496
  const range = new Circle(mouseClickPos.x, mouseClickPos.y, repulseRadius), query = container.particles.quadTree.query(range);
8242
8497
  for (const particle of query) {
8243
- const {dx, dy, distance} = getDistances(mouseClickPos, particle.position), d = distance ** 2, velocity = container.actualOptions.interactivity.modes.repulse.speed, force = -repulseRadius * velocity / d;
8498
+ const {dx: dx, dy: dy, distance: distance} = getDistances(mouseClickPos, particle.position), d = distance ** 2, velocity = container.actualOptions.interactivity.modes.repulse.speed, force = -repulseRadius * velocity / d;
8244
8499
  if (d <= repulseRadius) {
8245
8500
  container.repulse.particles.push(particle);
8246
8501
  const vect = Vector.create(dx, dy);
@@ -8256,8 +8511,8 @@
8256
8511
  }
8257
8512
  }
8258
8513
  }
8259
- function loadExternalRepulseInteraction(tsParticles) {
8260
- tsParticles.addInteractor("externalRepulse", (container => new Repulser(container)));
8514
+ async function loadExternalRepulseInteraction(tsParticles) {
8515
+ await tsParticles.addInteractor("externalRepulse", (container => new Repulser(container)));
8261
8516
  }
8262
8517
  class LineDrawer {
8263
8518
  getSidesCount() {
@@ -8268,8 +8523,8 @@
8268
8523
  context.lineTo(radius / 2, 0);
8269
8524
  }
8270
8525
  }
8271
- function loadLineShape(tsParticles) {
8272
- tsParticles.addShape("line", new LineDrawer);
8526
+ async function loadLineShape(tsParticles) {
8527
+ await tsParticles.addShape("line", new LineDrawer);
8273
8528
  }
8274
8529
  class Bouncer extends ExternalInteractorBase {
8275
8530
  constructor(container) {
@@ -8314,8 +8569,8 @@
8314
8569
  for (const particle of query) {
8315
8570
  if (area instanceof Circle) {
8316
8571
  circleBounce(circleBounceDataFromParticle(particle), {
8317
- position,
8318
- radius,
8572
+ position: position,
8573
+ radius: radius,
8319
8574
  mass: radius ** 2 * Math.PI / 2,
8320
8575
  velocity: Vector.origin,
8321
8576
  factor: Vector.origin
@@ -8326,8 +8581,8 @@
8326
8581
  }
8327
8582
  }
8328
8583
  }
8329
- function loadExternalBounceInteraction(tsParticles) {
8330
- tsParticles.addInteractor("externalBounce", (container => new Bouncer(container)));
8584
+ async function loadExternalBounceInteraction(tsParticles) {
8585
+ await tsParticles.addInteractor("externalBounce", (container => new Bouncer(container)));
8331
8586
  }
8332
8587
  const validTypes = [ "text", "character", "char" ];
8333
8588
  class TextDrawer {
@@ -8386,10 +8641,10 @@
8386
8641
  context.globalAlpha = 1;
8387
8642
  }
8388
8643
  }
8389
- function loadTextShape(tsParticles) {
8644
+ async function loadTextShape(tsParticles) {
8390
8645
  const drawer = new TextDrawer;
8391
8646
  for (const type of validTypes) {
8392
- tsParticles.addShape(type, drawer);
8647
+ await tsParticles.addShape(type, drawer);
8393
8648
  }
8394
8649
  }
8395
8650
  function getLinkDistance(pos1, pos2, optDistance, canvasSize, warp) {
@@ -8604,16 +8859,16 @@
8604
8859
  }
8605
8860
  loadOptions() {}
8606
8861
  }
8607
- function loadPlugin(tsParticles) {
8862
+ async function loadPlugin(tsParticles) {
8608
8863
  const plugin = new Plugin;
8609
- tsParticles.addPlugin(plugin);
8864
+ await tsParticles.addPlugin(plugin);
8610
8865
  }
8611
- function loadInteraction(tsParticles) {
8612
- tsParticles.addInteractor("particlesLinks", (container => new Linker(container)));
8866
+ async function loadInteraction(tsParticles) {
8867
+ await tsParticles.addInteractor("particlesLinks", (container => new Linker(container)));
8613
8868
  }
8614
- function loadParticlesLinksInteraction(tsParticles) {
8615
- loadInteraction(tsParticles);
8616
- loadPlugin(tsParticles);
8869
+ async function loadParticlesLinksInteraction(tsParticles) {
8870
+ await loadInteraction(tsParticles);
8871
+ await loadPlugin(tsParticles);
8617
8872
  }
8618
8873
  function SizeUpdater_checkDestroy(particle, value, minValue, maxValue) {
8619
8874
  switch (particle.options.size.animation.destroy) {
@@ -8680,38 +8935,38 @@
8680
8935
  updateSize(particle, delta);
8681
8936
  }
8682
8937
  }
8683
- function loadSizeUpdater(tsParticles) {
8684
- tsParticles.addParticleUpdater("size", (() => new SizeUpdater));
8685
- }
8686
- function loadSlim(tsParticles) {
8687
- loadExternalAttractInteraction(tsParticles);
8688
- loadExternalBounceInteraction(tsParticles);
8689
- loadExternalBubbleInteraction(tsParticles);
8690
- loadExternalConnectInteraction(tsParticles);
8691
- loadExternalGrabInteraction(tsParticles);
8692
- loadExternalRepulseInteraction(tsParticles);
8693
- loadParticlesAttractInteraction(tsParticles);
8694
- loadParticlesCollisionsInteraction(tsParticles);
8695
- loadParticlesLinksInteraction(tsParticles);
8696
- loadCircleShape(tsParticles);
8697
- loadImageShape(tsParticles);
8698
- loadLineShape(tsParticles);
8699
- loadPolygonShape(tsParticles);
8700
- loadSquareShape(tsParticles);
8701
- loadStarShape(tsParticles);
8702
- loadTextShape(tsParticles);
8703
- loadLifeUpdater(tsParticles);
8704
- loadOpacityUpdater(tsParticles);
8705
- loadSizeUpdater(tsParticles);
8706
- loadAngleUpdater(tsParticles);
8707
- loadColorUpdater(tsParticles);
8708
- loadStrokeColorUpdater(tsParticles);
8709
- loadOutModesUpdater(tsParticles);
8938
+ async function loadSizeUpdater(tsParticles) {
8939
+ await tsParticles.addParticleUpdater("size", (() => new SizeUpdater));
8940
+ }
8941
+ async function loadSlim(tsParticles) {
8942
+ await loadExternalAttractInteraction(tsParticles);
8943
+ await loadExternalBounceInteraction(tsParticles);
8944
+ await loadExternalBubbleInteraction(tsParticles);
8945
+ await loadExternalConnectInteraction(tsParticles);
8946
+ await loadExternalGrabInteraction(tsParticles);
8947
+ await loadExternalRepulseInteraction(tsParticles);
8948
+ await loadParticlesAttractInteraction(tsParticles);
8949
+ await loadParticlesCollisionsInteraction(tsParticles);
8950
+ await loadParticlesLinksInteraction(tsParticles);
8951
+ await loadCircleShape(tsParticles);
8952
+ await loadImageShape(tsParticles);
8953
+ await loadLineShape(tsParticles);
8954
+ await loadPolygonShape(tsParticles);
8955
+ await loadSquareShape(tsParticles);
8956
+ await loadStarShape(tsParticles);
8957
+ await loadTextShape(tsParticles);
8958
+ await loadLifeUpdater(tsParticles);
8959
+ await loadOpacityUpdater(tsParticles);
8960
+ await loadSizeUpdater(tsParticles);
8961
+ await loadAngleUpdater(tsParticles);
8962
+ await loadColorUpdater(tsParticles);
8963
+ await loadStrokeColorUpdater(tsParticles);
8964
+ await loadOutModesUpdater(tsParticles);
8710
8965
  }
8711
8966
  const tsParticles = new Main;
8712
8967
  tsParticles.init();
8968
+ const {particlesJS: particlesJS, pJSDom: pJSDom} = initPjs(tsParticles);
8713
8969
  loadSlim(tsParticles);
8714
- const {particlesJS, pJSDom} = initPjs(tsParticles);
8715
8970
  return __webpack_exports__;
8716
- })();
8971
+ }();
8717
8972
  }));