angular-confetti 4.2.1 → 4.3.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.
|
@@ -39,13 +39,12 @@ class NgxConfettiComponent {
|
|
|
39
39
|
container?.destroy();
|
|
40
40
|
return;
|
|
41
41
|
}
|
|
42
|
-
this.#container?.destroy();
|
|
43
42
|
this.#container = container;
|
|
44
43
|
}
|
|
45
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.
|
|
46
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.
|
|
44
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: NgxConfettiComponent, deps: [{ token: PLATFORM_ID }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
45
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "22.0.2", type: NgxConfettiComponent, isStandalone: false, selector: "ngx-confetti", inputs: { options: "options", id: "id", fire: "fire" }, usesOnChanges: true, ngImport: i0, template: '<div [id]="id"></div>', isInline: true }); }
|
|
47
46
|
}
|
|
48
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.
|
|
47
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: NgxConfettiComponent, decorators: [{
|
|
49
48
|
type: Component,
|
|
50
49
|
args: [{
|
|
51
50
|
selector: "ngx-confetti",
|
|
@@ -67,11 +66,11 @@ class NgxConfettiModule {
|
|
|
67
66
|
constructor() {
|
|
68
67
|
void confetti.init();
|
|
69
68
|
}
|
|
70
|
-
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.
|
|
71
|
-
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "22.0.
|
|
72
|
-
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "22.0.
|
|
69
|
+
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: NgxConfettiModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule }); }
|
|
70
|
+
static { this.ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "22.0.2", ngImport: i0, type: NgxConfettiModule, declarations: [NgxConfettiComponent], exports: [NgxConfettiComponent] }); }
|
|
71
|
+
static { this.ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: NgxConfettiModule }); }
|
|
73
72
|
}
|
|
74
|
-
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.
|
|
73
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.2", ngImport: i0, type: NgxConfettiModule, decorators: [{
|
|
75
74
|
type: NgModule,
|
|
76
75
|
args: [{
|
|
77
76
|
declarations: [NgxConfettiComponent],
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"angular-confetti.mjs","sources":["../../../projects/ng-confetti/src/lib/ng-confetti.component.ts","../../../projects/ng-confetti/src/lib/ng-confetti.module.ts","../../../projects/ng-confetti/src/public-api.ts","../../../projects/ng-confetti/src/angular-confetti.ts"],"sourcesContent":["import { isPlatformServer } from \"@angular/common\";\nimport {\n AfterViewInit,\n Component,\n Inject,\n Input,\n OnChanges,\n OnDestroy,\n PLATFORM_ID,\n SimpleChanges,\n} from \"@angular/core\";\nimport { confetti, ConfettiOptions } from \"@tsparticles/confetti\";\nimport type { Container } from \"@tsparticles/engine\";\n\n@Component({\n selector: \"ngx-confetti\",\n standalone: false,\n template: '<div [id]=\"id\"></div>',\n})\nexport class NgxConfettiComponent implements AfterViewInit, OnChanges, OnDestroy {\n @Input() options?: ConfettiOptions;\n @Input() id = \"tsparticles\";\n @Input() fire: boolean | number = true;\n\n #container?: Container;\n #renderId = 0;\n\n constructor(@Inject(PLATFORM_ID) protected platformId: string) {}\n\n public ngAfterViewInit(): void {\n if (isPlatformServer(this.platformId)) {\n return;\n }\n\n void this.#tryFire();\n }\n\n public ngOnChanges(changes: SimpleChanges): void {\n if (isPlatformServer(this.platformId)) {\n return;\n }\n\n const fireChanges = changes[\"fire\"];\n\n if (this.fire && fireChanges && fireChanges.previousValue !== fireChanges.currentValue) {\n void this.#tryFire();\n }\n }\n\n public ngOnDestroy(): void {\n this.#renderId++;\n this.#container?.destroy();\n\n this.#container = undefined;\n }\n\n async #tryFire(): Promise<void> {\n const currentRenderId = ++this.#renderId;\n const container = await confetti(this.id, this.options);\n\n if (currentRenderId !== this.#renderId) {\n container?.destroy();\n\n return;\n }\n\n this.#container
|
|
1
|
+
{"version":3,"file":"angular-confetti.mjs","sources":["../../../projects/ng-confetti/src/lib/ng-confetti.component.ts","../../../projects/ng-confetti/src/lib/ng-confetti.module.ts","../../../projects/ng-confetti/src/public-api.ts","../../../projects/ng-confetti/src/angular-confetti.ts"],"sourcesContent":["import { isPlatformServer } from \"@angular/common\";\nimport {\n AfterViewInit,\n Component,\n Inject,\n Input,\n OnChanges,\n OnDestroy,\n PLATFORM_ID,\n SimpleChanges,\n} from \"@angular/core\";\nimport { confetti, ConfettiOptions } from \"@tsparticles/confetti\";\nimport type { Container } from \"@tsparticles/engine\";\n\n@Component({\n selector: \"ngx-confetti\",\n standalone: false,\n template: '<div [id]=\"id\"></div>',\n})\nexport class NgxConfettiComponent implements AfterViewInit, OnChanges, OnDestroy {\n @Input() options?: ConfettiOptions;\n @Input() id = \"tsparticles\";\n @Input() fire: boolean | number = true;\n\n #container?: Container;\n #renderId = 0;\n\n constructor(@Inject(PLATFORM_ID) protected platformId: string) {}\n\n public ngAfterViewInit(): void {\n if (isPlatformServer(this.platformId)) {\n return;\n }\n\n void this.#tryFire();\n }\n\n public ngOnChanges(changes: SimpleChanges): void {\n if (isPlatformServer(this.platformId)) {\n return;\n }\n\n const fireChanges = changes[\"fire\"];\n\n if (this.fire && fireChanges && fireChanges.previousValue !== fireChanges.currentValue) {\n void this.#tryFire();\n }\n }\n\n public ngOnDestroy(): void {\n this.#renderId++;\n this.#container?.destroy();\n\n this.#container = undefined;\n }\n\n async #tryFire(): Promise<void> {\n const currentRenderId = ++this.#renderId;\n const container = await confetti(this.id, this.options);\n\n if (currentRenderId !== this.#renderId) {\n container?.destroy();\n\n return;\n }\n\n this.#container = container;\n }\n}\n","import { NgModule } from \"@angular/core\";\nimport { confetti } from \"@tsparticles/confetti\";\nimport { NgxConfettiComponent } from \"./ng-confetti.component\";\n\n@NgModule({\n declarations: [NgxConfettiComponent],\n imports: [],\n exports: [NgxConfettiComponent],\n})\nexport class NgxConfettiModule {\n constructor() {\n void confetti.init();\n }\n}\n","/*\n * Public API Surface of ng-confetti\n */\n\nexport * from \"./lib/ng-confetti.component\";\nexport * from \"./lib/ng-confetti.module\";\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;MAmBa,oBAAoB,CAAA;AAK/B,IAAA,UAAU;AACV,IAAA,SAAS;AAET,IAAA,WAAA,CAA2C,UAAkB,EAAA;QAAlB,IAAA,CAAA,UAAU,GAAV,UAAU;QAN5C,IAAA,CAAA,EAAE,GAAG,aAAa;QAClB,IAAA,CAAA,IAAI,GAAqB,IAAI;QAGtC,IAAA,CAAA,SAAS,GAAG,CAAC;IAEmD;IAEzD,eAAe,GAAA;AACpB,QAAA,IAAI,gBAAgB,CAAC,IAAI,CAAC,UAAU,CAAC,EAAE;YACrC;QACF;AAEA,QAAA,KAAK,IAAI,CAAC,QAAQ,EAAE;IACtB;AAEO,IAAA,WAAW,CAAC,OAAsB,EAAA;AACvC,QAAA,IAAI,gBAAgB,CAAC,IAAI,CAAC,UAAU,CAAC,EAAE;YACrC;QACF;AAEA,QAAA,MAAM,WAAW,GAAG,OAAO,CAAC,MAAM,CAAC;AAEnC,QAAA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jB,oBAAA,QAAQ,EAAE,uBAAuB;AAClC,iBAAA;;0BASc,MAAM;2BAAC,WAAW;;sBAP9B;;sBACA;;sBACA;;;MCbU,iBAAiB,CAAA;AAC5B,IAAA,WAAA,GAAA;AACE,QAAA,KAAK,QAAQ,CAAC,IAAI,EAAE;IACtB;8GAHW,iBAAiB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA,CAAA;+GAAjB,iBAAiB,EAAA,YAAA,EAAA,CAJb,oBAAoB,CAAA,EAAA,OAAA,EAAA,CAEzB,oBAAoB,CAAA,EAAA,CAAA,CAAA;+GAEnB,iBAAiB,EAAA,CAAA,CAAA;;2FAAjB,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAL7B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,YAAY,EAAE,CAAC,oBAAoB,CAAC;AACpC,oBAAA,OAAO,EAAE,EAAE;oBACX,OAAO,EAAE,CAAC,oBAAoB,CAAC;AAChC,iBAAA;;;ACRD;;AAEG;;ACFH;;AAEG;;;;"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "angular-confetti",
|
|
3
|
-
"version": "4.
|
|
3
|
+
"version": "4.3.0",
|
|
4
4
|
"description": "Official tsParticles Angular Confetti Component - Easily create highly customizable particle, confetti and fireworks animations and use them as animated backgrounds for your website. Ready to use components available also for Web Components, React, Vue.js (2.x and 3.x), Svelte, jQuery, Preact, Riot.js, Solid.js, Inferno.",
|
|
5
5
|
"homepage": "https://confetti.js.org",
|
|
6
6
|
"repository": {
|
|
@@ -85,8 +85,8 @@
|
|
|
85
85
|
"@angular/common": ">=12.0.0",
|
|
86
86
|
"@angular/core": ">=12.0.0",
|
|
87
87
|
"rxjs": ">=7.0.0",
|
|
88
|
-
"@tsparticles/confetti": "^4.
|
|
89
|
-
"@tsparticles/engine": "^4.
|
|
88
|
+
"@tsparticles/confetti": "^4.3.0",
|
|
89
|
+
"@tsparticles/engine": "^4.3.0"
|
|
90
90
|
},
|
|
91
91
|
"dependencies": {
|
|
92
92
|
"tslib": "^2.8.1"
|