@tsparticles/engine 3.9.1 → 4.0.0-alpha.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (431) hide show
  1. package/638.min.js +2 -0
  2. package/638.min.js.LICENSE.txt +1 -0
  3. package/browser/Core/Canvas.js +126 -181
  4. package/browser/Core/Container.js +22 -18
  5. package/browser/Core/Engine.js +64 -54
  6. package/browser/Core/Particle.js +43 -48
  7. package/browser/Core/Particles.js +33 -24
  8. package/browser/Core/Retina.js +2 -3
  9. package/browser/Core/Utils/Constants.js +2 -2
  10. package/browser/Core/Utils/EventListeners.js +74 -64
  11. package/browser/Core/Utils/QuadTree.js +1 -1
  12. package/browser/Core/Utils/Ranges.js +2 -2
  13. package/browser/Core/Utils/Vectors.js +15 -21
  14. package/browser/Options/Classes/AnimatableColor.js +3 -3
  15. package/browser/Options/Classes/AnimationOptions.js +1 -1
  16. package/browser/Options/Classes/ColorAnimation.js +1 -1
  17. package/browser/Options/Classes/Options.js +13 -10
  18. package/browser/Options/Classes/Particles/Move/Move.js +1 -4
  19. package/browser/Options/Classes/Particles/Move/MoveAngle.js +1 -1
  20. package/browser/Options/Classes/Particles/Move/MoveAttract.js +1 -1
  21. package/browser/Options/Classes/Particles/Move/MoveGravity.js +1 -1
  22. package/browser/Options/Classes/Particles/Move/Spin.js +1 -1
  23. package/browser/Options/Classes/Particles/ParticlesOptions.js +0 -6
  24. package/browser/Options/Classes/Particles/Stroke.js +1 -1
  25. package/browser/Options/Classes/ValueWithRandom.js +1 -1
  26. package/browser/Utils/CanvasUtils.js +65 -21
  27. package/browser/Utils/ColorUtils.js +61 -45
  28. package/browser/Utils/EventDispatcher.js +3 -1
  29. package/browser/Utils/LogUtils.js +22 -0
  30. package/browser/Utils/{NumberUtils.js → MathUtils.js} +14 -7
  31. package/browser/Utils/Utils.js +23 -125
  32. package/browser/bundle.js +3 -3
  33. package/browser/export-types.js +1 -99
  34. package/browser/exports.js +2 -9
  35. package/browser/index.js +3 -7
  36. package/browser/initEngine.js +4 -0
  37. package/cjs/Core/Canvas.js +136 -195
  38. package/cjs/Core/Container.js +57 -57
  39. package/cjs/Core/Engine.js +77 -71
  40. package/cjs/Core/Interfaces/Colors.js +1 -2
  41. package/cjs/Core/Interfaces/IBounds.js +1 -2
  42. package/cjs/Core/Interfaces/IBubbleParticleData.js +1 -2
  43. package/cjs/Core/Interfaces/ICircleBouncer.js +1 -2
  44. package/cjs/Core/Interfaces/IColorManager.js +1 -2
  45. package/cjs/Core/Interfaces/IContainerInteractivity.js +1 -2
  46. package/cjs/Core/Interfaces/IContainerPlugin.js +1 -2
  47. package/cjs/Core/Interfaces/ICoordinates.js +1 -2
  48. package/cjs/Core/Interfaces/IDelta.js +1 -2
  49. package/cjs/Core/Interfaces/IDimension.js +1 -2
  50. package/cjs/Core/Interfaces/IDistance.js +1 -2
  51. package/cjs/Core/Interfaces/IDrawParticleParams.js +1 -2
  52. package/cjs/Core/Interfaces/IEffectDrawer.js +1 -2
  53. package/cjs/Core/Interfaces/IExternalInteractor.js +1 -2
  54. package/cjs/Core/Interfaces/IInteractor.js +1 -2
  55. package/cjs/Core/Interfaces/ILoadParams.js +1 -2
  56. package/cjs/Core/Interfaces/IMouseData.js +1 -2
  57. package/cjs/Core/Interfaces/IMovePathGenerator.js +1 -2
  58. package/cjs/Core/Interfaces/IParticleColorStyle.js +1 -2
  59. package/cjs/Core/Interfaces/IParticleHslAnimation.js +1 -2
  60. package/cjs/Core/Interfaces/IParticleLife.js +1 -2
  61. package/cjs/Core/Interfaces/IParticleMover.js +1 -2
  62. package/cjs/Core/Interfaces/IParticleRetinaProps.js +1 -2
  63. package/cjs/Core/Interfaces/IParticleRoll.js +1 -2
  64. package/cjs/Core/Interfaces/IParticleTransformValues.js +1 -2
  65. package/cjs/Core/Interfaces/IParticleUpdater.js +1 -2
  66. package/cjs/Core/Interfaces/IParticleValueAnimation.js +1 -2
  67. package/cjs/Core/Interfaces/IParticlesInteractor.js +1 -2
  68. package/cjs/Core/Interfaces/IPlugin.js +1 -2
  69. package/cjs/Core/Interfaces/IPositionFromSizeParams.js +1 -2
  70. package/cjs/Core/Interfaces/IRangeValue.js +1 -2
  71. package/cjs/Core/Interfaces/IShapeDrawData.js +1 -2
  72. package/cjs/Core/Interfaces/IShapeDrawer.js +1 -2
  73. package/cjs/Core/Interfaces/IShapeValues.js +1 -2
  74. package/cjs/Core/Interfaces/ISlowParticleData.js +1 -2
  75. package/cjs/Core/Particle.js +99 -108
  76. package/cjs/Core/Particles.js +63 -58
  77. package/cjs/Core/Retina.js +13 -18
  78. package/cjs/Core/Utils/Constants.js +3 -7
  79. package/cjs/Core/Utils/EventListeners.js +94 -88
  80. package/cjs/Core/Utils/ExternalInteractorBase.js +3 -7
  81. package/cjs/Core/Utils/InteractionManager.js +4 -8
  82. package/cjs/Core/Utils/ParticlesInteractorBase.js +3 -7
  83. package/cjs/Core/Utils/Point.js +1 -5
  84. package/cjs/Core/Utils/QuadTree.js +10 -14
  85. package/cjs/Core/Utils/Ranges.js +14 -20
  86. package/cjs/Core/Utils/Vectors.js +24 -35
  87. package/cjs/Enums/AnimationStatus.js +2 -5
  88. package/cjs/Enums/Directions/MoveDirection.js +2 -5
  89. package/cjs/Enums/Directions/OutModeDirection.js +2 -5
  90. package/cjs/Enums/Directions/RotateDirection.js +2 -5
  91. package/cjs/Enums/InteractivityDetect.js +2 -5
  92. package/cjs/Enums/Modes/AnimationMode.js +2 -5
  93. package/cjs/Enums/Modes/LimitMode.js +2 -5
  94. package/cjs/Enums/Modes/OutMode.js +2 -5
  95. package/cjs/Enums/Modes/PixelMode.js +2 -5
  96. package/cjs/Enums/Modes/ResponsiveMode.js +2 -5
  97. package/cjs/Enums/Modes/ThemeMode.js +2 -5
  98. package/cjs/Enums/Types/AlterType.js +2 -5
  99. package/cjs/Enums/Types/DestroyType.js +2 -5
  100. package/cjs/Enums/Types/DivType.js +2 -5
  101. package/cjs/Enums/Types/EasingType.js +2 -5
  102. package/cjs/Enums/Types/EventType.js +2 -5
  103. package/cjs/Enums/Types/GradientType.js +2 -5
  104. package/cjs/Enums/Types/InteractorType.js +2 -5
  105. package/cjs/Enums/Types/ParticleOutType.js +2 -5
  106. package/cjs/Enums/Types/StartValueType.js +2 -5
  107. package/cjs/Options/Classes/AnimatableColor.js +10 -14
  108. package/cjs/Options/Classes/AnimationOptions.js +14 -19
  109. package/cjs/Options/Classes/Background/Background.js +6 -10
  110. package/cjs/Options/Classes/ColorAnimation.js +6 -10
  111. package/cjs/Options/Classes/FullScreen/FullScreen.js +3 -7
  112. package/cjs/Options/Classes/HslAnimation.js +7 -11
  113. package/cjs/Options/Classes/Interactivity/Events/ClickEvent.js +3 -7
  114. package/cjs/Options/Classes/Interactivity/Events/DivEvent.js +5 -9
  115. package/cjs/Options/Classes/Interactivity/Events/Events.js +14 -18
  116. package/cjs/Options/Classes/Interactivity/Events/HoverEvent.js +5 -9
  117. package/cjs/Options/Classes/Interactivity/Events/Parallax.js +3 -7
  118. package/cjs/Options/Classes/Interactivity/Events/ResizeEvent.js +3 -7
  119. package/cjs/Options/Classes/Interactivity/Interactivity.js +9 -13
  120. package/cjs/Options/Classes/Interactivity/Modes/Modes.js +3 -7
  121. package/cjs/Options/Classes/ManualParticle.js +10 -14
  122. package/cjs/Options/Classes/Options.js +41 -42
  123. package/cjs/Options/Classes/OptionsColor.js +5 -9
  124. package/cjs/Options/Classes/Particles/Bounce/ParticlesBounce.js +6 -10
  125. package/cjs/Options/Classes/Particles/Bounce/ParticlesBounceFactor.js +2 -6
  126. package/cjs/Options/Classes/Particles/Effect/Effect.js +5 -9
  127. package/cjs/Options/Classes/Particles/Move/Move.js +26 -33
  128. package/cjs/Options/Classes/Particles/Move/MoveAngle.js +6 -10
  129. package/cjs/Options/Classes/Particles/Move/MoveAttract.js +5 -9
  130. package/cjs/Options/Classes/Particles/Move/MoveCenter.js +5 -9
  131. package/cjs/Options/Classes/Particles/Move/MoveGravity.js +6 -10
  132. package/cjs/Options/Classes/Particles/Move/OutModes.js +5 -9
  133. package/cjs/Options/Classes/Particles/Move/Path/MovePath.js +7 -11
  134. package/cjs/Options/Classes/Particles/Move/Spin.js +7 -11
  135. package/cjs/Options/Classes/Particles/Number/ParticlesDensity.js +3 -7
  136. package/cjs/Options/Classes/Particles/Number/ParticlesNumber.js +7 -11
  137. package/cjs/Options/Classes/Particles/Number/ParticlesNumberLimit.js +5 -9
  138. package/cjs/Options/Classes/Particles/Opacity/Opacity.js +6 -10
  139. package/cjs/Options/Classes/Particles/Opacity/OpacityAnimation.js +6 -10
  140. package/cjs/Options/Classes/Particles/ParticlesOptions.js +29 -39
  141. package/cjs/Options/Classes/Particles/Shape/Shape.js +5 -9
  142. package/cjs/Options/Classes/Particles/Size/Size.js +6 -10
  143. package/cjs/Options/Classes/Particles/Size/SizeAnimation.js +6 -10
  144. package/cjs/Options/Classes/Particles/Stroke.js +8 -12
  145. package/cjs/Options/Classes/Particles/ZIndex/ZIndex.js +4 -8
  146. package/cjs/Options/Classes/Responsive.js +13 -17
  147. package/cjs/Options/Classes/Theme/Theme.js +7 -11
  148. package/cjs/Options/Classes/Theme/ThemeDefault.js +5 -9
  149. package/cjs/Options/Classes/ValueWithRandom.js +12 -18
  150. package/cjs/Options/Interfaces/Background/IBackground.js +1 -2
  151. package/cjs/Options/Interfaces/FullScreen/IFullScreen.js +1 -2
  152. package/cjs/Options/Interfaces/IAnimatable.js +1 -2
  153. package/cjs/Options/Interfaces/IAnimatableColor.js +1 -2
  154. package/cjs/Options/Interfaces/IAnimation.js +1 -2
  155. package/cjs/Options/Interfaces/IColorAnimation.js +1 -2
  156. package/cjs/Options/Interfaces/IHslAnimation.js +1 -2
  157. package/cjs/Options/Interfaces/IManualParticle.js +1 -2
  158. package/cjs/Options/Interfaces/IOptionLoader.js +1 -2
  159. package/cjs/Options/Interfaces/IOptions.js +1 -2
  160. package/cjs/Options/Interfaces/IOptionsColor.js +1 -2
  161. package/cjs/Options/Interfaces/IResponsive.js +1 -2
  162. package/cjs/Options/Interfaces/IValueWithRandom.js +1 -2
  163. package/cjs/Options/Interfaces/Interactivity/Events/IClickEvent.js +1 -2
  164. package/cjs/Options/Interfaces/Interactivity/Events/IDivEvent.js +1 -2
  165. package/cjs/Options/Interfaces/Interactivity/Events/IEvents.js +1 -2
  166. package/cjs/Options/Interfaces/Interactivity/Events/IHoverEvent.js +1 -2
  167. package/cjs/Options/Interfaces/Interactivity/Events/IParallax.js +1 -2
  168. package/cjs/Options/Interfaces/Interactivity/Events/IResizeEvent.js +1 -2
  169. package/cjs/Options/Interfaces/Interactivity/IInteractivity.js +1 -2
  170. package/cjs/Options/Interfaces/Interactivity/Modes/IModeDiv.js +1 -2
  171. package/cjs/Options/Interfaces/Interactivity/Modes/IModes.js +1 -2
  172. package/cjs/Options/Interfaces/Particles/Bounce/IParticlesBounce.js +1 -2
  173. package/cjs/Options/Interfaces/Particles/Effect/IEffect.js +1 -2
  174. package/cjs/Options/Interfaces/Particles/IParticlesOptions.js +1 -2
  175. package/cjs/Options/Interfaces/Particles/IStroke.js +1 -2
  176. package/cjs/Options/Interfaces/Particles/Move/IMove.js +1 -2
  177. package/cjs/Options/Interfaces/Particles/Move/IMoveAngle.js +1 -2
  178. package/cjs/Options/Interfaces/Particles/Move/IMoveAttract.js +1 -2
  179. package/cjs/Options/Interfaces/Particles/Move/IMoveCenter.js +1 -2
  180. package/cjs/Options/Interfaces/Particles/Move/IMoveGravity.js +1 -2
  181. package/cjs/Options/Interfaces/Particles/Move/IOutModes.js +1 -2
  182. package/cjs/Options/Interfaces/Particles/Move/ISpin.js +1 -2
  183. package/cjs/Options/Interfaces/Particles/Move/Path/IMovePath.js +1 -2
  184. package/cjs/Options/Interfaces/Particles/Number/IParticlesDensity.js +1 -2
  185. package/cjs/Options/Interfaces/Particles/Number/IParticlesNumber.js +1 -2
  186. package/cjs/Options/Interfaces/Particles/Number/IParticlesNumberLimit.js +1 -2
  187. package/cjs/Options/Interfaces/Particles/Opacity/IOpacity.js +1 -2
  188. package/cjs/Options/Interfaces/Particles/Opacity/IOpacityAnimation.js +1 -2
  189. package/cjs/Options/Interfaces/Particles/Shape/IShape.js +1 -2
  190. package/cjs/Options/Interfaces/Particles/Size/ISize.js +1 -2
  191. package/cjs/Options/Interfaces/Particles/Size/ISizeAnimation.js +1 -2
  192. package/cjs/Options/Interfaces/Particles/ZIndex/IZIndex.js +1 -2
  193. package/cjs/Options/Interfaces/Theme/ITheme.js +1 -2
  194. package/cjs/Options/Interfaces/Theme/IThemeDefault.js +1 -2
  195. package/cjs/Types/CustomEventArgs.js +1 -2
  196. package/cjs/Types/CustomEventListener.js +1 -2
  197. package/cjs/Types/EasingFunction.js +1 -2
  198. package/cjs/Types/ExportResult.js +1 -2
  199. package/cjs/Types/ISourceOptions.js +1 -2
  200. package/cjs/Types/ParticlesGroups.js +1 -2
  201. package/cjs/Types/PathOptions.js +1 -2
  202. package/cjs/Types/RangeValue.js +1 -2
  203. package/cjs/Types/RecursivePartial.js +1 -2
  204. package/cjs/Types/ShapeData.js +1 -2
  205. package/cjs/Types/SingleOrMultiple.js +1 -2
  206. package/cjs/Utils/CanvasUtils.js +86 -55
  207. package/cjs/Utils/ColorUtils.js +136 -141
  208. package/cjs/Utils/EventDispatcher.js +8 -10
  209. package/cjs/Utils/LogUtils.js +22 -0
  210. package/{esm/Utils/NumberUtils.js → cjs/Utils/MathUtils.js} +14 -7
  211. package/cjs/Utils/OptionsUtils.js +4 -8
  212. package/cjs/Utils/TypeUtils.js +7 -16
  213. package/cjs/Utils/Utils.js +104 -239
  214. package/cjs/bundle.js +5 -22
  215. package/cjs/export-types.js +1 -115
  216. package/cjs/exports.js +77 -100
  217. package/cjs/index.js +5 -26
  218. package/cjs/initEngine.js +4 -0
  219. package/dist_browser_Core_Container_js.js +102 -0
  220. package/esm/Core/Canvas.js +126 -181
  221. package/esm/Core/Container.js +22 -18
  222. package/esm/Core/Engine.js +64 -54
  223. package/esm/Core/Particle.js +43 -48
  224. package/esm/Core/Particles.js +33 -24
  225. package/esm/Core/Retina.js +2 -3
  226. package/esm/Core/Utils/Constants.js +2 -2
  227. package/esm/Core/Utils/EventListeners.js +74 -64
  228. package/esm/Core/Utils/QuadTree.js +1 -1
  229. package/esm/Core/Utils/Ranges.js +2 -2
  230. package/esm/Core/Utils/Vectors.js +15 -21
  231. package/esm/Enums/RangeType.js +5 -0
  232. package/esm/Options/Classes/AnimatableColor.js +3 -3
  233. package/esm/Options/Classes/AnimationOptions.js +1 -1
  234. package/esm/Options/Classes/ColorAnimation.js +1 -1
  235. package/esm/Options/Classes/Options.js +13 -10
  236. package/esm/Options/Classes/Particles/Move/Move.js +1 -4
  237. package/esm/Options/Classes/Particles/Move/MoveAngle.js +1 -1
  238. package/esm/Options/Classes/Particles/Move/MoveAttract.js +1 -1
  239. package/esm/Options/Classes/Particles/Move/MoveGravity.js +1 -1
  240. package/esm/Options/Classes/Particles/Move/Spin.js +1 -1
  241. package/esm/Options/Classes/Particles/ParticlesOptions.js +0 -6
  242. package/esm/Options/Classes/Particles/Stroke.js +1 -1
  243. package/esm/Options/Classes/ValueWithRandom.js +1 -1
  244. package/esm/Utils/CanvasUtils.js +65 -21
  245. package/esm/Utils/ColorUtils.js +61 -45
  246. package/esm/Utils/EventDispatcher.js +3 -1
  247. package/esm/Utils/LogUtils.js +22 -0
  248. package/esm/Utils/MathUtils.js +158 -0
  249. package/esm/Utils/Utils.js +23 -125
  250. package/esm/bundle.js +3 -3
  251. package/esm/export-types.js +1 -99
  252. package/esm/exports.js +2 -9
  253. package/esm/index.js +3 -7
  254. package/esm/initEngine.js +4 -0
  255. package/package.json +3 -2
  256. package/report.html +5 -4
  257. package/scripts/install.js +204 -118
  258. package/tsparticles.engine.js +492 -451
  259. package/tsparticles.engine.min.js +1 -1
  260. package/tsparticles.engine.min.js.LICENSE.txt +1 -1
  261. package/types/Core/Canvas.d.ts +6 -9
  262. package/types/Core/Container.d.ts +1 -0
  263. package/types/Core/Engine.d.ts +20 -16
  264. package/types/Core/Interfaces/Colors.d.ts +46 -2
  265. package/types/Core/Interfaces/IColorManager.d.ts +1 -1
  266. package/types/Core/Interfaces/IContainerPlugin.d.ts +4 -0
  267. package/types/Core/Interfaces/IDrawParticleParams.d.ts +0 -4
  268. package/types/Core/Interfaces/IEffectDrawer.d.ts +2 -1
  269. package/types/Core/Interfaces/IShapeDrawData.d.ts +2 -0
  270. package/types/Core/Interfaces/IShapeDrawer.d.ts +1 -0
  271. package/types/Core/Particle.d.ts +4 -5
  272. package/types/Core/Particles.d.ts +1 -1
  273. package/types/Core/Utils/Constants.d.ts +2 -2
  274. package/types/Core/Utils/EventListeners.d.ts +1 -0
  275. package/types/Core/Utils/Vectors.d.ts +3 -3
  276. package/types/Options/Classes/Options.d.ts +1 -2
  277. package/types/Options/Classes/OptionsColor.d.ts +2 -2
  278. package/types/Options/Classes/Particles/Move/Move.d.ts +0 -2
  279. package/types/Options/Classes/Particles/ParticlesOptions.d.ts +0 -4
  280. package/types/Options/Interfaces/IOptions.d.ts +1 -2
  281. package/types/Options/Interfaces/Particles/IParticlesOptions.d.ts +0 -4
  282. package/types/Options/Interfaces/Particles/Move/IMove.d.ts +0 -2
  283. package/types/Utils/CanvasUtils.d.ts +4 -1
  284. package/types/Utils/ColorUtils.d.ts +2 -2
  285. package/types/Utils/LogUtils.d.ts +11 -0
  286. package/types/Utils/{NumberUtils.d.ts → MathUtils.d.ts} +2 -1
  287. package/types/Utils/TypeUtils.d.ts +2 -2
  288. package/types/Utils/Utils.d.ts +4 -16
  289. package/types/export-types.d.ts +91 -101
  290. package/types/exports.d.ts +2 -9
  291. package/types/index.d.ts +1 -1
  292. package/types/initEngine.d.ts +2 -0
  293. package/umd/Core/Canvas.js +123 -178
  294. package/umd/Core/Container.js +25 -21
  295. package/umd/Core/Engine.js +97 -53
  296. package/umd/Core/Particle.js +54 -59
  297. package/umd/Core/Particles.js +33 -24
  298. package/umd/Core/Retina.js +9 -10
  299. package/umd/Core/Utils/Constants.js +3 -3
  300. package/umd/Core/Utils/EventListeners.js +72 -62
  301. package/umd/Core/Utils/QuadTree.js +3 -3
  302. package/umd/Core/Utils/Ranges.js +4 -4
  303. package/umd/Core/Utils/Vectors.js +15 -21
  304. package/umd/Options/Classes/AnimatableColor.js +3 -3
  305. package/umd/Options/Classes/AnimationOptions.js +6 -6
  306. package/umd/Options/Classes/ColorAnimation.js +3 -3
  307. package/umd/Options/Classes/Options.js +16 -13
  308. package/umd/Options/Classes/Particles/Move/Move.js +5 -8
  309. package/umd/Options/Classes/Particles/Move/MoveAngle.js +4 -4
  310. package/umd/Options/Classes/Particles/Move/MoveAttract.js +3 -3
  311. package/umd/Options/Classes/Particles/Move/MoveGravity.js +4 -4
  312. package/umd/Options/Classes/Particles/Move/Spin.js +3 -3
  313. package/umd/Options/Classes/Particles/ParticlesOptions.js +1 -7
  314. package/umd/Options/Classes/Particles/Stroke.js +4 -4
  315. package/umd/Options/Classes/ValueWithRandom.js +3 -3
  316. package/umd/Utils/CanvasUtils.js +69 -22
  317. package/umd/Utils/ColorUtils.js +72 -56
  318. package/umd/Utils/EventDispatcher.js +3 -1
  319. package/umd/Utils/LogUtils.js +36 -0
  320. package/umd/Utils/{NumberUtils.js → MathUtils.js} +16 -8
  321. package/umd/Utils/Utils.js +36 -141
  322. package/umd/bundle.js +4 -4
  323. package/umd/export-types.js +1 -114
  324. package/umd/exports.js +3 -10
  325. package/umd/index.js +4 -8
  326. package/umd/{init.js → initEngine.js} +3 -5
  327. package/browser/Core/Interfaces/IRectSideResult.js +0 -1
  328. package/browser/Core/Interfaces/ITrailFillData.js +0 -1
  329. package/browser/Enums/Modes/CollisionMode.js +0 -6
  330. package/browser/Options/Classes/BackgroundMask/BackgroundMask.js +0 -24
  331. package/browser/Options/Classes/BackgroundMask/BackgroundMaskCover.js +0 -21
  332. package/browser/Options/Classes/Particles/Collisions/Collisions.js +0 -33
  333. package/browser/Options/Classes/Particles/Collisions/CollisionsAbsorb.js +0 -14
  334. package/browser/Options/Classes/Particles/Collisions/CollisionsOverlap.js +0 -18
  335. package/browser/Options/Classes/Particles/Move/MoveTrail.js +0 -23
  336. package/browser/Options/Classes/Particles/Move/MoveTrailFill.js +0 -15
  337. package/browser/Options/Classes/Particles/Shadow.js +0 -35
  338. package/browser/Options/Interfaces/BackgroundMask/IBackgroundMask.js +0 -1
  339. package/browser/Options/Interfaces/BackgroundMask/IBackgroundMaskCover.js +0 -1
  340. package/browser/Options/Interfaces/Particles/Collisions/ICollisions.js +0 -1
  341. package/browser/Options/Interfaces/Particles/Collisions/ICollisionsAbsorb.js +0 -1
  342. package/browser/Options/Interfaces/Particles/Collisions/ICollisionsOverlap.js +0 -1
  343. package/browser/Options/Interfaces/Particles/IShadow.js +0 -1
  344. package/browser/Options/Interfaces/Particles/Move/IMoveTrail.js +0 -1
  345. package/browser/Options/Interfaces/Particles/Move/IMoveTrailFill.js +0 -1
  346. package/browser/init.js +0 -6
  347. package/cjs/Core/Interfaces/IRectSideResult.js +0 -2
  348. package/cjs/Core/Interfaces/ITrailFillData.js +0 -2
  349. package/cjs/Enums/Modes/CollisionMode.js +0 -9
  350. package/cjs/Options/Classes/BackgroundMask/BackgroundMask.js +0 -28
  351. package/cjs/Options/Classes/BackgroundMask/BackgroundMaskCover.js +0 -25
  352. package/cjs/Options/Classes/Particles/Collisions/Collisions.js +0 -37
  353. package/cjs/Options/Classes/Particles/Collisions/CollisionsAbsorb.js +0 -18
  354. package/cjs/Options/Classes/Particles/Collisions/CollisionsOverlap.js +0 -22
  355. package/cjs/Options/Classes/Particles/Move/MoveTrail.js +0 -27
  356. package/cjs/Options/Classes/Particles/Move/MoveTrailFill.js +0 -19
  357. package/cjs/Options/Classes/Particles/Shadow.js +0 -39
  358. package/cjs/Options/Interfaces/BackgroundMask/IBackgroundMask.js +0 -2
  359. package/cjs/Options/Interfaces/BackgroundMask/IBackgroundMaskCover.js +0 -2
  360. package/cjs/Options/Interfaces/Particles/Collisions/ICollisions.js +0 -2
  361. package/cjs/Options/Interfaces/Particles/Collisions/ICollisionsAbsorb.js +0 -2
  362. package/cjs/Options/Interfaces/Particles/Collisions/ICollisionsOverlap.js +0 -2
  363. package/cjs/Options/Interfaces/Particles/IShadow.js +0 -2
  364. package/cjs/Options/Interfaces/Particles/Move/IMoveTrail.js +0 -2
  365. package/cjs/Options/Interfaces/Particles/Move/IMoveTrailFill.js +0 -2
  366. package/cjs/Types/RangeType.js +0 -8
  367. package/cjs/Utils/NumberUtils.js +0 -177
  368. package/cjs/init.js +0 -9
  369. package/esm/Core/Interfaces/IRectSideResult.js +0 -1
  370. package/esm/Core/Interfaces/ITrailFillData.js +0 -1
  371. package/esm/Enums/Modes/CollisionMode.js +0 -6
  372. package/esm/Options/Classes/BackgroundMask/BackgroundMask.js +0 -24
  373. package/esm/Options/Classes/BackgroundMask/BackgroundMaskCover.js +0 -21
  374. package/esm/Options/Classes/Particles/Collisions/Collisions.js +0 -33
  375. package/esm/Options/Classes/Particles/Collisions/CollisionsAbsorb.js +0 -14
  376. package/esm/Options/Classes/Particles/Collisions/CollisionsOverlap.js +0 -18
  377. package/esm/Options/Classes/Particles/Move/MoveTrail.js +0 -23
  378. package/esm/Options/Classes/Particles/Move/MoveTrailFill.js +0 -15
  379. package/esm/Options/Classes/Particles/Shadow.js +0 -35
  380. package/esm/Options/Interfaces/BackgroundMask/IBackgroundMask.js +0 -1
  381. package/esm/Options/Interfaces/BackgroundMask/IBackgroundMaskCover.js +0 -1
  382. package/esm/Options/Interfaces/Particles/Collisions/ICollisions.js +0 -1
  383. package/esm/Options/Interfaces/Particles/Collisions/ICollisionsAbsorb.js +0 -1
  384. package/esm/Options/Interfaces/Particles/Collisions/ICollisionsOverlap.js +0 -1
  385. package/esm/Options/Interfaces/Particles/IShadow.js +0 -1
  386. package/esm/Options/Interfaces/Particles/Move/IMoveTrail.js +0 -1
  387. package/esm/Options/Interfaces/Particles/Move/IMoveTrailFill.js +0 -1
  388. package/esm/init.js +0 -6
  389. package/types/Core/Interfaces/IRectSideResult.d.ts +0 -5
  390. package/types/Core/Interfaces/ITrailFillData.d.ts +0 -6
  391. package/types/Enums/Modes/CollisionMode.d.ts +0 -5
  392. package/types/Options/Classes/BackgroundMask/BackgroundMask.d.ts +0 -11
  393. package/types/Options/Classes/BackgroundMask/BackgroundMaskCover.d.ts +0 -11
  394. package/types/Options/Classes/Particles/Collisions/Collisions.d.ts +0 -18
  395. package/types/Options/Classes/Particles/Collisions/CollisionsAbsorb.d.ts +0 -8
  396. package/types/Options/Classes/Particles/Collisions/CollisionsOverlap.d.ts +0 -9
  397. package/types/Options/Classes/Particles/Move/MoveTrail.d.ts +0 -11
  398. package/types/Options/Classes/Particles/Move/MoveTrailFill.d.ts +0 -9
  399. package/types/Options/Classes/Particles/Shadow.d.ts +0 -13
  400. package/types/Options/Interfaces/BackgroundMask/IBackgroundMask.d.ts +0 -8
  401. package/types/Options/Interfaces/BackgroundMask/IBackgroundMaskCover.d.ts +0 -6
  402. package/types/Options/Interfaces/Particles/Collisions/ICollisions.d.ts +0 -13
  403. package/types/Options/Interfaces/Particles/Collisions/ICollisionsAbsorb.d.ts +0 -3
  404. package/types/Options/Interfaces/Particles/Collisions/ICollisionsOverlap.d.ts +0 -4
  405. package/types/Options/Interfaces/Particles/IShadow.d.ts +0 -8
  406. package/types/Options/Interfaces/Particles/Move/IMoveTrail.d.ts +0 -6
  407. package/types/Options/Interfaces/Particles/Move/IMoveTrailFill.d.ts +0 -5
  408. package/types/init.d.ts +0 -2
  409. package/umd/Core/Interfaces/IRectSideResult.js +0 -12
  410. package/umd/Core/Interfaces/ITrailFillData.js +0 -12
  411. package/umd/Enums/Modes/CollisionMode.js +0 -19
  412. package/umd/Options/Classes/BackgroundMask/BackgroundMask.js +0 -38
  413. package/umd/Options/Classes/BackgroundMask/BackgroundMaskCover.js +0 -35
  414. package/umd/Options/Classes/Particles/Collisions/Collisions.js +0 -47
  415. package/umd/Options/Classes/Particles/Collisions/CollisionsAbsorb.js +0 -28
  416. package/umd/Options/Classes/Particles/Collisions/CollisionsOverlap.js +0 -32
  417. package/umd/Options/Classes/Particles/Move/MoveTrail.js +0 -37
  418. package/umd/Options/Classes/Particles/Move/MoveTrailFill.js +0 -29
  419. package/umd/Options/Classes/Particles/Shadow.js +0 -49
  420. package/umd/Options/Interfaces/BackgroundMask/IBackgroundMask.js +0 -12
  421. package/umd/Options/Interfaces/BackgroundMask/IBackgroundMaskCover.js +0 -12
  422. package/umd/Options/Interfaces/Particles/Collisions/ICollisions.js +0 -12
  423. package/umd/Options/Interfaces/Particles/Collisions/ICollisionsAbsorb.js +0 -12
  424. package/umd/Options/Interfaces/Particles/Collisions/ICollisionsOverlap.js +0 -12
  425. package/umd/Options/Interfaces/Particles/IShadow.js +0 -12
  426. package/umd/Options/Interfaces/Particles/Move/IMoveTrail.js +0 -12
  427. package/umd/Options/Interfaces/Particles/Move/IMoveTrailFill.js +0 -12
  428. /package/browser/{Types → Enums}/RangeType.js +0 -0
  429. /package/{esm/Types → cjs/Enums}/RangeType.js +0 -0
  430. /package/types/{Types → Enums}/RangeType.d.ts +0 -0
  431. /package/umd/{Types → Enums}/RangeType.js +0 -0
@@ -1,162 +1,248 @@
1
1
  const path = require("path");
2
- const particlesJsFoundError = "particles.js-found";
3
- const reactParticlesJsFoundError = "react-particles-js-found";
4
-
5
- try {
6
- console.log("Thank you for installing tsParticles.");
7
- console.log("Remember to checkout the official website https://particles.js.org to explore some samples.");
8
- console.log("You can find more samples on CodePen too: https://codepen.io/collection/DPOage");
9
- console.log("If you need documentation you can find it here: https://particles.js.org/docs");
10
- console.log(
11
- "Don't forget to star the tsParticles repository, if you like the project and want to support it: https://github.com/tsparticles/tsparticles"
12
- );
13
-
14
- const pkgSettings = require(path.join(process.env.INIT_CWD, "package.json"));
15
-
16
- if (!pkgSettings) {
17
- return;
18
- }
19
2
 
20
- const dependencies = pkgSettings.dependencies;
3
+ function checkErrors() {
4
+ const particlesJsFoundError = "particles.js-found",
5
+ reactParticlesJsFoundError = "react-particles-js-found",
6
+ reactParticlesFoundError = "react-particles-found",
7
+ reactTsParticlesFoundError = "react-tsparticles-found",
8
+ angularParticlesFoundError = "ng-particles-found",
9
+ vue2ParticlesFoundError = "vue2-particles-found",
10
+ vue3ParticlesFoundError = "vue3-particles-found";
11
+
12
+ try {
13
+ console.log("Thank you for installing tsParticles.");
14
+ console.log("Remember to checkout the official website https://particles.js.org to explore some samples.");
15
+ console.log("You can find more samples on CodePen too: https://codepen.io/collection/DPOage");
16
+ console.log("If you need documentation you can find it here: https://particles.js.org/docs");
17
+ console.log(
18
+ "Don't forget to star the tsParticles repository, if you like the project and want to support it: https://github.com/tsparticles/tsparticles"
19
+ );
21
20
 
22
- if (!dependencies) {
23
- return;
24
- }
21
+ const pkgSettings = require(path.join(process.env.INIT_CWD, "package.json"));
25
22
 
26
- if (dependencies["particles.js"]) {
27
- console.error(
28
- "\x1b[31m%s\x1b[0m",
29
- "The package particles.js can't be installed with tsparticles, since it can lead to unexpected behaviors, please uninstall particles.js and remove it from the package.json file."
30
- );
23
+ if (!pkgSettings) {
24
+ return;
25
+ }
31
26
 
32
- throw new Error(reactParticlesJsFoundError);
33
- }
27
+ const dependencies = pkgSettings.dependencies;
34
28
 
35
- if (dependencies["particlesjs"]) {
36
- console.error(
37
- "\x1b[31m%s\x1b[0m",
38
- "The package particlesjs can't be installed with tsparticles, since it can lead to unexpected behaviors, please uninstall particlesjs and remove it from the package.json file."
39
- );
29
+ if (!dependencies) {
30
+ return;
31
+ }
40
32
 
41
- throw new Error(reactParticlesJsFoundError);
42
- }
33
+ if (dependencies["particles.js"]) {
34
+ console.error(
35
+ "\x1b[31m%s\x1b[0m",
36
+ "The package particles.js can't be installed with tsparticles, since it can lead to unexpected behaviors, please uninstall particles.js and remove it from the package.json file."
37
+ );
43
38
 
44
- if (dependencies["react-particles-js"]) {
45
- console.error(
46
- "\x1b[31m%s\x1b[0m",
47
- "The package react-particles-js has been deprecated and is not supported anymore."
48
- );
49
- console.error("\x1b[31m%s\x1b[0m", "Please consider switching to react-particles package.");
50
- console.error(
51
- "\x1b[31m%s\x1b[0m",
52
- "This error will be fixed once react-particles-js is removed from the package.json file."
53
- );
39
+ throw new Error(reactParticlesJsFoundError);
40
+ }
54
41
 
55
- throw new Error(reactParticlesJsFoundError);
56
- }
42
+ if (dependencies["particlesjs"]) {
43
+ console.error(
44
+ "\x1b[31m%s\x1b[0m",
45
+ "The package particlesjs can't be installed with tsparticles, since it can lead to unexpected behaviors, please uninstall particlesjs and remove it from the package.json file."
46
+ );
57
47
 
58
- if (dependencies["react"] || dependencies["next"]) {
59
- if (!dependencies["react-particles"]) {
60
- console.warn(
61
- "\x1b[43m\x1b[30m%s\x1b[0m",
62
- "Found React installed. Please download react-particles to use tsParticles with a component ready to use and easier to configure."
48
+ throw new Error(reactParticlesJsFoundError);
49
+ }
50
+
51
+ if (dependencies["react-particles-js"]) {
52
+ console.error(
53
+ "\x1b[31m%s\x1b[0m",
54
+ "The package react-particles-js has been deprecated and is not supported anymore."
63
55
  );
64
- console.log(
65
- "You can read more about the component here: https://github.com/tsparticles/tsparticles/blob/main/components/react/README.md"
56
+ console.error("\x1b[31m%s\x1b[0m", "Please consider switching to react-particles package.");
57
+ console.error(
58
+ "\x1b[31m%s\x1b[0m",
59
+ "This error will be fixed once react-particles-js is removed from the package.json file."
66
60
  );
61
+
62
+ throw new Error(reactParticlesJsFoundError);
67
63
  }
68
- }
69
64
 
70
- if (dependencies["@angular/core"]) {
71
- if (!dependencies["ng-particles"]) {
72
- console.warn(
73
- "\x1b[43m\x1b[30m%s\x1b[0m",
74
- "Found Angular installed. Please download ng-particles to use tsParticles with a component ready to use and easier to configure."
65
+ if (dependencies["react-tsparticles"]) {
66
+ console.error(
67
+ "\x1b[31m%s\x1b[0m",
68
+ "The package react-tsparticles has been deprecated and is not supported anymore."
69
+ );
70
+ console.error("\x1b[31m%s\x1b[0m", "Please consider switching to @tsparticles/react package.");
71
+ console.error(
72
+ "\x1b[31m%s\x1b[0m",
73
+ "This error will be fixed once react-tsparticles is removed from the package.json file."
75
74
  );
76
- console.log("You can read more about the component here: https://github.com/tsparticles/angular/#readme");
75
+
76
+ throw new Error(reactTsParticlesFoundError);
77
77
  }
78
- }
79
78
 
80
- if (dependencies["vue"] || dependencies["nuxt"]) {
81
- const vueVersion = dependencies["vue"];
82
- const nuxtVersion = dependencies["nuxt"];
79
+ if (dependencies["react-particles"]) {
80
+ console.error(
81
+ "\x1b[31m%s\x1b[0m",
82
+ "The package react-particles has been deprecated and is not supported anymore."
83
+ );
84
+ console.error("\x1b[31m%s\x1b[0m", "Please consider switching to @tsparticles/react package.");
85
+ console.error(
86
+ "\x1b[31m%s\x1b[0m",
87
+ "This error will be fixed once react-particles is removed from the package.json file."
88
+ );
83
89
 
84
- const vueMajor = (vueVersion || nuxtVersion).split(".")[0];
90
+ throw new Error(reactParticlesFoundError);
91
+ }
85
92
 
86
- if (vueMajor > 2) {
87
- if (!dependencies["vue3-particles"]) {
93
+ if (dependencies["react"] || dependencies["next"]) {
94
+ if (!dependencies["@tsparticles/react"]) {
88
95
  console.warn(
89
96
  "\x1b[43m\x1b[30m%s\x1b[0m",
90
- "Found Vue 3.x installed. Please Download vue3-particles to use tsParticles with a component ready to use and easier to configure."
97
+ "Found React installed. Please download react-particles to use tsParticles with a component ready to use and easier to configure."
91
98
  );
92
99
  console.log(
93
- "You can read more about the component here: https://github.com/tsparticles/tsparticles/blob/main/components/vue3/README.md"
100
+ "You can read more about the component here: https://github.com/tsparticles/react/#readme"
94
101
  );
95
102
  }
96
- } else {
97
- if (!dependencies["vue2-particles"]) {
103
+ }
104
+
105
+ if (dependencies["ng-particles"]) {
106
+ console.error(
107
+ "\x1b[31m%s\x1b[0m",
108
+ "The package ng-particles has been deprecated and is not supported anymore."
109
+ );
110
+ console.error("\x1b[31m%s\x1b[0m", "Please consider switching to @tsparticles/angular package.");
111
+ console.error(
112
+ "\x1b[31m%s\x1b[0m",
113
+ "This error will be fixed once ng-particles is removed from the package.json file."
114
+ );
115
+
116
+ throw new Error(angularParticlesFoundError);
117
+ }
118
+
119
+ if (dependencies["@angular/core"]) {
120
+ if (!dependencies["@tsparticles/angular"]) {
98
121
  console.warn(
99
122
  "\x1b[43m\x1b[30m%s\x1b[0m",
100
- "Found Vue 2.x installed. Please Download vue2-particles to use tsParticles with a component ready to use and easier to configure."
101
- );
102
- console.log(
103
- "You can read more about the component here: https://github.com/tsparticles/tsparticles/blob/main/components/vue/README.md"
123
+ "Found Angular installed. Please download ng-particles to use tsParticles with a component ready to use and easier to configure."
104
124
  );
125
+ console.log("You can read more about the component here: https://github.com/tsparticles/angular/#readme");
105
126
  }
106
127
  }
107
- }
108
128
 
109
- if (dependencies["svelte"]) {
110
- if (!dependencies["svelte-particles"]) {
111
- console.warn(
112
- "\x1b[43m\x1b[30m%s\x1b[0m",
113
- "Found Svelte installed. Please Download svelte-particles to use tsParticles with a component ready to use and easier to configure."
129
+ if (dependencies["vue3-particles"]) {
130
+ console.error(
131
+ "\x1b[31m%s\x1b[0m",
132
+ "The package vue3-particles has been deprecated and is not supported anymore."
114
133
  );
115
- console.log(
116
- "You can read more about the component here: https://github.com/tsparticles/tsparticles/blob/main/components/svelte/README.md"
134
+ console.error("\x1b[31m%s\x1b[0m", "Please consider switching to @tsparticles/vue3 package.");
135
+ console.error(
136
+ "\x1b[31m%s\x1b[0m",
137
+ "This error will be fixed once vue3-particles is removed from the package.json file."
117
138
  );
139
+
140
+ throw new Error(vue3ParticlesFoundError);
118
141
  }
119
- }
120
142
 
121
- if (dependencies["inferno"]) {
122
- if (!dependencies["inferno-particles"]) {
123
- console.warn(
124
- "\x1b[43m\x1b[30m%s\x1b[0m",
125
- "Found Inferno installed. Please Download inferno-particles to use tsParticles with a component ready to use and easier to configure."
143
+ if (dependencies["vue2-particles"]) {
144
+ console.error(
145
+ "\x1b[31m%s\x1b[0m",
146
+ "The package vue2-particles has been deprecated and is not supported anymore."
126
147
  );
127
- console.log(
128
- "You can read more about the component here: https://github.com/tsparticles/tsparticles/blob/main/components/inferno/README.md"
148
+ console.error("\x1b[31m%s\x1b[0m", "Please consider switching to @tsparticles/vue2 package.");
149
+ console.error(
150
+ "\x1b[31m%s\x1b[0m",
151
+ "This error will be fixed once vue2-particles is removed from the package.json file."
129
152
  );
153
+
154
+ throw new Error(vue2ParticlesFoundError);
130
155
  }
131
- }
132
156
 
133
- if (dependencies["preact"]) {
134
- if (!dependencies["preact-particles"]) {
135
- console.warn(
136
- "\x1b[43m\x1b[30m%s\x1b[0m",
137
- "Found Preact installed. Please Download preact-particles to use tsParticles with a component ready to use and easier to configure."
138
- );
139
- console.log(
140
- "You can read more about the component here: https://github.com/tsparticles/tsparticles/blob/main/components/preact/README.md"
141
- );
157
+ if (dependencies["vue"] || dependencies["nuxt"]) {
158
+ const vueVersion = dependencies["vue"],
159
+ nuxtVersion = dependencies["nuxt"],
160
+ vueMajor = (vueVersion || nuxtVersion).split(".")[0];
161
+
162
+ if (vueMajor > 2) {
163
+ if (!dependencies["@tsparticles/vue3"]) {
164
+ console.warn(
165
+ "\x1b[43m\x1b[30m%s\x1b[0m",
166
+ "Found Vue 3.x installed. Please Download @tsparticles/vue3 to use tsParticles with a component ready to use and easier to configure."
167
+ );
168
+ console.log(
169
+ "You can read more about the component here: https://github.com/tsparticles/vue3/#readme"
170
+ );
171
+ }
172
+ } else {
173
+ if (!dependencies["@tsparticles/vue2"]) {
174
+ console.warn(
175
+ "\x1b[43m\x1b[30m%s\x1b[0m",
176
+ "Found Vue 2.x installed. Please Download @tsparticles/vue2 to use tsParticles with a component ready to use and easier to configure."
177
+ );
178
+ console.log(
179
+ "You can read more about the component here: https://github.com/tsparticles/vue2/#readme"
180
+ );
181
+ }
182
+ }
142
183
  }
143
- }
144
184
 
145
- if (dependencies["jquery"]) {
146
- if (!dependencies["jquery-particles"]) {
147
- console.warn(
148
- "\x1b[43m\x1b[30m%s\x1b[0m",
149
- "Found jQuery installed. Please Download jquery-particles to use tsParticles with a plugin ready to use and easier to configure."
150
- );
151
- console.log(
152
- "You can read more about the plugin here: https://github.com/tsparticles/tsparticles/blob/main/components/jquery/README.md"
153
- );
185
+ if (dependencies["svelte"]) {
186
+ if (!dependencies["svelte-particles"]) {
187
+ console.warn(
188
+ "\x1b[43m\x1b[30m%s\x1b[0m",
189
+ "Found Svelte installed. Please Download svelte-particles to use tsParticles with a component ready to use and easier to configure."
190
+ );
191
+ console.log(
192
+ "You can read more about the component here: https://github.com/tsparticles/tsparticles/blob/main/components/svelte/README.md"
193
+ );
194
+ }
195
+ }
196
+
197
+ if (dependencies["inferno"]) {
198
+ if (!dependencies["inferno-particles"]) {
199
+ console.warn(
200
+ "\x1b[43m\x1b[30m%s\x1b[0m",
201
+ "Found Inferno installed. Please Download inferno-particles to use tsParticles with a component ready to use and easier to configure."
202
+ );
203
+ console.log(
204
+ "You can read more about the component here: https://github.com/tsparticles/tsparticles/blob/main/components/inferno/README.md"
205
+ );
206
+ }
207
+ }
208
+
209
+ if (dependencies["preact"]) {
210
+ if (!dependencies["preact-particles"]) {
211
+ console.warn(
212
+ "\x1b[43m\x1b[30m%s\x1b[0m",
213
+ "Found Preact installed. Please Download preact-particles to use tsParticles with a component ready to use and easier to configure."
214
+ );
215
+ console.log(
216
+ "You can read more about the component here: https://github.com/tsparticles/tsparticles/blob/main/components/preact/README.md"
217
+ );
218
+ }
219
+ }
220
+
221
+ if (dependencies["jquery"]) {
222
+ if (!dependencies["jquery-particles"]) {
223
+ console.warn(
224
+ "\x1b[43m\x1b[30m%s\x1b[0m",
225
+ "Found jQuery installed. Please Download jquery-particles to use tsParticles with a plugin ready to use and easier to configure."
226
+ );
227
+ console.log(
228
+ "You can read more about the plugin here: https://github.com/tsparticles/tsparticles/blob/main/components/jquery/README.md"
229
+ );
230
+ }
231
+ }
232
+ } catch (error) {
233
+ if (error.message === reactParticlesJsFoundError ||
234
+ error.message === particlesJsFoundError ||
235
+ error.message === reactParticlesFoundError ||
236
+ error.message === reactTsParticlesFoundError ||
237
+ error.message === angularParticlesFoundError ||
238
+ error.message === vue2ParticlesFoundError ||
239
+ error.message === vue3ParticlesFoundError
240
+ ) {
241
+ throw error;
154
242
  }
155
- }
156
- } catch (error) {
157
- if (error.message === reactParticlesJsFoundError || error.message === particlesJsFoundError) {
158
- throw error;
159
- }
160
243
 
161
- console.log(error);
244
+ console.log(error);
245
+ }
162
246
  }
247
+
248
+ checkErrors();