Huge News!Announcing our $40M Series B led by Abstract Ventures.Learn More
Socket
Sign inDemoInstall
Socket

@tsparticles/updater-out-modes

Package Overview
Dependencies
Maintainers
2
Versions
21
Alerts
File Explorer

Advanced tools

Socket logo

Install Socket

Detect and block malicious and high-risk dependencies

Install

@tsparticles/updater-out-modes - npm Package Compare versions

Comparing version 3.0.0-beta.0 to 3.0.0-beta.1

browser/package.json

2

browser/BounceOutMode.js
import { calculateBounds, } from "@tsparticles/engine";
import { bounceHorizontal, bounceVertical } from "./Utils";
import { bounceHorizontal, bounceVertical } from "./Utils.js";
export class BounceOutMode {

@@ -4,0 +4,0 @@ constructor(container) {

@@ -1,4 +0,4 @@

import { OutOfCanvasUpdater } from "./OutOfCanvasUpdater";
import { OutOfCanvasUpdater } from "./OutOfCanvasUpdater.js";
export async function loadOutModesUpdater(engine, refresh = true) {
await engine.addParticleUpdater("outModes", (container) => new OutOfCanvasUpdater(container), refresh);
}

@@ -1,5 +0,5 @@

import { BounceOutMode } from "./BounceOutMode";
import { DestroyOutMode } from "./DestroyOutMode";
import { NoneOutMode } from "./NoneOutMode";
import { OutOutMode } from "./OutOutMode";
import { BounceOutMode } from "./BounceOutMode.js";
import { DestroyOutMode } from "./DestroyOutMode.js";
import { NoneOutMode } from "./NoneOutMode.js";
import { OutOutMode } from "./OutOutMode.js";
export class OutOfCanvasUpdater {

@@ -6,0 +6,0 @@ constructor(container) {

@@ -5,3 +5,3 @@ "use strict";

const engine_1 = require("@tsparticles/engine");
const Utils_1 = require("./Utils");
const Utils_js_1 = require("./Utils.js");
class BounceOutMode {

@@ -37,6 +37,6 @@ constructor(container) {

const pos = particle.getPosition(), offset = particle.offset, size = particle.getRadius(), bounds = (0, engine_1.calculateBounds)(pos, size), canvasSize = container.canvas.size;
(0, Utils_1.bounceHorizontal)({ particle, outMode, direction, bounds, canvasSize, offset, size });
(0, Utils_1.bounceVertical)({ particle, outMode, direction, bounds, canvasSize, offset, size });
(0, Utils_js_1.bounceHorizontal)({ particle, outMode, direction, bounds, canvasSize, offset, size });
(0, Utils_js_1.bounceVertical)({ particle, outMode, direction, bounds, canvasSize, offset, size });
}
}
exports.BounceOutMode = BounceOutMode;
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.loadOutModesUpdater = void 0;
const OutOfCanvasUpdater_1 = require("./OutOfCanvasUpdater");
const OutOfCanvasUpdater_js_1 = require("./OutOfCanvasUpdater.js");
async function loadOutModesUpdater(engine, refresh = true) {
await engine.addParticleUpdater("outModes", (container) => new OutOfCanvasUpdater_1.OutOfCanvasUpdater(container), refresh);
await engine.addParticleUpdater("outModes", (container) => new OutOfCanvasUpdater_js_1.OutOfCanvasUpdater(container), refresh);
}
exports.loadOutModesUpdater = loadOutModesUpdater;
"use strict";
Object.defineProperty(exports, "__esModule", { value: true });
exports.OutOfCanvasUpdater = void 0;
const BounceOutMode_1 = require("./BounceOutMode");
const DestroyOutMode_1 = require("./DestroyOutMode");
const NoneOutMode_1 = require("./NoneOutMode");
const OutOutMode_1 = require("./OutOutMode");
const BounceOutMode_js_1 = require("./BounceOutMode.js");
const DestroyOutMode_js_1 = require("./DestroyOutMode.js");
const NoneOutMode_js_1 = require("./NoneOutMode.js");
const OutOutMode_js_1 = require("./OutOutMode.js");
class OutOfCanvasUpdater {

@@ -17,6 +17,6 @@ constructor(container) {

this.updaters = [
new BounceOutMode_1.BounceOutMode(container),
new DestroyOutMode_1.DestroyOutMode(container),
new OutOutMode_1.OutOutMode(container),
new NoneOutMode_1.NoneOutMode(container),
new BounceOutMode_js_1.BounceOutMode(container),
new DestroyOutMode_js_1.DestroyOutMode(container),
new OutOutMode_js_1.OutOutMode(container),
new NoneOutMode_js_1.NoneOutMode(container),
];

@@ -23,0 +23,0 @@ }

import { calculateBounds, } from "@tsparticles/engine";
import { bounceHorizontal, bounceVertical } from "./Utils";
import { bounceHorizontal, bounceVertical } from "./Utils.js";
export class BounceOutMode {

@@ -4,0 +4,0 @@ constructor(container) {

@@ -1,4 +0,4 @@

import { OutOfCanvasUpdater } from "./OutOfCanvasUpdater";
import { OutOfCanvasUpdater } from "./OutOfCanvasUpdater.js";
export async function loadOutModesUpdater(engine, refresh = true) {
await engine.addParticleUpdater("outModes", (container) => new OutOfCanvasUpdater(container), refresh);
}

@@ -1,5 +0,5 @@

import { BounceOutMode } from "./BounceOutMode";
import { DestroyOutMode } from "./DestroyOutMode";
import { NoneOutMode } from "./NoneOutMode";
import { OutOutMode } from "./OutOutMode";
import { BounceOutMode } from "./BounceOutMode.js";
import { DestroyOutMode } from "./DestroyOutMode.js";
import { NoneOutMode } from "./NoneOutMode.js";
import { OutOutMode } from "./OutOutMode.js";
export class OutOfCanvasUpdater {

@@ -6,0 +6,0 @@ constructor(container) {

{
"name": "@tsparticles/updater-out-modes",
"version": "3.0.0-beta.0",
"version": "3.0.0-beta.1",
"description": "tsParticles particles out modes updater",

@@ -71,10 +71,22 @@ "homepage": "https://particles.js.org",

},
"main": "cjs/index.js",
"sideEffects": false,
"jsdelivr": "tsparticles.updater.out-modes.min.js",
"unpkg": "tsparticles.updater.out-modes.min.js",
"browser": "browser/index.js",
"main": "cjs/index.js",
"module": "esm/index.js",
"types": "types/index.d.ts",
"sideEffects": false,
"exports": {
".": {
"types": "./types/index.d.ts",
"browser": "./browser/index.js",
"import": "./esm/index.js",
"require": "./cjs/index.js",
"umd": "./umd/index.js",
"default": "./cjs/index.js"
},
"./package.json": "./package.json"
},
"dependencies": {
"@tsparticles/engine": "^3.0.0-beta.0"
"@tsparticles/engine": "^3.0.0-beta.1"
},

@@ -81,0 +93,0 @@ "publishConfig": {

@@ -7,3 +7,3 @@ /*!

* How to use? : Check the GitHub README
* v3.0.0-beta.0
* v3.0.0-beta.1
*/

@@ -10,0 +10,0 @@ (function webpackUniversalModuleDefinition(root, factory) {

@@ -1,1 +0,1 @@

/*! tsParticles Out Modes Updater v3.0.0-beta.0 by Matteo Bruni */
/*! tsParticles Out Modes Updater v3.0.0-beta.1 by Matteo Bruni */
import { type Container, type IDelta, OutMode, type OutModeAlt, type OutModeDirection, type Particle } from "@tsparticles/engine";
import type { IOutModeManager } from "./IOutModeManager";
import type { IOutModeManager } from "./IOutModeManager.js";
export declare class BounceOutMode implements IOutModeManager {

@@ -4,0 +4,0 @@ private readonly container;

import { type Container, type IDelta, OutMode, type OutModeAlt, type OutModeDirection, type Particle } from "@tsparticles/engine";
import type { IOutModeManager } from "./IOutModeManager";
import type { IOutModeManager } from "./IOutModeManager.js";
export declare class DestroyOutMode implements IOutModeManager {

@@ -4,0 +4,0 @@ private readonly container;

import { type Container, type IDelta, OutMode, type OutModeAlt, OutModeDirection, type Particle } from "@tsparticles/engine";
import type { IOutModeManager } from "./IOutModeManager";
import type { IOutModeManager } from "./IOutModeManager.js";
export declare class NoneOutMode implements IOutModeManager {

@@ -4,0 +4,0 @@ private readonly container;

import { type Container, type IDelta, type IParticleUpdater, type Particle } from "@tsparticles/engine";
import type { IOutModeManager } from "./IOutModeManager";
import type { IOutModeManager } from "./IOutModeManager.js";
export declare class OutOfCanvasUpdater implements IParticleUpdater {

@@ -4,0 +4,0 @@ private readonly container;

import { type Container, type IDelta, OutMode, type OutModeAlt, OutModeDirection, type Particle } from "@tsparticles/engine";
import type { IOutModeManager } from "./IOutModeManager";
import type { IOutModeManager } from "./IOutModeManager.js";
export declare class OutOutMode implements IOutModeManager {

@@ -4,0 +4,0 @@ private readonly container;

@@ -1,3 +0,3 @@

import type { IBounceData } from "./IBounceData";
import type { IBounceData } from "./IBounceData.js";
export declare function bounceHorizontal(data: IBounceData): void;
export declare function bounceVertical(data: IBounceData): void;

@@ -7,3 +7,3 @@ (function (factory) {

else if (typeof define === "function" && define.amd) {
define(["require", "exports", "@tsparticles/engine", "./Utils"], factory);
define(["require", "exports", "@tsparticles/engine", "./Utils.js"], factory);
}

@@ -15,3 +15,3 @@ })(function (require, exports) {

const engine_1 = require("@tsparticles/engine");
const Utils_1 = require("./Utils");
const Utils_js_1 = require("./Utils.js");
class BounceOutMode {

@@ -47,4 +47,4 @@ constructor(container) {

const pos = particle.getPosition(), offset = particle.offset, size = particle.getRadius(), bounds = (0, engine_1.calculateBounds)(pos, size), canvasSize = container.canvas.size;
(0, Utils_1.bounceHorizontal)({ particle, outMode, direction, bounds, canvasSize, offset, size });
(0, Utils_1.bounceVertical)({ particle, outMode, direction, bounds, canvasSize, offset, size });
(0, Utils_js_1.bounceHorizontal)({ particle, outMode, direction, bounds, canvasSize, offset, size });
(0, Utils_js_1.bounceVertical)({ particle, outMode, direction, bounds, canvasSize, offset, size });
}

@@ -51,0 +51,0 @@ }

@@ -7,3 +7,3 @@ (function (factory) {

else if (typeof define === "function" && define.amd) {
define(["require", "exports", "./OutOfCanvasUpdater"], factory);
define(["require", "exports", "./OutOfCanvasUpdater.js"], factory);
}

@@ -14,7 +14,7 @@ })(function (require, exports) {

exports.loadOutModesUpdater = void 0;
const OutOfCanvasUpdater_1 = require("./OutOfCanvasUpdater");
const OutOfCanvasUpdater_js_1 = require("./OutOfCanvasUpdater.js");
async function loadOutModesUpdater(engine, refresh = true) {
await engine.addParticleUpdater("outModes", (container) => new OutOfCanvasUpdater_1.OutOfCanvasUpdater(container), refresh);
await engine.addParticleUpdater("outModes", (container) => new OutOfCanvasUpdater_js_1.OutOfCanvasUpdater(container), refresh);
}
exports.loadOutModesUpdater = loadOutModesUpdater;
});

@@ -7,3 +7,3 @@ (function (factory) {

else if (typeof define === "function" && define.amd) {
define(["require", "exports", "./BounceOutMode", "./DestroyOutMode", "./NoneOutMode", "./OutOutMode"], factory);
define(["require", "exports", "./BounceOutMode.js", "./DestroyOutMode.js", "./NoneOutMode.js", "./OutOutMode.js"], factory);
}

@@ -14,6 +14,6 @@ })(function (require, exports) {

exports.OutOfCanvasUpdater = void 0;
const BounceOutMode_1 = require("./BounceOutMode");
const DestroyOutMode_1 = require("./DestroyOutMode");
const NoneOutMode_1 = require("./NoneOutMode");
const OutOutMode_1 = require("./OutOutMode");
const BounceOutMode_js_1 = require("./BounceOutMode.js");
const DestroyOutMode_js_1 = require("./DestroyOutMode.js");
const NoneOutMode_js_1 = require("./NoneOutMode.js");
const OutOutMode_js_1 = require("./OutOutMode.js");
class OutOfCanvasUpdater {

@@ -28,6 +28,6 @@ constructor(container) {

this.updaters = [
new BounceOutMode_1.BounceOutMode(container),
new DestroyOutMode_1.DestroyOutMode(container),
new OutOutMode_1.OutOutMode(container),
new NoneOutMode_1.NoneOutMode(container),
new BounceOutMode_js_1.BounceOutMode(container),
new DestroyOutMode_js_1.DestroyOutMode(container),
new OutOutMode_js_1.OutOutMode(container),
new NoneOutMode_js_1.NoneOutMode(container),
];

@@ -34,0 +34,0 @@ }

Sorry, the diff of this file is not supported yet

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap
  • Changelog

Packages

npm

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc