@siemens/element-ng 49.11.0 → 49.12.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (99) hide show
  1. package/carousel/package.json +4 -0
  2. package/fesm2022/siemens-element-ng-ag-grid.mjs +6 -5
  3. package/fesm2022/siemens-element-ng-ag-grid.mjs.map +1 -1
  4. package/fesm2022/siemens-element-ng-application-header.mjs +17 -20
  5. package/fesm2022/siemens-element-ng-application-header.mjs.map +1 -1
  6. package/fesm2022/siemens-element-ng-breadcrumb-router.mjs +3 -3
  7. package/fesm2022/siemens-element-ng-breadcrumb-router.mjs.map +1 -1
  8. package/fesm2022/siemens-element-ng-breadcrumb.mjs +3 -3
  9. package/fesm2022/siemens-element-ng-breadcrumb.mjs.map +1 -1
  10. package/fesm2022/siemens-element-ng-card.mjs +2 -2
  11. package/fesm2022/siemens-element-ng-card.mjs.map +1 -1
  12. package/fesm2022/siemens-element-ng-carousel.mjs +541 -0
  13. package/fesm2022/siemens-element-ng-carousel.mjs.map +1 -0
  14. package/fesm2022/siemens-element-ng-chat-messages.mjs +18 -21
  15. package/fesm2022/siemens-element-ng-chat-messages.mjs.map +1 -1
  16. package/fesm2022/siemens-element-ng-content-action-bar.mjs +2 -2
  17. package/fesm2022/siemens-element-ng-content-action-bar.mjs.map +1 -1
  18. package/fesm2022/siemens-element-ng-dashboard.mjs +34 -35
  19. package/fesm2022/siemens-element-ng-dashboard.mjs.map +1 -1
  20. package/fesm2022/siemens-element-ng-date-range-filter.mjs +10 -8
  21. package/fesm2022/siemens-element-ng-date-range-filter.mjs.map +1 -1
  22. package/fesm2022/siemens-element-ng-datepicker.mjs +10 -9
  23. package/fesm2022/siemens-element-ng-datepicker.mjs.map +1 -1
  24. package/fesm2022/siemens-element-ng-electron-titlebar.mjs +3 -3
  25. package/fesm2022/siemens-element-ng-electron-titlebar.mjs.map +1 -1
  26. package/fesm2022/siemens-element-ng-empty-state.mjs +2 -2
  27. package/fesm2022/siemens-element-ng-empty-state.mjs.map +1 -1
  28. package/fesm2022/siemens-element-ng-file-uploader.mjs +49 -47
  29. package/fesm2022/siemens-element-ng-file-uploader.mjs.map +1 -1
  30. package/fesm2022/siemens-element-ng-filter-bar.mjs +5 -5
  31. package/fesm2022/siemens-element-ng-filter-bar.mjs.map +1 -1
  32. package/fesm2022/siemens-element-ng-filtered-search.mjs +6 -5
  33. package/fesm2022/siemens-element-ng-filtered-search.mjs.map +1 -1
  34. package/fesm2022/siemens-element-ng-footer.mjs +3 -3
  35. package/fesm2022/siemens-element-ng-footer.mjs.map +1 -1
  36. package/fesm2022/siemens-element-ng-form.mjs +5 -4
  37. package/fesm2022/siemens-element-ng-form.mjs.map +1 -1
  38. package/fesm2022/siemens-element-ng-formly.mjs +24 -23
  39. package/fesm2022/siemens-element-ng-formly.mjs.map +1 -1
  40. package/fesm2022/siemens-element-ng-header-dropdown.mjs +26 -17
  41. package/fesm2022/siemens-element-ng-header-dropdown.mjs.map +1 -1
  42. package/fesm2022/siemens-element-ng-help-button.mjs +3 -3
  43. package/fesm2022/siemens-element-ng-help-button.mjs.map +1 -1
  44. package/fesm2022/siemens-element-ng-inline-notification.mjs +3 -3
  45. package/fesm2022/siemens-element-ng-inline-notification.mjs.map +1 -1
  46. package/fesm2022/siemens-element-ng-language-switcher.mjs +3 -3
  47. package/fesm2022/siemens-element-ng-language-switcher.mjs.map +1 -1
  48. package/fesm2022/siemens-element-ng-markdown-renderer.mjs +4 -3
  49. package/fesm2022/siemens-element-ng-markdown-renderer.mjs.map +1 -1
  50. package/fesm2022/siemens-element-ng-menu.mjs +2 -2
  51. package/fesm2022/siemens-element-ng-menu.mjs.map +1 -1
  52. package/fesm2022/siemens-element-ng-navbar-vertical-next.mjs +8 -7
  53. package/fesm2022/siemens-element-ng-navbar-vertical-next.mjs.map +1 -1
  54. package/fesm2022/siemens-element-ng-navbar-vertical.mjs +13 -12
  55. package/fesm2022/siemens-element-ng-navbar-vertical.mjs.map +1 -1
  56. package/fesm2022/siemens-element-ng-navbar.mjs +6 -8
  57. package/fesm2022/siemens-element-ng-navbar.mjs.map +1 -1
  58. package/fesm2022/siemens-element-ng-notification-item.mjs +3 -3
  59. package/fesm2022/siemens-element-ng-notification-item.mjs.map +1 -1
  60. package/fesm2022/siemens-element-ng-pagination.mjs +4 -1
  61. package/fesm2022/siemens-element-ng-pagination.mjs.map +1 -1
  62. package/fesm2022/siemens-element-ng-password-toggle.mjs +3 -3
  63. package/fesm2022/siemens-element-ng-password-toggle.mjs.map +1 -1
  64. package/fesm2022/siemens-element-ng-pills-input.mjs +4 -4
  65. package/fesm2022/siemens-element-ng-pills-input.mjs.map +1 -1
  66. package/fesm2022/siemens-element-ng-popover-legacy.mjs +3 -3
  67. package/fesm2022/siemens-element-ng-popover-legacy.mjs.map +1 -1
  68. package/fesm2022/siemens-element-ng-popover.mjs +3 -3
  69. package/fesm2022/siemens-element-ng-popover.mjs.map +1 -1
  70. package/fesm2022/siemens-element-ng-result-details-list.mjs +3 -3
  71. package/fesm2022/siemens-element-ng-result-details-list.mjs.map +1 -1
  72. package/fesm2022/siemens-element-ng-side-panel.mjs +5 -5
  73. package/fesm2022/siemens-element-ng-side-panel.mjs.map +1 -1
  74. package/fesm2022/siemens-element-ng-sort-bar.mjs +3 -3
  75. package/fesm2022/siemens-element-ng-sort-bar.mjs.map +1 -1
  76. package/fesm2022/siemens-element-ng-split.mjs +3 -3
  77. package/fesm2022/siemens-element-ng-split.mjs.map +1 -1
  78. package/fesm2022/siemens-element-ng-status-bar.mjs +3 -3
  79. package/fesm2022/siemens-element-ng-status-bar.mjs.map +1 -1
  80. package/fesm2022/siemens-element-ng-threshold.mjs +5 -5
  81. package/fesm2022/siemens-element-ng-threshold.mjs.map +1 -1
  82. package/fesm2022/siemens-element-ng-toast-notification.mjs +3 -3
  83. package/fesm2022/siemens-element-ng-toast-notification.mjs.map +1 -1
  84. package/fesm2022/siemens-element-ng-tooltip.mjs +3 -3
  85. package/fesm2022/siemens-element-ng-tooltip.mjs.map +1 -1
  86. package/fesm2022/siemens-element-ng-translate.mjs.map +1 -1
  87. package/fesm2022/siemens-element-ng-tree-view.mjs +5 -5
  88. package/fesm2022/siemens-element-ng-tree-view.mjs.map +1 -1
  89. package/package.json +12 -8
  90. package/template-i18n.json +7 -0
  91. package/types/siemens-element-ng-application-header.d.ts +3 -4
  92. package/types/siemens-element-ng-carousel.d.ts +209 -0
  93. package/types/siemens-element-ng-chat-messages.d.ts +1 -2
  94. package/types/siemens-element-ng-dashboard.d.ts +4 -4
  95. package/types/siemens-element-ng-date-range-filter.d.ts +1 -1
  96. package/types/siemens-element-ng-file-uploader.d.ts +6 -8
  97. package/types/siemens-element-ng-header-dropdown.d.ts +3 -3
  98. package/types/siemens-element-ng-navbar.d.ts +1 -2
  99. package/types/siemens-element-ng-translate.d.ts +7 -0
@@ -1,5 +1,5 @@
1
1
  import * as i0 from '@angular/core';
2
- import { input, booleanAttribute, output, Component, NgModule } from '@angular/core';
2
+ import { input, booleanAttribute, output, ChangeDetectionStrategy, Component, NgModule } from '@angular/core';
3
3
  import { CdkMenuTrigger } from '@angular/cdk/menu';
4
4
  import { elementOptionsVertical, elementRight4, elementLeft4 } from '@siemens/element-icons';
5
5
  import { addIcons, SiIconComponent } from '@siemens/element-ng/icon';
@@ -77,11 +77,11 @@ class SiElectrontitlebarComponent {
77
77
  ariaLabelMenu = input(t(() => $localize `:@@SI_ELECTRON_TITLEBAR.MENU:Menu`), ...(ngDevMode ? [{ debugName: "ariaLabelMenu" }] : []));
78
78
  icons = addIcons({ elementLeft4, elementRight4, elementOptionsVertical });
79
79
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiElectrontitlebarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
80
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: SiElectrontitlebarComponent, isStandalone: true, selector: "si-electron-titlebar", inputs: { appTitle: { classPropertyName: "appTitle", publicName: "appTitle", isSignal: true, isRequired: true, transformFunction: null }, canGoBack: { classPropertyName: "canGoBack", publicName: "canGoBack", isSignal: true, isRequired: false, transformFunction: null }, canGoForward: { classPropertyName: "canGoForward", publicName: "canGoForward", isSignal: true, isRequired: false, transformFunction: null }, hasFocus: { classPropertyName: "hasFocus", publicName: "hasFocus", isSignal: true, isRequired: false, transformFunction: null }, menuItems: { classPropertyName: "menuItems", publicName: "menuItems", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelForward: { classPropertyName: "ariaLabelForward", publicName: "ariaLabelForward", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelBack: { classPropertyName: "ariaLabelBack", publicName: "ariaLabelBack", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelMenu: { classPropertyName: "ariaLabelMenu", publicName: "ariaLabelMenu", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { forward: "forward", back: "back" }, ngImport: i0, template: "<div class=\"electron-title-bar-container w-100 bg-base-1 border-bottom fixed-top\">\n <div class=\"electron-title-bar align-items-center d-flex h-100 gap-6\">\n <span\n class=\"mx-6 si-body electron-title-bar-app-name text-truncate\"\n [class.unfocused]=\"!hasFocus()\"\n >{{ appTitle() }}</span\n >\n <button\n type=\"button\"\n class=\"btn btn-icon btn-sm btn-tertiary\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelBack() | translate\"\n [disabled]=\"!canGoBack()\"\n (click)=\"back.emit()\"\n >\n <si-icon class=\"flip-rtl\" [icon]=\"icons.elementLeft4\" />\n </button>\n <button\n type=\"button\"\n class=\"btn btn-icon btn-sm btn-tertiary\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelForward() | translate\"\n [disabled]=\"!canGoForward()\"\n (click)=\"forward.emit()\"\n >\n <si-icon class=\"flip-rtl\" [icon]=\"icons.elementRight4\" />\n </button>\n @if (menuItems().length > 0) {\n <button\n type=\"button\"\n class=\"btn btn-icon electron-title-bar-btn btn-tertiary btn-sm\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelMenu() | translate\"\n [cdkMenuTriggerFor]=\"menu\"\n >\n <si-icon [icon]=\"icons.elementOptionsVertical\" />\n </button>\n }\n <div class=\"electron-title-bar-draggable flex-grow-1 w-100 h-100\"></div>\n </div>\n</div>\n<ng-template #menu>\n <div class=\"mt-2\">\n <si-menu-factory [items]=\"menuItems()\" />\n </div>\n</ng-template>\n", styles: [".electron-title-bar-container{block-size:calc(1.5rem + 12px);z-index:1033;inset-block-start:var(--element-system-banner-spacing, 0px)}.electron-title-bar{position:absolute;inset-inline-start:env(titlebar-area-x,0);inline-size:env(titlebar-area-width,100%)}.electron-title-bar-app-name{color:var(--element-text-secondary);-webkit-app-region:drag;-webkit-user-select:none;user-select:none}.electron-title-bar-draggable{flex-basis:content;-webkit-app-region:drag}.unfocused{color:var(--element-ui-3)}\n"], dependencies: [{ kind: "directive", type: CdkMenuTrigger, selector: "[cdkMenuTriggerFor]", inputs: ["cdkMenuTriggerFor", "cdkMenuPosition", "cdkMenuTriggerData", "cdkMenuTriggerTransformOriginOn"], outputs: ["cdkMenuOpened", "cdkMenuClosed"], exportAs: ["cdkMenuTriggerFor"] }, { kind: "component", type: SiMenuFactoryComponent, selector: "si-menu-factory", inputs: ["items", "actionParam"] }, { kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }] });
80
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: SiElectrontitlebarComponent, isStandalone: true, selector: "si-electron-titlebar", inputs: { appTitle: { classPropertyName: "appTitle", publicName: "appTitle", isSignal: true, isRequired: true, transformFunction: null }, canGoBack: { classPropertyName: "canGoBack", publicName: "canGoBack", isSignal: true, isRequired: false, transformFunction: null }, canGoForward: { classPropertyName: "canGoForward", publicName: "canGoForward", isSignal: true, isRequired: false, transformFunction: null }, hasFocus: { classPropertyName: "hasFocus", publicName: "hasFocus", isSignal: true, isRequired: false, transformFunction: null }, menuItems: { classPropertyName: "menuItems", publicName: "menuItems", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelForward: { classPropertyName: "ariaLabelForward", publicName: "ariaLabelForward", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelBack: { classPropertyName: "ariaLabelBack", publicName: "ariaLabelBack", isSignal: true, isRequired: false, transformFunction: null }, ariaLabelMenu: { classPropertyName: "ariaLabelMenu", publicName: "ariaLabelMenu", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { forward: "forward", back: "back" }, ngImport: i0, template: "<div class=\"electron-title-bar-container w-100 bg-base-1 border-bottom fixed-top\">\n <div class=\"electron-title-bar align-items-center d-flex h-100 gap-6\">\n <span\n class=\"mx-6 si-body electron-title-bar-app-name text-truncate\"\n [class.unfocused]=\"!hasFocus()\"\n >{{ appTitle() }}</span\n >\n <button\n type=\"button\"\n class=\"btn btn-icon btn-sm btn-tertiary\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelBack() | translate\"\n [disabled]=\"!canGoBack()\"\n (click)=\"back.emit()\"\n >\n <si-icon class=\"flip-rtl\" [icon]=\"icons.elementLeft4\" />\n </button>\n <button\n type=\"button\"\n class=\"btn btn-icon btn-sm btn-tertiary\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelForward() | translate\"\n [disabled]=\"!canGoForward()\"\n (click)=\"forward.emit()\"\n >\n <si-icon class=\"flip-rtl\" [icon]=\"icons.elementRight4\" />\n </button>\n @if (menuItems().length > 0) {\n <button\n type=\"button\"\n class=\"btn btn-icon electron-title-bar-btn btn-tertiary btn-sm\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelMenu() | translate\"\n [cdkMenuTriggerFor]=\"menu\"\n >\n <si-icon [icon]=\"icons.elementOptionsVertical\" />\n </button>\n }\n <div class=\"electron-title-bar-draggable flex-grow-1 w-100 h-100\"></div>\n </div>\n</div>\n<ng-template #menu>\n <div class=\"mt-2\">\n <si-menu-factory [items]=\"menuItems()\" />\n </div>\n</ng-template>\n", styles: [".electron-title-bar-container{block-size:calc(1.5rem + 12px);z-index:1033;inset-block-start:var(--element-system-banner-spacing, 0px)}.electron-title-bar{position:absolute;inset-inline-start:env(titlebar-area-x,0);inline-size:env(titlebar-area-width,100%)}.electron-title-bar-app-name{color:var(--element-text-secondary);-webkit-app-region:drag;-webkit-user-select:none;user-select:none}.electron-title-bar-draggable{flex-basis:content;-webkit-app-region:drag}.unfocused{color:var(--element-ui-3)}\n"], dependencies: [{ kind: "directive", type: CdkMenuTrigger, selector: "[cdkMenuTriggerFor]", inputs: ["cdkMenuTriggerFor", "cdkMenuPosition", "cdkMenuTriggerData", "cdkMenuTriggerTransformOriginOn"], outputs: ["cdkMenuOpened", "cdkMenuClosed"], exportAs: ["cdkMenuTriggerFor"] }, { kind: "component", type: SiMenuFactoryComponent, selector: "si-menu-factory", inputs: ["items", "actionParam"] }, { kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.Default });
81
81
  }
82
82
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiElectrontitlebarComponent, decorators: [{
83
83
  type: Component,
84
- args: [{ selector: 'si-electron-titlebar', imports: [CdkMenuTrigger, SiMenuFactoryComponent, SiIconComponent, SiTranslatePipe], template: "<div class=\"electron-title-bar-container w-100 bg-base-1 border-bottom fixed-top\">\n <div class=\"electron-title-bar align-items-center d-flex h-100 gap-6\">\n <span\n class=\"mx-6 si-body electron-title-bar-app-name text-truncate\"\n [class.unfocused]=\"!hasFocus()\"\n >{{ appTitle() }}</span\n >\n <button\n type=\"button\"\n class=\"btn btn-icon btn-sm btn-tertiary\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelBack() | translate\"\n [disabled]=\"!canGoBack()\"\n (click)=\"back.emit()\"\n >\n <si-icon class=\"flip-rtl\" [icon]=\"icons.elementLeft4\" />\n </button>\n <button\n type=\"button\"\n class=\"btn btn-icon btn-sm btn-tertiary\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelForward() | translate\"\n [disabled]=\"!canGoForward()\"\n (click)=\"forward.emit()\"\n >\n <si-icon class=\"flip-rtl\" [icon]=\"icons.elementRight4\" />\n </button>\n @if (menuItems().length > 0) {\n <button\n type=\"button\"\n class=\"btn btn-icon electron-title-bar-btn btn-tertiary btn-sm\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelMenu() | translate\"\n [cdkMenuTriggerFor]=\"menu\"\n >\n <si-icon [icon]=\"icons.elementOptionsVertical\" />\n </button>\n }\n <div class=\"electron-title-bar-draggable flex-grow-1 w-100 h-100\"></div>\n </div>\n</div>\n<ng-template #menu>\n <div class=\"mt-2\">\n <si-menu-factory [items]=\"menuItems()\" />\n </div>\n</ng-template>\n", styles: [".electron-title-bar-container{block-size:calc(1.5rem + 12px);z-index:1033;inset-block-start:var(--element-system-banner-spacing, 0px)}.electron-title-bar{position:absolute;inset-inline-start:env(titlebar-area-x,0);inline-size:env(titlebar-area-width,100%)}.electron-title-bar-app-name{color:var(--element-text-secondary);-webkit-app-region:drag;-webkit-user-select:none;user-select:none}.electron-title-bar-draggable{flex-basis:content;-webkit-app-region:drag}.unfocused{color:var(--element-ui-3)}\n"] }]
84
+ args: [{ selector: 'si-electron-titlebar', imports: [CdkMenuTrigger, SiMenuFactoryComponent, SiIconComponent, SiTranslatePipe], changeDetection: ChangeDetectionStrategy.Default, template: "<div class=\"electron-title-bar-container w-100 bg-base-1 border-bottom fixed-top\">\n <div class=\"electron-title-bar align-items-center d-flex h-100 gap-6\">\n <span\n class=\"mx-6 si-body electron-title-bar-app-name text-truncate\"\n [class.unfocused]=\"!hasFocus()\"\n >{{ appTitle() }}</span\n >\n <button\n type=\"button\"\n class=\"btn btn-icon btn-sm btn-tertiary\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelBack() | translate\"\n [disabled]=\"!canGoBack()\"\n (click)=\"back.emit()\"\n >\n <si-icon class=\"flip-rtl\" [icon]=\"icons.elementLeft4\" />\n </button>\n <button\n type=\"button\"\n class=\"btn btn-icon btn-sm btn-tertiary\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelForward() | translate\"\n [disabled]=\"!canGoForward()\"\n (click)=\"forward.emit()\"\n >\n <si-icon class=\"flip-rtl\" [icon]=\"icons.elementRight4\" />\n </button>\n @if (menuItems().length > 0) {\n <button\n type=\"button\"\n class=\"btn btn-icon electron-title-bar-btn btn-tertiary btn-sm\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelMenu() | translate\"\n [cdkMenuTriggerFor]=\"menu\"\n >\n <si-icon [icon]=\"icons.elementOptionsVertical\" />\n </button>\n }\n <div class=\"electron-title-bar-draggable flex-grow-1 w-100 h-100\"></div>\n </div>\n</div>\n<ng-template #menu>\n <div class=\"mt-2\">\n <si-menu-factory [items]=\"menuItems()\" />\n </div>\n</ng-template>\n", styles: [".electron-title-bar-container{block-size:calc(1.5rem + 12px);z-index:1033;inset-block-start:var(--element-system-banner-spacing, 0px)}.electron-title-bar{position:absolute;inset-inline-start:env(titlebar-area-x,0);inline-size:env(titlebar-area-width,100%)}.electron-title-bar-app-name{color:var(--element-text-secondary);-webkit-app-region:drag;-webkit-user-select:none;user-select:none}.electron-title-bar-draggable{flex-basis:content;-webkit-app-region:drag}.unfocused{color:var(--element-ui-3)}\n"] }]
85
85
  }], propDecorators: { appTitle: [{ type: i0.Input, args: [{ isSignal: true, alias: "appTitle", required: true }] }], canGoBack: [{ type: i0.Input, args: [{ isSignal: true, alias: "canGoBack", required: false }] }], canGoForward: [{ type: i0.Input, args: [{ isSignal: true, alias: "canGoForward", required: false }] }], hasFocus: [{ type: i0.Input, args: [{ isSignal: true, alias: "hasFocus", required: false }] }], menuItems: [{ type: i0.Input, args: [{ isSignal: true, alias: "menuItems", required: false }] }], forward: [{ type: i0.Output, args: ["forward"] }], back: [{ type: i0.Output, args: ["back"] }], ariaLabelForward: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabelForward", required: false }] }], ariaLabelBack: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabelBack", required: false }] }], ariaLabelMenu: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabelMenu", required: false }] }] } });
86
86
 
87
87
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"siemens-element-ng-electron-titlebar.mjs","sources":["../../../../projects/element-ng/electron-titlebar/si-electron-titlebar.component.ts","../../../../projects/element-ng/electron-titlebar/si-electron-titlebar.component.html","../../../../projects/element-ng/electron-titlebar/si-electron-titlebar.module.ts","../../../../projects/element-ng/electron-titlebar/electron.helpers.ts","../../../../projects/element-ng/electron-titlebar/index.ts","../../../../projects/element-ng/electron-titlebar/siemens-element-ng-electron-titlebar.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { CdkMenuTrigger } from '@angular/cdk/menu';\nimport { booleanAttribute, Component, input, output } from '@angular/core';\nimport { elementLeft4, elementOptionsVertical, elementRight4 } from '@siemens/element-icons';\nimport { MenuItem as MenuItemLegacy } from '@siemens/element-ng/common';\nimport { addIcons, SiIconComponent } from '@siemens/element-ng/icon';\nimport { MenuItem, SiMenuFactoryComponent } from '@siemens/element-ng/menu';\nimport { SiTranslatePipe, t } from '@siemens/element-translate-ng/translate';\n\n@Component({\n selector: 'si-electron-titlebar',\n imports: [CdkMenuTrigger, SiMenuFactoryComponent, SiIconComponent, SiTranslatePipe],\n templateUrl: './si-electron-titlebar.component.html',\n styleUrl: './si-electron-titlebar.component.scss'\n})\nexport class SiElectrontitlebarComponent {\n /**\n * Title of your application\n */\n readonly appTitle = input.required<string>();\n\n /**\n * Defines if the application can go back or not\n *\n * @defaultValue false\n */\n readonly canGoBack = input(false, { transform: booleanAttribute });\n\n /**\n * Defines if the application can go forward or not\n *\n * @defaultValue false\n */\n readonly canGoForward = input(false, { transform: booleanAttribute });\n\n /**\n * Defines if the application is focused or not\n *\n * @defaultValue true\n */\n readonly hasFocus = input(true, { transform: booleanAttribute });\n\n /**\n * List of menu items for the dropdown\n * In this dropdown should the zoom functionality as well as the refresh function be provided\n *\n * @defaultValue []\n */\n readonly menuItems = input<(MenuItemLegacy | MenuItem)[]>([]);\n\n /**\n * Browsing forward function\n */\n readonly forward = output<void>();\n\n /**\n * Browsing back function\n */\n readonly back = output<void>();\n\n /**\n * Aria Label for Forward Button\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_ELECTRON_TITLEBAR.FORWARD:Forward`)\n * ```\n */\n readonly ariaLabelForward = input(t(() => $localize`:@@SI_ELECTRON_TITLEBAR.FORWARD:Forward`));\n\n /**\n * Aria Label for Back Button\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_ELECTRON_TITLEBAR.BACK:Back`)\n * ```\n */\n readonly ariaLabelBack = input(t(() => $localize`:@@SI_ELECTRON_TITLEBAR.BACK:Back`));\n\n /**\n * Aria Label for Menu Button\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_ELECTRON_TITLEBAR.MENU:Menu`)\n * ```\n */\n readonly ariaLabelMenu = input(t(() => $localize`:@@SI_ELECTRON_TITLEBAR.MENU:Menu`));\n\n protected readonly icons = addIcons({ elementLeft4, elementRight4, elementOptionsVertical });\n}\n","<div class=\"electron-title-bar-container w-100 bg-base-1 border-bottom fixed-top\">\n <div class=\"electron-title-bar align-items-center d-flex h-100 gap-6\">\n <span\n class=\"mx-6 si-body electron-title-bar-app-name text-truncate\"\n [class.unfocused]=\"!hasFocus()\"\n >{{ appTitle() }}</span\n >\n <button\n type=\"button\"\n class=\"btn btn-icon btn-sm btn-tertiary\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelBack() | translate\"\n [disabled]=\"!canGoBack()\"\n (click)=\"back.emit()\"\n >\n <si-icon class=\"flip-rtl\" [icon]=\"icons.elementLeft4\" />\n </button>\n <button\n type=\"button\"\n class=\"btn btn-icon btn-sm btn-tertiary\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelForward() | translate\"\n [disabled]=\"!canGoForward()\"\n (click)=\"forward.emit()\"\n >\n <si-icon class=\"flip-rtl\" [icon]=\"icons.elementRight4\" />\n </button>\n @if (menuItems().length > 0) {\n <button\n type=\"button\"\n class=\"btn btn-icon electron-title-bar-btn btn-tertiary btn-sm\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelMenu() | translate\"\n [cdkMenuTriggerFor]=\"menu\"\n >\n <si-icon [icon]=\"icons.elementOptionsVertical\" />\n </button>\n }\n <div class=\"electron-title-bar-draggable flex-grow-1 w-100 h-100\"></div>\n </div>\n</div>\n<ng-template #menu>\n <div class=\"mt-2\">\n <si-menu-factory [items]=\"menuItems()\" />\n </div>\n</ng-template>\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { NgModule } from '@angular/core';\n\nimport { SiElectrontitlebarComponent } from './si-electron-titlebar.component';\n\n@NgModule({\n imports: [SiElectrontitlebarComponent],\n exports: [SiElectrontitlebarComponent]\n})\nexport class SiElectrontitlebarModule {}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\n/** */\nexport const runsInElectron = (): boolean => {\n const windowAny = window as any;\n const processAny = windowAny.process as any;\n\n // Renderer process\n if (\n typeof windowAny !== 'undefined' &&\n typeof processAny === 'object' &&\n processAny.type === 'renderer'\n ) {\n return true;\n }\n\n // Main process\n if (\n typeof processAny !== 'undefined' &&\n typeof processAny.versions === 'object' &&\n !!processAny.versions.electron\n ) {\n return true;\n }\n\n // Detect the user agent when the `nodeIntegration` option is set to true\n if (\n typeof navigator === 'object' &&\n typeof navigator.userAgent === 'string' &&\n navigator.userAgent.includes('Electron')\n ) {\n return true;\n }\n return false;\n};\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-electron-titlebar.module';\nexport * from './si-electron-titlebar.component';\nexport * from './electron.helpers';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;AAAA;;;AAGG;MAeU,2BAA2B,CAAA;AACtC;;AAEG;AACM,IAAA,QAAQ,GAAG,KAAK,CAAC,QAAQ,mDAAU;AAE5C;;;;AAIG;IACM,SAAS,GAAG,KAAK,CAAC,KAAK,sDAAI,SAAS,EAAE,gBAAgB,EAAA,CAAG;AAElE;;;;AAIG;IACM,YAAY,GAAG,KAAK,CAAC,KAAK,yDAAI,SAAS,EAAE,gBAAgB,EAAA,CAAG;AAErE;;;;AAIG;IACM,QAAQ,GAAG,KAAK,CAAC,IAAI,qDAAI,SAAS,EAAE,gBAAgB,EAAA,CAAG;AAEhE;;;;;AAKG;AACM,IAAA,SAAS,GAAG,KAAK,CAAgC,EAAE,qDAAC;AAE7D;;AAEG;IACM,OAAO,GAAG,MAAM,EAAQ;AAEjC;;AAEG;IACM,IAAI,GAAG,MAAM,EAAQ;AAE9B;;;;;;;AAOG;AACM,IAAA,gBAAgB,GAAG,KAAK,CAAC,CAAC,CAAC,MAAM,SAAS,CAAA,CAAA,uCAAA,CAAyC,CAAC,4DAAC;AAE9F;;;;;;;AAOG;AACM,IAAA,aAAa,GAAG,KAAK,CAAC,CAAC,CAAC,MAAM,SAAS,CAAA,CAAA,iCAAA,CAAmC,CAAC,yDAAC;AAErF;;;;;;;AAOG;AACM,IAAA,aAAa,GAAG,KAAK,CAAC,CAAC,CAAC,MAAM,SAAS,CAAA,CAAA,iCAAA,CAAmC,CAAC,yDAAC;IAElE,KAAK,GAAG,QAAQ,CAAC,EAAE,YAAY,EAAE,aA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,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,wBAAwB,YAHzB,2BAA2B,CAAA,EAAA,CAAA;;2FAG1B,wBAAwB,EAAA,UAAA,EAAA,CAAA;kBAJpC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;oBACR,OAAO,EAAE,CAAC,2BAA2B,CAAC;oBACtC,OAAO,EAAE,CAAC,2BAA2B;AACtC,iBAAA;;;ACXD;;;AAGG;AACH;AACO,MAAM,cAAc,GAAG,MAAc;IAC1C,MAAM,SAAS,GAAG,MAAa;AAC/B,IAAA,MAAM,UAAU,GAAG,SAAS,CAAC,OAAc;;IAG3C,IACE,OAAO,SAAS,KAAK,WAAW;QAChC,OAAO,UAAU,KAAK,QAAQ;AAC9B,QAAA,UAAU,CAAC,IAAI,KAAK,UAAU,EAC9B;AACA,QAAA,OAAO,IAAI;IACb;;IAGA,IACE,OAAO,UAAU,KAAK,WAAW;AACjC,QAAA,OAAO,UAAU,CAAC,QAAQ,KAAK,QAAQ;AACvC,QAAA,CAAC,CAAC,UAAU,CAAC,QAAQ,CAAC,QAAQ,EAC9B;AACA,QAAA,OAAO,IAAI;IACb;;IAGA,IACE,OAAO,SAAS,KAAK,QAAQ;AAC7B,QAAA,OAAO,SAAS,CAAC,SAAS,KAAK,QAAQ;QACvC,SAAS,CAAC,SAAS,CAAC,QAAQ,CAAC,UAAU,CAAC,EACxC;AACA,QAAA,OAAO,IAAI;IACb;AACA,IAAA,OAAO,KAAK;AACd;;ACpCA;;;AAGG;;ACHH;;AAEG;;;;"}
1
+ {"version":3,"file":"siemens-element-ng-electron-titlebar.mjs","sources":["../../../../projects/element-ng/electron-titlebar/si-electron-titlebar.component.ts","../../../../projects/element-ng/electron-titlebar/si-electron-titlebar.component.html","../../../../projects/element-ng/electron-titlebar/si-electron-titlebar.module.ts","../../../../projects/element-ng/electron-titlebar/electron.helpers.ts","../../../../projects/element-ng/electron-titlebar/index.ts","../../../../projects/element-ng/electron-titlebar/siemens-element-ng-electron-titlebar.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { CdkMenuTrigger } from '@angular/cdk/menu';\nimport { booleanAttribute, ChangeDetectionStrategy, Component, input, output } from '@angular/core';\nimport { elementLeft4, elementOptionsVertical, elementRight4 } from '@siemens/element-icons';\nimport { MenuItem as MenuItemLegacy } from '@siemens/element-ng/common';\nimport { addIcons, SiIconComponent } from '@siemens/element-ng/icon';\nimport { MenuItem, SiMenuFactoryComponent } from '@siemens/element-ng/menu';\nimport { SiTranslatePipe, t } from '@siemens/element-translate-ng/translate';\n\n@Component({\n selector: 'si-electron-titlebar',\n imports: [CdkMenuTrigger, SiMenuFactoryComponent, SiIconComponent, SiTranslatePipe],\n templateUrl: './si-electron-titlebar.component.html',\n styleUrl: './si-electron-titlebar.component.scss',\n changeDetection: ChangeDetectionStrategy.Default\n})\nexport class SiElectrontitlebarComponent {\n /**\n * Title of your application\n */\n readonly appTitle = input.required<string>();\n\n /**\n * Defines if the application can go back or not\n *\n * @defaultValue false\n */\n readonly canGoBack = input(false, { transform: booleanAttribute });\n\n /**\n * Defines if the application can go forward or not\n *\n * @defaultValue false\n */\n readonly canGoForward = input(false, { transform: booleanAttribute });\n\n /**\n * Defines if the application is focused or not\n *\n * @defaultValue true\n */\n readonly hasFocus = input(true, { transform: booleanAttribute });\n\n /**\n * List of menu items for the dropdown\n * In this dropdown should the zoom functionality as well as the refresh function be provided\n *\n * @defaultValue []\n */\n readonly menuItems = input<(MenuItemLegacy | MenuItem)[]>([]);\n\n /**\n * Browsing forward function\n */\n readonly forward = output<void>();\n\n /**\n * Browsing back function\n */\n readonly back = output<void>();\n\n /**\n * Aria Label for Forward Button\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_ELECTRON_TITLEBAR.FORWARD:Forward`)\n * ```\n */\n readonly ariaLabelForward = input(t(() => $localize`:@@SI_ELECTRON_TITLEBAR.FORWARD:Forward`));\n\n /**\n * Aria Label for Back Button\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_ELECTRON_TITLEBAR.BACK:Back`)\n * ```\n */\n readonly ariaLabelBack = input(t(() => $localize`:@@SI_ELECTRON_TITLEBAR.BACK:Back`));\n\n /**\n * Aria Label for Menu Button\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_ELECTRON_TITLEBAR.MENU:Menu`)\n * ```\n */\n readonly ariaLabelMenu = input(t(() => $localize`:@@SI_ELECTRON_TITLEBAR.MENU:Menu`));\n\n protected readonly icons = addIcons({ elementLeft4, elementRight4, elementOptionsVertical });\n}\n","<div class=\"electron-title-bar-container w-100 bg-base-1 border-bottom fixed-top\">\n <div class=\"electron-title-bar align-items-center d-flex h-100 gap-6\">\n <span\n class=\"mx-6 si-body electron-title-bar-app-name text-truncate\"\n [class.unfocused]=\"!hasFocus()\"\n >{{ appTitle() }}</span\n >\n <button\n type=\"button\"\n class=\"btn btn-icon btn-sm btn-tertiary\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelBack() | translate\"\n [disabled]=\"!canGoBack()\"\n (click)=\"back.emit()\"\n >\n <si-icon class=\"flip-rtl\" [icon]=\"icons.elementLeft4\" />\n </button>\n <button\n type=\"button\"\n class=\"btn btn-icon btn-sm btn-tertiary\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelForward() | translate\"\n [disabled]=\"!canGoForward()\"\n (click)=\"forward.emit()\"\n >\n <si-icon class=\"flip-rtl\" [icon]=\"icons.elementRight4\" />\n </button>\n @if (menuItems().length > 0) {\n <button\n type=\"button\"\n class=\"btn btn-icon electron-title-bar-btn btn-tertiary btn-sm\"\n [class.unfocused]=\"!hasFocus()\"\n [attr.aria-label]=\"ariaLabelMenu() | translate\"\n [cdkMenuTriggerFor]=\"menu\"\n >\n <si-icon [icon]=\"icons.elementOptionsVertical\" />\n </button>\n }\n <div class=\"electron-title-bar-draggable flex-grow-1 w-100 h-100\"></div>\n </div>\n</div>\n<ng-template #menu>\n <div class=\"mt-2\">\n <si-menu-factory [items]=\"menuItems()\" />\n </div>\n</ng-template>\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { NgModule } from '@angular/core';\n\nimport { SiElectrontitlebarComponent } from './si-electron-titlebar.component';\n\n@NgModule({\n imports: [SiElectrontitlebarComponent],\n exports: [SiElectrontitlebarComponent]\n})\nexport class SiElectrontitlebarModule {}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\n/** */\nexport const runsInElectron = (): boolean => {\n const windowAny = window as any;\n const processAny = windowAny.process as any;\n\n // Renderer process\n if (\n typeof windowAny !== 'undefined' &&\n typeof processAny === 'object' &&\n processAny.type === 'renderer'\n ) {\n return true;\n }\n\n // Main process\n if (\n typeof processAny !== 'undefined' &&\n typeof processAny.versions === 'object' &&\n !!processAny.versions.electron\n ) {\n return true;\n }\n\n // Detect the user agent when the `nodeIntegration` option is set to true\n if (\n typeof navigator === 'object' &&\n typeof navigator.userAgent === 'string' &&\n navigator.userAgent.includes('Electron')\n ) {\n return true;\n }\n return false;\n};\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-electron-titlebar.module';\nexport * from './si-electron-titlebar.component';\nexport * from './electron.helpers';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;AAAA;;;AAGG;MAgBU,2BAA2B,CAAA;AACtC;;AAEG;AACM,IAAA,QAAQ,GAAG,KAAK,CAAC,QAAQ,mDAAU;AAE5C;;;;AAIG;IACM,SAAS,GAAG,KAAK,CAAC,KAAK,sDAAI,SAAS,EAAE,gBAAgB,EAAA,CAAG;AAElE;;;;AAIG;IACM,YAAY,GAAG,KAAK,CAAC,KAAK,yDAAI,SAAS,EAAE,gBAAgB,EAA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CAAC,OAAc;;IAG3C,IACE,OAAO,SAAS,KAAK,WAAW;QAChC,OAAO,UAAU,KAAK,QAAQ;AAC9B,QAAA,UAAU,CAAC,IAAI,KAAK,UAAU,EAC9B;AACA,QAAA,OAAO,IAAI;IACb;;IAGA,IACE,OAAO,UAAU,KAAK,WAAW;AACjC,QAAA,OAAO,UAAU,CAAC,QAAQ,KAAK,QAAQ;AACvC,QAAA,CAAC,CAAC,UAAU,CAAC,QAAQ,CAAC,QAAQ,EAC9B;AACA,QAAA,OAAO,IAAI;IACb;;IAGA,IACE,OAAO,SAAS,KAAK,QAAQ;AAC7B,QAAA,OAAO,SAAS,CAAC,SAAS,KAAK,QAAQ;QACvC,SAAS,CAAC,SAAS,CAAC,QAAQ,CAAC,UAAU,CAAC,EACxC;AACA,QAAA,OAAO,IAAI;IACb;AACA,IAAA,OAAO,KAAK;AACd;;ACpCA;;;AAGG;;ACHH;;AAEG;;;;"}
@@ -21,11 +21,11 @@ class SiEmptyStateComponent {
21
21
  */
22
22
  content = input(...(ngDevMode ? [undefined, { debugName: "content" }] : []));
23
23
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiEmptyStateComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
24
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: SiEmptyStateComponent, isStandalone: true, selector: "si-empty-state", inputs: { icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: true, transformFunction: null }, heading: { classPropertyName: "heading", publicName: "heading", isSignal: true, isRequired: true, transformFunction: null }, content: { classPropertyName: "content", publicName: "content", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"list-group-item-empty\">\n <si-icon class=\"state-icon\" [icon]=\"icon()\" />\n <h3 class=\"my-6 text-center\">{{ heading() | translate }}</h3>\n @if (content()) {\n <p class=\"text-pre-wrap text-center mb-6\">{{ content() | translate }}</p>\n }\n <ng-content />\n</div>\n", styles: [".list-group-item-empty{block-size:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;padding-inline:24px;padding-block:32px}.state-icon{color:var(--element-ui-2);font-size:80px}\n"], dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
24
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: SiEmptyStateComponent, isStandalone: true, selector: "si-empty-state", inputs: { icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: true, transformFunction: null }, heading: { classPropertyName: "heading", publicName: "heading", isSignal: true, isRequired: true, transformFunction: null }, content: { classPropertyName: "content", publicName: "content", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<div class=\"list-group-item-empty\">\n <si-icon class=\"state-icon\" [icon]=\"icon()\" />\n <span class=\"si-h3 my-6 text-center\">{{ heading() | translate }}</span>\n @if (content()) {\n <p class=\"text-pre-wrap text-center mb-6\">{{ content() | translate }}</p>\n }\n <ng-content />\n</div>\n", styles: [".list-group-item-empty{block-size:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;padding-inline:24px;padding-block:32px}.state-icon{color:var(--element-ui-2);font-size:80px}\n"], dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
25
25
  }
26
26
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiEmptyStateComponent, decorators: [{
27
27
  type: Component,
28
- args: [{ selector: 'si-empty-state', imports: [SiIconComponent, SiTranslatePipe], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"list-group-item-empty\">\n <si-icon class=\"state-icon\" [icon]=\"icon()\" />\n <h3 class=\"my-6 text-center\">{{ heading() | translate }}</h3>\n @if (content()) {\n <p class=\"text-pre-wrap text-center mb-6\">{{ content() | translate }}</p>\n }\n <ng-content />\n</div>\n", styles: [".list-group-item-empty{block-size:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;padding-inline:24px;padding-block:32px}.state-icon{color:var(--element-ui-2);font-size:80px}\n"] }]
28
+ args: [{ selector: 'si-empty-state', imports: [SiIconComponent, SiTranslatePipe], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div class=\"list-group-item-empty\">\n <si-icon class=\"state-icon\" [icon]=\"icon()\" />\n <span class=\"si-h3 my-6 text-center\">{{ heading() | translate }}</span>\n @if (content()) {\n <p class=\"text-pre-wrap text-center mb-6\">{{ content() | translate }}</p>\n }\n <ng-content />\n</div>\n", styles: [".list-group-item-empty{block-size:100%;display:flex;flex-direction:column;justify-content:center;align-items:center;padding-inline:24px;padding-block:32px}.state-icon{color:var(--element-ui-2);font-size:80px}\n"] }]
29
29
  }], propDecorators: { icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: true }] }], heading: [{ type: i0.Input, args: [{ isSignal: true, alias: "heading", required: true }] }], content: [{ type: i0.Input, args: [{ isSignal: true, alias: "content", required: false }] }] } });
30
30
 
31
31
  /**
@@ -1 +1 @@
1
- {"version":3,"file":"siemens-element-ng-empty-state.mjs","sources":["../../../../projects/element-ng/empty-state/si-empty-state.component.ts","../../../../projects/element-ng/empty-state/si-empty-state.component.html","../../../../projects/element-ng/empty-state/si-empty-state.module.ts","../../../../projects/element-ng/empty-state/index.ts","../../../../projects/element-ng/empty-state/siemens-element-ng-empty-state.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { ChangeDetectionStrategy, Component, input } from '@angular/core';\nimport { SiIconComponent } from '@siemens/element-ng/icon';\nimport { SiTranslatePipe, TranslatableString } from '@siemens/element-translate-ng/translate';\n\n@Component({\n selector: 'si-empty-state',\n imports: [SiIconComponent, SiTranslatePipe],\n templateUrl: './si-empty-state.component.html',\n styleUrl: './si-empty-state.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class SiEmptyStateComponent {\n /**\n * CSS class name of the desired icon.\n */\n readonly icon = input.required<string>();\n\n /**\n * Heading of empty state content.\n */\n readonly heading = input.required<TranslatableString>();\n\n /**\n * Description of empty state content.\n */\n readonly content = input<TranslatableString>();\n}\n","<div class=\"list-group-item-empty\">\n <si-icon class=\"state-icon\" [icon]=\"icon()\" />\n <h3 class=\"my-6 text-center\">{{ heading() | translate }}</h3>\n @if (content()) {\n <p class=\"text-pre-wrap text-center mb-6\">{{ content() | translate }}</p>\n }\n <ng-content />\n</div>\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { NgModule } from '@angular/core';\n\nimport { SiEmptyStateComponent } from './si-empty-state.component';\n\n@NgModule({\n imports: [SiEmptyStateComponent],\n exports: [SiEmptyStateComponent]\n})\nexport class SiEmptyStateModule {}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-empty-state.component';\nexport * from './si-empty-state.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AAAA;;;AAGG;MAYU,qBAAqB,CAAA;AAChC;;AAEG;AACM,IAAA,IAAI,GAAG,KAAK,CAAC,QAAQ,+CAAU;AAExC;;AAEG;AACM,IAAA,OAAO,GAAG,KAAK,CAAC,QAAQ,kDAAsB;AAEvD;;AAEG;IACM,OAAO,GAAG,KAAK,CAAA,IAAA,SAAA,GAAA,CAAA,SAAA,EAAA,EAAA,SAAA,EAAA,SAAA,EAAA,CAAA,GAAA,EAAA,CAAA,CAAsB;uGAdnC,qBAAqB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAArB,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA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,kBAAkB,EAAA,OAAA,EAAA,CAHnB,qBAAqB,CAAA,EAAA,OAAA,EAAA,CACrB,qBAAqB,CAAA,EAAA,CAAA;AAEpB,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,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-empty-state.mjs","sources":["../../../../projects/element-ng/empty-state/si-empty-state.component.ts","../../../../projects/element-ng/empty-state/si-empty-state.component.html","../../../../projects/element-ng/empty-state/si-empty-state.module.ts","../../../../projects/element-ng/empty-state/index.ts","../../../../projects/element-ng/empty-state/siemens-element-ng-empty-state.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { ChangeDetectionStrategy, Component, input } from '@angular/core';\nimport { SiIconComponent } from '@siemens/element-ng/icon';\nimport { SiTranslatePipe, TranslatableString } from '@siemens/element-translate-ng/translate';\n\n@Component({\n selector: 'si-empty-state',\n imports: [SiIconComponent, SiTranslatePipe],\n templateUrl: './si-empty-state.component.html',\n styleUrl: './si-empty-state.component.scss',\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class SiEmptyStateComponent {\n /**\n * CSS class name of the desired icon.\n */\n readonly icon = input.required<string>();\n\n /**\n * Heading of empty state content.\n */\n readonly heading = input.required<TranslatableString>();\n\n /**\n * Description of empty state content.\n */\n readonly content = input<TranslatableString>();\n}\n","<div class=\"list-group-item-empty\">\n <si-icon class=\"state-icon\" [icon]=\"icon()\" />\n <span class=\"si-h3 my-6 text-center\">{{ heading() | translate }}</span>\n @if (content()) {\n <p class=\"text-pre-wrap text-center mb-6\">{{ content() | translate }}</p>\n }\n <ng-content />\n</div>\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { NgModule } from '@angular/core';\n\nimport { SiEmptyStateComponent } from './si-empty-state.component';\n\n@NgModule({\n imports: [SiEmptyStateComponent],\n exports: [SiEmptyStateComponent]\n})\nexport class SiEmptyStateModule {}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-empty-state.component';\nexport * from './si-empty-state.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;AAAA;;;AAGG;MAYU,qBAAqB,CAAA;AAChC;;AAEG;AACM,IAAA,IAAI,GAAG,KAAK,CAAC,QAAQ,+CAAU;AAExC;;AAEG;AACM,IAAA,OAAO,GAAG,KAAK,CAAC,QAAQ,kDAAsB;AAEvD;;AAEG;IACM,OAAO,GAAG,KAAK,CAAA,IAAA,SAAA,GAAA,CAAA,SAAA,EAAA,EAAA,SAAA,EAAA,SAAA,EAAA,CAAA,GAAA,EAAA,CAAA,CAAsB;uGAdnC,qBAAqB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAArB,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,qBAAqB,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,gBAAA,EAAA,MAAA,EAAA,EAAA,IAAA,EAAA,EAAA,iBAAA,EAAA,MAAA,EAAA,UAAA,EAAA,MAAA,EAAA,QAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAA,iBAA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,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,5 +1,5 @@
1
1
  import * as i0 from '@angular/core';
2
- import { input, booleanAttribute, output, inject, ElementRef, LOCALE_ID, Directive, computed, viewChild, ChangeDetectionStrategy, Component, numberAttribute, ChangeDetectorRef, NgModule } from '@angular/core';
2
+ import { input, booleanAttribute, output, inject, ElementRef, LOCALE_ID, Directive, computed, viewChild, ChangeDetectionStrategy, Component, numberAttribute, signal, effect, untracked, NgModule } from '@angular/core';
3
3
  import { elementUpload, elementRedo, elementDocument, elementDelete, elementCancel } from '@siemens/element-icons';
4
4
  import { addIcons, SiIconComponent, SiStatusIconComponent } from '@siemens/element-ng/icon';
5
5
  import { t, SiTranslatePipe } from '@siemens/element-translate-ng/translate';
@@ -388,7 +388,7 @@ class SiFileDropzoneComponent {
388
388
  event.stopPropagation();
389
389
  this.dragOver = true;
390
390
  }
391
- inputEnterHandler() {
391
+ triggerFileSelect() {
392
392
  this.fileUploadDirective().triggerClick();
393
393
  }
394
394
  onFilesAdded(files) {
@@ -404,11 +404,11 @@ class SiFileDropzoneComponent {
404
404
  this.fileUploadDirective().reset();
405
405
  }
406
406
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiFileDropzoneComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
407
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: SiFileDropzoneComponent, isStandalone: true, selector: "si-file-dropzone", inputs: { uploadTextFileSelect: { classPropertyName: "uploadTextFileSelect", publicName: "uploadTextFileSelect", isSignal: true, isRequired: false, transformFunction: null }, uploadDropText: { classPropertyName: "uploadDropText", publicName: "uploadDropText", isSignal: true, isRequired: false, transformFunction: null }, maxFileSizeText: { classPropertyName: "maxFileSizeText", publicName: "maxFileSizeText", isSignal: true, isRequired: false, transformFunction: null }, acceptText: { classPropertyName: "acceptText", publicName: "acceptText", isSignal: true, isRequired: false, transformFunction: null }, errorTextFileType: { classPropertyName: "errorTextFileType", publicName: "errorTextFileType", isSignal: true, isRequired: false, transformFunction: null }, errorTextFileMaxSize: { classPropertyName: "errorTextFileMaxSize", publicName: "errorTextFileMaxSize", isSignal: true, isRequired: false, transformFunction: null }, accept: { classPropertyName: "accept", publicName: "accept", isSignal: true, isRequired: false, transformFunction: null }, maxFileSize: { classPropertyName: "maxFileSize", publicName: "maxFileSize", isSignal: true, isRequired: false, transformFunction: null }, multiple: { classPropertyName: "multiple", publicName: "multiple", isSignal: true, isRequired: false, transformFunction: null }, directoryUpload: { classPropertyName: "directoryUpload", publicName: "directoryUpload", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { filesAdded: "filesAdded", fileError: "fileError" }, viewQueries: [{ propertyName: "fileUploadDirective", first: true, predicate: SiFileUploadDirective, descendants: true, isSignal: true }], ngImport: i0, template: "<div\n class=\"drag-and-drop rounded p-6\"\n [class.drag-over]=\"dragOver\"\n (drop)=\"dropHandler($event)\"\n (dragover)=\"dragOverHandler($event)\"\n (dragleave)=\"dragOver = false\"\n>\n <si-icon class=\"mb-6 si-display-bold\" [icon]=\"icons.elementUpload\" />\n <span class=\"drag-and-drop-description si-h5 d-flex\">\n <span>{{ uploadDropText() | translate }}</span>\n &nbsp;\n <label class=\"select-file si-h5 mb-0\">\n <span tabindex=\"0\" (keydown.enter)=\"inputEnterHandler()\">{{\n uploadTextFileSelect() | translate\n }}</span>\n <input\n #fileInput\n type=\"file\"\n tabindex=\"-1\"\n class=\"d-none\"\n siFileUpload\n [accept]=\"accept()\"\n [maxFileSize]=\"maxFileSize()\"\n [multiple]=\"multiple()\"\n [directoryUpload]=\"directoryUpload()\"\n [errorTextFileType]=\"errorTextFileType()\"\n [errorTextFileMaxSize]=\"errorTextFileMaxSize()\"\n (filesAdded)=\"onFilesAdded($event)\"\n (fileError)=\"onFileError($event)\"\n (cancel)=\"$event.stopPropagation()\"\n />\n </label>\n </span>\n @if (maxFileSize() || accept()) {\n <div class=\"allowed si-caption mt-6 text-center\">\n @if (maxFileSize()) {\n {{ maxFileSizeText() | translate: { maxFileSize: maxFileSizeString() } }}\n }\n @if (accept()) {\n {{ acceptText() | translate: { accept: accept() } }}\n }\n </div>\n }\n</div>\n", styles: [":host{display:block}.select-file{margin-block-end:0;cursor:pointer;color:var(--element-ui-0)}.select-file:hover,.select-file:active{text-decoration:underline}.drag-and-drop{background-color:var(--element-base-1);border:1px dashed var(--element-ui-2);display:flex;flex-direction:column;justify-content:center;align-items:center}.drag-and-drop.drag-over{border:1px solid var(--element-focus-default);box-shadow:0 0 0 1px var(--element-focus-default)}\n"], dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "directive", type: SiFileUploadDirective, selector: "input[type=\"file\"][siFileUpload]", inputs: ["errorTextFileType", "errorTextFileMaxSize", "accept", "maxFileSize", "multiple", "directoryUpload"], outputs: ["validFiles", "filesAdded", "fileError"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
407
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: SiFileDropzoneComponent, isStandalone: true, selector: "si-file-dropzone", inputs: { uploadTextFileSelect: { classPropertyName: "uploadTextFileSelect", publicName: "uploadTextFileSelect", isSignal: true, isRequired: false, transformFunction: null }, uploadDropText: { classPropertyName: "uploadDropText", publicName: "uploadDropText", isSignal: true, isRequired: false, transformFunction: null }, maxFileSizeText: { classPropertyName: "maxFileSizeText", publicName: "maxFileSizeText", isSignal: true, isRequired: false, transformFunction: null }, acceptText: { classPropertyName: "acceptText", publicName: "acceptText", isSignal: true, isRequired: false, transformFunction: null }, errorTextFileType: { classPropertyName: "errorTextFileType", publicName: "errorTextFileType", isSignal: true, isRequired: false, transformFunction: null }, errorTextFileMaxSize: { classPropertyName: "errorTextFileMaxSize", publicName: "errorTextFileMaxSize", isSignal: true, isRequired: false, transformFunction: null }, accept: { classPropertyName: "accept", publicName: "accept", isSignal: true, isRequired: false, transformFunction: null }, maxFileSize: { classPropertyName: "maxFileSize", publicName: "maxFileSize", isSignal: true, isRequired: false, transformFunction: null }, multiple: { classPropertyName: "multiple", publicName: "multiple", isSignal: true, isRequired: false, transformFunction: null }, directoryUpload: { classPropertyName: "directoryUpload", publicName: "directoryUpload", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { filesAdded: "filesAdded", fileError: "fileError" }, viewQueries: [{ propertyName: "fileUploadDirective", first: true, predicate: SiFileUploadDirective, descendants: true, isSignal: true }], ngImport: i0, template: "<div\n class=\"drag-and-drop rounded p-6\"\n [class.drag-over]=\"dragOver\"\n (drop)=\"dropHandler($event)\"\n (dragover)=\"dragOverHandler($event)\"\n (dragleave)=\"dragOver = false\"\n>\n <si-icon class=\"mb-6 si-display-bold\" [icon]=\"icons.elementUpload\" />\n <span class=\"drag-and-drop-description si-h5 d-flex\">\n <span>{{ uploadDropText() | translate }}</span>\n &nbsp;\n <button type=\"button\" class=\"select-file si-h5 mb-0\" (click)=\"triggerFileSelect()\">\n {{ uploadTextFileSelect() | translate }}\n </button>\n <input\n #fileInput\n type=\"file\"\n tabindex=\"-1\"\n class=\"d-none\"\n siFileUpload\n [accept]=\"accept()\"\n [maxFileSize]=\"maxFileSize()\"\n [multiple]=\"multiple()\"\n [directoryUpload]=\"directoryUpload()\"\n [errorTextFileType]=\"errorTextFileType()\"\n [errorTextFileMaxSize]=\"errorTextFileMaxSize()\"\n (filesAdded)=\"onFilesAdded($event)\"\n (fileError)=\"onFileError($event)\"\n (cancel)=\"$event.stopPropagation()\"\n />\n </span>\n @if (maxFileSize() || accept()) {\n <div class=\"allowed si-caption mt-6 text-center\">\n @if (maxFileSize()) {\n {{ maxFileSizeText() | translate: { maxFileSize: maxFileSizeString() } }}\n }\n @if (accept()) {\n {{ acceptText() | translate: { accept: accept() } }}\n }\n </div>\n }\n</div>\n", styles: [":host{display:block}.select-file{margin-block-end:0;padding:0;border:0;background:transparent;cursor:pointer;color:var(--element-ui-0)}.select-file:hover,.select-file:active{text-decoration:underline}.drag-and-drop{background-color:var(--element-base-1);border:1px dashed var(--element-ui-2);display:flex;flex-direction:column;justify-content:center;align-items:center}.drag-and-drop.drag-over{border:1px solid var(--element-focus-default);box-shadow:0 0 0 1px var(--element-focus-default)}\n"], dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "directive", type: SiFileUploadDirective, selector: "input[type=\"file\"][siFileUpload]", inputs: ["errorTextFileType", "errorTextFileMaxSize", "accept", "maxFileSize", "multiple", "directoryUpload"], outputs: ["validFiles", "filesAdded", "fileError"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
408
408
  }
409
409
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiFileDropzoneComponent, decorators: [{
410
410
  type: Component,
411
- args: [{ selector: 'si-file-dropzone', imports: [SiIconComponent, SiTranslatePipe, SiFileUploadDirective], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div\n class=\"drag-and-drop rounded p-6\"\n [class.drag-over]=\"dragOver\"\n (drop)=\"dropHandler($event)\"\n (dragover)=\"dragOverHandler($event)\"\n (dragleave)=\"dragOver = false\"\n>\n <si-icon class=\"mb-6 si-display-bold\" [icon]=\"icons.elementUpload\" />\n <span class=\"drag-and-drop-description si-h5 d-flex\">\n <span>{{ uploadDropText() | translate }}</span>\n &nbsp;\n <label class=\"select-file si-h5 mb-0\">\n <span tabindex=\"0\" (keydown.enter)=\"inputEnterHandler()\">{{\n uploadTextFileSelect() | translate\n }}</span>\n <input\n #fileInput\n type=\"file\"\n tabindex=\"-1\"\n class=\"d-none\"\n siFileUpload\n [accept]=\"accept()\"\n [maxFileSize]=\"maxFileSize()\"\n [multiple]=\"multiple()\"\n [directoryUpload]=\"directoryUpload()\"\n [errorTextFileType]=\"errorTextFileType()\"\n [errorTextFileMaxSize]=\"errorTextFileMaxSize()\"\n (filesAdded)=\"onFilesAdded($event)\"\n (fileError)=\"onFileError($event)\"\n (cancel)=\"$event.stopPropagation()\"\n />\n </label>\n </span>\n @if (maxFileSize() || accept()) {\n <div class=\"allowed si-caption mt-6 text-center\">\n @if (maxFileSize()) {\n {{ maxFileSizeText() | translate: { maxFileSize: maxFileSizeString() } }}\n }\n @if (accept()) {\n {{ acceptText() | translate: { accept: accept() } }}\n }\n </div>\n }\n</div>\n", styles: [":host{display:block}.select-file{margin-block-end:0;cursor:pointer;color:var(--element-ui-0)}.select-file:hover,.select-file:active{text-decoration:underline}.drag-and-drop{background-color:var(--element-base-1);border:1px dashed var(--element-ui-2);display:flex;flex-direction:column;justify-content:center;align-items:center}.drag-and-drop.drag-over{border:1px solid var(--element-focus-default);box-shadow:0 0 0 1px var(--element-focus-default)}\n"] }]
411
+ args: [{ selector: 'si-file-dropzone', imports: [SiIconComponent, SiTranslatePipe, SiFileUploadDirective], changeDetection: ChangeDetectionStrategy.OnPush, template: "<div\n class=\"drag-and-drop rounded p-6\"\n [class.drag-over]=\"dragOver\"\n (drop)=\"dropHandler($event)\"\n (dragover)=\"dragOverHandler($event)\"\n (dragleave)=\"dragOver = false\"\n>\n <si-icon class=\"mb-6 si-display-bold\" [icon]=\"icons.elementUpload\" />\n <span class=\"drag-and-drop-description si-h5 d-flex\">\n <span>{{ uploadDropText() | translate }}</span>\n &nbsp;\n <button type=\"button\" class=\"select-file si-h5 mb-0\" (click)=\"triggerFileSelect()\">\n {{ uploadTextFileSelect() | translate }}\n </button>\n <input\n #fileInput\n type=\"file\"\n tabindex=\"-1\"\n class=\"d-none\"\n siFileUpload\n [accept]=\"accept()\"\n [maxFileSize]=\"maxFileSize()\"\n [multiple]=\"multiple()\"\n [directoryUpload]=\"directoryUpload()\"\n [errorTextFileType]=\"errorTextFileType()\"\n [errorTextFileMaxSize]=\"errorTextFileMaxSize()\"\n (filesAdded)=\"onFilesAdded($event)\"\n (fileError)=\"onFileError($event)\"\n (cancel)=\"$event.stopPropagation()\"\n />\n </span>\n @if (maxFileSize() || accept()) {\n <div class=\"allowed si-caption mt-6 text-center\">\n @if (maxFileSize()) {\n {{ maxFileSizeText() | translate: { maxFileSize: maxFileSizeString() } }}\n }\n @if (accept()) {\n {{ acceptText() | translate: { accept: accept() } }}\n }\n </div>\n }\n</div>\n", styles: [":host{display:block}.select-file{margin-block-end:0;padding:0;border:0;background:transparent;cursor:pointer;color:var(--element-ui-0)}.select-file:hover,.select-file:active{text-decoration:underline}.drag-and-drop{background-color:var(--element-base-1);border:1px dashed var(--element-ui-2);display:flex;flex-direction:column;justify-content:center;align-items:center}.drag-and-drop.drag-over{border:1px solid var(--element-focus-default);box-shadow:0 0 0 1px var(--element-focus-default)}\n"] }]
412
412
  }], propDecorators: { uploadTextFileSelect: [{ type: i0.Input, args: [{ isSignal: true, alias: "uploadTextFileSelect", required: false }] }], uploadDropText: [{ type: i0.Input, args: [{ isSignal: true, alias: "uploadDropText", required: false }] }], maxFileSizeText: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxFileSizeText", required: false }] }], acceptText: [{ type: i0.Input, args: [{ isSignal: true, alias: "acceptText", required: false }] }], errorTextFileType: [{ type: i0.Input, args: [{ isSignal: true, alias: "errorTextFileType", required: false }] }], errorTextFileMaxSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "errorTextFileMaxSize", required: false }] }], accept: [{ type: i0.Input, args: [{ isSignal: true, alias: "accept", required: false }] }], maxFileSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxFileSize", required: false }] }], multiple: [{ type: i0.Input, args: [{ isSignal: true, alias: "multiple", required: false }] }], filesAdded: [{ type: i0.Output, args: ["filesAdded"] }], fileError: [{ type: i0.Output, args: ["fileError"] }], directoryUpload: [{ type: i0.Input, args: [{ isSignal: true, alias: "directoryUpload", required: false }] }], fileUploadDirective: [{ type: i0.ViewChild, args: [i0.forwardRef(() => SiFileUploadDirective), { isSignal: true }] }] } });
413
413
 
414
414
  /**
@@ -640,18 +640,20 @@ class SiFileUploaderComponent {
640
640
  elementDocument,
641
641
  elementRedo
642
642
  });
643
- files = [];
643
+ files = signal([], ...(ngDevMode ? [{ debugName: "files" }] : []));
644
644
  pending = 0;
645
645
  uploading = 0;
646
- uploadEnabled = false;
647
- maxFilesReached = false;
646
+ uploadEnabled = signal(false, ...(ngDevMode ? [{ debugName: "uploadEnabled" }] : []));
647
+ maxFilesReached = signal(false, ...(ngDevMode ? [{ debugName: "maxFilesReached" }] : []));
648
648
  dropZone = viewChild.required('dropZone');
649
- cdRef = inject(ChangeDetectorRef);
650
649
  http = inject(HttpClient, { optional: true });
651
- ngOnChanges(changes) {
652
- if (changes.maxFiles || changes.disableUpload) {
653
- this.updateStates();
654
- }
650
+ constructor() {
651
+ effect(() => {
652
+ // Track only these inputs; use untracked to avoid tracking files() inside updateStates()
653
+ this.maxFiles();
654
+ this.disableUpload();
655
+ untracked(() => this.updateStates());
656
+ });
655
657
  }
656
658
  handleFiles(files) {
657
659
  if (!files?.length) {
@@ -659,12 +661,13 @@ class SiFileUploaderComponent {
659
661
  }
660
662
  const maxFiles = this.maxFiles();
661
663
  // for single-file case, replace exiting file if any
662
- if (maxFiles === 1 && this.files.length) {
664
+ if (maxFiles === 1 && this.files().length) {
663
665
  this.reset(false);
664
666
  }
665
667
  let numValid = this.countValid();
668
+ const current = this.files().slice();
666
669
  for (const file of files) {
667
- const duplicate = this.isDuplicate(file);
670
+ const duplicate = this.isDuplicate(file, current);
668
671
  if (duplicate) {
669
672
  // in case this is duplicated: reset if already uploaded or not handled yet
670
673
  if (duplicate.status !== 'uploading' && duplicate.status !== 'queued') {
@@ -675,29 +678,28 @@ class SiFileUploaderComponent {
675
678
  const canAdd = numValid + 1 <= maxFiles;
676
679
  const valid = file.status === 'added';
677
680
  if (valid && !canAdd) {
678
- this.maxFilesReached = true;
681
+ this.maxFilesReached.set(true);
679
682
  break;
680
683
  }
681
684
  else if (valid) {
682
685
  numValid++;
683
686
  }
684
- this.files.push(file);
687
+ current.push(file);
685
688
  }
686
- this.files.sort((a, b) => a.fileName.localeCompare(b.fileName));
687
- this.filesChanges.emit(this.files.slice());
689
+ current.sort((a, b) => a.fileName.localeCompare(b.fileName));
690
+ this.files.set(current);
691
+ this.filesChanges.emit(current.slice());
688
692
  this.updateStates();
689
- // needed for drag drop of directory
690
- this.cdRef.markForCheck();
691
693
  if (this.autoUpload()) {
692
694
  // allow concurrent uploads for auto upload mode.
693
- this.uploadEnabled = true;
695
+ this.uploadEnabled.set(true);
694
696
  this.fileUpload(false);
695
697
  }
696
698
  }
697
699
  removeFile(index) {
698
700
  if (index >= 0) {
699
- this.files.splice(index, 1);
700
- this.filesChanges.emit(this.files.slice());
701
+ this.files.update(current => current.filter((_, i) => i !== index));
702
+ this.filesChanges.emit(this.files());
701
703
  this.dropZone().reset();
702
704
  this.updateStates();
703
705
  }
@@ -711,6 +713,7 @@ class SiFileUploaderComponent {
711
713
  this.pending--;
712
714
  file.status = 'added';
713
715
  file.progress = 0;
716
+ this.files.update(f => [...f]);
714
717
  this.updateStates();
715
718
  const { status, fileName, size, progress } = file;
716
719
  this.uploadCanceled.emit({
@@ -729,8 +732,8 @@ class SiFileUploaderComponent {
729
732
  * Reset the state.
730
733
  */
731
734
  reset(emit = true) {
732
- this.files.forEach(f => f.subscription?.unsubscribe());
733
- this.files = [];
735
+ this.files().forEach(f => f.subscription?.unsubscribe());
736
+ this.files.set([]);
734
737
  this.dropZone().reset();
735
738
  this.updateStates();
736
739
  if (emit) {
@@ -741,11 +744,11 @@ class SiFileUploaderComponent {
741
744
  * Uploads the file
742
745
  */
743
746
  fileUpload(doRetry = true) {
744
- if (!this.uploadEnabled) {
747
+ if (!this.uploadEnabled()) {
745
748
  return;
746
749
  }
747
- this.uploadEnabled = false;
748
- this.doUpload(this.files, doRetry);
750
+ this.uploadEnabled.set(false);
751
+ this.doUpload(this.files(), doRetry);
749
752
  }
750
753
  doUpload(files, doRetry) {
751
754
  for (const file of files) {
@@ -758,8 +761,8 @@ class SiFileUploaderComponent {
758
761
  this.processQueue();
759
762
  }
760
763
  processQueue() {
761
- for (let i = 0; i < this.files.length && this.uploading < this.maxConcurrentUploads(); i++) {
762
- const file = this.files[i];
764
+ for (let i = 0; i < this.files().length && this.uploading < this.maxConcurrentUploads(); i++) {
765
+ const file = this.files()[i];
763
766
  if (file.status === 'queued') {
764
767
  this.uploading++;
765
768
  this.uploadOneFile(file);
@@ -788,6 +791,7 @@ class SiFileUploaderComponent {
788
791
  file.status = 'uploading';
789
792
  file.errorText = undefined;
790
793
  file.httpErrorText = undefined;
794
+ this.files.update(f => [...f]);
791
795
  const requestHandler = config.handler ??
792
796
  (this.http ? (r) => this.http.request(r) : undefined);
793
797
  if (!requestHandler) {
@@ -802,8 +806,8 @@ class SiFileUploaderComponent {
802
806
  });
803
807
  }
804
808
  // this is a light check for duplicate file - name and size only, not content!
805
- isDuplicate(file) {
806
- for (const uploadFile of this.files) {
809
+ isDuplicate(file, current) {
810
+ for (const uploadFile of current) {
807
811
  if (uploadFile.file.name === file.file.name && uploadFile.file.size === file.file.size) {
808
812
  return uploadFile;
809
813
  }
@@ -816,7 +820,7 @@ class SiFileUploaderComponent {
816
820
  }
817
821
  else if (httpEvent.type === HttpEventType.UploadProgress && httpEvent.total) {
818
822
  file.progress = Math.floor((100 * httpEvent.loaded) / httpEvent.total);
819
- this.cdRef.markForCheck();
823
+ this.files.update(f => [...f]);
820
824
  }
821
825
  }
822
826
  handleUploadError(file, error) {
@@ -842,34 +846,32 @@ class SiFileUploaderComponent {
842
846
  file.subscription = undefined;
843
847
  this.pending--;
844
848
  this.uploading--;
849
+ this.files.update(f => [...f]);
845
850
  this.updateStates();
846
851
  this.processQueue();
847
852
  }
848
853
  fadeOut(file) {
849
854
  setTimeout(() => {
850
855
  file.fadeOut = true;
851
- this.cdRef.markForCheck();
856
+ this.files.update(f => [...f]);
852
857
  setTimeout(() => {
853
- this.removeFile(this.files.indexOf(file));
854
- this.cdRef.markForCheck();
858
+ this.removeFile(this.files().indexOf(file));
855
859
  }, 500);
856
- this.cdRef.markForCheck();
857
860
  }, 3500);
858
861
  }
859
862
  updateStates() {
860
- this.uploadEnabled =
861
- !this.disableUpload() &&
862
- !this.pending &&
863
- this.files.some(f => f.status === 'added' || f.status === 'error');
864
- if (this.maxFilesReached && this.countValid() < this.maxFiles()) {
865
- this.maxFilesReached = false;
863
+ this.uploadEnabled.set(!this.disableUpload() &&
864
+ !this.pending &&
865
+ this.files().some(f => f.status === 'added' || f.status === 'error'));
866
+ if (this.maxFilesReached() && this.countValid() < this.maxFiles()) {
867
+ this.maxFilesReached.set(false);
866
868
  }
867
869
  }
868
870
  countValid() {
869
- return this.files.reduce((acc, f) => acc + (f.status !== 'invalid' ? 1 : 0), 0);
871
+ return this.files().reduce((acc, f) => acc + (f.status !== 'invalid' ? 1 : 0), 0);
870
872
  }
871
873
  static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiFileUploaderComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
872
- static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: SiFileUploaderComponent, isStandalone: true, selector: "si-file-uploader", inputs: { uploadTextFileSelect: { classPropertyName: "uploadTextFileSelect", publicName: "uploadTextFileSelect", isSignal: true, isRequired: false, transformFunction: null }, uploadDropText: { classPropertyName: "uploadDropText", publicName: "uploadDropText", isSignal: true, isRequired: false, transformFunction: null }, maxFileSizeText: { classPropertyName: "maxFileSizeText", publicName: "maxFileSizeText", isSignal: true, isRequired: false, transformFunction: null }, maxFilesReachedText: { classPropertyName: "maxFilesReachedText", publicName: "maxFilesReachedText", isSignal: true, isRequired: false, transformFunction: null }, acceptText: { classPropertyName: "acceptText", publicName: "acceptText", isSignal: true, isRequired: false, transformFunction: null }, uploadButtonText: { classPropertyName: "uploadButtonText", publicName: "uploadButtonText", isSignal: true, isRequired: false, transformFunction: null }, clearButtonText: { classPropertyName: "clearButtonText", publicName: "clearButtonText", isSignal: true, isRequired: false, transformFunction: null }, uploadingText: { classPropertyName: "uploadingText", publicName: "uploadingText", isSignal: true, isRequired: false, transformFunction: null }, removeButtonText: { classPropertyName: "removeButtonText", publicName: "removeButtonText", isSignal: true, isRequired: false, transformFunction: null }, cancelButtonText: { classPropertyName: "cancelButtonText", publicName: "cancelButtonText", isSignal: true, isRequired: false, transformFunction: null }, successTextTitle: { classPropertyName: "successTextTitle", publicName: "successTextTitle", isSignal: true, isRequired: false, transformFunction: null }, errorUploadFailed: { classPropertyName: "errorUploadFailed", publicName: "errorUploadFailed", isSignal: true, isRequired: false, transformFunction: null }, showHttpError: { classPropertyName: "showHttpError", publicName: "showHttpError", isSignal: true, isRequired: false, transformFunction: null }, errorTextFileType: { classPropertyName: "errorTextFileType", publicName: "errorTextFileType", isSignal: true, isRequired: false, transformFunction: null }, errorTextFileMaxSize: { classPropertyName: "errorTextFileMaxSize", publicName: "errorTextFileMaxSize", isSignal: true, isRequired: false, transformFunction: null }, uploadConfig: { classPropertyName: "uploadConfig", publicName: "uploadConfig", isSignal: true, isRequired: false, transformFunction: null }, accept: { classPropertyName: "accept", publicName: "accept", isSignal: true, isRequired: false, transformFunction: null }, maxFileSize: { classPropertyName: "maxFileSize", publicName: "maxFileSize", isSignal: true, isRequired: false, transformFunction: null }, maxFiles: { classPropertyName: "maxFiles", publicName: "maxFiles", isSignal: true, isRequired: false, transformFunction: null }, maxConcurrentUploads: { classPropertyName: "maxConcurrentUploads", publicName: "maxConcurrentUploads", isSignal: true, isRequired: false, transformFunction: null }, retries: { classPropertyName: "retries", publicName: "retries", isSignal: true, isRequired: false, transformFunction: null }, autoUpload: { classPropertyName: "autoUpload", publicName: "autoUpload", isSignal: true, isRequired: false, transformFunction: null }, disableUpload: { classPropertyName: "disableUpload", publicName: "disableUpload", isSignal: true, isRequired: false, transformFunction: null }, directoryUpload: { classPropertyName: "directoryUpload", publicName: "directoryUpload", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { uploadCanceled: "uploadCanceled", uploadCompleted: "uploadCompleted", filesChanges: "filesChanges" }, viewQueries: [{ propertyName: "dropZone", first: true, predicate: ["dropZone"], descendants: true, isSignal: true }], usesOnChanges: true, ngImport: i0, template: "<si-file-dropzone\n #dropZone\n [class]=\"autoUpload() ? 'mb-8' : 'mb-4'\"\n [uploadTextFileSelect]=\"uploadTextFileSelect()\"\n [uploadDropText]=\"uploadDropText()\"\n [multiple]=\"maxFiles() > 1\"\n [directoryUpload]=\"directoryUpload()\"\n [maxFileSizeText]=\"maxFileSizeText()\"\n [acceptText]=\"acceptText()\"\n [errorTextFileType]=\"errorTextFileType()\"\n [errorTextFileMaxSize]=\"errorTextFileMaxSize()\"\n [accept]=\"accept()\"\n [maxFileSize]=\"maxFileSize()\"\n (filesAdded)=\"handleFiles($event)\"\n/>\n\n@if (maxFilesReached) {\n <si-inline-notification\n class=\"mb-4\"\n severity=\"info\"\n [message]=\"maxFilesReachedText()\"\n [translationParams]=\"{ maxFiles: maxFiles() }\"\n />\n}\n\n<div class=\"file-list\">\n @for (file of files; track file) {\n <div class=\"file\" [class.fade-out]=\"file.fadeOut\">\n <si-icon class=\"icon align-self-center ms-6 me-4\" icon=\"element-document\" />\n <div class=\"flex-fill overflow-hidden mt-6\">\n <div class=\"file-info\">\n <div class=\"file-name text-truncate si-h5\">{{ file.fileName }}</div>\n <div class=\"file-size text-secondary\">{{ file.size }}</div>\n @if (file.errorText) {\n <div\n class=\"d-inline-flex gap-2 error text-truncate\"\n [class.text-warning]=\"file.status === 'invalid'\"\n [class.text-danger]=\"file.status === 'error'\"\n >\n <si-status-icon\n class=\"icon-sm\"\n [status]=\"file.status === 'invalid' ? 'warning' : 'danger'\"\n />\n {{ file.errorText | translate: file.errorParams }}\n @if (file.httpErrorText) {\n : {{ file.httpErrorText }}\n }\n </div>\n } @else {\n <div class=\"position-relative mt-1 mb-5\">\n <div class=\"position-absolute end-0 progress-value\">{{ file.progress }} %</div>\n <si-progressbar\n height=\"small\"\n [value]=\"file.progress\"\n [ariaLabel]=\"uploadingText() | translate\"\n />\n </div>\n }\n </div>\n </div>\n <div class=\"status align-self-center text-nowrap ps-4 pe-6\">\n @if (file.status === 'error') {\n <button\n type=\"button\"\n class=\"btn btn-circle btn-tertiary me-4\"\n [disabled]=\"!uploadEnabled\"\n [title]=\"uploadButtonText() | translate\"\n [attr.aria-label]=\"uploadButtonText() | translate\"\n (click)=\"retryUpload(file)\"\n >\n <si-icon [icon]=\"icons.elementRedo\" />\n </button>\n }\n @if (file.status === 'added' || file.status === 'error' || file.status === 'invalid') {\n <button\n type=\"button\"\n class=\"btn btn-circle btn-tertiary-ghost\"\n [title]=\"removeButtonText() | translate\"\n [attr.aria-label]=\"removeButtonText() | translate\"\n (click)=\"removeFile($index)\"\n >\n <si-icon [icon]=\"icons.elementDelete\" />\n </button>\n }\n @if (file.status === 'uploading' || file.status === 'queued') {\n <button\n type=\"button\"\n class=\"btn btn-circle btn-tertiary\"\n [title]=\"cancelButtonText() | translate\"\n [attr.aria-label]=\"cancelButtonText() | translate\"\n (click)=\"cancelUpload(file)\"\n >\n <si-icon [icon]=\"icons.elementCancel\" />\n </button>\n }\n @if (file.status === 'success') {\n <si-status-icon class=\"icon mx-2\" status=\"success\" />\n }\n </div>\n </div>\n }\n</div>\n\n@if (!autoUpload()) {\n <div class=\"buttons text-end\">\n <button\n type=\"button\"\n class=\"btn btn-secondary me-4\"\n [disabled]=\"pending || !files.length\"\n (click)=\"reset()\"\n >{{ clearButtonText() | translate }}</button\n >\n <button\n type=\"button\"\n class=\"btn btn-primary\"\n [disabled]=\"!uploadEnabled\"\n (click)=\"fileUpload()\"\n >{{ uploadButtonText() | translate }}</button\n >\n </div>\n}\n", styles: [":host{display:flex;flex-direction:column;justify-content:center;align-items:stretch}:host>*{min-inline-size:320px;max-inline-size:680px;inline-size:100%;align-self:center}.file-list{overflow-y:auto}.file-info{display:flex;justify-content:center;flex-direction:column}.progress-value{inset-block-start:-1lh}.file{display:flex;position:relative;margin-block-end:8px;min-block-size:72px;transition:opacity calc(.5s * var(--element-animations-enabled, 1))}.fade-out{opacity:0}\n"], dependencies: [{ kind: "component", type: SiStatusIconComponent, selector: "si-status-icon", inputs: ["status"] }, { kind: "component", type: SiFileDropzoneComponent, selector: "si-file-dropzone", inputs: ["uploadTextFileSelect", "uploadDropText", "maxFileSizeText", "acceptText", "errorTextFileType", "errorTextFileMaxSize", "accept", "maxFileSize", "multiple", "directoryUpload"], outputs: ["filesAdded", "fileError"] }, { kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "component", type: SiInlineNotificationComponent, selector: "si-inline-notification", inputs: ["severity", "heading", "message", "action", "translationParams", "embedded"] }, { kind: "component", type: SiProgressbarComponent, selector: "si-progressbar", inputs: ["ariaLabel", "max", "value", "heading", "progress", "height"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }] });
874
+ static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "21.0.8", type: SiFileUploaderComponent, isStandalone: true, selector: "si-file-uploader", inputs: { uploadTextFileSelect: { classPropertyName: "uploadTextFileSelect", publicName: "uploadTextFileSelect", isSignal: true, isRequired: false, transformFunction: null }, uploadDropText: { classPropertyName: "uploadDropText", publicName: "uploadDropText", isSignal: true, isRequired: false, transformFunction: null }, maxFileSizeText: { classPropertyName: "maxFileSizeText", publicName: "maxFileSizeText", isSignal: true, isRequired: false, transformFunction: null }, maxFilesReachedText: { classPropertyName: "maxFilesReachedText", publicName: "maxFilesReachedText", isSignal: true, isRequired: false, transformFunction: null }, acceptText: { classPropertyName: "acceptText", publicName: "acceptText", isSignal: true, isRequired: false, transformFunction: null }, uploadButtonText: { classPropertyName: "uploadButtonText", publicName: "uploadButtonText", isSignal: true, isRequired: false, transformFunction: null }, clearButtonText: { classPropertyName: "clearButtonText", publicName: "clearButtonText", isSignal: true, isRequired: false, transformFunction: null }, uploadingText: { classPropertyName: "uploadingText", publicName: "uploadingText", isSignal: true, isRequired: false, transformFunction: null }, removeButtonText: { classPropertyName: "removeButtonText", publicName: "removeButtonText", isSignal: true, isRequired: false, transformFunction: null }, cancelButtonText: { classPropertyName: "cancelButtonText", publicName: "cancelButtonText", isSignal: true, isRequired: false, transformFunction: null }, successTextTitle: { classPropertyName: "successTextTitle", publicName: "successTextTitle", isSignal: true, isRequired: false, transformFunction: null }, errorUploadFailed: { classPropertyName: "errorUploadFailed", publicName: "errorUploadFailed", isSignal: true, isRequired: false, transformFunction: null }, showHttpError: { classPropertyName: "showHttpError", publicName: "showHttpError", isSignal: true, isRequired: false, transformFunction: null }, errorTextFileType: { classPropertyName: "errorTextFileType", publicName: "errorTextFileType", isSignal: true, isRequired: false, transformFunction: null }, errorTextFileMaxSize: { classPropertyName: "errorTextFileMaxSize", publicName: "errorTextFileMaxSize", isSignal: true, isRequired: false, transformFunction: null }, uploadConfig: { classPropertyName: "uploadConfig", publicName: "uploadConfig", isSignal: true, isRequired: false, transformFunction: null }, accept: { classPropertyName: "accept", publicName: "accept", isSignal: true, isRequired: false, transformFunction: null }, maxFileSize: { classPropertyName: "maxFileSize", publicName: "maxFileSize", isSignal: true, isRequired: false, transformFunction: null }, maxFiles: { classPropertyName: "maxFiles", publicName: "maxFiles", isSignal: true, isRequired: false, transformFunction: null }, maxConcurrentUploads: { classPropertyName: "maxConcurrentUploads", publicName: "maxConcurrentUploads", isSignal: true, isRequired: false, transformFunction: null }, retries: { classPropertyName: "retries", publicName: "retries", isSignal: true, isRequired: false, transformFunction: null }, autoUpload: { classPropertyName: "autoUpload", publicName: "autoUpload", isSignal: true, isRequired: false, transformFunction: null }, disableUpload: { classPropertyName: "disableUpload", publicName: "disableUpload", isSignal: true, isRequired: false, transformFunction: null }, directoryUpload: { classPropertyName: "directoryUpload", publicName: "directoryUpload", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { uploadCanceled: "uploadCanceled", uploadCompleted: "uploadCompleted", filesChanges: "filesChanges" }, viewQueries: [{ propertyName: "dropZone", first: true, predicate: ["dropZone"], descendants: true, isSignal: true }], ngImport: i0, template: "<si-file-dropzone\n #dropZone\n [class]=\"autoUpload() ? 'mb-8' : 'mb-4'\"\n [uploadTextFileSelect]=\"uploadTextFileSelect()\"\n [uploadDropText]=\"uploadDropText()\"\n [multiple]=\"maxFiles() > 1\"\n [directoryUpload]=\"directoryUpload()\"\n [maxFileSizeText]=\"maxFileSizeText()\"\n [acceptText]=\"acceptText()\"\n [errorTextFileType]=\"errorTextFileType()\"\n [errorTextFileMaxSize]=\"errorTextFileMaxSize()\"\n [accept]=\"accept()\"\n [maxFileSize]=\"maxFileSize()\"\n (filesAdded)=\"handleFiles($event)\"\n/>\n\n@if (maxFilesReached()) {\n <si-inline-notification\n class=\"mb-4\"\n severity=\"info\"\n [message]=\"maxFilesReachedText()\"\n [translationParams]=\"{ maxFiles: maxFiles() }\"\n />\n}\n\n<div class=\"file-list\">\n @for (file of files(); track file) {\n <div class=\"file\" [class.fade-out]=\"file.fadeOut\">\n <si-icon class=\"icon align-self-center ms-6 me-4\" icon=\"element-document\" />\n <div class=\"flex-fill overflow-hidden mt-6\">\n <div class=\"file-info\">\n <div class=\"file-name text-truncate si-h5\">{{ file.fileName }}</div>\n <div class=\"file-size text-secondary\">{{ file.size }}</div>\n @if (file.errorText) {\n <div\n class=\"d-inline-flex gap-2 error text-truncate\"\n [class.text-warning]=\"file.status === 'invalid'\"\n [class.text-danger]=\"file.status === 'error'\"\n >\n <si-status-icon\n class=\"icon-sm\"\n [status]=\"file.status === 'invalid' ? 'warning' : 'danger'\"\n />\n {{ file.errorText | translate: file.errorParams }}\n @if (file.httpErrorText) {\n : {{ file.httpErrorText }}\n }\n </div>\n } @else {\n <div class=\"position-relative mt-1 mb-5\">\n <div class=\"position-absolute end-0 progress-value\">{{ file.progress }} %</div>\n <si-progressbar\n height=\"small\"\n [value]=\"file.progress\"\n [ariaLabel]=\"uploadingText() | translate\"\n />\n </div>\n }\n </div>\n </div>\n <div class=\"status align-self-center text-nowrap ps-4 pe-6\">\n @if (file.status === 'error') {\n <button\n type=\"button\"\n class=\"btn btn-circle btn-tertiary me-4\"\n [disabled]=\"!uploadEnabled()\"\n [title]=\"uploadButtonText() | translate\"\n [attr.aria-label]=\"uploadButtonText() | translate\"\n (click)=\"retryUpload(file)\"\n >\n <si-icon [icon]=\"icons.elementRedo\" />\n </button>\n }\n @if (file.status === 'added' || file.status === 'error' || file.status === 'invalid') {\n <button\n type=\"button\"\n class=\"btn btn-circle btn-tertiary-ghost\"\n [title]=\"removeButtonText() | translate\"\n [attr.aria-label]=\"removeButtonText() | translate\"\n (click)=\"removeFile($index)\"\n >\n <si-icon [icon]=\"icons.elementDelete\" />\n </button>\n }\n @if (file.status === 'uploading' || file.status === 'queued') {\n <button\n type=\"button\"\n class=\"btn btn-circle btn-tertiary\"\n [title]=\"cancelButtonText() | translate\"\n [attr.aria-label]=\"cancelButtonText() | translate\"\n (click)=\"cancelUpload(file)\"\n >\n <si-icon [icon]=\"icons.elementCancel\" />\n </button>\n }\n @if (file.status === 'success') {\n <si-status-icon class=\"icon mx-2\" status=\"success\" />\n }\n </div>\n </div>\n }\n</div>\n\n@if (!autoUpload()) {\n <div class=\"buttons text-end\">\n <button\n type=\"button\"\n class=\"btn btn-secondary me-4\"\n [disabled]=\"pending || !files().length\"\n (click)=\"reset()\"\n >{{ clearButtonText() | translate }}</button\n >\n <button\n type=\"button\"\n class=\"btn btn-primary\"\n [disabled]=\"!uploadEnabled()\"\n (click)=\"fileUpload()\"\n >{{ uploadButtonText() | translate }}</button\n >\n </div>\n}\n", styles: [":host{display:flex;flex-direction:column;justify-content:center;align-items:stretch}:host>*{min-inline-size:320px;max-inline-size:680px;inline-size:100%;align-self:center}.file-list{overflow-y:auto}.file-info{display:flex;justify-content:center;flex-direction:column}.progress-value{inset-block-start:-1lh}.file{display:flex;position:relative;margin-block-end:8px;min-block-size:72px;transition:opacity calc(.5s * var(--element-animations-enabled, 1))}.fade-out{opacity:0}\n"], dependencies: [{ kind: "component", type: SiStatusIconComponent, selector: "si-status-icon", inputs: ["status"] }, { kind: "component", type: SiFileDropzoneComponent, selector: "si-file-dropzone", inputs: ["uploadTextFileSelect", "uploadDropText", "maxFileSizeText", "acceptText", "errorTextFileType", "errorTextFileMaxSize", "accept", "maxFileSize", "multiple", "directoryUpload"], outputs: ["filesAdded", "fileError"] }, { kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "component", type: SiInlineNotificationComponent, selector: "si-inline-notification", inputs: ["severity", "heading", "message", "action", "translationParams", "embedded"] }, { kind: "component", type: SiProgressbarComponent, selector: "si-progressbar", inputs: ["ariaLabel", "max", "value", "heading", "progress", "height"] }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.Default });
873
875
  }
874
876
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImport: i0, type: SiFileUploaderComponent, decorators: [{
875
877
  type: Component,
@@ -880,8 +882,8 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.0.8", ngImpor
880
882
  SiInlineNotificationComponent,
881
883
  SiProgressbarComponent,
882
884
  SiTranslatePipe
883
- ], template: "<si-file-dropzone\n #dropZone\n [class]=\"autoUpload() ? 'mb-8' : 'mb-4'\"\n [uploadTextFileSelect]=\"uploadTextFileSelect()\"\n [uploadDropText]=\"uploadDropText()\"\n [multiple]=\"maxFiles() > 1\"\n [directoryUpload]=\"directoryUpload()\"\n [maxFileSizeText]=\"maxFileSizeText()\"\n [acceptText]=\"acceptText()\"\n [errorTextFileType]=\"errorTextFileType()\"\n [errorTextFileMaxSize]=\"errorTextFileMaxSize()\"\n [accept]=\"accept()\"\n [maxFileSize]=\"maxFileSize()\"\n (filesAdded)=\"handleFiles($event)\"\n/>\n\n@if (maxFilesReached) {\n <si-inline-notification\n class=\"mb-4\"\n severity=\"info\"\n [message]=\"maxFilesReachedText()\"\n [translationParams]=\"{ maxFiles: maxFiles() }\"\n />\n}\n\n<div class=\"file-list\">\n @for (file of files; track file) {\n <div class=\"file\" [class.fade-out]=\"file.fadeOut\">\n <si-icon class=\"icon align-self-center ms-6 me-4\" icon=\"element-document\" />\n <div class=\"flex-fill overflow-hidden mt-6\">\n <div class=\"file-info\">\n <div class=\"file-name text-truncate si-h5\">{{ file.fileName }}</div>\n <div class=\"file-size text-secondary\">{{ file.size }}</div>\n @if (file.errorText) {\n <div\n class=\"d-inline-flex gap-2 error text-truncate\"\n [class.text-warning]=\"file.status === 'invalid'\"\n [class.text-danger]=\"file.status === 'error'\"\n >\n <si-status-icon\n class=\"icon-sm\"\n [status]=\"file.status === 'invalid' ? 'warning' : 'danger'\"\n />\n {{ file.errorText | translate: file.errorParams }}\n @if (file.httpErrorText) {\n : {{ file.httpErrorText }}\n }\n </div>\n } @else {\n <div class=\"position-relative mt-1 mb-5\">\n <div class=\"position-absolute end-0 progress-value\">{{ file.progress }} %</div>\n <si-progressbar\n height=\"small\"\n [value]=\"file.progress\"\n [ariaLabel]=\"uploadingText() | translate\"\n />\n </div>\n }\n </div>\n </div>\n <div class=\"status align-self-center text-nowrap ps-4 pe-6\">\n @if (file.status === 'error') {\n <button\n type=\"button\"\n class=\"btn btn-circle btn-tertiary me-4\"\n [disabled]=\"!uploadEnabled\"\n [title]=\"uploadButtonText() | translate\"\n [attr.aria-label]=\"uploadButtonText() | translate\"\n (click)=\"retryUpload(file)\"\n >\n <si-icon [icon]=\"icons.elementRedo\" />\n </button>\n }\n @if (file.status === 'added' || file.status === 'error' || file.status === 'invalid') {\n <button\n type=\"button\"\n class=\"btn btn-circle btn-tertiary-ghost\"\n [title]=\"removeButtonText() | translate\"\n [attr.aria-label]=\"removeButtonText() | translate\"\n (click)=\"removeFile($index)\"\n >\n <si-icon [icon]=\"icons.elementDelete\" />\n </button>\n }\n @if (file.status === 'uploading' || file.status === 'queued') {\n <button\n type=\"button\"\n class=\"btn btn-circle btn-tertiary\"\n [title]=\"cancelButtonText() | translate\"\n [attr.aria-label]=\"cancelButtonText() | translate\"\n (click)=\"cancelUpload(file)\"\n >\n <si-icon [icon]=\"icons.elementCancel\" />\n </button>\n }\n @if (file.status === 'success') {\n <si-status-icon class=\"icon mx-2\" status=\"success\" />\n }\n </div>\n </div>\n }\n</div>\n\n@if (!autoUpload()) {\n <div class=\"buttons text-end\">\n <button\n type=\"button\"\n class=\"btn btn-secondary me-4\"\n [disabled]=\"pending || !files.length\"\n (click)=\"reset()\"\n >{{ clearButtonText() | translate }}</button\n >\n <button\n type=\"button\"\n class=\"btn btn-primary\"\n [disabled]=\"!uploadEnabled\"\n (click)=\"fileUpload()\"\n >{{ uploadButtonText() | translate }}</button\n >\n </div>\n}\n", styles: [":host{display:flex;flex-direction:column;justify-content:center;align-items:stretch}:host>*{min-inline-size:320px;max-inline-size:680px;inline-size:100%;align-self:center}.file-list{overflow-y:auto}.file-info{display:flex;justify-content:center;flex-direction:column}.progress-value{inset-block-start:-1lh}.file{display:flex;position:relative;margin-block-end:8px;min-block-size:72px;transition:opacity calc(.5s * var(--element-animations-enabled, 1))}.fade-out{opacity:0}\n"] }]
884
- }], propDecorators: { uploadTextFileSelect: [{ type: i0.Input, args: [{ isSignal: true, alias: "uploadTextFileSelect", required: false }] }], uploadDropText: [{ type: i0.Input, args: [{ isSignal: true, alias: "uploadDropText", required: false }] }], maxFileSizeText: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxFileSizeText", required: false }] }], maxFilesReachedText: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxFilesReachedText", required: false }] }], acceptText: [{ type: i0.Input, args: [{ isSignal: true, alias: "acceptText", required: false }] }], uploadButtonText: [{ type: i0.Input, args: [{ isSignal: true, alias: "uploadButtonText", required: false }] }], clearButtonText: [{ type: i0.Input, args: [{ isSignal: true, alias: "clearButtonText", required: false }] }], uploadingText: [{ type: i0.Input, args: [{ isSignal: true, alias: "uploadingText", required: false }] }], removeButtonText: [{ type: i0.Input, args: [{ isSignal: true, alias: "removeButtonText", required: false }] }], cancelButtonText: [{ type: i0.Input, args: [{ isSignal: true, alias: "cancelButtonText", required: false }] }], successTextTitle: [{ type: i0.Input, args: [{ isSignal: true, alias: "successTextTitle", required: false }] }], errorUploadFailed: [{ type: i0.Input, args: [{ isSignal: true, alias: "errorUploadFailed", required: false }] }], showHttpError: [{ type: i0.Input, args: [{ isSignal: true, alias: "showHttpError", required: false }] }], errorTextFileType: [{ type: i0.Input, args: [{ isSignal: true, alias: "errorTextFileType", required: false }] }], errorTextFileMaxSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "errorTextFileMaxSize", required: false }] }], uploadConfig: [{ type: i0.Input, args: [{ isSignal: true, alias: "uploadConfig", required: false }] }], accept: [{ type: i0.Input, args: [{ isSignal: true, alias: "accept", required: false }] }], maxFileSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxFileSize", required: false }] }], maxFiles: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxFiles", required: false }] }], maxConcurrentUploads: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxConcurrentUploads", required: false }] }], retries: [{ type: i0.Input, args: [{ isSignal: true, alias: "retries", required: false }] }], autoUpload: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoUpload", required: false }] }], disableUpload: [{ type: i0.Input, args: [{ isSignal: true, alias: "disableUpload", required: false }] }], directoryUpload: [{ type: i0.Input, args: [{ isSignal: true, alias: "directoryUpload", required: false }] }], uploadCanceled: [{ type: i0.Output, args: ["uploadCanceled"] }], uploadCompleted: [{ type: i0.Output, args: ["uploadCompleted"] }], filesChanges: [{ type: i0.Output, args: ["filesChanges"] }], dropZone: [{ type: i0.ViewChild, args: ['dropZone', { isSignal: true }] }] } });
885
+ ], changeDetection: ChangeDetectionStrategy.Default, template: "<si-file-dropzone\n #dropZone\n [class]=\"autoUpload() ? 'mb-8' : 'mb-4'\"\n [uploadTextFileSelect]=\"uploadTextFileSelect()\"\n [uploadDropText]=\"uploadDropText()\"\n [multiple]=\"maxFiles() > 1\"\n [directoryUpload]=\"directoryUpload()\"\n [maxFileSizeText]=\"maxFileSizeText()\"\n [acceptText]=\"acceptText()\"\n [errorTextFileType]=\"errorTextFileType()\"\n [errorTextFileMaxSize]=\"errorTextFileMaxSize()\"\n [accept]=\"accept()\"\n [maxFileSize]=\"maxFileSize()\"\n (filesAdded)=\"handleFiles($event)\"\n/>\n\n@if (maxFilesReached()) {\n <si-inline-notification\n class=\"mb-4\"\n severity=\"info\"\n [message]=\"maxFilesReachedText()\"\n [translationParams]=\"{ maxFiles: maxFiles() }\"\n />\n}\n\n<div class=\"file-list\">\n @for (file of files(); track file) {\n <div class=\"file\" [class.fade-out]=\"file.fadeOut\">\n <si-icon class=\"icon align-self-center ms-6 me-4\" icon=\"element-document\" />\n <div class=\"flex-fill overflow-hidden mt-6\">\n <div class=\"file-info\">\n <div class=\"file-name text-truncate si-h5\">{{ file.fileName }}</div>\n <div class=\"file-size text-secondary\">{{ file.size }}</div>\n @if (file.errorText) {\n <div\n class=\"d-inline-flex gap-2 error text-truncate\"\n [class.text-warning]=\"file.status === 'invalid'\"\n [class.text-danger]=\"file.status === 'error'\"\n >\n <si-status-icon\n class=\"icon-sm\"\n [status]=\"file.status === 'invalid' ? 'warning' : 'danger'\"\n />\n {{ file.errorText | translate: file.errorParams }}\n @if (file.httpErrorText) {\n : {{ file.httpErrorText }}\n }\n </div>\n } @else {\n <div class=\"position-relative mt-1 mb-5\">\n <div class=\"position-absolute end-0 progress-value\">{{ file.progress }} %</div>\n <si-progressbar\n height=\"small\"\n [value]=\"file.progress\"\n [ariaLabel]=\"uploadingText() | translate\"\n />\n </div>\n }\n </div>\n </div>\n <div class=\"status align-self-center text-nowrap ps-4 pe-6\">\n @if (file.status === 'error') {\n <button\n type=\"button\"\n class=\"btn btn-circle btn-tertiary me-4\"\n [disabled]=\"!uploadEnabled()\"\n [title]=\"uploadButtonText() | translate\"\n [attr.aria-label]=\"uploadButtonText() | translate\"\n (click)=\"retryUpload(file)\"\n >\n <si-icon [icon]=\"icons.elementRedo\" />\n </button>\n }\n @if (file.status === 'added' || file.status === 'error' || file.status === 'invalid') {\n <button\n type=\"button\"\n class=\"btn btn-circle btn-tertiary-ghost\"\n [title]=\"removeButtonText() | translate\"\n [attr.aria-label]=\"removeButtonText() | translate\"\n (click)=\"removeFile($index)\"\n >\n <si-icon [icon]=\"icons.elementDelete\" />\n </button>\n }\n @if (file.status === 'uploading' || file.status === 'queued') {\n <button\n type=\"button\"\n class=\"btn btn-circle btn-tertiary\"\n [title]=\"cancelButtonText() | translate\"\n [attr.aria-label]=\"cancelButtonText() | translate\"\n (click)=\"cancelUpload(file)\"\n >\n <si-icon [icon]=\"icons.elementCancel\" />\n </button>\n }\n @if (file.status === 'success') {\n <si-status-icon class=\"icon mx-2\" status=\"success\" />\n }\n </div>\n </div>\n }\n</div>\n\n@if (!autoUpload()) {\n <div class=\"buttons text-end\">\n <button\n type=\"button\"\n class=\"btn btn-secondary me-4\"\n [disabled]=\"pending || !files().length\"\n (click)=\"reset()\"\n >{{ clearButtonText() | translate }}</button\n >\n <button\n type=\"button\"\n class=\"btn btn-primary\"\n [disabled]=\"!uploadEnabled()\"\n (click)=\"fileUpload()\"\n >{{ uploadButtonText() | translate }}</button\n >\n </div>\n}\n", styles: [":host{display:flex;flex-direction:column;justify-content:center;align-items:stretch}:host>*{min-inline-size:320px;max-inline-size:680px;inline-size:100%;align-self:center}.file-list{overflow-y:auto}.file-info{display:flex;justify-content:center;flex-direction:column}.progress-value{inset-block-start:-1lh}.file{display:flex;position:relative;margin-block-end:8px;min-block-size:72px;transition:opacity calc(.5s * var(--element-animations-enabled, 1))}.fade-out{opacity:0}\n"] }]
886
+ }], ctorParameters: () => [], propDecorators: { uploadTextFileSelect: [{ type: i0.Input, args: [{ isSignal: true, alias: "uploadTextFileSelect", required: false }] }], uploadDropText: [{ type: i0.Input, args: [{ isSignal: true, alias: "uploadDropText", required: false }] }], maxFileSizeText: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxFileSizeText", required: false }] }], maxFilesReachedText: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxFilesReachedText", required: false }] }], acceptText: [{ type: i0.Input, args: [{ isSignal: true, alias: "acceptText", required: false }] }], uploadButtonText: [{ type: i0.Input, args: [{ isSignal: true, alias: "uploadButtonText", required: false }] }], clearButtonText: [{ type: i0.Input, args: [{ isSignal: true, alias: "clearButtonText", required: false }] }], uploadingText: [{ type: i0.Input, args: [{ isSignal: true, alias: "uploadingText", required: false }] }], removeButtonText: [{ type: i0.Input, args: [{ isSignal: true, alias: "removeButtonText", required: false }] }], cancelButtonText: [{ type: i0.Input, args: [{ isSignal: true, alias: "cancelButtonText", required: false }] }], successTextTitle: [{ type: i0.Input, args: [{ isSignal: true, alias: "successTextTitle", required: false }] }], errorUploadFailed: [{ type: i0.Input, args: [{ isSignal: true, alias: "errorUploadFailed", required: false }] }], showHttpError: [{ type: i0.Input, args: [{ isSignal: true, alias: "showHttpError", required: false }] }], errorTextFileType: [{ type: i0.Input, args: [{ isSignal: true, alias: "errorTextFileType", required: false }] }], errorTextFileMaxSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "errorTextFileMaxSize", required: false }] }], uploadConfig: [{ type: i0.Input, args: [{ isSignal: true, alias: "uploadConfig", required: false }] }], accept: [{ type: i0.Input, args: [{ isSignal: true, alias: "accept", required: false }] }], maxFileSize: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxFileSize", required: false }] }], maxFiles: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxFiles", required: false }] }], maxConcurrentUploads: [{ type: i0.Input, args: [{ isSignal: true, alias: "maxConcurrentUploads", required: false }] }], retries: [{ type: i0.Input, args: [{ isSignal: true, alias: "retries", required: false }] }], autoUpload: [{ type: i0.Input, args: [{ isSignal: true, alias: "autoUpload", required: false }] }], disableUpload: [{ type: i0.Input, args: [{ isSignal: true, alias: "disableUpload", required: false }] }], directoryUpload: [{ type: i0.Input, args: [{ isSignal: true, alias: "directoryUpload", required: false }] }], uploadCanceled: [{ type: i0.Output, args: ["uploadCanceled"] }], uploadCompleted: [{ type: i0.Output, args: ["uploadCompleted"] }], filesChanges: [{ type: i0.Output, args: ["filesChanges"] }], dropZone: [{ type: i0.ViewChild, args: ['dropZone', { isSignal: true }] }] } });
885
887
 
886
888
  /**
887
889
  * Copyright (c) Siemens 2016 - 2026