tsparticles 2.0.2 → 2.0.5

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/107.js CHANGED
@@ -4,7 +4,7 @@
4
4
  * Demo / Generator : https://particles.js.org/
5
5
  * GitHub : https://www.github.com/matteobruni/tsparticles
6
6
  * How to use? : Check the GitHub README
7
- * v2.0.2
7
+ * v2.0.5
8
8
  */
9
9
  "use strict";
10
10
  (this["webpackChunktsparticles"] = this["webpackChunktsparticles"] || []).push([[107],{
package/README.md CHANGED
@@ -9,15 +9,15 @@ a `tsparticles-engine` instance.
9
9
 
10
10
  **Included Packages**
11
11
 
12
- - tsparticles-engine
13
- - tsparticles-slim (and all its dependencies)
14
- - tsparticles-interaction-external-trail
15
- - tsparticles-plugin-absorbers
16
- - tsparticles-plugin-emitters
17
- - tsparticles-plugin-polygon-mask
18
- - tsparticles-updater-roll
19
- - tsparticles-updater-tilt
20
- - tsparticles-updater-wobble
12
+ - [tsparticles-engine](https://github.com/matteobruni/tsparticles/tree/main/engine)
13
+ - [tsparticles-slim (and all its dependencies)](https://github.com/matteobruni/tsparticles/tree/main/bundles/slim)
14
+ - [tsparticles-interaction-external-trail](https://github.com/matteobruni/tsparticles/tree/main/interactions/external/trail)
15
+ - [tsparticles-plugin-absorbers](https://github.com/matteobruni/tsparticles/tree/main/plugins/absorbers)
16
+ - [tsparticles-plugin-emitters](https://github.com/matteobruni/tsparticles/tree/main/plugins/emitters)
17
+ - [tsparticles-plugin-polygon-mask](https://github.com/matteobruni/tsparticles/tree/main/plugins/polygonMask)
18
+ - [tsparticles-updater-roll](https://github.com/matteobruni/tsparticles/tree/main/updaters/roll)
19
+ - [tsparticles-updater-tilt](https://github.com/matteobruni/tsparticles/tree/main/updaters/tilt)
20
+ - [tsparticles-updater-wobble](https://github.com/matteobruni/tsparticles/tree/main/updaters/wobble)
21
21
 
22
22
  ## How to use it
23
23
 
@@ -74,9 +74,9 @@ import { loadFull } from "tsparticles";
74
74
 
75
75
  export class ParticlesContainer extends PureComponent<unknown> {
76
76
  // this customizes the component tsParticles installation
77
- customInit(engine: Engine) {
77
+ async customInit(engine: Engine): Promise<void> {
78
78
  // this adds the bundle to tsParticles
79
- loadFull(engine);
79
+ await loadFull(engine);
80
80
  }
81
81
 
82
82
  render() {
@@ -99,9 +99,9 @@ import { loadFull } from "tsparticles";
99
99
 
100
100
  export function ParticlesContainer(props: unknown) {
101
101
  // this customizes the component tsParticles installation
102
- const customInit = useCallback((engine: Engine) => {
102
+ const customInit = useCallback(async (engine: Engine) => {
103
103
  // this adds the bundle to tsParticles
104
- loadFull(engine);
104
+ await loadFull(engine);
105
105
  });
106
106
 
107
107
  const options = {
@@ -121,8 +121,8 @@ _The syntax for `Vue.js 2.x` and `3.x` is the same_
121
121
  ```
122
122
 
123
123
  ```js
124
- function particlesInit(engine: Engine) {
125
- loadFull(engine);
124
+ async function particlesInit(engine: Engine): Promise<void> {
125
+ await loadFull(engine);
126
126
  }
127
127
  ```
128
128
 
@@ -133,13 +133,13 @@ function particlesInit(engine: Engine) {
133
133
  [id]="id"
134
134
  [options]="particlesOptions"
135
135
  (particlesLoaded)="particlesLoaded($event)"
136
- (particlesInit)="particlesInit($event)"
136
+ [particlesInit]="particlesInit"
137
137
  ></ng-particles>
138
138
  ```
139
139
 
140
140
  ```ts
141
- function particlesInit(engine: Engine): void {
142
- loadFull(engine);
141
+ async function particlesInit(engine: Engine): Promise<void> {
142
+ await loadFull(engine);
143
143
  }
144
144
  ```
145
145
 
package/index.js CHANGED
@@ -14,12 +14,14 @@ import { loadPolygonMaskPlugin } from "tsparticles-plugin-polygon-mask";
14
14
  import { loadRollUpdater } from "tsparticles-updater-roll";
15
15
  import { loadSlim } from "tsparticles-slim";
16
16
  import { loadTiltUpdater } from "tsparticles-updater-tilt";
17
+ import { loadTwinkleUpdater } from "tsparticles-updater-twinkle";
17
18
  import { loadWobbleUpdater } from "tsparticles-updater-wobble";
18
19
  export function loadFull(engine) {
19
20
  return __awaiter(this, void 0, void 0, function* () {
20
21
  yield loadSlim(engine);
21
- yield loadTiltUpdater(engine);
22
22
  yield loadRollUpdater(engine);
23
+ yield loadTiltUpdater(engine);
24
+ yield loadTwinkleUpdater(engine);
23
25
  yield loadWobbleUpdater(engine);
24
26
  yield loadExternalTrailInteraction(engine);
25
27
  yield loadAbsorbersPlugin(engine);
package/package.json CHANGED
@@ -1,11 +1,8 @@
1
1
  {
2
2
  "name": "tsparticles",
3
- "version": "2.0.2",
3
+ "version": "2.0.5",
4
4
  "description": "Easily create highly customizable particle animations and use them as animated backgrounds for your website. Ready to use components available also for React, Vue.js (2.x and 3.x), Angular, Svelte, jQuery, Preact, Riot.js, Inferno.",
5
5
  "homepage": "https://particles.js.org/",
6
- "scripts": {
7
- "install": "node ./scripts/install.js"
8
- },
9
6
  "repository": {
10
7
  "type": "git",
11
8
  "url": "git+https://github.com/matteobruni/tsparticles.git",
@@ -66,14 +63,15 @@
66
63
  "browser": "index.js",
67
64
  "types": "index.d.ts",
68
65
  "dependencies": {
69
- "tsparticles-engine": "^2.0.2",
70
- "tsparticles-interaction-external-trail": "^2.0.2",
71
- "tsparticles-plugin-absorbers": "^2.0.2",
72
- "tsparticles-plugin-emitters": "^2.0.2",
73
- "tsparticles-plugin-polygon-mask": "^2.0.2",
74
- "tsparticles-slim": "^2.0.2",
75
- "tsparticles-updater-roll": "^2.0.2",
76
- "tsparticles-updater-tilt": "^2.0.2",
77
- "tsparticles-updater-wobble": "^2.0.2"
66
+ "tsparticles-engine": "^2.0.5",
67
+ "tsparticles-interaction-external-trail": "^2.0.5",
68
+ "tsparticles-plugin-absorbers": "^2.0.5",
69
+ "tsparticles-plugin-emitters": "^2.0.5",
70
+ "tsparticles-plugin-polygon-mask": "^2.0.5",
71
+ "tsparticles-slim": "^2.0.5",
72
+ "tsparticles-updater-roll": "^2.0.5",
73
+ "tsparticles-updater-tilt": "^2.0.5",
74
+ "tsparticles-updater-twinkle": "^2.0.5",
75
+ "tsparticles-updater-wobble": "^2.0.5"
78
76
  }
79
77
  }