@siemens/element-ng 48.0.3 → 48.2.0-rc.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +9 -0
- package/accordion/index.d.ts +2 -1
- package/avatar/index.d.ts +3 -4
- package/card/index.d.ts +68 -29
- package/circle-status/index.d.ts +2 -1
- package/common/index.d.ts +11 -0
- package/dashboard/index.d.ts +6 -1
- package/datepicker/index.d.ts +32 -32
- package/fesm2022/siemens-element-ng-accordion.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-avatar.mjs +32 -36
- package/fesm2022/siemens-element-ng-avatar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-breadcrumb.mjs +2 -2
- package/fesm2022/siemens-element-ng-breadcrumb.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-card.mjs +103 -37
- package/fesm2022/siemens-element-ng-card.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-circle-status.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-column-selection-dialog.mjs +2 -2
- package/fesm2022/siemens-element-ng-column-selection-dialog.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-common.mjs +6 -0
- package/fesm2022/siemens-element-ng-common.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-connection-strength.mjs +2 -2
- package/fesm2022/siemens-element-ng-connection-strength.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-content-action-bar.mjs +2 -2
- package/fesm2022/siemens-element-ng-content-action-bar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-dashboard.mjs +34 -35
- package/fesm2022/siemens-element-ng-dashboard.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-datatable.mjs +5 -0
- package/fesm2022/siemens-element-ng-datatable.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-date-range-filter.mjs +1 -1
- package/fesm2022/siemens-element-ng-date-range-filter.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-datepicker.mjs +176 -142
- package/fesm2022/siemens-element-ng-datepicker.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-file-uploader.mjs +9 -2
- package/fesm2022/siemens-element-ng-file-uploader.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-filter-bar.mjs +5 -5
- package/fesm2022/siemens-element-ng-filter-bar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-filtered-search.mjs +34 -13
- package/fesm2022/siemens-element-ng-filtered-search.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-form.mjs +7 -1
- package/fesm2022/siemens-element-ng-form.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-formly.mjs +18 -18
- package/fesm2022/siemens-element-ng-formly.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-inline-notification.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-ip-input.mjs +38 -0
- package/fesm2022/siemens-element-ng-ip-input.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-language-switcher.mjs +1 -1
- package/fesm2022/siemens-element-ng-language-switcher.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-list-details.mjs +9 -4
- package/fesm2022/siemens-element-ng-list-details.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-main-detail-container.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-navbar-vertical.mjs +16 -3
- package/fesm2022/siemens-element-ng-navbar-vertical.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-notification-item.mjs +71 -0
- package/fesm2022/siemens-element-ng-notification-item.mjs.map +1 -0
- package/fesm2022/siemens-element-ng-pagination.mjs +2 -2
- package/fesm2022/siemens-element-ng-pagination.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-photo-upload.mjs +1 -1
- package/fesm2022/siemens-element-ng-photo-upload.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-progressbar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-resize-observer.mjs +0 -1
- package/fesm2022/siemens-element-ng-resize-observer.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-result-details-list.mjs +5 -0
- package/fesm2022/siemens-element-ng-result-details-list.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-search-bar.mjs +14 -4
- package/fesm2022/siemens-element-ng-search-bar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-side-panel.mjs +2 -2
- package/fesm2022/siemens-element-ng-side-panel.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-sort-bar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-split.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-status-bar.mjs +2 -2
- package/fesm2022/siemens-element-ng-status-bar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-tabs-legacy.mjs +2 -2
- package/fesm2022/siemens-element-ng-tabs-legacy.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-tabs.mjs +45 -12
- package/fesm2022/siemens-element-ng-tabs.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-tooltip.mjs +5 -6
- package/fesm2022/siemens-element-ng-tooltip.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-translate.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-tree-view.mjs +4 -4
- package/fesm2022/siemens-element-ng-tree-view.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-typeahead.mjs +329 -257
- package/fesm2022/siemens-element-ng-typeahead.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-wizard.mjs.map +1 -1
- package/file-uploader/index.d.ts +3 -1
- package/filter-bar/index.d.ts +13 -5
- package/form/index.d.ts +28 -29
- package/inline-notification/index.d.ts +3 -2
- package/ip-input/index.d.ts +42 -4
- package/landing-page/index.d.ts +3 -2
- package/language-switcher/index.d.ts +3 -1
- package/list-details/index.d.ts +2 -0
- package/main-detail-container/index.d.ts +4 -4
- package/navbar/index.d.ts +1 -1
- package/notification-item/index.d.ts +141 -0
- package/notification-item/package.json +3 -0
- package/package.json +19 -11
- package/progressbar/index.d.ts +3 -3
- package/result-details-list/index.d.ts +4 -2
- package/schematics/collection.json +28 -0
- package/schematics/ng-add/index.js +16 -0
- package/schematics/ng-add/schema.json +16 -0
- package/schematics/scss-import-to-siemens-migration/index.js +101 -0
- package/schematics/scss-import-to-siemens-migration/schema.json +16 -0
- package/schematics/scss-import-to-siemens-migration/style-mappings.js +46 -0
- package/schematics/simpl-siemens-migration/index.js +17 -0
- package/schematics/simpl-siemens-migration/schema.json +16 -0
- package/schematics/ts-import-to-siemens-migration/index.js +118 -0
- package/schematics/ts-import-to-siemens-migration/mappings/charts-ng-mappings.js +70 -0
- package/schematics/ts-import-to-siemens-migration/mappings/dashboards-ng-mappings.js +52 -0
- package/schematics/ts-import-to-siemens-migration/mappings/element-ng-mappings.js +651 -0
- package/schematics/ts-import-to-siemens-migration/mappings/element-translate-ng-mappings.js +21 -0
- package/schematics/ts-import-to-siemens-migration/mappings/index.js +9 -0
- package/schematics/ts-import-to-siemens-migration/mappings/maps-ng-mappings.js +46 -0
- package/schematics/ts-import-to-siemens-migration/model.js +4 -0
- package/schematics/ts-import-to-siemens-migration/schema.json +16 -0
- package/schematics/utils/index.js +8 -0
- package/schematics/utils/project-utils.js +75 -0
- package/schematics/utils/schematics-file-system.js +22 -0
- package/schematics/utils/testing.js +41 -0
- package/schematics/utils/ts-utils.js +99 -0
- package/search-bar/index.d.ts +11 -1
- package/select/index.d.ts +7 -5
- package/sort-bar/index.d.ts +3 -3
- package/split/index.d.ts +3 -2
- package/status-bar/index.d.ts +3 -2
- package/tabs/index.d.ts +15 -1
- package/template-i18n.json +8 -0
- package/tooltip/index.d.ts +1 -1
- package/translate/index.d.ts +8 -0
- package/tree-view/index.d.ts +4 -4
- package/typeahead/index.d.ts +85 -4
- package/wizard/index.d.ts +2 -1
|
@@ -0,0 +1,71 @@
|
|
|
1
|
+
import { CdkMenuTrigger } from '@angular/cdk/menu';
|
|
2
|
+
import * as i2 from '@angular/common';
|
|
3
|
+
import { CommonModule } from '@angular/common';
|
|
4
|
+
import * as i0 from '@angular/core';
|
|
5
|
+
import { input, booleanAttribute, inject, Component } from '@angular/core';
|
|
6
|
+
import * as i1 from '@angular/router';
|
|
7
|
+
import { ActivatedRoute, RouterModule } from '@angular/router';
|
|
8
|
+
import { SiMenuFactoryComponent } from '@siemens/element-ng/menu';
|
|
9
|
+
import { SiTranslatePipe } from '@siemens/element-translate-ng/translate';
|
|
10
|
+
|
|
11
|
+
/**
|
|
12
|
+
* Copyright (c) Siemens 2016 - 2025
|
|
13
|
+
* SPDX-License-Identifier: MIT
|
|
14
|
+
*/
|
|
15
|
+
/**
|
|
16
|
+
* This component represents a single notification that can be used within notification
|
|
17
|
+
* centers, popovers, or other containers. It supports various action types including
|
|
18
|
+
* router links, standard links, action buttons, and menus.
|
|
19
|
+
*/
|
|
20
|
+
class SiNotificationItemComponent {
|
|
21
|
+
/**
|
|
22
|
+
* The timestamp of the notification item.
|
|
23
|
+
*/
|
|
24
|
+
timeStamp = input.required();
|
|
25
|
+
/**
|
|
26
|
+
* The heading of the notification item.
|
|
27
|
+
*/
|
|
28
|
+
heading = input.required();
|
|
29
|
+
/**
|
|
30
|
+
* Optional translatable description.
|
|
31
|
+
*/
|
|
32
|
+
description = input();
|
|
33
|
+
/**
|
|
34
|
+
* Unread messages are emphasized with a bolder font.
|
|
35
|
+
*
|
|
36
|
+
* @defaultValue false
|
|
37
|
+
*/
|
|
38
|
+
unread = input(false, { transform: booleanAttribute });
|
|
39
|
+
/**
|
|
40
|
+
* Link to the source or relevant information of the notification,
|
|
41
|
+
* which triggers when clicking on the notification item text area.
|
|
42
|
+
*/
|
|
43
|
+
itemLink = input();
|
|
44
|
+
/**
|
|
45
|
+
* Actions that are displayed below the text of the notification.
|
|
46
|
+
*/
|
|
47
|
+
quickActions = input();
|
|
48
|
+
/**
|
|
49
|
+
* Action that is displayed on the right side of the notification.
|
|
50
|
+
*/
|
|
51
|
+
primaryAction = input();
|
|
52
|
+
activatedRoute = inject(ActivatedRoute, { optional: true });
|
|
53
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: SiNotificationItemComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
54
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.0.6", type: SiNotificationItemComponent, isStandalone: true, selector: "si-notification-item", inputs: { timeStamp: { classPropertyName: "timeStamp", publicName: "timeStamp", isSignal: true, isRequired: true, transformFunction: null }, heading: { classPropertyName: "heading", publicName: "heading", isSignal: true, isRequired: true, transformFunction: null }, description: { classPropertyName: "description", publicName: "description", isSignal: true, isRequired: false, transformFunction: null }, unread: { classPropertyName: "unread", publicName: "unread", isSignal: true, isRequired: false, transformFunction: null }, itemLink: { classPropertyName: "itemLink", publicName: "itemLink", isSignal: true, isRequired: false, transformFunction: null }, quickActions: { classPropertyName: "quickActions", publicName: "quickActions", isSignal: true, isRequired: false, transformFunction: null }, primaryAction: { classPropertyName: "primaryAction", publicName: "primaryAction", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"notification-item px-6 py-5\">\n <div class=\"notification-item-indicator\">\n <div>\n @if (unread()) {\n <span class=\"dot\"></span>\n }\n <ng-content select=\"si-avatar,si-circle-status,si-icon,si-status-icon\" />\n </div>\n </div>\n\n <div class=\"notification-item-content\">\n @let itemLinkValue = itemLink();\n @if (itemLinkValue) {\n @switch (itemLinkValue.type) {\n @case ('link') {\n <a\n [href]=\"itemLinkValue.href\"\n [target]=\"itemLinkValue.target\"\n [attr.aria-label]=\"heading() + ' link'\"\n >\n <ng-container *ngTemplateOutlet=\"content\" />\n </a>\n }\n @case ('router-link') {\n <a\n [routerLink]=\"itemLinkValue.routerLink\"\n [queryParams]=\"itemLinkValue.extras?.queryParams\"\n [queryParamsHandling]=\"itemLinkValue.extras?.queryParamsHandling\"\n [fragment]=\"itemLinkValue.extras?.fragment\"\n [state]=\"itemLinkValue.extras?.state\"\n [relativeTo]=\"itemLinkValue.extras?.relativeTo ?? activatedRoute\"\n [preserveFragment]=\"itemLinkValue.extras?.preserveFragment\"\n [skipLocationChange]=\"itemLinkValue.extras?.skipLocationChange\"\n [replaceUrl]=\"itemLinkValue.extras?.replaceUrl\"\n [attr.aria-label]=\"heading() + ' link'\"\n >\n <ng-container *ngTemplateOutlet=\"content\" />\n </a>\n }\n }\n } @else {\n <ng-container *ngTemplateOutlet=\"content\" />\n }\n </div>\n\n @let primaryActionValue = primaryAction();\n @if (primaryActionValue) {\n <div class=\"notification-item-primary-action\">\n @if (primaryActionValue.type === 'menu') {\n <ng-container *ngTemplateOutlet=\"menu; context: { $implicit: primaryActionValue }\" />\n } @else if (primaryActionValue.type === 'action-button') {\n <button\n type=\"button\"\n class=\"btn btn-tertiary\"\n (click)=\"primaryActionValue.action(primaryActionValue)\"\n >{{ primaryActionValue.label | translate }}</button\n >\n } @else {\n <ng-container *ngTemplateOutlet=\"action; context: { $implicit: primaryActionValue }\" />\n }\n </div>\n } @else {\n <div class=\"notification-item-primary-action\">\n <ng-content select=\"[action]\" />\n </div>\n }\n\n @let quickActionsValue = quickActions();\n @if (quickActionsValue) {\n <div class=\"notification-item-quick-actions\">\n @for (quickAction of quickActionsValue; track $index) {\n <ng-container *ngTemplateOutlet=\"action; context: { $implicit: quickAction }\" />\n }\n </div>\n } @else {\n <div class=\"notification-item-quick-actions\">\n <ng-content select=\"[quick-actions]\" />\n </div>\n }\n</div>\n\n<ng-template #action let-action>\n @switch (action.type) {\n @case ('action-circle-button') {\n <ng-container *ngTemplateOutlet=\"actionButton; context: { $implicit: action }\" />\n }\n @case ('router-link') {\n <ng-container *ngTemplateOutlet=\"routerLink; context: { $implicit: action }\" />\n }\n @case ('link') {\n <ng-container *ngTemplateOutlet=\"link; context: { $implicit: action }\" />\n }\n }\n</ng-template>\n\n<ng-template #content>\n <div class=\"d-flex flex-column gap-3 text-body\">\n <span class=\"si-body text-secondary\">{{ timeStamp() | translate }}</span>\n <span [ngClass]=\"unread() ? 'si-h5-bold' : 'si-h5'\">{{ heading() | translate }}</span>\n @if (description()) {\n <span class=\"si-body\">{{ description() | translate }}</span>\n }\n <div class=\"si-body\">\n <ng-content select=\"[description]\" />\n </div>\n </div>\n</ng-template>\n\n<ng-template #actionButton let-action>\n <button\n type=\"button\"\n class=\"btn btn-ghost btn-sm btn-circle\"\n [attr.aria-label]=\"action.ariaLabel\"\n (click)=\"action.action(action)\"\n >\n <i [ngClass]=\"'icon ' + action.icon\"></i>\n </button>\n</ng-template>\n\n<ng-template #routerLink let-action>\n <a\n class=\"btn btn-ghost btn-sm p-2 btn-circle\"\n [routerLink]=\"action.routerLink\"\n [queryParams]=\"action.extras?.queryParams\"\n [queryParamsHandling]=\"action.extras?.queryParamsHandling\"\n [fragment]=\"action.extras?.fragment\"\n [state]=\"action.extras?.state\"\n [relativeTo]=\"action.extras?.relativeTo ?? activatedRoute\"\n [preserveFragment]=\"action.extras?.preserveFragment\"\n [skipLocationChange]=\"action.extras?.skipLocationChange\"\n [replaceUrl]=\"action.extras?.replaceUrl\"\n [attr.aria-label]=\"action.ariaLabel\"\n >\n <i class=\"icon\" [ngClass]=\"action.icon\"></i>\n </a>\n</ng-template>\n\n<ng-template #link let-action>\n <a\n class=\"btn btn-ghost btn-sm p-2 btn-circle\"\n [href]=\"action.href\"\n [target]=\"action.target\"\n [attr.aria-label]=\"action.ariaLabel\"\n >\n <i class=\"icon\" [ngClass]=\"action.icon\"></i>\n </a>\n</ng-template>\n\n<ng-template #menu let-action>\n <button\n type=\"button\"\n class=\"btn btn-ghost btn-circle btn-sm element-options-vertical\"\n [attr.aria-label]=\"heading() + ' dropdown'\"\n [cdkMenuTriggerFor]=\"actionMenu\"\n ></button>\n\n <ng-template #actionMenu>\n <si-menu-factory [items]=\"action.menuItems\" />\n </ng-template>\n</ng-template>\n", styles: [":host div:empty{display:none!important}:host div:has(.notification-item-content a):hover{background-color:var(--element-base-1-hover)}:host .notification-item{display:grid;grid-template-columns:auto 1fr auto;grid-template-rows:auto auto}:host .notification-item a{text-decoration:none}:host .notification-item a:focus-visible div{outline:var(--element-button-focus-width) solid var(--element-focus-default);outline-offset:var(--element-button-focus-overlay-width)}:host .notification-item .notification-item-indicator{grid-column:1;grid-row:1}:host .notification-item .notification-item-indicator div{position:relative;display:flex;flex-direction:row;justify-content:center;align-items:center}:host .notification-item .notification-item-content{grid-column:2;grid-row:1;flex-grow:1}:host .notification-item .notification-item-primary-action{grid-column:3;grid-row:1/span 2;display:flex;align-items:center;margin-inline-start:8px}:host .notification-item .notification-item-quick-actions{grid-column:2;grid-row:2;display:flex;gap:8px;margin-block-start:8px}:host .dot{display:block;position:absolute;block-size:6px;inline-size:6px;border-radius:50%;background-color:var(--element-ui-1);inset-inline-start:-10px}:host .notification-item-indicator:has(si-avatar){margin-inline-end:16px}:host .notification-item-indicator:has(si-circle-status){margin-inline-end:4px}:host .notification-item-indicator:not(:has(si-avatar,si-circle-status)):has(si-icon){margin-inline-end:8px;margin-block-start:calc(1rem + 2px)}:host .notification-item-indicator:not(:has(si-avatar,si-circle-status,si-icon)){inline-size:0;margin-block-start:calc(1rem + 6px)}:host .notification-item-indicator:not(:has(si-avatar,si-circle-status,si-icon)) div{block-size:1rem}\n"], dependencies: [{ kind: "pipe", type: SiTranslatePipe, name: "translate" }, { kind: "ngmodule", type: RouterModule }, { kind: "directive", type: i1.RouterLink, selector: "[routerLink]", inputs: ["target", "queryParams", "fragment", "queryParamsHandling", "state", "info", "relativeTo", "preserveFragment", "skipLocationChange", "replaceUrl", "routerLink"] }, { kind: "ngmodule", type: CommonModule }, { kind: "directive", type: i2.NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "directive", type: i2.NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: SiMenuFactoryComponent, selector: "si-menu-factory", inputs: ["items", "actionParam"] }, { kind: "directive", type: CdkMenuTrigger, selector: "[cdkMenuTriggerFor]", inputs: ["cdkMenuTriggerFor", "cdkMenuPosition", "cdkMenuTriggerData"], outputs: ["cdkMenuOpened", "cdkMenuClosed"], exportAs: ["cdkMenuTriggerFor"] }] });
|
|
55
|
+
}
|
|
56
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: SiNotificationItemComponent, decorators: [{
|
|
57
|
+
type: Component,
|
|
58
|
+
args: [{ selector: 'si-notification-item', imports: [SiTranslatePipe, RouterModule, CommonModule, SiMenuFactoryComponent, CdkMenuTrigger], template: "<div class=\"notification-item px-6 py-5\">\n <div class=\"notification-item-indicator\">\n <div>\n @if (unread()) {\n <span class=\"dot\"></span>\n }\n <ng-content select=\"si-avatar,si-circle-status,si-icon,si-status-icon\" />\n </div>\n </div>\n\n <div class=\"notification-item-content\">\n @let itemLinkValue = itemLink();\n @if (itemLinkValue) {\n @switch (itemLinkValue.type) {\n @case ('link') {\n <a\n [href]=\"itemLinkValue.href\"\n [target]=\"itemLinkValue.target\"\n [attr.aria-label]=\"heading() + ' link'\"\n >\n <ng-container *ngTemplateOutlet=\"content\" />\n </a>\n }\n @case ('router-link') {\n <a\n [routerLink]=\"itemLinkValue.routerLink\"\n [queryParams]=\"itemLinkValue.extras?.queryParams\"\n [queryParamsHandling]=\"itemLinkValue.extras?.queryParamsHandling\"\n [fragment]=\"itemLinkValue.extras?.fragment\"\n [state]=\"itemLinkValue.extras?.state\"\n [relativeTo]=\"itemLinkValue.extras?.relativeTo ?? activatedRoute\"\n [preserveFragment]=\"itemLinkValue.extras?.preserveFragment\"\n [skipLocationChange]=\"itemLinkValue.extras?.skipLocationChange\"\n [replaceUrl]=\"itemLinkValue.extras?.replaceUrl\"\n [attr.aria-label]=\"heading() + ' link'\"\n >\n <ng-container *ngTemplateOutlet=\"content\" />\n </a>\n }\n }\n } @else {\n <ng-container *ngTemplateOutlet=\"content\" />\n }\n </div>\n\n @let primaryActionValue = primaryAction();\n @if (primaryActionValue) {\n <div class=\"notification-item-primary-action\">\n @if (primaryActionValue.type === 'menu') {\n <ng-container *ngTemplateOutlet=\"menu; context: { $implicit: primaryActionValue }\" />\n } @else if (primaryActionValue.type === 'action-button') {\n <button\n type=\"button\"\n class=\"btn btn-tertiary\"\n (click)=\"primaryActionValue.action(primaryActionValue)\"\n >{{ primaryActionValue.label | translate }}</button\n >\n } @else {\n <ng-container *ngTemplateOutlet=\"action; context: { $implicit: primaryActionValue }\" />\n }\n </div>\n } @else {\n <div class=\"notification-item-primary-action\">\n <ng-content select=\"[action]\" />\n </div>\n }\n\n @let quickActionsValue = quickActions();\n @if (quickActionsValue) {\n <div class=\"notification-item-quick-actions\">\n @for (quickAction of quickActionsValue; track $index) {\n <ng-container *ngTemplateOutlet=\"action; context: { $implicit: quickAction }\" />\n }\n </div>\n } @else {\n <div class=\"notification-item-quick-actions\">\n <ng-content select=\"[quick-actions]\" />\n </div>\n }\n</div>\n\n<ng-template #action let-action>\n @switch (action.type) {\n @case ('action-circle-button') {\n <ng-container *ngTemplateOutlet=\"actionButton; context: { $implicit: action }\" />\n }\n @case ('router-link') {\n <ng-container *ngTemplateOutlet=\"routerLink; context: { $implicit: action }\" />\n }\n @case ('link') {\n <ng-container *ngTemplateOutlet=\"link; context: { $implicit: action }\" />\n }\n }\n</ng-template>\n\n<ng-template #content>\n <div class=\"d-flex flex-column gap-3 text-body\">\n <span class=\"si-body text-secondary\">{{ timeStamp() | translate }}</span>\n <span [ngClass]=\"unread() ? 'si-h5-bold' : 'si-h5'\">{{ heading() | translate }}</span>\n @if (description()) {\n <span class=\"si-body\">{{ description() | translate }}</span>\n }\n <div class=\"si-body\">\n <ng-content select=\"[description]\" />\n </div>\n </div>\n</ng-template>\n\n<ng-template #actionButton let-action>\n <button\n type=\"button\"\n class=\"btn btn-ghost btn-sm btn-circle\"\n [attr.aria-label]=\"action.ariaLabel\"\n (click)=\"action.action(action)\"\n >\n <i [ngClass]=\"'icon ' + action.icon\"></i>\n </button>\n</ng-template>\n\n<ng-template #routerLink let-action>\n <a\n class=\"btn btn-ghost btn-sm p-2 btn-circle\"\n [routerLink]=\"action.routerLink\"\n [queryParams]=\"action.extras?.queryParams\"\n [queryParamsHandling]=\"action.extras?.queryParamsHandling\"\n [fragment]=\"action.extras?.fragment\"\n [state]=\"action.extras?.state\"\n [relativeTo]=\"action.extras?.relativeTo ?? activatedRoute\"\n [preserveFragment]=\"action.extras?.preserveFragment\"\n [skipLocationChange]=\"action.extras?.skipLocationChange\"\n [replaceUrl]=\"action.extras?.replaceUrl\"\n [attr.aria-label]=\"action.ariaLabel\"\n >\n <i class=\"icon\" [ngClass]=\"action.icon\"></i>\n </a>\n</ng-template>\n\n<ng-template #link let-action>\n <a\n class=\"btn btn-ghost btn-sm p-2 btn-circle\"\n [href]=\"action.href\"\n [target]=\"action.target\"\n [attr.aria-label]=\"action.ariaLabel\"\n >\n <i class=\"icon\" [ngClass]=\"action.icon\"></i>\n </a>\n</ng-template>\n\n<ng-template #menu let-action>\n <button\n type=\"button\"\n class=\"btn btn-ghost btn-circle btn-sm element-options-vertical\"\n [attr.aria-label]=\"heading() + ' dropdown'\"\n [cdkMenuTriggerFor]=\"actionMenu\"\n ></button>\n\n <ng-template #actionMenu>\n <si-menu-factory [items]=\"action.menuItems\" />\n </ng-template>\n</ng-template>\n", styles: [":host div:empty{display:none!important}:host div:has(.notification-item-content a):hover{background-color:var(--element-base-1-hover)}:host .notification-item{display:grid;grid-template-columns:auto 1fr auto;grid-template-rows:auto auto}:host .notification-item a{text-decoration:none}:host .notification-item a:focus-visible div{outline:var(--element-button-focus-width) solid var(--element-focus-default);outline-offset:var(--element-button-focus-overlay-width)}:host .notification-item .notification-item-indicator{grid-column:1;grid-row:1}:host .notification-item .notification-item-indicator div{position:relative;display:flex;flex-direction:row;justify-content:center;align-items:center}:host .notification-item .notification-item-content{grid-column:2;grid-row:1;flex-grow:1}:host .notification-item .notification-item-primary-action{grid-column:3;grid-row:1/span 2;display:flex;align-items:center;margin-inline-start:8px}:host .notification-item .notification-item-quick-actions{grid-column:2;grid-row:2;display:flex;gap:8px;margin-block-start:8px}:host .dot{display:block;position:absolute;block-size:6px;inline-size:6px;border-radius:50%;background-color:var(--element-ui-1);inset-inline-start:-10px}:host .notification-item-indicator:has(si-avatar){margin-inline-end:16px}:host .notification-item-indicator:has(si-circle-status){margin-inline-end:4px}:host .notification-item-indicator:not(:has(si-avatar,si-circle-status)):has(si-icon){margin-inline-end:8px;margin-block-start:calc(1rem + 2px)}:host .notification-item-indicator:not(:has(si-avatar,si-circle-status,si-icon)){inline-size:0;margin-block-start:calc(1rem + 6px)}:host .notification-item-indicator:not(:has(si-avatar,si-circle-status,si-icon)) div{block-size:1rem}\n"] }]
|
|
59
|
+
}] });
|
|
60
|
+
|
|
61
|
+
/**
|
|
62
|
+
* Copyright (c) Siemens 2016 - 2025
|
|
63
|
+
* SPDX-License-Identifier: MIT
|
|
64
|
+
*/
|
|
65
|
+
|
|
66
|
+
/**
|
|
67
|
+
* Generated bundle index. Do not edit.
|
|
68
|
+
*/
|
|
69
|
+
|
|
70
|
+
export { SiNotificationItemComponent };
|
|
71
|
+
//# sourceMappingURL=siemens-element-ng-notification-item.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"siemens-element-ng-notification-item.mjs","sources":["../../../../projects/element-ng/notification-item/si-notification-item.component.ts","../../../../projects/element-ng/notification-item/si-notification-item.component.html","../../../../projects/element-ng/notification-item/index.ts","../../../../projects/element-ng/notification-item/siemens-element-ng-notification-item.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nimport { CdkMenuTrigger } from '@angular/cdk/menu';\nimport { CommonModule } from '@angular/common';\nimport { booleanAttribute, Component, inject, input } from '@angular/core';\nimport { ActivatedRoute, RouterModule, type NavigationExtras } from '@angular/router';\nimport { SiMenuFactoryComponent, type MenuItem } from '@siemens/element-ng/menu';\nimport { SiTranslatePipe, TranslatableString } from '@siemens/element-translate-ng/translate';\n\n/**\n * Interface for a router link in a notification item.\n * @param type - The type of the link, always 'router-link'.\n * @param routerLink - The router link to navigate to.\n * @param extras - Optional navigation extras for the router.\n */\nexport interface NotificationItemRouterLink {\n type: 'router-link';\n routerLink: string | any[];\n extras?: NavigationExtras;\n}\n\n/**\n * Interface for a standard link in a notification item.\n * @param type - The type of the link, always 'link'.\n * @param href - The URL to navigate to.\n * @param target - Optional target attribute for the link.\n */\nexport interface NotificationItemLink {\n type: 'link';\n href: string;\n target?: string;\n}\n\n/**\n * Base interface for notification item actions.\n * @param ariaLabel - The ARIA label for accessibility.\n * @param icon - The icon to display for the action.\n */\nexport interface NotificationItemBase {\n ariaLabel: TranslatableString;\n icon: string;\n}\n\n/**\n * Interface for an action circle button in a notification item.\n * @param type - The type of the action, always 'action-circle-button'.\n * @param customClass - Optional custom CSS class for styling.\n * @param action - The action to perform when the button is clicked.\n */\nexport interface NotificationItemActionCircleButton extends NotificationItemBase {\n type: 'action-circle-button';\n customClass?: string;\n action: (source: this) => void;\n}\n\n/**\n * Interface for a router link with an icon in a notification item.\n * @param type - The type of the link, always 'router-link'.\n * @param routerLink - The router link to navigate to.\n * @param extras - Optional navigation extras for the router.\n */\nexport interface NotificationItemRouterLinkIcon extends NotificationItemBase {\n type: 'router-link';\n routerLink: string | any[];\n extras?: NavigationExtras;\n}\n\n/**\n * Interface for a standard link with an icon in a notification item.\n * @param type - The type of the link, always 'link'.\n * @param href - The URL to navigate to.\n * @param target - Optional target attribute for the link.\n */\nexport interface NotificationItemLinkIcon extends NotificationItemBase {\n type: 'link';\n href: string;\n target?: string;\n}\n\n/**\n * Interface for an action button in a notification item.\n * @param type - The type of the action, always 'action-button'.\n * @param label - The label to display on the button.\n * @param action - The action to perform when the button is clicked.\n */\nexport interface NotificationItemActionButton {\n type: 'action-button';\n label: TranslatableString;\n action: (source: this) => void;\n}\n\n/**\n * Interface for a menu in a notification item.\n * @param type - The type of the action, always 'menu'.\n * @param menuItems - The menu items to display in the menu.\n */\nexport interface NotificationItemMenu {\n type: 'menu';\n menuItems: MenuItem[];\n}\n\n/**\n * Union type for quick actions in a notification item.\n */\nexport type NotificationItemQuickAction =\n | NotificationItemActionCircleButton\n | NotificationItemLinkIcon\n | NotificationItemRouterLinkIcon;\n\n/**\n * Union type for primary actions in a notification item.\n */\nexport type NotificationItemPrimaryAction =\n | NotificationItemActionCircleButton\n | NotificationItemLinkIcon\n | NotificationItemRouterLinkIcon\n | NotificationItemMenu\n | NotificationItemActionButton;\n\n/**\n * This component represents a single notification that can be used within notification\n * centers, popovers, or other containers. It supports various action types including\n * router links, standard links, action buttons, and menus.\n */\n@Component({\n selector: 'si-notification-item',\n imports: [SiTranslatePipe, RouterModule, CommonModule, SiMenuFactoryComponent, CdkMenuTrigger],\n templateUrl: './si-notification-item.component.html',\n styleUrl: './si-notification-item.component.scss'\n})\nexport class SiNotificationItemComponent {\n /**\n * The timestamp of the notification item.\n */\n readonly timeStamp = input.required<TranslatableString>();\n /**\n * The heading of the notification item.\n */\n readonly heading = input.required<TranslatableString>();\n /**\n * Optional translatable description.\n */\n readonly description = input<TranslatableString>();\n /**\n * Unread messages are emphasized with a bolder font.\n *\n * @defaultValue false\n */\n readonly unread = input(false, { transform: booleanAttribute });\n /**\n * Link to the source or relevant information of the notification,\n * which triggers when clicking on the notification item text area.\n */\n readonly itemLink = input<NotificationItemRouterLink | NotificationItemLink>();\n /**\n * Actions that are displayed below the text of the notification.\n */\n readonly quickActions = input<NotificationItemQuickAction[]>();\n /**\n * Action that is displayed on the right side of the notification.\n */\n readonly primaryAction = input<NotificationItemPrimaryAction>();\n\n protected readonly activatedRoute = inject(ActivatedRoute, { optional: true });\n}\n","<div class=\"notification-item px-6 py-5\">\n <div class=\"notification-item-indicator\">\n <div>\n @if (unread()) {\n <span class=\"dot\"></span>\n }\n <ng-content select=\"si-avatar,si-circle-status,si-icon,si-status-icon\" />\n </div>\n </div>\n\n <div class=\"notification-item-content\">\n @let itemLinkValue = itemLink();\n @if (itemLinkValue) {\n @switch (itemLinkValue.type) {\n @case ('link') {\n <a\n [href]=\"itemLinkValue.href\"\n [target]=\"itemLinkValue.target\"\n [attr.aria-label]=\"heading() + ' link'\"\n >\n <ng-container *ngTemplateOutlet=\"content\" />\n </a>\n }\n @case ('router-link') {\n <a\n [routerLink]=\"itemLinkValue.routerLink\"\n [queryParams]=\"itemLinkValue.extras?.queryParams\"\n [queryParamsHandling]=\"itemLinkValue.extras?.queryParamsHandling\"\n [fragment]=\"itemLinkValue.extras?.fragment\"\n [state]=\"itemLinkValue.extras?.state\"\n [relativeTo]=\"itemLinkValue.extras?.relativeTo ?? activatedRoute\"\n [preserveFragment]=\"itemLinkValue.extras?.preserveFragment\"\n [skipLocationChange]=\"itemLinkValue.extras?.skipLocationChange\"\n [replaceUrl]=\"itemLinkValue.extras?.replaceUrl\"\n [attr.aria-label]=\"heading() + ' link'\"\n >\n <ng-container *ngTemplateOutlet=\"content\" />\n </a>\n }\n }\n } @else {\n <ng-container *ngTemplateOutlet=\"content\" />\n }\n </div>\n\n @let primaryActionValue = primaryAction();\n @if (primaryActionValue) {\n <div class=\"notification-item-primary-action\">\n @if (primaryActionValue.type === 'menu') {\n <ng-container *ngTemplateOutlet=\"menu; context: { $implicit: primaryActionValue }\" />\n } @else if (primaryActionValue.type === 'action-button') {\n <button\n type=\"button\"\n class=\"btn btn-tertiary\"\n (click)=\"primaryActionValue.action(primaryActionValue)\"\n >{{ primaryActionValue.label | translate }}</button\n >\n } @else {\n <ng-container *ngTemplateOutlet=\"action; context: { $implicit: primaryActionValue }\" />\n }\n </div>\n } @else {\n <div class=\"notification-item-primary-action\">\n <ng-content select=\"[action]\" />\n </div>\n }\n\n @let quickActionsValue = quickActions();\n @if (quickActionsValue) {\n <div class=\"notification-item-quick-actions\">\n @for (quickAction of quickActionsValue; track $index) {\n <ng-container *ngTemplateOutlet=\"action; context: { $implicit: quickAction }\" />\n }\n </div>\n } @else {\n <div class=\"notification-item-quick-actions\">\n <ng-content select=\"[quick-actions]\" />\n </div>\n }\n</div>\n\n<ng-template #action let-action>\n @switch (action.type) {\n @case ('action-circle-button') {\n <ng-container *ngTemplateOutlet=\"actionButton; context: { $implicit: action }\" />\n }\n @case ('router-link') {\n <ng-container *ngTemplateOutlet=\"routerLink; context: { $implicit: action }\" />\n }\n @case ('link') {\n <ng-container *ngTemplateOutlet=\"link; context: { $implicit: action }\" />\n }\n }\n</ng-template>\n\n<ng-template #content>\n <div class=\"d-flex flex-column gap-3 text-body\">\n <span class=\"si-body text-secondary\">{{ timeStamp() | translate }}</span>\n <span [ngClass]=\"unread() ? 'si-h5-bold' : 'si-h5'\">{{ heading() | translate }}</span>\n @if (description()) {\n <span class=\"si-body\">{{ description() | translate }}</span>\n }\n <div class=\"si-body\">\n <ng-content select=\"[description]\" />\n </div>\n </div>\n</ng-template>\n\n<ng-template #actionButton let-action>\n <button\n type=\"button\"\n class=\"btn btn-ghost btn-sm btn-circle\"\n [attr.aria-label]=\"action.ariaLabel\"\n (click)=\"action.action(action)\"\n >\n <i [ngClass]=\"'icon ' + action.icon\"></i>\n </button>\n</ng-template>\n\n<ng-template #routerLink let-action>\n <a\n class=\"btn btn-ghost btn-sm p-2 btn-circle\"\n [routerLink]=\"action.routerLink\"\n [queryParams]=\"action.extras?.queryParams\"\n [queryParamsHandling]=\"action.extras?.queryParamsHandling\"\n [fragment]=\"action.extras?.fragment\"\n [state]=\"action.extras?.state\"\n [relativeTo]=\"action.extras?.relativeTo ?? activatedRoute\"\n [preserveFragment]=\"action.extras?.preserveFragment\"\n [skipLocationChange]=\"action.extras?.skipLocationChange\"\n [replaceUrl]=\"action.extras?.replaceUrl\"\n [attr.aria-label]=\"action.ariaLabel\"\n >\n <i class=\"icon\" [ngClass]=\"action.icon\"></i>\n </a>\n</ng-template>\n\n<ng-template #link let-action>\n <a\n class=\"btn btn-ghost btn-sm p-2 btn-circle\"\n [href]=\"action.href\"\n [target]=\"action.target\"\n [attr.aria-label]=\"action.ariaLabel\"\n >\n <i class=\"icon\" [ngClass]=\"action.icon\"></i>\n </a>\n</ng-template>\n\n<ng-template #menu let-action>\n <button\n type=\"button\"\n class=\"btn btn-ghost btn-circle btn-sm element-options-vertical\"\n [attr.aria-label]=\"heading() + ' dropdown'\"\n [cdkMenuTriggerFor]=\"actionMenu\"\n ></button>\n\n <ng-template #actionMenu>\n <si-menu-factory [items]=\"action.menuItems\" />\n </ng-template>\n</ng-template>\n","/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-notification-item.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;AAAA;;;AAGG;AAsHH;;;;AAIG;MAOU,2BAA2B,CAAA;AACtC;;AAEG;AACM,IAAA,SAAS,GAAG,KAAK,CAAC,QAAQ,EAAsB;AACzD;;AAEG;AACM,IAAA,OAAO,GAAG,KAAK,CAAC,QAAQ,EAAsB;AACvD;;AAEG;IACM,WAAW,GAAG,KAAK,EAAsB;AAClD;;;;AAIG;IACM,MAAM,GAAG,KAAK,CAAC,KAAK,EAAE,EAAE,SAAS,EAAE,gBAAgB,EAAE,CAAC;AAC/D;;;AAGG;IACM,QAAQ,GAAG,KAAK,EAAqD;AAC9E;;AAEG;IACM,YAAY,GAAG,KAAK,EAAiC;AAC9D;;AAEG;IACM,aAAa,GAAG,KAAK,EAAiC;IAE5C,cAAc,GAAG,MAAM,CAAC,cAAc,EAAE,EAAE,QAAQ,EAAE,IAAI,EAAE,CAAC;uGAjCnE,2BAA2B,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;2FAA3B,2BAA2B,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,sBAAA,EAAA,MAAA,EAAA,EAAA,SAAA,EAAA,EAAA,iBAAA,EAAA,WAAA,EAAA,UAAA,EAAA,WAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,OAAA,EAAA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Page.set(page);
|
|
108
108
|
}
|
|
109
109
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: SiPaginationComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
110
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.0.6", type: SiPaginationComponent, isStandalone: true, selector: "si-pagination", inputs: { totalPages: { classPropertyName: "totalPages", publicName: "totalPages", isSignal: true, isRequired: false, transformFunction: null }, currentPage: { classPropertyName: "currentPage", publicName: "currentPage", isSignal: true, isRequired: false, transformFunction: null }, pageSize: { classPropertyName: "pageSize", publicName: "pageSize", isSignal: true, isRequired: false, transformFunction: null }, totalRowCount: { classPropertyName: "totalRowCount", publicName: "totalRowCount", isSignal: true, isRequired: false, transformFunction: null }, backButtonText: { classPropertyName: "backButtonText", publicName: "backButtonText", isSignal: true, isRequired: false, transformFunction: null }, forwardButtonText: { classPropertyName: "forwardButtonText", publicName: "forwardButtonText", isSignal: true, isRequired: false, transformFunction: null }, navAriaLabel: { classPropertyName: "navAriaLabel", publicName: "navAriaLabel", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { currentPage: "currentPageChange" }, ngImport: i0, template: "<nav role=\"navigation\" [attr.aria-label]=\"navAriaLabel() | translate\">\n <ul class=\"pagination\">\n <li class=\"me-5\">\n <button\n type=\"button\"\n class=\"page-item mx-4\"\n [class.disabled]=\"prevDisabled()\"\n [disabled]=\"prevDisabled()\"\n [attr.aria-label]=\"backButtonText() | translate\"\n (click)=\"direction($event, -1)\"\n >\n <si-icon class=\"icon flip-rtl\" [icon]=\"icons.elementLeft3\" />\n </button>\n </li>\n @for (page of pageButtons(); track $index) {\n <li>\n @if (!page.sep) {\n <button\n type=\"button\"\n class=\"page-item\"\n [attr.aria-current]=\"page.page === currentPage() ? 'page' : ''\"\n [class.active]=\"page.page === currentPage()\"\n [disabled]=\"page.page === currentPage()\"\n (click)=\"setPage($event, page.page)\"\n >\n {{ page.page }}\n </button>\n }
|
|
110
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "20.0.6", type: SiPaginationComponent, isStandalone: true, selector: "si-pagination", inputs: { totalPages: { classPropertyName: "totalPages", publicName: "totalPages", isSignal: true, isRequired: false, transformFunction: null }, currentPage: { classPropertyName: "currentPage", publicName: "currentPage", isSignal: true, isRequired: false, transformFunction: null }, pageSize: { classPropertyName: "pageSize", publicName: "pageSize", isSignal: true, isRequired: false, transformFunction: null }, totalRowCount: { classPropertyName: "totalRowCount", publicName: "totalRowCount", isSignal: true, isRequired: false, transformFunction: null }, backButtonText: { classPropertyName: "backButtonText", publicName: "backButtonText", isSignal: true, isRequired: false, transformFunction: null }, forwardButtonText: { classPropertyName: "forwardButtonText", publicName: "forwardButtonText", isSignal: true, isRequired: false, transformFunction: null }, navAriaLabel: { classPropertyName: "navAriaLabel", publicName: "navAriaLabel", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { currentPage: "currentPageChange" }, ngImport: i0, template: "<nav role=\"navigation\" [attr.aria-label]=\"navAriaLabel() | translate\">\n <ul class=\"pagination\">\n <li class=\"me-5\">\n <button\n type=\"button\"\n class=\"page-item mx-4\"\n [class.disabled]=\"prevDisabled()\"\n [disabled]=\"prevDisabled()\"\n [attr.aria-label]=\"backButtonText() | translate\"\n (click)=\"direction($event, -1)\"\n >\n <si-icon class=\"icon flip-rtl\" [icon]=\"icons.elementLeft3\" />\n </button>\n </li>\n @for (page of pageButtons(); track $index) {\n <li>\n @if (!page.sep) {\n <button\n type=\"button\"\n class=\"page-item\"\n [attr.aria-current]=\"page.page === currentPage() ? 'page' : ''\"\n [class.active]=\"page.page === currentPage()\"\n [disabled]=\"page.page === currentPage()\"\n (click)=\"setPage($event, page.page)\"\n >\n {{ page.page }}\n </button>\n } @else {\n <span class=\"page-item separator mx-2\">…</span>\n }\n </li>\n }\n <li class=\"ms-5\">\n <button\n type=\"button\"\n class=\"page-item mx-4\"\n [class.disabled]=\"nextDisabled()\"\n [disabled]=\"nextDisabled()\"\n [attr.aria-label]=\"forwardButtonText() | translate\"\n (click)=\"direction($event, 1)\"\n >\n <si-icon class=\"icon flip-rtl\" [icon]=\"icons.elementRight3\" />\n </button>\n </li>\n </ul>\n</nav>\n", dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
111
111
|
}
|
|
112
112
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "20.0.6", ngImport: i0, type: SiPaginationComponent, decorators: [{
|
|
113
113
|
type: Component,
|
|
114
|
-
args: [{ selector: 'si-pagination', imports: [SiIconComponent, SiTranslatePipe], changeDetection: ChangeDetectionStrategy.OnPush, template: "<nav role=\"navigation\" [attr.aria-label]=\"navAriaLabel() | translate\">\n <ul class=\"pagination\">\n <li class=\"me-5\">\n <button\n type=\"button\"\n class=\"page-item mx-4\"\n [class.disabled]=\"prevDisabled()\"\n [disabled]=\"prevDisabled()\"\n [attr.aria-label]=\"backButtonText() | translate\"\n (click)=\"direction($event, -1)\"\n >\n <si-icon class=\"icon flip-rtl\" [icon]=\"icons.elementLeft3\" />\n </button>\n </li>\n @for (page of pageButtons(); track $index) {\n <li>\n @if (!page.sep) {\n <button\n type=\"button\"\n class=\"page-item\"\n [attr.aria-current]=\"page.page === currentPage() ? 'page' : ''\"\n [class.active]=\"page.page === currentPage()\"\n [disabled]=\"page.page === currentPage()\"\n (click)=\"setPage($event, page.page)\"\n >\n {{ page.page }}\n </button>\n }
|
|
114
|
+
args: [{ selector: 'si-pagination', imports: [SiIconComponent, SiTranslatePipe], changeDetection: ChangeDetectionStrategy.OnPush, template: "<nav role=\"navigation\" [attr.aria-label]=\"navAriaLabel() | translate\">\n <ul class=\"pagination\">\n <li class=\"me-5\">\n <button\n type=\"button\"\n class=\"page-item mx-4\"\n [class.disabled]=\"prevDisabled()\"\n [disabled]=\"prevDisabled()\"\n [attr.aria-label]=\"backButtonText() | translate\"\n (click)=\"direction($event, -1)\"\n >\n <si-icon class=\"icon flip-rtl\" [icon]=\"icons.elementLeft3\" />\n </button>\n </li>\n @for (page of pageButtons(); track $index) {\n <li>\n @if (!page.sep) {\n <button\n type=\"button\"\n class=\"page-item\"\n [attr.aria-current]=\"page.page === currentPage() ? 'page' : ''\"\n [class.active]=\"page.page === currentPage()\"\n [disabled]=\"page.page === currentPage()\"\n (click)=\"setPage($event, page.page)\"\n >\n {{ page.page }}\n </button>\n } @else {\n <span class=\"page-item separator mx-2\">…</span>\n }\n </li>\n }\n <li class=\"ms-5\">\n <button\n type=\"button\"\n class=\"page-item mx-4\"\n [class.disabled]=\"nextDisabled()\"\n [disabled]=\"nextDisabled()\"\n [attr.aria-label]=\"forwardButtonText() | translate\"\n (click)=\"direction($event, 1)\"\n >\n <si-icon class=\"icon flip-rtl\" [icon]=\"icons.elementRight3\" />\n </button>\n </li>\n </ul>\n</nav>\n" }]
|
|
115
115
|
}] });
|
|
116
116
|
|
|
117
117
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"siemens-element-ng-pagination.mjs","sources":["../../../../projects/element-ng/pagination/si-pagination.component.ts","../../../../projects/element-ng/pagination/si-pagination.component.html","../../../../projects/element-ng/pagination/si-pagination.module.ts","../../../../projects/element-ng/pagination/index.ts","../../../../projects/element-ng/pagination/siemens-element-ng-pagination.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nimport { ChangeDetectionStrategy, Component, computed, input, model } from '@angular/core';\nimport { addIcons, elementLeft3, elementRight3, SiIconComponent } from '@siemens/element-ng/icon';\nimport { SiTranslatePipe, t } from '@siemens/element-translate-ng/translate';\n\n@Component({\n selector: 'si-pagination',\n imports: [SiIconComponent, SiTranslatePipe],\n templateUrl: './si-pagination.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class SiPaginationComponent {\n private static maxItems = 7;\n\n /**\n * The total number of pages.\n * Alternatively use `itemsPerPage` and `totalItems`\n */\n readonly totalPages = input<number>();\n /**\n * The current active page, counting starts from 1\n *\n * @defaultValue 1\n */\n readonly currentPage = model<number>(1);\n /**\n * The number of items per page.\n * Used to calculate the total number of page if `totalPages` is not available\n */\n readonly pageSize = input<number>();\n /**\n * The total number of items.\n * Used to calculate the total number of page if `totalPages` is not available\n */\n readonly totalRowCount = input<number>();\n\n /**\n * The text of the back button for pagination. Required for a11y.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PAGINATION.BACK:Back`)\n * ```\n */\n readonly backButtonText = input(t(() => $localize`:@@SI_PAGINATION.BACK:Back`));\n\n /**\n * The text of the forward button for pagination. Required for a11y.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PAGINATION.FORWARD:Forward`)\n * ```\n */\n readonly forwardButtonText = input(t(() => $localize`:@@SI_PAGINATION.FORWARD:Forward`));\n /**\n * When multiple paginations are used on the same page each pagination needs a distinct aria label.\n * Required for a11y.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PAGINATION.NAV_LABEL:Pagination`)\n * ```\n */\n readonly navAriaLabel = input(t(() => $localize`:@@SI_PAGINATION.NAV_LABEL:Pagination`));\n\n private readonly calculatedTotalPages = computed(\n () => this.totalPages() ?? Math.ceil((this.totalRowCount() ?? 0) / (this.pageSize() ?? 1))\n );\n\n protected readonly prevDisabled = computed(() => this.currentPage() === 1);\n\n protected readonly nextDisabled = computed(\n () => this.currentPage() === this.calculatedTotalPages()\n );\n\n protected readonly pageButtons = computed(() => {\n const pageButtons: { page: number; sep: boolean }[] = [];\n const totalPages = this.calculatedTotalPages();\n const currentPage = this.currentPage();\n\n if (totalPages <= SiPaginationComponent.maxItems) {\n for (let i = 0; i < totalPages; i++) {\n pageButtons.push({ page: i + 1, sep: false });\n }\n } else if (currentPage < SiPaginationComponent.maxItems - 2) {\n // separator only on the right (in LTR)\n for (let i = 0; i < SiPaginationComponent.maxItems - 2; i++) {\n pageButtons.push({ page: i + 1, sep: false });\n }\n pageButtons.push({ page: 0, sep: true });\n pageButtons.push({ page: totalPages, sep: false });\n } else if (currentPage >= totalPages - 3) {\n // separator only on the left (in LTR)\n pageButtons.push({ page: 1, sep: false });\n pageButtons.push({ page: 0, sep: true });\n for (let i = totalPages - SiPaginationComponent.maxItems + 2; i < totalPages; i++) {\n pageButtons.push({ page: i + 1, sep: false });\n }\n } else {\n // separator on both sides\n pageButtons.push({ page: 1, sep: false });\n pageButtons.push({ page: 0, sep: true });\n for (let i = -1; i <= 1; i++) {\n pageButtons.push({ page: currentPage + i, sep: false });\n }\n pageButtons.push({ page: 0, sep: true });\n pageButtons.push({ page: totalPages, sep: false });\n }\n\n return pageButtons;\n });\n\n protected readonly icons = addIcons({ elementLeft3, elementRight3 });\n\n protected direction(event: Event, delta: number): void {\n this.setPage(event, this.currentPage() + delta);\n }\n\n protected setPage(event: Event, page: number): void {\n (event.currentTarget as HTMLElement).blur();\n this.currentPage.set(page);\n }\n}\n","<nav role=\"navigation\" [attr.aria-label]=\"navAriaLabel() | translate\">\n <ul class=\"pagination\">\n <li class=\"me-5\">\n <button\n type=\"button\"\n class=\"page-item mx-4\"\n [class.disabled]=\"prevDisabled()\"\n [disabled]=\"prevDisabled()\"\n [attr.aria-label]=\"backButtonText() | translate\"\n (click)=\"direction($event, -1)\"\n >\n <si-icon class=\"icon flip-rtl\" [icon]=\"icons.elementLeft3\" />\n </button>\n </li>\n @for (page of pageButtons(); track $index) {\n <li>\n @if (!page.sep) {\n <button\n type=\"button\"\n class=\"page-item\"\n [attr.aria-current]=\"page.page === currentPage() ? 'page' : ''\"\n [class.active]=\"page.page === currentPage()\"\n [disabled]=\"page.page === currentPage()\"\n (click)=\"setPage($event, page.page)\"\n >\n {{ page.page }}\n </button>\n }\n @if (page.sep) {\n <span class=\"page-item separator mx-2\">…</span>\n }\n </li>\n }\n <li class=\"ms-5\">\n <button\n type=\"button\"\n class=\"page-item mx-4\"\n [class.disabled]=\"nextDisabled()\"\n [disabled]=\"nextDisabled()\"\n [attr.aria-label]=\"forwardButtonText() | translate\"\n (click)=\"direction($event, 1)\"\n >\n <si-icon class=\"icon flip-rtl\" [icon]=\"icons.elementRight3\" />\n </button>\n </li>\n </ul>\n</nav>\n","/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nimport { NgModule } from '@angular/core';\n\nimport { SiPaginationComponent } from './si-pagination.component';\n\n@NgModule({\n imports: [SiPaginationComponent],\n exports: [SiPaginationComponent]\n})\nexport class SiPaginationModule {}\n","/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-pagination.component';\nexport * from './si-pagination.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AAAA;;;AAGG;MAWU,qBAAqB,CAAA;AACxB,IAAA,OAAO,QAAQ,GAAG,CAAC;AAE3B;;;AAGG;IACM,UAAU,GAAG,KAAK,EAAU;AACrC;;;;AAIG;AACM,IAAA,WAAW,GAAG,KAAK,CAAS,CAAC,CAAC;AACvC;;;AAGG;IACM,QAAQ,GAAG,KAAK,EAAU;AACnC;;;AAGG;IACM,aAAa,GAAG,KAAK,EAAU;AAExC;;;;;;;AAOG;AACM,IAAA,cAAc,GAAG,KAAK,CAAC,CAAC,CAAC,MAAM,SAAS,CAAA,CAAA,0BAAA,CAA4B,CAAC,CAAC;AAE/E;;;;;;;AAOG;AACM,IAAA,iBAAiB,GAAG,KAAK,CAAC,CAAC,CAAC,MAAM,SAAS,CAAA,CAAA,gCAAA,CAAkC,CAAC,CAAC;AACxF;;;;;;;;AAQG;AACM,IAAA,YAAY,GAAG,KAAK,CAAC,CAAC,CAAC,MAAM,SAAS,CAAA,CAAA,qCAAA,CAAuC,CAAC,CAAC;AAEvE,IAAA,oBAAoB,GAAG,QAAQ,CAC9C,MAAM,IAAI,CAAC,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A,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,kBAAkB,YAHnB,qBAAqB,CAAA,EAAA,CAAA;;2FAGpB,kBAAkB,EAAA,UAAA,EAAA,CAAA;kBAJ9B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,qBAAqB,CAAC;oBAChC,OAAO,EAAE,CAAC,qBAAqB;AAChC,iBAAA;;;ACXD;;;AAGG;;ACHH;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"siemens-element-ng-pagination.mjs","sources":["../../../../projects/element-ng/pagination/si-pagination.component.ts","../../../../projects/element-ng/pagination/si-pagination.component.html","../../../../projects/element-ng/pagination/si-pagination.module.ts","../../../../projects/element-ng/pagination/index.ts","../../../../projects/element-ng/pagination/siemens-element-ng-pagination.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nimport { ChangeDetectionStrategy, Component, computed, input, model } from '@angular/core';\nimport { addIcons, elementLeft3, elementRight3, SiIconComponent } from '@siemens/element-ng/icon';\nimport { SiTranslatePipe, t } from '@siemens/element-translate-ng/translate';\n\n@Component({\n selector: 'si-pagination',\n imports: [SiIconComponent, SiTranslatePipe],\n templateUrl: './si-pagination.component.html',\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class SiPaginationComponent {\n private static maxItems = 7;\n\n /**\n * The total number of pages.\n * Alternatively use `itemsPerPage` and `totalItems`\n */\n readonly totalPages = input<number>();\n /**\n * The current active page, counting starts from 1\n *\n * @defaultValue 1\n */\n readonly currentPage = model<number>(1);\n /**\n * The number of items per page.\n * Used to calculate the total number of page if `totalPages` is not available\n */\n readonly pageSize = input<number>();\n /**\n * The total number of items.\n * Used to calculate the total number of page if `totalPages` is not available\n */\n readonly totalRowCount = input<number>();\n\n /**\n * The text of the back button for pagination. Required for a11y.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PAGINATION.BACK:Back`)\n * ```\n */\n readonly backButtonText = input(t(() => $localize`:@@SI_PAGINATION.BACK:Back`));\n\n /**\n * The text of the forward button for pagination. Required for a11y.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PAGINATION.FORWARD:Forward`)\n * ```\n */\n readonly forwardButtonText = input(t(() => $localize`:@@SI_PAGINATION.FORWARD:Forward`));\n /**\n * When multiple paginations are used on the same page each pagination needs a distinct aria label.\n * Required for a11y.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PAGINATION.NAV_LABEL:Pagination`)\n * ```\n */\n readonly navAriaLabel = input(t(() => $localize`:@@SI_PAGINATION.NAV_LABEL:Pagination`));\n\n private readonly calculatedTotalPages = computed(\n () => this.totalPages() ?? Math.ceil((this.totalRowCount() ?? 0) / (this.pageSize() ?? 1))\n );\n\n protected readonly prevDisabled = computed(() => this.currentPage() === 1);\n\n protected readonly nextDisabled = computed(\n () => this.currentPage() === this.calculatedTotalPages()\n );\n\n protected readonly pageButtons = computed(() => {\n const pageButtons: { page: number; sep: boolean }[] = [];\n const totalPages = this.calculatedTotalPages();\n const currentPage = this.currentPage();\n\n if (totalPages <= SiPaginationComponent.maxItems) {\n for (let i = 0; i < totalPages; i++) {\n pageButtons.push({ page: i + 1, sep: false });\n }\n } else if (currentPage < SiPaginationComponent.maxItems - 2) {\n // separator only on the right (in LTR)\n for (let i = 0; i < SiPaginationComponent.maxItems - 2; i++) {\n pageButtons.push({ page: i + 1, sep: false });\n }\n pageButtons.push({ page: 0, sep: true });\n pageButtons.push({ page: totalPages, sep: false });\n } else if (currentPage >= totalPages - 3) {\n // separator only on the left (in LTR)\n pageButtons.push({ page: 1, sep: false });\n pageButtons.push({ page: 0, sep: true });\n for (let i = totalPages - SiPaginationComponent.maxItems + 2; i < totalPages; i++) {\n pageButtons.push({ page: i + 1, sep: false });\n }\n } else {\n // separator on both sides\n pageButtons.push({ page: 1, sep: false });\n pageButtons.push({ page: 0, sep: true });\n for (let i = -1; i <= 1; i++) {\n pageButtons.push({ page: currentPage + i, sep: false });\n }\n pageButtons.push({ page: 0, sep: true });\n pageButtons.push({ page: totalPages, sep: false });\n }\n\n return pageButtons;\n });\n\n protected readonly icons = addIcons({ elementLeft3, elementRight3 });\n\n protected direction(event: Event, delta: number): void {\n this.setPage(event, this.currentPage() + delta);\n }\n\n protected setPage(event: Event, page: number): void {\n (event.currentTarget as HTMLElement).blur();\n this.currentPage.set(page);\n }\n}\n","<nav role=\"navigation\" [attr.aria-label]=\"navAriaLabel() | translate\">\n <ul class=\"pagination\">\n <li class=\"me-5\">\n <button\n type=\"button\"\n class=\"page-item mx-4\"\n [class.disabled]=\"prevDisabled()\"\n [disabled]=\"prevDisabled()\"\n [attr.aria-label]=\"backButtonText() | translate\"\n (click)=\"direction($event, -1)\"\n >\n <si-icon class=\"icon flip-rtl\" [icon]=\"icons.elementLeft3\" />\n </button>\n </li>\n @for (page of pageButtons(); track $index) {\n <li>\n @if (!page.sep) {\n <button\n type=\"button\"\n class=\"page-item\"\n [attr.aria-current]=\"page.page === currentPage() ? 'page' : ''\"\n [class.active]=\"page.page === currentPage()\"\n [disabled]=\"page.page === currentPage()\"\n (click)=\"setPage($event, page.page)\"\n >\n {{ page.page }}\n </button>\n } @else {\n <span class=\"page-item separator mx-2\">…</span>\n }\n </li>\n }\n <li class=\"ms-5\">\n <button\n type=\"button\"\n class=\"page-item mx-4\"\n [class.disabled]=\"nextDisabled()\"\n [disabled]=\"nextDisabled()\"\n [attr.aria-label]=\"forwardButtonText() | translate\"\n (click)=\"direction($event, 1)\"\n >\n <si-icon class=\"icon flip-rtl\" [icon]=\"icons.elementRight3\" />\n </button>\n </li>\n </ul>\n</nav>\n","/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nimport { NgModule } from '@angular/core';\n\nimport { SiPaginationComponent } from './si-pagination.component';\n\n@NgModule({\n imports: [SiPaginationComponent],\n exports: [SiPaginationComponent]\n})\nexport class SiPaginationModule {}\n","/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-pagination.component';\nexport * from './si-pagination.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AAAA;;;AAGG;MAWU,qBAAqB,CAAA;AACxB,IAAA,OAAO,QAAQ,GAAG,CAAC;AAE3B;;;AAGG;IACM,UAAU,GAAG,KAAK,EAAU;AACrC;;;;AAIG;AACM,IAAA,WAAW,GAAG,KAAK,CAAS,CAAC,CAAC;AACvC;;;AAGG;IACM,QAAQ,GAAG,KAAK,EAAU;AACnC;;;AAGG;IACM,aAAa,GAAG,KAAK,EAAU;AAExC;;;;;;;AAOG;AACM,IAAA,cAAc,GAAG,KAAK,CAAC,CAAC,CAAC,MAAM,SAAS,CAAA,CAAA,0BAAA,CAA4B,CAAC,CAAC;AAE/E;;;;;;;AAOG;AACM,IAAA,iBAAiB,GAAG,KAAK,CAAC,CAAC,CAAC,MAAM,SAAS,CAAA,CAAA,gCAAA,CAAkC,CAAC,CAAC;AACxF;;;;;;;;AAQG;AACM,IAAA,YAAY,GAAG,KAAK,CAAC,CAAC,CAAC,MAAM,SAAS,CAAA,CAAA,qCAAA,CAAuC,CAAC,CAAC;AAEvE,IAAA,oBAAoB,GAAG,QAAQ,CAC9C,MAAM,IAAI,CAAC,UAAU,EAAE,IAAI,IAAI,CAAC,IAAI,CAAC,CAAC,IAAI,CAAC,aAAa,EAAE,IAAI,CAAC,KAAK,IAAI,CAAC,QAAQ,EAAE,IAAI,CAAC,CAAC,CAAC,CAC3F;AAEkB,IAAA,YAAY,GAAG,QAAQ,CAAC,MAAM,IAAI,CAAC,WAAW,EAAE,KAAK,CAAC,CAAC;AAEvD,IAAA,YAAY,GAAG,QAAQ,CACxC,MAAM,IAAI,CAAC,WAAW,EAAE,KAAK,IAAI,CAAC,oBAAoB,EAAE,CACzD;AAEkB,IAAA,WAAW,GAAG,QAAQ,CAAC,MAAK;QAC7C,MAAM,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.croppedPhoto.set(undefined);
|
|
300
300
|
}
|
|
301
|
-
if (changes.sourcePhoto
|
|
301
|
+
if (changes.sourcePhoto?.currentValue !== this.imageCropperPhoto()) {
|
|
302
302
|
const sourcePhoto = this.sourcePhoto();
|
|
303
303
|
this.setPhoto(sourcePhoto);
|
|
304
304
|
this.cropperPosition = undefined;
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"siemens-element-ng-photo-upload.mjs","sources":["../../../../projects/element-ng/photo-upload/si-image-cropper-style.component.ts","../../../../projects/element-ng/photo-upload/si-photo-upload.component.ts","../../../../projects/element-ng/photo-upload/si-photo-upload.component.html","../../../../projects/element-ng/photo-upload/index.ts","../../../../projects/element-ng/photo-upload/siemens-element-ng-photo-upload.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nimport { Component } from '@angular/core';\n\n@Component({\n selector: 'si-image-cropper-style',\n template: '<ng-content />',\n styleUrl: './si-image-cropper-style.component.scss'\n})\nexport class SiImageCropperStyleComponent {}\n","/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nimport { NgTemplateOutlet } from '@angular/common';\nimport {\n booleanAttribute,\n ChangeDetectionStrategy,\n Component,\n computed,\n ElementRef,\n inject,\n input,\n model,\n OnChanges,\n OnDestroy,\n signal,\n SimpleChanges,\n TemplateRef,\n viewChild\n} from '@angular/core';\nimport { DomSanitizer, SafeResourceUrl } from '@angular/platform-browser';\nimport { SiAvatarBackgroundColorDirective } from '@siemens/element-ng/avatar';\nimport {\n addIcons,\n elementCancel,\n elementCircleFilled,\n elementStateExclamationMark,\n SiIconComponent\n} from '@siemens/element-ng/icon';\nimport { ModalRef, SiModalService } from '@siemens/element-ng/modal';\nimport { SiTranslatePipe, t, TranslatableString } from '@siemens/element-translate-ng/translate';\nimport { CropperPosition, ImageCroppedEvent, ImageCropperComponent } from 'ngx-image-cropper';\n\nimport { SiImageCropperStyleComponent } from './si-image-cropper-style.component';\n\n/**\n * A component used to upload, edit, and delete a user's photo. The user can upload\n * a photo either via file browser or a URL to the photo. You can set the source\n * photo with the `sourcePhoto` Data URL input or the `sourcePhotoUrl` URL input.\n * If you already have a cropped image you can set it with the `croppedPhoto` input.\n * Cropping changes are emitted via the `croppedPhotoChange` output.\n */\n@Component({\n selector: 'si-photo-upload',\n imports: [\n NgTemplateOutlet,\n ImageCropperComponent,\n SiIconComponent,\n SiImageCropperStyleComponent,\n SiTranslatePipe\n ],\n templateUrl: './si-photo-upload.component.html',\n styleUrl: './si-photo-upload.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n hostDirectives: [\n {\n directive: SiAvatarBackgroundColorDirective,\n inputs: ['color', 'autoColor']\n }\n ]\n})\nexport class SiPhotoUploadComponent implements OnChanges, OnDestroy {\n private static idCounter = 0;\n\n /**\n * Indicate that changing or uploads are disabled.\n *\n * @defaultValue false\n */\n readonly readonly = input(false, { transform: booleanAttribute });\n\n /**\n * Optionally disable image cropping.\n *\n * @defaultValue false\n */\n readonly disabledCropping = input(false, { transform: booleanAttribute });\n\n /**\n * Accepted image formats for the file selection dialog.\n *\n * @defaultValue '.png, .jpg, .jpeg'\n *\n * @see\n *\n * https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/file#attr-accept\n */\n readonly acceptedUploadFormats = input('.png, .jpg, .jpeg');\n\n /**\n * Maximum allowed file size of the uploaded file in kilobytes.\n *\n * @defaultValue 2048\n */\n readonly maxFileSize = input(2048);\n\n /**\n * If the uploaded file is of an unsupported type, this\n * error message will be displayed to the user.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.ERROR_FILE_TYPE:The image file is not valid. Please upload a PNG or JP(E)G.`)\n * ```\n */\n readonly uploadErrorWrongType = input(\n t(\n () =>\n $localize`:@@SI_PHOTO_UPLOAD.ERROR_FILE_TYPE:The image file is not valid. Please upload a PNG or JP(E)G.`\n )\n );\n\n /**\n * If the uploaded file exceeds the allowed upload size, this\n * error message will be displayed to the user.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.ERROR_FILE_SIZE_EXCEEDED:The actual file size {{mb}} MB exceeds the {{maxSizeMb}} MB limit.`)\n * ```\n */\n readonly uploadErrorTooBig = input(\n t(\n () =>\n $localize`:@@SI_PHOTO_UPLOAD.ERROR_FILE_SIZE_EXCEEDED:The actual file size {{mb}} MB exceeds the {{maxSizeMb}} MB limit.`\n )\n );\n\n /**\n * Alternative text for the photo.\n *\n * @defaultValue ''\n */\n readonly photoAltText = input<TranslatableString>('');\n\n /**\n * Alternative text for the photo´s placeholder.\n * The value will be used to calculate the background color when `autoColor` is true.\n *\n * @defaultValue ''\n */\n readonly placeholderAltText = input<TranslatableString>('');\n\n /**\n * Text for the button changing the photo.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.CHANGE_PHOTO:Change`)\n * ```\n */\n readonly changePhotoText = input(t(() => $localize`:@@SI_PHOTO_UPLOAD.CHANGE_PHOTO:Change`));\n\n /**\n * Cropper frame aria label.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.CROPPER_FRAME_LABEL:Crop photo`)\n * ```\n */\n readonly cropperFrameAriaLabel = input(\n t(() => $localize`:@@SI_PHOTO_UPLOAD.CROPPER_FRAME_LABEL:Crop photo`)\n );\n\n /**\n * Text for the button uploading a photo.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.UPLOAD_PHOTO:Upload photo`)\n * ```\n */\n readonly uploadPhotoText = input(\n t(() => $localize`:@@SI_PHOTO_UPLOAD.UPLOAD_PHOTO:Upload photo`)\n );\n\n /**\n * Text for the button removing the photo.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.REMOVE:Remove`)\n * ```\n */\n readonly removePhotoText = input(t(() => $localize`:@@SI_PHOTO_UPLOAD.REMOVE:Remove`));\n\n /**\n * Text for the button cancelling the editing process.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.CANCEL:Cancel`)\n * ```\n */\n readonly cancelEditText = input(t(() => $localize`:@@SI_PHOTO_UPLOAD.CANCEL:Cancel`));\n\n /**\n * Text for the button applying the edited photo.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.APPLY_PHOTO:Apply`)\n * ```\n */\n readonly applyEditText = input(t(() => $localize`:@@SI_PHOTO_UPLOAD.APPLY_PHOTO:Apply`));\n\n /**\n * Text displayed as header of the editing modal.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.MODAL_TITLE:Avatar photo`)\n * ```\n */\n readonly modalHeader = input(t(() => $localize`:@@SI_PHOTO_UPLOAD.MODAL_TITLE:Avatar photo`));\n\n /**\n * Text displayed as description of the editing modal.\n */\n readonly modalDescription = input<TranslatableString>();\n\n /**\n * Output format of the edited image.\n *\n * @defaultValue 'jpeg'\n */\n readonly cropperImageFormat = input<'png' | 'jpeg'>('jpeg');\n\n /**\n * The width / height ratio (e.g. 1 / 1 for a square, 4 / 3, 16 / 9 ...).\n *\n * @defaultValue 1\n */\n readonly cropperAspectRatio = input(1);\n\n /**\n * Whether to keep the width and height of the cropped image equal according\n * to the aspectRatio.\n *\n * @defaultValue true\n */\n readonly cropperMaintainAspectRatio = input(true, { transform: booleanAttribute });\n\n /**\n * When set to true, padding will be added around the image to make it fit to\n * the aspect ratio. Be aware that this transformation will cause the loaded\n * image to be a png file with an increased base64 string payload.\n *\n * @defaultValue false\n */\n readonly cropperContainWithinAspectRatio = input(false, { transform: booleanAttribute });\n\n /**\n * The cropper´s width cannot be made smaller than this number of pixels\n * (relative to original image´s size). (0 = disabled).\n *\n * @defaultValue 50\n */\n readonly cropperMinWidth = input(50);\n\n /**\n * The cropper´s height cannot be made smaller than this number of pixels\n * (relative to original image´s size). Will be ignored if\n * `cropperMaintainAspectRatio` is set. (0 = disabled).\n *\n * @defaultValue 50\n */\n readonly cropperMinHeight = input(50);\n\n /**\n * The cropper´s width cannot be made bigger than this number of pixels.\n * Default is 0 (disabled).\n *\n * @defaultValue 0\n */\n readonly cropperMaxWidth = input(0);\n\n /**\n * The cropper´s height cannot be made bigger than this number of pixels.\n * Default is 0 (disabled).\n *\n * @defaultValue 0\n */\n readonly cropperMaxHeight = input(0);\n\n /**\n * Set this to true for a round cropper. Resulting image will still\n * be square, but visually clipped with a border-radius: 50% on the\n * resulting image to show it as round.\n *\n * @defaultValue true\n */\n readonly roundImage = input(true, { transform: booleanAttribute });\n\n /**\n * The input photo to be used for cropping. A string in [Data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URLs) format\n * with base64 encoding.\n */\n readonly sourcePhoto = model<string>();\n\n /**\n * URL to a photo to be used for cropping.\n */\n readonly sourcePhotoUrl = input<string>();\n\n /**\n * The photo to be displayed and edited (when not readonly).\n */\n readonly croppedPhoto = model<string>();\n\n protected readonly editPhotoTemplate = viewChild.required<TemplateRef<any>>('editPhotoTemplate');\n protected readonly fileInput = viewChild.required<ElementRef<any>>('fileInput');\n protected readonly imageCropper = viewChild<ImageCropperComponent>('imageCropper');\n\n // used to label the dialog\n protected readonly titleId = `__si-photo-upload-${SiPhotoUploadComponent.idCounter++}`;\n\n /**\n * The trusted photo url string which is used to display the photo.\n */\n protected readonly sanitizedPhotoUrl = signal<SafeResourceUrl | undefined>(undefined);\n\n /**\n * The appropriate error message displayed to the user. Might be\n * `uploadErrorWrongType` or `uploadErrorTooBig`.\n */\n protected readonly uploadErrorMessage = signal<string | undefined>(undefined);\n protected readonly editButtonText = computed(() =>\n this.sanitizedPhotoUrl() ? this.changePhotoText() : this.uploadPhotoText()\n );\n protected readonly currentFileSizeKilobytes = signal(-1);\n protected readonly currentFileSizeMegabytes = signal(-1);\n protected readonly maxSizeMb = computed(() => this.maxFileSize() / 1024);\n\n /**\n * The photo instance to be used in the image cropper. We need a different\n * reference than `sourcePhoto` to support the cancel after uploading\n * a new photo. While `sourcePhoto` is A and image cropper uploads B,\n * we should not replace `sourcePhoto` A until user presses apply.\n */\n protected readonly imageCropperPhoto = signal<string | undefined>(undefined);\n\n protected readonly icons = addIcons({\n elementCancel,\n elementCircleFilled,\n elementStateExclamationMark\n });\n /**\n * Reference to the modal displaying the photo to edit.\n */\n protected modalRef?: ModalRef;\n /**\n * The last cropped event of the image cropper component.\n * Will be set on every mouse drag of the user. It contains\n * the cropped image and the position. When user completes\n * the cropping, the data from the last event is used.\n */\n private imageCroppedEvent?: ImageCroppedEvent;\n /**\n * Applied cropper position necessary to restore the cropper position when the use press the Change button.\n */\n private cropperPosition?: CropperPosition;\n\n private readonly sanitizer = inject(DomSanitizer);\n private readonly modalService = inject(SiModalService);\n private readonly autoBackgroundColorDirective = inject(SiAvatarBackgroundColorDirective);\n\n ngOnChanges(changes: SimpleChanges): void {\n if (changes.readonly) {\n this.resetErrorMessage();\n this.resetFileInputValue();\n }\n\n if (changes.sourcePhotoUrl) {\n this.setPhoto(this.sourcePhotoUrl());\n this.cropperPosition = undefined;\n this.croppedPhoto.set(undefined);\n }\n if (changes.sourcePhoto && changes.sourcePhoto.currentValue !== this.imageCropperPhoto()) {\n const sourcePhoto = this.sourcePhoto();\n this.setPhoto(sourcePhoto);\n this.cropperPosition = undefined;\n this.croppedPhoto.set(undefined);\n this.imageCropperPhoto.set(sourcePhoto);\n }\n if (\n changes.croppedPhoto &&\n changes.croppedPhoto.previousValue?.length > 0 &&\n changes.croppedPhoto.previousValue !== changes.croppedPhoto.currentValue\n ) {\n this.setPhoto(this.croppedPhoto());\n }\n if (changes.placeholderAltText) {\n this.autoBackgroundColorDirective.calculateColorFromInitials(this.placeholderAltText());\n }\n }\n\n ngOnDestroy(): void {\n this.modalRef?.detach();\n }\n\n /**\n * Opens a modal dialog with the cropping component.\n */\n protected showCroppingDialog(): void {\n if (this.modalRef) {\n return;\n }\n if (this.disabledCropping()) {\n this.sourcePhoto.set(this.imageCropperPhoto());\n const sourcePhoto = this.sourcePhoto();\n this.updateCroppedPhoto(sourcePhoto ?? '');\n return;\n }\n this.modalRef = this.modalService.show(\n this.editPhotoTemplate(),\n {\n ignoreBackdropClick: false,\n keyboard: true,\n class: 'modal-dialog-centered',\n ariaLabelledBy: this.titleId\n },\n 'cancel'\n );\n this.resetErrorMessage();\n this.modalRef.hidden.subscribe(() => {\n this.resetErrorMessage();\n this.resetFileInputValue();\n this.modalRef = undefined;\n });\n }\n\n protected fileUpload(event: Event): void {\n // Initially reset a possible error message\n this.resetErrorMessage();\n const files = (event.target as HTMLInputElement).files;\n const file = files && files.length > 0 ? files[0] : undefined;\n if (!file) {\n return;\n }\n const fileType = file.type;\n const allowedFileTypes = this.acceptedUploadFormats()\n .split(',')\n .map(type => type.trim().replace('.', 'image/'));\n const fileTypeWrong = !allowedFileTypes.includes(fileType);\n if (fileTypeWrong) {\n this.uploadErrorMessage.set(this.uploadErrorWrongType());\n return;\n }\n const sizeInKb = file.size / 1024;\n this.currentFileSizeKilobytes.set(Math.round(sizeInKb * 10) / 10);\n this.currentFileSizeMegabytes.set(Math.round((sizeInKb / 1024) * 1000) / 1000);\n const fileSizeTooBig = sizeInKb > this.maxFileSize();\n if (fileSizeTooBig) {\n this.uploadErrorMessage.set(this.uploadErrorTooBig());\n return;\n }\n const reader = new FileReader();\n reader.addEventListener('loadend', () => {\n if (typeof reader.result === 'string') {\n this.cropperPosition = undefined;\n this.imageCropperPhoto.set(reader.result);\n\n // Bring up the editing modal if not already present\n this.showCroppingDialog();\n }\n });\n reader.readAsDataURL(file);\n }\n\n private updateCroppedPhoto(croppedPhoto: string, position?: CropperPosition): void {\n this.croppedPhoto.set(croppedPhoto);\n this.setPhoto(this.croppedPhoto());\n this.cropperPosition = position;\n }\n\n protected removePhoto(): void {\n // We emit undefined to notify consumers that the cropped\n // images is removed. This is a kind of special crop event.\n this.croppedPhoto.set(undefined);\n this.imageCropperPhoto.set(undefined);\n this.setPhoto(undefined);\n this.cropperPosition = undefined;\n this.resetFileInputValue();\n this.sourcePhoto.set(undefined);\n }\n\n /**\n * Invoked when user cropped the photo and pressed apply button.\n * Updates the current photo by the selected cropped photo and\n * closes the modal dialog.\n */\n protected imageCropperApplied(): void {\n if (this.imageCroppedEvent) {\n this.sourcePhoto.set(this.imageCropperPhoto());\n this.updateCroppedPhoto(\n this.imageCroppedEvent.base64!.toString(),\n this.imageCroppedEvent.cropperPosition\n );\n }\n this.modalRef?.hide();\n }\n\n protected imageCropperCanceled(): void {\n this.imageCropperPhoto.set(this.sourcePhoto());\n this.modalRef?.hide('cancel');\n }\n\n /**\n * Callback from the image cropper on every mouse drag invoking a cropping.\n *\n * @param event - Event containing the cropped image and the image cropped position.\n *\n */\n protected cropperImageCropped(event: ImageCroppedEvent): void {\n this.imageCroppedEvent = event;\n }\n\n /**\n * Lifecycle hook from the image cropper component. Informs\n * us when initialized and ready.\n */\n protected cropperReady(): void {\n // When the user opens cropper dialog multiple times we need to\n // apply existing cropper position.\n const imageCropper = this.imageCropper();\n if (this.cropperPosition && imageCropper) {\n imageCropper.cropper = { ...this.cropperPosition };\n imageCropper.crop();\n }\n }\n\n private resetFileInputValue(): void {\n if (this.fileInput()) {\n // Remove fileInput value to allow for selecting the same\n // file for being uploaded again.\n this.fileInput().nativeElement.value = null;\n }\n }\n\n private resetErrorMessage(): void {\n this.uploadErrorMessage.set(undefined);\n }\n\n private setPhoto(photo?: string): void {\n this.resetErrorMessage();\n this.sanitizedPhotoUrl.set(\n photo ? this.sanitizer.bypassSecurityTrustResourceUrl(photo) : undefined\n );\n }\n}\n","<div class=\"photo-upload d-flex flex-column p-6\">\n <!-- File upload -->\n <input\n #fileInput\n type=\"file\"\n class=\"d-none\"\n [accept]=\"acceptedUploadFormats()\"\n (change)=\"fileUpload($event)\"\n />\n\n <!-- Image -->\n @if (sanitizedPhotoUrl()) {\n <img\n class=\"photo-upload-photo\"\n [class.round]=\"roundImage()\"\n [src]=\"sanitizedPhotoUrl()\"\n [alt]=\"photoAltText() | translate\"\n />\n } @else {\n <span\n class=\"photo-upload-placeholder d-flex align-items-center justify-content-center flex-none\"\n [class.round]=\"roundImage()\"\n >\n {{ placeholderAltText() | translate }}\n </span>\n }\n <!-- Buttons -->\n @if (!readonly()) {\n <div class=\"d-flex justify-content-center gap-6 mt-8\">\n <button\n type=\"button\"\n class=\"btn btn-secondary\"\n (click)=\"\n (sourcePhoto() || sourcePhotoUrl()) && !disabledCropping()\n ? showCroppingDialog()\n : fileInput.click()\n \"\n >\n {{ editButtonText() | translate }}\n </button>\n @if (sanitizedPhotoUrl()) {\n <button type=\"button\" class=\"btn btn-danger\" (click)=\"removePhoto()\">\n {{ removePhotoText() | translate }}\n </button>\n }\n </div>\n }\n\n <!-- Error message -->\n @if (uploadErrorMessage() && !modalRef) {\n <div class=\"mt-6\">\n <ng-container [ngTemplateOutlet]=\"errorMessageTemplate\" />\n </div>\n }\n</div>\n\n<!-- Template: modal -->\n<ng-template #editPhotoTemplate>\n <!-- Header -->\n <div class=\"modal-header\">\n <h4 class=\"modal-title\" [id]=\"titleId\">{{ modalHeader() | translate }}</h4>\n <button\n type=\"button\"\n class=\"btn btn-circle btn-sm btn-ghost\"\n [attr.aria-label]=\"cancelEditText() | translate\"\n (click)=\"imageCropperCanceled()\"\n >\n <si-icon [icon]=\"icons.elementCancel\" />\n </button>\n </div>\n <!-- Content -->\n <div class=\"modal-body\">\n @if (modalDescription()) {\n <div class=\"mb-4\">\n <span class=\"text-secondary\">{{ modalDescription() | translate }}</span>\n </div>\n }\n <ng-container [ngTemplateOutlet]=\"imageCropperTemplate\" />\n @if (uploadErrorMessage()) {\n <div class=\"d-flex mt-4\">\n <ng-container [ngTemplateOutlet]=\"errorMessageTemplate\" />\n </div>\n }\n </div>\n <!-- Footer -->\n <div class=\"modal-footer\">\n <button type=\"button\" class=\"btn btn-secondary me-auto\" (click)=\"fileInput.click()\">\n {{ changePhotoText() | translate }}\n </button>\n <div class=\"d-flex gap-6\">\n <button type=\"button\" class=\"btn btn-secondary\" (click)=\"imageCropperCanceled()\">\n {{ cancelEditText() | translate }}\n </button>\n <button type=\"button\" class=\"btn btn-primary\" (click)=\"imageCropperApplied()\">\n {{ applyEditText() | translate }}\n </button>\n </div>\n </div>\n</ng-template>\n\n<!-- Template: error message -->\n<ng-template #errorMessageTemplate>\n <div class=\"d-flex align-items-center\">\n <span class=\"icon-small icon-stack d-inline-block my-n2 me-2\">\n <si-icon class=\"status-danger\" [icon]=\"icons.elementCircleFilled\" />\n <si-icon class=\"status-danger-contrast\" [icon]=\"icons.elementStateExclamationMark\" />\n </span>\n <span class=\"text-danger\">{{\n uploadErrorMessage()\n | translate\n : {\n mb: currentFileSizeMegabytes(),\n kb: currentFileSizeKilobytes(),\n maxSizeMb: maxSizeMb()\n }\n }}</span>\n </div>\n</ng-template>\n\n<!-- Template: image cropper -->\n<ng-template #imageCropperTemplate>\n <si-image-cropper-style>\n <image-cropper\n #imageCropper\n output=\"base64\"\n [aspectRatio]=\"cropperAspectRatio()\"\n [containWithinAspectRatio]=\"cropperContainWithinAspectRatio()\"\n [cropperMinWidth]=\"cropperMinWidth()\"\n [cropperMinHeight]=\"cropperMinHeight()\"\n [cropperMaxWidth]=\"cropperMaxWidth()\"\n [cropperMaxHeight]=\"cropperMaxHeight()\"\n [cropperFrameAriaLabel]=\"cropperFrameAriaLabel() | translate\"\n [format]=\"cropperImageFormat()\"\n [imageBase64]=\"imageCropperPhoto()\"\n [imageURL]=\"sourcePhotoUrl()\"\n [maintainAspectRatio]=\"cropperMaintainAspectRatio()\"\n [onlyScaleDown]=\"true\"\n [roundCropper]=\"roundImage()\"\n (cropperReady)=\"cropperReady()\"\n (imageCropped)=\"cropperImageCropped($event)\"\n />\n </si-image-cropper-style>\n</ng-template>\n","/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-image-cropper-style.component';\nexport * from './si-photo-upload.component';\n","/**\n * Generated bundle index.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AA,QAAA,EAAA,iBAAiB,EAAA,OAAA,EAClB;wBACP,gBAAgB;wBAChB,qBAAqB;wBACrB,eAAe;wBACf,4BAA4B;wBAC5B;qBACD,EAAA,eAAA,EAGgB,uBAAuB,CAAC,MAAM,EAAA,cAAA,EAC/B;AACd,wBAAA;AACE,4BAAA,SAAS,EAAE,gCAAgC;AAC3C,4BAAA,MAAM,EAAE,CAAC,OAAO,EAAE,WAAW;AAC9B;AACF,qBAAA,EAAA,QAAA,EAAA,6hJAAA,EAAA,MAAA,EAAA,CAAA,4oBAAA,CAAA,EAAA;;;AE5DH;;;AAGG;;ACHH;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"siemens-element-ng-photo-upload.mjs","sources":["../../../../projects/element-ng/photo-upload/si-image-cropper-style.component.ts","../../../../projects/element-ng/photo-upload/si-photo-upload.component.ts","../../../../projects/element-ng/photo-upload/si-photo-upload.component.html","../../../../projects/element-ng/photo-upload/index.ts","../../../../projects/element-ng/photo-upload/siemens-element-ng-photo-upload.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nimport { Component } from '@angular/core';\n\n@Component({\n selector: 'si-image-cropper-style',\n template: '<ng-content />',\n styleUrl: './si-image-cropper-style.component.scss'\n})\nexport class SiImageCropperStyleComponent {}\n","/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nimport { NgTemplateOutlet } from '@angular/common';\nimport {\n booleanAttribute,\n ChangeDetectionStrategy,\n Component,\n computed,\n ElementRef,\n inject,\n input,\n model,\n OnChanges,\n OnDestroy,\n signal,\n SimpleChanges,\n TemplateRef,\n viewChild\n} from '@angular/core';\nimport { DomSanitizer, SafeResourceUrl } from '@angular/platform-browser';\nimport { SiAvatarBackgroundColorDirective } from '@siemens/element-ng/avatar';\nimport {\n addIcons,\n elementCancel,\n elementCircleFilled,\n elementStateExclamationMark,\n SiIconComponent\n} from '@siemens/element-ng/icon';\nimport { ModalRef, SiModalService } from '@siemens/element-ng/modal';\nimport { SiTranslatePipe, t, TranslatableString } from '@siemens/element-translate-ng/translate';\nimport { CropperPosition, ImageCroppedEvent, ImageCropperComponent } from 'ngx-image-cropper';\n\nimport { SiImageCropperStyleComponent } from './si-image-cropper-style.component';\n\n/**\n * A component used to upload, edit, and delete a user's photo. The user can upload\n * a photo either via file browser or a URL to the photo. You can set the source\n * photo with the `sourcePhoto` Data URL input or the `sourcePhotoUrl` URL input.\n * If you already have a cropped image you can set it with the `croppedPhoto` input.\n * Cropping changes are emitted via the `croppedPhotoChange` output.\n */\n@Component({\n selector: 'si-photo-upload',\n imports: [\n NgTemplateOutlet,\n ImageCropperComponent,\n SiIconComponent,\n SiImageCropperStyleComponent,\n SiTranslatePipe\n ],\n templateUrl: './si-photo-upload.component.html',\n styleUrl: './si-photo-upload.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush,\n hostDirectives: [\n {\n directive: SiAvatarBackgroundColorDirective,\n inputs: ['color', 'autoColor']\n }\n ]\n})\nexport class SiPhotoUploadComponent implements OnChanges, OnDestroy {\n private static idCounter = 0;\n\n /**\n * Indicate that changing or uploads are disabled.\n *\n * @defaultValue false\n */\n readonly readonly = input(false, { transform: booleanAttribute });\n\n /**\n * Optionally disable image cropping.\n *\n * @defaultValue false\n */\n readonly disabledCropping = input(false, { transform: booleanAttribute });\n\n /**\n * Accepted image formats for the file selection dialog.\n *\n * @defaultValue '.png, .jpg, .jpeg'\n *\n * @see\n *\n * https://developer.mozilla.org/en-US/docs/Web/HTML/Element/input/file#attr-accept\n */\n readonly acceptedUploadFormats = input('.png, .jpg, .jpeg');\n\n /**\n * Maximum allowed file size of the uploaded file in kilobytes.\n *\n * @defaultValue 2048\n */\n readonly maxFileSize = input(2048);\n\n /**\n * If the uploaded file is of an unsupported type, this\n * error message will be displayed to the user.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.ERROR_FILE_TYPE:The image file is not valid. Please upload a PNG or JP(E)G.`)\n * ```\n */\n readonly uploadErrorWrongType = input(\n t(\n () =>\n $localize`:@@SI_PHOTO_UPLOAD.ERROR_FILE_TYPE:The image file is not valid. Please upload a PNG or JP(E)G.`\n )\n );\n\n /**\n * If the uploaded file exceeds the allowed upload size, this\n * error message will be displayed to the user.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.ERROR_FILE_SIZE_EXCEEDED:The actual file size {{mb}} MB exceeds the {{maxSizeMb}} MB limit.`)\n * ```\n */\n readonly uploadErrorTooBig = input(\n t(\n () =>\n $localize`:@@SI_PHOTO_UPLOAD.ERROR_FILE_SIZE_EXCEEDED:The actual file size {{mb}} MB exceeds the {{maxSizeMb}} MB limit.`\n )\n );\n\n /**\n * Alternative text for the photo.\n *\n * @defaultValue ''\n */\n readonly photoAltText = input<TranslatableString>('');\n\n /**\n * Alternative text for the photo´s placeholder.\n * The value will be used to calculate the background color when `autoColor` is true.\n *\n * @defaultValue ''\n */\n readonly placeholderAltText = input<TranslatableString>('');\n\n /**\n * Text for the button changing the photo.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.CHANGE_PHOTO:Change`)\n * ```\n */\n readonly changePhotoText = input(t(() => $localize`:@@SI_PHOTO_UPLOAD.CHANGE_PHOTO:Change`));\n\n /**\n * Cropper frame aria label.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.CROPPER_FRAME_LABEL:Crop photo`)\n * ```\n */\n readonly cropperFrameAriaLabel = input(\n t(() => $localize`:@@SI_PHOTO_UPLOAD.CROPPER_FRAME_LABEL:Crop photo`)\n );\n\n /**\n * Text for the button uploading a photo.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.UPLOAD_PHOTO:Upload photo`)\n * ```\n */\n readonly uploadPhotoText = input(\n t(() => $localize`:@@SI_PHOTO_UPLOAD.UPLOAD_PHOTO:Upload photo`)\n );\n\n /**\n * Text for the button removing the photo.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.REMOVE:Remove`)\n * ```\n */\n readonly removePhotoText = input(t(() => $localize`:@@SI_PHOTO_UPLOAD.REMOVE:Remove`));\n\n /**\n * Text for the button cancelling the editing process.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.CANCEL:Cancel`)\n * ```\n */\n readonly cancelEditText = input(t(() => $localize`:@@SI_PHOTO_UPLOAD.CANCEL:Cancel`));\n\n /**\n * Text for the button applying the edited photo.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.APPLY_PHOTO:Apply`)\n * ```\n */\n readonly applyEditText = input(t(() => $localize`:@@SI_PHOTO_UPLOAD.APPLY_PHOTO:Apply`));\n\n /**\n * Text displayed as header of the editing modal.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PHOTO_UPLOAD.MODAL_TITLE:Avatar photo`)\n * ```\n */\n readonly modalHeader = input(t(() => $localize`:@@SI_PHOTO_UPLOAD.MODAL_TITLE:Avatar photo`));\n\n /**\n * Text displayed as description of the editing modal.\n */\n readonly modalDescription = input<TranslatableString>();\n\n /**\n * Output format of the edited image.\n *\n * @defaultValue 'jpeg'\n */\n readonly cropperImageFormat = input<'png' | 'jpeg'>('jpeg');\n\n /**\n * The width / height ratio (e.g. 1 / 1 for a square, 4 / 3, 16 / 9 ...).\n *\n * @defaultValue 1\n */\n readonly cropperAspectRatio = input(1);\n\n /**\n * Whether to keep the width and height of the cropped image equal according\n * to the aspectRatio.\n *\n * @defaultValue true\n */\n readonly cropperMaintainAspectRatio = input(true, { transform: booleanAttribute });\n\n /**\n * When set to true, padding will be added around the image to make it fit to\n * the aspect ratio. Be aware that this transformation will cause the loaded\n * image to be a png file with an increased base64 string payload.\n *\n * @defaultValue false\n */\n readonly cropperContainWithinAspectRatio = input(false, { transform: booleanAttribute });\n\n /**\n * The cropper´s width cannot be made smaller than this number of pixels\n * (relative to original image´s size). (0 = disabled).\n *\n * @defaultValue 50\n */\n readonly cropperMinWidth = input(50);\n\n /**\n * The cropper´s height cannot be made smaller than this number of pixels\n * (relative to original image´s size). Will be ignored if\n * `cropperMaintainAspectRatio` is set. (0 = disabled).\n *\n * @defaultValue 50\n */\n readonly cropperMinHeight = input(50);\n\n /**\n * The cropper´s width cannot be made bigger than this number of pixels.\n * Default is 0 (disabled).\n *\n * @defaultValue 0\n */\n readonly cropperMaxWidth = input(0);\n\n /**\n * The cropper´s height cannot be made bigger than this number of pixels.\n * Default is 0 (disabled).\n *\n * @defaultValue 0\n */\n readonly cropperMaxHeight = input(0);\n\n /**\n * Set this to true for a round cropper. Resulting image will still\n * be square, but visually clipped with a border-radius: 50% on the\n * resulting image to show it as round.\n *\n * @defaultValue true\n */\n readonly roundImage = input(true, { transform: booleanAttribute });\n\n /**\n * The input photo to be used for cropping. A string in [Data URL](https://developer.mozilla.org/en-US/docs/Web/HTTP/Basics_of_HTTP/Data_URLs) format\n * with base64 encoding.\n */\n readonly sourcePhoto = model<string>();\n\n /**\n * URL to a photo to be used for cropping.\n */\n readonly sourcePhotoUrl = input<string>();\n\n /**\n * The photo to be displayed and edited (when not readonly).\n */\n readonly croppedPhoto = model<string>();\n\n protected readonly editPhotoTemplate = viewChild.required<TemplateRef<any>>('editPhotoTemplate');\n protected readonly fileInput = viewChild.required<ElementRef<any>>('fileInput');\n protected readonly imageCropper = viewChild<ImageCropperComponent>('imageCropper');\n\n // used to label the dialog\n protected readonly titleId = `__si-photo-upload-${SiPhotoUploadComponent.idCounter++}`;\n\n /**\n * The trusted photo url string which is used to display the photo.\n */\n protected readonly sanitizedPhotoUrl = signal<SafeResourceUrl | undefined>(undefined);\n\n /**\n * The appropriate error message displayed to the user. Might be\n * `uploadErrorWrongType` or `uploadErrorTooBig`.\n */\n protected readonly uploadErrorMessage = signal<string | undefined>(undefined);\n protected readonly editButtonText = computed(() =>\n this.sanitizedPhotoUrl() ? this.changePhotoText() : this.uploadPhotoText()\n );\n protected readonly currentFileSizeKilobytes = signal(-1);\n protected readonly currentFileSizeMegabytes = signal(-1);\n protected readonly maxSizeMb = computed(() => this.maxFileSize() / 1024);\n\n /**\n * The photo instance to be used in the image cropper. We need a different\n * reference than `sourcePhoto` to support the cancel after uploading\n * a new photo. While `sourcePhoto` is A and image cropper uploads B,\n * we should not replace `sourcePhoto` A until user presses apply.\n */\n protected readonly imageCropperPhoto = signal<string | undefined>(undefined);\n\n protected readonly icons = addIcons({\n elementCancel,\n elementCircleFilled,\n elementStateExclamationMark\n });\n /**\n * Reference to the modal displaying the photo to edit.\n */\n protected modalRef?: ModalRef;\n /**\n * The last cropped event of the image cropper component.\n * Will be set on every mouse drag of the user. It contains\n * the cropped image and the position. When user completes\n * the cropping, the data from the last event is used.\n */\n private imageCroppedEvent?: ImageCroppedEvent;\n /**\n * Applied cropper position necessary to restore the cropper position when the use press the Change button.\n */\n private cropperPosition?: CropperPosition;\n\n private readonly sanitizer = inject(DomSanitizer);\n private readonly modalService = inject(SiModalService);\n private readonly autoBackgroundColorDirective = inject(SiAvatarBackgroundColorDirective);\n\n ngOnChanges(changes: SimpleChanges): void {\n if (changes.readonly) {\n this.resetErrorMessage();\n this.resetFileInputValue();\n }\n\n if (changes.sourcePhotoUrl) {\n this.setPhoto(this.sourcePhotoUrl());\n this.cropperPosition = undefined;\n this.croppedPhoto.set(undefined);\n }\n if (changes.sourcePhoto?.currentValue !== this.imageCropperPhoto()) {\n const sourcePhoto = this.sourcePhoto();\n this.setPhoto(sourcePhoto);\n this.cropperPosition = undefined;\n this.croppedPhoto.set(undefined);\n this.imageCropperPhoto.set(sourcePhoto);\n }\n if (\n changes.croppedPhoto &&\n changes.croppedPhoto.previousValue?.length > 0 &&\n changes.croppedPhoto.previousValue !== changes.croppedPhoto.currentValue\n ) {\n this.setPhoto(this.croppedPhoto());\n }\n if (changes.placeholderAltText) {\n this.autoBackgroundColorDirective.calculateColorFromInitials(this.placeholderAltText());\n }\n }\n\n ngOnDestroy(): void {\n this.modalRef?.detach();\n }\n\n /**\n * Opens a modal dialog with the cropping component.\n */\n protected showCroppingDialog(): void {\n if (this.modalRef) {\n return;\n }\n if (this.disabledCropping()) {\n this.sourcePhoto.set(this.imageCropperPhoto());\n const sourcePhoto = this.sourcePhoto();\n this.updateCroppedPhoto(sourcePhoto ?? '');\n return;\n }\n this.modalRef = this.modalService.show(\n this.editPhotoTemplate(),\n {\n ignoreBackdropClick: false,\n keyboard: true,\n class: 'modal-dialog-centered',\n ariaLabelledBy: this.titleId\n },\n 'cancel'\n );\n this.resetErrorMessage();\n this.modalRef.hidden.subscribe(() => {\n this.resetErrorMessage();\n this.resetFileInputValue();\n this.modalRef = undefined;\n });\n }\n\n protected fileUpload(event: Event): void {\n // Initially reset a possible error message\n this.resetErrorMessage();\n const files = (event.target as HTMLInputElement).files;\n const file = files && files.length > 0 ? files[0] : undefined;\n if (!file) {\n return;\n }\n const fileType = file.type;\n const allowedFileTypes = this.acceptedUploadFormats()\n .split(',')\n .map(type => type.trim().replace('.', 'image/'));\n const fileTypeWrong = !allowedFileTypes.includes(fileType);\n if (fileTypeWrong) {\n this.uploadErrorMessage.set(this.uploadErrorWrongType());\n return;\n }\n const sizeInKb = file.size / 1024;\n this.currentFileSizeKilobytes.set(Math.round(sizeInKb * 10) / 10);\n this.currentFileSizeMegabytes.set(Math.round((sizeInKb / 1024) * 1000) / 1000);\n const fileSizeTooBig = sizeInKb > this.maxFileSize();\n if (fileSizeTooBig) {\n this.uploadErrorMessage.set(this.uploadErrorTooBig());\n return;\n }\n const reader = new FileReader();\n reader.addEventListener('loadend', () => {\n if (typeof reader.result === 'string') {\n this.cropperPosition = undefined;\n this.imageCropperPhoto.set(reader.result);\n\n // Bring up the editing modal if not already present\n this.showCroppingDialog();\n }\n });\n reader.readAsDataURL(file);\n }\n\n private updateCroppedPhoto(croppedPhoto: string, position?: CropperPosition): void {\n this.croppedPhoto.set(croppedPhoto);\n this.setPhoto(this.croppedPhoto());\n this.cropperPosition = position;\n }\n\n protected removePhoto(): void {\n // We emit undefined to notify consumers that the cropped\n // images is removed. This is a kind of special crop event.\n this.croppedPhoto.set(undefined);\n this.imageCropperPhoto.set(undefined);\n this.setPhoto(undefined);\n this.cropperPosition = undefined;\n this.resetFileInputValue();\n this.sourcePhoto.set(undefined);\n }\n\n /**\n * Invoked when user cropped the photo and pressed apply button.\n * Updates the current photo by the selected cropped photo and\n * closes the modal dialog.\n */\n protected imageCropperApplied(): void {\n if (this.imageCroppedEvent) {\n this.sourcePhoto.set(this.imageCropperPhoto());\n this.updateCroppedPhoto(\n this.imageCroppedEvent.base64!.toString(),\n this.imageCroppedEvent.cropperPosition\n );\n }\n this.modalRef?.hide();\n }\n\n protected imageCropperCanceled(): void {\n this.imageCropperPhoto.set(this.sourcePhoto());\n this.modalRef?.hide('cancel');\n }\n\n /**\n * Callback from the image cropper on every mouse drag invoking a cropping.\n *\n * @param event - Event containing the cropped image and the image cropped position.\n *\n */\n protected cropperImageCropped(event: ImageCroppedEvent): void {\n this.imageCroppedEvent = event;\n }\n\n /**\n * Lifecycle hook from the image cropper component. Informs\n * us when initialized and ready.\n */\n protected cropperReady(): void {\n // When the user opens cropper dialog multiple times we need to\n // apply existing cropper position.\n const imageCropper = this.imageCropper();\n if (this.cropperPosition && imageCropper) {\n imageCropper.cropper = { ...this.cropperPosition };\n imageCropper.crop();\n }\n }\n\n private resetFileInputValue(): void {\n if (this.fileInput()) {\n // Remove fileInput value to allow for selecting the same\n // file for being uploaded again.\n this.fileInput().nativeElement.value = null;\n }\n }\n\n private resetErrorMessage(): void {\n this.uploadErrorMessage.set(undefined);\n }\n\n private setPhoto(photo?: string): void {\n this.resetErrorMessage();\n this.sanitizedPhotoUrl.set(\n photo ? this.sanitizer.bypassSecurityTrustResourceUrl(photo) : undefined\n );\n }\n}\n","<div class=\"photo-upload d-flex flex-column p-6\">\n <!-- File upload -->\n <input\n #fileInput\n type=\"file\"\n class=\"d-none\"\n [accept]=\"acceptedUploadFormats()\"\n (change)=\"fileUpload($event)\"\n />\n\n <!-- Image -->\n @if (sanitizedPhotoUrl()) {\n <img\n class=\"photo-upload-photo\"\n [class.round]=\"roundImage()\"\n [src]=\"sanitizedPhotoUrl()\"\n [alt]=\"photoAltText() | translate\"\n />\n } @else {\n <span\n class=\"photo-upload-placeholder d-flex align-items-center justify-content-center flex-none\"\n [class.round]=\"roundImage()\"\n >\n {{ placeholderAltText() | translate }}\n </span>\n }\n <!-- Buttons -->\n @if (!readonly()) {\n <div class=\"d-flex justify-content-center gap-6 mt-8\">\n <button\n type=\"button\"\n class=\"btn btn-secondary\"\n (click)=\"\n (sourcePhoto() || sourcePhotoUrl()) && !disabledCropping()\n ? showCroppingDialog()\n : fileInput.click()\n \"\n >\n {{ editButtonText() | translate }}\n </button>\n @if (sanitizedPhotoUrl()) {\n <button type=\"button\" class=\"btn btn-danger\" (click)=\"removePhoto()\">\n {{ removePhotoText() | translate }}\n </button>\n }\n </div>\n }\n\n <!-- Error message -->\n @if (uploadErrorMessage() && !modalRef) {\n <div class=\"mt-6\">\n <ng-container [ngTemplateOutlet]=\"errorMessageTemplate\" />\n </div>\n }\n</div>\n\n<!-- Template: modal -->\n<ng-template #editPhotoTemplate>\n <!-- Header -->\n <div class=\"modal-header\">\n <h4 class=\"modal-title\" [id]=\"titleId\">{{ modalHeader() | translate }}</h4>\n <button\n type=\"button\"\n class=\"btn btn-circle btn-sm btn-ghost\"\n [attr.aria-label]=\"cancelEditText() | translate\"\n (click)=\"imageCropperCanceled()\"\n >\n <si-icon [icon]=\"icons.elementCancel\" />\n </button>\n </div>\n <!-- Content -->\n <div class=\"modal-body\">\n @if (modalDescription()) {\n <div class=\"mb-4\">\n <span class=\"text-secondary\">{{ modalDescription() | translate }}</span>\n </div>\n }\n <ng-container [ngTemplateOutlet]=\"imageCropperTemplate\" />\n @if (uploadErrorMessage()) {\n <div class=\"d-flex mt-4\">\n <ng-container [ngTemplateOutlet]=\"errorMessageTemplate\" />\n </div>\n }\n </div>\n <!-- Footer -->\n <div class=\"modal-footer\">\n <button type=\"button\" class=\"btn btn-secondary me-auto\" (click)=\"fileInput.click()\">\n {{ changePhotoText() | translate }}\n </button>\n <div class=\"d-flex gap-6\">\n <button type=\"button\" class=\"btn btn-secondary\" (click)=\"imageCropperCanceled()\">\n {{ cancelEditText() | translate }}\n </button>\n <button type=\"button\" class=\"btn btn-primary\" (click)=\"imageCropperApplied()\">\n {{ applyEditText() | translate }}\n </button>\n </div>\n </div>\n</ng-template>\n\n<!-- Template: error message -->\n<ng-template #errorMessageTemplate>\n <div class=\"d-flex align-items-center\">\n <span class=\"icon-small icon-stack d-inline-block my-n2 me-2\">\n <si-icon class=\"status-danger\" [icon]=\"icons.elementCircleFilled\" />\n <si-icon class=\"status-danger-contrast\" [icon]=\"icons.elementStateExclamationMark\" />\n </span>\n <span class=\"text-danger\">{{\n uploadErrorMessage()\n | translate\n : {\n mb: currentFileSizeMegabytes(),\n kb: currentFileSizeKilobytes(),\n maxSizeMb: maxSizeMb()\n }\n }}</span>\n </div>\n</ng-template>\n\n<!-- Template: image cropper -->\n<ng-template #imageCropperTemplate>\n <si-image-cropper-style>\n <image-cropper\n #imageCropper\n output=\"base64\"\n [aspectRatio]=\"cropperAspectRatio()\"\n [containWithinAspectRatio]=\"cropperContainWithinAspectRatio()\"\n [cropperMinWidth]=\"cropperMinWidth()\"\n [cropperMinHeight]=\"cropperMinHeight()\"\n [cropperMaxWidth]=\"cropperMaxWidth()\"\n [cropperMaxHeight]=\"cropperMaxHeight()\"\n [cropperFrameAriaLabel]=\"cropperFrameAriaLabel() | translate\"\n [format]=\"cropperImageFormat()\"\n [imageBase64]=\"imageCropperPhoto()\"\n [imageURL]=\"sourcePhotoUrl()\"\n [maintainAspectRatio]=\"cropperMaintainAspectRatio()\"\n [onlyScaleDown]=\"true\"\n [roundCropper]=\"roundImage()\"\n (cropperReady)=\"cropperReady()\"\n (imageCropped)=\"cropperImageCropped($event)\"\n />\n </si-image-cropper-style>\n</ng-template>\n","/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-image-cropper-style.component';\nexport * from './si-photo-upload.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;AAAA;;;AAGG;MAQU,4BAA4B,CAAA;uGAA5B,4BAA4B,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAA5B,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,4BAA4B,kFAH7B,gBAAgB,EAAA,QAAA,EAAA,IAAA,EAAA,MAAA,EAAA,CAAA,mrBAAA,CAAA,EAAA,CAAA;;2FAGf,4BAA4B,EAAA,UAAA,EAAA,CAAA;kBALxC,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,wBAAwB,YACxB,gBAAgB,EAAA,MAAA,EAAA,CAAA,mrBAAA,CAAA,EAAA;;;ACR5B;;;AAGG;AAiCH;;;;;;AAMG;MAoBU,sBAAsB,CAAA;AACzB,IAAA,OAAO,SAAS,GAAG,CAAC;AAE5B;;;;AAIG;IACM,QAAQ,GAAG,KAAK,CAAC,KAAK,EAAE,EAAE,SAAS,EAAE,gBAAgB,EAAE,CAAC;AAEjE;;;;AAIG;IACM,gBAAgB,GAAG,KAAK,CAAC,KAAK,EAAE,EAAE,SAAS,EAAE,gBAAgB,EAAE,CAAC;AAEzE;;;;;;;;AAQG;AACM,IAAA,qBAAqB,GAAG,KAAK,CAAC,mBAAmB,CAAC;AAE3D;;;;AAIG;AACM,IAAA,WAAW,GAAG,KAAK,CAAC,IAAI,CAAC;AAElC;;;;;;;;AAQG;AACM,IAAA,oBAAoB,GAAG,KAAK,CACnC,CAAC,CACC,MACE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A,uBAAA,CAAA,MAAA,EAAA,CAAA;;2FAYN,sBAAsB,EAAA,UAAA,EAAA,CAAA;kBAnBlC,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,iBAAiB,EAAA,OAAA,EAClB;wBACP,gBAAgB;wBAChB,qBAAqB;wBACrB,eAAe;wBACf,4BAA4B;wBAC5B;qBACD,EAAA,eAAA,EAGgB,uBAAuB,CAAC,MAAM,EAAA,cAAA,EAC/B;AACd,wBAAA;AACE,4BAAA,SAAS,EAAE,gCAAgC;AAC3C,4BAAA,MAAM,EAAE,CAAC,OAAO,EAAE,WAAW;AAC9B;AACF,qBAAA,EAAA,QAAA,EAAA,6hJAAA,EAAA,MAAA,EAAA,CAAA,4oBAAA,CAAA,EAAA;;;AE5DH;;;AAGG;;ACHH;;AAEG;;;;"}
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"siemens-element-ng-progressbar.mjs","sources":["../../../../projects/element-ng/progressbar/si-progressbar.component.ts","../../../../projects/element-ng/progressbar/si-progressbar.component.html","../../../../projects/element-ng/progressbar/si-progressbar.module.ts","../../../../projects/element-ng/progressbar/index.ts","../../../../projects/element-ng/progressbar/siemens-element-ng-progressbar.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nimport { ChangeDetectionStrategy, Component, computed, input } from '@angular/core';\nimport { SiTranslatePipe, t } from '@siemens/element-translate-ng/translate';\n\n@Component({\n selector: 'si-progressbar',\n imports: [SiTranslatePipe],\n templateUrl: './si-progressbar.component.html',\n styleUrl: './si-progressbar.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class SiProgressbarComponent {\n /**\n * Needed for a11y\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PROGRESSBAR.LABEL:Progress`)\n * ```\n */\n readonly ariaLabel = input(t(() => $localize`:@@SI_PROGRESSBAR.LABEL:Progress`));\n\n /**\n * Max value for progressbar\n *\n * @defaultValue 100\n */\n readonly max = input(100);\n\n /**\n * Current value\n *\n * @defaultValue 0\n */\n readonly value = input<number | undefined>(0);\n\n /**\n * Heading to display on top of progress bar.\n */\n readonly heading = input<
|
|
1
|
+
{"version":3,"file":"siemens-element-ng-progressbar.mjs","sources":["../../../../projects/element-ng/progressbar/si-progressbar.component.ts","../../../../projects/element-ng/progressbar/si-progressbar.component.html","../../../../projects/element-ng/progressbar/si-progressbar.module.ts","../../../../projects/element-ng/progressbar/index.ts","../../../../projects/element-ng/progressbar/siemens-element-ng-progressbar.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nimport { ChangeDetectionStrategy, Component, computed, input } from '@angular/core';\nimport { SiTranslatePipe, t, TranslatableString } from '@siemens/element-translate-ng/translate';\n\n@Component({\n selector: 'si-progressbar',\n imports: [SiTranslatePipe],\n templateUrl: './si-progressbar.component.html',\n styleUrl: './si-progressbar.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class SiProgressbarComponent {\n /**\n * Needed for a11y\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_PROGRESSBAR.LABEL:Progress`)\n * ```\n */\n readonly ariaLabel = input(t(() => $localize`:@@SI_PROGRESSBAR.LABEL:Progress`));\n\n /**\n * Max value for progressbar\n *\n * @defaultValue 100\n */\n readonly max = input(100);\n\n /**\n * Current value\n *\n * @defaultValue 0\n */\n readonly value = input<number | undefined>(0);\n\n /**\n * Heading to display on top of progress bar.\n */\n readonly heading = input<TranslatableString>();\n\n /**\n * Optional progress text to be shown on top right (in LTR).\n * It can be percentage value or a progress status. E.g `50 %` or `Downloading 2/8`.\n */\n readonly progress = input<string>();\n\n /**\n * Height for progress bar.\n *\n * @defaultValue 'normal'\n */\n readonly height = input<ProgressbarHeight>('normal');\n\n protected readonly percent = computed(\n () => (100 * Number(this.value() ?? 0)) / Number(this.max() ?? 100)\n );\n}\n\nexport type ProgressbarHeight = 'small' | 'normal';\n","@if (heading() || progress()) {\n <div\n class=\"d-flex align-items-baseline\"\n [class.justify-content-end]=\"!heading()\"\n [class.justify-content-between]=\"heading()\"\n >\n @if (heading()) {\n <span class=\"si-h5 mb-2\">{{ heading() | translate }}</span>\n }\n @if (progress()) {\n <small class=\"text-nowrap\">{{ progress() }}</small>\n }\n </div>\n}\n<div class=\"progress\" [class.si-progress-small]=\"height() === 'small'\">\n <div\n class=\"progress-bar\"\n role=\"progressbar\"\n [attr.aria-valuemin]=\"0\"\n [attr.aria-valuemax]=\"max()\"\n [attr.aria-valuenow]=\"value()\"\n [attr.aria-valuetext]=\"value() !== undefined ? percent().toFixed(0) + '%' : null\"\n [attr.aria-label]=\"ariaLabel() | translate\"\n [style.width.%]=\"percent()\"\n >\n </div>\n</div>\n","/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nimport { NgModule } from '@angular/core';\n\nimport { SiProgressbarComponent } from './si-progressbar.component';\n\n@NgModule({\n imports: [SiProgressbarComponent],\n exports: [SiProgressbarComponent]\n})\nexport class SiProgressbarModule {}\n","/**\n * Copyright (c) Siemens 2016 - 2025\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-progressbar.component';\nexport * from './si-progressbar.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;AAAA;;;AAGG;MAWU,sBAAsB,CAAA;AACjC;;;;;;;AAOG;AACM,IAAA,SAAS,GAAG,KAAK,CAAC,CAAC,CAAC,MAAM,SAAS,CAAA,CAAA,gCAAA,CAAkC,CAAC,CAAC;AAEhF;;;;AAIG;AACM,IAAA,GAAG,GAAG,KAAK,CAAC,GAAG,CAAC;AAEzB;;;;AAIG;AACM,IAAA,KAAK,GAAG,KAAK,CAAqB,CAAC,CAAC;AAE7C;;AAEG;IACM,OAAO,GAAG,KAAK,EAAsB;AAE9C;;;AAGG;IACM,QAAQ,GAAG,KAAK,EAAU;AAEnC;;;;AAIG;AACM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,IAAA,EAAA,UAAA,EAAA,KAAA,EAAA,iBAAA,EAAA,IAAA,EAAA,EAAA,EAAA,QAAA,EAAA,EAAA,EAAA,QAAA,ECdnC,q0BA2BA,EAAA,MAAA,EAAA,CAAA,iEAAA,CAAA,EAAA,YAAA,EAAA,CAAA,EAAA,IAAA,EAAA,MAAA,EAAA,IAAA,EDlBY,eAAe,EAAA,IAAA,EAAA,WAAA,EAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;2FAKd,sBAAsB,EAAA,UAAA,EAAA,CAAA;kBAPlC,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,gBAAgB,WACjB,CAAC,eAAe,CAAC,EAAA,eAAA,EAGT,uBAAuB,CAAC,MAAM,EAAA,QAAA,EAAA,q0BAAA,EAAA,MAAA,EAAA,CAAA,iEAAA,CAAA,EAAA;;;AEZjD;;;AAGG;MASU,mBAAmB,CAAA;uGAAnB,mBAAmB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA;wGAAnB,mBAAmB,EAAA,OAAA,EAAA,CAHpB,sBAAsB,CAAA,EAAA,OAAA,EAAA,CACtB,sBAAsB,CAAA,EAAA,CAAA;wGAErB,mBAAmB,EAAA,CAAA;;2FAAnB,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBAJ/B,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,sBAAsB,CAAC;oBACjC,OAAO,EAAE,CAAC,sBAAsB;AACjC,iBAAA;;;ACXD;;;AAGG;;ACHH;;AAEG;;;;"}
|
|
@@ -170,7 +170,6 @@ class SiResizeObserverDirective {
|
|
|
170
170
|
/** @defaultValue 100 */
|
|
171
171
|
resizeThrottle = input(100);
|
|
172
172
|
/** @defaultValue true */
|
|
173
|
-
// TODO: switch default to false in v48.0.0
|
|
174
173
|
emitInitial = input(true, { transform: booleanAttribute });
|
|
175
174
|
siResizeObserver = output();
|
|
176
175
|
subs;
|