@uni-design-system/uni-angular 3.0.0 → 3.0.2

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/README.md CHANGED
@@ -21,13 +21,15 @@ The official **Angular** implementation of the Uni Design System. Built from the
21
21
  ```bash
22
22
  npm install @uni-design-system/uni-angular @uni-design-system/uni-core @emotion/css
23
23
  ```
24
- *Note: This package requires `@emotion/css` to be present in the host application as a peer dependency.*
24
+
25
+ _Note: This package requires `@emotion/css` to be present in the host application as a peer dependency._
25
26
 
26
27
  ## 🏁 Getting Started
27
28
 
28
29
  This library utilizes fully standalone components compliant with modern Angular architectures. Simply import the component into your Standalone Component or Angular Module:
29
30
 
30
31
  ### 1. Import Component
32
+
31
33
  ```typescript
32
34
  import { Component } from '@angular/core';
33
35
  import { ButtonComponent } from '@uni-design-system/uni-angular';
@@ -36,12 +38,7 @@ import { ButtonComponent } from '@uni-design-system/uni-angular';
36
38
  selector: 'app-root',
37
39
  standalone: true,
38
40
  imports: [ButtonComponent], // 🟢 Inject here
39
- template: `
40
- <uni-button
41
- text="Hello Uni!"
42
- (click)="handleOnClick()">
43
- </uni-button>
44
- `
41
+ template: ` <uni-button text="Hello Uni!" (click)="handleOnClick()"> </uni-button> `,
45
42
  })
46
43
  export class AppComponent {
47
44
  handleOnClick() {
@@ -51,7 +48,7 @@ export class AppComponent {
51
48
  ```
52
49
 
53
50
  ## 🛠️ Architecture Profile
51
+
54
52
  - **Framework Support:** Angular `^21.2.0`
55
53
  - **Package Format:** Compiled strictly under the **Angular Package Format (APF)** using `ng-packagr` into flat, optimized `fesm2022` modules.
56
54
  - **CSS Architecture:** Leverages native CSS properties and token maps for high-performance hardware rendering, avoiding heavy deprecated runtime framework animation libraries.
57
-
@@ -1,5 +1,5 @@
1
1
  import * as i0 from '@angular/core';
2
- import { signal, computed, linkedSignal, resource, Injectable, inject, DestroyRef, InjectionToken, input, Component, HostBinding, Input, Renderer2, ElementRef, HostListener, Directive, EventEmitter, effect, Output, output, ViewChild, ChangeDetectorRef, ChangeDetectionStrategy } from '@angular/core';
2
+ import { signal, computed, linkedSignal, resource, Injectable, inject, DestroyRef, InjectionToken, input, Component, HostBinding, Input, Renderer2, ElementRef, HostListener, Directive, EventEmitter, effect, Output, output, ViewChild, ChangeDetectorRef, ChangeDetectionStrategy, model } from '@angular/core';
3
3
  import { css, keyframes } from '@emotion/css';
4
4
  import { UniThemes, LightTheme, Z_INDEX, fadeIn, fadeOut } from '@uni-design-system/uni-core';
5
5
  import { NgClass, CommonModule, NgTemplateOutlet } from '@angular/common';
@@ -494,7 +494,7 @@ const UNI_THEMES = new InjectionToken('', {
494
494
  factory: () => UniThemes,
495
495
  });
496
496
 
497
- const safeParseInt = (n) => typeof n === 'number' ? n : parseInt(n);
497
+ const safeParseInt = (n) => (typeof n === 'number' ? n : parseInt(n));
498
498
 
499
499
  // noinspection JSUnusedGlobalSymbols
500
500
  class ThemeService {
@@ -567,7 +567,10 @@ class ThemeService {
567
567
  const token = (color + '-container');
568
568
  return this.colorPair(token, useVariant);
569
569
  };
570
- typeface = (typeface) => typeface && this.typeFaces()[typeface];
570
+ typeface = (typeface) => {
571
+ const typefaces = this.typeFaces();
572
+ return typeface && typefaces[typeface];
573
+ };
571
574
  colorPalette = () => this.colors();
572
575
  color(color) {
573
576
  return !color ? undefined : { color: this.colors()[color] };
@@ -1076,22 +1079,25 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImpo
1076
1079
  }]
1077
1080
  }], ctorParameters: () => [], propDecorators: { display: [{ type: i0.Input, args: [{ isSignal: true, alias: "display", required: false }] }], wrapItems: [{ type: i0.Input, args: [{ isSignal: true, alias: "wrapItems", required: false }] }] } });
1078
1081
 
1079
- class UniSymbolComponent {
1080
- name;
1081
- fill = 0;
1082
- weight = 400;
1083
- grade = 0;
1084
- opticalSize = 24;
1082
+ class UniSymbolComponent extends BaseComponent {
1083
+ name = input.required(...(ngDevMode ? [{ debugName: "name" }] : /* istanbul ignore next */ []));
1084
+ fill = input(...(ngDevMode ? [undefined, { debugName: "fill" }] : /* istanbul ignore next */ []));
1085
+ weight = input(...(ngDevMode ? [undefined, { debugName: "weight" }] : /* istanbul ignore next */ []));
1086
+ grade = input(...(ngDevMode ? [undefined, { debugName: "grade" }] : /* istanbul ignore next */ []));
1087
+ opticalSize = input(...(ngDevMode ? [undefined, { debugName: "opticalSize" }] : /* istanbul ignore next */ []));
1085
1088
  get className() {
1086
- const settings = `'FILL' ${this.fill}, 'wght' ${this.weight}, 'GRAD' ${this.grade}, 'opsz' ${this.opticalSize}`;
1089
+ const settings = `'FILL' ${this.fill() || this.componentOptions().fill || 0}, ` +
1090
+ `'wght' ${this.weight() || this.componentOptions().weight || 400}, ` +
1091
+ `'GRAD' ${this.grade() || this.componentOptions().grade || 0}, ` +
1092
+ `'opsz' ${this.opticalSize() || this.componentOptions().opticalSize || 24}`;
1087
1093
  return ('material-symbols-rounded ' +
1088
1094
  css({
1089
1095
  fontVariationSettings: settings,
1090
- fontSize: `${this.opticalSize}px`,
1096
+ fontSize: `${this.opticalSize() || this.componentOptions().opticalSize || 24}px`,
1091
1097
  }));
1092
1098
  }
1093
- static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: UniSymbolComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
1094
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.12", type: UniSymbolComponent, isStandalone: true, selector: "uni-symbol, Symbol", inputs: { name: "name", fill: "fill", weight: "weight", grade: "grade", opticalSize: "opticalSize" }, host: { properties: { "class": "this.className" } }, ngImport: i0, template: `{{ name }}`, isInline: true });
1099
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: UniSymbolComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
1100
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.12", type: UniSymbolComponent, isStandalone: true, selector: "uni-symbol, Symbol", inputs: { name: { classPropertyName: "name", publicName: "name", isSignal: true, isRequired: true, transformFunction: null }, fill: { classPropertyName: "fill", publicName: "fill", isSignal: true, isRequired: false, transformFunction: null }, weight: { classPropertyName: "weight", publicName: "weight", isSignal: true, isRequired: false, transformFunction: null }, grade: { classPropertyName: "grade", publicName: "grade", isSignal: true, isRequired: false, transformFunction: null }, opticalSize: { classPropertyName: "opticalSize", publicName: "opticalSize", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "this.className" } }, providers: [{ provide: COMPONENT_NAME, useValue: 'symbol' }], usesInheritance: true, ngImport: i0, template: `{{ name() }}`, isInline: true });
1095
1101
  }
1096
1102
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: UniSymbolComponent, decorators: [{
1097
1103
  type: Component,
@@ -1099,19 +1105,10 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImpo
1099
1105
  selector: 'uni-symbol, Symbol',
1100
1106
  standalone: true,
1101
1107
  imports: [],
1102
- template: `{{ name }}`,
1108
+ template: `{{ name() }}`,
1109
+ providers: [{ provide: COMPONENT_NAME, useValue: 'symbol' }],
1103
1110
  }]
1104
- }], propDecorators: { name: [{
1105
- type: Input
1106
- }], fill: [{
1107
- type: Input
1108
- }], weight: [{
1109
- type: Input
1110
- }], grade: [{
1111
- type: Input
1112
- }], opticalSize: [{
1113
- type: Input
1114
- }], className: [{
1111
+ }], propDecorators: { name: [{ type: i0.Input, args: [{ isSignal: true, alias: "name", required: true }] }], fill: [{ type: i0.Input, args: [{ isSignal: true, alias: "fill", required: false }] }], weight: [{ type: i0.Input, args: [{ isSignal: true, alias: "weight", required: false }] }], grade: [{ type: i0.Input, args: [{ isSignal: true, alias: "grade", required: false }] }], opticalSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "opticalSize", required: false }] }], className: [{
1115
1112
  type: HostBinding,
1116
1113
  args: ['class']
1117
1114
  }] } });
@@ -1194,7 +1191,7 @@ class UniButtonComponent extends BaseComponent {
1194
1191
  get className() {
1195
1192
  return css([
1196
1193
  this.style() && {
1197
- ...this.style(),
1194
+ ...this.style(), // TODO: Set priority on theme-defined styles
1198
1195
  },
1199
1196
  {
1200
1197
  display: 'flex',
@@ -1204,7 +1201,6 @@ class UniButtonComponent extends BaseComponent {
1204
1201
  outline: 0,
1205
1202
  border: 0,
1206
1203
  cursor: 'pointer',
1207
- fontFamily: 'Euphemia, sans-serif',
1208
1204
  transition: 'all 0.28s ease',
1209
1205
  '&:disabled': {
1210
1206
  cursor: 'not-allowed !important',
@@ -1938,11 +1934,11 @@ class UniMenuItemComponent extends UniBoxComponent {
1938
1934
  this._elementRef.nativeElement.focus();
1939
1935
  }
1940
1936
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: UniMenuItemComponent, deps: null, target: i0.ɵɵFactoryTarget.Component });
1941
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.12", type: UniMenuItemComponent, isStandalone: true, selector: "div[uni-menu-item], div[menu-item]", inputs: { display: { classPropertyName: "display", publicName: "display", isSignal: true, isRequired: false, transformFunction: null }, flexDirection: { classPropertyName: "flexDirection", publicName: "flexDirection", isSignal: true, isRequired: false, transformFunction: null }, alignItems: { classPropertyName: "alignItems", publicName: "alignItems", isSignal: true, isRequired: false, transformFunction: null }, paddingHorizontal: { classPropertyName: "paddingHorizontal", publicName: "paddingHorizontal", isSignal: true, isRequired: false, transformFunction: null }, gap: { classPropertyName: "gap", publicName: "gap", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, template: { classPropertyName: "template", publicName: "template", isSignal: true, isRequired: false, transformFunction: null }, context: { classPropertyName: "context", publicName: "context", isSignal: true, isRequired: false, transformFunction: null }, symbolName: { classPropertyName: "symbolName", publicName: "symbolName", isSignal: true, isRequired: false, transformFunction: null }, active: { classPropertyName: "active", publicName: "active", isSignal: true, isRequired: false, transformFunction: null }, hoverColor: { classPropertyName: "hoverColor", publicName: "hoverColor", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "this.className" } }, usesInheritance: true, ngImport: i0, template: "@let tpl = template();\n@let symbol = symbolName();\n@if (symbol) {\n <Symbol [name]=\"symbol\"></Symbol>\n}\n<div box-layout [grow]=\"1\">\n @if (tpl) {\n <ng-container\n [ngTemplateOutlet]=\"tpl\"\n [ngTemplateOutletContext]=\"context()\"\n ></ng-container>\n } @else {\n <Text role=\"label\" display=\"block\" [nowrap]=\"true\">\n {{ label() }}\n </Text>\n }\n</div>\n@if (active()) {\n <Symbol name=\"check\"></Symbol>\n}\n", styles: [":host:focus{background:#ccc;color:#fff}:host.disabled{color:#ddd;pointer-events:none}\n"], dependencies: [{ kind: "component", type: UniTextComponent, selector: "uni-text, Text", inputs: ["typeface", "color", "display", "align", "nowrap", "maxWidth", "ellipsis"] }, { kind: "component", type: UniSymbolComponent, selector: "uni-symbol, Symbol", inputs: ["name", "fill", "weight", "grade", "opticalSize"] }, { kind: "component", type: UniBoxComponent, selector: "div[uni-box-layout], Box, div[box-layout]", inputs: ["color", "backgroundColor", "borderRadius", "borderRadiusLeft", "borderRadiusRight", "borderRadiusTop", "borderRadiusBottom", "padding", "paddingHorizontal", "paddingVertical", "paddingLeft", "paddingRight", "paddingTop", "paddingBottom", "border", "borderTop", "borderBottom", "borderLeft", "borderRight", "dashBorder", "alignSelf", "alignItems", "alignContent", "justifyContent", "grow", "display", "position", "inset", "height", "minHeight", "maxHeight", "width", "minWidth", "maxWidth", "ignoreDir", "gridArea", "gridColumn", "gridRow", "overflow", "elevation", "shadow", "gap", "fullWidth", "fullHeight", "flexDirection", "textAlign", "wrapItems", "zIndex"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] });
1937
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.12", type: UniMenuItemComponent, isStandalone: true, selector: "div[uni-menu-item], div[menu-item]", inputs: { display: { classPropertyName: "display", publicName: "display", isSignal: true, isRequired: false, transformFunction: null }, flexDirection: { classPropertyName: "flexDirection", publicName: "flexDirection", isSignal: true, isRequired: false, transformFunction: null }, alignItems: { classPropertyName: "alignItems", publicName: "alignItems", isSignal: true, isRequired: false, transformFunction: null }, paddingHorizontal: { classPropertyName: "paddingHorizontal", publicName: "paddingHorizontal", isSignal: true, isRequired: false, transformFunction: null }, gap: { classPropertyName: "gap", publicName: "gap", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, template: { classPropertyName: "template", publicName: "template", isSignal: true, isRequired: false, transformFunction: null }, context: { classPropertyName: "context", publicName: "context", isSignal: true, isRequired: false, transformFunction: null }, symbolName: { classPropertyName: "symbolName", publicName: "symbolName", isSignal: true, isRequired: false, transformFunction: null }, active: { classPropertyName: "active", publicName: "active", isSignal: true, isRequired: false, transformFunction: null }, hoverColor: { classPropertyName: "hoverColor", publicName: "hoverColor", isSignal: true, isRequired: false, transformFunction: null }, disabled: { classPropertyName: "disabled", publicName: "disabled", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "this.className" } }, usesInheritance: true, ngImport: i0, template: "@let tpl = template();\n@let symbol = symbolName();\n@if (symbol) {\n <Symbol [name]=\"symbol\"></Symbol>\n}\n<div box-layout [grow]=\"1\">\n @if (tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl\" [ngTemplateOutletContext]=\"context()\"></ng-container>\n } @else {\n <Text role=\"label\" display=\"block\" [nowrap]=\"true\">\n {{ label() }}\n </Text>\n }\n</div>\n@if (active()) {\n <Symbol name=\"check\"></Symbol>\n}\n", styles: [":host:focus{background:#ccc;color:#fff}:host.disabled{color:#ddd;pointer-events:none}\n"], dependencies: [{ kind: "component", type: UniTextComponent, selector: "uni-text, Text", inputs: ["typeface", "color", "display", "align", "nowrap", "maxWidth", "ellipsis"] }, { kind: "component", type: UniSymbolComponent, selector: "uni-symbol, Symbol", inputs: ["name", "fill", "weight", "grade", "opticalSize"] }, { kind: "component", type: UniBoxComponent, selector: "div[uni-box-layout], Box, div[box-layout]", inputs: ["color", "backgroundColor", "borderRadius", "borderRadiusLeft", "borderRadiusRight", "borderRadiusTop", "borderRadiusBottom", "padding", "paddingHorizontal", "paddingVertical", "paddingLeft", "paddingRight", "paddingTop", "paddingBottom", "border", "borderTop", "borderBottom", "borderLeft", "borderRight", "dashBorder", "alignSelf", "alignItems", "alignContent", "justifyContent", "grow", "display", "position", "inset", "height", "minHeight", "maxHeight", "width", "minWidth", "maxWidth", "ignoreDir", "gridArea", "gridColumn", "gridRow", "overflow", "elevation", "shadow", "gap", "fullWidth", "fullHeight", "flexDirection", "textAlign", "wrapItems", "zIndex"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }] });
1942
1938
  }
1943
1939
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: UniMenuItemComponent, decorators: [{
1944
1940
  type: Component,
1945
- args: [{ selector: 'div[uni-menu-item], div[menu-item]', standalone: true, imports: [UniTextComponent, UniSymbolComponent, UniBoxComponent, NgTemplateOutlet], template: "@let tpl = template();\n@let symbol = symbolName();\n@if (symbol) {\n <Symbol [name]=\"symbol\"></Symbol>\n}\n<div box-layout [grow]=\"1\">\n @if (tpl) {\n <ng-container\n [ngTemplateOutlet]=\"tpl\"\n [ngTemplateOutletContext]=\"context()\"\n ></ng-container>\n } @else {\n <Text role=\"label\" display=\"block\" [nowrap]=\"true\">\n {{ label() }}\n </Text>\n }\n</div>\n@if (active()) {\n <Symbol name=\"check\"></Symbol>\n}\n", styles: [":host:focus{background:#ccc;color:#fff}:host.disabled{color:#ddd;pointer-events:none}\n"] }]
1941
+ args: [{ selector: 'div[uni-menu-item], div[menu-item]', standalone: true, imports: [UniTextComponent, UniSymbolComponent, UniBoxComponent, NgTemplateOutlet], template: "@let tpl = template();\n@let symbol = symbolName();\n@if (symbol) {\n <Symbol [name]=\"symbol\"></Symbol>\n}\n<div box-layout [grow]=\"1\">\n @if (tpl) {\n <ng-container [ngTemplateOutlet]=\"tpl\" [ngTemplateOutletContext]=\"context()\"></ng-container>\n } @else {\n <Text role=\"label\" display=\"block\" [nowrap]=\"true\">\n {{ label() }}\n </Text>\n }\n</div>\n@if (active()) {\n <Symbol name=\"check\"></Symbol>\n}\n", styles: [":host:focus{background:#ccc;color:#fff}:host.disabled{color:#ddd;pointer-events:none}\n"] }]
1946
1942
  }], propDecorators: { display: [{ type: i0.Input, args: [{ isSignal: true, alias: "display", required: false }] }], flexDirection: [{ type: i0.Input, args: [{ isSignal: true, alias: "flexDirection", required: false }] }], alignItems: [{ type: i0.Input, args: [{ isSignal: true, alias: "alignItems", required: false }] }], paddingHorizontal: [{ type: i0.Input, args: [{ isSignal: true, alias: "paddingHorizontal", required: false }] }], gap: [{ type: i0.Input, args: [{ isSignal: true, alias: "gap", required: false }] }], label: [{ type: i0.Input, args: [{ isSignal: true, alias: "label", required: false }] }], template: [{ type: i0.Input, args: [{ isSignal: true, alias: "template", required: false }] }], context: [{ type: i0.Input, args: [{ isSignal: true, alias: "context", required: false }] }], symbolName: [{ type: i0.Input, args: [{ isSignal: true, alias: "symbolName", required: false }] }], active: [{ type: i0.Input, args: [{ isSignal: true, alias: "active", required: false }] }], hoverColor: [{ type: i0.Input, args: [{ isSignal: true, alias: "hoverColor", required: false }] }], disabled: [{ type: i0.Input, args: [{ isSignal: true, alias: "disabled", required: false }] }], className: [{
1947
1943
  type: HostBinding,
1948
1944
  args: ['class']
@@ -2029,6 +2025,274 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImpo
2029
2025
  args: ['class']
2030
2026
  }] } });
2031
2027
 
2028
+ class UniAlertComponent extends BaseComponent {
2029
+ show = model(...(ngDevMode ? [undefined, { debugName: "show" }] : /* istanbul ignore next */ []));
2030
+ iconName = input(undefined, ...(ngDevMode ? [{ debugName: "iconName" }] : /* istanbul ignore next */ []));
2031
+ symbolName = input(undefined, ...(ngDevMode ? [{ debugName: "symbolName" }] : /* istanbul ignore next */ []));
2032
+ useVariant = input(false, ...(ngDevMode ? [{ debugName: "useVariant" }] : /* istanbul ignore next */ []));
2033
+ showing = new EventEmitter();
2034
+ alertRef;
2035
+ alertState = signal('closed', ...(ngDevMode ? [{ debugName: "alertState" }] : /* istanbul ignore next */ []));
2036
+ effectiveVariant = computed(() => this.variant() || this.componentOptions().defaultVariant, ...(ngDevMode ? [{ debugName: "effectiveVariant" }] : /* istanbul ignore next */ []));
2037
+ alertClass = computed(() => css({
2038
+ ...this.theme.getContainerColors(this.effectiveVariant(), this.useVariant()),
2039
+ ...this.theme.radius(this.componentOptions().borderRadius),
2040
+ ...this.theme.border(this.effectiveVariant()),
2041
+ ...this.theme.boxShadow(this.componentOptions().elevation),
2042
+ transition: `all ${this.componentOptions().transitionSpeed}s ease-in-out`,
2043
+ transitionBehavior: 'allow-discrete',
2044
+ opacity: 1,
2045
+ top: this.componentOptions().topPosition,
2046
+ '&[open]': {
2047
+ '@starting-style': {
2048
+ top: 0,
2049
+ opacity: 0,
2050
+ },
2051
+ },
2052
+ '&[closing]': {
2053
+ animation: `${this.fadeOut} 0.3s forwards`,
2054
+ },
2055
+ }), ...(ngDevMode ? [{ debugName: "alertClass" }] : /* istanbul ignore next */ []));
2056
+ fadeOut = keyframes({ ...fadeOut });
2057
+ constructor() {
2058
+ super();
2059
+ effect(() => {
2060
+ if (this.show() === true) {
2061
+ this.open();
2062
+ }
2063
+ else if (this.show() === false) {
2064
+ this.close();
2065
+ }
2066
+ });
2067
+ }
2068
+ ngAfterViewInit() {
2069
+ this.alertRef?.nativeElement.addEventListener('animationend', (e) => {
2070
+ if (e.animationName === this.fadeOut.toString()) {
2071
+ this.alertRef?.nativeElement.close();
2072
+ this.showing.emit(false);
2073
+ this.alertState.set('closed');
2074
+ }
2075
+ });
2076
+ }
2077
+ open() {
2078
+ if (!this.alertRef?.nativeElement)
2079
+ return;
2080
+ this.alertRef.nativeElement.removeAttribute('closing');
2081
+ this.alertRef.nativeElement.show();
2082
+ this.alertState.set('open');
2083
+ this.showing.emit(true);
2084
+ }
2085
+ close() {
2086
+ if (!this.alertRef?.nativeElement)
2087
+ return;
2088
+ this.alertRef.nativeElement.setAttribute('closing', 'true');
2089
+ this.alertState.set('closing');
2090
+ this.show.set(false);
2091
+ }
2092
+ effectiveIconName = computed(() => this.iconName(), ...(ngDevMode ? [{ debugName: "effectiveIconName" }] : /* istanbul ignore next */ []));
2093
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: UniAlertComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
2094
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.12", type: UniAlertComponent, isStandalone: true, selector: "uni-alert, Alert", inputs: { show: { classPropertyName: "show", publicName: "show", isSignal: true, isRequired: false, transformFunction: null }, iconName: { classPropertyName: "iconName", publicName: "iconName", isSignal: true, isRequired: false, transformFunction: null }, symbolName: { classPropertyName: "symbolName", publicName: "symbolName", isSignal: true, isRequired: false, transformFunction: null }, useVariant: { classPropertyName: "useVariant", publicName: "useVariant", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { show: "showChange", showing: "showing" }, providers: [{ provide: COMPONENT_NAME, useValue: 'alert' }], viewQueries: [{ propertyName: "alertRef", first: true, predicate: ["alert"], descendants: true }], usesInheritance: true, ngImport: i0, template: "<dialog #alert [class]=\"alertClass()\">\n <div row-layout gap=\"md\">\n @if (iconName() || symbolName()) {\n <div box-layout [height]=\"26\" [width]=\"26\">\n @if (effectiveIconName()) {\n <Icon [name]=\"effectiveIconName()!\" />\n } @else {\n <Symbol [name]=\"symbolName()!\" [opticalSize]=\"26\" />\n }\n </div>\n }\n <Text>\n <ng-content></ng-content>\n </Text>\n <button icon-button (click)=\"close()\" iconName=\"close\" size=\"md\">close</button>\n </div>\n</dialog>\n", dependencies: [{ kind: "component", type: UniRowComponent, selector: "div[uni-row-layout], Row, div[row-layout]", inputs: ["display", "flexDirection", "minWidth"] }, { kind: "component", type: UniIconButtonComponent, selector: "button[uni-icon-button], button[icon-button]", inputs: ["iconName", "symbolName", "variant", "size", "disable", "loading", "opticalSize"] }, { kind: "component", type: UniTextComponent, selector: "uni-text, Text", inputs: ["typeface", "color", "display", "align", "nowrap", "maxWidth", "ellipsis"] }, { kind: "component", type: UniBoxComponent, selector: "div[uni-box-layout], Box, div[box-layout]", inputs: ["color", "backgroundColor", "borderRadius", "borderRadiusLeft", "borderRadiusRight", "borderRadiusTop", "borderRadiusBottom", "padding", "paddingHorizontal", "paddingVertical", "paddingLeft", "paddingRight", "paddingTop", "paddingBottom", "border", "borderTop", "borderBottom", "borderLeft", "borderRight", "dashBorder", "alignSelf", "alignItems", "alignContent", "justifyContent", "grow", "display", "position", "inset", "height", "minHeight", "maxHeight", "width", "minWidth", "maxWidth", "ignoreDir", "gridArea", "gridColumn", "gridRow", "overflow", "elevation", "shadow", "gap", "fullWidth", "fullHeight", "flexDirection", "textAlign", "wrapItems", "zIndex"] }, { kind: "component", type: UniIconComponent, selector: "uni-icon, Icon", inputs: ["color", "name"] }, { kind: "component", type: UniSymbolComponent, selector: "uni-symbol, Symbol", inputs: ["name", "fill", "weight", "grade", "opticalSize"] }] });
2095
+ }
2096
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: UniAlertComponent, decorators: [{
2097
+ type: Component,
2098
+ args: [{ selector: 'uni-alert, Alert', standalone: true, imports: [
2099
+ UniRowComponent,
2100
+ UniIconButtonComponent,
2101
+ UniTextComponent,
2102
+ UniBoxComponent,
2103
+ UniIconComponent,
2104
+ UniSymbolComponent,
2105
+ ], providers: [{ provide: COMPONENT_NAME, useValue: 'alert' }], template: "<dialog #alert [class]=\"alertClass()\">\n <div row-layout gap=\"md\">\n @if (iconName() || symbolName()) {\n <div box-layout [height]=\"26\" [width]=\"26\">\n @if (effectiveIconName()) {\n <Icon [name]=\"effectiveIconName()!\" />\n } @else {\n <Symbol [name]=\"symbolName()!\" [opticalSize]=\"26\" />\n }\n </div>\n }\n <Text>\n <ng-content></ng-content>\n </Text>\n <button icon-button (click)=\"close()\" iconName=\"close\" size=\"md\">close</button>\n </div>\n</dialog>\n" }]
2106
+ }], ctorParameters: () => [], propDecorators: { show: [{ type: i0.Input, args: [{ isSignal: true, alias: "show", required: false }] }, { type: i0.Output, args: ["showChange"] }], iconName: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconName", required: false }] }], symbolName: [{ type: i0.Input, args: [{ isSignal: true, alias: "symbolName", required: false }] }], useVariant: [{ type: i0.Input, args: [{ isSignal: true, alias: "useVariant", required: false }] }], showing: [{
2107
+ type: Output
2108
+ }], alertRef: [{
2109
+ type: ViewChild,
2110
+ args: ['alert']
2111
+ }] } });
2112
+
2113
+ class ConfirmationDialogComponent {
2114
+ show = input(false, ...(ngDevMode ? [{ debugName: "show" }] : /* istanbul ignore next */ []));
2115
+ confirmation;
2116
+ showing = new EventEmitter();
2117
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: ConfirmationDialogComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
2118
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "21.2.12", type: ConfirmationDialogComponent, isStandalone: true, selector: "uni-confirmation-dialog, Confirmation", inputs: { show: { classPropertyName: "show", publicName: "show", isSignal: true, isRequired: false, transformFunction: null }, confirmation: { classPropertyName: "confirmation", publicName: "confirmation", isSignal: false, isRequired: false, transformFunction: null } }, outputs: { showing: "showing" }, ngImport: i0, template: "<dialog uni-dialog [show]=\"show()\" (showing)=\"showing.emit($event)\">\n <div uni-dialog-header>\n {{ confirmation?.title }}\n </div>\n <div box-layout padding=\"md\">\n <Text>\n {{ confirmation?.message }}\n </Text>\n </div>\n <div\n dialog-buttons\n [confirmButtonText]=\"confirmation?.actionLabel\"\n (confirmed)=\"confirmation?.action()\"\n [cancelButtonText]=\"confirmation?.dismissLabel\"\n ></div>\n</dialog>\n", dependencies: [{ kind: "component", type: UniDialogComponent, selector: "dialog[uni-dialog], Dialog", inputs: ["show", "defaultCloseButton"], outputs: ["showing"] }, { kind: "component", type: UniDialogHeaderComponent, selector: "div[uni-dialog-header], DialogHeader" }, { kind: "component", type: UniBoxComponent, selector: "div[uni-box-layout], Box, div[box-layout]", inputs: ["color", "backgroundColor", "borderRadius", "borderRadiusLeft", "borderRadiusRight", "borderRadiusTop", "borderRadiusBottom", "padding", "paddingHorizontal", "paddingVertical", "paddingLeft", "paddingRight", "paddingTop", "paddingBottom", "border", "borderTop", "borderBottom", "borderLeft", "borderRight", "dashBorder", "alignSelf", "alignItems", "alignContent", "justifyContent", "grow", "display", "position", "inset", "height", "minHeight", "maxHeight", "width", "minWidth", "maxWidth", "ignoreDir", "gridArea", "gridColumn", "gridRow", "overflow", "elevation", "shadow", "gap", "fullWidth", "fullHeight", "flexDirection", "textAlign", "wrapItems", "zIndex"] }, { kind: "component", type: UniTextComponent, selector: "uni-text, Text", inputs: ["typeface", "color", "display", "align", "nowrap", "maxWidth", "ellipsis"] }, { kind: "component", type: UniDialogButtonsComponent, selector: "uni-dialog-buttons, DialogButtons, div[dialog-buttons]", inputs: ["confirmButtonText", "confirmButtonVariant", "cancelButtonText", "disableConfirm", "padding", "paddingBottom", "justifyContent"], outputs: ["confirmed"] }] });
2119
+ }
2120
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: ConfirmationDialogComponent, decorators: [{
2121
+ type: Component,
2122
+ args: [{ selector: 'uni-confirmation-dialog, Confirmation', standalone: true, imports: [
2123
+ UniDialogComponent,
2124
+ UniDialogHeaderComponent,
2125
+ UniBoxComponent,
2126
+ UniTextComponent,
2127
+ UniDialogButtonsComponent,
2128
+ ], template: "<dialog uni-dialog [show]=\"show()\" (showing)=\"showing.emit($event)\">\n <div uni-dialog-header>\n {{ confirmation?.title }}\n </div>\n <div box-layout padding=\"md\">\n <Text>\n {{ confirmation?.message }}\n </Text>\n </div>\n <div\n dialog-buttons\n [confirmButtonText]=\"confirmation?.actionLabel\"\n (confirmed)=\"confirmation?.action()\"\n [cancelButtonText]=\"confirmation?.dismissLabel\"\n ></div>\n</dialog>\n" }]
2129
+ }], propDecorators: { show: [{ type: i0.Input, args: [{ isSignal: true, alias: "show", required: false }] }], confirmation: [{
2130
+ type: Input
2131
+ }], showing: [{
2132
+ type: Output
2133
+ }] } });
2134
+
2135
+ class UniSnackbarComponent extends BaseComponent {
2136
+ timer = useTimer();
2137
+ snackbarClass;
2138
+ show;
2139
+ iconName = input(...(ngDevMode ? [undefined, { debugName: "iconName" }] : /* istanbul ignore next */ []));
2140
+ symbolName = input(...(ngDevMode ? [undefined, { debugName: "symbolName" }] : /* istanbul ignore next */ []));
2141
+ timeout = input(...(ngDevMode ? [undefined, { debugName: "timeout" }] : /* istanbul ignore next */ []));
2142
+ actionLabel = input(...(ngDevMode ? [undefined, { debugName: "actionLabel" }] : /* istanbul ignore next */ []));
2143
+ useVariant = input(false, ...(ngDevMode ? [{ debugName: "useVariant" }] : /* istanbul ignore next */ []));
2144
+ action = new EventEmitter();
2145
+ showing = new EventEmitter();
2146
+ snackbarRef;
2147
+ get _snackbar() {
2148
+ return this.snackbarRef?.nativeElement;
2149
+ }
2150
+ constructor() {
2151
+ super();
2152
+ effect(() => {
2153
+ this.snackbarClass = css({
2154
+ ...this.theme.getContainerColors(this.variant() || 'primary', this.useVariant()),
2155
+ ...this.theme.radius('sm'),
2156
+ ...this.theme.border(this.variant() || 'primary'),
2157
+ ...this.theme.boxShadow('dialog'),
2158
+ padding: 0,
2159
+ transition: `all ${this.componentOptions().transitionDelay} ease-in-out`,
2160
+ transitionBehavior: 'allow-discrete',
2161
+ opacity: 1,
2162
+ bottom: this.componentOptions().bottomPosition,
2163
+ zIndex: Z_INDEX.dialog,
2164
+ position: 'fixed',
2165
+ '&[open]': {
2166
+ '@starting-style': {
2167
+ bottom: 0,
2168
+ opacity: 0,
2169
+ },
2170
+ },
2171
+ '&[closing]': {
2172
+ animation: `${this.fadeOut} 0.3s forwards`,
2173
+ },
2174
+ });
2175
+ });
2176
+ }
2177
+ fadeOut = keyframes({
2178
+ '0% ': {
2179
+ opacity: 1,
2180
+ },
2181
+ '100%': {
2182
+ opacity: 0,
2183
+ },
2184
+ });
2185
+ ngOnChanges(changes) {
2186
+ if (changes['show'] && changes['show'].currentValue) {
2187
+ this.open();
2188
+ }
2189
+ else {
2190
+ this.close();
2191
+ }
2192
+ }
2193
+ ngAfterViewInit() {
2194
+ this._snackbar?.addEventListener('animationend', (e) => {
2195
+ if (e.animationName == this.fadeOut) {
2196
+ this._snackbar?.close();
2197
+ this.showing.emit(false);
2198
+ }
2199
+ });
2200
+ }
2201
+ get _timeout() {
2202
+ const timeout = this.timeout();
2203
+ if (timeout === 'disabled')
2204
+ return undefined;
2205
+ return typeof timeout === 'string'
2206
+ ? parseFloat(timeout)
2207
+ : timeout || this.componentOptions().autoCloseDelay;
2208
+ }
2209
+ open() {
2210
+ this._snackbar?.removeAttribute('closing');
2211
+ this._snackbar?.show();
2212
+ this.show = true;
2213
+ this.showing.emit(true);
2214
+ if (this._timeout)
2215
+ this.timer.start(this._timeout, () => this.close());
2216
+ }
2217
+ close() {
2218
+ this._snackbar?.setAttribute('closing', 'true');
2219
+ this.show = false;
2220
+ }
2221
+ pauseTimer() {
2222
+ this.timer.pause();
2223
+ }
2224
+ resumeTimer() {
2225
+ this.timer.resume();
2226
+ }
2227
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: UniSnackbarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
2228
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.2.12", type: UniSnackbarComponent, isStandalone: true, selector: "uni-snackbar, Snackbar", inputs: { show: { classPropertyName: "show", publicName: "show", isSignal: false, isRequired: false, transformFunction: null }, iconName: { classPropertyName: "iconName", publicName: "iconName", isSignal: true, isRequired: false, transformFunction: null }, symbolName: { classPropertyName: "symbolName", publicName: "symbolName", isSignal: true, isRequired: false, transformFunction: null }, timeout: { classPropertyName: "timeout", publicName: "timeout", isSignal: true, isRequired: false, transformFunction: null }, actionLabel: { classPropertyName: "actionLabel", publicName: "actionLabel", isSignal: true, isRequired: false, transformFunction: null }, useVariant: { classPropertyName: "useVariant", publicName: "useVariant", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { action: "action", showing: "showing" }, providers: [{ provide: COMPONENT_NAME, useValue: 'snackbar' }], viewQueries: [{ propertyName: "snackbarRef", first: true, predicate: ["snackbar"], descendants: true }], usesInheritance: true, usesOnChanges: true, ngImport: i0, template: "@let icon = iconName();\n@let symbol = symbolName();\n<dialog\n #snackbar\n [class]=\"snackbarClass\"\n (mouseenter)=\"pauseTimer()\"\n (mouseleave)=\"resumeTimer()\"\n (focusin)=\"pauseTimer()\"\n (focusout)=\"resumeTimer()\"\n>\n <Row alignItems=\"center\">\n @if (icon || symbol) {\n <Box [height]=\"26\" [width]=\"26\" paddingLeft=\"sm\">\n @if (icon) {\n <Icon [name]=\"icon\"></Icon>\n } @else if (symbol) {\n <Symbol [name]=\"symbol\" [opticalSize]=\"26\"></Symbol>\n }\n </Box>\n }\n <Box padding=\"sm\">\n <Text>\n <ng-content></ng-content>\n </Text>\n </Box>\n <Box paddingRight=\"sm\">\n @if (!actionLabel()) {\n <button icon-button (click)=\"close()\" iconName=\"close\" size=\"md\">Close</button>\n } @else {\n <button text-button variant=\"ghost\" (click)=\"this.action.emit(); close()\">\n {{ actionLabel() }}\n </button>\n }\n </Box>\n </Row>\n</dialog>\n", dependencies: [{ kind: "component", type: UniRowComponent, selector: "div[uni-row-layout], Row, div[row-layout]", inputs: ["display", "flexDirection", "minWidth"] }, { kind: "component", type: UniBoxComponent, selector: "div[uni-box-layout], Box, div[box-layout]", inputs: ["color", "backgroundColor", "borderRadius", "borderRadiusLeft", "borderRadiusRight", "borderRadiusTop", "borderRadiusBottom", "padding", "paddingHorizontal", "paddingVertical", "paddingLeft", "paddingRight", "paddingTop", "paddingBottom", "border", "borderTop", "borderBottom", "borderLeft", "borderRight", "dashBorder", "alignSelf", "alignItems", "alignContent", "justifyContent", "grow", "display", "position", "inset", "height", "minHeight", "maxHeight", "width", "minWidth", "maxWidth", "ignoreDir", "gridArea", "gridColumn", "gridRow", "overflow", "elevation", "shadow", "gap", "fullWidth", "fullHeight", "flexDirection", "textAlign", "wrapItems", "zIndex"] }, { kind: "component", type: UniTextComponent, selector: "uni-text, Text", inputs: ["typeface", "color", "display", "align", "nowrap", "maxWidth", "ellipsis"] }, { kind: "component", type: UniIconButtonComponent, selector: "button[uni-icon-button], button[icon-button]", inputs: ["iconName", "symbolName", "variant", "size", "disable", "loading", "opticalSize"] }, { kind: "component", type: UniSymbolComponent, selector: "uni-symbol, Symbol", inputs: ["name", "fill", "weight", "grade", "opticalSize"] }, { kind: "component", type: UniIconComponent, selector: "uni-icon, Icon", inputs: ["color", "name"] }, { kind: "component", type: UniButtonComponent, selector: "button[uni-text-button], Button, button[text-button]", inputs: ["disable", "loading", "fullWidth", "symbolLeft", "symbolRight"] }] });
2229
+ }
2230
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: UniSnackbarComponent, decorators: [{
2231
+ type: Component,
2232
+ args: [{ selector: 'uni-snackbar, Snackbar', standalone: true, imports: [
2233
+ UniRowComponent,
2234
+ UniBoxComponent,
2235
+ UniTextComponent,
2236
+ UniIconButtonComponent,
2237
+ UniSymbolComponent,
2238
+ UniIconComponent,
2239
+ UniButtonComponent,
2240
+ ], providers: [{ provide: COMPONENT_NAME, useValue: 'snackbar' }], template: "@let icon = iconName();\n@let symbol = symbolName();\n<dialog\n #snackbar\n [class]=\"snackbarClass\"\n (mouseenter)=\"pauseTimer()\"\n (mouseleave)=\"resumeTimer()\"\n (focusin)=\"pauseTimer()\"\n (focusout)=\"resumeTimer()\"\n>\n <Row alignItems=\"center\">\n @if (icon || symbol) {\n <Box [height]=\"26\" [width]=\"26\" paddingLeft=\"sm\">\n @if (icon) {\n <Icon [name]=\"icon\"></Icon>\n } @else if (symbol) {\n <Symbol [name]=\"symbol\" [opticalSize]=\"26\"></Symbol>\n }\n </Box>\n }\n <Box padding=\"sm\">\n <Text>\n <ng-content></ng-content>\n </Text>\n </Box>\n <Box paddingRight=\"sm\">\n @if (!actionLabel()) {\n <button icon-button (click)=\"close()\" iconName=\"close\" size=\"md\">Close</button>\n } @else {\n <button text-button variant=\"ghost\" (click)=\"this.action.emit(); close()\">\n {{ actionLabel() }}\n </button>\n }\n </Box>\n </Row>\n</dialog>\n" }]
2241
+ }], ctorParameters: () => [], propDecorators: { show: [{
2242
+ type: Input
2243
+ }], iconName: [{ type: i0.Input, args: [{ isSignal: true, alias: "iconName", required: false }] }], symbolName: [{ type: i0.Input, args: [{ isSignal: true, alias: "symbolName", required: false }] }], timeout: [{ type: i0.Input, args: [{ isSignal: true, alias: "timeout", required: false }] }], actionLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "actionLabel", required: false }] }], useVariant: [{ type: i0.Input, args: [{ isSignal: true, alias: "useVariant", required: false }] }], action: [{
2244
+ type: Output
2245
+ }], showing: [{
2246
+ type: Output
2247
+ }], snackbarRef: [{
2248
+ type: ViewChild,
2249
+ args: ['snackbar']
2250
+ }] } });
2251
+
2252
+ class NotificationsComponent {
2253
+ notifications = inject(NotificationService);
2254
+ alertState = signal(undefined, ...(ngDevMode ? [{ debugName: "alertState" }] : /* istanbul ignore next */ []));
2255
+ snackbarState = signal(undefined, ...(ngDevMode ? [{ debugName: "snackbarState" }] : /* istanbul ignore next */ []));
2256
+ confirmationState = signal(undefined, ...(ngDevMode ? [{ debugName: "confirmationState" }] : /* istanbul ignore next */ []));
2257
+ // Computed values for the show states
2258
+ showAlert = computed(() => !!this.alertState(), ...(ngDevMode ? [{ debugName: "showAlert" }] : /* istanbul ignore next */ []));
2259
+ showSnackbar = computed(() => !!this.snackbarState(), ...(ngDevMode ? [{ debugName: "showSnackbar" }] : /* istanbul ignore next */ []));
2260
+ showConfirmation = computed(() => !!this.confirmationState(), ...(ngDevMode ? [{ debugName: "showConfirmation" }] : /* istanbul ignore next */ []));
2261
+ // Expose the alert state
2262
+ alert = computed(() => this.alertState(), ...(ngDevMode ? [{ debugName: "alert" }] : /* istanbul ignore next */ []));
2263
+ snackbar = computed(() => this.snackbarState(), ...(ngDevMode ? [{ debugName: "snackbar" }] : /* istanbul ignore next */ []));
2264
+ confirmation = computed(() => this.confirmationState(), ...(ngDevMode ? [{ debugName: "confirmation" }] : /* istanbul ignore next */ []));
2265
+ constructor() {
2266
+ effect(() => {
2267
+ this.alertState.set(this.notifications.alert());
2268
+ });
2269
+ effect(() => {
2270
+ this.snackbarState.set(this.notifications.snackbar());
2271
+ });
2272
+ effect(() => {
2273
+ this.confirmationState.set(this.notifications.confirmation());
2274
+ });
2275
+ }
2276
+ handleConfirmationShowingEvent(showing) {
2277
+ if (!showing)
2278
+ this.notifications.hideConfirmation();
2279
+ }
2280
+ handleSnackbarShowingEvent(showing) {
2281
+ if (!showing)
2282
+ this.notifications.hideSnackbar();
2283
+ }
2284
+ handleAlertShowingEvent(showing) {
2285
+ if (!showing)
2286
+ this.notifications.hideAlert();
2287
+ }
2288
+ static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: NotificationsComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
2289
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.12", type: NotificationsComponent, isStandalone: true, selector: "uni-notifications, Notifications", ngImport: i0, template: "<Alert\n [show]=\"showAlert()\"\n (showing)=\"handleAlertShowingEvent($event)\"\n [variant]=\"alert()?.variant || 'primary'\"\n [iconName]=\"alert()?.iconName\"\n [symbolName]=\"alert()?.symbolName\"\n >{{ alert()?.message }}</Alert\n>\n\n<Snackbar\n [show]=\"showSnackbar()\"\n (showing)=\"handleSnackbarShowingEvent($event)\"\n [variant]=\"snackbar()?.variant || 'primary'\"\n [actionLabel]=\"snackbar()?.actionLabel\"\n (action)=\"snackbar()?.action?.()\"\n [timeout]=\"snackbar()?.timeout\"\n [iconName]=\"snackbar()?.iconName\"\n [symbolName]=\"snackbar()?.symbolName\"\n >{{ snackbar()?.message }}</Snackbar\n>\n\n<Confirmation\n [show]=\"showConfirmation()\"\n (showing)=\"handleConfirmationShowingEvent($event)\"\n [confirmation]=\"confirmation()\"\n></Confirmation>\n", dependencies: [{ kind: "component", type: UniAlertComponent, selector: "uni-alert, Alert", inputs: ["show", "iconName", "symbolName", "useVariant"], outputs: ["showChange", "showing"] }, { kind: "component", type: UniSnackbarComponent, selector: "uni-snackbar, Snackbar", inputs: ["show", "iconName", "symbolName", "timeout", "actionLabel", "useVariant"], outputs: ["action", "showing"] }, { kind: "component", type: ConfirmationDialogComponent, selector: "uni-confirmation-dialog, Confirmation", inputs: ["show", "confirmation"], outputs: ["showing"] }] });
2290
+ }
2291
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImport: i0, type: NotificationsComponent, decorators: [{
2292
+ type: Component,
2293
+ args: [{ selector: 'uni-notifications, Notifications', standalone: true, imports: [UniAlertComponent, UniSnackbarComponent, ConfirmationDialogComponent], template: "<Alert\n [show]=\"showAlert()\"\n (showing)=\"handleAlertShowingEvent($event)\"\n [variant]=\"alert()?.variant || 'primary'\"\n [iconName]=\"alert()?.iconName\"\n [symbolName]=\"alert()?.symbolName\"\n >{{ alert()?.message }}</Alert\n>\n\n<Snackbar\n [show]=\"showSnackbar()\"\n (showing)=\"handleSnackbarShowingEvent($event)\"\n [variant]=\"snackbar()?.variant || 'primary'\"\n [actionLabel]=\"snackbar()?.actionLabel\"\n (action)=\"snackbar()?.action?.()\"\n [timeout]=\"snackbar()?.timeout\"\n [iconName]=\"snackbar()?.iconName\"\n [symbolName]=\"snackbar()?.symbolName\"\n >{{ snackbar()?.message }}</Snackbar\n>\n\n<Confirmation\n [show]=\"showConfirmation()\"\n (showing)=\"handleConfirmationShowingEvent($event)\"\n [confirmation]=\"confirmation()\"\n></Confirmation>\n" }]
2294
+ }], ctorParameters: () => [] });
2295
+
2032
2296
  class UniTooltipComponent extends BaseComponent {
2033
2297
  elRef = inject(ElementRef);
2034
2298
  renderer = inject(Renderer2);
@@ -2209,5 +2473,5 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.12", ngImpo
2209
2473
  * Generated bundle index. Do not edit.
2210
2474
  */
2211
2475
 
2212
- export { LocalStorageService, NotificationService, RippleDirective, ThemeService, UNI_THEMES, UniBadgeComponent, UniBaseDatasource, UniBoxComponent, UniButtonComponent, UniCardComponent, UniCardContentComponent, UniCardHeaderComponent, UniCenterComponent, UniDialogButtonsComponent, UniDialogComponent, UniDialogHeaderComponent, UniDividerComponent, UniDropdownComponent, UniGridAreaComponent, UniGridComponent, UniIconComponent, UniMenuComponent, UniRecordDatasource, UniRowComponent, UniServerSideDatasource, UniStackComponent, UniSymbolComponent, UniTextComponent, UniTooltipComponent, UniWrapComponent, useTimer };
2476
+ export { ConfirmationDialogComponent, LocalStorageService, NotificationService, NotificationsComponent, RippleDirective, ThemeService, UNI_THEMES, UniAlertComponent, UniBadgeComponent, UniBaseDatasource, UniBoxComponent, UniButtonComponent, UniCardComponent, UniCardContentComponent, UniCardHeaderComponent, UniCenterComponent, UniDialogButtonsComponent, UniDialogComponent, UniDialogHeaderComponent, UniDividerComponent, UniDropdownComponent, UniGridAreaComponent, UniGridComponent, UniIconButtonComponent, UniIconComponent, UniMenuComponent, UniRecordDatasource, UniRowComponent, UniServerSideDatasource, UniSnackbarComponent, UniStackComponent, UniSymbolComponent, UniTextComponent, UniTooltipComponent, UniWrapComponent, useTimer };
2213
2477
  //# sourceMappingURL=uni-design-system-uni-angular.mjs.map