@tsparticles/updater-rotate
Advanced tools
Comparing version 3.0.0-beta.0 to 3.0.0-beta.1
@@ -1,4 +0,4 @@ | ||
import { RotateUpdater } from "./RotateUpdater"; | ||
import { RotateUpdater } from "./RotateUpdater.js"; | ||
export async function loadRotateUpdater(engine, refresh = true) { | ||
await engine.addParticleUpdater("rotate", (container) => new RotateUpdater(container), refresh); | ||
} |
import { ValueWithRandom, } from "@tsparticles/engine"; | ||
import { RotateAnimation } from "./RotateAnimation"; | ||
import { RotateAnimation } from "./RotateAnimation.js"; | ||
export class Rotate extends ValueWithRandom { | ||
@@ -4,0 +4,0 @@ constructor() { |
import { getRandom, getRangeValue, } from "@tsparticles/engine"; | ||
import { Rotate } from "./Options/Classes/Rotate"; | ||
import { Rotate } from "./Options/Classes/Rotate.js"; | ||
function updateRotate(particle, delta) { | ||
@@ -4,0 +4,0 @@ const rotate = particle.rotate, rotateOptions = particle.options.rotate; |
"use strict"; | ||
Object.defineProperty(exports, "__esModule", { value: true }); | ||
exports.loadRotateUpdater = void 0; | ||
const RotateUpdater_1 = require("./RotateUpdater"); | ||
const RotateUpdater_js_1 = require("./RotateUpdater.js"); | ||
async function loadRotateUpdater(engine, refresh = true) { | ||
await engine.addParticleUpdater("rotate", (container) => new RotateUpdater_1.RotateUpdater(container), refresh); | ||
await engine.addParticleUpdater("rotate", (container) => new RotateUpdater_js_1.RotateUpdater(container), refresh); | ||
} | ||
exports.loadRotateUpdater = loadRotateUpdater; |
@@ -5,7 +5,7 @@ "use strict"; | ||
const engine_1 = require("@tsparticles/engine"); | ||
const RotateAnimation_1 = require("./RotateAnimation"); | ||
const RotateAnimation_js_1 = require("./RotateAnimation.js"); | ||
class Rotate extends engine_1.ValueWithRandom { | ||
constructor() { | ||
super(); | ||
this.animation = new RotateAnimation_1.RotateAnimation(); | ||
this.animation = new RotateAnimation_js_1.RotateAnimation(); | ||
this.direction = "clockwise"; | ||
@@ -12,0 +12,0 @@ this.path = false; |
@@ -5,3 +5,3 @@ "use strict"; | ||
const engine_1 = require("@tsparticles/engine"); | ||
const Rotate_1 = require("./Options/Classes/Rotate"); | ||
const Rotate_js_1 = require("./Options/Classes/Rotate.js"); | ||
function updateRotate(particle, delta) { | ||
@@ -83,3 +83,3 @@ const rotate = particle.rotate, rotateOptions = particle.options.rotate; | ||
if (!options.rotate) { | ||
options.rotate = new Rotate_1.Rotate(); | ||
options.rotate = new Rotate_js_1.Rotate(); | ||
} | ||
@@ -86,0 +86,0 @@ for (const source of sources) { |
@@ -1,4 +0,4 @@ | ||
import { RotateUpdater } from "./RotateUpdater"; | ||
import { RotateUpdater } from "./RotateUpdater.js"; | ||
export async function loadRotateUpdater(engine, refresh = true) { | ||
await engine.addParticleUpdater("rotate", (container) => new RotateUpdater(container), refresh); | ||
} |
import { ValueWithRandom, } from "@tsparticles/engine"; | ||
import { RotateAnimation } from "./RotateAnimation"; | ||
import { RotateAnimation } from "./RotateAnimation.js"; | ||
export class Rotate extends ValueWithRandom { | ||
@@ -4,0 +4,0 @@ constructor() { |
import { getRandom, getRangeValue, } from "@tsparticles/engine"; | ||
import { Rotate } from "./Options/Classes/Rotate"; | ||
import { Rotate } from "./Options/Classes/Rotate.js"; | ||
function updateRotate(particle, delta) { | ||
@@ -4,0 +4,0 @@ const rotate = particle.rotate, rotateOptions = particle.options.rotate; |
{ | ||
"name": "@tsparticles/updater-rotate", | ||
"version": "3.0.0-beta.0", | ||
"version": "3.0.0-beta.1", | ||
"description": "tsParticles particles rotate updater", | ||
@@ -71,10 +71,22 @@ "homepage": "https://particles.js.org", | ||
}, | ||
"main": "cjs/index.js", | ||
"sideEffects": false, | ||
"jsdelivr": "tsparticles.updater.rotate.min.js", | ||
"unpkg": "tsparticles.updater.rotate.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 Rotate Updater v3.0.0-beta.0 by Matteo Bruni */ | ||
/*! tsParticles Rotate Updater v3.0.0-beta.1 by Matteo Bruni */ |
import { type IOptionLoader, type RecursivePartial, RotateDirection, type RotateDirectionAlt, ValueWithRandom } from "@tsparticles/engine"; | ||
import type { IRotate } from "../Interfaces/IRotate"; | ||
import { RotateAnimation } from "./RotateAnimation"; | ||
import type { IRotate } from "../Interfaces/IRotate.js"; | ||
import { RotateAnimation } from "./RotateAnimation.js"; | ||
export declare class Rotate extends ValueWithRandom implements IRotate, IOptionLoader<IRotate> { | ||
@@ -5,0 +5,0 @@ animation: RotateAnimation; |
import { type IOptionLoader, type RangeValue, type RecursivePartial } from "@tsparticles/engine"; | ||
import type { IRotateAnimation } from "../Interfaces/IRotateAnimation"; | ||
import type { IRotateAnimation } from "../Interfaces/IRotateAnimation.js"; | ||
export declare class RotateAnimation implements IRotateAnimation, IOptionLoader<IRotateAnimation> { | ||
@@ -4,0 +4,0 @@ decay: RangeValue; |
import type { IValueWithRandom, RotateDirection, RotateDirectionAlt } from "@tsparticles/engine"; | ||
import type { IRotateAnimation } from "./IRotateAnimation"; | ||
import type { IRotateAnimation } from "./IRotateAnimation.js"; | ||
export interface IRotate extends IValueWithRandom { | ||
@@ -4,0 +4,0 @@ animation: IRotateAnimation; |
import { type Container, type IDelta, type IParticleUpdater, type IParticleValueAnimation, type IParticlesOptions, type Particle, type ParticlesOptions, type RecursivePartial } from "@tsparticles/engine"; | ||
import type { IRotate } from "./Options/Interfaces/IRotate"; | ||
import { Rotate } from "./Options/Classes/Rotate"; | ||
import type { IRotate } from "./Options/Interfaces/IRotate.js"; | ||
import { Rotate } from "./Options/Classes/Rotate.js"; | ||
type RotateParticle = Particle & { | ||
@@ -5,0 +5,0 @@ options: RotateParticlesOptions; |
@@ -7,3 +7,3 @@ (function (factory) { | ||
else if (typeof define === "function" && define.amd) { | ||
define(["require", "exports", "./RotateUpdater"], factory); | ||
define(["require", "exports", "./RotateUpdater.js"], factory); | ||
} | ||
@@ -14,7 +14,7 @@ })(function (require, exports) { | ||
exports.loadRotateUpdater = void 0; | ||
const RotateUpdater_1 = require("./RotateUpdater"); | ||
const RotateUpdater_js_1 = require("./RotateUpdater.js"); | ||
async function loadRotateUpdater(engine, refresh = true) { | ||
await engine.addParticleUpdater("rotate", (container) => new RotateUpdater_1.RotateUpdater(container), refresh); | ||
await engine.addParticleUpdater("rotate", (container) => new RotateUpdater_js_1.RotateUpdater(container), refresh); | ||
} | ||
exports.loadRotateUpdater = loadRotateUpdater; | ||
}); |
@@ -7,3 +7,3 @@ (function (factory) { | ||
else if (typeof define === "function" && define.amd) { | ||
define(["require", "exports", "@tsparticles/engine", "./RotateAnimation"], factory); | ||
define(["require", "exports", "@tsparticles/engine", "./RotateAnimation.js"], factory); | ||
} | ||
@@ -15,7 +15,7 @@ })(function (require, exports) { | ||
const engine_1 = require("@tsparticles/engine"); | ||
const RotateAnimation_1 = require("./RotateAnimation"); | ||
const RotateAnimation_js_1 = require("./RotateAnimation.js"); | ||
class Rotate extends engine_1.ValueWithRandom { | ||
constructor() { | ||
super(); | ||
this.animation = new RotateAnimation_1.RotateAnimation(); | ||
this.animation = new RotateAnimation_js_1.RotateAnimation(); | ||
this.direction = "clockwise"; | ||
@@ -22,0 +22,0 @@ this.path = false; |
@@ -7,3 +7,3 @@ (function (factory) { | ||
else if (typeof define === "function" && define.amd) { | ||
define(["require", "exports", "@tsparticles/engine", "./Options/Classes/Rotate"], factory); | ||
define(["require", "exports", "@tsparticles/engine", "./Options/Classes/Rotate.js"], factory); | ||
} | ||
@@ -15,3 +15,3 @@ })(function (require, exports) { | ||
const engine_1 = require("@tsparticles/engine"); | ||
const Rotate_1 = require("./Options/Classes/Rotate"); | ||
const Rotate_js_1 = require("./Options/Classes/Rotate.js"); | ||
function updateRotate(particle, delta) { | ||
@@ -93,3 +93,3 @@ const rotate = particle.rotate, rotateOptions = particle.options.rotate; | ||
if (!options.rotate) { | ||
options.rotate = new Rotate_1.Rotate(); | ||
options.rotate = new Rotate_js_1.Rotate(); | ||
} | ||
@@ -96,0 +96,0 @@ for (const source of sources) { |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
322313
40