@tsparticles/slim 3.2.2 → 3.4.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 (281) hide show
  1. package/README.md +1 -1
  2. package/browser/bundle.js +0 -2
  3. package/browser/index.js +25 -1
  4. package/cjs/bundle.js +0 -2
  5. package/cjs/index.js +50 -49
  6. package/esm/bundle.js +0 -2
  7. package/esm/index.js +25 -1
  8. package/package.json +27 -27
  9. package/report.html +1 -1
  10. package/tsparticles.slim.bundle.js +1594 -302
  11. package/tsparticles.slim.bundle.min.js +1 -1
  12. package/tsparticles.slim.bundle.min.js.LICENSE.txt +1 -1
  13. package/tsparticles.slim.js +14 -32
  14. package/tsparticles.slim.min.js +1 -1
  15. package/tsparticles.slim.min.js.LICENSE.txt +1 -1
  16. package/umd/bundle.js +1 -3
  17. package/umd/index.js +51 -51
  18. package/1147.min.js +0 -2
  19. package/1147.min.js.LICENSE.txt +0 -1
  20. package/1196.min.js +0 -2
  21. package/1196.min.js.LICENSE.txt +0 -1
  22. package/1264.min.js +0 -2
  23. package/1264.min.js.LICENSE.txt +0 -1
  24. package/1308.min.js +0 -2
  25. package/1308.min.js.LICENSE.txt +0 -1
  26. package/1364.min.js +0 -2
  27. package/1364.min.js.LICENSE.txt +0 -1
  28. package/1472.min.js +0 -2
  29. package/1472.min.js.LICENSE.txt +0 -1
  30. package/1513.min.js +0 -2
  31. package/1513.min.js.LICENSE.txt +0 -1
  32. package/1808.min.js +0 -2
  33. package/1808.min.js.LICENSE.txt +0 -1
  34. package/1810.min.js +0 -2
  35. package/1810.min.js.LICENSE.txt +0 -1
  36. package/1831.min.js +0 -2
  37. package/1831.min.js.LICENSE.txt +0 -1
  38. package/196.min.js +0 -2
  39. package/196.min.js.LICENSE.txt +0 -1
  40. package/1982.min.js +0 -2
  41. package/1982.min.js.LICENSE.txt +0 -1
  42. package/2121.min.js +0 -2
  43. package/2121.min.js.LICENSE.txt +0 -1
  44. package/2124.min.js +0 -2
  45. package/2124.min.js.LICENSE.txt +0 -1
  46. package/2173.min.js +0 -2
  47. package/2173.min.js.LICENSE.txt +0 -1
  48. package/2200.min.js +0 -2
  49. package/2200.min.js.LICENSE.txt +0 -1
  50. package/2486.min.js +0 -2
  51. package/2486.min.js.LICENSE.txt +0 -1
  52. package/256.min.js +0 -2
  53. package/256.min.js.LICENSE.txt +0 -1
  54. package/2580.min.js +0 -2
  55. package/2580.min.js.LICENSE.txt +0 -1
  56. package/2720.min.js +0 -2
  57. package/2720.min.js.LICENSE.txt +0 -1
  58. package/2765.min.js +0 -2
  59. package/2765.min.js.LICENSE.txt +0 -1
  60. package/2870.min.js +0 -2
  61. package/2870.min.js.LICENSE.txt +0 -1
  62. package/2890.min.js +0 -2
  63. package/2890.min.js.LICENSE.txt +0 -1
  64. package/290.min.js +0 -2
  65. package/290.min.js.LICENSE.txt +0 -1
  66. package/2946.min.js +0 -2
  67. package/2946.min.js.LICENSE.txt +0 -1
  68. package/3141.min.js +0 -2
  69. package/3141.min.js.LICENSE.txt +0 -1
  70. package/3255.min.js +0 -2
  71. package/3255.min.js.LICENSE.txt +0 -1
  72. package/3457.min.js +0 -2
  73. package/3457.min.js.LICENSE.txt +0 -1
  74. package/3486.min.js +0 -2
  75. package/3486.min.js.LICENSE.txt +0 -1
  76. package/3597.min.js +0 -2
  77. package/3597.min.js.LICENSE.txt +0 -1
  78. package/3648.min.js +0 -2
  79. package/3648.min.js.LICENSE.txt +0 -1
  80. package/3733.min.js +0 -2
  81. package/3733.min.js.LICENSE.txt +0 -1
  82. package/3869.min.js +0 -2
  83. package/3869.min.js.LICENSE.txt +0 -1
  84. package/3904.min.js +0 -2
  85. package/3904.min.js.LICENSE.txt +0 -1
  86. package/409.min.js +0 -2
  87. package/409.min.js.LICENSE.txt +0 -1
  88. package/4314.min.js +0 -2
  89. package/4314.min.js.LICENSE.txt +0 -1
  90. package/4328.min.js +0 -2
  91. package/4328.min.js.LICENSE.txt +0 -1
  92. package/4687.min.js +0 -2
  93. package/4687.min.js.LICENSE.txt +0 -1
  94. package/4732.min.js +0 -2
  95. package/4732.min.js.LICENSE.txt +0 -1
  96. package/4737.min.js +0 -2
  97. package/4737.min.js.LICENSE.txt +0 -1
  98. package/4744.min.js +0 -2
  99. package/4744.min.js.LICENSE.txt +0 -1
  100. package/4866.min.js +0 -2
  101. package/4866.min.js.LICENSE.txt +0 -1
  102. package/4922.min.js +0 -2
  103. package/4922.min.js.LICENSE.txt +0 -1
  104. package/4973.min.js +0 -2
  105. package/4973.min.js.LICENSE.txt +0 -1
  106. package/4994.min.js +0 -2
  107. package/4994.min.js.LICENSE.txt +0 -1
  108. package/5120.min.js +0 -2
  109. package/5120.min.js.LICENSE.txt +0 -1
  110. package/5243.min.js +0 -2
  111. package/5243.min.js.LICENSE.txt +0 -1
  112. package/5308.min.js +0 -2
  113. package/5308.min.js.LICENSE.txt +0 -1
  114. package/5329.min.js +0 -2
  115. package/5329.min.js.LICENSE.txt +0 -1
  116. package/533.min.js +0 -2
  117. package/533.min.js.LICENSE.txt +0 -1
  118. package/5437.min.js +0 -2
  119. package/5437.min.js.LICENSE.txt +0 -1
  120. package/5444.min.js +0 -2
  121. package/5444.min.js.LICENSE.txt +0 -1
  122. package/5523.min.js +0 -2
  123. package/5523.min.js.LICENSE.txt +0 -1
  124. package/5647.min.js +0 -2
  125. package/5647.min.js.LICENSE.txt +0 -1
  126. package/5715.min.js +0 -2
  127. package/5715.min.js.LICENSE.txt +0 -1
  128. package/5819.min.js +0 -2
  129. package/5819.min.js.LICENSE.txt +0 -1
  130. package/6072.min.js +0 -2
  131. package/6072.min.js.LICENSE.txt +0 -1
  132. package/6132.min.js +0 -2
  133. package/6132.min.js.LICENSE.txt +0 -1
  134. package/6634.min.js +0 -2
  135. package/6634.min.js.LICENSE.txt +0 -1
  136. package/675.min.js +0 -2
  137. package/675.min.js.LICENSE.txt +0 -1
  138. package/6772.min.js +0 -2
  139. package/6772.min.js.LICENSE.txt +0 -1
  140. package/69.min.js +0 -2
  141. package/69.min.js.LICENSE.txt +0 -1
  142. package/7031.min.js +0 -2
  143. package/7031.min.js.LICENSE.txt +0 -1
  144. package/7049.min.js +0 -2
  145. package/7049.min.js.LICENSE.txt +0 -1
  146. package/7077.min.js +0 -2
  147. package/7077.min.js.LICENSE.txt +0 -1
  148. package/7108.min.js +0 -2
  149. package/7108.min.js.LICENSE.txt +0 -1
  150. package/7331.min.js +0 -2
  151. package/7331.min.js.LICENSE.txt +0 -1
  152. package/7517.min.js +0 -2
  153. package/7517.min.js.LICENSE.txt +0 -1
  154. package/7704.min.js +0 -2
  155. package/7704.min.js.LICENSE.txt +0 -1
  156. package/7725.min.js +0 -2
  157. package/7725.min.js.LICENSE.txt +0 -1
  158. package/7757.min.js +0 -2
  159. package/7757.min.js.LICENSE.txt +0 -1
  160. package/7769.min.js +0 -2
  161. package/7769.min.js.LICENSE.txt +0 -1
  162. package/7835.min.js +0 -2
  163. package/7835.min.js.LICENSE.txt +0 -1
  164. package/7859.min.js +0 -2
  165. package/7859.min.js.LICENSE.txt +0 -1
  166. package/7886.min.js +0 -2
  167. package/7886.min.js.LICENSE.txt +0 -1
  168. package/7890.min.js +0 -2
  169. package/7890.min.js.LICENSE.txt +0 -1
  170. package/8158.min.js +0 -2
  171. package/8158.min.js.LICENSE.txt +0 -1
  172. package/8638.min.js +0 -2
  173. package/8638.min.js.LICENSE.txt +0 -1
  174. package/8883.min.js +0 -2
  175. package/8883.min.js.LICENSE.txt +0 -1
  176. package/889.min.js +0 -2
  177. package/889.min.js.LICENSE.txt +0 -1
  178. package/9062.min.js +0 -2
  179. package/9062.min.js.LICENSE.txt +0 -1
  180. package/9126.min.js +0 -2
  181. package/9126.min.js.LICENSE.txt +0 -1
  182. package/9133.min.js +0 -2
  183. package/9133.min.js.LICENSE.txt +0 -1
  184. package/9376.min.js +0 -2
  185. package/9376.min.js.LICENSE.txt +0 -1
  186. package/9431.min.js +0 -2
  187. package/9431.min.js.LICENSE.txt +0 -1
  188. package/9530.min.js +0 -2
  189. package/9530.min.js.LICENSE.txt +0 -1
  190. package/9532.min.js +0 -2
  191. package/9532.min.js.LICENSE.txt +0 -1
  192. package/9921.min.js +0 -2
  193. package/9921.min.js.LICENSE.txt +0 -1
  194. package/basic_dist_browser_index_js.js +0 -30
  195. package/engine_dist_browser_Core_Container_js.js +0 -90
  196. package/engine_dist_browser_Core_Particle_js.js +0 -30
  197. package/interactions_external_attract_dist_browser_Attractor_js.js +0 -30
  198. package/interactions_external_attract_dist_browser_Utils_js.js +0 -30
  199. package/interactions_external_attract_dist_browser_index_js.js +0 -50
  200. package/interactions_external_bounce_dist_browser_Bouncer_js.js +0 -30
  201. package/interactions_external_bounce_dist_browser_Utils_js.js +0 -30
  202. package/interactions_external_bounce_dist_browser_index_js.js +0 -50
  203. package/interactions_external_bubble_dist_browser_Bubbler_js.js +0 -40
  204. package/interactions_external_bubble_dist_browser_index_js.js +0 -90
  205. package/interactions_external_connect_dist_browser_Connector_js.js +0 -40
  206. package/interactions_external_connect_dist_browser_index_js.js +0 -70
  207. package/interactions_external_grab_dist_browser_Grabber_js.js +0 -40
  208. package/interactions_external_grab_dist_browser_index_js.js +0 -70
  209. package/interactions_external_pause_dist_browser_Pauser_js.js +0 -30
  210. package/interactions_external_pause_dist_browser_index_js.js +0 -30
  211. package/interactions_external_push_dist_browser_Pusher_js.js +0 -30
  212. package/interactions_external_push_dist_browser_index_js.js +0 -50
  213. package/interactions_external_remove_dist_browser_Remover_js.js +0 -30
  214. package/interactions_external_remove_dist_browser_index_js.js +0 -50
  215. package/interactions_external_repulse_dist_browser_Repulser_js.js +0 -30
  216. package/interactions_external_repulse_dist_browser_index_js.js +0 -90
  217. package/interactions_external_slow_dist_browser_Slower_js.js +0 -30
  218. package/interactions_external_slow_dist_browser_index_js.js +0 -50
  219. package/interactions_particles_attract_dist_browser_Attractor_js.js +0 -30
  220. package/interactions_particles_attract_dist_browser_index_js.js +0 -30
  221. package/interactions_particles_collisions_dist_browser_Absorb_js.js +0 -30
  222. package/interactions_particles_collisions_dist_browser_Bounce_js.js +0 -30
  223. package/interactions_particles_collisions_dist_browser_Collider_js.js +0 -40
  224. package/interactions_particles_collisions_dist_browser_Destroy_js.js +0 -40
  225. package/interactions_particles_collisions_dist_browser_index_js.js +0 -30
  226. package/interactions_particles_links_dist_browser_CircleWarp_js.js +0 -30
  227. package/interactions_particles_links_dist_browser_LinkInstance_js.js +0 -40
  228. package/interactions_particles_links_dist_browser_Linker_js.js +0 -30
  229. package/interactions_particles_links_dist_browser_LinksPlugin_js.js +0 -30
  230. package/interactions_particles_links_dist_browser_index_js.js +0 -90
  231. package/interactions_particles_links_dist_browser_interaction_js.js +0 -30
  232. package/interactions_particles_links_dist_browser_plugin_js.js +0 -30
  233. package/move_base_dist_browser_BaseMover_js.js +0 -30
  234. package/move_base_dist_browser_Utils_js.js +0 -30
  235. package/move_base_dist_browser_index_js.js +0 -30
  236. package/move_parallax_dist_browser_ParallaxMover_js.js +0 -30
  237. package/move_parallax_dist_browser_index_js.js +0 -30
  238. package/plugins_easings_quad_dist_browser_index_js.js +0 -30
  239. package/shapes_circle_dist_browser_CircleDrawer_js.js +0 -30
  240. package/shapes_circle_dist_browser_Utils_js.js +0 -30
  241. package/shapes_circle_dist_browser_index_js.js +0 -30
  242. package/shapes_emoji_dist_browser_EmojiDrawer_js.js +0 -30
  243. package/shapes_emoji_dist_browser_Utils_js.js +0 -30
  244. package/shapes_emoji_dist_browser_index_js.js +0 -40
  245. package/shapes_image_dist_browser_GifUtils_Utils_js.js +0 -50
  246. package/shapes_image_dist_browser_ImageDrawer_js.js +0 -30
  247. package/shapes_image_dist_browser_ImagePreloader_js.js +0 -40
  248. package/shapes_image_dist_browser_index_js.js +0 -40
  249. package/shapes_line_dist_browser_LineDrawer_js.js +0 -30
  250. package/shapes_line_dist_browser_Utils_js.js +0 -30
  251. package/shapes_line_dist_browser_index_js.js +0 -30
  252. package/shapes_polygon_dist_browser_PolygonDrawer_js.js +0 -40
  253. package/shapes_polygon_dist_browser_TriangleDrawer_js.js +0 -40
  254. package/shapes_polygon_dist_browser_Utils_js.js +0 -30
  255. package/shapes_polygon_dist_browser_index_js.js +0 -30
  256. package/shapes_square_dist_browser_SquareDrawer_js.js +0 -30
  257. package/shapes_square_dist_browser_Utils_js.js +0 -30
  258. package/shapes_square_dist_browser_index_js.js +0 -30
  259. package/shapes_star_dist_browser_StarDrawer_js.js +0 -30
  260. package/shapes_star_dist_browser_Utils_js.js +0 -30
  261. package/shapes_star_dist_browser_index_js.js +0 -30
  262. package/updaters_color_dist_browser_ColorUpdater_js.js +0 -30
  263. package/updaters_color_dist_browser_index_js.js +0 -30
  264. package/updaters_life_dist_browser_LifeUpdater_js.js +0 -60
  265. package/updaters_life_dist_browser_Utils_js.js +0 -30
  266. package/updaters_life_dist_browser_index_js.js +0 -30
  267. package/updaters_opacity_dist_browser_OpacityUpdater_js.js +0 -30
  268. package/updaters_opacity_dist_browser_index_js.js +0 -30
  269. package/updaters_outModes_dist_browser_BounceOutMode_js.js +0 -30
  270. package/updaters_outModes_dist_browser_DestroyOutMode_js.js +0 -30
  271. package/updaters_outModes_dist_browser_NoneOutMode_js.js +0 -30
  272. package/updaters_outModes_dist_browser_OutOfCanvasUpdater_js.js +0 -30
  273. package/updaters_outModes_dist_browser_OutOutMode_js.js +0 -30
  274. package/updaters_outModes_dist_browser_Utils_js.js +0 -30
  275. package/updaters_outModes_dist_browser_index_js.js +0 -30
  276. package/updaters_rotate_dist_browser_RotateUpdater_js.js +0 -50
  277. package/updaters_rotate_dist_browser_index_js.js +0 -30
  278. package/updaters_size_dist_browser_SizeUpdater_js.js +0 -30
  279. package/updaters_size_dist_browser_index_js.js +0 -30
  280. package/updaters_strokeColor_dist_browser_StrokeColorUpdater_js.js +0 -30
  281. package/updaters_strokeColor_dist_browser_index_js.js +0 -30
@@ -1,30 +0,0 @@
1
- /*!
2
- * Author : Matteo Bruni
3
- * MIT license: https://opensource.org/licenses/MIT
4
- * Demo / Generator : https://particles.js.org/
5
- * GitHub : https://www.github.com/matteobruni/tsparticles
6
- * How to use? : Check the GitHub README
7
- * v3.2.2
8
- */
9
- "use strict";
10
- /*
11
- * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
12
- * This devtool is neither made for production nor for readable output files.
13
- * It uses "eval()" calls to create a separate source file in the browser devtools.
14
- * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
15
- * or disable the default devtool with "devtool: false".
16
- * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
17
- */
18
- (this["webpackChunk_tsparticles_slim"] = this["webpackChunk_tsparticles_slim"] || []).push([["move_base_dist_browser_Utils_js"],{
19
-
20
- /***/ "../../move/base/dist/browser/Utils.js":
21
- /*!*********************************************!*\
22
- !*** ../../move/base/dist/browser/Utils.js ***!
23
- \*********************************************/
24
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
25
-
26
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ applyDistance: () => (/* binding */ applyDistance),\n/* harmony export */ applyPath: () => (/* binding */ applyPath),\n/* harmony export */ getProximitySpeedFactor: () => (/* binding */ getProximitySpeedFactor),\n/* harmony export */ initSpin: () => (/* binding */ initSpin),\n/* harmony export */ move: () => (/* binding */ move),\n/* harmony export */ spin: () => (/* binding */ spin)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"../../engine/dist/browser/index.js\");\n\nconst half = 0.5,\n minVelocity = 0,\n identity = 1,\n moveSpeedFactor = 60,\n minSpinRadius = 0,\n spinFactor = 0.01;\nfunction applyDistance(particle) {\n const initialPosition = particle.initialPosition,\n {\n dx,\n dy\n } = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getDistances)(initialPosition, particle.position),\n dxFixed = Math.abs(dx),\n dyFixed = Math.abs(dy),\n {\n maxDistance\n } = particle.retina,\n hDistance = maxDistance.horizontal,\n vDistance = maxDistance.vertical;\n if (!hDistance && !vDistance) {\n return;\n }\n const hasHDistance = (hDistance && dxFixed >= hDistance) ?? false,\n hasVDistance = (vDistance && dyFixed >= vDistance) ?? false;\n if ((hasHDistance || hasVDistance) && !particle.misplaced) {\n particle.misplaced = !!hDistance && dxFixed > hDistance || !!vDistance && dyFixed > vDistance;\n if (hDistance) {\n particle.velocity.x = particle.velocity.y * half - particle.velocity.x;\n }\n if (vDistance) {\n particle.velocity.y = particle.velocity.x * half - particle.velocity.y;\n }\n } else if ((!hDistance || dxFixed < hDistance) && (!vDistance || dyFixed < vDistance) && particle.misplaced) {\n particle.misplaced = false;\n } else if (particle.misplaced) {\n const pos = particle.position,\n vel = particle.velocity;\n if (hDistance && (pos.x < initialPosition.x && vel.x < minVelocity || pos.x > initialPosition.x && vel.x > minVelocity)) {\n vel.x *= -(0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getRandom)();\n }\n if (vDistance && (pos.y < initialPosition.y && vel.y < minVelocity || pos.y > initialPosition.y && vel.y > minVelocity)) {\n vel.y *= -(0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getRandom)();\n }\n }\n}\nasync function move(particle, moveOptions, moveSpeed, maxSpeed, moveDrift, delta) {\n await applyPath(particle, delta);\n const gravityOptions = particle.gravity,\n gravityFactor = gravityOptions?.enable && gravityOptions.inverse ? -identity : identity;\n if (moveDrift && moveSpeed) {\n particle.velocity.x += moveDrift * delta.factor / (moveSpeedFactor * moveSpeed);\n }\n if (gravityOptions?.enable && moveSpeed) {\n particle.velocity.y += gravityFactor * (gravityOptions.acceleration * delta.factor) / (moveSpeedFactor * moveSpeed);\n }\n const decay = particle.moveDecay;\n particle.velocity.multTo(decay);\n const velocity = particle.velocity.mult(moveSpeed);\n if (gravityOptions?.enable && maxSpeed > minVelocity && (!gravityOptions.inverse && velocity.y >= minVelocity && velocity.y >= maxSpeed || gravityOptions.inverse && velocity.y <= minVelocity && velocity.y <= -maxSpeed)) {\n velocity.y = gravityFactor * maxSpeed;\n if (moveSpeed) {\n particle.velocity.y = velocity.y / moveSpeed;\n }\n }\n const zIndexOptions = particle.options.zIndex,\n zVelocityFactor = (identity - particle.zIndexFactor) ** zIndexOptions.velocityRate;\n velocity.multTo(zVelocityFactor);\n const {\n position\n } = particle;\n position.addTo(velocity);\n if (moveOptions.vibrate) {\n position.x += Math.sin(position.x * Math.cos(position.y));\n position.y += Math.cos(position.y * Math.sin(position.x));\n }\n}\nfunction spin(particle, moveSpeed) {\n const container = particle.container;\n if (!particle.spin) {\n return;\n }\n const updateFunc = {\n x: particle.spin.direction === \"clockwise\" ? Math.cos : Math.sin,\n y: particle.spin.direction === \"clockwise\" ? Math.sin : Math.cos\n };\n particle.position.x = particle.spin.center.x + particle.spin.radius * updateFunc.x(particle.spin.angle);\n particle.position.y = particle.spin.center.y + particle.spin.radius * updateFunc.y(particle.spin.angle);\n particle.spin.radius += particle.spin.acceleration;\n const maxCanvasSize = Math.max(container.canvas.size.width, container.canvas.size.height),\n halfMaxSize = maxCanvasSize * half;\n if (particle.spin.radius > halfMaxSize) {\n particle.spin.radius = halfMaxSize;\n particle.spin.acceleration *= -identity;\n } else if (particle.spin.radius < minSpinRadius) {\n particle.spin.radius = minSpinRadius;\n particle.spin.acceleration *= -identity;\n }\n particle.spin.angle += moveSpeed * spinFactor * (identity - particle.spin.radius / maxCanvasSize);\n}\nasync function applyPath(particle, delta) {\n const particlesOptions = particle.options,\n pathOptions = particlesOptions.move.path,\n pathEnabled = pathOptions.enable;\n if (!pathEnabled) {\n return;\n }\n if (particle.lastPathTime <= particle.pathDelay) {\n particle.lastPathTime += delta.value;\n return;\n }\n const path = await particle.pathGenerator?.generate(particle, delta);\n if (path) {\n particle.velocity.addTo(path);\n }\n if (pathOptions.clamp) {\n particle.velocity.x = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.clamp)(particle.velocity.x, -identity, identity);\n particle.velocity.y = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.clamp)(particle.velocity.y, -identity, identity);\n }\n particle.lastPathTime -= particle.pathDelay;\n}\nfunction getProximitySpeedFactor(particle) {\n return particle.slow.inRange ? particle.slow.factor : identity;\n}\nfunction initSpin(particle) {\n const container = particle.container,\n options = particle.options,\n spinOptions = options.move.spin;\n if (!spinOptions.enable) {\n return;\n }\n const spinPos = spinOptions.position ?? {\n x: 50,\n y: 50\n },\n spinFactor = 0.01,\n spinCenter = {\n x: spinPos.x * spinFactor * container.canvas.size.width,\n y: spinPos.y * spinFactor * container.canvas.size.height\n },\n pos = particle.getPosition(),\n distance = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getDistance)(pos, spinCenter),\n spinAcceleration = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getRangeValue)(spinOptions.acceleration);\n particle.retina.spinAcceleration = spinAcceleration * container.retina.pixelRatio;\n const minVelocity = 0;\n particle.spin = {\n center: spinCenter,\n direction: particle.velocity.x >= minVelocity ? \"clockwise\" : \"counter-clockwise\",\n angle: particle.velocity.angle,\n radius: distance,\n acceleration: particle.retina.spinAcceleration\n };\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../move/base/dist/browser/Utils.js?");
27
-
28
- /***/ })
29
-
30
- }]);
@@ -1,30 +0,0 @@
1
- /*!
2
- * Author : Matteo Bruni
3
- * MIT license: https://opensource.org/licenses/MIT
4
- * Demo / Generator : https://particles.js.org/
5
- * GitHub : https://www.github.com/matteobruni/tsparticles
6
- * How to use? : Check the GitHub README
7
- * v3.2.2
8
- */
9
- "use strict";
10
- /*
11
- * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
12
- * This devtool is neither made for production nor for readable output files.
13
- * It uses "eval()" calls to create a separate source file in the browser devtools.
14
- * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
15
- * or disable the default devtool with "devtool: false".
16
- * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
17
- */
18
- (this["webpackChunk_tsparticles_slim"] = this["webpackChunk_tsparticles_slim"] || []).push([["move_base_dist_browser_index_js"],{
19
-
20
- /***/ "../../move/base/dist/browser/index.js":
21
- /*!*********************************************!*\
22
- !*** ../../move/base/dist/browser/index.js ***!
23
- \*********************************************/
24
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
25
-
26
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ loadBaseMover: () => (/* binding */ loadBaseMover)\n/* harmony export */ });\nasync function loadBaseMover(engine, refresh = true) {\n await engine.addMover(\"base\", async () => {\n const {\n BaseMover\n } = await __webpack_require__.e(/*! import() */ \"move_base_dist_browser_BaseMover_js\").then(__webpack_require__.bind(__webpack_require__, /*! ./BaseMover.js */ \"../../move/base/dist/browser/BaseMover.js\"));\n return new BaseMover();\n }, refresh);\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../move/base/dist/browser/index.js?");
27
-
28
- /***/ })
29
-
30
- }]);
@@ -1,30 +0,0 @@
1
- /*!
2
- * Author : Matteo Bruni
3
- * MIT license: https://opensource.org/licenses/MIT
4
- * Demo / Generator : https://particles.js.org/
5
- * GitHub : https://www.github.com/matteobruni/tsparticles
6
- * How to use? : Check the GitHub README
7
- * v3.2.2
8
- */
9
- "use strict";
10
- /*
11
- * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
12
- * This devtool is neither made for production nor for readable output files.
13
- * It uses "eval()" calls to create a separate source file in the browser devtools.
14
- * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
15
- * or disable the default devtool with "devtool: false".
16
- * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
17
- */
18
- (this["webpackChunk_tsparticles_slim"] = this["webpackChunk_tsparticles_slim"] || []).push([["move_parallax_dist_browser_ParallaxMover_js"],{
19
-
20
- /***/ "../../move/parallax/dist/browser/ParallaxMover.js":
21
- /*!*********************************************************!*\
22
- !*** ../../move/parallax/dist/browser/ParallaxMover.js ***!
23
- \*********************************************************/
24
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
25
-
26
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ ParallaxMover: () => (/* binding */ ParallaxMover)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"../../engine/dist/browser/index.js\");\n\nconst half = 0.5;\nclass ParallaxMover {\n async init() {\n await Promise.resolve();\n }\n isEnabled(particle) {\n return !(0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.isSsr)() && !particle.destroyed && particle.container.actualOptions.interactivity.events.onHover.parallax.enable;\n }\n async move(particle) {\n const container = particle.container,\n options = container.actualOptions,\n parallaxOptions = options.interactivity.events.onHover.parallax;\n if ((0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.isSsr)() || !parallaxOptions.enable) {\n return;\n }\n const parallaxForce = parallaxOptions.force,\n mousePos = container.interactivity.mouse.position;\n if (!mousePos) {\n return;\n }\n const canvasSize = container.canvas.size,\n canvasCenter = {\n x: canvasSize.width * half,\n y: canvasSize.height * half\n },\n parallaxSmooth = parallaxOptions.smooth,\n factor = particle.getRadius() / parallaxForce,\n centerDistance = {\n x: (mousePos.x - canvasCenter.x) * factor,\n y: (mousePos.y - canvasCenter.y) * factor\n },\n {\n offset\n } = particle;\n offset.x += (centerDistance.x - offset.x) / parallaxSmooth;\n offset.y += (centerDistance.y - offset.y) / parallaxSmooth;\n await Promise.resolve();\n }\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../move/parallax/dist/browser/ParallaxMover.js?");
27
-
28
- /***/ })
29
-
30
- }]);
@@ -1,30 +0,0 @@
1
- /*!
2
- * Author : Matteo Bruni
3
- * MIT license: https://opensource.org/licenses/MIT
4
- * Demo / Generator : https://particles.js.org/
5
- * GitHub : https://www.github.com/matteobruni/tsparticles
6
- * How to use? : Check the GitHub README
7
- * v3.2.2
8
- */
9
- "use strict";
10
- /*
11
- * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
12
- * This devtool is neither made for production nor for readable output files.
13
- * It uses "eval()" calls to create a separate source file in the browser devtools.
14
- * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
15
- * or disable the default devtool with "devtool: false".
16
- * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
17
- */
18
- (this["webpackChunk_tsparticles_slim"] = this["webpackChunk_tsparticles_slim"] || []).push([["move_parallax_dist_browser_index_js"],{
19
-
20
- /***/ "../../move/parallax/dist/browser/index.js":
21
- /*!*************************************************!*\
22
- !*** ../../move/parallax/dist/browser/index.js ***!
23
- \*************************************************/
24
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
25
-
26
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ loadParallaxMover: () => (/* binding */ loadParallaxMover)\n/* harmony export */ });\nasync function loadParallaxMover(engine, refresh = true) {\n await engine.addMover(\"parallax\", async () => {\n const {\n ParallaxMover\n } = await __webpack_require__.e(/*! import() */ \"move_parallax_dist_browser_ParallaxMover_js\").then(__webpack_require__.bind(__webpack_require__, /*! ./ParallaxMover.js */ \"../../move/parallax/dist/browser/ParallaxMover.js\"));\n return new ParallaxMover();\n }, refresh);\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../move/parallax/dist/browser/index.js?");
27
-
28
- /***/ })
29
-
30
- }]);
@@ -1,30 +0,0 @@
1
- /*!
2
- * Author : Matteo Bruni
3
- * MIT license: https://opensource.org/licenses/MIT
4
- * Demo / Generator : https://particles.js.org/
5
- * GitHub : https://www.github.com/matteobruni/tsparticles
6
- * How to use? : Check the GitHub README
7
- * v3.2.2
8
- */
9
- "use strict";
10
- /*
11
- * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
12
- * This devtool is neither made for production nor for readable output files.
13
- * It uses "eval()" calls to create a separate source file in the browser devtools.
14
- * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
15
- * or disable the default devtool with "devtool: false".
16
- * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
17
- */
18
- (this["webpackChunk_tsparticles_slim"] = this["webpackChunk_tsparticles_slim"] || []).push([["plugins_easings_quad_dist_browser_index_js"],{
19
-
20
- /***/ "../../plugins/easings/quad/dist/browser/index.js":
21
- /*!********************************************************!*\
22
- !*** ../../plugins/easings/quad/dist/browser/index.js ***!
23
- \********************************************************/
24
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
25
-
26
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ loadEasingQuadPlugin: () => (/* binding */ loadEasingQuadPlugin)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"../../engine/dist/browser/index.js\");\n\nasync function loadEasingQuadPlugin() {\n (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.addEasing)(\"ease-in-quad\", value => value ** 2);\n (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.addEasing)(\"ease-out-quad\", value => 1 - (1 - value) ** 2);\n (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.addEasing)(\"ease-in-out-quad\", value => value < 0.5 ? 2 * value ** 2 : 1 - (-2 * value + 2) ** 2 / 2);\n await Promise.resolve();\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../plugins/easings/quad/dist/browser/index.js?");
27
-
28
- /***/ })
29
-
30
- }]);
@@ -1,30 +0,0 @@
1
- /*!
2
- * Author : Matteo Bruni
3
- * MIT license: https://opensource.org/licenses/MIT
4
- * Demo / Generator : https://particles.js.org/
5
- * GitHub : https://www.github.com/matteobruni/tsparticles
6
- * How to use? : Check the GitHub README
7
- * v3.2.2
8
- */
9
- "use strict";
10
- /*
11
- * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
12
- * This devtool is neither made for production nor for readable output files.
13
- * It uses "eval()" calls to create a separate source file in the browser devtools.
14
- * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
15
- * or disable the default devtool with "devtool: false".
16
- * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
17
- */
18
- (this["webpackChunk_tsparticles_slim"] = this["webpackChunk_tsparticles_slim"] || []).push([["shapes_circle_dist_browser_CircleDrawer_js"],{
19
-
20
- /***/ "../../shapes/circle/dist/browser/CircleDrawer.js":
21
- /*!********************************************************!*\
22
- !*** ../../shapes/circle/dist/browser/CircleDrawer.js ***!
23
- \********************************************************/
24
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
25
-
26
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ CircleDrawer: () => (/* binding */ CircleDrawer)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"../../engine/dist/browser/index.js\");\n\nconst sides = 12,\n maxAngle = 360,\n minAngle = 0;\nclass CircleDrawer {\n async draw(data) {\n const {\n drawCircle\n } = await __webpack_require__.e(/*! import() */ \"shapes_circle_dist_browser_Utils_js\").then(__webpack_require__.bind(__webpack_require__, /*! ./Utils.js */ \"../../shapes/circle/dist/browser/Utils.js\"));\n drawCircle(data);\n }\n getSidesCount() {\n return sides;\n }\n async particleInit(container, particle) {\n const shapeData = particle.shapeData,\n angle = shapeData?.angle ?? {\n max: maxAngle,\n min: minAngle\n };\n particle.circleRange = !(0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.isObject)(angle) ? {\n min: minAngle,\n max: (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.degToRad)(angle)\n } : {\n min: (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.degToRad)(angle.min),\n max: (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.degToRad)(angle.max)\n };\n await Promise.resolve();\n }\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../shapes/circle/dist/browser/CircleDrawer.js?");
27
-
28
- /***/ })
29
-
30
- }]);
@@ -1,30 +0,0 @@
1
- /*!
2
- * Author : Matteo Bruni
3
- * MIT license: https://opensource.org/licenses/MIT
4
- * Demo / Generator : https://particles.js.org/
5
- * GitHub : https://www.github.com/matteobruni/tsparticles
6
- * How to use? : Check the GitHub README
7
- * v3.2.2
8
- */
9
- "use strict";
10
- /*
11
- * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
12
- * This devtool is neither made for production nor for readable output files.
13
- * It uses "eval()" calls to create a separate source file in the browser devtools.
14
- * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
15
- * or disable the default devtool with "devtool: false".
16
- * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
17
- */
18
- (this["webpackChunk_tsparticles_slim"] = this["webpackChunk_tsparticles_slim"] || []).push([["shapes_circle_dist_browser_Utils_js"],{
19
-
20
- /***/ "../../shapes/circle/dist/browser/Utils.js":
21
- /*!*************************************************!*\
22
- !*** ../../shapes/circle/dist/browser/Utils.js ***!
23
- \*************************************************/
24
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
25
-
26
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ drawCircle: () => (/* binding */ drawCircle)\n/* harmony export */ });\nconst double = 2,\n doublePI = Math.PI * double,\n minAngle = 0,\n origin = {\n x: 0,\n y: 0\n };\nfunction drawCircle(data) {\n const {\n context,\n particle,\n radius\n } = data;\n if (!particle.circleRange) {\n particle.circleRange = {\n min: minAngle,\n max: doublePI\n };\n }\n const circleRange = particle.circleRange;\n context.arc(origin.x, origin.y, radius, circleRange.min, circleRange.max, false);\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../shapes/circle/dist/browser/Utils.js?");
27
-
28
- /***/ })
29
-
30
- }]);
@@ -1,30 +0,0 @@
1
- /*!
2
- * Author : Matteo Bruni
3
- * MIT license: https://opensource.org/licenses/MIT
4
- * Demo / Generator : https://particles.js.org/
5
- * GitHub : https://www.github.com/matteobruni/tsparticles
6
- * How to use? : Check the GitHub README
7
- * v3.2.2
8
- */
9
- "use strict";
10
- /*
11
- * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
12
- * This devtool is neither made for production nor for readable output files.
13
- * It uses "eval()" calls to create a separate source file in the browser devtools.
14
- * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
15
- * or disable the default devtool with "devtool: false".
16
- * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
17
- */
18
- (this["webpackChunk_tsparticles_slim"] = this["webpackChunk_tsparticles_slim"] || []).push([["shapes_circle_dist_browser_index_js"],{
19
-
20
- /***/ "../../shapes/circle/dist/browser/index.js":
21
- /*!*************************************************!*\
22
- !*** ../../shapes/circle/dist/browser/index.js ***!
23
- \*************************************************/
24
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
25
-
26
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ loadCircleShape: () => (/* binding */ loadCircleShape)\n/* harmony export */ });\nasync function loadCircleShape(engine, refresh = true) {\n const {\n CircleDrawer\n } = await __webpack_require__.e(/*! import() */ \"shapes_circle_dist_browser_CircleDrawer_js\").then(__webpack_require__.bind(__webpack_require__, /*! ./CircleDrawer.js */ \"../../shapes/circle/dist/browser/CircleDrawer.js\"));\n await engine.addShape(\"circle\", new CircleDrawer(), refresh);\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../shapes/circle/dist/browser/index.js?");
27
-
28
- /***/ })
29
-
30
- }]);
@@ -1,30 +0,0 @@
1
- /*!
2
- * Author : Matteo Bruni
3
- * MIT license: https://opensource.org/licenses/MIT
4
- * Demo / Generator : https://particles.js.org/
5
- * GitHub : https://www.github.com/matteobruni/tsparticles
6
- * How to use? : Check the GitHub README
7
- * v3.2.2
8
- */
9
- "use strict";
10
- /*
11
- * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
12
- * This devtool is neither made for production nor for readable output files.
13
- * It uses "eval()" calls to create a separate source file in the browser devtools.
14
- * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
15
- * or disable the default devtool with "devtool: false".
16
- * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
17
- */
18
- (this["webpackChunk_tsparticles_slim"] = this["webpackChunk_tsparticles_slim"] || []).push([["shapes_emoji_dist_browser_EmojiDrawer_js"],{
19
-
20
- /***/ "../../shapes/emoji/dist/browser/EmojiDrawer.js":
21
- /*!******************************************************!*\
22
- !*** ../../shapes/emoji/dist/browser/EmojiDrawer.js ***!
23
- \******************************************************/
24
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
25
-
26
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ EmojiDrawer: () => (/* binding */ EmojiDrawer)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"../../engine/dist/browser/index.js\");\n/* harmony import */ var _Constants_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./Constants.js */ \"../../shapes/emoji/dist/browser/Constants.js\");\n\n\nconst defaultFont = '\"Twemoji Mozilla\", Apple Color Emoji, \"Segoe UI Emoji\", \"Noto Color Emoji\", \"EmojiOne Color\"';\nclass EmojiDrawer {\n constructor() {\n this._emojiShapeDict = new Map();\n }\n destroy() {\n for (const [key, emojiData] of this._emojiShapeDict) {\n if (emojiData instanceof ImageBitmap) {\n emojiData?.close();\n this._emojiShapeDict.delete(key);\n }\n }\n }\n async draw(data) {\n const {\n drawEmoji\n } = await __webpack_require__.e(/*! import() */ \"shapes_emoji_dist_browser_Utils_js\").then(__webpack_require__.bind(__webpack_require__, /*! ./Utils.js */ \"../../shapes/emoji/dist/browser/Utils.js\"));\n drawEmoji(data);\n }\n async init(container) {\n const options = container.actualOptions;\n if (!_Constants_js__WEBPACK_IMPORTED_MODULE_1__.validTypes.find(t => (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.isInArray)(t, options.particles.shape.type))) {\n return;\n }\n const promises = [(0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.loadFont)(defaultFont)],\n shapeOptions = _Constants_js__WEBPACK_IMPORTED_MODULE_1__.validTypes.map(t => options.particles.shape.options[t]).find(t => !!t);\n if (shapeOptions) {\n (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.executeOnSingleOrMultiple)(shapeOptions, shape => {\n if (shape.font) {\n promises.push((0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.loadFont)(shape.font));\n }\n });\n }\n await Promise.all(promises);\n }\n particleDestroy(particle) {\n delete particle.emojiData;\n }\n async particleInit(container, particle) {\n const double = 2,\n shapeData = particle.shapeData;\n if (!shapeData?.value) {\n return;\n }\n const emoji = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.itemFromSingleOrMultiple)(shapeData.value, particle.randomIndexData),\n font = shapeData.font ?? defaultFont;\n if (!emoji) {\n return;\n }\n const key = `${emoji}_${font}`,\n existingData = this._emojiShapeDict.get(key);\n if (existingData) {\n particle.emojiData = existingData;\n return;\n }\n const canvasSize = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getRangeMax)(particle.size.value) * double;\n let emojiData;\n const maxSize = (0,_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.getRangeMax)(particle.size.value);\n if (typeof OffscreenCanvas !== \"undefined\") {\n const canvas = new OffscreenCanvas(canvasSize, canvasSize),\n context = canvas.getContext(\"2d\");\n if (!context) {\n return;\n }\n context.font = `400 ${maxSize * double}px ${font}`;\n context.textBaseline = \"middle\";\n context.textAlign = \"center\";\n context.fillText(emoji, maxSize, maxSize);\n emojiData = canvas.transferToImageBitmap();\n } else {\n const canvas = document.createElement(\"canvas\");\n canvas.width = canvasSize;\n canvas.height = canvasSize;\n const context = canvas.getContext(\"2d\");\n if (!context) {\n return;\n }\n context.font = `400 ${maxSize * double}px ${font}`;\n context.textBaseline = \"middle\";\n context.textAlign = \"center\";\n context.fillText(emoji, maxSize, maxSize);\n emojiData = canvas;\n }\n this._emojiShapeDict.set(key, emojiData);\n particle.emojiData = emojiData;\n await Promise.resolve();\n }\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../shapes/emoji/dist/browser/EmojiDrawer.js?");
27
-
28
- /***/ })
29
-
30
- }]);
@@ -1,30 +0,0 @@
1
- /*!
2
- * Author : Matteo Bruni
3
- * MIT license: https://opensource.org/licenses/MIT
4
- * Demo / Generator : https://particles.js.org/
5
- * GitHub : https://www.github.com/matteobruni/tsparticles
6
- * How to use? : Check the GitHub README
7
- * v3.2.2
8
- */
9
- "use strict";
10
- /*
11
- * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
12
- * This devtool is neither made for production nor for readable output files.
13
- * It uses "eval()" calls to create a separate source file in the browser devtools.
14
- * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
15
- * or disable the default devtool with "devtool: false".
16
- * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
17
- */
18
- (this["webpackChunk_tsparticles_slim"] = this["webpackChunk_tsparticles_slim"] || []).push([["shapes_emoji_dist_browser_Utils_js"],{
19
-
20
- /***/ "../../shapes/emoji/dist/browser/Utils.js":
21
- /*!************************************************!*\
22
- !*** ../../shapes/emoji/dist/browser/Utils.js ***!
23
- \************************************************/
24
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
25
-
26
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ drawEmoji: () => (/* binding */ drawEmoji)\n/* harmony export */ });\nfunction drawEmoji(data) {\n const {\n context,\n particle,\n radius,\n opacity\n } = data,\n emojiData = particle.emojiData,\n double = 2,\n diameter = radius * double,\n previousAlpha = context.globalAlpha;\n if (!emojiData) {\n return;\n }\n context.globalAlpha = opacity;\n context.drawImage(emojiData, -radius, -radius, diameter, diameter);\n context.globalAlpha = previousAlpha;\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../shapes/emoji/dist/browser/Utils.js?");
27
-
28
- /***/ })
29
-
30
- }]);
@@ -1,40 +0,0 @@
1
- /*!
2
- * Author : Matteo Bruni
3
- * MIT license: https://opensource.org/licenses/MIT
4
- * Demo / Generator : https://particles.js.org/
5
- * GitHub : https://www.github.com/matteobruni/tsparticles
6
- * How to use? : Check the GitHub README
7
- * v3.2.2
8
- */
9
- "use strict";
10
- /*
11
- * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
12
- * This devtool is neither made for production nor for readable output files.
13
- * It uses "eval()" calls to create a separate source file in the browser devtools.
14
- * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
15
- * or disable the default devtool with "devtool: false".
16
- * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
17
- */
18
- (this["webpackChunk_tsparticles_slim"] = this["webpackChunk_tsparticles_slim"] || []).push([["shapes_emoji_dist_browser_index_js"],{
19
-
20
- /***/ "../../shapes/emoji/dist/browser/Constants.js":
21
- /*!****************************************************!*\
22
- !*** ../../shapes/emoji/dist/browser/Constants.js ***!
23
- \****************************************************/
24
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
25
-
26
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ validTypes: () => (/* binding */ validTypes)\n/* harmony export */ });\nconst validTypes = [\"emoji\"];\n\n//# sourceURL=webpack://@tsparticles/slim/../../shapes/emoji/dist/browser/Constants.js?");
27
-
28
- /***/ }),
29
-
30
- /***/ "../../shapes/emoji/dist/browser/index.js":
31
- /*!************************************************!*\
32
- !*** ../../shapes/emoji/dist/browser/index.js ***!
33
- \************************************************/
34
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
35
-
36
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ loadEmojiShape: () => (/* binding */ loadEmojiShape)\n/* harmony export */ });\n/* harmony import */ var _Constants_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./Constants.js */ \"../../shapes/emoji/dist/browser/Constants.js\");\n\nasync function loadEmojiShape(engine, refresh = true) {\n const {\n EmojiDrawer\n } = await __webpack_require__.e(/*! import() */ \"shapes_emoji_dist_browser_EmojiDrawer_js\").then(__webpack_require__.bind(__webpack_require__, /*! ./EmojiDrawer.js */ \"../../shapes/emoji/dist/browser/EmojiDrawer.js\"));\n await engine.addShape(_Constants_js__WEBPACK_IMPORTED_MODULE_0__.validTypes, new EmojiDrawer(), refresh);\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../shapes/emoji/dist/browser/index.js?");
37
-
38
- /***/ })
39
-
40
- }]);
@@ -1,50 +0,0 @@
1
- /*!
2
- * Author : Matteo Bruni
3
- * MIT license: https://opensource.org/licenses/MIT
4
- * Demo / Generator : https://particles.js.org/
5
- * GitHub : https://www.github.com/matteobruni/tsparticles
6
- * How to use? : Check the GitHub README
7
- * v3.2.2
8
- */
9
- "use strict";
10
- /*
11
- * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
12
- * This devtool is neither made for production nor for readable output files.
13
- * It uses "eval()" calls to create a separate source file in the browser devtools.
14
- * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
15
- * or disable the default devtool with "devtool: false".
16
- * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
17
- */
18
- (this["webpackChunk_tsparticles_slim"] = this["webpackChunk_tsparticles_slim"] || []).push([["shapes_image_dist_browser_GifUtils_Utils_js"],{
19
-
20
- /***/ "../../shapes/image/dist/browser/GifUtils/ByteStream.js":
21
- /*!**************************************************************!*\
22
- !*** ../../shapes/image/dist/browser/GifUtils/ByteStream.js ***!
23
- \**************************************************************/
24
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
25
-
26
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ ByteStream: () => (/* binding */ ByteStream)\n/* harmony export */ });\nclass ByteStream {\n constructor(bytes) {\n this.pos = 0;\n this.data = new Uint8ClampedArray(bytes);\n }\n getString(count) {\n const slice = this.data.slice(this.pos, this.pos + count);\n this.pos += slice.length;\n return slice.reduce((acc, curr) => acc + String.fromCharCode(curr), \"\");\n }\n nextByte() {\n return this.data[this.pos++];\n }\n nextTwoBytes() {\n const increment = 2,\n previous = 1,\n shift = 8;\n this.pos += increment;\n return this.data[this.pos - increment] + (this.data[this.pos - previous] << shift);\n }\n readSubBlocks() {\n let blockString = \"\",\n size = 0;\n const minCount = 0,\n emptySize = 0;\n do {\n size = this.data[this.pos++];\n for (let count = size; --count >= minCount; blockString += String.fromCharCode(this.data[this.pos++])) {}\n } while (size !== emptySize);\n return blockString;\n }\n readSubBlocksBin() {\n let size = this.data[this.pos],\n len = 0;\n const emptySize = 0,\n increment = 1;\n for (let offset = 0; size !== emptySize; offset += size + increment, size = this.data[this.pos + offset]) {\n len += size;\n }\n const blockData = new Uint8Array(len);\n size = this.data[this.pos++];\n for (let i = 0; size !== emptySize; size = this.data[this.pos++]) {\n for (let count = size; --count >= emptySize; blockData[i++] = this.data[this.pos++]) {}\n }\n return blockData;\n }\n skipSubBlocks() {\n for (const increment = 1, noData = 0; this.data[this.pos] !== noData; this.pos += this.data[this.pos] + increment) {}\n this.pos++;\n }\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../shapes/image/dist/browser/GifUtils/ByteStream.js?");
27
-
28
- /***/ }),
29
-
30
- /***/ "../../shapes/image/dist/browser/GifUtils/Constants.js":
31
- /*!*************************************************************!*\
32
- !*** ../../shapes/image/dist/browser/GifUtils/Constants.js ***!
33
- \*************************************************************/
34
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
35
-
36
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ InterlaceOffsets: () => (/* binding */ InterlaceOffsets),\n/* harmony export */ InterlaceSteps: () => (/* binding */ InterlaceSteps)\n/* harmony export */ });\nconst InterlaceOffsets = [0, 4, 2, 1];\nconst InterlaceSteps = [8, 8, 4, 2];\n\n//# sourceURL=webpack://@tsparticles/slim/../../shapes/image/dist/browser/GifUtils/Constants.js?");
37
-
38
- /***/ }),
39
-
40
- /***/ "../../shapes/image/dist/browser/GifUtils/Utils.js":
41
- /*!*********************************************************!*\
42
- !*** ../../shapes/image/dist/browser/GifUtils/Utils.js ***!
43
- \*********************************************************/
44
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
45
-
46
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ decodeGIF: () => (/* binding */ decodeGIF),\n/* harmony export */ drawGif: () => (/* binding */ drawGif),\n/* harmony export */ getGIFLoopAmount: () => (/* binding */ getGIFLoopAmount),\n/* harmony export */ loadGifImage: () => (/* binding */ loadGifImage)\n/* harmony export */ });\n/* harmony import */ var _Constants_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./Constants.js */ \"../../shapes/image/dist/browser/GifUtils/Constants.js\");\n/* harmony import */ var _ByteStream_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ./ByteStream.js */ \"../../shapes/image/dist/browser/GifUtils/ByteStream.js\");\n\n\nconst origin = {\n x: 0,\n y: 0\n },\n defaultFrame = 0,\n half = 0.5,\n initialTime = 0,\n firstIndex = 0,\n defaultLoopCount = 0;\nfunction parseColorTable(byteStream, count) {\n const colors = [];\n for (let i = 0; i < count; i++) {\n colors.push({\n r: byteStream.data[byteStream.pos],\n g: byteStream.data[byteStream.pos + 1],\n b: byteStream.data[byteStream.pos + 2]\n });\n byteStream.pos += 3;\n }\n return colors;\n}\nfunction parseExtensionBlock(byteStream, gif, getFrameIndex, getTransparencyIndex) {\n switch (byteStream.nextByte()) {\n case 249:\n {\n const frame = gif.frames[getFrameIndex(false)];\n byteStream.pos++;\n const packedByte = byteStream.nextByte();\n frame.GCreserved = (packedByte & 0xe0) >>> 5;\n frame.disposalMethod = (packedByte & 0x1c) >>> 2;\n frame.userInputDelayFlag = (packedByte & 2) === 2;\n const transparencyFlag = (packedByte & 1) === 1;\n frame.delayTime = byteStream.nextTwoBytes() * 0xa;\n const transparencyIndex = byteStream.nextByte();\n if (transparencyFlag) {\n getTransparencyIndex(transparencyIndex);\n }\n byteStream.pos++;\n break;\n }\n case 255:\n {\n byteStream.pos++;\n const applicationExtension = {\n identifier: byteStream.getString(8),\n authenticationCode: byteStream.getString(3),\n data: byteStream.readSubBlocksBin()\n };\n gif.applicationExtensions.push(applicationExtension);\n break;\n }\n case 254:\n {\n gif.comments.push([getFrameIndex(false), byteStream.readSubBlocks()]);\n break;\n }\n case 1:\n {\n if (gif.globalColorTable.length === 0) {\n throw new EvalError(\"plain text extension without global color table\");\n }\n byteStream.pos++;\n gif.frames[getFrameIndex(false)].plainTextData = {\n left: byteStream.nextTwoBytes(),\n top: byteStream.nextTwoBytes(),\n width: byteStream.nextTwoBytes(),\n height: byteStream.nextTwoBytes(),\n charSize: {\n width: byteStream.nextTwoBytes(),\n height: byteStream.nextTwoBytes()\n },\n foregroundColor: byteStream.nextByte(),\n backgroundColor: byteStream.nextByte(),\n text: byteStream.readSubBlocks()\n };\n break;\n }\n default:\n byteStream.skipSubBlocks();\n break;\n }\n}\nasync function parseImageBlock(byteStream, gif, avgAlpha, getFrameIndex, getTransparencyIndex, progressCallback) {\n const frame = gif.frames[getFrameIndex(true)];\n frame.left = byteStream.nextTwoBytes();\n frame.top = byteStream.nextTwoBytes();\n frame.width = byteStream.nextTwoBytes();\n frame.height = byteStream.nextTwoBytes();\n const packedByte = byteStream.nextByte(),\n localColorTableFlag = (packedByte & 0x80) === 0x80,\n interlacedFlag = (packedByte & 0x40) === 0x40;\n frame.sortFlag = (packedByte & 0x20) === 0x20;\n frame.reserved = (packedByte & 0x18) >>> 3;\n const localColorCount = 1 << (packedByte & 7) + 1;\n if (localColorTableFlag) {\n frame.localColorTable = parseColorTable(byteStream, localColorCount);\n }\n const getColor = index => {\n const {\n r,\n g,\n b\n } = (localColorTableFlag ? frame.localColorTable : gif.globalColorTable)[index];\n if (index !== getTransparencyIndex(null)) {\n return {\n r,\n g,\n b,\n a: 255\n };\n }\n return {\n r,\n g,\n b,\n a: avgAlpha ? ~~((r + g + b) / 3) : 0\n };\n };\n const image = (() => {\n try {\n return new ImageData(frame.width, frame.height, {\n colorSpace: \"srgb\"\n });\n } catch (error) {\n if (error instanceof DOMException && error.name === \"IndexSizeError\") {\n return null;\n }\n throw error;\n }\n })();\n if (image == null) {\n throw new EvalError(\"GIF frame size is to large\");\n }\n const minCodeSize = byteStream.nextByte(),\n imageData = byteStream.readSubBlocksBin(),\n clearCode = 1 << minCodeSize;\n const readBits = (pos, len) => {\n const bytePos = pos >>> 3,\n bitPos = pos & 7;\n return (imageData[bytePos] + (imageData[bytePos + 1] << 8) + (imageData[bytePos + 2] << 16) & (1 << len) - 1 << bitPos) >>> bitPos;\n };\n if (interlacedFlag) {\n for (let code = 0, size = minCodeSize + 1, pos = 0, dic = [[0]], pass = 0; pass < 4; pass++) {\n if (_Constants_js__WEBPACK_IMPORTED_MODULE_0__.InterlaceOffsets[pass] < frame.height) {\n let pixelPos = 0,\n lineIndex = 0,\n exit = false;\n while (!exit) {\n const last = code;\n code = readBits(pos, size);\n pos += size + 1;\n if (code === clearCode) {\n size = minCodeSize + 1;\n dic.length = clearCode + 2;\n for (let i = 0; i < dic.length; i++) {\n dic[i] = i < clearCode ? [i] : [];\n }\n } else {\n if (code >= dic.length) {\n dic.push(dic[last].concat(dic[last][0]));\n } else if (last !== clearCode) {\n dic.push(dic[last].concat(dic[code][0]));\n }\n for (const item of dic[code]) {\n const {\n r,\n g,\n b,\n a\n } = getColor(item);\n image.data.set([r, g, b, a], _Constants_js__WEBPACK_IMPORTED_MODULE_0__.InterlaceOffsets[pass] * frame.width + _Constants_js__WEBPACK_IMPORTED_MODULE_0__.InterlaceSteps[pass] * lineIndex + pixelPos % (frame.width * 4));\n pixelPos += 4;\n }\n if (dic.length === 1 << size && size < 0xc) {\n size++;\n }\n }\n if (pixelPos === frame.width * 4 * (lineIndex + 1)) {\n lineIndex++;\n if (_Constants_js__WEBPACK_IMPORTED_MODULE_0__.InterlaceOffsets[pass] + _Constants_js__WEBPACK_IMPORTED_MODULE_0__.InterlaceSteps[pass] * lineIndex >= frame.height) {\n exit = true;\n }\n }\n }\n }\n progressCallback?.(byteStream.pos / (byteStream.data.length - 1), getFrameIndex(false) + 1, image, {\n x: frame.left,\n y: frame.top\n }, {\n width: gif.width,\n height: gif.height\n });\n }\n frame.image = image;\n frame.bitmap = await createImageBitmap(image);\n } else {\n let code = 0,\n size = minCodeSize + 1,\n pos = 0,\n pixelPos = -4,\n exit = false;\n const dic = [[0]];\n while (!exit) {\n const last = code;\n code = readBits(pos, size);\n pos += size;\n if (code === clearCode) {\n size = minCodeSize + 1;\n dic.length = clearCode + 2;\n for (let i = 0; i < dic.length; i++) {\n dic[i] = i < clearCode ? [i] : [];\n }\n } else {\n if (code === clearCode + 1) {\n exit = true;\n break;\n }\n if (code >= dic.length) {\n dic.push(dic[last].concat(dic[last][0]));\n } else if (last !== clearCode) {\n dic.push(dic[last].concat(dic[code][0]));\n }\n for (const item of dic[code]) {\n const {\n r,\n g,\n b,\n a\n } = getColor(item);\n image.data.set([r, g, b, a], pixelPos += 4);\n }\n if (dic.length >= 1 << size && size < 0xc) {\n size++;\n }\n }\n }\n frame.image = image;\n frame.bitmap = await createImageBitmap(image);\n progressCallback?.((byteStream.pos + 1) / byteStream.data.length, getFrameIndex(false) + 1, frame.image, {\n x: frame.left,\n y: frame.top\n }, {\n width: gif.width,\n height: gif.height\n });\n }\n}\nasync function parseBlock(byteStream, gif, avgAlpha, getFrameIndex, getTransparencyIndex, progressCallback) {\n switch (byteStream.nextByte()) {\n case 59:\n return true;\n case 44:\n await parseImageBlock(byteStream, gif, avgAlpha, getFrameIndex, getTransparencyIndex, progressCallback);\n break;\n case 33:\n parseExtensionBlock(byteStream, gif, getFrameIndex, getTransparencyIndex);\n break;\n default:\n throw new EvalError(\"undefined block found\");\n }\n return false;\n}\nfunction getGIFLoopAmount(gif) {\n for (const extension of gif.applicationExtensions) {\n if (extension.identifier + extension.authenticationCode !== \"NETSCAPE2.0\") {\n continue;\n }\n return extension.data[1] + (extension.data[2] << 8);\n }\n return NaN;\n}\nasync function decodeGIF(gifURL, progressCallback, avgAlpha) {\n if (!avgAlpha) avgAlpha = false;\n const res = await fetch(gifURL);\n if (!res.ok && res.status === 404) {\n throw new EvalError(\"file not found\");\n }\n const buffer = await res.arrayBuffer();\n const gif = {\n width: 0,\n height: 0,\n totalTime: 0,\n colorRes: 0,\n pixelAspectRatio: 0,\n frames: [],\n sortFlag: false,\n globalColorTable: [],\n backgroundImage: new ImageData(1, 1, {\n colorSpace: \"srgb\"\n }),\n comments: [],\n applicationExtensions: []\n },\n byteStream = new _ByteStream_js__WEBPACK_IMPORTED_MODULE_1__.ByteStream(new Uint8ClampedArray(buffer));\n if (byteStream.getString(6) !== \"GIF89a\") {\n throw new Error(\"not a supported GIF file\");\n }\n gif.width = byteStream.nextTwoBytes();\n gif.height = byteStream.nextTwoBytes();\n const packedByte = byteStream.nextByte(),\n globalColorTableFlag = (packedByte & 0x80) === 0x80;\n gif.colorRes = (packedByte & 0x70) >>> 4;\n gif.sortFlag = (packedByte & 8) === 8;\n const globalColorCount = 1 << (packedByte & 7) + 1,\n backgroundColorIndex = byteStream.nextByte();\n gif.pixelAspectRatio = byteStream.nextByte();\n if (gif.pixelAspectRatio !== 0) {\n gif.pixelAspectRatio = (gif.pixelAspectRatio + 0xf) / 0x40;\n }\n if (globalColorTableFlag) {\n gif.globalColorTable = parseColorTable(byteStream, globalColorCount);\n }\n const backgroundImage = (() => {\n try {\n return new ImageData(gif.width, gif.height, {\n colorSpace: \"srgb\"\n });\n } catch (error) {\n if (error instanceof DOMException && error.name === \"IndexSizeError\") {\n return null;\n }\n throw error;\n }\n })();\n if (backgroundImage == null) {\n throw new Error(\"GIF frame size is to large\");\n }\n const {\n r,\n g,\n b\n } = gif.globalColorTable[backgroundColorIndex];\n backgroundImage.data.set(globalColorTableFlag ? [r, g, b, 255] : [0, 0, 0, 0]);\n for (let i = 4; i < backgroundImage.data.length; i *= 2) {\n backgroundImage.data.copyWithin(i, 0, i);\n }\n gif.backgroundImage = backgroundImage;\n let frameIndex = -1,\n incrementFrameIndex = true,\n transparencyIndex = -1;\n const getframeIndex = increment => {\n if (increment) {\n incrementFrameIndex = true;\n }\n return frameIndex;\n };\n const getTransparencyIndex = newValue => {\n if (newValue != null) {\n transparencyIndex = newValue;\n }\n return transparencyIndex;\n };\n try {\n do {\n if (incrementFrameIndex) {\n gif.frames.push({\n left: 0,\n top: 0,\n width: 0,\n height: 0,\n disposalMethod: 0,\n image: new ImageData(1, 1, {\n colorSpace: \"srgb\"\n }),\n plainTextData: null,\n userInputDelayFlag: false,\n delayTime: 0,\n sortFlag: false,\n localColorTable: [],\n reserved: 0,\n GCreserved: 0\n });\n frameIndex++;\n transparencyIndex = -1;\n incrementFrameIndex = false;\n }\n } while (!(await parseBlock(byteStream, gif, avgAlpha, getframeIndex, getTransparencyIndex, progressCallback)));\n gif.frames.length--;\n for (const frame of gif.frames) {\n if (frame.userInputDelayFlag && frame.delayTime === 0) {\n gif.totalTime = Infinity;\n break;\n }\n gif.totalTime += frame.delayTime;\n }\n return gif;\n } catch (error) {\n if (error instanceof EvalError) {\n throw new Error(`error while parsing frame ${frameIndex} \"${error.message}\"`);\n }\n throw error;\n }\n}\nfunction drawGif(data) {\n const {\n context,\n radius,\n particle,\n delta\n } = data,\n image = particle.image;\n if (!image?.gifData || !image.gif) {\n return;\n }\n const offscreenCanvas = new OffscreenCanvas(image.gifData.width, image.gifData.height),\n offscreenContext = offscreenCanvas.getContext(\"2d\");\n if (!offscreenContext) {\n throw new Error(\"could not create offscreen canvas context\");\n }\n offscreenContext.imageSmoothingQuality = \"low\";\n offscreenContext.imageSmoothingEnabled = false;\n offscreenContext.clearRect(origin.x, origin.y, offscreenCanvas.width, offscreenCanvas.height);\n if (particle.gifLoopCount === undefined) {\n particle.gifLoopCount = image.gifLoopCount ?? defaultLoopCount;\n }\n let frameIndex = particle.gifFrame ?? defaultFrame;\n const pos = {\n x: -image.gifData.width * half,\n y: -image.gifData.height * half\n },\n frame = image.gifData.frames[frameIndex];\n if (particle.gifTime === undefined) {\n particle.gifTime = initialTime;\n }\n if (!frame.bitmap) {\n return;\n }\n context.scale(radius / image.gifData.width, radius / image.gifData.height);\n switch (frame.disposalMethod) {\n case 4:\n case 5:\n case 6:\n case 7:\n case 0:\n offscreenContext.drawImage(frame.bitmap, frame.left, frame.top);\n context.drawImage(offscreenCanvas, pos.x, pos.y);\n offscreenContext.clearRect(origin.x, origin.y, offscreenCanvas.width, offscreenCanvas.height);\n break;\n case 1:\n offscreenContext.drawImage(frame.bitmap, frame.left, frame.top);\n context.drawImage(offscreenCanvas, pos.x, pos.y);\n break;\n case 2:\n offscreenContext.drawImage(frame.bitmap, frame.left, frame.top);\n context.drawImage(offscreenCanvas, pos.x, pos.y);\n offscreenContext.clearRect(origin.x, origin.y, offscreenCanvas.width, offscreenCanvas.height);\n if (!image.gifData.globalColorTable.length) {\n offscreenContext.putImageData(image.gifData.frames[firstIndex].image, pos.x + frame.left, pos.y + frame.top);\n } else {\n offscreenContext.putImageData(image.gifData.backgroundImage, pos.x, pos.y);\n }\n break;\n case 3:\n {\n const previousImageData = offscreenContext.getImageData(origin.x, origin.y, offscreenCanvas.width, offscreenCanvas.height);\n offscreenContext.drawImage(frame.bitmap, frame.left, frame.top);\n context.drawImage(offscreenCanvas, pos.x, pos.y);\n offscreenContext.clearRect(origin.x, origin.y, offscreenCanvas.width, offscreenCanvas.height);\n offscreenContext.putImageData(previousImageData, origin.x, origin.y);\n }\n break;\n }\n particle.gifTime += delta.value;\n if (particle.gifTime > frame.delayTime) {\n particle.gifTime -= frame.delayTime;\n if (++frameIndex >= image.gifData.frames.length) {\n if (--particle.gifLoopCount <= defaultLoopCount) {\n return;\n }\n frameIndex = firstIndex;\n offscreenContext.clearRect(origin.x, origin.y, offscreenCanvas.width, offscreenCanvas.height);\n }\n particle.gifFrame = frameIndex;\n }\n context.scale(image.gifData.width / radius, image.gifData.height / radius);\n}\nasync function loadGifImage(image) {\n if (image.type !== \"gif\") {\n const {\n loadImage\n } = await Promise.resolve(/*! import() */).then(__webpack_require__.bind(__webpack_require__, /*! ../Utils.js */ \"../../shapes/image/dist/browser/Utils.js\"));\n await loadImage(image);\n return;\n }\n image.loading = true;\n try {\n image.gifData = await decodeGIF(image.source);\n image.gifLoopCount = getGIFLoopAmount(image.gifData) ?? defaultLoopCount;\n if (!image.gifLoopCount) {\n image.gifLoopCount = Infinity;\n }\n } catch {\n image.error = true;\n }\n image.loading = false;\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../shapes/image/dist/browser/GifUtils/Utils.js?");
47
-
48
- /***/ })
49
-
50
- }]);
@@ -1,30 +0,0 @@
1
- /*!
2
- * Author : Matteo Bruni
3
- * MIT license: https://opensource.org/licenses/MIT
4
- * Demo / Generator : https://particles.js.org/
5
- * GitHub : https://www.github.com/matteobruni/tsparticles
6
- * How to use? : Check the GitHub README
7
- * v3.2.2
8
- */
9
- "use strict";
10
- /*
11
- * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
12
- * This devtool is neither made for production nor for readable output files.
13
- * It uses "eval()" calls to create a separate source file in the browser devtools.
14
- * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
15
- * or disable the default devtool with "devtool: false".
16
- * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
17
- */
18
- (this["webpackChunk_tsparticles_slim"] = this["webpackChunk_tsparticles_slim"] || []).push([["shapes_image_dist_browser_ImageDrawer_js"],{
19
-
20
- /***/ "../../shapes/image/dist/browser/ImageDrawer.js":
21
- /*!******************************************************!*\
22
- !*** ../../shapes/image/dist/browser/ImageDrawer.js ***!
23
- \******************************************************/
24
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
25
-
26
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ ImageDrawer: () => (/* binding */ ImageDrawer)\n/* harmony export */ });\n/* harmony import */ var _tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! @tsparticles/engine */ \"../../engine/dist/browser/index.js\");\n\nconst double = 2,\n defaultAlpha = 1,\n sides = 12,\n defaultRatio = 1;\nclass ImageDrawer {\n constructor(engine) {\n this.loadImageShape = async imageShape => {\n if (!this._engine.loadImage) {\n throw new Error(`${_tsparticles_engine__WEBPACK_IMPORTED_MODULE_0__.errorPrefix} image shape not initialized`);\n }\n await this._engine.loadImage({\n gif: imageShape.gif,\n name: imageShape.name,\n replaceColor: imageShape.replaceColor ?? false,\n src: imageShape.src\n });\n };\n this._engine = engine;\n }\n addImage(image) {\n if (!this._engine.images) {\n this._engine.images = [];\n }\n this._engine.images.push(image);\n }\n async draw(data) {\n const {\n context,\n radius,\n particle,\n opacity\n } = data,\n image = particle.image,\n element = image?.element;\n if (!image) {\n return;\n }\n context.globalAlpha = opacity;\n if (image.gif && image.gifData) {\n const {\n drawGif\n } = await __webpack_require__.e(/*! import() */ \"shapes_image_dist_browser_GifUtils_Utils_js\").then(__webpack_require__.bind(__webpack_require__, /*! ./GifUtils/Utils.js */ \"../../shapes/image/dist/browser/GifUtils/Utils.js\"));\n drawGif(data);\n } else if (element) {\n const ratio = image.ratio,\n pos = {\n x: -radius,\n y: -radius\n },\n diameter = radius * double;\n context.drawImage(element, pos.x, pos.y, diameter, diameter / ratio);\n }\n context.globalAlpha = defaultAlpha;\n }\n getSidesCount() {\n return sides;\n }\n async init(container) {\n const options = container.actualOptions;\n if (!options.preload || !this._engine.loadImage) {\n return;\n }\n for (const imageData of options.preload) {\n await this._engine.loadImage(imageData);\n }\n }\n async loadShape(particle) {\n if (particle.shape !== \"image\" && particle.shape !== \"images\") {\n return;\n }\n if (!this._engine.images) {\n this._engine.images = [];\n }\n const imageData = particle.shapeData;\n if (!imageData) {\n return;\n }\n const image = this._engine.images.find(t => t.name === imageData.name || t.source === imageData.src);\n if (!image) {\n await this.loadImageShape(imageData);\n await this.loadShape(particle);\n }\n }\n async particleInit(container, particle) {\n if (particle.shape !== \"image\" && particle.shape !== \"images\") {\n return;\n }\n if (!this._engine.images) {\n this._engine.images = [];\n }\n const images = this._engine.images,\n imageData = particle.shapeData;\n if (!imageData) {\n return;\n }\n const color = particle.getFillColor(),\n image = images.find(t => t.name === imageData.name || t.source === imageData.src);\n if (!image) {\n return;\n }\n const replaceColor = imageData.replaceColor ?? image.replaceColor;\n if (image.loading) {\n setTimeout(() => {\n void this.particleInit(container, particle);\n });\n return;\n }\n let imageRes;\n if (image.svgData && color) {\n const {\n replaceImageColor\n } = await Promise.resolve(/*! import() */).then(__webpack_require__.bind(__webpack_require__, /*! ./Utils.js */ \"../../shapes/image/dist/browser/Utils.js\"));\n imageRes = await replaceImageColor(image, imageData, color, particle);\n } else {\n imageRes = {\n color,\n data: image,\n element: image.element,\n gif: image.gif,\n gifData: image.gifData,\n gifLoopCount: image.gifLoopCount,\n loaded: true,\n ratio: imageData.width && imageData.height ? imageData.width / imageData.height : image.ratio ?? defaultRatio,\n replaceColor: replaceColor,\n source: imageData.src\n };\n }\n if (!imageRes.ratio) {\n imageRes.ratio = 1;\n }\n const fill = imageData.fill ?? particle.shapeFill,\n close = imageData.close ?? particle.shapeClose,\n imageShape = {\n image: imageRes,\n fill,\n close\n };\n particle.image = imageShape.image;\n particle.shapeFill = imageShape.fill;\n particle.shapeClose = imageShape.close;\n }\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../shapes/image/dist/browser/ImageDrawer.js?");
27
-
28
- /***/ })
29
-
30
- }]);
@@ -1,40 +0,0 @@
1
- /*!
2
- * Author : Matteo Bruni
3
- * MIT license: https://opensource.org/licenses/MIT
4
- * Demo / Generator : https://particles.js.org/
5
- * GitHub : https://www.github.com/matteobruni/tsparticles
6
- * How to use? : Check the GitHub README
7
- * v3.2.2
8
- */
9
- "use strict";
10
- /*
11
- * ATTENTION: The "eval" devtool has been used (maybe by default in mode: "development").
12
- * This devtool is neither made for production nor for readable output files.
13
- * It uses "eval()" calls to create a separate source file in the browser devtools.
14
- * If you are trying to read the output file, select a different devtool (https://webpack.js.org/configuration/devtool/)
15
- * or disable the default devtool with "devtool: false".
16
- * If you are looking for production-ready output files, see mode: "production" (https://webpack.js.org/configuration/mode/).
17
- */
18
- (this["webpackChunk_tsparticles_slim"] = this["webpackChunk_tsparticles_slim"] || []).push([["shapes_image_dist_browser_ImagePreloader_js"],{
19
-
20
- /***/ "../../shapes/image/dist/browser/ImagePreloader.js":
21
- /*!*********************************************************!*\
22
- !*** ../../shapes/image/dist/browser/ImagePreloader.js ***!
23
- \*********************************************************/
24
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
25
-
26
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ ImagePreloaderPlugin: () => (/* binding */ ImagePreloaderPlugin)\n/* harmony export */ });\n/* harmony import */ var _Options_Classes_Preload_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./Options/Classes/Preload.js */ \"../../shapes/image/dist/browser/Options/Classes/Preload.js\");\n\nclass ImagePreloaderPlugin {\n constructor(engine) {\n this.id = \"imagePreloader\";\n this._engine = engine;\n }\n async getPlugin() {\n await Promise.resolve();\n return {};\n }\n loadOptions(options, source) {\n if (!source?.preload) {\n return;\n }\n if (!options.preload) {\n options.preload = [];\n }\n const preloadOptions = options.preload;\n for (const item of source.preload) {\n const existing = preloadOptions.find(t => t.name === item.name || t.src === item.src);\n if (existing) {\n existing.load(item);\n } else {\n const preload = new _Options_Classes_Preload_js__WEBPACK_IMPORTED_MODULE_0__.Preload();\n preload.load(item);\n preloadOptions.push(preload);\n }\n }\n }\n needsPlugin() {\n return true;\n }\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../shapes/image/dist/browser/ImagePreloader.js?");
27
-
28
- /***/ }),
29
-
30
- /***/ "../../shapes/image/dist/browser/Options/Classes/Preload.js":
31
- /*!******************************************************************!*\
32
- !*** ../../shapes/image/dist/browser/Options/Classes/Preload.js ***!
33
- \******************************************************************/
34
- /***/ ((__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) => {
35
-
36
- eval("__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ Preload: () => (/* binding */ Preload)\n/* harmony export */ });\nclass Preload {\n constructor() {\n this.src = \"\";\n this.gif = false;\n }\n load(data) {\n if (!data) {\n return;\n }\n if (data.gif !== undefined) {\n this.gif = data.gif;\n }\n if (data.height !== undefined) {\n this.height = data.height;\n }\n if (data.name !== undefined) {\n this.name = data.name;\n }\n if (data.replaceColor !== undefined) {\n this.replaceColor = data.replaceColor;\n }\n if (data.src !== undefined) {\n this.src = data.src;\n }\n if (data.width !== undefined) {\n this.width = data.width;\n }\n }\n}\n\n//# sourceURL=webpack://@tsparticles/slim/../../shapes/image/dist/browser/Options/Classes/Preload.js?");
37
-
38
- /***/ })
39
-
40
- }]);