@tsparticles/all 3.0.0-beta.0 → 3.0.0-beta.2
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.
- package/README.md +37 -37
- package/browser/package.json +1 -0
- package/cjs/package.json +1 -0
- package/esm/package.json +1 -0
- package/package.json +55 -43
- package/report.html +23 -5
- package/tsparticles.all.bundle.js +13953 -13988
- package/tsparticles.all.bundle.min.js +1 -1
- package/tsparticles.all.bundle.min.js.LICENSE.txt +1 -1
- package/tsparticles.all.js +19 -19
- package/tsparticles.all.min.js +1 -1
- package/tsparticles.all.min.js.LICENSE.txt +1 -1
|
@@ -1 +1 @@
|
|
|
1
|
-
/*! tsParticles All v3.0.0-beta.
|
|
1
|
+
/*! tsParticles All v3.0.0-beta.2 by Matteo Bruni */
|
package/tsparticles.all.js
CHANGED
|
@@ -4,18 +4,18 @@
|
|
|
4
4
|
* Demo / Generator : https://particles.js.org/
|
|
5
5
|
* GitHub : https://www.github.com/matteobruni/tsparticles
|
|
6
6
|
* How to use? : Check the GitHub README
|
|
7
|
-
* v3.0.0-beta.
|
|
7
|
+
* v3.0.0-beta.2
|
|
8
8
|
*/
|
|
9
9
|
(function webpackUniversalModuleDefinition(root, factory) {
|
|
10
10
|
if(typeof exports === 'object' && typeof module === 'object')
|
|
11
|
-
module.exports = factory(require("@tsparticles/shape-bubble"), require("@tsparticles/plugin-canvas-mask"), require("@tsparticles/shape-cards"), require("@tsparticles/path-curves"), require("@tsparticles/plugin-easing-back"), require("@tsparticles/plugin-easing-circ"), require("@tsparticles/plugin-easing-cubic"), require("@tsparticles/plugin-easing-expo"), require("@tsparticles/plugin-easing-quart"), require("@tsparticles/plugin-easing-quint"), require("@tsparticles/plugin-easing-sine"), require("tsparticles"), require("@tsparticles/updater-gradient"), require("@tsparticles/shape-heart"), require("@tsparticles/plugin-hsv-color"), require("@tsparticles/plugin-infection"), require("@tsparticles/interaction-light"), require("@tsparticles/plugin-motion"), require("@tsparticles/shape-multiline-text"), require("@tsparticles/updater-orbit"), require("@tsparticles/interaction-particles-repulse"), require("@tsparticles/shape-path"), require("@tsparticles/path-perlin-noise"), require("@tsparticles/plugin-polygon-mask"), require("@tsparticles/path-polygon"), require("@tsparticles/shape-rounded-rect"), require("@tsparticles/path-simplex-noise"), require("@tsparticles/plugin-sounds"), require("@tsparticles/shape-spiral")
|
|
11
|
+
module.exports = factory(require("@tsparticles/engine"), require("@tsparticles/shape-bubble"), require("@tsparticles/plugin-canvas-mask"), require("@tsparticles/shape-cards"), require("@tsparticles/path-curves"), require("@tsparticles/plugin-easing-back"), require("@tsparticles/plugin-easing-circ"), require("@tsparticles/plugin-easing-cubic"), require("@tsparticles/plugin-easing-expo"), require("@tsparticles/plugin-easing-quart"), require("@tsparticles/plugin-easing-quint"), require("@tsparticles/plugin-easing-sine"), require("tsparticles"), require("@tsparticles/updater-gradient"), require("@tsparticles/shape-heart"), require("@tsparticles/plugin-hsv-color"), require("@tsparticles/plugin-infection"), require("@tsparticles/interaction-light"), require("@tsparticles/plugin-motion"), require("@tsparticles/shape-multiline-text"), require("@tsparticles/updater-orbit"), require("@tsparticles/interaction-particles-repulse"), require("@tsparticles/shape-path"), require("@tsparticles/path-perlin-noise"), require("@tsparticles/plugin-polygon-mask"), require("@tsparticles/path-polygon"), require("@tsparticles/shape-rounded-rect"), require("@tsparticles/path-simplex-noise"), require("@tsparticles/plugin-sounds"), require("@tsparticles/shape-spiral"));
|
|
12
12
|
else if(typeof define === 'function' && define.amd)
|
|
13
|
-
define(["@tsparticles/shape-bubble", "@tsparticles/plugin-canvas-mask", "@tsparticles/shape-cards", "@tsparticles/path-curves", "@tsparticles/plugin-easing-back", "@tsparticles/plugin-easing-circ", "@tsparticles/plugin-easing-cubic", "@tsparticles/plugin-easing-expo", "@tsparticles/plugin-easing-quart", "@tsparticles/plugin-easing-quint", "@tsparticles/plugin-easing-sine", "tsparticles", "@tsparticles/updater-gradient", "@tsparticles/shape-heart", "@tsparticles/plugin-hsv-color", "@tsparticles/plugin-infection", "@tsparticles/interaction-light", "@tsparticles/plugin-motion", "@tsparticles/shape-multiline-text", "@tsparticles/updater-orbit", "@tsparticles/interaction-particles-repulse", "@tsparticles/shape-path", "@tsparticles/path-perlin-noise", "@tsparticles/plugin-polygon-mask", "@tsparticles/path-polygon", "@tsparticles/shape-rounded-rect", "@tsparticles/path-simplex-noise", "@tsparticles/plugin-sounds", "@tsparticles/shape-spiral"
|
|
13
|
+
define(["@tsparticles/engine", "@tsparticles/shape-bubble", "@tsparticles/plugin-canvas-mask", "@tsparticles/shape-cards", "@tsparticles/path-curves", "@tsparticles/plugin-easing-back", "@tsparticles/plugin-easing-circ", "@tsparticles/plugin-easing-cubic", "@tsparticles/plugin-easing-expo", "@tsparticles/plugin-easing-quart", "@tsparticles/plugin-easing-quint", "@tsparticles/plugin-easing-sine", "tsparticles", "@tsparticles/updater-gradient", "@tsparticles/shape-heart", "@tsparticles/plugin-hsv-color", "@tsparticles/plugin-infection", "@tsparticles/interaction-light", "@tsparticles/plugin-motion", "@tsparticles/shape-multiline-text", "@tsparticles/updater-orbit", "@tsparticles/interaction-particles-repulse", "@tsparticles/shape-path", "@tsparticles/path-perlin-noise", "@tsparticles/plugin-polygon-mask", "@tsparticles/path-polygon", "@tsparticles/shape-rounded-rect", "@tsparticles/path-simplex-noise", "@tsparticles/plugin-sounds", "@tsparticles/shape-spiral"], factory);
|
|
14
14
|
else {
|
|
15
|
-
var a = typeof exports === 'object' ? factory(require("@tsparticles/shape-bubble"), require("@tsparticles/plugin-canvas-mask"), require("@tsparticles/shape-cards"), require("@tsparticles/path-curves"), require("@tsparticles/plugin-easing-back"), require("@tsparticles/plugin-easing-circ"), require("@tsparticles/plugin-easing-cubic"), require("@tsparticles/plugin-easing-expo"), require("@tsparticles/plugin-easing-quart"), require("@tsparticles/plugin-easing-quint"), require("@tsparticles/plugin-easing-sine"), require("tsparticles"), require("@tsparticles/updater-gradient"), require("@tsparticles/shape-heart"), require("@tsparticles/plugin-hsv-color"), require("@tsparticles/plugin-infection"), require("@tsparticles/interaction-light"), require("@tsparticles/plugin-motion"), require("@tsparticles/shape-multiline-text"), require("@tsparticles/updater-orbit"), require("@tsparticles/interaction-particles-repulse"), require("@tsparticles/shape-path"), require("@tsparticles/path-perlin-noise"), require("@tsparticles/plugin-polygon-mask"), require("@tsparticles/path-polygon"), require("@tsparticles/shape-rounded-rect"), require("@tsparticles/path-simplex-noise"), require("@tsparticles/plugin-sounds"), require("@tsparticles/shape-spiral")
|
|
15
|
+
var a = typeof exports === 'object' ? factory(require("@tsparticles/engine"), require("@tsparticles/shape-bubble"), require("@tsparticles/plugin-canvas-mask"), require("@tsparticles/shape-cards"), require("@tsparticles/path-curves"), require("@tsparticles/plugin-easing-back"), require("@tsparticles/plugin-easing-circ"), require("@tsparticles/plugin-easing-cubic"), require("@tsparticles/plugin-easing-expo"), require("@tsparticles/plugin-easing-quart"), require("@tsparticles/plugin-easing-quint"), require("@tsparticles/plugin-easing-sine"), require("tsparticles"), require("@tsparticles/updater-gradient"), require("@tsparticles/shape-heart"), require("@tsparticles/plugin-hsv-color"), require("@tsparticles/plugin-infection"), require("@tsparticles/interaction-light"), require("@tsparticles/plugin-motion"), require("@tsparticles/shape-multiline-text"), require("@tsparticles/updater-orbit"), require("@tsparticles/interaction-particles-repulse"), require("@tsparticles/shape-path"), require("@tsparticles/path-perlin-noise"), require("@tsparticles/plugin-polygon-mask"), require("@tsparticles/path-polygon"), require("@tsparticles/shape-rounded-rect"), require("@tsparticles/path-simplex-noise"), require("@tsparticles/plugin-sounds"), require("@tsparticles/shape-spiral")) : factory(root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"], root["window"]);
|
|
16
16
|
for(var i in a) (typeof exports === 'object' ? exports : root)[i] = a[i];
|
|
17
17
|
}
|
|
18
|
-
})(this, (__WEBPACK_EXTERNAL_MODULE__164__, __WEBPACK_EXTERNAL_MODULE__72__, __WEBPACK_EXTERNAL_MODULE__686__, __WEBPACK_EXTERNAL_MODULE__997__, __WEBPACK_EXTERNAL_MODULE__792__, __WEBPACK_EXTERNAL_MODULE__176__, __WEBPACK_EXTERNAL_MODULE__922__, __WEBPACK_EXTERNAL_MODULE__594__, __WEBPACK_EXTERNAL_MODULE__205__, __WEBPACK_EXTERNAL_MODULE__144__, __WEBPACK_EXTERNAL_MODULE__691__, __WEBPACK_EXTERNAL_MODULE__802__, __WEBPACK_EXTERNAL_MODULE__887__, __WEBPACK_EXTERNAL_MODULE__12__, __WEBPACK_EXTERNAL_MODULE__673__, __WEBPACK_EXTERNAL_MODULE__521__, __WEBPACK_EXTERNAL_MODULE__55__, __WEBPACK_EXTERNAL_MODULE__82__, __WEBPACK_EXTERNAL_MODULE__940__, __WEBPACK_EXTERNAL_MODULE__193__, __WEBPACK_EXTERNAL_MODULE__297__, __WEBPACK_EXTERNAL_MODULE__901__, __WEBPACK_EXTERNAL_MODULE__228__, __WEBPACK_EXTERNAL_MODULE__124__, __WEBPACK_EXTERNAL_MODULE__231__, __WEBPACK_EXTERNAL_MODULE__550__, __WEBPACK_EXTERNAL_MODULE__520__, __WEBPACK_EXTERNAL_MODULE__490__, __WEBPACK_EXTERNAL_MODULE__561__
|
|
18
|
+
})(this, (__WEBPACK_EXTERNAL_MODULE__533__, __WEBPACK_EXTERNAL_MODULE__164__, __WEBPACK_EXTERNAL_MODULE__72__, __WEBPACK_EXTERNAL_MODULE__686__, __WEBPACK_EXTERNAL_MODULE__997__, __WEBPACK_EXTERNAL_MODULE__792__, __WEBPACK_EXTERNAL_MODULE__176__, __WEBPACK_EXTERNAL_MODULE__922__, __WEBPACK_EXTERNAL_MODULE__594__, __WEBPACK_EXTERNAL_MODULE__205__, __WEBPACK_EXTERNAL_MODULE__144__, __WEBPACK_EXTERNAL_MODULE__691__, __WEBPACK_EXTERNAL_MODULE__802__, __WEBPACK_EXTERNAL_MODULE__887__, __WEBPACK_EXTERNAL_MODULE__12__, __WEBPACK_EXTERNAL_MODULE__673__, __WEBPACK_EXTERNAL_MODULE__521__, __WEBPACK_EXTERNAL_MODULE__55__, __WEBPACK_EXTERNAL_MODULE__82__, __WEBPACK_EXTERNAL_MODULE__940__, __WEBPACK_EXTERNAL_MODULE__193__, __WEBPACK_EXTERNAL_MODULE__297__, __WEBPACK_EXTERNAL_MODULE__901__, __WEBPACK_EXTERNAL_MODULE__228__, __WEBPACK_EXTERNAL_MODULE__124__, __WEBPACK_EXTERNAL_MODULE__231__, __WEBPACK_EXTERNAL_MODULE__550__, __WEBPACK_EXTERNAL_MODULE__520__, __WEBPACK_EXTERNAL_MODULE__490__, __WEBPACK_EXTERNAL_MODULE__561__) => {
|
|
19
19
|
return /******/ (() => { // webpackBootstrap
|
|
20
20
|
/******/ "use strict";
|
|
21
21
|
/******/ var __webpack_modules__ = ({
|
|
@@ -299,7 +299,7 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
299
299
|
|
|
300
300
|
// EXTERNAL MODULE: external {"commonjs":"@tsparticles/engine","commonjs2":"@tsparticles/engine","amd":"@tsparticles/engine","root":"window"}
|
|
301
301
|
var engine_root_window_ = __webpack_require__(533);
|
|
302
|
-
;// CONCATENATED MODULE: ../../shapes/arrow/dist/
|
|
302
|
+
;// CONCATENATED MODULE: ../../shapes/arrow/dist/browser/ArrowDrawer.js
|
|
303
303
|
|
|
304
304
|
class ArrowDrawer {
|
|
305
305
|
draw(context, particle, radius) {
|
|
@@ -327,7 +327,7 @@ class ArrowDrawer {
|
|
|
327
327
|
particle.bodyHeightFactor = (0,engine_root_window_.getRangeValue)(shapeData?.bodyHeightFactor ?? 0.5);
|
|
328
328
|
}
|
|
329
329
|
}
|
|
330
|
-
;// CONCATENATED MODULE: ../../shapes/arrow/dist/
|
|
330
|
+
;// CONCATENATED MODULE: ../../shapes/arrow/dist/browser/index.js
|
|
331
331
|
|
|
332
332
|
async function loadArrowShape(engine, refresh = true) {
|
|
333
333
|
await engine.addShape("arrow", new ArrowDrawer(), refresh);
|
|
@@ -338,7 +338,7 @@ var shape_bubble_root_window_ = __webpack_require__(164);
|
|
|
338
338
|
var plugin_canvas_mask_root_window_ = __webpack_require__(72);
|
|
339
339
|
// EXTERNAL MODULE: external {"commonjs":"@tsparticles/shape-cards","commonjs2":"@tsparticles/shape-cards","amd":"@tsparticles/shape-cards","root":"window"}
|
|
340
340
|
var shape_cards_root_window_ = __webpack_require__(686);
|
|
341
|
-
;// CONCATENATED MODULE: ../../shapes/cog/dist/
|
|
341
|
+
;// CONCATENATED MODULE: ../../shapes/cog/dist/browser/CogDrawer.js
|
|
342
342
|
|
|
343
343
|
class CogDrawer {
|
|
344
344
|
afterEffect(ctx, particle, radius) {
|
|
@@ -387,7 +387,7 @@ class CogDrawer {
|
|
|
387
387
|
particle.cogOuterTaper = (0,engine_root_window_.getRangeValue)(shapeData?.outerTaper ?? 50);
|
|
388
388
|
}
|
|
389
389
|
}
|
|
390
|
-
;// CONCATENATED MODULE: ../../shapes/cog/dist/
|
|
390
|
+
;// CONCATENATED MODULE: ../../shapes/cog/dist/browser/index.js
|
|
391
391
|
|
|
392
392
|
async function loadCogShape(engine, refresh = true) {
|
|
393
393
|
await engine.addShape("cog", new CogDrawer(), refresh);
|
|
@@ -408,7 +408,7 @@ var plugin_easing_quart_root_window_ = __webpack_require__(205);
|
|
|
408
408
|
var plugin_easing_quint_root_window_ = __webpack_require__(144);
|
|
409
409
|
// EXTERNAL MODULE: external {"commonjs":"@tsparticles/plugin-easing-sine","commonjs2":"@tsparticles/plugin-easing-sine","amd":"@tsparticles/plugin-easing-sine","root":"window"}
|
|
410
410
|
var plugin_easing_sine_root_window_ = __webpack_require__(691);
|
|
411
|
-
;// CONCATENATED MODULE: ../../plugins/exports/image/dist/
|
|
411
|
+
;// CONCATENATED MODULE: ../../plugins/exports/image/dist/browser/ExportImageInstance.js
|
|
412
412
|
class ExportImageInstance {
|
|
413
413
|
constructor(container, engine) {
|
|
414
414
|
this._exportImage = async data => {
|
|
@@ -442,7 +442,7 @@ class ExportImageInstance {
|
|
|
442
442
|
return res;
|
|
443
443
|
}
|
|
444
444
|
}
|
|
445
|
-
;// CONCATENATED MODULE: ../../plugins/exports/image/dist/
|
|
445
|
+
;// CONCATENATED MODULE: ../../plugins/exports/image/dist/browser/index.js
|
|
446
446
|
|
|
447
447
|
class ExportImagePlugin {
|
|
448
448
|
constructor(engine) {
|
|
@@ -460,7 +460,7 @@ class ExportImagePlugin {
|
|
|
460
460
|
async function loadExportImagePlugin(engine, refresh = true) {
|
|
461
461
|
await engine.addPlugin(new ExportImagePlugin(engine), refresh);
|
|
462
462
|
}
|
|
463
|
-
;// CONCATENATED MODULE: ../../plugins/exports/json/dist/
|
|
463
|
+
;// CONCATENATED MODULE: ../../plugins/exports/json/dist/browser/ExportJSONInstance.js
|
|
464
464
|
class ExportJSONInstance {
|
|
465
465
|
constructor(container, engine) {
|
|
466
466
|
this._exportJSON = async () => {
|
|
@@ -490,7 +490,7 @@ class ExportJSONInstance {
|
|
|
490
490
|
return res;
|
|
491
491
|
}
|
|
492
492
|
}
|
|
493
|
-
;// CONCATENATED MODULE: ../../plugins/exports/json/dist/
|
|
493
|
+
;// CONCATENATED MODULE: ../../plugins/exports/json/dist/browser/index.js
|
|
494
494
|
|
|
495
495
|
class ExportJSONPlugin {
|
|
496
496
|
constructor(engine) {
|
|
@@ -508,7 +508,7 @@ class ExportJSONPlugin {
|
|
|
508
508
|
async function loadExportJSONPlugin(engine, refresh = true) {
|
|
509
509
|
await engine.addPlugin(new ExportJSONPlugin(engine), refresh);
|
|
510
510
|
}
|
|
511
|
-
;// CONCATENATED MODULE: ../../plugins/exports/video/dist/
|
|
511
|
+
;// CONCATENATED MODULE: ../../plugins/exports/video/dist/browser/ExportVideoInstance.js
|
|
512
512
|
const videoTypes = ["webm", "ogg", "mp4", "x-matroska"],
|
|
513
513
|
codecs = ["vp9", "vp9.0", "vp8", "vp8.0", "avc1", "av1", "h265", "h.265", "h264", "h.264", "opus", "pcm", "aac", "mpeg", "mp4a"];
|
|
514
514
|
function getVideoSupportedMimeTypes() {
|
|
@@ -573,7 +573,7 @@ class ExportVideoInstance {
|
|
|
573
573
|
return res;
|
|
574
574
|
}
|
|
575
575
|
}
|
|
576
|
-
;// CONCATENATED MODULE: ../../plugins/exports/video/dist/
|
|
576
|
+
;// CONCATENATED MODULE: ../../plugins/exports/video/dist/browser/index.js
|
|
577
577
|
|
|
578
578
|
class ExportVideoPlugin {
|
|
579
579
|
constructor(engine) {
|
|
@@ -619,7 +619,7 @@ var path_perlin_noise_root_window_ = __webpack_require__(228);
|
|
|
619
619
|
var plugin_polygon_mask_root_window_ = __webpack_require__(124);
|
|
620
620
|
// EXTERNAL MODULE: external {"commonjs":"@tsparticles/path-polygon","commonjs2":"@tsparticles/path-polygon","amd":"@tsparticles/path-polygon","root":"window"}
|
|
621
621
|
var path_polygon_root_window_ = __webpack_require__(231);
|
|
622
|
-
;// CONCATENATED MODULE: ../../shapes/rounded-polygon/dist/
|
|
622
|
+
;// CONCATENATED MODULE: ../../shapes/rounded-polygon/dist/browser/RoundedPolygonDrawer.js
|
|
623
623
|
|
|
624
624
|
function polygon(sides, radius, rot = 0) {
|
|
625
625
|
const step = Math.PI * 2 / sides,
|
|
@@ -656,14 +656,14 @@ class RoundedPolygonDrawer {
|
|
|
656
656
|
particle.borderRadius = Math.round((0,engine_root_window_.getRangeValue)(shapeData?.radius ?? 5)) * container.retina.pixelRatio;
|
|
657
657
|
}
|
|
658
658
|
}
|
|
659
|
-
;// CONCATENATED MODULE: ../../shapes/rounded-polygon/dist/
|
|
659
|
+
;// CONCATENATED MODULE: ../../shapes/rounded-polygon/dist/browser/index.js
|
|
660
660
|
|
|
661
661
|
async function loadRoundedPolygonShape(engine, refresh = true) {
|
|
662
662
|
await engine.addShape("rounded-polygon", new RoundedPolygonDrawer(), refresh);
|
|
663
663
|
}
|
|
664
664
|
// EXTERNAL MODULE: external {"commonjs":"@tsparticles/shape-rounded-rect","commonjs2":"@tsparticles/shape-rounded-rect","amd":"@tsparticles/shape-rounded-rect","root":"window"}
|
|
665
665
|
var shape_rounded_rect_root_window_ = __webpack_require__(550);
|
|
666
|
-
;// CONCATENATED MODULE: ../../paths/svg/dist/
|
|
666
|
+
;// CONCATENATED MODULE: ../../paths/svg/dist/browser/SVGPathGenerator.js
|
|
667
667
|
|
|
668
668
|
class SVGPathGenerator {
|
|
669
669
|
constructor() {
|
|
@@ -815,7 +815,7 @@ class SVGPathGenerator {
|
|
|
815
815
|
reset() {}
|
|
816
816
|
update() {}
|
|
817
817
|
}
|
|
818
|
-
;// CONCATENATED MODULE: ../../paths/svg/dist/
|
|
818
|
+
;// CONCATENATED MODULE: ../../paths/svg/dist/browser/index.js
|
|
819
819
|
|
|
820
820
|
const svgPathName = "svgPathGenerator";
|
|
821
821
|
async function loadSVGPath(engine, refresh = true) {
|
package/tsparticles.all.min.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
1
|
/*! For license information please see tsparticles.all.min.js.LICENSE.txt */
|
|
2
|
-
!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t(require("@tsparticles/shape-bubble"),require("@tsparticles/plugin-canvas-mask"),require("@tsparticles/shape-cards"),require("@tsparticles/path-curves"),require("@tsparticles/plugin-easing-back"),require("@tsparticles/plugin-easing-circ"),require("@tsparticles/plugin-easing-cubic"),require("@tsparticles/plugin-easing-expo"),require("@tsparticles/plugin-easing-quart"),require("@tsparticles/plugin-easing-quint"),require("@tsparticles/plugin-easing-sine"),require("tsparticles"),require("@tsparticles/updater-gradient"),require("@tsparticles/shape-heart"),require("@tsparticles/plugin-hsv-color"),require("@tsparticles/plugin-infection"),require("@tsparticles/interaction-light"),require("@tsparticles/plugin-motion"),require("@tsparticles/shape-multiline-text"),require("@tsparticles/updater-orbit"),require("@tsparticles/interaction-particles-repulse"),require("@tsparticles/shape-path"),require("@tsparticles/path-perlin-noise"),require("@tsparticles/plugin-polygon-mask"),require("@tsparticles/path-polygon"),require("@tsparticles/shape-rounded-rect"),require("@tsparticles/path-simplex-noise"),require("@tsparticles/plugin-sounds"),require("@tsparticles/shape-spiral"),require("@tsparticles/engine"));else if("function"==typeof define&&define.amd)define(["@tsparticles/shape-bubble","@tsparticles/plugin-canvas-mask","@tsparticles/shape-cards","@tsparticles/path-curves","@tsparticles/plugin-easing-back","@tsparticles/plugin-easing-circ","@tsparticles/plugin-easing-cubic","@tsparticles/plugin-easing-expo","@tsparticles/plugin-easing-quart","@tsparticles/plugin-easing-quint","@tsparticles/plugin-easing-sine","tsparticles","@tsparticles/updater-gradient","@tsparticles/shape-heart","@tsparticles/plugin-hsv-color","@tsparticles/plugin-infection","@tsparticles/interaction-light","@tsparticles/plugin-motion","@tsparticles/shape-multiline-text","@tsparticles/updater-orbit","@tsparticles/interaction-particles-repulse","@tsparticles/shape-path","@tsparticles/path-perlin-noise","@tsparticles/plugin-polygon-mask","@tsparticles/path-polygon","@tsparticles/shape-rounded-rect","@tsparticles/path-simplex-noise","@tsparticles/plugin-sounds","@tsparticles/shape-spiral","@tsparticles/engine"],t);else{var i="object"==typeof exports?t(require("@tsparticles/shape-bubble"),require("@tsparticles/plugin-canvas-mask"),require("@tsparticles/shape-cards"),require("@tsparticles/path-curves"),require("@tsparticles/plugin-easing-back"),require("@tsparticles/plugin-easing-circ"),require("@tsparticles/plugin-easing-cubic"),require("@tsparticles/plugin-easing-expo"),require("@tsparticles/plugin-easing-quart"),require("@tsparticles/plugin-easing-quint"),require("@tsparticles/plugin-easing-sine"),require("tsparticles"),require("@tsparticles/updater-gradient"),require("@tsparticles/shape-heart"),require("@tsparticles/plugin-hsv-color"),require("@tsparticles/plugin-infection"),require("@tsparticles/interaction-light"),require("@tsparticles/plugin-motion"),require("@tsparticles/shape-multiline-text"),require("@tsparticles/updater-orbit"),require("@tsparticles/interaction-particles-repulse"),require("@tsparticles/shape-path"),require("@tsparticles/path-perlin-noise"),require("@tsparticles/plugin-polygon-mask"),require("@tsparticles/path-polygon"),require("@tsparticles/shape-rounded-rect"),require("@tsparticles/path-simplex-noise"),require("@tsparticles/plugin-sounds"),require("@tsparticles/shape-spiral"),require("@tsparticles/engine")):t(e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window);for(var s in i)("object"==typeof exports?exports:e)[s]=i[s]}}(this,((e,t,i,s,a,r,n,o,p,l,c,u,h,g,d,w,v,x,f,m,y,P,_,q,b,I,T,S,R,M)=>(()=>{"use strict";var O={533:e=>{e.exports=M},55:e=>{e.exports=v},297:e=>{e.exports=y},997:e=>{e.exports=s},228:e=>{e.exports=_},231:e=>{e.exports=b},520:e=>{e.exports=T},72:e=>{e.exports=t},792:e=>{e.exports=a},176:e=>{e.exports=r},922:e=>{e.exports=n},594:e=>{e.exports=o},205:e=>{e.exports=p},144:e=>{e.exports=l},691:e=>{e.exports=c},673:e=>{e.exports=d},521:e=>{e.exports=w},82:e=>{e.exports=x},124:e=>{e.exports=q},490:e=>{e.exports=S},164:t=>{t.exports=e},686:e=>{e.exports=i},12:e=>{e.exports=g},940:e=>{e.exports=f},901:e=>{e.exports=P},550:e=>{e.exports=I},561:e=>{e.exports=R},887:e=>{e.exports=h},193:e=>{e.exports=m},802:e=>{e.exports=u}},E={};function k(e){var t=E[e];if(void 0!==t)return t.exports;var i=E[e]={exports:{}};return O[e](i,i.exports,k),i.exports}k.d=(e,t)=>{for(var i in t)k.o(t,i)&&!k.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},k.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),k.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var F={};return(()=>{k.r(F),k.d(F,{loadAll:()=>W});var e=k(533);class t{draw(e,t,i){const s=2*i,a=s*(t.heightFactor??.5),r=s*(t.headWidthFactor??.2),n=a*(t.bodyHeightFactor??.5);e.moveTo(-s/2,0),e.lineTo(-s/2,-n/2),e.lineTo(s/2-r,-n/2),e.lineTo(s/2-r,-a/2),e.lineTo(s/2+r,0),e.lineTo(s/2-r,a/2),e.lineTo(s/2-r,n/2),e.lineTo(-s/2,n/2),e.lineTo(-s/2,0)}particleInit(t,i){const s=i.shapeData;i.heightFactor=(0,e.getRangeValue)(s?.heightFactor??.5),i.headWidthFactor=(0,e.getRangeValue)(s?.headWidthFactor??.2),i.bodyHeightFactor=(0,e.getRangeValue)(s?.bodyHeightFactor??.5)}}var i=k(164),s=k(72),a=k(686);class r{afterEffect(e,t,i){if(void 0===t.cogHoleRadius||void 0===t.cogInnerRadius||void 0===t.cogInnerTaper||void 0===t.cogNotches||void 0===t.cogOuterTaper)return;const s=2*Math.PI,a=i*t.cogHoleRadius/100;e.globalCompositeOperation="destination-out",e.beginPath(),e.moveTo(a,0),e.arc(0,0,a,0,s),e.closePath(),e.fill(),e.globalCompositeOperation="source-over"}draw(e,t,i){if(void 0===t.cogHoleRadius||void 0===t.cogInnerRadius||void 0===t.cogInnerTaper||void 0===t.cogNotches||void 0===t.cogOuterTaper)return;const s=2*Math.PI,a=s/(2*t.cogNotches),r=a*t.cogInnerTaper*.005,n=a*t.cogOuterTaper*.005,o=i*t.cogInnerRadius/100;let p=a,l=!1;for(e.moveTo(i*Math.cos(n),i*Math.sin(n));p<=s;p+=a)l?(e.lineTo(o*Math.cos(p-r),o*Math.sin(p-r)),e.lineTo(i*Math.cos(p+n),i*Math.sin(p+n))):(e.lineTo(i*Math.cos(p-n),i*Math.sin(p-n)),e.lineTo(o*Math.cos(p+r),o*Math.sin(p+r))),l=!l}particleInit(t,i){const s=i.shapeData;i.cogHoleRadius=(0,e.getRangeValue)(s?.holeRadius??44),i.cogInnerRadius=(0,e.getRangeValue)(s?.innerRadius??72),i.cogInnerTaper=(0,e.getRangeValue)(s?.innerTaper??35),i.cogNotches=(0,e.getRangeValue)(s?.notches??7),i.cogOuterTaper=(0,e.getRangeValue)(s?.outerTaper??50)}}var n=k(997),o=k(792),p=k(176),l=k(922),c=k(594),u=k(205),h=k(144),g=k(691);class d{constructor(e,t){this._exportImage=async e=>{const t=this._container.canvas.element;if(t)return new Promise((i=>{t.toBlob((e=>{i(e||void 0)}),e.type??"image/png",e.quality)}))},this._container=e,this._engine=t}async export(e,t){const i={supported:!1};if("image"===e)i.supported=!0,i.blob=await this._exportImage(t);return i}}class w{constructor(e){this.id="export-image",this._engine=e}getPlugin(e){return new d(e,this._engine)}loadOptions(){}needsPlugin(){return!0}}class v{constructor(e,t){this._exportJSON=async()=>{const e=JSON.stringify(this._container.actualOptions,((e,t)=>{if(!e.startsWith("_"))return t}),2);return new Blob([e],{type:"application/json"})},this._container=e,this._engine=t}async export(e){const t={supported:!1};if("json"===e)t.supported=!0,t.blob=await this._exportJSON();return t}}class x{constructor(e){this.id="export-json",this._engine=e}getPlugin(e){return new v(e,this._engine)}loadOptions(){}needsPlugin(){return!0}}const f=["webm","ogg","mp4","x-matroska"],m=["vp9","vp9.0","vp8","vp8.0","avc1","av1","h265","h.265","h264","h.264","opus","pcm","aac","mpeg","mp4a"];class y{constructor(e,t){this._supportedTypes=[],this._exportVideo=async e=>{const t=this._container.canvas.element;if(t)return new Promise((i=>{const s=t.captureStream(e.fps??this._container.actualOptions.fpsLimit),a=e.mimeType??this._supportedTypes[0],r=new MediaRecorder(s,{mimeType:a}),n=[];r.addEventListener("dataavailable",(e=>{n.push(e.data)})),r.addEventListener("stop",(()=>{i(new Blob(n,{type:a}))})),r.start(),setTimeout((()=>{r.stop()}),e.duration??5e3)}))},this._container=e,this._engine=t,this._supportedTypes=function(){const e=MediaRecorder.isTypeSupported,t=[];return f.forEach((i=>{const s=`video/${i}`;m.forEach((i=>[`${s};codecs=${i}`,`${s};codecs=${i.toUpperCase()}`].forEach((i=>{e(i)&&t.push(i)})))),e(s)&&t.push(s)})),t}()}async export(e,t){const i={supported:!1};if("video"===e)i.supported=!0,i.blob=await this._exportVideo(t);return i}}class P{constructor(e){this.id="export-video",this._engine=e}getPlugin(e){return new y(e,this._engine)}loadOptions(){}needsPlugin(){return!0}}var _=k(802),q=k(887),b=k(12),I=k(673),T=k(521),S=k(55),R=k(82),M=k(940),O=k(193),E=k(297),N=k(901),V=k(228),j=k(124),C=k(231);class z{draw(e,t,i){!function(e,t,i){let s=t[0],a=t[1];const r=t.length;e.moveTo((s.x+a.x)/2,(s.y+a.y)/2);for(let n=1;n<=r;n++)s=a,a=t[(n+1)%r],e.arcTo(s.x,s.y,(s.x+a.x)/2,(s.y+a.y)/2,i)}(e,function(e,t,i=0){const s=2*Math.PI/e,a=[];for(let r=0;r<e;r++)a.push({x:Math.cos(r*s+i)*t,y:Math.sin(r*s+i)*t});return a}(t.sides,i),t.borderRadius??5)}getSidesCount(t){const i=t.shapeData;return Math.round((0,e.getRangeValue)(i?.sides??5))}particleInit(t,i){const s=i.shapeData;i.borderRadius=Math.round((0,e.getRangeValue)(s?.radius??5))*t.retina.pixelRatio}}var D=k(550);class H{constructor(){this._paths=[],this._reverse=!1,this._size={width:0,height:0},this._scale=1,this._offset={x:0,y:0,mode:"percent"},this._width=0}generate(t,i){const s=t.container.retina.pixelRatio;void 0===t.svgDirection&&(t.svgDirection=(0,e.getRandom)()>.5?0:1),void 0===t.svgPathIndex&&(t.svgPathIndex=Math.floor(Math.random()*this._paths.length)),void 0===t.svgSpeed&&(t.svgSpeed=t.velocity.mult((t.retina.moveSpeed??1)/2).length),void 0===t.svgStep&&(t.svgStep=(0,e.randomInRange)({min:0,max:this._paths[t.svgPathIndex].length})*s),void 0===t.svgOffset&&(t.svgOffset={width:(0,e.randomInRange)({min:-this._width/2,max:this._width/2})*s,height:(0,e.randomInRange)({min:-this._width/2,max:this._width/2})*s}),void 0===t.svgInitialPosition&&(t.svgInitialPosition={...t.position}),t.velocity.x=0,t.velocity.y=0,0===t.svgDirection?t.svgStep+=t.svgSpeed*i.factor:t.svgStep-=t.svgSpeed*i.factor;let a=this._paths[t.svgPathIndex];if(a){const e=a.length;t.svgStep>=e?(t.svgPathIndex=t.svgPathIndex+1,t.svgPathIndex>=this._paths.length&&(this._reverse?(t.svgPathIndex=this._paths.length-1,t.svgDirection=1):(t.svgPathIndex=0,t.svgStep=0))):t.svgStep<=0&&(t.svgPathIndex=t.svgPathIndex-1,t.svgPathIndex<0&&(this._reverse?(t.svgPathIndex=0,t.svgDirection=0):(t.svgPathIndex=this._paths.length-1,a=this._paths[t.svgPathIndex],t.svgStep=a.length))),a=this._paths[t.svgPathIndex]}if(a){const i=a.element.getPointAtLength(t.svgStep),r=t.container.canvas.size,n=(0,e.getPosition)(this._offset,r),o=this._scale*s;t.position.x=(i.x-this._size.width/2)*o+t.svgInitialPosition.x+n.x+t.svgOffset.width,t.position.y=(i.y-this._size.height/2)*o+t.svgInitialPosition.y+n.y+t.svgOffset.height}return e.Vector.origin}init(e){const t=e.actualOptions.particles.move.path.options,i=t.position??this._offset;if(this._reverse=t.reverse??this._reverse,this._scale=t.scale??1,this._offset.x=i.x,this._offset.y=i.y,this._offset.mode=i.mode,this._width=t.width??0,t.url&&!t.path){const e=t.url;(async()=>{const t=await fetch(e),i=await t.text(),s=(new DOMParser).parseFromString(i,"image/svg+xml"),a=s.getElementsByTagName("svg")[0];let r=a.getElementsByTagName("path");r.length||(r=s.getElementsByTagName("path")),this._paths=[];for(let e=0;e<r.length;e++){const t=r.item(e);t&&this._paths.push({element:t,length:t.getTotalLength()})}this._size.height=parseFloat(a.getAttribute("height")??"0"),this._size.width=parseFloat(a.getAttribute("width")??"0")})()}else if(t.path){const e=t.path;this._paths=[];for(const t of e.data){const e=document.createElementNS("http://www.w3.org/2000/svg","path");e.setAttribute("d",t),this._paths.push({element:e,length:e.getTotalLength()})}this._size.height=e.size.height,this._size.width=e.size.width}}reset(){}update(){}}const B="svgPathGenerator";var L=k(520),A=k(490),$=k(561);async function W(e,d=!0){await(0,_.loadFull)(e,!1),await(0,I.loadHsvColorPlugin)(),await(0,o.loadEasingBackPlugin)(),await(0,p.loadEasingCircPlugin)(),await(0,l.loadEasingCubicPlugin)(),await(0,c.loadEasingExpoPlugin)(),await(0,u.loadEasingQuartPlugin)(),await(0,h.loadEasingQuintPlugin)(),await(0,g.loadEasingSinePlugin)(),await(0,I.loadHsvColorPlugin)(),await(0,s.loadCanvasMaskPlugin)(e,!1),await(0,T.loadInfectionPlugin)(e,!1),await(0,R.loadMotionPlugin)(e,!1),await(0,j.loadPolygonMaskPlugin)(e,!1),await(0,A.loadSoundsPlugin)(e,!1),await async function(e,t=!0){await e.addPlugin(new w(e),t)}(e,!1),await async function(e,t=!0){await e.addPlugin(new x(e),t)}(e,!1),await async function(e,t=!0){await e.addPlugin(new P(e),t)}(e,!1),await(0,S.loadLightInteraction)(e,!1),await(0,E.loadParticlesRepulseInteraction)(e,!1),await(0,q.loadGradientUpdater)(e,!1),await(0,O.loadOrbitUpdater)(e,!1),await(0,n.loadCurvesPath)(e,!1),await(0,V.loadPerlinNoisePath)(e,!1),await(0,C.loadPolygonPath)(e,!1),await async function(e,t=!0){await e.addPathGenerator(B,new H,t)}(e,!1),await(0,L.loadSimplexNoisePath)(e,!1),await async function(e,i=!0){await e.addShape("arrow",new t,i)}(e,!1),await(0,i.loadBubbleShape)(e,!1),await(0,a.loadCardsShape)(e,!1),await async function(e,t=!0){await e.addShape("cog",new r,t)}(e,!1),await(0,b.loadHeartShape)(e,!1),await(0,M.loadMultilineTextShape)(e,!1),await(0,N.loadPathShape)(e,!1),await async function(e,t=!0){await e.addShape("rounded-polygon",new z,t)}(e,!1),await(0,D.loadRoundedRectShape)(e,!1),await(0,$.loadSpiralShape)(e,!1),await e.refresh(d)}})(),F})()));
|
|
2
|
+
!function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t(require("@tsparticles/engine"),require("@tsparticles/shape-bubble"),require("@tsparticles/plugin-canvas-mask"),require("@tsparticles/shape-cards"),require("@tsparticles/path-curves"),require("@tsparticles/plugin-easing-back"),require("@tsparticles/plugin-easing-circ"),require("@tsparticles/plugin-easing-cubic"),require("@tsparticles/plugin-easing-expo"),require("@tsparticles/plugin-easing-quart"),require("@tsparticles/plugin-easing-quint"),require("@tsparticles/plugin-easing-sine"),require("tsparticles"),require("@tsparticles/updater-gradient"),require("@tsparticles/shape-heart"),require("@tsparticles/plugin-hsv-color"),require("@tsparticles/plugin-infection"),require("@tsparticles/interaction-light"),require("@tsparticles/plugin-motion"),require("@tsparticles/shape-multiline-text"),require("@tsparticles/updater-orbit"),require("@tsparticles/interaction-particles-repulse"),require("@tsparticles/shape-path"),require("@tsparticles/path-perlin-noise"),require("@tsparticles/plugin-polygon-mask"),require("@tsparticles/path-polygon"),require("@tsparticles/shape-rounded-rect"),require("@tsparticles/path-simplex-noise"),require("@tsparticles/plugin-sounds"),require("@tsparticles/shape-spiral"));else if("function"==typeof define&&define.amd)define(["@tsparticles/engine","@tsparticles/shape-bubble","@tsparticles/plugin-canvas-mask","@tsparticles/shape-cards","@tsparticles/path-curves","@tsparticles/plugin-easing-back","@tsparticles/plugin-easing-circ","@tsparticles/plugin-easing-cubic","@tsparticles/plugin-easing-expo","@tsparticles/plugin-easing-quart","@tsparticles/plugin-easing-quint","@tsparticles/plugin-easing-sine","tsparticles","@tsparticles/updater-gradient","@tsparticles/shape-heart","@tsparticles/plugin-hsv-color","@tsparticles/plugin-infection","@tsparticles/interaction-light","@tsparticles/plugin-motion","@tsparticles/shape-multiline-text","@tsparticles/updater-orbit","@tsparticles/interaction-particles-repulse","@tsparticles/shape-path","@tsparticles/path-perlin-noise","@tsparticles/plugin-polygon-mask","@tsparticles/path-polygon","@tsparticles/shape-rounded-rect","@tsparticles/path-simplex-noise","@tsparticles/plugin-sounds","@tsparticles/shape-spiral"],t);else{var i="object"==typeof exports?t(require("@tsparticles/engine"),require("@tsparticles/shape-bubble"),require("@tsparticles/plugin-canvas-mask"),require("@tsparticles/shape-cards"),require("@tsparticles/path-curves"),require("@tsparticles/plugin-easing-back"),require("@tsparticles/plugin-easing-circ"),require("@tsparticles/plugin-easing-cubic"),require("@tsparticles/plugin-easing-expo"),require("@tsparticles/plugin-easing-quart"),require("@tsparticles/plugin-easing-quint"),require("@tsparticles/plugin-easing-sine"),require("tsparticles"),require("@tsparticles/updater-gradient"),require("@tsparticles/shape-heart"),require("@tsparticles/plugin-hsv-color"),require("@tsparticles/plugin-infection"),require("@tsparticles/interaction-light"),require("@tsparticles/plugin-motion"),require("@tsparticles/shape-multiline-text"),require("@tsparticles/updater-orbit"),require("@tsparticles/interaction-particles-repulse"),require("@tsparticles/shape-path"),require("@tsparticles/path-perlin-noise"),require("@tsparticles/plugin-polygon-mask"),require("@tsparticles/path-polygon"),require("@tsparticles/shape-rounded-rect"),require("@tsparticles/path-simplex-noise"),require("@tsparticles/plugin-sounds"),require("@tsparticles/shape-spiral")):t(e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window,e.window);for(var s in i)("object"==typeof exports?exports:e)[s]=i[s]}}(this,((e,t,i,s,a,r,n,o,p,l,c,u,h,g,d,w,v,x,f,m,y,P,_,q,b,I,T,S,R,M)=>(()=>{"use strict";var O={533:t=>{t.exports=e},55:e=>{e.exports=x},297:e=>{e.exports=P},997:e=>{e.exports=a},228:e=>{e.exports=q},231:e=>{e.exports=I},520:e=>{e.exports=S},72:e=>{e.exports=i},792:e=>{e.exports=r},176:e=>{e.exports=n},922:e=>{e.exports=o},594:e=>{e.exports=p},205:e=>{e.exports=l},144:e=>{e.exports=c},691:e=>{e.exports=u},673:e=>{e.exports=w},521:e=>{e.exports=v},82:e=>{e.exports=f},124:e=>{e.exports=b},490:e=>{e.exports=R},164:e=>{e.exports=t},686:e=>{e.exports=s},12:e=>{e.exports=d},940:e=>{e.exports=m},901:e=>{e.exports=_},550:e=>{e.exports=T},561:e=>{e.exports=M},887:e=>{e.exports=g},193:e=>{e.exports=y},802:e=>{e.exports=h}},E={};function k(e){var t=E[e];if(void 0!==t)return t.exports;var i=E[e]={exports:{}};return O[e](i,i.exports,k),i.exports}k.d=(e,t)=>{for(var i in t)k.o(t,i)&&!k.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},k.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),k.r=e=>{"undefined"!=typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})};var F={};return(()=>{k.r(F),k.d(F,{loadAll:()=>W});var e=k(533);class t{draw(e,t,i){const s=2*i,a=s*(t.heightFactor??.5),r=s*(t.headWidthFactor??.2),n=a*(t.bodyHeightFactor??.5);e.moveTo(-s/2,0),e.lineTo(-s/2,-n/2),e.lineTo(s/2-r,-n/2),e.lineTo(s/2-r,-a/2),e.lineTo(s/2+r,0),e.lineTo(s/2-r,a/2),e.lineTo(s/2-r,n/2),e.lineTo(-s/2,n/2),e.lineTo(-s/2,0)}particleInit(t,i){const s=i.shapeData;i.heightFactor=(0,e.getRangeValue)(s?.heightFactor??.5),i.headWidthFactor=(0,e.getRangeValue)(s?.headWidthFactor??.2),i.bodyHeightFactor=(0,e.getRangeValue)(s?.bodyHeightFactor??.5)}}var i=k(164),s=k(72),a=k(686);class r{afterEffect(e,t,i){if(void 0===t.cogHoleRadius||void 0===t.cogInnerRadius||void 0===t.cogInnerTaper||void 0===t.cogNotches||void 0===t.cogOuterTaper)return;const s=2*Math.PI,a=i*t.cogHoleRadius/100;e.globalCompositeOperation="destination-out",e.beginPath(),e.moveTo(a,0),e.arc(0,0,a,0,s),e.closePath(),e.fill(),e.globalCompositeOperation="source-over"}draw(e,t,i){if(void 0===t.cogHoleRadius||void 0===t.cogInnerRadius||void 0===t.cogInnerTaper||void 0===t.cogNotches||void 0===t.cogOuterTaper)return;const s=2*Math.PI,a=s/(2*t.cogNotches),r=a*t.cogInnerTaper*.005,n=a*t.cogOuterTaper*.005,o=i*t.cogInnerRadius/100;let p=a,l=!1;for(e.moveTo(i*Math.cos(n),i*Math.sin(n));p<=s;p+=a)l?(e.lineTo(o*Math.cos(p-r),o*Math.sin(p-r)),e.lineTo(i*Math.cos(p+n),i*Math.sin(p+n))):(e.lineTo(i*Math.cos(p-n),i*Math.sin(p-n)),e.lineTo(o*Math.cos(p+r),o*Math.sin(p+r))),l=!l}particleInit(t,i){const s=i.shapeData;i.cogHoleRadius=(0,e.getRangeValue)(s?.holeRadius??44),i.cogInnerRadius=(0,e.getRangeValue)(s?.innerRadius??72),i.cogInnerTaper=(0,e.getRangeValue)(s?.innerTaper??35),i.cogNotches=(0,e.getRangeValue)(s?.notches??7),i.cogOuterTaper=(0,e.getRangeValue)(s?.outerTaper??50)}}var n=k(997),o=k(792),p=k(176),l=k(922),c=k(594),u=k(205),h=k(144),g=k(691);class d{constructor(e,t){this._exportImage=async e=>{const t=this._container.canvas.element;if(t)return new Promise((i=>{t.toBlob((e=>{i(e||void 0)}),e.type??"image/png",e.quality)}))},this._container=e,this._engine=t}async export(e,t){const i={supported:!1};if("image"===e)i.supported=!0,i.blob=await this._exportImage(t);return i}}class w{constructor(e){this.id="export-image",this._engine=e}getPlugin(e){return new d(e,this._engine)}loadOptions(){}needsPlugin(){return!0}}class v{constructor(e,t){this._exportJSON=async()=>{const e=JSON.stringify(this._container.actualOptions,((e,t)=>{if(!e.startsWith("_"))return t}),2);return new Blob([e],{type:"application/json"})},this._container=e,this._engine=t}async export(e){const t={supported:!1};if("json"===e)t.supported=!0,t.blob=await this._exportJSON();return t}}class x{constructor(e){this.id="export-json",this._engine=e}getPlugin(e){return new v(e,this._engine)}loadOptions(){}needsPlugin(){return!0}}const f=["webm","ogg","mp4","x-matroska"],m=["vp9","vp9.0","vp8","vp8.0","avc1","av1","h265","h.265","h264","h.264","opus","pcm","aac","mpeg","mp4a"];class y{constructor(e,t){this._supportedTypes=[],this._exportVideo=async e=>{const t=this._container.canvas.element;if(t)return new Promise((i=>{const s=t.captureStream(e.fps??this._container.actualOptions.fpsLimit),a=e.mimeType??this._supportedTypes[0],r=new MediaRecorder(s,{mimeType:a}),n=[];r.addEventListener("dataavailable",(e=>{n.push(e.data)})),r.addEventListener("stop",(()=>{i(new Blob(n,{type:a}))})),r.start(),setTimeout((()=>{r.stop()}),e.duration??5e3)}))},this._container=e,this._engine=t,this._supportedTypes=function(){const e=MediaRecorder.isTypeSupported,t=[];return f.forEach((i=>{const s=`video/${i}`;m.forEach((i=>[`${s};codecs=${i}`,`${s};codecs=${i.toUpperCase()}`].forEach((i=>{e(i)&&t.push(i)})))),e(s)&&t.push(s)})),t}()}async export(e,t){const i={supported:!1};if("video"===e)i.supported=!0,i.blob=await this._exportVideo(t);return i}}class P{constructor(e){this.id="export-video",this._engine=e}getPlugin(e){return new y(e,this._engine)}loadOptions(){}needsPlugin(){return!0}}var _=k(802),q=k(887),b=k(12),I=k(673),T=k(521),S=k(55),R=k(82),M=k(940),O=k(193),E=k(297),N=k(901),V=k(228),j=k(124),C=k(231);class z{draw(e,t,i){!function(e,t,i){let s=t[0],a=t[1];const r=t.length;e.moveTo((s.x+a.x)/2,(s.y+a.y)/2);for(let n=1;n<=r;n++)s=a,a=t[(n+1)%r],e.arcTo(s.x,s.y,(s.x+a.x)/2,(s.y+a.y)/2,i)}(e,function(e,t,i=0){const s=2*Math.PI/e,a=[];for(let r=0;r<e;r++)a.push({x:Math.cos(r*s+i)*t,y:Math.sin(r*s+i)*t});return a}(t.sides,i),t.borderRadius??5)}getSidesCount(t){const i=t.shapeData;return Math.round((0,e.getRangeValue)(i?.sides??5))}particleInit(t,i){const s=i.shapeData;i.borderRadius=Math.round((0,e.getRangeValue)(s?.radius??5))*t.retina.pixelRatio}}var D=k(550);class H{constructor(){this._paths=[],this._reverse=!1,this._size={width:0,height:0},this._scale=1,this._offset={x:0,y:0,mode:"percent"},this._width=0}generate(t,i){const s=t.container.retina.pixelRatio;void 0===t.svgDirection&&(t.svgDirection=(0,e.getRandom)()>.5?0:1),void 0===t.svgPathIndex&&(t.svgPathIndex=Math.floor(Math.random()*this._paths.length)),void 0===t.svgSpeed&&(t.svgSpeed=t.velocity.mult((t.retina.moveSpeed??1)/2).length),void 0===t.svgStep&&(t.svgStep=(0,e.randomInRange)({min:0,max:this._paths[t.svgPathIndex].length})*s),void 0===t.svgOffset&&(t.svgOffset={width:(0,e.randomInRange)({min:-this._width/2,max:this._width/2})*s,height:(0,e.randomInRange)({min:-this._width/2,max:this._width/2})*s}),void 0===t.svgInitialPosition&&(t.svgInitialPosition={...t.position}),t.velocity.x=0,t.velocity.y=0,0===t.svgDirection?t.svgStep+=t.svgSpeed*i.factor:t.svgStep-=t.svgSpeed*i.factor;let a=this._paths[t.svgPathIndex];if(a){const e=a.length;t.svgStep>=e?(t.svgPathIndex=t.svgPathIndex+1,t.svgPathIndex>=this._paths.length&&(this._reverse?(t.svgPathIndex=this._paths.length-1,t.svgDirection=1):(t.svgPathIndex=0,t.svgStep=0))):t.svgStep<=0&&(t.svgPathIndex=t.svgPathIndex-1,t.svgPathIndex<0&&(this._reverse?(t.svgPathIndex=0,t.svgDirection=0):(t.svgPathIndex=this._paths.length-1,a=this._paths[t.svgPathIndex],t.svgStep=a.length))),a=this._paths[t.svgPathIndex]}if(a){const i=a.element.getPointAtLength(t.svgStep),r=t.container.canvas.size,n=(0,e.getPosition)(this._offset,r),o=this._scale*s;t.position.x=(i.x-this._size.width/2)*o+t.svgInitialPosition.x+n.x+t.svgOffset.width,t.position.y=(i.y-this._size.height/2)*o+t.svgInitialPosition.y+n.y+t.svgOffset.height}return e.Vector.origin}init(e){const t=e.actualOptions.particles.move.path.options,i=t.position??this._offset;if(this._reverse=t.reverse??this._reverse,this._scale=t.scale??1,this._offset.x=i.x,this._offset.y=i.y,this._offset.mode=i.mode,this._width=t.width??0,t.url&&!t.path){const e=t.url;(async()=>{const t=await fetch(e),i=await t.text(),s=(new DOMParser).parseFromString(i,"image/svg+xml"),a=s.getElementsByTagName("svg")[0];let r=a.getElementsByTagName("path");r.length||(r=s.getElementsByTagName("path")),this._paths=[];for(let e=0;e<r.length;e++){const t=r.item(e);t&&this._paths.push({element:t,length:t.getTotalLength()})}this._size.height=parseFloat(a.getAttribute("height")??"0"),this._size.width=parseFloat(a.getAttribute("width")??"0")})()}else if(t.path){const e=t.path;this._paths=[];for(const t of e.data){const e=document.createElementNS("http://www.w3.org/2000/svg","path");e.setAttribute("d",t),this._paths.push({element:e,length:e.getTotalLength()})}this._size.height=e.size.height,this._size.width=e.size.width}}reset(){}update(){}}const B="svgPathGenerator";var L=k(520),A=k(490),$=k(561);async function W(e,d=!0){await(0,_.loadFull)(e,!1),await(0,I.loadHsvColorPlugin)(),await(0,o.loadEasingBackPlugin)(),await(0,p.loadEasingCircPlugin)(),await(0,l.loadEasingCubicPlugin)(),await(0,c.loadEasingExpoPlugin)(),await(0,u.loadEasingQuartPlugin)(),await(0,h.loadEasingQuintPlugin)(),await(0,g.loadEasingSinePlugin)(),await(0,I.loadHsvColorPlugin)(),await(0,s.loadCanvasMaskPlugin)(e,!1),await(0,T.loadInfectionPlugin)(e,!1),await(0,R.loadMotionPlugin)(e,!1),await(0,j.loadPolygonMaskPlugin)(e,!1),await(0,A.loadSoundsPlugin)(e,!1),await async function(e,t=!0){await e.addPlugin(new w(e),t)}(e,!1),await async function(e,t=!0){await e.addPlugin(new x(e),t)}(e,!1),await async function(e,t=!0){await e.addPlugin(new P(e),t)}(e,!1),await(0,S.loadLightInteraction)(e,!1),await(0,E.loadParticlesRepulseInteraction)(e,!1),await(0,q.loadGradientUpdater)(e,!1),await(0,O.loadOrbitUpdater)(e,!1),await(0,n.loadCurvesPath)(e,!1),await(0,V.loadPerlinNoisePath)(e,!1),await(0,C.loadPolygonPath)(e,!1),await async function(e,t=!0){await e.addPathGenerator(B,new H,t)}(e,!1),await(0,L.loadSimplexNoisePath)(e,!1),await async function(e,i=!0){await e.addShape("arrow",new t,i)}(e,!1),await(0,i.loadBubbleShape)(e,!1),await(0,a.loadCardsShape)(e,!1),await async function(e,t=!0){await e.addShape("cog",new r,t)}(e,!1),await(0,b.loadHeartShape)(e,!1),await(0,M.loadMultilineTextShape)(e,!1),await(0,N.loadPathShape)(e,!1),await async function(e,t=!0){await e.addShape("rounded-polygon",new z,t)}(e,!1),await(0,D.loadRoundedRectShape)(e,!1),await(0,$.loadSpiralShape)(e,!1),await e.refresh(d)}})(),F})()));
|
|
@@ -1 +1 @@
|
|
|
1
|
-
/*! tsParticles All v3.0.0-beta.
|
|
1
|
+
/*! tsParticles All v3.0.0-beta.2 by Matteo Bruni */
|