@tsparticles/engine 4.0.0-alpha.18 → 4.0.0-alpha.20

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/515.min.js ADDED
@@ -0,0 +1 @@
1
+ "use strict";(this.webpackChunk_tsparticles_engine=this.webpackChunk_tsparticles_engine||[]).push([[515],{5515(t,i,e){e.d(i,{Container:()=>M});var s=e(493),a=e(7157),r=e(1963),n=e(2439),h=e(6720);function o(t,i,e=!1){if(!i)return;let s=t.style,a=new Set;for(let t=0;t<s.length;t++){let i=s.item(t);i&&a.add(i)}for(let t=0;t<i.length;t++){let e=i.item(t);e&&a.add(e)}for(let t of a){let a=i.getPropertyValue(t);a?s.setProperty(t,a,e?"important":""):s.removeProperty(t)}}class l{container;element;size;_canvasClearPlugins;_canvasPaintPlugins;_canvasSettings;_clearDrawPlugins;_colorPlugins;_context;_drawParticlePlugins;_drawParticlesCleanupPlugins;_drawParticlesSetupPlugins;_drawPlugins;_drawSettingsCleanupPlugins;_drawSettingsSetupPlugins;_engine;_generated;_mutationObserver;_originalStyle;_pointerEvents;_postDrawUpdaters;_preDrawUpdaters;_resizePlugins;_reusableColorStyles={};_reusablePluginColors=[void 0,void 0];_reusableTransform={};_standardSize;constructor(t,i){this.container=t,this._engine=i,this._standardSize={height:0,width:0};const e=t.retina.pixelRatio,s=this._standardSize;this.size={height:s.height*e,width:s.width*e},this._context=null,this._generated=!1,this._preDrawUpdaters=[],this._postDrawUpdaters=[],this._resizePlugins=[],this._colorPlugins=[],this._canvasClearPlugins=[],this._canvasPaintPlugins=[],this._clearDrawPlugins=[],this._drawParticlePlugins=[],this._drawParticlesCleanupPlugins=[],this._drawParticlesSetupPlugins=[],this._drawPlugins=[],this._drawSettingsSetupPlugins=[],this._drawSettingsCleanupPlugins=[],this._pointerEvents="none"}get settings(){return this._canvasSettings}get _fullScreen(){return this.container.actualOptions.fullScreen.enable}canvasClear(){this.container.actualOptions.clear&&this.draw(t=>{(0,r.IU)(t,this.size)})}clear(){let t=!1;for(let i of this._canvasClearPlugins)if(t=i.canvasClear?.()??!1)break;t||this.canvasClear()}destroy(){if(this.stop(),this._generated){let t=this.element;t?.remove(),this.element=void 0}else this._resetOriginalStyle();this._preDrawUpdaters=[],this._postDrawUpdaters=[],this._resizePlugins=[],this._colorPlugins=[],this._canvasClearPlugins=[],this._canvasPaintPlugins=[],this._clearDrawPlugins=[],this._drawParticlePlugins=[],this._drawParticlesCleanupPlugins=[],this._drawParticlesSetupPlugins=[],this._drawPlugins=[],this._drawSettingsSetupPlugins=[],this._drawSettingsCleanupPlugins=[]}draw(t){let i=this._context;if(i)return t(i)}drawParticle(t,i){if(t.spawning||t.destroyed)return;let e=t.getRadius();if(e<=a.w2)return;let s=t.getFillColor(),n=t.getStrokeColor()??s,[o,l]=this._getPluginParticleColors(t);if(o??=s,l??=n,!o&&!l)return;let c=this.container,d=t.options.zIndex,p=a.RV-t.zIndexFactor,{opacity:u,strokeOpacity:_}=t.getOpacity(),g=this._reusableTransform,f=this._reusableColorStyles,P=o?(0,h.LC)(o,c.hdr,u):void 0,m=l?(0,h.LC)(l,c.hdr,_):P;g.a=g.b=g.c=g.d=void 0,f.fill=P,f.stroke=m,this.draw(s=>{for(let e of this._drawParticlesSetupPlugins)e.drawParticleSetup?.(s,t,i);for(let a of(this._applyPreDrawUpdaters(s,t,e,u,f,g),(0,r.p0)({container:c,context:s,particle:t,delta:i,colorStyles:f,radius:e*p**d.sizeRate,opacity:u,transform:g}),this._applyPostDrawUpdaters(t),this._drawParticlesCleanupPlugins))a.drawParticleCleanup?.(s,t,i)})}drawParticlePlugins(t,i){this.draw(e=>{for(let s of this._drawParticlePlugins)(0,r.Wb)(e,s,t,i)})}drawParticles(t){let{particles:i}=this.container;this.clear(),i.update(t),this.draw(e=>{for(let i of this._drawSettingsSetupPlugins)i.drawSettingsSetup?.(e,t);for(let i of this._drawPlugins)i.draw?.(e,t);for(let s of(i.drawParticles(t),this._clearDrawPlugins))s.clearDraw?.(e,t);for(let i of this._drawSettingsCleanupPlugins)i.drawSettingsCleanup?.(e,t)})}init(){this._safeMutationObserver(t=>{t.disconnect()}),this._mutationObserver=(0,n.tG)(t=>{for(let i of t)"attributes"===i.type&&"style"===i.attributeName&&this._repairStyle()}),this.resize(),this._initStyle(),this.initBackground(),this._safeMutationObserver(t=>{this.element&&this.element instanceof Node&&t.observe(this.element,{attributes:!0})}),this.initUpdaters(),this.initPlugins(),this.paint()}initBackground(){let{container:t}=this,i=t.actualOptions.background,e=this.element;if(!e)return;let s=e.style,a=(0,h.BN)(this._engine,i.color);a?s.backgroundColor=(0,h.xx)(a,t.hdr,i.opacity):s.backgroundColor="",s.backgroundImage=i.image||"",s.backgroundPosition=i.position||"",s.backgroundRepeat=i.repeat||"",s.backgroundSize=i.size||""}initPlugins(){for(let t of(this._resizePlugins=[],this._colorPlugins=[],this._canvasClearPlugins=[],this._canvasPaintPlugins=[],this._clearDrawPlugins=[],this._drawParticlePlugins=[],this._drawParticlesSetupPlugins=[],this._drawParticlesCleanupPlugins=[],this._drawPlugins=[],this._drawSettingsSetupPlugins=[],this._drawSettingsCleanupPlugins=[],this.container.plugins))t.resize&&this._resizePlugins.push(t),(t.particleFillColor??t.particleStrokeColor)&&this._colorPlugins.push(t),t.canvasClear&&this._canvasClearPlugins.push(t),t.canvasPaint&&this._canvasPaintPlugins.push(t),t.drawParticle&&this._drawParticlePlugins.push(t),t.drawParticleSetup&&this._drawParticlesSetupPlugins.push(t),t.drawParticleCleanup&&this._drawParticlesCleanupPlugins.push(t),t.draw&&this._drawPlugins.push(t),t.drawSettingsSetup&&this._drawSettingsSetupPlugins.push(t),t.drawSettingsCleanup&&this._drawSettingsCleanupPlugins.push(t),t.clearDraw&&this._clearDrawPlugins.push(t)}initUpdaters(){for(let t of(this._preDrawUpdaters=[],this._postDrawUpdaters=[],this.container.particles.updaters))t.afterDraw&&this._postDrawUpdaters.push(t),(t.getColorStyles??t.getTransformValues??t.beforeDraw)&&this._preDrawUpdaters.push(t)}loadCanvas(t){this._generated&&this.element&&this.element.remove();let i=this.container;this._generated=a.eb in t.dataset?"true"===t.dataset[a.eb]:this._generated,this.element=t,this.element.ariaHidden="true",this._originalStyle=(0,n.td)(this.element.style);let e=this._standardSize;e.height=t.offsetHeight,e.width=t.offsetWidth;let s=this.container.retina.pixelRatio,r=this.size;t.height=r.height=e.height*s,t.width=r.width=e.width*s;let h=(0,n.lV)("(color-gamut: p3)");this._canvasSettings={alpha:!0,colorSpace:h?.matches&&i.hdr?"display-p3":"srgb",desynchronized:!0,willReadFrequently:!1},this._context=this.element.getContext("2d",this._canvasSettings),this._safeMutationObserver(t=>{t.disconnect()}),i.retina.init(),this.initBackground(),this._safeMutationObserver(t=>{this.element&&this.element instanceof Node&&t.observe(this.element,{attributes:!0})})}paint(){let t=!1;for(let i of this._canvasPaintPlugins)if(t=i.canvasPaint?.()??!1)break;t||this.paintBase()}paintBase(t){this.draw(i=>{(0,r.Sn)(i,this.size,t)})}paintImage(t,i){this.draw(e=>{(0,r.Md)(e,this.size,t,i)})}resize(){if(!this.element)return!1;let t=this.container,i=t.canvas._standardSize,e={width:this.element.offsetWidth,height:this.element.offsetHeight},s=t.retina.pixelRatio,a={width:e.width*s,height:e.height*s};if(e.height===i.height&&e.width===i.width&&a.height===this.element.height&&a.width===this.element.width)return!1;let r={...i};i.height=e.height,i.width=e.width;let n=this.size;return this.element.width=n.width=a.width,this.element.height=n.height=a.height,this.container.started&&t.particles.setResizeFactor({width:i.width/r.width,height:i.height/r.height}),!0}setPointerEvents(t){this.element&&(this._pointerEvents=t,this._repairStyle())}stop(){this._safeMutationObserver(t=>{t.disconnect()}),this._mutationObserver=void 0,this.draw(t=>{(0,r.IU)(t,this.size)})}async windowResize(){if(!this.element||!this.resize())return;let t=this.container,i=t.updateActualOptions();t.particles.setDensity(),this._applyResizePlugins(),i&&await t.refresh()}_applyPostDrawUpdaters=t=>{for(let i of this._postDrawUpdaters)i.afterDraw?.(t)};_applyPreDrawUpdaters=(t,i,e,s,r,n)=>{for(let h of this._preDrawUpdaters){if(h.getColorStyles){let{fill:a,stroke:n}=h.getColorStyles(i,t,e,s);a&&(r.fill=a),n&&(r.stroke=n)}if(h.getTransformValues){let t=h.getTransformValues(i);for(let i in t)!function(t,i,e){let s=i[e];void 0!==s&&(t[e]=(t[e]??a.zs)*s)}(n,t,i)}h.beforeDraw?.(i)}};_applyResizePlugins=()=>{for(let t of this._resizePlugins)t.resize?.()};_getPluginParticleColors=t=>{let i,e;for(let s of this._colorPlugins)if(!i&&s.particleFillColor&&(i=(0,h.R5)(this._engine,s.particleFillColor(t))),!e&&s.particleStrokeColor&&(e=(0,h.R5)(this._engine,s.particleStrokeColor(t))),i&&e)break;return this._reusablePluginColors[0]=i,this._reusablePluginColors[1]=e,this._reusablePluginColors};_initStyle=()=>{let t=this.element,i=this.container.actualOptions;if(t)for(let e in this._fullScreen?this._setFullScreenStyle():this._resetOriginalStyle(),i.style){if(!e||!Object.hasOwn(i.style,e))continue;let s=i.style[e];s&&t.style.setProperty(e,s,"important")}};_repairStyle=()=>{let t=this.element;if(!t)return;this._safeMutationObserver(t=>{t.disconnect()}),this._initStyle(),this.initBackground();let i=this._pointerEvents;t.style.pointerEvents=i,t.setAttribute("pointer-events",i),this._safeMutationObserver(i=>{t instanceof Node&&i.observe(t,{attributes:!0})})};_resetOriginalStyle=()=>{let t=this.element,i=this._originalStyle;t&&i&&o(t,i,!0)};_safeMutationObserver=t=>{this._mutationObserver&&t(this._mutationObserver)};_setFullScreenStyle=()=>{let t=this.element;t&&o(t,(0,n.hJ)(this.container.actualOptions.fullScreen.zIndex),!0)}}class c{container;_handlers;_resizeObserver;_resizeTimeout;constructor(t){this.container=t,this._handlers={visibilityChange:()=>{this._handleVisibilityChange()},resize:()=>{this._handleWindowResize()}}}addListeners(){this._manageListeners(!0)}removeListeners(){this._manageListeners(!1)}_handleVisibilityChange=()=>{let t=this.container;t.actualOptions.pauseOnBlur&&((0,n.T5)().hidden?(t.pageHidden=!0,t.pause()):(t.pageHidden=!1,t.animationStatus?t.play(!0):t.draw(!0)))};_handleWindowResize=()=>{this._resizeTimeout&&(clearTimeout(this._resizeTimeout),delete this._resizeTimeout);let t=async()=>{let t=this.container.canvas;await t.windowResize()};this._resizeTimeout=setTimeout(()=>void t(),this.container.actualOptions.resize.delay*a.Xu)};_manageListeners=t=>{let i=this._handlers;this._manageResize(t),(0,n.Kp)(document,a.nK,i.visibilityChange,t,!1)};_manageResize=t=>{let i=this._handlers,e=this.container;if(!e.actualOptions.resize.enable)return;if("u"<typeof ResizeObserver)return void(0,n.Kp)(globalThis,a.NF,i.resize,t);let s=e.canvas.element;this._resizeObserver&&!t?(s&&this._resizeObserver.unobserve(s),this._resizeObserver.disconnect(),delete this._resizeObserver):!this._resizeObserver&&t&&s&&(this._resizeObserver=new ResizeObserver(t=>{t.find(t=>t.target===s)&&this._handleWindowResize()}),this._resizeObserver.observe(s))}}var d=e(6911),p=e(5872),u=e(1610),_=e(1808),g=e(3702),f=e(3849),P=e(3457),m=e(9875);function y(t){if(!(0,n.hn)(t.outMode,t.checkModes))return;let i=t.radius*a.gd;t.coord>t.maxCoord-i?t.setCb(-t.radius):t.coord<i&&t.setCb(t.radius)}class w{container;backColor;bubble;color;destroyed;direction;effect;effectClose;effectData;effectFill;group;id;ignoresResizeRatio;initialPosition;initialVelocity;isRotating;lastPathTime;misplaced;moveCenter;moveDecay;offset;opacity;options;outType;pathDelay;pathGenerator;pathRotation;position;randomIndexData;retina;roll;rotation;shape;shapeClose;shapeData;shapeFill;sides;size;slow;spawning;strokeColor;strokeOpacity;strokeWidth;unbreakable;velocity;zIndexFactor;_cachedOpacityData={opacity:a.hv,strokeOpacity:a.hv};_cachedPosition=_.p.origin;_cachedRotateData={sin:0,cos:0};_cachedTransform={a:1,b:0,c:0,d:1};_engine;constructor(t,i){this.container=i,this._engine=t}destroy(t){if(this.unbreakable||this.destroyed)return;this.destroyed=!0,this.bubble.inRange=!1,this.slow.inRange=!1;let i=this.container,e=this.pathGenerator,s=this.shape?i.particles.shapeDrawers.get(this.shape):void 0;for(let e of(s?.particleDestroy?.(this),i.particleDestroyedPlugins))e.particleDestroyed?.(this,t);for(let e of i.particles.updaters)e.particleDestroyed?.(this,t);e?.reset(this),this._engine.dispatchEvent(d.B.particleDestroyed,{container:this.container,data:{particle:this}})}draw(t){let i=this.container.canvas;i.drawParticlePlugins(this,t),i.drawParticle(this,t)}getAngle(){return this.rotation+(this.pathRotation?this.velocity.angle:a.tA)}getFillColor(){return this._getRollColor(this.bubble.color??(0,h.O_)(this.color))}getMass(){return this.getRadius()**a.dm*Math.PI*a.MX}getOpacity(){let t=this.options.zIndex,i=a.RV-this.zIndexFactor,e=i**t.opacityRate,r=this.bubble.opacity??(0,s.VG)(this.opacity?.value??a.hv),n=this.strokeOpacity??r;return this._cachedOpacityData.opacity=r*e,this._cachedOpacityData.strokeOpacity=n*e,this._cachedOpacityData}getPosition(){return this._cachedPosition.x=this.position.x+this.offset.x,this._cachedPosition.y=this.position.y+this.offset.y,this._cachedPosition.z=this.position.z,this._cachedPosition}getRadius(){return this.bubble.radius??this.size.value}getRotateData(){let t=this.getAngle();return this._cachedRotateData.sin=Math.sin(t),this._cachedRotateData.cos=Math.cos(t),this._cachedRotateData}getStrokeColor(){return this._getRollColor(this.bubble.color??(0,h.O_)(this.strokeColor))}getTransformData(t){let i=this.getRotateData(),e=this.isRotating;return this._cachedTransform.a=i.cos*(t.a??a.Ug.a),this._cachedTransform.b=e?i.sin*(t.b??a.D_):t.b??a.Ug.b,this._cachedTransform.c=e?-i.sin*(t.c??a.D_):t.c??a.Ug.c,this._cachedTransform.d=i.cos*(t.d??a.Ug.d),this._cachedTransform}init(t,i,e,r){var h,o,l,c;let d,p,u,_,g=this.container;this.id=t,this.group=r,this.effectClose=!0,this.effectFill=!0,this.shapeClose=!0,this.shapeFill=!0,this.pathRotation=!1,this.lastPathTime=0,this.destroyed=!1,this.unbreakable=!1,this.isRotating=!1,this.rotation=0,this.misplaced=!1,this.retina={maxDistance:{}},this.outType=P.x.normal,this.ignoresResizeRatio=!0;let f=g.retina.pixelRatio,y=g.actualOptions,w=(0,m.y)(this._engine,g,y.particles),v=w.reduceDuplicates,b=w.effect.type,z=w.shape.type;this.effect=(0,n.TA)(b,this.id,v),this.shape=(0,n.TA)(z,this.id,v);let S=w.effect,C=w.shape;if(e){if(e.effect?.type){let t=e.effect.type,i=(0,n.TA)(t,this.id,v);i&&(this.effect=i,S.load(e.effect))}if(e.shape?.type){let t=e.shape.type,i=(0,n.TA)(t,this.id,v);i&&(this.shape=i,C.load(e.shape))}}if(this.effect===a.mR){let t=[...this.container.particles.effectDrawers.keys()];this.effect=t[Math.floor((0,s.G0)()*t.length)]}if(this.shape===a.mR){let t=[...this.container.particles.shapeDrawers.keys()];this.shape=t[Math.floor((0,s.G0)()*t.length)]}this.effectData=this.effect?(h=this.effect,o=this.id,u=S.options[h],(0,n.zw)({close:S.close,fill:S.fill},(0,n.TA)(u,o,v))):void 0,this.shapeData=this.shape?(l=this.shape,c=this.id,_=C.options[l],(0,n.zw)({close:C.close,fill:C.fill},(0,n.TA)(_,c,v))):void 0,w.load(e);let D=this.effectData;D&&w.load(D.particles);let x=this.shapeData;x&&w.load(x.particles),this.effectFill=D?.fill??w.effect.fill,this.effectClose=D?.close??w.effect.close,this.shapeFill=x?.fill??w.shape.fill,this.shapeClose=x?.close??w.shape.close,this.options=w;let R=this.options.move.path;if(this.pathDelay=(0,s.VG)(R.delay.value)*a.Xu,R.generator){let t=this.container.particles.pathGenerators.get(R.generator);!t&&(t=this.container.particles.availablePathGenerators.get(R.generator))&&(this.container.particles.pathGenerators.set(R.generator,t),t.init()),this.pathGenerator=t}g.retina.initParticle(this),this.size=(0,n.Xs)(this.options.size,f),this.bubble={inRange:!1},this.slow={inRange:!1,factor:1},this._initPosition(i),this.initialVelocity=this._calculateVelocity(),this.velocity=this.initialVelocity.copy(),this.moveDecay=a.WH-(0,s.VG)(this.options.move.decay);let O=g.particles;O.setLastZIndex(this.position.z),this.zIndexFactor=this.position.z/g.zLayers,this.sides=24,this.effect&&(d=g.particles.effectDrawers.get(this.effect)),d?.loadEffect&&d.loadEffect(this),this.shape&&(p=g.particles.shapeDrawers.get(this.shape)),p?.loadShape&&p.loadShape(this);let M=p?.getSidesCount;for(let t of(M&&(this.sides=M(this)),this.spawning=!1,O.updaters))t.init(this);for(let t of O.movers)t.init(this);for(let t of(d?.particleInit?.(g,this),p?.particleInit?.(g,this),g.particleCreatedPlugins))t.particleCreated?.(this)}isInsideCanvas(){let t=this.getRadius(),i=this.container.canvas.size,e=this.position;return e.x>=-t&&e.y>=-t&&e.y<=i.height+t&&e.x<=i.width+t}isShowingBack(){if(!this.roll)return!1;let t=this.roll.angle;if(this.roll.horizontal&&this.roll.vertical){let i=t%a.R1,e=i<a.tA?i+a.R1:i;return e>=Math.PI*a.MX&&e<Math.PI*a.Nu*a.MX}if(this.roll.horizontal){let i=(t+Math.PI*a.MX)%(Math.PI*a.gd),e=i<a.tA?i+Math.PI*a.gd:i;return e>=Math.PI&&e<Math.PI*a.gd}if(this.roll.vertical){let i=t%(Math.PI*a.gd),e=i<a.tA?i+Math.PI*a.gd:i;return e>=Math.PI&&e<Math.PI*a.gd}return!1}isVisible(){return!this.destroyed&&!this.spawning&&this.isInsideCanvas()}reset(){for(let t of this.container.particles.updaters)t.reset?.(this)}_calcPosition=(t,i)=>{let e=a.rq,r=t?_.p.create(t.x,t.y,i):void 0,n=this.container,h=n.particlePositionPlugins,o=this.options.move.outModes,l=this.getRadius(),c=n.canvas.size,{signal:d}=new AbortController;for(;!d.aborted;){for(let t of h){let e=t.particlePosition?.(r,this);if(e)return _.p.create(e.x,e.y,i)}let t=(0,s.Nx)({size:c,position:r}),d=_.p.create(t.x,t.y,i);this._fixHorizontal(d,l,o.left??o.default),this._fixHorizontal(d,l,o.right??o.default),this._fixVertical(d,l,o.top??o.default),this._fixVertical(d,l,o.bottom??o.default);let p=!0;for(let t of n.particles.checkParticlePositionPlugins)if(!(p=t.checkParticlePosition?.(this,d,e)??!0))break;if(p)return d;e+=a.Eo,r=void 0}return r};_calculateVelocity=()=>{let t=(0,s.$m)(this.direction).copy(),i=this.options.move;if(i.direction===g.F.inside||i.direction===g.F.outside)return t;let e=(0,s.pu)((0,s.VG)(i.angle.value)),r=(0,s.pu)((0,s.VG)(i.angle.offset)),n={left:r-e*a.MX,right:r+e*a.MX};return i.straight||(t.angle+=(0,s.vE)((0,s.DT)(n.left,n.right))),i.random&&"number"==typeof i.speed&&(t.length*=(0,s.G0)()),t};_fixHorizontal=(t,i,e)=>{y({outMode:e,checkModes:[f.Y.bounce],coord:t.x,maxCoord:this.container.canvas.size.width,setCb:i=>t.x+=i,radius:i})};_fixVertical=(t,i,e)=>{y({outMode:e,checkModes:[f.Y.bounce],coord:t.y,maxCoord:this.container.canvas.size.height,setCb:i=>t.y+=i,radius:i})};_getRollColor=t=>t&&this.roll&&(this.backColor||this.roll.alter)&&this.isShowingBack()?this.backColor?this.backColor:this.roll.alter?(0,r.yx)(t,this.roll.alter.type,this.roll.alter.value):t:t;_initPosition=t=>{let i=this.container,e=(0,s.VG)(this.options.zIndex.value),r=this._calcPosition(t,(0,s.qE)(e,a.X_,i.zLayers));if(!r)throw Error("a valid position cannot be found for particle");this.position=r,this.initialPosition=this.position.copy();let h=i.canvas.size;switch(this.moveCenter={...(0,n.E9)(this.options.move.center,h),radius:this.options.move.center.radius,mode:this.options.move.center.mode},this.direction=(0,s.JY)(this.options.move.direction,this.position,this.moveCenter),this.options.move.direction){case g.F.inside:this.outType=P.x.inside;break;case g.F.outside:this.outType=P.x.outside}this.offset=_.M.origin}}var v=e(2714),b=e(1636);class z{rectangle;capacity;_divided;_points;_subs;constructor(t,i){this.rectangle=t,this.capacity=i,this._points=[],this._divided=!1,this._subs=[]}insert(t){return!!this.rectangle.contains(t.position)&&(this._points.length<this.capacity?(this._points.push(t),!0):(this._divided||this._subdivide(),this._subs.some(i=>i.insert(t))))}query(t,i){let e=[];if(!t.intersects(this.rectangle))return[];for(let a of this._points)!t.contains(a.position)&&(0,s.Yf)(t.position,a.position)>a.particle.getRadius()&&(!i||i(a.particle))||e.push(a.particle);if(this._divided)for(let s of this._subs)e.push(...s.query(t,i));return e}queryCircle(t,i,e){return this.query(new b.jl(t.x,t.y,i),e)}queryRectangle(t,i,e){return this.query(new b.M_(t.x,t.y,i.width,i.height),e)}_subdivide=()=>{let{x:t,y:i}=this.rectangle.position,{width:e,height:s}=this.rectangle.size,{capacity:r}=this;for(let n=0;n<a.Pg;n++){let h=n%a.gd;this._subs.push(new z(new b.M_(t+e*a.MX*h,i+s*a.MX*(Math.round(n*a.MX)-h),e*a.MX,s*a.MX),r))}this._divided=!0}}var S=e(567);let C=t=>{let{height:i,width:e}=t;return new b.M_(a.un*e,a.un*i,a.Rh*e,a.Rh*i)};class D{availablePathGenerators;checkParticlePositionPlugins;effectDrawers;movers;pathGenerators;quadTree;shapeDrawers;updaters;_array;_container;_engine;_groupLimits;_limit;_maxZIndex;_minZIndex;_needsSort;_nextId;_particleResetPlugins;_particleUpdatePlugins;_pool;_postParticleUpdatePlugins;_postUpdatePlugins;_resizeFactor;_updatePlugins;_zArray;constructor(t,i){this._engine=t,this._container=i,this._nextId=0,this._array=[],this._zArray=[],this._pool=[],this._limit=0,this._groupLimits=new Map,this._needsSort=!1,this._minZIndex=0,this._maxZIndex=0;const e=i.canvas.size;this.quadTree=new z(C(e),a.Kw),this.effectDrawers=new Map,this.movers=[],this.availablePathGenerators=new Map,this.pathGenerators=new Map,this.shapeDrawers=new Map,this.updaters=[],this.checkParticlePositionPlugins=[],this._particleResetPlugins=[],this._particleUpdatePlugins=[],this._postUpdatePlugins=[],this._postParticleUpdatePlugins=[],this._updatePlugins=[]}get count(){return this._array.length}addParticle(t,i,e,s){let r=this._container.actualOptions.particles.number.limit.mode,n=void 0===e?this._limit:this._groupLimits.get(e)??this._limit,h=this.count;if(n>a.ou)switch(r){case u.d.delete:{let t=h+a.nq-n;t>a.wM&&this.removeQuantity(t);break}case u.d.wait:if(h>=n)return}try{let a=this._pool.pop()??new w(this._engine,this._container);a.init(this._nextId,t,i,e);let r=!0;if(s&&(r=s(a)),!r)return void this._pool.push(a);return this._array.push(a),this._zArray.push(a),this._nextId++,this._engine.dispatchEvent(d.B.particleAdded,{container:this._container,data:{particle:a}}),a}catch(t){(0,S.t)().warning(`error adding particle: ${t}`)}}clear(){this._array=[],this._zArray=[]}destroy(){let t=this._container;for(let[,i]of this.effectDrawers)i.destroy?.(t);for(let[,i]of this.shapeDrawers)i.destroy?.(t);this._array=[],this._pool.length=0,this._zArray=[],this.effectDrawers=new Map,this.movers=[],this.availablePathGenerators=new Map,this.pathGenerators=new Map,this.shapeDrawers=new Map,this.updaters=[],this.checkParticlePositionPlugins=[],this._particleResetPlugins=[],this._particleUpdatePlugins=[],this._postUpdatePlugins=[],this._postParticleUpdatePlugins=[],this._updatePlugins=[]}drawParticles(t){for(let i of this._zArray)i.draw(t)}filter(t){return this._array.filter(t)}find(t){return this._array.find(t)}get(t){return this._array[t]}async init(){let t=this._container,i=t.actualOptions;for(let i of(this._minZIndex=0,this._maxZIndex=0,this._needsSort=!1,this.checkParticlePositionPlugins=[],this._updatePlugins=[],this._particleUpdatePlugins=[],this._postUpdatePlugins=[],this._particleResetPlugins=[],this._postParticleUpdatePlugins=[],t.plugins))i.redrawInit&&await i.redrawInit(),i.checkParticlePosition&&this.checkParticlePositionPlugins.push(i),i.update&&this._updatePlugins.push(i),i.particleUpdate&&this._particleUpdatePlugins.push(i),i.postUpdate&&this._postUpdatePlugins.push(i),i.particleReset&&this._particleResetPlugins.push(i),i.postParticleUpdate&&this._postParticleUpdatePlugins.push(i);for(let i of(await this.initPlugins(),this.effectDrawers.values()))await i.init?.(t);for(let i of this.shapeDrawers.values())await i.init?.(t);let e=!1;for(let i of t.plugins)if(e=i.particlesInitialization?.()??e)break;if(!e){let t=i.particles,e=t.groups;for(let i in e){let s=e[i];if(s)for(let e=this.count,a=0;a<s.number.value&&e<t.number.value;e++,a++)this.addParticle(void 0,s,i)}for(let i=this.count;i<t.number.value;i++)this.addParticle()}}async initPlugins(){let t=this._container;for(let i of(this.effectDrawers=await this._engine.getEffectDrawers(t,!0),this.movers=await this._engine.getMovers(t,!0),this.availablePathGenerators=await this._engine.getPathGenerators(t,!0),this.pathGenerators=new Map,this.shapeDrawers=await this._engine.getShapeDrawers(t,!0),this.updaters=await this._engine.getUpdaters(t,!0),this.pathGenerators.values()))i.init()}push(t,i,e,s){for(let a=0;a<t;a++)this.addParticle(i,e,s)}async redraw(){this.clear(),await this.init(),this._container.canvas.drawParticles({value:0,factor:0})}remove(t,i,e){this.removeAt(this._array.indexOf(t),void 0,i,e)}removeAt(t,i=a.xd,e,s){if(t<a.z9||t>this.count)return;let r=0;for(let a=t;r<i&&a<this.count;a++)this._removeParticle(a,e,s)&&(a--,r++)}removeQuantity(t,i){this.removeAt(a.z9,t,i)}setDensity(){let t=this._container.actualOptions,i=t.particles.groups,e=0;for(let t of this._container.plugins)t.particlesDensityCount&&(e+=t.particlesDensityCount());for(let t in i){let s=i[t];if(!s)continue;let a=(0,m.y)(this._engine,this._container,s);this._applyDensity(a,e,t)}this._applyDensity(t.particles,e)}setLastZIndex(t){this._needsSort||=t>=this._maxZIndex||t>this._minZIndex&&t<this._maxZIndex}setResizeFactor(t){this._resizeFactor=t}update(t){let i=this._container,e=new Set;for(let t of(this.quadTree=new z(C(i.canvas.size),a.Kw),this.pathGenerators.values()))t.update();for(let i of this._updatePlugins)i.update?.(t);let s=this._resizeFactor;for(let i of this._array){for(let t of(s&&!i.ignoresResizeRatio&&(i.position.x*=s.width,i.position.y*=s.height,i.initialPosition.x*=s.width,i.initialPosition.y*=s.height),i.ignoresResizeRatio=!1,this._particleResetPlugins))t.particleReset?.(i);for(let e of this._particleUpdatePlugins){if(i.destroyed)break;e.particleUpdate?.(i,t)}for(let e of this.movers)e.isEnabled(i)&&e.move(i,t);if(i.destroyed){e.add(i);continue}this.quadTree.insert(new v.b(i.getPosition(),i))}if(e.size){let t=t=>!e.has(t);for(let i of(this._array=this.filter(t),this._zArray=this._zArray.filter(t),e))this._engine.dispatchEvent(d.B.particleRemoved,{container:this._container,data:{particle:i}});this._addToPool(...e)}for(let i of this._postUpdatePlugins)i.postUpdate?.(t);for(let i of this._array){for(let e of this.updaters)e.update(i,t);if(!i.destroyed&&!i.spawning)for(let e of this._postParticleUpdatePlugins)e.postParticleUpdate?.(i,t)}if(delete this._resizeFactor,this._needsSort){let t=this._zArray;t.sort((t,i)=>i.position.z-t.position.z||t.id-i.id);let i=t[a.z9],e=t[t.length-a.K3];if(!i||!e)return;this._maxZIndex=i.position.z,this._minZIndex=e.position.z,this._needsSort=!1}}_addToPool=(...t)=>{this._pool.push(...t)};_applyDensity=(t,i,e,s)=>{let r=t.number;if(!r.density.enable)return void(void 0===e?this._limit=r.limit.value:(s?.number.limit.value??r.limit.value)&&this._groupLimits.set(e,s?.number.limit.value??r.limit.value));let n=this._initDensityFactor(r.density),h=r.value,o=r.limit.value>a.ou?r.limit.value:h,l=Math.min(h,o)*n+i,c=Math.min(this.count,this.filter(t=>t.group===e).length);void 0===e?this._limit=r.limit.value*n:this._groupLimits.set(e,r.limit.value*n),c<l?this.push(Math.abs(l-c),void 0,t,e):c>l&&this.removeQuantity(c-l,e)};_initDensityFactor=t=>{let i=this._container;if(!i.canvas.element||!t.enable)return a.lA;let e=i.canvas.element,s=i.retina.pixelRatio;return e.width*e.height/(t.height*t.width*s**a.dm)};_removeParticle=(t,i,e)=>{let s=this._array[t];if(!s||s.group!==i)return!1;let r=this._zArray.indexOf(s);return this._array.splice(t,a.LD),this._zArray.splice(r,a.LD),s.destroy(e),this._engine.dispatchEvent(d.B.particleRemoved,{container:this._container,data:{particle:s}}),this._addToPool(s),!0}}class x{container;maxSpeed;pixelRatio;reduceFactor;sizeAnimationSpeed;constructor(t){this.container=t,this.pixelRatio=a.$x,this.reduceFactor=a.Zp}init(){let t=this.container,i=t.actualOptions;this.pixelRatio=i.detectRetina?devicePixelRatio:a.$x,this.reduceFactor=a.Zp;let e=this.pixelRatio,r=t.canvas;if(r.element){let t=r.element;r.size.width=t.offsetWidth*e,r.size.height=t.offsetHeight*e}let n=i.particles,h=n.move;this.maxSpeed=(0,s.VG)(h.gravity.maxSpeed)*e,this.sizeAnimationSpeed=(0,s.VG)(n.size.animation.speed)*e}initParticle(t){let i=t.options,e=this.pixelRatio,a=i.move,r=a.distance,n=t.retina;n.moveDrift=(0,s.VG)(a.drift)*e,n.moveSpeed=(0,s.VG)(a.speed)*e,n.sizeAnimationSpeed=(0,s.VG)(i.size.animation.speed)*e;let h=n.maxDistance;h.horizontal=void 0!==r.horizontal?r.horizontal*e:void 0,h.vertical=void 0!==r.vertical?r.vertical*e:void 0,n.maxSpeed=(0,s.VG)(a.gravity.maxSpeed)*e}}function R(t){return!t.destroyed}function O(t,i,...e){let s=new p.J(t,i);return(0,m.Z)(s,...e),s}class M{actualOptions;canvas;destroyed;fpsLimit;hdr;id;pageHidden;particleCreatedPlugins;particleDestroyedPlugins;particlePositionPlugins;particles;plugins;retina;started;zLayers;_delay;_delayTimeout;_delta={value:0,factor:0};_drawAnimationFrame;_duration;_engine;_eventListeners;_firstStart;_initialSourceOptions;_lastFrameTime;_lifeTime;_options;_paused;_smooth;_sourceOptions;constructor(t,i,e){this._engine=t,this.id=Symbol(i),this.fpsLimit=120,this.hdr=!1,this._smooth=!1,this._delay=0,this._duration=0,this._lifeTime=0,this._firstStart=!0,this.started=!1,this.destroyed=!1,this._paused=!0,this._lastFrameTime=0,this.zLayers=100,this.pageHidden=!1,this._sourceOptions=e,this._initialSourceOptions=e,this.retina=new x(this),this.canvas=new l(this,this._engine),this.particles=new D(this._engine,this),this.plugins=[],this.particleDestroyedPlugins=[],this.particleCreatedPlugins=[],this.particlePositionPlugins=[],this._options=O(this._engine,this),this.actualOptions=O(this._engine,this),this._eventListeners=new c(this),this._engine.dispatchEvent(d.B.containerBuilt,{container:this})}get animationStatus(){return!this._paused&&!this.pageHidden&&R(this)}get options(){return this._options}get sourceOptions(){return this._sourceOptions}addLifeTime(t){this._lifeTime+=t}alive(){return!this._duration||this._lifeTime<=this._duration}destroy(t=!0){if(R(this)){for(let t of(this.stop(),this.particles.destroy(),this.canvas.destroy(),this.plugins))t.destroy?.();if(this.plugins.length=0,this._engine.clearPlugins(this),this.destroyed=!0,t){let t=this._engine.items,i=t.indexOf(this);i>=a.vF&&t.splice(i,a.JC)}this._engine.dispatchEvent(d.B.containerDestroyed,{container:this})}}draw(t){if(!R(this))return;let i=t,e=t=>{i&&(this._lastFrameTime=void 0,i=!1),this._nextFrame(t)};this._drawAnimationFrame=(0,s.i0)(t=>{e(t)})}async export(t,i={}){for(let e of this.plugins){if(!e.export)continue;let s=await e.export(t,i);if(s.supported)return s.blob}(0,S.t)().error(`Export plugin with type ${t} not found`)}async init(){if(!R(this))return;let t=new Map;for(let i of this._engine.plugins){let e=await i.getPlugin(this);e.preInit&&await e.preInit(),t.set(i,e)}for(let[i,e]of(await this.particles.initPlugins(),this._options=O(this._engine,this,this._initialSourceOptions,this.sourceOptions),this.actualOptions=O(this._engine,this,this._options),this.plugins.length=0,this.particleDestroyedPlugins.length=0,this.particleCreatedPlugins.length=0,this.particlePositionPlugins.length=0,t))i.needsPlugin(this.actualOptions)&&(this.plugins.push(e),e.particleCreated&&this.particleCreatedPlugins.push(e),e.particleDestroyed&&this.particleDestroyedPlugins.push(e),e.particlePosition&&this.particlePositionPlugins.push(e));this.retina.init(),this.canvas.init(),this.updateActualOptions(),this.canvas.initBackground(),this.canvas.resize();let{delay:i,duration:e,fpsLimit:r,hdr:n,smooth:h,zLayers:o}=this.actualOptions;for(let t of(this.hdr=n,this.zLayers=o,this._duration=(0,s.VG)(e)*a.Xu,this._delay=(0,s.VG)(i)*a.Xu,this._lifeTime=0,this.fpsLimit=r>a.DN?r:a.i8,this._smooth=h,this.plugins))await t.init?.();for(let t of(await this.particles.init(),this._engine.dispatchEvent(d.B.containerInit,{container:this}),this.particles.setDensity(),this.plugins))t.particlesSetup?.();this._engine.dispatchEvent(d.B.particlesSetup,{container:this})}pause(){if(R(this)&&(void 0!==this._drawAnimationFrame&&((0,s.px)(this._drawAnimationFrame),delete this._drawAnimationFrame),!this._paused)){for(let t of this.plugins)t.pause?.();this.pageHidden||(this._paused=!0),this._engine.dispatchEvent(d.B.containerPaused,{container:this})}}play(t){if(!R(this))return;let i=this._paused||t;if(this._firstStart&&!this.actualOptions.autoPlay){this._firstStart=!1;return}if(this._paused&&(this._paused=!1),i)for(let t of this.plugins)t.play&&t.play();this._engine.dispatchEvent(d.B.containerPlay,{container:this}),this.draw(i??!1)}async refresh(){if(R(this))return this.stop(),this.start()}async reset(t){if(R(this))return this._initialSourceOptions=t,this._sourceOptions=t,this._options=O(this._engine,this,this._initialSourceOptions,this.sourceOptions),this.actualOptions=O(this._engine,this,this._options),this.refresh()}async start(){R(this)&&!this.started&&(await this.init(),this.started=!0,await new Promise(t=>{let i=async()=>{for(let t of(this._eventListeners.addListeners(),this.plugins))await t.start?.();this._engine.dispatchEvent(d.B.containerStarted,{container:this}),this.play(),t()};this._delayTimeout=setTimeout(()=>void i(),this._delay)}))}stop(){if(R(this)&&this.started){for(let t of(this._delayTimeout&&(clearTimeout(this._delayTimeout),delete this._delayTimeout),this._firstStart=!0,this.started=!1,this._eventListeners.removeListeners(),this.pause(),this.particles.clear(),this.canvas.stop(),this.plugins))t.stop?.();this.particleCreatedPlugins.length=0,this.particleDestroyedPlugins.length=0,this.particlePositionPlugins.length=0,this._sourceOptions=this._options,this._engine.dispatchEvent(d.B.containerStopped,{container:this})}}updateActualOptions(){let t=!1;for(let i of this.plugins)i.updateActualOptions&&(t=i.updateActualOptions()||t);return t}_nextFrame=t=>{try{if(!this._smooth&&void 0!==this._lastFrameTime&&t<this._lastFrameTime+a.Xu/this.fpsLimit||(this._lastFrameTime??=t,!function(t,i,e=a.z$,s=!1){t.value=i,t.factor=s?a.z$/e:a.z$*i/a.Xu}(this._delta,t-this._lastFrameTime,this.fpsLimit,this._smooth),this.addLifeTime(this._delta.value),this._lastFrameTime=t,this._delta.value>a.Xu))return void this.draw(!1);if(this.canvas.drawParticles(this._delta),!this.alive())return void this.destroy();this.animationStatus&&this.draw(!1)}catch(t){(0,S.t)().error("error in animation loop",t)}}}}}]);
@@ -87,7 +87,7 @@ export class Engine {
87
87
  return this._domArray;
88
88
  }
89
89
  get version() {
90
- return "4.0.0-alpha.18";
90
+ return "4.0.0-alpha.20";
91
91
  }
92
92
  addColorManager(name, manager) {
93
93
  this.colorManagers.set(name, manager);
@@ -87,7 +87,7 @@ export class Engine {
87
87
  return this._domArray;
88
88
  }
89
89
  get version() {
90
- return "4.0.0-alpha.18";
90
+ return "4.0.0-alpha.20";
91
91
  }
92
92
  addColorManager(name, manager) {
93
93
  this.colorManagers.set(name, manager);
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * tsParticles Engine v4.0.0-alpha.18
2
+ * tsParticles Engine v4.0.0-alpha.20
3
3
  * Author: Matteo Bruni
4
4
  * MIT license: https://opensource.org/licenses/MIT
5
5
  * Website: https://particles.js.org/
@@ -87,7 +87,7 @@ export class Engine {
87
87
  return this._domArray;
88
88
  }
89
89
  get version() {
90
- return "4.0.0-alpha.18";
90
+ return "4.0.0-alpha.20";
91
91
  }
92
92
  addColorManager(name, manager) {
93
93
  this.colorManagers.set(name, manager);
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@tsparticles/engine",
3
- "version": "4.0.0-alpha.18",
3
+ "version": "4.0.0-alpha.20",
4
4
  "description": "Easily create highly customizable particle, confetti and fireworks animations and use them as animated backgrounds for your website. Ready to use components available also for React, Vue.js (2.x and 3.x), Angular, Svelte, jQuery, Preact, Riot.js, Inferno.",
5
5
  "homepage": "https://particles.js.org",
6
6
  "scripts": {
package/report.html CHANGED
@@ -3,7 +3,7 @@
3
3
  <head>
4
4
  <meta charset="UTF-8"/>
5
5
  <meta name="viewport" content="width=device-width, initial-scale=1"/>
6
- <title>@tsparticles/engine [4 Feb 2026 at 09:15]</title>
6
+ <title>@tsparticles/engine [4 Feb 2026 at 15:35]</title>
7
7
  <link rel="shortcut icon" href="data:image/png;base64,iVBORw0KGgoAAAANSUhEUgAAAEAAAABACAMAAACdt4HsAAABrVBMVEUAAAD///////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////////+O1foceMD///+J0/qK1Pr7/v8Xdr/9///W8P4UdL7L7P0Scr2r4Pyj3vwad8D5/f/2/f+55f3E6f34+/2H0/ojfMKpzOd0rNgQcb3F3O/j9f7c8v6g3Pz0/P/w+v/q+P7n9v6T1/uQ1vuE0vqLut/y+v+Z2fvt+f+15Pzv9fuc2/vR7v2V2Pvd6/bg9P7I6/285/2y4/yp3/zp8vk8i8kqgMT7/P31+fyv4vxGkcz6/P6/6P3j7vfS5PNnpNUxhcbO7f7F6v3O4vHK3/DA2u631Ouy0eqXweKJud5wqthfoNMMbLvY8f73+v2dxeR8sNtTmdDx9/zX6PSjyeaCtd1YnNGX2PuQveCGt95Nls42h8dLlM3F4vBtAAAAM3RSTlMAAyOx0/sKBvik8opWGBMOAe3l1snDm2E9LSb06eHcu5JpHbarfHZCN9CBb08zzkdNS0kYaptYAAAFV0lEQVRYw92X51/aYBDHHS2O2qqttVbrqNq9m+TJIAYIShBkWwqIiCgoWvfeq7Z2/s29hyQNyUcR7LveGwVyXy6XH8/9rqxglLfUPLxVduUor3h0rfp2TYvpivk37929TkG037hffoX0+peVtZQc1589rigVUdXS/ABSAyEmGIO/1XfvldSK8vs3OqB6u3m0nxmIrvgB0dj7rr7Y9IbuF68hnfFaiHA/sxqm0wciIG43P60qKv9WXWc1RXGh/mFESFABTSBi0sNAKzqet17eCtOb3kZIDwxEEU0oAIJGYxNBDhBND29e0rtXXbcpuPmED9IhEAAQ/AXEaF8EPmnrrKsv0LvWR3fg5sWDNAFZOgAgaKvZDogHNU9MFwnnYROkc56RD5CjAbQX9Ow4g7upCsvYu55aSI/Nj0H1akgKQEUM94dwK65hYRmFU9MIcH/fqJYOZYcnuJSU/waKDgTOEVaVKhwrTRP5XzgSpAITYzom7UvkhFX5VutmxeNnWDjjswTKTyfgluNDGbUpWissXhF3s7mlSml+czWkg3D0l1nNjGNjz3myOQOa1KM/jOS6ebdbAVTCi4gljHSFrviza7tOgRWcS0MOUX9zdNgag5w7rRqA44Lzw0hr1WqES36dFliSJFlh2rXIae3FFcDDgKdxrUIDePr8jGcSClV1u7A9xeN0ModY/pHMxmR1EzRh8TJiwqsHmKW0l4FCEZI+jHio+JdPPE9qwQtTRxku2D8sIeRL2LnxWSllANCQGOIiqVHAz2ye2JR0DcH+HoxDkaADLjgxjKQ+AwCX/g0+DNgdG0ukYCONAe+dbc2IAc6fwt1ARoDSezNHxV2Cmzwv3O6lDMV55edBGwGK9n1+x2F8EDfAGCxug8MhpsMEcTEAWf3rx2vZhe/LAmtIn/6apE6PN0ULKgywD9mmdxbmFl3OvD5AS5fW5zLbv/YHmcsBTjf/afDz3MaZTVCfAP9z6/Bw6ycv8EUBWJIn9zYcoAWWlW9+OzO3vkTy8H+RANLmdrpOuYWdZYEXpo+TlCJrW5EARb7fF+bWdqf3hhyZI1nWJQHgznErZhbjoEsWqi8dQNoE294aldzFurwSABL2XXMf9+H1VQGke9exw5P/AnA5Pv5ngMul7LOvO922iwACu8WkCwLCafvM4CeWPxfA8lNHcWZSoi8EwMAIciKX2Z4SWCMAa3snCZ/G4EA8D6CMLNFsGQhkkz/gQNEBbPCbWsxGUpYVu3z8IyNAknwJkfPMEhLyrdi5RTyUVACkw4GSFRNWJNEW+fgPGwHD8/JxnRuLabN4CGNRkAE23na2+VmEAUmrYymSGjMAYqH84YUIyzgzs3XC7gNgH36Vcc4zKY9o9fgPBXUAiHHwVboBHGLiX6Zcjp1f2wu4tvzZKo0ecPnDtQYDQvJXaBeNzce45Fp28ZQLrEZVuFqgBwOalArKXnW1UzlnSusQKJqKYNuz4tOnI6sZG4zanpemv+7ySU2jbA9h6uhcgpfy6G2PahirDZ6zvq6zDduMVFTKvzw8wgyEdelwY9in3XkEPs3osJuwRQ4qTkfzifndg9Gfc4pdsu82+tTnHZTBa2EAMrqr2t43pguc8tNm7JQVQ2S0ukj2d22dhXYP0/veWtwKrCkNoNimAN5+Xr/oLrxswKbVJjteWrX7eR63o4j9q0GxnaBdWgGA5VStpanIjQmEhV0/nVt5VOFUvix6awJhPcAaTEShgrG+iGyvb5a0Ndb1YGHFPEwoqAinoaykaID1o1pdPNu7XsnCKQ3R+hwWIIhGvORcJUBYXe3Xa3vq/mF/N9V13ugufMkfXn+KHsRD0B8AAAAASUVORK5CYII=" type="image/x-icon" />
8
8
 
9
9
  <script>
@@ -1,5 +1,5 @@
1
1
  /*!
2
- * tsParticles Engine v4.0.0-alpha.18
2
+ * tsParticles Engine v4.0.0-alpha.20
3
3
  * Author: Matteo Bruni
4
4
  * MIT license: https://opensource.org/licenses/MIT
5
5
  * Website: https://particles.js.org/
@@ -36,7 +36,7 @@ return /******/ (() => { // webpackBootstrap
36
36
  \*************************************/
37
37
  (__unused_webpack___webpack_module__, __webpack_exports__, __webpack_require__) {
38
38
 
39
- eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ Engine: () => (/* binding */ Engine)\n/* harmony export */ });\n/* harmony import */ var _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./Utils/Constants.js */ \"./dist/browser/Core/Utils/Constants.js\");\n/* harmony import */ var _Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../Utils/Utils.js */ \"./dist/browser/Utils/Utils.js\");\n/* harmony import */ var _Utils_EventDispatcher_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../Utils/EventDispatcher.js */ \"./dist/browser/Utils/EventDispatcher.js\");\n/* harmony import */ var _Enums_Types_EventType_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../Enums/Types/EventType.js */ \"./dist/browser/Enums/Types/EventType.js\");\n/* harmony import */ var _Utils_LogUtils_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../Utils/LogUtils.js */ \"./dist/browser/Utils/LogUtils.js\");\n/* harmony import */ var _Utils_MathUtils_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../Utils/MathUtils.js */ \"./dist/browser/Utils/MathUtils.js\");\n\n\n\n\n\n\nconst fullPercent = \"100%\";\nasync function getDataFromUrl(data) {\n const url = (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.itemFromSingleOrMultiple)(data.url, data.index);\n if (!url) {\n return data.fallback;\n }\n const response = await fetch(url);\n if (response.ok) {\n return await response.json();\n }\n (0,_Utils_LogUtils_js__WEBPACK_IMPORTED_MODULE_4__.getLogger)().error(`${response.status.toString()} while retrieving config file`);\n return data.fallback;\n}\nconst getCanvasFromContainer = (domContainer)=>{\n const documentSafe = (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.safeDocument)();\n let canvasEl;\n if (domContainer instanceof HTMLCanvasElement || domContainer.tagName.toLowerCase() === _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.canvasTag) {\n canvasEl = domContainer;\n canvasEl.dataset[_Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedAttribute] ??= _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedFalse;\n } else {\n const existingCanvases = domContainer.getElementsByTagName(_Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.canvasTag), foundCanvas = existingCanvases[_Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.canvasFirstIndex];\n if (foundCanvas) {\n canvasEl = foundCanvas;\n canvasEl.dataset[_Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedAttribute] = _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedFalse;\n } else {\n canvasEl = documentSafe.createElement(_Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.canvasTag);\n canvasEl.dataset[_Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedAttribute] = _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedTrue;\n domContainer.appendChild(canvasEl);\n }\n }\n canvasEl.style.width ||= fullPercent;\n canvasEl.style.height ||= fullPercent;\n return canvasEl;\n}, getDomContainer = (id, source)=>{\n const documentSafe = (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.safeDocument)();\n let domContainer = source ?? documentSafe.getElementById(id);\n if (domContainer) {\n return domContainer;\n }\n domContainer = documentSafe.createElement(\"div\");\n domContainer.id = id;\n domContainer.dataset[_Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedAttribute] = _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedTrue;\n documentSafe.body.append(domContainer);\n return domContainer;\n};\nclass Engine {\n colorManagers = new Map();\n easingFunctions = new Map();\n effectDrawers = new Map();\n initializers = {\n effects: new Map(),\n movers: new Map(),\n pathGenerators: new Map(),\n shapes: new Map(),\n updaters: new Map()\n };\n movers = new Map();\n pathGenerators = new Map();\n plugins = [];\n presets = new Map();\n shapeDrawers = new Map();\n updaters = new Map();\n _allLoadersSet = new Set();\n _configs = new Map();\n _domArray = [];\n _eventDispatcher = new _Utils_EventDispatcher_js__WEBPACK_IMPORTED_MODULE_2__.EventDispatcher();\n _executedSet = new Set();\n _initialized = false;\n _isRunningLoaders = false;\n _loadPromises = new Set();\n get configs() {\n const res = {};\n for (const [name, config] of this._configs){\n res[name] = config;\n }\n return res;\n }\n get items() {\n return this._domArray;\n }\n get version() {\n return \"4.0.0-alpha.18\";\n }\n addColorManager(name, manager) {\n this.colorManagers.set(name, manager);\n }\n addConfig(config) {\n const key = config.key ?? config.name ?? \"default\";\n this._configs.set(key, config);\n this._eventDispatcher.dispatchEvent(_Enums_Types_EventType_js__WEBPACK_IMPORTED_MODULE_3__.EventType.configAdded, {\n data: {\n name: key,\n config\n }\n });\n }\n addEasing(name, easing) {\n if (this.easingFunctions.get(name)) {\n return;\n }\n this.easingFunctions.set(name, easing);\n }\n addEffect(effect, drawer) {\n this.initializers.effects.set(effect, drawer);\n }\n addEventListener(type, listener) {\n this._eventDispatcher.addEventListener(type, listener);\n }\n addMover(name, moverInitializer) {\n this.initializers.movers.set(name, moverInitializer);\n }\n addParticleUpdater(name, updaterInitializer) {\n this.initializers.updaters.set(name, updaterInitializer);\n }\n addPathGenerator(name, generator) {\n this.initializers.pathGenerators.set(name, generator);\n }\n addPlugin(plugin) {\n if (this.getPlugin(plugin.id)) {\n return;\n }\n this.plugins.push(plugin);\n }\n addPreset(preset, options, override = false) {\n if (!(override || !this.getPreset(preset))) {\n return;\n }\n this.presets.set(preset, options);\n }\n addShape(shapes, drawer) {\n for (const shape of shapes){\n this.initializers.shapes.set(shape, drawer);\n }\n }\n checkVersion(pluginVersion) {\n if (this.version === pluginVersion) {\n return;\n }\n throw new Error(`The tsParticles version is different from the loaded plugins version. Engine version: ${this.version}. Plugin version: ${pluginVersion}`);\n }\n clearPlugins(container) {\n this.effectDrawers.delete(container);\n this.movers.delete(container);\n this.shapeDrawers.delete(container);\n this.updaters.delete(container);\n }\n dispatchEvent(type, args) {\n this._eventDispatcher.dispatchEvent(type, args);\n }\n getEasing(name) {\n return this.easingFunctions.get(name) ?? ((value)=>value);\n }\n getEffectDrawers(container, force = false) {\n return (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.getItemMapFromInitializer)(container, this.effectDrawers, this.initializers.effects, force);\n }\n getMovers(container, force = false) {\n return (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.getItemsFromInitializer)(container, this.movers, this.initializers.movers, force);\n }\n getPathGenerators(container, force = false) {\n return (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.getItemMapFromInitializer)(container, this.pathGenerators, this.initializers.pathGenerators, force);\n }\n getPlugin(plugin) {\n return this.plugins.find((t)=>t.id === plugin);\n }\n getPreset(preset) {\n return this.presets.get(preset);\n }\n async getShapeDrawers(container, force = false) {\n return (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.getItemMapFromInitializer)(container, this.shapeDrawers, this.initializers.shapes, force);\n }\n async getUpdaters(container, force = false) {\n return (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.getItemsFromInitializer)(container, this.updaters, this.initializers.updaters, force);\n }\n async init() {\n if (this._initialized || this._isRunningLoaders) return;\n this._isRunningLoaders = true;\n this._executedSet = new Set();\n this._allLoadersSet = new Set(this._loadPromises);\n try {\n for (const loader of this._allLoadersSet){\n await this._runLoader(loader, this._executedSet, this._allLoadersSet);\n }\n } finally{\n this._loadPromises.clear();\n this._isRunningLoaders = false;\n this._initialized = true;\n }\n }\n item(index) {\n const { items } = this, item = items[index];\n if (item?.destroyed) {\n items.splice(index, _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.removeDeleteCount);\n return;\n }\n return item;\n }\n async load(params) {\n await this.init();\n const { Container } = await __webpack_require__.e(/*! import() */ \"dist_browser_Core_Container_js\").then(__webpack_require__.bind(__webpack_require__, /*! ./Container.js */ \"./dist/browser/Core/Container.js\")), id = params.id ?? params.element?.id ?? `tsparticles${Math.floor((0,_Utils_MathUtils_js__WEBPACK_IMPORTED_MODULE_5__.getRandom)() * _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.loadRandomFactor).toString()}`, { index, url } = params, options = url ? await getDataFromUrl({\n fallback: params.options,\n url,\n index\n }) : params.options, currentOptions = (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.itemFromSingleOrMultiple)(options, index), { items } = this, oldIndex = items.findIndex((v)=>v.id.description === id), newItem = new Container(this, id, currentOptions);\n if (oldIndex >= _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.loadMinIndex) {\n const old = this.item(oldIndex), deleteCount = old ? _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.one : _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.none;\n if (old && !old.destroyed) {\n old.destroy(false);\n }\n items.splice(oldIndex, deleteCount, newItem);\n } else {\n items.push(newItem);\n }\n const domContainer = getDomContainer(id, params.element), canvasEl = getCanvasFromContainer(domContainer);\n newItem.canvas.loadCanvas(canvasEl);\n await newItem.start();\n return newItem;\n }\n loadParticlesOptions(container, options, ...sourceOptions) {\n const updaters = this.updaters.get(container);\n if (!updaters) {\n return;\n }\n updaters.forEach((updater)=>updater.loadOptions?.(options, ...sourceOptions));\n }\n async refresh(refresh = true) {\n if (!refresh) {\n return;\n }\n await Promise.all(this.items.map((t)=>t.refresh()));\n }\n async register(...loaders) {\n if (this._initialized) {\n throw new Error(\"Register plugins can only be done before calling tsParticles.load()\");\n }\n for (const loader of loaders){\n if (this._isRunningLoaders) {\n await this._runLoader(loader, this._executedSet, this._allLoadersSet);\n } else {\n this._loadPromises.add(loader);\n }\n }\n }\n removeEventListener(type, listener) {\n this._eventDispatcher.removeEventListener(type, listener);\n }\n async _runLoader(loader, executed, allLoaders) {\n if (executed.has(loader)) return;\n executed.add(loader);\n allLoaders.add(loader);\n await loader(this);\n }\n}\n\n\n//# sourceURL=webpack://@tsparticles/engine/./dist/browser/Core/Engine.js?\n}");
39
+ eval("{__webpack_require__.r(__webpack_exports__);\n/* harmony export */ __webpack_require__.d(__webpack_exports__, {\n/* harmony export */ Engine: () => (/* binding */ Engine)\n/* harmony export */ });\n/* harmony import */ var _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(/*! ./Utils/Constants.js */ \"./dist/browser/Core/Utils/Constants.js\");\n/* harmony import */ var _Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(/*! ../Utils/Utils.js */ \"./dist/browser/Utils/Utils.js\");\n/* harmony import */ var _Utils_EventDispatcher_js__WEBPACK_IMPORTED_MODULE_2__ = __webpack_require__(/*! ../Utils/EventDispatcher.js */ \"./dist/browser/Utils/EventDispatcher.js\");\n/* harmony import */ var _Enums_Types_EventType_js__WEBPACK_IMPORTED_MODULE_3__ = __webpack_require__(/*! ../Enums/Types/EventType.js */ \"./dist/browser/Enums/Types/EventType.js\");\n/* harmony import */ var _Utils_LogUtils_js__WEBPACK_IMPORTED_MODULE_4__ = __webpack_require__(/*! ../Utils/LogUtils.js */ \"./dist/browser/Utils/LogUtils.js\");\n/* harmony import */ var _Utils_MathUtils_js__WEBPACK_IMPORTED_MODULE_5__ = __webpack_require__(/*! ../Utils/MathUtils.js */ \"./dist/browser/Utils/MathUtils.js\");\n\n\n\n\n\n\nconst fullPercent = \"100%\";\nasync function getDataFromUrl(data) {\n const url = (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.itemFromSingleOrMultiple)(data.url, data.index);\n if (!url) {\n return data.fallback;\n }\n const response = await fetch(url);\n if (response.ok) {\n return await response.json();\n }\n (0,_Utils_LogUtils_js__WEBPACK_IMPORTED_MODULE_4__.getLogger)().error(`${response.status.toString()} while retrieving config file`);\n return data.fallback;\n}\nconst getCanvasFromContainer = (domContainer)=>{\n const documentSafe = (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.safeDocument)();\n let canvasEl;\n if (domContainer instanceof HTMLCanvasElement || domContainer.tagName.toLowerCase() === _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.canvasTag) {\n canvasEl = domContainer;\n canvasEl.dataset[_Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedAttribute] ??= _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedFalse;\n } else {\n const existingCanvases = domContainer.getElementsByTagName(_Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.canvasTag), foundCanvas = existingCanvases[_Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.canvasFirstIndex];\n if (foundCanvas) {\n canvasEl = foundCanvas;\n canvasEl.dataset[_Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedAttribute] = _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedFalse;\n } else {\n canvasEl = documentSafe.createElement(_Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.canvasTag);\n canvasEl.dataset[_Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedAttribute] = _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedTrue;\n domContainer.appendChild(canvasEl);\n }\n }\n canvasEl.style.width ||= fullPercent;\n canvasEl.style.height ||= fullPercent;\n return canvasEl;\n}, getDomContainer = (id, source)=>{\n const documentSafe = (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.safeDocument)();\n let domContainer = source ?? documentSafe.getElementById(id);\n if (domContainer) {\n return domContainer;\n }\n domContainer = documentSafe.createElement(\"div\");\n domContainer.id = id;\n domContainer.dataset[_Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedAttribute] = _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.generatedTrue;\n documentSafe.body.append(domContainer);\n return domContainer;\n};\nclass Engine {\n colorManagers = new Map();\n easingFunctions = new Map();\n effectDrawers = new Map();\n initializers = {\n effects: new Map(),\n movers: new Map(),\n pathGenerators: new Map(),\n shapes: new Map(),\n updaters: new Map()\n };\n movers = new Map();\n pathGenerators = new Map();\n plugins = [];\n presets = new Map();\n shapeDrawers = new Map();\n updaters = new Map();\n _allLoadersSet = new Set();\n _configs = new Map();\n _domArray = [];\n _eventDispatcher = new _Utils_EventDispatcher_js__WEBPACK_IMPORTED_MODULE_2__.EventDispatcher();\n _executedSet = new Set();\n _initialized = false;\n _isRunningLoaders = false;\n _loadPromises = new Set();\n get configs() {\n const res = {};\n for (const [name, config] of this._configs){\n res[name] = config;\n }\n return res;\n }\n get items() {\n return this._domArray;\n }\n get version() {\n return \"4.0.0-alpha.20\";\n }\n addColorManager(name, manager) {\n this.colorManagers.set(name, manager);\n }\n addConfig(config) {\n const key = config.key ?? config.name ?? \"default\";\n this._configs.set(key, config);\n this._eventDispatcher.dispatchEvent(_Enums_Types_EventType_js__WEBPACK_IMPORTED_MODULE_3__.EventType.configAdded, {\n data: {\n name: key,\n config\n }\n });\n }\n addEasing(name, easing) {\n if (this.easingFunctions.get(name)) {\n return;\n }\n this.easingFunctions.set(name, easing);\n }\n addEffect(effect, drawer) {\n this.initializers.effects.set(effect, drawer);\n }\n addEventListener(type, listener) {\n this._eventDispatcher.addEventListener(type, listener);\n }\n addMover(name, moverInitializer) {\n this.initializers.movers.set(name, moverInitializer);\n }\n addParticleUpdater(name, updaterInitializer) {\n this.initializers.updaters.set(name, updaterInitializer);\n }\n addPathGenerator(name, generator) {\n this.initializers.pathGenerators.set(name, generator);\n }\n addPlugin(plugin) {\n if (this.getPlugin(plugin.id)) {\n return;\n }\n this.plugins.push(plugin);\n }\n addPreset(preset, options, override = false) {\n if (!(override || !this.getPreset(preset))) {\n return;\n }\n this.presets.set(preset, options);\n }\n addShape(shapes, drawer) {\n for (const shape of shapes){\n this.initializers.shapes.set(shape, drawer);\n }\n }\n checkVersion(pluginVersion) {\n if (this.version === pluginVersion) {\n return;\n }\n throw new Error(`The tsParticles version is different from the loaded plugins version. Engine version: ${this.version}. Plugin version: ${pluginVersion}`);\n }\n clearPlugins(container) {\n this.effectDrawers.delete(container);\n this.movers.delete(container);\n this.shapeDrawers.delete(container);\n this.updaters.delete(container);\n }\n dispatchEvent(type, args) {\n this._eventDispatcher.dispatchEvent(type, args);\n }\n getEasing(name) {\n return this.easingFunctions.get(name) ?? ((value)=>value);\n }\n getEffectDrawers(container, force = false) {\n return (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.getItemMapFromInitializer)(container, this.effectDrawers, this.initializers.effects, force);\n }\n getMovers(container, force = false) {\n return (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.getItemsFromInitializer)(container, this.movers, this.initializers.movers, force);\n }\n getPathGenerators(container, force = false) {\n return (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.getItemMapFromInitializer)(container, this.pathGenerators, this.initializers.pathGenerators, force);\n }\n getPlugin(plugin) {\n return this.plugins.find((t)=>t.id === plugin);\n }\n getPreset(preset) {\n return this.presets.get(preset);\n }\n async getShapeDrawers(container, force = false) {\n return (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.getItemMapFromInitializer)(container, this.shapeDrawers, this.initializers.shapes, force);\n }\n async getUpdaters(container, force = false) {\n return (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.getItemsFromInitializer)(container, this.updaters, this.initializers.updaters, force);\n }\n async init() {\n if (this._initialized || this._isRunningLoaders) return;\n this._isRunningLoaders = true;\n this._executedSet = new Set();\n this._allLoadersSet = new Set(this._loadPromises);\n try {\n for (const loader of this._allLoadersSet){\n await this._runLoader(loader, this._executedSet, this._allLoadersSet);\n }\n } finally{\n this._loadPromises.clear();\n this._isRunningLoaders = false;\n this._initialized = true;\n }\n }\n item(index) {\n const { items } = this, item = items[index];\n if (item?.destroyed) {\n items.splice(index, _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.removeDeleteCount);\n return;\n }\n return item;\n }\n async load(params) {\n await this.init();\n const { Container } = await __webpack_require__.e(/*! import() */ \"dist_browser_Core_Container_js\").then(__webpack_require__.bind(__webpack_require__, /*! ./Container.js */ \"./dist/browser/Core/Container.js\")), id = params.id ?? params.element?.id ?? `tsparticles${Math.floor((0,_Utils_MathUtils_js__WEBPACK_IMPORTED_MODULE_5__.getRandom)() * _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.loadRandomFactor).toString()}`, { index, url } = params, options = url ? await getDataFromUrl({\n fallback: params.options,\n url,\n index\n }) : params.options, currentOptions = (0,_Utils_Utils_js__WEBPACK_IMPORTED_MODULE_1__.itemFromSingleOrMultiple)(options, index), { items } = this, oldIndex = items.findIndex((v)=>v.id.description === id), newItem = new Container(this, id, currentOptions);\n if (oldIndex >= _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.loadMinIndex) {\n const old = this.item(oldIndex), deleteCount = old ? _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.one : _Utils_Constants_js__WEBPACK_IMPORTED_MODULE_0__.none;\n if (old && !old.destroyed) {\n old.destroy(false);\n }\n items.splice(oldIndex, deleteCount, newItem);\n } else {\n items.push(newItem);\n }\n const domContainer = getDomContainer(id, params.element), canvasEl = getCanvasFromContainer(domContainer);\n newItem.canvas.loadCanvas(canvasEl);\n await newItem.start();\n return newItem;\n }\n loadParticlesOptions(container, options, ...sourceOptions) {\n const updaters = this.updaters.get(container);\n if (!updaters) {\n return;\n }\n updaters.forEach((updater)=>updater.loadOptions?.(options, ...sourceOptions));\n }\n async refresh(refresh = true) {\n if (!refresh) {\n return;\n }\n await Promise.all(this.items.map((t)=>t.refresh()));\n }\n async register(...loaders) {\n if (this._initialized) {\n throw new Error(\"Register plugins can only be done before calling tsParticles.load()\");\n }\n for (const loader of loaders){\n if (this._isRunningLoaders) {\n await this._runLoader(loader, this._executedSet, this._allLoadersSet);\n } else {\n this._loadPromises.add(loader);\n }\n }\n }\n removeEventListener(type, listener) {\n this._eventDispatcher.removeEventListener(type, listener);\n }\n async _runLoader(loader, executed, allLoaders) {\n if (executed.has(loader)) return;\n executed.add(loader);\n allLoaders.add(loader);\n await loader(this);\n }\n}\n\n\n//# sourceURL=webpack://@tsparticles/engine/./dist/browser/Core/Engine.js?\n}");
40
40
 
41
41
  /***/ },
42
42
 
@@ -1,2 +1,2 @@
1
- !function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var i=t();for(var a in i)("object"==typeof exports?exports:e)[a]=i[a]}}(this,()=>(()=>{"use strict";var e,t,i,a,n,s,o,r,l,d={299(e,t,i){var a,n;i.d(t,{B:()=>a}),(n=a||(a={})).configAdded="configAdded",n.containerInit="containerInit",n.particlesSetup="particlesSetup",n.containerStarted="containerStarted",n.containerStopped="containerStopped",n.containerDestroyed="containerDestroyed",n.containerPaused="containerPaused",n.containerPlay="containerPlay",n.containerBuilt="containerBuilt",n.particleAdded="particleAdded",n.particleDestroyed="particleDestroyed",n.particleRemoved="particleRemoved"},546(e,t,i){var a,n;i.d(t,{F:()=>a}),(n=a||(a={})).bottom="bottom",n.bottomLeft="bottom-left",n.bottomRight="bottom-right",n.left="left",n.none="none",n.right="right",n.top="top",n.topLeft="top-left",n.topRight="top-right",n.outside="outside",n.inside="inside"},816(e,t,i){i.d(t,{j:()=>s});var a=i(5045),n=i(9739);class s{bottom;default;left;right;top;constructor(){this.default=a.Y.out}load(e){(0,n.kZ)(e)||(void 0!==e.default&&(this.default=e.default),this.bottom=e.bottom??e.default,this.left=e.left??e.default,this.right=e.right??e.default,this.top=e.top??e.default)}}},884(e,t,i){i.d(t,{v:()=>o});var a=i(4860),n=i(5107),s=i(9739);class o{clamp;delay;enable;generator;options;constructor(){this.clamp=!0,this.delay=new a.PV,this.enable=!1,this.options={}}load(e){!(0,s.kZ)(e)&&(void 0!==e.clamp&&(this.clamp=e.clamp),this.delay.load(e.delay),void 0!==e.enable&&(this.enable=e.enable),this.generator=e.generator,e.options&&(this.options=(0,n.zw)(this.options,e.options)))}}},1139(e,t,i){i.d(t,{V:()=>s});var a=i(5633),n=i(9739);class s{color;image;opacity;position;repeat;size;constructor(){this.color=new a.O,this.color.value="",this.image="",this.position="",this.repeat="",this.size="",this.opacity=1}load(e){(0,n.kZ)(e)||(void 0!==e.color&&(this.color=a.O.create(this.color,e.color)),void 0!==e.image&&(this.image=e.image),void 0!==e.position&&(this.position=e.position),void 0!==e.repeat&&(this.repeat=e.repeat),void 0!==e.size&&(this.size=e.size),void 0!==e.opacity&&(this.opacity=e.opacity))}}},1412(e,t,i){i.d(t,{t:()=>o});var a=i(5107),n=i(9739),s=i(1913);class o{acceleration;enable;position;constructor(){this.acceleration=0,this.enable=!1}load(e){!(0,n.kZ)(e)&&(void 0!==e.acceleration&&(this.acceleration=(0,s.DT)(e.acceleration)),void 0!==e.enable&&(this.enable=e.enable),e.position&&(this.position=(0,a.zw)({},e.position)))}}},1695(e,t,i){i.d(t,{y:()=>s});var a=i(9739),n=i(1913);class s{acceleration;enable;inverse;maxSpeed;constructor(){this.acceleration=9.81,this.enable=!1,this.inverse=!1,this.maxSpeed=50}load(e){(0,a.kZ)(e)||(void 0!==e.acceleration&&(this.acceleration=(0,n.DT)(e.acceleration)),void 0!==e.enable&&(this.enable=e.enable),void 0!==e.inverse&&(this.inverse=e.inverse),void 0!==e.maxSpeed&&(this.maxSpeed=(0,n.DT)(e.maxSpeed)))}}},1789(e,t,i){i.d(t,{Y:()=>o});var a=i(4615),n=i(4860),s=i(9739);class o extends n.AI{animation;constructor(){super(),this.animation=new a.I,this.value=1}load(e){if((0,s.kZ)(e))return;super.load(e);let t=e.animation;void 0!==t&&this.animation.load(t)}}},1803(e,t,i){i.d(t,{i:()=>s});var a=i(5127),n=i(9739);class s{h=new a.e;l=new a.e;s=new a.e;load(e){(0,n.kZ)(e)||(this.h.load(e.h),this.s.load(e.s),this.l.load(e.l))}}},1913(e,t,i){i.d(t,{$m:()=>R,AD:()=>p,DT:()=>function e(t,i){if(t===i||void 0===i&&(0,o.Et)(t))return t;let a=x(t),n=w(t);return void 0!==i?{min:Math.min(a,i),max:Math.max(n,i)}:e(a,n)},G0:()=>u,JY:()=>O,M3:()=>I,Mh:()=>T,Nx:()=>_,OE:()=>c,OW:()=>P,Sg:()=>x,VG:()=>b,W9:()=>w,Yf:()=>z,e4:()=>h,eh:()=>k,i0:()=>f,jh:()=>m,l1:()=>F,pu:()=>S,px:()=>v,qE:()=>g,qM:()=>E,vE:()=>y,vr:()=>M});var a=i(546),n=i(7313),s=i(2740),o=i(9739);let r=Math.PI/180,l=Math.random,d={nextFrame:e=>requestAnimationFrame(e),cancel:e=>{cancelAnimationFrame(e)}};function c(e=Math.random){l=e}function u(){return g(l(),0,1-Number.EPSILON)}function h(e,t){return u()*(t-e)+e}function p(e,t){d.nextFrame=t=>e(t),d.cancel=e=>{t(e)}}function f(e){return d.nextFrame(e)}function v(e){d.cancel(e)}function g(e,t,i){return Math.min(Math.max(e,t),i)}function m(e,t,i,a){return Math.floor((e*i+t*a)/(i+a))}function y(e){let t=w(e),i=x(e);return t===i&&(i=0),h(i,t)}function b(e){return(0,o.Et)(e)?e:y(e)}function x(e){return(0,o.Et)(e)?e:e.min}function w(e){return(0,o.Et)(e)?e:e.max}function M(e,t){let i=e.x-t.x,a=e.y-t.y;return{dx:i,dy:a,distance:Math.sqrt(i**2+a**2)}}function z(e,t){return M(e,t).distance}function S(e){return e*r}function O(e,t,i){if((0,o.Et)(e))return e*r;switch(e){case a.F.top:return-Math.PI*n.MX;case a.F.topRight:return-Math.PI*n.$G;case a.F.right:return n.Ie;case a.F.bottomRight:return Math.PI*n.$G;case a.F.bottom:return Math.PI*n.MX;case a.F.bottomLeft:return Math.PI*n.Rq;case a.F.left:return Math.PI;case a.F.topLeft:return-Math.PI*n.Rq;case a.F.inside:return Math.atan2(i.y-t.y,i.x-t.x);case a.F.outside:return Math.atan2(t.y-i.y,t.x-i.x);default:return u()*n.R1}}function R(e){let t=s.M.origin;return t.length=1,t.angle=e,t}function P(e,t,i,a){return s.M.create(e.x*(i-a)/(i+a)+t.x*n.gd*a/(i+a),e.y)}function k(e){return e.position?.x!==void 0&&void 0!==e.position.y?{x:e.position.x*e.size.width/n.a5,y:e.position.y*e.size.height/n.a5}:void 0}function T(e){return{x:(e.position?.x??u()*n.a5)*e.size.width/n.a5,y:(e.position?.y??u()*n.a5)*e.size.height/n.a5}}function F(e){let t={x:e.position?.x!==void 0?b(e.position.x):void 0,y:e.position?.y!==void 0?b(e.position.y):void 0};return T({size:e.size,position:t})}function _(e){let{position:t,size:i}=e;return{x:t?.x??u()*i.width,y:t?.y??u()*i.height}}function E(e){let t={x:e.position?.x!==void 0?b(e.position.x):void 0,y:e.position?.y!==void 0?b(e.position.y):void 0};return _({size:e.size,position:t})}function I(e){return e?e.endsWith("%")?parseFloat(e)/n.a5:parseFloat(e):1}},1964(e,t,i){i.d(t,{BN:()=>u,EY:()=>S,Jv:()=>_,K6:()=>v,Ko:()=>F,LC:()=>z,OH:()=>x,O_:()=>P,PG:()=>R,R5:()=>f,YL:()=>y,_h:()=>O,ay:()=>b,eg:()=>m,mK:()=>p,pz:()=>k,qe:()=>h,xx:()=>w,zI:()=>g});var a=i(1913),n=i(7313),s=i(9739),o=i(7205),r=i(5107);let l=new Map;function d(e,t){let i=l.get(e);return i||(i=t(),l.size>=1e3&&[...l.keys()].slice(0,1e3*n.MX).forEach(e=>l.delete(e)),l.set(e,i)),i}function c(e,t){if(t){for(let i of e.colorManagers.values())if(i.accepts(t))return i.parseString(t)}}function u(e,t,i,a=!0){if(!t)return;let n=(0,s.Kg)(t)?{value:t}:t;if((0,s.Kg)(n.value))return h(e,n.value,i,a);if((0,s.cy)(n.value)){let t=(0,r.Vh)(n.value,i,a);if(!t)return;return u(e,{value:t})}for(let t of e.colorManagers.values()){let e=t.handleRangeColor(n);if(e)return e}}function h(e,t,i,a=!0){if(!t)return;let o=(0,s.Kg)(t)?{value:t}:t;if((0,s.Kg)(o.value))return o.value===n.mR?x():c(e,o.value);if((0,s.cy)(o.value)){let t=(0,r.Vh)(o.value,i,a);if(!t)return;return h(e,{value:t})}for(let t of e.colorManagers.values()){let e=t.handleColor(o);if(e)return e}}function p(e,t,i,a=!0){let n=h(e,t,i,a);return n?v(n):void 0}function f(e,t,i,a=!0){let n=u(e,t,i,a);return n?v(n):void 0}function v(e){let t=e.r/n.oi,i=e.g/n.oi,a=e.b/n.oi,s=Math.max(t,i,a),o=Math.min(t,i,a),r={h:n.L1,l:(s+o)*n.MX,s:n.yx};return s!==o&&(r.s=r.l<n.MX?(s-o)/(s+o):(s-o)/(n.gd-s-o),t===s?r.h=(i-a)/(s-o):i===s?r.h=n.gd+(a-t)/(s-o):r.h=n.gd*n.gd+(t-i)/(s-o)),r.l*=n.$_,r.s*=n.eu,r.h*=n.U0,r.h<n.L1&&(r.h+=n.vS),r.h>=n.vS&&(r.h-=n.vS),r}function g(e,t){return c(e,t)?.a}function m(e,t){return c(e,t)}function y(e){let t=(e.h%n.vS+n.vS)%n.vS,i=Math.max(n.yx,Math.min(n.eu,e.s)),a=Math.max(n.vd,Math.min(n.$_,e.l)),s=t/n.vS,o=i/n.eu,r=a/n.$_;if(i===n.yx){let e=Math.round(r*n.oi);return{r:e,g:e,b:e}}let l=(e,t,i)=>(i<0&&i++,i>1&&i--,i*n.zg<1)?e+(t-e)*n.zg*i:i*n.gd<1?t:i*n.Nu<+n.gd?e+(t-e)*(n.gd/n.Nu-i)*n.zg:e,d=r<n.MX?r*(n.aE+o):r+o-r*o,c=n.gd*r-d,u=n.BF/n.Nu;return{r:Math.round(Math.min(n.oi,n.oi*l(c,d,s+u))),g:Math.round(Math.min(n.oi,n.oi*l(c,d,s))),b:Math.round(Math.min(n.oi,n.oi*l(c,d,s-u)))}}function b(e){let t=y(e);return{a:e.a,b:t.b,g:t.g,r:t.r}}function x(e){let t=e??n.Fl,i=n.oi+n.D_,s=()=>Math.floor((0,a.e4)(t,i));return{b:s(),g:s(),r:s()}}function w(e,t,i){let a=i??n.hv;return d(`rgb-${e.r.toFixed(2)}-${e.g.toFixed(2)}-${e.b.toFixed(2)}-${t?"hdr":"sdr"}-${a.toString()}`,()=>{var a,s;return t?M(e,i):(a=e,s=i,`rgba(${a.r.toString()}, ${a.g.toString()}, ${a.b.toString()}, ${(s??n.hv).toString()})`)})}function M(e,t){return`color(display-p3 ${(e.r/n.oi).toString()} ${(e.g/n.oi).toString()} ${(e.b/n.oi).toString()} / ${(t??n.hv).toString()})`}function z(e,t,i){let a=i??n.hv;return d(`hsl-${e.h.toFixed(2)}-${e.s.toFixed(2)}-${e.l.toFixed(2)}-${t?"hdr":"sdr"}-${a.toString()}`,()=>{var a,s,o,r;return t?(a=e,s=i,M(y(a),s)):(o=e,r=i,`hsla(${o.h.toString()}, ${o.s.toString()}%, ${o.l.toString()}%, ${(r??n.hv).toString()})`)})}function S(e,t,i,n){let s=e,o=t;return Object.hasOwn(s,"r")||(s=y(e)),Object.hasOwn(o,"r")||(o=y(t)),{b:(0,a.jh)(s.b,o.b,i,n),g:(0,a.jh)(s.g,o.g,i,n),r:(0,a.jh)(s.r,o.r,i,n)}}function O(e,t,i){if(i===n.mR)return x();if(i!==n.BW)return i;{let i=e.getFillColor()??e.getStrokeColor(),a=t?.getFillColor()??t?.getStrokeColor();if(i&&a&&t)return S(i,a,e.getRadius(),t.getRadius());{let e=i??a;if(e)return y(e)}}}function R(e,t,i,a){let o=(0,s.Kg)(t)?t:t.value;return o===n.mR?a?u(e,{value:o}):i?n.mR:n.BW:o===n.BW?n.BW:u(e,{value:o})}function P(e){return void 0!==e?{h:e.h.value,s:e.s.value,l:e.l.value}:void 0}function k(e,t,i){let a={h:{enable:!1,value:e.h},s:{enable:!1,value:e.s},l:{enable:!1,value:e.l}};return t&&(T(a.h,t.h,i),T(a.s,t.s,i),T(a.l,t.l,i)),a}function T(e,t,i){e.enable=t.enable,e.enable?(e.velocity=(0,a.VG)(t.speed)/n.a5*i,e.decay=n.WH-(0,a.VG)(t.decay),e.status=o.H.increasing,e.loops=n.hK,e.maxLoops=(0,a.VG)(t.count),e.time=n.tR,e.delayTime=(0,a.VG)(t.delay)*n.Xu,t.sync||(e.velocity*=(0,a.G0)(),e.value*=(0,a.G0)()),e.initialValue=e.value,e.offset=(0,a.DT)(t.offset)):e.velocity=n.jn}function F(e,t,i,n){if(!e.enable||(e.maxLoops??0)>0&&(e.loops??0)>(e.maxLoops??0)||(e.time??=0,(e.delayTime??0)>0&&e.time<(e.delayTime??0)&&(e.time+=n.value),(e.delayTime??0)>0&&e.time<(e.delayTime??0)))return;let s=e.offset?(0,a.vE)(e.offset):0,r=(e.velocity??0)*n.factor+3.6*s,l=e.decay??1,d=(0,a.W9)(t),c=(0,a.Sg)(t);i&&e.status!==o.H.increasing?(e.value-=r,e.value<0&&(e.loops??=0,e.loops++,e.status=o.H.increasing)):(e.value+=r,e.value>d&&(e.loops??=0,e.loops++,i?e.status=o.H.decreasing:e.value-=d)),e.velocity&&1!==l&&(e.velocity*=l),e.value=(0,a.qE)(e.value,c,d)}function _(e,t){if(!e)return;let{h:i,s:a,l:s}=e,o={h:{min:n.L1,max:n.vS},s:{min:n.yx,max:n.eu},l:{min:n.vd,max:n.$_}};F(i,o.h,!1,t),F(a,o.s,!0,t),F(s,o.l,!0,t)}},2010(e,t,i){var a,n;i.d(t,{S:()=>a}),(n=a||(a={})).max="max",n.min="min",n.random="random"},2057(e,t,i){i.d(t,{y:()=>s});var a=i(5107),n=i(9739);class s{close;fill;options;type;constructor(){this.close=!0,this.fill=!0,this.options={},this.type="circle"}load(e){if((0,n.kZ)(e))return;let t=e.options;if(void 0!==t)for(let e in t){let i=t[e];i&&(this.options[e]=(0,a.zw)(this.options[e]??{},i))}void 0!==e.close&&(this.close=e.close),void 0!==e.fill&&(this.fill=e.fill),void 0!==e.type&&(this.type=e.type)}}},2268(e,t,i){i.d(t,{Z:()=>s});var a=i(7073),n=i(9739);class s{mode;radius;x;y;constructor(){this.x=50,this.y=50,this.mode=a.q.percent,this.radius=0}load(e){(0,n.kZ)(e)||(void 0!==e.x&&(this.x=e.x),void 0!==e.y&&(this.y=e.y),void 0!==e.mode&&(this.mode=e.mode),void 0!==e.radius&&(this.radius=e.radius))}}},2679(e,t,i){i.d(t,{Z:()=>n,y:()=>s});var a=i(5953);function n(e,...t){for(let i of t)e.load(i)}function s(e,t,...i){let o=new a.U(e,t);return n(o,...i),o}},2685(e,t,i){i.d(t,{A:()=>o});var a=i(9739),n=i(1803),s=i(5633);class o extends s.O{animation;constructor(){super(),this.animation=new n.i}static create(e,t){let i=new o;return i.load(e),void 0!==t&&((0,a.Kg)(t)||(0,a.cy)(t)?i.load({value:t}):i.load(t)),i}load(e){if(super.load(e),(0,a.kZ)(e))return;let t=e.animation;void 0!==t&&(void 0===t.enable?this.animation.load(e.animation):this.animation.h.load(t))}}},2740(e,t,i){i.d(t,{M:()=>s,p:()=>n});var a=i(7313);class n{x;y;z;constructor(e=a.bo.x,t=a.bo.y,i=a.bo.z){this.x=e,this.y=t,this.z=i}static get origin(){return n.create(a.bo.x,a.bo.y,a.bo.z)}get angle(){return Math.atan2(this.y,this.x)}set angle(e){this._updateFromAngle(e,this.length)}get length(){return Math.sqrt(this.getLengthSq())}set length(e){this._updateFromAngle(this.angle,e)}static clone(e){return n.create(e.x,e.y,e.z)}static create(e,t,i){return"number"==typeof e?new n(e,t??a.bo.y,i??a.bo.z):new n(e.x,e.y,Object.hasOwn(e,"z")?e.z:a.bo.z)}add(e){return n.create(this.x+e.x,this.y+e.y,this.z+e.z)}addTo(e){this.x+=e.x,this.y+=e.y,this.z+=e.z}copy(){return n.clone(this)}distanceTo(e){return this.sub(e).length}distanceToSq(e){return this.sub(e).getLengthSq()}div(e){return n.create(this.x/e,this.y/e,this.z/e)}divTo(e){this.x/=e,this.y/=e,this.z/=e}getLengthSq(){return this.x**a.dm+this.y**a.dm}mult(e){return n.create(this.x*e,this.y*e,this.z*e)}multTo(e){this.x*=e,this.y*=e,this.z*=e}normalize(){let e=this.length;e!=a.dv&&this.multTo(a.hB/e)}rotate(e){return n.create(this.x*Math.cos(e)-this.y*Math.sin(e),this.x*Math.sin(e)+this.y*Math.cos(e),a.bo.z)}setTo(e){this.x=e.x,this.y=e.y,this.z=e.z?e.z:a.bo.z}sub(e){return n.create(this.x-e.x,this.y-e.y,this.z-e.z)}subFrom(e){this.x-=e.x,this.y-=e.y,this.z-=e.z}_updateFromAngle=(e,t)=>{this.x=Math.cos(e)*t,this.y=Math.sin(e)*t}}class s extends n{constructor(e=a.bo.x,t=a.bo.y){super(e,t,a.bo.z)}static get origin(){return s.create(a.bo.x,a.bo.y)}static clone(e){return s.create(e.x,e.y)}static create(e,t){return"number"==typeof e?new s(e,t??a.bo.y):new s(e.x,e.y)}}},3801(e,t,i){i.d(t,{M:()=>n});var a=i(9739);class n{enable;height;width;constructor(){this.enable=!1,this.width=1920,this.height=1080}load(e){if((0,a.kZ)(e))return;void 0!==e.enable&&(this.enable=e.enable);let t=e.width;void 0!==t&&(this.width=t);let i=e.height;void 0!==i&&(this.height=i)}}},3996(e,t,i){i.d(t,{Q:()=>l,p:()=>r});var a=i(9355),n=i(2010),s=i(9739),o=i(1913);class r{count;decay;delay;enable;speed;sync;constructor(){this.count=0,this.enable=!1,this.speed=1,this.decay=0,this.delay=0,this.sync=!1}load(e){(0,s.kZ)(e)||(void 0!==e.count&&(this.count=(0,o.DT)(e.count)),void 0!==e.enable&&(this.enable=e.enable),void 0!==e.speed&&(this.speed=(0,o.DT)(e.speed)),void 0!==e.decay&&(this.decay=(0,o.DT)(e.decay)),void 0!==e.delay&&(this.delay=(0,o.DT)(e.delay)),void 0!==e.sync&&(this.sync=e.sync))}}class l extends r{mode;startValue;constructor(){super(),this.mode=a.g.auto,this.startValue=n.S.random}load(e){super.load(e),(0,s.kZ)(e)||(void 0!==e.mode&&(this.mode=e.mode),void 0!==e.startValue&&(this.startValue=e.startValue))}}},4508(e,t,i){i.d(t,{t:()=>o});var a=i(2685),n=i(9739),s=i(1913);class o{color;opacity;width;constructor(){this.width=0}load(e){(0,n.kZ)(e)||(void 0!==e.color&&(this.color=a.A.create(this.color,e.color)),void 0!==e.width&&(this.width=(0,s.DT)(e.width)),void 0!==e.opacity&&(this.opacity=(0,s.DT)(e.opacity)))}}},4575(e,t,i){i.d(t,{q:()=>o});var a=i(6761),n=i(3996),s=i(9739);class o extends n.Q{destroy;constructor(){super(),this.destroy=a.V.none,this.speed=5}load(e){super.load(e),(0,s.kZ)(e)||void 0!==e.destroy&&(this.destroy=e.destroy)}}},4615(e,t,i){i.d(t,{I:()=>o});var a=i(6761),n=i(3996),s=i(9739);class o extends n.Q{destroy;constructor(){super(),this.destroy=a.V.none,this.speed=2}load(e){super.load(e),(0,s.kZ)(e)||void 0!==e.destroy&&(this.destroy=e.destroy)}}},4860(e,t,i){i.d(t,{AI:()=>l,Jm:()=>r,PV:()=>o});var a=i(3996),n=i(9739),s=i(1913);class o{value;constructor(){this.value=0}load(e){!(0,n.kZ)(e)&&((0,n.kZ)(e.value)||(this.value=(0,s.DT)(e.value)))}}class r extends o{animation=new a.p;load(e){if(super.load(e),(0,n.kZ)(e))return;let t=e.animation;void 0!==t&&this.animation.load(t)}}class l extends r{animation;constructor(){super(),this.animation=new a.Q}load(e){super.load(e)}}},4939(e,t,i){i.d(t,{F:()=>n});var a=i(4860);class n extends a.PV{constructor(){super(),this.value=1}}},4975(e,t,i){i.d(t,{P:()=>s});var a=i(4860),n=i(9739);class s extends a.PV{opacityRate;sizeRate;velocityRate;constructor(){super(),this.opacityRate=1,this.sizeRate=1,this.velocityRate=1}load(e){super.load(e),(0,n.kZ)(e)||(void 0!==e.opacityRate&&(this.opacityRate=e.opacityRate),void 0!==e.sizeRate&&(this.sizeRate=e.sizeRate),void 0!==e.velocityRate&&(this.velocityRate=e.velocityRate))}}},5045(e,t,i){var a,n;i.d(t,{Y:()=>a}),(n=a||(a={})).bounce="bounce",n.none="none",n.out="out",n.destroy="destroy",n.split="split"},5107(e,t,i){let a;i.d(t,{AE:()=>O,BR:()=>y,E9:()=>I,HQ:()=>$,Kp:()=>C,O2:()=>S,Ot:()=>Z,T5:()=>g,TA:()=>T,Tg:()=>R,Tj:()=>z,UC:()=>D,Vh:()=>M,Xs:()=>_,YC:()=>A,hJ:()=>V,hn:()=>x,lV:()=>m,n0:()=>w,pE:()=>P,q8:()=>v,tG:()=>b,td:()=>L,w3:()=>F,wJ:()=>k,zw:()=>function e(t,...i){for(let a of i)if(null!=a){if(!(0,r.Gv)(a)){t=a;continue}for(let i in Array.isArray(a)?Array.isArray(t)||(t=[]):(!(0,r.Gv)(t)||Array.isArray(t))&&(t={}),a){if("__proto__"===i)continue;let n=a[i],s=t;s[i]=(0,r.Gv)(n)&&Array.isArray(n)?n.map(t=>e(s[i],t)):e(s[i],n)}}return t}});var n,s=i(1913),o=i(7313),r=i(9739),l=i(9355),d=i(7205),c=i(6761),u=i(7230),h=i(7073),p=i(2010),f=i(2740);function v(){return"u">typeof matchMedia}function g(){return globalThis.document}function m(e){if(v())return matchMedia(e)}function y(e){if("u">typeof IntersectionObserver)return new IntersectionObserver(e)}function b(e){if("u">typeof MutationObserver)return new MutationObserver(e)}function x(e,t){return e===t||(0,r.cy)(t)&&t.includes(e)}function w(e){return Math.floor((0,s.G0)()*e.length)}function M(e,t,i=!0){return e[void 0!==t&&i?t%e.length:w(e)]}function z(e,t,i,a,n){return S(O(e,a??0),t,i,n)}function S(e,t,i,a){let n=!0;return a&&a!==u.v.bottom||(n=e.top<t.height+i.x),n&&(!a||a===u.v.left)&&(n=e.right>i.x),n&&(!a||a===u.v.right)&&(n=e.left<t.width+i.y),n&&(!a||a===u.v.top)&&(n=e.bottom>i.y),n}function O(e,t){return{bottom:e.y+t,left:e.x-t,right:e.x+t,top:e.y-t}}function R(e){return{position:e.getPosition(),radius:e.getRadius(),mass:e.getMass(),velocity:e.velocity,factor:f.M.create((0,s.VG)(e.options.bounce.horizontal.value),(0,s.VG)(e.options.bounce.vertical.value))}}function P(e,t){let{x:i,y:a}=e.velocity.sub(t.velocity),[n,o]=[e.position,t.position],{dx:r,dy:l}=(0,s.vr)(o,n);if(i*r+a*l<0)return;let d=-Math.atan2(l,r),c=e.mass,u=t.mass,h=e.velocity.rotate(d),p=t.velocity.rotate(d),f=(0,s.OW)(h,p,c,u),v=(0,s.OW)(p,h,c,u),g=f.rotate(-d),m=v.rotate(-d);e.velocity.x=g.x*e.factor.x,e.velocity.y=g.y*e.factor.y,t.velocity.x=m.x*t.factor.x,t.velocity.y=m.y*t.factor.y}function k(e,t){return(0,r.cy)(e)?e.map((e,i)=>t(e,i)):t(e,0)}function T(e,t,i){return(0,r.cy)(e)?M(e,t,i):e}function F(e,t){return(0,r.cy)(e)?e.find((e,i)=>t(e,i)):t(e,0)?e:void 0}function _(e,t){let i=e.value,a=e.animation,n={delayTime:(0,s.VG)(a.delay)*o.Xu,enable:a.enable,value:(0,s.VG)(e.value)*t,max:(0,s.W9)(i)*t,min:(0,s.Sg)(i)*t,loops:0,maxLoops:(0,s.VG)(a.count),time:0};if(a.enable){switch(n.decay=1-(0,s.VG)(a.decay),a.mode){case l.g.increase:n.status=d.H.increasing;break;case l.g.decrease:n.status=d.H.decreasing;break;case l.g.random:n.status=(0,s.G0)()>=o.MX?d.H.increasing:d.H.decreasing}let e=a.mode===l.g.auto;switch(a.startValue){case p.S.min:n.value=n.min,e&&(n.status=d.H.increasing);break;case p.S.max:n.value=n.max,e&&(n.status=d.H.decreasing);break;case p.S.random:default:n.value=(0,s.vE)(n),e&&(n.status=(0,s.G0)()>=o.MX?d.H.increasing:d.H.decreasing)}}return n.initialValue=n.value,n}function E(e,t){if(e.mode!==h.q.percent){let{mode:t,...i}=e;return i}return"x"in e?{x:e.x/o.a5*t.width,y:e.y/o.a5*t.height}:{width:e.width/o.a5*t.width,height:e.height/o.a5*t.height}}function I(e,t){return E(e,t)}function A(e,t){return E(e,t)}function D(e,t,i,a,n){if(e.destroyed||!t.enable||(t.maxLoops??0)>0&&(t.loops??0)>(t.maxLoops??0))return;let o=(t.velocity??0)*n.factor,r=t.min,l=t.max,u=t.decay??1;if(t.time??=0,(t.delayTime??0)>0&&t.time<(t.delayTime??0)&&(t.time+=n.value),!((t.delayTime??0)>0)||!(t.time<(t.delayTime??0))){switch(t.status){case d.H.increasing:t.value>=l?(i?t.status=d.H.decreasing:t.value-=l,t.loops??=0,t.loops++):t.value+=o;break;case d.H.decreasing:t.value<=r?(i?t.status=d.H.increasing:t.value+=l,t.loops??=0,t.loops++):t.value-=o}t.velocity&&1!==u&&(t.velocity*=u);var h=t.value;switch(a){case c.V.max:h>=l&&e.destroy();break;case c.V.min:h<=r&&e.destroy()}t.value=(0,s.qE)(t.value,r,l)}}function L(e){let t=g().createElement("div").style;for(let i in e){let a=e[i];if(!Object.hasOwn(e,i)||(0,r.kZ)(a))continue;let n=e.getPropertyValue?.(a);if(!n)continue;let s=e.getPropertyPriority?.(a);s?t.setProperty(a,n,s):t.setProperty(a,n)}return t}let V=(n=function(e){let t=g().createElement("div").style,i={width:"100%",height:"100%",margin:"0",padding:"0",borderWidth:"0",position:"fixed",zIndex:e.toString(10),"z-index":e.toString(10),top:"0",left:"0"};for(let e in i){let a=i[e];void 0!==a&&t.setProperty(e,a)}return t},a=new Map,(...e)=>{let t=JSON.stringify(e);if(a.has(t))return a.get(t);let i=n(...e);return a.set(t,i),i});function C(e,t,i,a,n){if(a){let a={passive:!0};(0,r.Lm)(n)?a.capture=n:void 0!==n&&(a=n),e.addEventListener(t,i,a)}else e.removeEventListener(t,i,n)}async function $(e,t,i,a=!1){let n=t.get(e);return(!n||a)&&(n=await Promise.all([...i.values()].map(t=>t(e))),t.set(e,n)),n}async function Z(e,t,i,a=!1){let n=t.get(e);if(!n||a){for(let[t,a]of(n=new Map,await Promise.all([...i.entries()].map(async([t,i])=>[t,await i(e)]))))n.set(t,a);t.set(e,n)}return n}},5127(e,t,i){i.d(t,{e:()=>o});var a=i(3996),n=i(9739),s=i(1913);class o extends a.p{offset;constructor(){super(),this.offset=0,this.sync=!0}load(e){super.load(e),(0,n.kZ)(e)||void 0!==e.offset&&(this.offset=(0,s.DT)(e.offset))}}},5373(e,t,i){i.d(t,{y:()=>p});var a=i(546),n=i(9739),s=i(9114),o=i(6156),r=i(2268),l=i(1695),d=i(884),c=i(816),u=i(1412),h=i(1913);class p{angle;attract;center;decay;direction;distance;drift;enable;gravity;outModes;path;random;size;speed;spin;straight;vibrate;warp;constructor(){this.angle=new s.h,this.attract=new o.R,this.center=new r.Z,this.decay=0,this.distance={},this.direction=a.F.none,this.drift=0,this.enable=!1,this.gravity=new l.y,this.path=new d.v,this.outModes=new c.j,this.random=!1,this.size=!1,this.speed=2,this.spin=new u.t,this.straight=!1,this.vibrate=!1,this.warp=!1}load(e){if((0,n.kZ)(e))return;this.angle.load((0,n.Et)(e.angle)?{value:e.angle}:e.angle),this.attract.load(e.attract),this.center.load(e.center),void 0!==e.decay&&(this.decay=(0,h.DT)(e.decay)),void 0!==e.direction&&(this.direction=e.direction),void 0!==e.distance&&(this.distance=(0,n.Et)(e.distance)?{horizontal:e.distance,vertical:e.distance}:{...e.distance}),void 0!==e.drift&&(this.drift=(0,h.DT)(e.drift)),void 0!==e.enable&&(this.enable=e.enable),this.gravity.load(e.gravity);let t=e.outModes;void 0!==t&&((0,n.Gv)(t)?this.outModes.load(t):this.outModes.load({default:t})),this.path.load(e.path),void 0!==e.random&&(this.random=e.random),void 0!==e.size&&(this.size=e.size),void 0!==e.speed&&(this.speed=(0,h.DT)(e.speed)),this.spin.load(e.spin),void 0!==e.straight&&(this.straight=e.straight),void 0!==e.vibrate&&(this.vibrate=e.vibrate),void 0!==e.warp&&(this.warp=e.warp)}}},5398(e,t,i){var a,n;i.d(t,{d:()=>a}),(n=a||(a={})).delete="delete",n.wait="wait"},5563(e,t,i){var a,n;i.d(t,{H:()=>a}),(n=a||(a={})).darken="darken",n.enlighten="enlighten"},5633(e,t,i){i.d(t,{O:()=>n});var a=i(9739);class n{value;constructor(){this.value=""}static create(e,t){let i=new n;return i.load(e),void 0!==t&&((0,a.Kg)(t)||(0,a.cy)(t)?i.load({value:t}):i.load(t)),i}load(e){!(0,a.kZ)(e)&&((0,a.kZ)(e.value)||(this.value=e.value))}}},5668(e,t,i){i.d(t,{dg:()=>r,jl:()=>l,M_:()=>d}),(a=n||(n={})).circle="circle",a.rectangle="rectangle";var a,n,s=i(1913),o=i(7313);class r{position;type;constructor(e,t,i){this.position={x:e,y:t},this.type=i}}class l extends r{radius;constructor(e,t,i){super(e,t,n.circle),this.radius=i}contains(e){return(0,s.Yf)(e,this.position)<=this.radius}intersects(e){let t=this.position,i=e.position,a={x:Math.abs(i.x-t.x),y:Math.abs(i.y-t.y)},s=this.radius;if(e instanceof l||e.type===n.circle)return s+e.radius>Math.sqrt(a.x**o.dm+a.y**o.dm);if(e instanceof d||e.type===n.rectangle){let{width:t,height:i}=e.size;return Math.pow(a.x-t,o.dm)+Math.pow(a.y-i,o.dm)<=s**o.dm||a.x<=s+t&&a.y<=s+i||a.x<=t||a.y<=i}return!1}}class d extends r{size;constructor(e,t,i,a){super(e,t,n.rectangle),this.size={height:a,width:i}}contains(e){let t=this.size.width,i=this.size.height,a=this.position;return e.x>=a.x&&e.x<=a.x+t&&e.y>=a.y&&e.y<=a.y+i}intersects(e){if(e instanceof l)return e.intersects(this);let t=this.size.width,i=this.size.height,a=this.position,n=e.position,s=e instanceof d?e.size:{width:0,height:0},o=s.width,r=s.height;return n.x<a.x+t&&n.x+o>a.x&&n.y<a.y+i&&n.y+r>a.y}}},5953(e,t,i){i.d(t,{U:()=>v});var a=i(5107),n=i(2685),s=i(9739);class o{close;fill;options;type;constructor(){this.close=!0,this.fill=!0,this.options={},this.type=[]}load(e){if((0,s.kZ)(e))return;let t=e.options;if(void 0!==t)for(let e in t){let i=t[e];i&&(this.options[e]=(0,a.zw)(this.options[e]??{},i))}void 0!==e.close&&(this.close=e.close),void 0!==e.fill&&(this.fill=e.fill),void 0!==e.type&&(this.type=e.type)}}var r=i(5373),l=i(1789),d=i(6408),c=i(6556),u=i(2057),h=i(8997),p=i(4508),f=i(4975);class v{bounce;color;effect;groups;move;number;opacity;reduceDuplicates;shape;size;stroke;zIndex;_container;_engine;constructor(e,t){this._engine=e,this._container=t,this.bounce=new d.w,this.color=new n.A,this.color.value="#fff",this.effect=new o,this.groups={},this.move=new r.y,this.number=new c.N,this.opacity=new l.Y,this.reduceDuplicates=!1,this.shape=new u.y,this.size=new h.o,this.stroke=new p.t,this.zIndex=new f.P}load(e){if((0,s.kZ)(e))return;if(void 0!==e.groups)for(let t of Object.keys(e.groups)){if(!Object.hasOwn(e.groups,t))continue;let i=e.groups[t];void 0!==i&&(this.groups[t]=(0,a.zw)(this.groups[t]??{},i))}void 0!==e.reduceDuplicates&&(this.reduceDuplicates=e.reduceDuplicates),this.bounce.load(e.bounce),this.color.load(n.A.create(this.color,e.color)),this.effect.load(e.effect),this.move.load(e.move),this.number.load(e.number),this.opacity.load(e.opacity),this.shape.load(e.shape),this.size.load(e.size),this.zIndex.load(e.zIndex);let t=e.stroke;if(t&&(this.stroke=(0,a.wJ)(t,e=>{let t=new p.t;return t.load(e),t})),this._container){for(let t of this._engine.plugins)t.loadParticlesOptions&&t.loadParticlesOptions(this._container,this,e);let t=this._engine.updaters.get(this._container);if(t)for(let i of t)i.loadOptions&&i.loadOptions(this,e)}}}},6156(e,t,i){i.d(t,{R:()=>s});var a=i(9739),n=i(1913);class s{distance;enable;rotate;constructor(){this.distance=200,this.enable=!1,this.rotate={x:3e3,y:3e3}}load(e){if(!(0,a.kZ)(e)&&(void 0!==e.distance&&(this.distance=(0,n.DT)(e.distance)),void 0!==e.enable&&(this.enable=e.enable),e.rotate)){let t=e.rotate.x;void 0!==t&&(this.rotate.x=t);let i=e.rotate.y;void 0!==i&&(this.rotate.y=i)}}}},6408(e,t,i){i.d(t,{w:()=>s});var a=i(4939),n=i(9739);class s{horizontal;vertical;constructor(){this.horizontal=new a.F,this.vertical=new a.F}load(e){(0,n.kZ)(e)||(this.horizontal.load(e.horizontal),this.vertical.load(e.vertical))}}},6556(e,t,i){i.d(t,{N:()=>o});var a=i(3801),n=i(9197),s=i(9739);class o{density;limit;value;constructor(){this.density=new a.M,this.limit=new n.A,this.value=0}load(e){(0,s.kZ)(e)||(this.density.load(e.density),this.limit.load(e.limit),void 0!==e.value&&(this.value=e.value))}}},6761(e,t,i){var a,n;i.d(t,{V:()=>a}),(n=a||(a={})).none="none",n.max="max",n.min="min"},6996(e,t,i){i.d(t,{J:()=>c});var a=i(5107),n=i(9739),s=i(1139),o=i(8705),r=i(9946),l=i(2679),d=i(1913);class c{autoPlay;background;clear;defaultThemes;delay;detectRetina;duration;fpsLimit;fullScreen;hdr;key;name;particles;pauseOnBlur;pauseOnOutsideViewport;preset;resize;smooth;style;zLayers;_container;_engine;constructor(e,t){this._engine=e,this._container=t,this.autoPlay=!0,this.background=new s.V,this.clear=!0,this.defaultThemes={},this.delay=0,this.fullScreen=new o.m,this.detectRetina=!0,this.duration=0,this.fpsLimit=120,this.hdr=!0,this.particles=(0,l.y)(this._engine,this._container),this.pauseOnBlur=!0,this.pauseOnOutsideViewport=!0,this.resize=new r.z,this.smooth=!1,this.style={},this.zLayers=100}load(e){if((0,n.kZ)(e))return;void 0!==e.preset&&(0,a.wJ)(e.preset,e=>{this._importPreset(e)}),void 0!==e.autoPlay&&(this.autoPlay=e.autoPlay),void 0!==e.clear&&(this.clear=e.clear),void 0!==e.key&&(this.key=e.key),void 0!==e.name&&(this.name=e.name),void 0!==e.delay&&(this.delay=(0,d.DT)(e.delay));let t=e.detectRetina;void 0!==t&&(this.detectRetina=t),void 0!==e.duration&&(this.duration=(0,d.DT)(e.duration));let i=e.fpsLimit;void 0!==i&&(this.fpsLimit=i),void 0!==e.hdr&&(this.hdr=e.hdr),void 0!==e.pauseOnBlur&&(this.pauseOnBlur=e.pauseOnBlur),void 0!==e.pauseOnOutsideViewport&&(this.pauseOnOutsideViewport=e.pauseOnOutsideViewport),void 0!==e.zLayers&&(this.zLayers=e.zLayers),this.background.load(e.background);let s=e.fullScreen;(0,n.Lm)(s)?this.fullScreen.enable=s:this.fullScreen.load(s),this.particles.load(e.particles),this.resize.load(e.resize),this.style=(0,a.zw)(this.style,e.style),void 0!==e.smooth&&(this.smooth=e.smooth),this._engine.plugins.forEach(t=>{t.loadOptions(this._container,this,e)})}_importPreset=e=>{this.load(this._engine.getPreset(e))}}},7073(e,t,i){var a,n;i.d(t,{q:()=>a}),(n=a||(a={})).precise="precise",n.percent="percent"},7205(e,t,i){var a,n;i.d(t,{H:()=>a}),(n=a||(a={})).increasing="increasing",n.decreasing="decreasing"},7230(e,t,i){var a,n;i.d(t,{v:()=>a}),(n=a||(a={})).bottom="bottom",n.left="left",n.right="right",n.top="top"},7313(e,t,i){i.d(t,{$G:()=>L,$O:()=>B,$_:()=>_,$v:()=>J,$x:()=>S,BF:()=>eR,BW:()=>h,DN:()=>Q,D_:()=>eb,Dv:()=>ex,Eo:()=>ea,FS:()=>H,Fl:()=>eP,GW:()=>C,Ie:()=>D,JC:()=>K,K3:()=>ep,KZ:()=>N,Kw:()=>M,L1:()=>E,LD:()=>ev,M1:()=>eo,MX:()=>r,N5:()=>en,NF:()=>n,Nu:()=>ez,Nx:()=>U,PZ:()=>Y,Pg:()=>R,R1:()=>f,RF:()=>b,RV:()=>G,Rh:()=>el,Rq:()=>V,TL:()=>j,U0:()=>A,Ug:()=>c,WH:()=>ei,X$:()=>y,X_:()=>es,Xu:()=>l,Zp:()=>O,a5:()=>o,aE:()=>eO,aZ:()=>g,bo:()=>d,ce:()=>m,dm:()=>w,dv:()=>et,eb:()=>a,eu:()=>F,gd:()=>p,hB:()=>P,hK:()=>eT,hv:()=>q,i8:()=>X,iU:()=>ew,jn:()=>ek,lA:()=>ef,mR:()=>u,nK:()=>s,nq:()=>ec,oi:()=>k,ou:()=>ed,pH:()=>eg,rq:()=>x,tA:()=>ey,tR:()=>eF,td:()=>em,un:()=>er,vF:()=>W,vS:()=>T,vd:()=>eM,w2:()=>Z,wM:()=>eu,xH:()=>ee,xd:()=>z,yx:()=>I,z$:()=>v,z9:()=>eh,zg:()=>eS,zs:()=>$});let a="generated",n="resize",s="visibilitychange",o=100,r=.5,l=1e3,d={x:0,y:0,z:0},c={a:1,b:0,c:0,d:1},u="random",h="mid",p=2,f=2*Math.PI,v=60,g=1,m="true",y="false",b="canvas",x=0,w=2,M=4,z=1,S=1,O=1,R=4,P=1,k=255,T=360,F=100,_=100,E=0,I=0,A=60,D=0,L=.25,V=.75,C=0,$=1,Z=0,B=0,G=1,q=1,H=1,N=1,j=0,K=1,W=0,X=120,Q=0,U=0,J=1e4,Y=0,ee=1,et=0,ei=1,ea=1,en=0,es=0,eo=0,er=-.25,el=1.5,ed=0,ec=1,eu=0,eh=0,ep=1,ef=1,ev=1,eg=500,em=50,ey=0,eb=1,ex=0,ew=1,eM=0,ez=3,eS=6,eO=1,eR=1,eP=0,ek=0,eT=0,eF=0},7927(e,t,i){i.d(t,{IU:()=>r,KG:()=>u,Md:()=>o,Sn:()=>s,VG:()=>p,Wb:()=>f,gF:()=>h,k:()=>d,p0:()=>l,yx:()=>v,z5:()=>c});var a=i(7313),n=i(5563);function s(e,t,i){e.fillStyle=i??"rgba(0,0,0,0)",e.fillRect(a.bo.x,a.bo.y,t.width,t.height)}function o(e,t,i,n){i&&(e.globalAlpha=n,e.drawImage(i,a.bo.x,a.bo.y,t.width,t.height),e.globalAlpha=1)}function r(e,t){e.clearRect(a.bo.x,a.bo.y,t.width,t.height)}function l(e){let{container:t,context:i,particle:n,delta:s,colorStyles:o,radius:r,opacity:l,transform:f}=e,v=n.getPosition(),g=n.getTransformData(f);i.setTransform(g.a,g.b,g.c,g.d,v.x,v.y),o.fill&&(i.fillStyle=o.fill);let m=n.strokeWidth??a.Dv;i.lineWidth=m,o.stroke&&(i.strokeStyle=o.stroke);let y={context:i,particle:n,radius:r,opacity:l,delta:s,pixelRatio:t.retina.pixelRatio,fill:n.shapeFill,stroke:m>a.Dv||!n.shapeFill,transformData:g};c(t,y),p(t,y),u(t,y),h(t,y),d(t,y),i.resetTransform()}function d(e,t){let{particle:i}=t;if(!i.effect)return;let a=e.particles.effectDrawers.get(i.effect),n=a?.drawAfter;n&&n(t)}function c(e,t){let{particle:i}=t;if(!i.effect)return;let a=e.particles.effectDrawers.get(i.effect);a?.drawBefore&&a.drawBefore(t)}function u(e,t){let{context:i,particle:a,stroke:n}=t;if(!a.shape)return;let s=e.particles.shapeDrawers.get(a.shape);s&&(i.beginPath(),s.draw(t),a.shapeClose&&i.closePath(),n&&i.stroke(),a.shapeFill&&i.fill())}function h(e,t){let{particle:i}=t;if(!i.shape)return;let a=e.particles.shapeDrawers.get(i.shape);a?.afterDraw&&a.afterDraw(t)}function p(e,t){let{particle:i}=t;if(!i.shape)return;let a=e.particles.shapeDrawers.get(i.shape);a?.beforeDraw&&a.beforeDraw(t)}function f(e,t,i,a){t.drawParticle&&t.drawParticle(e,i,a)}function v(e,t,i){return{h:e.h,s:e.s,l:e.l+(t===n.H.darken?-a.iU:a.iU)*i}}},8150(e,t,i){i.d(t,{b:()=>a});class a{particle;position;constructor(e,t){this.position=e,this.particle=t}}},8405(e,t,i){var a,n;i.d(t,{x:()=>a}),(n=a||(a={})).normal="normal",n.inside="inside",n.outside="outside"},8705(e,t,i){i.d(t,{m:()=>n});var a=i(9739);class n{enable;zIndex;constructor(){this.enable=!0,this.zIndex=0}load(e){(0,a.kZ)(e)||(void 0!==e.enable&&(this.enable=e.enable),void 0!==e.zIndex&&(this.zIndex=e.zIndex))}}},8963(e,t,i){i.d(t,{B:()=>n,t:()=>s});let a={debug:console.debug,error:(e,t)=>{console.error(`tsParticles - Error - ${e}`,t)},info:console.info,log:console.log,verbose:console.log,warning:console.warn};function n(e){a.debug=e.debug,a.error=e.error,a.info=e.info,a.log=e.log,a.verbose=e.verbose,a.warning=e.warning}function s(){return a}},8997(e,t,i){i.d(t,{o:()=>o});var a=i(4860),n=i(4575),s=i(9739);class o extends a.AI{animation;constructor(){super(),this.animation=new n.q,this.value=3}load(e){if(super.load(e),(0,s.kZ)(e))return;let t=e.animation;void 0!==t&&this.animation.load(t)}}},9114(e,t,i){i.d(t,{h:()=>s});var a=i(9739),n=i(1913);class s{offset;value;constructor(){this.offset=0,this.value=90}load(e){(0,a.kZ)(e)||(void 0!==e.offset&&(this.offset=(0,n.DT)(e.offset)),void 0!==e.value&&(this.value=(0,n.DT)(e.value)))}}},9197(e,t,i){i.d(t,{A:()=>s});var a=i(5398),n=i(9739);class s{mode;value;constructor(){this.mode=a.d.delete,this.value=0}load(e){(0,n.kZ)(e)||(void 0!==e.mode&&(this.mode=e.mode),void 0!==e.value&&(this.value=e.value))}}},9355(e,t,i){var a,n;i.d(t,{g:()=>a}),(n=a||(a={})).auto="auto",n.increase="increase",n.decrease="decrease",n.random="random"},9739(e,t,i){function a(e){return"boolean"==typeof e}function n(e){return"string"==typeof e}function s(e){return"number"==typeof e}function o(e){return"function"==typeof e}function r(e){return"object"==typeof e&&null!==e}function l(e){return Array.isArray(e)}function d(e){return null==e}i.d(t,{Et:()=>s,Gv:()=>r,Kg:()=>n,Lm:()=>a,Tn:()=>o,cy:()=>l,kZ:()=>d})},9946(e,t,i){i.d(t,{z:()=>n});var a=i(9739);class n{delay;enable;constructor(){this.delay=.5,this.enable=!0}load(e){(0,a.kZ)(e)||(void 0!==e.delay&&(this.delay=e.delay),void 0!==e.enable&&(this.enable=e.enable))}}}},c={};function u(e){var t=c[e];if(void 0!==t)return t.exports;var i=c[e]={exports:{}};return d[e](i,i.exports,u),i.exports}u.m=d,u.d=(e,t)=>{for(var i in t)u.o(t,i)&&!u.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},u.f={},u.e=e=>Promise.all(Object.keys(u.f).reduce((t,i)=>(u.f[i](e,t),t),[])),u.u=e=>""+e+".min.js",u.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||Function("return this")()}catch(e){if("object"==typeof window)return window}}(),u.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),h={},u.l=(e,t,i,a)=>{if(h[e])return void h[e].push(t);if(void 0!==i)for(var n,s,o=document.getElementsByTagName("script"),r=0;r<o.length;r++){var l=o[r];if(l.getAttribute("src")==e||l.getAttribute("data-webpack")=="@tsparticles/engine:"+i){n=l;break}}n||(s=!0,(n=document.createElement("script")).charset="utf-8",u.nc&&n.setAttribute("nonce",u.nc),n.setAttribute("data-webpack","@tsparticles/engine:"+i),n.src=e),h[e]=[t];var d=(t,i)=>{n.onerror=n.onload=null,clearTimeout(c);var a=h[e];if(delete h[e],n.parentNode&&n.parentNode.removeChild(n),a&&a.forEach(e=>e(i)),t)return t(i)},c=setTimeout(d.bind(null,void 0,{type:"timeout",target:n}),12e4);n.onerror=d.bind(null,n.onerror),n.onload=d.bind(null,n.onload),s&&document.head.appendChild(n)},u.r=e=>{"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},u.g.importScripts&&(p=u.g.location+"");var h,p,f=u.g.document;if(!p&&f&&(f.currentScript&&"SCRIPT"===f.currentScript.tagName.toUpperCase()&&(p=f.currentScript.src),!p)){var v=f.getElementsByTagName("script");if(v.length)for(var g=v.length-1;g>-1&&(!p||!/^http(s?):/.test(p));)p=v[g--].src}if(!p)throw Error("Automatic publicPath is not supported in this browser");u.p=p=p.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),e={397:0},u.f.j=(t,i)=>{var a=u.o(e,t)?e[t]:void 0;if(0!==a)if(a)i.push(a[2]);else{var n=new Promise((i,n)=>a=e[t]=[i,n]);i.push(a[2]=n);var s=u.p+u.u(t),o=Error();u.l(s,i=>{if(u.o(e,t)&&(0!==(a=e[t])&&(e[t]=void 0),a)){var n=i&&("load"===i.type?"missing":i.type),s=i&&i.target&&i.target.src;o.message="Loading chunk "+t+` failed.
2
- (`+n+": "+s+")",o.name="ChunkLoadError",o.type=n,o.request=s,a[1](o)}},"chunk-"+t,t)}},t=(t,i)=>{var a,n,[s,o,r]=i,l=0;if(s.some(t=>0!==e[t])){for(a in o)u.o(o,a)&&(u.m[a]=o[a]);r&&r(u)}for(t&&t(i);l<s.length;l++)n=s[l],u.o(e,n)&&e[n]&&e[n][0](),e[n]=0},(i=this.webpackChunk_tsparticles_engine=this.webpackChunk_tsparticles_engine||[]).forEach(t.bind(null,0)),i.push=t.bind(null,i.push.bind(i));var m={};u.r(m),u.d(m,{AlterType:()=>L.H,AnimatableColor:()=>B.A,AnimationMode:()=>E.g,AnimationOptions:()=>G.p,AnimationStatus:()=>Z.H,AnimationValueWithRandom:()=>em.Jm,Background:()=>q.V,BaseRange:()=>k.dg,Circle:()=>k.jl,ColorAnimation:()=>H.e,DestroyType:()=>V.V,EasingType:()=>l,EventType:()=>w.B,FullScreen:()=>N.m,GradientType:()=>r,HslAnimation:()=>j.i,LimitMode:()=>I.d,Move:()=>ee.y,MoveAngle:()=>et.h,MoveAttract:()=>Y.R,MoveCenter:()=>ei.Z,MoveDirection:()=>F.F,MoveGravity:()=>ea.y,MovePath:()=>es.v,Opacity:()=>ec.Y,OpacityAnimation:()=>eu.I,Options:()=>K.J,OptionsColor:()=>W.O,OutMode:()=>A.Y,OutModeDirection:()=>_.v,OutModes:()=>en.j,ParticleOutType:()=>C.x,ParticlesBounce:()=>X.w,ParticlesBounceFactor:()=>Q.F,ParticlesDensity:()=>ed.M,ParticlesNumber:()=>er.N,ParticlesNumberLimit:()=>el.A,ParticlesOptions:()=>U.U,PixelMode:()=>D.q,Point:()=>P.b,RangedAnimationOptions:()=>G.Q,RangedAnimationValueWithRandom:()=>em.AI,Rectangle:()=>k.M_,ResizeEvent:()=>eg.z,RotateDirection:()=>o,Shape:()=>eh.y,Size:()=>ep.o,SizeAnimation:()=>ef.q,Spin:()=>eo.t,StartValueType:()=>$.S,Stroke:()=>J.t,ValueWithRandom:()=>em.PV,Vector:()=>T.M,Vector3d:()=>T.p,ZIndex:()=>ev.P,alterHsl:()=>ey.yx,animate:()=>z.i0,areBoundsInside:()=>b.O2,arrayRandomIndex:()=>b.n0,calcExactPositionOrRandomFromSize:()=>z.Nx,calcExactPositionOrRandomFromSizeRanged:()=>z.qM,calcPositionFromSize:()=>z.eh,calcPositionOrRandomFromSize:()=>z.Mh,calcPositionOrRandomFromSizeRanged:()=>z.l1,calculateBounds:()=>b.AE,cancelAnimation:()=>z.px,canvasFirstIndex:()=>y.Nx,canvasTag:()=>y.RF,circleBounce:()=>b.pE,circleBounceDataFromParticle:()=>b.Tg,clamp:()=>z.qE,clear:()=>ey.IU,clickRadius:()=>y.FS,cloneStyle:()=>b.td,collisionVelocity:()=>z.OW,colorMix:()=>eb.EY,colorToHsl:()=>eb.mK,colorToRgb:()=>eb.qe,countOffset:()=>y.nq,decayOffset:()=>y.WH,deepExtend:()=>b.zw,defaultAlpha:()=>y.aZ,defaultAngle:()=>y.tA,defaultDensityFactor:()=>y.lA,defaultFps:()=>y.z$,defaultFpsLimit:()=>y.i8,defaultLoops:()=>y.hK,defaultOpacity:()=>y.hv,defaultRadius:()=>y.M1,defaultRatio:()=>y.$x,defaultReduceFactor:()=>y.Zp,defaultRemoveQuantity:()=>y.xd,defaultRetryCount:()=>y.rq,defaultRgbMin:()=>y.Fl,defaultTime:()=>y.tR,defaultTransform:()=>y.Ug,defaultTransformValue:()=>y.zs,defaultVelocity:()=>y.jn,degToRad:()=>z.pu,deleteCount:()=>y.LD,double:()=>y.gd,doublePI:()=>y.R1,drawAfterEffect:()=>ey.k,drawBeforeEffect:()=>ey.z5,drawParticle:()=>ey.p0,drawParticlePlugin:()=>ey.Wb,drawShape:()=>ey.KG,drawShapeAfterDraw:()=>ey.gF,drawShapeBeforeDraw:()=>ey.VG,empty:()=>y.Ie,executeOnSingleOrMultiple:()=>b.wJ,findItemFromSingleOrMultiple:()=>b.w3,generatedAttribute:()=>y.eb,generatedFalse:()=>y.X$,generatedTrue:()=>y.ce,getDistance:()=>z.Yf,getDistances:()=>z.vr,getFullScreenStyle:()=>b.hJ,getHslAnimationFromHsl:()=>eb.pz,getHslFromAnimation:()=>eb.O_,getItemMapFromInitializer:()=>b.Ot,getItemsFromInitializer:()=>b.HQ,getLinkColor:()=>eb._h,getLinkRandomColor:()=>eb.PG,getLogger:()=>M.t,getParticleBaseVelocity:()=>z.$m,getParticleDirectionAngle:()=>z.JY,getPosition:()=>b.E9,getRandom:()=>z.G0,getRandomInRange:()=>z.e4,getRandomRgbColor:()=>eb.OH,getRangeMax:()=>z.W9,getRangeMin:()=>z.Sg,getRangeValue:()=>z.VG,getSize:()=>b.YC,getStyleFromHsl:()=>eb.LC,getStyleFromRgb:()=>eb.xx,hMax:()=>y.vS,hMin:()=>y.L1,hPhase:()=>y.U0,half:()=>y.MX,hasMatchMedia:()=>b.q8,hslToRgb:()=>eb.YL,hslaToRgba:()=>eb.ay,identity:()=>y.D_,initParticleNumericAnimationValue:()=>b.Xs,inverseFactorNumerator:()=>y.hB,isArray:()=>ew.cy,isBoolean:()=>ew.Lm,isFunction:()=>ew.Tn,isInArray:()=>b.hn,isNull:()=>ew.kZ,isNumber:()=>ew.Et,isObject:()=>ew.Gv,isPointInside:()=>b.Tj,isString:()=>ew.Kg,itemFromArray:()=>b.Vh,itemFromSingleOrMultiple:()=>b.TA,lFactor:()=>y.iU,lMax:()=>y.$_,lMin:()=>y.vd,lengthOffset:()=>y.K3,loadMinIndex:()=>y.PZ,loadOptions:()=>ex.Z,loadParticlesOptions:()=>ex.y,loadRandomFactor:()=>y.$v,manageListener:()=>b.Kp,manualDefaultPosition:()=>y.td,midColorValue:()=>y.BW,millisecondsToSeconds:()=>y.Xu,minCoordinate:()=>y.TL,minCount:()=>y.wM,minFpsLimit:()=>y.DN,minIndex:()=>y.z9,minLimit:()=>y.ou,minRetries:()=>y.N5,minStrokeWidth:()=>y.Dv,minVelocity:()=>y.GW,minZ:()=>y.X_,minimumLength:()=>y.$O,minimumSize:()=>y.w2,mix:()=>z.jh,none:()=>y.dv,one:()=>y.xH,originPoint:()=>y.bo,paintBase:()=>ey.Sn,paintImage:()=>ey.Md,parseAlpha:()=>z.M3,percentDenominator:()=>y.a5,phaseNumerator:()=>y.BF,posOffset:()=>y.un,qTreeCapacity:()=>y.Kw,quarter:()=>y.$G,randomColorValue:()=>y.mR,randomInRangeValue:()=>z.vE,rangeColorToHsl:()=>eb.R5,rangeColorToRgb:()=>eb.BN,removeDeleteCount:()=>y.JC,removeMinIndex:()=>y.vF,resizeEvent:()=>y.NF,rgbMax:()=>y.oi,rgbToHsl:()=>eb.K6,sMax:()=>y.eu,sMin:()=>y.yx,sNormalizedOffset:()=>y.aE,safeDocument:()=>b.T5,safeIntersectionObserver:()=>b.BR,safeMatchMedia:()=>b.lV,safeMutationObserver:()=>b.tG,setAnimationFunctions:()=>z.AD,setLogger:()=>M.B,setRandom:()=>z.OE,setRangeValue:()=>z.DT,sextuple:()=>y.zg,sizeFactor:()=>y.Rh,squareExp:()=>y.dm,stringToAlpha:()=>eb.zI,stringToRgb:()=>eb.eg,subdivideCount:()=>y.Pg,threeQuarter:()=>y.Rq,touchDelay:()=>y.pH,touchEndLengthOffset:()=>y.KZ,triple:()=>y.Nu,tryCountIncrement:()=>y.Eo,tsParticles:()=>eM,updateAnimation:()=>b.UC,updateColor:()=>eb.Jv,updateColorValue:()=>eb.Ko,visibilityChangeEvent:()=>y.nK,zIndexFactorOffset:()=>y.RV});var y=u(7313),b=u(5107);class x{_listeners;constructor(){this._listeners=new Map}addEventListener(e,t){this.removeEventListener(e,t);let i=this._listeners.get(e);i||(i=[],this._listeners.set(e,i)),i.push(t)}dispatchEvent(e,t){let i=this._listeners.get(e);i?.forEach(e=>{e(t)})}hasEventListener(e){return!!this._listeners.get(e)}removeAllEventListeners(e){e?this._listeners.delete(e):this._listeners=new Map}removeEventListener(e,t){let i=this._listeners.get(e);if(!i)return;let a=i.length,n=i.indexOf(t);n<y.z9||(a===y.LD?this._listeners.delete(e):i.splice(n,y.LD))}}var w=u(299),M=u(8963),z=u(1913);let S="100%";async function O(e){let t=(0,b.TA)(e.url,e.index);if(!t)return e.fallback;let i=await fetch(t);return i.ok?await i.json():((0,M.t)().error(`${i.status.toString()} while retrieving config file`),e.fallback)}class R{colorManagers=new Map;easingFunctions=new Map;effectDrawers=new Map;initializers={effects:new Map,movers:new Map,pathGenerators:new Map,shapes:new Map,updaters:new Map};movers=new Map;pathGenerators=new Map;plugins=[];presets=new Map;shapeDrawers=new Map;updaters=new Map;_allLoadersSet=new Set;_configs=new Map;_domArray=[];_eventDispatcher=new x;_executedSet=new Set;_initialized=!1;_isRunningLoaders=!1;_loadPromises=new Set;get configs(){let e={};for(let[t,i]of this._configs)e[t]=i;return e}get items(){return this._domArray}get version(){return"4.0.0-alpha.18"}addColorManager(e,t){this.colorManagers.set(e,t)}addConfig(e){let t=e.key??e.name??"default";this._configs.set(t,e),this._eventDispatcher.dispatchEvent(w.B.configAdded,{data:{name:t,config:e}})}addEasing(e,t){this.easingFunctions.get(e)||this.easingFunctions.set(e,t)}addEffect(e,t){this.initializers.effects.set(e,t)}addEventListener(e,t){this._eventDispatcher.addEventListener(e,t)}addMover(e,t){this.initializers.movers.set(e,t)}addParticleUpdater(e,t){this.initializers.updaters.set(e,t)}addPathGenerator(e,t){this.initializers.pathGenerators.set(e,t)}addPlugin(e){this.getPlugin(e.id)||this.plugins.push(e)}addPreset(e,t,i=!1){(i||!this.getPreset(e))&&this.presets.set(e,t)}addShape(e,t){for(let i of e)this.initializers.shapes.set(i,t)}checkVersion(e){if(this.version!==e)throw Error(`The tsParticles version is different from the loaded plugins version. Engine version: ${this.version}. Plugin version: ${e}`)}clearPlugins(e){this.effectDrawers.delete(e),this.movers.delete(e),this.shapeDrawers.delete(e),this.updaters.delete(e)}dispatchEvent(e,t){this._eventDispatcher.dispatchEvent(e,t)}getEasing(e){return this.easingFunctions.get(e)??(e=>e)}getEffectDrawers(e,t=!1){return(0,b.Ot)(e,this.effectDrawers,this.initializers.effects,t)}getMovers(e,t=!1){return(0,b.HQ)(e,this.movers,this.initializers.movers,t)}getPathGenerators(e,t=!1){return(0,b.Ot)(e,this.pathGenerators,this.initializers.pathGenerators,t)}getPlugin(e){return this.plugins.find(t=>t.id===e)}getPreset(e){return this.presets.get(e)}async getShapeDrawers(e,t=!1){return(0,b.Ot)(e,this.shapeDrawers,this.initializers.shapes,t)}async getUpdaters(e,t=!1){return(0,b.HQ)(e,this.updaters,this.initializers.updaters,t)}async init(){if(!this._initialized&&!this._isRunningLoaders){this._isRunningLoaders=!0,this._executedSet=new Set,this._allLoadersSet=new Set(this._loadPromises);try{for(let e of this._allLoadersSet)await this._runLoader(e,this._executedSet,this._allLoadersSet)}finally{this._loadPromises.clear(),this._isRunningLoaders=!1,this._initialized=!0}}}item(e){let{items:t}=this,i=t[e];return i?.destroyed?void t.splice(e,y.JC):i}async load(e){var t;let i,a;await this.init();let{Container:n}=await u.e(219).then(u.bind(u,3219)),s=e.id??e.element?.id??`tsparticles${Math.floor((0,z.G0)()*y.$v).toString()}`,{index:o,url:r}=e,l=r?await O({fallback:e.options,url:r,index:o}):e.options,d=(0,b.TA)(l,o),{items:c}=this,h=c.findIndex(e=>e.id.description===s),p=new n(this,s,d);if(h>=y.PZ){let e=this.item(h),t=e?y.xH:y.dv;e&&!e.destroyed&&e.destroy(!1),c.splice(h,t,p)}else c.push(p);let f=(e=>{let t,i=(0,b.T5)();if(e instanceof HTMLCanvasElement||e.tagName.toLowerCase()===y.RF)t=e,t.dataset[y.eb]??=y.X$;else{let a=e.getElementsByTagName(y.RF)[y.Nx];a?(t=a).dataset[y.eb]=y.X$:((t=i.createElement(y.RF)).dataset[y.eb]=y.ce,e.appendChild(t))}return t.style.width||=S,t.style.height||=S,t})((t=e.element,i=(0,b.T5)(),(a=t??i.getElementById(s))||((a=i.createElement("div")).id=s,a.dataset[y.eb]=y.ce,i.body.append(a)),a));return p.canvas.loadCanvas(f),await p.start(),p}loadParticlesOptions(e,t,...i){let a=this.updaters.get(e);a&&a.forEach(e=>e.loadOptions?.(t,...i))}async refresh(e=!0){e&&await Promise.all(this.items.map(e=>e.refresh()))}async register(...e){if(this._initialized)throw Error("Register plugins can only be done before calling tsParticles.load()");for(let t of e)this._isRunningLoaders?await this._runLoader(t,this._executedSet,this._allLoadersSet):this._loadPromises.add(t)}removeEventListener(e,t){this._eventDispatcher.removeEventListener(e,t)}async _runLoader(e,t,i){t.has(e)||(t.add(e),i.add(e),await e(this))}}var P=u(8150),k=u(5668),T=u(2740),F=u(546);(a=o||(o={})).clockwise="clockwise",a.counterClockwise="counter-clockwise",a.random="random";var _=u(7230),E=u(9355),I=u(5398),A=u(5045),D=u(7073),L=u(5563),V=u(6761);(n=r||(r={})).linear="linear",n.radial="radial",n.random="random";var C=u(8405),$=u(2010);(s=l||(l={})).easeInBack="ease-in-back",s.easeInBounce="ease-in-bounce",s.easeInCirc="ease-in-circ",s.easeInCubic="ease-in-cubic",s.easeInElastic="ease-in-elastic",s.easeInExpo="ease-in-expo",s.easeInGaussian="ease-in-gaussian",s.easeInLinear="ease-in-linear",s.easeInQuad="ease-in-quad",s.easeInQuart="ease-in-quart",s.easeInQuint="ease-in-quint",s.easeInSigmoid="ease-in-sigmoid",s.easeInSine="ease-in-sine",s.easeInSmoothstep="ease-in-smoothstep",s.easeOutBack="ease-out-back",s.easeOutBounce="ease-out-bounce",s.easeOutCirc="ease-out-circ",s.easeOutCubic="ease-out-cubic",s.easeOutElastic="ease-out-elastic",s.easeOutExpo="ease-out-expo",s.easeOutGaussian="ease-out-gaussian",s.easeOutLinear="ease-out-linear",s.easeOutQuad="ease-out-quad",s.easeOutQuart="ease-out-quart",s.easeOutQuint="ease-out-quint",s.easeOutSigmoid="ease-out-sigmoid",s.easeOutSine="ease-out-sine",s.easeOutSmoothstep="ease-out-smoothstep",s.easeInOutBack="ease-in-out-back",s.easeInOutBounce="ease-in-out-bounce",s.easeInOutCirc="ease-in-out-circ",s.easeInOutCubic="ease-in-out-cubic",s.easeInOutElastic="ease-in-out-elastic",s.easeInOutExpo="ease-in-out-expo",s.easeInOutGaussian="ease-in-out-gaussian",s.easeInOutLinear="ease-in-out-linear",s.easeInOutQuad="ease-in-out-quad",s.easeInOutQuart="ease-in-out-quart",s.easeInOutQuint="ease-in-out-quint",s.easeInOutSigmoid="ease-in-out-sigmoid",s.easeInOutSine="ease-in-out-sine",s.easeInOutSmoothstep="ease-in-out-smoothstep";var Z=u(7205),B=u(2685),G=u(3996),q=u(1139),H=u(5127),N=u(8705),j=u(1803),K=u(6996),W=u(5633),X=u(6408),Q=u(4939),U=u(5953),J=u(4508),Y=u(6156),ee=u(5373),et=u(9114),ei=u(2268),ea=u(1695),en=u(816),es=u(884),eo=u(1412),er=u(6556),el=u(9197),ed=u(3801),ec=u(1789),eu=u(4615),eh=u(2057),ep=u(8997),ef=u(4575),ev=u(4975),eg=u(9946),em=u(4860),ey=u(7927),eb=u(1964),ex=u(2679),ew=u(9739);let eM=new R;return globalThis.tsParticles=eM,m})());
1
+ !function(e,t){if("object"==typeof exports&&"object"==typeof module)module.exports=t();else if("function"==typeof define&&define.amd)define([],t);else{var i=t();for(var a in i)("object"==typeof exports?exports:e)[a]=i[a]}}(this,()=>(()=>{"use strict";var e,t,i,a,n,s,o,r,l,d={7157(e,t,i){i.d(t,{$G:()=>L,$O:()=>B,$_:()=>_,$v:()=>J,$x:()=>S,BF:()=>eR,BW:()=>h,DN:()=>Q,D_:()=>eb,Dv:()=>ex,Eo:()=>ea,FS:()=>H,Fl:()=>eP,GW:()=>C,Ie:()=>D,JC:()=>K,K3:()=>ep,KZ:()=>N,Kw:()=>M,L1:()=>E,LD:()=>ev,M1:()=>eo,MX:()=>r,N5:()=>en,NF:()=>n,Nu:()=>ez,Nx:()=>U,PZ:()=>Y,Pg:()=>R,R1:()=>f,RF:()=>b,RV:()=>G,Rh:()=>el,Rq:()=>V,TL:()=>j,U0:()=>A,Ug:()=>c,WH:()=>ei,X$:()=>y,X_:()=>es,Xu:()=>l,Zp:()=>O,a5:()=>o,aE:()=>eO,aZ:()=>g,bo:()=>d,ce:()=>m,dm:()=>w,dv:()=>et,eb:()=>a,eu:()=>F,gd:()=>p,hB:()=>P,hK:()=>eT,hv:()=>q,i8:()=>X,iU:()=>ew,jn:()=>ek,lA:()=>ef,mR:()=>u,nK:()=>s,nq:()=>ec,oi:()=>k,ou:()=>ed,pH:()=>eg,rq:()=>x,tA:()=>ey,tR:()=>eF,td:()=>em,un:()=>er,vF:()=>W,vS:()=>T,vd:()=>eM,w2:()=>Z,wM:()=>eu,xH:()=>ee,xd:()=>z,yx:()=>I,z$:()=>v,z9:()=>eh,zg:()=>eS,zs:()=>$});let a="generated",n="resize",s="visibilitychange",o=100,r=.5,l=1e3,d={x:0,y:0,z:0},c={a:1,b:0,c:0,d:1},u="random",h="mid",p=2,f=2*Math.PI,v=60,g=1,m="true",y="false",b="canvas",x=0,w=2,M=4,z=1,S=1,O=1,R=4,P=1,k=255,T=360,F=100,_=100,E=0,I=0,A=60,D=0,L=.25,V=.75,C=0,$=1,Z=0,B=0,G=1,q=1,H=1,N=1,j=0,K=1,W=0,X=120,Q=0,U=0,J=1e4,Y=0,ee=1,et=0,ei=1,ea=1,en=0,es=0,eo=0,er=-.25,el=1.5,ed=0,ec=1,eu=0,eh=0,ep=1,ef=1,ev=1,eg=500,em=50,ey=0,eb=1,ex=0,ew=1,eM=0,ez=3,eS=6,eO=1,eR=1,eP=0,ek=0,eT=0,eF=0},2714(e,t,i){i.d(t,{b:()=>a});class a{particle;position;constructor(e,t){this.position=e,this.particle=t}}},1636(e,t,i){i.d(t,{dg:()=>r,jl:()=>l,M_:()=>d}),(a=n||(n={})).circle="circle",a.rectangle="rectangle";var a,n,s=i(493),o=i(7157);class r{position;type;constructor(e,t,i){this.position={x:e,y:t},this.type=i}}class l extends r{radius;constructor(e,t,i){super(e,t,n.circle),this.radius=i}contains(e){return(0,s.Yf)(e,this.position)<=this.radius}intersects(e){let t=this.position,i=e.position,a={x:Math.abs(i.x-t.x),y:Math.abs(i.y-t.y)},s=this.radius;if(e instanceof l||e.type===n.circle)return s+e.radius>Math.sqrt(a.x**o.dm+a.y**o.dm);if(e instanceof d||e.type===n.rectangle){let{width:t,height:i}=e.size;return Math.pow(a.x-t,o.dm)+Math.pow(a.y-i,o.dm)<=s**o.dm||a.x<=s+t&&a.y<=s+i||a.x<=t||a.y<=i}return!1}}class d extends r{size;constructor(e,t,i,a){super(e,t,n.rectangle),this.size={height:a,width:i}}contains(e){let t=this.size.width,i=this.size.height,a=this.position;return e.x>=a.x&&e.x<=a.x+t&&e.y>=a.y&&e.y<=a.y+i}intersects(e){if(e instanceof l)return e.intersects(this);let t=this.size.width,i=this.size.height,a=this.position,n=e.position,s=e instanceof d?e.size:{width:0,height:0},o=s.width,r=s.height;return n.x<a.x+t&&n.x+o>a.x&&n.y<a.y+i&&n.y+r>a.y}}},1808(e,t,i){i.d(t,{M:()=>s,p:()=>n});var a=i(7157);class n{x;y;z;constructor(e=a.bo.x,t=a.bo.y,i=a.bo.z){this.x=e,this.y=t,this.z=i}static get origin(){return n.create(a.bo.x,a.bo.y,a.bo.z)}get angle(){return Math.atan2(this.y,this.x)}set angle(e){this._updateFromAngle(e,this.length)}get length(){return Math.sqrt(this.getLengthSq())}set length(e){this._updateFromAngle(this.angle,e)}static clone(e){return n.create(e.x,e.y,e.z)}static create(e,t,i){return"number"==typeof e?new n(e,t??a.bo.y,i??a.bo.z):new n(e.x,e.y,Object.hasOwn(e,"z")?e.z:a.bo.z)}add(e){return n.create(this.x+e.x,this.y+e.y,this.z+e.z)}addTo(e){this.x+=e.x,this.y+=e.y,this.z+=e.z}copy(){return n.clone(this)}distanceTo(e){return this.sub(e).length}distanceToSq(e){return this.sub(e).getLengthSq()}div(e){return n.create(this.x/e,this.y/e,this.z/e)}divTo(e){this.x/=e,this.y/=e,this.z/=e}getLengthSq(){return this.x**a.dm+this.y**a.dm}mult(e){return n.create(this.x*e,this.y*e,this.z*e)}multTo(e){this.x*=e,this.y*=e,this.z*=e}normalize(){let e=this.length;e!=a.dv&&this.multTo(a.hB/e)}rotate(e){return n.create(this.x*Math.cos(e)-this.y*Math.sin(e),this.x*Math.sin(e)+this.y*Math.cos(e),a.bo.z)}setTo(e){this.x=e.x,this.y=e.y,this.z=e.z?e.z:a.bo.z}sub(e){return n.create(this.x-e.x,this.y-e.y,this.z-e.z)}subFrom(e){this.x-=e.x,this.y-=e.y,this.z-=e.z}_updateFromAngle=(e,t)=>{this.x=Math.cos(e)*t,this.y=Math.sin(e)*t}}class s extends n{constructor(e=a.bo.x,t=a.bo.y){super(e,t,a.bo.z)}static get origin(){return s.create(a.bo.x,a.bo.y)}static clone(e){return s.create(e.x,e.y)}static create(e,t){return"number"==typeof e?new s(e,t??a.bo.y):new s(e.x,e.y)}}},1609(e,t,i){var a,n;i.d(t,{H:()=>a}),(n=a||(a={})).increasing="increasing",n.decreasing="decreasing"},3702(e,t,i){var a,n;i.d(t,{F:()=>a}),(n=a||(a={})).bottom="bottom",n.bottomLeft="bottom-left",n.bottomRight="bottom-right",n.left="left",n.none="none",n.right="right",n.top="top",n.topLeft="top-left",n.topRight="top-right",n.outside="outside",n.inside="inside"},9890(e,t,i){var a,n;i.d(t,{v:()=>a}),(n=a||(a={})).bottom="bottom",n.left="left",n.right="right",n.top="top"},5615(e,t,i){var a,n;i.d(t,{g:()=>a}),(n=a||(a={})).auto="auto",n.increase="increase",n.decrease="decrease",n.random="random"},1610(e,t,i){var a,n;i.d(t,{d:()=>a}),(n=a||(a={})).delete="delete",n.wait="wait"},3849(e,t,i){var a,n;i.d(t,{Y:()=>a}),(n=a||(a={})).bounce="bounce",n.none="none",n.out="out",n.destroy="destroy",n.split="split"},7917(e,t,i){var a,n;i.d(t,{q:()=>a}),(n=a||(a={})).precise="precise",n.percent="percent"},1903(e,t,i){var a,n;i.d(t,{H:()=>a}),(n=a||(a={})).darken="darken",n.enlighten="enlighten"},5717(e,t,i){var a,n;i.d(t,{V:()=>a}),(n=a||(a={})).none="none",n.max="max",n.min="min"},6911(e,t,i){var a,n;i.d(t,{B:()=>a}),(n=a||(a={})).configAdded="configAdded",n.containerInit="containerInit",n.particlesSetup="particlesSetup",n.containerStarted="containerStarted",n.containerStopped="containerStopped",n.containerDestroyed="containerDestroyed",n.containerPaused="containerPaused",n.containerPlay="containerPlay",n.containerBuilt="containerBuilt",n.particleAdded="particleAdded",n.particleDestroyed="particleDestroyed",n.particleRemoved="particleRemoved"},3457(e,t,i){var a,n;i.d(t,{x:()=>a}),(n=a||(a={})).normal="normal",n.inside="inside",n.outside="outside"},8910(e,t,i){var a,n;i.d(t,{S:()=>a}),(n=a||(a={})).max="max",n.min="min",n.random="random"},2249(e,t,i){i.d(t,{A:()=>o});var a=i(3727),n=i(1311),s=i(7981);class o extends s.O{animation;constructor(){super(),this.animation=new n.i}static create(e,t){let i=new o;return i.load(e),void 0!==t&&((0,a.Kg)(t)||(0,a.cy)(t)?i.load({value:t}):i.load(t)),i}load(e){if(super.load(e),(0,a.kZ)(e))return;let t=e.animation;void 0!==t&&(void 0===t.enable?this.animation.load(e.animation):this.animation.h.load(t))}}},7896(e,t,i){i.d(t,{Q:()=>l,p:()=>r});var a=i(5615),n=i(8910),s=i(3727),o=i(493);class r{count;decay;delay;enable;speed;sync;constructor(){this.count=0,this.enable=!1,this.speed=1,this.decay=0,this.delay=0,this.sync=!1}load(e){(0,s.kZ)(e)||(void 0!==e.count&&(this.count=(0,o.DT)(e.count)),void 0!==e.enable&&(this.enable=e.enable),void 0!==e.speed&&(this.speed=(0,o.DT)(e.speed)),void 0!==e.decay&&(this.decay=(0,o.DT)(e.decay)),void 0!==e.delay&&(this.delay=(0,o.DT)(e.delay)),void 0!==e.sync&&(this.sync=e.sync))}}class l extends r{mode;startValue;constructor(){super(),this.mode=a.g.auto,this.startValue=n.S.random}load(e){super.load(e),(0,s.kZ)(e)||(void 0!==e.mode&&(this.mode=e.mode),void 0!==e.startValue&&(this.startValue=e.startValue))}}},5767(e,t,i){i.d(t,{V:()=>s});var a=i(7981),n=i(3727);class s{color;image;opacity;position;repeat;size;constructor(){this.color=new a.O,this.color.value="",this.image="",this.position="",this.repeat="",this.size="",this.opacity=1}load(e){(0,n.kZ)(e)||(void 0!==e.color&&(this.color=a.O.create(this.color,e.color)),void 0!==e.image&&(this.image=e.image),void 0!==e.position&&(this.position=e.position),void 0!==e.repeat&&(this.repeat=e.repeat),void 0!==e.size&&(this.size=e.size),void 0!==e.opacity&&(this.opacity=e.opacity))}}},8859(e,t,i){i.d(t,{e:()=>o});var a=i(7896),n=i(3727),s=i(493);class o extends a.p{offset;constructor(){super(),this.offset=0,this.sync=!0}load(e){super.load(e),(0,n.kZ)(e)||void 0!==e.offset&&(this.offset=(0,s.DT)(e.offset))}}},1845(e,t,i){i.d(t,{m:()=>n});var a=i(3727);class n{enable;zIndex;constructor(){this.enable=!0,this.zIndex=0}load(e){(0,a.kZ)(e)||(void 0!==e.enable&&(this.enable=e.enable),void 0!==e.zIndex&&(this.zIndex=e.zIndex))}}},1311(e,t,i){i.d(t,{i:()=>s});var a=i(8859),n=i(3727);class s{h=new a.e;l=new a.e;s=new a.e;load(e){(0,n.kZ)(e)||(this.h.load(e.h),this.s.load(e.s),this.l.load(e.l))}}},5872(e,t,i){i.d(t,{J:()=>c});var a=i(2439),n=i(3727),s=i(5767),o=i(1845),r=i(8590),l=i(9875),d=i(493);class c{autoPlay;background;clear;defaultThemes;delay;detectRetina;duration;fpsLimit;fullScreen;hdr;key;name;particles;pauseOnBlur;pauseOnOutsideViewport;preset;resize;smooth;style;zLayers;_container;_engine;constructor(e,t){this._engine=e,this._container=t,this.autoPlay=!0,this.background=new s.V,this.clear=!0,this.defaultThemes={},this.delay=0,this.fullScreen=new o.m,this.detectRetina=!0,this.duration=0,this.fpsLimit=120,this.hdr=!0,this.particles=(0,l.y)(this._engine,this._container),this.pauseOnBlur=!0,this.pauseOnOutsideViewport=!0,this.resize=new r.z,this.smooth=!1,this.style={},this.zLayers=100}load(e){if((0,n.kZ)(e))return;void 0!==e.preset&&(0,a.wJ)(e.preset,e=>{this._importPreset(e)}),void 0!==e.autoPlay&&(this.autoPlay=e.autoPlay),void 0!==e.clear&&(this.clear=e.clear),void 0!==e.key&&(this.key=e.key),void 0!==e.name&&(this.name=e.name),void 0!==e.delay&&(this.delay=(0,d.DT)(e.delay));let t=e.detectRetina;void 0!==t&&(this.detectRetina=t),void 0!==e.duration&&(this.duration=(0,d.DT)(e.duration));let i=e.fpsLimit;void 0!==i&&(this.fpsLimit=i),void 0!==e.hdr&&(this.hdr=e.hdr),void 0!==e.pauseOnBlur&&(this.pauseOnBlur=e.pauseOnBlur),void 0!==e.pauseOnOutsideViewport&&(this.pauseOnOutsideViewport=e.pauseOnOutsideViewport),void 0!==e.zLayers&&(this.zLayers=e.zLayers),this.background.load(e.background);let s=e.fullScreen;(0,n.Lm)(s)?this.fullScreen.enable=s:this.fullScreen.load(s),this.particles.load(e.particles),this.resize.load(e.resize),this.style=(0,a.zw)(this.style,e.style),void 0!==e.smooth&&(this.smooth=e.smooth),this._engine.plugins.forEach(t=>{t.loadOptions(this._container,this,e)})}_importPreset=e=>{this.load(this._engine.getPreset(e))}}},7981(e,t,i){i.d(t,{O:()=>n});var a=i(3727);class n{value;constructor(){this.value=""}static create(e,t){let i=new n;return i.load(e),void 0!==t&&((0,a.Kg)(t)||(0,a.cy)(t)?i.load({value:t}):i.load(t)),i}load(e){!(0,a.kZ)(e)&&((0,a.kZ)(e.value)||(this.value=e.value))}}},5484(e,t,i){i.d(t,{w:()=>s});var a=i(1799),n=i(3727);class s{horizontal;vertical;constructor(){this.horizontal=new a.F,this.vertical=new a.F}load(e){(0,n.kZ)(e)||(this.horizontal.load(e.horizontal),this.vertical.load(e.vertical))}}},1799(e,t,i){i.d(t,{F:()=>n});var a=i(424);class n extends a.PV{constructor(){super(),this.value=1}}},2657(e,t,i){i.d(t,{y:()=>p});var a=i(3702),n=i(3727),s=i(6086),o=i(2816),r=i(608),l=i(2256),d=i(8136),c=i(668),u=i(3072),h=i(493);class p{angle;attract;center;decay;direction;distance;drift;enable;gravity;outModes;path;random;size;speed;spin;straight;vibrate;warp;constructor(){this.angle=new s.h,this.attract=new o.R,this.center=new r.Z,this.decay=0,this.distance={},this.direction=a.F.none,this.drift=0,this.enable=!1,this.gravity=new l.y,this.path=new d.v,this.outModes=new c.j,this.random=!1,this.size=!1,this.speed=2,this.spin=new u.t,this.straight=!1,this.vibrate=!1,this.warp=!1}load(e){if((0,n.kZ)(e))return;this.angle.load((0,n.Et)(e.angle)?{value:e.angle}:e.angle),this.attract.load(e.attract),this.center.load(e.center),void 0!==e.decay&&(this.decay=(0,h.DT)(e.decay)),void 0!==e.direction&&(this.direction=e.direction),void 0!==e.distance&&(this.distance=(0,n.Et)(e.distance)?{horizontal:e.distance,vertical:e.distance}:{...e.distance}),void 0!==e.drift&&(this.drift=(0,h.DT)(e.drift)),void 0!==e.enable&&(this.enable=e.enable),this.gravity.load(e.gravity);let t=e.outModes;void 0!==t&&((0,n.Gv)(t)?this.outModes.load(t):this.outModes.load({default:t})),this.path.load(e.path),void 0!==e.random&&(this.random=e.random),void 0!==e.size&&(this.size=e.size),void 0!==e.speed&&(this.speed=(0,h.DT)(e.speed)),this.spin.load(e.spin),void 0!==e.straight&&(this.straight=e.straight),void 0!==e.vibrate&&(this.vibrate=e.vibrate),void 0!==e.warp&&(this.warp=e.warp)}}},6086(e,t,i){i.d(t,{h:()=>s});var a=i(3727),n=i(493);class s{offset;value;constructor(){this.offset=0,this.value=90}load(e){(0,a.kZ)(e)||(void 0!==e.offset&&(this.offset=(0,n.DT)(e.offset)),void 0!==e.value&&(this.value=(0,n.DT)(e.value)))}}},2816(e,t,i){i.d(t,{R:()=>s});var a=i(3727),n=i(493);class s{distance;enable;rotate;constructor(){this.distance=200,this.enable=!1,this.rotate={x:3e3,y:3e3}}load(e){if(!(0,a.kZ)(e)&&(void 0!==e.distance&&(this.distance=(0,n.DT)(e.distance)),void 0!==e.enable&&(this.enable=e.enable),e.rotate)){let t=e.rotate.x;void 0!==t&&(this.rotate.x=t);let i=e.rotate.y;void 0!==i&&(this.rotate.y=i)}}}},608(e,t,i){i.d(t,{Z:()=>s});var a=i(7917),n=i(3727);class s{mode;radius;x;y;constructor(){this.x=50,this.y=50,this.mode=a.q.percent,this.radius=0}load(e){(0,n.kZ)(e)||(void 0!==e.x&&(this.x=e.x),void 0!==e.y&&(this.y=e.y),void 0!==e.mode&&(this.mode=e.mode),void 0!==e.radius&&(this.radius=e.radius))}}},2256(e,t,i){i.d(t,{y:()=>s});var a=i(3727),n=i(493);class s{acceleration;enable;inverse;maxSpeed;constructor(){this.acceleration=9.81,this.enable=!1,this.inverse=!1,this.maxSpeed=50}load(e){(0,a.kZ)(e)||(void 0!==e.acceleration&&(this.acceleration=(0,n.DT)(e.acceleration)),void 0!==e.enable&&(this.enable=e.enable),void 0!==e.inverse&&(this.inverse=e.inverse),void 0!==e.maxSpeed&&(this.maxSpeed=(0,n.DT)(e.maxSpeed)))}}},668(e,t,i){i.d(t,{j:()=>s});var a=i(3849),n=i(3727);class s{bottom;default;left;right;top;constructor(){this.default=a.Y.out}load(e){(0,n.kZ)(e)||(void 0!==e.default&&(this.default=e.default),this.bottom=e.bottom??e.default,this.left=e.left??e.default,this.right=e.right??e.default,this.top=e.top??e.default)}}},8136(e,t,i){i.d(t,{v:()=>o});var a=i(424),n=i(2439),s=i(3727);class o{clamp;delay;enable;generator;options;constructor(){this.clamp=!0,this.delay=new a.PV,this.enable=!1,this.options={}}load(e){!(0,s.kZ)(e)&&(void 0!==e.clamp&&(this.clamp=e.clamp),this.delay.load(e.delay),void 0!==e.enable&&(this.enable=e.enable),this.generator=e.generator,e.options&&(this.options=(0,n.zw)(this.options,e.options)))}}},3072(e,t,i){i.d(t,{t:()=>o});var a=i(2439),n=i(3727),s=i(493);class o{acceleration;enable;position;constructor(){this.acceleration=0,this.enable=!1}load(e){!(0,n.kZ)(e)&&(void 0!==e.acceleration&&(this.acceleration=(0,s.DT)(e.acceleration)),void 0!==e.enable&&(this.enable=e.enable),e.position&&(this.position=(0,a.zw)({},e.position)))}}},9829(e,t,i){i.d(t,{M:()=>n});var a=i(3727);class n{enable;height;width;constructor(){this.enable=!1,this.width=1920,this.height=1080}load(e){if((0,a.kZ)(e))return;void 0!==e.enable&&(this.enable=e.enable);let t=e.width;void 0!==t&&(this.width=t);let i=e.height;void 0!==i&&(this.height=i)}}},2096(e,t,i){i.d(t,{N:()=>o});var a=i(9829),n=i(7537),s=i(3727);class o{density;limit;value;constructor(){this.density=new a.M,this.limit=new n.A,this.value=0}load(e){(0,s.kZ)(e)||(this.density.load(e.density),this.limit.load(e.limit),void 0!==e.value&&(this.value=e.value))}}},7537(e,t,i){i.d(t,{A:()=>s});var a=i(1610),n=i(3727);class s{mode;value;constructor(){this.mode=a.d.delete,this.value=0}load(e){(0,n.kZ)(e)||(void 0!==e.mode&&(this.mode=e.mode),void 0!==e.value&&(this.value=e.value))}}},7089(e,t,i){i.d(t,{Y:()=>o});var a=i(763),n=i(424),s=i(3727);class o extends n.AI{animation;constructor(){super(),this.animation=new a.I,this.value=1}load(e){if((0,s.kZ)(e))return;super.load(e);let t=e.animation;void 0!==t&&this.animation.load(t)}}},763(e,t,i){i.d(t,{I:()=>o});var a=i(5717),n=i(7896),s=i(3727);class o extends n.Q{destroy;constructor(){super(),this.destroy=a.V.none,this.speed=2}load(e){super.load(e),(0,s.kZ)(e)||void 0!==e.destroy&&(this.destroy=e.destroy)}}},3068(e,t,i){i.d(t,{U:()=>v});var a=i(2439),n=i(2249),s=i(3727);class o{close;fill;options;type;constructor(){this.close=!0,this.fill=!0,this.options={},this.type=[]}load(e){if((0,s.kZ)(e))return;let t=e.options;if(void 0!==t)for(let e in t){let i=t[e];i&&(this.options[e]=(0,a.zw)(this.options[e]??{},i))}void 0!==e.close&&(this.close=e.close),void 0!==e.fill&&(this.fill=e.fill),void 0!==e.type&&(this.type=e.type)}}var r=i(2657),l=i(7089),d=i(5484),c=i(2096),u=i(8861),h=i(2825),p=i(3480),f=i(9651);class v{bounce;color;effect;groups;move;number;opacity;reduceDuplicates;shape;size;stroke;zIndex;_container;_engine;constructor(e,t){this._engine=e,this._container=t,this.bounce=new d.w,this.color=new n.A,this.color.value="#fff",this.effect=new o,this.groups={},this.move=new r.y,this.number=new c.N,this.opacity=new l.Y,this.reduceDuplicates=!1,this.shape=new u.y,this.size=new h.o,this.stroke=new p.t,this.zIndex=new f.P}load(e){if((0,s.kZ)(e))return;if(void 0!==e.groups)for(let t of Object.keys(e.groups)){if(!Object.hasOwn(e.groups,t))continue;let i=e.groups[t];void 0!==i&&(this.groups[t]=(0,a.zw)(this.groups[t]??{},i))}void 0!==e.reduceDuplicates&&(this.reduceDuplicates=e.reduceDuplicates),this.bounce.load(e.bounce),this.color.load(n.A.create(this.color,e.color)),this.effect.load(e.effect),this.move.load(e.move),this.number.load(e.number),this.opacity.load(e.opacity),this.shape.load(e.shape),this.size.load(e.size),this.zIndex.load(e.zIndex);let t=e.stroke;if(t&&(this.stroke=(0,a.wJ)(t,e=>{let t=new p.t;return t.load(e),t})),this._container){for(let t of this._engine.plugins)t.loadParticlesOptions&&t.loadParticlesOptions(this._container,this,e);let t=this._engine.updaters.get(this._container);if(t)for(let i of t)i.loadOptions&&i.loadOptions(this,e)}}}},8861(e,t,i){i.d(t,{y:()=>s});var a=i(2439),n=i(3727);class s{close;fill;options;type;constructor(){this.close=!0,this.fill=!0,this.options={},this.type="circle"}load(e){if((0,n.kZ)(e))return;let t=e.options;if(void 0!==t)for(let e in t){let i=t[e];i&&(this.options[e]=(0,a.zw)(this.options[e]??{},i))}void 0!==e.close&&(this.close=e.close),void 0!==e.fill&&(this.fill=e.fill),void 0!==e.type&&(this.type=e.type)}}},2825(e,t,i){i.d(t,{o:()=>o});var a=i(424),n=i(5555),s=i(3727);class o extends a.AI{animation;constructor(){super(),this.animation=new n.q,this.value=3}load(e){if(super.load(e),(0,s.kZ)(e))return;let t=e.animation;void 0!==t&&this.animation.load(t)}}},5555(e,t,i){i.d(t,{q:()=>o});var a=i(5717),n=i(7896),s=i(3727);class o extends n.Q{destroy;constructor(){super(),this.destroy=a.V.none,this.speed=5}load(e){super.load(e),(0,s.kZ)(e)||void 0!==e.destroy&&(this.destroy=e.destroy)}}},3480(e,t,i){i.d(t,{t:()=>o});var a=i(2249),n=i(3727),s=i(493);class o{color;opacity;width;constructor(){this.width=0}load(e){(0,n.kZ)(e)||(void 0!==e.color&&(this.color=a.A.create(this.color,e.color)),void 0!==e.width&&(this.width=(0,s.DT)(e.width)),void 0!==e.opacity&&(this.opacity=(0,s.DT)(e.opacity)))}}},9651(e,t,i){i.d(t,{P:()=>s});var a=i(424),n=i(3727);class s extends a.PV{opacityRate;sizeRate;velocityRate;constructor(){super(),this.opacityRate=1,this.sizeRate=1,this.velocityRate=1}load(e){super.load(e),(0,n.kZ)(e)||(void 0!==e.opacityRate&&(this.opacityRate=e.opacityRate),void 0!==e.sizeRate&&(this.sizeRate=e.sizeRate),void 0!==e.velocityRate&&(this.velocityRate=e.velocityRate))}}},8590(e,t,i){i.d(t,{z:()=>n});var a=i(3727);class n{delay;enable;constructor(){this.delay=.5,this.enable=!0}load(e){(0,a.kZ)(e)||(void 0!==e.delay&&(this.delay=e.delay),void 0!==e.enable&&(this.enable=e.enable))}}},424(e,t,i){i.d(t,{AI:()=>l,Jm:()=>r,PV:()=>o});var a=i(7896),n=i(3727),s=i(493);class o{value;constructor(){this.value=0}load(e){!(0,n.kZ)(e)&&((0,n.kZ)(e.value)||(this.value=(0,s.DT)(e.value)))}}class r extends o{animation=new a.p;load(e){if(super.load(e),(0,n.kZ)(e))return;let t=e.animation;void 0!==t&&this.animation.load(t)}}class l extends r{animation;constructor(){super(),this.animation=new a.Q}load(e){super.load(e)}}},1963(e,t,i){i.d(t,{IU:()=>r,KG:()=>u,Md:()=>o,Sn:()=>s,VG:()=>p,Wb:()=>f,gF:()=>h,k:()=>d,p0:()=>l,yx:()=>v,z5:()=>c});var a=i(7157),n=i(1903);function s(e,t,i){e.fillStyle=i??"rgba(0,0,0,0)",e.fillRect(a.bo.x,a.bo.y,t.width,t.height)}function o(e,t,i,n){i&&(e.globalAlpha=n,e.drawImage(i,a.bo.x,a.bo.y,t.width,t.height),e.globalAlpha=1)}function r(e,t){e.clearRect(a.bo.x,a.bo.y,t.width,t.height)}function l(e){let{container:t,context:i,particle:n,delta:s,colorStyles:o,radius:r,opacity:l,transform:f}=e,v=n.getPosition(),g=n.getTransformData(f);i.setTransform(g.a,g.b,g.c,g.d,v.x,v.y),o.fill&&(i.fillStyle=o.fill);let m=n.strokeWidth??a.Dv;i.lineWidth=m,o.stroke&&(i.strokeStyle=o.stroke);let y={context:i,particle:n,radius:r,opacity:l,delta:s,pixelRatio:t.retina.pixelRatio,fill:n.shapeFill,stroke:m>a.Dv||!n.shapeFill,transformData:g};c(t,y),p(t,y),u(t,y),h(t,y),d(t,y),i.resetTransform()}function d(e,t){let{particle:i}=t;if(!i.effect)return;let a=e.particles.effectDrawers.get(i.effect),n=a?.drawAfter;n&&n(t)}function c(e,t){let{particle:i}=t;if(!i.effect)return;let a=e.particles.effectDrawers.get(i.effect);a?.drawBefore&&a.drawBefore(t)}function u(e,t){let{context:i,particle:a,stroke:n}=t;if(!a.shape)return;let s=e.particles.shapeDrawers.get(a.shape);s&&(i.beginPath(),s.draw(t),a.shapeClose&&i.closePath(),n&&i.stroke(),a.shapeFill&&i.fill())}function h(e,t){let{particle:i}=t;if(!i.shape)return;let a=e.particles.shapeDrawers.get(i.shape);a?.afterDraw&&a.afterDraw(t)}function p(e,t){let{particle:i}=t;if(!i.shape)return;let a=e.particles.shapeDrawers.get(i.shape);a?.beforeDraw&&a.beforeDraw(t)}function f(e,t,i,a){t.drawParticle&&t.drawParticle(e,i,a)}function v(e,t,i){return{h:e.h,s:e.s,l:e.l+(t===n.H.darken?-a.iU:a.iU)*i}}},6720(e,t,i){i.d(t,{BN:()=>u,EY:()=>S,Jv:()=>_,K6:()=>v,Ko:()=>F,LC:()=>z,OH:()=>x,O_:()=>P,PG:()=>R,R5:()=>f,YL:()=>y,_h:()=>O,ay:()=>b,eg:()=>m,mK:()=>p,pz:()=>k,qe:()=>h,xx:()=>w,zI:()=>g});var a=i(493),n=i(7157),s=i(3727),o=i(1609),r=i(2439);let l=new Map;function d(e,t){let i=l.get(e);return i||(i=t(),l.size>=1e3&&[...l.keys()].slice(0,1e3*n.MX).forEach(e=>l.delete(e)),l.set(e,i)),i}function c(e,t){if(t){for(let i of e.colorManagers.values())if(i.accepts(t))return i.parseString(t)}}function u(e,t,i,a=!0){if(!t)return;let n=(0,s.Kg)(t)?{value:t}:t;if((0,s.Kg)(n.value))return h(e,n.value,i,a);if((0,s.cy)(n.value)){let t=(0,r.Vh)(n.value,i,a);if(!t)return;return u(e,{value:t})}for(let t of e.colorManagers.values()){let e=t.handleRangeColor(n);if(e)return e}}function h(e,t,i,a=!0){if(!t)return;let o=(0,s.Kg)(t)?{value:t}:t;if((0,s.Kg)(o.value))return o.value===n.mR?x():c(e,o.value);if((0,s.cy)(o.value)){let t=(0,r.Vh)(o.value,i,a);if(!t)return;return h(e,{value:t})}for(let t of e.colorManagers.values()){let e=t.handleColor(o);if(e)return e}}function p(e,t,i,a=!0){let n=h(e,t,i,a);return n?v(n):void 0}function f(e,t,i,a=!0){let n=u(e,t,i,a);return n?v(n):void 0}function v(e){let t=e.r/n.oi,i=e.g/n.oi,a=e.b/n.oi,s=Math.max(t,i,a),o=Math.min(t,i,a),r={h:n.L1,l:(s+o)*n.MX,s:n.yx};return s!==o&&(r.s=r.l<n.MX?(s-o)/(s+o):(s-o)/(n.gd-s-o),t===s?r.h=(i-a)/(s-o):i===s?r.h=n.gd+(a-t)/(s-o):r.h=n.gd*n.gd+(t-i)/(s-o)),r.l*=n.$_,r.s*=n.eu,r.h*=n.U0,r.h<n.L1&&(r.h+=n.vS),r.h>=n.vS&&(r.h-=n.vS),r}function g(e,t){return c(e,t)?.a}function m(e,t){return c(e,t)}function y(e){let t=(e.h%n.vS+n.vS)%n.vS,i=Math.max(n.yx,Math.min(n.eu,e.s)),a=Math.max(n.vd,Math.min(n.$_,e.l)),s=t/n.vS,o=i/n.eu,r=a/n.$_;if(i===n.yx){let e=Math.round(r*n.oi);return{r:e,g:e,b:e}}let l=(e,t,i)=>(i<0&&i++,i>1&&i--,i*n.zg<1)?e+(t-e)*n.zg*i:i*n.gd<1?t:i*n.Nu<+n.gd?e+(t-e)*(n.gd/n.Nu-i)*n.zg:e,d=r<n.MX?r*(n.aE+o):r+o-r*o,c=n.gd*r-d,u=n.BF/n.Nu;return{r:Math.round(Math.min(n.oi,n.oi*l(c,d,s+u))),g:Math.round(Math.min(n.oi,n.oi*l(c,d,s))),b:Math.round(Math.min(n.oi,n.oi*l(c,d,s-u)))}}function b(e){let t=y(e);return{a:e.a,b:t.b,g:t.g,r:t.r}}function x(e){let t=e??n.Fl,i=n.oi+n.D_,s=()=>Math.floor((0,a.e4)(t,i));return{b:s(),g:s(),r:s()}}function w(e,t,i){let a=i??n.hv;return d(`rgb-${e.r.toFixed(2)}-${e.g.toFixed(2)}-${e.b.toFixed(2)}-${t?"hdr":"sdr"}-${a.toString()}`,()=>{var a,s;return t?M(e,i):(a=e,s=i,`rgba(${a.r.toString()}, ${a.g.toString()}, ${a.b.toString()}, ${(s??n.hv).toString()})`)})}function M(e,t){return`color(display-p3 ${(e.r/n.oi).toString()} ${(e.g/n.oi).toString()} ${(e.b/n.oi).toString()} / ${(t??n.hv).toString()})`}function z(e,t,i){let a=i??n.hv;return d(`hsl-${e.h.toFixed(2)}-${e.s.toFixed(2)}-${e.l.toFixed(2)}-${t?"hdr":"sdr"}-${a.toString()}`,()=>{var a,s,o,r;return t?(a=e,s=i,M(y(a),s)):(o=e,r=i,`hsla(${o.h.toString()}, ${o.s.toString()}%, ${o.l.toString()}%, ${(r??n.hv).toString()})`)})}function S(e,t,i,n){let s=e,o=t;return Object.hasOwn(s,"r")||(s=y(e)),Object.hasOwn(o,"r")||(o=y(t)),{b:(0,a.jh)(s.b,o.b,i,n),g:(0,a.jh)(s.g,o.g,i,n),r:(0,a.jh)(s.r,o.r,i,n)}}function O(e,t,i){if(i===n.mR)return x();if(i!==n.BW)return i;{let i=e.getFillColor()??e.getStrokeColor(),a=t?.getFillColor()??t?.getStrokeColor();if(i&&a&&t)return S(i,a,e.getRadius(),t.getRadius());{let e=i??a;if(e)return y(e)}}}function R(e,t,i,a){let o=(0,s.Kg)(t)?t:t.value;return o===n.mR?a?u(e,{value:o}):i?n.mR:n.BW:o===n.BW?n.BW:u(e,{value:o})}function P(e){return void 0!==e?{h:e.h.value,s:e.s.value,l:e.l.value}:void 0}function k(e,t,i){let a={h:{enable:!1,value:e.h},s:{enable:!1,value:e.s},l:{enable:!1,value:e.l}};return t&&(T(a.h,t.h,i),T(a.s,t.s,i),T(a.l,t.l,i)),a}function T(e,t,i){e.enable=t.enable,e.enable?(e.velocity=(0,a.VG)(t.speed)/n.a5*i,e.decay=n.WH-(0,a.VG)(t.decay),e.status=o.H.increasing,e.loops=n.hK,e.maxLoops=(0,a.VG)(t.count),e.time=n.tR,e.delayTime=(0,a.VG)(t.delay)*n.Xu,t.sync||(e.velocity*=(0,a.G0)(),e.value*=(0,a.G0)()),e.initialValue=e.value,e.offset=(0,a.DT)(t.offset)):e.velocity=n.jn}function F(e,t,i,n){if(!e.enable||(e.maxLoops??0)>0&&(e.loops??0)>(e.maxLoops??0)||(e.time??=0,(e.delayTime??0)>0&&e.time<(e.delayTime??0)&&(e.time+=n.value),(e.delayTime??0)>0&&e.time<(e.delayTime??0)))return;let s=e.offset?(0,a.vE)(e.offset):0,r=(e.velocity??0)*n.factor+3.6*s,l=e.decay??1,d=(0,a.W9)(t),c=(0,a.Sg)(t);i&&e.status!==o.H.increasing?(e.value-=r,e.value<0&&(e.loops??=0,e.loops++,e.status=o.H.increasing)):(e.value+=r,e.value>d&&(e.loops??=0,e.loops++,i?e.status=o.H.decreasing:e.value-=d)),e.velocity&&1!==l&&(e.velocity*=l),e.value=(0,a.qE)(e.value,c,d)}function _(e,t){if(!e)return;let{h:i,s:a,l:s}=e,o={h:{min:n.L1,max:n.vS},s:{min:n.yx,max:n.eu},l:{min:n.vd,max:n.$_}};F(i,o.h,!1,t),F(a,o.s,!0,t),F(s,o.l,!0,t)}},567(e,t,i){i.d(t,{B:()=>n,t:()=>s});let a={debug:console.debug,error:(e,t)=>{console.error(`tsParticles - Error - ${e}`,t)},info:console.info,log:console.log,verbose:console.log,warning:console.warn};function n(e){a.debug=e.debug,a.error=e.error,a.info=e.info,a.log=e.log,a.verbose=e.verbose,a.warning=e.warning}function s(){return a}},493(e,t,i){i.d(t,{$m:()=>R,AD:()=>p,DT:()=>function e(t,i){if(t===i||void 0===i&&(0,o.Et)(t))return t;let a=x(t),n=w(t);return void 0!==i?{min:Math.min(a,i),max:Math.max(n,i)}:e(a,n)},G0:()=>u,JY:()=>O,M3:()=>I,Mh:()=>T,Nx:()=>_,OE:()=>c,OW:()=>P,Sg:()=>x,VG:()=>b,W9:()=>w,Yf:()=>z,e4:()=>h,eh:()=>k,i0:()=>f,jh:()=>m,l1:()=>F,pu:()=>S,px:()=>v,qE:()=>g,qM:()=>E,vE:()=>y,vr:()=>M});var a=i(3702),n=i(7157),s=i(1808),o=i(3727);let r=Math.PI/180,l=Math.random,d={nextFrame:e=>requestAnimationFrame(e),cancel:e=>{cancelAnimationFrame(e)}};function c(e=Math.random){l=e}function u(){return g(l(),0,1-Number.EPSILON)}function h(e,t){return u()*(t-e)+e}function p(e,t){d.nextFrame=t=>e(t),d.cancel=e=>{t(e)}}function f(e){return d.nextFrame(e)}function v(e){d.cancel(e)}function g(e,t,i){return Math.min(Math.max(e,t),i)}function m(e,t,i,a){return Math.floor((e*i+t*a)/(i+a))}function y(e){let t=w(e),i=x(e);return t===i&&(i=0),h(i,t)}function b(e){return(0,o.Et)(e)?e:y(e)}function x(e){return(0,o.Et)(e)?e:e.min}function w(e){return(0,o.Et)(e)?e:e.max}function M(e,t){let i=e.x-t.x,a=e.y-t.y;return{dx:i,dy:a,distance:Math.sqrt(i**2+a**2)}}function z(e,t){return M(e,t).distance}function S(e){return e*r}function O(e,t,i){if((0,o.Et)(e))return e*r;switch(e){case a.F.top:return-Math.PI*n.MX;case a.F.topRight:return-Math.PI*n.$G;case a.F.right:return n.Ie;case a.F.bottomRight:return Math.PI*n.$G;case a.F.bottom:return Math.PI*n.MX;case a.F.bottomLeft:return Math.PI*n.Rq;case a.F.left:return Math.PI;case a.F.topLeft:return-Math.PI*n.Rq;case a.F.inside:return Math.atan2(i.y-t.y,i.x-t.x);case a.F.outside:return Math.atan2(t.y-i.y,t.x-i.x);default:return u()*n.R1}}function R(e){let t=s.M.origin;return t.length=1,t.angle=e,t}function P(e,t,i,a){return s.M.create(e.x*(i-a)/(i+a)+t.x*n.gd*a/(i+a),e.y)}function k(e){return e.position?.x!==void 0&&void 0!==e.position.y?{x:e.position.x*e.size.width/n.a5,y:e.position.y*e.size.height/n.a5}:void 0}function T(e){return{x:(e.position?.x??u()*n.a5)*e.size.width/n.a5,y:(e.position?.y??u()*n.a5)*e.size.height/n.a5}}function F(e){let t={x:e.position?.x!==void 0?b(e.position.x):void 0,y:e.position?.y!==void 0?b(e.position.y):void 0};return T({size:e.size,position:t})}function _(e){let{position:t,size:i}=e;return{x:t?.x??u()*i.width,y:t?.y??u()*i.height}}function E(e){let t={x:e.position?.x!==void 0?b(e.position.x):void 0,y:e.position?.y!==void 0?b(e.position.y):void 0};return _({size:e.size,position:t})}function I(e){return e?e.endsWith("%")?parseFloat(e)/n.a5:parseFloat(e):1}},9875(e,t,i){i.d(t,{Z:()=>n,y:()=>s});var a=i(3068);function n(e,...t){for(let i of t)e.load(i)}function s(e,t,...i){let o=new a.U(e,t);return n(o,...i),o}},3727(e,t,i){function a(e){return"boolean"==typeof e}function n(e){return"string"==typeof e}function s(e){return"number"==typeof e}function o(e){return"function"==typeof e}function r(e){return"object"==typeof e&&null!==e}function l(e){return Array.isArray(e)}function d(e){return null==e}i.d(t,{Et:()=>s,Gv:()=>r,Kg:()=>n,Lm:()=>a,Tn:()=>o,cy:()=>l,kZ:()=>d})},2439(e,t,i){let a;i.d(t,{AE:()=>O,BR:()=>y,E9:()=>I,HQ:()=>$,Kp:()=>C,O2:()=>S,Ot:()=>Z,T5:()=>g,TA:()=>T,Tg:()=>R,Tj:()=>z,UC:()=>D,Vh:()=>M,Xs:()=>_,YC:()=>A,hJ:()=>V,hn:()=>x,lV:()=>m,n0:()=>w,pE:()=>P,q8:()=>v,tG:()=>b,td:()=>L,w3:()=>F,wJ:()=>k,zw:()=>function e(t,...i){for(let a of i)if(null!=a){if(!(0,r.Gv)(a)){t=a;continue}for(let i in Array.isArray(a)?Array.isArray(t)||(t=[]):(!(0,r.Gv)(t)||Array.isArray(t))&&(t={}),a){if("__proto__"===i)continue;let n=a[i],s=t;s[i]=(0,r.Gv)(n)&&Array.isArray(n)?n.map(t=>e(s[i],t)):e(s[i],n)}}return t}});var n,s=i(493),o=i(7157),r=i(3727),l=i(5615),d=i(1609),c=i(5717),u=i(9890),h=i(7917),p=i(8910),f=i(1808);function v(){return"u">typeof matchMedia}function g(){return globalThis.document}function m(e){if(v())return matchMedia(e)}function y(e){if("u">typeof IntersectionObserver)return new IntersectionObserver(e)}function b(e){if("u">typeof MutationObserver)return new MutationObserver(e)}function x(e,t){return e===t||(0,r.cy)(t)&&t.includes(e)}function w(e){return Math.floor((0,s.G0)()*e.length)}function M(e,t,i=!0){return e[void 0!==t&&i?t%e.length:w(e)]}function z(e,t,i,a,n){return S(O(e,a??0),t,i,n)}function S(e,t,i,a){let n=!0;return a&&a!==u.v.bottom||(n=e.top<t.height+i.x),n&&(!a||a===u.v.left)&&(n=e.right>i.x),n&&(!a||a===u.v.right)&&(n=e.left<t.width+i.y),n&&(!a||a===u.v.top)&&(n=e.bottom>i.y),n}function O(e,t){return{bottom:e.y+t,left:e.x-t,right:e.x+t,top:e.y-t}}function R(e){return{position:e.getPosition(),radius:e.getRadius(),mass:e.getMass(),velocity:e.velocity,factor:f.M.create((0,s.VG)(e.options.bounce.horizontal.value),(0,s.VG)(e.options.bounce.vertical.value))}}function P(e,t){let{x:i,y:a}=e.velocity.sub(t.velocity),[n,o]=[e.position,t.position],{dx:r,dy:l}=(0,s.vr)(o,n);if(i*r+a*l<0)return;let d=-Math.atan2(l,r),c=e.mass,u=t.mass,h=e.velocity.rotate(d),p=t.velocity.rotate(d),f=(0,s.OW)(h,p,c,u),v=(0,s.OW)(p,h,c,u),g=f.rotate(-d),m=v.rotate(-d);e.velocity.x=g.x*e.factor.x,e.velocity.y=g.y*e.factor.y,t.velocity.x=m.x*t.factor.x,t.velocity.y=m.y*t.factor.y}function k(e,t){return(0,r.cy)(e)?e.map((e,i)=>t(e,i)):t(e,0)}function T(e,t,i){return(0,r.cy)(e)?M(e,t,i):e}function F(e,t){return(0,r.cy)(e)?e.find((e,i)=>t(e,i)):t(e,0)?e:void 0}function _(e,t){let i=e.value,a=e.animation,n={delayTime:(0,s.VG)(a.delay)*o.Xu,enable:a.enable,value:(0,s.VG)(e.value)*t,max:(0,s.W9)(i)*t,min:(0,s.Sg)(i)*t,loops:0,maxLoops:(0,s.VG)(a.count),time:0};if(a.enable){switch(n.decay=1-(0,s.VG)(a.decay),a.mode){case l.g.increase:n.status=d.H.increasing;break;case l.g.decrease:n.status=d.H.decreasing;break;case l.g.random:n.status=(0,s.G0)()>=o.MX?d.H.increasing:d.H.decreasing}let e=a.mode===l.g.auto;switch(a.startValue){case p.S.min:n.value=n.min,e&&(n.status=d.H.increasing);break;case p.S.max:n.value=n.max,e&&(n.status=d.H.decreasing);break;case p.S.random:default:n.value=(0,s.vE)(n),e&&(n.status=(0,s.G0)()>=o.MX?d.H.increasing:d.H.decreasing)}}return n.initialValue=n.value,n}function E(e,t){if(e.mode!==h.q.percent){let{mode:t,...i}=e;return i}return"x"in e?{x:e.x/o.a5*t.width,y:e.y/o.a5*t.height}:{width:e.width/o.a5*t.width,height:e.height/o.a5*t.height}}function I(e,t){return E(e,t)}function A(e,t){return E(e,t)}function D(e,t,i,a,n){if(e.destroyed||!t.enable||(t.maxLoops??0)>0&&(t.loops??0)>(t.maxLoops??0))return;let o=(t.velocity??0)*n.factor,r=t.min,l=t.max,u=t.decay??1;if(t.time??=0,(t.delayTime??0)>0&&t.time<(t.delayTime??0)&&(t.time+=n.value),!((t.delayTime??0)>0)||!(t.time<(t.delayTime??0))){switch(t.status){case d.H.increasing:t.value>=l?(i?t.status=d.H.decreasing:t.value-=l,t.loops??=0,t.loops++):t.value+=o;break;case d.H.decreasing:t.value<=r?(i?t.status=d.H.increasing:t.value+=l,t.loops??=0,t.loops++):t.value-=o}t.velocity&&1!==u&&(t.velocity*=u);var h=t.value;switch(a){case c.V.max:h>=l&&e.destroy();break;case c.V.min:h<=r&&e.destroy()}t.value=(0,s.qE)(t.value,r,l)}}function L(e){let t=g().createElement("div").style;for(let i in e){let a=e[i];if(!Object.hasOwn(e,i)||(0,r.kZ)(a))continue;let n=e.getPropertyValue?.(a);if(!n)continue;let s=e.getPropertyPriority?.(a);s?t.setProperty(a,n,s):t.setProperty(a,n)}return t}let V=(n=function(e){let t=g().createElement("div").style,i={width:"100%",height:"100%",margin:"0",padding:"0",borderWidth:"0",position:"fixed",zIndex:e.toString(10),"z-index":e.toString(10),top:"0",left:"0"};for(let e in i){let a=i[e];void 0!==a&&t.setProperty(e,a)}return t},a=new Map,(...e)=>{let t=JSON.stringify(e);if(a.has(t))return a.get(t);let i=n(...e);return a.set(t,i),i});function C(e,t,i,a,n){if(a){let a={passive:!0};(0,r.Lm)(n)?a.capture=n:void 0!==n&&(a=n),e.addEventListener(t,i,a)}else e.removeEventListener(t,i,n)}async function $(e,t,i,a=!1){let n=t.get(e);return(!n||a)&&(n=await Promise.all([...i.values()].map(t=>t(e))),t.set(e,n)),n}async function Z(e,t,i,a=!1){let n=t.get(e);if(!n||a){for(let[t,a]of(n=new Map,await Promise.all([...i.entries()].map(async([t,i])=>[t,await i(e)]))))n.set(t,a);t.set(e,n)}return n}}},c={};function u(e){var t=c[e];if(void 0!==t)return t.exports;var i=c[e]={exports:{}};return d[e](i,i.exports,u),i.exports}u.m=d,u.d=(e,t)=>{for(var i in t)u.o(t,i)&&!u.o(e,i)&&Object.defineProperty(e,i,{enumerable:!0,get:t[i]})},u.f={},u.e=e=>Promise.all(Object.keys(u.f).reduce((t,i)=>(u.f[i](e,t),t),[])),u.u=e=>""+e+".min.js",u.g=function(){if("object"==typeof globalThis)return globalThis;try{return this||Function("return this")()}catch(e){if("object"==typeof window)return window}}(),u.o=(e,t)=>Object.prototype.hasOwnProperty.call(e,t),h={},u.l=(e,t,i,a)=>{if(h[e])return void h[e].push(t);if(void 0!==i)for(var n,s,o=document.getElementsByTagName("script"),r=0;r<o.length;r++){var l=o[r];if(l.getAttribute("src")==e||l.getAttribute("data-webpack")=="@tsparticles/engine:"+i){n=l;break}}n||(s=!0,(n=document.createElement("script")).charset="utf-8",u.nc&&n.setAttribute("nonce",u.nc),n.setAttribute("data-webpack","@tsparticles/engine:"+i),n.src=e),h[e]=[t];var d=(t,i)=>{n.onerror=n.onload=null,clearTimeout(c);var a=h[e];if(delete h[e],n.parentNode&&n.parentNode.removeChild(n),a&&a.forEach(e=>e(i)),t)return t(i)},c=setTimeout(d.bind(null,void 0,{type:"timeout",target:n}),12e4);n.onerror=d.bind(null,n.onerror),n.onload=d.bind(null,n.onload),s&&document.head.appendChild(n)},u.r=e=>{"u">typeof Symbol&&Symbol.toStringTag&&Object.defineProperty(e,Symbol.toStringTag,{value:"Module"}),Object.defineProperty(e,"__esModule",{value:!0})},u.g.importScripts&&(p=u.g.location+"");var h,p,f=u.g.document;if(!p&&f&&(f.currentScript&&"SCRIPT"===f.currentScript.tagName.toUpperCase()&&(p=f.currentScript.src),!p)){var v=f.getElementsByTagName("script");if(v.length)for(var g=v.length-1;g>-1&&(!p||!/^http(s?):/.test(p));)p=v[g--].src}if(!p)throw Error("Automatic publicPath is not supported in this browser");u.p=p=p.replace(/^blob:/,"").replace(/#.*$/,"").replace(/\?.*$/,"").replace(/\/[^\/]+$/,"/"),e={397:0},u.f.j=(t,i)=>{var a=u.o(e,t)?e[t]:void 0;if(0!==a)if(a)i.push(a[2]);else{var n=new Promise((i,n)=>a=e[t]=[i,n]);i.push(a[2]=n);var s=u.p+u.u(t),o=Error();u.l(s,i=>{if(u.o(e,t)&&(0!==(a=e[t])&&(e[t]=void 0),a)){var n=i&&("load"===i.type?"missing":i.type),s=i&&i.target&&i.target.src;o.message="Loading chunk "+t+` failed.
2
+ (`+n+": "+s+")",o.name="ChunkLoadError",o.type=n,o.request=s,a[1](o)}},"chunk-"+t,t)}},t=(t,i)=>{var a,n,[s,o,r]=i,l=0;if(s.some(t=>0!==e[t])){for(a in o)u.o(o,a)&&(u.m[a]=o[a]);r&&r(u)}for(t&&t(i);l<s.length;l++)n=s[l],u.o(e,n)&&e[n]&&e[n][0](),e[n]=0},(i=this.webpackChunk_tsparticles_engine=this.webpackChunk_tsparticles_engine||[]).forEach(t.bind(null,0)),i.push=t.bind(null,i.push.bind(i));var m={};u.r(m),u.d(m,{AlterType:()=>L.H,AnimatableColor:()=>B.A,AnimationMode:()=>E.g,AnimationOptions:()=>G.p,AnimationStatus:()=>Z.H,AnimationValueWithRandom:()=>em.Jm,Background:()=>q.V,BaseRange:()=>k.dg,Circle:()=>k.jl,ColorAnimation:()=>H.e,DestroyType:()=>V.V,EasingType:()=>l,EventType:()=>w.B,FullScreen:()=>N.m,GradientType:()=>r,HslAnimation:()=>j.i,LimitMode:()=>I.d,Move:()=>ee.y,MoveAngle:()=>et.h,MoveAttract:()=>Y.R,MoveCenter:()=>ei.Z,MoveDirection:()=>F.F,MoveGravity:()=>ea.y,MovePath:()=>es.v,Opacity:()=>ec.Y,OpacityAnimation:()=>eu.I,Options:()=>K.J,OptionsColor:()=>W.O,OutMode:()=>A.Y,OutModeDirection:()=>_.v,OutModes:()=>en.j,ParticleOutType:()=>C.x,ParticlesBounce:()=>X.w,ParticlesBounceFactor:()=>Q.F,ParticlesDensity:()=>ed.M,ParticlesNumber:()=>er.N,ParticlesNumberLimit:()=>el.A,ParticlesOptions:()=>U.U,PixelMode:()=>D.q,Point:()=>P.b,RangedAnimationOptions:()=>G.Q,RangedAnimationValueWithRandom:()=>em.AI,Rectangle:()=>k.M_,ResizeEvent:()=>eg.z,RotateDirection:()=>o,Shape:()=>eh.y,Size:()=>ep.o,SizeAnimation:()=>ef.q,Spin:()=>eo.t,StartValueType:()=>$.S,Stroke:()=>J.t,ValueWithRandom:()=>em.PV,Vector:()=>T.M,Vector3d:()=>T.p,ZIndex:()=>ev.P,alterHsl:()=>ey.yx,animate:()=>z.i0,areBoundsInside:()=>b.O2,arrayRandomIndex:()=>b.n0,calcExactPositionOrRandomFromSize:()=>z.Nx,calcExactPositionOrRandomFromSizeRanged:()=>z.qM,calcPositionFromSize:()=>z.eh,calcPositionOrRandomFromSize:()=>z.Mh,calcPositionOrRandomFromSizeRanged:()=>z.l1,calculateBounds:()=>b.AE,cancelAnimation:()=>z.px,canvasFirstIndex:()=>y.Nx,canvasTag:()=>y.RF,circleBounce:()=>b.pE,circleBounceDataFromParticle:()=>b.Tg,clamp:()=>z.qE,clear:()=>ey.IU,clickRadius:()=>y.FS,cloneStyle:()=>b.td,collisionVelocity:()=>z.OW,colorMix:()=>eb.EY,colorToHsl:()=>eb.mK,colorToRgb:()=>eb.qe,countOffset:()=>y.nq,decayOffset:()=>y.WH,deepExtend:()=>b.zw,defaultAlpha:()=>y.aZ,defaultAngle:()=>y.tA,defaultDensityFactor:()=>y.lA,defaultFps:()=>y.z$,defaultFpsLimit:()=>y.i8,defaultLoops:()=>y.hK,defaultOpacity:()=>y.hv,defaultRadius:()=>y.M1,defaultRatio:()=>y.$x,defaultReduceFactor:()=>y.Zp,defaultRemoveQuantity:()=>y.xd,defaultRetryCount:()=>y.rq,defaultRgbMin:()=>y.Fl,defaultTime:()=>y.tR,defaultTransform:()=>y.Ug,defaultTransformValue:()=>y.zs,defaultVelocity:()=>y.jn,degToRad:()=>z.pu,deleteCount:()=>y.LD,double:()=>y.gd,doublePI:()=>y.R1,drawAfterEffect:()=>ey.k,drawBeforeEffect:()=>ey.z5,drawParticle:()=>ey.p0,drawParticlePlugin:()=>ey.Wb,drawShape:()=>ey.KG,drawShapeAfterDraw:()=>ey.gF,drawShapeBeforeDraw:()=>ey.VG,empty:()=>y.Ie,executeOnSingleOrMultiple:()=>b.wJ,findItemFromSingleOrMultiple:()=>b.w3,generatedAttribute:()=>y.eb,generatedFalse:()=>y.X$,generatedTrue:()=>y.ce,getDistance:()=>z.Yf,getDistances:()=>z.vr,getFullScreenStyle:()=>b.hJ,getHslAnimationFromHsl:()=>eb.pz,getHslFromAnimation:()=>eb.O_,getItemMapFromInitializer:()=>b.Ot,getItemsFromInitializer:()=>b.HQ,getLinkColor:()=>eb._h,getLinkRandomColor:()=>eb.PG,getLogger:()=>M.t,getParticleBaseVelocity:()=>z.$m,getParticleDirectionAngle:()=>z.JY,getPosition:()=>b.E9,getRandom:()=>z.G0,getRandomInRange:()=>z.e4,getRandomRgbColor:()=>eb.OH,getRangeMax:()=>z.W9,getRangeMin:()=>z.Sg,getRangeValue:()=>z.VG,getSize:()=>b.YC,getStyleFromHsl:()=>eb.LC,getStyleFromRgb:()=>eb.xx,hMax:()=>y.vS,hMin:()=>y.L1,hPhase:()=>y.U0,half:()=>y.MX,hasMatchMedia:()=>b.q8,hslToRgb:()=>eb.YL,hslaToRgba:()=>eb.ay,identity:()=>y.D_,initParticleNumericAnimationValue:()=>b.Xs,inverseFactorNumerator:()=>y.hB,isArray:()=>ew.cy,isBoolean:()=>ew.Lm,isFunction:()=>ew.Tn,isInArray:()=>b.hn,isNull:()=>ew.kZ,isNumber:()=>ew.Et,isObject:()=>ew.Gv,isPointInside:()=>b.Tj,isString:()=>ew.Kg,itemFromArray:()=>b.Vh,itemFromSingleOrMultiple:()=>b.TA,lFactor:()=>y.iU,lMax:()=>y.$_,lMin:()=>y.vd,lengthOffset:()=>y.K3,loadMinIndex:()=>y.PZ,loadOptions:()=>ex.Z,loadParticlesOptions:()=>ex.y,loadRandomFactor:()=>y.$v,manageListener:()=>b.Kp,manualDefaultPosition:()=>y.td,midColorValue:()=>y.BW,millisecondsToSeconds:()=>y.Xu,minCoordinate:()=>y.TL,minCount:()=>y.wM,minFpsLimit:()=>y.DN,minIndex:()=>y.z9,minLimit:()=>y.ou,minRetries:()=>y.N5,minStrokeWidth:()=>y.Dv,minVelocity:()=>y.GW,minZ:()=>y.X_,minimumLength:()=>y.$O,minimumSize:()=>y.w2,mix:()=>z.jh,none:()=>y.dv,one:()=>y.xH,originPoint:()=>y.bo,paintBase:()=>ey.Sn,paintImage:()=>ey.Md,parseAlpha:()=>z.M3,percentDenominator:()=>y.a5,phaseNumerator:()=>y.BF,posOffset:()=>y.un,qTreeCapacity:()=>y.Kw,quarter:()=>y.$G,randomColorValue:()=>y.mR,randomInRangeValue:()=>z.vE,rangeColorToHsl:()=>eb.R5,rangeColorToRgb:()=>eb.BN,removeDeleteCount:()=>y.JC,removeMinIndex:()=>y.vF,resizeEvent:()=>y.NF,rgbMax:()=>y.oi,rgbToHsl:()=>eb.K6,sMax:()=>y.eu,sMin:()=>y.yx,sNormalizedOffset:()=>y.aE,safeDocument:()=>b.T5,safeIntersectionObserver:()=>b.BR,safeMatchMedia:()=>b.lV,safeMutationObserver:()=>b.tG,setAnimationFunctions:()=>z.AD,setLogger:()=>M.B,setRandom:()=>z.OE,setRangeValue:()=>z.DT,sextuple:()=>y.zg,sizeFactor:()=>y.Rh,squareExp:()=>y.dm,stringToAlpha:()=>eb.zI,stringToRgb:()=>eb.eg,subdivideCount:()=>y.Pg,threeQuarter:()=>y.Rq,touchDelay:()=>y.pH,touchEndLengthOffset:()=>y.KZ,triple:()=>y.Nu,tryCountIncrement:()=>y.Eo,tsParticles:()=>eM,updateAnimation:()=>b.UC,updateColor:()=>eb.Jv,updateColorValue:()=>eb.Ko,visibilityChangeEvent:()=>y.nK,zIndexFactorOffset:()=>y.RV});var y=u(7157),b=u(2439);class x{_listeners;constructor(){this._listeners=new Map}addEventListener(e,t){this.removeEventListener(e,t);let i=this._listeners.get(e);i||(i=[],this._listeners.set(e,i)),i.push(t)}dispatchEvent(e,t){let i=this._listeners.get(e);i?.forEach(e=>{e(t)})}hasEventListener(e){return!!this._listeners.get(e)}removeAllEventListeners(e){e?this._listeners.delete(e):this._listeners=new Map}removeEventListener(e,t){let i=this._listeners.get(e);if(!i)return;let a=i.length,n=i.indexOf(t);n<y.z9||(a===y.LD?this._listeners.delete(e):i.splice(n,y.LD))}}var w=u(6911),M=u(567),z=u(493);let S="100%";async function O(e){let t=(0,b.TA)(e.url,e.index);if(!t)return e.fallback;let i=await fetch(t);return i.ok?await i.json():((0,M.t)().error(`${i.status.toString()} while retrieving config file`),e.fallback)}class R{colorManagers=new Map;easingFunctions=new Map;effectDrawers=new Map;initializers={effects:new Map,movers:new Map,pathGenerators:new Map,shapes:new Map,updaters:new Map};movers=new Map;pathGenerators=new Map;plugins=[];presets=new Map;shapeDrawers=new Map;updaters=new Map;_allLoadersSet=new Set;_configs=new Map;_domArray=[];_eventDispatcher=new x;_executedSet=new Set;_initialized=!1;_isRunningLoaders=!1;_loadPromises=new Set;get configs(){let e={};for(let[t,i]of this._configs)e[t]=i;return e}get items(){return this._domArray}get version(){return"4.0.0-alpha.20"}addColorManager(e,t){this.colorManagers.set(e,t)}addConfig(e){let t=e.key??e.name??"default";this._configs.set(t,e),this._eventDispatcher.dispatchEvent(w.B.configAdded,{data:{name:t,config:e}})}addEasing(e,t){this.easingFunctions.get(e)||this.easingFunctions.set(e,t)}addEffect(e,t){this.initializers.effects.set(e,t)}addEventListener(e,t){this._eventDispatcher.addEventListener(e,t)}addMover(e,t){this.initializers.movers.set(e,t)}addParticleUpdater(e,t){this.initializers.updaters.set(e,t)}addPathGenerator(e,t){this.initializers.pathGenerators.set(e,t)}addPlugin(e){this.getPlugin(e.id)||this.plugins.push(e)}addPreset(e,t,i=!1){(i||!this.getPreset(e))&&this.presets.set(e,t)}addShape(e,t){for(let i of e)this.initializers.shapes.set(i,t)}checkVersion(e){if(this.version!==e)throw Error(`The tsParticles version is different from the loaded plugins version. Engine version: ${this.version}. Plugin version: ${e}`)}clearPlugins(e){this.effectDrawers.delete(e),this.movers.delete(e),this.shapeDrawers.delete(e),this.updaters.delete(e)}dispatchEvent(e,t){this._eventDispatcher.dispatchEvent(e,t)}getEasing(e){return this.easingFunctions.get(e)??(e=>e)}getEffectDrawers(e,t=!1){return(0,b.Ot)(e,this.effectDrawers,this.initializers.effects,t)}getMovers(e,t=!1){return(0,b.HQ)(e,this.movers,this.initializers.movers,t)}getPathGenerators(e,t=!1){return(0,b.Ot)(e,this.pathGenerators,this.initializers.pathGenerators,t)}getPlugin(e){return this.plugins.find(t=>t.id===e)}getPreset(e){return this.presets.get(e)}async getShapeDrawers(e,t=!1){return(0,b.Ot)(e,this.shapeDrawers,this.initializers.shapes,t)}async getUpdaters(e,t=!1){return(0,b.HQ)(e,this.updaters,this.initializers.updaters,t)}async init(){if(!this._initialized&&!this._isRunningLoaders){this._isRunningLoaders=!0,this._executedSet=new Set,this._allLoadersSet=new Set(this._loadPromises);try{for(let e of this._allLoadersSet)await this._runLoader(e,this._executedSet,this._allLoadersSet)}finally{this._loadPromises.clear(),this._isRunningLoaders=!1,this._initialized=!0}}}item(e){let{items:t}=this,i=t[e];return i?.destroyed?void t.splice(e,y.JC):i}async load(e){var t;let i,a;await this.init();let{Container:n}=await u.e(515).then(u.bind(u,5515)),s=e.id??e.element?.id??`tsparticles${Math.floor((0,z.G0)()*y.$v).toString()}`,{index:o,url:r}=e,l=r?await O({fallback:e.options,url:r,index:o}):e.options,d=(0,b.TA)(l,o),{items:c}=this,h=c.findIndex(e=>e.id.description===s),p=new n(this,s,d);if(h>=y.PZ){let e=this.item(h),t=e?y.xH:y.dv;e&&!e.destroyed&&e.destroy(!1),c.splice(h,t,p)}else c.push(p);let f=(e=>{let t,i=(0,b.T5)();if(e instanceof HTMLCanvasElement||e.tagName.toLowerCase()===y.RF)t=e,t.dataset[y.eb]??=y.X$;else{let a=e.getElementsByTagName(y.RF)[y.Nx];a?(t=a).dataset[y.eb]=y.X$:((t=i.createElement(y.RF)).dataset[y.eb]=y.ce,e.appendChild(t))}return t.style.width||=S,t.style.height||=S,t})((t=e.element,i=(0,b.T5)(),(a=t??i.getElementById(s))||((a=i.createElement("div")).id=s,a.dataset[y.eb]=y.ce,i.body.append(a)),a));return p.canvas.loadCanvas(f),await p.start(),p}loadParticlesOptions(e,t,...i){let a=this.updaters.get(e);a&&a.forEach(e=>e.loadOptions?.(t,...i))}async refresh(e=!0){e&&await Promise.all(this.items.map(e=>e.refresh()))}async register(...e){if(this._initialized)throw Error("Register plugins can only be done before calling tsParticles.load()");for(let t of e)this._isRunningLoaders?await this._runLoader(t,this._executedSet,this._allLoadersSet):this._loadPromises.add(t)}removeEventListener(e,t){this._eventDispatcher.removeEventListener(e,t)}async _runLoader(e,t,i){t.has(e)||(t.add(e),i.add(e),await e(this))}}var P=u(2714),k=u(1636),T=u(1808),F=u(3702);(a=o||(o={})).clockwise="clockwise",a.counterClockwise="counter-clockwise",a.random="random";var _=u(9890),E=u(5615),I=u(1610),A=u(3849),D=u(7917),L=u(1903),V=u(5717);(n=r||(r={})).linear="linear",n.radial="radial",n.random="random";var C=u(3457),$=u(8910);(s=l||(l={})).easeInBack="ease-in-back",s.easeInBounce="ease-in-bounce",s.easeInCirc="ease-in-circ",s.easeInCubic="ease-in-cubic",s.easeInElastic="ease-in-elastic",s.easeInExpo="ease-in-expo",s.easeInGaussian="ease-in-gaussian",s.easeInLinear="ease-in-linear",s.easeInQuad="ease-in-quad",s.easeInQuart="ease-in-quart",s.easeInQuint="ease-in-quint",s.easeInSigmoid="ease-in-sigmoid",s.easeInSine="ease-in-sine",s.easeInSmoothstep="ease-in-smoothstep",s.easeOutBack="ease-out-back",s.easeOutBounce="ease-out-bounce",s.easeOutCirc="ease-out-circ",s.easeOutCubic="ease-out-cubic",s.easeOutElastic="ease-out-elastic",s.easeOutExpo="ease-out-expo",s.easeOutGaussian="ease-out-gaussian",s.easeOutLinear="ease-out-linear",s.easeOutQuad="ease-out-quad",s.easeOutQuart="ease-out-quart",s.easeOutQuint="ease-out-quint",s.easeOutSigmoid="ease-out-sigmoid",s.easeOutSine="ease-out-sine",s.easeOutSmoothstep="ease-out-smoothstep",s.easeInOutBack="ease-in-out-back",s.easeInOutBounce="ease-in-out-bounce",s.easeInOutCirc="ease-in-out-circ",s.easeInOutCubic="ease-in-out-cubic",s.easeInOutElastic="ease-in-out-elastic",s.easeInOutExpo="ease-in-out-expo",s.easeInOutGaussian="ease-in-out-gaussian",s.easeInOutLinear="ease-in-out-linear",s.easeInOutQuad="ease-in-out-quad",s.easeInOutQuart="ease-in-out-quart",s.easeInOutQuint="ease-in-out-quint",s.easeInOutSigmoid="ease-in-out-sigmoid",s.easeInOutSine="ease-in-out-sine",s.easeInOutSmoothstep="ease-in-out-smoothstep";var Z=u(1609),B=u(2249),G=u(7896),q=u(5767),H=u(8859),N=u(1845),j=u(1311),K=u(5872),W=u(7981),X=u(5484),Q=u(1799),U=u(3068),J=u(3480),Y=u(2816),ee=u(2657),et=u(6086),ei=u(608),ea=u(2256),en=u(668),es=u(8136),eo=u(3072),er=u(2096),el=u(7537),ed=u(9829),ec=u(7089),eu=u(763),eh=u(8861),ep=u(2825),ef=u(5555),ev=u(9651),eg=u(8590),em=u(424),ey=u(1963),eb=u(6720),ex=u(9875),ew=u(3727);let eM=new R;return globalThis.tsParticles=eM,m})());
@@ -133,7 +133,7 @@ var __importStar = (this && this.__importStar) || (function () {
133
133
  return this._domArray;
134
134
  }
135
135
  get version() {
136
- return "4.0.0-alpha.18";
136
+ return "4.0.0-alpha.20";
137
137
  }
138
138
  addColorManager(name, manager) {
139
139
  this.colorManagers.set(name, manager);
package/219.min.js DELETED
@@ -1 +0,0 @@
1
- "use strict";(this.webpackChunk_tsparticles_engine=this.webpackChunk_tsparticles_engine||[]).push([[219],{3219(t,i,e){e.d(i,{Container:()=>M});var s=e(1913),a=e(7313),r=e(7927),n=e(5107),h=e(1964);function o(t,i,e=!1){if(!i)return;let s=t.style,a=new Set;for(let t=0;t<s.length;t++){let i=s.item(t);i&&a.add(i)}for(let t=0;t<i.length;t++){let e=i.item(t);e&&a.add(e)}for(let t of a){let a=i.getPropertyValue(t);a?s.setProperty(t,a,e?"important":""):s.removeProperty(t)}}class l{container;element;size;_canvasClearPlugins;_canvasPaintPlugins;_canvasSettings;_clearDrawPlugins;_colorPlugins;_context;_drawParticlePlugins;_drawParticlesCleanupPlugins;_drawParticlesSetupPlugins;_drawPlugins;_drawSettingsCleanupPlugins;_drawSettingsSetupPlugins;_engine;_generated;_mutationObserver;_originalStyle;_pointerEvents;_postDrawUpdaters;_preDrawUpdaters;_resizePlugins;_reusableColorStyles={};_reusablePluginColors=[void 0,void 0];_reusableTransform={};_standardSize;constructor(t,i){this.container=t,this._engine=i,this._standardSize={height:0,width:0};const e=t.retina.pixelRatio,s=this._standardSize;this.size={height:s.height*e,width:s.width*e},this._context=null,this._generated=!1,this._preDrawUpdaters=[],this._postDrawUpdaters=[],this._resizePlugins=[],this._colorPlugins=[],this._canvasClearPlugins=[],this._canvasPaintPlugins=[],this._clearDrawPlugins=[],this._drawParticlePlugins=[],this._drawParticlesCleanupPlugins=[],this._drawParticlesSetupPlugins=[],this._drawPlugins=[],this._drawSettingsSetupPlugins=[],this._drawSettingsCleanupPlugins=[],this._pointerEvents="none"}get settings(){return this._canvasSettings}get _fullScreen(){return this.container.actualOptions.fullScreen.enable}canvasClear(){this.container.actualOptions.clear&&this.draw(t=>{(0,r.IU)(t,this.size)})}clear(){let t=!1;for(let i of this._canvasClearPlugins)if(t=i.canvasClear?.()??!1)break;t||this.canvasClear()}destroy(){if(this.stop(),this._generated){let t=this.element;t?.remove(),this.element=void 0}else this._resetOriginalStyle();this._preDrawUpdaters=[],this._postDrawUpdaters=[],this._resizePlugins=[],this._colorPlugins=[],this._canvasClearPlugins=[],this._canvasPaintPlugins=[],this._clearDrawPlugins=[],this._drawParticlePlugins=[],this._drawParticlesCleanupPlugins=[],this._drawParticlesSetupPlugins=[],this._drawPlugins=[],this._drawSettingsSetupPlugins=[],this._drawSettingsCleanupPlugins=[]}draw(t){let i=this._context;if(i)return t(i)}drawParticle(t,i){if(t.spawning||t.destroyed)return;let e=t.getRadius();if(e<=a.w2)return;let s=t.getFillColor(),n=t.getStrokeColor()??s,[o,l]=this._getPluginParticleColors(t);if(o??=s,l??=n,!o&&!l)return;let c=this.container,d=t.options.zIndex,p=a.RV-t.zIndexFactor,{opacity:u,strokeOpacity:_}=t.getOpacity(),g=this._reusableTransform,f=this._reusableColorStyles,P=o?(0,h.LC)(o,c.hdr,u):void 0,m=l?(0,h.LC)(l,c.hdr,_):P;g.a=g.b=g.c=g.d=void 0,f.fill=P,f.stroke=m,this.draw(s=>{for(let e of this._drawParticlesSetupPlugins)e.drawParticleSetup?.(s,t,i);for(let a of(this._applyPreDrawUpdaters(s,t,e,u,f,g),(0,r.p0)({container:c,context:s,particle:t,delta:i,colorStyles:f,radius:e*p**d.sizeRate,opacity:u,transform:g}),this._applyPostDrawUpdaters(t),this._drawParticlesCleanupPlugins))a.drawParticleCleanup?.(s,t,i)})}drawParticlePlugins(t,i){this.draw(e=>{for(let s of this._drawParticlePlugins)(0,r.Wb)(e,s,t,i)})}drawParticles(t){let{particles:i}=this.container;this.clear(),i.update(t),this.draw(e=>{for(let i of this._drawSettingsSetupPlugins)i.drawSettingsSetup?.(e,t);for(let i of this._drawPlugins)i.draw?.(e,t);for(let s of(i.drawParticles(t),this._clearDrawPlugins))s.clearDraw?.(e,t);for(let i of this._drawSettingsCleanupPlugins)i.drawSettingsCleanup?.(e,t)})}init(){this._safeMutationObserver(t=>{t.disconnect()}),this._mutationObserver=(0,n.tG)(t=>{for(let i of t)"attributes"===i.type&&"style"===i.attributeName&&this._repairStyle()}),this.resize(),this._initStyle(),this.initBackground(),this._safeMutationObserver(t=>{this.element&&this.element instanceof Node&&t.observe(this.element,{attributes:!0})}),this.initUpdaters(),this.initPlugins(),this.paint()}initBackground(){let{container:t}=this,i=t.actualOptions.background,e=this.element;if(!e)return;let s=e.style,a=(0,h.BN)(this._engine,i.color);a?s.backgroundColor=(0,h.xx)(a,t.hdr,i.opacity):s.backgroundColor="",s.backgroundImage=i.image||"",s.backgroundPosition=i.position||"",s.backgroundRepeat=i.repeat||"",s.backgroundSize=i.size||""}initPlugins(){for(let t of(this._resizePlugins=[],this._colorPlugins=[],this._canvasClearPlugins=[],this._canvasPaintPlugins=[],this._clearDrawPlugins=[],this._drawParticlePlugins=[],this._drawParticlesSetupPlugins=[],this._drawParticlesCleanupPlugins=[],this._drawPlugins=[],this._drawSettingsSetupPlugins=[],this._drawSettingsCleanupPlugins=[],this.container.plugins))t.resize&&this._resizePlugins.push(t),(t.particleFillColor??t.particleStrokeColor)&&this._colorPlugins.push(t),t.canvasClear&&this._canvasClearPlugins.push(t),t.canvasPaint&&this._canvasPaintPlugins.push(t),t.drawParticle&&this._drawParticlePlugins.push(t),t.drawParticleSetup&&this._drawParticlesSetupPlugins.push(t),t.drawParticleCleanup&&this._drawParticlesCleanupPlugins.push(t),t.draw&&this._drawPlugins.push(t),t.drawSettingsSetup&&this._drawSettingsSetupPlugins.push(t),t.drawSettingsCleanup&&this._drawSettingsCleanupPlugins.push(t),t.clearDraw&&this._clearDrawPlugins.push(t)}initUpdaters(){for(let t of(this._preDrawUpdaters=[],this._postDrawUpdaters=[],this.container.particles.updaters))t.afterDraw&&this._postDrawUpdaters.push(t),(t.getColorStyles??t.getTransformValues??t.beforeDraw)&&this._preDrawUpdaters.push(t)}loadCanvas(t){this._generated&&this.element&&this.element.remove();let i=this.container;this._generated=a.eb in t.dataset?"true"===t.dataset[a.eb]:this._generated,this.element=t,this.element.ariaHidden="true",this._originalStyle=(0,n.td)(this.element.style);let e=this._standardSize;e.height=t.offsetHeight,e.width=t.offsetWidth;let s=this.container.retina.pixelRatio,r=this.size;t.height=r.height=e.height*s,t.width=r.width=e.width*s;let h=(0,n.lV)("(color-gamut: p3)");this._canvasSettings={alpha:!0,colorSpace:h?.matches&&i.hdr?"display-p3":"srgb",desynchronized:!0,willReadFrequently:!1},this._context=this.element.getContext("2d",this._canvasSettings),this._safeMutationObserver(t=>{t.disconnect()}),i.retina.init(),this.initBackground(),this._safeMutationObserver(t=>{this.element&&this.element instanceof Node&&t.observe(this.element,{attributes:!0})})}paint(){let t=!1;for(let i of this._canvasPaintPlugins)if(t=i.canvasPaint?.()??!1)break;t||this.paintBase()}paintBase(t){this.draw(i=>{(0,r.Sn)(i,this.size,t)})}paintImage(t,i){this.draw(e=>{(0,r.Md)(e,this.size,t,i)})}resize(){if(!this.element)return!1;let t=this.container,i=t.canvas._standardSize,e={width:this.element.offsetWidth,height:this.element.offsetHeight},s=t.retina.pixelRatio,a={width:e.width*s,height:e.height*s};if(e.height===i.height&&e.width===i.width&&a.height===this.element.height&&a.width===this.element.width)return!1;let r={...i};i.height=e.height,i.width=e.width;let n=this.size;return this.element.width=n.width=a.width,this.element.height=n.height=a.height,this.container.started&&t.particles.setResizeFactor({width:i.width/r.width,height:i.height/r.height}),!0}setPointerEvents(t){this.element&&(this._pointerEvents=t,this._repairStyle())}stop(){this._safeMutationObserver(t=>{t.disconnect()}),this._mutationObserver=void 0,this.draw(t=>{(0,r.IU)(t,this.size)})}async windowResize(){if(!this.element||!this.resize())return;let t=this.container,i=t.updateActualOptions();t.particles.setDensity(),this._applyResizePlugins(),i&&await t.refresh()}_applyPostDrawUpdaters=t=>{for(let i of this._postDrawUpdaters)i.afterDraw?.(t)};_applyPreDrawUpdaters=(t,i,e,s,r,n)=>{for(let h of this._preDrawUpdaters){if(h.getColorStyles){let{fill:a,stroke:n}=h.getColorStyles(i,t,e,s);a&&(r.fill=a),n&&(r.stroke=n)}if(h.getTransformValues){let t=h.getTransformValues(i);for(let i in t)!function(t,i,e){let s=i[e];void 0!==s&&(t[e]=(t[e]??a.zs)*s)}(n,t,i)}h.beforeDraw?.(i)}};_applyResizePlugins=()=>{for(let t of this._resizePlugins)t.resize?.()};_getPluginParticleColors=t=>{let i,e;for(let s of this._colorPlugins)if(!i&&s.particleFillColor&&(i=(0,h.R5)(this._engine,s.particleFillColor(t))),!e&&s.particleStrokeColor&&(e=(0,h.R5)(this._engine,s.particleStrokeColor(t))),i&&e)break;return this._reusablePluginColors[0]=i,this._reusablePluginColors[1]=e,this._reusablePluginColors};_initStyle=()=>{let t=this.element,i=this.container.actualOptions;if(t)for(let e in this._fullScreen?this._setFullScreenStyle():this._resetOriginalStyle(),i.style){if(!e||!Object.hasOwn(i.style,e))continue;let s=i.style[e];s&&t.style.setProperty(e,s,"important")}};_repairStyle=()=>{let t=this.element;if(!t)return;this._safeMutationObserver(t=>{t.disconnect()}),this._initStyle(),this.initBackground();let i=this._pointerEvents;t.style.pointerEvents=i,t.setAttribute("pointer-events",i),this._safeMutationObserver(i=>{t instanceof Node&&i.observe(t,{attributes:!0})})};_resetOriginalStyle=()=>{let t=this.element,i=this._originalStyle;t&&i&&o(t,i,!0)};_safeMutationObserver=t=>{this._mutationObserver&&t(this._mutationObserver)};_setFullScreenStyle=()=>{let t=this.element;t&&o(t,(0,n.hJ)(this.container.actualOptions.fullScreen.zIndex),!0)}}class c{container;_handlers;_resizeObserver;_resizeTimeout;constructor(t){this.container=t,this._handlers={visibilityChange:()=>{this._handleVisibilityChange()},resize:()=>{this._handleWindowResize()}}}addListeners(){this._manageListeners(!0)}removeListeners(){this._manageListeners(!1)}_handleVisibilityChange=()=>{let t=this.container;t.actualOptions.pauseOnBlur&&((0,n.T5)().hidden?(t.pageHidden=!0,t.pause()):(t.pageHidden=!1,t.animationStatus?t.play(!0):t.draw(!0)))};_handleWindowResize=()=>{this._resizeTimeout&&(clearTimeout(this._resizeTimeout),delete this._resizeTimeout);let t=async()=>{let t=this.container.canvas;await t.windowResize()};this._resizeTimeout=setTimeout(()=>void t(),this.container.actualOptions.resize.delay*a.Xu)};_manageListeners=t=>{let i=this._handlers;this._manageResize(t),(0,n.Kp)(document,a.nK,i.visibilityChange,t,!1)};_manageResize=t=>{let i=this._handlers,e=this.container;if(!e.actualOptions.resize.enable)return;if("u"<typeof ResizeObserver)return void(0,n.Kp)(globalThis,a.NF,i.resize,t);let s=e.canvas.element;this._resizeObserver&&!t?(s&&this._resizeObserver.unobserve(s),this._resizeObserver.disconnect(),delete this._resizeObserver):!this._resizeObserver&&t&&s&&(this._resizeObserver=new ResizeObserver(t=>{t.find(t=>t.target===s)&&this._handleWindowResize()}),this._resizeObserver.observe(s))}}var d=e(299),p=e(6996),u=e(5398),_=e(2740),g=e(546),f=e(5045),P=e(8405),m=e(2679);function y(t){if(!(0,n.hn)(t.outMode,t.checkModes))return;let i=t.radius*a.gd;t.coord>t.maxCoord-i?t.setCb(-t.radius):t.coord<i&&t.setCb(t.radius)}class w{container;backColor;bubble;color;destroyed;direction;effect;effectClose;effectData;effectFill;group;id;ignoresResizeRatio;initialPosition;initialVelocity;isRotating;lastPathTime;misplaced;moveCenter;moveDecay;offset;opacity;options;outType;pathDelay;pathGenerator;pathRotation;position;randomIndexData;retina;roll;rotation;shape;shapeClose;shapeData;shapeFill;sides;size;slow;spawning;strokeColor;strokeOpacity;strokeWidth;unbreakable;velocity;zIndexFactor;_cachedOpacityData={opacity:a.hv,strokeOpacity:a.hv};_cachedPosition=_.p.origin;_cachedRotateData={sin:0,cos:0};_cachedTransform={a:1,b:0,c:0,d:1};_engine;constructor(t,i){this.container=i,this._engine=t}destroy(t){if(this.unbreakable||this.destroyed)return;this.destroyed=!0,this.bubble.inRange=!1,this.slow.inRange=!1;let i=this.container,e=this.pathGenerator,s=this.shape?i.particles.shapeDrawers.get(this.shape):void 0;for(let e of(s?.particleDestroy?.(this),i.particleDestroyedPlugins))e.particleDestroyed?.(this,t);for(let e of i.particles.updaters)e.particleDestroyed?.(this,t);e?.reset(this),this._engine.dispatchEvent(d.B.particleDestroyed,{container:this.container,data:{particle:this}})}draw(t){let i=this.container.canvas;i.drawParticlePlugins(this,t),i.drawParticle(this,t)}getAngle(){return this.rotation+(this.pathRotation?this.velocity.angle:a.tA)}getFillColor(){return this._getRollColor(this.bubble.color??(0,h.O_)(this.color))}getMass(){return this.getRadius()**a.dm*Math.PI*a.MX}getOpacity(){let t=this.options.zIndex,i=a.RV-this.zIndexFactor,e=i**t.opacityRate,r=this.bubble.opacity??(0,s.VG)(this.opacity?.value??a.hv),n=this.strokeOpacity??r;return this._cachedOpacityData.opacity=r*e,this._cachedOpacityData.strokeOpacity=n*e,this._cachedOpacityData}getPosition(){return this._cachedPosition.x=this.position.x+this.offset.x,this._cachedPosition.y=this.position.y+this.offset.y,this._cachedPosition.z=this.position.z,this._cachedPosition}getRadius(){return this.bubble.radius??this.size.value}getRotateData(){let t=this.getAngle();return this._cachedRotateData.sin=Math.sin(t),this._cachedRotateData.cos=Math.cos(t),this._cachedRotateData}getStrokeColor(){return this._getRollColor(this.bubble.color??(0,h.O_)(this.strokeColor))}getTransformData(t){let i=this.getRotateData(),e=this.isRotating;return this._cachedTransform.a=i.cos*(t.a??a.Ug.a),this._cachedTransform.b=e?i.sin*(t.b??a.D_):t.b??a.Ug.b,this._cachedTransform.c=e?-i.sin*(t.c??a.D_):t.c??a.Ug.c,this._cachedTransform.d=i.cos*(t.d??a.Ug.d),this._cachedTransform}init(t,i,e,r){var h,o,l,c;let d,p,u,_,g=this.container;this.id=t,this.group=r,this.effectClose=!0,this.effectFill=!0,this.shapeClose=!0,this.shapeFill=!0,this.pathRotation=!1,this.lastPathTime=0,this.destroyed=!1,this.unbreakable=!1,this.isRotating=!1,this.rotation=0,this.misplaced=!1,this.retina={maxDistance:{}},this.outType=P.x.normal,this.ignoresResizeRatio=!0;let f=g.retina.pixelRatio,y=g.actualOptions,w=(0,m.y)(this._engine,g,y.particles),v=w.reduceDuplicates,b=w.effect.type,z=w.shape.type;this.effect=(0,n.TA)(b,this.id,v),this.shape=(0,n.TA)(z,this.id,v);let S=w.effect,C=w.shape;if(e){if(e.effect?.type){let t=e.effect.type,i=(0,n.TA)(t,this.id,v);i&&(this.effect=i,S.load(e.effect))}if(e.shape?.type){let t=e.shape.type,i=(0,n.TA)(t,this.id,v);i&&(this.shape=i,C.load(e.shape))}}if(this.effect===a.mR){let t=[...this.container.particles.effectDrawers.keys()];this.effect=t[Math.floor((0,s.G0)()*t.length)]}if(this.shape===a.mR){let t=[...this.container.particles.shapeDrawers.keys()];this.shape=t[Math.floor((0,s.G0)()*t.length)]}this.effectData=this.effect?(h=this.effect,o=this.id,u=S.options[h],(0,n.zw)({close:S.close,fill:S.fill},(0,n.TA)(u,o,v))):void 0,this.shapeData=this.shape?(l=this.shape,c=this.id,_=C.options[l],(0,n.zw)({close:C.close,fill:C.fill},(0,n.TA)(_,c,v))):void 0,w.load(e);let D=this.effectData;D&&w.load(D.particles);let x=this.shapeData;x&&w.load(x.particles),this.effectFill=D?.fill??w.effect.fill,this.effectClose=D?.close??w.effect.close,this.shapeFill=x?.fill??w.shape.fill,this.shapeClose=x?.close??w.shape.close,this.options=w;let R=this.options.move.path;if(this.pathDelay=(0,s.VG)(R.delay.value)*a.Xu,R.generator){let t=this.container.particles.pathGenerators.get(R.generator);!t&&(t=this.container.particles.availablePathGenerators.get(R.generator))&&(this.container.particles.pathGenerators.set(R.generator,t),t.init()),this.pathGenerator=t}g.retina.initParticle(this),this.size=(0,n.Xs)(this.options.size,f),this.bubble={inRange:!1},this.slow={inRange:!1,factor:1},this._initPosition(i),this.initialVelocity=this._calculateVelocity(),this.velocity=this.initialVelocity.copy(),this.moveDecay=a.WH-(0,s.VG)(this.options.move.decay);let O=g.particles;O.setLastZIndex(this.position.z),this.zIndexFactor=this.position.z/g.zLayers,this.sides=24,this.effect&&(d=g.particles.effectDrawers.get(this.effect)),d?.loadEffect&&d.loadEffect(this),this.shape&&(p=g.particles.shapeDrawers.get(this.shape)),p?.loadShape&&p.loadShape(this);let M=p?.getSidesCount;for(let t of(M&&(this.sides=M(this)),this.spawning=!1,O.updaters))t.init(this);for(let t of O.movers)t.init(this);for(let t of(d?.particleInit?.(g,this),p?.particleInit?.(g,this),g.particleCreatedPlugins))t.particleCreated?.(this)}isInsideCanvas(){let t=this.getRadius(),i=this.container.canvas.size,e=this.position;return e.x>=-t&&e.y>=-t&&e.y<=i.height+t&&e.x<=i.width+t}isShowingBack(){if(!this.roll)return!1;let t=this.roll.angle;if(this.roll.horizontal&&this.roll.vertical){let i=t%a.R1,e=i<a.tA?i+a.R1:i;return e>=Math.PI*a.MX&&e<Math.PI*a.Nu*a.MX}if(this.roll.horizontal){let i=(t+Math.PI*a.MX)%(Math.PI*a.gd),e=i<a.tA?i+Math.PI*a.gd:i;return e>=Math.PI&&e<Math.PI*a.gd}if(this.roll.vertical){let i=t%(Math.PI*a.gd),e=i<a.tA?i+Math.PI*a.gd:i;return e>=Math.PI&&e<Math.PI*a.gd}return!1}isVisible(){return!this.destroyed&&!this.spawning&&this.isInsideCanvas()}reset(){for(let t of this.container.particles.updaters)t.reset?.(this)}_calcPosition=(t,i)=>{let e=a.rq,r=t?_.p.create(t.x,t.y,i):void 0,n=this.container,h=n.particlePositionPlugins,o=this.options.move.outModes,l=this.getRadius(),c=n.canvas.size,{signal:d}=new AbortController;for(;!d.aborted;){for(let t of h){let e=t.particlePosition?.(r,this);if(e)return _.p.create(e.x,e.y,i)}let t=(0,s.Nx)({size:c,position:r}),d=_.p.create(t.x,t.y,i);this._fixHorizontal(d,l,o.left??o.default),this._fixHorizontal(d,l,o.right??o.default),this._fixVertical(d,l,o.top??o.default),this._fixVertical(d,l,o.bottom??o.default);let p=!0;for(let t of n.particles.checkParticlePositionPlugins)if(!(p=t.checkParticlePosition?.(this,d,e)??!0))break;if(p)return d;e+=a.Eo,r=void 0}return r};_calculateVelocity=()=>{let t=(0,s.$m)(this.direction).copy(),i=this.options.move;if(i.direction===g.F.inside||i.direction===g.F.outside)return t;let e=(0,s.pu)((0,s.VG)(i.angle.value)),r=(0,s.pu)((0,s.VG)(i.angle.offset)),n={left:r-e*a.MX,right:r+e*a.MX};return i.straight||(t.angle+=(0,s.vE)((0,s.DT)(n.left,n.right))),i.random&&"number"==typeof i.speed&&(t.length*=(0,s.G0)()),t};_fixHorizontal=(t,i,e)=>{y({outMode:e,checkModes:[f.Y.bounce],coord:t.x,maxCoord:this.container.canvas.size.width,setCb:i=>t.x+=i,radius:i})};_fixVertical=(t,i,e)=>{y({outMode:e,checkModes:[f.Y.bounce],coord:t.y,maxCoord:this.container.canvas.size.height,setCb:i=>t.y+=i,radius:i})};_getRollColor=t=>t&&this.roll&&(this.backColor||this.roll.alter)&&this.isShowingBack()?this.backColor?this.backColor:this.roll.alter?(0,r.yx)(t,this.roll.alter.type,this.roll.alter.value):t:t;_initPosition=t=>{let i=this.container,e=(0,s.VG)(this.options.zIndex.value),r=this._calcPosition(t,(0,s.qE)(e,a.X_,i.zLayers));if(!r)throw Error("a valid position cannot be found for particle");this.position=r,this.initialPosition=this.position.copy();let h=i.canvas.size;switch(this.moveCenter={...(0,n.E9)(this.options.move.center,h),radius:this.options.move.center.radius,mode:this.options.move.center.mode},this.direction=(0,s.JY)(this.options.move.direction,this.position,this.moveCenter),this.options.move.direction){case g.F.inside:this.outType=P.x.inside;break;case g.F.outside:this.outType=P.x.outside}this.offset=_.M.origin}}var v=e(8150),b=e(5668);class z{rectangle;capacity;_divided;_points;_subs;constructor(t,i){this.rectangle=t,this.capacity=i,this._points=[],this._divided=!1,this._subs=[]}insert(t){return!!this.rectangle.contains(t.position)&&(this._points.length<this.capacity?(this._points.push(t),!0):(this._divided||this._subdivide(),this._subs.some(i=>i.insert(t))))}query(t,i){let e=[];if(!t.intersects(this.rectangle))return[];for(let a of this._points)!t.contains(a.position)&&(0,s.Yf)(t.position,a.position)>a.particle.getRadius()&&(!i||i(a.particle))||e.push(a.particle);if(this._divided)for(let s of this._subs)e.push(...s.query(t,i));return e}queryCircle(t,i,e){return this.query(new b.jl(t.x,t.y,i),e)}queryRectangle(t,i,e){return this.query(new b.M_(t.x,t.y,i.width,i.height),e)}_subdivide=()=>{let{x:t,y:i}=this.rectangle.position,{width:e,height:s}=this.rectangle.size,{capacity:r}=this;for(let n=0;n<a.Pg;n++){let h=n%a.gd;this._subs.push(new z(new b.M_(t+e*a.MX*h,i+s*a.MX*(Math.round(n*a.MX)-h),e*a.MX,s*a.MX),r))}this._divided=!0}}var S=e(8963);let C=t=>{let{height:i,width:e}=t;return new b.M_(a.un*e,a.un*i,a.Rh*e,a.Rh*i)};class D{availablePathGenerators;checkParticlePositionPlugins;effectDrawers;movers;pathGenerators;quadTree;shapeDrawers;updaters;_array;_container;_engine;_groupLimits;_limit;_maxZIndex;_minZIndex;_needsSort;_nextId;_particleResetPlugins;_particleUpdatePlugins;_pool;_postParticleUpdatePlugins;_postUpdatePlugins;_resizeFactor;_updatePlugins;_zArray;constructor(t,i){this._engine=t,this._container=i,this._nextId=0,this._array=[],this._zArray=[],this._pool=[],this._limit=0,this._groupLimits=new Map,this._needsSort=!1,this._minZIndex=0,this._maxZIndex=0;const e=i.canvas.size;this.quadTree=new z(C(e),a.Kw),this.effectDrawers=new Map,this.movers=[],this.availablePathGenerators=new Map,this.pathGenerators=new Map,this.shapeDrawers=new Map,this.updaters=[],this.checkParticlePositionPlugins=[],this._particleResetPlugins=[],this._particleUpdatePlugins=[],this._postUpdatePlugins=[],this._postParticleUpdatePlugins=[],this._updatePlugins=[]}get count(){return this._array.length}addParticle(t,i,e,s){let r=this._container.actualOptions.particles.number.limit.mode,n=void 0===e?this._limit:this._groupLimits.get(e)??this._limit,h=this.count;if(n>a.ou)switch(r){case u.d.delete:{let t=h+a.nq-n;t>a.wM&&this.removeQuantity(t);break}case u.d.wait:if(h>=n)return}try{let a=this._pool.pop()??new w(this._engine,this._container);a.init(this._nextId,t,i,e);let r=!0;if(s&&(r=s(a)),!r)return void this._pool.push(a);return this._array.push(a),this._zArray.push(a),this._nextId++,this._engine.dispatchEvent(d.B.particleAdded,{container:this._container,data:{particle:a}}),a}catch(t){(0,S.t)().warning(`error adding particle: ${t}`)}}clear(){this._array=[],this._zArray=[]}destroy(){let t=this._container;for(let[,i]of this.effectDrawers)i.destroy?.(t);for(let[,i]of this.shapeDrawers)i.destroy?.(t);this._array=[],this._pool.length=0,this._zArray=[],this.effectDrawers=new Map,this.movers=[],this.availablePathGenerators=new Map,this.pathGenerators=new Map,this.shapeDrawers=new Map,this.updaters=[],this.checkParticlePositionPlugins=[],this._particleResetPlugins=[],this._particleUpdatePlugins=[],this._postUpdatePlugins=[],this._postParticleUpdatePlugins=[],this._updatePlugins=[]}drawParticles(t){for(let i of this._zArray)i.draw(t)}filter(t){return this._array.filter(t)}find(t){return this._array.find(t)}get(t){return this._array[t]}async init(){let t=this._container,i=t.actualOptions;for(let i of(this._minZIndex=0,this._maxZIndex=0,this._needsSort=!1,this.checkParticlePositionPlugins=[],this._updatePlugins=[],this._particleUpdatePlugins=[],this._postUpdatePlugins=[],this._particleResetPlugins=[],this._postParticleUpdatePlugins=[],t.plugins))i.redrawInit&&await i.redrawInit(),i.checkParticlePosition&&this.checkParticlePositionPlugins.push(i),i.update&&this._updatePlugins.push(i),i.particleUpdate&&this._particleUpdatePlugins.push(i),i.postUpdate&&this._postUpdatePlugins.push(i),i.particleReset&&this._particleResetPlugins.push(i),i.postParticleUpdate&&this._postParticleUpdatePlugins.push(i);for(let i of(await this.initPlugins(),this.effectDrawers.values()))await i.init?.(t);for(let i of this.shapeDrawers.values())await i.init?.(t);let e=!1;for(let i of t.plugins)if(e=i.particlesInitialization?.()??e)break;if(!e){let t=i.particles,e=t.groups;for(let i in e){let s=e[i];if(s)for(let e=this.count,a=0;a<s.number.value&&e<t.number.value;e++,a++)this.addParticle(void 0,s,i)}for(let i=this.count;i<t.number.value;i++)this.addParticle()}}async initPlugins(){let t=this._container;for(let i of(this.effectDrawers=await this._engine.getEffectDrawers(t,!0),this.movers=await this._engine.getMovers(t,!0),this.availablePathGenerators=await this._engine.getPathGenerators(t,!0),this.pathGenerators=new Map,this.shapeDrawers=await this._engine.getShapeDrawers(t,!0),this.updaters=await this._engine.getUpdaters(t,!0),this.pathGenerators.values()))i.init()}push(t,i,e,s){for(let a=0;a<t;a++)this.addParticle(i,e,s)}async redraw(){this.clear(),await this.init(),this._container.canvas.drawParticles({value:0,factor:0})}remove(t,i,e){this.removeAt(this._array.indexOf(t),void 0,i,e)}removeAt(t,i=a.xd,e,s){if(t<a.z9||t>this.count)return;let r=0;for(let a=t;r<i&&a<this.count;a++)this._removeParticle(a,e,s)&&(a--,r++)}removeQuantity(t,i){this.removeAt(a.z9,t,i)}setDensity(){let t=this._container.actualOptions,i=t.particles.groups,e=0;for(let t of this._container.plugins)t.particlesDensityCount&&(e+=t.particlesDensityCount());for(let t in i){let s=i[t];if(!s)continue;let a=(0,m.y)(this._engine,this._container,s);this._applyDensity(a,e,t)}this._applyDensity(t.particles,e)}setLastZIndex(t){this._needsSort||=t>=this._maxZIndex||t>this._minZIndex&&t<this._maxZIndex}setResizeFactor(t){this._resizeFactor=t}update(t){let i=this._container,e=new Set;for(let t of(this.quadTree=new z(C(i.canvas.size),a.Kw),this.pathGenerators.values()))t.update();for(let i of this._updatePlugins)i.update?.(t);let s=this._resizeFactor;for(let i of this._array){for(let t of(s&&!i.ignoresResizeRatio&&(i.position.x*=s.width,i.position.y*=s.height,i.initialPosition.x*=s.width,i.initialPosition.y*=s.height),i.ignoresResizeRatio=!1,this._particleResetPlugins))t.particleReset?.(i);for(let e of this._particleUpdatePlugins){if(i.destroyed)break;e.particleUpdate?.(i,t)}for(let e of this.movers)e.isEnabled(i)&&e.move(i,t);if(i.destroyed){e.add(i);continue}this.quadTree.insert(new v.b(i.getPosition(),i))}if(e.size){let t=t=>!e.has(t);for(let i of(this._array=this.filter(t),this._zArray=this._zArray.filter(t),e))this._engine.dispatchEvent(d.B.particleRemoved,{container:this._container,data:{particle:i}});this._addToPool(...e)}for(let i of this._postUpdatePlugins)i.postUpdate?.(t);for(let i of this._array){for(let e of this.updaters)e.update(i,t);if(!i.destroyed&&!i.spawning)for(let e of this._postParticleUpdatePlugins)e.postParticleUpdate?.(i,t)}if(delete this._resizeFactor,this._needsSort){let t=this._zArray;t.sort((t,i)=>i.position.z-t.position.z||t.id-i.id);let i=t[a.z9],e=t[t.length-a.K3];if(!i||!e)return;this._maxZIndex=i.position.z,this._minZIndex=e.position.z,this._needsSort=!1}}_addToPool=(...t)=>{this._pool.push(...t)};_applyDensity=(t,i,e,s)=>{let r=t.number;if(!r.density.enable)return void(void 0===e?this._limit=r.limit.value:(s?.number.limit.value??r.limit.value)&&this._groupLimits.set(e,s?.number.limit.value??r.limit.value));let n=this._initDensityFactor(r.density),h=r.value,o=r.limit.value>a.ou?r.limit.value:h,l=Math.min(h,o)*n+i,c=Math.min(this.count,this.filter(t=>t.group===e).length);void 0===e?this._limit=r.limit.value*n:this._groupLimits.set(e,r.limit.value*n),c<l?this.push(Math.abs(l-c),void 0,t,e):c>l&&this.removeQuantity(c-l,e)};_initDensityFactor=t=>{let i=this._container;if(!i.canvas.element||!t.enable)return a.lA;let e=i.canvas.element,s=i.retina.pixelRatio;return e.width*e.height/(t.height*t.width*s**a.dm)};_removeParticle=(t,i,e)=>{let s=this._array[t];if(!s||s.group!==i)return!1;let r=this._zArray.indexOf(s);return this._array.splice(t,a.LD),this._zArray.splice(r,a.LD),s.destroy(e),this._engine.dispatchEvent(d.B.particleRemoved,{container:this._container,data:{particle:s}}),this._addToPool(s),!0}}class x{container;maxSpeed;pixelRatio;reduceFactor;sizeAnimationSpeed;constructor(t){this.container=t,this.pixelRatio=a.$x,this.reduceFactor=a.Zp}init(){let t=this.container,i=t.actualOptions;this.pixelRatio=i.detectRetina?devicePixelRatio:a.$x,this.reduceFactor=a.Zp;let e=this.pixelRatio,r=t.canvas;if(r.element){let t=r.element;r.size.width=t.offsetWidth*e,r.size.height=t.offsetHeight*e}let n=i.particles,h=n.move;this.maxSpeed=(0,s.VG)(h.gravity.maxSpeed)*e,this.sizeAnimationSpeed=(0,s.VG)(n.size.animation.speed)*e}initParticle(t){let i=t.options,e=this.pixelRatio,a=i.move,r=a.distance,n=t.retina;n.moveDrift=(0,s.VG)(a.drift)*e,n.moveSpeed=(0,s.VG)(a.speed)*e,n.sizeAnimationSpeed=(0,s.VG)(i.size.animation.speed)*e;let h=n.maxDistance;h.horizontal=void 0!==r.horizontal?r.horizontal*e:void 0,h.vertical=void 0!==r.vertical?r.vertical*e:void 0,n.maxSpeed=(0,s.VG)(a.gravity.maxSpeed)*e}}function R(t){return!t.destroyed}function O(t,i,...e){let s=new p.J(t,i);return(0,m.Z)(s,...e),s}class M{actualOptions;canvas;destroyed;fpsLimit;hdr;id;pageHidden;particleCreatedPlugins;particleDestroyedPlugins;particlePositionPlugins;particles;plugins;retina;started;zLayers;_delay;_delayTimeout;_delta={value:0,factor:0};_drawAnimationFrame;_duration;_engine;_eventListeners;_firstStart;_initialSourceOptions;_lastFrameTime;_lifeTime;_options;_paused;_smooth;_sourceOptions;constructor(t,i,e){this._engine=t,this.id=Symbol(i),this.fpsLimit=120,this.hdr=!1,this._smooth=!1,this._delay=0,this._duration=0,this._lifeTime=0,this._firstStart=!0,this.started=!1,this.destroyed=!1,this._paused=!0,this._lastFrameTime=0,this.zLayers=100,this.pageHidden=!1,this._sourceOptions=e,this._initialSourceOptions=e,this.retina=new x(this),this.canvas=new l(this,this._engine),this.particles=new D(this._engine,this),this.plugins=[],this.particleDestroyedPlugins=[],this.particleCreatedPlugins=[],this.particlePositionPlugins=[],this._options=O(this._engine,this),this.actualOptions=O(this._engine,this),this._eventListeners=new c(this),this._engine.dispatchEvent(d.B.containerBuilt,{container:this})}get animationStatus(){return!this._paused&&!this.pageHidden&&R(this)}get options(){return this._options}get sourceOptions(){return this._sourceOptions}addLifeTime(t){this._lifeTime+=t}alive(){return!this._duration||this._lifeTime<=this._duration}destroy(t=!0){if(R(this)){for(let t of(this.stop(),this.particles.destroy(),this.canvas.destroy(),this.plugins))t.destroy?.();if(this.plugins.length=0,this._engine.clearPlugins(this),this.destroyed=!0,t){let t=this._engine.items,i=t.indexOf(this);i>=a.vF&&t.splice(i,a.JC)}this._engine.dispatchEvent(d.B.containerDestroyed,{container:this})}}draw(t){if(!R(this))return;let i=t,e=t=>{i&&(this._lastFrameTime=void 0,i=!1),this._nextFrame(t)};this._drawAnimationFrame=(0,s.i0)(t=>{e(t)})}async export(t,i={}){for(let e of this.plugins){if(!e.export)continue;let s=await e.export(t,i);if(s.supported)return s.blob}(0,S.t)().error(`Export plugin with type ${t} not found`)}async init(){if(!R(this))return;let t=new Map;for(let i of this._engine.plugins){let e=await i.getPlugin(this);e.preInit&&await e.preInit(),t.set(i,e)}for(let[i,e]of(await this.particles.initPlugins(),this._options=O(this._engine,this,this._initialSourceOptions,this.sourceOptions),this.actualOptions=O(this._engine,this,this._options),this.plugins.length=0,this.particleDestroyedPlugins.length=0,this.particleCreatedPlugins.length=0,this.particlePositionPlugins.length=0,t))i.needsPlugin(this.actualOptions)&&(this.plugins.push(e),e.particleCreated&&this.particleCreatedPlugins.push(e),e.particleDestroyed&&this.particleDestroyedPlugins.push(e),e.particlePosition&&this.particlePositionPlugins.push(e));this.retina.init(),this.canvas.init(),this.updateActualOptions(),this.canvas.initBackground(),this.canvas.resize();let{delay:i,duration:e,fpsLimit:r,hdr:n,smooth:h,zLayers:o}=this.actualOptions;for(let t of(this.hdr=n,this.zLayers=o,this._duration=(0,s.VG)(e)*a.Xu,this._delay=(0,s.VG)(i)*a.Xu,this._lifeTime=0,this.fpsLimit=r>a.DN?r:a.i8,this._smooth=h,this.plugins))await t.init?.();for(let t of(await this.particles.init(),this._engine.dispatchEvent(d.B.containerInit,{container:this}),this.particles.setDensity(),this.plugins))t.particlesSetup?.();this._engine.dispatchEvent(d.B.particlesSetup,{container:this})}pause(){if(R(this)&&(void 0!==this._drawAnimationFrame&&((0,s.px)(this._drawAnimationFrame),delete this._drawAnimationFrame),!this._paused)){for(let t of this.plugins)t.pause?.();this.pageHidden||(this._paused=!0),this._engine.dispatchEvent(d.B.containerPaused,{container:this})}}play(t){if(!R(this))return;let i=this._paused||t;if(this._firstStart&&!this.actualOptions.autoPlay){this._firstStart=!1;return}if(this._paused&&(this._paused=!1),i)for(let t of this.plugins)t.play&&t.play();this._engine.dispatchEvent(d.B.containerPlay,{container:this}),this.draw(i??!1)}async refresh(){if(R(this))return this.stop(),this.start()}async reset(t){if(R(this))return this._initialSourceOptions=t,this._sourceOptions=t,this._options=O(this._engine,this,this._initialSourceOptions,this.sourceOptions),this.actualOptions=O(this._engine,this,this._options),this.refresh()}async start(){R(this)&&!this.started&&(await this.init(),this.started=!0,await new Promise(t=>{let i=async()=>{for(let t of(this._eventListeners.addListeners(),this.plugins))await t.start?.();this._engine.dispatchEvent(d.B.containerStarted,{container:this}),this.play(),t()};this._delayTimeout=setTimeout(()=>void i(),this._delay)}))}stop(){if(R(this)&&this.started){for(let t of(this._delayTimeout&&(clearTimeout(this._delayTimeout),delete this._delayTimeout),this._firstStart=!0,this.started=!1,this._eventListeners.removeListeners(),this.pause(),this.particles.clear(),this.canvas.stop(),this.plugins))t.stop?.();this.particleCreatedPlugins.length=0,this.particleDestroyedPlugins.length=0,this.particlePositionPlugins.length=0,this._sourceOptions=this._options,this._engine.dispatchEvent(d.B.containerStopped,{container:this})}}updateActualOptions(){let t=!1;for(let i of this.plugins)i.updateActualOptions&&(t=i.updateActualOptions()||t);return t}_nextFrame=t=>{try{if(!this._smooth&&void 0!==this._lastFrameTime&&t<this._lastFrameTime+a.Xu/this.fpsLimit||(this._lastFrameTime??=t,!function(t,i,e=a.z$,s=!1){t.value=i,t.factor=s?a.z$/e:a.z$*i/a.Xu}(this._delta,t-this._lastFrameTime,this.fpsLimit,this._smooth),this.addLifeTime(this._delta.value),this._lastFrameTime=t,this._delta.value>a.Xu))return void this.draw(!1);if(this.canvas.drawParticles(this._delta),!this.alive())return void this.destroy();this.animationStatus&&this.draw(!1)}catch(t){(0,S.t)().error("error in animation loop",t)}}}}}]);