@tsparticles/engine 3.0.0-alpha.1 → 3.0.0-beta.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (329) hide show
  1. package/README.md +244 -188
  2. package/browser/Core/Canvas.js +271 -241
  3. package/browser/Core/Container.js +90 -106
  4. package/browser/Core/Engine.js +271 -0
  5. package/browser/Core/Particle.js +158 -165
  6. package/browser/Core/Particles.js +148 -143
  7. package/browser/Core/Retina.js +15 -13
  8. package/browser/Core/Utils/Circle.js +10 -6
  9. package/browser/Core/Utils/Constants.js +4 -3
  10. package/browser/Core/Utils/EventListeners.js +258 -234
  11. package/browser/Core/Utils/InteractionManager.js +6 -16
  12. package/browser/Core/Utils/QuadTree.js +14 -20
  13. package/browser/Core/Utils/Vector3d.js +17 -9
  14. package/browser/Options/Classes/AnimatableColor.js +2 -1
  15. package/browser/Options/Classes/AnimationOptions.js +4 -3
  16. package/browser/Options/Classes/BackgroundMask/BackgroundMask.js +2 -1
  17. package/browser/Options/Classes/ColorAnimation.js +4 -0
  18. package/browser/Options/Classes/Interactivity/Events/DivEvent.js +0 -24
  19. package/browser/Options/Classes/Interactivity/Events/Events.js +5 -24
  20. package/browser/Options/Classes/Interactivity/Interactivity.js +1 -8
  21. package/browser/Options/Classes/Interactivity/Modes/Modes.js +11 -8
  22. package/browser/Options/Classes/ManualParticle.js +5 -6
  23. package/browser/Options/Classes/Options.js +19 -39
  24. package/browser/Options/Classes/OptionsColor.js +3 -2
  25. package/browser/Options/Classes/Particles/Collisions/Collisions.js +5 -0
  26. package/browser/Options/Classes/Particles/Move/Move.js +11 -41
  27. package/browser/Options/Classes/Particles/Move/MoveAttract.js +9 -20
  28. package/browser/Options/Classes/Particles/Move/MoveTrail.js +2 -8
  29. package/browser/Options/Classes/Particles/Move/OutModes.js +4 -5
  30. package/browser/Options/Classes/Particles/Move/Spin.js +3 -1
  31. package/browser/Options/Classes/Particles/Number/ParticlesDensity.js +2 -21
  32. package/browser/Options/Classes/Particles/Number/ParticlesNumber.js +2 -9
  33. package/browser/Options/Classes/Particles/Opacity/Opacity.js +11 -7
  34. package/browser/Options/Classes/Particles/Opacity/OpacityAnimation.js +0 -9
  35. package/browser/Options/Classes/Particles/ParticlesOptions.js +6 -11
  36. package/browser/Options/Classes/Particles/Shape/Shape.js +9 -10
  37. package/browser/Options/Classes/Particles/Size/Size.js +11 -7
  38. package/browser/Options/Classes/Particles/Size/SizeAnimation.js +0 -9
  39. package/browser/Options/Classes/ValueWithRandom.js +4 -17
  40. package/browser/Utils/CanvasUtils.js +18 -54
  41. package/browser/Utils/ColorUtils.js +17 -19
  42. package/browser/Utils/EventDispatcher.js +7 -6
  43. package/browser/Utils/HslColorManager.js +2 -4
  44. package/browser/Utils/NumberUtils.js +41 -45
  45. package/browser/Utils/RgbColorManager.js +2 -4
  46. package/browser/Utils/Utils.js +133 -62
  47. package/browser/bundle.js +4 -97
  48. package/browser/export-types.js +97 -0
  49. package/browser/exports.js +89 -0
  50. package/browser/index.js +8 -199
  51. package/browser/init.js +12 -0
  52. package/cjs/Core/Canvas.js +269 -239
  53. package/cjs/Core/Container.js +90 -106
  54. package/cjs/Core/Engine.js +275 -0
  55. package/cjs/Core/Particle.js +157 -164
  56. package/cjs/Core/Particles.js +148 -143
  57. package/cjs/Core/Retina.js +15 -13
  58. package/cjs/Core/Utils/Circle.js +10 -6
  59. package/cjs/Core/Utils/Constants.js +5 -4
  60. package/cjs/Core/Utils/EventListeners.js +257 -233
  61. package/cjs/Core/Utils/InteractionManager.js +6 -16
  62. package/cjs/Core/Utils/QuadTree.js +14 -20
  63. package/cjs/Core/Utils/Vector3d.js +17 -9
  64. package/cjs/Options/Classes/AnimatableColor.js +2 -1
  65. package/cjs/Options/Classes/AnimationOptions.js +4 -3
  66. package/cjs/Options/Classes/BackgroundMask/BackgroundMask.js +2 -1
  67. package/cjs/Options/Classes/ColorAnimation.js +4 -0
  68. package/cjs/Options/Classes/Interactivity/Events/DivEvent.js +0 -24
  69. package/cjs/Options/Classes/Interactivity/Events/Events.js +5 -24
  70. package/cjs/Options/Classes/Interactivity/Interactivity.js +1 -8
  71. package/cjs/Options/Classes/Interactivity/Modes/Modes.js +11 -8
  72. package/cjs/Options/Classes/ManualParticle.js +5 -6
  73. package/cjs/Options/Classes/Options.js +18 -38
  74. package/cjs/Options/Classes/OptionsColor.js +3 -2
  75. package/cjs/Options/Classes/Particles/Collisions/Collisions.js +5 -0
  76. package/cjs/Options/Classes/Particles/Move/Move.js +11 -41
  77. package/cjs/Options/Classes/Particles/Move/MoveAttract.js +9 -20
  78. package/cjs/Options/Classes/Particles/Move/MoveTrail.js +2 -8
  79. package/cjs/Options/Classes/Particles/Move/OutModes.js +4 -5
  80. package/cjs/Options/Classes/Particles/Move/Spin.js +3 -1
  81. package/cjs/Options/Classes/Particles/Number/ParticlesDensity.js +2 -21
  82. package/cjs/Options/Classes/Particles/Number/ParticlesNumber.js +2 -9
  83. package/cjs/Options/Classes/Particles/Opacity/Opacity.js +10 -6
  84. package/cjs/Options/Classes/Particles/Opacity/OpacityAnimation.js +0 -9
  85. package/cjs/Options/Classes/Particles/ParticlesOptions.js +6 -11
  86. package/cjs/Options/Classes/Particles/Shape/Shape.js +9 -10
  87. package/cjs/Options/Classes/Particles/Size/Size.js +11 -7
  88. package/cjs/Options/Classes/Particles/Size/SizeAnimation.js +0 -9
  89. package/cjs/Options/Classes/ValueWithRandom.js +4 -17
  90. package/cjs/Utils/CanvasUtils.js +21 -58
  91. package/cjs/Utils/ColorUtils.js +16 -18
  92. package/cjs/Utils/EventDispatcher.js +7 -6
  93. package/cjs/Utils/HslColorManager.js +2 -4
  94. package/cjs/Utils/NumberUtils.js +41 -45
  95. package/cjs/Utils/RgbColorManager.js +2 -4
  96. package/cjs/Utils/Utils.js +146 -66
  97. package/cjs/bundle.js +4 -97
  98. package/cjs/export-types.js +113 -0
  99. package/cjs/exports.js +105 -0
  100. package/cjs/index.js +8 -199
  101. package/cjs/init.js +16 -0
  102. package/esm/Core/Canvas.js +271 -241
  103. package/esm/Core/Container.js +90 -106
  104. package/esm/Core/Engine.js +271 -0
  105. package/esm/Core/Particle.js +158 -165
  106. package/esm/Core/Particles.js +148 -143
  107. package/esm/Core/Retina.js +15 -13
  108. package/esm/Core/Utils/Circle.js +10 -6
  109. package/esm/Core/Utils/Constants.js +4 -3
  110. package/esm/Core/Utils/EventListeners.js +258 -234
  111. package/esm/Core/Utils/InteractionManager.js +6 -16
  112. package/esm/Core/Utils/QuadTree.js +14 -20
  113. package/esm/Core/Utils/Vector3d.js +17 -9
  114. package/esm/Options/Classes/AnimatableColor.js +2 -1
  115. package/esm/Options/Classes/AnimationOptions.js +4 -3
  116. package/esm/Options/Classes/BackgroundMask/BackgroundMask.js +2 -1
  117. package/esm/Options/Classes/ColorAnimation.js +4 -0
  118. package/esm/Options/Classes/Interactivity/Events/DivEvent.js +0 -24
  119. package/esm/Options/Classes/Interactivity/Events/Events.js +5 -24
  120. package/esm/Options/Classes/Interactivity/Interactivity.js +1 -8
  121. package/esm/Options/Classes/Interactivity/Modes/Modes.js +11 -8
  122. package/esm/Options/Classes/ManualParticle.js +5 -6
  123. package/esm/Options/Classes/Options.js +19 -39
  124. package/esm/Options/Classes/OptionsColor.js +3 -2
  125. package/esm/Options/Classes/Particles/Collisions/Collisions.js +5 -0
  126. package/esm/Options/Classes/Particles/Move/Move.js +11 -41
  127. package/esm/Options/Classes/Particles/Move/MoveAttract.js +9 -20
  128. package/esm/Options/Classes/Particles/Move/MoveTrail.js +2 -8
  129. package/esm/Options/Classes/Particles/Move/OutModes.js +4 -5
  130. package/esm/Options/Classes/Particles/Move/Spin.js +3 -1
  131. package/esm/Options/Classes/Particles/Number/ParticlesDensity.js +2 -21
  132. package/esm/Options/Classes/Particles/Number/ParticlesNumber.js +2 -9
  133. package/esm/Options/Classes/Particles/Opacity/Opacity.js +11 -7
  134. package/esm/Options/Classes/Particles/Opacity/OpacityAnimation.js +0 -9
  135. package/esm/Options/Classes/Particles/ParticlesOptions.js +6 -11
  136. package/esm/Options/Classes/Particles/Shape/Shape.js +9 -10
  137. package/esm/Options/Classes/Particles/Size/Size.js +11 -7
  138. package/esm/Options/Classes/Particles/Size/SizeAnimation.js +0 -9
  139. package/esm/Options/Classes/ValueWithRandom.js +4 -17
  140. package/esm/Utils/CanvasUtils.js +18 -54
  141. package/esm/Utils/ColorUtils.js +17 -19
  142. package/esm/Utils/EventDispatcher.js +7 -6
  143. package/esm/Utils/HslColorManager.js +2 -4
  144. package/esm/Utils/NumberUtils.js +41 -45
  145. package/esm/Utils/RgbColorManager.js +2 -4
  146. package/esm/Utils/Utils.js +133 -62
  147. package/esm/bundle.js +4 -97
  148. package/esm/export-types.js +97 -0
  149. package/esm/exports.js +89 -0
  150. package/esm/index.js +8 -199
  151. package/esm/init.js +12 -0
  152. package/package.json +17 -2
  153. package/report.html +4 -4
  154. package/scripts/install.js +90 -33
  155. package/tsparticles.engine.js +1832 -2007
  156. package/tsparticles.engine.min.js +1 -1
  157. package/tsparticles.engine.min.js.LICENSE.txt +1 -10
  158. package/types/Core/Canvas.d.ts +20 -16
  159. package/types/Core/Container.d.ts +10 -14
  160. package/types/Core/Engine.d.ts +71 -0
  161. package/types/Core/Interfaces/IContainerPlugin.d.ts +2 -0
  162. package/types/Core/Interfaces/ICoordinates.d.ts +2 -2
  163. package/types/Core/Interfaces/IDimension.d.ts +2 -2
  164. package/types/Core/Interfaces/IMovePathGenerator.d.ts +2 -1
  165. package/types/Core/Interfaces/IParticleUpdater.d.ts +0 -2
  166. package/types/Core/Interfaces/IParticleValueAnimation.d.ts +2 -0
  167. package/types/Core/Interfaces/IPlugin.d.ts +4 -3
  168. package/types/Core/Particle.d.ts +7 -7
  169. package/types/Core/Particles.d.ts +14 -11
  170. package/types/Core/Utils/Constants.d.ts +4 -3
  171. package/types/Core/Utils/EventListeners.d.ts +20 -18
  172. package/types/Core/Utils/InteractionManager.d.ts +1 -1
  173. package/types/Core/Utils/QuadTree.d.ts +2 -5
  174. package/types/Core/Utils/Vector3d.d.ts +2 -1
  175. package/types/Enums/Modes/{SizeMode.d.ts → PixelMode.d.ts} +1 -1
  176. package/types/Options/Classes/AnimationOptions.d.ts +1 -1
  177. package/types/Options/Classes/ColorAnimation.d.ts +1 -0
  178. package/types/Options/Classes/Interactivity/Events/DivEvent.d.ts +0 -6
  179. package/types/Options/Classes/Interactivity/Events/Events.d.ts +0 -6
  180. package/types/Options/Classes/Interactivity/Interactivity.d.ts +1 -3
  181. package/types/Options/Classes/Interactivity/Modes/Modes.d.ts +1 -1
  182. package/types/Options/Classes/Options.d.ts +5 -12
  183. package/types/Options/Classes/Particles/Collisions/Collisions.d.ts +2 -0
  184. package/types/Options/Classes/Particles/Move/Move.d.ts +0 -11
  185. package/types/Options/Classes/Particles/Move/MoveAttract.d.ts +0 -4
  186. package/types/Options/Classes/Particles/Move/MoveCenter.d.ts +2 -2
  187. package/types/Options/Classes/Particles/Move/MoveTrail.d.ts +0 -3
  188. package/types/Options/Classes/Particles/Number/ParticlesDensity.d.ts +0 -6
  189. package/types/Options/Classes/Particles/Number/ParticlesNumber.d.ts +0 -2
  190. package/types/Options/Classes/Particles/Opacity/Opacity.d.ts +4 -4
  191. package/types/Options/Classes/Particles/Opacity/OpacityAnimation.d.ts +0 -2
  192. package/types/Options/Classes/Particles/ParticlesOptions.d.ts +1 -1
  193. package/types/Options/Classes/Particles/Size/Size.d.ts +4 -4
  194. package/types/Options/Classes/Particles/Size/SizeAnimation.d.ts +0 -2
  195. package/types/Options/Classes/Responsive.d.ts +3 -3
  196. package/types/Options/Classes/Theme/Theme.d.ts +2 -2
  197. package/types/Options/Classes/ValueWithRandom.d.ts +2 -6
  198. package/types/Options/Interfaces/IAnimation.d.ts +1 -1
  199. package/types/Options/Interfaces/IOptions.d.ts +1 -4
  200. package/types/Options/Interfaces/IResponsive.d.ts +4 -3
  201. package/types/Options/Interfaces/Interactivity/Events/IDivEvent.d.ts +0 -3
  202. package/types/Options/Interfaces/Interactivity/Events/IEvents.d.ts +0 -3
  203. package/types/Options/Interfaces/Interactivity/IInteractivity.d.ts +0 -1
  204. package/types/Options/Interfaces/Interactivity/Modes/IModeDiv.d.ts +0 -1
  205. package/types/Options/Interfaces/Particles/Collisions/ICollisions.d.ts +2 -0
  206. package/types/Options/Interfaces/Particles/IStroke.d.ts +2 -1
  207. package/types/Options/Interfaces/Particles/Move/IMove.d.ts +0 -5
  208. package/types/Options/Interfaces/Particles/Move/IMoveAttract.d.ts +0 -2
  209. package/types/Options/Interfaces/Particles/Move/IMoveTrail.d.ts +0 -2
  210. package/types/Options/Interfaces/Particles/Number/IParticlesDensity.d.ts +0 -3
  211. package/types/Options/Interfaces/Particles/Number/IParticlesNumber.d.ts +0 -1
  212. package/types/Options/Interfaces/Particles/Opacity/IOpacity.d.ts +0 -1
  213. package/types/Options/Interfaces/Particles/Opacity/IOpacityAnimation.d.ts +0 -1
  214. package/types/Options/Interfaces/Particles/Size/ISize.d.ts +0 -1
  215. package/types/Options/Interfaces/Particles/Size/ISizeAnimation.d.ts +0 -1
  216. package/types/Options/Interfaces/Theme/ITheme.d.ts +3 -2
  217. package/types/Types/ExportResult.d.ts +5 -0
  218. package/types/Utils/CanvasUtils.d.ts +2 -5
  219. package/types/Utils/OptionsUtils.d.ts +1 -1
  220. package/types/Utils/Utils.d.ts +22 -4
  221. package/types/bundle.d.ts +2 -91
  222. package/types/export-types.d.ts +107 -0
  223. package/types/exports.d.ts +89 -0
  224. package/types/index.d.ts +3 -204
  225. package/types/init.d.ts +2 -0
  226. package/umd/Core/Canvas.js +269 -239
  227. package/umd/Core/Container.js +91 -107
  228. package/umd/Core/Engine.js +285 -0
  229. package/umd/Core/Particle.js +158 -165
  230. package/umd/Core/Particles.js +149 -144
  231. package/umd/Core/Retina.js +15 -13
  232. package/umd/Core/Utils/Circle.js +11 -7
  233. package/umd/Core/Utils/Constants.js +5 -4
  234. package/umd/Core/Utils/EventListeners.js +257 -233
  235. package/umd/Core/Utils/InteractionManager.js +6 -16
  236. package/umd/Core/Utils/QuadTree.js +14 -20
  237. package/umd/Core/Utils/Vector3d.js +18 -10
  238. package/umd/Options/Classes/AnimatableColor.js +3 -2
  239. package/umd/Options/Classes/AnimationOptions.js +4 -3
  240. package/umd/Options/Classes/BackgroundMask/BackgroundMask.js +3 -2
  241. package/umd/Options/Classes/ColorAnimation.js +4 -0
  242. package/umd/Options/Classes/Interactivity/Events/DivEvent.js +1 -25
  243. package/umd/Options/Classes/Interactivity/Events/Events.js +6 -25
  244. package/umd/Options/Classes/Interactivity/Interactivity.js +1 -8
  245. package/umd/Options/Classes/Interactivity/Modes/Modes.js +11 -8
  246. package/umd/Options/Classes/ManualParticle.js +5 -6
  247. package/umd/Options/Classes/Options.js +18 -38
  248. package/umd/Options/Classes/OptionsColor.js +4 -3
  249. package/umd/Options/Classes/Particles/Collisions/Collisions.js +6 -1
  250. package/umd/Options/Classes/Particles/Move/Move.js +12 -42
  251. package/umd/Options/Classes/Particles/Move/MoveAttract.js +9 -20
  252. package/umd/Options/Classes/Particles/Move/MoveTrail.js +2 -8
  253. package/umd/Options/Classes/Particles/Move/OutModes.js +4 -5
  254. package/umd/Options/Classes/Particles/Move/Spin.js +3 -1
  255. package/umd/Options/Classes/Particles/Number/ParticlesDensity.js +2 -21
  256. package/umd/Options/Classes/Particles/Number/ParticlesNumber.js +2 -9
  257. package/umd/Options/Classes/Particles/Opacity/Opacity.js +10 -6
  258. package/umd/Options/Classes/Particles/Opacity/OpacityAnimation.js +0 -9
  259. package/umd/Options/Classes/Particles/ParticlesOptions.js +6 -11
  260. package/umd/Options/Classes/Particles/Shape/Shape.js +9 -10
  261. package/umd/Options/Classes/Particles/Size/Size.js +12 -8
  262. package/umd/Options/Classes/Particles/Size/SizeAnimation.js +0 -9
  263. package/umd/Options/Classes/ValueWithRandom.js +5 -18
  264. package/umd/Utils/CanvasUtils.js +21 -58
  265. package/umd/Utils/ColorUtils.js +16 -18
  266. package/umd/Utils/EventDispatcher.js +7 -6
  267. package/umd/Utils/HslColorManager.js +2 -4
  268. package/umd/Utils/NumberUtils.js +42 -46
  269. package/umd/Utils/RgbColorManager.js +2 -4
  270. package/umd/Utils/Utils.js +146 -66
  271. package/umd/bundle.js +5 -98
  272. package/umd/export-types.js +123 -0
  273. package/umd/exports.js +115 -0
  274. package/umd/index.js +9 -200
  275. package/umd/init.js +26 -0
  276. package/browser/Core/Utils/FrameManager.js +0 -42
  277. package/browser/Core/Utils/Plugins.js +0 -112
  278. package/browser/Options/Interfaces/Particles/Shape/IImageShape.js +0 -1
  279. package/browser/Options/Interfaces/Particles/Shape/IPolygonShape.js +0 -1
  280. package/browser/Options/Interfaces/Particles/Shape/IShapeValues.js +0 -1
  281. package/browser/Options/Interfaces/Particles/Shape/IStarShape.js +0 -1
  282. package/browser/engine.js +0 -175
  283. package/cjs/Core/Utils/FrameManager.js +0 -46
  284. package/cjs/Core/Utils/Plugins.js +0 -116
  285. package/cjs/Enums/Modes/SizeMode.js +0 -2
  286. package/cjs/Options/Interfaces/Particles/Shape/ICharacterShape.js +0 -2
  287. package/cjs/Options/Interfaces/Particles/Shape/IImageShape.js +0 -2
  288. package/cjs/Options/Interfaces/Particles/Shape/IPolygonShape.js +0 -2
  289. package/cjs/Options/Interfaces/Particles/Shape/IShapeValues.js +0 -17
  290. package/cjs/Options/Interfaces/Particles/Shape/IStarShape.js +0 -2
  291. package/cjs/engine.js +0 -179
  292. package/esm/Core/Interfaces/IParticleOverride.js +0 -1
  293. package/esm/Core/Interfaces/IParticlesMover.js +0 -1
  294. package/esm/Core/Utils/FrameManager.js +0 -42
  295. package/esm/Core/Utils/Plugins.js +0 -112
  296. package/esm/Enums/Modes/SizeMode.js +0 -1
  297. package/esm/Options/Interfaces/Particles/Shape/ICharacterShape.js +0 -1
  298. package/esm/Options/Interfaces/Particles/Shape/IImageShape.js +0 -1
  299. package/esm/Options/Interfaces/Particles/Shape/IPolygonShape.js +0 -1
  300. package/esm/Options/Interfaces/Particles/Shape/IShapeValues.js +0 -1
  301. package/esm/Options/Interfaces/Particles/Shape/IStarShape.js +0 -1
  302. package/esm/engine.js +0 -175
  303. package/types/Core/Interfaces/IParticleOverride.d.ts +0 -6
  304. package/types/Core/Interfaces/IParticlesMover.d.ts +0 -7
  305. package/types/Core/Utils/FrameManager.d.ts +0 -6
  306. package/types/Core/Utils/Plugins.d.ts +0 -51
  307. package/types/Options/Interfaces/Particles/Shape/ICharacterShape.d.ts +0 -8
  308. package/types/Options/Interfaces/Particles/Shape/IImageShape.d.ts +0 -8
  309. package/types/Options/Interfaces/Particles/Shape/IPolygonShape.d.ts +0 -5
  310. package/types/Options/Interfaces/Particles/Shape/IShapeValues.d.ts +0 -1
  311. package/types/Options/Interfaces/Particles/Shape/IStarShape.d.ts +0 -6
  312. package/types/engine.d.ts +0 -39
  313. package/umd/Core/Utils/FrameManager.js +0 -56
  314. package/umd/Core/Utils/Plugins.js +0 -126
  315. package/umd/Enums/Modes/SizeMode.js +0 -12
  316. package/umd/Options/Interfaces/Particles/Shape/ICharacterShape.js +0 -12
  317. package/umd/Options/Interfaces/Particles/Shape/IImageShape.js +0 -12
  318. package/umd/Options/Interfaces/Particles/Shape/IPolygonShape.js +0 -12
  319. package/umd/Options/Interfaces/Particles/Shape/IShapeValues.js +0 -27
  320. package/umd/Options/Interfaces/Particles/Shape/IStarShape.js +0 -12
  321. package/umd/engine.js +0 -189
  322. /package/browser/{Core/Interfaces/IParticleOverride.js → Enums/Modes/PixelMode.js} +0 -0
  323. /package/browser/{Core/Interfaces/IParticlesMover.js → Types/ExportResult.js} +0 -0
  324. /package/cjs/{Core/Interfaces/IParticleOverride.js → Enums/Modes/PixelMode.js} +0 -0
  325. /package/cjs/{Core/Interfaces/IParticlesMover.js → Types/ExportResult.js} +0 -0
  326. /package/{browser/Enums/Modes/SizeMode.js → esm/Enums/Modes/PixelMode.js} +0 -0
  327. /package/{browser/Options/Interfaces/Particles/Shape/ICharacterShape.js → esm/Types/ExportResult.js} +0 -0
  328. /package/umd/{Core/Interfaces/IParticleOverride.js → Enums/Modes/PixelMode.js} +0 -0
  329. /package/umd/{Core/Interfaces/IParticlesMover.js → Types/ExportResult.js} +0 -0
@@ -1,5 +1,5 @@
1
+ import type { PixelMode } from "../../Enums/Modes/PixelMode";
1
2
  import type { RangeValue } from "../../Types/RangeValue";
2
- import type { SizeMode } from "../../Enums/Modes/SizeMode";
3
3
  export interface ICoordinates {
4
4
  x: number;
5
5
  y: number;
@@ -15,7 +15,7 @@ export interface IRangedCoordinates3d extends IRangedCoordinates {
15
15
  z: RangeValue;
16
16
  }
17
17
  export interface ICoordinatesWithMode extends ICoordinates {
18
- mode: SizeMode;
18
+ mode: PixelMode | keyof typeof PixelMode;
19
19
  }
20
20
  export interface ICenterCoordinates extends ICoordinatesWithMode {
21
21
  radius: number;
@@ -1,8 +1,8 @@
1
- import type { SizeMode } from "../../Enums/Modes/SizeMode";
1
+ import type { PixelMode } from "../../Enums/Modes/PixelMode";
2
2
  export interface IDimension {
3
3
  height: number;
4
4
  width: number;
5
5
  }
6
6
  export interface IDimensionWithMode extends IDimension {
7
- mode: SizeMode;
7
+ mode: PixelMode | keyof typeof PixelMode;
8
8
  }
@@ -1,8 +1,9 @@
1
1
  import type { Container } from "../Container";
2
+ import type { IDelta } from "./IDelta";
2
3
  import type { Particle } from "../Particle";
3
4
  import type { Vector } from "../Utils/Vector";
4
5
  export interface IMovePathGenerator {
5
- generate: (particle: Particle) => Vector;
6
+ generate: (particle: Particle, delta: IDelta) => Vector;
6
7
  init: (container: Container) => void;
7
8
  reset: (particle: Particle) => void;
8
9
  update: () => void;
@@ -1,6 +1,5 @@
1
1
  import type { IDelta } from "./IDelta";
2
2
  import type { IParticleColorStyle } from "./IParticleColorStyle";
3
- import type { IParticleOverride } from "./IParticleOverride";
4
3
  import type { IParticleTransformValues } from "./IParticleTransformValues";
5
4
  import type { IParticlesOptions } from "../../Options/Interfaces/Particles/IParticlesOptions";
6
5
  import type { Particle } from "../Particle";
@@ -10,7 +9,6 @@ export interface IParticleUpdater {
10
9
  afterDraw?: (particle: Particle) => void;
11
10
  beforeDraw?: (particle: Particle) => void;
12
11
  getColorStyles?: (particle: Particle, context: CanvasRenderingContext2D, radius: number, opacity: number) => IParticleColorStyle;
13
- getOverrides?: (particle: Particle, context: CanvasRenderingContext2D, radius: number, opacity: number) => IParticleOverride;
14
12
  getTransformValues?: (particle: Particle) => IParticleTransformValues;
15
13
  loadOptions?: (options: ParticlesOptions, ...sources: (RecursivePartial<IParticlesOptions> | undefined)[]) => void;
16
14
  particleDestroyed?: (particle: Particle, override?: boolean) => void;
@@ -1,11 +1,13 @@
1
1
  import type { AnimationStatus } from "../../Enums/AnimationStatus";
2
2
  export interface IParticleValueAnimation<T> {
3
3
  decay?: number;
4
+ delayTime?: number;
4
5
  enable: boolean;
5
6
  initialValue?: number;
6
7
  loops?: number;
7
8
  maxLoops?: number;
8
9
  status?: AnimationStatus;
10
+ time?: number;
9
11
  value: T;
10
12
  velocity?: number;
11
13
  }
@@ -1,10 +1,11 @@
1
1
  import type { Container } from "../Container";
2
2
  import type { IContainerPlugin } from "./IContainerPlugin";
3
- import type { ISourceOptions } from "../../Types/ISourceOptions";
3
+ import type { IOptions } from "../../Options/Interfaces/IOptions";
4
4
  import type { Options } from "../../Options/Classes/Options";
5
+ import type { RecursivePartial } from "../../Types/RecursivePartial";
5
6
  export interface IPlugin {
6
7
  readonly id: string;
7
8
  getPlugin(container: Container): IContainerPlugin;
8
- loadOptions(options: Options, source?: ISourceOptions): void;
9
- needsPlugin(options?: ISourceOptions): boolean;
9
+ loadOptions(options: Options, source?: RecursivePartial<IOptions>): void;
10
+ needsPlugin(options?: RecursivePartial<IOptions>): boolean;
10
11
  }
@@ -1,7 +1,7 @@
1
1
  import type { ICenterCoordinates, ICoordinates, ICoordinates3d } from "./Interfaces/ICoordinates";
2
2
  import type { IHsl, IRgb } from "./Interfaces/Colors";
3
3
  import type { Container } from "./Container";
4
- import type { Engine } from "../engine";
4
+ import type { Engine } from "./Engine";
5
5
  import type { IBubbleParticleData } from "./Interfaces/IBubbleParticleData";
6
6
  import type { IDelta } from "./Interfaces/IDelta";
7
7
  import type { IMovePathGenerator } from "./Interfaces/IMovePathGenerator";
@@ -76,10 +76,10 @@ export declare class Particle implements IParticle {
76
76
  isInsideCanvas(): boolean;
77
77
  isVisible(): boolean;
78
78
  reset(): void;
79
- private _calcPosition;
80
- private _calculateVelocity;
81
- private _checkOverlap;
82
- private _getRollColor;
83
- private _initPosition;
84
- private _loadShapeData;
79
+ private readonly _calcPosition;
80
+ private readonly _calculateVelocity;
81
+ private readonly _checkOverlap;
82
+ private readonly _getRollColor;
83
+ private readonly _initPosition;
84
+ private readonly _loadShapeData;
85
85
  }
@@ -1,6 +1,6 @@
1
1
  import type { ClickMode } from "../Enums/Modes/ClickMode";
2
2
  import type { Container } from "./Container";
3
- import type { Engine } from "../engine";
3
+ import type { Engine } from "./Engine";
4
4
  import type { ICoordinates } from "./Interfaces/ICoordinates";
5
5
  import type { IDelta } from "./Interfaces/IDelta";
6
6
  import type { IMouseData } from "./Interfaces/IMouseData";
@@ -9,20 +9,20 @@ import { Particle } from "./Particle";
9
9
  import { QuadTree } from "./Utils/QuadTree";
10
10
  import type { RecursivePartial } from "../Types/RecursivePartial";
11
11
  export declare class Particles {
12
- private readonly container;
13
- array: Particle[];
14
12
  lastZIndex: number;
15
13
  limit: number;
16
- movers: import("./Interfaces/IParticleMover").IParticleMover[];
14
+ movers: import("..").IParticleMover[];
17
15
  needsSort: boolean;
18
16
  pool: Particle[];
19
17
  pushing?: boolean;
20
18
  quadTree: QuadTree;
21
19
  updaters: import("..").IParticleUpdater[];
22
- zArray: Particle[];
20
+ private _array;
21
+ private readonly _container;
23
22
  private readonly _engine;
24
- private readonly interactionManager;
25
- private nextId;
23
+ private readonly _interactionManager;
24
+ private _nextId;
25
+ private _zArray;
26
26
  constructor(engine: Engine, container: Container);
27
27
  get count(): number;
28
28
  addManualParticles(): void;
@@ -30,6 +30,9 @@ export declare class Particles {
30
30
  clear(): void;
31
31
  destroy(): void;
32
32
  draw(delta: IDelta): Promise<void>;
33
+ filter(condition: (particle: Particle) => boolean): Particle[];
34
+ find(condition: (particle: Particle) => boolean): Particle | undefined;
35
+ get(index: number): Particle | undefined;
33
36
  handleClickMode(mode: ClickMode | string): void;
34
37
  init(): void;
35
38
  push(nb: number, mouse?: IMouseData, overrideOptions?: RecursivePartial<IParticlesOptions>, group?: string): void;
@@ -39,8 +42,8 @@ export declare class Particles {
39
42
  removeQuantity(quantity: number, group?: string): void;
40
43
  setDensity(): void;
41
44
  update(delta: IDelta): Promise<void>;
42
- private _applyDensity;
43
- private _initDensityFactor;
44
- private _pushParticle;
45
- private _removeParticle;
45
+ private readonly _applyDensity;
46
+ private readonly _initDensityFactor;
47
+ private readonly _pushParticle;
48
+ private readonly _removeParticle;
46
49
  }
@@ -1,12 +1,13 @@
1
1
  export declare const generatedAttribute = "generated";
2
- export declare const touchEndEvent = "touchend";
3
2
  export declare const mouseDownEvent = "pointerdown";
4
3
  export declare const mouseUpEvent = "pointerup";
4
+ export declare const mouseLeaveEvent = "pointerleave";
5
+ export declare const mouseOutEvent = "pointerout";
5
6
  export declare const mouseMoveEvent = "pointermove";
6
7
  export declare const touchStartEvent = "touchstart";
8
+ export declare const touchEndEvent = "touchend";
7
9
  export declare const touchMoveEvent = "touchmove";
8
- export declare const mouseLeaveEvent = "pointerleave";
9
- export declare const mouseOutEvent = "pointerout";
10
10
  export declare const touchCancelEvent = "touchcancel";
11
11
  export declare const resizeEvent = "resize";
12
12
  export declare const visibilityChangeEvent = "visibilitychange";
13
+ export declare const errorPrefix = "tsParticles - Error";
@@ -1,25 +1,27 @@
1
1
  import type { Container } from "../Container";
2
2
  export declare class EventListeners {
3
3
  private readonly container;
4
- private canPush;
5
- private readonly handlers;
6
- private resizeObserver?;
7
- private resizeTimeout?;
4
+ private _canPush;
5
+ private readonly _handlers;
6
+ private _resizeObserver?;
7
+ private _resizeTimeout?;
8
+ private readonly _touches;
8
9
  constructor(container: Container);
9
10
  addListeners(): void;
10
11
  removeListeners(): void;
11
- private _doMouseTouchClick;
12
- private _handleClickMode;
13
- private _handleThemeChange;
14
- private _handleVisibilityChange;
15
- private _handleWindowResize;
16
- private _manageInteractivityEvents;
17
- private _manageListeners;
18
- private _manageMediaEvents;
19
- private _manageResizeEvent;
20
- private _manageVisibilityEvent;
21
- private _mouseDown;
22
- private _mouseTouchClick;
23
- private _mouseTouchFinish;
24
- private _mouseTouchMove;
12
+ private readonly _doMouseTouchClick;
13
+ private readonly _handleThemeChange;
14
+ private readonly _handleVisibilityChange;
15
+ private readonly _handleWindowResize;
16
+ private readonly _manageInteractivityListeners;
17
+ private readonly _manageListeners;
18
+ private readonly _manageMediaMatch;
19
+ private readonly _manageResize;
20
+ private readonly _mouseDown;
21
+ private readonly _mouseTouchClick;
22
+ private readonly _mouseTouchFinish;
23
+ private readonly _mouseTouchMove;
24
+ private readonly _touchEnd;
25
+ private readonly _touchEndClick;
26
+ private readonly _touchStart;
25
27
  }
@@ -1,6 +1,6 @@
1
1
  import type { ClickMode } from "../../Enums/Modes/ClickMode";
2
2
  import type { Container } from "../Container";
3
- import type { Engine } from "../../engine";
3
+ import type { Engine } from "../Engine";
4
4
  import type { IDelta } from "../Interfaces/IDelta";
5
5
  import type { Particle } from "../Particle";
6
6
  export declare class InteractionManager {
@@ -7,16 +7,13 @@ import { Rectangle } from "./Rectangle";
7
7
  export declare class QuadTree {
8
8
  readonly rectangle: Rectangle;
9
9
  readonly capacity: number;
10
- private _NE?;
11
- private _NW?;
12
- private _SE?;
13
- private _SW?;
14
10
  private _divided;
15
11
  private readonly _points;
12
+ private readonly _subs;
16
13
  constructor(rectangle: Rectangle, capacity: number);
17
14
  insert(point: Point): boolean;
18
15
  query(range: Range, check?: (particle: Particle) => boolean, found?: Particle[]): Particle[];
19
16
  queryCircle(position: ICoordinates, radius: number, check?: (particle: Particle) => boolean): Particle[];
20
17
  queryRectangle(position: ICoordinates, size: IDimension, check?: (particle: Particle) => boolean): Particle[];
21
- private subdivide;
18
+ private readonly _subdivide;
22
19
  }
@@ -21,9 +21,10 @@ export declare class Vector3d implements ICoordinates3d {
21
21
  getLengthSq(): number;
22
22
  mult(n: number): Vector3d;
23
23
  multTo(n: number): void;
24
+ normalize(): void;
24
25
  rotate(angle: number): Vector3d;
25
26
  setTo(c: ICoordinates): void;
26
27
  sub(v: Vector3d): Vector3d;
27
28
  subFrom(v: Vector3d): void;
28
- private updateFromAngle;
29
+ private readonly _updateFromAngle;
29
30
  }
@@ -1,4 +1,4 @@
1
- export declare const enum SizeMode {
1
+ export declare const enum PixelMode {
2
2
  precise = "precise",
3
3
  percent = "percent"
4
4
  }
@@ -7,6 +7,7 @@ import { StartValueType } from "../../Enums/Types/StartValueType";
7
7
  export declare class AnimationOptions implements IAnimation, IOptionLoader<IAnimation> {
8
8
  count: RangeValue;
9
9
  decay: RangeValue;
10
+ delay: RangeValue;
10
11
  enable: boolean;
11
12
  speed: RangeValue;
12
13
  sync: boolean;
@@ -14,7 +15,6 @@ export declare class AnimationOptions implements IAnimation, IOptionLoader<IAnim
14
15
  load(data?: RecursivePartial<IAnimation>): void;
15
16
  }
16
17
  export declare class RangedAnimationOptions extends AnimationOptions implements IOptionLoader<IRangedAnimation> {
17
- minimumValue?: number;
18
18
  mode: AnimationMode | keyof typeof AnimationMode;
19
19
  startValue: StartValueType | keyof typeof StartValueType;
20
20
  constructor();
@@ -5,6 +5,7 @@ import type { RecursivePartial } from "../../Types/RecursivePartial";
5
5
  export declare class ColorAnimation implements IColorAnimation, IOptionLoader<IColorAnimation> {
6
6
  count: RangeValue;
7
7
  decay: RangeValue;
8
+ delay: RangeValue;
8
9
  enable: boolean;
9
10
  offset: RangeValue;
10
11
  speed: RangeValue;
@@ -10,11 +10,5 @@ export declare class DivEvent implements IDivEvent, IOptionLoader<IDivEvent> {
10
10
  selectors: SingleOrMultiple<string>;
11
11
  type: DivType | keyof typeof DivType;
12
12
  constructor();
13
- get el(): SingleOrMultiple<string>;
14
- set el(value: SingleOrMultiple<string>);
15
- get elementId(): SingleOrMultiple<string>;
16
- set elementId(value: SingleOrMultiple<string>);
17
- get ids(): SingleOrMultiple<string>;
18
- set ids(value: SingleOrMultiple<string>);
19
13
  load(data?: RecursivePartial<IDivEvent>): void;
20
14
  }
@@ -12,11 +12,5 @@ export declare class Events implements IEvents, IOptionLoader<IEvents> {
12
12
  onHover: HoverEvent;
13
13
  resize: ResizeEvent;
14
14
  constructor();
15
- get onclick(): ClickEvent;
16
- set onclick(value: ClickEvent);
17
- get ondiv(): SingleOrMultiple<DivEvent>;
18
- set ondiv(value: SingleOrMultiple<DivEvent>);
19
- get onhover(): HoverEvent;
20
- set onhover(value: HoverEvent);
21
15
  load(data?: RecursivePartial<IEvents>): void;
22
16
  }
@@ -1,5 +1,5 @@
1
1
  import type { Container } from "../../../Core/Container";
2
- import type { Engine } from "../../../engine";
2
+ import type { Engine } from "../../../Core/Engine";
3
3
  import { Events } from "./Events/Events";
4
4
  import type { IInteractivity } from "../../Interfaces/Interactivity/IInteractivity";
5
5
  import type { IOptionLoader } from "../../Interfaces/IOptionLoader";
@@ -12,7 +12,5 @@ export declare class Interactivity implements IInteractivity, IOptionLoader<IInt
12
12
  events: Events;
13
13
  modes: Modes;
14
14
  constructor(engine: Engine, container?: Container);
15
- get detect_on(): InteractivityDetect | keyof typeof InteractivityDetect;
16
- set detect_on(value: InteractivityDetect | keyof typeof InteractivityDetect);
17
15
  load(data?: RecursivePartial<IInteractivity>): void;
18
16
  }
@@ -1,5 +1,5 @@
1
1
  import type { Container } from "../../../../Core/Container";
2
- import type { Engine } from "../../../../engine";
2
+ import type { Engine } from "../../../../Core/Engine";
3
3
  import type { IModes } from "../../../Interfaces/Interactivity/Modes/IModes";
4
4
  import type { IOptionLoader } from "../../../Interfaces/IOptionLoader";
5
5
  import type { RecursivePartial } from "../../../../Types/RecursivePartial";
@@ -1,11 +1,10 @@
1
1
  import { Background } from "./Background/Background";
2
2
  import { BackgroundMask } from "./BackgroundMask/BackgroundMask";
3
3
  import type { Container } from "../../Core/Container";
4
- import type { Engine } from "../../engine";
4
+ import type { Engine } from "../../Core/Engine";
5
5
  import { FullScreen } from "./FullScreen/FullScreen";
6
6
  import type { IOptionLoader } from "../Interfaces/IOptionLoader";
7
7
  import type { IOptions } from "../Interfaces/IOptions";
8
- import type { ISourceOptions } from "../../Types/ISourceOptions";
9
8
  import { Interactivity } from "./Interactivity/Interactivity";
10
9
  import { ManualParticle } from "./ManualParticle";
11
10
  import type { RangeValue } from "../../Types/RangeValue";
@@ -30,7 +29,7 @@ export declare class Options implements IOptions, IOptionLoader<IOptions> {
30
29
  fullScreen: FullScreen;
31
30
  interactivity: Interactivity;
32
31
  manualParticles: ManualParticle[];
33
- name: string;
32
+ name?: string;
34
33
  particles: import("./Particles/ParticlesOptions").ParticlesOptions;
35
34
  pauseOnBlur: boolean;
36
35
  pauseOnOutsideViewport: boolean;
@@ -43,16 +42,10 @@ export declare class Options implements IOptions, IOptionLoader<IOptions> {
43
42
  private readonly _container;
44
43
  private readonly _engine;
45
44
  constructor(engine: Engine, container: Container);
46
- get backgroundMode(): FullScreen;
47
- set backgroundMode(value: FullScreen);
48
- get fps_limit(): number;
49
- set fps_limit(value: number);
50
- get retina_detect(): boolean;
51
- set retina_detect(value: boolean);
52
- load(data?: ISourceOptions): void;
45
+ load(data?: RecursivePartial<IOptions>): void;
53
46
  setResponsive(width: number, pxRatio: number, defaultOptions: IOptions): number | undefined;
54
47
  setTheme(name?: string): void;
55
- private _findDefaultTheme;
56
- private _importPreset;
48
+ private readonly _findDefaultTheme;
49
+ private readonly _importPreset;
57
50
  }
58
51
  export {};
@@ -4,11 +4,13 @@ import { CollisionsOverlap } from "./CollisionsOverlap";
4
4
  import type { ICollisions } from "../../../Interfaces/Particles/Collisions/ICollisions";
5
5
  import type { IOptionLoader } from "../../../Interfaces/IOptionLoader";
6
6
  import { ParticlesBounce } from "../Bounce/ParticlesBounce";
7
+ import type { RangeValue } from "../../../../Types/RangeValue";
7
8
  import type { RecursivePartial } from "../../../../Types/RecursivePartial";
8
9
  export declare class Collisions implements ICollisions, IOptionLoader<ICollisions> {
9
10
  absorb: CollisionsAbsorb;
10
11
  bounce: ParticlesBounce;
11
12
  enable: boolean;
13
+ maxSpeed: RangeValue;
12
14
  mode: CollisionMode | keyof typeof CollisionMode;
13
15
  overlap: CollisionsOverlap;
14
16
  constructor();
@@ -1,4 +1,3 @@
1
- import type { OutMode, OutModeAlt } from "../../../../Enums/Modes/OutMode";
2
1
  import type { IDistance } from "../../../../Core/Interfaces/IDistance";
3
2
  import type { IMove } from "../../../Interfaces/Particles/Move/IMove";
4
3
  import type { IOptionLoader } from "../../../Interfaces/IOptionLoader";
@@ -35,15 +34,5 @@ export declare class Move implements IMove, IOptionLoader<IMove> {
35
34
  vibrate: boolean;
36
35
  warp: boolean;
37
36
  constructor();
38
- get bounce(): boolean;
39
- set bounce(value: boolean);
40
- get collisions(): boolean;
41
- set collisions(_: boolean);
42
- get noise(): MovePath;
43
- set noise(value: MovePath);
44
- get outMode(): OutMode | keyof typeof OutMode | OutModeAlt;
45
- set outMode(value: OutMode | keyof typeof OutMode | OutModeAlt);
46
- get out_mode(): OutMode | keyof typeof OutMode | OutModeAlt;
47
- set out_mode(value: OutMode | keyof typeof OutMode | OutModeAlt);
48
37
  load(data?: RecursivePartial<IMove>): void;
49
38
  }
@@ -8,9 +8,5 @@ export declare class MoveAttract implements IMoveAttract, IOptionLoader<IMoveAtt
8
8
  enable: boolean;
9
9
  rotate: ICoordinates;
10
10
  constructor();
11
- get rotateX(): number;
12
- set rotateX(value: number);
13
- get rotateY(): number;
14
- set rotateY(value: number);
15
11
  load(data?: RecursivePartial<IMoveAttract>): void;
16
12
  }
@@ -1,9 +1,9 @@
1
1
  import type { IMoveCenter } from "../../../Interfaces/Particles/Move/IMoveCenter";
2
2
  import type { IOptionLoader } from "../../../Interfaces/IOptionLoader";
3
+ import { PixelMode } from "../../../../Enums/Modes/PixelMode";
3
4
  import type { RecursivePartial } from "../../../../Types/RecursivePartial";
4
- import { SizeMode } from "../../../../Enums/Modes/SizeMode";
5
5
  export declare class MoveCenter implements IMoveCenter, IOptionLoader<IMoveCenter> {
6
- mode: SizeMode;
6
+ mode: PixelMode | keyof typeof PixelMode;
7
7
  radius: number;
8
8
  x: number;
9
9
  y: number;
@@ -1,14 +1,11 @@
1
1
  import type { IMoveTrail } from "../../../Interfaces/Particles/Move/IMoveTrail";
2
2
  import type { IOptionLoader } from "../../../Interfaces/IOptionLoader";
3
3
  import { MoveTrailFill } from "./MoveTrailFill";
4
- import type { OptionsColor } from "../../OptionsColor";
5
4
  import type { RecursivePartial } from "../../../../Types/RecursivePartial";
6
5
  export declare class MoveTrail implements IMoveTrail, IOptionLoader<IMoveTrail> {
7
6
  enable: boolean;
8
7
  fill: MoveTrailFill;
9
8
  length: number;
10
9
  constructor();
11
- get fillColor(): string | OptionsColor | undefined;
12
- set fillColor(value: string | OptionsColor | undefined);
13
10
  load(data?: RecursivePartial<IMoveTrail>): void;
14
11
  }
@@ -6,11 +6,5 @@ export declare class ParticlesDensity implements IParticlesDensity, IOptionLoade
6
6
  height: number;
7
7
  width: number;
8
8
  constructor();
9
- get area(): number;
10
- set area(value: number);
11
- get factor(): number;
12
- set factor(value: number);
13
- get value_area(): number;
14
- set value_area(value: number);
15
9
  load(data?: RecursivePartial<IParticlesDensity>): void;
16
10
  }
@@ -7,7 +7,5 @@ export declare class ParticlesNumber implements IParticlesNumber, IOptionLoader<
7
7
  limit: number;
8
8
  value: number;
9
9
  constructor();
10
- get max(): number;
11
- set max(value: number);
12
10
  load(data?: RecursivePartial<IParticlesNumber>): void;
13
11
  }
@@ -1,10 +1,10 @@
1
1
  import type { IOpacity } from "../../../Interfaces/Particles/Opacity/IOpacity";
2
2
  import type { IOptionLoader } from "../../../Interfaces/IOptionLoader";
3
3
  import { OpacityAnimation } from "./OpacityAnimation";
4
- import { RangedAnimationValueWithRandom } from "../../ValueWithRandom";
5
- export declare class Opacity extends RangedAnimationValueWithRandom implements IOpacity, IOptionLoader<IOpacity> {
4
+ import type { RecursivePartial } from "../../../../Types/RecursivePartial";
5
+ import { ValueWithRandom } from "../../ValueWithRandom";
6
+ export declare class Opacity extends ValueWithRandom implements IOpacity, IOptionLoader<IOpacity> {
6
7
  animation: OpacityAnimation;
7
8
  constructor();
8
- get anim(): OpacityAnimation;
9
- set anim(value: OpacityAnimation);
9
+ load(data?: RecursivePartial<IOpacity>): void;
10
10
  }
@@ -6,7 +6,5 @@ import type { RecursivePartial } from "../../../../Types/RecursivePartial";
6
6
  export declare class OpacityAnimation extends RangedAnimationOptions implements IOpacityAnimation, IOptionLoader<IOpacityAnimation> {
7
7
  destroy: DestroyType | keyof typeof DestroyType;
8
8
  constructor();
9
- get opacity_min(): number | undefined;
10
- set opacity_min(value: number | undefined);
11
9
  load(data?: RecursivePartial<IOpacityAnimation>): void;
12
10
  }
@@ -1,7 +1,7 @@
1
1
  import { AnimatableColor } from "../AnimatableColor";
2
2
  import { Collisions } from "./Collisions/Collisions";
3
3
  import type { Container } from "../../../Core/Container";
4
- import type { Engine } from "../../../engine";
4
+ import type { Engine } from "../../../Core/Engine";
5
5
  import type { IInteractivity } from "../../Interfaces/Interactivity/IInteractivity";
6
6
  import type { IOptionLoader } from "../../Interfaces/IOptionLoader";
7
7
  import type { IParticlesOptions } from "../../Interfaces/Particles/IParticlesOptions";
@@ -1,10 +1,10 @@
1
1
  import type { IOptionLoader } from "../../../Interfaces/IOptionLoader";
2
2
  import type { ISize } from "../../../Interfaces/Particles/Size/ISize";
3
- import { RangedAnimationValueWithRandom } from "../../ValueWithRandom";
3
+ import type { RecursivePartial } from "../../../../Types/RecursivePartial";
4
4
  import { SizeAnimation } from "./SizeAnimation";
5
- export declare class Size extends RangedAnimationValueWithRandom implements ISize, IOptionLoader<ISize> {
5
+ import { ValueWithRandom } from "../../ValueWithRandom";
6
+ export declare class Size extends ValueWithRandom implements ISize, IOptionLoader<ISize> {
6
7
  animation: SizeAnimation;
7
8
  constructor();
8
- get anim(): SizeAnimation;
9
- set anim(value: SizeAnimation);
9
+ load(data?: RecursivePartial<ISize>): void;
10
10
  }
@@ -6,7 +6,5 @@ import type { RecursivePartial } from "../../../../Types/RecursivePartial";
6
6
  export declare class SizeAnimation extends RangedAnimationOptions implements ISizeAnimation, IOptionLoader<ISizeAnimation> {
7
7
  destroy: DestroyType | keyof typeof DestroyType;
8
8
  constructor();
9
- get size_min(): number | undefined;
10
- set size_min(value: number | undefined);
11
9
  load(data?: RecursivePartial<ISizeAnimation>): void;
12
10
  }
@@ -1,12 +1,12 @@
1
1
  import type { IOptionLoader } from "../Interfaces/IOptionLoader";
2
+ import type { IOptions } from "../Interfaces/IOptions";
2
3
  import type { IResponsive } from "../Interfaces/IResponsive";
3
- import type { ISourceOptions } from "../../Types/ISourceOptions";
4
4
  import type { RecursivePartial } from "../../Types/RecursivePartial";
5
5
  import { ResponsiveMode } from "../../Enums/Modes/ResponsiveMode";
6
6
  export declare class Responsive implements IResponsive, IOptionLoader<IResponsive> {
7
7
  maxWidth: number;
8
- mode: ResponsiveMode;
9
- options: ISourceOptions;
8
+ mode: ResponsiveMode | keyof typeof ResponsiveMode;
9
+ options: RecursivePartial<IOptions>;
10
10
  constructor();
11
11
  load(data?: RecursivePartial<IResponsive>): void;
12
12
  }
@@ -1,12 +1,12 @@
1
1
  import type { IOptionLoader } from "../../Interfaces/IOptionLoader";
2
- import type { ISourceOptions } from "../../../Types/ISourceOptions";
2
+ import type { IOptions } from "../../Interfaces/IOptions";
3
3
  import type { ITheme } from "../../Interfaces/Theme/ITheme";
4
4
  import type { RecursivePartial } from "../../../Types/RecursivePartial";
5
5
  import { ThemeDefault } from "./ThemeDefault";
6
6
  export declare class Theme implements ITheme, IOptionLoader<ITheme> {
7
7
  default: ThemeDefault;
8
8
  name: string;
9
- options?: ISourceOptions;
9
+ options?: RecursivePartial<IOptions>;
10
10
  constructor();
11
11
  load(data?: RecursivePartial<ITheme>): void;
12
12
  }
@@ -1,10 +1,8 @@
1
+ import { AnimationOptions, RangedAnimationOptions } from "./AnimationOptions";
1
2
  import type { IAnimationValueWithRandom, IRangedAnimationValueWithRandom, IValueWithRandom } from "../Interfaces/IValueWithRandom";
2
- import { AnimationOptions } from "./AnimationOptions";
3
3
  import type { IOptionLoader } from "../Interfaces/IOptionLoader";
4
- import type { ISize } from "../Interfaces/Particles/Size/ISize";
5
4
  import { Random } from "./Random";
6
5
  import type { RangeValue } from "../../Types/RangeValue";
7
- import { RangedAnimationOptions } from "./AnimationOptions";
8
6
  import type { RecursivePartial } from "../../Types/RecursivePartial";
9
7
  export declare class ValueWithRandom implements IValueWithRandom, IOptionLoader<IValueWithRandom> {
10
8
  random: Random;
@@ -15,9 +13,7 @@ export declare class ValueWithRandom implements IValueWithRandom, IOptionLoader<
15
13
  export declare class AnimationValueWithRandom extends ValueWithRandom implements IOptionLoader<IAnimationValueWithRandom> {
16
14
  animation: AnimationOptions;
17
15
  constructor();
18
- get anim(): AnimationOptions;
19
- set anim(value: AnimationOptions);
20
- load(data?: RecursivePartial<ISize>): void;
16
+ load(data?: RecursivePartial<IAnimationValueWithRandom>): void;
21
17
  }
22
18
  export declare class RangedAnimationValueWithRandom extends AnimationValueWithRandom implements IOptionLoader<IRangedAnimationValueWithRandom> {
23
19
  animation: RangedAnimationOptions;
@@ -4,12 +4,12 @@ import type { StartValueType } from "../../Enums/Types/StartValueType";
4
4
  export interface IAnimation {
5
5
  count: RangeValue;
6
6
  decay: RangeValue;
7
+ delay: RangeValue;
7
8
  enable: boolean;
8
9
  speed: RangeValue;
9
10
  sync: boolean;
10
11
  }
11
12
  export interface IRangedAnimation extends IAnimation {
12
- minimumValue?: number;
13
13
  mode: AnimationMode | keyof typeof AnimationMode;
14
14
  startValue: StartValueType | keyof typeof StartValueType;
15
15
  }