@i-cell/ids-angular 0.1.8 → 0.1.9

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.
@@ -0,0 +1,13 @@
1
+ import { IdsBadgeAppearanceType } from './types/badge-appearance.type';
2
+ import { IdsBadgeVariantType } from './types/badge-variant.type';
3
+ import { InjectionToken } from '@angular/core';
4
+ import { IdsSizeType } from '@i-cell/ids-angular/core';
5
+ export interface IdsBadgeDefaultConfig {
6
+ appearance?: IdsBadgeAppearanceType;
7
+ size?: IdsSizeType;
8
+ variant?: IdsBadgeVariantType;
9
+ showLeadingElement?: boolean;
10
+ label?: string;
11
+ }
12
+ export declare const IDS_BADGE_DEFAULT_CONFIG: InjectionToken<IdsBadgeDefaultConfig>;
13
+ export declare function IDS_BADGE_DEFAULT_CONFIG_FACTORY(): Required<IdsBadgeDefaultConfig>;
@@ -0,0 +1,7 @@
1
+ import { PipeTransform } from '@angular/core';
2
+ import * as i0 from "@angular/core";
3
+ export declare class BadgeLimitPipe implements PipeTransform {
4
+ transform(value: string, max: number | string | null): string;
5
+ static ɵfac: i0.ɵɵFactoryDeclaration<BadgeLimitPipe, never>;
6
+ static ɵpipe: i0.ɵɵPipeDeclaration<BadgeLimitPipe, "badgeLimit", true>;
7
+ }
@@ -0,0 +1,17 @@
1
+ import { IdsBadgeVariantType } from './types/badge-variant.type';
2
+ import { ComponentBase, IdsSizeType } from '@i-cell/ids-angular/core';
3
+ import { IdsIconComponent } from '@i-cell/ids-angular/icon';
4
+ import * as i0 from "@angular/core";
5
+ export declare class IdsBadgeComponent extends ComponentBase {
6
+ protected get _hostName(): string;
7
+ appearance: import("@angular/core").InputSignal<"filled" | undefined>;
8
+ variant: import("@angular/core").InputSignal<IdsBadgeVariantType | undefined>;
9
+ label: import("@angular/core").InputSignal<string>;
10
+ size: import("@angular/core").InputSignal<IdsSizeType | undefined>;
11
+ limit: import("@angular/core").InputSignal<number | null>;
12
+ showLeadingElement: import("@angular/core").InputSignal<boolean>;
13
+ protected _iconLeading: import("@angular/core").Signal<readonly IdsIconComponent[]>;
14
+ protected _hostClasses: import("@angular/core").Signal<string>;
15
+ static ɵfac: i0.ɵɵFactoryDeclaration<IdsBadgeComponent, never>;
16
+ static ɵcmp: i0.ɵɵComponentDeclaration<IdsBadgeComponent, "ids-badge", never, { "appearance": { "alias": "appearance"; "required": false; "isSignal": true; }; "variant": { "alias": "variant"; "required": false; "isSignal": true; }; "label": { "alias": "label"; "required": false; "isSignal": true; }; "size": { "alias": "size"; "required": false; "isSignal": true; }; "limit": { "alias": "limit"; "required": false; "isSignal": true; }; "showLeadingElement": { "alias": "showLeadingElement"; "required": false; "isSignal": true; }; }, {}, ["_iconLeading"], ["ids-icon[icon-leading]"], true, never>;
17
+ }
@@ -0,0 +1,25 @@
1
+ import { IdsBadgeDefaultConfig } from './badge-defaults';
2
+ import { IdsBadgeVariantType } from './types/badge-variant.type';
3
+ import { OnDestroy, OnInit } from '@angular/core';
4
+ import { DirectiveBaseWithDefaults, IdsSizeType } from '@i-cell/ids-angular/core';
5
+ import * as i0 from "@angular/core";
6
+ export declare class IdsBadgeDirective extends DirectiveBaseWithDefaults<IdsBadgeDefaultConfig> implements OnInit, OnDestroy {
7
+ private _badgeRef;
8
+ private _iconEffectRef?;
9
+ private readonly _elementRef;
10
+ private readonly _viewContainerRef;
11
+ private readonly _injector;
12
+ protected readonly _defaultConfig: Required<IdsBadgeDefaultConfig>;
13
+ appearance: import("@angular/core").InputSignal<"filled">;
14
+ label: import("@angular/core").InputSignal<string>;
15
+ size: import("@angular/core").InputSignal<IdsSizeType>;
16
+ variant: import("@angular/core").InputSignal<IdsBadgeVariantType>;
17
+ limit: import("@angular/core").InputSignal<number | null>;
18
+ showLeadingElement: import("@angular/core").InputSignal<boolean>;
19
+ ngOnInit(): void;
20
+ private _moveIconIfNeeded;
21
+ ngOnDestroy(): void;
22
+ protected _hostClasses: import("@angular/core").Signal<string>;
23
+ static ɵfac: i0.ɵɵFactoryDeclaration<IdsBadgeDirective, never>;
24
+ static ɵdir: i0.ɵɵDirectiveDeclaration<IdsBadgeDirective, "[idsBadge]", never, { "appearance": { "alias": "badgeAppearance"; "required": false; "isSignal": true; }; "label": { "alias": "badgeLabel"; "required": false; "isSignal": true; }; "size": { "alias": "badgeSize"; "required": false; "isSignal": true; }; "variant": { "alias": "badgeVariant"; "required": false; "isSignal": true; }; "limit": { "alias": "badgeLimit"; "required": false; "isSignal": true; }; "showLeadingElement": { "alias": "badgeShowLeadingElement"; "required": false; "isSignal": true; }; }, {}, never, never, true, never>;
25
+ }
@@ -0,0 +1,5 @@
1
+ /**
2
+ * Generated bundle index. Do not edit.
3
+ */
4
+ /// <amd-module name="@i-cell/ids-angular/badge" />
5
+ export * from './public-api';
@@ -0,0 +1,5 @@
1
+ export * from './badge.directive';
2
+ export * from './types/badge-variant.type';
3
+ export * from './types/badge-appearance.type';
4
+ export * from './badge-defaults';
5
+ export * from './badge-limit.pipe';
@@ -0,0 +1,4 @@
1
+ export declare const IdsBadgeAppearance: {
2
+ readonly FILLED: "filled";
3
+ };
4
+ export type IdsBadgeAppearanceType = (typeof IdsBadgeAppearance)[keyof typeof IdsBadgeAppearance];
@@ -0,0 +1,12 @@
1
+ export declare const IdsBadgeVariant: {
2
+ readonly PRIMARY: "primary";
3
+ readonly SECONDARY: "secondary";
4
+ readonly SURFACE: "surface";
5
+ readonly BRAND: "brand";
6
+ readonly ERROR: "error";
7
+ readonly WARNING: "warning";
8
+ readonly SUCCESS: "success";
9
+ readonly LIGHT: "light";
10
+ readonly DARK: "dark";
11
+ };
12
+ export type IdsBadgeVariantType = (typeof IdsBadgeVariant)[keyof typeof IdsBadgeVariant];
@@ -0,0 +1,172 @@
1
+ import * as i0 from '@angular/core';
2
+ import { InjectionToken, Pipe, input, contentChildren, computed, Component, inject, ElementRef, ViewContainerRef, Injector, runInInjectionContext, effect, Directive } from '@angular/core';
3
+ import { IdsSize, ComponentBase, DirectiveBaseWithDefaults } from '@i-cell/ids-angular/core';
4
+ import { NgClass } from '@angular/common';
5
+
6
+ const IdsBadgeAppearance = {
7
+ FILLED: 'filled',
8
+ };
9
+
10
+ const IdsBadgeVariant = {
11
+ PRIMARY: 'primary',
12
+ SECONDARY: 'secondary',
13
+ SURFACE: 'surface',
14
+ BRAND: 'brand',
15
+ ERROR: 'error',
16
+ WARNING: 'warning',
17
+ SUCCESS: 'success',
18
+ LIGHT: 'light',
19
+ DARK: 'dark',
20
+ };
21
+
22
+ const IDS_BADGE_DEFAULT_CONFIG = new InjectionToken('IDS_BADGE_DEFAULT_CONFIG', {
23
+ providedIn: 'root',
24
+ factory: IDS_BADGE_DEFAULT_CONFIG_FACTORY,
25
+ });
26
+ function IDS_BADGE_DEFAULT_CONFIG_FACTORY() {
27
+ return {
28
+ appearance: IdsBadgeAppearance.FILLED,
29
+ size: IdsSize.COMPACT,
30
+ variant: IdsBadgeVariant.SURFACE,
31
+ showLeadingElement: false,
32
+ label: '',
33
+ };
34
+ }
35
+
36
+ class BadgeLimitPipe {
37
+ transform(value, max) {
38
+ if (value === null || value === undefined || value === '') {
39
+ return '';
40
+ }
41
+ if (max === null || max === undefined || max === '') {
42
+ return String(value);
43
+ }
44
+ const num = Number(value);
45
+ const maxNum = Number(max);
46
+ if (!isNaN(num) && !isNaN(maxNum)) {
47
+ return num > maxNum ? `${maxNum}+` : `${num}`;
48
+ }
49
+ return String(value);
50
+ }
51
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.2", ngImport: i0, type: BadgeLimitPipe, deps: [], target: i0.ɵɵFactoryTarget.Pipe }); }
52
+ static { this.ɵpipe = i0.ɵɵngDeclarePipe({ minVersion: "14.0.0", version: "19.1.2", ngImport: i0, type: BadgeLimitPipe, isStandalone: true, name: "badgeLimit", pure: false }); }
53
+ }
54
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.2", ngImport: i0, type: BadgeLimitPipe, decorators: [{
55
+ type: Pipe,
56
+ args: [{
57
+ name: 'badgeLimit',
58
+ standalone: true,
59
+ pure: false,
60
+ }]
61
+ }] });
62
+
63
+ class IdsBadgeComponent extends ComponentBase {
64
+ constructor() {
65
+ super(...arguments);
66
+ this.appearance = input();
67
+ this.variant = input();
68
+ this.label = input('');
69
+ this.size = input();
70
+ this.limit = input(null);
71
+ this.showLeadingElement = input(false);
72
+ this._iconLeading = contentChildren('ids-icon[icon-leading]');
73
+ this._hostClasses = computed(() => this._getHostClasses([
74
+ this.size(),
75
+ this.variant(),
76
+ ]));
77
+ }
78
+ get _hostName() {
79
+ return 'badge';
80
+ }
81
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.2", ngImport: i0, type: IdsBadgeComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
82
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.2", type: IdsBadgeComponent, isStandalone: true, selector: "ids-badge", inputs: { appearance: { classPropertyName: "appearance", publicName: "appearance", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "label", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, limit: { classPropertyName: "limit", publicName: "limit", isSignal: true, isRequired: false, transformFunction: null }, showLeadingElement: { classPropertyName: "showLeadingElement", publicName: "showLeadingElement", isSignal: true, isRequired: false, transformFunction: null } }, queries: [{ propertyName: "_iconLeading", predicate: ["ids-icon[icon-leading]"], isSignal: true }], usesInheritance: true, ngImport: i0, template: "<div [ngClass]=\"!showLeadingElement() && !label() ? 'ids-badge__container-no-element' : 'ids-badge__container'\">\n @if (_iconLeading()) {\n <ng-content select=\"ids-icon[icon-leading]\"/>\n }\n <span class=\"ids-badge__label\" aria-live=\"polite\">{{ label() | badgeLimit:limit() }}</span>\n</div>\n", dependencies: [{ kind: "pipe", type: BadgeLimitPipe, name: "badgeLimit" }, { kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }] }); }
83
+ }
84
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.2", ngImport: i0, type: IdsBadgeComponent, decorators: [{
85
+ type: Component,
86
+ args: [{ selector: 'ids-badge', standalone: true, imports: [
87
+ BadgeLimitPipe,
88
+ NgClass,
89
+ ], template: "<div [ngClass]=\"!showLeadingElement() && !label() ? 'ids-badge__container-no-element' : 'ids-badge__container'\">\n @if (_iconLeading()) {\n <ng-content select=\"ids-icon[icon-leading]\"/>\n }\n <span class=\"ids-badge__label\" aria-live=\"polite\">{{ label() | badgeLimit:limit() }}</span>\n</div>\n" }]
90
+ }] });
91
+
92
+ const defaultConfig = IDS_BADGE_DEFAULT_CONFIG_FACTORY();
93
+ class IdsBadgeDirective extends DirectiveBaseWithDefaults {
94
+ constructor() {
95
+ super(...arguments);
96
+ this._elementRef = inject((ElementRef));
97
+ this._viewContainerRef = inject(ViewContainerRef);
98
+ this._injector = inject(Injector);
99
+ this._defaultConfig = this._getDefaultConfig(defaultConfig, IDS_BADGE_DEFAULT_CONFIG);
100
+ this.appearance = input(this._defaultConfig.appearance, { alias: 'badgeAppearance' });
101
+ this.label = input('', { alias: 'badgeLabel' });
102
+ this.size = input(this._defaultConfig.size, { alias: 'badgeSize' });
103
+ this.variant = input(this._defaultConfig.variant, { alias: 'badgeVariant' });
104
+ this.limit = input(null, { alias: 'badgeLimit' });
105
+ this.showLeadingElement = input(this._defaultConfig.showLeadingElement, { alias: 'badgeShowLeadingElement' });
106
+ this._hostClasses = computed(() => this._getHostClasses([]));
107
+ }
108
+ ngOnInit() {
109
+ const originalEl = this._elementRef.nativeElement;
110
+ runInInjectionContext(this._injector, () => {
111
+ this._badgeRef = this._viewContainerRef.createComponent(IdsBadgeComponent, {
112
+ injector: this._injector,
113
+ });
114
+ const badgeEl = this._badgeRef.location.nativeElement;
115
+ const parent = originalEl.parentElement;
116
+ if (!parent) {
117
+ return;
118
+ }
119
+ const placeholder = document.createComment('ids-badge-wrapper');
120
+ parent.replaceChild(placeholder, originalEl);
121
+ badgeEl.appendChild(originalEl);
122
+ parent.replaceChild(badgeEl, placeholder);
123
+ effect(() => {
124
+ this._badgeRef.setInput('appearance', this.appearance());
125
+ this._badgeRef.setInput('variant', this.variant());
126
+ this._badgeRef.setInput('label', this.label());
127
+ this._badgeRef.setInput('size', this.size());
128
+ this._badgeRef.setInput('limit', this.limit());
129
+ this._badgeRef.setInput('showLeadingElement', this.showLeadingElement());
130
+ });
131
+ this._iconEffectRef = effect(() => {
132
+ if (this.showLeadingElement()) {
133
+ queueMicrotask(() => this._moveIconIfNeeded());
134
+ }
135
+ });
136
+ this._moveIconIfNeeded();
137
+ });
138
+ }
139
+ _moveIconIfNeeded() {
140
+ const host = this._elementRef.nativeElement;
141
+ const icon = host.querySelector('ids-icon[icon-leading]');
142
+ const badgeEl = this._badgeRef?.location.nativeElement;
143
+ if (!icon || !badgeEl) {
144
+ return;
145
+ }
146
+ const container = badgeEl.querySelector('.ids-badge__container') ||
147
+ badgeEl.querySelector('.ids-badge__container-no-element');
148
+ if (container && !container.contains(icon)) {
149
+ container.prepend(icon);
150
+ }
151
+ }
152
+ ngOnDestroy() {
153
+ this._iconEffectRef?.destroy();
154
+ this._badgeRef?.destroy();
155
+ }
156
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.2", ngImport: i0, type: IdsBadgeDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive }); }
157
+ static { this.ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.1.2", type: IdsBadgeDirective, isStandalone: true, selector: "[idsBadge]", inputs: { appearance: { classPropertyName: "appearance", publicName: "badgeAppearance", isSignal: true, isRequired: false, transformFunction: null }, label: { classPropertyName: "label", publicName: "badgeLabel", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "badgeSize", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "badgeVariant", isSignal: true, isRequired: false, transformFunction: null }, limit: { classPropertyName: "limit", publicName: "badgeLimit", isSignal: true, isRequired: false, transformFunction: null }, showLeadingElement: { classPropertyName: "showLeadingElement", publicName: "badgeShowLeadingElement", isSignal: true, isRequired: false, transformFunction: null } }, usesInheritance: true, ngImport: i0 }); }
158
+ }
159
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.2", ngImport: i0, type: IdsBadgeDirective, decorators: [{
160
+ type: Directive,
161
+ args: [{
162
+ selector: '[idsBadge]',
163
+ standalone: true,
164
+ }]
165
+ }] });
166
+
167
+ /**
168
+ * Generated bundle index. Do not edit.
169
+ */
170
+
171
+ export { BadgeLimitPipe, IDS_BADGE_DEFAULT_CONFIG, IDS_BADGE_DEFAULT_CONFIG_FACTORY, IdsBadgeAppearance, IdsBadgeDirective, IdsBadgeVariant };
172
+ //# sourceMappingURL=i-cell-ids-angular-badge.mjs.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"i-cell-ids-angular-badge.mjs","sources":["../../../projects/widgets/badge/types/badge-appearance.type.ts","../../../projects/widgets/badge/types/badge-variant.type.ts","../../../projects/widgets/badge/badge-defaults.ts","../../../projects/widgets/badge/badge-limit.pipe.ts","../../../projects/widgets/badge/badge.component.ts","../../../projects/widgets/badge/badge.component.html","../../../projects/widgets/badge/badge.directive.ts","../../../projects/widgets/badge/i-cell-ids-angular-badge.ts"],"sourcesContent":["export const IdsBadgeAppearance = {\n FILLED: 'filled',\n} as const;\n\nexport type IdsBadgeAppearanceType =\n (typeof IdsBadgeAppearance)[keyof typeof IdsBadgeAppearance];\n","export const IdsBadgeVariant = {\n PRIMARY: 'primary',\n SECONDARY: 'secondary',\n SURFACE: 'surface',\n BRAND: 'brand',\n ERROR: 'error',\n WARNING: 'warning',\n SUCCESS: 'success',\n LIGHT: 'light',\n DARK: 'dark',\n} as const;\n\nexport type IdsBadgeVariantType =\n (typeof IdsBadgeVariant)[keyof typeof IdsBadgeVariant];\n","import { IdsBadgeAppearanceType, IdsBadgeAppearance } from './types/badge-appearance.type';\nimport { IdsBadgeVariantType, IdsBadgeVariant } from './types/badge-variant.type';\n\nimport { InjectionToken } from '@angular/core';\nimport { IdsSizeType, IdsSize } from '@i-cell/ids-angular/core';\n\nexport interface IdsBadgeDefaultConfig {\n appearance?: IdsBadgeAppearanceType;\n size?: IdsSizeType;\n variant?: IdsBadgeVariantType;\n showLeadingElement?: boolean;\n label?: string;\n}\n\nexport const IDS_BADGE_DEFAULT_CONFIG = new InjectionToken<IdsBadgeDefaultConfig>(\n 'IDS_BADGE_DEFAULT_CONFIG',\n {\n providedIn: 'root',\n factory: IDS_BADGE_DEFAULT_CONFIG_FACTORY,\n },\n);\n\nexport function IDS_BADGE_DEFAULT_CONFIG_FACTORY(): Required<IdsBadgeDefaultConfig> {\n return {\n appearance: IdsBadgeAppearance.FILLED,\n size: IdsSize.COMPACT,\n variant: IdsBadgeVariant.SURFACE,\n showLeadingElement: false,\n label: '',\n };\n}\n","import { Pipe, PipeTransform } from '@angular/core';\n\n@Pipe({\n name: 'badgeLimit',\n standalone: true,\n pure: false,\n})\nexport class BadgeLimitPipe implements PipeTransform {\n public transform(value: string, max: number | string | null): string {\n if (value === null || value === undefined || value === '') {\n return '';\n }\n\n if (max === null || max === undefined || max === '') {\n return String(value);\n }\n\n const num = Number(value);\n const maxNum = Number(max);\n\n if (!isNaN(num) && !isNaN(maxNum)) {\n return num > maxNum ? `${maxNum}+` : `${num}`;\n }\n\n return String(value);\n }\n}\n","import { BadgeLimitPipe } from './badge-limit.pipe';\nimport { IdsBadgeAppearanceType } from './types/badge-appearance.type';\nimport { IdsBadgeVariantType } from './types/badge-variant.type';\n\nimport { NgClass } from '@angular/common';\nimport {\n Component,\n computed,\n contentChildren,\n input,\n} from '@angular/core';\nimport { ComponentBase, IdsSizeType } from '@i-cell/ids-angular/core';\nimport { IdsIconComponent } from '@i-cell/ids-angular/icon';\n\n@Component({\n selector: 'ids-badge',\n standalone: true,\n templateUrl: './badge.component.html',\n imports: [\n BadgeLimitPipe,\n NgClass,\n ],\n})\nexport class IdsBadgeComponent extends ComponentBase {\n protected override get _hostName(): string {\n return 'badge';\n }\n\n public appearance = input<IdsBadgeAppearanceType>();\n public variant = input<IdsBadgeVariantType>();\n public label = input<string>('');\n public size = input<IdsSizeType>();\n public limit = input<null | number>(null);\n public showLeadingElement = input<boolean>(false);\n\n protected _iconLeading = contentChildren<IdsIconComponent>('ids-icon[icon-leading]');\n\n protected _hostClasses = computed(() => this._getHostClasses([\n this.size(),\n this.variant(),\n ]));\n}\n","<div [ngClass]=\"!showLeadingElement() && !label() ? 'ids-badge__container-no-element' : 'ids-badge__container'\">\n @if (_iconLeading()) {\n <ng-content select=\"ids-icon[icon-leading]\"/>\n }\n <span class=\"ids-badge__label\" aria-live=\"polite\">{{ label() | badgeLimit:limit() }}</span>\n</div>\n","import {\n IDS_BADGE_DEFAULT_CONFIG,\n IDS_BADGE_DEFAULT_CONFIG_FACTORY,\n IdsBadgeDefaultConfig,\n} from './badge-defaults';\nimport { IdsBadgeComponent } from './badge.component';\nimport { IdsBadgeAppearanceType } from './types/badge-appearance.type';\nimport { IdsBadgeVariantType } from './types/badge-variant.type';\n\nimport {\n ComponentRef,\n computed,\n Directive, effect, EffectRef,\n ElementRef, inject,\n Injector,\n input, OnDestroy,\n OnInit, runInInjectionContext,\n ViewContainerRef,\n} from '@angular/core';\nimport { DirectiveBaseWithDefaults, IdsSizeType } from '@i-cell/ids-angular/core';\n\nconst defaultConfig = IDS_BADGE_DEFAULT_CONFIG_FACTORY();\n\n@Directive({\n selector: '[idsBadge]',\n standalone: true,\n})\nexport class IdsBadgeDirective extends DirectiveBaseWithDefaults<IdsBadgeDefaultConfig> implements OnInit, OnDestroy {\n private _badgeRef!: ComponentRef<IdsBadgeComponent>;\n private _iconEffectRef?: EffectRef;\n private readonly _elementRef = inject(ElementRef<HTMLElement>);\n private readonly _viewContainerRef = inject(ViewContainerRef);\n private readonly _injector = inject(Injector);\n\n protected readonly _defaultConfig = this._getDefaultConfig(defaultConfig, IDS_BADGE_DEFAULT_CONFIG);\n\n public appearance = input<IdsBadgeAppearanceType>(this._defaultConfig.appearance, { alias: 'badgeAppearance' });\n public label = input<string>('', { alias: 'badgeLabel' });\n public size = input<IdsSizeType>(this._defaultConfig.size, { alias: 'badgeSize' });\n public variant = input<IdsBadgeVariantType>(this._defaultConfig.variant, { alias: 'badgeVariant' });\n public limit = input<number | null>(null, { alias: 'badgeLimit' });\n public showLeadingElement = input<boolean>(this._defaultConfig.showLeadingElement, { alias: 'badgeShowLeadingElement' });\n\n public ngOnInit(): void {\n const originalEl = this._elementRef.nativeElement;\n\n runInInjectionContext(this._injector, () => {\n this._badgeRef = this._viewContainerRef.createComponent(IdsBadgeComponent, {\n injector: this._injector,\n });\n const badgeEl = this._badgeRef.location.nativeElement;\n\n const parent = originalEl.parentElement;\n if (!parent) {\n return;\n }\n\n const placeholder = document.createComment('ids-badge-wrapper');\n parent.replaceChild(placeholder, originalEl);\n badgeEl.appendChild(originalEl);\n parent.replaceChild(badgeEl, placeholder);\n\n effect(() => {\n this._badgeRef.setInput('appearance', this.appearance());\n this._badgeRef.setInput('variant', this.variant());\n this._badgeRef.setInput('label', this.label());\n this._badgeRef.setInput('size', this.size());\n this._badgeRef.setInput('limit', this.limit());\n this._badgeRef.setInput('showLeadingElement', this.showLeadingElement());\n });\n\n this._iconEffectRef = effect(() => {\n if (this.showLeadingElement()) {\n queueMicrotask(() => this._moveIconIfNeeded());\n }\n });\n\n this._moveIconIfNeeded();\n });\n }\n\n private _moveIconIfNeeded(): void {\n const host = this._elementRef.nativeElement;\n const icon = host.querySelector('ids-icon[icon-leading]');\n const badgeEl = this._badgeRef?.location.nativeElement;\n if (!icon || !badgeEl) {\n return;\n }\n const container =\n badgeEl.querySelector('.ids-badge__container') ||\n badgeEl.querySelector('.ids-badge__container-no-element');\n if (container && !container.contains(icon)) {\n container.prepend(icon);\n }\n }\n\n public ngOnDestroy(): void {\n this._iconEffectRef?.destroy();\n this._badgeRef?.destroy();\n }\n\n protected _hostClasses = computed(() => this._getHostClasses([]));\n}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;AAAa,MAAA,kBAAkB,GAAG;AAChC,IAAA,MAAM,EAAE,QAAQ;;;ACDL,MAAA,eAAe,GAAG;AAC7B,IAAA,OAAO,EAAE,SAAS;AAClB,IAAA,SAAS,EAAE,WAAW;AACtB,IAAA,OAAO,EAAE,SAAS;AAClB,IAAA,KAAK,EAAE,OAAO;AACd,IAAA,KAAK,EAAE,OAAO;AACd,IAAA,OAAO,EAAE,SAAS;AAClB,IAAA,OAAO,EAAE,SAAS;AAClB,IAAA,KAAK,EAAE,OAAO;AACd,IAAA,IAAI,EAAE,MAAM;;;MCKD,wBAAwB,GAAG,IAAI,cAAc,CACxD,0BAA0B,EAC1B;AACE,IAAA,UAAU,EAAE,MAAM;AAClB,IAAA,OAAO,EAAE,gCAAgC;AAC1C,CAAA;SAGa,gCAAgC,GAAA;IAC9C,OAAO;QACL,UAAU,EAAE,kBAAkB,CAAC,MAAM;QACrC,IAAI,EAAE,OAAO,CAAC,OAAO;QACrB,OAAO,EAAE,eAAe,CAAC,OAAO;AAChC,QAAA,kBAAkB,EAAE,KAAK;AACzB,QAAA,KAAK,EAAE,EAAE;KACV;AACH;;MCvBa,cAAc,CAAA;IAClB,SAAS,CAAC,KAAa,EAAE,GAA2B,EAAA;AACzD,QAAA,IAAI,KAAK,KAAK,IAAI,IAAI,KAAK,KAAK,SAAS,IAAI,KAAK,KAAK,EAAE,EAAE;AACzD,YAAA,OAAO,EAAE;;AAGX,QAAA,IAAI,GAAG,KAAK,IAAI,IAAI,GAAG,KAAK,SAAS,IAAI,GAAG,KAAK,EAAE,EAAE;AACnD,YAAA,OAAO,MAAM,CAAC,K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AAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,kBAAA,EAAA,EAAA,iBAAA,EAAA,oBAAA,EAAA,UAAA,EAAA,yBAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,EAAA,eAAA,EAAA,IAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA,CAAA;;2FAAjB,iBAAiB,EAAA,UAAA,EAAA,CAAA;kBAJ7B,SAAS;AAAC,YAAA,IAAA,EAAA,CAAA;AACT,oBAAA,QAAQ,EAAE,YAAY;AACtB,oBAAA,UAAU,EAAE,IAAI;AACjB,iBAAA;;;AC1BD;;AAEG;;;;"}
@@ -609,11 +609,11 @@ class IdsFormFieldComponent extends ComponentBaseWithDefaults {
609
609
  }
610
610
  }
611
611
  static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.1.2", ngImport: i0, type: IdsFormFieldComponent, deps: null, target: i0.ɵɵFactoryTarget.Component }); }
612
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.2", type: IdsFormFieldComponent, isStandalone: true, selector: "ids-form-field", inputs: { size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null } }, queries: [{ propertyName: "_child", first: true, predicate: IDS_FORM_FIELD_CONTROL, descendants: true, isSignal: true }, { propertyName: "_hintMessages", predicate: IdsHintMessageComponent, descendants: true, isSignal: true }, { propertyName: "_successMessages", predicate: IdsSuccessMessageComponent, descendants: true, isSignal: true }, { propertyName: "_errorMessages", predicate: IdsErrorMessageComponent, descendants: true, isSignal: true }, { propertyName: "_actions", predicate: IdsFormFieldActionDirective, isSignal: true }, { propertyName: "_prefixes", predicate: IdsPrefixDirective, isSignal: true }, { propertyName: "_suffixes", predicate: IdsSuffixDirective, isSignal: true }], viewQueries: [{ propertyName: "_fieldWrapper", first: true, predicate: ["fieldWrapper"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<label class=\"ids-form-field__label\" [for]=\"_inputId()\">\n <ng-content select=\"ids-label\" />\n @if (hasRequiredValidator()) {\n <span class=\"ids-form-field__required-marker\"></span>\n }\n</label>\n\n<div #fieldWrapper class=\"ids-form-field__field-wrapper\">\n <div class=\"ids-form-field__field-wrapper__container\" (click)=\"containerClick($event)\">\n @if (_hasLeadingIcon()) {\n <div class=\"ids-form-field__leading-icon\">\n <ng-content select=\"ids-icon[idsLeadingIcon]\" />\n </div>\n }\n @if (_hasPrefix()) {\n <div class=\"ids-form-field__prefix\">\n <ng-content select=\"[idsPrefix]\" />\n </div>\n }\n <div class=\"ids-form-field__infix\">\n <ng-content />\n </div>\n @if (_hasSuffix()) {\n <div class=\"ids-form-field__suffix\">\n <ng-content select=\"[idsSuffix]\" />\n </div>\n }\n @if (_hasTrailingIcon()) {\n <div class=\"ids-form-field__trailing-icon\">\n <ng-content select=\"ids-icon[idsTrailingIcon]\" />\n </div>\n }\n </div>\n @if (_hasActions()) {\n <div class=\"ids-form-field__field-wrapper__action\">\n <ng-content select=\"[idsFormFieldAction]\" />\n </div>\n }\n</div>\n\n<div class=\"ids-form-field__subscript-wrapper\">\n @let messages = _displayedMessages();\n @if (messages) {\n <div class=\"ids-form-field__message-container\">\n @switch (messages) {\n @case (\"error\") {\n <ng-content select=\"ids-error-message\" />\n }\n @case (\"success\") {\n <ng-content select=\"ids-success-message\" />\n }\n @case (\"hint\") {\n <ng-content select=\"ids-hint-message\" />\n }\n }\n </div>\n }\n</div>\n", changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
612
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.1.2", type: IdsFormFieldComponent, isStandalone: true, selector: "ids-form-field", inputs: { size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: true, isRequired: false, transformFunction: null } }, queries: [{ propertyName: "_child", first: true, predicate: IDS_FORM_FIELD_CONTROL, descendants: true, isSignal: true }, { propertyName: "_hintMessages", predicate: IdsHintMessageComponent, descendants: true, isSignal: true }, { propertyName: "_successMessages", predicate: IdsSuccessMessageComponent, descendants: true, isSignal: true }, { propertyName: "_errorMessages", predicate: IdsErrorMessageComponent, descendants: true, isSignal: true }, { propertyName: "_actions", predicate: IdsFormFieldActionDirective, isSignal: true }, { propertyName: "_prefixes", predicate: IdsPrefixDirective, isSignal: true }, { propertyName: "_suffixes", predicate: IdsSuffixDirective, isSignal: true }], viewQueries: [{ propertyName: "_fieldWrapper", first: true, predicate: ["fieldWrapper"], descendants: true, isSignal: true }], usesInheritance: true, ngImport: i0, template: "<label class=\"ids-form-field__label\" [for]=\"_inputId()\">\n @if (hasRequiredValidator()) {\n <span class=\"ids-form-field__required-marker\"></span>\n }\n <ng-content select=\"ids-label\" />\n</label>\n\n<div #fieldWrapper class=\"ids-form-field__field-wrapper\">\n <div class=\"ids-form-field__field-wrapper__container\" (click)=\"containerClick($event)\">\n @if (_hasLeadingIcon()) {\n <div class=\"ids-form-field__leading-icon\">\n <ng-content select=\"ids-icon[idsLeadingIcon]\" />\n </div>\n }\n @if (_hasPrefix()) {\n <div class=\"ids-form-field__prefix\">\n <ng-content select=\"[idsPrefix]\" />\n </div>\n }\n <div class=\"ids-form-field__infix\">\n <ng-content />\n </div>\n @if (_hasSuffix()) {\n <div class=\"ids-form-field__suffix\">\n <ng-content select=\"[idsSuffix]\" />\n </div>\n }\n @if (_hasTrailingIcon()) {\n <div class=\"ids-form-field__trailing-icon\">\n <ng-content select=\"ids-icon[idsTrailingIcon]\" />\n </div>\n }\n </div>\n @if (_hasActions()) {\n <div class=\"ids-form-field__field-wrapper__action\">\n <ng-content select=\"[idsFormFieldAction]\" />\n </div>\n }\n</div>\n\n<div class=\"ids-form-field__subscript-wrapper\">\n @let messages = _displayedMessages();\n @if (messages) {\n <div class=\"ids-form-field__message-container\">\n @switch (messages) {\n @case (\"error\") {\n <ng-content select=\"ids-error-message\" />\n }\n @case (\"success\") {\n <ng-content select=\"ids-success-message\" />\n }\n @case (\"hint\") {\n <ng-content select=\"ids-hint-message\" />\n }\n }\n </div>\n }\n</div>\n", changeDetection: i0.ChangeDetectionStrategy.OnPush, encapsulation: i0.ViewEncapsulation.None }); }
613
613
  }
614
614
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.1.2", ngImport: i0, type: IdsFormFieldComponent, decorators: [{
615
615
  type: Component,
616
- args: [{ selector: 'ids-form-field', imports: [], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<label class=\"ids-form-field__label\" [for]=\"_inputId()\">\n <ng-content select=\"ids-label\" />\n @if (hasRequiredValidator()) {\n <span class=\"ids-form-field__required-marker\"></span>\n }\n</label>\n\n<div #fieldWrapper class=\"ids-form-field__field-wrapper\">\n <div class=\"ids-form-field__field-wrapper__container\" (click)=\"containerClick($event)\">\n @if (_hasLeadingIcon()) {\n <div class=\"ids-form-field__leading-icon\">\n <ng-content select=\"ids-icon[idsLeadingIcon]\" />\n </div>\n }\n @if (_hasPrefix()) {\n <div class=\"ids-form-field__prefix\">\n <ng-content select=\"[idsPrefix]\" />\n </div>\n }\n <div class=\"ids-form-field__infix\">\n <ng-content />\n </div>\n @if (_hasSuffix()) {\n <div class=\"ids-form-field__suffix\">\n <ng-content select=\"[idsSuffix]\" />\n </div>\n }\n @if (_hasTrailingIcon()) {\n <div class=\"ids-form-field__trailing-icon\">\n <ng-content select=\"ids-icon[idsTrailingIcon]\" />\n </div>\n }\n </div>\n @if (_hasActions()) {\n <div class=\"ids-form-field__field-wrapper__action\">\n <ng-content select=\"[idsFormFieldAction]\" />\n </div>\n }\n</div>\n\n<div class=\"ids-form-field__subscript-wrapper\">\n @let messages = _displayedMessages();\n @if (messages) {\n <div class=\"ids-form-field__message-container\">\n @switch (messages) {\n @case (\"error\") {\n <ng-content select=\"ids-error-message\" />\n }\n @case (\"success\") {\n <ng-content select=\"ids-success-message\" />\n }\n @case (\"hint\") {\n <ng-content select=\"ids-hint-message\" />\n }\n }\n </div>\n }\n</div>\n" }]
616
+ args: [{ selector: 'ids-form-field', imports: [], encapsulation: ViewEncapsulation.None, changeDetection: ChangeDetectionStrategy.OnPush, template: "<label class=\"ids-form-field__label\" [for]=\"_inputId()\">\n @if (hasRequiredValidator()) {\n <span class=\"ids-form-field__required-marker\"></span>\n }\n <ng-content select=\"ids-label\" />\n</label>\n\n<div #fieldWrapper class=\"ids-form-field__field-wrapper\">\n <div class=\"ids-form-field__field-wrapper__container\" (click)=\"containerClick($event)\">\n @if (_hasLeadingIcon()) {\n <div class=\"ids-form-field__leading-icon\">\n <ng-content select=\"ids-icon[idsLeadingIcon]\" />\n </div>\n }\n @if (_hasPrefix()) {\n <div class=\"ids-form-field__prefix\">\n <ng-content select=\"[idsPrefix]\" />\n </div>\n }\n <div class=\"ids-form-field__infix\">\n <ng-content />\n </div>\n @if (_hasSuffix()) {\n <div class=\"ids-form-field__suffix\">\n <ng-content select=\"[idsSuffix]\" />\n </div>\n }\n @if (_hasTrailingIcon()) {\n <div class=\"ids-form-field__trailing-icon\">\n <ng-content select=\"ids-icon[idsTrailingIcon]\" />\n </div>\n }\n </div>\n @if (_hasActions()) {\n <div class=\"ids-form-field__field-wrapper__action\">\n <ng-content select=\"[idsFormFieldAction]\" />\n </div>\n }\n</div>\n\n<div class=\"ids-form-field__subscript-wrapper\">\n @let messages = _displayedMessages();\n @if (messages) {\n <div class=\"ids-form-field__message-container\">\n @switch (messages) {\n @case (\"error\") {\n <ng-content select=\"ids-error-message\" />\n }\n @case (\"success\") {\n <ng-content select=\"ids-success-message\" />\n }\n @case (\"hint\") {\n <ng-content select=\"ids-hint-message\" />\n }\n }\n </div>\n }\n</div>\n" }]
617
617
  }] });
618
618
 
619
619
  const IDS_INPUT_DEFAULT_CONFIG = new InjectionToken('IDS_INPUT_DEFAULT_CONFIG', {