tsparticles 1.40.2 → 1.41.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/Core/Container.d.ts +1 -1
- package/Core/Container.js +7 -21
- package/browser/Core/Container.d.ts +1 -1
- package/browser/Core/Container.js +7 -21
- package/esm/Core/Container.d.ts +1 -1
- package/esm/Core/Container.js +7 -21
- package/package.json +1 -1
- package/report.html +2 -2
- package/report.slim.html +2 -2
- package/tsparticles.engine.js +7 -21
- package/tsparticles.engine.min.js +2 -2
- package/tsparticles.interaction.external.attract.js +7 -21
- package/tsparticles.interaction.external.attract.min.js +1 -1
- package/tsparticles.interaction.external.bounce.js +7 -21
- package/tsparticles.interaction.external.bounce.min.js +1 -1
- package/tsparticles.interaction.external.bubble.js +7 -21
- package/tsparticles.interaction.external.bubble.min.js +1 -1
- package/tsparticles.interaction.external.connect.js +7 -21
- package/tsparticles.interaction.external.connect.min.js +1 -1
- package/tsparticles.interaction.external.grab.js +7 -21
- package/tsparticles.interaction.external.grab.min.js +1 -1
- package/tsparticles.interaction.external.repulse.js +7 -21
- package/tsparticles.interaction.external.repulse.min.js +1 -1
- package/tsparticles.interaction.external.trail.js +7 -21
- package/tsparticles.interaction.external.trail.min.js +1 -1
- package/tsparticles.interaction.particles.attract.js +7 -21
- package/tsparticles.interaction.particles.attract.min.js +1 -1
- package/tsparticles.interaction.particles.collisions.js +7 -21
- package/tsparticles.interaction.particles.collisions.min.js +1 -1
- package/tsparticles.interaction.particles.links.js +7 -21
- package/tsparticles.interaction.particles.links.min.js +1 -1
- package/tsparticles.js +7 -21
- package/tsparticles.min.js +2 -2
- package/tsparticles.pathseg.min.js +1 -1
- package/tsparticles.plugins.absorbers.js +7 -21
- package/tsparticles.plugins.absorbers.min.js +1 -1
- package/tsparticles.plugins.emitters.js +7 -21
- package/tsparticles.plugins.emitters.min.js +1 -1
- package/tsparticles.plugins.polygonMask.js +7 -21
- package/tsparticles.plugins.polygonMask.min.js +1 -1
- package/tsparticles.shape.circle.min.js +1 -1
- package/tsparticles.shape.image.js +7 -21
- package/tsparticles.shape.image.min.js +1 -1
- package/tsparticles.shape.line.min.js +1 -1
- package/tsparticles.shape.polygon.min.js +1 -1
- package/tsparticles.shape.square.min.js +1 -1
- package/tsparticles.shape.star.min.js +1 -1
- package/tsparticles.shape.text.js +7 -21
- package/tsparticles.shape.text.min.js +1 -1
- package/tsparticles.slim.js +7 -21
- package/tsparticles.slim.min.js +2 -2
- package/tsparticles.updater.angle.js +7 -21
- package/tsparticles.updater.angle.min.js +1 -1
- package/tsparticles.updater.color.js +7 -21
- package/tsparticles.updater.color.min.js +1 -1
- package/tsparticles.updater.life.js +7 -21
- package/tsparticles.updater.life.min.js +1 -1
- package/tsparticles.updater.opacity.js +7 -21
- package/tsparticles.updater.opacity.min.js +1 -1
- package/tsparticles.updater.outModes.js +7 -21
- package/tsparticles.updater.outModes.min.js +1 -1
- package/tsparticles.updater.roll.js +7 -21
- package/tsparticles.updater.roll.min.js +1 -1
- package/tsparticles.updater.size.js +7 -21
- package/tsparticles.updater.size.min.js +1 -1
- package/tsparticles.updater.strokeColor.js +7 -21
- package/tsparticles.updater.strokeColor.min.js +1 -1
- package/tsparticles.updater.tilt.js +7 -21
- package/tsparticles.updater.tilt.min.js +1 -1
- package/tsparticles.updater.wobble.js +7 -21
- package/tsparticles.updater.wobble.min.js +1 -1
- package/umd/Core/Canvas.d.ts +35 -0
- package/umd/Core/Canvas.js +328 -0
- package/umd/Core/Container.d.ts +68 -0
- package/umd/Core/Container.js +405 -0
- package/umd/Core/Interfaces/Colors.d.ts +33 -0
- package/umd/Core/Interfaces/Colors.js +12 -0
- package/umd/Core/Interfaces/Gradients.d.ts +21 -0
- package/umd/Core/Interfaces/Gradients.js +12 -0
- package/umd/Core/Interfaces/IAttract.d.ts +7 -0
- package/umd/Core/Interfaces/IAttract.js +12 -0
- package/umd/Core/Interfaces/IBounds.d.ts +6 -0
- package/umd/Core/Interfaces/IBounds.js +12 -0
- package/umd/Core/Interfaces/IBubble.d.ts +4 -0
- package/umd/Core/Interfaces/IBubble.js +12 -0
- package/umd/Core/Interfaces/IBubbleParticleData.d.ts +9 -0
- package/umd/Core/Interfaces/IBubbleParticleData.js +12 -0
- package/umd/Core/Interfaces/ICircleBouncer.d.ts +9 -0
- package/umd/Core/Interfaces/ICircleBouncer.js +12 -0
- package/umd/Core/Interfaces/IContainerInteractivity.d.ts +6 -0
- package/umd/Core/Interfaces/IContainerInteractivity.js +12 -0
- package/umd/Core/Interfaces/IContainerPlugin.d.ts +32 -0
- package/umd/Core/Interfaces/IContainerPlugin.js +12 -0
- package/umd/Core/Interfaces/ICoordinates.d.ts +7 -0
- package/umd/Core/Interfaces/ICoordinates.js +12 -0
- package/umd/Core/Interfaces/IDelta.d.ts +4 -0
- package/umd/Core/Interfaces/IDelta.js +12 -0
- package/umd/Core/Interfaces/IDimension.d.ts +4 -0
- package/umd/Core/Interfaces/IDimension.js +12 -0
- package/umd/Core/Interfaces/IDistance.d.ts +4 -0
- package/umd/Core/Interfaces/IDistance.js +12 -0
- package/umd/Core/Interfaces/IExternalInteractor.d.ts +6 -0
- package/umd/Core/Interfaces/IExternalInteractor.js +12 -0
- package/umd/Core/Interfaces/IInteractor.d.ts +6 -0
- package/umd/Core/Interfaces/IInteractor.js +12 -0
- package/umd/Core/Interfaces/IMouseData.d.ts +9 -0
- package/umd/Core/Interfaces/IMouseData.js +12 -0
- package/umd/Core/Interfaces/IMovePathGenerator.d.ts +8 -0
- package/umd/Core/Interfaces/IMovePathGenerator.js +12 -0
- package/umd/Core/Interfaces/IParticle.d.ts +55 -0
- package/umd/Core/Interfaces/IParticle.js +12 -0
- package/umd/Core/Interfaces/IParticleGradientAnimation.d.ts +8 -0
- package/umd/Core/Interfaces/IParticleGradientAnimation.js +12 -0
- package/umd/Core/Interfaces/IParticleGradientColorAnimation.d.ts +7 -0
- package/umd/Core/Interfaces/IParticleGradientColorAnimation.js +12 -0
- package/umd/Core/Interfaces/IParticleHslAnimation.d.ts +6 -0
- package/umd/Core/Interfaces/IParticleHslAnimation.js +12 -0
- package/umd/Core/Interfaces/IParticleLife.d.ts +7 -0
- package/umd/Core/Interfaces/IParticleLife.js +12 -0
- package/umd/Core/Interfaces/IParticleLoops.d.ts +4 -0
- package/umd/Core/Interfaces/IParticleLoops.js +12 -0
- package/umd/Core/Interfaces/IParticleRetinaProps.d.ts +12 -0
- package/umd/Core/Interfaces/IParticleRetinaProps.js +12 -0
- package/umd/Core/Interfaces/IParticleRoll.d.ts +9 -0
- package/umd/Core/Interfaces/IParticleRoll.js +12 -0
- package/umd/Core/Interfaces/IParticleSpin.d.ts +9 -0
- package/umd/Core/Interfaces/IParticleSpin.js +12 -0
- package/umd/Core/Interfaces/IParticleUpdater.d.ts +9 -0
- package/umd/Core/Interfaces/IParticleUpdater.js +12 -0
- package/umd/Core/Interfaces/IParticleValueAnimation.d.ts +17 -0
- package/umd/Core/Interfaces/IParticleValueAnimation.js +12 -0
- package/umd/Core/Interfaces/IParticleWobble.d.ts +4 -0
- package/umd/Core/Interfaces/IParticleWobble.js +12 -0
- package/umd/Core/Interfaces/IParticlesFrequencies.d.ts +4 -0
- package/umd/Core/Interfaces/IParticlesFrequencies.js +12 -0
- package/umd/Core/Interfaces/IParticlesInteractor.d.ts +7 -0
- package/umd/Core/Interfaces/IParticlesInteractor.js +12 -0
- package/umd/Core/Interfaces/IPlugin.d.ts +11 -0
- package/umd/Core/Interfaces/IPlugin.js +12 -0
- package/umd/Core/Interfaces/IRangeValue.d.ts +4 -0
- package/umd/Core/Interfaces/IRangeValue.js +12 -0
- package/umd/Core/Interfaces/IRectSideResult.d.ts +5 -0
- package/umd/Core/Interfaces/IRectSideResult.js +12 -0
- package/umd/Core/Interfaces/IRepulse.d.ts +7 -0
- package/umd/Core/Interfaces/IRepulse.js +12 -0
- package/umd/Core/Interfaces/IShapeDrawer.d.ts +10 -0
- package/umd/Core/Interfaces/IShapeDrawer.js +12 -0
- package/umd/Core/Interfaces/IShapeValues.d.ts +8 -0
- package/umd/Core/Interfaces/IShapeValues.js +12 -0
- package/umd/Core/Interfaces/index.d.ts +36 -0
- package/umd/Core/Interfaces/index.js +58 -0
- package/umd/Core/Loader.d.ts +32 -0
- package/umd/Core/Loader.js +193 -0
- package/umd/Core/Particle.d.ts +71 -0
- package/umd/Core/Particle.js +394 -0
- package/umd/Core/Particles.d.ts +46 -0
- package/umd/Core/Particles.js +331 -0
- package/umd/Core/Retina.d.ts +26 -0
- package/umd/Core/Retina.js +107 -0
- package/umd/Core/Utils/Circle.d.ts +8 -0
- package/umd/Core/Utils/Circle.js +52 -0
- package/umd/Core/Utils/CircleWarp.d.ts +9 -0
- package/umd/Core/Utils/CircleWarp.js +70 -0
- package/umd/Core/Utils/Constants.d.ts +18 -0
- package/umd/Core/Utils/Constants.js +32 -0
- package/umd/Core/Utils/EventListeners.d.ts +33 -0
- package/umd/Core/Utils/EventListeners.js +383 -0
- package/umd/Core/Utils/ExternalInteractorBase.d.ts +12 -0
- package/umd/Core/Utils/ExternalInteractorBase.js +20 -0
- package/umd/Core/Utils/FrameManager.d.ts +6 -0
- package/umd/Core/Utils/FrameManager.js +53 -0
- package/umd/Core/Utils/InteractionManager.d.ts +14 -0
- package/umd/Core/Utils/InteractionManager.js +69 -0
- package/umd/Core/Utils/ParticlesInteractorBase.d.ts +12 -0
- package/umd/Core/Utils/ParticlesInteractorBase.js +20 -0
- package/umd/Core/Utils/ParticlesMover.d.ts +13 -0
- package/umd/Core/Utils/ParticlesMover.js +196 -0
- package/umd/Core/Utils/Plugins.d.ts +36 -0
- package/umd/Core/Utils/Plugins.js +108 -0
- package/umd/Core/Utils/Point.d.ts +7 -0
- package/umd/Core/Utils/Point.js +20 -0
- package/umd/Core/Utils/QuadTree.d.ts +23 -0
- package/umd/Core/Utils/QuadTree.js +88 -0
- package/umd/Core/Utils/Range.d.ts +7 -0
- package/umd/Core/Utils/Range.js +22 -0
- package/umd/Core/Utils/Rectangle.d.ts +8 -0
- package/umd/Core/Utils/Rectangle.js +48 -0
- package/umd/Core/Utils/Vector.d.ts +29 -0
- package/umd/Core/Utils/Vector.js +106 -0
- package/umd/Core/Utils/Vector3d.d.ts +18 -0
- package/umd/Core/Utils/Vector3d.js +68 -0
- package/umd/Core/Utils/index.d.ts +16 -0
- package/umd/Core/Utils/index.js +38 -0
- package/umd/Core/index.d.ts +8 -0
- package/umd/Core/index.js +30 -0
- package/umd/Enums/AnimationStatus.d.ts +4 -0
- package/umd/Enums/AnimationStatus.js +12 -0
- package/umd/Enums/Directions/MoveDirection.d.ts +12 -0
- package/umd/Enums/Directions/MoveDirection.js +12 -0
- package/umd/Enums/Directions/OutModeDirection.d.ts +6 -0
- package/umd/Enums/Directions/OutModeDirection.js +12 -0
- package/umd/Enums/Directions/RotateDirection.d.ts +6 -0
- package/umd/Enums/Directions/RotateDirection.js +12 -0
- package/umd/Enums/Directions/TiltDirection.d.ts +6 -0
- package/umd/Enums/Directions/TiltDirection.js +12 -0
- package/umd/Enums/Directions/index.d.ts +4 -0
- package/umd/Enums/Directions/index.js +26 -0
- package/umd/Enums/InteractivityDetect.d.ts +5 -0
- package/umd/Enums/InteractivityDetect.js +12 -0
- package/umd/Enums/Modes/ClickMode.d.ts +9 -0
- package/umd/Enums/Modes/ClickMode.js +12 -0
- package/umd/Enums/Modes/CollisionMode.d.ts +5 -0
- package/umd/Enums/Modes/CollisionMode.js +12 -0
- package/umd/Enums/Modes/DestroyMode.d.ts +4 -0
- package/umd/Enums/Modes/DestroyMode.js +12 -0
- package/umd/Enums/Modes/DivMode.d.ts +5 -0
- package/umd/Enums/Modes/DivMode.js +12 -0
- package/umd/Enums/Modes/HoverMode.d.ts +11 -0
- package/umd/Enums/Modes/HoverMode.js +12 -0
- package/umd/Enums/Modes/OutMode.d.ts +10 -0
- package/umd/Enums/Modes/OutMode.js +12 -0
- package/umd/Enums/Modes/ResponsiveMode.d.ts +4 -0
- package/umd/Enums/Modes/ResponsiveMode.js +12 -0
- package/umd/Enums/Modes/RollMode.d.ts +5 -0
- package/umd/Enums/Modes/RollMode.js +12 -0
- package/umd/Enums/Modes/SizeMode.d.ts +4 -0
- package/umd/Enums/Modes/SizeMode.js +12 -0
- package/umd/Enums/Modes/ThemeMode.d.ts +5 -0
- package/umd/Enums/Modes/ThemeMode.js +12 -0
- package/umd/Enums/Modes/index.d.ts +10 -0
- package/umd/Enums/Modes/index.js +32 -0
- package/umd/Enums/Types/AlterType.d.ts +4 -0
- package/umd/Enums/Types/AlterType.js +12 -0
- package/umd/Enums/Types/DestroyType.d.ts +5 -0
- package/umd/Enums/Types/DestroyType.js +12 -0
- package/umd/Enums/Types/DivType.d.ts +4 -0
- package/umd/Enums/Types/DivType.js +12 -0
- package/umd/Enums/Types/EasingType.d.ts +10 -0
- package/umd/Enums/Types/EasingType.js +12 -0
- package/umd/Enums/Types/GradientType.d.ts +5 -0
- package/umd/Enums/Types/GradientType.js +12 -0
- package/umd/Enums/Types/InteractorType.d.ts +4 -0
- package/umd/Enums/Types/InteractorType.js +12 -0
- package/umd/Enums/Types/OrbitType.d.ts +4 -0
- package/umd/Enums/Types/OrbitType.js +12 -0
- package/umd/Enums/Types/ShapeType.d.ts +13 -0
- package/umd/Enums/Types/ShapeType.js +12 -0
- package/umd/Enums/Types/StartValueType.d.ts +5 -0
- package/umd/Enums/Types/StartValueType.js +12 -0
- package/umd/Enums/Types/index.d.ts +9 -0
- package/umd/Enums/Types/index.js +31 -0
- package/umd/Enums/index.d.ts +5 -0
- package/umd/Enums/index.js +27 -0
- package/umd/Interactions/External/Attract/Attractor.d.ts +11 -0
- package/umd/Interactions/External/Attract/Attractor.js +85 -0
- package/umd/Interactions/External/Attract/index.d.ts +2 -0
- package/umd/Interactions/External/Attract/index.js +18 -0
- package/umd/Interactions/External/Bounce/Bouncer.d.ts +11 -0
- package/umd/Interactions/External/Bounce/Bouncer.js +77 -0
- package/umd/Interactions/External/Bounce/index.d.ts +2 -0
- package/umd/Interactions/External/Bounce/index.js +18 -0
- package/umd/Interactions/External/Bubble/Bubbler.d.ts +16 -0
- package/umd/Interactions/External/Bubble/Bubbler.js +261 -0
- package/umd/Interactions/External/Bubble/IBubblerProcessParam.d.ts +10 -0
- package/umd/Interactions/External/Bubble/IBubblerProcessParam.js +12 -0
- package/umd/Interactions/External/Bubble/ProcessBubbleType.d.ts +5 -0
- package/umd/Interactions/External/Bubble/ProcessBubbleType.js +12 -0
- package/umd/Interactions/External/Bubble/index.d.ts +2 -0
- package/umd/Interactions/External/Bubble/index.js +18 -0
- package/umd/Interactions/External/Connect/Connector.d.ts +8 -0
- package/umd/Interactions/External/Connect/Connector.js +51 -0
- package/umd/Interactions/External/Connect/index.d.ts +2 -0
- package/umd/Interactions/External/Connect/index.js +18 -0
- package/umd/Interactions/External/Grab/Grabber.d.ts +8 -0
- package/umd/Interactions/External/Grab/Grabber.js +57 -0
- package/umd/Interactions/External/Grab/index.d.ts +2 -0
- package/umd/Interactions/External/Grab/index.js +18 -0
- package/umd/Interactions/External/Repulse/Repulser.d.ts +12 -0
- package/umd/Interactions/External/Repulse/Repulser.js +108 -0
- package/umd/Interactions/External/Repulse/index.d.ts +2 -0
- package/umd/Interactions/External/Repulse/index.js +18 -0
- package/umd/Interactions/External/Trail/TrailMaker.d.ts +10 -0
- package/umd/Interactions/External/Trail/TrailMaker.js +63 -0
- package/umd/Interactions/External/Trail/index.d.ts +2 -0
- package/umd/Interactions/External/Trail/index.js +18 -0
- package/umd/Interactions/Particles/Attract/Attractor.d.ts +8 -0
- package/umd/Interactions/Particles/Attract/Attractor.js +40 -0
- package/umd/Interactions/Particles/Attract/index.d.ts +2 -0
- package/umd/Interactions/Particles/Attract/index.js +18 -0
- package/umd/Interactions/Particles/Collisions/Collider.d.ts +10 -0
- package/umd/Interactions/Particles/Collisions/Collider.js +119 -0
- package/umd/Interactions/Particles/Collisions/index.d.ts +2 -0
- package/umd/Interactions/Particles/Collisions/index.js +18 -0
- package/umd/Interactions/Particles/Links/ILink.d.ts +9 -0
- package/umd/Interactions/Particles/Links/ILink.js +12 -0
- package/umd/Interactions/Particles/Links/LinkInstance.d.ts +10 -0
- package/umd/Interactions/Particles/Links/LinkInstance.js +134 -0
- package/umd/Interactions/Particles/Links/LinkParticle.d.ts +5 -0
- package/umd/Interactions/Particles/Links/LinkParticle.js +12 -0
- package/umd/Interactions/Particles/Links/Linker.d.ts +10 -0
- package/umd/Interactions/Particles/Links/Linker.js +115 -0
- package/umd/Interactions/Particles/Links/index.d.ts +2 -0
- package/umd/Interactions/Particles/Links/index.js +20 -0
- package/umd/Interactions/Particles/Links/interaction.d.ts +2 -0
- package/umd/Interactions/Particles/Links/interaction.js +18 -0
- package/umd/Interactions/Particles/Links/plugin.d.ts +2 -0
- package/umd/Interactions/Particles/Links/plugin.js +32 -0
- package/umd/Options/Classes/AnimatableColor.d.ts +11 -0
- package/umd/Options/Classes/AnimatableColor.js +50 -0
- package/umd/Options/Classes/AnimatableGradient.d.ts +53 -0
- package/umd/Options/Classes/AnimatableGradient.js +156 -0
- package/umd/Options/Classes/AnimationOptions.d.ts +11 -0
- package/umd/Options/Classes/AnimationOptions.js +39 -0
- package/umd/Options/Classes/Background/Background.d.ts +14 -0
- package/umd/Options/Classes/Background/Background.js +49 -0
- package/umd/Options/Classes/BackgroundMask/BackgroundMask.d.ts +11 -0
- package/umd/Options/Classes/BackgroundMask/BackgroundMask.js +38 -0
- package/umd/Options/Classes/BackgroundMask/BackgroundMaskCover.d.ts +10 -0
- package/umd/Options/Classes/BackgroundMask/BackgroundMaskCover.js +32 -0
- package/umd/Options/Classes/ColorAnimation.d.ts +12 -0
- package/umd/Options/Classes/ColorAnimation.js +44 -0
- package/umd/Options/Classes/FullScreen/FullScreen.d.ts +9 -0
- package/umd/Options/Classes/FullScreen/FullScreen.js +31 -0
- package/umd/Options/Classes/HslAnimation.d.ts +11 -0
- package/umd/Options/Classes/HslAnimation.js +30 -0
- package/umd/Options/Classes/Interactivity/Events/ClickEvent.d.ts +10 -0
- package/umd/Options/Classes/Interactivity/Events/ClickEvent.js +31 -0
- package/umd/Options/Classes/Interactivity/Events/DivEvent.d.ts +18 -0
- package/umd/Options/Classes/Interactivity/Events/DivEvent.js +64 -0
- package/umd/Options/Classes/Interactivity/Events/Events.d.ts +20 -0
- package/umd/Options/Classes/Interactivity/Events/Events.js +68 -0
- package/umd/Options/Classes/Interactivity/Events/HoverEvent.d.ts +12 -0
- package/umd/Options/Classes/Interactivity/Events/HoverEvent.js +34 -0
- package/umd/Options/Classes/Interactivity/Events/Parallax.d.ts +10 -0
- package/umd/Options/Classes/Interactivity/Events/Parallax.js +35 -0
- package/umd/Options/Classes/Interactivity/Interactivity.d.ts +15 -0
- package/umd/Options/Classes/Interactivity/Interactivity.js +51 -0
- package/umd/Options/Classes/Interactivity/Modes/Attract.d.ts +14 -0
- package/umd/Options/Classes/Interactivity/Modes/Attract.js +47 -0
- package/umd/Options/Classes/Interactivity/Modes/Bounce.d.ts +8 -0
- package/umd/Options/Classes/Interactivity/Modes/Bounce.js +27 -0
- package/umd/Options/Classes/Interactivity/Modes/Bubble.d.ts +9 -0
- package/umd/Options/Classes/Interactivity/Modes/Bubble.js +37 -0
- package/umd/Options/Classes/Interactivity/Modes/BubbleBase.d.ts +13 -0
- package/umd/Options/Classes/Interactivity/Modes/BubbleBase.js +53 -0
- package/umd/Options/Classes/Interactivity/Modes/BubbleDiv.d.ts +11 -0
- package/umd/Options/Classes/Interactivity/Modes/BubbleDiv.js +41 -0
- package/umd/Options/Classes/Interactivity/Modes/Connect.d.ts +15 -0
- package/umd/Options/Classes/Interactivity/Modes/Connect.js +47 -0
- package/umd/Options/Classes/Interactivity/Modes/ConnectLinks.d.ts +8 -0
- package/umd/Options/Classes/Interactivity/Modes/ConnectLinks.js +25 -0
- package/umd/Options/Classes/Interactivity/Modes/Grab.d.ts +14 -0
- package/umd/Options/Classes/Interactivity/Modes/Grab.js +43 -0
- package/umd/Options/Classes/Interactivity/Modes/GrabLinks.d.ts +12 -0
- package/umd/Options/Classes/Interactivity/Modes/GrabLinks.js +39 -0
- package/umd/Options/Classes/Interactivity/Modes/Light.d.ts +11 -0
- package/umd/Options/Classes/Interactivity/Modes/Light.js +29 -0
- package/umd/Options/Classes/Interactivity/Modes/LightArea.d.ts +10 -0
- package/umd/Options/Classes/Interactivity/Modes/LightArea.js +30 -0
- package/umd/Options/Classes/Interactivity/Modes/LightGradient.d.ts +10 -0
- package/umd/Options/Classes/Interactivity/Modes/LightGradient.js +30 -0
- package/umd/Options/Classes/Interactivity/Modes/LightShadow.d.ts +10 -0
- package/umd/Options/Classes/Interactivity/Modes/LightShadow.js +31 -0
- package/umd/Options/Classes/Interactivity/Modes/Modes.d.ts +29 -0
- package/umd/Options/Classes/Interactivity/Modes/Modes.js +55 -0
- package/umd/Options/Classes/Interactivity/Modes/Push.d.ts +12 -0
- package/umd/Options/Classes/Interactivity/Modes/Push.js +46 -0
- package/umd/Options/Classes/Interactivity/Modes/Remove.d.ts +10 -0
- package/umd/Options/Classes/Interactivity/Modes/Remove.js +35 -0
- package/umd/Options/Classes/Interactivity/Modes/Repulse.d.ts +9 -0
- package/umd/Options/Classes/Interactivity/Modes/Repulse.js +37 -0
- package/umd/Options/Classes/Interactivity/Modes/RepulseBase.d.ts +14 -0
- package/umd/Options/Classes/Interactivity/Modes/RepulseBase.js +47 -0
- package/umd/Options/Classes/Interactivity/Modes/RepulseDiv.d.ts +11 -0
- package/umd/Options/Classes/Interactivity/Modes/RepulseDiv.js +49 -0
- package/umd/Options/Classes/Interactivity/Modes/Slow.d.ts +11 -0
- package/umd/Options/Classes/Interactivity/Modes/Slow.js +36 -0
- package/umd/Options/Classes/Interactivity/Modes/Trail.d.ts +12 -0
- package/umd/Options/Classes/Interactivity/Modes/Trail.js +39 -0
- package/umd/Options/Classes/ManualParticle.d.ts +10 -0
- package/umd/Options/Classes/ManualParticle.js +32 -0
- package/umd/Options/Classes/Motion/Motion.d.ts +10 -0
- package/umd/Options/Classes/Motion/Motion.js +30 -0
- package/umd/Options/Classes/Motion/MotionReduce.d.ts +9 -0
- package/umd/Options/Classes/Motion/MotionReduce.js +31 -0
- package/umd/Options/Classes/Options.d.ts +48 -0
- package/umd/Options/Classes/Options.js +184 -0
- package/umd/Options/Classes/OptionsColor.d.ts +10 -0
- package/umd/Options/Classes/OptionsColor.js +38 -0
- package/umd/Options/Classes/Particles/Bounce/Bounce.d.ts +10 -0
- package/umd/Options/Classes/Particles/Bounce/Bounce.js +28 -0
- package/umd/Options/Classes/Particles/Bounce/BounceFactor.d.ts +4 -0
- package/umd/Options/Classes/Particles/Bounce/BounceFactor.js +22 -0
- package/umd/Options/Classes/Particles/Collisions/Collisions.d.ts +14 -0
- package/umd/Options/Classes/Particles/Collisions/Collisions.js +37 -0
- package/umd/Options/Classes/Particles/Collisions/CollisionsOverlap.d.ts +9 -0
- package/umd/Options/Classes/Particles/Collisions/CollisionsOverlap.js +31 -0
- package/umd/Options/Classes/Particles/Destroy/Destroy.d.ts +11 -0
- package/umd/Options/Classes/Particles/Destroy/Destroy.js +30 -0
- package/umd/Options/Classes/Particles/Destroy/Split.d.ts +15 -0
- package/umd/Options/Classes/Particles/Destroy/Split.js +41 -0
- package/umd/Options/Classes/Particles/Destroy/SplitFactor.d.ts +4 -0
- package/umd/Options/Classes/Particles/Destroy/SplitFactor.js +21 -0
- package/umd/Options/Classes/Particles/Destroy/SplitRate.d.ts +4 -0
- package/umd/Options/Classes/Particles/Destroy/SplitRate.js +21 -0
- package/umd/Options/Classes/Particles/Life/Life.d.ts +12 -0
- package/umd/Options/Classes/Particles/Life/Life.js +33 -0
- package/umd/Options/Classes/Particles/Life/LifeDelay.d.ts +9 -0
- package/umd/Options/Classes/Particles/Life/LifeDelay.js +30 -0
- package/umd/Options/Classes/Particles/Life/LifeDuration.d.ts +9 -0
- package/umd/Options/Classes/Particles/Life/LifeDuration.js +31 -0
- package/umd/Options/Classes/Particles/Links/Links.d.ts +22 -0
- package/umd/Options/Classes/Particles/Links/Links.js +67 -0
- package/umd/Options/Classes/Particles/Links/LinksShadow.d.ts +11 -0
- package/umd/Options/Classes/Particles/Links/LinksShadow.js +35 -0
- package/umd/Options/Classes/Particles/Links/LinksTriangle.d.ts +12 -0
- package/umd/Options/Classes/Particles/Links/LinksTriangle.js +38 -0
- package/umd/Options/Classes/Particles/Move/Attract.d.ts +15 -0
- package/umd/Options/Classes/Particles/Move/Attract.js +56 -0
- package/umd/Options/Classes/Particles/Move/Move.d.ts +44 -0
- package/umd/Options/Classes/Particles/Move/Move.js +142 -0
- package/umd/Options/Classes/Particles/Move/MoveAngle.d.ts +9 -0
- package/umd/Options/Classes/Particles/Move/MoveAngle.js +31 -0
- package/umd/Options/Classes/Particles/Move/MoveGravity.d.ts +11 -0
- package/umd/Options/Classes/Particles/Move/MoveGravity.js +39 -0
- package/umd/Options/Classes/Particles/Move/OutModes.d.ts +13 -0
- package/umd/Options/Classes/Particles/Move/OutModes.js +32 -0
- package/umd/Options/Classes/Particles/Move/Path/Path.d.ts +13 -0
- package/umd/Options/Classes/Particles/Move/Path/Path.js +40 -0
- package/umd/Options/Classes/Particles/Move/Path/PathDelay.d.ts +4 -0
- package/umd/Options/Classes/Particles/Move/Path/PathDelay.js +20 -0
- package/umd/Options/Classes/Particles/Move/Spin.d.ts +11 -0
- package/umd/Options/Classes/Particles/Move/Spin.js +33 -0
- package/umd/Options/Classes/Particles/Move/Trail.d.ts +11 -0
- package/umd/Options/Classes/Particles/Move/Trail.js +35 -0
- package/umd/Options/Classes/Particles/Number/Density.d.ts +12 -0
- package/umd/Options/Classes/Particles/Number/Density.js +43 -0
- package/umd/Options/Classes/Particles/Number/ParticlesNumber.d.ts +13 -0
- package/umd/Options/Classes/Particles/Number/ParticlesNumber.js +42 -0
- package/umd/Options/Classes/Particles/Opacity/Opacity.d.ts +12 -0
- package/umd/Options/Classes/Particles/Opacity/Opacity.js +43 -0
- package/umd/Options/Classes/Particles/Opacity/OpacityAnimation.d.ts +14 -0
- package/umd/Options/Classes/Particles/Opacity/OpacityAnimation.js +54 -0
- package/umd/Options/Classes/Particles/Orbit/Orbit.d.ts +18 -0
- package/umd/Options/Classes/Particles/Orbit/Orbit.js +48 -0
- package/umd/Options/Classes/Particles/Orbit/OrbitRotation.d.ts +7 -0
- package/umd/Options/Classes/Particles/Orbit/OrbitRotation.js +29 -0
- package/umd/Options/Classes/Particles/ParticlesOptions.d.ts +58 -0
- package/umd/Options/Classes/Particles/ParticlesOptions.js +153 -0
- package/umd/Options/Classes/Particles/Repulse/Repulse.d.ts +13 -0
- package/umd/Options/Classes/Particles/Repulse/Repulse.js +46 -0
- package/umd/Options/Classes/Particles/Roll/Roll.d.ts +16 -0
- package/umd/Options/Classes/Particles/Roll/Roll.js +45 -0
- package/umd/Options/Classes/Particles/Roll/RollLight.d.ts +9 -0
- package/umd/Options/Classes/Particles/Roll/RollLight.js +31 -0
- package/umd/Options/Classes/Particles/Rotate/Rotate.d.ts +13 -0
- package/umd/Options/Classes/Particles/Rotate/Rotate.js +38 -0
- package/umd/Options/Classes/Particles/Rotate/RotateAnimation.d.ts +10 -0
- package/umd/Options/Classes/Particles/Rotate/RotateAnimation.js +35 -0
- package/umd/Options/Classes/Particles/Shadow.d.ts +13 -0
- package/umd/Options/Classes/Particles/Shadow.js +48 -0
- package/umd/Options/Classes/Particles/Shape/Shape.d.ts +27 -0
- package/umd/Options/Classes/Particles/Shape/Shape.js +113 -0
- package/umd/Options/Classes/Particles/Size/Size.d.ts +12 -0
- package/umd/Options/Classes/Particles/Size/Size.js +43 -0
- package/umd/Options/Classes/Particles/Size/SizeAnimation.d.ts +14 -0
- package/umd/Options/Classes/Particles/Size/SizeAnimation.js +54 -0
- package/umd/Options/Classes/Particles/Stroke.d.ts +11 -0
- package/umd/Options/Classes/Particles/Stroke.js +34 -0
- package/umd/Options/Classes/Particles/Tilt/Tilt.d.ts +13 -0
- package/umd/Options/Classes/Particles/Tilt/Tilt.js +38 -0
- package/umd/Options/Classes/Particles/Tilt/TiltAnimation.d.ts +10 -0
- package/umd/Options/Classes/Particles/Tilt/TiltAnimation.js +35 -0
- package/umd/Options/Classes/Particles/Twinkle/Twinkle.d.ts +10 -0
- package/umd/Options/Classes/Particles/Twinkle/Twinkle.js +28 -0
- package/umd/Options/Classes/Particles/Twinkle/TwinkleValues.d.ts +12 -0
- package/umd/Options/Classes/Particles/Twinkle/TwinkleValues.js +39 -0
- package/umd/Options/Classes/Particles/Wobble/Wobble.d.ts +10 -0
- package/umd/Options/Classes/Particles/Wobble/Wobble.js +36 -0
- package/umd/Options/Classes/Particles/ZIndex/ZIndex.d.ts +11 -0
- package/umd/Options/Classes/Particles/ZIndex/ZIndex.js +38 -0
- package/umd/Options/Classes/Random.d.ts +9 -0
- package/umd/Options/Classes/Random.js +31 -0
- package/umd/Options/Classes/Responsive.d.ts +12 -0
- package/umd/Options/Classes/Responsive.js +41 -0
- package/umd/Options/Classes/Theme/Theme.d.ts +12 -0
- package/umd/Options/Classes/Theme/Theme.js +34 -0
- package/umd/Options/Classes/Theme/ThemeDefault.d.ts +11 -0
- package/umd/Options/Classes/Theme/ThemeDefault.js +35 -0
- package/umd/Options/Classes/ValueWithRandom.d.ts +10 -0
- package/umd/Options/Classes/ValueWithRandom.js +36 -0
- package/umd/Options/Interfaces/Background/IBackground.d.ts +9 -0
- package/umd/Options/Interfaces/Background/IBackground.js +12 -0
- package/umd/Options/Interfaces/BackgroundMask/IBackgroundMask.d.ts +7 -0
- package/umd/Options/Interfaces/BackgroundMask/IBackgroundMask.js +12 -0
- package/umd/Options/Interfaces/BackgroundMask/IBackgroundMaskCover.d.ts +5 -0
- package/umd/Options/Interfaces/BackgroundMask/IBackgroundMaskCover.js +12 -0
- package/umd/Options/Interfaces/FullScreen/IFullScreen.d.ts +4 -0
- package/umd/Options/Interfaces/FullScreen/IFullScreen.js +12 -0
- package/umd/Options/Interfaces/IAnimatable.d.ts +4 -0
- package/umd/Options/Interfaces/IAnimatable.js +12 -0
- package/umd/Options/Interfaces/IAnimatableColor.d.ts +6 -0
- package/umd/Options/Interfaces/IAnimatableColor.js +12 -0
- package/umd/Options/Interfaces/IAnimatableGradient.d.ts +8 -0
- package/umd/Options/Interfaces/IAnimatableGradient.js +12 -0
- package/umd/Options/Interfaces/IAnimation.d.ts +6 -0
- package/umd/Options/Interfaces/IAnimation.js +12 -0
- package/umd/Options/Interfaces/IColorAnimation.d.ts +5 -0
- package/umd/Options/Interfaces/IColorAnimation.js +12 -0
- package/umd/Options/Interfaces/IHslAnimation.d.ts +6 -0
- package/umd/Options/Interfaces/IHslAnimation.js +12 -0
- package/umd/Options/Interfaces/IManualParticle.d.ts +7 -0
- package/umd/Options/Interfaces/IManualParticle.js +12 -0
- package/umd/Options/Interfaces/IOptionLoader.d.ts +4 -0
- package/umd/Options/Interfaces/IOptionLoader.js +12 -0
- package/umd/Options/Interfaces/IOptions.d.ts +34 -0
- package/umd/Options/Interfaces/IOptions.js +12 -0
- package/umd/Options/Interfaces/IOptionsColor.d.ts +2 -0
- package/umd/Options/Interfaces/IOptionsColor.js +12 -0
- package/umd/Options/Interfaces/IOptionsGradient.d.ts +13 -0
- package/umd/Options/Interfaces/IOptionsGradient.js +12 -0
- package/umd/Options/Interfaces/IRandom.d.ts +4 -0
- package/umd/Options/Interfaces/IRandom.js +12 -0
- package/umd/Options/Interfaces/IResponsive.d.ts +8 -0
- package/umd/Options/Interfaces/IResponsive.js +12 -0
- package/umd/Options/Interfaces/IValueWithRandom.d.ts +6 -0
- package/umd/Options/Interfaces/IValueWithRandom.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Events/IClickEvent.d.ts +6 -0
- package/umd/Options/Interfaces/Interactivity/Events/IClickEvent.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Events/IDivEvent.d.ts +11 -0
- package/umd/Options/Interfaces/Interactivity/Events/IDivEvent.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Events/IEvents.d.ts +13 -0
- package/umd/Options/Interfaces/Interactivity/Events/IEvents.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Events/IHoverEvent.d.ts +8 -0
- package/umd/Options/Interfaces/Interactivity/Events/IHoverEvent.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Events/IParallax.d.ts +5 -0
- package/umd/Options/Interfaces/Interactivity/Events/IParallax.js +12 -0
- package/umd/Options/Interfaces/Interactivity/IInteractivity.d.ts +9 -0
- package/umd/Options/Interfaces/Interactivity/IInteractivity.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IAttract.d.ts +9 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IAttract.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IBounce.d.ts +3 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IBounce.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IBubble.d.ts +6 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IBubble.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IBubbleBase.d.ts +10 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IBubbleBase.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IBubbleDiv.d.ts +4 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IBubbleDiv.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IConnect.d.ts +8 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IConnect.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IConnectLinks.d.ts +3 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IConnectLinks.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IGrab.d.ts +7 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IGrab.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IGrabLinks.d.ts +7 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IGrabLinks.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/ILight.d.ts +6 -0
- package/umd/Options/Interfaces/Interactivity/Modes/ILight.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/ILightArea.d.ts +9 -0
- package/umd/Options/Interfaces/Interactivity/Modes/ILightArea.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/ILightShadow.d.ts +5 -0
- package/umd/Options/Interfaces/Interactivity/Modes/ILightShadow.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IModeDiv.d.ts +5 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IModeDiv.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IModes.d.ts +22 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IModes.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IPush.d.ts +6 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IPush.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IRemove.d.ts +4 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IRemove.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IRepulse.d.ts +6 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IRepulse.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IRepulseBase.d.ts +9 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IRepulseBase.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IRepulseDiv.d.ts +4 -0
- package/umd/Options/Interfaces/Interactivity/Modes/IRepulseDiv.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/ISlow.d.ts +5 -0
- package/umd/Options/Interfaces/Interactivity/Modes/ISlow.js +12 -0
- package/umd/Options/Interfaces/Interactivity/Modes/ITrail.d.ts +8 -0
- package/umd/Options/Interfaces/Interactivity/Modes/ITrail.js +12 -0
- package/umd/Options/Interfaces/Motion/IMotion.d.ts +5 -0
- package/umd/Options/Interfaces/Motion/IMotion.js +12 -0
- package/umd/Options/Interfaces/Motion/IMotionReduce.d.ts +4 -0
- package/umd/Options/Interfaces/Motion/IMotionReduce.js +12 -0
- package/umd/Options/Interfaces/Particles/Bounce/IBounce.d.ts +5 -0
- package/umd/Options/Interfaces/Particles/Bounce/IBounce.js +12 -0
- package/umd/Options/Interfaces/Particles/Collisions/ICollisions.d.ts +9 -0
- package/umd/Options/Interfaces/Particles/Collisions/ICollisions.js +12 -0
- package/umd/Options/Interfaces/Particles/Collisions/ICollisionsOverlap.d.ts +4 -0
- package/umd/Options/Interfaces/Particles/Collisions/ICollisionsOverlap.js +12 -0
- package/umd/Options/Interfaces/Particles/Destroy/IDestroy.d.ts +6 -0
- package/umd/Options/Interfaces/Particles/Destroy/IDestroy.js +12 -0
- package/umd/Options/Interfaces/Particles/Destroy/ISplit.d.ts +10 -0
- package/umd/Options/Interfaces/Particles/Destroy/ISplit.js +12 -0
- package/umd/Options/Interfaces/Particles/IParticles.d.ts +52 -0
- package/umd/Options/Interfaces/Particles/IParticles.js +12 -0
- package/umd/Options/Interfaces/Particles/IShadow.d.ts +8 -0
- package/umd/Options/Interfaces/Particles/IShadow.js +12 -0
- package/umd/Options/Interfaces/Particles/IStroke.d.ts +7 -0
- package/umd/Options/Interfaces/Particles/IStroke.js +12 -0
- package/umd/Options/Interfaces/Particles/Life/ILife.d.ts +7 -0
- package/umd/Options/Interfaces/Particles/Life/ILife.js +12 -0
- package/umd/Options/Interfaces/Particles/Life/ILifeDelay.d.ts +4 -0
- package/umd/Options/Interfaces/Particles/Life/ILifeDelay.js +12 -0
- package/umd/Options/Interfaces/Particles/Life/ILifeDuration.d.ts +4 -0
- package/umd/Options/Interfaces/Particles/Life/ILifeDuration.js +12 -0
- package/umd/Options/Interfaces/Particles/Links/ILinks.d.ts +17 -0
- package/umd/Options/Interfaces/Particles/Links/ILinks.js +12 -0
- package/umd/Options/Interfaces/Particles/Links/ILinksShadow.d.ts +6 -0
- package/umd/Options/Interfaces/Particles/Links/ILinksShadow.js +12 -0
- package/umd/Options/Interfaces/Particles/Links/ILinksTriangle.d.ts +7 -0
- package/umd/Options/Interfaces/Particles/Links/ILinksTriangle.js +12 -0
- package/umd/Options/Interfaces/Particles/Move/IAttract.d.ts +8 -0
- package/umd/Options/Interfaces/Particles/Move/IAttract.js +12 -0
- package/umd/Options/Interfaces/Particles/Move/IMove.d.ts +35 -0
- package/umd/Options/Interfaces/Particles/Move/IMove.js +12 -0
- package/umd/Options/Interfaces/Particles/Move/IMoveAngle.d.ts +4 -0
- package/umd/Options/Interfaces/Particles/Move/IMoveAngle.js +12 -0
- package/umd/Options/Interfaces/Particles/Move/IMoveGravity.d.ts +6 -0
- package/umd/Options/Interfaces/Particles/Move/IMoveGravity.js +12 -0
- package/umd/Options/Interfaces/Particles/Move/IOutModes.d.ts +8 -0
- package/umd/Options/Interfaces/Particles/Move/IOutModes.js +12 -0
- package/umd/Options/Interfaces/Particles/Move/ISpin.d.ts +7 -0
- package/umd/Options/Interfaces/Particles/Move/ISpin.js +12 -0
- package/umd/Options/Interfaces/Particles/Move/ITrail.d.ts +6 -0
- package/umd/Options/Interfaces/Particles/Move/ITrail.js +12 -0
- package/umd/Options/Interfaces/Particles/Move/Path/IPath.d.ts +9 -0
- package/umd/Options/Interfaces/Particles/Move/Path/IPath.js +12 -0
- package/umd/Options/Interfaces/Particles/Number/IDensity.d.ts +6 -0
- package/umd/Options/Interfaces/Particles/Number/IDensity.js +12 -0
- package/umd/Options/Interfaces/Particles/Number/IParticlesNumber.d.ts +7 -0
- package/umd/Options/Interfaces/Particles/Number/IParticlesNumber.js +12 -0
- package/umd/Options/Interfaces/Particles/Opacity/IOpacity.d.ts +6 -0
- package/umd/Options/Interfaces/Particles/Opacity/IOpacity.js +12 -0
- package/umd/Options/Interfaces/Particles/Opacity/IOpacityAnimation.d.ts +8 -0
- package/umd/Options/Interfaces/Particles/Opacity/IOpacityAnimation.js +12 -0
- package/umd/Options/Interfaces/Particles/Orbit/IOrbit.d.ts +12 -0
- package/umd/Options/Interfaces/Particles/Orbit/IOrbit.js +12 -0
- package/umd/Options/Interfaces/Particles/Repulse/IRepulse.d.ts +8 -0
- package/umd/Options/Interfaces/Particles/Repulse/IRepulse.js +12 -0
- package/umd/Options/Interfaces/Particles/Roll/IRoll.d.ts +12 -0
- package/umd/Options/Interfaces/Particles/Roll/IRoll.js +12 -0
- package/umd/Options/Interfaces/Particles/Roll/IRollLight.d.ts +4 -0
- package/umd/Options/Interfaces/Particles/Roll/IRollLight.js +12 -0
- package/umd/Options/Interfaces/Particles/Rotate/IRotate.d.ts +8 -0
- package/umd/Options/Interfaces/Particles/Rotate/IRotate.js +12 -0
- package/umd/Options/Interfaces/Particles/Rotate/IRotateAnimation.d.ts +5 -0
- package/umd/Options/Interfaces/Particles/Rotate/IRotateAnimation.js +12 -0
- package/umd/Options/Interfaces/Particles/Shape/ICharacterShape.d.ts +8 -0
- package/umd/Options/Interfaces/Particles/Shape/ICharacterShape.js +12 -0
- package/umd/Options/Interfaces/Particles/Shape/IImageShape.d.ts +8 -0
- package/umd/Options/Interfaces/Particles/Shape/IImageShape.js +12 -0
- package/umd/Options/Interfaces/Particles/Shape/IPolygonShape.d.ts +5 -0
- package/umd/Options/Interfaces/Particles/Shape/IPolygonShape.js +12 -0
- package/umd/Options/Interfaces/Particles/Shape/IShape.d.ts +16 -0
- package/umd/Options/Interfaces/Particles/Shape/IShape.js +12 -0
- package/umd/Options/Interfaces/Particles/Shape/IShapeValues.d.ts +1 -0
- package/umd/Options/Interfaces/Particles/Shape/IShapeValues.js +23 -0
- package/umd/Options/Interfaces/Particles/Shape/IStarShape.d.ts +6 -0
- package/umd/Options/Interfaces/Particles/Shape/IStarShape.js +12 -0
- package/umd/Options/Interfaces/Particles/Size/ISize.d.ts +6 -0
- package/umd/Options/Interfaces/Particles/Size/ISize.js +12 -0
- package/umd/Options/Interfaces/Particles/Size/ISizeAnimation.d.ts +8 -0
- package/umd/Options/Interfaces/Particles/Size/ISizeAnimation.js +12 -0
- package/umd/Options/Interfaces/Particles/Tilt/ITilt.d.ts +8 -0
- package/umd/Options/Interfaces/Particles/Tilt/ITilt.js +12 -0
- package/umd/Options/Interfaces/Particles/Tilt/ITiltAnimation.d.ts +5 -0
- package/umd/Options/Interfaces/Particles/Tilt/ITiltAnimation.js +12 -0
- package/umd/Options/Interfaces/Particles/Twinkle/ITwinkle.d.ts +5 -0
- package/umd/Options/Interfaces/Particles/Twinkle/ITwinkle.js +12 -0
- package/umd/Options/Interfaces/Particles/Twinkle/ITwinkleValues.d.ts +7 -0
- package/umd/Options/Interfaces/Particles/Twinkle/ITwinkleValues.js +12 -0
- package/umd/Options/Interfaces/Particles/Wobble/IWobble.d.ts +6 -0
- package/umd/Options/Interfaces/Particles/Wobble/IWobble.js +12 -0
- package/umd/Options/Interfaces/Particles/ZIndex/IZIndex.d.ts +6 -0
- package/umd/Options/Interfaces/Particles/ZIndex/IZIndex.js +12 -0
- package/umd/Options/Interfaces/Theme/ITheme.d.ts +8 -0
- package/umd/Options/Interfaces/Theme/ITheme.js +12 -0
- package/umd/Options/Interfaces/Theme/IThemeDefault.d.ts +6 -0
- package/umd/Options/Interfaces/Theme/IThemeDefault.js +12 -0
- package/umd/Plugins/Absorbers/AbsorberContainer.d.ts +7 -0
- package/umd/Plugins/Absorbers/AbsorberContainer.js +12 -0
- package/umd/Plugins/Absorbers/AbsorberInstance.d.ts +33 -0
- package/umd/Plugins/Absorbers/AbsorberInstance.js +172 -0
- package/umd/Plugins/Absorbers/Absorbers.d.ts +22 -0
- package/umd/Plugins/Absorbers/Absorbers.js +128 -0
- package/umd/Plugins/Absorbers/Enums/AbsorberClickMode.d.ts +3 -0
- package/umd/Plugins/Absorbers/Enums/AbsorberClickMode.js +12 -0
- package/umd/Plugins/Absorbers/Enums/index.d.ts +1 -0
- package/umd/Plugins/Absorbers/Enums/index.js +23 -0
- package/umd/Plugins/Absorbers/Options/Classes/Absorber.d.ts +18 -0
- package/umd/Plugins/Absorbers/Options/Classes/Absorber.js +57 -0
- package/umd/Plugins/Absorbers/Options/Classes/AbsorberSize.d.ts +11 -0
- package/umd/Plugins/Absorbers/Options/Classes/AbsorberSize.js +40 -0
- package/umd/Plugins/Absorbers/Options/Classes/AbsorberSizeLimit.d.ts +9 -0
- package/umd/Plugins/Absorbers/Options/Classes/AbsorberSizeLimit.js +31 -0
- package/umd/Plugins/Absorbers/Options/Interfaces/IAbsorber.d.ts +13 -0
- package/umd/Plugins/Absorbers/Options/Interfaces/IAbsorber.js +12 -0
- package/umd/Plugins/Absorbers/Options/Interfaces/IAbsorberOptions.d.ts +12 -0
- package/umd/Plugins/Absorbers/Options/Interfaces/IAbsorberOptions.js +12 -0
- package/umd/Plugins/Absorbers/Options/Interfaces/IAbsorberSize.d.ts +6 -0
- package/umd/Plugins/Absorbers/Options/Interfaces/IAbsorberSize.js +12 -0
- package/umd/Plugins/Absorbers/Options/Interfaces/IAbsorberSizeLimit.d.ts +4 -0
- package/umd/Plugins/Absorbers/Options/Interfaces/IAbsorberSizeLimit.js +12 -0
- package/umd/Plugins/Absorbers/index.d.ts +2 -0
- package/umd/Plugins/Absorbers/index.js +90 -0
- package/umd/Plugins/Emitters/EmitterContainer.d.ts +10 -0
- package/umd/Plugins/Emitters/EmitterContainer.js +12 -0
- package/umd/Plugins/Emitters/EmitterInstance.d.ts +45 -0
- package/umd/Plugins/Emitters/EmitterInstance.js +278 -0
- package/umd/Plugins/Emitters/Emitters.d.ts +25 -0
- package/umd/Plugins/Emitters/Emitters.js +163 -0
- package/umd/Plugins/Emitters/EmittersEngine.d.ts +7 -0
- package/umd/Plugins/Emitters/EmittersEngine.js +12 -0
- package/umd/Plugins/Emitters/Enums/EmitterClickMode.d.ts +3 -0
- package/umd/Plugins/Emitters/Enums/EmitterClickMode.js +12 -0
- package/umd/Plugins/Emitters/Enums/EmitterShapeType.d.ts +4 -0
- package/umd/Plugins/Emitters/Enums/EmitterShapeType.js +12 -0
- package/umd/Plugins/Emitters/Enums/index.d.ts +2 -0
- package/umd/Plugins/Emitters/Enums/index.js +24 -0
- package/umd/Plugins/Emitters/IEmitterShape.d.ts +4 -0
- package/umd/Plugins/Emitters/IEmitterShape.js +12 -0
- package/umd/Plugins/Emitters/Options/Classes/Emitter.d.ts +28 -0
- package/umd/Plugins/Emitters/Options/Classes/Emitter.js +74 -0
- package/umd/Plugins/Emitters/Options/Classes/EmitterLife.d.ts +11 -0
- package/umd/Plugins/Emitters/Options/Classes/EmitterLife.js +36 -0
- package/umd/Plugins/Emitters/Options/Classes/EmitterRate.d.ts +9 -0
- package/umd/Plugins/Emitters/Options/Classes/EmitterRate.js +32 -0
- package/umd/Plugins/Emitters/Options/Classes/EmitterSize.d.ts +11 -0
- package/umd/Plugins/Emitters/Options/Classes/EmitterSize.js +35 -0
- package/umd/Plugins/Emitters/Options/Interfaces/IEmitter.d.ts +24 -0
- package/umd/Plugins/Emitters/Options/Interfaces/IEmitter.js +12 -0
- package/umd/Plugins/Emitters/Options/Interfaces/IEmitterLife.d.ts +6 -0
- package/umd/Plugins/Emitters/Options/Interfaces/IEmitterLife.js +12 -0
- package/umd/Plugins/Emitters/Options/Interfaces/IEmitterOptions.d.ts +12 -0
- package/umd/Plugins/Emitters/Options/Interfaces/IEmitterOptions.js +12 -0
- package/umd/Plugins/Emitters/Options/Interfaces/IEmitterRate.d.ts +5 -0
- package/umd/Plugins/Emitters/Options/Interfaces/IEmitterRate.js +12 -0
- package/umd/Plugins/Emitters/Options/Interfaces/IEmitterSize.d.ts +5 -0
- package/umd/Plugins/Emitters/Options/Interfaces/IEmitterSize.js +12 -0
- package/umd/Plugins/Emitters/ShapeManager.d.ts +9 -0
- package/umd/Plugins/Emitters/ShapeManager.js +40 -0
- package/umd/Plugins/Emitters/Shapes/Circle/CircleShape.d.ts +5 -0
- package/umd/Plugins/Emitters/Shapes/Circle/CircleShape.js +42 -0
- package/umd/Plugins/Emitters/Shapes/Square/SquareShape.d.ts +5 -0
- package/umd/Plugins/Emitters/Shapes/Square/SquareShape.js +53 -0
- package/umd/Plugins/Emitters/index.d.ts +3 -0
- package/umd/Plugins/Emitters/index.js +120 -0
- package/umd/Plugins/PolygonMask/Enums/PolygonMaskInlineArrangement.d.ts +8 -0
- package/umd/Plugins/PolygonMask/Enums/PolygonMaskInlineArrangement.js +12 -0
- package/umd/Plugins/PolygonMask/Enums/PolygonMaskMoveType.d.ts +4 -0
- package/umd/Plugins/PolygonMask/Enums/PolygonMaskMoveType.js +12 -0
- package/umd/Plugins/PolygonMask/Enums/PolygonMaskType.d.ts +6 -0
- package/umd/Plugins/PolygonMask/Enums/PolygonMaskType.js +12 -0
- package/umd/Plugins/PolygonMask/Enums/index.d.ts +3 -0
- package/umd/Plugins/PolygonMask/Enums/index.js +25 -0
- package/umd/Plugins/PolygonMask/Interfaces/ISvgPath.d.ts +6 -0
- package/umd/Plugins/PolygonMask/Interfaces/ISvgPath.js +12 -0
- package/umd/Plugins/PolygonMask/Options/Classes/PolygonMask.d.ts +24 -0
- package/umd/Plugins/PolygonMask/Options/Classes/PolygonMask.js +76 -0
- package/umd/Plugins/PolygonMask/Options/Classes/PolygonMaskDraw.d.ts +15 -0
- package/umd/Plugins/PolygonMask/Options/Classes/PolygonMaskDraw.js +48 -0
- package/umd/Plugins/PolygonMask/Options/Classes/PolygonMaskDrawStroke.d.ts +11 -0
- package/umd/Plugins/PolygonMask/Options/Classes/PolygonMaskDrawStroke.js +39 -0
- package/umd/Plugins/PolygonMask/Options/Classes/PolygonMaskInline.d.ts +9 -0
- package/umd/Plugins/PolygonMask/Options/Classes/PolygonMaskInline.js +27 -0
- package/umd/Plugins/PolygonMask/Options/Classes/PolygonMaskLocalSvg.d.ts +11 -0
- package/umd/Plugins/PolygonMask/Options/Classes/PolygonMaskLocalSvg.js +39 -0
- package/umd/Plugins/PolygonMask/Options/Classes/PolygonMaskMove.d.ts +10 -0
- package/umd/Plugins/PolygonMask/Options/Classes/PolygonMaskMove.js +31 -0
- package/umd/Plugins/PolygonMask/Options/Interfaces/IPolygonMask.d.ts +18 -0
- package/umd/Plugins/PolygonMask/Options/Interfaces/IPolygonMask.js +12 -0
- package/umd/Plugins/PolygonMask/Options/Interfaces/IPolygonMaskDraw.d.ts +8 -0
- package/umd/Plugins/PolygonMask/Options/Interfaces/IPolygonMaskDraw.js +12 -0
- package/umd/Plugins/PolygonMask/Options/Interfaces/IPolygonMaskDrawStroke.d.ts +6 -0
- package/umd/Plugins/PolygonMask/Options/Interfaces/IPolygonMaskDrawStroke.js +12 -0
- package/umd/Plugins/PolygonMask/Options/Interfaces/IPolygonMaskInline.d.ts +4 -0
- package/umd/Plugins/PolygonMask/Options/Interfaces/IPolygonMaskInline.js +12 -0
- package/umd/Plugins/PolygonMask/Options/Interfaces/IPolygonMaskLocalSvg.d.ts +6 -0
- package/umd/Plugins/PolygonMask/Options/Interfaces/IPolygonMaskLocalSvg.js +12 -0
- package/umd/Plugins/PolygonMask/Options/Interfaces/IPolygonMaskMove.d.ts +5 -0
- package/umd/Plugins/PolygonMask/Options/Interfaces/IPolygonMaskMove.js +12 -0
- package/umd/Plugins/PolygonMask/Options/Interfaces/IPolygonMaskOptions.d.ts +4 -0
- package/umd/Plugins/PolygonMask/Options/Interfaces/IPolygonMaskOptions.js +12 -0
- package/umd/Plugins/PolygonMask/PolygonMaskInstance.d.ts +38 -0
- package/umd/Plugins/PolygonMask/PolygonMaskInstance.js +396 -0
- package/umd/Plugins/PolygonMask/Types.d.ts +8 -0
- package/umd/Plugins/PolygonMask/Types.js +12 -0
- package/umd/Plugins/PolygonMask/Utils.d.ts +11 -0
- package/umd/Plugins/PolygonMask/Utils.js +134 -0
- package/umd/Plugins/PolygonMask/index.d.ts +2 -0
- package/umd/Plugins/PolygonMask/index.js +67 -0
- package/umd/Plugins/PolygonMask/pathseg.d.ts +0 -0
- package/umd/Plugins/PolygonMask/pathseg.js +1548 -0
- package/umd/Shapes/Circle/CircleDrawer.d.ts +5 -0
- package/umd/Shapes/Circle/CircleDrawer.js +22 -0
- package/umd/Shapes/Circle/index.d.ts +2 -0
- package/umd/Shapes/Circle/index.js +18 -0
- package/umd/Shapes/Image/ImageDrawer.d.ts +18 -0
- package/umd/Shapes/Image/ImageDrawer.js +142 -0
- package/umd/Shapes/Image/Utils.d.ts +28 -0
- package/umd/Shapes/Image/Utils.js +99 -0
- package/umd/Shapes/Image/index.d.ts +2 -0
- package/umd/Shapes/Image/index.js +20 -0
- package/umd/Shapes/Line/LineDrawer.d.ts +5 -0
- package/umd/Shapes/Line/LineDrawer.js +23 -0
- package/umd/Shapes/Line/index.d.ts +2 -0
- package/umd/Shapes/Line/index.js +18 -0
- package/umd/Shapes/Polygon/PolygonDrawer.d.ts +7 -0
- package/umd/Shapes/Polygon/PolygonDrawer.js +36 -0
- package/umd/Shapes/Polygon/PolygonDrawerBase.d.ts +15 -0
- package/umd/Shapes/Polygon/PolygonDrawerBase.js +40 -0
- package/umd/Shapes/Polygon/TriangleDrawer.d.ts +8 -0
- package/umd/Shapes/Polygon/TriangleDrawer.js +35 -0
- package/umd/Shapes/Polygon/index.d.ts +4 -0
- package/umd/Shapes/Polygon/index.js +28 -0
- package/umd/Shapes/Square/SquareDrawer.d.ts +5 -0
- package/umd/Shapes/Square/SquareDrawer.js +23 -0
- package/umd/Shapes/Square/index.d.ts +2 -0
- package/umd/Shapes/Square/index.js +20 -0
- package/umd/Shapes/Star/StarDrawer.d.ts +5 -0
- package/umd/Shapes/Star/StarDrawer.js +34 -0
- package/umd/Shapes/Star/index.d.ts +2 -0
- package/umd/Shapes/Star/index.js +18 -0
- package/umd/Shapes/Text/TextDrawer.d.ts +7 -0
- package/umd/Shapes/Text/TextDrawer.js +75 -0
- package/umd/Shapes/Text/index.d.ts +2 -0
- package/umd/Shapes/Text/index.js +21 -0
- package/umd/Types/ParticlesGroups.d.ts +4 -0
- package/umd/Types/ParticlesGroups.js +12 -0
- package/umd/Types/PathOptions.d.ts +3 -0
- package/umd/Types/PathOptions.js +12 -0
- package/umd/Types/RangeValue.d.ts +2 -0
- package/umd/Types/RangeValue.js +12 -0
- package/umd/Types/RecursivePartial.d.ts +3 -0
- package/umd/Types/RecursivePartial.js +12 -0
- package/umd/Types/ShapeData.d.ts +5 -0
- package/umd/Types/ShapeData.js +12 -0
- package/umd/Types/ShapeDrawerFunctions.d.ts +11 -0
- package/umd/Types/ShapeDrawerFunctions.js +12 -0
- package/umd/Types/SingleOrMultiple.d.ts +1 -0
- package/umd/Types/SingleOrMultiple.js +12 -0
- package/umd/Types/index.d.ts +6 -0
- package/umd/Types/index.js +28 -0
- package/umd/Updaters/Angle/AngleUpdater.d.ts +8 -0
- package/umd/Updaters/Angle/AngleUpdater.js +88 -0
- package/umd/Updaters/Angle/index.d.ts +2 -0
- package/umd/Updaters/Angle/index.js +18 -0
- package/umd/Updaters/Color/ColorUpdater.d.ts +8 -0
- package/umd/Updaters/Color/ColorUpdater.js +77 -0
- package/umd/Updaters/Color/index.d.ts +2 -0
- package/umd/Updaters/Color/index.js +18 -0
- package/umd/Updaters/Life/LifeUpdater.d.ts +8 -0
- package/umd/Updaters/Life/LifeUpdater.js +77 -0
- package/umd/Updaters/Life/index.d.ts +2 -0
- package/umd/Updaters/Life/index.js +18 -0
- package/umd/Updaters/Opacity/OpacityUpdater.d.ts +8 -0
- package/umd/Updaters/Opacity/OpacityUpdater.js +129 -0
- package/umd/Updaters/Opacity/index.d.ts +2 -0
- package/umd/Updaters/Opacity/index.js +18 -0
- package/umd/Updaters/OutModes/IBounceData.d.ts +11 -0
- package/umd/Updaters/OutModes/IBounceData.js +12 -0
- package/umd/Updaters/OutModes/OutOfCanvasUpdater.d.ts +13 -0
- package/umd/Updaters/OutModes/OutOfCanvasUpdater.js +156 -0
- package/umd/Updaters/OutModes/Utils.d.ts +3 -0
- package/umd/Updaters/OutModes/Utils.js +75 -0
- package/umd/Updaters/OutModes/index.d.ts +2 -0
- package/umd/Updaters/OutModes/index.js +18 -0
- package/umd/Updaters/Roll/RollUpdater.d.ts +6 -0
- package/umd/Updaters/Roll/RollUpdater.js +73 -0
- package/umd/Updaters/Roll/index.d.ts +2 -0
- package/umd/Updaters/Roll/index.js +18 -0
- package/umd/Updaters/Size/SizeUpdater.d.ts +6 -0
- package/umd/Updaters/Size/SizeUpdater.js +86 -0
- package/umd/Updaters/Size/index.d.ts +2 -0
- package/umd/Updaters/Size/index.js +18 -0
- package/umd/Updaters/StrokeColor/StrokeColorUpdater.d.ts +8 -0
- package/umd/Updaters/StrokeColor/StrokeColorUpdater.js +94 -0
- package/umd/Updaters/StrokeColor/index.d.ts +2 -0
- package/umd/Updaters/StrokeColor/index.js +18 -0
- package/umd/Updaters/Tilt/TiltUpdater.d.ts +8 -0
- package/umd/Updaters/Tilt/TiltUpdater.js +89 -0
- package/umd/Updaters/Tilt/index.d.ts +2 -0
- package/umd/Updaters/Tilt/index.js +18 -0
- package/umd/Updaters/Wobble/WobbleUpdater.d.ts +14 -0
- package/umd/Updaters/Wobble/WobbleUpdater.js +61 -0
- package/umd/Updaters/Wobble/index.d.ts +2 -0
- package/umd/Updaters/Wobble/index.js +18 -0
- package/umd/Utils/CanvasUtils.d.ts +19 -0
- package/umd/Utils/CanvasUtils.js +297 -0
- package/umd/Utils/ColorUtils.d.ts +26 -0
- package/umd/Utils/ColorUtils.js +486 -0
- package/umd/Utils/NumberUtils.d.ts +23 -0
- package/umd/Utils/NumberUtils.js +138 -0
- package/umd/Utils/Utils.d.ts +38 -0
- package/umd/Utils/Utils.js +279 -0
- package/umd/Utils/index.d.ts +4 -0
- package/umd/Utils/index.js +26 -0
- package/umd/engine.d.ts +26 -0
- package/umd/engine.js +108 -0
- package/umd/full.d.ts +2 -0
- package/umd/full.js +32 -0
- package/umd/index.d.ts +20 -0
- package/umd/index.engine.d.ts +13 -0
- package/umd/index.engine.js +37 -0
- package/umd/index.js +43 -0
- package/umd/index.slim.d.ts +14 -0
- package/umd/index.slim.js +40 -0
- package/umd/pjs.d.ts +14 -0
- package/umd/pjs.js +36 -0
- package/umd/slim.d.ts +2 -0
- package/umd/slim.js +62 -0
|
@@ -0,0 +1,331 @@
|
|
|
1
|
+
var __classPrivateFieldSet = (this && this.__classPrivateFieldSet) || function (receiver, state, value, kind, f) {
|
|
2
|
+
if (kind === "m") throw new TypeError("Private method is not writable");
|
|
3
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a setter");
|
|
4
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot write private member to an object whose class did not declare it");
|
|
5
|
+
return (kind === "a" ? f.call(receiver, value) : f ? f.value = value : state.set(receiver, value)), value;
|
|
6
|
+
};
|
|
7
|
+
var __classPrivateFieldGet = (this && this.__classPrivateFieldGet) || function (receiver, state, kind, f) {
|
|
8
|
+
if (kind === "a" && !f) throw new TypeError("Private accessor was defined without a getter");
|
|
9
|
+
if (typeof state === "function" ? receiver !== state || !f : !state.has(receiver)) throw new TypeError("Cannot read private member from an object whose class did not declare it");
|
|
10
|
+
return kind === "m" ? f : kind === "a" ? f.call(receiver) : f ? f.value : state.get(receiver);
|
|
11
|
+
};
|
|
12
|
+
(function (factory) {
|
|
13
|
+
if (typeof module === "object" && typeof module.exports === "object") {
|
|
14
|
+
var v = factory(require, exports);
|
|
15
|
+
if (v !== undefined) module.exports = v;
|
|
16
|
+
}
|
|
17
|
+
else if (typeof define === "function" && define.amd) {
|
|
18
|
+
define(["require", "exports", "./Utils", "../Utils", "./Particle", "../Options/Classes/Particles/ParticlesOptions"], factory);
|
|
19
|
+
}
|
|
20
|
+
})(function (require, exports) {
|
|
21
|
+
"use strict";
|
|
22
|
+
var _Particles_engine;
|
|
23
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
24
|
+
exports.Particles = void 0;
|
|
25
|
+
const Utils_1 = require("./Utils");
|
|
26
|
+
const Utils_2 = require("../Utils");
|
|
27
|
+
const Particle_1 = require("./Particle");
|
|
28
|
+
const ParticlesOptions_1 = require("../Options/Classes/Particles/ParticlesOptions");
|
|
29
|
+
class Particles {
|
|
30
|
+
constructor(engine, container) {
|
|
31
|
+
this.container = container;
|
|
32
|
+
_Particles_engine.set(this, void 0);
|
|
33
|
+
__classPrivateFieldSet(this, _Particles_engine, engine, "f");
|
|
34
|
+
this.nextId = 0;
|
|
35
|
+
this.array = [];
|
|
36
|
+
this.zArray = [];
|
|
37
|
+
this.mover = new Utils_1.ParticlesMover(container);
|
|
38
|
+
this.limit = 0;
|
|
39
|
+
this.needsSort = false;
|
|
40
|
+
this.lastZIndex = 0;
|
|
41
|
+
this.freqs = {
|
|
42
|
+
links: new Map(),
|
|
43
|
+
triangles: new Map(),
|
|
44
|
+
};
|
|
45
|
+
this.interactionManager = new Utils_1.InteractionManager(__classPrivateFieldGet(this, _Particles_engine, "f"), container);
|
|
46
|
+
const canvasSize = this.container.canvas.size;
|
|
47
|
+
this.linksColors = new Map();
|
|
48
|
+
this.quadTree = new Utils_1.QuadTree(new Utils_1.Rectangle(-canvasSize.width / 4, -canvasSize.height / 4, (canvasSize.width * 3) / 2, (canvasSize.height * 3) / 2), 4);
|
|
49
|
+
this.updaters = __classPrivateFieldGet(this, _Particles_engine, "f").plugins.getUpdaters(container, true);
|
|
50
|
+
}
|
|
51
|
+
get count() {
|
|
52
|
+
return this.array.length;
|
|
53
|
+
}
|
|
54
|
+
init() {
|
|
55
|
+
var _a;
|
|
56
|
+
const container = this.container;
|
|
57
|
+
const options = container.actualOptions;
|
|
58
|
+
this.lastZIndex = 0;
|
|
59
|
+
this.needsSort = false;
|
|
60
|
+
this.freqs.links = new Map();
|
|
61
|
+
this.freqs.triangles = new Map();
|
|
62
|
+
let handled = false;
|
|
63
|
+
this.updaters = __classPrivateFieldGet(this, _Particles_engine, "f").plugins.getUpdaters(container, true);
|
|
64
|
+
this.interactionManager.init();
|
|
65
|
+
for (const [, plugin] of container.plugins) {
|
|
66
|
+
if (plugin.particlesInitialization !== undefined) {
|
|
67
|
+
handled = plugin.particlesInitialization();
|
|
68
|
+
}
|
|
69
|
+
if (handled) {
|
|
70
|
+
break;
|
|
71
|
+
}
|
|
72
|
+
}
|
|
73
|
+
this.addManualParticles();
|
|
74
|
+
if (!handled) {
|
|
75
|
+
for (const group in options.particles.groups) {
|
|
76
|
+
const groupOptions = options.particles.groups[group];
|
|
77
|
+
for (let i = this.count, j = 0; j < ((_a = groupOptions.number) === null || _a === void 0 ? void 0 : _a.value) && i < options.particles.number.value; i++, j++) {
|
|
78
|
+
this.addParticle(undefined, groupOptions, group);
|
|
79
|
+
}
|
|
80
|
+
}
|
|
81
|
+
for (let i = this.count; i < options.particles.number.value; i++) {
|
|
82
|
+
this.addParticle();
|
|
83
|
+
}
|
|
84
|
+
}
|
|
85
|
+
container.pathGenerator.init(container);
|
|
86
|
+
}
|
|
87
|
+
redraw() {
|
|
88
|
+
this.clear();
|
|
89
|
+
this.init();
|
|
90
|
+
this.draw({ value: 0, factor: 0 });
|
|
91
|
+
}
|
|
92
|
+
removeAt(index, quantity = 1, group, override) {
|
|
93
|
+
if (!(index >= 0 && index <= this.count)) {
|
|
94
|
+
return;
|
|
95
|
+
}
|
|
96
|
+
let deleted = 0;
|
|
97
|
+
for (let i = index; deleted < quantity && i < this.count; i++) {
|
|
98
|
+
const particle = this.array[i];
|
|
99
|
+
if (!particle || particle.group !== group) {
|
|
100
|
+
continue;
|
|
101
|
+
}
|
|
102
|
+
particle.destroy(override);
|
|
103
|
+
this.array.splice(i--, 1);
|
|
104
|
+
const zIdx = this.zArray.indexOf(particle);
|
|
105
|
+
this.zArray.splice(zIdx, 1);
|
|
106
|
+
deleted++;
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
remove(particle, group, override) {
|
|
110
|
+
this.removeAt(this.array.indexOf(particle), undefined, group, override);
|
|
111
|
+
}
|
|
112
|
+
update(delta) {
|
|
113
|
+
const container = this.container;
|
|
114
|
+
const particlesToDelete = [];
|
|
115
|
+
container.pathGenerator.update();
|
|
116
|
+
for (const [, plugin] of container.plugins) {
|
|
117
|
+
if (plugin.update !== undefined) {
|
|
118
|
+
plugin.update(delta);
|
|
119
|
+
}
|
|
120
|
+
}
|
|
121
|
+
for (const particle of this.array) {
|
|
122
|
+
const resizeFactor = container.canvas.resizeFactor;
|
|
123
|
+
if (resizeFactor) {
|
|
124
|
+
particle.position.x *= resizeFactor.width;
|
|
125
|
+
particle.position.y *= resizeFactor.height;
|
|
126
|
+
}
|
|
127
|
+
particle.bubble.inRange = false;
|
|
128
|
+
for (const [, plugin] of this.container.plugins) {
|
|
129
|
+
if (particle.destroyed) {
|
|
130
|
+
break;
|
|
131
|
+
}
|
|
132
|
+
if (plugin.particleUpdate) {
|
|
133
|
+
plugin.particleUpdate(particle, delta);
|
|
134
|
+
}
|
|
135
|
+
}
|
|
136
|
+
this.mover.move(particle, delta);
|
|
137
|
+
if (particle.destroyed) {
|
|
138
|
+
particlesToDelete.push(particle);
|
|
139
|
+
continue;
|
|
140
|
+
}
|
|
141
|
+
this.quadTree.insert(new Utils_1.Point(particle.getPosition(), particle));
|
|
142
|
+
}
|
|
143
|
+
for (const particle of particlesToDelete) {
|
|
144
|
+
this.remove(particle);
|
|
145
|
+
}
|
|
146
|
+
this.interactionManager.externalInteract(delta);
|
|
147
|
+
for (const particle of container.particles.array) {
|
|
148
|
+
for (const updater of this.updaters) {
|
|
149
|
+
updater.update(particle, delta);
|
|
150
|
+
}
|
|
151
|
+
if (!particle.destroyed && !particle.spawning) {
|
|
152
|
+
this.interactionManager.particlesInteract(particle, delta);
|
|
153
|
+
}
|
|
154
|
+
}
|
|
155
|
+
delete container.canvas.resizeFactor;
|
|
156
|
+
}
|
|
157
|
+
draw(delta) {
|
|
158
|
+
const container = this.container;
|
|
159
|
+
container.canvas.clear();
|
|
160
|
+
const canvasSize = this.container.canvas.size;
|
|
161
|
+
this.quadTree = new Utils_1.QuadTree(new Utils_1.Rectangle(-canvasSize.width / 4, -canvasSize.height / 4, (canvasSize.width * 3) / 2, (canvasSize.height * 3) / 2), 4);
|
|
162
|
+
this.update(delta);
|
|
163
|
+
if (this.needsSort) {
|
|
164
|
+
this.zArray.sort((a, b) => b.position.z - a.position.z || a.id - b.id);
|
|
165
|
+
this.lastZIndex = this.zArray[this.zArray.length - 1].position.z;
|
|
166
|
+
this.needsSort = false;
|
|
167
|
+
}
|
|
168
|
+
for (const [, plugin] of container.plugins) {
|
|
169
|
+
container.canvas.drawPlugin(plugin, delta);
|
|
170
|
+
}
|
|
171
|
+
for (const p of this.zArray) {
|
|
172
|
+
p.draw(delta);
|
|
173
|
+
}
|
|
174
|
+
}
|
|
175
|
+
clear() {
|
|
176
|
+
this.array = [];
|
|
177
|
+
this.zArray = [];
|
|
178
|
+
}
|
|
179
|
+
push(nb, mouse, overrideOptions, group) {
|
|
180
|
+
this.pushing = true;
|
|
181
|
+
for (let i = 0; i < nb; i++) {
|
|
182
|
+
this.addParticle(mouse === null || mouse === void 0 ? void 0 : mouse.position, overrideOptions, group);
|
|
183
|
+
}
|
|
184
|
+
this.pushing = false;
|
|
185
|
+
}
|
|
186
|
+
addParticle(position, overrideOptions, group) {
|
|
187
|
+
const container = this.container, options = container.actualOptions, limit = options.particles.number.limit * container.density;
|
|
188
|
+
if (limit > 0) {
|
|
189
|
+
const countToRemove = this.count + 1 - limit;
|
|
190
|
+
if (countToRemove > 0) {
|
|
191
|
+
this.removeQuantity(countToRemove);
|
|
192
|
+
}
|
|
193
|
+
}
|
|
194
|
+
return this.pushParticle(position, overrideOptions, group);
|
|
195
|
+
}
|
|
196
|
+
addSplitParticle(parent) {
|
|
197
|
+
const splitOptions = parent.options.destroy.split, options = new ParticlesOptions_1.ParticlesOptions();
|
|
198
|
+
options.load(parent.options);
|
|
199
|
+
const factor = (0, Utils_2.getRangeValue)(splitOptions.factor.value);
|
|
200
|
+
options.color.load({
|
|
201
|
+
value: {
|
|
202
|
+
hsl: parent.getFillColor(),
|
|
203
|
+
},
|
|
204
|
+
});
|
|
205
|
+
if (typeof options.size.value === "number") {
|
|
206
|
+
options.size.value /= factor;
|
|
207
|
+
}
|
|
208
|
+
else {
|
|
209
|
+
options.size.value.min /= factor;
|
|
210
|
+
options.size.value.max /= factor;
|
|
211
|
+
}
|
|
212
|
+
options.load(splitOptions.particles);
|
|
213
|
+
const offset = splitOptions.sizeOffset ? (0, Utils_2.setRangeValue)(-parent.size.value, parent.size.value) : 0;
|
|
214
|
+
const position = {
|
|
215
|
+
x: parent.position.x + (0, Utils_2.randomInRange)(offset),
|
|
216
|
+
y: parent.position.y + (0, Utils_2.randomInRange)(offset),
|
|
217
|
+
};
|
|
218
|
+
return this.pushParticle(position, options, parent.group, (particle) => {
|
|
219
|
+
if (particle.size.value < 0.5) {
|
|
220
|
+
return false;
|
|
221
|
+
}
|
|
222
|
+
particle.velocity.length = (0, Utils_2.randomInRange)((0, Utils_2.setRangeValue)(parent.velocity.length, particle.velocity.length));
|
|
223
|
+
particle.splitCount = parent.splitCount + 1;
|
|
224
|
+
particle.unbreakable = true;
|
|
225
|
+
setTimeout(() => {
|
|
226
|
+
particle.unbreakable = false;
|
|
227
|
+
}, 500);
|
|
228
|
+
return true;
|
|
229
|
+
});
|
|
230
|
+
}
|
|
231
|
+
removeQuantity(quantity, group) {
|
|
232
|
+
this.removeAt(0, quantity, group);
|
|
233
|
+
}
|
|
234
|
+
getLinkFrequency(p1, p2) {
|
|
235
|
+
const range = (0, Utils_2.setRangeValue)(p1.id, p2.id), key = `${(0, Utils_2.getRangeMin)(range)}_${(0, Utils_2.getRangeMax)(range)}`;
|
|
236
|
+
let res = this.freqs.links.get(key);
|
|
237
|
+
if (res === undefined) {
|
|
238
|
+
res = Math.random();
|
|
239
|
+
this.freqs.links.set(key, res);
|
|
240
|
+
}
|
|
241
|
+
return res;
|
|
242
|
+
}
|
|
243
|
+
getTriangleFrequency(p1, p2, p3) {
|
|
244
|
+
let [id1, id2, id3] = [p1.id, p2.id, p3.id];
|
|
245
|
+
if (id1 > id2) {
|
|
246
|
+
[id2, id1] = [id1, id2];
|
|
247
|
+
}
|
|
248
|
+
if (id2 > id3) {
|
|
249
|
+
[id3, id2] = [id2, id3];
|
|
250
|
+
}
|
|
251
|
+
if (id1 > id3) {
|
|
252
|
+
[id3, id1] = [id1, id3];
|
|
253
|
+
}
|
|
254
|
+
const key = `${id1}_${id2}_${id3}`;
|
|
255
|
+
let res = this.freqs.triangles.get(key);
|
|
256
|
+
if (res === undefined) {
|
|
257
|
+
res = Math.random();
|
|
258
|
+
this.freqs.triangles.set(key, res);
|
|
259
|
+
}
|
|
260
|
+
return res;
|
|
261
|
+
}
|
|
262
|
+
addManualParticles() {
|
|
263
|
+
const container = this.container, options = container.actualOptions;
|
|
264
|
+
for (const particle of options.manualParticles) {
|
|
265
|
+
const pos = particle.position
|
|
266
|
+
? {
|
|
267
|
+
x: (particle.position.x * container.canvas.size.width) / 100,
|
|
268
|
+
y: (particle.position.y * container.canvas.size.height) / 100,
|
|
269
|
+
}
|
|
270
|
+
: undefined;
|
|
271
|
+
this.addParticle(pos, particle.options);
|
|
272
|
+
}
|
|
273
|
+
}
|
|
274
|
+
setDensity() {
|
|
275
|
+
const options = this.container.actualOptions;
|
|
276
|
+
for (const group in options.particles.groups) {
|
|
277
|
+
this.applyDensity(options.particles.groups[group], 0, group);
|
|
278
|
+
}
|
|
279
|
+
this.applyDensity(options.particles, options.manualParticles.length);
|
|
280
|
+
}
|
|
281
|
+
applyDensity(options, manualCount, group) {
|
|
282
|
+
var _a;
|
|
283
|
+
if (!((_a = options.number.density) === null || _a === void 0 ? void 0 : _a.enable)) {
|
|
284
|
+
return;
|
|
285
|
+
}
|
|
286
|
+
const numberOptions = options.number;
|
|
287
|
+
const densityFactor = this.initDensityFactor(numberOptions.density);
|
|
288
|
+
const optParticlesNumber = numberOptions.value;
|
|
289
|
+
const optParticlesLimit = numberOptions.limit > 0 ? numberOptions.limit : optParticlesNumber;
|
|
290
|
+
const particlesNumber = Math.min(optParticlesNumber, optParticlesLimit) * densityFactor + manualCount;
|
|
291
|
+
const particlesCount = Math.min(this.count, this.array.filter((t) => t.group === group).length);
|
|
292
|
+
this.limit = numberOptions.limit * densityFactor;
|
|
293
|
+
if (particlesCount < particlesNumber) {
|
|
294
|
+
this.push(Math.abs(particlesNumber - particlesCount), undefined, options, group);
|
|
295
|
+
}
|
|
296
|
+
else if (particlesCount > particlesNumber) {
|
|
297
|
+
this.removeQuantity(particlesCount - particlesNumber, group);
|
|
298
|
+
}
|
|
299
|
+
}
|
|
300
|
+
initDensityFactor(densityOptions) {
|
|
301
|
+
const container = this.container;
|
|
302
|
+
if (!container.canvas.element || !densityOptions.enable) {
|
|
303
|
+
return 1;
|
|
304
|
+
}
|
|
305
|
+
const canvas = container.canvas.element, pxRatio = container.retina.pixelRatio;
|
|
306
|
+
return (canvas.width * canvas.height) / (densityOptions.factor * pxRatio ** 2 * densityOptions.area);
|
|
307
|
+
}
|
|
308
|
+
pushParticle(position, overrideOptions, group, initializer) {
|
|
309
|
+
try {
|
|
310
|
+
const particle = new Particle_1.Particle(__classPrivateFieldGet(this, _Particles_engine, "f"), this.nextId, this.container, position, overrideOptions, group);
|
|
311
|
+
let canAdd = true;
|
|
312
|
+
if (initializer) {
|
|
313
|
+
canAdd = initializer(particle);
|
|
314
|
+
}
|
|
315
|
+
if (!canAdd) {
|
|
316
|
+
return;
|
|
317
|
+
}
|
|
318
|
+
this.array.push(particle);
|
|
319
|
+
this.zArray.push(particle);
|
|
320
|
+
this.nextId++;
|
|
321
|
+
return particle;
|
|
322
|
+
}
|
|
323
|
+
catch (e) {
|
|
324
|
+
console.warn(`error adding particle: ${e}`);
|
|
325
|
+
return;
|
|
326
|
+
}
|
|
327
|
+
}
|
|
328
|
+
}
|
|
329
|
+
exports.Particles = Particles;
|
|
330
|
+
_Particles_engine = new WeakMap();
|
|
331
|
+
});
|
|
@@ -0,0 +1,26 @@
|
|
|
1
|
+
import type { Container } from "./Container";
|
|
2
|
+
import type { Particle } from "./Particle";
|
|
3
|
+
export declare class Retina {
|
|
4
|
+
private readonly container;
|
|
5
|
+
reduceFactor: number;
|
|
6
|
+
bubbleModeDistance: number;
|
|
7
|
+
bubbleModeSize?: number;
|
|
8
|
+
connectModeDistance: number;
|
|
9
|
+
connectModeRadius: number;
|
|
10
|
+
grabModeDistance: number;
|
|
11
|
+
repulseModeDistance: number;
|
|
12
|
+
attractModeDistance: number;
|
|
13
|
+
attractDistance: number;
|
|
14
|
+
slowModeRadius: number;
|
|
15
|
+
linksDistance: number;
|
|
16
|
+
linksWidth: number;
|
|
17
|
+
sizeAnimationSpeed: number;
|
|
18
|
+
pixelRatio: number;
|
|
19
|
+
bounceModeDistance: number;
|
|
20
|
+
maxSpeed: number;
|
|
21
|
+
orbitRadius?: number;
|
|
22
|
+
constructor(container: Container);
|
|
23
|
+
init(): void;
|
|
24
|
+
initParticle(particle: Particle): void;
|
|
25
|
+
private handleMotionChange;
|
|
26
|
+
}
|
|
@@ -0,0 +1,107 @@
|
|
|
1
|
+
(function (factory) {
|
|
2
|
+
if (typeof module === "object" && typeof module.exports === "object") {
|
|
3
|
+
var v = factory(require, exports);
|
|
4
|
+
if (v !== undefined) module.exports = v;
|
|
5
|
+
}
|
|
6
|
+
else if (typeof define === "function" && define.amd) {
|
|
7
|
+
define(["require", "exports", "../Utils"], factory);
|
|
8
|
+
}
|
|
9
|
+
})(function (require, exports) {
|
|
10
|
+
"use strict";
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.Retina = void 0;
|
|
13
|
+
const Utils_1 = require("../Utils");
|
|
14
|
+
class Retina {
|
|
15
|
+
constructor(container) {
|
|
16
|
+
this.container = container;
|
|
17
|
+
}
|
|
18
|
+
init() {
|
|
19
|
+
const container = this.container;
|
|
20
|
+
const options = container.actualOptions;
|
|
21
|
+
this.pixelRatio = !options.detectRetina || (0, Utils_1.isSsr)() ? 1 : window.devicePixelRatio;
|
|
22
|
+
const motionOptions = this.container.actualOptions.motion;
|
|
23
|
+
if (motionOptions && (motionOptions.disable || motionOptions.reduce.value)) {
|
|
24
|
+
if ((0, Utils_1.isSsr)() || typeof matchMedia === "undefined" || !matchMedia) {
|
|
25
|
+
this.reduceFactor = 1;
|
|
26
|
+
}
|
|
27
|
+
else {
|
|
28
|
+
const mediaQuery = matchMedia("(prefers-reduced-motion: reduce)");
|
|
29
|
+
if (mediaQuery) {
|
|
30
|
+
this.handleMotionChange(mediaQuery);
|
|
31
|
+
const handleChange = () => {
|
|
32
|
+
this.handleMotionChange(mediaQuery);
|
|
33
|
+
container.refresh().catch(() => {
|
|
34
|
+
});
|
|
35
|
+
};
|
|
36
|
+
if (mediaQuery.addEventListener !== undefined) {
|
|
37
|
+
mediaQuery.addEventListener("change", handleChange);
|
|
38
|
+
}
|
|
39
|
+
else if (mediaQuery.addListener !== undefined) {
|
|
40
|
+
mediaQuery.addListener(handleChange);
|
|
41
|
+
}
|
|
42
|
+
}
|
|
43
|
+
}
|
|
44
|
+
}
|
|
45
|
+
else {
|
|
46
|
+
this.reduceFactor = 1;
|
|
47
|
+
}
|
|
48
|
+
const ratio = this.pixelRatio;
|
|
49
|
+
if (container.canvas.element) {
|
|
50
|
+
const element = container.canvas.element;
|
|
51
|
+
container.canvas.size.width = element.offsetWidth * ratio;
|
|
52
|
+
container.canvas.size.height = element.offsetHeight * ratio;
|
|
53
|
+
}
|
|
54
|
+
const particles = options.particles;
|
|
55
|
+
this.attractDistance = particles.move.attract.distance * ratio;
|
|
56
|
+
this.linksDistance = particles.links.distance * ratio;
|
|
57
|
+
this.linksWidth = particles.links.width * ratio;
|
|
58
|
+
this.sizeAnimationSpeed = particles.size.animation.speed * ratio;
|
|
59
|
+
this.maxSpeed = particles.move.gravity.maxSpeed * ratio;
|
|
60
|
+
if (particles.orbit.radius !== undefined) {
|
|
61
|
+
this.orbitRadius = particles.orbit.radius * this.container.retina.pixelRatio;
|
|
62
|
+
}
|
|
63
|
+
const modes = options.interactivity.modes;
|
|
64
|
+
this.connectModeDistance = modes.connect.distance * ratio;
|
|
65
|
+
this.connectModeRadius = modes.connect.radius * ratio;
|
|
66
|
+
this.grabModeDistance = modes.grab.distance * ratio;
|
|
67
|
+
this.repulseModeDistance = modes.repulse.distance * ratio;
|
|
68
|
+
this.bounceModeDistance = modes.bounce.distance * ratio;
|
|
69
|
+
this.attractModeDistance = modes.attract.distance * ratio;
|
|
70
|
+
this.slowModeRadius = modes.slow.radius * ratio;
|
|
71
|
+
this.bubbleModeDistance = modes.bubble.distance * ratio;
|
|
72
|
+
if (modes.bubble.size) {
|
|
73
|
+
this.bubbleModeSize = modes.bubble.size * ratio;
|
|
74
|
+
}
|
|
75
|
+
}
|
|
76
|
+
initParticle(particle) {
|
|
77
|
+
const options = particle.options;
|
|
78
|
+
const ratio = this.pixelRatio;
|
|
79
|
+
const moveDistance = options.move.distance;
|
|
80
|
+
const props = particle.retina;
|
|
81
|
+
props.attractDistance = options.move.attract.distance * ratio;
|
|
82
|
+
props.linksDistance = options.links.distance * ratio;
|
|
83
|
+
props.linksWidth = options.links.width * ratio;
|
|
84
|
+
props.moveDrift = (0, Utils_1.getRangeValue)(options.move.drift) * ratio;
|
|
85
|
+
props.moveSpeed = (0, Utils_1.getRangeValue)(options.move.speed) * ratio;
|
|
86
|
+
props.sizeAnimationSpeed = options.size.animation.speed * ratio;
|
|
87
|
+
if (particle.spin) {
|
|
88
|
+
props.spinAcceleration = (0, Utils_1.getRangeValue)(options.move.spin.acceleration) * ratio;
|
|
89
|
+
}
|
|
90
|
+
const maxDistance = props.maxDistance;
|
|
91
|
+
maxDistance.horizontal = moveDistance.horizontal !== undefined ? moveDistance.horizontal * ratio : undefined;
|
|
92
|
+
maxDistance.vertical = moveDistance.vertical !== undefined ? moveDistance.vertical * ratio : undefined;
|
|
93
|
+
props.maxSpeed = options.move.gravity.maxSpeed * ratio;
|
|
94
|
+
}
|
|
95
|
+
handleMotionChange(mediaQuery) {
|
|
96
|
+
const options = this.container.actualOptions;
|
|
97
|
+
if (mediaQuery.matches) {
|
|
98
|
+
const motion = options.motion;
|
|
99
|
+
this.reduceFactor = motion.disable ? 0 : motion.reduce.value ? 1 / motion.reduce.factor : 1;
|
|
100
|
+
}
|
|
101
|
+
else {
|
|
102
|
+
this.reduceFactor = 1;
|
|
103
|
+
}
|
|
104
|
+
}
|
|
105
|
+
}
|
|
106
|
+
exports.Retina = Retina;
|
|
107
|
+
});
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import type { ICoordinates } from "../Interfaces";
|
|
2
|
+
import { Range } from "./Range";
|
|
3
|
+
export declare class Circle extends Range {
|
|
4
|
+
readonly radius: number;
|
|
5
|
+
constructor(x: number, y: number, radius: number);
|
|
6
|
+
contains(point: ICoordinates): boolean;
|
|
7
|
+
intersects(range: Range): boolean;
|
|
8
|
+
}
|
|
@@ -0,0 +1,52 @@
|
|
|
1
|
+
(function (factory) {
|
|
2
|
+
if (typeof module === "object" && typeof module.exports === "object") {
|
|
3
|
+
var v = factory(require, exports);
|
|
4
|
+
if (v !== undefined) module.exports = v;
|
|
5
|
+
}
|
|
6
|
+
else if (typeof define === "function" && define.amd) {
|
|
7
|
+
define(["require", "exports", "./Range", "../../Utils"], factory);
|
|
8
|
+
}
|
|
9
|
+
})(function (require, exports) {
|
|
10
|
+
"use strict";
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.Circle = void 0;
|
|
13
|
+
const Range_1 = require("./Range");
|
|
14
|
+
const Utils_1 = require("../../Utils");
|
|
15
|
+
class Circle extends Range_1.Range {
|
|
16
|
+
constructor(x, y, radius) {
|
|
17
|
+
super(x, y);
|
|
18
|
+
this.radius = radius;
|
|
19
|
+
}
|
|
20
|
+
contains(point) {
|
|
21
|
+
return (0, Utils_1.getDistance)(point, this.position) <= this.radius;
|
|
22
|
+
}
|
|
23
|
+
intersects(range) {
|
|
24
|
+
const rect = range;
|
|
25
|
+
const circle = range;
|
|
26
|
+
const pos1 = this.position;
|
|
27
|
+
const pos2 = range.position;
|
|
28
|
+
const xDist = Math.abs(pos2.x - pos1.x);
|
|
29
|
+
const yDist = Math.abs(pos2.y - pos1.y);
|
|
30
|
+
const r = this.radius;
|
|
31
|
+
if (circle.radius !== undefined) {
|
|
32
|
+
const rSum = r + circle.radius;
|
|
33
|
+
const dist = Math.sqrt(xDist * xDist + yDist + yDist);
|
|
34
|
+
return rSum > dist;
|
|
35
|
+
}
|
|
36
|
+
else if (rect.size !== undefined) {
|
|
37
|
+
const w = rect.size.width;
|
|
38
|
+
const h = rect.size.height;
|
|
39
|
+
const edges = Math.pow(xDist - w, 2) + Math.pow(yDist - h, 2);
|
|
40
|
+
if (xDist > r + w || yDist > r + h) {
|
|
41
|
+
return false;
|
|
42
|
+
}
|
|
43
|
+
if (xDist <= w || yDist <= h) {
|
|
44
|
+
return true;
|
|
45
|
+
}
|
|
46
|
+
return edges <= r * r;
|
|
47
|
+
}
|
|
48
|
+
return false;
|
|
49
|
+
}
|
|
50
|
+
}
|
|
51
|
+
exports.Circle = Circle;
|
|
52
|
+
});
|
|
@@ -0,0 +1,9 @@
|
|
|
1
|
+
import type { ICoordinates, IDimension } from "../Interfaces";
|
|
2
|
+
import { Circle } from "./Circle";
|
|
3
|
+
import { Range } from "./Range";
|
|
4
|
+
export declare class CircleWarp extends Circle {
|
|
5
|
+
private readonly canvasSize;
|
|
6
|
+
constructor(x: number, y: number, radius: number, canvasSize: IDimension);
|
|
7
|
+
contains(point: ICoordinates): boolean;
|
|
8
|
+
intersects(range: Range): boolean;
|
|
9
|
+
}
|
|
@@ -0,0 +1,70 @@
|
|
|
1
|
+
(function (factory) {
|
|
2
|
+
if (typeof module === "object" && typeof module.exports === "object") {
|
|
3
|
+
var v = factory(require, exports);
|
|
4
|
+
if (v !== undefined) module.exports = v;
|
|
5
|
+
}
|
|
6
|
+
else if (typeof define === "function" && define.amd) {
|
|
7
|
+
define(["require", "exports", "./Circle", "./Rectangle"], factory);
|
|
8
|
+
}
|
|
9
|
+
})(function (require, exports) {
|
|
10
|
+
"use strict";
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.CircleWarp = void 0;
|
|
13
|
+
const Circle_1 = require("./Circle");
|
|
14
|
+
const Rectangle_1 = require("./Rectangle");
|
|
15
|
+
class CircleWarp extends Circle_1.Circle {
|
|
16
|
+
constructor(x, y, radius, canvasSize) {
|
|
17
|
+
super(x, y, radius);
|
|
18
|
+
this.canvasSize = canvasSize;
|
|
19
|
+
this.canvasSize = {
|
|
20
|
+
height: canvasSize.height,
|
|
21
|
+
width: canvasSize.width,
|
|
22
|
+
};
|
|
23
|
+
}
|
|
24
|
+
contains(point) {
|
|
25
|
+
if (super.contains(point)) {
|
|
26
|
+
return true;
|
|
27
|
+
}
|
|
28
|
+
const posNE = {
|
|
29
|
+
x: point.x - this.canvasSize.width,
|
|
30
|
+
y: point.y,
|
|
31
|
+
};
|
|
32
|
+
if (super.contains(posNE)) {
|
|
33
|
+
return true;
|
|
34
|
+
}
|
|
35
|
+
const posSE = {
|
|
36
|
+
x: point.x - this.canvasSize.width,
|
|
37
|
+
y: point.y - this.canvasSize.height,
|
|
38
|
+
};
|
|
39
|
+
if (super.contains(posSE)) {
|
|
40
|
+
return true;
|
|
41
|
+
}
|
|
42
|
+
const posSW = {
|
|
43
|
+
x: point.x,
|
|
44
|
+
y: point.y - this.canvasSize.height,
|
|
45
|
+
};
|
|
46
|
+
return super.contains(posSW);
|
|
47
|
+
}
|
|
48
|
+
intersects(range) {
|
|
49
|
+
if (super.intersects(range)) {
|
|
50
|
+
return true;
|
|
51
|
+
}
|
|
52
|
+
const rect = range;
|
|
53
|
+
const circle = range;
|
|
54
|
+
const newPos = {
|
|
55
|
+
x: range.position.x - this.canvasSize.width,
|
|
56
|
+
y: range.position.y - this.canvasSize.height,
|
|
57
|
+
};
|
|
58
|
+
if (circle.radius !== undefined) {
|
|
59
|
+
const biggerCircle = new Circle_1.Circle(newPos.x, newPos.y, circle.radius * 2);
|
|
60
|
+
return super.intersects(biggerCircle);
|
|
61
|
+
}
|
|
62
|
+
else if (rect.size !== undefined) {
|
|
63
|
+
const rectSW = new Rectangle_1.Rectangle(newPos.x, newPos.y, rect.size.width * 2, rect.size.height * 2);
|
|
64
|
+
return super.intersects(rectSW);
|
|
65
|
+
}
|
|
66
|
+
return false;
|
|
67
|
+
}
|
|
68
|
+
}
|
|
69
|
+
exports.CircleWarp = CircleWarp;
|
|
70
|
+
});
|
|
@@ -0,0 +1,18 @@
|
|
|
1
|
+
export declare class Constants {
|
|
2
|
+
static readonly generatedAttribute: string;
|
|
3
|
+
static readonly randomColorValue: string;
|
|
4
|
+
static readonly midColorValue: string;
|
|
5
|
+
static readonly touchEndEvent: string;
|
|
6
|
+
static readonly mouseDownEvent: string;
|
|
7
|
+
static readonly mouseUpEvent: string;
|
|
8
|
+
static readonly mouseMoveEvent: string;
|
|
9
|
+
static readonly touchStartEvent: string;
|
|
10
|
+
static readonly touchMoveEvent: string;
|
|
11
|
+
static readonly mouseLeaveEvent: string;
|
|
12
|
+
static readonly mouseOutEvent: string;
|
|
13
|
+
static readonly touchCancelEvent: string;
|
|
14
|
+
static readonly resizeEvent: string;
|
|
15
|
+
static readonly visibilityChangeEvent: string;
|
|
16
|
+
static readonly noPolygonDataLoaded: string;
|
|
17
|
+
static readonly noPolygonFound: string;
|
|
18
|
+
}
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
(function (factory) {
|
|
2
|
+
if (typeof module === "object" && typeof module.exports === "object") {
|
|
3
|
+
var v = factory(require, exports);
|
|
4
|
+
if (v !== undefined) module.exports = v;
|
|
5
|
+
}
|
|
6
|
+
else if (typeof define === "function" && define.amd) {
|
|
7
|
+
define(["require", "exports"], factory);
|
|
8
|
+
}
|
|
9
|
+
})(function (require, exports) {
|
|
10
|
+
"use strict";
|
|
11
|
+
Object.defineProperty(exports, "__esModule", { value: true });
|
|
12
|
+
exports.Constants = void 0;
|
|
13
|
+
class Constants {
|
|
14
|
+
}
|
|
15
|
+
exports.Constants = Constants;
|
|
16
|
+
Constants.generatedAttribute = "generated";
|
|
17
|
+
Constants.randomColorValue = "random";
|
|
18
|
+
Constants.midColorValue = "mid";
|
|
19
|
+
Constants.touchEndEvent = "touchend";
|
|
20
|
+
Constants.mouseDownEvent = "mousedown";
|
|
21
|
+
Constants.mouseUpEvent = "mouseup";
|
|
22
|
+
Constants.mouseMoveEvent = "mousemove";
|
|
23
|
+
Constants.touchStartEvent = "touchstart";
|
|
24
|
+
Constants.touchMoveEvent = "touchmove";
|
|
25
|
+
Constants.mouseLeaveEvent = "mouseleave";
|
|
26
|
+
Constants.mouseOutEvent = "mouseout";
|
|
27
|
+
Constants.touchCancelEvent = "touchcancel";
|
|
28
|
+
Constants.resizeEvent = "resize";
|
|
29
|
+
Constants.visibilityChangeEvent = "visibilitychange";
|
|
30
|
+
Constants.noPolygonDataLoaded = "No polygon data loaded.";
|
|
31
|
+
Constants.noPolygonFound = "No polygon found, you need to specify SVG url in config.";
|
|
32
|
+
});
|