@testgorilla/tgo-ui 7.9.1 → 7.11.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.
- package/components/badge/badge.component.d.ts +20 -2
- package/components/button/button.component.d.ts +10 -1
- package/fesm2022/testgorilla-tgo-ui-components-ai-feedback.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-ai-feedback.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-alert-banner.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-alert-banner.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-avatar.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-avatar.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-badge.mjs +26 -4
- package/fesm2022/testgorilla-tgo-ui-components-badge.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-breadcrumb.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-breadcrumb.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-button.mjs +16 -2
- package/fesm2022/testgorilla-tgo-ui-components-button.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-checklist.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-checklist.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-dialog.mjs +2 -2
- package/fesm2022/testgorilla-tgo-ui-components-dialog.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-dropdown.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-dropdown.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-empty-state.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-empty-state.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-field.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-field.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-filter-button.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-filter-button.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-inline-field.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-inline-field.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-media-card.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-media-card.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-media-dialog.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-media-dialog.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-navbar.mjs +2 -2
- package/fesm2022/testgorilla-tgo-ui-components-navbar.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-overflow-menu.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-overflow-menu.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-page-header.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-page-header.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-prompt.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-prompt.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-radial-progress.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-radial-progress.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-scale-table.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-scale-table.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-side-panel.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-side-panel.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-side-sheet.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-side-sheet.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-snackbar.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-snackbar.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-table.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-table.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-tag.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-tag.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-universal-skills.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-universal-skills.mjs.map +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-write-with-ai.mjs +1 -1
- package/fesm2022/testgorilla-tgo-ui-components-write-with-ai.mjs.map +1 -1
- package/mcp/catalog.json +1 -1
- package/package.json +32 -32
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { Input, Optional, Inject, Component, NgModule } from '@angular/core';
|
|
2
|
+
import { input, Input, Optional, Inject, Component, NgModule } from '@angular/core';
|
|
3
3
|
import * as i1 from '@angular/common';
|
|
4
4
|
import { CommonModule } from '@angular/common';
|
|
5
5
|
import * as i2 from '@testgorilla/tgo-ui/components/icon';
|
|
@@ -69,6 +69,22 @@ class BadgeComponent {
|
|
|
69
69
|
* @memberof BadgeComponent
|
|
70
70
|
*/
|
|
71
71
|
this.icon = '';
|
|
72
|
+
/**
|
|
73
|
+
* Override color for the leading icon. Accepts any value the `ui-icon`
|
|
74
|
+
* `color` input accepts (named token, hex, or CSS custom property).
|
|
75
|
+
* When unset, falls back to the auto-derived color based on the badge background.
|
|
76
|
+
*/
|
|
77
|
+
this.iconColor = input(undefined);
|
|
78
|
+
/**
|
|
79
|
+
* Optional trailing icon, rendered after the label/static label on the primary variant.
|
|
80
|
+
*/
|
|
81
|
+
this.trailingIcon = input('');
|
|
82
|
+
/**
|
|
83
|
+
* Override color for the trailing icon. Accepts any value the `ui-icon`
|
|
84
|
+
* `color` input accepts (named token, hex, or CSS custom property).
|
|
85
|
+
* When unset, falls back to the auto-derived color based on the badge background.
|
|
86
|
+
*/
|
|
87
|
+
this.trailingIconColor = input(undefined);
|
|
72
88
|
/**
|
|
73
89
|
* The color of the badge. Defaults to 'petrol'.
|
|
74
90
|
* @type {BadgeColor}
|
|
@@ -129,18 +145,24 @@ class BadgeComponent {
|
|
|
129
145
|
this.applicationTheme = defaultAppTheme;
|
|
130
146
|
}
|
|
131
147
|
}
|
|
132
|
-
get
|
|
148
|
+
get autoIconColor() {
|
|
133
149
|
return this.darkColors.includes(this.isClassicTheme ? this.color : this.rebrandColor) ? 'black' : 'white';
|
|
134
150
|
}
|
|
151
|
+
get resolvedIconColor() {
|
|
152
|
+
return this.iconColor() ?? this.autoIconColor;
|
|
153
|
+
}
|
|
154
|
+
get resolvedTrailingIconColor() {
|
|
155
|
+
return this.trailingIconColor() ?? this.autoIconColor;
|
|
156
|
+
}
|
|
135
157
|
get isClassicTheme() {
|
|
136
158
|
return this.applicationTheme === 'classic';
|
|
137
159
|
}
|
|
138
160
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: BadgeComponent, deps: [{ token: 'CANOPYUI_DEFAULT_APPLICATION_THEME', optional: true }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
139
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "19.2.20", type: BadgeComponent, isStandalone: false, selector: "ui-badge", inputs: { label: "label", staticLabel: "staticLabel", icon: "icon", color: "color", variant: "variant", notificationsAmount: "notificationsAmount", applicationTheme: "applicationTheme", rebrandColor: "rebrandColor", truncateLabel: "truncateLabel", enableAnimation: "enableAnimation" }, ngImport: i0, template: "<div\n [class]=\"'badge badge-container-' + variant\"\n [class.no-label]=\"!label && !staticLabel\"\n [attr.aria-label]=\"label + (staticLabel ? ' ' + staticLabel : '')\"\n [attr.theme]=\"applicationTheme\"\n [attr.color]=\"isClassicTheme ? color : rebrandColor\"\n [matTooltip]=\"\n label.length > 25 - (staticLabel.length < 4 ? staticLabel.length : 4)\n ? label + (staticLabel ? ' ' + staticLabel : '')\n : ''\n \"\n [matTooltipClass]=\"applicationTheme\"\n>\n <ng-container [ngSwitch]=\"variant\">\n <ng-container *ngSwitchCase=\"badgeVariant.PRIMARY\">\n <ui-icon *ngIf=\"icon\" [class.badge-icon]=\"!!label\" [name]=\"icon\" [color]=\"iconColor\"></ui-icon>\n </ng-container>\n <ng-container *ngSwitchCase=\"badgeVariant.PRIMARY_AI\">\n <ng-container [ngTemplateOutlet]=\"aiIconTpl\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"badgeVariant.SECONDARY_AI\">\n <ng-container [ngTemplateOutlet]=\"aiIconTpl\"></ng-container>\n </ng-container>\n <div\n *ngSwitchCase=\"badgeVariant.SECONDARY\"\n class=\"point\"\n [attr.color]=\"isClassicTheme ? color : rebrandColor\"\n ></div>\n <div *ngSwitchCase=\"badgeVariant.NOTIFICATION\" class=\"number-notification\">{{ notificationsAmount }}</div>\n </ng-container>\n <div\n class=\"label\"\n *ngIf=\"variant !== badgeVariant.NOTIFICATION\"\n [class.empty]=\"!label && !staticLabel\"\n [class.animated]=\"enableAnimation\"\n >\n {{\n label.length > 25 - (staticLabel.length < 4 ? staticLabel.length : 4) && truncateLabel\n ? (label | slice: 0 : 25 - (staticLabel.length < 4 ? staticLabel.length : 4)) + '...'\n : label\n }}\n </div>\n <span *ngIf=\"staticLabel && variant !== badgeVariant.NOTIFICATION\" class=\"static-label\">{{\n staticLabel | slice: 0 : 4\n }}</span>\n</div>\n\n<ng-template #aiIconTpl>\n <ui-icon class=\"badge-icon\" [name]=\"'Sparkle-in-line'\" [color]=\"'ai'\"></ui-icon>\n</ng-template>\n", styles: [".bg-teal-60b{background:#1c443c}.bg-teal-30b{background:#31766a}.bg-teal-default{background:#46a997}.bg-teal-30w{background:#7ec3b6}.bg-teal-60w{background:#b5ddd5}.bg-teal-secondary{background:#cbd6cb}.bg-teal-90w{background:#ecf6f5}.bg-petrol-60b{background:#102930}.bg-petrol-30b{background:#1b4754}.bg-petrol-default{background:#276678}.bg-petrol-30w{background:#6894a0}.bg-petrol-60w{background:#a9c2c9}.bg-petrol-secondary{background:#c8d7de}.bg-petrol-90w{background:#e9f0f1}.bg-error-60b{background:#513131}.bg-error-30b{background:#8e5655}.bg-error-60w{background:#e3c3c6}.bg-error-secondary{background:#f0dad9}.bg-error-default{background:#cb7b7a}.bg-warning-secondary{background:#f0d6bb}.bg-warning-default{background:#cca45f}.bg-black{background:#000}.bg-dark{background:#888}.bg-medium{background:#e0e0e0}.bg-grey{background:#ededed}.bg-light{background:#f6f6f6}.bg-white{background:#fff}.bg-box-shadow{background:#00000014}.bg-navigation-subtitle{background:#528593}.bgc-teal-60b{background-color:#1c443c}.bgc-teal-30b{background-color:#31766a}.bgc-teal-default{background-color:#46a997}.bgc-teal-30w{background-color:#7ec3b6}.bgc-teal-60w{background-color:#b5ddd5}.bgc-teal-secondary{background-color:#cbd6cb}.bgc-teal-90w{background-color:#ecf6f5}.bgc-petrol-60b{background-color:#102930}.bgc-petrol-30b{background-color:#1b4754}.bgc-petrol-default{background-color:#276678}.bgc-petrol-30w{background-color:#6894a0}.bgc-petrol-60w{background-color:#a9c2c9}.bgc-petrol-secondary{background-color:#c8d7de}.bgc-petrol-90w{background-color:#e9f0f1}.bgc-error-60b{background-color:#513131}.bgc-error-30b{background-color:#8e5655}.bgc-error-60w{background-color:#e3c3c6}.bgc-error-secondary{background-color:#f0dad9}.bgc-error-default{background-color:#cb7b7a}.bgc-warning-secondary{background-color:#f0d6bb}.bgc-warning-default{background-color:#cca45f}.bgc-black{background-color:#000}.bgc-dark{background-color:#888}.bgc-medium{background-color:#e0e0e0}.bgc-grey{background-color:#ededed}.bgc-light{background-color:#f6f6f6}.bgc-white{background-color:#fff}.bgc-box-shadow{background-color:#00000014}.bgc-navigation-subtitle{background-color:#528593}:host{display:block}:host .badge-container-primary,:host .badge-container-primary-ai,:host .badge-container-secondary,:host .badge-container-secondary-ai,:host .badge-container-notification{width:fit-content}:host .badge-container-primary,:host .badge-container-primary-ai,:host .badge-container-secondary,:host .badge-container-secondary-ai{height:24px;padding:0 8px;border-radius:21px;color:#fff;line-height:10px;transition:all .2s ease-out}:host .badge-container-primary .label,:host .badge-container-primary-ai .label,:host .badge-container-secondary .label,:host .badge-container-secondary-ai .label{font-size:12px;line-height:14px}:host .badge-container-primary .label.animated,:host .badge-container-primary-ai .label.animated,:host .badge-container-secondary .label.animated,:host .badge-container-secondary-ai .label.animated{display:inline-block;max-width:500px;opacity:1;overflow:hidden;white-space:nowrap;transition:max-width .25s ease-in-out,opacity .2s ease-in-out;will-change:max-width,opacity;contain:layout style}:host .badge-container-primary .label.empty,:host .badge-container-primary-ai .label.empty,:host .badge-container-secondary .label.empty,:host .badge-container-secondary-ai .label.empty{max-width:0;opacity:0}:host .badge-container-primary .static-label,:host .badge-container-primary-ai .static-label,:host .badge-container-secondary .static-label,:host .badge-container-secondary-ai .static-label{font-size:12px;line-height:14px;white-space:nowrap;flex-shrink:0;margin-left:2px}:host .badge-container-primary .badge-icon:not(:last-child),:host .badge-container-primary-ai .badge-icon:not(:last-child),:host .badge-container-secondary .badge-icon:not(:last-child),:host .badge-container-secondary-ai .badge-icon:not(:last-child){margin-right:8px}:host .badge-container-primary.no-label .badge-icon,:host .badge-container-primary-ai.no-label .badge-icon,:host .badge-container-secondary.no-label .badge-icon,:host .badge-container-secondary-ai.no-label .badge-icon{margin-right:0}:host .badge-container-secondary{padding:0}:host .badge-container-primary-ai.no-label{padding:4px}:host .badge-container-secondary .point,:host .badge-container-secondary-ai .point{border-radius:50%;padding:4px;margin-right:8px}:host .badge-container-secondary .label,:host .badge-container-secondary-ai .label{color:#000!important;width:100%}:host .badge-container-secondary[theme=dark],:host .badge-container-secondary[theme=light],:host .badge-container-secondary-ai[theme=dark],:host .badge-container-secondary-ai[theme=light]{color:#242424}:host .badge-container-secondary .badge-icon:not(:last-child),:host .badge-container-secondary-ai .badge-icon:not(:last-child){margin-right:4px}:host .badge-container-notification{min-width:20px;height:20px;border-radius:50%;color:#fff;line-height:10px}:host .badge-container-notification .label{font-size:12px}:host .badge-container-notification[theme=dark],:host .badge-container-notification[theme=light]{background:#242424!important;color:#fff!important;border-color:1px solid #ffffff}:host .badge{width:100%!important;max-width:fit-content!important}:host .badge .label{white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;box-sizing:border-box!important}.flex-center,:host .badge-container-primary,:host .badge-container-primary-ai,:host .badge-container-secondary,:host .badge-container-secondary-ai,:host .badge-container-notification{display:flex;align-items:center;justify-content:center}.background-colors[color=red],:host [color=red].badge-container-primary,:host [color=red].badge-container-primary-ai,:host .badge-container-secondary [color=red].point,:host .badge-container-secondary-ai [color=red].point,:host [color=red].badge-container-notification{background:#cb7b7a}.background-colors[color=grey-medium],:host [color=grey-medium].badge-container-primary,:host [color=grey-medium].badge-container-primary-ai,:host .badge-container-secondary [color=grey-medium].point,:host .badge-container-secondary-ai [color=grey-medium].point,:host [color=grey-medium].badge-container-notification{background:#e0e0e0;color:#000}.background-colors[color=teal],:host [color=teal].badge-container-primary,:host [color=teal].badge-container-primary-ai,:host .badge-container-secondary [color=teal].point,:host .badge-container-secondary-ai [color=teal].point,:host [color=teal].badge-container-notification{background:#46a997}.background-colors[color=yellow],:host [color=yellow].badge-container-primary,:host [color=yellow].badge-container-primary-ai,:host .badge-container-secondary [color=yellow].point,:host .badge-container-secondary-ai [color=yellow].point,:host [color=yellow].badge-container-notification{background:#cca45f}.background-colors[color=petrol],:host [color=petrol].badge-container-primary,:host [color=petrol].badge-container-primary-ai,:host .badge-container-secondary [color=petrol].point,:host .badge-container-secondary-ai [color=petrol].point,:host [color=petrol].badge-container-notification{background:#276678}.background-colors[color=teal-60w],:host [color=teal-60w].badge-container-primary,:host [color=teal-60w].badge-container-primary-ai,:host .badge-container-secondary [color=teal-60w].point,:host .badge-container-secondary-ai [color=teal-60w].point,:host [color=teal-60w].badge-container-notification{background:#b5ddd5;color:#000}.background-colors[color=petrol-90w],:host [color=petrol-90w].badge-container-primary,:host [color=petrol-90w].badge-container-primary-ai,:host .badge-container-secondary [color=petrol-90w].point,:host .badge-container-secondary-ai [color=petrol-90w].point,:host [color=petrol-90w].badge-container-notification{background:#e9f0f1;color:#000}.background-colors[color=petrol-60w],:host [color=petrol-60w].badge-container-primary,:host [color=petrol-60w].badge-container-primary-ai,:host .badge-container-secondary [color=petrol-60w].point,:host .badge-container-secondary-ai [color=petrol-60w].point,:host [color=petrol-60w].badge-container-notification{background:#a9c2c9;color:#000}.background-colors[color=grey-dark],:host [color=grey-dark].badge-container-primary,:host [color=grey-dark].badge-container-primary-ai,:host .badge-container-secondary [color=grey-dark].point,:host .badge-container-secondary-ai [color=grey-dark].point,:host [color=grey-dark].badge-container-notification{background:#888}.background-colors[color=success],:host [color=success].badge-container-primary,:host [color=success].badge-container-primary-ai,:host .badge-container-secondary [color=success].point,:host .badge-container-secondary-ai [color=success].point,:host [color=success].badge-container-notification{background:#d4f2c3;color:#242424}.background-colors[color=warning],:host [color=warning].badge-container-primary,:host [color=warning].badge-container-primary-ai,:host .badge-container-secondary [color=warning].point,:host .badge-container-secondary-ai [color=warning].point,:host [color=warning].badge-container-notification{background:#ffe1b3;color:#242424}.background-colors[color=negative],:host [color=negative].badge-container-primary,:host [color=negative].badge-container-primary-ai,:host .badge-container-secondary [color=negative].point,:host .badge-container-secondary-ai [color=negative].point,:host [color=negative].badge-container-notification{background:#ffac9a;color:#242424}.background-colors[color=info],:host [color=info].badge-container-primary,:host [color=info].badge-container-primary-ai,:host .badge-container-secondary [color=info].point,:host .badge-container-secondary-ai [color=info].point,:host [color=info].badge-container-notification{background:#d9e8ff;color:#242424}.background-colors[color=brand],:host [color=brand].badge-container-primary,:host [color=brand].badge-container-primary-ai,:host .badge-container-secondary [color=brand].point,:host .badge-container-secondary-ai [color=brand].point,:host [color=brand].badge-container-notification{background:#ffe6fa;color:#242424}.background-colors[color=neutral],:host [color=neutral].badge-container-primary,:host [color=neutral].badge-container-primary-ai,:host .badge-container-secondary [color=neutral].point,:host .badge-container-secondary-ai [color=neutral].point,:host [color=neutral].badge-container-notification{background:#e9e9e9;color:#242424}.background-colors[color=blue-20],:host [color=blue-20].badge-container-primary,:host [color=blue-20].badge-container-primary-ai,:host .badge-container-secondary [color=blue-20].point,:host .badge-container-secondary-ai [color=blue-20].point,:host [color=blue-20].badge-container-notification{background:#99c1fe;color:#242424}.background-colors[color=blue-30],:host [color=blue-30].badge-container-primary,:host [color=blue-30].badge-container-primary-ai,:host .badge-container-secondary [color=blue-30].point,:host .badge-container-secondary-ai [color=blue-30].point,:host [color=blue-30].badge-container-notification{background:#277cfd;color:#fff}.background-colors[color=blue-40],:host [color=blue-40].badge-container-primary,:host [color=blue-40].badge-container-primary-ai,:host .badge-container-secondary [color=blue-40].point,:host .badge-container-secondary-ai [color=blue-40].point,:host [color=blue-40].badge-container-notification{background:#0165fc;color:#fff}.background-colors[color=pink-30],:host [color=pink-30].badge-container-primary,:host [color=pink-30].badge-container-primary-ai,:host .badge-container-secondary [color=pink-30].point,:host .badge-container-secondary-ai [color=pink-30].point,:host [color=pink-30].badge-container-notification{background:#ffb3ee;color:#242424}.background-colors[color=blue-10],:host [color=blue-10].badge-container-primary,:host [color=blue-10].badge-container-primary-ai,:host .badge-container-secondary [color=blue-10].point,:host .badge-container-secondary-ai [color=blue-10].point,:host [color=blue-10].badge-container-notification{background:#d9e8ff;color:#242424}.background-colors[color=grey-30],:host [color=grey-30].badge-container-primary,:host [color=grey-30].badge-container-primary-ai,:host .badge-container-secondary [color=grey-30].point,:host .badge-container-secondary-ai [color=grey-30].point,:host [color=grey-30].badge-container-notification{background:#d3d3d3;color:#242424}.background-colors[color=grey-20],:host [color=grey-20].badge-container-primary,:host [color=grey-20].badge-container-primary-ai,:host .badge-container-secondary [color=grey-20].point,:host .badge-container-secondary-ai [color=grey-20].point,:host [color=grey-20].badge-container-notification{background:#e9e9e9;color:#242424}.background-colors[color=grey-10],:host [color=grey-10].badge-container-primary,:host [color=grey-10].badge-container-primary-ai,:host .badge-container-secondary [color=grey-10].point,:host .badge-container-secondary-ai [color=grey-10].point,:host [color=grey-10].badge-container-notification{background:#f4f4f4;color:#242424}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "component", type: i2.IconComponent, selector: "ui-icon", inputs: ["size", "cssClass", "name", "color", "filled", "toggleIconStyle", "applicationTheme", "useFullIconName"] }, { kind: "directive", type: i3.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "pipe", type: i1.SlicePipe, name: "slice" }] }); }
|
|
161
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.2.20", type: BadgeComponent, isStandalone: false, selector: "ui-badge", inputs: { label: { classPropertyName: "label", publicName: "label", isSignal: false, isRequired: false, transformFunction: null }, staticLabel: { classPropertyName: "staticLabel", publicName: "staticLabel", isSignal: false, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: false, isRequired: false, transformFunction: null }, iconColor: { classPropertyName: "iconColor", publicName: "iconColor", isSignal: true, isRequired: false, transformFunction: null }, trailingIcon: { classPropertyName: "trailingIcon", publicName: "trailingIcon", isSignal: true, isRequired: false, transformFunction: null }, trailingIconColor: { classPropertyName: "trailingIconColor", publicName: "trailingIconColor", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: false, isRequired: false, transformFunction: null }, variant: { classPropertyName: "variant", publicName: "variant", isSignal: false, isRequired: false, transformFunction: null }, notificationsAmount: { classPropertyName: "notificationsAmount", publicName: "notificationsAmount", isSignal: false, isRequired: false, transformFunction: null }, applicationTheme: { classPropertyName: "applicationTheme", publicName: "applicationTheme", isSignal: false, isRequired: false, transformFunction: null }, rebrandColor: { classPropertyName: "rebrandColor", publicName: "rebrandColor", isSignal: false, isRequired: false, transformFunction: null }, truncateLabel: { classPropertyName: "truncateLabel", publicName: "truncateLabel", isSignal: false, isRequired: false, transformFunction: null }, enableAnimation: { classPropertyName: "enableAnimation", publicName: "enableAnimation", isSignal: false, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div\n [class]=\"'badge badge-container-' + variant\"\n [class.no-label]=\"!label && !staticLabel && !trailingIcon()\"\n [attr.aria-label]=\"label + (staticLabel ? ' ' + staticLabel : '')\"\n [attr.theme]=\"applicationTheme\"\n [attr.color]=\"isClassicTheme ? color : rebrandColor\"\n [matTooltip]=\"\n label.length > 25 - (staticLabel.length < 4 ? staticLabel.length : 4)\n ? label + (staticLabel ? ' ' + staticLabel : '')\n : ''\n \"\n [matTooltipClass]=\"applicationTheme\"\n>\n <ng-container [ngSwitch]=\"variant\">\n <ng-container *ngSwitchCase=\"badgeVariant.PRIMARY\">\n <ui-icon\n *ngIf=\"icon\"\n [class.badge-icon]=\"!!label || !!staticLabel || !!trailingIcon\"\n [name]=\"icon\"\n [color]=\"resolvedIconColor\"\n ></ui-icon>\n </ng-container>\n <ng-container *ngSwitchCase=\"badgeVariant.PRIMARY_AI\">\n <ng-container [ngTemplateOutlet]=\"aiIconTpl\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"badgeVariant.SECONDARY_AI\">\n <ng-container [ngTemplateOutlet]=\"aiIconTpl\"></ng-container>\n </ng-container>\n <div\n *ngSwitchCase=\"badgeVariant.SECONDARY\"\n class=\"point\"\n [attr.color]=\"isClassicTheme ? color : rebrandColor\"\n ></div>\n <div *ngSwitchCase=\"badgeVariant.NOTIFICATION\" class=\"number-notification\">{{ notificationsAmount }}</div>\n </ng-container>\n <div\n class=\"label\"\n *ngIf=\"variant !== badgeVariant.NOTIFICATION\"\n [class.empty]=\"!label && !staticLabel\"\n [class.animated]=\"enableAnimation\"\n >\n {{\n label.length > 25 - (staticLabel.length < 4 ? staticLabel.length : 4) && truncateLabel\n ? (label | slice: 0 : 25 - (staticLabel.length < 4 ? staticLabel.length : 4)) + '...'\n : label\n }}\n </div>\n <span *ngIf=\"staticLabel && variant !== badgeVariant.NOTIFICATION\" class=\"static-label\">{{\n staticLabel | slice: 0 : 4\n }}</span>\n <ui-icon\n *ngIf=\"trailingIcon() && variant === badgeVariant.PRIMARY\"\n class=\"badge-icon-trailing\"\n [name]=\"trailingIcon()\"\n [color]=\"resolvedTrailingIconColor\"\n ></ui-icon>\n</div>\n\n<ng-template #aiIconTpl>\n <ui-icon class=\"badge-icon\" [name]=\"'Sparkle-in-line'\" [color]=\"'ai'\"></ui-icon>\n</ng-template>\n", styles: [".bg-teal-60b{background:#1c443c}.bg-teal-30b{background:#31766a}.bg-teal-default{background:#46a997}.bg-teal-30w{background:#7ec3b6}.bg-teal-60w{background:#b5ddd5}.bg-teal-secondary{background:#cbd6cb}.bg-teal-90w{background:#ecf6f5}.bg-petrol-60b{background:#102930}.bg-petrol-30b{background:#1b4754}.bg-petrol-default{background:#276678}.bg-petrol-30w{background:#6894a0}.bg-petrol-60w{background:#a9c2c9}.bg-petrol-secondary{background:#c8d7de}.bg-petrol-90w{background:#e9f0f1}.bg-error-60b{background:#513131}.bg-error-30b{background:#8e5655}.bg-error-60w{background:#e3c3c6}.bg-error-secondary{background:#f0dad9}.bg-error-default{background:#cb7b7a}.bg-warning-secondary{background:#f0d6bb}.bg-warning-default{background:#cca45f}.bg-black{background:#000}.bg-dark{background:#888}.bg-medium{background:#e0e0e0}.bg-grey{background:#ededed}.bg-light{background:#f6f6f6}.bg-white{background:#fff}.bg-box-shadow{background:#00000014}.bg-navigation-subtitle{background:#528593}.bgc-teal-60b{background-color:#1c443c}.bgc-teal-30b{background-color:#31766a}.bgc-teal-default{background-color:#46a997}.bgc-teal-30w{background-color:#7ec3b6}.bgc-teal-60w{background-color:#b5ddd5}.bgc-teal-secondary{background-color:#cbd6cb}.bgc-teal-90w{background-color:#ecf6f5}.bgc-petrol-60b{background-color:#102930}.bgc-petrol-30b{background-color:#1b4754}.bgc-petrol-default{background-color:#276678}.bgc-petrol-30w{background-color:#6894a0}.bgc-petrol-60w{background-color:#a9c2c9}.bgc-petrol-secondary{background-color:#c8d7de}.bgc-petrol-90w{background-color:#e9f0f1}.bgc-error-60b{background-color:#513131}.bgc-error-30b{background-color:#8e5655}.bgc-error-60w{background-color:#e3c3c6}.bgc-error-secondary{background-color:#f0dad9}.bgc-error-default{background-color:#cb7b7a}.bgc-warning-secondary{background-color:#f0d6bb}.bgc-warning-default{background-color:#cca45f}.bgc-black{background-color:#000}.bgc-dark{background-color:#888}.bgc-medium{background-color:#e0e0e0}.bgc-grey{background-color:#ededed}.bgc-light{background-color:#f6f6f6}.bgc-white{background-color:#fff}.bgc-box-shadow{background-color:#00000014}.bgc-navigation-subtitle{background-color:#528593}:host{display:block}:host .badge-container-primary,:host .badge-container-primary-ai,:host .badge-container-secondary,:host .badge-container-secondary-ai,:host .badge-container-notification{width:fit-content}:host .badge-container-primary,:host .badge-container-primary-ai,:host .badge-container-secondary,:host .badge-container-secondary-ai{height:24px;padding:0 8px;border-radius:21px;color:#fff;line-height:10px;transition:all .2s ease-out}:host .badge-container-primary .label,:host .badge-container-primary-ai .label,:host .badge-container-secondary .label,:host .badge-container-secondary-ai .label{font-size:12px;line-height:14px}:host .badge-container-primary .label.animated,:host .badge-container-primary-ai .label.animated,:host .badge-container-secondary .label.animated,:host .badge-container-secondary-ai .label.animated{display:inline-block;max-width:500px;opacity:1;overflow:hidden;white-space:nowrap;transition:max-width .25s ease-in-out,opacity .2s ease-in-out;will-change:max-width,opacity;contain:layout style}:host .badge-container-primary .label.empty,:host .badge-container-primary-ai .label.empty,:host .badge-container-secondary .label.empty,:host .badge-container-secondary-ai .label.empty{max-width:0;opacity:0}:host .badge-container-primary .static-label,:host .badge-container-primary-ai .static-label,:host .badge-container-secondary .static-label,:host .badge-container-secondary-ai .static-label{font-size:12px;line-height:14px;white-space:nowrap;flex-shrink:0;margin-left:2px}:host .badge-container-primary .badge-icon:not(:last-child),:host .badge-container-primary-ai .badge-icon:not(:last-child),:host .badge-container-secondary .badge-icon:not(:last-child),:host .badge-container-secondary-ai .badge-icon:not(:last-child){margin-right:8px}:host .badge-container-primary .badge-icon-trailing,:host .badge-container-primary-ai .badge-icon-trailing,:host .badge-container-secondary .badge-icon-trailing,:host .badge-container-secondary-ai .badge-icon-trailing{margin-left:8px}:host .badge-container-primary.no-label .badge-icon,:host .badge-container-primary-ai.no-label .badge-icon,:host .badge-container-secondary.no-label .badge-icon,:host .badge-container-secondary-ai.no-label .badge-icon{margin-right:0}:host .badge-container-secondary{padding:0}:host .badge-container-primary-ai.no-label{padding:4px}:host .badge-container-secondary .point,:host .badge-container-secondary-ai .point{border-radius:50%;padding:4px;margin-right:8px}:host .badge-container-secondary .label,:host .badge-container-secondary-ai .label{color:#000!important;width:100%}:host .badge-container-secondary[theme=dark],:host .badge-container-secondary[theme=light],:host .badge-container-secondary-ai[theme=dark],:host .badge-container-secondary-ai[theme=light]{color:#242424}:host .badge-container-secondary .badge-icon:not(:last-child),:host .badge-container-secondary-ai .badge-icon:not(:last-child){margin-right:4px}:host .badge-container-notification{min-width:20px;height:20px;border-radius:50%;color:#fff;line-height:10px}:host .badge-container-notification .label{font-size:12px}:host .badge-container-notification[theme=dark],:host .badge-container-notification[theme=light]{background:#242424!important;color:#fff!important;border-color:1px solid #ffffff}:host .badge{width:100%!important;max-width:fit-content!important}:host .badge .label{white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;box-sizing:border-box!important}.flex-center,:host .badge-container-primary,:host .badge-container-primary-ai,:host .badge-container-secondary,:host .badge-container-secondary-ai,:host .badge-container-notification{display:flex;align-items:center;justify-content:center}.background-colors[color=red],:host [color=red].badge-container-primary,:host [color=red].badge-container-primary-ai,:host .badge-container-secondary [color=red].point,:host .badge-container-secondary-ai [color=red].point,:host [color=red].badge-container-notification{background:#cb7b7a}.background-colors[color=grey-medium],:host [color=grey-medium].badge-container-primary,:host [color=grey-medium].badge-container-primary-ai,:host .badge-container-secondary [color=grey-medium].point,:host .badge-container-secondary-ai [color=grey-medium].point,:host [color=grey-medium].badge-container-notification{background:#e0e0e0;color:#000}.background-colors[color=teal],:host [color=teal].badge-container-primary,:host [color=teal].badge-container-primary-ai,:host .badge-container-secondary [color=teal].point,:host .badge-container-secondary-ai [color=teal].point,:host [color=teal].badge-container-notification{background:#46a997}.background-colors[color=yellow],:host [color=yellow].badge-container-primary,:host [color=yellow].badge-container-primary-ai,:host .badge-container-secondary [color=yellow].point,:host .badge-container-secondary-ai [color=yellow].point,:host [color=yellow].badge-container-notification{background:#cca45f}.background-colors[color=petrol],:host [color=petrol].badge-container-primary,:host [color=petrol].badge-container-primary-ai,:host .badge-container-secondary [color=petrol].point,:host .badge-container-secondary-ai [color=petrol].point,:host [color=petrol].badge-container-notification{background:#276678}.background-colors[color=teal-60w],:host [color=teal-60w].badge-container-primary,:host [color=teal-60w].badge-container-primary-ai,:host .badge-container-secondary [color=teal-60w].point,:host .badge-container-secondary-ai [color=teal-60w].point,:host [color=teal-60w].badge-container-notification{background:#b5ddd5;color:#000}.background-colors[color=petrol-90w],:host [color=petrol-90w].badge-container-primary,:host [color=petrol-90w].badge-container-primary-ai,:host .badge-container-secondary [color=petrol-90w].point,:host .badge-container-secondary-ai [color=petrol-90w].point,:host [color=petrol-90w].badge-container-notification{background:#e9f0f1;color:#000}.background-colors[color=petrol-60w],:host [color=petrol-60w].badge-container-primary,:host [color=petrol-60w].badge-container-primary-ai,:host .badge-container-secondary [color=petrol-60w].point,:host .badge-container-secondary-ai [color=petrol-60w].point,:host [color=petrol-60w].badge-container-notification{background:#a9c2c9;color:#000}.background-colors[color=grey-dark],:host [color=grey-dark].badge-container-primary,:host [color=grey-dark].badge-container-primary-ai,:host .badge-container-secondary [color=grey-dark].point,:host .badge-container-secondary-ai [color=grey-dark].point,:host [color=grey-dark].badge-container-notification{background:#888}.background-colors[color=success],:host [color=success].badge-container-primary,:host [color=success].badge-container-primary-ai,:host .badge-container-secondary [color=success].point,:host .badge-container-secondary-ai [color=success].point,:host [color=success].badge-container-notification{background:#d4f2c3;color:#242424}.background-colors[color=warning],:host [color=warning].badge-container-primary,:host [color=warning].badge-container-primary-ai,:host .badge-container-secondary [color=warning].point,:host .badge-container-secondary-ai [color=warning].point,:host [color=warning].badge-container-notification{background:#ffe1b3;color:#242424}.background-colors[color=negative],:host [color=negative].badge-container-primary,:host [color=negative].badge-container-primary-ai,:host .badge-container-secondary [color=negative].point,:host .badge-container-secondary-ai [color=negative].point,:host [color=negative].badge-container-notification{background:#ffac9a;color:#242424}.background-colors[color=info],:host [color=info].badge-container-primary,:host [color=info].badge-container-primary-ai,:host .badge-container-secondary [color=info].point,:host .badge-container-secondary-ai [color=info].point,:host [color=info].badge-container-notification{background:#d9e8ff;color:#242424}.background-colors[color=brand],:host [color=brand].badge-container-primary,:host [color=brand].badge-container-primary-ai,:host .badge-container-secondary [color=brand].point,:host .badge-container-secondary-ai [color=brand].point,:host [color=brand].badge-container-notification{background:#ffe6fa;color:#242424}.background-colors[color=neutral],:host [color=neutral].badge-container-primary,:host [color=neutral].badge-container-primary-ai,:host .badge-container-secondary [color=neutral].point,:host .badge-container-secondary-ai [color=neutral].point,:host [color=neutral].badge-container-notification{background:#e9e9e9;color:#242424}.background-colors[color=blue-20],:host [color=blue-20].badge-container-primary,:host [color=blue-20].badge-container-primary-ai,:host .badge-container-secondary [color=blue-20].point,:host .badge-container-secondary-ai [color=blue-20].point,:host [color=blue-20].badge-container-notification{background:#99c1fe;color:#242424}.background-colors[color=blue-30],:host [color=blue-30].badge-container-primary,:host [color=blue-30].badge-container-primary-ai,:host .badge-container-secondary [color=blue-30].point,:host .badge-container-secondary-ai [color=blue-30].point,:host [color=blue-30].badge-container-notification{background:#277cfd;color:#fff}.background-colors[color=blue-40],:host [color=blue-40].badge-container-primary,:host [color=blue-40].badge-container-primary-ai,:host .badge-container-secondary [color=blue-40].point,:host .badge-container-secondary-ai [color=blue-40].point,:host [color=blue-40].badge-container-notification{background:#0165fc;color:#fff}.background-colors[color=pink-30],:host [color=pink-30].badge-container-primary,:host [color=pink-30].badge-container-primary-ai,:host .badge-container-secondary [color=pink-30].point,:host .badge-container-secondary-ai [color=pink-30].point,:host [color=pink-30].badge-container-notification{background:#ffb3ee;color:#242424}.background-colors[color=blue-10],:host [color=blue-10].badge-container-primary,:host [color=blue-10].badge-container-primary-ai,:host .badge-container-secondary [color=blue-10].point,:host .badge-container-secondary-ai [color=blue-10].point,:host [color=blue-10].badge-container-notification{background:#d9e8ff;color:#242424}.background-colors[color=grey-30],:host [color=grey-30].badge-container-primary,:host [color=grey-30].badge-container-primary-ai,:host .badge-container-secondary [color=grey-30].point,:host .badge-container-secondary-ai [color=grey-30].point,:host [color=grey-30].badge-container-notification{background:#d3d3d3;color:#242424}.background-colors[color=grey-20],:host [color=grey-20].badge-container-primary,:host [color=grey-20].badge-container-primary-ai,:host .badge-container-secondary [color=grey-20].point,:host .badge-container-secondary-ai [color=grey-20].point,:host [color=grey-20].badge-container-notification{background:#e9e9e9;color:#242424}.background-colors[color=grey-10],:host [color=grey-10].badge-container-primary,:host [color=grey-10].badge-container-primary-ai,:host .badge-container-secondary [color=grey-10].point,:host .badge-container-secondary-ai [color=grey-10].point,:host [color=grey-10].badge-container-notification{background:#f4f4f4;color:#242424}\n"], dependencies: [{ kind: "directive", type: i1.NgIf, selector: "[ngIf]", inputs: ["ngIf", "ngIfThen", "ngIfElse"] }, { kind: "directive", type: i1.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "directive", type: i1.NgSwitch, selector: "[ngSwitch]", inputs: ["ngSwitch"] }, { kind: "directive", type: i1.NgSwitchCase, selector: "[ngSwitchCase]", inputs: ["ngSwitchCase"] }, { kind: "component", type: i2.IconComponent, selector: "ui-icon", inputs: ["size", "cssClass", "name", "color", "filled", "toggleIconStyle", "applicationTheme", "useFullIconName"] }, { kind: "directive", type: i3.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "pipe", type: i1.SlicePipe, name: "slice" }] }); }
|
|
140
162
|
}
|
|
141
163
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: BadgeComponent, decorators: [{
|
|
142
164
|
type: Component,
|
|
143
|
-
args: [{ selector: 'ui-badge', standalone: false, template: "<div\n [class]=\"'badge badge-container-' + variant\"\n [class.no-label]=\"!label && !staticLabel\"\n [attr.aria-label]=\"label + (staticLabel ? ' ' + staticLabel : '')\"\n [attr.theme]=\"applicationTheme\"\n [attr.color]=\"isClassicTheme ? color : rebrandColor\"\n [matTooltip]=\"\n label.length > 25 - (staticLabel.length < 4 ? staticLabel.length : 4)\n ? label + (staticLabel ? ' ' + staticLabel : '')\n : ''\n \"\n [matTooltipClass]=\"applicationTheme\"\n>\n <ng-container [ngSwitch]=\"variant\">\n <ng-container *ngSwitchCase=\"badgeVariant.PRIMARY\">\n <ui-icon *ngIf=\"icon\" [class.badge-icon]=\"!!label\" [name]=\"icon\" [color]=\"iconColor\"></ui-icon>\n </ng-container>\n <ng-container *ngSwitchCase=\"badgeVariant.PRIMARY_AI\">\n <ng-container [ngTemplateOutlet]=\"aiIconTpl\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"badgeVariant.SECONDARY_AI\">\n <ng-container [ngTemplateOutlet]=\"aiIconTpl\"></ng-container>\n </ng-container>\n <div\n *ngSwitchCase=\"badgeVariant.SECONDARY\"\n class=\"point\"\n [attr.color]=\"isClassicTheme ? color : rebrandColor\"\n ></div>\n <div *ngSwitchCase=\"badgeVariant.NOTIFICATION\" class=\"number-notification\">{{ notificationsAmount }}</div>\n </ng-container>\n <div\n class=\"label\"\n *ngIf=\"variant !== badgeVariant.NOTIFICATION\"\n [class.empty]=\"!label && !staticLabel\"\n [class.animated]=\"enableAnimation\"\n >\n {{\n label.length > 25 - (staticLabel.length < 4 ? staticLabel.length : 4) && truncateLabel\n ? (label | slice: 0 : 25 - (staticLabel.length < 4 ? staticLabel.length : 4)) + '...'\n : label\n }}\n </div>\n <span *ngIf=\"staticLabel && variant !== badgeVariant.NOTIFICATION\" class=\"static-label\">{{\n staticLabel | slice: 0 : 4\n }}</span>\n</div>\n\n<ng-template #aiIconTpl>\n <ui-icon class=\"badge-icon\" [name]=\"'Sparkle-in-line'\" [color]=\"'ai'\"></ui-icon>\n</ng-template>\n", styles: [".bg-teal-60b{background:#1c443c}.bg-teal-30b{background:#31766a}.bg-teal-default{background:#46a997}.bg-teal-30w{background:#7ec3b6}.bg-teal-60w{background:#b5ddd5}.bg-teal-secondary{background:#cbd6cb}.bg-teal-90w{background:#ecf6f5}.bg-petrol-60b{background:#102930}.bg-petrol-30b{background:#1b4754}.bg-petrol-default{background:#276678}.bg-petrol-30w{background:#6894a0}.bg-petrol-60w{background:#a9c2c9}.bg-petrol-secondary{background:#c8d7de}.bg-petrol-90w{background:#e9f0f1}.bg-error-60b{background:#513131}.bg-error-30b{background:#8e5655}.bg-error-60w{background:#e3c3c6}.bg-error-secondary{background:#f0dad9}.bg-error-default{background:#cb7b7a}.bg-warning-secondary{background:#f0d6bb}.bg-warning-default{background:#cca45f}.bg-black{background:#000}.bg-dark{background:#888}.bg-medium{background:#e0e0e0}.bg-grey{background:#ededed}.bg-light{background:#f6f6f6}.bg-white{background:#fff}.bg-box-shadow{background:#00000014}.bg-navigation-subtitle{background:#528593}.bgc-teal-60b{background-color:#1c443c}.bgc-teal-30b{background-color:#31766a}.bgc-teal-default{background-color:#46a997}.bgc-teal-30w{background-color:#7ec3b6}.bgc-teal-60w{background-color:#b5ddd5}.bgc-teal-secondary{background-color:#cbd6cb}.bgc-teal-90w{background-color:#ecf6f5}.bgc-petrol-60b{background-color:#102930}.bgc-petrol-30b{background-color:#1b4754}.bgc-petrol-default{background-color:#276678}.bgc-petrol-30w{background-color:#6894a0}.bgc-petrol-60w{background-color:#a9c2c9}.bgc-petrol-secondary{background-color:#c8d7de}.bgc-petrol-90w{background-color:#e9f0f1}.bgc-error-60b{background-color:#513131}.bgc-error-30b{background-color:#8e5655}.bgc-error-60w{background-color:#e3c3c6}.bgc-error-secondary{background-color:#f0dad9}.bgc-error-default{background-color:#cb7b7a}.bgc-warning-secondary{background-color:#f0d6bb}.bgc-warning-default{background-color:#cca45f}.bgc-black{background-color:#000}.bgc-dark{background-color:#888}.bgc-medium{background-color:#e0e0e0}.bgc-grey{background-color:#ededed}.bgc-light{background-color:#f6f6f6}.bgc-white{background-color:#fff}.bgc-box-shadow{background-color:#00000014}.bgc-navigation-subtitle{background-color:#528593}:host{display:block}:host .badge-container-primary,:host .badge-container-primary-ai,:host .badge-container-secondary,:host .badge-container-secondary-ai,:host .badge-container-notification{width:fit-content}:host .badge-container-primary,:host .badge-container-primary-ai,:host .badge-container-secondary,:host .badge-container-secondary-ai{height:24px;padding:0 8px;border-radius:21px;color:#fff;line-height:10px;transition:all .2s ease-out}:host .badge-container-primary .label,:host .badge-container-primary-ai .label,:host .badge-container-secondary .label,:host .badge-container-secondary-ai .label{font-size:12px;line-height:14px}:host .badge-container-primary .label.animated,:host .badge-container-primary-ai .label.animated,:host .badge-container-secondary .label.animated,:host .badge-container-secondary-ai .label.animated{display:inline-block;max-width:500px;opacity:1;overflow:hidden;white-space:nowrap;transition:max-width .25s ease-in-out,opacity .2s ease-in-out;will-change:max-width,opacity;contain:layout style}:host .badge-container-primary .label.empty,:host .badge-container-primary-ai .label.empty,:host .badge-container-secondary .label.empty,:host .badge-container-secondary-ai .label.empty{max-width:0;opacity:0}:host .badge-container-primary .static-label,:host .badge-container-primary-ai .static-label,:host .badge-container-secondary .static-label,:host .badge-container-secondary-ai .static-label{font-size:12px;line-height:14px;white-space:nowrap;flex-shrink:0;margin-left:2px}:host .badge-container-primary .badge-icon:not(:last-child),:host .badge-container-primary-ai .badge-icon:not(:last-child),:host .badge-container-secondary .badge-icon:not(:last-child),:host .badge-container-secondary-ai .badge-icon:not(:last-child){margin-right:8px}:host .badge-container-primary.no-label .badge-icon,:host .badge-container-primary-ai.no-label .badge-icon,:host .badge-container-secondary.no-label .badge-icon,:host .badge-container-secondary-ai.no-label .badge-icon{margin-right:0}:host .badge-container-secondary{padding:0}:host .badge-container-primary-ai.no-label{padding:4px}:host .badge-container-secondary .point,:host .badge-container-secondary-ai .point{border-radius:50%;padding:4px;margin-right:8px}:host .badge-container-secondary .label,:host .badge-container-secondary-ai .label{color:#000!important;width:100%}:host .badge-container-secondary[theme=dark],:host .badge-container-secondary[theme=light],:host .badge-container-secondary-ai[theme=dark],:host .badge-container-secondary-ai[theme=light]{color:#242424}:host .badge-container-secondary .badge-icon:not(:last-child),:host .badge-container-secondary-ai .badge-icon:not(:last-child){margin-right:4px}:host .badge-container-notification{min-width:20px;height:20px;border-radius:50%;color:#fff;line-height:10px}:host .badge-container-notification .label{font-size:12px}:host .badge-container-notification[theme=dark],:host .badge-container-notification[theme=light]{background:#242424!important;color:#fff!important;border-color:1px solid #ffffff}:host .badge{width:100%!important;max-width:fit-content!important}:host .badge .label{white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;box-sizing:border-box!important}.flex-center,:host .badge-container-primary,:host .badge-container-primary-ai,:host .badge-container-secondary,:host .badge-container-secondary-ai,:host .badge-container-notification{display:flex;align-items:center;justify-content:center}.background-colors[color=red],:host [color=red].badge-container-primary,:host [color=red].badge-container-primary-ai,:host .badge-container-secondary [color=red].point,:host .badge-container-secondary-ai [color=red].point,:host [color=red].badge-container-notification{background:#cb7b7a}.background-colors[color=grey-medium],:host [color=grey-medium].badge-container-primary,:host [color=grey-medium].badge-container-primary-ai,:host .badge-container-secondary [color=grey-medium].point,:host .badge-container-secondary-ai [color=grey-medium].point,:host [color=grey-medium].badge-container-notification{background:#e0e0e0;color:#000}.background-colors[color=teal],:host [color=teal].badge-container-primary,:host [color=teal].badge-container-primary-ai,:host .badge-container-secondary [color=teal].point,:host .badge-container-secondary-ai [color=teal].point,:host [color=teal].badge-container-notification{background:#46a997}.background-colors[color=yellow],:host [color=yellow].badge-container-primary,:host [color=yellow].badge-container-primary-ai,:host .badge-container-secondary [color=yellow].point,:host .badge-container-secondary-ai [color=yellow].point,:host [color=yellow].badge-container-notification{background:#cca45f}.background-colors[color=petrol],:host [color=petrol].badge-container-primary,:host [color=petrol].badge-container-primary-ai,:host .badge-container-secondary [color=petrol].point,:host .badge-container-secondary-ai [color=petrol].point,:host [color=petrol].badge-container-notification{background:#276678}.background-colors[color=teal-60w],:host [color=teal-60w].badge-container-primary,:host [color=teal-60w].badge-container-primary-ai,:host .badge-container-secondary [color=teal-60w].point,:host .badge-container-secondary-ai [color=teal-60w].point,:host [color=teal-60w].badge-container-notification{background:#b5ddd5;color:#000}.background-colors[color=petrol-90w],:host [color=petrol-90w].badge-container-primary,:host [color=petrol-90w].badge-container-primary-ai,:host .badge-container-secondary [color=petrol-90w].point,:host .badge-container-secondary-ai [color=petrol-90w].point,:host [color=petrol-90w].badge-container-notification{background:#e9f0f1;color:#000}.background-colors[color=petrol-60w],:host [color=petrol-60w].badge-container-primary,:host [color=petrol-60w].badge-container-primary-ai,:host .badge-container-secondary [color=petrol-60w].point,:host .badge-container-secondary-ai [color=petrol-60w].point,:host [color=petrol-60w].badge-container-notification{background:#a9c2c9;color:#000}.background-colors[color=grey-dark],:host [color=grey-dark].badge-container-primary,:host [color=grey-dark].badge-container-primary-ai,:host .badge-container-secondary [color=grey-dark].point,:host .badge-container-secondary-ai [color=grey-dark].point,:host [color=grey-dark].badge-container-notification{background:#888}.background-colors[color=success],:host [color=success].badge-container-primary,:host [color=success].badge-container-primary-ai,:host .badge-container-secondary [color=success].point,:host .badge-container-secondary-ai [color=success].point,:host [color=success].badge-container-notification{background:#d4f2c3;color:#242424}.background-colors[color=warning],:host [color=warning].badge-container-primary,:host [color=warning].badge-container-primary-ai,:host .badge-container-secondary [color=warning].point,:host .badge-container-secondary-ai [color=warning].point,:host [color=warning].badge-container-notification{background:#ffe1b3;color:#242424}.background-colors[color=negative],:host [color=negative].badge-container-primary,:host [color=negative].badge-container-primary-ai,:host .badge-container-secondary [color=negative].point,:host .badge-container-secondary-ai [color=negative].point,:host [color=negative].badge-container-notification{background:#ffac9a;color:#242424}.background-colors[color=info],:host [color=info].badge-container-primary,:host [color=info].badge-container-primary-ai,:host .badge-container-secondary [color=info].point,:host .badge-container-secondary-ai [color=info].point,:host [color=info].badge-container-notification{background:#d9e8ff;color:#242424}.background-colors[color=brand],:host [color=brand].badge-container-primary,:host [color=brand].badge-container-primary-ai,:host .badge-container-secondary [color=brand].point,:host .badge-container-secondary-ai [color=brand].point,:host [color=brand].badge-container-notification{background:#ffe6fa;color:#242424}.background-colors[color=neutral],:host [color=neutral].badge-container-primary,:host [color=neutral].badge-container-primary-ai,:host .badge-container-secondary [color=neutral].point,:host .badge-container-secondary-ai [color=neutral].point,:host [color=neutral].badge-container-notification{background:#e9e9e9;color:#242424}.background-colors[color=blue-20],:host [color=blue-20].badge-container-primary,:host [color=blue-20].badge-container-primary-ai,:host .badge-container-secondary [color=blue-20].point,:host .badge-container-secondary-ai [color=blue-20].point,:host [color=blue-20].badge-container-notification{background:#99c1fe;color:#242424}.background-colors[color=blue-30],:host [color=blue-30].badge-container-primary,:host [color=blue-30].badge-container-primary-ai,:host .badge-container-secondary [color=blue-30].point,:host .badge-container-secondary-ai [color=blue-30].point,:host [color=blue-30].badge-container-notification{background:#277cfd;color:#fff}.background-colors[color=blue-40],:host [color=blue-40].badge-container-primary,:host [color=blue-40].badge-container-primary-ai,:host .badge-container-secondary [color=blue-40].point,:host .badge-container-secondary-ai [color=blue-40].point,:host [color=blue-40].badge-container-notification{background:#0165fc;color:#fff}.background-colors[color=pink-30],:host [color=pink-30].badge-container-primary,:host [color=pink-30].badge-container-primary-ai,:host .badge-container-secondary [color=pink-30].point,:host .badge-container-secondary-ai [color=pink-30].point,:host [color=pink-30].badge-container-notification{background:#ffb3ee;color:#242424}.background-colors[color=blue-10],:host [color=blue-10].badge-container-primary,:host [color=blue-10].badge-container-primary-ai,:host .badge-container-secondary [color=blue-10].point,:host .badge-container-secondary-ai [color=blue-10].point,:host [color=blue-10].badge-container-notification{background:#d9e8ff;color:#242424}.background-colors[color=grey-30],:host [color=grey-30].badge-container-primary,:host [color=grey-30].badge-container-primary-ai,:host .badge-container-secondary [color=grey-30].point,:host .badge-container-secondary-ai [color=grey-30].point,:host [color=grey-30].badge-container-notification{background:#d3d3d3;color:#242424}.background-colors[color=grey-20],:host [color=grey-20].badge-container-primary,:host [color=grey-20].badge-container-primary-ai,:host .badge-container-secondary [color=grey-20].point,:host .badge-container-secondary-ai [color=grey-20].point,:host [color=grey-20].badge-container-notification{background:#e9e9e9;color:#242424}.background-colors[color=grey-10],:host [color=grey-10].badge-container-primary,:host [color=grey-10].badge-container-primary-ai,:host .badge-container-secondary [color=grey-10].point,:host .badge-container-secondary-ai [color=grey-10].point,:host [color=grey-10].badge-container-notification{background:#f4f4f4;color:#242424}\n"] }]
|
|
165
|
+
args: [{ selector: 'ui-badge', standalone: false, template: "<div\n [class]=\"'badge badge-container-' + variant\"\n [class.no-label]=\"!label && !staticLabel && !trailingIcon()\"\n [attr.aria-label]=\"label + (staticLabel ? ' ' + staticLabel : '')\"\n [attr.theme]=\"applicationTheme\"\n [attr.color]=\"isClassicTheme ? color : rebrandColor\"\n [matTooltip]=\"\n label.length > 25 - (staticLabel.length < 4 ? staticLabel.length : 4)\n ? label + (staticLabel ? ' ' + staticLabel : '')\n : ''\n \"\n [matTooltipClass]=\"applicationTheme\"\n>\n <ng-container [ngSwitch]=\"variant\">\n <ng-container *ngSwitchCase=\"badgeVariant.PRIMARY\">\n <ui-icon\n *ngIf=\"icon\"\n [class.badge-icon]=\"!!label || !!staticLabel || !!trailingIcon\"\n [name]=\"icon\"\n [color]=\"resolvedIconColor\"\n ></ui-icon>\n </ng-container>\n <ng-container *ngSwitchCase=\"badgeVariant.PRIMARY_AI\">\n <ng-container [ngTemplateOutlet]=\"aiIconTpl\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"badgeVariant.SECONDARY_AI\">\n <ng-container [ngTemplateOutlet]=\"aiIconTpl\"></ng-container>\n </ng-container>\n <div\n *ngSwitchCase=\"badgeVariant.SECONDARY\"\n class=\"point\"\n [attr.color]=\"isClassicTheme ? color : rebrandColor\"\n ></div>\n <div *ngSwitchCase=\"badgeVariant.NOTIFICATION\" class=\"number-notification\">{{ notificationsAmount }}</div>\n </ng-container>\n <div\n class=\"label\"\n *ngIf=\"variant !== badgeVariant.NOTIFICATION\"\n [class.empty]=\"!label && !staticLabel\"\n [class.animated]=\"enableAnimation\"\n >\n {{\n label.length > 25 - (staticLabel.length < 4 ? staticLabel.length : 4) && truncateLabel\n ? (label | slice: 0 : 25 - (staticLabel.length < 4 ? staticLabel.length : 4)) + '...'\n : label\n }}\n </div>\n <span *ngIf=\"staticLabel && variant !== badgeVariant.NOTIFICATION\" class=\"static-label\">{{\n staticLabel | slice: 0 : 4\n }}</span>\n <ui-icon\n *ngIf=\"trailingIcon() && variant === badgeVariant.PRIMARY\"\n class=\"badge-icon-trailing\"\n [name]=\"trailingIcon()\"\n [color]=\"resolvedTrailingIconColor\"\n ></ui-icon>\n</div>\n\n<ng-template #aiIconTpl>\n <ui-icon class=\"badge-icon\" [name]=\"'Sparkle-in-line'\" [color]=\"'ai'\"></ui-icon>\n</ng-template>\n", styles: [".bg-teal-60b{background:#1c443c}.bg-teal-30b{background:#31766a}.bg-teal-default{background:#46a997}.bg-teal-30w{background:#7ec3b6}.bg-teal-60w{background:#b5ddd5}.bg-teal-secondary{background:#cbd6cb}.bg-teal-90w{background:#ecf6f5}.bg-petrol-60b{background:#102930}.bg-petrol-30b{background:#1b4754}.bg-petrol-default{background:#276678}.bg-petrol-30w{background:#6894a0}.bg-petrol-60w{background:#a9c2c9}.bg-petrol-secondary{background:#c8d7de}.bg-petrol-90w{background:#e9f0f1}.bg-error-60b{background:#513131}.bg-error-30b{background:#8e5655}.bg-error-60w{background:#e3c3c6}.bg-error-secondary{background:#f0dad9}.bg-error-default{background:#cb7b7a}.bg-warning-secondary{background:#f0d6bb}.bg-warning-default{background:#cca45f}.bg-black{background:#000}.bg-dark{background:#888}.bg-medium{background:#e0e0e0}.bg-grey{background:#ededed}.bg-light{background:#f6f6f6}.bg-white{background:#fff}.bg-box-shadow{background:#00000014}.bg-navigation-subtitle{background:#528593}.bgc-teal-60b{background-color:#1c443c}.bgc-teal-30b{background-color:#31766a}.bgc-teal-default{background-color:#46a997}.bgc-teal-30w{background-color:#7ec3b6}.bgc-teal-60w{background-color:#b5ddd5}.bgc-teal-secondary{background-color:#cbd6cb}.bgc-teal-90w{background-color:#ecf6f5}.bgc-petrol-60b{background-color:#102930}.bgc-petrol-30b{background-color:#1b4754}.bgc-petrol-default{background-color:#276678}.bgc-petrol-30w{background-color:#6894a0}.bgc-petrol-60w{background-color:#a9c2c9}.bgc-petrol-secondary{background-color:#c8d7de}.bgc-petrol-90w{background-color:#e9f0f1}.bgc-error-60b{background-color:#513131}.bgc-error-30b{background-color:#8e5655}.bgc-error-60w{background-color:#e3c3c6}.bgc-error-secondary{background-color:#f0dad9}.bgc-error-default{background-color:#cb7b7a}.bgc-warning-secondary{background-color:#f0d6bb}.bgc-warning-default{background-color:#cca45f}.bgc-black{background-color:#000}.bgc-dark{background-color:#888}.bgc-medium{background-color:#e0e0e0}.bgc-grey{background-color:#ededed}.bgc-light{background-color:#f6f6f6}.bgc-white{background-color:#fff}.bgc-box-shadow{background-color:#00000014}.bgc-navigation-subtitle{background-color:#528593}:host{display:block}:host .badge-container-primary,:host .badge-container-primary-ai,:host .badge-container-secondary,:host .badge-container-secondary-ai,:host .badge-container-notification{width:fit-content}:host .badge-container-primary,:host .badge-container-primary-ai,:host .badge-container-secondary,:host .badge-container-secondary-ai{height:24px;padding:0 8px;border-radius:21px;color:#fff;line-height:10px;transition:all .2s ease-out}:host .badge-container-primary .label,:host .badge-container-primary-ai .label,:host .badge-container-secondary .label,:host .badge-container-secondary-ai .label{font-size:12px;line-height:14px}:host .badge-container-primary .label.animated,:host .badge-container-primary-ai .label.animated,:host .badge-container-secondary .label.animated,:host .badge-container-secondary-ai .label.animated{display:inline-block;max-width:500px;opacity:1;overflow:hidden;white-space:nowrap;transition:max-width .25s ease-in-out,opacity .2s ease-in-out;will-change:max-width,opacity;contain:layout style}:host .badge-container-primary .label.empty,:host .badge-container-primary-ai .label.empty,:host .badge-container-secondary .label.empty,:host .badge-container-secondary-ai .label.empty{max-width:0;opacity:0}:host .badge-container-primary .static-label,:host .badge-container-primary-ai .static-label,:host .badge-container-secondary .static-label,:host .badge-container-secondary-ai .static-label{font-size:12px;line-height:14px;white-space:nowrap;flex-shrink:0;margin-left:2px}:host .badge-container-primary .badge-icon:not(:last-child),:host .badge-container-primary-ai .badge-icon:not(:last-child),:host .badge-container-secondary .badge-icon:not(:last-child),:host .badge-container-secondary-ai .badge-icon:not(:last-child){margin-right:8px}:host .badge-container-primary .badge-icon-trailing,:host .badge-container-primary-ai .badge-icon-trailing,:host .badge-container-secondary .badge-icon-trailing,:host .badge-container-secondary-ai .badge-icon-trailing{margin-left:8px}:host .badge-container-primary.no-label .badge-icon,:host .badge-container-primary-ai.no-label .badge-icon,:host .badge-container-secondary.no-label .badge-icon,:host .badge-container-secondary-ai.no-label .badge-icon{margin-right:0}:host .badge-container-secondary{padding:0}:host .badge-container-primary-ai.no-label{padding:4px}:host .badge-container-secondary .point,:host .badge-container-secondary-ai .point{border-radius:50%;padding:4px;margin-right:8px}:host .badge-container-secondary .label,:host .badge-container-secondary-ai .label{color:#000!important;width:100%}:host .badge-container-secondary[theme=dark],:host .badge-container-secondary[theme=light],:host .badge-container-secondary-ai[theme=dark],:host .badge-container-secondary-ai[theme=light]{color:#242424}:host .badge-container-secondary .badge-icon:not(:last-child),:host .badge-container-secondary-ai .badge-icon:not(:last-child){margin-right:4px}:host .badge-container-notification{min-width:20px;height:20px;border-radius:50%;color:#fff;line-height:10px}:host .badge-container-notification .label{font-size:12px}:host .badge-container-notification[theme=dark],:host .badge-container-notification[theme=light]{background:#242424!important;color:#fff!important;border-color:1px solid #ffffff}:host .badge{width:100%!important;max-width:fit-content!important}:host .badge .label{white-space:nowrap!important;overflow:hidden!important;text-overflow:ellipsis!important;box-sizing:border-box!important}.flex-center,:host .badge-container-primary,:host .badge-container-primary-ai,:host .badge-container-secondary,:host .badge-container-secondary-ai,:host .badge-container-notification{display:flex;align-items:center;justify-content:center}.background-colors[color=red],:host [color=red].badge-container-primary,:host [color=red].badge-container-primary-ai,:host .badge-container-secondary [color=red].point,:host .badge-container-secondary-ai [color=red].point,:host [color=red].badge-container-notification{background:#cb7b7a}.background-colors[color=grey-medium],:host [color=grey-medium].badge-container-primary,:host [color=grey-medium].badge-container-primary-ai,:host .badge-container-secondary [color=grey-medium].point,:host .badge-container-secondary-ai [color=grey-medium].point,:host [color=grey-medium].badge-container-notification{background:#e0e0e0;color:#000}.background-colors[color=teal],:host [color=teal].badge-container-primary,:host [color=teal].badge-container-primary-ai,:host .badge-container-secondary [color=teal].point,:host .badge-container-secondary-ai [color=teal].point,:host [color=teal].badge-container-notification{background:#46a997}.background-colors[color=yellow],:host [color=yellow].badge-container-primary,:host [color=yellow].badge-container-primary-ai,:host .badge-container-secondary [color=yellow].point,:host .badge-container-secondary-ai [color=yellow].point,:host [color=yellow].badge-container-notification{background:#cca45f}.background-colors[color=petrol],:host [color=petrol].badge-container-primary,:host [color=petrol].badge-container-primary-ai,:host .badge-container-secondary [color=petrol].point,:host .badge-container-secondary-ai [color=petrol].point,:host [color=petrol].badge-container-notification{background:#276678}.background-colors[color=teal-60w],:host [color=teal-60w].badge-container-primary,:host [color=teal-60w].badge-container-primary-ai,:host .badge-container-secondary [color=teal-60w].point,:host .badge-container-secondary-ai [color=teal-60w].point,:host [color=teal-60w].badge-container-notification{background:#b5ddd5;color:#000}.background-colors[color=petrol-90w],:host [color=petrol-90w].badge-container-primary,:host [color=petrol-90w].badge-container-primary-ai,:host .badge-container-secondary [color=petrol-90w].point,:host .badge-container-secondary-ai [color=petrol-90w].point,:host [color=petrol-90w].badge-container-notification{background:#e9f0f1;color:#000}.background-colors[color=petrol-60w],:host [color=petrol-60w].badge-container-primary,:host [color=petrol-60w].badge-container-primary-ai,:host .badge-container-secondary [color=petrol-60w].point,:host .badge-container-secondary-ai [color=petrol-60w].point,:host [color=petrol-60w].badge-container-notification{background:#a9c2c9;color:#000}.background-colors[color=grey-dark],:host [color=grey-dark].badge-container-primary,:host [color=grey-dark].badge-container-primary-ai,:host .badge-container-secondary [color=grey-dark].point,:host .badge-container-secondary-ai [color=grey-dark].point,:host [color=grey-dark].badge-container-notification{background:#888}.background-colors[color=success],:host [color=success].badge-container-primary,:host [color=success].badge-container-primary-ai,:host .badge-container-secondary [color=success].point,:host .badge-container-secondary-ai [color=success].point,:host [color=success].badge-container-notification{background:#d4f2c3;color:#242424}.background-colors[color=warning],:host [color=warning].badge-container-primary,:host [color=warning].badge-container-primary-ai,:host .badge-container-secondary [color=warning].point,:host .badge-container-secondary-ai [color=warning].point,:host [color=warning].badge-container-notification{background:#ffe1b3;color:#242424}.background-colors[color=negative],:host [color=negative].badge-container-primary,:host [color=negative].badge-container-primary-ai,:host .badge-container-secondary [color=negative].point,:host .badge-container-secondary-ai [color=negative].point,:host [color=negative].badge-container-notification{background:#ffac9a;color:#242424}.background-colors[color=info],:host [color=info].badge-container-primary,:host [color=info].badge-container-primary-ai,:host .badge-container-secondary [color=info].point,:host .badge-container-secondary-ai [color=info].point,:host [color=info].badge-container-notification{background:#d9e8ff;color:#242424}.background-colors[color=brand],:host [color=brand].badge-container-primary,:host [color=brand].badge-container-primary-ai,:host .badge-container-secondary [color=brand].point,:host .badge-container-secondary-ai [color=brand].point,:host [color=brand].badge-container-notification{background:#ffe6fa;color:#242424}.background-colors[color=neutral],:host [color=neutral].badge-container-primary,:host [color=neutral].badge-container-primary-ai,:host .badge-container-secondary [color=neutral].point,:host .badge-container-secondary-ai [color=neutral].point,:host [color=neutral].badge-container-notification{background:#e9e9e9;color:#242424}.background-colors[color=blue-20],:host [color=blue-20].badge-container-primary,:host [color=blue-20].badge-container-primary-ai,:host .badge-container-secondary [color=blue-20].point,:host .badge-container-secondary-ai [color=blue-20].point,:host [color=blue-20].badge-container-notification{background:#99c1fe;color:#242424}.background-colors[color=blue-30],:host [color=blue-30].badge-container-primary,:host [color=blue-30].badge-container-primary-ai,:host .badge-container-secondary [color=blue-30].point,:host .badge-container-secondary-ai [color=blue-30].point,:host [color=blue-30].badge-container-notification{background:#277cfd;color:#fff}.background-colors[color=blue-40],:host [color=blue-40].badge-container-primary,:host [color=blue-40].badge-container-primary-ai,:host .badge-container-secondary [color=blue-40].point,:host .badge-container-secondary-ai [color=blue-40].point,:host [color=blue-40].badge-container-notification{background:#0165fc;color:#fff}.background-colors[color=pink-30],:host [color=pink-30].badge-container-primary,:host [color=pink-30].badge-container-primary-ai,:host .badge-container-secondary [color=pink-30].point,:host .badge-container-secondary-ai [color=pink-30].point,:host [color=pink-30].badge-container-notification{background:#ffb3ee;color:#242424}.background-colors[color=blue-10],:host [color=blue-10].badge-container-primary,:host [color=blue-10].badge-container-primary-ai,:host .badge-container-secondary [color=blue-10].point,:host .badge-container-secondary-ai [color=blue-10].point,:host [color=blue-10].badge-container-notification{background:#d9e8ff;color:#242424}.background-colors[color=grey-30],:host [color=grey-30].badge-container-primary,:host [color=grey-30].badge-container-primary-ai,:host .badge-container-secondary [color=grey-30].point,:host .badge-container-secondary-ai [color=grey-30].point,:host [color=grey-30].badge-container-notification{background:#d3d3d3;color:#242424}.background-colors[color=grey-20],:host [color=grey-20].badge-container-primary,:host [color=grey-20].badge-container-primary-ai,:host .badge-container-secondary [color=grey-20].point,:host .badge-container-secondary-ai [color=grey-20].point,:host [color=grey-20].badge-container-notification{background:#e9e9e9;color:#242424}.background-colors[color=grey-10],:host [color=grey-10].badge-container-primary,:host [color=grey-10].badge-container-primary-ai,:host .badge-container-secondary [color=grey-10].point,:host .badge-container-secondary-ai [color=grey-10].point,:host [color=grey-10].badge-container-notification{background:#f4f4f4;color:#242424}\n"] }]
|
|
144
166
|
}], ctorParameters: () => [{ type: undefined, decorators: [{
|
|
145
167
|
type: Optional
|
|
146
168
|
}, {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"testgorilla-tgo-ui-components-badge.mjs","sources":["../../../components/badge/badge.model.ts","../../../components/badge/badge.component.ts","../../../components/badge/badge.component.html","../../../components/badge/badge.component.module.ts","../../../components/badge/testgorilla-tgo-ui-components-badge.ts"],"sourcesContent":["export type BadgeVariant = 'primary' | 'secondary' | 'notification' | 'primary-ai' | 'secondary-ai';\nexport type BadgeColor =\n | 'red'\n | 'grey-medium'\n | 'teal'\n | 'yellow'\n | 'petrol'\n | 'teal-60w'\n | 'petrol-90w'\n | 'petrol-60w'\n | 'grey-dark'\n | 'blue-20'\n | 'blue-40'\n | 'pink-30'\n | 'blue-10';\n\nexport enum BadgeColorEnum {\n RED = 'red',\n GREY_MEDIUM = 'grey-medium',\n TEAL = 'teal',\n YELLOW = 'yellow',\n PETROL = 'petrol',\n TEAL_60W = 'teal-60w',\n PETROL_90W = 'petrol-90w',\n PETROL_60W = 'petrol-60w',\n GREY_DARK = 'grey-dark',\n BLUE_20 = 'blue-20',\n BLUE_40 = 'blue-40',\n}\n\nexport type RebrandBadgeColor =\n | 'success'\n | 'warning'\n | 'negative'\n | 'info'\n | 'brand'\n | 'neutral'\n | 'blue-20'\n | 'blue-40'\n | 'pink-30'\n | 'blue-10'\n | 'grey-10'\n | 'grey-20'\n | 'grey-30';\n\nexport enum RebrandBadgeColorEnum {\n SUCCESS = 'success',\n WARNING = 'warning',\n NEGATIVE = 'negative',\n INFO = 'info',\n BRAND = 'brand',\n NEUTRAL = 'neutral',\n BLUE_40 = 'blue-40',\n BLUE_20 = 'blue-20',\n PINK_30 = 'pink-30',\n BLUE_10 = 'blue-10',\n GREY_30 = 'grey-30',\n GREY_20 = 'grey-20',\n GREY_10 = 'grey-10',\n}\n\nexport enum BadgeVariantEnum {\n PRIMARY = 'primary',\n PRIMARY_AI = 'primary-ai',\n SECONDARY = 'secondary',\n SECONDARY_AI = 'secondary-ai',\n NOTIFICATION = 'notification',\n}\n","import { Component, Inject, Input, Optional } from '@angular/core';\nimport { ApplicationTheme } from '@testgorilla/tgo-ui/components/core';\nimport { IconColor, IconName } from '@testgorilla/tgo-ui/components/icon';\nimport {\n BadgeColor,\n BadgeColorEnum,\n BadgeVariant,\n BadgeVariantEnum,\n RebrandBadgeColor,\n RebrandBadgeColorEnum,\n} from './badge.model';\n\n@Component({\n selector: 'ui-badge',\n templateUrl: './badge.component.html',\n styleUrls: ['./badge.component.scss'],\n standalone: false,\n})\nexport class BadgeComponent {\n /**\n * The label to be displayed on the badge.\n * @type {string}\n * @memberof BadgeComponent\n */\n @Input() label = '';\n\n /**\n * A static label always displayed after the main label, never truncated.\n * Intended for short suffixes (max 4 chars, e.g. \"100%\").\n * When the main label is truncated, the tooltip shows both labels in full.\n * @type {string}\n * @memberof BadgeComponent\n */\n @Input() staticLabel = '';\n\n /**\n * The icon name to be displayed on the badge.\n * @type {IconName}\n * @memberof BadgeComponent\n */\n @Input() icon: IconName = '';\n\n /**\n * The color of the badge. Defaults to 'petrol'.\n * @type {BadgeColor}\n * @memberof BadgeComponent\n */\n @Input() color: BadgeColor = 'petrol';\n\n /**\n * The variant of the badge. Defaults to 'primary'.\n * @type {BadgeVariant}\n * @memberof BadgeComponent\n */\n @Input() variant: BadgeVariant = 'primary';\n\n /**\n * The amount of notifications to be displayed on the badge.\n * @type {number}\n * @memberof BadgeComponent\n */\n @Input() notificationsAmount = 0;\n\n /**\n *\n * Defines the application theme\n *\n * @type {ApplicationTheme}\n * @memberof BadgeComponent\n */\n @Input() applicationTheme: ApplicationTheme = 'light';\n\n /**\n * The color of the badge on new theme. Defaults to 'brand'.\n * @type {RebrandBadgeColor}\n * @memberof BadgeComponent\n */\n @Input() rebrandColor: RebrandBadgeColor = 'brand';\n\n @Input() truncateLabel = true;\n\n /**\n * Whether to enable the animation when label changes from empty to having content.\n * @type {boolean}\n * @memberof BadgeComponent\n */\n @Input() enableAnimation = false;\n\n protected badgeVariant = BadgeVariantEnum;\n private darkColors: string[] = [\n BadgeColorEnum.GREY_MEDIUM,\n BadgeColorEnum.PETROL_90W,\n BadgeColorEnum.TEAL_60W,\n BadgeColorEnum.PETROL_60W,\n RebrandBadgeColorEnum.SUCCESS,\n RebrandBadgeColorEnum.INFO,\n RebrandBadgeColorEnum.BRAND,\n RebrandBadgeColorEnum.NEUTRAL,\n RebrandBadgeColorEnum.NEGATIVE,\n RebrandBadgeColorEnum.WARNING,\n RebrandBadgeColorEnum.BLUE_20,\n RebrandBadgeColorEnum.PINK_30,\n RebrandBadgeColorEnum.BLUE_10,\n RebrandBadgeColorEnum.GREY_20,\n ];\n\n constructor(\n @Optional() @Inject('CANOPYUI_DEFAULT_APPLICATION_THEME') private readonly defaultAppTheme: ApplicationTheme\n ) {\n if (defaultAppTheme) {\n this.applicationTheme = defaultAppTheme;\n }\n }\n\n protected get iconColor(): IconColor {\n return this.darkColors.includes(this.isClassicTheme ? this.color : this.rebrandColor) ? 'black' : 'white';\n }\n\n protected get isClassicTheme(): boolean {\n return this.applicationTheme === 'classic';\n }\n}\n","<div\n [class]=\"'badge badge-container-' + variant\"\n [class.no-label]=\"!label && !staticLabel\"\n [attr.aria-label]=\"label + (staticLabel ? ' ' + staticLabel : '')\"\n [attr.theme]=\"applicationTheme\"\n [attr.color]=\"isClassicTheme ? color : rebrandColor\"\n [matTooltip]=\"\n label.length > 25 - (staticLabel.length < 4 ? staticLabel.length : 4)\n ? label + (staticLabel ? ' ' + staticLabel : '')\n : ''\n \"\n [matTooltipClass]=\"applicationTheme\"\n>\n <ng-container [ngSwitch]=\"variant\">\n <ng-container *ngSwitchCase=\"badgeVariant.PRIMARY\">\n <ui-icon *ngIf=\"icon\" [class.badge-icon]=\"!!label\" [name]=\"icon\" [color]=\"iconColor\"></ui-icon>\n </ng-container>\n <ng-container *ngSwitchCase=\"badgeVariant.PRIMARY_AI\">\n <ng-container [ngTemplateOutlet]=\"aiIconTpl\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"badgeVariant.SECONDARY_AI\">\n <ng-container [ngTemplateOutlet]=\"aiIconTpl\"></ng-container>\n </ng-container>\n <div\n *ngSwitchCase=\"badgeVariant.SECONDARY\"\n class=\"point\"\n [attr.color]=\"isClassicTheme ? color : rebrandColor\"\n ></div>\n <div *ngSwitchCase=\"badgeVariant.NOTIFICATION\" class=\"number-notification\">{{ notificationsAmount }}</div>\n </ng-container>\n <div\n class=\"label\"\n *ngIf=\"variant !== badgeVariant.NOTIFICATION\"\n [class.empty]=\"!label && !staticLabel\"\n [class.animated]=\"enableAnimation\"\n >\n {{\n label.length > 25 - (staticLabel.length < 4 ? staticLabel.length : 4) && truncateLabel\n ? (label | slice: 0 : 25 - (staticLabel.length < 4 ? staticLabel.length : 4)) + '...'\n : label\n }}\n </div>\n <span *ngIf=\"staticLabel && variant !== badgeVariant.NOTIFICATION\" class=\"static-label\">{{\n staticLabel | slice: 0 : 4\n }}</span>\n</div>\n\n<ng-template #aiIconTpl>\n <ui-icon class=\"badge-icon\" [name]=\"'Sparkle-in-line'\" [color]=\"'ai'\"></ui-icon>\n</ng-template>\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { BadgeComponent } from './badge.component';\nimport { IconComponentModule } from '@testgorilla/tgo-ui/components/icon';\nimport { MatTooltipModule } from '@angular/material/tooltip';\n\n@NgModule({\n declarations: [BadgeComponent],\n imports: [CommonModule, IconComponentModule, MatTooltipModule],\n exports: [BadgeComponent],\n})\nexport class BadgeComponentModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;IAgBY;AAAZ,CAAA,UAAY,cAAc,EAAA;AACxB,IAAA,cAAA,CAAA,KAAA,CAAA,GAAA,KAAW;AACX,IAAA,cAAA,CAAA,aAAA,CAAA,GAAA,aAA2B;AAC3B,IAAA,cAAA,CAAA,MAAA,CAAA,GAAA,MAAa;AACb,IAAA,cAAA,CAAA,QAAA,CAAA,GAAA,QAAiB;AACjB,IAAA,cAAA,CAAA,QAAA,CAAA,GAAA,QAAiB;AACjB,IAAA,cAAA,CAAA,UAAA,CAAA,GAAA,UAAqB;AACrB,IAAA,cAAA,CAAA,YAAA,CAAA,GAAA,YAAyB;AACzB,IAAA,cAAA,CAAA,YAAA,CAAA,GAAA,YAAyB;AACzB,IAAA,cAAA,CAAA,WAAA,CAAA,GAAA,WAAuB;AACvB,IAAA,cAAA,CAAA,SAAA,CAAA,GAAA,SAAmB;AACnB,IAAA,cAAA,CAAA,SAAA,CAAA,GAAA,SAAmB;AACrB,CAAC,EAZW,cAAc,KAAd,cAAc,GAAA,EAAA,CAAA,CAAA;IA6Bd;AAAZ,CAAA,UAAY,qBAAqB,EAAA;AAC/B,IAAA,qBAAA,CAAA,SAAA,CAAA,GAAA,SAAmB;AACnB,IAAA,qBAAA,CAAA,SAAA,CAAA,GAAA,SAAmB;AACnB,IAAA,qBAAA,CAAA,UAAA,CAAA,GAAA,UAAqB;AACrB,IAAA,qBAAA,CAAA,MAAA,CAAA,GAAA,MAAa;AACb,IAAA,qBAAA,CAAA,OAAA,CAAA,GAAA,OAAe;AACf,IAAA,qBAAA,CAAA,SAAA,CAAA,GAAA,SAAmB;AACnB,IAAA,qBAAA,CAAA,SAAA,CAAA,GAAA,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AA,SAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,oBAAoB,EAAA,OAAA,EAAA,CAHrB,YAAY,EAAE,mBAAmB,EAAE,gBAAgB,CAAA,EAAA,CAAA,CAAA;;4FAGlD,oBAAoB,EAAA,UAAA,EAAA,CAAA;kBALhC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,YAAY,EAAE,CAAC,cAAc,CAAC;AAC9B,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,mBAAmB,EAAE,gBAAgB,CAAC;oBAC9D,OAAO,EAAE,CAAC,cAAc,CAAC;AAC1B,iBAAA;;;ACVD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"testgorilla-tgo-ui-components-badge.mjs","sources":["../../../components/badge/badge.model.ts","../../../components/badge/badge.component.ts","../../../components/badge/badge.component.html","../../../components/badge/badge.component.module.ts","../../../components/badge/testgorilla-tgo-ui-components-badge.ts"],"sourcesContent":["export type BadgeVariant = 'primary' | 'secondary' | 'notification' | 'primary-ai' | 'secondary-ai';\nexport type BadgeColor =\n | 'red'\n | 'grey-medium'\n | 'teal'\n | 'yellow'\n | 'petrol'\n | 'teal-60w'\n | 'petrol-90w'\n | 'petrol-60w'\n | 'grey-dark'\n | 'blue-20'\n | 'blue-40'\n | 'pink-30'\n | 'blue-10';\n\nexport enum BadgeColorEnum {\n RED = 'red',\n GREY_MEDIUM = 'grey-medium',\n TEAL = 'teal',\n YELLOW = 'yellow',\n PETROL = 'petrol',\n TEAL_60W = 'teal-60w',\n PETROL_90W = 'petrol-90w',\n PETROL_60W = 'petrol-60w',\n GREY_DARK = 'grey-dark',\n BLUE_20 = 'blue-20',\n BLUE_40 = 'blue-40',\n}\n\nexport type RebrandBadgeColor =\n | 'success'\n | 'warning'\n | 'negative'\n | 'info'\n | 'brand'\n | 'neutral'\n | 'blue-20'\n | 'blue-40'\n | 'pink-30'\n | 'blue-10'\n | 'grey-10'\n | 'grey-20'\n | 'grey-30';\n\nexport enum RebrandBadgeColorEnum {\n SUCCESS = 'success',\n WARNING = 'warning',\n NEGATIVE = 'negative',\n INFO = 'info',\n BRAND = 'brand',\n NEUTRAL = 'neutral',\n BLUE_40 = 'blue-40',\n BLUE_20 = 'blue-20',\n PINK_30 = 'pink-30',\n BLUE_10 = 'blue-10',\n GREY_30 = 'grey-30',\n GREY_20 = 'grey-20',\n GREY_10 = 'grey-10',\n}\n\nexport enum BadgeVariantEnum {\n PRIMARY = 'primary',\n PRIMARY_AI = 'primary-ai',\n SECONDARY = 'secondary',\n SECONDARY_AI = 'secondary-ai',\n NOTIFICATION = 'notification',\n}\n","import { Component, Inject, Input, Optional, input } from '@angular/core';\nimport { ApplicationTheme } from '@testgorilla/tgo-ui/components/core';\nimport { IconColor, IconName } from '@testgorilla/tgo-ui/components/icon';\nimport {\n BadgeColor,\n BadgeColorEnum,\n BadgeVariant,\n BadgeVariantEnum,\n RebrandBadgeColor,\n RebrandBadgeColorEnum,\n} from './badge.model';\n\n@Component({\n selector: 'ui-badge',\n templateUrl: './badge.component.html',\n styleUrls: ['./badge.component.scss'],\n standalone: false,\n})\nexport class BadgeComponent {\n /**\n * The label to be displayed on the badge.\n * @type {string}\n * @memberof BadgeComponent\n */\n @Input() label = '';\n\n /**\n * A static label always displayed after the main label, never truncated.\n * Intended for short suffixes (max 4 chars, e.g. \"100%\").\n * When the main label is truncated, the tooltip shows both labels in full.\n * @type {string}\n * @memberof BadgeComponent\n */\n @Input() staticLabel = '';\n\n /**\n * The icon name to be displayed on the badge.\n * @type {IconName}\n * @memberof BadgeComponent\n */\n @Input() icon: IconName = '';\n\n /**\n * Override color for the leading icon. Accepts any value the `ui-icon`\n * `color` input accepts (named token, hex, or CSS custom property).\n * When unset, falls back to the auto-derived color based on the badge background.\n */\n iconColor = input<string | undefined>(undefined);\n\n /**\n * Optional trailing icon, rendered after the label/static label on the primary variant.\n */\n trailingIcon = input<IconName>('');\n\n /**\n * Override color for the trailing icon. Accepts any value the `ui-icon`\n * `color` input accepts (named token, hex, or CSS custom property).\n * When unset, falls back to the auto-derived color based on the badge background.\n */\n trailingIconColor = input<string | undefined>(undefined);\n\n /**\n * The color of the badge. Defaults to 'petrol'.\n * @type {BadgeColor}\n * @memberof BadgeComponent\n */\n @Input() color: BadgeColor = 'petrol';\n\n /**\n * The variant of the badge. Defaults to 'primary'.\n * @type {BadgeVariant}\n * @memberof BadgeComponent\n */\n @Input() variant: BadgeVariant = 'primary';\n\n /**\n * The amount of notifications to be displayed on the badge.\n * @type {number}\n * @memberof BadgeComponent\n */\n @Input() notificationsAmount = 0;\n\n /**\n *\n * Defines the application theme\n *\n * @type {ApplicationTheme}\n * @memberof BadgeComponent\n */\n @Input() applicationTheme: ApplicationTheme = 'light';\n\n /**\n * The color of the badge on new theme. Defaults to 'brand'.\n * @type {RebrandBadgeColor}\n * @memberof BadgeComponent\n */\n @Input() rebrandColor: RebrandBadgeColor = 'brand';\n\n @Input() truncateLabel = true;\n\n /**\n * Whether to enable the animation when label changes from empty to having content.\n * @type {boolean}\n * @memberof BadgeComponent\n */\n @Input() enableAnimation = false;\n\n protected badgeVariant = BadgeVariantEnum;\n private darkColors: string[] = [\n BadgeColorEnum.GREY_MEDIUM,\n BadgeColorEnum.PETROL_90W,\n BadgeColorEnum.TEAL_60W,\n BadgeColorEnum.PETROL_60W,\n RebrandBadgeColorEnum.SUCCESS,\n RebrandBadgeColorEnum.INFO,\n RebrandBadgeColorEnum.BRAND,\n RebrandBadgeColorEnum.NEUTRAL,\n RebrandBadgeColorEnum.NEGATIVE,\n RebrandBadgeColorEnum.WARNING,\n RebrandBadgeColorEnum.BLUE_20,\n RebrandBadgeColorEnum.PINK_30,\n RebrandBadgeColorEnum.BLUE_10,\n RebrandBadgeColorEnum.GREY_20,\n ];\n\n constructor(\n @Optional() @Inject('CANOPYUI_DEFAULT_APPLICATION_THEME') private readonly defaultAppTheme: ApplicationTheme\n ) {\n if (defaultAppTheme) {\n this.applicationTheme = defaultAppTheme;\n }\n }\n\n protected get autoIconColor(): IconColor {\n return this.darkColors.includes(this.isClassicTheme ? this.color : this.rebrandColor) ? 'black' : 'white';\n }\n\n protected get resolvedIconColor(): IconColor {\n return this.iconColor() ?? this.autoIconColor;\n }\n\n protected get resolvedTrailingIconColor(): IconColor {\n return this.trailingIconColor() ?? this.autoIconColor;\n }\n\n protected get isClassicTheme(): boolean {\n return this.applicationTheme === 'classic';\n }\n}\n","<div\n [class]=\"'badge badge-container-' + variant\"\n [class.no-label]=\"!label && !staticLabel && !trailingIcon()\"\n [attr.aria-label]=\"label + (staticLabel ? ' ' + staticLabel : '')\"\n [attr.theme]=\"applicationTheme\"\n [attr.color]=\"isClassicTheme ? color : rebrandColor\"\n [matTooltip]=\"\n label.length > 25 - (staticLabel.length < 4 ? staticLabel.length : 4)\n ? label + (staticLabel ? ' ' + staticLabel : '')\n : ''\n \"\n [matTooltipClass]=\"applicationTheme\"\n>\n <ng-container [ngSwitch]=\"variant\">\n <ng-container *ngSwitchCase=\"badgeVariant.PRIMARY\">\n <ui-icon\n *ngIf=\"icon\"\n [class.badge-icon]=\"!!label || !!staticLabel || !!trailingIcon\"\n [name]=\"icon\"\n [color]=\"resolvedIconColor\"\n ></ui-icon>\n </ng-container>\n <ng-container *ngSwitchCase=\"badgeVariant.PRIMARY_AI\">\n <ng-container [ngTemplateOutlet]=\"aiIconTpl\"></ng-container>\n </ng-container>\n <ng-container *ngSwitchCase=\"badgeVariant.SECONDARY_AI\">\n <ng-container [ngTemplateOutlet]=\"aiIconTpl\"></ng-container>\n </ng-container>\n <div\n *ngSwitchCase=\"badgeVariant.SECONDARY\"\n class=\"point\"\n [attr.color]=\"isClassicTheme ? color : rebrandColor\"\n ></div>\n <div *ngSwitchCase=\"badgeVariant.NOTIFICATION\" class=\"number-notification\">{{ notificationsAmount }}</div>\n </ng-container>\n <div\n class=\"label\"\n *ngIf=\"variant !== badgeVariant.NOTIFICATION\"\n [class.empty]=\"!label && !staticLabel\"\n [class.animated]=\"enableAnimation\"\n >\n {{\n label.length > 25 - (staticLabel.length < 4 ? staticLabel.length : 4) && truncateLabel\n ? (label | slice: 0 : 25 - (staticLabel.length < 4 ? staticLabel.length : 4)) + '...'\n : label\n }}\n </div>\n <span *ngIf=\"staticLabel && variant !== badgeVariant.NOTIFICATION\" class=\"static-label\">{{\n staticLabel | slice: 0 : 4\n }}</span>\n <ui-icon\n *ngIf=\"trailingIcon() && variant === badgeVariant.PRIMARY\"\n class=\"badge-icon-trailing\"\n [name]=\"trailingIcon()\"\n [color]=\"resolvedTrailingIconColor\"\n ></ui-icon>\n</div>\n\n<ng-template #aiIconTpl>\n <ui-icon class=\"badge-icon\" [name]=\"'Sparkle-in-line'\" [color]=\"'ai'\"></ui-icon>\n</ng-template>\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { BadgeComponent } from './badge.component';\nimport { IconComponentModule } from '@testgorilla/tgo-ui/components/icon';\nimport { MatTooltipModule } from '@angular/material/tooltip';\n\n@NgModule({\n declarations: [BadgeComponent],\n imports: [CommonModule, IconComponentModule, MatTooltipModule],\n exports: [BadgeComponent],\n})\nexport class BadgeComponentModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;IAgBY;AAAZ,CAAA,UAAY,cAAc,EAAA;AACxB,IAAA,cAAA,CAAA,KAAA,CAAA,GAAA,KAAW;AACX,IAAA,cAAA,CAAA,aAAA,CAAA,GAAA,aAA2B;AAC3B,IAAA,cAAA,CAAA,MAAA,CAAA,GAAA,MAAa;AACb,IAAA,cAAA,CAAA,QAAA,CAAA,GAAA,QAAiB;AACjB,IAAA,cAAA,CAAA,QAAA,CAAA,GAAA,QAAiB;AACjB,IAAA,cAAA,CAAA,UAAA,CAAA,GAAA,UAAqB;AACrB,IAAA,cAAA,CAAA,YAAA,CAAA,GAAA,YAAyB;AACzB,IAAA,cAAA,CAAA,YAAA,CAAA,GAAA,YAAyB;AACzB,IAAA,cAAA,CAAA,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;oBACR,YAAY,EAAE,CAAC,cAAc,CAAC;AAC9B,oBAAA,OAAO,EAAE,CAAC,YAAY,EAAE,mBAAmB,EAAE,gBAAgB,CAAC;oBAC9D,OAAO,EAAE,CAAC,cAAc,CAAC;AAC1B,iBAAA;;;ACVD;;AAEG;;;;"}
|
|
@@ -193,7 +193,7 @@ class BreadcrumbComponent {
|
|
|
193
193
|
this.resizeObserver.observe(this.breadcrumbContainer.nativeElement);
|
|
194
194
|
}
|
|
195
195
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: BreadcrumbComponent, deps: [{ token: i0.Injector }], target: i0.ɵɵFactoryTarget.Component }); }
|
|
196
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.20", type: BreadcrumbComponent, isStandalone: false, selector: "ui-breadcrumb", inputs: { size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: false, transformFunction: null }, applicationTheme: { classPropertyName: "applicationTheme", publicName: "applicationTheme", isSignal: true, isRequired: false, transformFunction: null }, includeBackButton: { classPropertyName: "includeBackButton", publicName: "includeBackButton", isSignal: true, isRequired: false, transformFunction: null }, isLoading: { classPropertyName: "isLoading", publicName: "isLoading", isSignal: true, isRequired: false, transformFunction: null }, numberOfLoadingItems: { classPropertyName: "numberOfLoadingItems", publicName: "numberOfLoadingItems", isSignal: true, isRequired: false, transformFunction: null }, maxItemLength: { classPropertyName: "maxItemLength", publicName: "maxItemLength", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { selectItem: "selectItem", backButtonClickEvent: "backButtonClickEvent" }, viewQueries: [{ propertyName: "breadcrumbContainer", first: true, predicate: ["breadcrumbContainer"], descendants: true }], ngImport: i0, template: "@if (!isLoading()) {\n <div class=\"breadcrumb\" [attr.theme]=\"applicationTheme()\" #breadcrumbContainer [class]=\"'breadcrumb-' + size()\">\n @if (includeBackButton()) {\n <ui-button\n [variant]=\"'icon-button'\"\n [tooltip]=\"('COMMON.BACK' | uiTranslate | async)!\"\n [iconName]=\"'Arrow-chevron-left-filled'\"\n (buttonClickEvent)=\"backButtonClickEvent.emit($event)\"\n ></ui-button>\n }\n @if (isOverflowing()) {\n <ui-overflow-menu\n [applicationTheme]=\"applicationTheme()\"\n [contentTemplateRef]=\"overflowMenu\"\n [buttons]=\"overflowButtonItems()\"\n [matTooltip]=\"('COMMON.OPTIONS' | uiTranslate | async)!\"\n [matTooltipClass]=\"applicationTheme()\"\n [isDynamicMenu]=\"true\"\n (selectItem)=\"selectItem.emit($event)\"\n class=\"breadcrumb-overflow-menu\"\n ></ui-overflow-menu>\n <ui-icon name=\"Arrow-chevron-right-filled\" [applicationTheme]=\"applicationTheme()\" color=\"gray\"></ui-icon>\n }\n @for (item of visibleItems(); track item.value) {\n @if (!$last) {\n <span\n class=\"breadcrumb-item\"\n tabindex=\"0\"\n [matTooltip]=\"item.label.length > maxItemLength() ? item.label : ''\"\n [matTooltipClass]=\"applicationTheme()\"\n [attr.aria-label]=\"item.label\"\n (click)=\"selectItem.emit(item.value)\"\n (keydown.enter)=\"selectItem.emit(item.value)\"\n >\n {{ item.label | truncate: maxItemLength() : '...' }}\n </span>\n <ui-icon name=\"Arrow-chevron-right-filled\" [applicationTheme]=\"applicationTheme()\" color=\"gray\"></ui-icon>\n } @else {\n <strong\n class=\"breadcrumb-item-active\"\n tabindex=\"0\"\n [matTooltip]=\"shouldTruncateLastItem() ? item.label : ''\"\n [matTooltipClass]=\"applicationTheme()\"\n [class.breadcrumb-item-active-truncated]=\"shouldTruncateLastItem()\"\n [attr.aria-label]=\"item.label\"\n [attr.aria-current]=\"'page'\"\n (click)=\"selectItem.emit(item.value)\"\n (keydown.enter)=\"selectItem.emit(item.value)\"\n >\n {{ item.label }}\n </strong>\n }\n }\n </div>\n} @else {\n <div class=\"breadcrumb\">\n @for (i of loadingItems(); track $index) {\n <ui-skeleton count=\"1\" [theme]=\"{ width: '160px', margin: '10px 0 0' }\"></ui-skeleton>\n @if ($index !== numberOfLoadingItems() - 1) {\n <ui-icon name=\"Arrow-chevron-right-filled\" [applicationTheme]=\"applicationTheme()\" color=\"gray\"></ui-icon>\n }\n }\n </div>\n}\n<ng-template #overflowMenu>\n <div class=\"breadcrumb-item breadcrumb-overflow\" [class]=\"'breadcrumb-' + size()\">...</div>\n</ng-template>\n", styles: [".bg-teal-60b{background:#1c443c}.bg-teal-30b{background:#31766a}.bg-teal-default{background:#46a997}.bg-teal-30w{background:#7ec3b6}.bg-teal-60w{background:#b5ddd5}.bg-teal-secondary{background:#cbd6cb}.bg-teal-90w{background:#ecf6f5}.bg-petrol-60b{background:#102930}.bg-petrol-30b{background:#1b4754}.bg-petrol-default{background:#276678}.bg-petrol-30w{background:#6894a0}.bg-petrol-60w{background:#a9c2c9}.bg-petrol-secondary{background:#c8d7de}.bg-petrol-90w{background:#e9f0f1}.bg-error-60b{background:#513131}.bg-error-30b{background:#8e5655}.bg-error-60w{background:#e3c3c6}.bg-error-secondary{background:#f0dad9}.bg-error-default{background:#cb7b7a}.bg-warning-secondary{background:#f0d6bb}.bg-warning-default{background:#cca45f}.bg-black{background:#000}.bg-dark{background:#888}.bg-medium{background:#e0e0e0}.bg-grey{background:#ededed}.bg-light{background:#f6f6f6}.bg-white{background:#fff}.bg-box-shadow{background:#00000014}.bg-navigation-subtitle{background:#528593}.bgc-teal-60b{background-color:#1c443c}.bgc-teal-30b{background-color:#31766a}.bgc-teal-default{background-color:#46a997}.bgc-teal-30w{background-color:#7ec3b6}.bgc-teal-60w{background-color:#b5ddd5}.bgc-teal-secondary{background-color:#cbd6cb}.bgc-teal-90w{background-color:#ecf6f5}.bgc-petrol-60b{background-color:#102930}.bgc-petrol-30b{background-color:#1b4754}.bgc-petrol-default{background-color:#276678}.bgc-petrol-30w{background-color:#6894a0}.bgc-petrol-60w{background-color:#a9c2c9}.bgc-petrol-secondary{background-color:#c8d7de}.bgc-petrol-90w{background-color:#e9f0f1}.bgc-error-60b{background-color:#513131}.bgc-error-30b{background-color:#8e5655}.bgc-error-60w{background-color:#e3c3c6}.bgc-error-secondary{background-color:#f0dad9}.bgc-error-default{background-color:#cb7b7a}.bgc-warning-secondary{background-color:#f0d6bb}.bgc-warning-default{background-color:#cca45f}.bgc-black{background-color:#000}.bgc-dark{background-color:#888}.bgc-medium{background-color:#e0e0e0}.bgc-grey{background-color:#ededed}.bgc-light{background-color:#f6f6f6}.bgc-white{background-color:#fff}.bgc-box-shadow{background-color:#00000014}.bgc-navigation-subtitle{background-color:#528593}:host{min-width:0}:host .breadcrumb{display:flex;align-items:center;gap:4px;color:#666}:host .breadcrumb .breadcrumb-item{text-decoration:underline;cursor:pointer;transition:color .15s ease,transform .1s ease;white-space:nowrap}:host .breadcrumb .breadcrumb-item:hover{color:#919191}:host .breadcrumb .breadcrumb-item:active{transform:scale(.98);color:#919191}:host .breadcrumb .breadcrumb-item:focus-visible{outline:2px solid #242424;outline-offset:4px;border-radius:1px}:host .breadcrumb.breadcrumb-small{font-size:14px;line-height:22px}:host .breadcrumb.breadcrumb-medium{font-size:20px;line-height:26px}:host .breadcrumb.breadcrumb-large{font-size:32px;line-height:48px}:host .breadcrumb.breadcrumb-large .breadcrumb-item:focus-visible{outline-offset:8px}:host .breadcrumb.breadcrumb-large .breadcrumb-item-active{font-weight:900!important}:host .breadcrumb.breadcrumb-large .breadcrumb-item-active:focus-visible{outline-offset:8px}:host .breadcrumb .breadcrumb-item-active{color:#242424;white-space:nowrap}:host .breadcrumb .breadcrumb-item-active.breadcrumb-item-active-truncated{text-overflow:ellipsis;overflow:hidden}:host .breadcrumb .breadcrumb-item-active:focus-visible{outline:2px solid #242424;outline-offset:4px;border-radius:1px}:host .breadcrumb .breadcrumb-overflow-menu ::ng-deep .overflow-menu-container .mat-mdc-menu-trigger{min-width:0}:host .breadcrumb-overflow{cursor:pointer;color:#666}:host .breadcrumb-overflow:active{transform:scale(.98);color:#919191}:host .breadcrumb-overflow.breadcrumb-small{font-size:14px;line-height:22px}:host .breadcrumb-overflow.breadcrumb-medium{font-size:20px;line-height:26px}:host .breadcrumb-overflow.breadcrumb-large{font-size:32px;line-height:48px}\n"], dependencies: [{ kind: "component", type: i1.IconComponent, selector: "ui-icon", inputs: ["size", "cssClass", "name", "color", "filled", "toggleIconStyle", "applicationTheme", "useFullIconName"] }, { kind: "directive", type: i2.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: i3.OverflowMenuComponent, selector: "ui-overflow-menu", inputs: ["buttons", "iconTrigger", "menuLabel", "applicationTheme", "ariaLabel", "ariaRequired", "describedby", "contentTemplateRef", "buttonVariant", "buttonSize", "menuConfig", "isDynamicMenu", "withRemovableOption"], outputs: ["selectItem", "menuOpened", "menuClosed"] }, { kind: "component", type: i4.ButtonComponent, selector: "ui-button", inputs: ["size", "variant", "label", "iconPosition", "justIcon", "iconName", "disabled", "loading", "fullWidth", "url", "urlTarget", "value", "tooltip", "isPremium", "type", "companyColor", "buttonBadgeConfig", "applicationTheme", "disabledScaleOnClick", "ariaLabel", "ariaRequired", "ariaLabelledby", "ariaDescribedby", "preventDefault", "hasBackground", "tooltipPosition", "role", "iconFilled"], outputs: ["buttonClickEvent", "buttonHoverEvent"] }, { kind: "component", type: i5.SkeletonComponent, selector: "ui-skeleton", inputs: ["count", "theme", "appearance", "isAiTheme", "applicationTheme"] }, { kind: "pipe", type: i6.AsyncPipe, name: "async" }, { kind: "pipe", type: i7.UiTranslatePipe, name: "uiTranslate" }, { kind: "pipe", type: i7.TruncatePipe, name: "truncate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
196
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.20", type: BreadcrumbComponent, isStandalone: false, selector: "ui-breadcrumb", inputs: { size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: false, transformFunction: null }, applicationTheme: { classPropertyName: "applicationTheme", publicName: "applicationTheme", isSignal: true, isRequired: false, transformFunction: null }, includeBackButton: { classPropertyName: "includeBackButton", publicName: "includeBackButton", isSignal: true, isRequired: false, transformFunction: null }, isLoading: { classPropertyName: "isLoading", publicName: "isLoading", isSignal: true, isRequired: false, transformFunction: null }, numberOfLoadingItems: { classPropertyName: "numberOfLoadingItems", publicName: "numberOfLoadingItems", isSignal: true, isRequired: false, transformFunction: null }, maxItemLength: { classPropertyName: "maxItemLength", publicName: "maxItemLength", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { selectItem: "selectItem", backButtonClickEvent: "backButtonClickEvent" }, viewQueries: [{ propertyName: "breadcrumbContainer", first: true, predicate: ["breadcrumbContainer"], descendants: true }], ngImport: i0, template: "@if (!isLoading()) {\n <div class=\"breadcrumb\" [attr.theme]=\"applicationTheme()\" #breadcrumbContainer [class]=\"'breadcrumb-' + size()\">\n @if (includeBackButton()) {\n <ui-button\n [variant]=\"'icon-button'\"\n [tooltip]=\"('COMMON.BACK' | uiTranslate | async)!\"\n [iconName]=\"'Arrow-chevron-left-filled'\"\n (buttonClickEvent)=\"backButtonClickEvent.emit($event)\"\n ></ui-button>\n }\n @if (isOverflowing()) {\n <ui-overflow-menu\n [applicationTheme]=\"applicationTheme()\"\n [contentTemplateRef]=\"overflowMenu\"\n [buttons]=\"overflowButtonItems()\"\n [matTooltip]=\"('COMMON.OPTIONS' | uiTranslate | async)!\"\n [matTooltipClass]=\"applicationTheme()\"\n [isDynamicMenu]=\"true\"\n (selectItem)=\"selectItem.emit($event)\"\n class=\"breadcrumb-overflow-menu\"\n ></ui-overflow-menu>\n <ui-icon name=\"Arrow-chevron-right-filled\" [applicationTheme]=\"applicationTheme()\" color=\"gray\"></ui-icon>\n }\n @for (item of visibleItems(); track item.value) {\n @if (!$last) {\n <span\n class=\"breadcrumb-item\"\n tabindex=\"0\"\n [matTooltip]=\"item.label.length > maxItemLength() ? item.label : ''\"\n [matTooltipClass]=\"applicationTheme()\"\n [attr.aria-label]=\"item.label\"\n (click)=\"selectItem.emit(item.value)\"\n (keydown.enter)=\"selectItem.emit(item.value)\"\n >\n {{ item.label | truncate: maxItemLength() : '...' }}\n </span>\n <ui-icon name=\"Arrow-chevron-right-filled\" [applicationTheme]=\"applicationTheme()\" color=\"gray\"></ui-icon>\n } @else {\n <strong\n class=\"breadcrumb-item-active\"\n tabindex=\"0\"\n [matTooltip]=\"shouldTruncateLastItem() ? item.label : ''\"\n [matTooltipClass]=\"applicationTheme()\"\n [class.breadcrumb-item-active-truncated]=\"shouldTruncateLastItem()\"\n [attr.aria-label]=\"item.label\"\n [attr.aria-current]=\"'page'\"\n (click)=\"selectItem.emit(item.value)\"\n (keydown.enter)=\"selectItem.emit(item.value)\"\n >\n {{ item.label }}\n </strong>\n }\n }\n </div>\n} @else {\n <div class=\"breadcrumb\">\n @for (i of loadingItems(); track $index) {\n <ui-skeleton count=\"1\" [theme]=\"{ width: '160px', margin: '10px 0 0' }\"></ui-skeleton>\n @if ($index !== numberOfLoadingItems() - 1) {\n <ui-icon name=\"Arrow-chevron-right-filled\" [applicationTheme]=\"applicationTheme()\" color=\"gray\"></ui-icon>\n }\n }\n </div>\n}\n<ng-template #overflowMenu>\n <div class=\"breadcrumb-item breadcrumb-overflow\" [class]=\"'breadcrumb-' + size()\">...</div>\n</ng-template>\n", styles: [".bg-teal-60b{background:#1c443c}.bg-teal-30b{background:#31766a}.bg-teal-default{background:#46a997}.bg-teal-30w{background:#7ec3b6}.bg-teal-60w{background:#b5ddd5}.bg-teal-secondary{background:#cbd6cb}.bg-teal-90w{background:#ecf6f5}.bg-petrol-60b{background:#102930}.bg-petrol-30b{background:#1b4754}.bg-petrol-default{background:#276678}.bg-petrol-30w{background:#6894a0}.bg-petrol-60w{background:#a9c2c9}.bg-petrol-secondary{background:#c8d7de}.bg-petrol-90w{background:#e9f0f1}.bg-error-60b{background:#513131}.bg-error-30b{background:#8e5655}.bg-error-60w{background:#e3c3c6}.bg-error-secondary{background:#f0dad9}.bg-error-default{background:#cb7b7a}.bg-warning-secondary{background:#f0d6bb}.bg-warning-default{background:#cca45f}.bg-black{background:#000}.bg-dark{background:#888}.bg-medium{background:#e0e0e0}.bg-grey{background:#ededed}.bg-light{background:#f6f6f6}.bg-white{background:#fff}.bg-box-shadow{background:#00000014}.bg-navigation-subtitle{background:#528593}.bgc-teal-60b{background-color:#1c443c}.bgc-teal-30b{background-color:#31766a}.bgc-teal-default{background-color:#46a997}.bgc-teal-30w{background-color:#7ec3b6}.bgc-teal-60w{background-color:#b5ddd5}.bgc-teal-secondary{background-color:#cbd6cb}.bgc-teal-90w{background-color:#ecf6f5}.bgc-petrol-60b{background-color:#102930}.bgc-petrol-30b{background-color:#1b4754}.bgc-petrol-default{background-color:#276678}.bgc-petrol-30w{background-color:#6894a0}.bgc-petrol-60w{background-color:#a9c2c9}.bgc-petrol-secondary{background-color:#c8d7de}.bgc-petrol-90w{background-color:#e9f0f1}.bgc-error-60b{background-color:#513131}.bgc-error-30b{background-color:#8e5655}.bgc-error-60w{background-color:#e3c3c6}.bgc-error-secondary{background-color:#f0dad9}.bgc-error-default{background-color:#cb7b7a}.bgc-warning-secondary{background-color:#f0d6bb}.bgc-warning-default{background-color:#cca45f}.bgc-black{background-color:#000}.bgc-dark{background-color:#888}.bgc-medium{background-color:#e0e0e0}.bgc-grey{background-color:#ededed}.bgc-light{background-color:#f6f6f6}.bgc-white{background-color:#fff}.bgc-box-shadow{background-color:#00000014}.bgc-navigation-subtitle{background-color:#528593}:host{min-width:0}:host .breadcrumb{display:flex;align-items:center;gap:4px;color:#666}:host .breadcrumb .breadcrumb-item{text-decoration:underline;cursor:pointer;transition:color .15s ease,transform .1s ease;white-space:nowrap}:host .breadcrumb .breadcrumb-item:hover{color:#919191}:host .breadcrumb .breadcrumb-item:active{transform:scale(.98);color:#919191}:host .breadcrumb .breadcrumb-item:focus-visible{outline:2px solid #242424;outline-offset:4px;border-radius:1px}:host .breadcrumb.breadcrumb-small{font-size:14px;line-height:22px}:host .breadcrumb.breadcrumb-medium{font-size:20px;line-height:26px}:host .breadcrumb.breadcrumb-large{font-size:32px;line-height:48px}:host .breadcrumb.breadcrumb-large .breadcrumb-item:focus-visible{outline-offset:8px}:host .breadcrumb.breadcrumb-large .breadcrumb-item-active{font-weight:900!important}:host .breadcrumb.breadcrumb-large .breadcrumb-item-active:focus-visible{outline-offset:8px}:host .breadcrumb .breadcrumb-item-active{color:#242424;white-space:nowrap}:host .breadcrumb .breadcrumb-item-active.breadcrumb-item-active-truncated{text-overflow:ellipsis;overflow:hidden}:host .breadcrumb .breadcrumb-item-active:focus-visible{outline:2px solid #242424;outline-offset:4px;border-radius:1px}:host .breadcrumb .breadcrumb-overflow-menu ::ng-deep .overflow-menu-container .mat-mdc-menu-trigger{min-width:0}:host .breadcrumb-overflow{cursor:pointer;color:#666}:host .breadcrumb-overflow:active{transform:scale(.98);color:#919191}:host .breadcrumb-overflow.breadcrumb-small{font-size:14px;line-height:22px}:host .breadcrumb-overflow.breadcrumb-medium{font-size:20px;line-height:26px}:host .breadcrumb-overflow.breadcrumb-large{font-size:32px;line-height:48px}\n"], dependencies: [{ kind: "component", type: i1.IconComponent, selector: "ui-icon", inputs: ["size", "cssClass", "name", "color", "filled", "toggleIconStyle", "applicationTheme", "useFullIconName"] }, { kind: "directive", type: i2.MatTooltip, selector: "[matTooltip]", inputs: ["matTooltipPosition", "matTooltipPositionAtOrigin", "matTooltipDisabled", "matTooltipShowDelay", "matTooltipHideDelay", "matTooltipTouchGestures", "matTooltip", "matTooltipClass"], exportAs: ["matTooltip"] }, { kind: "component", type: i3.OverflowMenuComponent, selector: "ui-overflow-menu", inputs: ["buttons", "iconTrigger", "menuLabel", "applicationTheme", "ariaLabel", "ariaRequired", "describedby", "contentTemplateRef", "buttonVariant", "buttonSize", "menuConfig", "isDynamicMenu", "withRemovableOption"], outputs: ["selectItem", "menuOpened", "menuClosed"] }, { kind: "component", type: i4.ButtonComponent, selector: "ui-button", inputs: ["size", "variant", "label", "iconPosition", "justIcon", "iconName", "disabled", "loading", "loadingWithLabel", "fullWidth", "url", "urlTarget", "value", "tooltip", "isPremium", "type", "companyColor", "buttonBadgeConfig", "applicationTheme", "disabledScaleOnClick", "ariaLabel", "ariaRequired", "ariaLabelledby", "ariaDescribedby", "preventDefault", "hasBackground", "tooltipPosition", "role", "iconFilled"], outputs: ["buttonClickEvent", "buttonHoverEvent"] }, { kind: "component", type: i5.SkeletonComponent, selector: "ui-skeleton", inputs: ["count", "theme", "appearance", "isAiTheme", "applicationTheme"] }, { kind: "pipe", type: i6.AsyncPipe, name: "async" }, { kind: "pipe", type: i7.UiTranslatePipe, name: "uiTranslate" }, { kind: "pipe", type: i7.TruncatePipe, name: "truncate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
|
|
197
197
|
}
|
|
198
198
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.20", ngImport: i0, type: BreadcrumbComponent, decorators: [{
|
|
199
199
|
type: Component,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"testgorilla-tgo-ui-components-breadcrumb.mjs","sources":["../../../components/breadcrumb/breadcrumb.component.ts","../../../components/breadcrumb/breadcrumb.component.html","../../../components/breadcrumb/breadcrumb.component.module.ts","../../../components/breadcrumb/testgorilla-tgo-ui-components-breadcrumb.ts"],"sourcesContent":["import {\n AfterViewInit,\n Component,\n input,\n signal,\n ViewChild,\n OnDestroy,\n computed,\n EventEmitter,\n Output,\n effect,\n ChangeDetectionStrategy,\n Injector,\n afterNextRender,\n} from '@angular/core';\nimport { BreadcrumbItem, BreadcrumbSize } from './breadcrumb.model';\nimport { ElementRef } from '@angular/core';\nimport { ApplicationTheme } from '@testgorilla/tgo-ui/components/core';\nimport { OverflowMenuButtonsType } from '@testgorilla/tgo-ui/components/overflow-menu';\n\n@Component({\n selector: 'ui-breadcrumb',\n templateUrl: './breadcrumb.component.html',\n styleUrls: ['./breadcrumb.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n standalone: false,\n})\nexport class BreadcrumbComponent implements AfterViewInit, OnDestroy {\n size = input<BreadcrumbSize>('large');\n items = input<BreadcrumbItem[]>([]);\n applicationTheme = input<ApplicationTheme>('light');\n includeBackButton = input<boolean>(false);\n isLoading = input<boolean>(false);\n numberOfLoadingItems = input<number>(3);\n maxItemLength = input<number>(18);\n @Output() selectItem: EventEmitter<string> = new EventEmitter<string>();\n @Output() backButtonClickEvent: EventEmitter<Event> = new EventEmitter<Event>();\n\n loadingItems = computed(() => Array(this.numberOfLoadingItems()));\n isOverflowing = signal<boolean>(false);\n visibleItems = signal<BreadcrumbItem[]>([]);\n overflowItems = signal<BreadcrumbItem[]>([]);\n overflowButtonItems = computed<OverflowMenuButtonsType[]>(() =>\n this.overflowItems().map(item => ({\n label: item.label,\n value: item.value,\n }))\n );\n shouldTruncateLastItem = signal<boolean>(false);\n\n @ViewChild('breadcrumbContainer') breadcrumbContainer!: ElementRef<HTMLElement>;\n\n private resizeObserver?: ResizeObserver;\n private itemsInOverflow = 0;\n private previousLoadingState?: boolean;\n private injector = Injector.create({ providers: [] });\n\n constructor(private readonly parentInjector: Injector) {\n this.injector = parentInjector;\n // React to items changes and recalculate overflow\n effect(() => {\n this.items();\n this.itemsInOverflow = 0;\n\n // Only proceed if not in loading state\n if (!this.isLoading()) {\n // Use afterNextRender to ensure DOM is updated before calculating\n afterNextRender(\n () => {\n if (this.breadcrumbContainer?.nativeElement) {\n this.calculateItemDistribution();\n }\n },\n { injector: this.injector }\n );\n }\n });\n\n // React to loading state changes and setup ResizeObserver when loading changes from true to false\n effect(() => {\n const currentLoadingState = this.isLoading();\n\n if (this.previousLoadingState === true && currentLoadingState === false) {\n // Use afterNextRender to ensure DOM is ready before setting up observer\n afterNextRender(\n () => {\n this.setupResizeObserver();\n },\n { injector: this.injector }\n );\n }\n\n this.previousLoadingState = currentLoadingState;\n });\n }\n\n ngAfterViewInit() {\n this.calculateItemDistribution();\n this.setupResizeObserver();\n }\n\n ngOnDestroy() {\n this.resizeObserver?.disconnect();\n }\n\n private calculateItemDistribution() {\n if (!this.breadcrumbContainer?.nativeElement || this.items().length === 0) {\n this.resetToAllVisible();\n return;\n }\n\n const element = this.breadcrumbContainer.nativeElement;\n const hasHorizontalOverflow = element.scrollWidth > element.clientWidth;\n\n if (hasHorizontalOverflow) {\n this.handleOverflow();\n } else if (this.itemsInOverflow > 0) {\n // Check if we can bring items back from overflow\n this.tryReduceOverflow();\n } else {\n this.resetToAllVisible();\n }\n }\n\n private handleOverflow() {\n this.itemsInOverflow = Math.min(this.itemsInOverflow + 1, this.items().length - 1);\n\n this.updateItemArrays();\n this.isOverflowing.set(true);\n\n // Wait for DOM to render the updated template after hiding items\n // We need to measure dimensions AFTER the DOM has been updated with the new visible items\n setTimeout(() => {\n if (this.breadcrumbContainer?.nativeElement) {\n const element = this.breadcrumbContainer.nativeElement;\n const stillOverflowing = element.scrollWidth > element.clientWidth;\n\n if (stillOverflowing && this.itemsInOverflow < this.items().length - 1) {\n this.handleOverflow();\n } else if (stillOverflowing && this.itemsInOverflow === this.items().length - 1) {\n this.shouldTruncateLastItem.set(true);\n }\n }\n }, 0);\n }\n\n private tryReduceOverflow() {\n const testItemsInOverflow = this.itemsInOverflow - 1;\n\n if (testItemsInOverflow >= 0) {\n const testVisibleItems = this.items().slice(testItemsInOverflow);\n const testOverflowItems = testItemsInOverflow > 0 ? this.items().slice(0, testItemsInOverflow) : [];\n\n this.visibleItems.set(testVisibleItems);\n this.overflowItems.set(testOverflowItems);\n\n // Always reset truncation when trying to reduce overflow\n this.shouldTruncateLastItem.set(false);\n\n // Wait for DOM to render with test configuration before measuring\n setTimeout(() => {\n if (this.breadcrumbContainer?.nativeElement) {\n const element = this.breadcrumbContainer.nativeElement;\n const hasOverflow = element.scrollWidth > element.clientWidth;\n\n if (!hasOverflow) {\n // It fits! Update the counter\n this.itemsInOverflow = testItemsInOverflow;\n this.isOverflowing.set(this.itemsInOverflow > 0);\n\n // Try to reduce more if there are still items in overflow\n if (this.itemsInOverflow > 0) {\n // Schedule next reduction attempt after current render cycle\n setTimeout(() => this.tryReduceOverflow(), 0);\n }\n } else {\n // Doesn't fit, revert to previous state\n this.updateItemArrays();\n\n // Wait for DOM to render reverted state before checking truncation\n setTimeout(() => {\n if (this.breadcrumbContainer?.nativeElement) {\n const containerElement = this.breadcrumbContainer.nativeElement;\n const stillOverflowing = containerElement.scrollWidth > containerElement.clientWidth;\n\n if (stillOverflowing && this.itemsInOverflow === this.items().length - 1) {\n this.shouldTruncateLastItem.set(true);\n }\n }\n }, 0);\n }\n }\n }, 0);\n } else {\n // testItemsInOverflow < 0, means we're trying to show all items\n this.resetToAllVisible();\n\n // Wait for DOM to render all items before measuring overflow\n setTimeout(() => {\n if (this.breadcrumbContainer?.nativeElement) {\n const element = this.breadcrumbContainer.nativeElement;\n const hasOverflow = element.scrollWidth > element.clientWidth;\n\n if (hasOverflow) {\n // Still overflows with all items, need to go back to overflow state\n this.itemsInOverflow = 1; // Start with minimal overflow\n this.handleOverflow();\n }\n }\n }, 0);\n }\n }\n\n private updateItemArrays() {\n if (this.itemsInOverflow > 0) {\n this.overflowItems.set(this.items().slice(0, this.itemsInOverflow));\n this.visibleItems.set(this.items().slice(this.itemsInOverflow));\n } else {\n this.resetToAllVisible();\n }\n }\n\n private resetToAllVisible() {\n this.visibleItems.set(this.items());\n this.overflowItems.set([]);\n this.isOverflowing.set(false);\n this.shouldTruncateLastItem.set(false);\n this.itemsInOverflow = 0;\n }\n\n private setupResizeObserver() {\n if (!this.breadcrumbContainer?.nativeElement) {\n return;\n }\n\n this.resizeObserver = new ResizeObserver(() => {\n this.calculateItemDistribution();\n });\n\n this.resizeObserver.observe(this.breadcrumbContainer.nativeElement);\n }\n}\n","@if (!isLoading()) {\n <div class=\"breadcrumb\" [attr.theme]=\"applicationTheme()\" #breadcrumbContainer [class]=\"'breadcrumb-' + size()\">\n @if (includeBackButton()) {\n <ui-button\n [variant]=\"'icon-button'\"\n [tooltip]=\"('COMMON.BACK' | uiTranslate | async)!\"\n [iconName]=\"'Arrow-chevron-left-filled'\"\n (buttonClickEvent)=\"backButtonClickEvent.emit($event)\"\n ></ui-button>\n }\n @if (isOverflowing()) {\n <ui-overflow-menu\n [applicationTheme]=\"applicationTheme()\"\n [contentTemplateRef]=\"overflowMenu\"\n [buttons]=\"overflowButtonItems()\"\n [matTooltip]=\"('COMMON.OPTIONS' | uiTranslate | async)!\"\n [matTooltipClass]=\"applicationTheme()\"\n [isDynamicMenu]=\"true\"\n (selectItem)=\"selectItem.emit($event)\"\n class=\"breadcrumb-overflow-menu\"\n ></ui-overflow-menu>\n <ui-icon name=\"Arrow-chevron-right-filled\" [applicationTheme]=\"applicationTheme()\" color=\"gray\"></ui-icon>\n }\n @for (item of visibleItems(); track item.value) {\n @if (!$last) {\n <span\n class=\"breadcrumb-item\"\n tabindex=\"0\"\n [matTooltip]=\"item.label.length > maxItemLength() ? item.label : ''\"\n [matTooltipClass]=\"applicationTheme()\"\n [attr.aria-label]=\"item.label\"\n (click)=\"selectItem.emit(item.value)\"\n (keydown.enter)=\"selectItem.emit(item.value)\"\n >\n {{ item.label | truncate: maxItemLength() : '...' }}\n </span>\n <ui-icon name=\"Arrow-chevron-right-filled\" [applicationTheme]=\"applicationTheme()\" color=\"gray\"></ui-icon>\n } @else {\n <strong\n class=\"breadcrumb-item-active\"\n tabindex=\"0\"\n [matTooltip]=\"shouldTruncateLastItem() ? item.label : ''\"\n [matTooltipClass]=\"applicationTheme()\"\n [class.breadcrumb-item-active-truncated]=\"shouldTruncateLastItem()\"\n [attr.aria-label]=\"item.label\"\n [attr.aria-current]=\"'page'\"\n (click)=\"selectItem.emit(item.value)\"\n (keydown.enter)=\"selectItem.emit(item.value)\"\n >\n {{ item.label }}\n </strong>\n }\n }\n </div>\n} @else {\n <div class=\"breadcrumb\">\n @for (i of loadingItems(); track $index) {\n <ui-skeleton count=\"1\" [theme]=\"{ width: '160px', margin: '10px 0 0' }\"></ui-skeleton>\n @if ($index !== numberOfLoadingItems() - 1) {\n <ui-icon name=\"Arrow-chevron-right-filled\" [applicationTheme]=\"applicationTheme()\" color=\"gray\"></ui-icon>\n }\n }\n </div>\n}\n<ng-template #overflowMenu>\n <div class=\"breadcrumb-item breadcrumb-overflow\" [class]=\"'breadcrumb-' + size()\">...</div>\n</ng-template>\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { MatTooltipModule } from '@angular/material/tooltip';\nimport { BreadcrumbComponent } from './breadcrumb.component';\nimport { IconComponentModule } from '@testgorilla/tgo-ui/components/icon';\nimport { OverflowMenuComponentModule } from '@testgorilla/tgo-ui/components/overflow-menu';\nimport { ButtonComponentModule } from '@testgorilla/tgo-ui/components/button';\nimport { UiTranslatePipe, TruncatePipe } from '@testgorilla/tgo-ui/components/core';\nimport { SkeletonComponent } from '@testgorilla/tgo-ui/components/skeleton';\n\n@NgModule({\n declarations: [BreadcrumbComponent],\n imports: [\n CommonModule,\n IconComponentModule,\n MatTooltipModule,\n OverflowMenuComponentModule,\n ButtonComponentModule,\n SkeletonComponent,\n UiTranslatePipe,\n TruncatePipe,\n ],\n exports: [BreadcrumbComponent],\n})\nexport class BreadcrumbComponentModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;MA2Ba,mBAAmB,CAAA;AA8B9B,IAAA,WAAA,CAA6B,cAAwB,EAAA;QAAxB,IAAA,CAAA,cAAc,GAAd,cAAc;AA7B3C,QAAA,IAAA,CAAA,IAAI,GAAG,KAAK,CAAiB,OAAO,CAAC;AACrC,QAAA,IAAA,CAAA,KAAK,GAAG,KAAK,CAAmB,EAAE,CAAC;AACnC,QA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ACP,YAAY;wBACZ,mBAAmB;wBACnB,gBAAgB;wBAChB,2BAA2B;wBAC3B,qBAAqB;wBACrB,iBAAiB;wBACjB,eAAe;wBACf,YAAY;AACb,qBAAA;oBACD,OAAO,EAAE,CAAC,mBAAmB,CAAC;AAC/B,iBAAA;;;ACvBD;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"testgorilla-tgo-ui-components-breadcrumb.mjs","sources":["../../../components/breadcrumb/breadcrumb.component.ts","../../../components/breadcrumb/breadcrumb.component.html","../../../components/breadcrumb/breadcrumb.component.module.ts","../../../components/breadcrumb/testgorilla-tgo-ui-components-breadcrumb.ts"],"sourcesContent":["import {\n AfterViewInit,\n Component,\n input,\n signal,\n ViewChild,\n OnDestroy,\n computed,\n EventEmitter,\n Output,\n effect,\n ChangeDetectionStrategy,\n Injector,\n afterNextRender,\n} from '@angular/core';\nimport { BreadcrumbItem, BreadcrumbSize } from './breadcrumb.model';\nimport { ElementRef } from '@angular/core';\nimport { ApplicationTheme } from '@testgorilla/tgo-ui/components/core';\nimport { OverflowMenuButtonsType } from '@testgorilla/tgo-ui/components/overflow-menu';\n\n@Component({\n selector: 'ui-breadcrumb',\n templateUrl: './breadcrumb.component.html',\n styleUrls: ['./breadcrumb.component.scss'],\n changeDetection: ChangeDetectionStrategy.OnPush,\n standalone: false,\n})\nexport class BreadcrumbComponent implements AfterViewInit, OnDestroy {\n size = input<BreadcrumbSize>('large');\n items = input<BreadcrumbItem[]>([]);\n applicationTheme = input<ApplicationTheme>('light');\n includeBackButton = input<boolean>(false);\n isLoading = input<boolean>(false);\n numberOfLoadingItems = input<number>(3);\n maxItemLength = input<number>(18);\n @Output() selectItem: EventEmitter<string> = new EventEmitter<string>();\n @Output() backButtonClickEvent: EventEmitter<Event> = new EventEmitter<Event>();\n\n loadingItems = computed(() => Array(this.numberOfLoadingItems()));\n isOverflowing = signal<boolean>(false);\n visibleItems = signal<BreadcrumbItem[]>([]);\n overflowItems = signal<BreadcrumbItem[]>([]);\n overflowButtonItems = computed<OverflowMenuButtonsType[]>(() =>\n this.overflowItems().map(item => ({\n label: item.label,\n value: item.value,\n }))\n );\n shouldTruncateLastItem = signal<boolean>(false);\n\n @ViewChild('breadcrumbContainer') breadcrumbContainer!: ElementRef<HTMLElement>;\n\n private resizeObserver?: ResizeObserver;\n private itemsInOverflow = 0;\n private previousLoadingState?: boolean;\n private injector = Injector.create({ providers: [] });\n\n constructor(private readonly parentInjector: Injector) {\n this.injector = parentInjector;\n // React to items changes and recalculate overflow\n effect(() => {\n this.items();\n this.itemsInOverflow = 0;\n\n // Only proceed if not in loading state\n if (!this.isLoading()) {\n // Use afterNextRender to ensure DOM is updated before calculating\n afterNextRender(\n () => {\n if (this.breadcrumbContainer?.nativeElement) {\n this.calculateItemDistribution();\n }\n },\n { injector: this.injector }\n );\n }\n });\n\n // React to loading state changes and setup ResizeObserver when loading changes from true to false\n effect(() => {\n const currentLoadingState = this.isLoading();\n\n if (this.previousLoadingState === true && currentLoadingState === false) {\n // Use afterNextRender to ensure DOM is ready before setting up observer\n afterNextRender(\n () => {\n this.setupResizeObserver();\n },\n { injector: this.injector }\n );\n }\n\n this.previousLoadingState = currentLoadingState;\n });\n }\n\n ngAfterViewInit() {\n this.calculateItemDistribution();\n this.setupResizeObserver();\n }\n\n ngOnDestroy() {\n this.resizeObserver?.disconnect();\n }\n\n private calculateItemDistribution() {\n if (!this.breadcrumbContainer?.nativeElement || this.items().length === 0) {\n this.resetToAllVisible();\n return;\n }\n\n const element = this.breadcrumbContainer.nativeElement;\n const hasHorizontalOverflow = element.scrollWidth > element.clientWidth;\n\n if (hasHorizontalOverflow) {\n this.handleOverflow();\n } else if (this.itemsInOverflow > 0) {\n // Check if we can bring items back from overflow\n this.tryReduceOverflow();\n } else {\n this.resetToAllVisible();\n }\n }\n\n private handleOverflow() {\n this.itemsInOverflow = Math.min(this.itemsInOverflow + 1, this.items().length - 1);\n\n this.updateItemArrays();\n this.isOverflowing.set(true);\n\n // Wait for DOM to render the updated template after hiding items\n // We need to measure dimensions AFTER the DOM has been updated with the new visible items\n setTimeout(() => {\n if (this.breadcrumbContainer?.nativeElement) {\n const element = this.breadcrumbContainer.nativeElement;\n const stillOverflowing = element.scrollWidth > element.clientWidth;\n\n if (stillOverflowing && this.itemsInOverflow < this.items().length - 1) {\n this.handleOverflow();\n } else if (stillOverflowing && this.itemsInOverflow === this.items().length - 1) {\n this.shouldTruncateLastItem.set(true);\n }\n }\n }, 0);\n }\n\n private tryReduceOverflow() {\n const testItemsInOverflow = this.itemsInOverflow - 1;\n\n if (testItemsInOverflow >= 0) {\n const testVisibleItems = this.items().slice(testItemsInOverflow);\n const testOverflowItems = testItemsInOverflow > 0 ? this.items().slice(0, testItemsInOverflow) : [];\n\n this.visibleItems.set(testVisibleItems);\n this.overflowItems.set(testOverflowItems);\n\n // Always reset truncation when trying to reduce overflow\n this.shouldTruncateLastItem.set(false);\n\n // Wait for DOM to render with test configuration before measuring\n setTimeout(() => {\n if (this.breadcrumbContainer?.nativeElement) {\n const element = this.breadcrumbContainer.nativeElement;\n const hasOverflow = element.scrollWidth > element.clientWidth;\n\n if (!hasOverflow) {\n // It fits! Update the counter\n this.itemsInOverflow = testItemsInOverflow;\n this.isOverflowing.set(this.itemsInOverflow > 0);\n\n // Try to reduce more if there are still items in overflow\n if (this.itemsInOverflow > 0) {\n // Schedule next reduction attempt after current render cycle\n setTimeout(() => this.tryReduceOverflow(), 0);\n }\n } else {\n // Doesn't fit, revert to previous state\n this.updateItemArrays();\n\n // Wait for DOM to render reverted state before checking truncation\n setTimeout(() => {\n if (this.breadcrumbContainer?.nativeElement) {\n const containerElement = this.breadcrumbContainer.nativeElement;\n const stillOverflowing = containerElement.scrollWidth > containerElement.clientWidth;\n\n if (stillOverflowing && this.itemsInOverflow === this.items().length - 1) {\n this.shouldTruncateLastItem.set(true);\n }\n }\n }, 0);\n }\n }\n }, 0);\n } else {\n // testItemsInOverflow < 0, means we're trying to show all items\n this.resetToAllVisible();\n\n // Wait for DOM to render all items before measuring overflow\n setTimeout(() => {\n if (this.breadcrumbContainer?.nativeElement) {\n const element = this.breadcrumbContainer.nativeElement;\n const hasOverflow = element.scrollWidth > element.clientWidth;\n\n if (hasOverflow) {\n // Still overflows with all items, need to go back to overflow state\n this.itemsInOverflow = 1; // Start with minimal overflow\n this.handleOverflow();\n }\n }\n }, 0);\n }\n }\n\n private updateItemArrays() {\n if (this.itemsInOverflow > 0) {\n this.overflowItems.set(this.items().slice(0, this.itemsInOverflow));\n this.visibleItems.set(this.items().slice(this.itemsInOverflow));\n } else {\n this.resetToAllVisible();\n }\n }\n\n private resetToAllVisible() {\n this.visibleItems.set(this.items());\n this.overflowItems.set([]);\n this.isOverflowing.set(false);\n this.shouldTruncateLastItem.set(false);\n this.itemsInOverflow = 0;\n }\n\n private setupResizeObserver() {\n if (!this.breadcrumbContainer?.nativeElement) {\n return;\n }\n\n this.resizeObserver = new ResizeObserver(() => {\n this.calculateItemDistribution();\n });\n\n this.resizeObserver.observe(this.breadcrumbContainer.nativeElement);\n }\n}\n","@if (!isLoading()) {\n <div class=\"breadcrumb\" [attr.theme]=\"applicationTheme()\" #breadcrumbContainer [class]=\"'breadcrumb-' + size()\">\n @if (includeBackButton()) {\n <ui-button\n [variant]=\"'icon-button'\"\n [tooltip]=\"('COMMON.BACK' | uiTranslate | async)!\"\n [iconName]=\"'Arrow-chevron-left-filled'\"\n (buttonClickEvent)=\"backButtonClickEvent.emit($event)\"\n ></ui-button>\n }\n @if (isOverflowing()) {\n <ui-overflow-menu\n [applicationTheme]=\"applicationTheme()\"\n [contentTemplateRef]=\"overflowMenu\"\n [buttons]=\"overflowButtonItems()\"\n [matTooltip]=\"('COMMON.OPTIONS' | uiTranslate | async)!\"\n [matTooltipClass]=\"applicationTheme()\"\n [isDynamicMenu]=\"true\"\n (selectItem)=\"selectItem.emit($event)\"\n class=\"breadcrumb-overflow-menu\"\n ></ui-overflow-menu>\n <ui-icon name=\"Arrow-chevron-right-filled\" [applicationTheme]=\"applicationTheme()\" color=\"gray\"></ui-icon>\n }\n @for (item of visibleItems(); track item.value) {\n @if (!$last) {\n <span\n class=\"breadcrumb-item\"\n tabindex=\"0\"\n [matTooltip]=\"item.label.length > maxItemLength() ? item.label : ''\"\n [matTooltipClass]=\"applicationTheme()\"\n [attr.aria-label]=\"item.label\"\n (click)=\"selectItem.emit(item.value)\"\n (keydown.enter)=\"selectItem.emit(item.value)\"\n >\n {{ item.label | truncate: maxItemLength() : '...' }}\n </span>\n <ui-icon name=\"Arrow-chevron-right-filled\" [applicationTheme]=\"applicationTheme()\" color=\"gray\"></ui-icon>\n } @else {\n <strong\n class=\"breadcrumb-item-active\"\n tabindex=\"0\"\n [matTooltip]=\"shouldTruncateLastItem() ? item.label : ''\"\n [matTooltipClass]=\"applicationTheme()\"\n [class.breadcrumb-item-active-truncated]=\"shouldTruncateLastItem()\"\n [attr.aria-label]=\"item.label\"\n [attr.aria-current]=\"'page'\"\n (click)=\"selectItem.emit(item.value)\"\n (keydown.enter)=\"selectItem.emit(item.value)\"\n >\n {{ item.label }}\n </strong>\n }\n }\n </div>\n} @else {\n <div class=\"breadcrumb\">\n @for (i of loadingItems(); track $index) {\n <ui-skeleton count=\"1\" [theme]=\"{ width: '160px', margin: '10px 0 0' }\"></ui-skeleton>\n @if ($index !== numberOfLoadingItems() - 1) {\n <ui-icon name=\"Arrow-chevron-right-filled\" [applicationTheme]=\"applicationTheme()\" color=\"gray\"></ui-icon>\n }\n }\n </div>\n}\n<ng-template #overflowMenu>\n <div class=\"breadcrumb-item breadcrumb-overflow\" [class]=\"'breadcrumb-' + size()\">...</div>\n</ng-template>\n","import { NgModule } from '@angular/core';\nimport { CommonModule } from '@angular/common';\nimport { MatTooltipModule } from '@angular/material/tooltip';\nimport { BreadcrumbComponent } from './breadcrumb.component';\nimport { IconComponentModule } from '@testgorilla/tgo-ui/components/icon';\nimport { OverflowMenuComponentModule } from '@testgorilla/tgo-ui/components/overflow-menu';\nimport { ButtonComponentModule } from '@testgorilla/tgo-ui/components/button';\nimport { UiTranslatePipe, TruncatePipe } from '@testgorilla/tgo-ui/components/core';\nimport { SkeletonComponent } from '@testgorilla/tgo-ui/components/skeleton';\n\n@NgModule({\n declarations: [BreadcrumbComponent],\n imports: [\n CommonModule,\n IconComponentModule,\n MatTooltipModule,\n OverflowMenuComponentModule,\n ButtonComponentModule,\n SkeletonComponent,\n UiTranslatePipe,\n TruncatePipe,\n ],\n exports: [BreadcrumbComponent],\n})\nexport class BreadcrumbComponentModule {}\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './public-api';\n"],"names":[],"mappings":";;;;;;;;;;;;;;;;;MA2Ba,mBAAmB,CAAA;AA8B9B,IAAA,WAAA,CAA6B,cAAwB,EAAA;QAAxB,IAAA,CAAA,cAAc,GAAd,cAAc;AA7B3C,QAAA,IAAA,CAAA,IAAI,GAAG,KAAK,CAAiB,OAAO,CAAC;AACrC,QAAA,IAAA,CAAA,KAAK,GAAG,KAAK,CAAmB,EAAE,CAAC;AACnC,QAAA,IAAA,CAAA,gBAAgB,GAAG,KAAK,CAAmB,OAAO,CAAC;AACnD,QAAA,IAAA,CAAA,iBAAiB,GAAG,KAAK,CAAU,KAAK,CAAC;AACzC,QAAA,IAAA,CAAA,SAAS,GAAG,KAAK,CAAU,KAAK,CAAC;AACjC,QAAA,IAAA,CAAA,oBAAoB,GAAG,KAAK,CAAS,CAAC,CAAC;AACvC,QAAA,IAAA,CAAA,aAAa,GAAG,KAAK,CAAS,EAAE,CAAC;AACvB,QAAA,IAAA,CAAA,UAAU,GAAyB,IAAI,YAAY,EAAU;AAC7D,QAAA,IAAA,CAAA,oBAAoB,GAAwB,IAAI,YAAY,EAAS;AAE/E,QAAA,IAAA,CAAA,YAAY,GAAG,QAAQ,CAAC,MAAM,KAAK,CAAC,IAAI,CAAC,oBAAoB,EAAE,CAAC,CAAC;AACjE,QAAA,IAAA,CAAA,aAAa,GAAG,MAAM,CAAU,KAAK,CAAC;AACtC,QAAA,IA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