@tsparticles/template-confetti 4.4.0 → 4.5.1
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/CHANGELOG.md +12 -2
- package/package.json +4 -4
- package/scripts/prebuild.js +1 -1
- package/template/angular/package.json +14 -14
- package/template/angular/src/app/app.component.ts +1 -0
- package/template/angular-confetti/package.json +15 -15
- package/template/angular-confetti/src/app/app.component.ts +1 -0
- package/template/angular-fireworks/package.json +15 -15
- package/template/angular-fireworks/src/app/app.component.ts +1 -0
- package/template/astro/package.json +5 -5
- package/template/ember/app/templates/application.hbs +1 -1
- package/template/ember/package.json +4 -6
- package/template/inferno/package.json +5 -6
- package/template/inferno/src/App.tsx +1 -1
- package/template/jquery/index.html +22 -0
- package/template/jquery/package.json +5 -4
- package/template/jquery/src/main.ts +0 -4
- package/template/lit/package.json +5 -5
- package/template/nextjs/package.json +6 -6
- package/template/nuxt2/package.json +12 -3
- package/template/nuxt3/package.json +3 -3
- package/template/nuxt4/package.json +3 -3
- package/template/preact/package.json +4 -4
- package/template/qwik/package.json +4 -4
- package/template/react/package.json +4 -2
- package/template/react/src/App.tsx +3 -3
- package/template/riot/package.json +5 -5
- package/template/solid/package.json +2 -2
- package/template/stencil/package.json +3 -3
- package/template/stencil/src/components/app-home/app-home.tsx +10 -12
- package/template/svelte/package.json +1 -1
- package/template/vue2/package.json +5 -5
- package/template/vue3/package.json +1 -1
- package/template/webcomponents/index.html +22 -0
- package/template/webcomponents/package.json +4 -4
- package/template/webcomponents/src/main.ts +3 -0
- package/template.json +4 -4
package/CHANGELOG.md
CHANGED
|
@@ -3,11 +3,21 @@
|
|
|
3
3
|
All notable changes to this project will be documented in this file.
|
|
4
4
|
See [Conventional Commits](https://conventionalcommits.org) for commit guidelines.
|
|
5
5
|
|
|
6
|
+
## [4.5.1](https://github.com/tsparticles/tsparticles/compare/v4.5.0...v4.5.1) (2026-11-02)
|
|
7
|
+
|
|
8
|
+
**Note:** Version bump only for package @tsparticles/template-confetti
|
|
9
|
+
|
|
10
|
+
# [4.5.0](https://github.com/tsparticles/tsparticles/compare/v4.4.0...v4.5.0) (2026-10-25)
|
|
11
|
+
|
|
12
|
+
### Bug Fixes
|
|
13
|
+
|
|
14
|
+
- fixed some issues in mcp server and some coderabbit reports ([4700d3e](https://github.com/tsparticles/tsparticles/commit/4700d3e953f3a3a1930db064a6b6b21d61233cdf))
|
|
15
|
+
|
|
6
16
|
# [4.4.0](https://github.com/tsparticles/tsparticles/compare/v4.3.3...v4.4.0) (2026-08-30)
|
|
7
17
|
|
|
8
18
|
### Bug Fixes
|
|
9
19
|
|
|
10
|
-
|
|
20
|
+
- various fixes for 4.4.0 ([475d06d](https://github.com/tsparticles/tsparticles/commit/475d06da27e1497bb097c0822fcfcb72d7142456))
|
|
11
21
|
|
|
12
22
|
## [4.3.3](https://github.com/tsparticles/tsparticles/compare/v4.3.2...v4.3.3) (2026-07-23)
|
|
13
23
|
|
|
@@ -25,7 +35,7 @@ See [Conventional Commits](https://conventionalcommits.org) for commit guideline
|
|
|
25
35
|
|
|
26
36
|
### Bug Fixes
|
|
27
37
|
|
|
28
|
-
|
|
38
|
+
- fixed angular confetti ([6f25a4a](https://github.com/tsparticles/tsparticles/commit/6f25a4a1eaa69c47f2668316e7b396fe55195f84))
|
|
29
39
|
|
|
30
40
|
## [4.2.1](https://github.com/tsparticles/tsparticles/compare/v4.2.0...v4.2.1) (2026-06-18)
|
|
31
41
|
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@tsparticles/template-confetti",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.5.1",
|
|
4
4
|
"private": false,
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"access": "public"
|
|
@@ -18,11 +18,11 @@
|
|
|
18
18
|
"prepack": "pnpm run build"
|
|
19
19
|
},
|
|
20
20
|
"dependencies": {
|
|
21
|
-
"@tsparticles/confetti": "4.
|
|
22
|
-
"@tsparticles/engine": "4.
|
|
21
|
+
"@tsparticles/confetti": "4.5.1",
|
|
22
|
+
"@tsparticles/engine": "4.5.1"
|
|
23
23
|
},
|
|
24
24
|
"devDependencies": {
|
|
25
25
|
"fs-extra": "^11.3.4"
|
|
26
26
|
},
|
|
27
|
-
"gitHead": "
|
|
27
|
+
"gitHead": "433c560448e5020cb051e1b025e0f9914f23b147"
|
|
28
28
|
}
|
package/scripts/prebuild.js
CHANGED
|
@@ -51,7 +51,7 @@ fs.readFile(libPackage, function (error, data) {
|
|
|
51
51
|
}
|
|
52
52
|
}
|
|
53
53
|
|
|
54
|
-
fs.writeFile(libPackage, JSON.stringify(libObj, undefined, 2)
|
|
54
|
+
fs.writeFile(libPackage, `${JSON.stringify(libObj, undefined, 2)}\n`, "utf-8", function () {
|
|
55
55
|
console.log("template.json dependencies updated successfully");
|
|
56
56
|
});
|
|
57
57
|
});
|
|
@@ -11,24 +11,24 @@
|
|
|
11
11
|
"watch": "ng build --watch --configuration development"
|
|
12
12
|
},
|
|
13
13
|
"dependencies": {
|
|
14
|
-
"@angular/animations": "~22.
|
|
15
|
-
"@angular/common": "~22.
|
|
16
|
-
"@angular/compiler": "~22.
|
|
17
|
-
"@angular/core": "~22.
|
|
18
|
-
"@angular/forms": "~22.
|
|
19
|
-
"@angular/platform-browser": "~22.
|
|
20
|
-
"@angular/platform-browser-dynamic": "~22.
|
|
21
|
-
"@angular/router": "~22.
|
|
22
|
-
"@tsparticles/angular": "^4.
|
|
23
|
-
"@tsparticles/confetti": "^
|
|
14
|
+
"@angular/animations": "~22.2.2",
|
|
15
|
+
"@angular/common": "~22.2.2",
|
|
16
|
+
"@angular/compiler": "~22.2.2",
|
|
17
|
+
"@angular/core": "~22.2.2",
|
|
18
|
+
"@angular/forms": "~22.2.2",
|
|
19
|
+
"@angular/platform-browser": "~22.2.2",
|
|
20
|
+
"@angular/platform-browser-dynamic": "~22.2.2",
|
|
21
|
+
"@angular/router": "~22.2.2",
|
|
22
|
+
"@tsparticles/angular": "^4.4.0",
|
|
23
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
24
24
|
"rxjs": "~7.8.2",
|
|
25
25
|
"tslib": "^2.8.1",
|
|
26
|
-
"zone.js": "~0.16.
|
|
26
|
+
"zone.js": "~0.16.3"
|
|
27
27
|
},
|
|
28
28
|
"devDependencies": {
|
|
29
|
-
"@angular-devkit/build-angular": "~22.
|
|
30
|
-
"@angular/cli": "~22.
|
|
31
|
-
"@angular/compiler-cli": "~22.
|
|
29
|
+
"@angular-devkit/build-angular": "~22.2.2",
|
|
30
|
+
"@angular/cli": "~22.2.2",
|
|
31
|
+
"@angular/compiler-cli": "~22.2.2",
|
|
32
32
|
"typescript": "~6.0.3"
|
|
33
33
|
}
|
|
34
34
|
}
|
|
@@ -11,25 +11,25 @@
|
|
|
11
11
|
"watch": "ng build --watch --configuration development"
|
|
12
12
|
},
|
|
13
13
|
"dependencies": {
|
|
14
|
-
"@angular/animations": "~22.
|
|
15
|
-
"@angular/common": "~22.
|
|
16
|
-
"@angular/compiler": "~22.
|
|
17
|
-
"@angular/core": "~22.
|
|
18
|
-
"@angular/forms": "~22.
|
|
19
|
-
"@angular/platform-browser": "~22.
|
|
20
|
-
"@angular/platform-browser-dynamic": "~22.
|
|
21
|
-
"@angular/router": "~22.
|
|
22
|
-
"angular
|
|
23
|
-
"@tsparticles/confetti": "^4.
|
|
24
|
-
"@tsparticles/engine": "^4.
|
|
14
|
+
"@angular/animations": "~22.2.2",
|
|
15
|
+
"@angular/common": "~22.2.2",
|
|
16
|
+
"@angular/compiler": "~22.2.2",
|
|
17
|
+
"@angular/core": "~22.2.2",
|
|
18
|
+
"@angular/forms": "~22.2.2",
|
|
19
|
+
"@angular/platform-browser": "~22.2.2",
|
|
20
|
+
"@angular/platform-browser-dynamic": "~22.2.2",
|
|
21
|
+
"@angular/router": "~22.2.2",
|
|
22
|
+
"@tsparticles/angular": "^4.4.0",
|
|
23
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
24
|
+
"@tsparticles/engine": "^4.4.0",
|
|
25
25
|
"rxjs": "~7.8.2",
|
|
26
26
|
"tslib": "^2.8.1",
|
|
27
|
-
"zone.js": "~0.16.
|
|
27
|
+
"zone.js": "~0.16.3"
|
|
28
28
|
},
|
|
29
29
|
"devDependencies": {
|
|
30
|
-
"@angular-devkit/build-angular": "~22.
|
|
31
|
-
"@angular/cli": "~22.
|
|
32
|
-
"@angular/compiler-cli": "~22.
|
|
30
|
+
"@angular-devkit/build-angular": "~22.2.2",
|
|
31
|
+
"@angular/cli": "~22.2.2",
|
|
32
|
+
"@angular/compiler-cli": "~22.2.2",
|
|
33
33
|
"typescript": "~6.0.3"
|
|
34
34
|
}
|
|
35
35
|
}
|
|
@@ -11,25 +11,25 @@
|
|
|
11
11
|
"watch": "ng build --watch --configuration development"
|
|
12
12
|
},
|
|
13
13
|
"dependencies": {
|
|
14
|
-
"@angular/animations": "~22.
|
|
15
|
-
"@angular/common": "~22.
|
|
16
|
-
"@angular/compiler": "~22.
|
|
17
|
-
"@angular/core": "~22.
|
|
18
|
-
"@angular/forms": "~22.
|
|
19
|
-
"@angular/platform-browser": "~22.
|
|
20
|
-
"@angular/platform-browser-dynamic": "~22.
|
|
21
|
-
"@angular/router": "~22.
|
|
22
|
-
"angular
|
|
23
|
-
"@tsparticles/confetti": "^4.
|
|
24
|
-
"@tsparticles/engine": "^4.
|
|
14
|
+
"@angular/animations": "~22.2.2",
|
|
15
|
+
"@angular/common": "~22.2.2",
|
|
16
|
+
"@angular/compiler": "~22.2.2",
|
|
17
|
+
"@angular/core": "~22.2.2",
|
|
18
|
+
"@angular/forms": "~22.2.2",
|
|
19
|
+
"@angular/platform-browser": "~22.2.2",
|
|
20
|
+
"@angular/platform-browser-dynamic": "~22.2.2",
|
|
21
|
+
"@angular/router": "~22.2.2",
|
|
22
|
+
"@tsparticles/angular": "^4.4.0",
|
|
23
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
24
|
+
"@tsparticles/engine": "^4.4.0",
|
|
25
25
|
"rxjs": "~7.8.2",
|
|
26
26
|
"tslib": "^2.8.1",
|
|
27
|
-
"zone.js": "~0.16.
|
|
27
|
+
"zone.js": "~0.16.3"
|
|
28
28
|
},
|
|
29
29
|
"devDependencies": {
|
|
30
|
-
"@angular-devkit/build-angular": "~22.
|
|
31
|
-
"@angular/cli": "~22.
|
|
32
|
-
"@angular/compiler-cli": "~22.
|
|
30
|
+
"@angular-devkit/build-angular": "~22.2.2",
|
|
31
|
+
"@angular/cli": "~22.2.2",
|
|
32
|
+
"@angular/compiler-cli": "~22.2.2",
|
|
33
33
|
"typescript": "~6.0.3"
|
|
34
34
|
}
|
|
35
35
|
}
|
|
@@ -9,11 +9,11 @@
|
|
|
9
9
|
"preview": "astro preview"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"@astrojs/check": "^0.9.
|
|
13
|
-
"astro": "^
|
|
14
|
-
"@tsparticles/astro": "^4.
|
|
15
|
-
"@tsparticles/confetti": "^4.
|
|
16
|
-
"@tsparticles/engine": "^4.
|
|
12
|
+
"@astrojs/check": "^0.9.10",
|
|
13
|
+
"astro": "^7.3.2",
|
|
14
|
+
"@tsparticles/astro": "^4.4.0",
|
|
15
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
16
|
+
"@tsparticles/engine": "^4.4.0"
|
|
17
17
|
},
|
|
18
18
|
"devDependencies": {
|
|
19
19
|
"typescript": "^6.0.3"
|
|
@@ -28,14 +28,12 @@
|
|
|
28
28
|
"webpack": "^5.106.1"
|
|
29
29
|
},
|
|
30
30
|
"dependencies": {
|
|
31
|
-
"@tsparticles/
|
|
32
|
-
"@tsparticles/
|
|
33
|
-
"@tsparticles/engine": "^4.
|
|
31
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
32
|
+
"@tsparticles/ember": "^4.4.0",
|
|
33
|
+
"@tsparticles/engine": "^4.4.0",
|
|
34
|
+
"@tsparticles/slim": "^4.4.0"
|
|
34
35
|
},
|
|
35
36
|
"ember": {
|
|
36
37
|
"edition": "octane"
|
|
37
|
-
},
|
|
38
|
-
"ember-addon": {
|
|
39
|
-
"configPath": "tests/dummy/config"
|
|
40
38
|
}
|
|
41
39
|
}
|
|
@@ -10,14 +10,13 @@
|
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"inferno": "^9.1.0",
|
|
13
|
-
"
|
|
14
|
-
"@tsparticles/
|
|
15
|
-
"@tsparticles/
|
|
13
|
+
"inferno-create-element": "^9.1.0",
|
|
14
|
+
"@tsparticles/inferno": "^4.4.0",
|
|
15
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
16
|
+
"@tsparticles/engine": "^4.4.0"
|
|
16
17
|
},
|
|
17
18
|
"devDependencies": {
|
|
18
19
|
"typescript": "^6.0.3",
|
|
19
|
-
"vite": "^8.
|
|
20
|
-
"babel-plugin-inferno": "^6.8.5",
|
|
21
|
-
"vite-plugin-inferno": "^2.0.1"
|
|
20
|
+
"vite": "^8.3.5"
|
|
22
21
|
}
|
|
23
22
|
}
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import Particles,
|
|
1
|
+
import { Particles, ParticlesProvider } from "@tsparticles/inferno";
|
|
2
2
|
import { confetti } from "@tsparticles/confetti";
|
|
3
3
|
import type { Engine } from "@tsparticles/engine";
|
|
4
4
|
import { Component } from "inferno";
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
+
<title>{{projectName}}</title>
|
|
7
|
+
</head>
|
|
8
|
+
<body>
|
|
9
|
+
<div id="app">
|
|
10
|
+
<h1>Confetti!</h1>
|
|
11
|
+
<div class="controls">
|
|
12
|
+
<button id="fireBtn">Fire Confetti</button>
|
|
13
|
+
<select id="modeSelect">
|
|
14
|
+
<option value="cannon">Cannon</option>
|
|
15
|
+
<option value="waterfall">Waterfall</option>
|
|
16
|
+
<option value="random">Random</option>
|
|
17
|
+
</select>
|
|
18
|
+
</div>
|
|
19
|
+
</div>
|
|
20
|
+
<script type="module" src="/src/main.ts"></script>
|
|
21
|
+
</body>
|
|
22
|
+
</html>
|
|
@@ -10,12 +10,13 @@
|
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"jquery": "^3.7.1",
|
|
13
|
-
"@tsparticles/jquery": "^4.
|
|
14
|
-
"@tsparticles/confetti": "^4.
|
|
15
|
-
"@tsparticles/engine": "^4.
|
|
13
|
+
"@tsparticles/jquery": "^4.4.0",
|
|
14
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
15
|
+
"@tsparticles/engine": "^4.4.0"
|
|
16
16
|
},
|
|
17
17
|
"devDependencies": {
|
|
18
18
|
"typescript": "^5.7.2",
|
|
19
|
-
"vite": "^
|
|
19
|
+
"vite": "^8.3.5",
|
|
20
|
+
"@types/jquery": "^3.5.32"
|
|
20
21
|
}
|
|
21
22
|
}
|
|
@@ -1,6 +1,4 @@
|
|
|
1
|
-
import $ from "jquery";
|
|
2
1
|
import "@tsparticles/jquery";
|
|
3
|
-
import { tsParticles } from "@tsparticles/engine";
|
|
4
2
|
import { confetti } from "@tsparticles/confetti";
|
|
5
3
|
import "./style.css";
|
|
6
4
|
|
|
@@ -9,8 +7,6 @@ function randomInRange(min: number, max: number): number {
|
|
|
9
7
|
}
|
|
10
8
|
|
|
11
9
|
(async () => {
|
|
12
|
-
$("#tsparticles").particles().load({});
|
|
13
|
-
|
|
14
10
|
const fireBtn = document.getElementById("fireBtn") as HTMLButtonElement;
|
|
15
11
|
const modeSelect = document.getElementById("modeSelect") as HTMLSelectElement;
|
|
16
12
|
|
|
@@ -9,13 +9,13 @@
|
|
|
9
9
|
"preview": "vite preview"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"lit": "^3.
|
|
13
|
-
"@tsparticles/lit": "^4.
|
|
14
|
-
"@tsparticles/confetti": "^4.
|
|
15
|
-
"@tsparticles/engine": "^4.
|
|
12
|
+
"lit": "^3.3.0",
|
|
13
|
+
"@tsparticles/lit": "^4.4.0",
|
|
14
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
15
|
+
"@tsparticles/engine": "^4.4.0"
|
|
16
16
|
},
|
|
17
17
|
"devDependencies": {
|
|
18
18
|
"typescript": "^5.7.2",
|
|
19
|
-
"vite": "^
|
|
19
|
+
"vite": "^8.3.5"
|
|
20
20
|
}
|
|
21
21
|
}
|
|
@@ -11,14 +11,14 @@
|
|
|
11
11
|
"next": "^15.3.2",
|
|
12
12
|
"react": "^19.2.5",
|
|
13
13
|
"react-dom": "^19.2.5",
|
|
14
|
-
"@tsparticles/nextjs": "^4.
|
|
15
|
-
"@tsparticles/confetti": "^4.
|
|
16
|
-
"@tsparticles/engine": "^4.
|
|
14
|
+
"@tsparticles/nextjs": "^4.4.0",
|
|
15
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
16
|
+
"@tsparticles/engine": "^4.4.0"
|
|
17
17
|
},
|
|
18
18
|
"devDependencies": {
|
|
19
|
-
"
|
|
20
|
-
"@types/node": "^22.15.3",
|
|
19
|
+
"@types/node": "^26.6.6",
|
|
21
20
|
"@types/react": "^19.1.4",
|
|
22
|
-
"@types/react-dom": "^19.1.3"
|
|
21
|
+
"@types/react-dom": "^19.1.3",
|
|
22
|
+
"typescript": "^6.0.3"
|
|
23
23
|
}
|
|
24
24
|
}
|
|
@@ -9,8 +9,17 @@
|
|
|
9
9
|
},
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"nuxt": "^2.18.1",
|
|
12
|
-
"@tsparticles/nuxt2": "^4.
|
|
13
|
-
"@tsparticles/confetti": "^4.
|
|
14
|
-
"@tsparticles/engine": "^4.
|
|
12
|
+
"@tsparticles/nuxt2": "^4.4.0",
|
|
13
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
14
|
+
"@tsparticles/engine": "^4.4.0"
|
|
15
|
+
},
|
|
16
|
+
"browserslist": [
|
|
17
|
+
"chrome 58",
|
|
18
|
+
"edge 16",
|
|
19
|
+
"firefox 57",
|
|
20
|
+
"safari 11"
|
|
21
|
+
],
|
|
22
|
+
"devDependencies": {
|
|
23
|
+
"@babel/preset-env": "^7.29.0"
|
|
15
24
|
}
|
|
16
25
|
}
|
|
@@ -10,9 +10,9 @@
|
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"nuxt": "^3.17.3",
|
|
13
|
-
"@tsparticles/nuxt3": "^4.
|
|
14
|
-
"@tsparticles/confetti": "^4.
|
|
15
|
-
"@tsparticles/engine": "^4.
|
|
13
|
+
"@tsparticles/nuxt3": "^4.4.0",
|
|
14
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
15
|
+
"@tsparticles/engine": "^4.4.0"
|
|
16
16
|
},
|
|
17
17
|
"devDependencies": {
|
|
18
18
|
"typescript": "^6.0.3"
|
|
@@ -10,9 +10,9 @@
|
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"nuxt": "^4.4.2",
|
|
13
|
-
"@tsparticles/nuxt4": "^4.
|
|
14
|
-
"@tsparticles/confetti": "^4.
|
|
15
|
-
"@tsparticles/engine": "^4.
|
|
13
|
+
"@tsparticles/nuxt4": "^4.4.0",
|
|
14
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
15
|
+
"@tsparticles/engine": "^4.4.0"
|
|
16
16
|
},
|
|
17
17
|
"devDependencies": {
|
|
18
18
|
"typescript": "^6.0.3"
|
|
@@ -10,13 +10,13 @@
|
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"preact": "^10.19.3",
|
|
13
|
-
"@tsparticles/preact": "^4.
|
|
14
|
-
"@tsparticles/confetti": "^4.
|
|
15
|
-
"@tsparticles/engine": "^4.
|
|
13
|
+
"@tsparticles/preact": "^4.4.0",
|
|
14
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
15
|
+
"@tsparticles/engine": "^4.4.0"
|
|
16
16
|
},
|
|
17
17
|
"devDependencies": {
|
|
18
18
|
"@preact/preset-vite": "^2.8.1",
|
|
19
19
|
"typescript": "^5.7.2",
|
|
20
|
-
"vite": "^
|
|
20
|
+
"vite": "^8.3.5"
|
|
21
21
|
}
|
|
22
22
|
}
|
|
@@ -10,12 +10,12 @@
|
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"@builder.io/qwik": "^1.12.0",
|
|
13
|
-
"@tsparticles/qwik": "^4.
|
|
14
|
-
"@tsparticles/confetti": "^4.
|
|
15
|
-
"@tsparticles/engine": "^4.
|
|
13
|
+
"@tsparticles/qwik": "^4.4.0",
|
|
14
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
15
|
+
"@tsparticles/engine": "^4.4.0"
|
|
16
16
|
},
|
|
17
17
|
"devDependencies": {
|
|
18
18
|
"typescript": "^5.7.2",
|
|
19
|
-
"vite": "^
|
|
19
|
+
"vite": "^7.3.6"
|
|
20
20
|
}
|
|
21
21
|
}
|
|
@@ -11,9 +11,11 @@
|
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"react": "^19.2.5",
|
|
13
13
|
"react-dom": "^19.2.5",
|
|
14
|
-
"@tsparticles/react": "^4.
|
|
14
|
+
"@tsparticles/react": "^4.4.0"
|
|
15
15
|
},
|
|
16
16
|
"devDependencies": {
|
|
17
|
-
"@vitejs/plugin-react": "^6.0.1"
|
|
17
|
+
"@vitejs/plugin-react": "^6.0.1",
|
|
18
|
+
"@types/react": "^19.2.14",
|
|
19
|
+
"@types/react-dom": "^19.2.3"
|
|
18
20
|
}
|
|
19
21
|
}
|
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import { useState } from "react";
|
|
2
|
-
import
|
|
2
|
+
import { ParticlesProvider } from "@tsparticles/react";
|
|
3
3
|
import { confetti } from "@tsparticles/confetti";
|
|
4
|
-
import type { Engine } from "@tsparticles/engine";
|
|
5
4
|
import "./App.css";
|
|
6
5
|
|
|
7
6
|
function randomInRange(min: number, max: number): number {
|
|
8
7
|
return Math.random() * (max - min) + min;
|
|
9
8
|
}
|
|
10
9
|
|
|
11
|
-
async function init(
|
|
10
|
+
async function init(): Promise<void> {
|
|
11
|
+
}
|
|
12
12
|
|
|
13
13
|
export default function App() {
|
|
14
14
|
const [mode, setMode] = useState("cannon");
|
|
@@ -9,15 +9,15 @@
|
|
|
9
9
|
"preview": "vite preview"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"riot": "^10.
|
|
13
|
-
"@tsparticles/riot": "^4.
|
|
14
|
-
"@tsparticles/confetti": "^4.
|
|
15
|
-
"@tsparticles/engine": "^4.
|
|
12
|
+
"riot": "^10.1.6",
|
|
13
|
+
"@tsparticles/riot": "^4.4.0",
|
|
14
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
15
|
+
"@tsparticles/engine": "^4.4.0"
|
|
16
16
|
},
|
|
17
17
|
"devDependencies": {
|
|
18
18
|
"@riotjs/compiler": "^10.0.0",
|
|
19
19
|
"rollup-plugin-riot": "^10.0.0",
|
|
20
20
|
"typescript": "^5.7.2",
|
|
21
|
-
"vite": "^
|
|
21
|
+
"vite": "^8.3.5"
|
|
22
22
|
}
|
|
23
23
|
}
|
|
@@ -9,9 +9,9 @@
|
|
|
9
9
|
},
|
|
10
10
|
"dependencies": {
|
|
11
11
|
"@stencil/core": "^4.43.5",
|
|
12
|
-
"@tsparticles/stencil": "^4.
|
|
13
|
-
"@tsparticles/confetti": "^4.
|
|
14
|
-
"@tsparticles/engine": "^4.
|
|
12
|
+
"@tsparticles/stencil": "^4.4.0",
|
|
13
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
14
|
+
"@tsparticles/engine": "^4.4.0"
|
|
15
15
|
},
|
|
16
16
|
"devDependencies": {
|
|
17
17
|
"typescript": "^6.0.3"
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { Component, State, h, type JSX } from "@stencil/core";
|
|
2
2
|
import { confetti } from "@tsparticles/confetti";
|
|
3
|
-
import type { Engine } from "@tsparticles/engine";
|
|
4
3
|
|
|
5
4
|
function randomInRange(min: number, max: number): number {
|
|
6
5
|
return Math.random() * (max - min) + min;
|
|
@@ -15,8 +14,6 @@ export class AppHome {
|
|
|
15
14
|
@State()
|
|
16
15
|
private mode = "cannon";
|
|
17
16
|
|
|
18
|
-
private async particlesInit(engine: Engine): Promise<void> {}
|
|
19
|
-
|
|
20
17
|
private fireConfetti(): void {
|
|
21
18
|
switch (this.mode) {
|
|
22
19
|
case "cannon":
|
|
@@ -56,17 +53,18 @@ export class AppHome {
|
|
|
56
53
|
<h1>Confetti!</h1>
|
|
57
54
|
<div class="controls">
|
|
58
55
|
<button onClick={this.fireConfetti.bind(this)}>Fire Confetti</button>
|
|
59
|
-
<select
|
|
60
|
-
<option value="cannon">
|
|
61
|
-
|
|
62
|
-
|
|
56
|
+
<select onChange={this.handleModeChange.bind(this)}>
|
|
57
|
+
<option value="cannon" selected={this.mode === "cannon"}>
|
|
58
|
+
Cannon
|
|
59
|
+
</option>
|
|
60
|
+
<option value="waterfall" selected={this.mode === "waterfall"}>
|
|
61
|
+
Waterfall
|
|
62
|
+
</option>
|
|
63
|
+
<option value="random" selected={this.mode === "random"}>
|
|
64
|
+
Random
|
|
65
|
+
</option>
|
|
63
66
|
</select>
|
|
64
67
|
</div>
|
|
65
|
-
<stencil-particles
|
|
66
|
-
container-id="tsparticles"
|
|
67
|
-
init={this.particlesInit.bind(this)}
|
|
68
|
-
options={{}}
|
|
69
|
-
/>
|
|
70
68
|
</div>
|
|
71
69
|
);
|
|
72
70
|
}
|
|
@@ -10,14 +10,14 @@
|
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
12
|
"vue": "^2.7.16",
|
|
13
|
-
"@tsparticles/vue2": "^4.
|
|
14
|
-
"@tsparticles/confetti": "^4.
|
|
15
|
-
"@tsparticles/engine": "^4.
|
|
13
|
+
"@tsparticles/vue2": "^4.4.0",
|
|
14
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
15
|
+
"@tsparticles/engine": "^4.4.0"
|
|
16
16
|
},
|
|
17
17
|
"devDependencies": {
|
|
18
|
-
"@vitejs/plugin-vue2": "^2.
|
|
18
|
+
"@vitejs/plugin-vue2": "^2.3.4",
|
|
19
19
|
"vue-template-compiler": "^2.7.16",
|
|
20
20
|
"typescript": "^5.7.2",
|
|
21
|
-
"vite": "^
|
|
21
|
+
"vite": "^7.3.6"
|
|
22
22
|
}
|
|
23
23
|
}
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
<!doctype html>
|
|
2
|
+
<html lang="en">
|
|
3
|
+
<head>
|
|
4
|
+
<meta charset="UTF-8" />
|
|
5
|
+
<meta name="viewport" content="width=device-width, initial-scale=1.0" />
|
|
6
|
+
<title>{{projectName}}</title>
|
|
7
|
+
</head>
|
|
8
|
+
<body>
|
|
9
|
+
<div id="app">
|
|
10
|
+
<h1>Confetti!</h1>
|
|
11
|
+
<div class="controls">
|
|
12
|
+
<button id="fireBtn">Fire Confetti</button>
|
|
13
|
+
<select id="modeSelect">
|
|
14
|
+
<option value="cannon">Cannon</option>
|
|
15
|
+
<option value="waterfall">Waterfall</option>
|
|
16
|
+
<option value="random">Random</option>
|
|
17
|
+
</select>
|
|
18
|
+
</div>
|
|
19
|
+
</div>
|
|
20
|
+
<script type="module" src="/src/main.ts"></script>
|
|
21
|
+
</body>
|
|
22
|
+
</html>
|
|
@@ -9,12 +9,12 @@
|
|
|
9
9
|
"preview": "vite preview"
|
|
10
10
|
},
|
|
11
11
|
"dependencies": {
|
|
12
|
-
"@tsparticles/webcomponents": "^4.
|
|
13
|
-
"@tsparticles/confetti": "^4.
|
|
14
|
-
"@tsparticles/engine": "^4.
|
|
12
|
+
"@tsparticles/webcomponents": "^4.4.0",
|
|
13
|
+
"@tsparticles/confetti": "^4.4.0",
|
|
14
|
+
"@tsparticles/engine": "^4.4.0"
|
|
15
15
|
},
|
|
16
16
|
"devDependencies": {
|
|
17
17
|
"typescript": "^5.7.2",
|
|
18
|
-
"vite": "^
|
|
18
|
+
"vite": "^8.3.5"
|
|
19
19
|
}
|
|
20
20
|
}
|
|
@@ -1,7 +1,10 @@
|
|
|
1
1
|
import "./style.css";
|
|
2
|
+
import { tsParticles } from "@tsparticles/engine";
|
|
2
3
|
import { defineParticlesElement, initParticlesEngine } from "@tsparticles/webcomponents";
|
|
3
4
|
import { confetti } from "@tsparticles/confetti";
|
|
4
5
|
|
|
6
|
+
globalThis.tsParticles = tsParticles;
|
|
7
|
+
|
|
5
8
|
void initParticlesEngine(() => Promise.resolve());
|
|
6
9
|
|
|
7
10
|
defineParticlesElement();
|
package/template.json
CHANGED
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
{
|
|
2
2
|
"package": {
|
|
3
3
|
"dependencies": {
|
|
4
|
-
"@tsparticles/engine": "^4.
|
|
5
|
-
"@tsparticles/confetti": "^4.
|
|
4
|
+
"@tsparticles/engine": "^4.5.1",
|
|
5
|
+
"@tsparticles/confetti": "^4.5.1"
|
|
6
6
|
},
|
|
7
7
|
"devDependencies": {
|
|
8
8
|
"typescript": "^6.0.3",
|
|
9
|
-
"vite": "^8.
|
|
9
|
+
"vite": "^8.3.5"
|
|
10
10
|
}
|
|
11
11
|
}
|
|
12
|
-
}
|
|
12
|
+
}
|