@tsparticles/preset-triangles 4.4.0 → 4.5.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(t){t.__tsParticlesInternals=t.__tsParticlesInternals||{},t.__tsParticlesInternals.bundles=t.__tsParticlesInternals.bundles||{},t.__tsParticlesInternals.effects=t.__tsParticlesInternals.effects||{},t.__tsParticlesInternals.engine=t.__tsParticlesInternals.engine||{},t.__tsParticlesInternals.interactions=t.__tsParticlesInternals.interactions||{},t.__tsParticlesInternals.palettes=t.__tsParticlesInternals.palettes||{},t.__tsParticlesInternals.paths=t.__tsParticlesInternals.paths||{},t.__tsParticlesInternals.plugins=t.__tsParticlesInternals.plugins||{},t.__tsParticlesInternals.plugins=t.__tsParticlesInternals.plugins||{},t.__tsParticlesInternals.plugins.emittersShapes=t.__tsParticlesInternals.plugins.emittersShapes||{},t.__tsParticlesInternals.presets=t.__tsParticlesInternals.presets||{},t.__tsParticlesInternals.shapes=t.__tsParticlesInternals.shapes||{},t.__tsParticlesInternals.updaters=t.__tsParticlesInternals.updaters||{},t.__tsParticlesInternals.utils=t.__tsParticlesInternals.utils||{},t.__tsParticlesInternals.canvas=t.__tsParticlesInternals.canvas||{},t.__tsParticlesInternals.canvas=t.__tsParticlesInternals.canvas||{},t.__tsParticlesInternals.canvas.utils=t.__tsParticlesInternals.canvas.utils||{},t.__tsParticlesInternals.path=t.__tsParticlesInternals.path||{},t.__tsParticlesInternals.path=t.__tsParticlesInternals.path||{},t.__tsParticlesInternals.path.utils=t.__tsParticlesInternals.path.utils||{};var e="undefined"!=typeof Proxy?function(t){return new Proxy(t,{get:function(t,e){return e in t||(t[e]={}),t[e]}})}:function(t){return t};t.__tsParticlesInternals.bundles=e(t.__tsParticlesInternals.bundles),t.__tsParticlesInternals.effects=e(t.__tsParticlesInternals.effects),t.__tsParticlesInternals.interactions=e(t.__tsParticlesInternals.interactions),t.__tsParticlesInternals.palettes=e(t.__tsParticlesInternals.palettes),t.__tsParticlesInternals.paths=e(t.__tsParticlesInternals.paths),t.__tsParticlesInternals.plugins=e(t.__tsParticlesInternals.plugins),t.__tsParticlesInternals.plugins.emittersShapes=e(t.__tsParticlesInternals.plugins.emittersShapes),t.__tsParticlesInternals.presets=e(t.__tsParticlesInternals.presets),t.__tsParticlesInternals.shapes=e(t.__tsParticlesInternals.shapes),t.__tsParticlesInternals.updaters=e(t.__tsParticlesInternals.updaters),t.__tsParticlesInternals.utils=e(t.__tsParticlesInternals.utils),t.__tsParticlesInternals.canvas=e(t.__tsParticlesInternals.canvas),t.__tsParticlesInternals.path=e(t.__tsParticlesInternals.path),t.tsparticlesInternalExports=t.tsparticlesInternalExports||{}}("undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:this),function(t,e){"object"==typeof exports&&"undefined"!=typeof module?e(exports):"function"==typeof define&&define.amd?define(["exports"],e):e(((t="undefined"!=typeof globalThis?globalThis:t||self).__tsParticlesInternals=t.__tsParticlesInternals||{},t.__tsParticlesInternals.presets=t.__tsParticlesInternals.presets||{},t.__tsParticlesInternals.presets.triangles=t.__tsParticlesInternals.presets.triangles||{}))}(this,function(t){"use strict";const e="generated",i="source-over",s="visibilitychange",n=100,a=.5,o=1e3,r={x:0,y:0,z:0},c=1,l=0,h=0,d=1,u="random",p="mid",f=2*Math.PI,g="true",y="false",m="canvas",v=255,w=360,b=100,P=100,x=.25,M=400;var k;function C(t){return"z"in t?t.z:r.z}!function(t){t.bottom="bottom",t.bottomLeft="bottom-left",t.bottomRight="bottom-right",t.left="left",t.none="none",t.right="right",t.top="top",t.topLeft="top-left",t.topRight="top-right",t.outside="outside",t.inside="inside"}(k||(k={}));class z{x;y;z;constructor(t=r.x,e=r.y,i=r.z){this.x=t,this.y=e,this.z=i}static get origin(){return z.create(r.x,r.y,r.z)}get angle(){return Math.atan2(this.y,this.x)}set angle(t){this.#t(t,this.length)}get length(){return Math.sqrt(this.getLengthSq())}set length(t){this.#t(this.angle,t)}static clone(t){return z.create(t.x,t.y,C(t))}static create(t,e,i){return"number"==typeof t?new z(t,e??r.y,i??r.z):new z(t.x,t.y,C(t))}add(t){return z.create(this.x+t.x,this.y+t.y,this.z+C(t))}addTo(t){this.x+=t.x,this.y+=t.y,this.z+=C(t)}copy(){return z.clone(this)}div(t){return z.create(this.x/t,this.y/t,this.z/t)}getLengthSq(){return this.x**2+this.y**2}mult(t){return z.create(this.x*t,this.y*t,this.z*t)}multTo(t){this.x*=t,this.y*=t,this.z*=t}normalize(){const t=this.length;0!=t&&this.multTo(1/t)}rotate(t){return z.create(this.x*Math.cos(t)-this.y*Math.sin(t),this.x*Math.sin(t)+this.y*Math.cos(t),r.z)}setTo(t){this.x=t.x,this.y=t.y,this.z=C(t)}sub(t){return z.create(this.x-t.x,this.y-t.y,this.z-C(t))}subFrom(t){this.x-=t.x,this.y-=t.y,this.z-=C(t)}#t(t,e){this.x=Math.cos(t)*e,this.y=Math.sin(t)*e}}class I extends z{constructor(t=r.x,e=r.y){super(t,e,r.z)}static get origin(){return I.create(r.x,r.y)}static clone(t){return I.create(t.x,t.y)}static create(t,e){return"number"==typeof t?new I(t,e??r.y):new I(t.x,t.y)}}function S(t){return"boolean"==typeof t}function O(t){return"string"==typeof t}function D(t){return"number"==typeof t}function L(t){return"object"==typeof t&&null!==t}function _(t){return Array.isArray(t)}function E(t){return null==t}const T=Math.PI/180;let R=Math.random;const B=t=>requestAnimationFrame(t),F=t=>{cancelAnimationFrame(t)};function A(){return H(R(),0,1-Number.EPSILON)}function U(t,e){return A()*(e-t)+t}function H(t,e,i){return Math.min(Math.max(t,e),i)}function $(t,e,i,s){return Math.floor((t*i+e*s)/(i+s))}function V(t){const e=N(t);let i=W(t);return e===i&&(i=0),U(i,e)}function q(t){return D(t)?t:V(t)}function W(t){return D(t)?t:t.min}function N(t){return D(t)?t:t.max}function j(t,e){if(t===e||void 0===e&&D(t))return t;const i=W(t),s=N(t);return void 0!==e?{min:Math.min(i,e),max:Math.max(s,e)}:j(i,s)}function G(t,e){const i=t.x-e.x,s=t.y-e.y;return{dx:i,dy:s,distance:Math.hypot(i,s)}}function X(t,e){const i=t.x-e.x,s=t.y-e.y;return i*i+s*s}function Y(t){return t*T}function Q(t){const{position:e,size:i}=t;return{x:e?.x??A()*i.width,y:e?.y??A()*i.height}}function K(t){return t?t.endsWith("%")?parseFloat(t)/n:parseFloat(t):1}var Z,J;!function(t){t.bottom="bottom",t.left="left",t.right="right",t.top="top"}(Z||(Z={})),function(t){t.precise="precise",t.percent="percent"}(J||(J={}));function tt(t){return"__proto__"===t||"constructor"===t||"prototype"===t}function et(){return globalThis.document}function it(t){if("undefined"!=typeof matchMedia)return matchMedia(t)}function st(t,e,i=!0){return t[void 0!==e&&i?e%t.length:Math.floor(A()*t.length)]}function nt(t,e,i,s,n){return function(t,e,i,s){let n=!0;s&&s!==Z.bottom||(n=t.top<e.height+i.x);!n||s&&s!==Z.left||(n=t.right>i.x);!n||s&&s!==Z.right||(n=t.left<e.width+i.y);!n||s&&s!==Z.top||(n=t.bottom>i.y);return n}(at(t,s??0),e,i,n)}function at(t,e){return{bottom:t.y+e,left:t.x-e,right:t.x+e,top:t.y-e}}function ot(t,...e){for(const i of e){if(E(i))continue;if(!L(i)){t=i;continue}Array.isArray(i)?Array.isArray(t)||(t=[]):L(t)&&!Array.isArray(t)||(t=Object.create(null));const e=Object.keys(i);if(!e.some(t=>{const e=i[t];return L(e)||Array.isArray(e)})){const s=i,n=t;for(const t of e){if(tt(t))continue;const e=s[t];void 0!==e&&(n[t]=e)}continue}for(const s of e){if(tt(s))continue;const e=t,n=i[s];e[s]=Array.isArray(n)?n.map(t=>ot(void 0,t)):ot(e[s],n)}}return t}function rt(t,e){return _(t)?t.map((t,i)=>e(t,i)):e(t,0)}function ct(t,e,i){return _(t)?st(t,e,i):t}function lt(t,e){return function(t,e){if(t.mode!==J.percent){const{mode:e,...i}=t;return i}return"x"in t?{x:t.x/n*e.width,y:t.y/n*e.height}:{width:t.width/n*e.width,height:t.height/n*e.height}}(t,e)}let ht,dt;function ut(t,e,i,s,n){if(s){let s={passive:!0};S(n)?s.capture=n:void 0!==n&&(s=n),t.addEventListener(e,i,s)}else{const s=n;t.removeEventListener(e,i,s)}}async function pt(t,e,i,s=!1){let n=e.get(t);return n&&!s||(n=await Promise.all([...i.values()].map(e=>e(t))),e.set(t,n)),n}async function ft(t,e,i,s=!1){let n=e.get(t);if(!n||s){const s=await Promise.all([...i.entries()].map(([e,i])=>i(t).then(t=>[e,t])));n=new Map(s),e.set(t,n)}return n}class gt{#e;constructor(){this.#e=new Map}addEventListener(t,e){this.removeEventListener(t,e);let i=this.#e.get(t);i||(i=[],this.#e.set(t,i)),i.push(e)}dispatchEvent(t,e){const i=this.#e.get(t);i?.forEach(t=>{t(e)})}hasEventListener(t){return!!this.#e.get(t)}removeAllEventListeners(t){t?this.#e.delete(t):this.#e=new Map}removeEventListener(t,e){const i=this.#e.get(t);if(!i)return;const s=i.length,n=i.indexOf(e);n<0||(1===s?this.#e.delete(t):i.splice(n,1))}}var yt;!function(t){t.configAdded="configAdded",t.containerInit="containerInit",t.particlesSetup="particlesSetup",t.containerStarted="containerStarted",t.containerStopped="containerStopped",t.containerDestroyed="containerDestroyed",t.containerPaused="containerPaused",t.containerPlay="containerPlay",t.containerBuilt="containerBuilt",t.particleAdded="particleAdded",t.particleDestroyed="particleDestroyed",t.particleRemoved="particleRemoved"}(yt||(yt={}));class mt{colorManagers=new Map;easingFunctions=new Map;effectDrawers=new Map;initializers={effects:new Map,shapes:new Map,updaters:new Map};palettes=new Map;plugins=[];presets=new Map;shapeDrawers=new Map;updaters=new Map;#i=new Set;#s=new Map;#n;#a=new Set;#o=!1;#r=!1;#c=new Set;constructor(t){this.#n=t}get configs(){const t={};for(const[e,i]of this.#s)t[e]=i;return t}addColorManager(t,e){this.colorManagers.set(t,e)}addConfig(t){const e=t.key??t.name??"default";this.#s.set(e,t),this.#n.dispatchEvent(yt.configAdded,{data:{name:e,config:t}})}addEasing(t,e){this.easingFunctions.get(t)||this.easingFunctions.set(t,e)}addEffect(t,e){this.initializers.effects.set(t,e)}addPalette(t,e){this.palettes.set(t,e)}addParticleUpdater(t,e){this.initializers.updaters.set(t,e)}addPlugin(t){this.getPlugin(t.id)||this.plugins.push(t)}addPreset(t,e,i=!1){!i&&this.getPreset(t)||this.presets.set(t,e)}addShape(t,e){for(const i of t)this.initializers.shapes.set(i,e)}clearPlugins(t){this.effectDrawers.delete(t),this.shapeDrawers.delete(t),this.updaters.delete(t)}getEasing(t){return this.easingFunctions.get(t)??(t=>t)}getEffectDrawers(t,e=!1){return ft(t,this.effectDrawers,this.initializers.effects,e)}getPalette(t){return this.palettes.get(t)}getPlugin(t){return this.plugins.find(e=>e.id===t)}getPreset(t){return this.presets.get(t)}async getShapeDrawers(t,e=!1){return ft(t,this.shapeDrawers,this.initializers.shapes,e)}async getUpdaters(t,e=!1){return pt(t,this.updaters,this.initializers.updaters,e)}async init(){if(!this.#o&&!this.#r){this.#r=!0,this.#a=new Set,this.#i=new Set(this.#c);try{for(const t of this.#i)await this.#l(t,this.#a,this.#i)}finally{this.#c.clear(),this.#r=!1,this.#o=!0}}}loadParticlesOptions(t,e,...i){const s=this.updaters.get(t);s&&s.forEach(t=>t.loadOptions?.(e,...i))}async register(...t){if(this.#o)throw new Error("Register plugins can only be done before calling tsParticles.load()");for(const e of t)this.#r?await this.#l(e,this.#a,this.#i):this.#c.add(e)}async#l(t,e,i){e.has(t)||(e.add(t),i.add(t),await t(this.#n))}}const vt=t=>(...e)=>{t(...e)},wt={debug:vt(console.debug),error:(t,...e)=>{console.error(`tsParticles - Error - ${t}`,...e)},info:vt(console.info),log:vt(console.log),trace:vt(console.trace),verbose:vt(console.log),warning:vt(console.warn)};function bt(){return wt}const Pt="100%";class xt{pluginManager=new mt(this);#h=[];#d=new gt;#o=!1;get items(){return this.#h}get version(){return"4.4.0"}addEventListener(t,e){this.#d.addEventListener(t,e)}checkVersion(t){if(this.version!==t)throw new Error(`The tsParticles version is different from the loaded plugins version. Engine version: ${this.version}. Plugin version: ${t}`)}dispatchEvent(t,e){this.#d.dispatchEvent(t,e)}async init(){this.#o||(await this.pluginManager.init(),this.#o=!0)}item(t){const e=this.items,i=e[t];if(!i?.destroyed)return i;e.splice(t,1)}async load(t){let i;await this.init(),"undefined"!=typeof HTMLElement&&t.element instanceof HTMLElement&&(i=t.element);const{Container:s}=await Promise.resolve().then(function(){return Ss}),n=t.id??i?.id??`tsparticles${Math.floor(1e4*A()).toString()}`,{index:a,url:o}=t,r=o?await async function(t){const e=ct(t.url,t.index);if(!e)return t.fallback;const i=await fetch(e);return i.ok?await i.json():(bt().error(`${i.status.toString()} while retrieving config file`),t.fallback)}({fallback:t.options,url:o,index:a}):t.options,c=ct(r,a),{items:l}=this,h=l.findIndex(t=>t.id.description===n),d=new s({dispatchCallback:(t,e)=>{this.dispatchEvent(t,e)},id:n,onDestroy:t=>{if(!t)return;const e=this.items,i=e.indexOf(d);i>=0&&e.splice(i,1)},pluginManager:this.pluginManager,sourceOptions:c});if(h>=0){const t=this.item(h),e=t?1:0;t&&!t.destroyed&&t.destroy(!1),l.splice(h,e,d)}else l.push(d);const u="undefined"!=typeof OffscreenCanvas&&t.element instanceof OffscreenCanvas?t.element:(t=>{const i=et();let s;if(t instanceof HTMLCanvasElement||t.tagName.toLowerCase()===m)s=t,s.dataset[e]??=y,s.dataset[e]===g&&(s.style.width||=Pt,s.style.height||=Pt,s.style.pointerEvents="none",s.style.setProperty("pointer-events","none"));else{const n=t.getElementsByTagName(m).item(0);n?(s=n,s.dataset[e]=y):(s=i.createElement(m),s.dataset[e]=g,t.appendChild(s)),s.style.width||=Pt,s.style.height||=Pt,s.style.pointerEvents="none",s.style.setProperty("pointer-events","none")}return s})(((t,i)=>{const s=et();let n=i??s.getElementById(t);return n||(n=s.createElement("canvas"),n.id=t,n.dataset[e]=g,s.body.append(n),n)})(n,i));return d.canvas.loadCanvas(u),await d.start(),d}async refresh(t=!0){t&&await Promise.all(this.items.map(t=>t.refresh()))}removeEventListener(t,e){this.#d.removeEventListener(t,e)}}var Mt,kt,Ct,zt,It,St,Ot,Dt,Lt,_t,Et,Tt,Rt;!function(t){t.circle="circle",t.rectangle="rectangle"}(Mt||(Mt={}));class Bt{position;type;constructor(t,e,i){this.position={x:t,y:e},this.type=i}_resetPosition(t,e){this.position.x=t,this.position.y=e}}class Ft extends Bt{radius;constructor(t,e,i){super(t,e,Mt.circle),this.radius=i}contains(t){return e=t,i=this.position,s=this.radius,X(e,i)<=s*s;var e,i,s}intersects(t){const e=this.position,i=t.position,s=this.radius,n=Math.abs(i.x-e.x),a=Math.abs(i.y-e.y);if(t instanceof Ft||t.type===Mt.circle){return s+t.radius>Math.hypot(n,a)}if(t instanceof At||t.type===Mt.rectangle){const e=t,{width:i,height:o}=e.size;return Math.pow(n-i,2)+Math.pow(a-o,2)<=s**2||n<=s+i&&a<=s+o||n<=i||a<=o}return!1}reset(t,e,i){return this._resetPosition(t,e),this.radius=i,this}}class At extends Bt{size;constructor(t,e,i,s){super(t,e,Mt.rectangle),this.size={height:s,width:i}}contains(t){const e=this.size.width,i=this.size.height,s=this.position;return t.x>=s.x&&t.x<=s.x+e&&t.y>=s.y&&t.y<=s.y+i}intersects(t){if(t instanceof Ft)return t.intersects(this);if(!(t instanceof At))return!1;const e=this.size.width,i=this.size.height,s=this.position,n=t.position,a=t.size,o=a.width,r=a.height;return n.x<s.x+e&&n.x+o>s.x&&n.y<s.y+i&&n.y+r>s.y}reset(t,e,i,s){return this._resetPosition(t,e),this.size.width=i,this.size.height=s,this}}!function(t){t.clockwise="clockwise",t.counterClockwise="counter-clockwise",t.random="random"}(kt||(kt={})),function(t){t.auto="auto",t.increase="increase",t.decrease="decrease",t.random="random"}(Ct||(Ct={})),function(t){t.standard="standard",t.natural="natural",t.vivid="vivid",t.cinematic="cinematic",t.dynamic="dynamic"}(zt||(zt={})),function(t){t.delete="delete",t.wait="wait"}(It||(It={})),function(t){t.bounce="bounce",t.none="none",t.out="out",t.destroy="destroy",t.split="split"}(St||(St={})),function(t){t.darken="darken",t.enlighten="enlighten"}(Ot||(Ot={})),function(t){t.none="none",t.max="max",t.min="min"}(Dt||(Dt={})),function(t){t.linear="linear",t.radial="radial",t.random="random"}(Lt||(Lt={})),function(t){t.normal="normal",t.inside="inside",t.outside="outside"}(_t||(_t={})),function(t){t.max="max",t.min="min",t.random="random"}(Et||(Et={})),function(t){t.increasing="increasing",t.decreasing="decreasing"}(Tt||(Tt={})),function(t){t[t.BackgroundElement=0]="BackgroundElement",t[t.BackgroundDraw=1]="BackgroundDraw",t[t.BackgroundMask=2]="BackgroundMask",t[t.CanvasSetup=3]="CanvasSetup",t[t.PluginContent=4]="PluginContent",t[t.Particles=5]="Particles",t[t.CanvasCleanup=6]="CanvasCleanup",t[t.Foreground=7]="Foreground"}(Rt||(Rt={}));class Ut{load(t){E(t)||this.doLoad(t)}}function Ht(t,...e){for(const i of e)t.load(i)}function $t(t,e,i){void 0!==i&&(t[e]=i)}function Vt(t,e,i){void 0!==i&&(t[e]=j(i))}function qt(t,e,i,s){if(void 0!==i){const n=t;n[e]??=s(),n[e].load(i)}}function Wt(t,e,i,...s){const n=t;n[e]??=new i;const a=n[e];for(const t of s)a.load(t?.[e])}class Nt extends Ut{count=0;decay=0;delay=0;enable=!1;speed=1;sync=!1;doLoad(t){Vt(this,"count",t.count),$t(this,"enable",t.enable),Vt(this,"speed",t.speed),Vt(this,"decay",t.decay),Vt(this,"delay",t.delay),$t(this,"sync",t.sync)}}class jt extends Nt{mode=Ct.auto;startValue=Et.random;doLoad(t){super.doLoad(t),$t(this,"mode",t.mode),$t(this,"startValue",t.startValue)}}class Gt extends Nt{max;min;offset=0;sync=!0;constructor(t,e){super(),this.min=t,this.max=e}doLoad(t){super.doLoad(t),$t(this,"max",t.max),$t(this,"min",t.min),Vt(this,"offset",t.offset)}}class Xt extends Ut{h=new Gt(0,w);l=new Gt(0,P);s=new Gt(0,b);doLoad(t){this.h.load(t.h),this.s.load(t.s),this.l.load(t.l)}}class Yt extends Ut{value="";static create(t,e){const i=new Yt;return i.load(t),void 0!==e&&(O(e)||_(e)?i.load({value:e}):i.load(e)),i}doLoad(t){E(t.value)||(this.value=t.value)}}class Qt extends Yt{animation=new Xt;static create(t,e){const i=new Qt;return i.load(t),void 0!==e&&(O(e)||_(e)?i.load({value:e}):i.load(e)),i}doLoad(t){super.doLoad(t);const e=t.animation;void 0!==e&&(void 0===e.enable?this.animation.load(t.animation):this.animation.h.load(e))}}class Kt extends Ut{color;draw;element;image="";opacity=1;position="";repeat="";size="";constructor(){super(),this.color=new Yt,this.color.value=""}doLoad(t){void 0!==t.color&&(this.color=Yt.create(this.color,t.color)),$t(this,"element",t.element),$t(this,"draw",t.draw),$t(this,"image",t.image),$t(this,"position",t.position),$t(this,"repeat",t.repeat),$t(this,"size",t.size),$t(this,"opacity",t.opacity)}}class Zt extends Ut{enable=!0;zIndex=0;doLoad(t){$t(this,"enable",t.enable),$t(this,"zIndex",t.zIndex)}}class Jt extends Ut{enable=!0;mode=zt.standard;peakNits=400;doLoad(t){if(void 0!==t.enable&&!S(t.enable))throw new Error(`Invalid HDR "enable" value: expected a boolean, got "${String(t.enable)}"`);if(void 0!==t.mode&&("string"!=typeof t.mode||!Object.values(zt).includes(t.mode)))throw new Error(`Invalid HDR "mode" value: expected one of ${Object.values(zt).join(", ")}, got "${e=t.mode,String(e)}"`);var e;if(void 0!==t.peakNits&&(!D(t.peakNits)||!Number.isFinite(t.peakNits)||t.peakNits<=0))throw new Error(`Invalid HDR "peakNits" value: expected a positive number, got "${String(t.peakNits)}"`);$t(this,"enable",t.enable),$t(this,"mode",t.mode),$t(this,"peakNits",t.peakNits)}}class te extends Ut{delay=.5;enable=!0;doLoad(t){$t(this,"delay",t.delay),$t(this,"enable",t.enable)}}class ee extends Ut{close=!0;options={};type=[];doLoad(t){const e=t.options;if(void 0!==e)for(const t in e){const i=e[t];i&&(this.options[t]=ot(this.options[t]??{},i))}$t(this,"close",t.close),$t(this,"type",t.type)}}class ie extends Ut{color;enable=!0;opacity=1;doLoad(t){void 0!==t.color&&(this.color=Qt.create(this.color,t.color)),$t(this,"enable",t.enable),Vt(this,"opacity",t.opacity)}}class se extends Ut{offset=0;value=90;doLoad(t){Vt(this,"offset",t.offset),Vt(this,"value",t.value)}}class ne extends Ut{mode=J.percent;radius=0;x=50;y=50;doLoad(t){$t(this,"x",t.x),$t(this,"y",t.y),$t(this,"mode",t.mode),$t(this,"radius",t.radius)}}class ae extends Ut{acceleration=9.81;enable=!1;inverse=!1;maxSpeed=50;doLoad(t){Vt(this,"acceleration",t.acceleration),$t(this,"enable",t.enable),$t(this,"inverse",t.inverse),Vt(this,"maxSpeed",t.maxSpeed)}}class oe extends Ut{value=0;doLoad(t){E(t.value)||(this.value=j(t.value))}}class re extends oe{animation=new Nt;doLoad(t){var e,i,s;super.doLoad(t),e=this,i="animation",void 0!==(s=t.animation)&&e[i].load(s)}}class ce extends re{animation=new jt}class le extends Ut{clamp=!0;delay=new oe;enable=!1;generator;options={};doLoad(t){$t(this,"clamp",t.clamp),this.delay.load(t.delay),$t(this,"enable",t.enable),this.generator=t.generator,t.options&&(this.options=ot(this.options,t.options))}}class he extends Ut{bottom;default=St.out;left;right;top;doLoad(t){void 0!==t.default&&(this.default=t.default),this.bottom=t.bottom??t.default,this.left=t.left??t.default,this.right=t.right??t.default,this.top=t.top??t.default}}class de extends Ut{acceleration=0;enable=!1;position;doLoad(t){Vt(this,"acceleration",t.acceleration),$t(this,"enable",t.enable),t.position&&(this.position=ot({},t.position))}}class ue extends Ut{angle=new se;center=new ne;decay=0;direction=k.none;distance={};drift=0;enable=!1;gravity=new ae;outModes=new he;path=new le;random=!1;size=!1;speed=2;spin=new de;straight=!1;vibrate=!1;warp=!1;doLoad(t){this.angle.load(D(t.angle)?{value:t.angle}:t.angle),this.center.load(t.center),Vt(this,"decay",t.decay),$t(this,"direction",t.direction),void 0!==t.distance&&(this.distance=D(t.distance)?{horizontal:t.distance,vertical:t.distance}:{...t.distance}),Vt(this,"drift",t.drift),$t(this,"enable",t.enable),this.gravity.load(t.gravity);const e=t.outModes;void 0!==e&&(L(e)?this.outModes.load(e):this.outModes.load({default:e})),this.path.load(t.path),$t(this,"random",t.random),$t(this,"size",t.size),Vt(this,"speed",t.speed),this.spin.load(t.spin),$t(this,"straight",t.straight),$t(this,"vibrate",t.vibrate),$t(this,"warp",t.warp)}}class pe extends Ut{color;opacity;width=0;doLoad(t){void 0!==t.color&&(this.color=Qt.create(this.color,t.color)),Vt(this,"width",t.width),Vt(this,"opacity",t.opacity)}}class fe extends Ut{color;fill;stroke;doLoad(t){void 0!==t.color&&(this.color=Qt.create(this.color,t.color)),qt(this,"fill",t.fill,()=>new ie),qt(this,"stroke",t.stroke,()=>new pe)}}class ge extends oe{value=1}class ye extends Ut{horizontal=new ge;vertical=new ge;doLoad(t){this.horizontal.load(t.horizontal),this.vertical.load(t.vertical)}}class me extends Ut{enable=!1;height=1080;width=1920;doLoad(t){$t(this,"enable",t.enable),$t(this,"width",t.width),$t(this,"height",t.height)}}class ve extends Ut{mode=It.delete;value=0;doLoad(t){$t(this,"mode",t.mode),$t(this,"value",t.value)}}class we extends Ut{density=new me;limit=new ve;value=0;doLoad(t){this.density.load(t.density),this.limit.load(t.limit),$t(this,"value",t.value)}}class be extends Ut{close=!0;options={};type="circle";doLoad(t){const e=t.options;if(void 0!==e)for(const t in e){const i=e[t];i&&(this.options[t]=ot(this.options[t]??{},i))}$t(this,"close",t.close),$t(this,"type",t.type)}}class Pe extends oe{opacityRate=1;sizeRate=1;velocityRate=1;doLoad(t){super.doLoad(t),$t(this,"opacityRate",t.opacityRate),$t(this,"sizeRate",t.sizeRate),$t(this,"velocityRate",t.velocityRate)}}class xe extends Ut{bounce=new ye;effect=new ee;groups={};move=new ue;number=new we;paint;palette;reduceDuplicates=!1;shape=new be;zIndex=new Pe;#u;#p;constructor(t,e){super(),this.#p=t,this.#u=e,this.paint=new fe,this.paint.color=new Qt,this.paint.color.value="#fff",this.paint.fill=new ie,this.paint.fill.enable=!0}doLoad(t){if(t.palette&&(this.palette=t.palette,this.#f(this.palette)),void 0!==t.groups)for(const e of Object.keys(t.groups)){if(!(e in t.groups))continue;const i=t.groups[e];void 0!==i&&(this.groups[e]=ot(this.groups[e]??{},i))}void 0!==t.reduceDuplicates&&(this.reduceDuplicates=t.reduceDuplicates),this.bounce.load(t.bounce),this.effect.load(t.effect),this.move.load(t.move),this.number.load(t.number);const e=t.paint;if(e&&(_(e)?this.paint=rt(e,t=>{const e=new fe;return e.load(t),e}):_(this.paint)?(this.paint=new fe,this.paint.load(e)):this.paint.load(e)),this.shape.load(t.shape),this.zIndex.load(t.zIndex),this.#u){for(const e of this.#p.plugins)e.loadParticlesOptions&&e.loadParticlesOptions(this.#u,this,t);const e=this.#p.updaters.get(this.#u);if(e)for(const i of e)i.loadOptions&&i.loadOptions(this,t)}}#f(t){const e=this.#p.getPalette(t);if(!e)return;const i=e.colors,s=(_(i)?i:[i]).flatMap(t=>{const e=t.fill,i=t.stroke,s=e?{color:{value:e.value},enable:e.enable,opacity:e.opacity}:void 0;return i?[{fill:s,stroke:{color:{value:i.value},opacity:i.opacity,width:i.width||0}}]:[{fill:s}]}),n=s.length>1?s:s[0]??{};this.load({paint:n,blend:{enable:!0,mode:e.blendMode}})}}function Me(t,e,...i){const s=new xe(t,e);return Ht(s,...i),s}class ke extends Ut{autoPlay=!0;background;clear=!0;defaultThemes={};delay=0;detectRetina=!0;duration=0;fpsLimit=120;fullScreen;hdr;key;name;palette;particles;pauseOnBlur=!0;pauseOnOutsideViewport=!0;preset;resize;smooth=!1;style={};zLayers=100;#u;#p;constructor(t,e){super(),this.#p=t,this.#u=e,this.background=new Kt,this.fullScreen=new Zt,this.hdr=new Jt,this.particles=Me(this.#p,this.#u),this.resize=new te}doLoad(t){void 0!==t.preset&&(this.preset=t.preset,rt(this.preset,t=>{this.#g(t)})),void 0!==t.palette&&(this.palette=t.palette,this.#f(this.palette)),$t(this,"autoPlay",t.autoPlay),$t(this,"clear",t.clear),$t(this,"key",t.key),$t(this,"name",t.name),Vt(this,"delay",t.delay),$t(this,"detectRetina",t.detectRetina),Vt(this,"duration",t.duration),$t(this,"fpsLimit",t.fpsLimit);const e=t.hdr;S(e)?(this.hdr.enable=e,this.hdr.mode=zt.standard,this.hdr.peakNits=400):this.hdr.load(e),$t(this,"pauseOnBlur",t.pauseOnBlur),$t(this,"pauseOnOutsideViewport",t.pauseOnOutsideViewport),$t(this,"zLayers",t.zLayers),this.background.load(t.background);const i=t.fullScreen;S(i)?this.fullScreen.enable=i:this.fullScreen.load(i),this.particles.load(t.particles),this.resize.load(t.resize),this.style=ot(this.style,t.style),$t(this,"smooth",t.smooth),this.#p.plugins.forEach(e=>{e.loadOptions(this.#u,this,t)})}#f(t){const e=this.#p.getPalette(t);e&&this.load({background:{color:e.background},blend:{enable:!0,mode:e.blendMode},particles:{palette:t}})}#g(t){this.load(this.#p.getPreset(t))}}const Ce=new Map,ze=1.15,Ie=1.05,Se=.2126,Oe=.7152,De=.0722;function Le(t,e){let i=Ce.get(t);return i||(i=e(),Ce.size>2e3&&Ce.clear(),Ce.set(t,i)),i}function _e(t){return H(t*(2.51*t+.03)/(t*(2.43*t+.59)+.14),0,1)}function Ee(t){return t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function Te(t){return t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055}function Re(t,e,i,s=!0){if(!e)return;const n=O(e)?{value:e}:e;if(O(n.value))return Be(t,n.value,i,s);if(_(n.value)){const e=st(n.value,i,s);if(!e)return;return Re(t,{value:e})}for(const e of t.colorManagers.values()){const t=e.handleRangeColor(n);if(t)return t}}function Be(t,e,i,s=!0){if(!e)return;const n=O(e)?{value:e}:e;if(O(n.value))return n.value===u?$e():function(t,e){return function(t,e){if(e)for(const i of t.colorManagers.values())if(i.accepts(e))return i.parseString(e)}(t,e)}(t,n.value);if(_(n.value)){const e=st(n.value,i,s);if(!e)return;return Be(t,{value:e})}for(const e of t.colorManagers.values()){const t=e.handleColor(n);if(t)return t}}function Fe(t,e,i,s=!0){const n=Re(t,e,i,s);return n?function(t){const e=t.r/v,i=t.g/v,s=t.b/v,n=Math.max(e,i,s),o=Math.min(e,i,s),r={h:0,l:(n+o)*a,s:0};n!==o&&(r.s=r.l<a?(n-o)/(n+o):(n-o)/(2-n-o),r.h=e===n?(i-s)/(n-o):i===n?2+(s-e)/(n-o):4+(e-i)/(n-o));r.l*=P,r.s*=b,r.h*=60,r.h<0&&(r.h+=w);r.h>=w&&(r.h-=w);return r}(n):void 0}function Ae(t,e,i){if(i<0&&i++,i>1&&i--,6*i<1)return t+6*(e-t)*i;if(2*i<1)return e;if(3*i<2){return t+(e-t)*(2/3-i)*6}return t}function Ue(t){const e=(t.h%w+w)%w,i=Math.max(0,Math.min(b,t.s)),s=Math.max(0,Math.min(P,t.l)),n=e/w,o=i/b,r=s/P;if(0===i){const t=Math.round(r*v);return{r:t,g:t,b:t}}const c=r<a?r*(1+o):r+o-r*o,l=2*r-c,h=1/3,d=Math.min(v,v*Ae(l,c,n+h)),u=Math.min(v,v*Ae(l,c,n)),p=Math.min(v,v*Ae(l,c,n-h));return{r:Math.round(d),g:Math.round(u),b:Math.round(p)}}function He(t){const e=(t.h%w+w)%w,i=Math.max(0,Math.min(b,t.s)),s=Math.max(0,Math.min(P,t.l)),n=e/w,o=i/b,r=s/P;if(0===i){const t=r*v;return{r:t,g:t,b:t}}const c=r<a?r*(1+o):r+o-r*o,l=2*r-c,h=1/3;return{r:Math.min(v,v*Ae(l,c,n+h)),g:Math.min(v,v*Ae(l,c,n)),b:Math.min(v,v*Ae(l,c,n-h))}}function $e(t,e){const i=()=>Math.floor(U(0,256));return{b:i(),g:i(),r:i()}}function Ve(t,e,i,s,n){const a=e?4:2,o=i??1;return Le(e?`rgb-${t.r.toFixed(a)}-${t.g.toFixed(a)}-${t.b.toFixed(a)}-hdr-${o.toString()}-${(s??400).toString()}-${n??zt.standard}`:`rgb-${t.r.toFixed(a)}-${t.g.toFixed(a)}-${t.b.toFixed(a)}-sdr-${o.toString()}`,()=>e?function(t,e,i=400,s=zt.standard){const n=i/203,a=function(t,e,i,s){const n=t.r/v,a=t.g/v,o=t.b/v;if(s!==zt.natural&&s!==zt.vivid&&s!==zt.cinematic&&s!==zt.dynamic)return{b:o,g:a,r:n};const r=Math.max(1,e),c=Se*n+Oe*a+De*o,l=function(t,e,i){if(t<=i)return _e(t);const s=t+(t-i)*(e-1);return _e(s)}(c,e,i),h=c>0?l/c:1;return function(t,e,i,s,n){switch(s){case zt.vivid:{const s=(t+e+i)/3;return{b:H(H(s+(i-s)*ze,0,n)*Ie,0,n),g:H(H(s+(e-s)*ze,0,n)*Ie,0,n),r:H(H(s+(t-s)*ze,0,n)*Ie,0,n)}}case zt.cinematic:{const s=1.05*t,a=.95*i,o=(s+e+a)/3;return{b:H(o+1.1*(a-o),0,n),g:H(o+1.1*(e-o),0,n),r:H(o+1.1*(s-o),0,n)}}case zt.dynamic:{const s=Se*t+Oe*e+De*i,a=Math.min(1,2*s),o=1-a,r=(t+e+i)/3,c=H(r+(t-r)*ze,0,n)*Ie,l=H(r+(e-r)*ze,0,n)*Ie,h=H(r+(i-r)*ze,0,n)*Ie;return{b:H(i*o+h*a,0,n),g:H(e*o+l*a,0,n),r:H(t*o+c*a,0,n)}}case zt.standard:case zt.natural:default:return{b:i,g:e,r:t}}}(H(n*h,0,r),H(a*h,0,r),H(o*h,0,r),s,r)}(t,n,.18,s);return`color(display-p3 ${a.r.toString()} ${a.g.toString()} ${a.b.toString()} / ${(e??1).toString()})`}(t,i,s,n):function(t,e){return`rgba(${t.r.toString()}, ${t.g.toString()}, ${t.b.toString()}, ${(e??1).toString()})`}(t,i))}function qe(t,e,i,s,n){const a=e?4:2,o=i??1;return Le(e?`hsl-${t.h.toFixed(a)}-${t.s.toFixed(a)}-${t.l.toFixed(a)}-hdr-${o.toString()}-${(s??M).toString()}-${n??zt.standard}`:`hsl-${t.h.toFixed(a)}-${t.s.toFixed(a)}-${t.l.toFixed(a)}-sdr-${o.toString()}`,()=>e?Ve(He(t),!0,i,s,n):`hsla(${t.h.toString()}, ${t.s.toString()}%, ${t.l.toString()}%, ${o.toString()})`)}function We(t,e,i,s){if(i===u)return $e();if(i!==p)return i;{const i=t.getFillColor()??t.getStrokeColor(),n=e?.getFillColor()??e?.getStrokeColor();if(i&&n&&e)return function(t,e,i,s,n){let a=t,o=e;if("r"in a||(a=n?He(t):Ue(t)),"r"in o||(o=n?He(e):Ue(e)),n){const t={b:Ee(a.b/v),g:Ee(a.g/v),r:Ee(a.r/v)},e={b:Ee(o.b/v),g:Ee(o.g/v),r:Ee(o.r/v)},n=i+s;return{b:Te((t.b*i+e.b*s)/n)*v,g:Te((t.g*i+e.g*s)/n)*v,r:Te((t.r*i+e.r*s)/n)*v}}return{b:$(a.b,o.b,i,s),g:$(a.g,o.g,i,s),r:$(a.r,o.r,i,s)}}(i,n,t.getRadius(),e.getRadius(),s);{const t=i??n;if(t)return Ue(t)}}}function Ne(t){return void 0===t?void 0:{h:t.h.value,s:t.s.value,l:t.l.value}}function je(t,e,i){const s={h:{enable:!1,value:t.h,min:0,max:w},s:{enable:!1,value:t.s,min:0,max:b},l:{enable:!1,value:t.l,min:0,max:P}};return e&&(Ge(s.h,e.h,i),Ge(s.s,e.s,i),Ge(s.l,e.l,i)),s}function Ge(t,e,i){t.enable=e.enable,t.min=e.min,t.max=e.max,t.enable?(t.velocity=q(e.speed)/n*i,t.decay=1-q(e.decay),t.status=Tt.increasing,t.loops=0,t.maxLoops=q(e.count),t.time=0,t.delayTime=q(e.delay)*o,e.sync||(t.velocity*=A(),t.value*=A()),t.initialValue=t.value,t.offset=j(e.offset)):t.velocity=0}function Xe(t,e,i,s){if(!t.enable||(t.maxLoops??0)>0&&(t.loops??0)>(t.maxLoops??0))return;if(t.time??=0,(t.delayTime??0)>0&&t.time<(t.delayTime??0)&&(t.time+=i.value),(t.delayTime??0)>0&&t.time<(t.delayTime??0))return;const n=t.offset?V(t.offset):0,a=(t.velocity??0)*i.factor+3.6*n,o=t.decay??1,r=t.max,c=t.min;e&&t.status!==Tt.increasing?(t.value-=a,t.value<c&&(t.loops??=0,t.loops++,t.status=Tt.increasing)):(t.value+=a,t.value>r&&(t.loops??=0,t.loops++,e?t.status=Tt.decreasing:t.value-=r)),t.velocity&&1!==o&&(t.velocity*=o),t.value=H(t.value,c,r)}function Ye(t,e,i){if(!t)return;const{h:s,s:n,l:a}=t;Xe(s,!1,e),Xe(n,!0,e),Xe(a,!0,e)}const Qe=function(){const t=globalThis.tsParticles;return t?.pluginManager?t:new xt}();class Ke{enable=!1;mode="destination-out";load(t){E(t)||($t(this,"mode",t.mode),$t(this,"enable",t.enable))}}class Ze{id="blend";async getPlugin(t){const{BlendPluginInstance:e}=await Promise.resolve().then(function(){return Os});return new e(t)}loadOptions(t,e,i){if(!this.needsPlugin(e)&&!this.needsPlugin(i))return;let s=e.blend;s?.load||(e.blend=s=new Ke),s.load(i?.blend)}loadParticlesOptions(t,e,i){e.blend??=new Ke,e.blend.load(i?.blend)}needsPlugin(t){return!!t?.blend?.enable||!!t?.particles?.blend?.enable}}async function Je(t){t.checkVersion("4.4.0"),await t.pluginManager.register(t=>{t.pluginManager.addPlugin(new Ze)})}class ti{draw(t){!function(t){const{context:e,particle:i,radius:s}=t;i.circleRange??={min:0,max:f};const n=i.circleRange;e.arc(r.x,r.y,s,n.min,n.max,!1)}(t)}getSidesCount(){return 12}particleInit(t,e){const i=e.shapeData,s=i?.angle??{max:360,min:0};e.circleRange=L(s)?{min:Y(s.min),max:Y(s.max)}:{min:0,max:Y(s)}}}async function ei(t){t.checkVersion("4.4.0"),await t.pluginManager.register(t=>{t.pluginManager.addShape(["circle"],()=>Promise.resolve(new ti))})}var ii;!function(t){t[t.r=1]="r",t[t.g=2]="g",t[t.b=3]="b",t[t.a=4]="a"}(ii||(ii={}));const si=/^#?([a-f\d])([a-f\d])([a-f\d])([a-f\d])?$/i,ni=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})?$/i;class ai{accepts(t){return t.startsWith("#")}handleColor(t){return this.#y(t.value)}handleRangeColor(t){return this.#y(t.value)}parseString(t){return this.#y(t)}#y(t){if("string"!=typeof t||!this.accepts(t))return;const e=t.replace(si,(t,e,i,s,n)=>e+e+i+i+s+s+(void 0===n?"":n+n)),i=ni.exec(e);return i?{a:i[ii.a]?Number.parseInt(i[ii.a],16)/255:1,b:Number.parseInt(i[ii.b]??"0",16),g:Number.parseInt(i[ii.g]??"0",16),r:Number.parseInt(i[ii.r]??"0",16)}:void 0}}async function oi(t){t.checkVersion("4.4.0"),await t.pluginManager.register(t=>{t.pluginManager.addColorManager("hex",new ai)})}var ri;!function(t){t[t.h=1]="h",t[t.s=2]="s",t[t.l=3]="l",t[t.a=5]="a"}(ri||(ri={}));const ci=/hsla?\(\s*(\d+)\s*[\s,]\s*(\d+)%\s*[\s,]\s*(\d+)%\s*([\s,]\s*(0|1|0?\.\d+|(\d{1,3})%)\s*)?\)/i;class li{accepts(t){return t.startsWith("hsl")}handleColor(t){const e=t.value.hsl??t.value;if("h"in e&&"s"in e&&"l"in e)return Ue(e)}handleRangeColor(t){const e=t.value.hsl??t.value;if("h"in e&&"s"in e&&"l"in e)return Ue({h:q(e.h),l:q(e.l),s:q(e.s)})}parseString(t){if(!this.accepts(t))return;const e=ci.exec(t);return e?function(t){const e=Ue(t);return{a:t.a,b:e.b,g:e.g,r:e.r}}({a:e.length>4?K(e[ri.a]):1,h:Number.parseInt(e[ri.h]??"0",10),l:Number.parseInt(e[ri.l]??"0",10),s:Number.parseInt(e[ri.s]??"0",10)}):void 0}}async function hi(t){t.checkVersion("4.4.0"),await t.pluginManager.register(t=>{t.pluginManager.addColorManager("hsl",new li)})}class di{id="move";#p;constructor(t){this.#p=t}async getPlugin(t){const{MovePluginInstance:e}=await Promise.resolve().then(function(){return _s});return new e(this.#p,t)}loadOptions(){}needsPlugin(){return!0}}async function ui(t){t.checkVersion("4.4.0"),await t.pluginManager.register(t=>{const e=t.pluginManager;e.initializers.pathGenerators??=new Map,e.pathGenerators??=new Map,e.addPathGenerator=(t,i)=>{e.initializers.pathGenerators??=new Map,e.initializers.pathGenerators.set(t,i)},e.getPathGenerators=async(t,i=!1)=>(e.initializers.pathGenerators??=new Map,e.pathGenerators??=new Map,ft(t,e.pathGenerators,e.initializers.pathGenerators,i)),t.pluginManager.addPlugin(new di(t.pluginManager))})}function pi(t,e){const i=t.value,s=t.animation,n={delayTime:q(s.delay)*o,enable:s.enable,value:q(t.value)*e,max:N(i)*e,min:W(i)*e,loops:0,maxLoops:q(s.count),time:0};if(s.enable){switch(n.decay=1-q(s.decay),s.mode){case Ct.increase:n.status=Tt.increasing;break;case Ct.decrease:n.status=Tt.decreasing;break;case Ct.random:n.status=A()>=a?Tt.increasing:Tt.decreasing}const t=s.mode===Ct.auto;switch(s.startValue){case Et.min:n.value=n.min,t&&(n.status=Tt.increasing);break;case Et.max:n.value=n.max,t&&(n.status=Tt.decreasing);break;case Et.random:default:n.value=V(n),t&&(n.status=A()>=a?Tt.increasing:Tt.decreasing)}}return n.initialValue=n.value,n}function fi(t,e,i,s,n){if(t.destroyed||!e.enable||(e.maxLoops??0)>0&&(e.loops??0)>(e.maxLoops??0))return;const a=(e.velocity??0)*n.factor,o=e.min,r=e.max,c=e.decay??1;e.time??=0;const l=e.delayTime??0;if(!(l>0&&e.time<l&&(e.time+=n.value,e.time<l))){switch(e.status){case Tt.increasing:e.value+=a;break;case Tt.decreasing:e.value-=a}switch(e.velocity&&1!==c&&(e.velocity*=c),e.status){case Tt.increasing:e.value>=r&&(e.status=Tt.decreasing,e.loops??=0,e.loops++);break;case Tt.decreasing:e.value<=o&&(e.status=Tt.increasing,e.loops??=0,e.loops++)}!function(t,e,i,s,n){switch(e){case Dt.max:i>=n&&t.destroy();break;case Dt.min:i<=s&&t.destroy()}}(t,s,e.value,o,r),t.destroyed||(e.value=H(e.value,o,r))}}class gi extends jt{destroy=Dt.none;load(t){super.load(t),E(t)||$t(this,"destroy",t.destroy)}}class yi extends ce{animation=new gi;value=1;load(t){if(E(t))return;super.load(t);const e=t.animation;void 0!==e&&this.animation.load(e)}}class mi{#u;constructor(t){this.#u=t}init(t){const e=t.options.opacity;if(!e)return;t.opacity=pi(e,1);const i=e.animation;i.enable&&(t.opacity.velocity=q(i.speed)/n*this.#u.retina.reduceFactor,i.sync||(t.opacity.velocity*=A()))}isEnabled(t){return!t.destroyed&&!t.spawning&&!!t.opacity&&t.opacity.enable&&((t.opacity.maxLoops??0)<=0||(t.opacity.maxLoops??0)>0&&(t.opacity.loops??0)<(t.opacity.maxLoops??0))}loadOptions(t,...e){Wt(t,"opacity",yi,...e)}reset(t){t.opacity&&(t.opacity.time=0,t.opacity.loops=0)}update(t,e){this.isEnabled(t)&&t.opacity&&t.options.opacity&&fi(t,t.opacity,0,t.options.opacity.animation.destroy,e)}}async function vi(t){t.checkVersion("4.4.0"),await t.pluginManager.register(t=>{t.pluginManager.addParticleUpdater("opacity",t=>Promise.resolve(new mi(t)))})}class wi{modes;#u;#m;constructor(t){this.#u=t,this.modes=[St.bounce,St.split],this.#m=t.plugins.filter(t=>void 0!==t.particleBounce)}update(t,e,i,s){if(!this.modes.includes(s))return;const n=this.#u;let a=!1;for(const s of this.#m)if(a=s.particleBounce?.(t,i,e)??!1,a)break;if(a)return;const o=t.getPosition(),r=t.offset,c=t.getRadius(),l=at(o,c),h=n.canvas.size,d=!t.isInsideCanvasForOutMode(s,e);!function(t){if(t.outMode!==St.bounce&&t.outMode!==St.split||t.direction!==Z.left&&t.direction!==Z.right)return;t.bounds.right<0&&t.direction===Z.left?t.particle.position.x=t.size+t.offset.x:t.bounds.left>t.canvasSize.width&&t.direction===Z.right&&(t.particle.position.x=t.canvasSize.width-t.size-t.offset.x);const e=t.particle.velocity.x;let i=!1;if(t.outOfCanvas&&(t.direction===Z.right&&e>0||t.direction===Z.left&&e<0)){const e=q(t.particle.options.bounce.horizontal.value);t.particle.velocity.x*=-e,i=!0}if(!i)return;const s=t.offset.x+t.size;t.outOfCanvas&&t.direction===Z.right?t.particle.position.x=t.canvasSize.width-s:t.outOfCanvas&&t.direction===Z.left&&(t.particle.position.x=s),t.outMode===St.split&&t.particle.destroy()}({particle:t,outMode:s,direction:e,bounds:l,canvasSize:h,offset:r,outOfCanvas:d,size:c}),function(t){if(t.outMode!==St.bounce&&t.outMode!==St.split||t.direction!==Z.bottom&&t.direction!==Z.top)return;t.bounds.bottom<0&&t.direction===Z.top?t.particle.position.y=t.size+t.offset.y:t.bounds.top>t.canvasSize.height&&t.direction===Z.bottom&&(t.particle.position.y=t.canvasSize.height-t.size-t.offset.y);const e=t.particle.velocity.y;let i=!1;if(t.outOfCanvas&&(t.direction===Z.bottom&&e>0||t.direction===Z.top&&e<0)){const e=q(t.particle.options.bounce.vertical.value);t.particle.velocity.y*=-e,i=!0}if(!i)return;const s=t.offset.y+t.size;t.outOfCanvas&&t.direction===Z.bottom?t.particle.position.y=t.canvasSize.height-s:t.outOfCanvas&&t.direction===Z.top&&(t.particle.position.y=s),t.outMode===St.split&&t.particle.destroy()}({particle:t,outMode:s,direction:e,bounds:l,canvasSize:h,offset:r,outOfCanvas:d,size:c})}}class bi{modes;constructor(t){this.modes=[St.destroy]}update(t,e,i,s){if(this.modes.includes(s)){switch(t.outType){case _t.normal:case _t.outside:if(t.isInsideCanvasForOutMode(s,e))return;break;case _t.inside:{const{dx:e,dy:i}=G(t.position,t.moveCenter),{x:s,y:n}=t.velocity;if(s<0&&e>t.moveCenter.radius||n<0&&i>t.moveCenter.radius||s>=0&&e<-t.moveCenter.radius||n>=0&&i<-t.moveCenter.radius)return;break}}t.destroy(!0)}}}class Pi{modes;#u;constructor(t){this.#u=t,this.modes=[St.none]}update(t,e,i,s){if(!this.modes.includes(s))return;if((t.options.move.distance.horizontal&&(e===Z.left||e===Z.right))??(t.options.move.distance.vertical&&(e===Z.top||e===Z.bottom)))return;const n=t.options.move.gravity,a=this.#u,o=a.canvas.size,c=t.getRadius();if(n.enable){const i=t.position;(!n.inverse&&i.y>o.height+c&&e===Z.bottom||n.inverse&&i.y<-c&&e===Z.top)&&t.destroy()}else{if(t.velocity.y>0&&t.position.y<=o.height+c||t.velocity.y<0&&t.position.y>=-c||t.velocity.x>0&&t.position.x<=o.width+c||t.velocity.x<0&&t.position.x>=-c)return;nt(t.position,a.canvas.size,r,c,e)||t.destroy()}}}const xi=I.origin;class Mi{modes;#u;constructor(t){this.#u=t,this.modes=[St.out]}update(t,e,i,s){if(!this.modes.includes(s))return;const n=this.#u;switch(t.outType){case _t.inside:{const{x:e,y:i}=t.velocity;xi.setTo(r),xi.length=t.moveCenter.radius,xi.angle=t.velocity.angle+Math.PI,xi.addTo(t.moveCenter);const{dx:s,dy:a}=G(t.position,xi);if(e<=0&&s>=0||i<=0&&a>=0||e>=0&&s<=0||i>=0&&a<=0)return;t.position.x=Math.floor(V({min:0,max:n.canvas.size.width})),t.position.y=Math.floor(V({min:0,max:n.canvas.size.height}));const{dx:o,dy:c}=G(t.position,t.moveCenter);t.direction=Math.atan2(-c,-o),t.velocity.angle=t.direction,t.justWarped=!0;break}default:if(t.isInsideCanvasForOutMode(s,e))return;switch(t.outType){case _t.outside:{t.position.x=Math.floor(V({min:-t.moveCenter.radius,max:t.moveCenter.radius}))+t.moveCenter.x,t.position.y=Math.floor(V({min:-t.moveCenter.radius,max:t.moveCenter.radius}))+t.moveCenter.y;const{dx:e,dy:i}=G(t.position,t.moveCenter);t.moveCenter.radius&&(t.direction=Math.atan2(i,e),t.velocity.angle=t.direction),t.justWarped=!0;break}case _t.normal:{const i=t.options.move.warp,s=n.canvas.size,a={bottom:s.height+t.getRadius()+t.offset.y,left:-t.getRadius()-t.offset.x,right:s.width+t.getRadius()+t.offset.x,top:-t.getRadius()-t.offset.y},o=t.getRadius(),r=at(t.position,o);e===Z.right&&r.left>s.width+t.offset.x?(t.position.x=a.left,t.initialPosition.x=t.position.x,i||(t.position.y=A()*s.height,t.initialPosition.y=t.position.y),t.justWarped=!0):e===Z.left&&r.right<-t.offset.x&&(t.position.x=a.right,t.initialPosition.x=t.position.x,i||(t.position.y=A()*s.height,t.initialPosition.y=t.position.y),t.justWarped=!0),e===Z.bottom&&r.top>s.height+t.offset.y?(i||(t.position.x=A()*s.width,t.initialPosition.x=t.position.x),t.position.y=a.top,t.initialPosition.y=t.position.y,t.justWarped=!0):e===Z.top&&r.bottom<-t.offset.y&&(i||(t.position.x=A()*s.width,t.initialPosition.x=t.position.x),t.position.y=a.bottom,t.initialPosition.y=t.position.y,t.justWarped=!0);break}}}}}class ki{updaters;#u;constructor(t){this.#u=t,this.updaters=new Map}init(t){this.#v(t,St.bounce,t=>new wi(t)),this.#v(t,St.out,t=>new Mi(t)),this.#v(t,St.destroy,t=>new bi(t)),this.#v(t,St.none,t=>new Pi(t))}isEnabled(t){return!t.destroyed&&!t.spawning}update(t,e){const i=t.options.move.outModes;t.justWarped=!1,this.#w(t,e,i.bottom??i.default,Z.bottom),this.#w(t,e,i.left??i.default,Z.left),this.#w(t,e,i.right??i.default,Z.right),this.#w(t,e,i.top??i.default,Z.top)}#v(t,e,i){const s=t.options.move.outModes;!this.updaters.has(e)&&((t,e)=>t.default===e||t.bottom===e||t.left===e||t.right===e||t.top===e)(s,e)&&this.updaters.set(e,i(this.#u))}#w(t,e,i,s){for(const n of this.updaters.values())n.update(t,s,e,i)}}async function Ci(t){t.checkVersion("4.4.0"),await t.pluginManager.register(t=>{t.pluginManager.addParticleUpdater("outModes",t=>Promise.resolve(new ki(t)))})}class zi{#u;#p;constructor(t,e){this.#u=e,this.#p=t}init(t){const e=this.#u,i=t.options,s=ct(i.paint,t.id,i.reduceDuplicates),n=s?.color,a=n??void 0,o=s?.fill,r=s?.stroke;if(o){const i=Qt.create(void 0===a?void 0:Qt.create(void 0,a),o.color);t.fillEnabled=o.enable,t.fillOpacity=q(o.opacity),t.fillAnimation=i.animation;const s=Fe(this.#p,i);s&&(t.fillColor=je(s,t.fillAnimation,e.retina.reduceFactor))}else t.fillEnabled=!1,t.fillAnimation=void 0,t.fillColor=void 0,t.fillOpacity=1;if(r){const i=Qt.create(void 0===a?void 0:Qt.create(void 0,a),r.color);t.strokeWidth=q(r.width)*e.retina.pixelRatio,t.strokeOpacity=q(r.opacity??1),t.strokeAnimation=i.animation;const s=Fe(this.#p,i)??t.getFillColor();s&&(t.strokeColor=je(s,t.strokeAnimation,e.retina.reduceFactor))}else t.strokeAnimation=void 0,t.strokeColor=void 0,t.strokeOpacity=1,t.strokeWidth=0}isEnabled(t){const{fillAnimation:e,fillColor:i,strokeAnimation:s,strokeColor:n}=t,a=!!e&&(void 0!==i?.h.value&&i.h.enable||void 0!==i?.s.value&&i.s.enable||void 0!==i?.l.value&&i.l.enable),o=!!s&&(void 0!==n?.h.value&&n.h.enable||void 0!==n?.s.value&&n.s.enable||void 0!==n?.l.value&&n.l.enable);return!t.destroyed&&!t.spawning&&(a||o)}update(t,e){this.isEnabled(t)&&(Ye(t.fillColor,e,this.#u.hdr),Ye(t.strokeColor,e,this.#u.hdr))}}async function Ii(t){t.checkVersion("4.4.0"),await t.pluginManager.register(t=>{t.pluginManager.addParticleUpdater("paint",e=>Promise.resolve(new zi(t.pluginManager,e)))})}var Si;!function(t){t[t.r=1]="r",t[t.g=2]="g",t[t.b=3]="b",t[t.a=5]="a"}(Si||(Si={}));const Oi=/rgba?\(\s*(\d{1,3})\s*[\s,]\s*(\d{1,3})\s*[\s,]\s*(\d{1,3})\s*([\s,]\s*(0|1|0?\.\d+|(\d{1,3})%)\s*)?\)/i;class Di{accepts(t){return t.startsWith("rgb")}handleColor(t){const e=t.value.rgb??t.value;if("r"in e&&"g"in e&&"b"in e)return e}handleRangeColor(t){const e=t.value.rgb??t.value;if("r"in e&&"g"in e&&"b"in e)return{r:q(e.r),g:q(e.g),b:q(e.b)}}parseString(t){if(!this.accepts(t))return;const e=Oi.exec(t);return e?{a:e.length>4?K(e[Si.a]):1,b:parseInt(e[Si.b]??"0",10),g:parseInt(e[Si.g]??"0",10),r:parseInt(e[Si.r]??"0",10)}:void 0}}async function Li(t){t.checkVersion("4.4.0"),await t.pluginManager.register(t=>{t.pluginManager.addColorManager("rgb",new Di)})}class _i extends jt{destroy=Dt.none;load(t){super.load(t),E(t)||$t(this,"destroy",t.destroy)}}class Ei extends ce{animation=new _i;value=3;load(t){if(super.load(t),E(t))return;const e=t.animation;void 0!==e&&this.animation.load(e)}}class Ti{#u;constructor(t){this.#u=t}init(t){const e=this.#u,i=t.options.size;if(!i)return;const s=i.animation;s.enable&&(t.size.velocity=t.retina.sizeAnimationSpeed/n*e.retina.reduceFactor,s.sync||(t.size.velocity*=A()))}isEnabled(t){return!t.destroyed&&!t.spawning&&t.size.enable&&((t.size.maxLoops??0)<=0||(t.size.maxLoops??0)>0&&(t.size.loops??0)<(t.size.maxLoops??0))}loadOptions(t,...e){Wt(t,"size",Ei,...e)}preInit(t){const e=this.#u.retina.pixelRatio,i=t.options.size;i&&(t.size=pi(i,e),t.retina.sizeAnimationSpeed=q(i.animation.speed)*e)}reset(t){t.size.time=0,t.size.loops=0}update(t,e){this.isEnabled(t)&&t.options.size&&fi(t,t.size,0,t.options.size.animation.destroy,e)}}async function Ri(t){t.checkVersion("4.4.0"),await t.pluginManager.register(t=>{t.pluginManager.addParticleUpdater("size",t=>Promise.resolve(new Ti(t)))})}async function Bi(t){t.checkVersion("4.4.0"),await t.pluginManager.register(async t=>{await Promise.all([Je(t),oi(t),hi(t),Li(t),ui(t),ei(t),Ii(t),vi(t),Ci(t),Ri(t)])})}class Fi{enable=!1;mode=[];load(t){E(t)||($t(this,"enable",t.enable),$t(this,"mode",t.mode))}}var Ai,Ui,Hi;!function(t){t.circle="circle",t.rectangle="rectangle"}(Ai||(Ai={}));class $i{enable=!1;mode=[];selectors=[];type=Ai.circle;load(t){E(t)||($t(this,"selectors",t.selectors),$t(this,"enable",t.enable),$t(this,"mode",t.mode),$t(this,"type",t.type))}}class Vi{enable=!1;mode=[];load(t){E(t)||($t(this,"enable",t.enable),$t(this,"mode",t.mode))}}class qi{onClick=new Fi;onDiv=new $i;onHover=new Vi;load(t){if(E(t))return;this.onClick.load(t.onClick);const e=t.onDiv;void 0!==e&&(this.onDiv=rt(e,t=>{const e=new $i;return e.load(t),e})),this.onHover.load(t.onHover)}}!function(t){t.canvas="canvas",t.parent="parent",t.window="window"}(Ui||(Ui={}));class Wi{#u;#p;constructor(t,e){this.#p=t,this.#u=e}load(t){if(E(t))return;if(!this.#u)return;const e=this.#p.interactors?.get(this.#u);if(e)for(const i of e)i.loadModeOptions&&i.loadModeOptions(this,t)}}class Ni{detectsOn=Ui.window;events=new qi;modes;constructor(t,e){this.modes=new Wi(t,e)}load(t){if(E(t))return;const e=t.detectsOn;void 0!==e&&(this.detectsOn=e),this.events.load(t.events),this.modes.load(t.modes)}}class ji{id="interactivity";#p;constructor(t){this.#p=t}async getPlugin(t){const{InteractivityPluginInstance:e}=await Promise.resolve().then(function(){return Rs});return new e(this.#p,t)}loadOptions(t,e,i){if(!this.needsPlugin())return;let s=e.interactivity;s?.load||(e.interactivity=s=new Ni(this.#p,t)),s.load(i?.interactivity);const n=this.#p.interactors?.get(t);if(n)for(const t of n)t.loadOptions&&t.loadOptions(e,i)}loadParticlesOptions(t,e,i){i?.interactivity&&(e.interactivity=ot({},i.interactivity));const s=this.#p.interactors?.get(t);if(s)for(const t of s)t.loadParticlesOptions?.(e,i)}needsPlugin(){return!0}}!function(t){t.external="external",t.particles="particles"}(Hi||(Hi={}));class Gi{type=Hi.particles;container;constructor(t){this.container=t}}const Xi="pointerdown",Yi="pointerup",Qi="pointerleave",Ki="pointermove",Zi="touchstart",Ji="touchend",ts="touchmove",es="touchcancel";class is extends Ft{#b;constructor(t,e,i,s){super(t,e,i),this.#b=s}contains(t){if(super.contains(t))return!0;const{width:e,height:i}=this.#b,{x:s,y:n}=t;return super.contains({x:s-e,y:n})||super.contains({x:s+e,y:n})||super.contains({x:s,y:n-i})||super.contains({x:s,y:n+i})||super.contains({x:s-e,y:n-i})||super.contains({x:s+e,y:n+i})||super.contains({x:s-e,y:n+i})||super.contains({x:s+e,y:n-i})}intersects(t){if(super.intersects(t))return!0;const{width:e,height:i}=this.#b,s=t.position,n=[{x:-e,y:0},{x:e,y:0},{x:0,y:-i},{x:0,y:i},{x:-e,y:-i},{x:e,y:i},{x:-e,y:i},{x:e,y:-i}];for(const e of n){const i={x:s.x+e.x,y:s.y+e.y};let n;if(t instanceof Ft)n=new Ft(i.x,i.y,t.radius);else{const e=t;n=new At(i.x,i.y,e.size.width,e.size.height)}if(super.intersects(n))return!0}return!1}}class ss{blur=5;color=new Yt;enable=!1;constructor(){this.color.value="#000"}load(t){E(t)||($t(this,"blur",t.blur),this.color=Yt.create(this.color,t.color),$t(this,"enable",t.enable))}}class ns{color;enable=!1;frequency=1;opacity;load(t){E(t)||(void 0!==t.color&&(this.color=Yt.create(this.color,t.color)),$t(this,"enable",t.enable),$t(this,"frequency",t.frequency),$t(this,"opacity",t.opacity))}}class as{blink=!1;color=new Yt;consent=!1;distance=100;enable=!1;frequency=1;id;opacity=1;shadow=new ss;triangles=new ns;warp=!1;width=1;constructor(){this.color.value="#fff"}load(t){E(t)||($t(this,"id",t.id),$t(this,"blink",t.blink),this.color=Yt.create(this.color,t.color),$t(this,"consent",t.consent),$t(this,"distance",t.distance),$t(this,"enable",t.enable),$t(this,"frequency",t.frequency),$t(this,"opacity",t.opacity),this.shadow.load(t.shadow),this.triangles.load(t.triangles),$t(this,"width",t.width),$t(this,"warp",t.warp))}}function os(t,e,i){const{dx:s,dy:n}=G(t,e),a={x:Math.abs(s),y:Math.abs(n)},o={x:Math.min(a.x,i.width-a.x),y:Math.min(a.y,i.height-a.y)};return Math.hypot(o.x,o.y)}class rs extends Gi{#P;#p;constructor(t,e){super(e),this.#p=t,this.#P=0}get maxDistance(){return this.#P}clear(){}init(){this.container.particles.linksColor=void 0,this.container.particles.linksColors=new Map}interact(t){if(!t.options.links)return;t.links=[],t.linksDistance&&t.linksDistance>this.#P&&(this.#P=t.linksDistance);const e=t.getPosition(),i=this.container,s=i.canvas.size;if(e.x<r.x||e.y<r.y||e.x>s.width||e.y>s.height)return;const n=t.options.links,a=n.opacity,o=t.retina.linksDistance??0,c=n.warp,l=c?new is(e.x,e.y,o,s):new Ft(e.x,e.y,o),h=i.particles.grid.query(l);for(const i of h){const l=i.options.links;if(t===i||!l?.enable||n.id!==l.id||i.spawning||i.destroyed||!i.links||t.links.some(t=>t.destination===i)||i.links.some(e=>e.destination===t))continue;const h=i.getPosition();if(h.x<r.x||h.y<r.y||h.x>s.width||h.y>s.height)continue;const d=G(e,h).distance,u=c&&l.warp?os(e,h,s):d,p=Math.min(d,u);if(p>o)continue;const f=(1-p/o)*a;this.#x(t),t.links.push({destination:i,opacity:f,color:this.#M(t,i),isWarped:u<d})}}isEnabled(t){return!!t.options.links?.enable}loadParticlesOptions(t,...e){Wt(t,"links",as,...e)}reset(){}#M(t,e){const i=this.container,s=t.options.links;if(!s)return;return We(t,e,void 0!==s.id?i.particles.linksColors.get(s.id):i.particles.linksColor,i.hdr)}#x(t){if(!t.options.links)return;const e=this.container,i=t.options.links;let s=void 0===i.id?e.particles.linksColor:e.particles.linksColors.get(i.id);s||(s=function(t,e,i,s){const n=O(e)?e:e.value;return n===u?s?Re(t,{value:n}):i?u:p:n===p?p:Re(t,{value:n})}(this.#p,i.color,i.blink,i.consent),void 0===i.id?e.particles.linksColor=s:e.particles.linksColors.set(i.id,s))}}class cs{id="links";#p;constructor(t){this.#p=t}async getPlugin(t){const{LinkInstance:e}=await Promise.resolve().then(function(){return Fs});return new e(this.#p,t)}loadOptions(){}needsPlugin(){return!0}}async function ls(t){t.checkVersion("4.4.0"),await t.pluginManager.register(t=>{const e=t.pluginManager;!function(t){if(!t.pluginManager.addInteractor)throw new Error("tsParticles Interactivity Plugin is not loaded")}(t),e.addPlugin(new cs(e)),e.addInteractor?.("particlesLinks",t=>Promise.resolve(new rs(e,t)))})}const hs={background:{color:"#000000"},particles:{number:{value:100},links:{distance:125,enable:!0,triangles:{enable:!0,opacity:.1}},move:{enable:!0,speed:5},paint:{fill:{color:{value:"#ffffff"}}},size:{value:1},shape:{type:"circle"}}};async function ds(t){await t.pluginManager.register(async t=>{await Promise.all([Bi(t),(async t=>{await async function(t){t.checkVersion("4.4.0"),await t.pluginManager.register(t=>{const e=t,i=e.pluginManager;i.addPlugin(new ji(i)),i.initializers.interactors??=new Map,i.interactors??=new Map,i.addInteractor=(t,e)=>{i.initializers.interactors??=new Map,i.initializers.interactors.set(t,e)},i.getInteractors=async(t,e=!1)=>(i.interactors??=new Map,i.initializers.interactors??=new Map,pt(t,i.interactors,i.initializers.interactors,e)),i.setOnClickHandler=t=>{const{items:i}=e;if(!i.length)throw new Error("Click handlers can only be set after calling tsParticles.load()");i.forEach(e=>{const i=e;i.addClickHandler?.(t)})}})}(t),await ls(t)})(t)]),t.pluginManager.addPreset("triangles",hs)})}const us=globalThis;us.loadTrianglesPreset=ds,us.tsParticles=Qe;function ps(t,e,i){const s=e[i];void 0!==s&&(t[i]=(t[i]??1)*s)}class fs{#k;#C;#z;#I;#S;#u;#O;#D;#L;#_;#E;#T;#p;#R;#B;#F={};#A=[void 0,void 0];#U={};constructor(t,e,i){this.#p=t,this.#u=e,this.#I=i,this.#O=null,this.#k=null,this.#C=new Set,this.#B=[],this.#R=[],this.#z=[],this.#S=[],this.#L=[],this.#_=[],this.#E=[],this.#T={0:[],1:[],2:[],3:[],4:[],5:[],6:[],7:[]}}get settings(){return this.#D}canvasClear(){this.#u.actualOptions.clear&&this.draw(t=>{t.clearRect(r.x,r.y,this.#I.size.width,this.#I.size.height)})}clear(){for(const t of this.#z)if(t.canvasClear?.())return;for(const t of Object.values(Rt))if("number"==typeof t)for(const e of this.#H(t))if(e.canvasClear?.())return;this.canvasClear()}destroy(){this.stop(),this.#k=null,this.#C.clear(),this.#B=[],this.#R=[],this.#z=[],this.#S=[],this.#L=[],this.#_=[],this.#E=[];for(const t of Object.values(Rt))"number"==typeof t&&(this.#T[t]=[])}draw(t){const e=this.#O;if(e)return t(e)}drawParticle(t,e){if(t.spawning||t.destroyed)return;const i=t.getRadius();if(i<=0)return;const s=t.getFillColor(),n=t.getStrokeColor();let[a,o]=this.#$(t);if(a??=s,o??=n,!a&&!o)return;const r=this.#u,c=t.options.zIndex,l=1-t.zIndexFactor,{fillOpacity:h,opacity:d,strokeOpacity:u}=t.getOpacity(),p=this.#U,f=this.#F,g=a?qe(a,r.hdr,h*d,r.peakNits,r.hdrMode):void 0,y=o?qe(o,r.hdr,u*d,r.peakNits,r.hdrMode):g;p.a=p.b=p.c=p.d=void 0,f.fill=g,f.stroke=y,this.draw(s=>{for(const i of this.#E)i.drawParticleSetup?.(s,t,e);this.#V(s,t,i,d,f,p),this.#q({container:r,context:s,particle:t,delta:e,colorStyles:f,radius:i*l**c.sizeRate,opacity:d,transform:p}),this.#W(t);for(const i of this.#_)i.drawParticleCleanup?.(s,t,e)})}drawParticlePlugins(t,e){this.draw(i=>{for(const s of this.#L)this.#N(i,s,t,e)})}drawParticles(t){const{particles:e,actualOptions:i}=this.#u;this.clear(),e.update(t),this.draw(s=>{const n=this.#I.size.width,a=this.#I.size.height;if(this.#k)try{s.drawImage(this.#k,r.x,r.y,n,a)}catch{this.#j("background-element-draw-error","Error drawing background element onto canvas")}const o=i.background;if(o.draw)try{o.draw(s,t)}catch{this.#j("background-draw-error","Error in background.draw callback")}for(const t of this.#H(Rt.BackgroundMask))t.canvasPaint?.();for(const e of this.#H(Rt.CanvasSetup))e.drawSettingsSetup?.(s,t);for(const e of this.#H(Rt.PluginContent))e.draw?.(s,t);e.drawParticles(t);for(const e of this.#H(Rt.CanvasCleanup))e.clearDraw?.(s,t),e.drawSettingsCleanup?.(s,t)})}init(){this.initUpdaters(),this.initPlugins(),this.#G(),this.paint()}initPlugins(){this.#z=[],this.#S=[],this.#L=[],this.#E=[],this.#_=[];for(const t of Object.values(Rt))"number"==typeof t&&(this.#T[t]=[]);for(const t of this.#u.plugins)(t.particleFillColor??t.particleStrokeColor)&&this.#S.push(t),t.drawParticle&&this.#L.push(t),t.drawParticleSetup&&this.#E.push(t),t.drawParticleCleanup&&this.#_.push(t),t.canvasClear&&this.#z.push(t),t.canvasPaint&&this.#H(Rt.BackgroundMask).push(t),t.drawSettingsSetup&&this.#H(Rt.CanvasSetup).push(t),t.draw&&this.#H(Rt.PluginContent).push(t),(t.clearDraw??t.drawSettingsCleanup)&&this.#H(Rt.CanvasCleanup).push(t)}initUpdaters(){this.#B=[],this.#R=[];for(const t of this.#u.particleUpdaters)t.afterDraw&&this.#R.push(t),(t.getColorStyles??t.getTransformValues??t.beforeDraw)&&this.#B.push(t)}paint(){let t=!1;for(const e of this.#H(Rt.BackgroundMask))if(t=e.canvasPaint?.()??!1,t)break;t||this.paintBase()}paintBase(t){this.draw(e=>{e.fillStyle=t??"rgba(0,0,0,0)",e.fillRect(r.x,r.y,this.#I.size.width,this.#I.size.height)})}paintImage(t,e){this.draw(i=>{if(!t)return;const s=i.globalAlpha;i.globalAlpha=e,i.drawImage(t,r.x,r.y,this.#I.size.width,this.#I.size.height),i.globalAlpha=s})}setContext(t){this.#O=t,this.#O&&(this.#O.globalCompositeOperation=i)}setContextSettings(t){this.#D=t}stop(){this.draw(t=>{t.clearRect(r.x,r.y,this.#I.size.width,this.#I.size.height)})}#W(t){for(const e of this.#R)e.afterDraw?.(t)}#V(t,e,i,s,n,a){for(const o of this.#B){if(o.getColorStyles){const{fill:a,stroke:r}=o.getColorStyles(e,t,i,s);a&&(n.fill=a),r&&(n.stroke=r)}if(o.getTransformValues){const t=o.getTransformValues(e);for(const e in t)ps(a,t,e)}o.beforeDraw?.(e)}}#X(t,e){if(!t?.drawAfter)return;const{particle:i}=e;i.effect&&t.drawAfter(e)}#Y(t,e){if(!t?.drawBefore)return;const{particle:i}=e;i.effect&&t.drawBefore(e)}#q(t){const{container:e,context:i,particle:s,delta:n,colorStyles:a,radius:o,opacity:r,transform:c}=t,{effectDrawers:l,shapeDrawers:h}=e,d=s.getPosition(),u=s.getTransformData(c),p={x:d.x,y:d.y};i.setTransform(u.a,u.b,u.c,u.d,d.x,d.y),a.fill&&(i.fillStyle=a.fill);const f=!!s.fillEnabled,g=s.strokeWidth??0;i.lineWidth=g,a.stroke&&(i.strokeStyle=a.stroke);const y={context:i,particle:s,radius:o,drawRadius:1*o,opacity:r,delta:n,pixelRatio:e.retina.pixelRatio,fill:f,stroke:g>0,transformData:u,position:{...d},drawPosition:p,drawScale:1};for(const t of e.plugins)t.drawParticleTransform?.(y);const m=s.effect?l.get(s.effect):void 0,v=s.shape?h.get(s.shape):void 0;this.#Y(m,y),this.#Q(v,y),this.#K(v,y),this.#Z(v,y),this.#X(m,y),i.resetTransform()}#N(t,e,i,s){e.drawParticle&&e.drawParticle(t,i,s)}#K(t,e){if(!t)return;const{context:i,fill:s,particle:n,stroke:a}=e;n.shape&&(i.beginPath(),t.draw(e),n.shapeClose&&i.closePath(),s&&i.fill(),a&&i.stroke())}#Z(t,e){if(!t?.afterDraw)return;const{particle:i}=e;i.shape&&t.afterDraw(e)}#Q(t,e){if(!t?.beforeDraw)return;const{particle:i}=e;i.shape&&t.beforeDraw(e)}#H(t){return this.#T[t]}#$(t){let e,i;for(const s of this.#S)if(!e&&s.particleFillColor&&(e=Fe(this.#p,s.particleFillColor(t))),!i&&s.particleStrokeColor&&(i=Fe(this.#p,s.particleStrokeColor(t))),e&&i)break;return this.#A[0]=e,this.#A[1]=i,this.#A}#G(){const t=this.#u.actualOptions.background;if(this.#k=null,t.element)if("string"==typeof t.element){if("undefined"!=typeof document){const e=document.querySelector(t.element);"undefined"!=typeof HTMLCanvasElement&&e instanceof HTMLCanvasElement||"undefined"!=typeof HTMLVideoElement&&e instanceof HTMLVideoElement||"undefined"!=typeof HTMLImageElement&&e instanceof HTMLImageElement?this.#k=e:e?this.#j("background-element-not-supported",`Background element "${t.element}" is not a supported drawable element (canvas, video, or img)`):this.#j("background-element-not-found",`Background element selector "${t.element}" not found`)}}else("undefined"!=typeof HTMLCanvasElement&&t.element instanceof HTMLCanvasElement||"undefined"!=typeof OffscreenCanvas&&t.element instanceof OffscreenCanvas||"undefined"!=typeof HTMLVideoElement&&t.element instanceof HTMLVideoElement||"undefined"!=typeof HTMLImageElement&&t.element instanceof HTMLImageElement)&&(this.#k=t.element)}#j(t,e){this.#C.has(t)||(this.#C.add(t),bt().warning(e))}}const gs=new WeakMap;function ys(t,e,i=!1){if(!e)return;const s=t.style,n=new Set;for(let t=0;t<s.length;t++){const e=s.item(t);e&&n.add(e)}for(let t=0;t<e.length;t++){const i=e.item(t);i&&n.add(i)}for(const t of n){const n=e.getPropertyValue(t);n?s.setProperty(t,n,i?"important":""):s.removeProperty(t)}}class ms{domElement;render;renderCanvas;size;zoom=1;#u;#J;#tt;#et;#it;#p;#st;#nt;#at;#ot;constructor(t,e){this.#p=t,this.#u=e,this.render=new fs(t,e,this),this.#at={height:0,width:0};const i=e.retina.pixelRatio,s=this.#at;this.size={height:s.height*i,width:s.width*i},this.#J=!1,this.#nt=[],this.#st="none"}get#rt(){return this.#u.actualOptions.fullScreen.enable}destroy(){if(this.stop(),this.#J){const t=this.domElement;t?.remove(),this.domElement=void 0,this.renderCanvas=void 0}else this.#ct();this.render.destroy(),this.#nt=[]}getZoomCenter(){const t=this.#u.retina.pixelRatio,{width:e,height:i}=this.size;return this.#ot?this.#ot:{x:e*a/t,y:i*a/t}}init(){this.#lt(t=>{t.disconnect()}),this.#et=function(t){if("undefined"!=typeof MutationObserver)return new MutationObserver(t)}(t=>{for(const e of t)"attributes"===e.type&&"style"===e.attributeName&&this.#ht()}),this.resize(),this.#dt(),this.#lt(t=>{const e=this.domElement;e&&e instanceof Node&&t.observe(e,{attributes:!0})}),this.initPlugins(),this.#ut(),this.initBackground(),this.#pt(),this.render.init()}initBackground(){const t=this.#u,e=t.actualOptions.background,i=this.domElement;if(!i)return;const s=i.style,n=Re(this.#p,e.color);if(n){const i=t.actualOptions.hdr;s.backgroundColor=Ve(n,t.hdr,e.opacity,i.peakNits,i.mode)}else s.backgroundColor="";s.backgroundImage=e.image||"",s.backgroundPosition=e.position||"",s.backgroundRepeat=e.repeat||"",s.backgroundSize=e.size||""}initPlugins(){this.#nt=[];for(const t of this.#u.plugins)t.resize&&this.#nt.push(t)}loadCanvas(t){this.#J&&this.domElement&&this.domElement.remove();const i=(t=>"undefined"!=typeof HTMLCanvasElement&&t instanceof HTMLCanvasElement)(t)?t:void 0;this.domElement=i,this.#J=!!i&&"true"===i.dataset[e],this.renderCanvas=i?(t=>{const e=gs.get(t);if(e)return e;if("function"!=typeof t.transferControlToOffscreen)throw new TypeError("OffscreenCanvas is required but not supported by this browser");try{const e=t.transferControlToOffscreen();return gs.set(t,e),e}catch{throw new TypeError("OffscreenCanvas transfer failed")}})(i):t;const s=this.domElement;s&&(s.ariaHidden="true",this.#it=function(t){const e=et().createElement("div").style;for(const i in t){const s=t[i];if(!(i in t)||E(s))continue;const n=t.getPropertyValue?.(s);if(!n)continue;const a=t.getPropertyPriority?.(s);a?e.setProperty(s,n,a):e.setProperty(s,n)}return e}(s.style));const n=this.#at,a=this.renderCanvas;s?(n.height=s.offsetHeight,n.width=s.offsetWidth):(n.height=a.height,n.width=a.width);const o=this.#u.retina.pixelRatio,r=this.size;a.height=r.height=n.height*o,a.width=r.width=n.width*o}resize(){const t=this.domElement;if(!t)return!1;const e=this.#u,i=this.renderCanvas;if(void 0===i)return!1;const s=e.canvas.#at,n={width:t.offsetWidth,height:t.offsetHeight},a=e.retina.pixelRatio,o={width:n.width*a,height:n.height*a};if(n.height===s.height&&n.width===s.width&&o.height===i.height&&o.width===i.width)return!1;const r={...s};s.height=n.height,s.width=n.width;const c=this.size;return i.width=c.width=o.width,i.height=c.height=o.height,this.#u.started&&e.particles.setResizeFactor({width:s.width/r.width,height:s.height/r.height}),!0}setPointerEvents(t){this.domElement&&(this.#st=t,this.#ht())}setZoom(t,e){this.zoom=t,this.#ot=e}stop(){this.#lt(t=>{t.disconnect()}),this.#et=void 0,this.#ft(),this.render.stop()}async windowResize(){if(!this.domElement||!this.resize())return;const t=this.#u,e=t.updateActualOptions();t.particles.setDensity(),this.#gt(),e&&await t.refresh()}#gt(){for(const t of this.#nt)t.resize?.()}#ut(){const t=this.#u,e=t.actualOptions.hdr.enable&&it("(color-gamut: p3)")?.matches&&it("(dynamic-range: high)")?.matches;t.hdr=e??!1,t.hdrMode=t.actualOptions.hdr.mode,t.peakNits=t.actualOptions.hdr.peakNits;const i=this.renderCanvas;if(!i)return;let s;this.render.setContextSettings({alpha:!0,desynchronized:!0,willReadFrequently:!1,...e?{colorSpace:"display-p3",colorType:"float16"}:{colorSpace:"srgb"}});try{s=i.getContext("2d",this.render.settings)}catch{s=null}if(e&&!s){t.hdr=!1;const e={alpha:!0,desynchronized:!0,willReadFrequently:!1,colorSpace:"srgb"};this.render.setContextSettings(e);try{s=i.getContext("2d",e)}catch{s=null}}this.render.setContext(s)}#pt(){this.#ft();const t=it("(color-gamut: p3)"),e=it("(dynamic-range: high)"),i=()=>{this.#yt(),this.#ut(),this.initBackground()},s=[];t&&(t.addEventListener("change",i),s.push({handler:i,mql:t})),e&&(e.addEventListener("change",i),s.push({handler:i,mql:e})),this.#tt=s}#dt(){const t=this.domElement,e=this.#u.actualOptions;if(t){this.#rt?this.#mt():this.#ct();for(const i in e.style){if(!i||!(i in e.style))continue;const s=e.style[i];s&&t.style.setProperty(i,s,"important")}}}#yt(){const t=this.renderCanvas;t&&(this.domElement||(this.renderCanvas=new OffscreenCanvas(t.width,t.height)))}#ft(){if(this.#tt){for(const{handler:t,mql:e}of this.#tt)e.removeEventListener("change",t);this.#tt=void 0}}#ht(){const t=this.domElement;if(!t)return;this.#lt(t=>{t.disconnect()}),this.#dt(),this.initBackground();const e=this.#st;t.style.pointerEvents=e,t.style.setProperty("pointer-events",e),this.#lt(e=>{t instanceof Node&&e.observe(t,{attributes:!0})})}#ct(){const t=this.domElement,e=this.#it;t&&e&&ys(t,e,!0)}#lt(t){this.#et&&t(this.#et)}#mt(){const t=this.domElement;t&&ys(t,function(t){if(ht!==t||!dt){ht=t;const e=et().createElement("div").style,i=10,s={width:"100%",height:"100%",margin:"0",padding:"0",borderWidth:"0",position:"fixed",zIndex:t.toString(i),"z-index":t.toString(i),top:"0",left:"0","pointer-events":"none"};for(const t in s){const i=s[t];void 0!==i&&e.setProperty(t,i)}dt=e}return dt}(this.#u.actualOptions.fullScreen.zIndex),!0)}}class vs{#u;#vt;#wt;#bt;constructor(t){this.#u=t,this.#vt={visibilityChange:()=>{this.#Pt()},resize:()=>{this.#xt()}}}addListeners(){this.#Mt(!0)}removeListeners(){this.#Mt(!1)}#Pt(){const t=this.#u;t.actualOptions.pauseOnBlur&&(et().hidden?(t.pageHidden=!0,t.pause()):(t.pageHidden=!1,t.animationStatus?t.play(!0):t.draw(!0)))}#xt(){this.#bt&&(clearTimeout(this.#bt),this.#bt=void 0);const t=async()=>{const t=this.#u.canvas;await t.windowResize()};this.#bt=setTimeout(()=>{t()},this.#u.actualOptions.resize.delay*o)}#Mt(t){const e=this.#vt;this.#kt(t),ut(document,s,e.visibilityChange,t,!1)}#kt(t){const e=this.#vt,i=this.#u;if(!i.actualOptions.resize.enable)return;if("undefined"==typeof ResizeObserver)return void ut(globalThis,"resize",e.resize,t);const s=i.canvas.domElement;this.#wt&&!t?(s&&this.#wt.unobserve(s),this.#wt.disconnect(),this.#wt=void 0):!this.#wt&&t&&s&&(this.#wt=new ResizeObserver(t=>{t.find(t=>t.target===s)&&this.#xt()}),this.#wt.observe(s))}}function ws(t){if(e=t.outMode,i=t.checkModes,!(e===i||_(i)&&i.includes(e)))return;var e,i;const s=2*t.radius;t.coord>t.maxCoord-s?t.setCb(-t.radius):t.coord<s&&t.setCb(t.radius)}function bs(t,e){const i=t%e;return i<0?i+e:i}function Ps(t,e,i,s){const n=Me(i,e,e.actualOptions.particles),a=n.reduceDuplicates;t.effect=ct(n.effect.type,t.id,a),t.shape=ct(n.shape.type,t.id,a);const o=n.effect,r=n.shape;if(s){if(s.effect){const e=s.effect.type;if(e&&e!==t.effect){const i=ct(e,t.id,a);i&&(t.effect=i)}o.load(s.effect)}if(s.shape){const e=s.shape.type;if(e&&e!==t.shape){const i=ct(e,t.id,a);i&&(t.shape=i)}r.load(s.shape)}}if(t.effect===u){const i=[...e.effectDrawers.keys()];t.effect=i[Math.floor(A()*i.length)]}if(t.shape===u){const i=[...e.shapeDrawers.keys()];t.shape=i[Math.floor(A()*i.length)]}t.effectData=t.effect?function(t,e,i,s){const n=e.options[t];return ot({close:e.close},ct(n,i,s))}(t.effect,o,t.id,a):void 0,t.shapeData=t.shape?function(t,e,i,s){const n=e.options[t];return ot({close:e.close},ct(n,i,s))}(t.shape,r,t.id,a):void 0,n.load(s);const c=t.effectData,l=t.shapeData;return c&&n.load(c.particles),l&&n.load(l.particles),t.effectClose=c?.close??n.effect.close,t.shapeClose=l?.close??n.shape.close,n}class xs{backColor;destroyed;direction;effect;effectClose;effectData;fillColor;fillEnabled;fillOpacity;group;id;ignoresResizeRatio;initialPosition;initialVelocity;isRotating;justWarped;lastPathTime;misplaced;moveCenter;offset;opacity;options;outType;pathRotation;position;randomIndexData;retina;roll;rotation;shape;shapeClose;shapeData;sides;size;spawning;strokeColor;strokeOpacity;strokeWidth;unbreakable;velocity;zIndexFactor;#Ct={fillOpacity:1,opacity:1,strokeOpacity:1};#zt=z.origin;#It={sin:0,cos:0};#St={a:1,b:0,c:0,d:1};#u;#Ot=[];#p;constructor(t,e){this.#p=t,this.#u=e}addModifier(t){this.#Ot.push(t),this.#Ot.sort((t,e)=>t.priority-e.priority)}clearModifiers(){this.#Ot.length=0}destroy(t){if(this.unbreakable||this.destroyed)return;this.destroyed=!0,this.clearModifiers();const e=this.#u,i=this.shape?e.shapeDrawers.get(this.shape):void 0;i?.particleDestroy?.(this);for(const i of e.particleDestroyedPlugins)i.particleDestroyed?.(this,t);for(const i of e.particleUpdaters)i.particleDestroyed?.(this,t);this.#u.dispatchEvent(yt.particleDestroyed,{particle:this})}draw(t){const e=this.#u.canvas.render;e.drawParticlePlugins(this,t),e.drawParticle(this,t)}getAngle(){return this.rotation+(this.pathRotation?this.velocity.angle:0)}getFillColor(){return this.#Dt(this.#Lt(Ne(this.fillColor),t=>t.fillColor))}getMass(){return this.getRadius()**2*Math.PI*a}getModifier(t){return this.#Ot.find(e=>e.id===t)}getOpacity(){const t=this.options.zIndex,e=(1-this.zIndexFactor)**t.opacityRate,i=q(this.opacity?.value??1),s=this.#Lt(void 0,t=>t.opacity)??i,n=this.fillOpacity??1,a=this.strokeOpacity??1;return this.#Ct.fillOpacity=n,this.#Ct.opacity=s*e,this.#Ct.strokeOpacity=a,this.#Ct}getPosition(){return this.#zt.x=this.position.x+this.offset.x,this.#zt.y=this.position.y+this.offset.y,this.#zt.z=this.position.z,this.#zt}getRadius(){return this.#Lt(this.size.value,t=>t.radius)}getRotateData(){const t=this.getAngle();return this.#It.sin=Math.sin(t),this.#It.cos=Math.cos(t),this.#It}getStrokeColor(){return this.#Dt(this.#Lt(Ne(this.strokeColor),t=>t.strokeColor))}getTransformData(t){const e=this.getRotateData(),i=this.isRotating;return this.#St.a=e.cos*(t.a??c),this.#St.b=i?e.sin*(t.b??1):t.b??l,this.#St.c=i?-e.sin*(t.c??1):t.c??h,this.#St.d=e.cos*(t.d??d),this.#St}init(t,e,i,s){const n=this.#u;!function(t,e,i){t.id=e,t.group=i,t.justWarped=!1,t.effectClose=!0,t.shapeClose=!0,t.pathRotation=!1,t.lastPathTime=0,t.destroyed=!1,t.unbreakable=!1,t.isRotating=!1,t.rotation=0,t.misplaced=!1,t.retina={maxDistance:{},maxSpeed:0,moveDrift:0,moveSpeed:0,sizeAnimationSpeed:0},t.size={value:1,max:1,min:1,enable:!1},t.outType=_t.normal,t.ignoresResizeRatio=!0}(this,t,s),this.options=Ps(this,n,this.#p,i),n.retina.initParticle(this),function(t,e){for(const i of t)i.preInit?.(e)}(n.particleUpdaters,this),this.#_t(e),this.initialVelocity=this.#Et(),this.velocity=this.initialVelocity.copy(),this.zIndexFactor=this.position.z/n.zLayers,this.sides=24,function(t,e){let i,s;t.effect&&(i=e.effectDrawers.get(t.effect)),i?.loadEffect&&i.loadEffect(t),t.shape&&(s=e.shapeDrawers.get(t.shape)),s?.loadShape&&s.loadShape(t);const n=s?.getSidesCount;n&&(t.sides=n(t))}(this,n),this.spawning=!1,function(t,e){for(const i of t)i.init(e)}(n.particleUpdaters,this),function(t,e){const i=e.shape?t.shapeDrawers.get(e.shape):void 0,s=e.effect?t.effectDrawers.get(e.effect):void 0;s?.particleInit?.(t,e),i?.particleInit?.(t,e)}(n,this),function(t,e){for(const i of t.particleCreatedPlugins)i.particleCreated?.(e)}(n,this)}isInsideCanvas(t){return this.#Tt({direction:t}).inside}isInsideCanvasForOutMode(t,e){return this.#Tt({direction:e,outMode:t}).inside}isShowingBack(){if(!this.roll)return!1;const t=this.roll.angle;if(this.roll.horizontal&&this.roll.vertical){const e=bs(t,f);return e>=Math.PI*a&&e<3*Math.PI*a}if(this.roll.horizontal){const e=bs(t+Math.PI*a,f);return e>=Math.PI&&e<2*Math.PI}if(this.roll.vertical){const e=bs(t,f);return e>=Math.PI&&e<2*Math.PI}return!1}isVisible(){return!this.destroyed&&!this.spawning&&this.isInsideCanvas()}removeModifier(t){const e=this.#Ot.findIndex(e=>e.id===t);e>=0&&this.#Ot.splice(e,1)}reset(){for(const t of this.#u.particleUpdaters)t.reset?.(this)}#Lt(t,e){let i=t;for(const t of this.#Ot)if(t.enabled){const s=e(t);void 0!==s&&(i=s)}return i}#Rt(t,e){let i=0,s=t?z.create(t.x,t.y,e):void 0;const n=this.#u,a=n.particlePositionPlugins,o=this.options.move.outModes,r=this.getRadius(),c=n.canvas.size;for(;;){for(const t of a){const i=t.particlePosition?.(s,this);if(i)return z.create(i.x,i.y,e)}const t=Q({size:c,position:s}),l=z.create(t.x,t.y,e);this.#Bt(l,r,o.left??o.default),this.#Bt(l,r,o.right??o.default),this.#Ft(l,r,o.top??o.default),this.#Ft(l,r,o.bottom??o.default);let h=!0;for(const t of n.particles.checkParticlePositionPlugins)if(h=t.checkParticlePosition?.(this,l,i)??!0,!h)break;if(h)return l;i+=1,s=void 0}}#Et(){const t=this.options.move,e=function(t){const e=I.origin;return e.length=1,e.angle=t,e}(this.direction).copy();if(t.direction===k.inside||t.direction===k.outside)return e;const i=Y(q(t.angle.value)),s=Y(q(t.angle.offset)),n={left:s-i*a,right:s+i*a};return t.straight||(e.angle+=V(j(n.left,n.right))),t.random&&"number"==typeof t.speed&&(e.length*=A()),e}#Bt(t,e,i){ws({outMode:i,checkModes:[St.bounce],coord:t.x,maxCoord:this.#u.canvas.size.width,setCb:e=>t.x+=e,radius:e})}#Ft(t,e,i){ws({outMode:i,checkModes:[St.bounce],coord:t.y,maxCoord:this.#u.canvas.size.height,setCb:e=>t.y+=e,radius:e})}#At(t,e){const i=this.getRadius(),s=this.#u.canvas.size,n=this.position,a=e===St.bounce;return t===Z.bottom?{inside:a?n.y+i<s.height:n.y-i<s.height,reason:"default"}:t===Z.left?{inside:a?n.x-i>0:n.x+i>0,reason:"default"}:t===Z.right?{inside:a?n.x+i<s.width:n.x-i<s.width,reason:"default"}:t===Z.top?{inside:a?n.y-i>0:n.y+i>0,reason:"default"}:{inside:n.x>=-i&&n.y>=-i&&n.y<=s.height+i&&n.x<=s.width+i,reason:"default"}}#Ut(t,e){return{canvasSize:this.#u.canvas.size,direction:t,outMode:e,particle:this,radius:this.getRadius()}}#Tt(t){const e=this.#At(t.direction,t.outMode),i=this.#u,s=this.shape?i.shapeDrawers.get(this.shape):void 0,n=this.effect?i.effectDrawers.get(this.effect):void 0,a=s?.isInsideCanvas,o=n?.isInsideCanvas;if(!a&&!o)return e;const r=this.#Ut(t.direction,t.outMode),c=a?this.#Ht(a(r),"shape"):void 0,l=o?this.#Ht(o(r),"effect"):void 0;if(c&&l){const t=Math.max(c.margin??0,l.margin??0);return{inside:c.inside&&l.inside,margin:t>0?t:void 0,reason:"combined"}}return c??l??e}#Dt(t){return t&&this.roll&&(this.backColor||this.roll.alter)&&this.isShowingBack()?this.backColor?this.backColor:this.roll.alter?function(t,e,i){return{h:t.h,s:t.s,l:t.l+(e===Ot.darken?-1:1)*i}}(t,this.roll.alter.type,this.roll.alter.value):t:t}#_t(t){const e=this.#u,i=Math.floor(q(this.options.zIndex.value)),s=this.#Rt(t,H(i,0,e.zLayers));if(!s)throw new Error("a valid position cannot be found for particle");this.position=s,this.initialPosition=this.position.copy();const n=e.canvas.size;switch(this.moveCenter={...lt(this.options.move.center,n),radius:this.options.move.center.radius,mode:this.options.move.center.mode},this.direction=function(t,e,i){if(D(t))return Y(t);switch(t){case k.top:return-Math.PI*a;case k.topRight:return-Math.PI*x;case k.right:return 0;case k.bottomRight:return Math.PI*x;case k.bottom:return Math.PI*a;case k.bottomLeft:return.75*Math.PI;case k.left:return Math.PI;case k.topLeft:return.75*-Math.PI;case k.inside:return Math.atan2(i.y-e.y,i.x-e.x);case k.outside:return Math.atan2(e.y-i.y,e.x-i.x);default:return A()*f}}(this.options.move.direction,this.position,this.moveCenter),this.options.move.direction){case k.inside:this.outType=_t.inside;break;case k.outside:this.outType=_t.outside}this.offset=I.origin}#Ht(t,e){return"boolean"==typeof t?{inside:t,reason:e}:{inside:t.inside,margin:t.margin,reason:t.reason??e}}}class Ms{#$t;#Vt=new Map;#qt=[];#Wt;#Nt;#jt=[];#Gt;constructor(t){this.#$t=t,this.#Wt=0,this.#Gt=0}clear(){this.#Vt.clear();const t=this.#Nt;t&&(this.#$t=t),this.#Nt=void 0}insert(t){const{x:e,y:i}=t.getPosition(),s=this.#Xt(e,i);this.#Vt.has(s)||this.#Vt.set(s,[]),this.#Vt.get(s)?.push(t)}query(t,e,i=[]){const s=this.#Yt(t);if(!s)return i;const n=Math.floor(s.minX/this.#$t),a=Math.floor(s.maxX/this.#$t),o=Math.floor(s.minY/this.#$t),r=Math.floor(s.maxY/this.#$t);for(let s=n;s<=a;s++)for(let n=o;n<=r;n++){const a=`${s}_${n}`,o=this.#Vt.get(a);if(o)for(const s of o)e&&!e(s)||t.contains(s.getPosition())&&i.push(s)}return i}queryCircle(t,e,i,s=[]){const n=this.#Qt(t.x,t.y,e),a=this.query(n,i,s);return this.#Kt(),a}queryRectangle(t,e,i,s=[]){const n=this.#Zt(t.x,t.y,e.width,e.height),a=this.query(n,i,s);return this.#Kt(),a}setCellSize(t){this.#Nt=t}#Qt(t,e,i){return(this.#qt[this.#Wt++]??=new Ft(t,e,i)).reset(t,e,i)}#Zt(t,e,i,s){return(this.#jt[this.#Gt++]??=new At(t,e,i,s)).reset(t,e,i,s)}#Xt(t,e){return`${Math.floor(t/this.#$t)}_${Math.floor(e/this.#$t)}`}#Yt(t){if(t instanceof Ft){const e=t.radius,{x:i,y:s}=t.position;return{minX:i-e,maxX:i+e,minY:s-e,maxY:s+e}}if(t instanceof At){const{x:e,y:i}=t.position,{width:s,height:n}=t.size;return{minX:e,maxX:e+s,minY:i,maxY:i+n}}return null}#Kt(){this.#Wt=0,this.#Gt=0}}class ks{checkParticlePositionPlugins;grid;#Jt;#u;#te;#ee;#ie;#se;#ne;#ae;#p;#oe;#re;#ce;#le;#he;#de;constructor(t,e){this.#p=t,this.#u=e,this.#ie=0,this.#Jt=[],this.#oe=[],this.#ee=0,this.#te=new Map,this.#se=new Map,this.#de=this.#ue(this.#u.zLayers),this.grid=new Ms(100),this.checkParticlePositionPlugins=[],this.#ne=[],this.#ae=[],this.#ce=[],this.#re=[],this.#he=[]}get count(){return this.#Jt.length}addParticle(t,e,i,s){const n=this.#u.actualOptions.particles.number.limit.mode,a=void 0===i?this.#ee:this.#te.get(i)??this.#ee,o=this.count;if(a>0)switch(n){case It.delete:{const t=o+1-a;t>0&&this.removeQuantity(t);break}case It.wait:if(o>=a)return}try{const n=this.#oe.pop()??new xs(this.#p,this.#u);n.init(this.#ie,t,e,i);let a=!0;return s&&(a=s(n)),a?(this.#Jt.push(n),this.#pe(n),this.#ie++,this.#u.dispatchEvent(yt.particleAdded,{particle:n}),n):void this.#oe.push(n)}catch(t){bt().warning(`error adding particle: ${t}`)}}clear(){this.#Jt=[],this.#se.clear(),this.#fe(this.#u.zLayers)}destroy(){this.#Jt=[],this.#oe.length=0,this.#se.clear(),this.#de=[],this.checkParticlePositionPlugins=[],this.#ne=[],this.#ae=[],this.#ce=[],this.#re=[],this.#he=[]}drawParticles(t){for(let e=this.#de.length-1;e>=0;e--){const i=this.#de[e];if(i)for(const e of i)e.draw(t)}}filter(t){return this.#Jt.filter(t)}find(t){return this.#Jt.find(t)}get(t){return this.#Jt[t]}async init(){const t=this.#u,e=t.actualOptions;this.checkParticlePositionPlugins=[],this.#he=[],this.#ae=[],this.#ce=[],this.#ne=[],this.#re=[],this.#se.clear(),this.#fe(t.zLayers),this.grid=new Ms(100*t.retina.pixelRatio);for(const e of t.plugins)e.redrawInit&&await e.redrawInit(),e.checkParticlePosition&&this.checkParticlePositionPlugins.push(e),e.update&&this.#he.push(e),e.particleUpdate&&this.#ae.push(e),e.postUpdate&&this.#ce.push(e),e.particleReset&&this.#ne.push(e),e.postParticleUpdate&&this.#re.push(e);await this.#u.initDrawersAndUpdaters();for(const e of this.#u.effectDrawers.values())await(e.init?.(t));for(const e of this.#u.shapeDrawers.values())await(e.init?.(t));let i=!1;for(const e of t.plugins)if(i=e.particlesInitialization?.()??i,i)break;if(!i){const t=e.particles,i=t.groups;for(const e in i){const s=i[e];if(s)for(let i=this.count,n=0;n<s.number.value&&i<t.number.value;i++,n++)this.addParticle(void 0,s,e)}for(let e=this.count;e<t.number.value;e++)this.addParticle()}}push(t,e,i,s){for(let n=0;n<t;n++)this.addParticle(e,i,s)}async redraw(){this.clear(),await this.init(),this.#u.canvas.render.drawParticles({value:0,factor:0})}remove(t,e,i){this.removeAt(this.#Jt.indexOf(t),void 0,e,i)}removeAt(t,e=1,i,s){if(t<0||t>this.count)return;let n=0;for(let a=t;n<e&&a<this.count;a++)this.#ge(a,i,s)&&(a--,n++)}removeQuantity(t,e){this.removeAt(0,t,e)}setDensity(){const t=this.#u.actualOptions,e=t.particles.groups;let i=0;for(const t of this.#u.plugins)t.particlesDensityCount&&(i+=t.particlesDensityCount());for(const t in e){const s=e[t];if(!s)continue;const n=Me(this.#p,this.#u,s);this.#ye(n,i,t)}this.#ye(t.particles,i)}setResizeFactor(t){this.#le=t}update(t){this.grid.clear();for(const e of this.#he)e.update?.(t);const e=this.#me(t);for(const e of this.#ce)e.postUpdate?.(t);if(this.#ve(t,e),e.size)for(const t of e)this.remove(t);this.#le=void 0}#we(...t){this.#oe.push(...t)}#ye(t,e,i,s){const n=t.number;if(!n.density.enable)return void(void 0===i?this.#ee=n.limit.value:(s?.number.limit.value??n.limit.value)&&this.#te.set(i,s?.number.limit.value??n.limit.value));const a=this.#be(n.density),o=n.value,r=n.limit.value>0?n.limit.value:o,c=Math.min(o,r)*a+e,l=Math.min(this.count,this.filter(t=>t.group===i).length);void 0===i?this.#ee=n.limit.value*a:this.#te.set(i,n.limit.value*a),l<c?this.push(Math.abs(c-l),void 0,t,i):l>c&&this.removeQuantity(l-c,i)}#ue(t){const e=Math.max(Math.floor(t),1);return Array.from({length:e},()=>[])}#Pe(t){const e=this.#de.length-1;return e<=0?0:Math.min(Math.max(Math.floor(t),0),e)}#be(t){const e=this.#u;if(!t.enable)return 1;const i=e.canvas.size,s=e.retina.pixelRatio;return i.width&&i.height?i.width*i.height/(t.height*t.width*s**2):1}#pe(t){const e=this.#Pe(t.position.z),i=this.#de[e];i&&(i.push(t),this.#se.set(t.id,e))}#ge(t,e,i){const s=this.#Jt[t];return!!s&&(s.group===e&&(this.#Jt.splice(t,1),this.#xe(s),s.destroy(i),this.#u.dispatchEvent(yt.particleRemoved,{particle:s}),this.#we(s),!0))}#xe(t){const e=this.#se.get(t.id)??this.#Pe(t.position.z),i=this.#de[e];if(!i)return void this.#se.delete(t.id);const s=i.findIndex(e=>e.id===t.id);s>=0&&i.splice(s,1),this.#se.delete(t.id)}#fe(t){const e=Math.max(Math.floor(t),1);if(this.#de.length===e)for(const t of this.#de)t.length=0;else this.#de=this.#ue(e)}#Me(t){const e=this.#Pe(t.position.z),i=this.#se.get(t.id);if(void 0===i)return void this.#pe(t);if(i===e)return;const s=this.#de[i];if(s){const e=s.findIndex(e=>e.id===t.id);e>=0&&s.splice(e,1)}const n=this.#de[e];if(n){if(n.push(t),n.length>=2){const e=n[n.length-2];e&&t.id<e.id&&n.sort((t,e)=>t.id-e.id)}this.#se.set(t.id,e)}else this.#se.set(t.id,e)}#me(t){const e=new Set,i=this.#le;for(const s of this.#Jt){i&&!s.ignoresResizeRatio&&(s.position.x*=i.width,s.position.y*=i.height,s.initialPosition.x*=i.width,s.initialPosition.y*=i.height),s.ignoresResizeRatio=!1;for(const t of this.#ne)t.particleReset?.(s);for(const e of this.#ae){if(s.destroyed)break;e.particleUpdate?.(s,t)}s.destroyed?e.add(s):this.grid.insert(s)}return e}#ve(t,e){for(const i of this.#Jt)if(i.destroyed)e.add(i);else{for(const e of this.#u.particleUpdaters)e.update(i,t);if(!i.spawning)for(const e of this.#re)e.postParticleUpdate?.(i,t);this.#Me(i)}}}class Cs{pixelRatio;reduceFactor;#u;constructor(t){this.#u=t,this.pixelRatio=1,this.reduceFactor=1}init(){const t=this.#u,e=t.actualOptions;this.pixelRatio=e.detectRetina?devicePixelRatio:1,this.reduceFactor=1;const i=this.pixelRatio,s=t.canvas,n=s.domElement;n&&(s.size.width=n.offsetWidth*i,s.size.height=n.offsetHeight*i)}initParticle(t){const e=t.options,i=this.pixelRatio,s=e.move,n=s.distance,a=t.retina;a.maxSpeed=q(s.gravity.maxSpeed)*i,a.moveDrift=q(s.drift)*i,a.moveSpeed=q(s.speed)*i;const o=a.maxDistance;o.horizontal=void 0===n.horizontal?void 0:n.horizontal*i,o.vertical=void 0===n.vertical?void 0:n.vertical*i}}function zs(t){return!t.destroyed}function Is(t,e,...i){const s=new ke(t,e);return Ht(s,...i),s}var Ss=Object.freeze({__proto__:null,Container:class{actualOptions;canvas;destroyed;effectDrawers;fpsLimit;hdr;hdrMode;id;pageHidden;particleCreatedPlugins;particleDestroyedPlugins;particlePositionPlugins;particleUpdaters;particles;peakNits;plugins;retina;shapeDrawers;started;zLayers;#ke;#Ce;#ze={value:0,factor:0};#Ie;#Se;#Oe;#De;#Le;#_e;#Ee;#Te;#Re;#Be;#Fe;#p;#Ae;#Ue;constructor(t){const{dispatchCallback:e,pluginManager:i,id:s,onDestroy:n,sourceOptions:a}=t;this.#p=i,this.#Ie=e,this.#Re=n,this.id=Symbol(s),this.fpsLimit=120,this.hdr=!1,this.hdrMode=zt.standard,this.peakNits=400,this.#Ae=!1,this.#ke=0,this.#Oe=0,this.#Te=0,this.#Le=!0,this.started=!1,this.destroyed=!1,this.#Fe=!0,this.#Ee=0,this.zLayers=100,this.pageHidden=!1,this.#Ue=a,this.#_e=a,this.effectDrawers=new Map,this.shapeDrawers=new Map,this.particleUpdaters=[],this.retina=new Cs(this),this.canvas=new ms(this.#p,this),this.particles=new ks(this.#p,this),this.plugins=[],this.particleDestroyedPlugins=[],this.particleCreatedPlugins=[],this.particlePositionPlugins=[],this.#Be=Is(this.#p,this),this.actualOptions=Is(this.#p,this),this.#De=new vs(this),this.dispatchEvent(yt.containerBuilt)}get animationStatus(){return!this.#Fe&&!this.pageHidden&&zs(this)}get options(){return this.#Be}get sourceOptions(){return this.#Ue}addLifeTime(t){this.#Te+=t}alive(){return!this.#Oe||this.#Te<=this.#Oe}destroy(t=!0){if(zs(this)){this.stop(),this.particles.destroy(),this.canvas.destroy();for(const[,t]of this.effectDrawers)t.destroy?.(this);for(const[,t]of this.shapeDrawers)t.destroy?.(this);for(const t of this.plugins)t.destroy?.();this.effectDrawers=new Map,this.shapeDrawers=new Map,this.particleUpdaters=[],this.plugins.length=0,this.#p.clearPlugins(this),this.destroyed=!0,this.#Re(t),this.dispatchEvent(yt.containerDestroyed)}}dispatchEvent(t,e){this.#Ie(t,{container:this,data:e})}draw(t){if(!zs(this))return;let e=t;this.#Se=B(t=>{e&&(this.#Ee=void 0,e=!1),this.#He(t)})}async export(t,e={}){for(const i of this.plugins){if(!i.export)continue;const s=await i.export(t,e);if(s.supported)return s.blob}bt().error(`Export plugin with type ${t} not found`)}async init(){if(!zs(this))return;const t=new Map;for(const e of this.#p.plugins){const i=await e.getPlugin(this);i.preInit&&await i.preInit(),t.set(e,i)}await this.initDrawersAndUpdaters(),this.#Be=Is(this.#p,this,this.#_e,this.sourceOptions),this.actualOptions=Is(this.#p,this,this.#Be),this.plugins.length=0,this.particleDestroyedPlugins.length=0,this.particleCreatedPlugins.length=0,this.particlePositionPlugins.length=0;for(const[e,i]of t)e.needsPlugin(this.actualOptions)&&(this.plugins.push(i),i.particleCreated&&this.particleCreatedPlugins.push(i),i.particleDestroyed&&this.particleDestroyedPlugins.push(i),i.particlePosition&&this.particlePositionPlugins.push(i));this.retina.init(),this.canvas.init(),this.updateActualOptions(),this.canvas.initBackground(),this.canvas.resize();const{delay:e,duration:i,fpsLimit:s,smooth:n,zLayers:a}=this.actualOptions,r=this.actualOptions.hdr;this.hdrMode=r.mode,this.peakNits=r.peakNits,this.zLayers=a,this.#Oe=q(i)*o,this.#ke=q(e)*o,this.#Te=0,this.fpsLimit=s>0?s:120,this.#Ae=n;for(const t of this.plugins)await(t.init?.());await this.particles.init(),this.dispatchEvent(yt.containerInit),this.particles.setDensity();for(const t of this.plugins)t.particlesSetup?.();this.dispatchEvent(yt.particlesSetup)}async initDrawersAndUpdaters(){const t=this.#p;this.effectDrawers=await t.getEffectDrawers(this,!0),this.shapeDrawers=await t.getShapeDrawers(this,!0),this.particleUpdaters=await t.getUpdaters(this,!0)}pause(){var t;if(zs(this)&&(void 0!==this.#Se&&(t=this.#Se,F(t),this.#Se=void 0),!this.#Fe)){for(const t of this.plugins)t.pause?.();this.pageHidden||(this.#Fe=!0),this.dispatchEvent(yt.containerPaused)}}play(t){if(!zs(this))return;const e=this.#Fe||t;if(!this.#Le||this.actualOptions.autoPlay){if(this.#Fe&&(this.#Fe=!1),e)for(const t of this.plugins)t.play&&t.play();this.dispatchEvent(yt.containerPlay),this.draw(e??!1)}else this.#Le=!1}async refresh(){if(zs(this))return this.stop(),this.start()}async reset(t){if(zs(this))return this.#_e=t,this.#Ue=t,this.#Be=Is(this.#p,this,this.#_e,this.sourceOptions),this.actualOptions=Is(this.#p,this,this.#Be),this.refresh()}async start(){zs(this)&&!this.started&&(await this.init(),this.started=!0,await new Promise(t=>{const e=async()=>{this.#De.addListeners();for(const t of this.plugins)await(t.start?.());this.dispatchEvent(yt.containerStarted),this.play(),t()};this.#Ce=setTimeout(()=>{e()},this.#ke)}))}stop(){if(zs(this)&&this.started){this.#Ce&&(clearTimeout(this.#Ce),this.#Ce=void 0),this.#Le=!0,this.started=!1,this.#De.removeListeners(),this.pause(),this.particles.clear(),this.canvas.stop();for(const t of this.plugins)t.stop?.();this.particleCreatedPlugins.length=0,this.particleDestroyedPlugins.length=0,this.particlePositionPlugins.length=0,this.#Ue=this.#Be,this.dispatchEvent(yt.containerStopped)}}updateActualOptions(){let t=!1;for(const e of this.plugins)e.updateActualOptions&&(t=e.updateActualOptions()||t);return t}#He(t){try{if(!this.#Ae&&void 0!==this.#Ee&&t<this.#Ee+o/this.fpsLimit)return void this.draw(!1);if(this.#Ee??=t,function(t,e,i=60,s=!1){t.value=e,t.factor=s?60/i:60*e/o}(this.#ze,t-this.#Ee,this.fpsLimit,this.#Ae),this.addLifeTime(this.#ze.value),this.#Ee=t,this.#ze.value>o)return void this.draw(!1);if(this.canvas.render.drawParticles(this.#ze),!this.alive())return void this.destroy();this.animationStatus&&this.draw(!1)}catch(t){bt().error("error in animation loop",t)}}}});var Os=Object.freeze({__proto__:null,BlendPluginInstance:class{layer=Rt.CanvasSetup;#u;#$e;constructor(t){this.#u=t}drawParticleCleanup(t,e){e.options.blend?.enable&&(t.globalCompositeOperation=e.originalBlendMode??i,e.originalBlendMode=void 0)}drawParticleSetup(t,e){e.options.blend?.enable&&(e.originalBlendMode=t.globalCompositeOperation,t.globalCompositeOperation=e.options.blend.mode)}drawSettingsCleanup(t){this.#$e&&(t.globalCompositeOperation=this.#$e)}drawSettingsSetup(t){const e=t.globalCompositeOperation,i=this.#u.actualOptions.blend;this.#$e=e,t.globalCompositeOperation=i?.enable?i.mode:e}}});function Ds(t,e,i,s,n,a,o){!function(t,e){const i=t.options,s=i.move.path;if(!s.enable)return;const n=t.pathDelay??0;if(t.lastPathTime<=n)return void(t.lastPathTime+=e.value);const a=t.pathGenerator?.generate(t,e);a&&t.velocity.addTo(a);s.clamp&&(t.velocity.x=H(t.velocity.x,-1,1),t.velocity.y=H(t.velocity.y,-1,1));t.lastPathTime-=n}(t,o);const r=t.gravity,c=r?.enable&&r.inverse?-1:1;n&&i&&(t.velocity.x+=n*o.factor/(60*i)),r?.enable&&i&&(t.velocity.y+=c*(r.acceleration*o.factor)/(60*i));const l=t.moveDecay;t.velocity.multTo(l??1);const h=t.velocity.mult(i);r?.enable&&s>0&&(!r.inverse&&h.y>=0&&h.y>=s||r.inverse&&h.y<=0&&h.y<=-s)&&(h.y=c*s,i&&(t.velocity.y=h.y/i));const d=t.options.zIndex,u=(1-t.zIndexFactor)**d.velocityRate;h.multTo(u),h.multTo(a);const{position:p}=t;p.addTo(h),e.vibrate&&(p.x+=Math.sin(p.x*Math.cos(p.y))*a,p.y+=Math.cos(p.y*Math.sin(p.x))*a)}function Ls(t,e){const i=e.options.move.spin;if(!i.enable)return;const s=i.position??{x:50,y:50},n={x:.01*s.x*t.canvas.size.width,y:.01*s.y*t.canvas.size.height},a=e.getPosition(),o=(c=a,l=n,Math.sqrt(X(c,l))),r=q(i.acceleration);var c,l;e.retina.spinAcceleration=r*t.retina.pixelRatio,e.spin={center:n,direction:e.velocity.x>=0?kt.clockwise:kt.counterClockwise,angle:A()*f,radius:o,acceleration:e.retina.spinAcceleration}}var _s=Object.freeze({__proto__:null,MovePluginInstance:class{availablePathGenerators;pathGenerators;#u;#p;constructor(t,e){this.#p=t,this.#u=e,this.availablePathGenerators=new Map,this.pathGenerators=new Map}destroy(){this.availablePathGenerators=new Map,this.pathGenerators=new Map}isEnabled(t){return!t.destroyed&&t.options.move.enable}particleCreated(t){const e=t.options.move,i=e.gravity,s=e.path;if(t.moveDecay=1-q(e.decay),t.pathDelay=q(s.delay.value)*o,s.generator){let e=this.pathGenerators.get(s.generator);e||(e=this.availablePathGenerators.get(s.generator),e&&(this.pathGenerators.set(s.generator,e),e.init())),t.pathGenerator=e}t.gravity={enable:i.enable,acceleration:q(i.acceleration),inverse:i.inverse},Ls(this.#u,t)}particleDestroyed(t){const e=t.pathGenerator;e?.reset(t)}particleUpdate(t,e){const i=t.options.move;if(!i.enable)return;const s=this.#u,n=function(t){const e=t.getModifier("slow");return e?.enabled?e.speedFactor??1:1}(t),o=s.retina.reduceFactor,r=t.retina.moveSpeed,c=t.retina.moveDrift,l=t.size.max,h=r*(i.size?t.getRadius()/l:1)*n*(e.factor||1)*a,d=t.retina.maxSpeed;i.spin.enable?function(t,e,i,s){if(!e.spin)return;const n=e.spin.direction===kt.clockwise,o={x:n?Math.cos:Math.sin,y:n?Math.sin:Math.cos};e.position.x=e.spin.center.x+e.spin.radius*o.x(e.spin.angle)*s,e.position.y=e.spin.center.y+e.spin.radius*o.y(e.spin.angle)*s,e.spin.radius+=e.spin.acceleration*s;const r=Math.max(t.canvas.size.width,t.canvas.size.height),c=r*a;e.spin.radius>c?(e.spin.radius=c,e.spin.acceleration*=-1):e.spin.radius<0&&(e.spin.radius=0,e.spin.acceleration*=-1),e.spin.angle+=.01*i*(1-e.spin.radius/r)}(s,t,h,o):Ds(t,i,h,d,c,o,e),function(t){const e=t.initialPosition,{dx:i,dy:s}=G(e,t.position),n=Math.abs(i),o=Math.abs(s),{maxDistance:r}=t.retina,c=r.horizontal,l=r.vertical;if(!c&&!l)return;if((c&&n>=c||l&&o>=l)&&!t.misplaced)t.misplaced=!!c&&n>c||!!l&&o>l,c&&(t.velocity.x=t.velocity.y*a-t.velocity.x),l&&(t.velocity.y=t.velocity.x*a-t.velocity.y);else if((!c||n<c)&&(!l||o<l)&&t.misplaced)t.misplaced=!1;else if(t.misplaced){const i=t.position,s=t.velocity;c&&(i.x<e.x&&s.x<0||i.x>e.x&&s.x>0)&&(s.x*=-A()),l&&(i.y<e.y&&s.y<0||i.y>e.y&&s.y>0)&&(s.y*=-A())}}(t)}preInit(){return this.#Ve()}redrawInit(){return this.#Ve()}update(){for(const t of this.pathGenerators.values())t.update()}async#Ve(){const t=await(this.#p.getPathGenerators?.(this.#u,!0));if(t){this.availablePathGenerators=t,this.pathGenerators=new Map;for(const t of this.pathGenerators.values())t.init()}}}});class Es{#qe=!0;#We;#u;#vt;#Ne;#je;constructor(t,e){this.#u=t,this.#We=[],this.#Ne=e,this.#je=new Map,this.#vt={mouseDown:()=>{this.#Ge()},mouseLeave:()=>{this.#Xe()},mouseMove:t=>{this.#Ye(t)},mouseUp:t=>{this.#Qe(t)},touchStart:t=>{this.#Ke(t)},touchMove:t=>{this.#Ye(t)},touchEnd:t=>{this.#Ze(t)},touchCancel:t=>{this.#Ze(t)},touchEndClick:t=>{this.#Je(t)},visibilityChange:()=>{this.#Pt()}}}addListeners(){this.#Mt(!0)}init(){this.#We.length=0;for(const t of this.#u.plugins.filter(t=>!!t.clickPositionValid))this.#We.push(t)}removeListeners(){this.#Mt(!1)}#ti(t){const e=this.#u,i=this.#Ne,s=e.actualOptions;if(this.#qe){const t=i.interactivityData.mouse,e=t.position;if(!e)return;t.clickPosition={...e},t.clickTime=performance.now();const n=s.interactivity?.events.onClick;if(!n?.mode)return;rt(n.mode,t=>{i.handleClickMode(t)})}"touchend"===t.type&&setTimeout(()=>{this.#Xe()},500)}#Pt(){this.#Xe()}#ei(t){const e=this.#vt,i=this.#u,s=this.#Ne,n=i.actualOptions,a=s.interactivityData.element;if(!a)return;const o=a,r=i.canvas;r.setPointerEvents(o===r.domElement?"initial":"none"),(!t||n.interactivity?.events.onHover.enable||n.interactivity?.events.onClick.enable)&&(ut(a,Ki,e.mouseMove,t),ut(a,Zi,e.touchStart,t),ut(a,ts,e.touchMove,t),t?n.interactivity?.events.onClick.enable?(ut(a,Ji,e.touchEndClick,t),ut(a,Yi,e.mouseUp,t),ut(a,Xi,e.mouseDown,t)):ut(a,Ji,e.touchEnd,t):(ut(a,Ji,e.touchEndClick,t),ut(a,Yi,e.mouseUp,t),ut(a,Xi,e.mouseDown,t),ut(a,Ji,e.touchEnd,t)),ut(a,Qi,e.mouseLeave,t),ut(a,es,e.touchCancel,t))}#Mt(t){const e=this.#vt,i=this.#u,n=this.#Ne,a=i.actualOptions,o=a.interactivity?.detectsOn,r=i.canvas.domElement;o===Ui.window?n.interactivityData.element=et():o===Ui.parent&&r?n.interactivityData.element=r.parentElement??r.parentNode:n.interactivityData.element=r,this.#ei(t),ut(document,s,e.visibilityChange,t,!1)}#Ge(){const{interactivityData:t}=this.#Ne,{mouse:e}=t;e.clicking=!0,e.downPosition=e.position}#Qe(t){const e=this.#u,i=this.#Ne,s=e.actualOptions,{mouse:n}=i.interactivityData;n.inside=!0;let a=!1;const o=n.position;if(o&&s.interactivity?.events.onClick.enable){for(const t of this.#We)if(a=t.clickPositionValid?.(o)??!1,a)break;a||this.#ti(t),n.clicking=!1}}#Xe(){const{interactivityData:t}=this.#Ne,{mouse:e}=t;delete e.position,delete e.clickPosition,delete e.downPosition,t.status=Qi,e.inside=!1,e.clicking=!1}#Ye(t){const e=this.#u,i=this.#Ne,s=e.actualOptions,n=i.interactivityData,a=e.canvas.domElement;if(!n.element)return;let o;if(n.mouse.inside=!0,t.type.startsWith("pointer")){this.#qe=!0;const e=t;if(n.element===et()){if(a){const t=a.getBoundingClientRect();o={x:e.clientX-t.left,y:e.clientY-t.top}}}else if(s.interactivity?.detectsOn===Ui.parent){const t=e.target,i=e.currentTarget;if(a){const s=t.getBoundingClientRect(),n=i.getBoundingClientRect(),r=a.getBoundingClientRect();o={x:e.offsetX+2*s.left-(n.left+r.left),y:e.offsetY+2*s.top-(n.top+r.top)}}else o={x:e.offsetX,y:e.offsetY}}else e.target===a&&(o={x:e.offsetX,y:e.offsetY})}else if(this.#qe="touchmove"!==t.type,a){const e=t,i=e.touches[e.touches.length-1],s=a.getBoundingClientRect();if(!i)return;o={x:i.clientX-s.left,y:i.clientY-s.top}}const r=e.retina.pixelRatio;o&&(o.x*=r,o.y*=r),n.mouse.position=o,n.status=Ki}#Ze(t){const e=t,i=Array.from(e.changedTouches);for(const t of i)this.#je.delete(t.identifier);this.#Xe()}#Je(t){const e=t,i=Array.from(e.changedTouches);for(const t of i)this.#je.delete(t.identifier);this.#Qe(t)}#Ke(t){const e=t,i=Array.from(e.changedTouches);for(const t of i)this.#je.set(t.identifier,performance.now());this.#Ye(t)}}class Ts{interactivityData;#ii;#u;#De;#si;#ni;#ai;#oi;#p;constructor(t,e){this.#u=e,this.#p=t,this.#ni=[],this.#si=[],this.#oi=[],this.#ii=new Map,this.#De=new Es(e,this),this.interactivityData={mouse:{clicking:!1,inside:!1}},this.#ai=function(t){if("undefined"!=typeof IntersectionObserver)return new IntersectionObserver(t)}(t=>{this.#ri(t)})}addClickHandler(t){const e=this.#u,i=this.interactivityData;if(e.destroyed)return;const s=i.element;if(!s)return;const n=(i,s,n)=>{if(e.destroyed)return;const a=e.retina.pixelRatio,o={x:s.x*a,y:s.y*a},r=e.particles.grid.queryCircle(o,n*a);t(i,r)};let a=!1,o=!1;this.#ii.set("click",t=>{if(e.destroyed)return;const i=t,s={x:i.offsetX,y:i.offsetY};n(t,s,1)}),this.#ii.set(Zi,()=>{e.destroyed||(a=!0,o=!1)}),this.#ii.set(ts,()=>{e.destroyed||(o=!0)}),this.#ii.set(Ji,t=>{if(!e.destroyed){if(a&&!o){const i=t,s=i.touches[i.touches.length-1];if(!s)return;const a=e.canvas.domElement,o=a?a.getBoundingClientRect():void 0,r={x:s.clientX-(o?o.left:0),y:s.clientY-(o?o.top:0)};n(t,r,Math.max(s.radiusX,s.radiusY))}a=!1,o=!1}}),this.#ii.set(es,()=>{e.destroyed||(a=!1,o=!1)});for(const[t,e]of this.#ii)s.addEventListener(t,e)}addListeners(){this.#De.addListeners()}clearClickHandlers(){const t=this.#u,e=this.interactivityData;if(!t.destroyed){for(const[t,i]of this.#ii)e.element?.removeEventListener(t,i);this.#ii.clear()}}externalInteract(t){for(const e of this.#si){const i=this.interactivityData;e.isEnabled(i)&&e.interact(i,t)}}handleClickMode(t){if(this.#u.destroyed)return;const e=this.interactivityData;for(const i of this.#si)i.handleClickMode?.(t,e)}init(){this.#De.init();for(const t of this.#ni){switch(t.type){case Hi.external:this.#si.push(t);break;case Hi.particles:this.#oi.push(t)}t.init()}}async initInteractors(){const t=await(this.#p.getInteractors?.(this.#u,!0));t&&(this.#ni=t,this.#si=[],this.#oi=[])}particlesInteract(t,e){const i=this.interactivityData;for(const i of this.#si)i.clear(t,e);for(const s of this.#oi)s.isEnabled(t,i)&&s.interact(t,i,e)}removeListeners(){this.#De.removeListeners()}reset(t){const e=this.interactivityData;for(const i of this.#si)i.isEnabled(e)&&i.reset(e,t);for(const i of this.#oi)i.isEnabled(t,e)&&i.reset(e,t)}startObserving(){const t=this.interactivityData;t.element instanceof HTMLElement&&this.#ai&&this.#ai.observe(t.element)}stopObserving(){const t=this.interactivityData;t.element instanceof HTMLElement&&this.#ai&&this.#ai.unobserve(t.element)}updateMaxDistance(){let t=0;for(const e of this.#ni)e.maxDistance>t&&(t=e.maxDistance);const e=this.#u;e.particles.grid.setCellSize(t*e.retina.pixelRatio)}#ri(t){const e=this.#u;if(!e.destroyed&&e.actualOptions.pauseOnOutsideViewport)for(const i of t)i.target===this.interactivityData.element&&(i.isIntersecting?e.play():e.pause())}}var Rs=Object.freeze({__proto__:null,InteractivityPluginInstance:class{interactionManager;#u;#p;constructor(t,e){this.#u=e,this.#p=t,this.interactionManager=new Ts(t,e),this.#u.addClickHandler=t=>{this.interactionManager.addClickHandler(t)}}addClickHandler(t){this.interactionManager.addClickHandler(t)}clearClickHandlers(){this.interactionManager.clearClickHandlers()}destroy(){this.clearClickHandlers(),this.#p.interactors?.delete(this.#u)}particleCreated(t){const e=t,i=new Ni(this.#p,this.#u);i.load(this.#u.actualOptions.interactivity),i.load(e.options.interactivity),e.interactivity=i}particleReset(t){this.interactionManager.reset(t)}postParticleUpdate(t,e){this.interactionManager.particlesInteract(t,e)}postUpdate(t){this.interactionManager.externalInteract(t),this.interactionManager.updateMaxDistance()}async preInit(){await this.interactionManager.initInteractors(),this.interactionManager.init()}async redrawInit(){await this.interactionManager.initInteractors(),this.interactionManager.init()}start(){return this.interactionManager.addListeners(),this.interactionManager.startObserving(),Promise.resolve()}stop(){this.interactionManager.removeListeners(),this.interactionManager.stopObserving()}}});function Bs(t,e){const i=(s=t.map(t=>t.id),[...s].sort((t,e)=>t-e).join("_"));var s;let n=e.get(i);return void 0===n&&(n=A(),e.set(i,n)),n}var Fs=Object.freeze({__proto__:null,LinkInstance:class{#ci=new Map;#u;#li;#p;constructor(t,e){this.#p=t,this.#u=e,this.#li={links:new Map,triangles:new Map}}drawParticle(t,e){const{links:i,options:s}=e;if(!i?.length||!s.links)return;const n=s.links,o=e.retina.linksWidth??0,c=e.getPosition(),l=e.options.twinkle?.links,h=n.triangles.enable,d=h?new Set(i.map(t=>t.destination.id)):null,u=t.globalAlpha;let p="",f=-1,g=-1,y=!1;const m=()=>{y&&(t.stroke(),y=!1)};for(const u of i){if(n.frequency<1&&this.#hi(e,u.destination)>n.frequency)continue;const i=u.destination.getPosition();if(h&&!u.isWarped&&d&&(m(),this.#di(s,e,u,d,c,i,t)),u.opacity<=0||o<=0)continue;if(!n.enable)continue;let v=u.opacity,w=u.color;const b=l?.enable&&A()<l.frequency?Re(this.#p,l.color):void 0;if(l&&b&&(w=b,v=q(l.opacity)),!w){const t=void 0!==n.id?this.#u.particles.linksColors.get(n.id):this.#u.particles.linksColor;w=We(e,u.destination,t)}if(!w)continue;const P=this.#ui(w);if(P===p&&o===f&&v===g||(m(),t.strokeStyle=P,t.lineWidth=o,t.globalAlpha=v,p=P,f=o,g=v,t.beginPath(),y=!0),u.isWarped){const e=this.#u.canvas.size,s=i.x-c.x,n=i.y-c.y;let o=r.x,l=r.y;Math.abs(s)>e.width*a&&(o=s>0?-e.width:e.width),Math.abs(n)>e.height*a&&(l=n>0?-e.height:e.height),t.moveTo(c.x,c.y),t.lineTo(i.x+o,i.y+l),t.moveTo(c.x-o,c.y-l),t.lineTo(i.x,i.y)}else t.moveTo(c.x,c.y),t.lineTo(i.x,i.y)}m(),t.globalAlpha=u}init(){return this.#li.links.clear(),this.#li.triangles.clear(),this.#ci.clear(),Promise.resolve()}particleCreated(t){if(t.links=[],!t.options.links)return;t.linksDistance=t.options.links.distance,t.linksWidth=t.options.links.width;const e=this.#u.retina.pixelRatio;t.retina.linksDistance=t.linksDistance*e,t.retina.linksWidth=t.linksWidth*e}particleDestroyed(t){t.links=[]}#di(t,e,i,s,n,o,r){const c=i.destination,l=t.links?.triangles;if(!l?.enable||!c.options.links?.triangles.enable)return;const h=c.links;if(h?.length)for(const d of h){if(d.isWarped||this.#hi(c,d.destination)>c.options.links.frequency||!s.has(d.destination.id))continue;const h=d.destination;if(this.#pi(e,c,h)>(t.links?.triangles.frequency??0))continue;const u=l.opacity??(i.opacity+d.opacity)*a,p=Re(this.#p,l.color)??i.color;if(!p||u<=0)continue;const f=h.getPosition();r.save(),r.fillStyle=this.#ui(p),r.globalAlpha=u,r.beginPath(),r.moveTo(n.x,n.y),r.lineTo(o.x,o.y),r.lineTo(f.x,f.y),r.closePath(),r.fill(),r.restore()}}#ui(t){const e=`${t.r},${t.g},${t.b}-${this.#u.hdr}-${this.#u.peakNits}-${this.#u.hdrMode}`;let i=this.#ci.get(e);return i||(i=Ve(t,this.#u.hdr,void 0,this.#u.peakNits,this.#u.hdrMode),this.#ci.set(e,i)),i}#hi(t,e){return Bs([t,e],this.#li.links)}#pi(t,e,i){return Bs([t,e,i],this.#li.triangles)}}});t.loadTrianglesPreset=ds,t.tsParticles=Qe}),Object.assign(globalThis.window||globalThis,{loadTrianglesPreset:(globalThis.__tsParticlesInternals.presets.triangles||{}).loadTrianglesPreset}),delete(globalThis.window||globalThis).tsparticlesInternalExports;
|
|
1
|
+
!function(t){t.__tsParticlesInternals=t.__tsParticlesInternals||{},t.__tsParticlesInternals.bundles=t.__tsParticlesInternals.bundles||{},t.__tsParticlesInternals.effects=t.__tsParticlesInternals.effects||{},t.__tsParticlesInternals.engine=t.__tsParticlesInternals.engine||{},t.__tsParticlesInternals.interactions=t.__tsParticlesInternals.interactions||{},t.__tsParticlesInternals.palettes=t.__tsParticlesInternals.palettes||{},t.__tsParticlesInternals.paths=t.__tsParticlesInternals.paths||{},t.__tsParticlesInternals.plugins=t.__tsParticlesInternals.plugins||{},t.__tsParticlesInternals.plugins=t.__tsParticlesInternals.plugins||{},t.__tsParticlesInternals.plugins.emittersShapes=t.__tsParticlesInternals.plugins.emittersShapes||{},t.__tsParticlesInternals.presets=t.__tsParticlesInternals.presets||{},t.__tsParticlesInternals.shapes=t.__tsParticlesInternals.shapes||{},t.__tsParticlesInternals.updaters=t.__tsParticlesInternals.updaters||{},t.__tsParticlesInternals.utils=t.__tsParticlesInternals.utils||{},t.__tsParticlesInternals.canvas=t.__tsParticlesInternals.canvas||{},t.__tsParticlesInternals.canvas=t.__tsParticlesInternals.canvas||{},t.__tsParticlesInternals.canvas.utils=t.__tsParticlesInternals.canvas.utils||{},t.__tsParticlesInternals.path=t.__tsParticlesInternals.path||{},t.__tsParticlesInternals.path=t.__tsParticlesInternals.path||{},t.__tsParticlesInternals.path.utils=t.__tsParticlesInternals.path.utils||{};var e="undefined"!=typeof Proxy?function(t){return new Proxy(t,{get:function(t,e){return e in t||(t[e]={}),t[e]}})}:function(t){return t};t.__tsParticlesInternals.bundles=e(t.__tsParticlesInternals.bundles),t.__tsParticlesInternals.effects=e(t.__tsParticlesInternals.effects),t.__tsParticlesInternals.interactions=e(t.__tsParticlesInternals.interactions),t.__tsParticlesInternals.palettes=e(t.__tsParticlesInternals.palettes),t.__tsParticlesInternals.paths=e(t.__tsParticlesInternals.paths),t.__tsParticlesInternals.plugins=e(t.__tsParticlesInternals.plugins),t.__tsParticlesInternals.plugins.emittersShapes=e(t.__tsParticlesInternals.plugins.emittersShapes),t.__tsParticlesInternals.presets=e(t.__tsParticlesInternals.presets),t.__tsParticlesInternals.shapes=e(t.__tsParticlesInternals.shapes),t.__tsParticlesInternals.updaters=e(t.__tsParticlesInternals.updaters),t.__tsParticlesInternals.utils=e(t.__tsParticlesInternals.utils),t.__tsParticlesInternals.canvas=e(t.__tsParticlesInternals.canvas),t.__tsParticlesInternals.path=e(t.__tsParticlesInternals.path)}("undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:this),function(t){t.__tsParticlesInternals=t.__tsParticlesInternals||{},t.__tsParticlesInternals.presets=t.__tsParticlesInternals.presets||{},function(t){"use strict";const e=/^\[tsParticles Error (TSP-\d+)\]\s*/,i=t=>(...e)=>{t(...e)},s={debug:i(console.debug),error:(t,...i)=>{if("string"==typeof t){const s=e.exec(t);if(s?.[1])return void console.error(`tsParticles - ${s[1]} - ${t.slice(s[0].length)}`,...i)}console.error(`tsParticles - Error - ${t}`,...i)},info:i(console.info),log:i(console.log),trace:i(console.trace),verbose:i(console.log),warning:i(console.warn)};function n(){return s}var a;!function(t){t.bottom="bottom",t.bottomLeft="bottom-left",t.bottomRight="bottom-right",t.left="left",t.none="none",t.right="right",t.top="top",t.topLeft="top-left",t.topRight="top-right",t.outside="outside",t.inside="inside"}(a||(a={}));const o="generated",r="100%",c="source-over",l="visibilitychange",h=100,d=.5,u=1e3,p={x:0,y:0,z:0},f=1,g=0,y=0,m=1,v="random",w="mid",P=2*Math.PI,b="true",x="false",M="canvas",k=255,z=360,C=100,S=100,I=.25,O=400;function L(t){return"z"in t?t.z:p.z}class D{x;y;z;constructor(t=p.x,e=p.y,i=p.z){this.x=t,this.y=e,this.z=i}static get origin(){return D.create(p.x,p.y,p.z)}get angle(){return Math.atan2(this.y,this.x)}set angle(t){this.#t(t,this.length)}get length(){return Math.sqrt(this.getLengthSq())}set length(t){this.#t(this.angle,t)}static clone(t){return D.create(t.x,t.y,L(t))}static create(t,e,i){return"number"==typeof t?new D(t,e??p.y,i??p.z):new D(t.x,t.y,L(t))}add(t){return D.create(this.x+t.x,this.y+t.y,this.z+L(t))}addTo(t){this.x+=t.x,this.y+=t.y,this.z+=L(t)}copy(){return D.clone(this)}div(t){return D.create(this.x/t,this.y/t,this.z/t)}getLengthSq(){return this.x**2+this.y**2}mult(t){return D.create(this.x*t,this.y*t,this.z*t)}multTo(t){this.x*=t,this.y*=t,this.z*=t}normalize(){const t=this.length;0!=t&&this.multTo(1/t)}rotate(t){return D.create(this.x*Math.cos(t)-this.y*Math.sin(t),this.x*Math.sin(t)+this.y*Math.cos(t),p.z)}setTo(t){this.x=t.x,this.y=t.y,this.z=L(t)}sub(t){return D.create(this.x-t.x,this.y-t.y,this.z-L(t))}subFrom(t){this.x-=t.x,this.y-=t.y,this.z-=L(t)}#t(t,e){this.x=Math.cos(t)*e,this.y=Math.sin(t)*e}}class _ extends D{constructor(t=p.x,e=p.y){super(t,e,p.z)}static get origin(){return _.create(p.x,p.y)}static clone(t){return _.create(t.x,t.y)}static create(t,e){return"number"==typeof t?new _(t,e??p.y):new _(t.x,t.y)}}function E(t){return"boolean"==typeof t}function T(t){return"string"==typeof t}function R(t){return"number"==typeof t}function B(t,e){return Object.values(t).some(t=>t===e)}function F(t,e,i){return B(t,e)?e:i}function A(t){return"object"==typeof t&&null!==t}function U(t){return Array.isArray(t)}function $(t){return null==t}const H=Math.PI/180;let q=Math.random;const V=t=>requestAnimationFrame(t),W=t=>{cancelAnimationFrame(t)};function N(){return G(q(),0,1-Number.EPSILON)}function j(t,e){return N()*(e-t)+t}function G(t,e,i){return Math.min(Math.max(t,e),i)}function X(t,e,i,s){return Math.floor((t*i+e*s)/(i+s))}function Y(t){const e=Z(t);let i=K(t);return e===i&&(i=0),j(i,e)}function Q(t){return R(t)?t:Y(t)}function K(t){return R(t)?t:t.min}function Z(t){return R(t)?t:t.max}function J(t,e){if(t===e||void 0===e&&R(t))return t;const i=K(t),s=Z(t);return void 0!==e?{min:Math.min(i,e),max:Math.max(s,e)}:J(i,s)}function tt(t,e){const i=t.x-e.x,s=t.y-e.y;return{dx:i,dy:s,distance:Math.hypot(i,s)}}function et(t,e){const i=t.x-e.x,s=t.y-e.y;return i*i+s*s}function it(t){return t*H}function st(t){const{position:e,size:i}=t;return{x:e?.x??N()*i.width,y:e?.y??N()*i.height}}function nt(t){return t?t.endsWith("%")?Number.parseFloat(t)/h:Number.parseFloat(t):1}const at="TSP-1001",ot="TSP-1002",rt="TSP-1003",ct="TSP-1101",lt="TSP-1102",ht="TSP-1201",dt="TSP-1202",ut="TSP-1203";function pt(t,...e){return`[tsParticles Error ${t}] https://particles.js.org/errors/#${t}`}var ft,gt;function yt(t){return"__proto__"===t||"constructor"===t||"prototype"===t}function mt(){return globalThis.document}function vt(t){if("undefined"!=typeof matchMedia)return matchMedia(t)}function wt(t,e,i=!0){return t[void 0!==e&&i?e%t.length:Math.floor(N()*t.length)]}function Pt(t,e,i,s,n){return function(t,e,i,s){let n=!0;s&&s!==ft.bottom||(n=t.top<e.height+i.x);!n||s&&s!==ft.left||(n=t.right>i.x);!n||s&&s!==ft.right||(n=t.left<e.width+i.y);!n||s&&s!==ft.top||(n=t.bottom>i.y);return n}(bt(t,s??0),e,i,n)}function bt(t,e){return{bottom:t.y+e,left:t.x-e,right:t.x+e,top:t.y-e}}function xt(t,...e){for(const i of e){if($(i))continue;if(!A(i)){t=i;continue}Array.isArray(i)?Array.isArray(t)||(t=[]):A(t)&&!Array.isArray(t)||(t=Object.create(null));const e=Object.keys(i);if(!e.some(t=>{const e=i[t];return A(e)||Array.isArray(e)})){const s=i,n=t;for(const t of e){if(yt(t))continue;const e=s[t];void 0!==e&&(n[t]=e)}continue}for(const s of e){if(yt(s))continue;const e=t,n=i[s];e[s]=Array.isArray(n)?n.map(t=>xt(void 0,t)):xt(e[s],n)}}return t}function Mt(t,e){return U(t)?t.map((t,i)=>e(t,i)):e(t,0)}function kt(t,e,i){return U(t)?wt(t,e,i):t}function zt(t,e){return function(t,e){if(t.mode!==gt.percent){const{mode:e,...i}=t;return i}return"x"in t?{x:t.x/h*e.width,y:t.y/h*e.height}:{width:t.width/h*e.width,height:t.height/h*e.height}}(t,e)}let Ct,St;function It(t,e,i,s,n){if(s){let s={passive:!0};E(n)?s.capture=n:void 0!==n&&(s=n),t.addEventListener(e,i,s)}else{const s=n;t.removeEventListener(e,i,s)}}async function Ot(t,e){return await Promise.all([...e.values()].map(e=>e(t)))}async function Lt(t,e){const i=await Promise.all([...e.entries()].map(([e,i])=>i(t).then(t=>[e,t])));return new Map(i)}async function Dt(t){const e=kt(t.url,t.index);if(!e)return t.fallback;try{const t=await fetch(e);if(t.ok){const e=await t.json();if(function(t){if(U(t))return t.every(t=>A(t)&&!U(t));return A(t)&&!U(t)}(e))return e;n().error("invalid configuration data while retrieving config file")}else n().error(`${t.status.toString()} while retrieving config file`)}catch(t){n().error(`error while retrieving config file: ${t}`)}return t.fallback}!function(t){t.bottom="bottom",t.left="left",t.right="right",t.top="top"}(ft||(ft={})),function(t){t.precise="precise",t.percent="percent"}(gt||(gt={}));class _t{#e;constructor(){this.#e=new Map}addEventListener(t,e){this.removeEventListener(t,e);const i=this.#e.get(t);this.#e.set(t,i?[...i,e]:[e])}dispatchEvent(t,e){const i=this.#e.get(t);i?.forEach(t=>{t(e)})}hasEventListener(t){return!!this.#e.get(t)}removeAllEventListeners(t){t?this.#e.delete(t):this.#e=new Map}removeEventListener(t,e){const i=this.#e.get(t);if(!i)return;const s=i.length,n=i.indexOf(e);n<0||(1===s?this.#e.delete(t):this.#e.set(t,[...i.slice(0,n),...i.slice(n+1)]))}}var Et,Tt,Rt,Bt,Ft,At,Ut,$t,Ht,qt,Vt,Wt,Nt,jt;!function(t){t.configAdded="configAdded",t.containerInit="containerInit",t.particlesSetup="particlesSetup",t.containerStarted="containerStarted",t.containerStopped="containerStopped",t.containerDestroyed="containerDestroyed",t.containerPaused="containerPaused",t.containerPlay="containerPlay",t.containerBuilt="containerBuilt",t.particleAdded="particleAdded",t.particleDestroyed="particleDestroyed",t.particleRemoved="particleRemoved"}(Et||(Et={}));class Gt{colorManagers=new Map;easingFunctions=new Map;initializers={effects:new Map,shapes:new Map,updaters:new Map};palettes=new Map;plugins=[];presets=new Map;#i=new Set;#s=new Map;#n;#a=new Set;#o=!1;#r=!1;#c=new Set;constructor(t){this.#n=t}get configs(){const t={};for(const[e,i]of this.#s)t[e]=i;return t}get initialized(){return this.#o}addColorManager(t,e){this.#o||this.colorManagers.set(t,e)}addConfig(t){if(this.#o)return;const e=t.key??t.name??"default";this.#s.set(e,t),this.#n.dispatchEvent(Et.configAdded,{data:{name:e,config:t}})}addEasing(t,e){this.#o||this.easingFunctions.get(t)||this.easingFunctions.set(t,e)}addEffect(t,e){this.#o||this.initializers.effects.set(t,e)}addPalette(t,e){this.#o||this.palettes.set(t,e)}addParticleUpdater(t,e){this.#o||this.initializers.updaters.set(t,e)}addPlugin(t){this.#o||this.getPlugin(t.id)||this.plugins.push(t)}addPreset(t,e,i=!1){this.#o||!i&&this.getPreset(t)||this.presets.set(t,e)}addShape(t,e){if(!this.#o)for(const i of t)this.initializers.shapes.set(i,e)}getEasing(t){return this.easingFunctions.get(t)??(t=>t)}getPalette(t){return this.palettes.get(t)}getPlugin(t){return this.plugins.find(e=>e.id===t)}getPreset(t){return this.presets.get(t)}async init(){if(!this.#o&&!this.#r){this.#r=!0,this.#a=new Set,this.#i=new Set(this.#c);try{for(const t of this.#i)await this.#l(t,this.#a,this.#i)}finally{this.#c.clear(),this.#r=!1,this.#o=!0}}}async register(...t){if(this.#o)throw new Error(pt(rt));for(const e of t)this.#r?await this.#l(e,this.#a,this.#i):this.#c.add(e)}async#l(t,e,i){e.has(t)||(e.add(t),i.add(t),await t(this.#n))}}class Xt{pluginManager=new Gt(this);#h=[];#d=new _t;#o=!1;get items(){return this.#h}get version(){return"4.5.1"}addEventListener(t,e){this.#d.addEventListener(t,e)}checkVersion(t){if(this.version!==t)throw new Error(pt(at,this.version))}dispatchEvent(t,e){this.#d.dispatchEvent(t,e)}async init(){this.#o||(await this.pluginManager.init(),this.#o=!0)}item(t){const e=this.items,i=e[t];if(!i?.destroyed)return i;e.splice(t,1)}async load(t){let e;await this.init(),"undefined"!=typeof HTMLElement&&t.element instanceof HTMLElement&&(e=t.element);const{Container:i}=await Promise.resolve().then(function(){return qs}),s=t.id??e?.id??`tsparticles${Math.floor(1e4*N()).toString()}`,{index:n,url:a}=t,c=kt(a?await Dt({fallback:t.options,url:a,index:n}):t.options,n),{items:l}=this,h=l.findIndex(t=>t.id.description===s),d=new i({dispatchCallback:(t,e)=>{this.dispatchEvent(t,e)},id:s,onDestroy:t=>{if(!t)return;const e=this.items,i=e.indexOf(d);i>=0&&e.splice(i,1)},pluginManager:this.pluginManager,sourceOptions:c});if(h>=0){const t=this.item(h),e=t?1:0;t&&!t.destroyed&&t.destroy(!1),l.splice(h,e,d)}else l.push(d);const u="undefined"!=typeof OffscreenCanvas&&t.element instanceof OffscreenCanvas?t.element:function(t){let e;const i=mt();if(t instanceof HTMLCanvasElement||t.tagName.toLowerCase()===M)e=t,e.dataset[o]??=x,e.dataset[o]===b&&(e.style.width||=r,e.style.height||=r,e.style.pointerEvents="none",e.style.setProperty("pointer-events","none"));else{const s=t.getElementsByTagName(M).item(0);s?(e=s,e.dataset[o]=x):(e=i.createElement(M),e.dataset[o]=b,t.appendChild(e)),e.style.width||=r,e.style.height||=r,e.style.pointerEvents="none",e.style.setProperty("pointer-events","none")}return e}(function(t,e){const i=mt();let s=e??i.getElementById(t);return s||(s=i.createElement("canvas"),s.id=t,s.dataset[o]=b,i.body.append(s),s)}(s,e));return d.canvas.loadCanvas(u),await d.start(),d}async refresh(t=!0){t&&await Promise.all(this.items.map(t=>t.refresh()))}removeEventListener(t,e){this.#d.removeEventListener(t,e)}}!function(t){t.circle="circle",t.rectangle="rectangle"}(Tt||(Tt={}));class Yt{position;type;constructor(t,e,i){this.position={x:t,y:e},this.type=i}_resetPosition(t,e){this.position.x=t,this.position.y=e}}class Qt extends Yt{radius;constructor(t,e,i){super(t,e,Tt.circle),this.radius=i}contains(t){return e=t,i=this.position,s=this.radius,et(e,i)<=s*s;var e,i,s}intersects(t){const e=this.position,i=t.position,s=this.radius,n=Math.abs(i.x-e.x),a=Math.abs(i.y-e.y);if(t instanceof Qt||t.type===Tt.circle){return s+t.radius>Math.hypot(n,a)}if(t instanceof Kt||t.type===Tt.rectangle){const e=t,{width:i,height:o}=e.size;return Math.pow(n-i,2)+Math.pow(a-o,2)<=s**2||n<=s+i&&a<=s+o||n<=i||a<=o}return!1}reset(t,e,i){return this._resetPosition(t,e),this.radius=i,this}}class Kt extends Yt{size;constructor(t,e,i,s){super(t,e,Tt.rectangle),this.size={height:s,width:i}}contains(t){const e=this.size.width,i=this.size.height,s=this.position;return t.x>=s.x&&t.x<=s.x+e&&t.y>=s.y&&t.y<=s.y+i}intersects(t){if(t instanceof Qt)return t.intersects(this);if(!(t instanceof Kt))return!1;const e=this.size.width,i=this.size.height,s=this.position,n=t.position,a=t.size,o=a.width,r=a.height;return n.x<s.x+e&&n.x+o>s.x&&n.y<s.y+i&&n.y+r>s.y}reset(t,e,i,s){return this._resetPosition(t,e),this.size.width=i,this.size.height=s,this}}function Zt(t,e,i){void 0!==i&&(t[e]=i)}function Jt(t,e,i){void 0!==i&&(t[e]=J(i))}function te(t,e,i,s){if(void 0!==i){const n=t;n[e]??=s(),n[e].load(i)}}function ee(t,e,i,...s){const n=t;n[e]??=new i;const a=n[e];for(const t of s)a.load(t?.[e])}!function(t){t.clockwise="clockwise",t.counterClockwise="counter-clockwise",t.random="random"}(Rt||(Rt={})),function(t){t.auto="auto",t.increase="increase",t.decrease="decrease",t.random="random"}(Bt||(Bt={})),function(t){t.standard="standard",t.natural="natural",t.vivid="vivid",t.cinematic="cinematic",t.dynamic="dynamic"}(Ft||(Ft={})),function(t){t.delete="delete",t.wait="wait"}(At||(At={})),function(t){t.bounce="bounce",t.none="none",t.out="out",t.destroy="destroy",t.split="split"}(Ut||(Ut={})),function(t){t.darken="darken",t.enlighten="enlighten"}($t||($t={})),function(t){t.none="none",t.max="max",t.min="min"}(Ht||(Ht={})),function(t){t.linear="linear",t.radial="radial",t.random="random"}(qt||(qt={})),function(t){t.normal="normal",t.inside="inside",t.outside="outside"}(Vt||(Vt={})),function(t){t.max="max",t.min="min",t.random="random"}(Wt||(Wt={})),function(t){t.increasing="increasing",t.decreasing="decreasing"}(Nt||(Nt={})),function(t){t[t.BackgroundElement=0]="BackgroundElement",t[t.BackgroundDraw=1]="BackgroundDraw",t[t.BackgroundMask=2]="BackgroundMask",t[t.CanvasSetup=3]="CanvasSetup",t[t.PluginContent=4]="PluginContent",t[t.Particles=5]="Particles",t[t.CanvasCleanup=6]="CanvasCleanup",t[t.Foreground=7]="Foreground"}(jt||(jt={}));class ie{load(t){$(t)||this.doLoad(t)}}function se(t,...e){for(const i of e)t.load(i)}class ne extends ie{count=0;decay=0;delay=0;enable=!1;speed=1;sync=!1;doLoad(t){Jt(this,"count",t.count),Zt(this,"enable",t.enable),Jt(this,"speed",t.speed),Jt(this,"decay",t.decay),Jt(this,"delay",t.delay),Zt(this,"sync",t.sync)}}class ae extends ne{mode=Bt.auto;startValue=Wt.random;doLoad(t){super.doLoad(t),Zt(this,"mode",t.mode),Zt(this,"startValue",t.startValue)}}class oe extends ne{max;min;offset=0;sync=!0;constructor(t,e){super(),this.min=t,this.max=e}doLoad(t){super.doLoad(t),Zt(this,"max",t.max),Zt(this,"min",t.min),Jt(this,"offset",t.offset)}}class re extends ie{h=new oe(0,z);l=new oe(0,S);s=new oe(0,C);doLoad(t){this.h.load(t.h),this.s.load(t.s),this.l.load(t.l)}}class ce extends ie{value="";static create(t,e){const i=new ce;return i.load(t),void 0!==e&&(T(e)||U(e)?i.load({value:e}):i.load(e)),i}doLoad(t){$(t.value)||(this.value=t.value)}}class le extends ce{animation=new re;static create(t,e){const i=new le;return i.load(t),void 0!==e&&(T(e)||U(e)?i.load({value:e}):i.load(e)),i}doLoad(t){super.doLoad(t);const e=t.animation;void 0!==e&&(void 0===e.enable?this.animation.load(t.animation):this.animation.h.load(e))}}class he extends ie{color;draw;element;image="";opacity=1;position="";repeat="";size="";constructor(){super(),this.color=new ce,this.color.value=""}doLoad(t){void 0!==t.color&&(this.color=ce.create(this.color,t.color)),Zt(this,"element",t.element),Zt(this,"draw",t.draw),Zt(this,"image",t.image),Zt(this,"position",t.position),Zt(this,"repeat",t.repeat),Zt(this,"size",t.size),Zt(this,"opacity",t.opacity)}}class de extends ie{enable=!0;zIndex=0;doLoad(t){Zt(this,"enable",t.enable),Zt(this,"zIndex",t.zIndex)}}class ue extends ie{enable=!0;mode=Ft.standard;peakNits=400;doLoad(t){if(void 0!==t.enable&&!E(t.enable))throw new Error(pt(ht,String(t.enable)));if(void 0!==t.mode&&!B(Ft,t.mode))throw new Error(pt(dt,Object.values(Ft).join(", "),(e=t.mode,String(e))));var e;if(void 0!==t.peakNits&&(!R(t.peakNits)||!Number.isFinite(t.peakNits)||t.peakNits<=0))throw new Error(pt(ut,String(t.peakNits)));Zt(this,"enable",t.enable),Zt(this,"mode",t.mode),Zt(this,"peakNits",t.peakNits)}}class pe extends ie{delay=.5;enable=!0;doLoad(t){Zt(this,"delay",t.delay),Zt(this,"enable",t.enable)}}class fe extends ie{close=!0;options={};type=[];doLoad(t){const e=t.options;if(void 0!==e)for(const t in e){const i=e[t];i&&(this.options[t]=xt(this.options[t]??{},i))}Zt(this,"close",t.close),Zt(this,"type",t.type)}}class ge extends ie{color;enable=!0;opacity=1;doLoad(t){void 0!==t.color&&(this.color=le.create(this.color,t.color)),Zt(this,"enable",t.enable),Jt(this,"opacity",t.opacity)}}class ye extends ie{offset=0;value=90;doLoad(t){Jt(this,"offset",t.offset),Jt(this,"value",t.value)}}class me extends ie{mode=gt.percent;radius=0;x=50;y=50;doLoad(t){Zt(this,"x",t.x),Zt(this,"y",t.y),Zt(this,"mode",t.mode),Zt(this,"radius",t.radius)}}class ve extends ie{acceleration=9.81;enable=!1;inverse=!1;maxSpeed=50;doLoad(t){Jt(this,"acceleration",t.acceleration),Zt(this,"enable",t.enable),Zt(this,"inverse",t.inverse),Jt(this,"maxSpeed",t.maxSpeed)}}class we extends ie{value=0;doLoad(t){$(t.value)||(this.value=J(t.value))}}class Pe extends we{animation=new ne;doLoad(t){var e,i,s;super.doLoad(t),e=this,i="animation",void 0!==(s=t.animation)&&e[i].load(s)}}class be extends Pe{animation=new ae}class xe extends ie{clamp=!0;delay=new we;enable=!1;generator;options={};doLoad(t){Zt(this,"clamp",t.clamp),this.delay.load(t.delay),Zt(this,"enable",t.enable),this.generator=t.generator,t.options&&(this.options=xt(this.options,t.options))}}class Me extends ie{bottom;default=Ut.out;left;right;top;doLoad(t){void 0!==t.default&&(this.default=t.default),this.bottom=t.bottom??t.default,this.left=t.left??t.default,this.right=t.right??t.default,this.top=t.top??t.default}}class ke extends ie{acceleration=0;enable=!1;position;doLoad(t){Jt(this,"acceleration",t.acceleration),Zt(this,"enable",t.enable),t.position&&(this.position=xt({},t.position))}}class ze extends ie{angle=new ye;center=new me;decay=0;direction=a.none;distance={};drift=0;enable=!1;gravity=new ve;outModes=new Me;path=new xe;random=!1;size=!1;speed=2;spin=new ke;straight=!1;vibrate=!1;warp=!1;doLoad(t){this.angle.load(R(t.angle)?{value:t.angle}:t.angle),this.center.load(t.center),Jt(this,"decay",t.decay),Zt(this,"direction",t.direction),void 0!==t.distance&&(this.distance=R(t.distance)?{horizontal:t.distance,vertical:t.distance}:{...t.distance}),Jt(this,"drift",t.drift),Zt(this,"enable",t.enable),this.gravity.load(t.gravity);const e=t.outModes;void 0!==e&&(A(e)?this.outModes.load(e):this.outModes.load({default:e})),this.path.load(t.path),Zt(this,"random",t.random),Zt(this,"size",t.size),Jt(this,"speed",t.speed),this.spin.load(t.spin),Zt(this,"straight",t.straight),Zt(this,"vibrate",t.vibrate),Zt(this,"warp",t.warp)}}class Ce extends ie{color;opacity;width=0;doLoad(t){void 0!==t.color&&(this.color=le.create(this.color,t.color)),Jt(this,"width",t.width),Jt(this,"opacity",t.opacity)}}class Se extends ie{color;fill;stroke;doLoad(t){void 0!==t.color&&(this.color=le.create(this.color,t.color)),te(this,"fill",t.fill,()=>new ge),te(this,"stroke",t.stroke,()=>new Ce)}}class Ie extends we{value=1}class Oe extends ie{horizontal=new Ie;vertical=new Ie;doLoad(t){this.horizontal.load(t.horizontal),this.vertical.load(t.vertical)}}class Le extends ie{enable=!1;height=1080;width=1920;doLoad(t){Zt(this,"enable",t.enable),Zt(this,"width",t.width),Zt(this,"height",t.height)}}class De extends ie{mode=At.delete;value=0;doLoad(t){Zt(this,"mode",t.mode),Zt(this,"value",t.value)}}class _e extends ie{density=new Le;limit=new De;value=0;doLoad(t){this.density.load(t.density),this.limit.load(t.limit),Zt(this,"value",t.value)}}class Ee extends ie{close=!0;options={};type="circle";doLoad(t){const e=t.options;if(void 0!==e)for(const t in e){const i=e[t];i&&(this.options[t]=xt(this.options[t]??{},i))}Zt(this,"close",t.close),Zt(this,"type",t.type)}}class Te extends we{opacityRate=1;sizeRate=1;velocityRate=1;doLoad(t){super.doLoad(t),Zt(this,"opacityRate",t.opacityRate),Zt(this,"sizeRate",t.sizeRate),Zt(this,"velocityRate",t.velocityRate)}}class Re extends ie{bounce=new Oe;effect=new fe;groups={};move=new ze;number=new _e;paint;palette;reduceDuplicates=!1;shape=new Ee;zIndex=new Te;#u;#p;constructor(t,e){super(),this.#p=t,this.#u=e,this.paint=new Se,this.paint.color=new le,this.paint.color.value="#fff",this.paint.fill=new ge,this.paint.fill.enable=!0}doLoad(t){if(t.palette&&(this.palette=t.palette,this.#f(this.palette)),void 0!==t.groups)for(const e of Object.keys(t.groups)){if(!(e in t.groups))continue;const i=t.groups[e];void 0!==i&&(this.groups[e]=xt(this.groups[e]??{},i))}void 0!==t.reduceDuplicates&&(this.reduceDuplicates=t.reduceDuplicates),this.bounce.load(t.bounce),this.effect.load(t.effect),this.move.load(t.move),this.number.load(t.number);const e=t.paint;if(e&&(U(e)?this.paint=Mt(e,t=>{const e=new Se;return e.load(t),e}):U(this.paint)?(this.paint=new Se,this.paint.load(e)):this.paint.load(e)),this.shape.load(t.shape),this.zIndex.load(t.zIndex),this.#u){for(const e of this.#p.plugins)e.loadParticlesOptions&&e.loadParticlesOptions(this.#u,this,t);const e=this.#u.particleUpdaters;for(const i of e)i.loadOptions&&i.loadOptions(this,t)}}#f(t){const e=this.#p.getPalette(t);if(!e)return;const i=e.colors,s=(U(i)?i:[i]).flatMap(t=>{const e=t.fill,i=t.stroke,s=e?{color:{value:e.value},enable:e.enable,opacity:e.opacity}:void 0;return i?[{fill:s,stroke:{color:{value:i.value},opacity:i.opacity,width:i.width||0}}]:[{fill:s}]}),n=s.length>1?s:s[0]??{};this.load({paint:n,blend:{enable:!0,mode:e.blendMode}})}}function Be(t,e,...i){const s=new Re(t,e);return se(s,...i),s}class Fe extends ie{autoPlay=!0;background;clear=!0;defaultThemes={};delay=0;detectRetina=!0;duration=0;fpsLimit=120;fullScreen;hdr;key;name;palette;particles;pauseOnBlur=!0;pauseOnOutsideViewport=!0;preset;resize;smooth=!1;style={};zLayers=100;#u;#p;constructor(t,e){super(),this.#p=t,this.#u=e,this.background=new he,this.fullScreen=new de,this.hdr=new ue,this.particles=Be(this.#p,this.#u),this.resize=new pe}doLoad(t){void 0!==t.preset&&(this.preset=t.preset,Mt(this.preset,t=>{this.#g(t)})),void 0!==t.palette&&(this.palette=t.palette,this.#f(this.palette)),Zt(this,"autoPlay",t.autoPlay),Zt(this,"clear",t.clear),Zt(this,"key",t.key),Zt(this,"name",t.name),Jt(this,"delay",t.delay),Zt(this,"detectRetina",t.detectRetina),Jt(this,"duration",t.duration),Zt(this,"fpsLimit",t.fpsLimit);const e=t.hdr;E(e)?(this.hdr.enable=e,this.hdr.mode=Ft.standard,this.hdr.peakNits=400):this.hdr.load(e),Zt(this,"pauseOnBlur",t.pauseOnBlur),Zt(this,"pauseOnOutsideViewport",t.pauseOnOutsideViewport),Zt(this,"zLayers",t.zLayers),this.background.load(t.background);const i=t.fullScreen;E(i)?this.fullScreen.enable=i:this.fullScreen.load(i),this.particles.load(t.particles),this.resize.load(t.resize),this.style=xt(this.style,t.style),Zt(this,"smooth",t.smooth),this.#p.plugins.forEach(e=>{e.loadOptions(this.#u,this,t)})}#f(t){const e=this.#p.getPalette(t);e&&this.load({background:{color:e.background},blend:{enable:!0,mode:e.blendMode},particles:{palette:t}})}#g(t){this.load(this.#p.getPreset(t))}}const Ae=new Map,Ue=1.15,$e=1.05,He=.2126,qe=.7152,Ve=.0722;function We(t,e){let i=Ae.get(t);return i||(i=e(),Ae.size>2e3&&Ae.clear(),Ae.set(t,i)),i}function Ne(t){return G(t*(2.51*t+.03)/(t*(2.43*t+.59)+.14),0,1)}function je(t){return t<=.04045?t/12.92:Math.pow((t+.055)/1.055,2.4)}function Ge(t){return t<=.0031308?12.92*t:1.055*Math.pow(t,1/2.4)-.055}function Xe(t,e,i,s=!0){if(!e)return;const n=T(e)?{value:e}:e;if(T(n.value))return Ye(t,n.value,i,s);if(U(n.value)){const e=wt(n.value,i,s);if(!e)return;return Xe(t,{value:e})}for(const e of t.colorManagers.values()){const t=e.handleRangeColor(n);if(t)return t}}function Ye(t,e,i,s=!0){if(!e)return;const n=T(e)?{value:e}:e;if(T(n.value))return n.value===v?ti():function(t,e){return function(t,e){if(e)for(const i of t.colorManagers.values())if(i.accepts(e))return i.parseString(e)}(t,e)}(t,n.value);if(U(n.value)){const e=wt(n.value,i,s);if(!e)return;return Ye(t,{value:e})}for(const e of t.colorManagers.values()){const t=e.handleColor(n);if(t)return t}}function Qe(t,e,i,s=!0){const n=Xe(t,e,i,s);return n?function(t){const e=t.r/k,i=t.g/k,s=t.b/k,n=Math.max(e,i,s),a=Math.min(e,i,s),o={h:0,l:(n+a)*d,s:0};n!==a&&(o.s=o.l<d?(n-a)/(n+a):(n-a)/(2-n-a),o.h=e===n?(i-s)/(n-a):i===n?2+(s-e)/(n-a):4+(e-i)/(n-a));o.l*=S,o.s*=C,o.h*=60,o.h<0&&(o.h+=z);o.h>=z&&(o.h-=z);return o}(n):void 0}function Ke(t,e,i){if(i<0&&i++,i>1&&i--,6*i<1)return t+6*(e-t)*i;if(2*i<1)return e;if(3*i<2){return t+(e-t)*(2/3-i)*6}return t}function Ze(t){const e=(t.h%z+z)%z,i=Math.max(0,Math.min(C,t.s)),s=Math.max(0,Math.min(S,t.l)),n=e/z,a=i/C,o=s/S;if(0===i){const t=Math.round(o*k);return{r:t,g:t,b:t}}const r=o<d?o*(1+a):o+a-o*a,c=2*o-r,l=1/3,h=Math.min(k,k*Ke(c,r,n+l)),u=Math.min(k,k*Ke(c,r,n)),p=Math.min(k,k*Ke(c,r,n-l));return{r:Math.round(h),g:Math.round(u),b:Math.round(p)}}function Je(t){const e=(t.h%z+z)%z,i=Math.max(0,Math.min(C,t.s)),s=Math.max(0,Math.min(S,t.l)),n=e/z,a=i/C,o=s/S;if(0===i){const t=o*k;return{r:t,g:t,b:t}}const r=o<d?o*(1+a):o+a-o*a,c=2*o-r,l=1/3;return{r:Math.min(k,k*Ke(c,r,n+l)),g:Math.min(k,k*Ke(c,r,n)),b:Math.min(k,k*Ke(c,r,n-l))}}function ti(t,e){const i=()=>Math.floor(j(0,256));return{b:i(),g:i(),r:i()}}function ei(t,e,i,s,n){const a=e?4:2,o=i??1;return We(e?`rgb-${t.r.toFixed(a)}-${t.g.toFixed(a)}-${t.b.toFixed(a)}-hdr-${o.toString()}-${(s??400).toString()}-${n??Ft.standard}`:`rgb-${t.r.toFixed(a)}-${t.g.toFixed(a)}-${t.b.toFixed(a)}-sdr-${o.toString()}`,()=>e?function(t,e,i=400,s=Ft.standard){const n=i/203,a=function(t,e,i,s){const n=t.r/k,a=t.g/k,o=t.b/k;if(s!==Ft.natural&&s!==Ft.vivid&&s!==Ft.cinematic&&s!==Ft.dynamic)return{b:o,g:a,r:n};const r=Math.max(1,e),c=He*n+qe*a+Ve*o,l=function(t,e,i){if(t<=i)return Ne(t);const s=t+(t-i)*(e-1);return Ne(s)}(c,e,i),h=c>0?l/c:1;return function(t,e,i,s,n){switch(s){case Ft.vivid:{const s=(t+e+i)/3;return{b:G(G(s+(i-s)*Ue,0,n)*$e,0,n),g:G(G(s+(e-s)*Ue,0,n)*$e,0,n),r:G(G(s+(t-s)*Ue,0,n)*$e,0,n)}}case Ft.cinematic:{const s=1.05*t,a=.95*i,o=(s+e+a)/3;return{b:G(o+1.1*(a-o),0,n),g:G(o+1.1*(e-o),0,n),r:G(o+1.1*(s-o),0,n)}}case Ft.dynamic:{const s=He*t+qe*e+Ve*i,a=Math.min(1,2*s),o=1-a,r=(t+e+i)/3,c=G(r+(t-r)*Ue,0,n)*$e,l=G(r+(e-r)*Ue,0,n)*$e,h=G(r+(i-r)*Ue,0,n)*$e;return{b:G(i*o+h*a,0,n),g:G(e*o+l*a,0,n),r:G(t*o+c*a,0,n)}}case Ft.standard:case Ft.natural:default:return{b:i,g:e,r:t}}}(G(n*h,0,r),G(a*h,0,r),G(o*h,0,r),s,r)}(t,n,.18,s);return`color(display-p3 ${a.r.toString()} ${a.g.toString()} ${a.b.toString()} / ${(e??1).toString()})`}(t,i,s,n):function(t,e){return`rgba(${t.r.toString()}, ${t.g.toString()}, ${t.b.toString()}, ${(e??1).toString()})`}(t,i))}function ii(t,e,i,s,n){const a=e?4:2,o=i??1;return We(e?`hsl-${t.h.toFixed(a)}-${t.s.toFixed(a)}-${t.l.toFixed(a)}-hdr-${o.toString()}-${(s??O).toString()}-${n??Ft.standard}`:`hsl-${t.h.toFixed(a)}-${t.s.toFixed(a)}-${t.l.toFixed(a)}-sdr-${o.toString()}`,()=>e?ei(Je(t),!0,i,s,n):`hsla(${t.h.toString()}, ${t.s.toString()}%, ${t.l.toString()}%, ${o.toString()})`)}function si(t,e,i,s){if(i===v)return ti();if(i!==w)return i;{const i=t.getFillColor()??t.getStrokeColor(),n=e?.getFillColor()??e?.getStrokeColor();if(i&&n&&e)return function(t,e,i,s,n){let a=t,o=e;if("r"in a||(a=n?Je(t):Ze(t)),"r"in o||(o=n?Je(e):Ze(e)),n){const t={b:je(a.b/k),g:je(a.g/k),r:je(a.r/k)},e={b:je(o.b/k),g:je(o.g/k),r:je(o.r/k)},n=i+s;return{b:Ge((t.b*i+e.b*s)/n)*k,g:Ge((t.g*i+e.g*s)/n)*k,r:Ge((t.r*i+e.r*s)/n)*k}}return{b:X(a.b,o.b,i,s),g:X(a.g,o.g,i,s),r:X(a.r,o.r,i,s)}}(i,n,t.getRadius(),e.getRadius(),s);{const t=i??n;if(t)return Ze(t)}}}function ni(t){return void 0===t?void 0:{h:t.h.value,s:t.s.value,l:t.l.value}}function ai(t,e,i){const s={h:{enable:!1,value:t.h,min:0,max:z},s:{enable:!1,value:t.s,min:0,max:C},l:{enable:!1,value:t.l,min:0,max:S}};return e&&(oi(s.h,e.h,i),oi(s.s,e.s,i),oi(s.l,e.l,i)),s}function oi(t,e,i){t.enable=e.enable,t.min=e.min,t.max=e.max,t.enable?(t.velocity=Q(e.speed)/h*i,t.decay=1-Q(e.decay),t.status=Nt.increasing,t.loops=0,t.maxLoops=Q(e.count),t.time=0,t.delayTime=Q(e.delay)*u,e.sync||(t.velocity*=N(),t.value*=N()),t.initialValue=t.value,t.offset=J(e.offset)):t.velocity=0}function ri(t,e,i,s){if(!t.enable||(t.maxLoops??0)>0&&(t.loops??0)>(t.maxLoops??0))return;if(t.time??=0,(t.delayTime??0)>0&&t.time<(t.delayTime??0)&&(t.time+=i.value),(t.delayTime??0)>0&&t.time<(t.delayTime??0))return;const n=t.offset?Y(t.offset):0,a=(t.velocity??0)*i.factor+3.6*n,o=t.decay??1,r=t.max,c=t.min;e&&t.status!==Nt.increasing?(t.value-=a,t.value<c&&(t.loops??=0,t.loops++,t.status=Nt.increasing)):(t.value+=a,t.value>r&&(t.loops??=0,t.loops++,e?t.status=Nt.decreasing:t.value-=r)),t.velocity&&1!==o&&(t.velocity*=o),t.value=G(t.value,c,r)}function ci(t,e,i){if(!t)return;const{h:s,s:n,l:a}=t;ri(s,!1,e),ri(n,!0,e),ri(a,!0,e)}const li=function(){const t=globalThis.tsParticles;return t?.pluginManager?t:new Xt}();class hi{enable=!1;mode="destination-out";load(t){$(t)||(Zt(this,"mode",t.mode),Zt(this,"enable",t.enable))}}class di{id="blend";async getPlugin(t){const{BlendPluginInstance:e}=await Promise.resolve().then(function(){return Vs});return new e(t)}loadOptions(t,e,i){if(!this.needsPlugin(e)&&!this.needsPlugin(i))return;let s=e.blend;s?.load||(e.blend=s=new hi),s.load(i?.blend)}loadParticlesOptions(t,e,i){e.blend??=new hi,e.blend.load(i?.blend)}needsPlugin(t){return!!t?.blend?.enable||!!t?.particles?.blend?.enable}}async function ui(t){t.checkVersion("4.5.1"),await t.pluginManager.register(t=>{t.pluginManager.addPlugin(new di)})}class pi{draw(t){!function(t){const{context:e,particle:i,radius:s}=t;i.circleRange??={min:0,max:P};const n=i.circleRange;e.arc(p.x,p.y,s,n.min,n.max,!1)}(t)}getSidesCount(){return 12}particleInit(t,e){const i=e.shapeData,s=i?.angle??{max:360,min:0};e.circleRange=A(s)?{min:it(s.min),max:it(s.max)}:{min:0,max:it(s)}}}async function fi(t){t.checkVersion("4.5.1"),await t.pluginManager.register(t=>{t.pluginManager.addShape(["circle"],()=>Promise.resolve(new pi))})}var gi;!function(t){t[t.r=1]="r",t[t.g=2]="g",t[t.b=3]="b",t[t.a=4]="a"}(gi||(gi={}));const yi=/^#?([a-f\d])([a-f\d])([a-f\d])([a-f\d])?$/i,mi=/^#?([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})([a-f\d]{2})?$/i;class vi{accepts(t){return t.startsWith("#")}handleColor(t){return this.#y(t.value)}handleRangeColor(t){return this.#y(t.value)}parseString(t){return this.#y(t)}#y(t){if("string"!=typeof t||!this.accepts(t))return;const e=t.replace(yi,(t,e,i,s,n)=>e+e+i+i+s+s+(void 0===n?"":n+n)),i=mi.exec(e);return i?{a:i[gi.a]?Number.parseInt(i[gi.a],16)/255:1,b:Number.parseInt(i[gi.b]??"0",16),g:Number.parseInt(i[gi.g]??"0",16),r:Number.parseInt(i[gi.r]??"0",16)}:void 0}}async function wi(t){t.checkVersion("4.5.1"),await t.pluginManager.register(t=>{t.pluginManager.addColorManager("hex",new vi)})}var Pi;!function(t){t[t.h=1]="h",t[t.s=2]="s",t[t.l=3]="l",t[t.a=5]="a"}(Pi||(Pi={}));const bi=/hsla?\(\s*(\d+)\s*[\s,]\s*(\d+)%\s*[\s,]\s*(\d+)%\s*([\s,]\s*(0|1|0?\.\d+|(\d{1,3})%)\s*)?\)/i;class xi{accepts(t){return t.startsWith("hsl")}handleColor(t){const e=t.value.hsl??t.value;if("h"in e&&"s"in e&&"l"in e)return Ze(e)}handleRangeColor(t){const e=t.value.hsl??t.value;if("h"in e&&"s"in e&&"l"in e)return Ze({h:Q(e.h),l:Q(e.l),s:Q(e.s)})}parseString(t){if(!this.accepts(t))return;const e=bi.exec(t);return e?function(t){const e=Ze(t);return{a:t.a,b:e.b,g:e.g,r:e.r}}({a:e.length>4?nt(e[Pi.a]):1,h:Number.parseInt(e[Pi.h]??"0",10),l:Number.parseInt(e[Pi.l]??"0",10),s:Number.parseInt(e[Pi.s]??"0",10)}):void 0}}async function Mi(t){t.checkVersion("4.5.1"),await t.pluginManager.register(t=>{t.pluginManager.addColorManager("hsl",new xi)})}class ki{id="move";#p;constructor(t){this.#p=t}async getPlugin(t){const{MovePluginInstance:e}=await Promise.resolve().then(function(){return js});return new e(this.#p,t)}loadOptions(){}needsPlugin(){return!0}}async function zi(t){t.checkVersion("4.5.1"),await t.pluginManager.register(t=>{const e=t.pluginManager;e.initializers.pathGenerators??=new Map,e.addPathGenerator=(t,i)=>{e.initialized||(e.initializers.pathGenerators??=new Map,e.initializers.pathGenerators.set(t,i))},t.pluginManager.addPlugin(new ki(t.pluginManager))})}function Ci(t,e){const i=t.value,s=t.animation,n={delayTime:Q(s.delay)*u,enable:s.enable,value:Q(t.value)*e,max:Z(i)*e,min:K(i)*e,loops:0,maxLoops:Q(s.count),time:0};if(s.enable){switch(n.decay=1-Q(s.decay),s.mode){case Bt.increase:n.status=Nt.increasing;break;case Bt.decrease:n.status=Nt.decreasing;break;case Bt.random:n.status=N()>=d?Nt.increasing:Nt.decreasing}const t=s.mode===Bt.auto;switch(s.startValue){case Wt.min:n.value=n.min,t&&(n.status=Nt.increasing);break;case Wt.max:n.value=n.max,t&&(n.status=Nt.decreasing);break;case Wt.random:default:n.value=Y(n),t&&(n.status=N()>=d?Nt.increasing:Nt.decreasing)}}return n.initialValue=n.value,n}function Si(t,e,i,s,n){if(t.destroyed||!e.enable||(e.maxLoops??0)>0&&(e.loops??0)>(e.maxLoops??0))return;const a=(e.velocity??0)*n.factor,o=e.min,r=e.max,c=e.decay??1;e.time??=0;const l=e.delayTime??0;if(!(l>0&&e.time<l&&(e.time+=n.value,e.time<l))){switch(e.status){case Nt.increasing:e.value+=a;break;case Nt.decreasing:e.value-=a}switch(e.velocity&&1!==c&&(e.velocity*=c),e.status){case Nt.increasing:e.value>=r&&(e.status=Nt.decreasing,e.loops??=0,e.loops++);break;case Nt.decreasing:e.value<=o&&(e.status=Nt.increasing,e.loops??=0,e.loops++)}!function(t,e,i,s,n){switch(e){case Ht.max:i>=n&&t.destroy();break;case Ht.min:i<=s&&t.destroy()}}(t,s,e.value,o,r),t.destroyed||(e.value=G(e.value,o,r))}}class Ii extends ae{destroy=Ht.none;load(t){super.load(t),$(t)||Zt(this,"destroy",t.destroy)}}class Oi extends be{animation=new Ii;value=1;load(t){if($(t))return;super.load(t);const e=t.animation;void 0!==e&&this.animation.load(e)}}class Li{#u;constructor(t){this.#u=t}init(t){const e=t.options.opacity;if(!e)return;t.opacity=Ci(e,1);const i=e.animation;i.enable&&(t.opacity.velocity=Q(i.speed)/h*this.#u.retina.reduceFactor,i.sync||(t.opacity.velocity*=N()))}isEnabled(t){return!t.destroyed&&!t.spawning&&!!t.opacity&&t.opacity.enable&&((t.opacity.maxLoops??0)<=0||(t.opacity.maxLoops??0)>0&&(t.opacity.loops??0)<(t.opacity.maxLoops??0))}loadOptions(t,...e){ee(t,"opacity",Oi,...e)}reset(t){t.opacity&&(t.opacity.time=0,t.opacity.loops=0)}update(t,e){this.isEnabled(t)&&t.opacity&&t.options.opacity&&Si(t,t.opacity,0,t.options.opacity.animation.destroy,e)}}async function Di(t){t.checkVersion("4.5.1"),await t.pluginManager.register(t=>{t.pluginManager.addParticleUpdater("opacity",t=>Promise.resolve(new Li(t)))})}const _i={[ft.left]:{axis:"x",canvas:"width",bounce:"horizontal",negativeEdge:"right",positiveEdge:"left",negative:!0},[ft.right]:{axis:"x",canvas:"width",bounce:"horizontal",negativeEdge:"right",positiveEdge:"left",negative:!1},[ft.top]:{axis:"y",canvas:"height",bounce:"vertical",negativeEdge:"bottom",positiveEdge:"top",negative:!0},[ft.bottom]:{axis:"y",canvas:"height",bounce:"vertical",negativeEdge:"bottom",positiveEdge:"top",negative:!1}};class Ei{modes;#u;#m;constructor(t){this.#u=t,this.modes=[Ut.bounce,Ut.split],this.#m=t.plugins.filter(t=>!!t.particleBounce)}update(t,e,i,s){if(!this.modes.includes(s))return;for(const s of this.#m)if(s.particleBounce?.(t,i,e))return;const n=t.getPosition(),a=t.offset,o=t.getRadius(),r=bt(n,o),c=this.#u.canvas.size,l=!t.isInsideCanvasForOutMode(s,e);!function(t){if(t.outMode!==Ut.bounce&&t.outMode!==Ut.split||!(t.direction in _i))return;const e=_i[t.direction],i=t.bounds,s=t.canvasSize[e.canvas],n=t.particle.position,a=t.particle.velocity[e.axis];if(e.negative&&i[e.negativeEdge]<0?n[e.axis]=t.size+t.offset[e.axis]:!e.negative&&i[e.positiveEdge]>s&&(n[e.axis]=s-t.size-t.offset[e.axis]),!t.outOfCanvas||!(e.negative&&a<0||!e.negative&&a>0))return;t.particle.velocity[e.axis]*=-Q(t.particle.options.bounce[e.bounce].value);const o=t.offset[e.axis]+t.size;n[e.axis]=e.negative?o:s-o,t.outMode===Ut.split&&t.particle.destroy()}({particle:t,outMode:s,direction:e,bounds:r,canvasSize:c,offset:a,outOfCanvas:l,size:o})}}class Ti{modes;constructor(t){this.modes=[Ut.destroy]}update(t,e,i,s){if(this.modes.includes(s)){switch(t.outType){case Vt.normal:case Vt.outside:if(t.isInsideCanvasForOutMode(s,e))return;break;case Vt.inside:{const{dx:e,dy:i}=tt(t.position,t.moveCenter),{x:s,y:n}=t.velocity;if(s<0&&e>t.moveCenter.radius||n<0&&i>t.moveCenter.radius||s>=0&&e<-t.moveCenter.radius||n>=0&&i<-t.moveCenter.radius)return;break}}t.destroy(!0)}}}class Ri{modes;#u;constructor(t){this.#u=t,this.modes=[Ut.none]}update(t,e,i,s){if(!this.modes.includes(s))return;if((t.options.move.distance.horizontal&&(e===ft.left||e===ft.right))??(t.options.move.distance.vertical&&(e===ft.top||e===ft.bottom)))return;const n=t.options.move.gravity,a=this.#u,o=a.canvas.size,r=t.getRadius();if(n.enable){const i=t.position;(!n.inverse&&i.y>o.height+r&&e===ft.bottom||n.inverse&&i.y<-r&&e===ft.top)&&t.destroy()}else{if(t.velocity.y>0&&t.position.y<=o.height+r||t.velocity.y<0&&t.position.y>=-r||t.velocity.x>0&&t.position.x<=o.width+r||t.velocity.x<0&&t.position.x>=-r)return;Pt(t.position,a.canvas.size,p,r,e)||t.destroy()}}}const Bi=_.origin;class Fi{modes;#u;constructor(t){this.#u=t,this.modes=[Ut.out]}update(t,e,i,s){if(!this.modes.includes(s))return;const n=this.#u;if(t.outType===Vt.inside)this.#v(t,n);else{if(t.isInsideCanvasForOutMode(s,e))return;t.outType===Vt.outside?this.#w(t):this.#P(t,n,e)}}#v(t,e){const{x:i,y:s}=t.velocity;Bi.setTo(p),Bi.length=t.moveCenter.radius,Bi.angle=t.velocity.angle+Math.PI,Bi.addTo(t.moveCenter);const{dx:n,dy:a}=tt(t.position,Bi);if(i<=0&&n>=0||s<=0&&a>=0||i>=0&&n<=0||s>=0&&a<=0)return;t.position.x=Math.floor(Y({min:0,max:e.canvas.size.width})),t.position.y=Math.floor(Y({min:0,max:e.canvas.size.height}));const{dx:o,dy:r}=tt(t.position,t.moveCenter);t.direction=Math.atan2(-r,-o),t.velocity.angle=t.direction,t.justWarped=!0}#P(t,e,i){const s=t.options.move.warp,n=e.canvas.size,a=t.getRadius(),o={bottom:n.height+a+t.offset.y,left:-a-t.offset.x,right:n.width+a+t.offset.x,top:-a-t.offset.y},r=bt(t.position,a);i===ft.right&&r.left>n.width+t.offset.x?(t.position.x=o.left,t.initialPosition.x=t.position.x,s||(t.position.y=N()*n.height,t.initialPosition.y=t.position.y),t.justWarped=!0):i===ft.left&&r.right<-t.offset.x&&(t.position.x=o.right,t.initialPosition.x=t.position.x,s||(t.position.y=N()*n.height,t.initialPosition.y=t.position.y),t.justWarped=!0),i===ft.bottom&&r.top>n.height+t.offset.y?(s||(t.position.x=N()*n.width,t.initialPosition.x=t.position.x),t.position.y=o.top,t.initialPosition.y=t.position.y,t.justWarped=!0):i===ft.top&&r.bottom<-t.offset.y&&(s||(t.position.x=N()*n.width,t.initialPosition.x=t.position.x),t.position.y=o.bottom,t.initialPosition.y=t.position.y,t.justWarped=!0)}#w(t){t.position.x=Math.floor(Y({min:-t.moveCenter.radius,max:t.moveCenter.radius}))+t.moveCenter.x,t.position.y=Math.floor(Y({min:-t.moveCenter.radius,max:t.moveCenter.radius}))+t.moveCenter.y;const{dx:e,dy:i}=tt(t.position,t.moveCenter);t.moveCenter.radius&&(t.direction=Math.atan2(i,e),t.velocity.angle=t.direction),t.justWarped=!0}}class Ai{updaters;#u;constructor(t){this.#u=t,this.updaters=new Map}init(t){this.#b(t,Ut.bounce,t=>new Ei(t)),this.#b(t,Ut.out,t=>new Fi(t)),this.#b(t,Ut.destroy,t=>new Ti(t)),this.#b(t,Ut.none,t=>new Ri(t))}isEnabled(t){return!t.destroyed&&!t.spawning}update(t,e){const i=t.options.move.outModes;t.justWarped=!1,this.#x(t,e,i.bottom??i.default,ft.bottom),this.#x(t,e,i.left??i.default,ft.left),this.#x(t,e,i.right??i.default,ft.right),this.#x(t,e,i.top??i.default,ft.top)}#b(t,e,i){const s=t.options.move.outModes;!this.updaters.has(e)&&((t,e)=>t.default===e||t.bottom===e||t.left===e||t.right===e||t.top===e)(s,e)&&this.updaters.set(e,i(this.#u))}#x(t,e,i,s){for(const n of this.updaters.values())n.update(t,s,e,i)}}async function Ui(t){t.checkVersion("4.5.1"),await t.pluginManager.register(t=>{t.pluginManager.addParticleUpdater("outModes",t=>Promise.resolve(new Ai(t)))})}class $i{#u;#p;constructor(t,e){this.#u=e,this.#p=t}init(t){const e=this.#u,i=t.options,s=kt(i.paint,t.id,i.reduceDuplicates);this.#M(s,t,e),this.#k(s,t,e)}isEnabled(t){const{fillAnimation:e,fillColor:i,strokeAnimation:s,strokeColor:n}=t,a=!!e&&(void 0!==i?.h.value&&i.h.enable||void 0!==i?.s.value&&i.s.enable||void 0!==i?.l.value&&i.l.enable),o=!!s&&(void 0!==n?.h.value&&n.h.enable||void 0!==n?.s.value&&n.s.enable||void 0!==n?.l.value&&n.l.enable);return!t.destroyed&&!t.spawning&&(a||o)}update(t,e){this.isEnabled(t)&&(ci(t.fillColor,e,this.#u.hdr),ci(t.strokeColor,e,this.#u.hdr))}#M(t,e,i){const s=t?.fill,n=t?.color,a=n??void 0;if(!s)return e.fillEnabled=!1,e.fillAnimation=void 0,e.fillColor=void 0,void(e.fillOpacity=1);const o=le.create(void 0===a?void 0:le.create(void 0,a),s.color);e.fillEnabled=s.enable,e.fillOpacity=Q(s.opacity),e.fillAnimation=o.animation;const r=Qe(this.#p,o);r&&(e.fillColor=ai(r,e.fillAnimation,i.retina.reduceFactor))}#k(t,e,i){const s=t?.stroke,n=t?.color,a=n??void 0;if(!s)return e.strokeAnimation=void 0,e.strokeColor=void 0,e.strokeOpacity=1,void(e.strokeWidth=0);const o=le.create(void 0===a?void 0:le.create(void 0,a),s.color);e.strokeWidth=Q(s.width)*i.retina.pixelRatio,e.strokeOpacity=Q(s.opacity??1),e.strokeAnimation=o.animation;const r=Qe(this.#p,o)??e.getFillColor();r&&(e.strokeColor=ai(r,e.strokeAnimation,i.retina.reduceFactor))}}async function Hi(t){t.checkVersion("4.5.1"),await t.pluginManager.register(t=>{t.pluginManager.addParticleUpdater("paint",e=>Promise.resolve(new $i(t.pluginManager,e)))})}var qi;!function(t){t[t.r=1]="r",t[t.g=2]="g",t[t.b=3]="b",t[t.a=5]="a"}(qi||(qi={}));const Vi=/rgba?\(\s*(\d{1,3})\s*[\s,]\s*(\d{1,3})\s*[\s,]\s*(\d{1,3})\s*([\s,]\s*(0|1|0?\.\d+|(\d{1,3})%)\s*)?\)/i;class Wi{accepts(t){return t.startsWith("rgb")}handleColor(t){const e=t.value.rgb??t.value;if("r"in e&&"g"in e&&"b"in e)return e}handleRangeColor(t){const e=t.value.rgb??t.value;if("r"in e&&"g"in e&&"b"in e)return{r:Q(e.r),g:Q(e.g),b:Q(e.b)}}parseString(t){if(!this.accepts(t))return;const e=Vi.exec(t);return e?{a:e.length>4?nt(e[qi.a]):1,b:parseInt(e[qi.b]??"0",10),g:parseInt(e[qi.g]??"0",10),r:parseInt(e[qi.r]??"0",10)}:void 0}}async function Ni(t){t.checkVersion("4.5.1"),await t.pluginManager.register(t=>{t.pluginManager.addColorManager("rgb",new Wi)})}class ji extends ae{destroy=Ht.none;load(t){super.load(t),$(t)||Zt(this,"destroy",t.destroy)}}class Gi extends be{animation=new ji;value=3;load(t){if(super.load(t),$(t))return;const e=t.animation;void 0!==e&&this.animation.load(e)}}class Xi{#u;constructor(t){this.#u=t}init(t){const e=this.#u,i=t.options.size;if(!i)return;const s=i.animation;s.enable&&(t.size.velocity=t.retina.sizeAnimationSpeed/h*e.retina.reduceFactor,s.sync||(t.size.velocity*=N()))}isEnabled(t){return!t.destroyed&&!t.spawning&&t.size.enable&&((t.size.maxLoops??0)<=0||(t.size.maxLoops??0)>0&&(t.size.loops??0)<(t.size.maxLoops??0))}loadOptions(t,...e){ee(t,"size",Gi,...e)}preInit(t){const e=this.#u.retina.pixelRatio,i=t.options.size;i&&(t.size=Ci(i,e),t.retina.sizeAnimationSpeed=Q(i.animation.speed)*e)}reset(t){t.size.time=0,t.size.loops=0}update(t,e){this.isEnabled(t)&&t.options.size&&Si(t,t.size,0,t.options.size.animation.destroy,e)}}async function Yi(t){t.checkVersion("4.5.1"),await t.pluginManager.register(t=>{t.pluginManager.addParticleUpdater("size",t=>Promise.resolve(new Xi(t)))})}async function Qi(t){t.checkVersion("4.5.1"),await t.pluginManager.register(async t=>{await Promise.all([ui(t),wi(t),Mi(t),Ni(t),zi(t),fi(t),Hi(t),Di(t),Ui(t),Yi(t)])})}const Ki="TSP-3201",Zi="TSP-3202";class Ji{enable=!1;mode=[];load(t){$(t)||(Zt(this,"enable",t.enable),Zt(this,"mode",t.mode))}}var ts,es,is;!function(t){t.circle="circle",t.rectangle="rectangle"}(ts||(ts={}));class ss{enable=!1;mode=[];selectors=[];type=ts.circle;load(t){$(t)||(Zt(this,"selectors",t.selectors),Zt(this,"enable",t.enable),Zt(this,"mode",t.mode),Zt(this,"type",t.type))}}class ns{enable=!1;mode=[];load(t){$(t)||(Zt(this,"enable",t.enable),Zt(this,"mode",t.mode))}}class as{onClick=new Ji;onDiv=new ss;onHover=new ns;load(t){if($(t))return;this.onClick.load(t.onClick);const e=t.onDiv;void 0!==e&&(this.onDiv=Mt(e,t=>{const e=new ss;return e.load(t),e})),this.onHover.load(t.onHover)}}!function(t){t.canvas="canvas",t.parent="parent",t.window="window"}(es||(es={}));class os{#u;constructor(t){this.#u=t}load(t){if($(t))return;if(!this.#u)return;const e=this.#u.interactionManager?.interactors??[];for(const i of e)i.loadModeOptions&&i.loadModeOptions(this,t)}}class rs{detectsOn=es.window;events=new as;modes;constructor(t){this.modes=new os(t)}load(t){if($(t))return;const e=t.detectsOn;void 0!==e&&(this.detectsOn=e),this.events.load(t.events),this.modes.load(t.modes)}}class cs{id="interactivity";#p;constructor(t){this.#p=t}async getPlugin(t){const{InteractivityPluginInstance:e}=await Promise.resolve().then(function(){return Ys});return new e(this.#p,t)}loadOptions(t,e,i){if(!this.needsPlugin())return;let s=e.interactivity;s?.load||(e.interactivity=s=new rs(t)),s.load(i?.interactivity);const n=t.interactionManager?.interactors;if(n)for(const t of n)t.loadOptions&&t.loadOptions(e,i)}loadParticlesOptions(t,e,i){i?.interactivity&&(e.interactivity=xt({},i.interactivity));const s=t.interactionManager?.interactors;if(s)for(const t of s)t.loadParticlesOptions?.(e,i)}needsPlugin(){return!0}}!function(t){t.external="external",t.particles="particles"}(is||(is={}));class ls{type=is.particles;container;constructor(t){this.container=t}}const hs="pointerleave",ds="pointermove",us="touchstart",ps="touchend",fs="touchmove",gs="touchcancel";class ys extends Qt{#z;constructor(t,e,i,s){super(t,e,i),this.#z=s}contains(t){if(super.contains(t))return!0;const{width:e,height:i}=this.#z,{x:s,y:n}=t;return super.contains({x:s-e,y:n})||super.contains({x:s+e,y:n})||super.contains({x:s,y:n-i})||super.contains({x:s,y:n+i})||super.contains({x:s-e,y:n-i})||super.contains({x:s+e,y:n+i})||super.contains({x:s-e,y:n+i})||super.contains({x:s+e,y:n-i})}intersects(t){if(super.intersects(t))return!0;const{width:e,height:i}=this.#z,s=t.position,n=[{x:-e,y:0},{x:e,y:0},{x:0,y:-i},{x:0,y:i},{x:-e,y:-i},{x:e,y:i},{x:-e,y:i},{x:e,y:-i}];for(const e of n){const i={x:s.x+e.x,y:s.y+e.y};let n;if(t instanceof Qt)n=new Qt(i.x,i.y,t.radius);else{const e=t;n=new Kt(i.x,i.y,e.size.width,e.size.height)}if(super.intersects(n))return!0}return!1}query(t){const{x:e,y:i}=this.position,{width:s,height:n}=this.#z,a=this.radius,o=e-a<=p.x,r=e+a>=s,c=i-a<=p.y,l=i+a>=n;if(!(o||r||c||l))return t.query(this);const h=[p.x],d=[p.y];o&&h.push(s),r&&h.push(-s),c&&d.push(n),l&&d.push(-n);const u=new Set;for(const s of h)for(const n of d)for(const o of t.queryCircle({x:e+s,y:i+n},a))u.add(o);return[...u]}}class ms{blur=5;color=new ce;enable=!1;constructor(){this.color.value="#000"}load(t){$(t)||(Zt(this,"blur",t.blur),this.color=ce.create(this.color,t.color),Zt(this,"enable",t.enable))}}class vs{color;enable=!1;frequency=1;opacity;load(t){$(t)||(void 0!==t.color&&(this.color=ce.create(this.color,t.color)),Zt(this,"enable",t.enable),Zt(this,"frequency",t.frequency),Zt(this,"opacity",t.opacity))}}class ws{blink=!1;color=new ce;consent=!1;distance=100;enable=!1;frequency=1;id;opacity=1;shadow=new ms;triangles=new vs;warp=!1;width=1;constructor(){this.color.value="#fff"}load(t){$(t)||(Zt(this,"id",t.id),Zt(this,"blink",t.blink),this.color=ce.create(this.color,t.color),Zt(this,"consent",t.consent),Zt(this,"distance",t.distance),Zt(this,"enable",t.enable),Zt(this,"frequency",t.frequency),Zt(this,"opacity",t.opacity),this.shadow.load(t.shadow),this.triangles.load(t.triangles),Zt(this,"width",t.width),Zt(this,"warp",t.warp))}}function Ps(t,e,i){const{dx:s,dy:n}=tt(t,e),a={x:Math.abs(s),y:Math.abs(n)},o={x:Math.min(a.x,i.width-a.x),y:Math.min(a.y,i.height-a.y)};return Math.hypot(o.x,o.y)}class bs extends ls{#C;#p;constructor(t,e){super(e),this.#p=t,this.#C=0}get maxDistance(){return this.#C}clear(){}init(){this.container.particles.linksColor=void 0,this.container.particles.linksColors=new Map}interact(t){if(!t.options.links)return;t.links=[],t.linksDistance&&t.linksDistance>this.#C&&(this.#C=t.linksDistance);const e=t.getPosition(),i=this.container,s=i.canvas.size;if(e.x<p.x||e.y<p.y||e.x>s.width||e.y>s.height)return;const n=t.options.links,a=n.opacity,o=t.retina.linksDistance??0,r=n.warp,c=r?new ys(e.x,e.y,o,s).query(i.particles.grid):i.particles.grid.queryCircle(e,o);for(const i of c){const c=i.options.links;if(t===i||!c?.enable||n.id!==c.id||i.spawning||i.destroyed||!i.links||t.links.some(t=>t.destination===i)||i.links.some(e=>e.destination===t))continue;const l=i.getPosition();if(l.x<p.x||l.y<p.y||l.x>s.width||l.y>s.height)continue;const h=tt(e,l).distance,d=r&&c.warp?Ps(e,l,s):h,u=Math.min(h,d);if(u>o)continue;const f=(1-u/o)*a;this.#S(t),t.links.push({destination:i,opacity:f,color:this.#I(t,i),isWarped:d<h})}}isEnabled(t){return!!t.options.links?.enable}loadParticlesOptions(t,...e){ee(t,"links",ws,...e)}reset(){}#I(t,e){const i=this.container,s=t.options.links;if(!s)return;return si(t,e,void 0!==s.id?i.particles.linksColors.get(s.id):i.particles.linksColor,i.hdr)}#S(t){if(!t.options.links)return;const e=this.container,i=t.options.links;let s=void 0===i.id?e.particles.linksColor:e.particles.linksColors.get(i.id);s||(s=function(t,e,i,s){const n=T(e)?e:e.value;return n===v?s?Xe(t,{value:n}):i?v:w:n===w?w:Xe(t,{value:n})}(this.#p,i.color,i.blink,i.consent),void 0===i.id?e.particles.linksColor=s:e.particles.linksColors.set(i.id,s))}}class xs{id="links";#p;constructor(t){this.#p=t}async getPlugin(t){const{LinkInstance:e}=await Promise.resolve().then(function(){return Ks});return new e(this.#p,t)}loadOptions(){}needsPlugin(){return!0}}async function Ms(t){t.checkVersion("4.5.1"),await t.pluginManager.register(t=>{const e=t.pluginManager;!function(t){if(!t.pluginManager.addInteractor)throw new Error(pt(Ki))}(t),e.addPlugin(new xs(e)),e.addInteractor?.("particlesLinks",t=>Promise.resolve(new bs(e,t)))})}const ks={background:{color:"#000000"},particles:{number:{value:100},links:{distance:125,enable:!0,triangles:{enable:!0,opacity:.1}},move:{enable:!0,speed:5},paint:{fill:{color:{value:"#ffffff"}}},size:{value:1},shape:{type:"circle"}}};async function zs(t){await t.pluginManager.register(async t=>{await Promise.all([Qi(t),(async t=>{await async function(t){t.checkVersion("4.5.1"),await t.pluginManager.register(t=>{const e=t,i=e.pluginManager;i.addPlugin(new cs(i)),i.initializers.interactors??=new Map,i.addInteractor=(t,e)=>{i.initialized||(i.initializers.interactors??=new Map,i.initializers.interactors.set(t,e))},i.setOnClickHandler=t=>{const{items:i}=e;if(!i.length)throw new Error(pt(Zi));i.forEach(e=>{const i=e;i.addClickHandler?.(t)})}})}(t),await Ms(t)})(t)]),t.pluginManager.addPreset("triangles",ks)})}const Cs=globalThis;Cs.loadTrianglesPreset=zs,Cs.tsParticles=li;function Ss(t,e,i){const s=e[i];void 0!==s&&(t[i]=(t[i]??1)*s)}class Is{#O;#L;#D;#_;#E;#u;#T;#R;#B;#F;#A;#U;#p;#$;#H;#q={};#V=[void 0,void 0];#W={};constructor(t,e,i){this.#p=t,this.#u=e,this.#_=i,this.#T=null,this.#O=null,this.#L=new Set,this.#H=[],this.#$=[],this.#D=[],this.#E=[],this.#B=[],this.#F=[],this.#A=[],this.#U={0:[],1:[],2:[],3:[],4:[],5:[],6:[],7:[]}}get settings(){return this.#R}canvasClear(){this.#u.actualOptions.clear&&this.draw(t=>{t.clearRect(p.x,p.y,this.#_.size.width,this.#_.size.height)})}clear(){const t=new Set;for(const e of this.#D)if(t.add(e),e.canvasClear?.())return e;for(const e of Object.values(jt))if("number"==typeof e)for(const i of this.#N(e))if(!t.has(i)&&(t.add(i),i.canvasClear?.()))return i;this.canvasClear()}destroy(){this.stop(),this.#O=null,this.#L.clear(),this.#H=[],this.#$=[],this.#D=[],this.#E=[],this.#B=[],this.#F=[],this.#A=[];for(const t of Object.values(jt))"number"==typeof t&&(this.#U[t]=[])}draw(t){const e=this.#T;if(e)return t(e)}drawParticle(t,e){if(t.spawning||t.destroyed)return;const i=t.getRadius();if(i<=0)return;const s=t.getFillColor(),n=t.getStrokeColor();let[a,o]=this.#j(t);if(a??=s,o??=n,!a&&!o)return;const r=this.#u,c=t.options.zIndex,l=1-t.zIndexFactor,{fillOpacity:h,opacity:d,strokeOpacity:u}=t.getOpacity(),p=this.#W,f=this.#q,g=a?ii(a,r.hdr,h*d,r.peakNits,r.hdrMode):void 0,y=o?ii(o,r.hdr,u*d,r.peakNits,r.hdrMode):g;p.a=p.b=p.c=p.d=void 0,f.fill=g,f.stroke=y,this.draw(s=>{for(const i of this.#A)i.drawParticleSetup?.(s,t,e);this.#G(s,t,i,d,f,p),this.#X({container:r,context:s,particle:t,delta:e,colorStyles:f,radius:i*l**c.sizeRate,opacity:d,transform:p}),this.#Y(t);for(const i of this.#F)i.drawParticleCleanup?.(s,t,e)})}drawParticlePlugins(t,e){this.draw(i=>{for(const s of this.#B)this.#Q(i,s,t,e)})}drawParticles(t){const{particles:e,actualOptions:i}=this.#u,s=this.clear();e.update(t),this.draw(n=>{const a=this.#_.size.width,o=this.#_.size.height;if(this.#O)try{n.drawImage(this.#O,p.x,p.y,a,o)}catch{this.#K("background-element-draw-error","Error drawing background element onto canvas")}const r=i.background;if(r.draw)try{r.draw(n,t)}catch{this.#K("background-draw-error","Error in background.draw callback")}for(const t of this.#N(jt.BackgroundMask))t!==s&&t.canvasPaint?.();for(const e of this.#N(jt.CanvasSetup))e.drawSettingsSetup?.(n,t);for(const e of this.#N(jt.PluginContent))e.draw?.(n,t);e.drawParticles(t);for(const e of this.#N(jt.CanvasCleanup))e.clearDraw?.(n,t),e.drawSettingsCleanup?.(n,t)})}init(){this.initUpdaters(),this.initPlugins(),this.#Z(),this.paint()}initPlugins(){this.#D=[],this.#E=[],this.#B=[],this.#A=[],this.#F=[];for(const t of Object.values(jt))"number"==typeof t&&(this.#U[t]=[]);this.#J()}initUpdaters(){this.#H=[],this.#$=[];for(const t of this.#u.particleUpdaters)t.afterDraw&&this.#$.push(t),(t.getColorStyles??t.getTransformValues??t.beforeDraw)&&this.#H.push(t)}paint(){let t=!1;for(const e of this.#N(jt.BackgroundMask))if(t=e.canvasPaint?.()??!1,t)break;t||this.paintBase()}paintBase(t){this.draw(e=>{e.fillStyle=t??"rgba(0,0,0,0)",e.fillRect(p.x,p.y,this.#_.size.width,this.#_.size.height)})}paintImage(t,e){this.draw(i=>{if(!t)return;const s=i.globalAlpha;i.globalAlpha=e,i.drawImage(t,p.x,p.y,this.#_.size.width,this.#_.size.height),i.globalAlpha=s})}setContext(t){this.#T=t,this.#T&&(this.#T.globalCompositeOperation=c)}setContextSettings(t){this.#R=t}stop(){this.draw(t=>{t.clearRect(p.x,p.y,this.#_.size.width,this.#_.size.height)})}#Y(t){for(const e of this.#$)e.afterDraw?.(t)}#G(t,e,i,s,n,a){for(const o of this.#H){if(o.getColorStyles){const{fill:a,stroke:r}=o.getColorStyles(e,t,i,s);a&&(n.fill=a),r&&(n.stroke=r)}if(o.getTransformValues){const t=o.getTransformValues(e);for(const e in t)Ss(a,t,e)}o.beforeDraw?.(e)}}#tt(t,e){if(!t?.drawAfter)return;const{particle:i}=e;i.effect&&t.drawAfter(e)}#et(t,e){if(!t?.drawBefore)return;const{particle:i}=e;i.effect&&t.drawBefore(e)}#X(t){const{container:e,context:i,particle:s,delta:n,colorStyles:a,radius:o,opacity:r,transform:c}=t,{effectDrawers:l,shapeDrawers:h}=e,d=s.getPosition(),u=s.getTransformData(c),p={x:d.x,y:d.y};i.setTransform(u.a,u.b,u.c,u.d,d.x,d.y),a.fill&&(i.fillStyle=a.fill);const f=!!s.fillEnabled,g=s.strokeWidth??0;i.lineWidth=g,a.stroke&&(i.strokeStyle=a.stroke);const y={context:i,particle:s,radius:o,drawRadius:1*o,opacity:r,delta:n,pixelRatio:e.retina.pixelRatio,fill:f,stroke:g>0,transformData:u,position:{...d},drawPosition:p,drawScale:1};for(const t of e.plugins)t.drawParticleTransform?.(y);const m=s.effect?l.get(s.effect):void 0,v=s.shape?h.get(s.shape):void 0;this.#et(m,y),this.#it(v,y),this.#st(v,y),this.#nt(v,y),this.#tt(m,y),i.resetTransform()}#Q(t,e,i,s){e.drawParticle&&e.drawParticle(t,i,s)}#st(t,e){if(!t)return;const{context:i,fill:s,particle:n,stroke:a}=e;n.shape&&(i.beginPath(),t.draw(e),n.shapeClose&&i.closePath(),s&&i.fill(),a&&i.stroke())}#nt(t,e){if(!t?.afterDraw)return;const{particle:i}=e;i.shape&&t.afterDraw(e)}#it(t,e){if(!t?.beforeDraw)return;const{particle:i}=e;i.shape&&t.beforeDraw(e)}#N(t){return this.#U[t]}#j(t){let e,i;for(const s of this.#E)if(!e&&s.particleFillColor&&(e=Qe(this.#p,s.particleFillColor(t))),!i&&s.particleStrokeColor&&(i=Qe(this.#p,s.particleStrokeColor(t))),e&&i)break;return this.#V[0]=e,this.#V[1]=i,this.#V}#at(t){const e=[[jt.BackgroundMask,!!t.canvasPaint],[jt.CanvasSetup,!!t.drawSettingsSetup],[jt.PluginContent,!!t.draw],[jt.CanvasCleanup,!!(t.clearDraw??t.drawSettingsCleanup)]];for(const[i,s]of e)s&&this.#U[i].push(t)}#J(){for(const t of this.#u.plugins)(t.particleFillColor??t.particleStrokeColor)&&this.#E.push(t),t.drawParticle&&this.#B.push(t),t.drawParticleSetup&&this.#A.push(t),t.drawParticleCleanup&&this.#F.push(t),t.canvasClear&&this.#D.push(t),this.#at(t)}#ot(t){return"undefined"!=typeof HTMLCanvasElement&&t instanceof HTMLCanvasElement||"undefined"!=typeof OffscreenCanvas&&t instanceof OffscreenCanvas||"undefined"!=typeof HTMLVideoElement&&t instanceof HTMLVideoElement||"undefined"!=typeof HTMLImageElement&&t instanceof HTMLImageElement}#Z(){const t=this.#u.actualOptions.background;if(this.#O=null,t.element)if("string"==typeof t.element){if("undefined"!=typeof document){const e=document.querySelector(t.element);e&&this.#ot(e)?this.#O=e:e?this.#K("background-element-not-supported",`Background element "${t.element}" is not a supported drawable element (canvas, video, or img)`):this.#K("background-element-not-found",`Background element selector "${t.element}" not found`)}}else this.#ot(t.element)&&(this.#O=t.element)}#K(t,e){this.#L.has(t)||(this.#L.add(t),n().warning(e))}}const Os=new WeakMap;function Ls(t,e,i=!1){if(!e)return;const s=t.style,n=new Set;for(let t=0;t<s.length;t++){const e=s.item(t);e&&n.add(e)}for(let t=0;t<e.length;t++){const i=e.item(t);i&&n.add(i)}for(const t of n){const n=e.getPropertyValue(t);n?s.setProperty(t,n,i?"important":""):s.removeProperty(t)}}class Ds{domElement;render;renderCanvas;size;zoom=1;#u;#rt;#ct;#lt;#ht;#p;#dt;#ut;#pt;#ft;constructor(t,e){this.#p=t,this.#u=e,this.render=new Is(t,e,this),this.#pt={height:0,width:0};const i=e.retina.pixelRatio,s=this.#pt;this.size={height:s.height*i,width:s.width*i},this.#rt=!1,this.#ut=[],this.#dt="none"}get#gt(){return this.#u.actualOptions.fullScreen.enable}destroy(){if(this.stop(),this.#rt){const t=this.domElement;t?.remove(),this.domElement=void 0,this.renderCanvas=void 0}else this.#yt();this.render.destroy(),this.#ut=[]}getZoomCenter(){const t=this.#u.retina.pixelRatio,{width:e,height:i}=this.size;return this.#ft?this.#ft:{x:e*d/t,y:i*d/t}}init(){this.#mt(t=>{t.disconnect()}),this.#lt=function(t){if("undefined"!=typeof MutationObserver)return new MutationObserver(t)}(t=>{for(const e of t)"attributes"===e.type&&"style"===e.attributeName&&this.#vt()}),this.resize(),this.#wt(),this.#mt(t=>{const e=this.domElement;e&&e instanceof Node&&t.observe(e,{attributes:!0})}),this.initPlugins(),this.#Pt(),this.initBackground(),this.#bt(),this.render.init()}initBackground(){const t=this.#u,e=t.actualOptions.background,i=this.domElement;if(!i)return;const s=i.style,n=Xe(this.#p,e.color);if(n){const i=t.actualOptions.hdr;s.backgroundColor=ei(n,t.hdr,e.opacity,i.peakNits,F(Ft,i.mode,Ft.standard))}else s.backgroundColor="";s.backgroundImage=e.image||"",s.backgroundPosition=e.position||"",s.backgroundRepeat=e.repeat||"",s.backgroundSize=e.size||""}initPlugins(){this.#ut=[];for(const t of this.#u.plugins)t.resize&&this.#ut.push(t)}loadCanvas(t){this.#rt&&this.domElement&&this.domElement.remove();const e=(t=>"undefined"!=typeof HTMLCanvasElement&&t instanceof HTMLCanvasElement)(t)?t:void 0;this.domElement=e,this.#rt=!!e&&"true"===e.dataset[o],this.renderCanvas=e?(t=>{const e=Os.get(t);if(e)return e;if("function"!=typeof t.transferControlToOffscreen)throw new TypeError(pt(ct));try{const e=t.transferControlToOffscreen();return Os.set(t,e),e}catch{throw new TypeError(pt(lt))}})(e):t;const i=this.domElement;i&&(i.ariaHidden="true",this.#ht=function(t){const e=mt().createElement("div").style;for(const i in t){const s=t[i];if(!(i in t)||$(s))continue;const n=t.getPropertyValue?.(s);if(!n)continue;const a=t.getPropertyPriority?.(s);a?e.setProperty(s,n,a):e.setProperty(s,n)}return e}(i.style));const s=this.#pt,n=this.renderCanvas;i?(s.height=i.offsetHeight,s.width=i.offsetWidth):(s.height=n.height,s.width=n.width);const a=this.#u.retina.pixelRatio,r=this.size;n.height=r.height=s.height*a,n.width=r.width=s.width*a}resize(){const t=this.domElement;if(!t)return!1;const e=this.#u,i=this.renderCanvas;if(void 0===i)return!1;const s=e.canvas.#pt,n={width:t.offsetWidth,height:t.offsetHeight},a=e.retina.pixelRatio,o={width:n.width*a,height:n.height*a};if(n.height===s.height&&n.width===s.width&&o.height===i.height&&o.width===i.width)return!1;const r={...s};s.height=n.height,s.width=n.width;const c=this.size;return i.width=c.width=o.width,i.height=c.height=o.height,this.#u.started&&e.particles.setResizeFactor({width:s.width/r.width,height:s.height/r.height}),!0}setPointerEvents(t){this.domElement&&(this.#dt=t,this.#vt())}setZoom(t,e){this.zoom=t,this.#ft=e}stop(){this.#mt(t=>{t.disconnect()}),this.#lt=void 0,this.#xt(),this.render.stop()}async windowResize(){if(!this.domElement||!this.resize())return;const t=this.#u,e=t.updateActualOptions();t.particles.setDensity(),this.#Mt(),e&&await t.refresh()}#Mt(){for(const t of this.#ut)t.resize?.()}#Pt(){const t=this.#u,e=t.actualOptions.hdr.enable&&vt("(color-gamut: p3)")?.matches&&vt("(dynamic-range: high)")?.matches;t.hdrMode=F(Ft,t.actualOptions.hdr.mode,Ft.standard),t.peakNits=t.actualOptions.hdr.peakNits;const i=this.renderCanvas;if(!i)return void(t.hdr=e??!1);let s;this.render.setContextSettings({alpha:!0,desynchronized:!0,willReadFrequently:!1,...e?{colorSpace:"display-p3",colorType:"float16"}:{colorSpace:"srgb"}});try{s=i.getContext("2d",this.render.settings)}catch{s=null}if(e&&!s){const t={alpha:!0,desynchronized:!0,willReadFrequently:!1,colorSpace:"srgb"};this.render.setContextSettings(t);try{s=i.getContext("2d",t)}catch{s=null}}if(this.render.setContext(s),s){const e=(t=>{if(!t)return;const e=t;return e.getContextAttributes?.().colorSpace??void 0})(s);void 0!==e&&(t.hdr="display-p3"===e)}}#bt(){this.#xt();const t=vt("(color-gamut: p3)"),e=vt("(dynamic-range: high)"),i=()=>{this.#Pt(),this.initBackground()},s=[];t&&(t.addEventListener("change",i),s.push({handler:i,mql:t})),e&&(e.addEventListener("change",i),s.push({handler:i,mql:e})),this.#ct=s}#wt(){const t=this.domElement,e=this.#u.actualOptions;if(t){this.#gt?this.#kt():this.#yt();for(const i in e.style){if(!i||!(i in e.style))continue;const s=e.style[i];s&&t.style.setProperty(i,s,"important")}}}#xt(){if(this.#ct){for(const{handler:t,mql:e}of this.#ct)e.removeEventListener("change",t);this.#ct=void 0}}#vt(){const t=this.domElement;if(!t)return;this.#mt(t=>{t.disconnect()}),this.#wt(),this.initBackground();const e=this.#dt;t.style.pointerEvents=e,t.style.setProperty("pointer-events",e),this.#mt(e=>{t instanceof Node&&e.observe(t,{attributes:!0})})}#yt(){const t=this.domElement,e=this.#ht;t&&e&&Ls(t,e,!0)}#mt(t){this.#lt&&t(this.#lt)}#kt(){const t=this.domElement;t&&Ls(t,function(t){if(Ct!==t||!St){Ct=t;const e=mt().createElement("div").style,i=10,s={width:"100%",height:"100%",margin:"0",padding:"0",borderWidth:"0",position:"fixed",zIndex:t.toString(i),"z-index":t.toString(i),top:"0",left:"0","pointer-events":"none"};for(const t in s){const i=s[t];void 0!==i&&e.setProperty(t,i)}St=e}return St}(this.#u.actualOptions.fullScreen.zIndex),!0)}}class _s{#u;#zt;#Ct;#St;constructor(t){this.#u=t,this.#zt={visibilityChange:()=>{this.#It()},resize:()=>{this.#Ot()}}}addListeners(){this.#Lt(!0)}removeListeners(){void 0!==this.#St&&(clearTimeout(this.#St),this.#St=void 0),this.#Lt(!1)}#It(){const t=this.#u;t.actualOptions.pauseOnBlur&&(mt().hidden?(t.pageHidden=!0,t.pause()):(t.pageHidden=!1,t.animationStatus?t.play(!0):t.draw(!0)))}#Ot(){this.#St&&(clearTimeout(this.#St),this.#St=void 0);const t=async()=>{await this.#u.canvas.windowResize()};this.#St=setTimeout(()=>{t()},this.#u.actualOptions.resize.delay*u)}#Lt(t){const e=this.#zt;this.#Dt(t),It(document,l,e.visibilityChange,t,!1)}#Dt(t){const e=this.#zt,i=this.#u;if(!i.actualOptions.resize.enable)return;if("undefined"==typeof ResizeObserver)return void It(globalThis,"resize",e.resize,t);const s=i.canvas.domElement;this.#Ct&&!t?(s&&this.#Ct.unobserve(s),this.#Ct.disconnect(),this.#Ct=void 0):!this.#Ct&&t&&s&&(this.#Ct=new ResizeObserver(t=>{t.some(t=>t.target===s)&&this.#Ot()}),this.#Ct.observe(s))}}function Es(t){if(e=t.outMode,i=t.checkModes,!(e===i||U(i)&&i.includes(e)))return;var e,i;const s=2*t.radius;t.coord>t.maxCoord-s?t.setCb(-t.radius):t.coord<s&&t.setCb(t.radius)}function Ts(t,e){const i=t%e;return i<0?i+e:i}function Rs(t,e,i,s){const n=Be(i,e,e.actualOptions.particles),a=n.reduceDuplicates;t.effect=kt(n.effect.type,t.id,a),t.shape=kt(n.shape.type,t.id,a);const o=n.effect,r=n.shape;if(s){if(s.effect){const e=s.effect.type;if(e&&e!==t.effect){const i=kt(e,t.id,a);i&&(t.effect=i)}o.load(s.effect)}if(s.shape){const e=s.shape.type;if(e&&e!==t.shape){const i=kt(e,t.id,a);i&&(t.shape=i)}r.load(s.shape)}}if(t.effect===v){const i=[...e.effectDrawers.keys()];t.effect=i[Math.floor(N()*i.length)]}if(t.shape===v){const i=[...e.shapeDrawers.keys()];t.shape=i[Math.floor(N()*i.length)]}t.effectData=t.effect?function(t,e,i,s){const n=e.options[t];return xt({close:e.close},kt(n,i,s))}(t.effect,o,t.id,a):void 0,t.shapeData=t.shape?function(t,e,i,s){const n=e.options[t];return xt({close:e.close},kt(n,i,s))}(t.shape,r,t.id,a):void 0,n.load(s);const c=t.effectData,l=t.shapeData;return c&&n.load(c.particles),l&&n.load(l.particles),t.effectClose=c?.close??n.effect.close,t.shapeClose=l?.close??n.shape.close,n}class Bs{backColor;destroyed;direction;effect;effectClose;effectData;fillColor;fillEnabled;fillOpacity;group;id;ignoresResizeRatio;initialPosition;initialVelocity;isRotating;justWarped;lastPathTime;misplaced;moveCenter;offset;opacity;options;outType;pathRotation;position;randomIndexData;retina;roll;rotation;shape;shapeClose;shapeData;sides;size;spawning;strokeColor;strokeOpacity;strokeWidth;unbreakable;velocity;zIndexFactor;#_t={fillOpacity:1,opacity:1,strokeOpacity:1};#Et=D.origin;#Tt={sin:0,cos:0};#Rt={a:1,b:0,c:0,d:1};#u;#Bt=[];#p;constructor(t,e){this.#p=t,this.#u=e}addModifier(t){this.#Bt.push(t),this.#Bt.sort((t,e)=>t.priority-e.priority)}clearModifiers(){this.#Bt.length=0}destroy(t){if(this.unbreakable||this.destroyed)return;this.destroyed=!0,this.clearModifiers();const e=this.#u,i=this.shape?e.shapeDrawers.get(this.shape):void 0;i?.particleDestroy?.(this);for(const i of e.particleDestroyedPlugins)i.particleDestroyed?.(this,t);for(const i of e.particleUpdaters)i.particleDestroyed?.(this,t);this.#u.dispatchEvent(Et.particleDestroyed,{particle:this})}draw(t){const e=this.#u.canvas.render;e.drawParticlePlugins(this,t),e.drawParticle(this,t)}getAngle(){return this.rotation+(this.pathRotation?this.velocity.angle:0)}getFillColor(){return this.#Ft(this.#At(ni(this.fillColor),t=>t.fillColor))}getMass(){return this.getRadius()**2*Math.PI*d}getModifier(t){return this.#Bt.find(e=>e.id===t)}getOpacity(){const t=this.options.zIndex,e=(1-this.zIndexFactor)**t.opacityRate,i=Q(this.opacity?.value??1),s=this.#At(void 0,t=>t.opacity)??i;return this.#_t.fillOpacity=this.fillOpacity??1,this.#_t.opacity=s*e,this.#_t.strokeOpacity=this.strokeOpacity??1,this.#_t}getPosition(){return this.#Et.x=this.position.x+this.offset.x,this.#Et.y=this.position.y+this.offset.y,this.#Et.z=this.position.z,this.#Et}getRadius(){return this.#At(this.size.value,t=>t.radius)}getRotateData(){const t=this.getAngle();return this.#Tt.sin=Math.sin(t),this.#Tt.cos=Math.cos(t),this.#Tt}getStrokeColor(){return this.#Ft(this.#At(ni(this.strokeColor),t=>t.strokeColor))}getTransformData(t){const e=this.getRotateData(),i=this.isRotating;return this.#Rt.a=e.cos*(t.a??f),this.#Rt.b=i?e.sin*(t.b??1):t.b??g,this.#Rt.c=i?-e.sin*(t.c??1):t.c??y,this.#Rt.d=e.cos*(t.d??m),this.#Rt}init(t,e,i,s){const n=this.#u;!function(t,e,i){t.id=e,t.group=i,t.justWarped=!1,t.effectClose=!0,t.shapeClose=!0,t.pathRotation=!1,t.lastPathTime=0,t.destroyed=!1,t.unbreakable=!1,t.isRotating=!1,t.rotation=0,t.misplaced=!1,t.retina={maxDistance:{},maxSpeed:0,moveDrift:0,moveSpeed:0,sizeAnimationSpeed:0},t.size={value:1,max:1,min:1,enable:!1},t.outType=Vt.normal,t.ignoresResizeRatio=!0}(this,t,s),this.options=Rs(this,n,this.#p,i),n.retina.initParticle(this),function(t,e){for(const i of t)i.preInit?.(e)}(n.particleUpdaters,this),this.#Ut(e),this.initialVelocity=this.#$t(),this.velocity=this.initialVelocity.copy(),this.zIndexFactor=this.position.z/n.zLayers,this.sides=24,function(t,e){let i,s;t.effect&&(i=e.effectDrawers.get(t.effect)),i?.loadEffect&&i.loadEffect(t),t.shape&&(s=e.shapeDrawers.get(t.shape)),s?.loadShape&&s.loadShape(t);const n=s?.getSidesCount;n&&(t.sides=n(t))}(this,n),this.spawning=!1,function(t,e){for(const i of t)i.init(e)}(n.particleUpdaters,this),function(t,e){const i=e.shape?t.shapeDrawers.get(e.shape):void 0,s=e.effect?t.effectDrawers.get(e.effect):void 0;s?.particleInit?.(t,e),i?.particleInit?.(t,e)}(n,this),function(t,e){for(const i of t.particleCreatedPlugins)i.particleCreated?.(e)}(n,this)}isInsideCanvas(t){return this.#Ht({direction:t}).inside}isInsideCanvasForOutMode(t,e){return this.#Ht({direction:e,outMode:t}).inside}isShowingBack(){if(!this.roll)return!1;const t=this.roll.angle;if(this.roll.horizontal&&this.roll.vertical){const e=Ts(t,P);return e>=Math.PI*d&&e<3*Math.PI*d}if(this.roll.horizontal){const e=Ts(t+Math.PI*d,P);return e>=Math.PI&&e<2*Math.PI}if(this.roll.vertical){const e=Ts(t,P);return e>=Math.PI&&e<2*Math.PI}return!1}isVisible(){return!this.destroyed&&!this.spawning&&this.isInsideCanvas()}removeModifier(t){const e=this.#Bt.findIndex(e=>e.id===t);e>=0&&this.#Bt.splice(e,1)}reset(){for(const t of this.#u.particleUpdaters)t.reset?.(this)}#At(t,e){let i=t;for(const t of this.#Bt)if(t.enabled){const s=e(t);void 0!==s&&(i=s)}return i}#qt(t,e){let i=0,s=t?D.create(t.x,t.y,e):void 0;const n=this.#u,a=n.particlePositionPlugins,o=this.options.move.outModes,r=this.getRadius(),c=n.canvas.size;for(;;){for(const t of a){const i=t.particlePosition?.(s,this);if(i)return D.create(i.x,i.y,e)}const t=st({size:c,position:s}),l=D.create(t.x,t.y,e);this.#Vt(l,r,o.left??o.default),this.#Vt(l,r,o.right??o.default),this.#Wt(l,r,o.top??o.default),this.#Wt(l,r,o.bottom??o.default);let h=!0;for(const t of n.particles.checkParticlePositionPlugins)if(h=t.checkParticlePosition?.(this,l,i)??!0,!h)break;if(h)return l;i+=1,s=void 0}}#$t(){const t=this.options.move,e=function(t){const e=_.origin;return e.length=1,e.angle=t,e}(this.direction).copy();if(t.direction===a.inside||t.direction===a.outside)return e;const i=it(Q(t.angle.value)),s=it(Q(t.angle.offset)),n={left:s-i*d,right:s+i*d};return t.straight||(e.angle+=Y(J(n.left,n.right))),t.random&&"number"==typeof t.speed&&(e.length*=N()),e}#Vt(t,e,i){Es({outMode:i,checkModes:[Ut.bounce],coord:t.x,maxCoord:this.#u.canvas.size.width,setCb:e=>t.x+=e,radius:e})}#Wt(t,e,i){Es({outMode:i,checkModes:[Ut.bounce],coord:t.y,maxCoord:this.#u.canvas.size.height,setCb:e=>t.y+=e,radius:e})}#Nt(t,e){const i=this.getRadius(),s=this.#u.canvas.size,n=this.position,a=e===Ut.bounce;return t===ft.bottom?{inside:a?n.y+i<s.height:n.y-i<s.height,reason:"default"}:t===ft.left?{inside:a?n.x-i>0:n.x+i>0,reason:"default"}:t===ft.right?{inside:a?n.x+i<s.width:n.x-i<s.width,reason:"default"}:t===ft.top?{inside:a?n.y-i>0:n.y+i>0,reason:"default"}:{inside:n.x>=-i&&n.y>=-i&&n.y<=s.height+i&&n.x<=s.width+i,reason:"default"}}#jt(t,e){return{canvasSize:this.#u.canvas.size,direction:t,outMode:e,particle:this,radius:this.getRadius()}}#Ht(t){const e=this.#Nt(t.direction,t.outMode),i=this.#u,s=this.shape?i.shapeDrawers.get(this.shape):void 0,n=this.effect?i.effectDrawers.get(this.effect):void 0,a=s?.isInsideCanvas,o=n?.isInsideCanvas;if(!a&&!o)return e;const r=this.#jt(t.direction,t.outMode),c=a?this.#Gt(a(r),"shape"):void 0,l=o?this.#Gt(o(r),"effect"):void 0;if(c&&l){const t=Math.max(c.margin??0,l.margin??0);return{inside:c.inside&&l.inside,margin:t>0?t:void 0,reason:"combined"}}return c??l??e}#Ft(t){return t&&this.roll&&(this.backColor||this.roll.alter)&&this.isShowingBack()?this.backColor?this.backColor:this.roll.alter?function(t,e,i){return{h:t.h,s:t.s,l:t.l+(e===$t.darken?-1:1)*i}}(t,this.roll.alter.type,this.roll.alter.value):t:t}#Ut(t){const e=this.#u,i=Math.floor(Q(this.options.zIndex.value)),s=this.#qt(t,G(i,0,e.zLayers));if(!s)throw new Error(pt(ot));this.position=s,this.initialPosition=this.position.copy();const n=e.canvas.size;switch(this.moveCenter={...zt(this.options.move.center,n),radius:this.options.move.center.radius,mode:this.options.move.center.mode},this.direction=function(t,e,i){if(R(t))return it(t);switch(t){case a.top:return-Math.PI*d;case a.topRight:return-Math.PI*I;case a.right:return 0;case a.bottomRight:return Math.PI*I;case a.bottom:return Math.PI*d;case a.bottomLeft:return.75*Math.PI;case a.left:return Math.PI;case a.topLeft:return.75*-Math.PI;case a.inside:return Math.atan2(i.y-e.y,i.x-e.x);case a.outside:return Math.atan2(e.y-i.y,e.x-i.x);default:return N()*P}}(this.options.move.direction,this.position,this.moveCenter),this.options.move.direction){case a.inside:this.outType=Vt.inside;break;case a.outside:this.outType=Vt.outside}this.offset=_.origin}#Gt(t,e){return"boolean"==typeof t?{inside:t,reason:e}:{inside:t.inside,margin:t.margin,reason:t.reason??e}}}class Fs{#Xt;#Yt=new Map;#Qt=[];#Kt;#Zt;#Jt=[];#te;constructor(t){this.#Xt=t,this.#Kt=0,this.#te=0}get cellSize(){return this.#Xt}set cellSize(t){this.#Zt=t}clear(){this.#Yt.clear();const t=this.#Zt;t&&(this.#Xt=t),this.#Zt=void 0}insert(t){const{x:e,y:i}=t.getPosition(),s=this.#ee(e,i);this.#Yt.has(s)||this.#Yt.set(s,[]),this.#Yt.get(s)?.push(t)}query(t,e,i=[]){const s=this.#ie(t);if(!s)return i;const n=Math.floor(s.minX/this.#Xt),a=Math.floor(s.maxX/this.#Xt),o=Math.floor(s.minY/this.#Xt),r=Math.floor(s.maxY/this.#Xt);for(let s=n;s<=a;s++)for(let n=o;n<=r;n++)this.#se(s,n,t,e,i);return i}queryCircle(t,e,i,s=[]){const n=this.#ne(t.x,t.y,e);try{return this.query(n,i,s)}finally{this.#Kt--}}queryRectangle(t,e,i,s=[]){const n=this.#ae(t.x,t.y,e.width,e.height);try{return this.query(n,i,s)}finally{this.#te--}}#ne(t,e,i){const s=this.#Kt++;let n=this.#Qt[s];return n||(n=new Qt(t,e,i),this.#Qt[s]=n),n.reset(t,e,i)}#ae(t,e,i,s){const n=this.#te++;let a=this.#Jt[n];return a||(a=new Kt(t,e,i,s),this.#Jt[n]=a),a.reset(t,e,i,s)}#ee(t,e){return`${Math.floor(t/this.#Xt)}_${Math.floor(e/this.#Xt)}`}#ie(t){if(t instanceof Qt){const e=t.radius,{x:i,y:s}=t.position;return{minX:i-e,maxX:i+e,minY:s-e,maxY:s+e}}if(t instanceof Kt){const{x:e,y:i}=t.position,{width:s,height:n}=t.size;return{minX:e,maxX:e+s,minY:i,maxY:i+n}}return null}#se(t,e,i,s,n){const a=this.#Yt.get(`${t}_${e}`);if(a)for(const t of a)s&&!s(t)||i.contains(t.getPosition())&&n.push(t)}}class As{checkParticlePositionPlugins;#oe;#u;#re;#ce;#le;#he;#de;#ue;#pe;#p;#fe;#ge;#ye;#me;#ve;#we;constructor(t,e){this.#p=t,this.#u=e,this.#he=0,this.#oe=[],this.#fe=[],this.#le=0,this.#ce=new Map,this.#de=new Map,this.#we=this.#Pe(this.#u.zLayers),this.#re=new Fs(100),this.checkParticlePositionPlugins=[],this.#ue=[],this.#pe=[],this.#ye=[],this.#ge=[],this.#ve=[]}get count(){return this.#oe.length}get grid(){return this.#re}addParticle(t,e,i,s){if(!this.#be(i,this.count))try{const n=this.#fe.pop()??new Bs(this.#p,this.#u);n.init(this.#he,t,e,i);let a=!0;return s&&(a=s(n)),a?(this.#oe.push(n),this.#xe(n),this.#he++,this.#u.dispatchEvent(Et.particleAdded,{particle:n}),n):void this.#fe.push(n)}catch(t){n().warning(`error adding particle: ${t}`)}}clear(){this.#oe=[],this.#de.clear(),this.#Me(this.#u.zLayers)}destroy(){this.#oe=[],this.#fe.length=0,this.#de.clear(),this.#we=[],this.checkParticlePositionPlugins=[],this.#ue=[],this.#pe=[],this.#ye=[],this.#ge=[],this.#ve=[]}drawParticles(t){for(let e=this.#we.length-1;e>=0;e--){const i=this.#we[e];if(i)for(const e of i)e.draw(t)}}filter(t){return this.#oe.filter(t)}find(t){return this.#oe.find(t)}get(t){return this.#oe[t]}async init(){const t=this.#u;this.checkParticlePositionPlugins=[],this.#ve=[],this.#pe=[],this.#ye=[],this.#ue=[],this.#ge=[],this.#de.clear(),this.#Me(t.zLayers),this.#re=new Fs(100*t.retina.pixelRatio),this.#ke(t.actualOptions.particles);const e=t.actualOptions.particles.groups;for(const t in e){const i=e[t];i&&this.#ke(Be(this.#p,this.#u,i),t,i)}await this.#ze()}push(t,e,i,s){for(let n=0;n<t;n++)this.addParticle(e,i,s)}async redraw(){this.clear(),await this.init(),this.#u.canvas.render.drawParticles({value:0,factor:0})}remove(t,e,i){this.removeAt(this.#oe.indexOf(t),void 0,e,i)}removeAt(t,e=1,i,s,n=!0){if(t<0||t>this.count)return;let a=0;for(let o=t;a<e&&o<this.count;o++)this.#Ce(o,i,s,n)&&(o--,a++)}removeQuantity(t,e){this.removeAt(0,t,e)}setDensity(){const t=this.#u.actualOptions,e=t.particles.groups;let i=0;for(const t of this.#u.plugins)t.particlesDensityCount&&(i+=t.particlesDensityCount());for(const t in e){const s=e[t];if(!s)continue;const n=Be(this.#p,this.#u,s);this.#Se(n,i,t)}this.#Se(t.particles,i)}setResizeFactor(t){this.#me=t}update(t){this.#re.clear();for(const e of this.#ve)e.update?.(t);const e=this.#Ie(t);for(const e of this.#ye)e.postUpdate?.(t);if(this.#Oe(t,e),e.size)for(const t of e)this.remove(t,t.group);this.#me=void 0}#Le(...t){this.#fe.push(...t)}#Se(t,e,i,s){const n=t.number;if(!n.density.enable)return void this.#ke(t,i,s);const a=this.#De(n.density),o=n.value,r=n.limit.value>0?n.limit.value:o,c=Math.min(o,r)*a+e,l=Math.min(this.count,this.filter(t=>t.group===i).length);void 0===i?this.#le=n.limit.value*a:this.#ce.set(i,{limit:n.limit.value*a,mode:F(At,n.limit.mode,At.delete)}),l<c?this.push(Math.abs(c-l),void 0,t,i):l>c&&this.removeQuantity(l-c,i)}#ke(t,e,i){if(void 0===e){this.#le=t.number.limit.value;const e=this.#u.actualOptions.particles.groups;for(const t of this.#ce.keys())t in e||this.#ce.delete(t)}else{const s=i?.number?.limit?.value??t.number.limit.value;s>0?this.#ce.set(e,{limit:s,mode:F(At,i?.number?.limit?.mode??t.number.limit.mode,At.delete)}):this.#ce.delete(e)}}#be(t,e){const i=this.#le,s=this.#u.actualOptions.particles.number.limit.mode;if(i>0&&s===At.wait&&e>=i)return!0;const n=void 0===t?void 0:this.#ce.get(t);if(n&&n.limit>0&&n.mode===At.wait){if(this.filter(e=>e.group===t).length>=n.limit)return!0}if(n&&n.limit>0&&n.mode===At.delete){const e=this.filter(e=>e.group===t).length+1-n.limit;e>0&&this.removeQuantity(e,t)}if(i>0&&s===At.delete){const t=this.count+1-i;t>0&&this.#_e(t)}return!1}#Pe(t){const e=Math.max(Math.floor(t),1);return Array.from({length:e},()=>[])}#Ee(t){const e=this.#we.length-1;return e<=0?0:Math.min(Math.max(Math.floor(t),0),e)}#De(t){const e=this.#u;if(!t.enable)return 1;const i=e.canvas.size,s=e.retina.pixelRatio;return i.width&&i.height?i.width*i.height/(t.height*t.width*s**2):1}async#Te(){const t=this.#u;await t.initDrawersAndUpdaters();for(const e of t.effectDrawers.values())await(e.init?.(t));for(const e of t.shapeDrawers.values())await(e.init?.(t))}async#ze(){await this.#Re(),await this.#Te();let t=!1;const e=this.#u;for(const i of e.plugins)if(t=i.particlesInitialization?.()??t,t)break;if(t)return;const i=e.actualOptions.particles,s=i.groups;for(const t in s){const e=s[t];if(e)for(let s=this.count,n=0;n<e.number.value&&s<i.number.value;s++,n++)this.addParticle(void 0,e,t)}for(let t=this.count;t<i.number.value;t++)this.addParticle()}async#Re(){const t=this.#u;for(const e of t.plugins)e.redrawInit&&await e.redrawInit(),e.checkParticlePosition&&this.checkParticlePositionPlugins.push(e),e.update&&this.#ve.push(e),e.particleUpdate&&this.#pe.push(e),e.postUpdate&&this.#ye.push(e),e.particleReset&&this.#ue.push(e),e.postParticleUpdate&&this.#ge.push(e)}#xe(t){const e=this.#Ee(t.position.z),i=this.#we[e];i&&(i.push(t),this.#de.set(t.id,e))}#_e(t){this.removeAt(0,t,void 0,void 0,!1)}#Ce(t,e,i,s=!0){const n=this.#oe[t];return!!n&&((!s||n.group===e)&&(this.#oe.splice(t,1),this.#Be(n),n.destroy(i),this.#u.dispatchEvent(Et.particleRemoved,{particle:n}),this.#Le(n),!0))}#Be(t){const e=this.#de.get(t.id)??this.#Ee(t.position.z),i=this.#we[e];if(!i)return void this.#de.delete(t.id);const s=i.findIndex(e=>e.id===t.id);s>=0&&i.splice(s,1),this.#de.delete(t.id)}#Me(t){const e=Math.max(Math.floor(t),1);if(this.#we.length===e)for(const t of this.#we)t.length=0;else this.#we=this.#Pe(e)}#Fe(t){const e=this.#Ee(t.position.z),i=this.#de.get(t.id);if(void 0===i)return void this.#xe(t);if(i===e)return;const s=this.#we[i];if(s){const e=s.findIndex(e=>e.id===t.id);e>=0&&s.splice(e,1)}const n=this.#we[e];if(n){if(n.push(t),n.length>=2){const e=n[n.length-2];e&&t.id<e.id&&n.sort((t,e)=>t.id-e.id)}this.#de.set(t.id,e)}else this.#de.set(t.id,e)}#Ie(t){const e=new Set,i=this.#me;for(const s of this.#oe){i&&!s.ignoresResizeRatio&&(s.position.x*=i.width,s.position.y*=i.height,s.initialPosition.x*=i.width,s.initialPosition.y*=i.height),s.ignoresResizeRatio=!1;for(const t of this.#ue)t.particleReset?.(s);for(const e of this.#pe){if(s.destroyed)break;e.particleUpdate?.(s,t)}s.destroyed?e.add(s):this.#re.insert(s)}return e}#Oe(t,e){for(const i of this.#oe)if(i.destroyed)e.add(i);else{for(const e of this.#u.particleUpdaters)e.update(i,t);if(!i.spawning)for(const e of this.#ge)e.postParticleUpdate?.(i,t);this.#Fe(i)}}}class Us{pixelRatio;reduceFactor;#u;constructor(t){this.#u=t,this.pixelRatio=1,this.reduceFactor=1}init(){const t=this.#u,e=t.actualOptions;this.pixelRatio=e.detectRetina?devicePixelRatio:1,this.reduceFactor=1;const i=this.pixelRatio,s=t.canvas,n=s.domElement;n&&(s.size.width=n.offsetWidth*i,s.size.height=n.offsetHeight*i)}initParticle(t){const e=t.options,i=this.pixelRatio,s=e.move,n=s.distance,a=t.retina;a.maxSpeed=Q(s.gravity.maxSpeed)*i,a.moveDrift=Q(s.drift)*i,a.moveSpeed=Q(s.speed)*i;const o=a.maxDistance;o.horizontal=void 0===n.horizontal?void 0:n.horizontal*i,o.vertical=void 0===n.vertical?void 0:n.vertical*i}}function $s(t){return!t.destroyed}function Hs(t,e,...i){const s=new Fe(t,e);return se(s,...i),s}var qs=Object.freeze({__proto__:null,Container:class{actualOptions;canvas;destroyed;effectDrawers;fpsLimit;hdr;hdrMode;id;pageHidden;particleCreatedPlugins;particleDestroyedPlugins;particlePositionPlugins;particleUpdaters;particles;peakNits;plugins;retina;shapeDrawers;started;zLayers;#Ae;#Ue;#$e;#He={value:0,factor:0};#qe;#Ve;#We;#Ne;#je;#Ge;#Xe;#Ye;#Qe;#Ke;#Ze;#p;#Je;#ti;constructor(t){const{dispatchCallback:e,pluginManager:i,id:s,onDestroy:n,sourceOptions:a}=t;this.#p=i,this.#qe=e,this.#Qe=n,this.id=Symbol(s),this.fpsLimit=120,this.hdr=!1,this.hdrMode=Ft.standard,this.peakNits=400,this.#Je=!1,this.#Ae=0,this.#We=0,this.#Ye=0,this.#je=!0,this.started=!1,this.destroyed=!1,this.#Ze=!0,this.#Xe=0,this.zLayers=100,this.pageHidden=!1,this.#ti=a,this.#Ge=a,this.effectDrawers=new Map,this.shapeDrawers=new Map,this.particleUpdaters=[],this.retina=new Us(this),this.canvas=new Ds(this.#p,this),this.particles=new As(this.#p,this),this.plugins=[],this.particleDestroyedPlugins=[],this.particleCreatedPlugins=[],this.particlePositionPlugins=[],this.#Ke=Hs(this.#p,this),this.actualOptions=Hs(this.#p,this),this.#Ne=new _s(this),this.dispatchEvent(Et.containerBuilt)}get animationStatus(){return!this.#Ze&&!this.pageHidden&&$s(this)}get options(){return this.#Ke}get sourceOptions(){return this.#ti}addLifeTime(t){this.#Ye+=t}alive(){return!this.#We||this.#Ye<=this.#We}destroy(t=!0){if($s(this)){this.stop(),this.particles.destroy(),this.canvas.destroy();for(const[,t]of this.effectDrawers)t.destroy?.(this);for(const[,t]of this.shapeDrawers)t.destroy?.(this);for(const t of this.plugins)t.destroy?.();this.effectDrawers=new Map,this.shapeDrawers=new Map,this.particleUpdaters=[],this.plugins.length=0,this.destroyed=!0,this.#Qe(t),this.dispatchEvent(Et.containerDestroyed)}}dispatchEvent(t,e){this.#qe(t,{container:this,data:e})}draw(t){if(!$s(this))return;let e=t;this.#Ve=V(t=>{e&&(this.#Xe=void 0,e=!1),this.#ei(t)})}async export(t,e={}){for(const i of this.plugins){if(!i.export)continue;const s=await i.export(t,e);if(s.supported)return s.blob}n().error(`Export plugin with type ${t} not found`)}async init(){if(!$s(this))return;const t=new Map;for(const e of this.#p.plugins){const i=await e.getPlugin(this);i.preInit&&await i.preInit(),t.set(e,i)}await this.initDrawersAndUpdaters(),this.#Ke=Hs(this.#p,this,this.#Ge,this.sourceOptions),this.actualOptions=Hs(this.#p,this,this.#Ke),this.#ze(t),this.retina.init(),this.canvas.init(),this.updateActualOptions(),this.canvas.initBackground(),this.canvas.resize();const{delay:e,duration:i,fpsLimit:s,smooth:n,zLayers:a}=this.actualOptions,o=this.actualOptions.hdr;this.hdrMode=F(Ft,o.mode,Ft.standard),this.peakNits=o.peakNits,this.zLayers=a,this.#We=Q(i)*u,this.#Ae=Q(e)*u,this.#Ye=0,this.fpsLimit=s>0?s:120,this.#Je=n;for(const t of this.plugins)await(t.init?.());await this.particles.init(),this.dispatchEvent(Et.containerInit),this.particles.setDensity();for(const t of this.plugins)t.particlesSetup?.();this.dispatchEvent(Et.particlesSetup)}async initDrawersAndUpdaters(){const t=this.#p;this.effectDrawers=await Lt(this,t.initializers.effects),this.shapeDrawers=await Lt(this,t.initializers.shapes),this.particleUpdaters=await Ot(this,t.initializers.updaters)}pause(){var t;if($s(this)&&(void 0!==this.#Ve&&(t=this.#Ve,W(t),this.#Ve=void 0),!this.#Ze)){for(const t of this.plugins)t.pause?.();this.pageHidden||(this.#Ze=!0),this.dispatchEvent(Et.containerPaused)}}play(t){if(!$s(this))return;const e=this.#Ze||t;if(!this.#je||this.actualOptions.autoPlay){if(this.#Ze&&(this.#Ze=!1),e)for(const t of this.plugins)t.play&&t.play();this.dispatchEvent(Et.containerPlay),this.draw(e??!1)}else this.#je=!1}async refresh(){if($s(this))return this.stop(),this.start()}async reset(t){if($s(this))return this.#Ge=t,this.#ti=t,this.#Ke=Hs(this.#p,this,this.#Ge,this.sourceOptions),this.actualOptions=Hs(this.#p,this,this.#Ke),this.refresh()}async start(){$s(this)&&!this.started&&(await this.init(),this.started=!0,await new Promise(t=>{this.#Ue=t;const e=async()=>{this.#$e=void 0,this.#Ue=void 0,this.#Ne.addListeners();for(const t of this.plugins)await(t.start?.());this.dispatchEvent(Et.containerStarted),this.play(),t()};this.#$e=setTimeout(()=>{e()},this.#Ae)}))}stop(){if($s(this)&&this.started){void 0!==this.#$e&&(clearTimeout(this.#$e),this.#$e=void 0,this.#Ue?.(),this.#Ue=void 0),this.#je=!0,this.started=!1,this.#Ne.removeListeners(),this.pause(),this.particles.clear(),this.canvas.stop();for(const t of this.plugins)t.stop?.();this.particleCreatedPlugins.length=0,this.particleDestroyedPlugins.length=0,this.particlePositionPlugins.length=0,this.#ti=this.#Ke,this.dispatchEvent(Et.containerStopped)}}updateActualOptions(){let t=!1;for(const e of this.plugins)e.updateActualOptions&&(t=e.updateActualOptions()||t);return t}#ze(t){this.plugins.length=0,this.particleDestroyedPlugins.length=0,this.particleCreatedPlugins.length=0,this.particlePositionPlugins.length=0;for(const[e,i]of t)e.needsPlugin(this.actualOptions)&&(this.plugins.push(i),i.particleCreated&&this.particleCreatedPlugins.push(i),i.particleDestroyed&&this.particleDestroyedPlugins.push(i),i.particlePosition&&this.particlePositionPlugins.push(i))}#ei(t){try{if(!this.#Je&&void 0!==this.#Xe&&t<this.#Xe+u/this.fpsLimit)return void this.draw(!1);if(this.#Xe??=t,function(t,e,i=60,s=!1){t.value=e,t.factor=s?60/i:60*e/u}(this.#He,t-this.#Xe,this.fpsLimit,this.#Je),this.addLifeTime(this.#He.value),this.#Xe=t,this.#He.value>u)return void this.draw(!1);if(this.canvas.render.drawParticles(this.#He),!this.alive())return void this.destroy();this.animationStatus&&this.draw(!1)}catch(t){n().error("error in animation loop",t)}}}});var Vs=Object.freeze({__proto__:null,BlendPluginInstance:class{layer=jt.CanvasSetup;#u;#ii;constructor(t){this.#u=t}drawParticleCleanup(t,e){e.options.blend?.enable&&(t.globalCompositeOperation=e.originalBlendMode??c,e.originalBlendMode=void 0)}drawParticleSetup(t,e){e.options.blend?.enable&&(e.originalBlendMode=t.globalCompositeOperation,t.globalCompositeOperation=e.options.blend.mode)}drawSettingsCleanup(t){this.#ii&&(t.globalCompositeOperation=this.#ii)}drawSettingsSetup(t){const e=t.globalCompositeOperation,i=this.#u.actualOptions.blend;this.#ii=e,t.globalCompositeOperation=i?.enable?i.mode:e}}});function Ws(t,e,i,s,n,a,o){!function(t,e){const i=t.options,s=i.move.path;if(!s.enable)return;const n=t.pathDelay??0;if(t.lastPathTime<=n)return void(t.lastPathTime+=e.value);const a=t.pathGenerator?.generate(t,e);a&&t.velocity.addTo(a);s.clamp&&(t.velocity.x=G(t.velocity.x,-1,1),t.velocity.y=G(t.velocity.y,-1,1));t.lastPathTime-=n}(t,o);const r=t.gravity,c=r?.enable&&r.inverse?-1:1;n&&i&&(t.velocity.x+=n*o.factor/(60*i)),r?.enable&&i&&(t.velocity.y+=c*(r.acceleration*o.factor)/(60*i));const l=t.moveDecay;t.velocity.multTo(l??1);const h=t.velocity.mult(i);r?.enable&&s>0&&(!r.inverse&&h.y>=0&&h.y>=s||r.inverse&&h.y<=0&&h.y<=-s)&&(h.y=c*s,i&&(t.velocity.y=h.y/i));const d=t.options.zIndex,u=(1-t.zIndexFactor)**d.velocityRate;h.multTo(u),h.multTo(a);const{position:p}=t;p.addTo(h),e.vibrate&&(p.x+=Math.sin(p.x*Math.cos(p.y))*a,p.y+=Math.cos(p.y*Math.sin(p.x))*a)}function Ns(t,e){const i=e.options.move.spin;if(!i.enable)return;const s=i.position??{x:50,y:50},n={x:.01*s.x*t.canvas.size.width,y:.01*s.y*t.canvas.size.height},a=e.getPosition(),o=(c=a,l=n,Math.sqrt(et(c,l))),r=Q(i.acceleration);var c,l;e.retina.spinAcceleration=r*t.retina.pixelRatio,e.spin={center:n,direction:e.velocity.x>=0?Rt.clockwise:Rt.counterClockwise,angle:N()*P,radius:o,acceleration:e.retina.spinAcceleration}}var js=Object.freeze({__proto__:null,MovePluginInstance:class{availablePathGenerators;pathGenerators;#u;#p;constructor(t,e){this.#p=t,this.#u=e,this.availablePathGenerators=new Map,this.pathGenerators=new Map}destroy(){this.availablePathGenerators=new Map,this.pathGenerators=new Map}isEnabled(t){return!t.destroyed&&t.options.move.enable}particleCreated(t){const e=t.options.move,i=e.gravity,s=e.path;if(t.moveDecay=1-Q(e.decay),t.pathDelay=Q(s.delay.value)*u,s.generator){let e=this.pathGenerators.get(s.generator);e||(e=this.availablePathGenerators.get(s.generator),e&&(this.pathGenerators.set(s.generator,e),e.init())),t.pathGenerator=e}t.gravity={enable:i.enable,acceleration:Q(i.acceleration),inverse:i.inverse},Ns(this.#u,t)}particleDestroyed(t){const e=t.pathGenerator;e?.reset(t)}particleUpdate(t,e){const i=t.options.move;if(!i.enable)return;const s=this.#u,n=function(t){const e=t.getModifier("slow");return e?.enabled?e.speedFactor??1:1}(t),a=s.retina.reduceFactor,o=t.retina.moveSpeed,r=t.retina.moveDrift,c=t.size.max,l=o*(i.size?t.getRadius()/c:1)*n*(e.factor||1)*d,h=t.retina.maxSpeed;i.spin.enable?function(t,e,i,s){if(!e.spin)return;const n=e.spin.direction===Rt.clockwise,a={x:n?Math.cos:Math.sin,y:n?Math.sin:Math.cos};e.position.x=e.spin.center.x+e.spin.radius*a.x(e.spin.angle)*s,e.position.y=e.spin.center.y+e.spin.radius*a.y(e.spin.angle)*s,e.spin.radius+=e.spin.acceleration*s;const o=Math.max(t.canvas.size.width,t.canvas.size.height),r=o*d;e.spin.radius>r?(e.spin.radius=r,e.spin.acceleration*=-1):e.spin.radius<0&&(e.spin.radius=0,e.spin.acceleration*=-1),e.spin.angle+=.01*i*(1-e.spin.radius/o)}(s,t,l,a):Ws(t,i,l,h,r,a,e),function(t){const e=t.initialPosition,{dx:i,dy:s}=tt(e,t.position),n=Math.abs(i),a=Math.abs(s),{maxDistance:o}=t.retina,r=o.horizontal,c=o.vertical;if(!r&&!c)return;if((r&&n>=r||c&&a>=c)&&!t.misplaced)t.misplaced=!!r&&n>r||!!c&&a>c,r&&(t.velocity.x=t.velocity.y*d-t.velocity.x),c&&(t.velocity.y=t.velocity.x*d-t.velocity.y);else if((!r||n<r)&&(!c||a<c)&&t.misplaced)t.misplaced=!1;else if(t.misplaced){const i=t.position,s=t.velocity;r&&(i.x<e.x&&s.x<0||i.x>e.x&&s.x>0)&&(s.x*=-N()),c&&(i.y<e.y&&s.y<0||i.y>e.y&&s.y>0)&&(s.y*=-N())}}(t)}preInit(){return this.#si()}redrawInit(){return this.#si()}update(){for(const t of this.pathGenerators.values())t.update()}async#si(){const t=this.#p;if(t.initializers.pathGenerators){this.availablePathGenerators=await Lt(this.#u,t.initializers.pathGenerators),this.pathGenerators=new Map;for(const t of this.pathGenerators.values())t.init()}}}});class Gs{#ni=!0;#ai;#u;#zt;#oi;#ri;constructor(t,e){this.#u=t,this.#ai=[],this.#oi=e,this.#ri=new Map,this.#zt={mouseDown:()=>{this.#ci()},mouseLeave:()=>{this.#li()},mouseMove:t=>{this.#hi(t)},mouseUp:t=>{this.#di(t)},touchStart:t=>{this.#ui(t)},touchMove:t=>{this.#hi(t)},touchEnd:t=>{this.#pi(t)},touchCancel:t=>{this.#pi(t)},touchEndClick:t=>{this.#fi(t)},visibilityChange:()=>{this.#It()}}}addListeners(){this.#Lt(!0)}init(){this.#ai.length=0;for(const t of this.#u.plugins.filter(t=>!!t.clickPositionValid))this.#ai.push(t)}removeListeners(){this.#Lt(!1)}#gi(t){const e=this.#u,i=this.#oi,s=e.actualOptions;if(this.#ni){const t=i.interactivityData.mouse,e=t.position;if(!e)return;t.clickPosition={...e},t.clickTime=performance.now();const n=s.interactivity?.events.onClick;if(!n?.mode)return;Mt(n.mode,t=>{i.handleClickMode(t)})}"touchend"===t.type&&setTimeout(()=>{this.#li()},500)}#It(){this.#li()}#yi(t){const e=this.#zt,i=this.#u,s=this.#oi,n=i.actualOptions,a=s.interactivityData.element;if(!a)return;const o=a,r=i.canvas;r.setPointerEvents(o===r.domElement?"initial":"none"),It(a,ds,e.mouseMove,t),It(a,us,e.touchStart,t),It(a,fs,e.touchMove,t);const c=!!n.interactivity?.events.onClick.enable;It(a,ps,e.touchEndClick,t&&c),It(a,ps,e.touchEnd,t&&!c),It(a,"pointerup",e.mouseUp,t),It(a,"pointerdown",e.mouseDown,t),It(a,hs,e.mouseLeave,t),It(a,gs,e.touchCancel,t)}#Lt(t){const e=this.#zt,i=this.#u,s=this.#oi,n=i.actualOptions,a=n.interactivity?.detectsOn,o=i.canvas.domElement;a===es.window?s.interactivityData.element=mt():a===es.parent&&o?s.interactivityData.element=o.parentElement??o.parentNode:s.interactivityData.element=o,this.#yi(t),It(document,l,e.visibilityChange,t,!1)}#ci(){const{interactivityData:t}=this.#oi,{mouse:e}=t;e.clicking=!0,e.downPosition=e.position}#di(t){const e=this.#u,i=this.#oi,s=e.actualOptions,{mouse:n}=i.interactivityData;n.inside=!0;const a=n.position;if(a&&s.interactivity?.events.onClick.enable){let e=!1;for(const t of this.#ai)if(e=t.clickPositionValid?.(a)??!1,e)break;e||this.#gi(t)}n.clicking=!1}#li(){const{interactivityData:t}=this.#oi,{mouse:e}=t;delete e.position,delete e.clickPosition,delete e.downPosition,t.status=hs,e.inside=!1,e.clicking=!1}#hi(t){const e=this.#u,i=this.#oi,s=e.actualOptions,n=i.interactivityData,a=e.canvas.domElement;if(!n.element)return;let o;if(n.mouse.inside=!0,t.type.startsWith("pointer")){this.#ni=!0;const e=t;if(n.element===mt()){if(a){const t=a.getBoundingClientRect();o={x:e.clientX-t.left,y:e.clientY-t.top}}}else if(s.interactivity?.detectsOn===es.parent){const t=e.target,i=e.currentTarget;if(a){const s=t.getBoundingClientRect(),n=i.getBoundingClientRect(),r=a.getBoundingClientRect();o={x:e.offsetX+2*s.left-(n.left+r.left),y:e.offsetY+2*s.top-(n.top+r.top)}}else o={x:e.offsetX,y:e.offsetY}}else e.target===a&&(o={x:e.offsetX,y:e.offsetY})}else if(this.#ni="touchmove"!==t.type,a){const e=t,i=e.touches[e.touches.length-1],s=a.getBoundingClientRect();if(!i)return;o={x:i.clientX-s.left,y:i.clientY-s.top}}const r=e.retina.pixelRatio;o&&(o.x*=r,o.y*=r),n.mouse.position=o,n.status=ds}#pi(t){const e=t,i=Array.from(e.changedTouches);for(const t of i)this.#ri.delete(t.identifier);this.#li()}#fi(t){const e=t,i=Array.from(e.changedTouches);for(const t of i)this.#ri.delete(t.identifier);this.#di(t)}#ui(t){const e=t,i=Array.from(e.changedTouches);for(const t of i)this.#ri.set(t.identifier,performance.now());this.#hi(t);const{mouse:s}=this.#oi.interactivityData;s.clicking=!0,s.downPosition=s.position}}class Xs{interactivityData;interactors;#mi;#u;#Ne;#vi;#wi;#Pi;#p;constructor(t,e){this.#u=e,this.#p=t,this.interactors=[],this.#vi=[],this.#Pi=[],this.#mi=new Map,this.#Ne=new Gs(e,this),this.interactivityData={mouse:{clicking:!1,inside:!1}},this.#wi=function(t){if("undefined"!=typeof IntersectionObserver)return new IntersectionObserver(t)}(t=>{this.#bi(t)})}addClickHandler(t){const e=this.#u,i=this.interactivityData;if(e.destroyed)return;const s=i.element;if(!s)return;const n=(i,s,n)=>{if(e.destroyed)return;const a=e.retina.pixelRatio,o={x:s.x*a,y:s.y*a},r=e.particles.grid.queryCircle(o,n*a);t(i,r)};let a=!1,o=!1;this.#mi.set("click",t=>{if(e.destroyed)return;const i=t,s={x:i.offsetX,y:i.offsetY};n(t,s,1)}),this.#mi.set(us,()=>{e.destroyed||(a=!0,o=!1)}),this.#mi.set(fs,()=>{e.destroyed||(o=!0)}),this.#mi.set(ps,t=>{if(!e.destroyed){if(a&&!o){const i=t,s=i.touches[i.touches.length-1];if(!s)return;const a=e.canvas.domElement,o=a?a.getBoundingClientRect():void 0,r={x:s.clientX-(o?o.left:0),y:s.clientY-(o?o.top:0)};n(t,r,Math.max(s.radiusX,s.radiusY))}a=!1,o=!1}}),this.#mi.set(gs,()=>{e.destroyed||(a=!1,o=!1)});for(const[t,e]of this.#mi)s.addEventListener(t,e)}addListeners(){this.#Ne.addListeners()}clearClickHandlers(){const t=this.#u,e=this.interactivityData;if(!t.destroyed){for(const[t,i]of this.#mi)e.element?.removeEventListener(t,i);this.#mi.clear()}}externalInteract(t){for(const e of this.#vi){const i=this.interactivityData;e.isEnabled(i)&&e.interact(i,t)}}handleClickMode(t){if(this.#u.destroyed)return;const e=this.interactivityData;for(const i of this.#vi)i.handleClickMode?.(t,e)}init(){this.#Ne.init();for(const t of this.interactors){switch(t.type){case is.external:this.#vi.push(t);break;case is.particles:this.#Pi.push(t)}t.init()}}async initInteractors(){const t=this.#p;t.initializers.interactors&&(this.interactors=await Ot(this.#u,t.initializers.interactors),this.#vi=[],this.#Pi=[])}particlesInteract(t,e){const i=this.interactivityData;for(const i of this.#vi)i.clear(t,e);for(const s of this.#Pi)s.isEnabled(t,i)&&s.interact(t,i,e)}removeListeners(){this.#Ne.removeListeners()}reset(t){const e=this.interactivityData;for(const i of this.#vi)i.isEnabled(e)&&i.reset(e,t);for(const i of this.#Pi)i.isEnabled(t,e)&&i.reset(e,t)}startObserving(){const t=this.interactivityData;t.element instanceof HTMLElement&&this.#wi&&this.#wi.observe(t.element)}stopObserving(){const t=this.interactivityData;t.element instanceof HTMLElement&&this.#wi&&this.#wi.unobserve(t.element)}updateMaxDistance(){let t=0;for(const e of this.interactors)e.maxDistance>t&&(t=e.maxDistance);const e=this.#u;e.particles.grid.cellSize=t*e.retina.pixelRatio}#bi(t){const e=this.#u;if(!e.destroyed&&e.actualOptions.pauseOnOutsideViewport)for(const i of t)i.target===this.interactivityData.element&&(i.isIntersecting?e.play():e.pause())}}var Ys=Object.freeze({__proto__:null,InteractivityPluginInstance:class{#u;constructor(t,e){e.addClickHandler=t=>{e.interactionManager?.addClickHandler(t)},e.interactionManager=new Xs(t,e),this.#u=e}addClickHandler(t){this.#u.interactionManager?.addClickHandler(t)}clearClickHandlers(){this.#u.interactionManager?.clearClickHandlers()}destroy(){this.clearClickHandlers()}particleCreated(t){const e=t,i=this.#u,s=new rs(i);s.load(i.actualOptions.interactivity),s.load(e.options.interactivity),e.interactivity=s}particleReset(t){this.#u.interactionManager?.reset(t)}postParticleUpdate(t,e){this.#u.interactionManager?.particlesInteract(t,e)}postUpdate(t){const e=this.#u;e.interactionManager?.externalInteract(t),e.interactionManager?.updateMaxDistance()}async preInit(){const t=this.#u;await(t.interactionManager?.initInteractors()),t.interactionManager?.init()}async redrawInit(){const t=this.#u;await(t.interactionManager?.initInteractors()),t.interactionManager?.init()}start(){const t=this.#u;return t.interactionManager?.addListeners(),t.interactionManager?.startObserving(),Promise.resolve()}stop(){this.#u.interactionManager?.removeListeners(),this.#u.interactionManager?.stopObserving()}}});function Qs(t,e){const i=(s=t.map(t=>t.id),[...s].sort((t,e)=>t-e).join("_"));var s;let n=e.get(i);return void 0===n&&(n=N(),e.set(i,n)),n}var Ks=Object.freeze({__proto__:null,LinkInstance:class{#xi=new Map;#u;#Mi;#p;constructor(t,e){this.#p=t,this.#u=e,this.#Mi={links:new Map,triangles:new Map}}drawParticle(t,e){const{links:i,options:s}=e;if(!i?.length||!s.links)return;const n=s.links,a=e.retina.linksWidth??0,o=e.getPosition(),r=e.options.twinkle?.links,c=n.triangles.enable,l=c?new Set(i.map(t=>t.destination.id)):null,h=t.globalAlpha;let u="",f=-1,g=-1,y=!1;const m=()=>{y&&(t.stroke(),y=!1)};for(const h of i){if(n.frequency<1&&this.#ki(e,h.destination)>n.frequency)continue;const i=h.destination.getPosition();if(c&&!h.isWarped&&l&&(m(),this.#zi(s,e,h,l,o,i,t)),h.opacity<=0||a<=0)continue;if(!n.enable)continue;let v=h.opacity,w=h.color;const P=r?.enable&&N()<r.frequency?Xe(this.#p,r.color):void 0;if(r&&P&&(w=P,v=Q(r.opacity)),!w){const t=void 0!==n.id?this.#u.particles.linksColors.get(n.id):this.#u.particles.linksColor;w=si(e,h.destination,t)}if(!w)continue;const b=this.#Ci(w);if(b===u&&a===f&&v===g||(m(),t.strokeStyle=b,t.lineWidth=a,t.globalAlpha=v,u=b,f=a,g=v,t.beginPath(),y=!0),h.isWarped){const e=this.#u.canvas.size,s=i.x-o.x,n=i.y-o.y;let a=p.x,r=p.y;Math.abs(s)>e.width*d&&(a=s>0?-e.width:e.width),Math.abs(n)>e.height*d&&(r=n>0?-e.height:e.height),t.moveTo(o.x,o.y),t.lineTo(i.x+a,i.y+r),t.moveTo(o.x-a,o.y-r),t.lineTo(i.x,i.y)}else t.moveTo(o.x,o.y),t.lineTo(i.x,i.y)}m(),t.globalAlpha=h}init(){return this.#Mi.links.clear(),this.#Mi.triangles.clear(),this.#xi.clear(),Promise.resolve()}particleCreated(t){if(t.links=[],!t.options.links)return;t.linksDistance=t.options.links.distance,t.linksWidth=t.options.links.width;const e=this.#u.retina.pixelRatio;t.retina.linksDistance=t.linksDistance*e,t.retina.linksWidth=t.linksWidth*e}particleDestroyed(t){t.links=[]}#zi(t,e,i,s,n,a,o){const r=i.destination,c=t.links?.triangles;if(!c?.enable||!r.options.links?.triangles.enable)return;const l=r.links;if(l?.length)for(const h of l){if(h.isWarped||this.#ki(r,h.destination)>r.options.links.frequency||!s.has(h.destination.id))continue;const l=h.destination;if(this.#Si(e,r,l)>(t.links?.triangles.frequency??0))continue;const u=c.opacity??(i.opacity+h.opacity)*d,p=Xe(this.#p,c.color)??i.color;if(!p||u<=0)continue;const f=l.getPosition();o.save(),o.fillStyle=this.#Ci(p),o.globalAlpha=u,o.beginPath(),o.moveTo(n.x,n.y),o.lineTo(a.x,a.y),o.lineTo(f.x,f.y),o.closePath(),o.fill(),o.restore()}}#Ci(t){const e=`${t.r},${t.g},${t.b}-${this.#u.hdr}-${this.#u.peakNits}-${this.#u.hdrMode}`;let i=this.#xi.get(e);return i||(i=ei(t,this.#u.hdr,void 0,this.#u.peakNits,this.#u.hdrMode),this.#xi.set(e,i)),i}#ki(t,e){return Qs([t,e],this.#Mi.links)}#Si(t,e,i){return Qs([t,e,i],this.#Mi.triangles)}}});t.loadTrianglesPreset=zs,t.tsParticles=li}(t.__tsParticlesInternals.presets.triangles=t.__tsParticlesInternals.presets.triangles||{})}("undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:self),Object.assign(globalThis.window||globalThis,{loadTrianglesPreset:(globalThis.__tsParticlesInternals.presets.triangles||{}).loadTrianglesPreset});
|
|
@@ -1,10 +1,10 @@
|
|
|
1
|
-
(function(g){g.__tsParticlesInternals=g.__tsParticlesInternals||{};g.__tsParticlesInternals.bundles=g.__tsParticlesInternals.bundles||{};g.__tsParticlesInternals.effects=g.__tsParticlesInternals.effects||{};g.__tsParticlesInternals.engine=g.__tsParticlesInternals.engine||{};g.__tsParticlesInternals.interactions=g.__tsParticlesInternals.interactions||{};g.__tsParticlesInternals.palettes=g.__tsParticlesInternals.palettes||{};g.__tsParticlesInternals.paths=g.__tsParticlesInternals.paths||{};g.__tsParticlesInternals.plugins=g.__tsParticlesInternals.plugins||{};g.__tsParticlesInternals.plugins=g.__tsParticlesInternals.plugins||{};g.__tsParticlesInternals.plugins.emittersShapes=g.__tsParticlesInternals.plugins.emittersShapes||{};g.__tsParticlesInternals.presets=g.__tsParticlesInternals.presets||{};g.__tsParticlesInternals.shapes=g.__tsParticlesInternals.shapes||{};g.__tsParticlesInternals.updaters=g.__tsParticlesInternals.updaters||{};g.__tsParticlesInternals.utils=g.__tsParticlesInternals.utils||{};g.__tsParticlesInternals.canvas=g.__tsParticlesInternals.canvas||{};g.__tsParticlesInternals.canvas=g.__tsParticlesInternals.canvas||{};g.__tsParticlesInternals.canvas.utils=g.__tsParticlesInternals.canvas.utils||{};g.__tsParticlesInternals.path=g.__tsParticlesInternals.path||{};g.__tsParticlesInternals.path=g.__tsParticlesInternals.path||{};g.__tsParticlesInternals.path.utils=g.__tsParticlesInternals.path.utils||{};var __tsProxyFactory=typeof Proxy!=="undefined"?function(obj){return new Proxy(obj,{get:function(target,key){if(!(key in target)){target[key]={};}return target[key];}});}:function(obj){return obj;};g.__tsParticlesInternals.bundles=__tsProxyFactory(g.__tsParticlesInternals.bundles);g.__tsParticlesInternals.effects=__tsProxyFactory(g.__tsParticlesInternals.effects);g.__tsParticlesInternals.interactions=__tsProxyFactory(g.__tsParticlesInternals.interactions);g.__tsParticlesInternals.palettes=__tsProxyFactory(g.__tsParticlesInternals.palettes);g.__tsParticlesInternals.paths=__tsProxyFactory(g.__tsParticlesInternals.paths);g.__tsParticlesInternals.plugins=__tsProxyFactory(g.__tsParticlesInternals.plugins);g.__tsParticlesInternals.plugins.emittersShapes=__tsProxyFactory(g.__tsParticlesInternals.plugins.emittersShapes);g.__tsParticlesInternals.presets=__tsProxyFactory(g.__tsParticlesInternals.presets);g.__tsParticlesInternals.shapes=__tsProxyFactory(g.__tsParticlesInternals.shapes);g.__tsParticlesInternals.updaters=__tsProxyFactory(g.__tsParticlesInternals.updaters);g.__tsParticlesInternals.utils=__tsProxyFactory(g.__tsParticlesInternals.utils);g.__tsParticlesInternals.canvas=__tsProxyFactory(g.__tsParticlesInternals.canvas);g.__tsParticlesInternals.path=__tsProxyFactory(g.__tsParticlesInternals.path);
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
1
|
+
(function(g){g.__tsParticlesInternals=g.__tsParticlesInternals||{};g.__tsParticlesInternals.bundles=g.__tsParticlesInternals.bundles||{};g.__tsParticlesInternals.effects=g.__tsParticlesInternals.effects||{};g.__tsParticlesInternals.engine=g.__tsParticlesInternals.engine||{};g.__tsParticlesInternals.interactions=g.__tsParticlesInternals.interactions||{};g.__tsParticlesInternals.palettes=g.__tsParticlesInternals.palettes||{};g.__tsParticlesInternals.paths=g.__tsParticlesInternals.paths||{};g.__tsParticlesInternals.plugins=g.__tsParticlesInternals.plugins||{};g.__tsParticlesInternals.plugins=g.__tsParticlesInternals.plugins||{};g.__tsParticlesInternals.plugins.emittersShapes=g.__tsParticlesInternals.plugins.emittersShapes||{};g.__tsParticlesInternals.presets=g.__tsParticlesInternals.presets||{};g.__tsParticlesInternals.shapes=g.__tsParticlesInternals.shapes||{};g.__tsParticlesInternals.updaters=g.__tsParticlesInternals.updaters||{};g.__tsParticlesInternals.utils=g.__tsParticlesInternals.utils||{};g.__tsParticlesInternals.canvas=g.__tsParticlesInternals.canvas||{};g.__tsParticlesInternals.canvas=g.__tsParticlesInternals.canvas||{};g.__tsParticlesInternals.canvas.utils=g.__tsParticlesInternals.canvas.utils||{};g.__tsParticlesInternals.path=g.__tsParticlesInternals.path||{};g.__tsParticlesInternals.path=g.__tsParticlesInternals.path||{};g.__tsParticlesInternals.path.utils=g.__tsParticlesInternals.path.utils||{};var __tsProxyFactory=typeof Proxy!=="undefined"?function(obj){return new Proxy(obj,{get:function(target,key){if(!(key in target)){target[key]={};}return target[key];}});}:function(obj){return obj;};g.__tsParticlesInternals.bundles=__tsProxyFactory(g.__tsParticlesInternals.bundles);g.__tsParticlesInternals.effects=__tsProxyFactory(g.__tsParticlesInternals.effects);g.__tsParticlesInternals.interactions=__tsProxyFactory(g.__tsParticlesInternals.interactions);g.__tsParticlesInternals.palettes=__tsProxyFactory(g.__tsParticlesInternals.palettes);g.__tsParticlesInternals.paths=__tsProxyFactory(g.__tsParticlesInternals.paths);g.__tsParticlesInternals.plugins=__tsProxyFactory(g.__tsParticlesInternals.plugins);g.__tsParticlesInternals.plugins.emittersShapes=__tsProxyFactory(g.__tsParticlesInternals.plugins.emittersShapes);g.__tsParticlesInternals.presets=__tsProxyFactory(g.__tsParticlesInternals.presets);g.__tsParticlesInternals.shapes=__tsProxyFactory(g.__tsParticlesInternals.shapes);g.__tsParticlesInternals.updaters=__tsProxyFactory(g.__tsParticlesInternals.updaters);g.__tsParticlesInternals.utils=__tsProxyFactory(g.__tsParticlesInternals.utils);g.__tsParticlesInternals.canvas=__tsProxyFactory(g.__tsParticlesInternals.canvas);g.__tsParticlesInternals.path=__tsProxyFactory(g.__tsParticlesInternals.path);})(typeof globalThis!=="undefined"?globalThis:typeof window!=="undefined"?window:this);
|
|
2
|
+
(function (g) {
|
|
3
|
+
/* Preset v4.5.1 */
|
|
4
|
+
g.__tsParticlesInternals = g.__tsParticlesInternals || {};
|
|
5
|
+
g.__tsParticlesInternals.presets = g.__tsParticlesInternals.presets || {};
|
|
6
|
+
(function (exports, basic, pluginInteractivity, interactionParticlesLinks) {
|
|
7
|
+
'use strict';
|
|
8
8
|
|
|
9
9
|
const options = {
|
|
10
10
|
background: {
|
|
@@ -63,6 +63,7 @@
|
|
|
63
63
|
|
|
64
64
|
exports.loadTrianglesPreset = loadTrianglesPreset;
|
|
65
65
|
|
|
66
|
-
}));
|
|
66
|
+
})(g.__tsParticlesInternals.presets.triangles = g.__tsParticlesInternals.presets.triangles || {}, g.__tsParticlesInternals.bundles.basic, g.__tsParticlesInternals.plugins.interactivity, g.__tsParticlesInternals.interactions.particlesLinks);
|
|
67
|
+
})(typeof globalThis !== "undefined" ? globalThis : typeof window !== "undefined" ? window : self);
|
|
68
|
+
|
|
67
69
|
Object.assign(globalThis.window || globalThis, { loadTrianglesPreset: (globalThis.__tsParticlesInternals.presets.triangles || {}).loadTrianglesPreset });
|
|
68
|
-
delete (globalThis.window || globalThis).tsparticlesInternalExports;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
!function(s){s.__tsParticlesInternals=s.__tsParticlesInternals||{},s.__tsParticlesInternals.bundles=s.__tsParticlesInternals.bundles||{},s.__tsParticlesInternals.effects=s.__tsParticlesInternals.effects||{},s.__tsParticlesInternals.engine=s.__tsParticlesInternals.engine||{},s.__tsParticlesInternals.interactions=s.__tsParticlesInternals.interactions||{},s.__tsParticlesInternals.palettes=s.__tsParticlesInternals.palettes||{},s.__tsParticlesInternals.paths=s.__tsParticlesInternals.paths||{},s.__tsParticlesInternals.plugins=s.__tsParticlesInternals.plugins||{},s.__tsParticlesInternals.plugins=s.__tsParticlesInternals.plugins||{},s.__tsParticlesInternals.plugins.emittersShapes=s.__tsParticlesInternals.plugins.emittersShapes||{},s.__tsParticlesInternals.presets=s.__tsParticlesInternals.presets||{},s.__tsParticlesInternals.shapes=s.__tsParticlesInternals.shapes||{},s.__tsParticlesInternals.updaters=s.__tsParticlesInternals.updaters||{},s.__tsParticlesInternals.utils=s.__tsParticlesInternals.utils||{},s.__tsParticlesInternals.canvas=s.__tsParticlesInternals.canvas||{},s.__tsParticlesInternals.canvas=s.__tsParticlesInternals.canvas||{},s.__tsParticlesInternals.canvas.utils=s.__tsParticlesInternals.canvas.utils||{},s.__tsParticlesInternals.path=s.__tsParticlesInternals.path||{},s.__tsParticlesInternals.path=s.__tsParticlesInternals.path||{},s.__tsParticlesInternals.path.utils=s.__tsParticlesInternals.path.utils||{};var t="undefined"!=typeof Proxy?function(s){return new Proxy(s,{get:function(s,t){return t in s||(s[t]={}),s[t]}})}:function(s){return s};s.__tsParticlesInternals.bundles=t(s.__tsParticlesInternals.bundles),s.__tsParticlesInternals.effects=t(s.__tsParticlesInternals.effects),s.__tsParticlesInternals.interactions=t(s.__tsParticlesInternals.interactions),s.__tsParticlesInternals.palettes=t(s.__tsParticlesInternals.palettes),s.__tsParticlesInternals.paths=t(s.__tsParticlesInternals.paths),s.__tsParticlesInternals.plugins=t(s.__tsParticlesInternals.plugins),s.__tsParticlesInternals.plugins.emittersShapes=t(s.__tsParticlesInternals.plugins.emittersShapes),s.__tsParticlesInternals.presets=t(s.__tsParticlesInternals.presets),s.__tsParticlesInternals.shapes=t(s.__tsParticlesInternals.shapes),s.__tsParticlesInternals.updaters=t(s.__tsParticlesInternals.updaters),s.__tsParticlesInternals.utils=t(s.__tsParticlesInternals.utils),s.__tsParticlesInternals.canvas=t(s.__tsParticlesInternals.canvas),s.__tsParticlesInternals.path=t(s.__tsParticlesInternals.path)
|
|
1
|
+
!function(s){s.__tsParticlesInternals=s.__tsParticlesInternals||{},s.__tsParticlesInternals.bundles=s.__tsParticlesInternals.bundles||{},s.__tsParticlesInternals.effects=s.__tsParticlesInternals.effects||{},s.__tsParticlesInternals.engine=s.__tsParticlesInternals.engine||{},s.__tsParticlesInternals.interactions=s.__tsParticlesInternals.interactions||{},s.__tsParticlesInternals.palettes=s.__tsParticlesInternals.palettes||{},s.__tsParticlesInternals.paths=s.__tsParticlesInternals.paths||{},s.__tsParticlesInternals.plugins=s.__tsParticlesInternals.plugins||{},s.__tsParticlesInternals.plugins=s.__tsParticlesInternals.plugins||{},s.__tsParticlesInternals.plugins.emittersShapes=s.__tsParticlesInternals.plugins.emittersShapes||{},s.__tsParticlesInternals.presets=s.__tsParticlesInternals.presets||{},s.__tsParticlesInternals.shapes=s.__tsParticlesInternals.shapes||{},s.__tsParticlesInternals.updaters=s.__tsParticlesInternals.updaters||{},s.__tsParticlesInternals.utils=s.__tsParticlesInternals.utils||{},s.__tsParticlesInternals.canvas=s.__tsParticlesInternals.canvas||{},s.__tsParticlesInternals.canvas=s.__tsParticlesInternals.canvas||{},s.__tsParticlesInternals.canvas.utils=s.__tsParticlesInternals.canvas.utils||{},s.__tsParticlesInternals.path=s.__tsParticlesInternals.path||{},s.__tsParticlesInternals.path=s.__tsParticlesInternals.path||{},s.__tsParticlesInternals.path.utils=s.__tsParticlesInternals.path.utils||{};var t="undefined"!=typeof Proxy?function(s){return new Proxy(s,{get:function(s,t){return t in s||(s[t]={}),s[t]}})}:function(s){return s};s.__tsParticlesInternals.bundles=t(s.__tsParticlesInternals.bundles),s.__tsParticlesInternals.effects=t(s.__tsParticlesInternals.effects),s.__tsParticlesInternals.interactions=t(s.__tsParticlesInternals.interactions),s.__tsParticlesInternals.palettes=t(s.__tsParticlesInternals.palettes),s.__tsParticlesInternals.paths=t(s.__tsParticlesInternals.paths),s.__tsParticlesInternals.plugins=t(s.__tsParticlesInternals.plugins),s.__tsParticlesInternals.plugins.emittersShapes=t(s.__tsParticlesInternals.plugins.emittersShapes),s.__tsParticlesInternals.presets=t(s.__tsParticlesInternals.presets),s.__tsParticlesInternals.shapes=t(s.__tsParticlesInternals.shapes),s.__tsParticlesInternals.updaters=t(s.__tsParticlesInternals.updaters),s.__tsParticlesInternals.utils=t(s.__tsParticlesInternals.utils),s.__tsParticlesInternals.canvas=t(s.__tsParticlesInternals.canvas),s.__tsParticlesInternals.path=t(s.__tsParticlesInternals.path)}("undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:this),function(s){s.__tsParticlesInternals=s.__tsParticlesInternals||{},s.__tsParticlesInternals.presets=s.__tsParticlesInternals.presets||{},function(s,t,e,a){"use strict";const n={background:{color:"#000000"},particles:{number:{value:100},links:{distance:125,enable:!0,triangles:{enable:!0,opacity:.1}},move:{enable:!0,speed:5},paint:{fill:{color:{value:"#ffffff"}}},size:{value:1},shape:{type:"circle"}}};async function l(s){await s.pluginManager.register(async s=>{await Promise.all([t.loadBasic(s),(async s=>{await e.loadInteractivityPlugin(s),await a.loadParticlesLinksInteraction(s)})(s)]),s.pluginManager.addPreset("triangles",n)})}const r=globalThis;r.__tsParticlesInternals=r.__tsParticlesInternals??{},r.loadTrianglesPreset=l,s.loadTrianglesPreset=l}(s.__tsParticlesInternals.presets.triangles=s.__tsParticlesInternals.presets.triangles||{},s.__tsParticlesInternals.bundles.basic,s.__tsParticlesInternals.plugins.interactivity,s.__tsParticlesInternals.interactions.particlesLinks)}("undefined"!=typeof globalThis?globalThis:"undefined"!=typeof window?window:self),Object.assign(globalThis.window||globalThis,{loadTrianglesPreset:(globalThis.__tsParticlesInternals.presets.triangles||{}).loadTrianglesPreset});
|