@siemens/element-ng 51.0.0-rc.6 → 51.0.0-rc.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/fesm2022/siemens-element-ng-auto-collapsable-list.mjs +8 -7
- package/fesm2022/siemens-element-ng-auto-collapsable-list.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-avatar.mjs +2 -2
- package/fesm2022/siemens-element-ng-avatar.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-breadcrumb.mjs +2 -2
- package/fesm2022/siemens-element-ng-breadcrumb.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-chat-messages.mjs +10 -10
- package/fesm2022/siemens-element-ng-chat-messages.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-dashboard.mjs +2 -2
- package/fesm2022/siemens-element-ng-dashboard.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-datepicker.mjs +11 -11
- package/fesm2022/siemens-element-ng-datepicker.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-empty-state.mjs +2 -2
- package/fesm2022/siemens-element-ng-empty-state.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-form.mjs +7 -7
- package/fesm2022/siemens-element-ng-form.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-list-details.mjs +1 -1
- package/fesm2022/siemens-element-ng-list-details.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-main-detail-container.mjs +1 -1
- package/fesm2022/siemens-element-ng-main-detail-container.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-markdown-extensions-citations.mjs +208 -0
- package/fesm2022/siemens-element-ng-markdown-extensions-citations.mjs.map +1 -0
- package/fesm2022/siemens-element-ng-markdown-extensions-katex.mjs +76 -0
- package/fesm2022/siemens-element-ng-markdown-extensions-katex.mjs.map +1 -0
- package/fesm2022/siemens-element-ng-markdown-extensions-mermaid.mjs +86 -0
- package/fesm2022/siemens-element-ng-markdown-extensions-mermaid.mjs.map +1 -0
- package/fesm2022/siemens-element-ng-markdown-hightlighter-highlightjs.mjs +130 -0
- package/fesm2022/siemens-element-ng-markdown-hightlighter-highlightjs.mjs.map +1 -0
- package/fesm2022/siemens-element-ng-markdown.mjs +139 -15
- package/fesm2022/siemens-element-ng-markdown.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-navbar-vertical-next.mjs +4 -4
- package/fesm2022/siemens-element-ng-navbar-vertical-next.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-notification-item.mjs +2 -2
- package/fesm2022/siemens-element-ng-notification-item.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-split.mjs +13 -13
- package/fesm2022/siemens-element-ng-split.mjs.map +1 -1
- package/fesm2022/siemens-element-ng-tabs.mjs +2 -2
- package/fesm2022/siemens-element-ng-translate.mjs.map +1 -1
- package/markdown/extensions/citations/package.json +4 -0
- package/markdown/extensions/katex/package.json +4 -0
- package/markdown/extensions/mermaid/package.json +4 -0
- package/markdown/hightlighter/highlightjs/package.json +4 -0
- package/package.json +21 -4
- package/schematics/migrations/data/component-property-to-child.js +11 -0
- package/schematics/migrations/data/element-migration-data.js +2 -0
- package/schematics/migrations/data/migration-test-data.js +8 -0
- package/schematics/migrations/element-migration/element-migration.js +3 -2
- package/schematics/migrations/utilities/component-property-to-child.migration.js +73 -0
- package/schematics/migrations/utilities/css-custom-property.migration.js +1 -0
- package/schematics/migrations/utilities/index.js +1 -0
- package/schematics/ng-update/migrate-split-collapse.js +196 -0
- package/schematics/ng-update/migrate-to-v51.js +3 -1
- package/template-i18n.json +3 -1
- package/types/siemens-element-ng-markdown-extensions-citations.d.ts +11 -0
- package/types/siemens-element-ng-markdown-extensions-katex.d.ts +19 -0
- package/types/siemens-element-ng-markdown-extensions-mermaid.d.ts +11 -0
- package/types/siemens-element-ng-markdown-hightlighter-highlightjs.d.ts +48 -0
- package/types/siemens-element-ng-markdown.d.ts +42 -5
- package/types/siemens-element-ng-navbar-vertical-next.d.ts +1 -1
- package/types/siemens-element-ng-split.d.ts +6 -6
- package/types/siemens-element-ng-translate.d.ts +2 -0
|
@@ -64,17 +64,18 @@ class SiAutoCollapsableListItemDirective extends SiAutoCollapsableListMeasurable
|
|
|
64
64
|
}
|
|
65
65
|
}
|
|
66
66
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: SiAutoCollapsableListItemDirective, deps: null, target: i0.ɵɵFactoryTarget.Directive });
|
|
67
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.0.8", type: SiAutoCollapsableListItemDirective, isStandalone: true, selector: "[siAutoCollapsableListItem]", inputs: { forceHide: { classPropertyName: "forceHide", publicName: "forceHide", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "
|
|
67
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "22.0.8", type: SiAutoCollapsableListItemDirective, isStandalone: true, selector: "[siAutoCollapsableListItem]", inputs: { forceHide: { classPropertyName: "forceHide", publicName: "forceHide", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class.visible": "isVisible()", "class.invisible": "!isVisible()", "class.position-absolute": "!isVisible()", "class.z-n1": "!isVisible()" } }, exportAs: ["siAutoCollapsableListItem"], usesInheritance: true, ngImport: i0 });
|
|
68
68
|
}
|
|
69
69
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: SiAutoCollapsableListItemDirective, decorators: [{
|
|
70
70
|
type: Directive,
|
|
71
71
|
args: [{
|
|
72
72
|
selector: '[siAutoCollapsableListItem]',
|
|
73
73
|
host: {
|
|
74
|
-
'[
|
|
75
|
-
'[
|
|
74
|
+
'[class.visible]': 'isVisible()',
|
|
75
|
+
'[class.invisible]': '!isVisible()',
|
|
76
|
+
'[class.position-absolute]': '!isVisible()',
|
|
76
77
|
// Ensure hidden items are behind the visible ones. Otherwise, the visible ones are not clickable
|
|
77
|
-
'[
|
|
78
|
+
'[class.z-n1]': '!isVisible()'
|
|
78
79
|
},
|
|
79
80
|
exportAs: 'siAutoCollapsableListItem'
|
|
80
81
|
}]
|
|
@@ -265,15 +266,15 @@ class SiAutoCollapsableListDirective {
|
|
|
265
266
|
}
|
|
266
267
|
}
|
|
267
268
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: SiAutoCollapsableListDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
268
|
-
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.2.0", version: "22.0.8", type: SiAutoCollapsableListDirective, isStandalone: true, selector: "[siAutoCollapsableList]", inputs: { siAutoCollapsableList: { classPropertyName: "siAutoCollapsableList", publicName: "siAutoCollapsableList", isSignal: true, isRequired: false, transformFunction: null }, gap: { classPropertyName: "gap", publicName: "gap", isSignal: true, isRequired: false, transformFunction: null }, containerElement: { classPropertyName: "containerElement", publicName: "siAutoCollapsableListContainerElement", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "
|
|
269
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.2.0", version: "22.0.8", type: SiAutoCollapsableListDirective, isStandalone: true, selector: "[siAutoCollapsableList]", inputs: { siAutoCollapsableList: { classPropertyName: "siAutoCollapsableList", publicName: "siAutoCollapsableList", isSignal: true, isRequired: false, transformFunction: null }, gap: { classPropertyName: "gap", publicName: "gap", isSignal: true, isRequired: false, transformFunction: null }, containerElement: { classPropertyName: "containerElement", publicName: "siAutoCollapsableListContainerElement", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class.overflow-hidden": "siAutoCollapsableList()" }, classAttribute: "position-relative" }, queries: [{ propertyName: "items", predicate: SiAutoCollapsableListItemDirective, isSignal: true }, { propertyName: "overflowItem", first: true, predicate: SiAutoCollapsableListOverflowItemDirective, descendants: true, isSignal: true }, { propertyName: "additionalContent", predicate: SiAutoCollapsableListAdditionalContentDirective, isSignal: true }], exportAs: ["siAutoCollapsableList"], usesOnChanges: true, ngImport: i0 });
|
|
269
270
|
}
|
|
270
271
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: SiAutoCollapsableListDirective, decorators: [{
|
|
271
272
|
type: Directive,
|
|
272
273
|
args: [{
|
|
273
274
|
selector: '[siAutoCollapsableList]',
|
|
274
275
|
host: {
|
|
275
|
-
|
|
276
|
-
'[
|
|
276
|
+
class: 'position-relative',
|
|
277
|
+
'[class.overflow-hidden]': 'siAutoCollapsableList()'
|
|
277
278
|
},
|
|
278
279
|
exportAs: 'siAutoCollapsableList'
|
|
279
280
|
}]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"siemens-element-ng-auto-collapsable-list.mjs","sources":["../../../../projects/element-ng/auto-collapsable-list/si-auto-collapsable-list-measurable.class.ts","../../../../projects/element-ng/auto-collapsable-list/si-auto-collapsable-list-item.directive.ts","../../../../projects/element-ng/auto-collapsable-list/si-auto-collapsable-list-additional-content.directive.ts","../../../../projects/element-ng/auto-collapsable-list/si-auto-collapsable-list-overflow-item.directive.ts","../../../../projects/element-ng/auto-collapsable-list/si-auto-collapsable-list.directive.ts","../../../../projects/element-ng/auto-collapsable-list/si-auto-collapsable-list.module.ts","../../../../projects/element-ng/auto-collapsable-list/index.ts","../../../../projects/element-ng/auto-collapsable-list/siemens-element-ng-auto-collapsable-list.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { Directive, ElementRef, inject } from '@angular/core';\nimport { ResizeObserverService } from '@siemens/element-ng/resize-observer';\nimport { distinctUntilChanged, map, shareReplay } from 'rxjs/operators';\n\n@Directive()\nexport class SiAutoCollapsableListMeasurable {\n protected readonly elementRef = inject(ElementRef<HTMLElement>);\n private readonly resizeObserverService = inject(ResizeObserverService);\n\n /**\n * Emits on element width changes.\n *\n * @defaultValue\n * ```\n * this.resizeObserverService\n * .observe(this.elementRef.nativeElement, 0, true, true)\n * .pipe(\n * map(size => size.width),\n * distinctUntilChanged(),\n * shareReplay(1)\n * )\n * ```\n */\n size$ = this.resizeObserverService.observe(this.elementRef.nativeElement, 0, true, true).pipe(\n map(size => size.width),\n distinctUntilChanged(),\n shareReplay(1)\n );\n}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { AfterViewInit, booleanAttribute, computed, Directive, input, signal } from '@angular/core';\n\nimport { SiAutoCollapsableListMeasurable } from './si-auto-collapsable-list-measurable.class';\n\n@Directive({\n selector: '[siAutoCollapsableListItem]',\n host: {\n '[style.visibility]': 'isVisible() ? \"visible\" : \"hidden\"',\n '[style.position]': 'isVisible() ? \"\" : \"absolute\"',\n // Ensure hidden items are behind the visible ones. Otherwise, the visible ones are not clickable\n '[style.z-index]': 'isVisible() ? \"\" : \"-1\"'\n },\n exportAs: 'siAutoCollapsableListItem'\n})\nexport class SiAutoCollapsableListItemDirective\n extends SiAutoCollapsableListMeasurable\n implements AfterViewInit\n{\n /**\n * Hide this item even if enough space is available.\n * When calculating the overall available size, this item is still considered when forceHide=true\n *\n * @defaultValue false\n */\n readonly forceHide = input(false, { transform: booleanAttribute });\n\n /**\n * True if enough space is available for this item.\n *\n * @defaultValue false\n */\n readonly canBeVisible = signal<boolean>(false);\n\n /**\n * True if this item is actually visible to the user\n */\n readonly isVisible = computed(() => this.canBeVisible() && !this.forceHide());\n\n ngAfterViewInit(): void {\n if (getComputedStyle(this.elementRef.nativeElement).display === 'inline') {\n console.error('siAutoCollapsibleListItem does not work on items with display=\"inline\"');\n }\n }\n}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { Directive } from '@angular/core';\n\nimport { SiAutoCollapsableListMeasurable } from './si-auto-collapsable-list-measurable.class';\n\n@Directive({\n selector: '[siAutoCollapsableListAdditionalContent]'\n})\nexport class SiAutoCollapsableListAdditionalContentDirective extends SiAutoCollapsableListMeasurable {}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { Directive } from '@angular/core';\n\nimport { SiAutoCollapsableListItemDirective } from './si-auto-collapsable-list-item.directive';\n\n@Directive({\n selector: '[siAutoCollapsableListOverflowItem]',\n exportAs: 'siAutoCollapsableListOverflowItem'\n})\nexport class SiAutoCollapsableListOverflowItemDirective extends SiAutoCollapsableListItemDirective {\n /**\n * Number of hidden items.\n *\n * @defaultValue 0\n */\n hiddenItemCount = 0;\n}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport {\n AfterViewInit,\n booleanAttribute,\n ChangeDetectorRef,\n contentChild,\n contentChildren,\n Directive,\n ElementRef,\n inject,\n INJECTOR,\n input,\n OnChanges,\n OnDestroy,\n SimpleChanges\n} from '@angular/core';\nimport { toObservable } from '@angular/core/rxjs-interop';\nimport { ResizeObserverService } from '@siemens/element-ng/resize-observer';\nimport { BehaviorSubject, combineLatest, of, Subscription } from 'rxjs';\nimport { auditTime, distinctUntilChanged, map, startWith, switchMap } from 'rxjs/operators';\n\nimport { SiAutoCollapsableListAdditionalContentDirective } from './si-auto-collapsable-list-additional-content.directive';\nimport { SiAutoCollapsableListItemDirective } from './si-auto-collapsable-list-item.directive';\nimport { SiAutoCollapsableListOverflowItemDirective } from './si-auto-collapsable-list-overflow-item.directive';\n\n@Directive({\n selector: '[siAutoCollapsableList]',\n host: {\n style: 'position: relative',\n '[style.overflow]': 'siAutoCollapsableList() ? \"hidden\" : \"\"'\n },\n exportAs: 'siAutoCollapsableList'\n})\nexport class SiAutoCollapsableListDirective implements AfterViewInit, OnChanges, OnDestroy {\n /**\n * The items which are displayed in the siAutoCollapsableList.\n */\n readonly items = contentChildren(SiAutoCollapsableListItemDirective);\n\n private readonly overflowItem = contentChild(SiAutoCollapsableListOverflowItemDirective);\n\n private readonly additionalContent = contentChildren(\n SiAutoCollapsableListAdditionalContentDirective\n );\n\n /**\n * Enables the auto-collapsing behavior. When `true`, items that overflow the container\n * are hidden and an overflow indicator item is shown instead.\n *\n * @defaultValue true\n */\n readonly siAutoCollapsableList = input(true, { transform: booleanAttribute });\n\n /**\n * The (flex) gap in pixels, will automatically be set if a pixel value is used in CSS.\n */\n readonly gap = input<number>();\n\n /**\n * The element which size is available for the content of the siAutoCollapsableList.\n *\n * @defaultValue undefined\n */\n readonly containerElement = input<HTMLElement | undefined | null>(undefined, {\n alias: 'siAutoCollapsableListContainerElement'\n });\n\n private resizeSubscription?: Subscription;\n private disableInitSubscription?: Subscription;\n private readonly elementRef = inject(ElementRef);\n private readonly resizeObserverService = inject(ResizeObserverService);\n private readonly changeDetectorRef = inject(ChangeDetectorRef);\n private readonly containerElementSubject = new BehaviorSubject<HTMLElement | null>(\n this.elementRef.nativeElement\n );\n\n /**\n * The same as {@link gap}, but automatically read from the computed styles.\n * Used if not set by user.\n */\n private computedGap = 0;\n private injector = inject(INJECTOR);\n\n ngAfterViewInit(): void {\n if (this.siAutoCollapsableList()) {\n this.readGapSize();\n this.setupResizeListener();\n } else {\n this.reset();\n }\n }\n\n ngOnChanges(changes: SimpleChanges<this>): void {\n if (changes.siAutoCollapsableList) {\n const siAutoCollapsableList = this.siAutoCollapsableList();\n if (!siAutoCollapsableList && this.resizeSubscription) {\n this.reset();\n } else if (siAutoCollapsableList && !this.resizeSubscription && this.items()) {\n this.setupResizeListener();\n }\n }\n\n if (changes.containerElement) {\n this.containerElementSubject.next(this.containerElement() ?? this.elementRef.nativeElement);\n }\n }\n\n ngOnDestroy(): void {\n this.resizeSubscription?.unsubscribe();\n this.disableInitSubscription?.unsubscribe();\n this.containerElementSubject.complete();\n }\n\n private setupResizeListener(): void {\n this.disableInitSubscription?.unsubscribe();\n const containerSize$ = this.containerElementSubject.pipe(\n switchMap(element => this.resizeObserverService.observe(element!, 0, true, true)),\n map(size => size.width),\n distinctUntilChanged(),\n map(size => {\n const { paddingInlineStart, paddingInlineEnd } = getComputedStyle(\n this.containerElement() ?? this.elementRef.nativeElement\n );\n return size - parseFloat(paddingInlineStart) - parseFloat(paddingInlineEnd);\n })\n );\n\n const itemSizes$ = toObservable(this.items, { injector: this.injector }).pipe(\n startWith(this.items()),\n switchMap(items =>\n !items.length\n ? of([])\n : combineLatest(\n items.map(item =>\n item.size$.pipe(\n map(size => ({\n size,\n directive: item\n }))\n )\n )\n )\n )\n );\n const additionalContentSizes$ = toObservable(this.additionalContent, {\n injector: this.injector\n }).pipe(\n startWith(this.additionalContent()),\n switchMap(additionalContent => combineLatest(additionalContent.map(item => item.size$))),\n startWith([])\n );\n\n this.resizeSubscription = combineLatest([\n containerSize$,\n this.overflowItem()?.size$ ?? of(0),\n itemSizes$,\n additionalContentSizes$\n ])\n .pipe(auditTime(0))\n .subscribe(([containerSize, overflowItemSize, items, additionalContentSizes]) =>\n this.updateItemVisibility(containerSize, overflowItemSize, items, additionalContentSizes)\n );\n }\n\n private updateItemVisibility(\n containerSize: number,\n overflowItemSize: number,\n items: { size: number; directive: SiAutoCollapsableListItemDirective }[],\n additionalContent: number[]\n ): void {\n let remainingSpace = containerSize - additionalContent.reduce((a, b) => a + b, 0);\n\n const itemsRemaining = items.slice();\n\n const gap = this.gap() ?? this.computedGap;\n\n while (remainingSpace > 0 && itemsRemaining.length) {\n const item = itemsRemaining.shift()!;\n if (remainingSpace - item.size - gap - overflowItemSize >= 0) {\n // There is space for the item and an overflow item.\n item.directive.canBeVisible.set(true);\n remainingSpace -= item.size + gap;\n } else if (\n !itemsRemaining.length &&\n (remainingSpace - item.size >= 0 || overflowItemSize >= item.size)\n ) {\n // There are no other items remaining and there is enough space or the overflow item is biggger than the current one.\n item.directive.canBeVisible.set(true);\n remainingSpace = 0;\n } else {\n // There is no space for the item.\n remainingSpace = 0;\n item.directive.canBeVisible.set(false);\n }\n }\n itemsRemaining.forEach(item => item.directive.canBeVisible.set(false));\n\n const overflowItem = this.overflowItem();\n if (overflowItem) {\n overflowItem.hiddenItemCount = this.items().filter(item => !item.canBeVisible()).length;\n overflowItem.canBeVisible.set(overflowItem.hiddenItemCount !== 0);\n }\n this.changeDetectorRef.markForCheck();\n }\n\n private reset(): void {\n this.resizeSubscription?.unsubscribe();\n this.resizeSubscription = undefined;\n this.disableInitSubscription = toObservable(this.items, { injector: this.injector }).subscribe(\n items =>\n queueMicrotask(() => {\n items.forEach(item => item.canBeVisible.set(true));\n })\n );\n\n const overflowItem = this.overflowItem();\n if (overflowItem) {\n queueMicrotask(() => {\n overflowItem!.canBeVisible.set(false);\n overflowItem!.hiddenItemCount = 0;\n });\n }\n }\n\n private readGapSize(): void {\n const { gap } = getComputedStyle(this.containerElement() ?? this.elementRef.nativeElement);\n if (gap.endsWith('px') || gap === '0') {\n this.computedGap = parseFloat(gap);\n }\n }\n}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { NgModule } from '@angular/core';\n\nimport { SiAutoCollapsableListAdditionalContentDirective } from './si-auto-collapsable-list-additional-content.directive';\nimport { SiAutoCollapsableListItemDirective } from './si-auto-collapsable-list-item.directive';\nimport { SiAutoCollapsableListOverflowItemDirective } from './si-auto-collapsable-list-overflow-item.directive';\nimport { SiAutoCollapsableListDirective } from './si-auto-collapsable-list.directive';\n\n@NgModule({\n imports: [\n SiAutoCollapsableListAdditionalContentDirective,\n SiAutoCollapsableListDirective,\n SiAutoCollapsableListItemDirective,\n SiAutoCollapsableListOverflowItemDirective\n ],\n exports: [\n SiAutoCollapsableListAdditionalContentDirective,\n SiAutoCollapsableListDirective,\n SiAutoCollapsableListItemDirective,\n SiAutoCollapsableListOverflowItemDirective\n ]\n})\nexport class SiAutoCollapsableListModule {}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-auto-collapsable-list-item.directive';\nexport * from './si-auto-collapsable-list.directive';\nexport * from './si-auto-collapsable-list-overflow-item.directive';\nexport * from './si-auto-collapsable-list-measurable.class';\nexport * from './si-auto-collapsable-list-additional-content.directive';\nexport * from './si-auto-collapsable-list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,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,KAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,gBAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,uCAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,EAAA,CAAA;;AC7CnD;;;AAGG;MAsBU,2BAA2B,CAAA;uGAA3B,2BAA2B,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA;AAA3B,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,mBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,2BAA2B,YAZpC,+CAA+C;YAC/C,8BAA8B;YAC9B,kCAAkC;AAClC,YAAA,0CAA0C,aAG1C,+CAA+C;YAC/C,8BAA8B;YAC9B,kCAAkC;YAClC,0CAA0C,CAAA,EAAA,CAAA;wGAGjC,2BAA2B,EAAA,CAAA;;2FAA3B,2BAA2B,EAAA,UAAA,EAAA,CAAA;kBAdvC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE;wBACP,+CAA+C;wBAC/C,8BAA8B;wBAC9B,kCAAkC;wBAClC;AACD,qBAAA;AACD,oBAAA,OAAO,EAAE;wBACP,+CAA+C;wBAC/C,8BAA8B;wBAC9B,kCAAkC;wBAClC;AACD;AACF,iBAAA;;;ACxBD;;;AAGG;;ACHH;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"siemens-element-ng-auto-collapsable-list.mjs","sources":["../../../../projects/element-ng/auto-collapsable-list/si-auto-collapsable-list-measurable.class.ts","../../../../projects/element-ng/auto-collapsable-list/si-auto-collapsable-list-item.directive.ts","../../../../projects/element-ng/auto-collapsable-list/si-auto-collapsable-list-additional-content.directive.ts","../../../../projects/element-ng/auto-collapsable-list/si-auto-collapsable-list-overflow-item.directive.ts","../../../../projects/element-ng/auto-collapsable-list/si-auto-collapsable-list.directive.ts","../../../../projects/element-ng/auto-collapsable-list/si-auto-collapsable-list.module.ts","../../../../projects/element-ng/auto-collapsable-list/index.ts","../../../../projects/element-ng/auto-collapsable-list/siemens-element-ng-auto-collapsable-list.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { Directive, ElementRef, inject } from '@angular/core';\nimport { ResizeObserverService } from '@siemens/element-ng/resize-observer';\nimport { distinctUntilChanged, map, shareReplay } from 'rxjs/operators';\n\n@Directive()\nexport class SiAutoCollapsableListMeasurable {\n protected readonly elementRef = inject(ElementRef<HTMLElement>);\n private readonly resizeObserverService = inject(ResizeObserverService);\n\n /**\n * Emits on element width changes.\n *\n * @defaultValue\n * ```\n * this.resizeObserverService\n * .observe(this.elementRef.nativeElement, 0, true, true)\n * .pipe(\n * map(size => size.width),\n * distinctUntilChanged(),\n * shareReplay(1)\n * )\n * ```\n */\n size$ = this.resizeObserverService.observe(this.elementRef.nativeElement, 0, true, true).pipe(\n map(size => size.width),\n distinctUntilChanged(),\n shareReplay(1)\n );\n}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { AfterViewInit, booleanAttribute, computed, Directive, input, signal } from '@angular/core';\n\nimport { SiAutoCollapsableListMeasurable } from './si-auto-collapsable-list-measurable.class';\n\n@Directive({\n selector: '[siAutoCollapsableListItem]',\n host: {\n '[class.visible]': 'isVisible()',\n '[class.invisible]': '!isVisible()',\n '[class.position-absolute]': '!isVisible()',\n // Ensure hidden items are behind the visible ones. Otherwise, the visible ones are not clickable\n '[class.z-n1]': '!isVisible()'\n },\n exportAs: 'siAutoCollapsableListItem'\n})\nexport class SiAutoCollapsableListItemDirective\n extends SiAutoCollapsableListMeasurable\n implements AfterViewInit\n{\n /**\n * Hide this item even if enough space is available.\n * When calculating the overall available size, this item is still considered when forceHide=true\n *\n * @defaultValue false\n */\n readonly forceHide = input(false, { transform: booleanAttribute });\n\n /**\n * True if enough space is available for this item.\n *\n * @defaultValue false\n */\n readonly canBeVisible = signal<boolean>(false);\n\n /**\n * True if this item is actually visible to the user\n */\n readonly isVisible = computed(() => this.canBeVisible() && !this.forceHide());\n\n ngAfterViewInit(): void {\n if (getComputedStyle(this.elementRef.nativeElement).display === 'inline') {\n console.error('siAutoCollapsibleListItem does not work on items with display=\"inline\"');\n }\n }\n}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { Directive } from '@angular/core';\n\nimport { SiAutoCollapsableListMeasurable } from './si-auto-collapsable-list-measurable.class';\n\n@Directive({\n selector: '[siAutoCollapsableListAdditionalContent]'\n})\nexport class SiAutoCollapsableListAdditionalContentDirective extends SiAutoCollapsableListMeasurable {}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { Directive } from '@angular/core';\n\nimport { SiAutoCollapsableListItemDirective } from './si-auto-collapsable-list-item.directive';\n\n@Directive({\n selector: '[siAutoCollapsableListOverflowItem]',\n exportAs: 'siAutoCollapsableListOverflowItem'\n})\nexport class SiAutoCollapsableListOverflowItemDirective extends SiAutoCollapsableListItemDirective {\n /**\n * Number of hidden items.\n *\n * @defaultValue 0\n */\n hiddenItemCount = 0;\n}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport {\n AfterViewInit,\n booleanAttribute,\n ChangeDetectorRef,\n contentChild,\n contentChildren,\n Directive,\n ElementRef,\n inject,\n INJECTOR,\n input,\n OnChanges,\n OnDestroy,\n SimpleChanges\n} from '@angular/core';\nimport { toObservable } from '@angular/core/rxjs-interop';\nimport { ResizeObserverService } from '@siemens/element-ng/resize-observer';\nimport { BehaviorSubject, combineLatest, of, Subscription } from 'rxjs';\nimport { auditTime, distinctUntilChanged, map, startWith, switchMap } from 'rxjs/operators';\n\nimport { SiAutoCollapsableListAdditionalContentDirective } from './si-auto-collapsable-list-additional-content.directive';\nimport { SiAutoCollapsableListItemDirective } from './si-auto-collapsable-list-item.directive';\nimport { SiAutoCollapsableListOverflowItemDirective } from './si-auto-collapsable-list-overflow-item.directive';\n\n@Directive({\n selector: '[siAutoCollapsableList]',\n host: {\n class: 'position-relative',\n '[class.overflow-hidden]': 'siAutoCollapsableList()'\n },\n exportAs: 'siAutoCollapsableList'\n})\nexport class SiAutoCollapsableListDirective implements AfterViewInit, OnChanges, OnDestroy {\n /**\n * The items which are displayed in the siAutoCollapsableList.\n */\n readonly items = contentChildren(SiAutoCollapsableListItemDirective);\n\n private readonly overflowItem = contentChild(SiAutoCollapsableListOverflowItemDirective);\n\n private readonly additionalContent = contentChildren(\n SiAutoCollapsableListAdditionalContentDirective\n );\n\n /**\n * Enables the auto-collapsing behavior. When `true`, items that overflow the container\n * are hidden and an overflow indicator item is shown instead.\n *\n * @defaultValue true\n */\n readonly siAutoCollapsableList = input(true, { transform: booleanAttribute });\n\n /**\n * The (flex) gap in pixels, will automatically be set if a pixel value is used in CSS.\n */\n readonly gap = input<number>();\n\n /**\n * The element which size is available for the content of the siAutoCollapsableList.\n *\n * @defaultValue undefined\n */\n readonly containerElement = input<HTMLElement | undefined | null>(undefined, {\n alias: 'siAutoCollapsableListContainerElement'\n });\n\n private resizeSubscription?: Subscription;\n private disableInitSubscription?: Subscription;\n private readonly elementRef = inject(ElementRef);\n private readonly resizeObserverService = inject(ResizeObserverService);\n private readonly changeDetectorRef = inject(ChangeDetectorRef);\n private readonly containerElementSubject = new BehaviorSubject<HTMLElement | null>(\n this.elementRef.nativeElement\n );\n\n /**\n * The same as {@link gap}, but automatically read from the computed styles.\n * Used if not set by user.\n */\n private computedGap = 0;\n private injector = inject(INJECTOR);\n\n ngAfterViewInit(): void {\n if (this.siAutoCollapsableList()) {\n this.readGapSize();\n this.setupResizeListener();\n } else {\n this.reset();\n }\n }\n\n ngOnChanges(changes: SimpleChanges<this>): void {\n if (changes.siAutoCollapsableList) {\n const siAutoCollapsableList = this.siAutoCollapsableList();\n if (!siAutoCollapsableList && this.resizeSubscription) {\n this.reset();\n } else if (siAutoCollapsableList && !this.resizeSubscription && this.items()) {\n this.setupResizeListener();\n }\n }\n\n if (changes.containerElement) {\n this.containerElementSubject.next(this.containerElement() ?? this.elementRef.nativeElement);\n }\n }\n\n ngOnDestroy(): void {\n this.resizeSubscription?.unsubscribe();\n this.disableInitSubscription?.unsubscribe();\n this.containerElementSubject.complete();\n }\n\n private setupResizeListener(): void {\n this.disableInitSubscription?.unsubscribe();\n const containerSize$ = this.containerElementSubject.pipe(\n switchMap(element => this.resizeObserverService.observe(element!, 0, true, true)),\n map(size => size.width),\n distinctUntilChanged(),\n map(size => {\n const { paddingInlineStart, paddingInlineEnd } = getComputedStyle(\n this.containerElement() ?? this.elementRef.nativeElement\n );\n return size - parseFloat(paddingInlineStart) - parseFloat(paddingInlineEnd);\n })\n );\n\n const itemSizes$ = toObservable(this.items, { injector: this.injector }).pipe(\n startWith(this.items()),\n switchMap(items =>\n !items.length\n ? of([])\n : combineLatest(\n items.map(item =>\n item.size$.pipe(\n map(size => ({\n size,\n directive: item\n }))\n )\n )\n )\n )\n );\n const additionalContentSizes$ = toObservable(this.additionalContent, {\n injector: this.injector\n }).pipe(\n startWith(this.additionalContent()),\n switchMap(additionalContent => combineLatest(additionalContent.map(item => item.size$))),\n startWith([])\n );\n\n this.resizeSubscription = combineLatest([\n containerSize$,\n this.overflowItem()?.size$ ?? of(0),\n itemSizes$,\n additionalContentSizes$\n ])\n .pipe(auditTime(0))\n .subscribe(([containerSize, overflowItemSize, items, additionalContentSizes]) =>\n this.updateItemVisibility(containerSize, overflowItemSize, items, additionalContentSizes)\n );\n }\n\n private updateItemVisibility(\n containerSize: number,\n overflowItemSize: number,\n items: { size: number; directive: SiAutoCollapsableListItemDirective }[],\n additionalContent: number[]\n ): void {\n let remainingSpace = containerSize - additionalContent.reduce((a, b) => a + b, 0);\n\n const itemsRemaining = items.slice();\n\n const gap = this.gap() ?? this.computedGap;\n\n while (remainingSpace > 0 && itemsRemaining.length) {\n const item = itemsRemaining.shift()!;\n if (remainingSpace - item.size - gap - overflowItemSize >= 0) {\n // There is space for the item and an overflow item.\n item.directive.canBeVisible.set(true);\n remainingSpace -= item.size + gap;\n } else if (\n !itemsRemaining.length &&\n (remainingSpace - item.size >= 0 || overflowItemSize >= item.size)\n ) {\n // There are no other items remaining and there is enough space or the overflow item is biggger than the current one.\n item.directive.canBeVisible.set(true);\n remainingSpace = 0;\n } else {\n // There is no space for the item.\n remainingSpace = 0;\n item.directive.canBeVisible.set(false);\n }\n }\n itemsRemaining.forEach(item => item.directive.canBeVisible.set(false));\n\n const overflowItem = this.overflowItem();\n if (overflowItem) {\n overflowItem.hiddenItemCount = this.items().filter(item => !item.canBeVisible()).length;\n overflowItem.canBeVisible.set(overflowItem.hiddenItemCount !== 0);\n }\n this.changeDetectorRef.markForCheck();\n }\n\n private reset(): void {\n this.resizeSubscription?.unsubscribe();\n this.resizeSubscription = undefined;\n this.disableInitSubscription = toObservable(this.items, { injector: this.injector }).subscribe(\n items =>\n queueMicrotask(() => {\n items.forEach(item => item.canBeVisible.set(true));\n })\n );\n\n const overflowItem = this.overflowItem();\n if (overflowItem) {\n queueMicrotask(() => {\n overflowItem!.canBeVisible.set(false);\n overflowItem!.hiddenItemCount = 0;\n });\n }\n }\n\n private readGapSize(): void {\n const { gap } = getComputedStyle(this.containerElement() ?? this.elementRef.nativeElement);\n if (gap.endsWith('px') || gap === '0') {\n this.computedGap = parseFloat(gap);\n }\n }\n}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { NgModule } from '@angular/core';\n\nimport { SiAutoCollapsableListAdditionalContentDirective } from './si-auto-collapsable-list-additional-content.directive';\nimport { SiAutoCollapsableListItemDirective } from './si-auto-collapsable-list-item.directive';\nimport { SiAutoCollapsableListOverflowItemDirective } from './si-auto-collapsable-list-overflow-item.directive';\nimport { SiAutoCollapsableListDirective } from './si-auto-collapsable-list.directive';\n\n@NgModule({\n imports: [\n SiAutoCollapsableListAdditionalContentDirective,\n SiAutoCollapsableListDirective,\n SiAutoCollapsableListItemDirective,\n SiAutoCollapsableListOverflowItemDirective\n ],\n exports: [\n SiAutoCollapsableListAdditionalContentDirective,\n SiAutoCollapsableListDirective,\n SiAutoCollapsableListItemDirective,\n SiAutoCollapsableListOverflowItemDirective\n ]\n})\nexport class SiAutoCollapsableListModule {}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-auto-collapsable-list-item.directive';\nexport * from './si-auto-collapsable-list.directive';\nexport * from './si-auto-collapsable-list-overflow-item.directive';\nexport * from './si-auto-collapsable-list-measurable.class';\nexport * from './si-auto-collapsable-list-additional-content.directive';\nexport * from './si-auto-collapsable-list.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;AAAA;;;AAGG;MAMU,+BAA+B,CAAA;AACvB,IAAA,UAAU,GAAG,MAAM,EAAC,UAAuB,EAAC;AAC9C,IAAA,qBAAqB,GAAG,MAAM,CAAC,qBAAqB,CAAC;AAEtE;;;;;;;;;;;;;AAaG;AACH,IAAA,KAAK,GAAG,IAAI,CAAC,qBAAqB,CAAC,OAAO,CAAC,IAAI,CAAC,UAAU,CAAC,aAAa,EAAE,CAAC,EAAE,IAAI,EAAE,IAAI,CAAC,CAAC,IAAI,CAC3F,GAAG,CAAC,IAAI,IAAI,IAAI,CAAC,KAAK,CAAC,EACvB,oBAAoB,EAAE,EACtB,WAAW,CAAC,CAAC,CAAC,CACf;uGAtBU,+BAA+B,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,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,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,QAAA,EAAA,EAAA,EAAA,IAAA,EAAA,2BAA2B,YAZpC,+CAA+C;YAC/C,8BAA8B;YAC9B,kCAAkC;AAClC,YAAA,0CAA0C,aAG1C,+CAA+C;YAC/C,8BAA8B;YAC9B,kCAAkC;YAClC,0CAA0C,CAAA,EAAA,CAAA;wGAGjC,2BAA2B,EAAA,CAAA;;2FAA3B,2BAA2B,EAAA,UAAA,EAAA,CAAA;kBAdvC,QAAQ;AAAC,YAAA,IAAA,EAAA,CAAA;AACR,oBAAA,OAAO,EAAE;wBACP,+CAA+C;wBAC/C,8BAA8B;wBAC9B,kCAAkC;wBAClC;AACD,qBAAA;AACD,oBAAA,OAAO,EAAE;wBACP,+CAA+C;wBAC/C,8BAA8B;wBAC9B,kCAAkC;wBAClC;AACD;AACF,iBAAA;;;ACxBD;;;AAGG;;ACHH;;AAEG;;;;"}
|
|
@@ -161,7 +161,7 @@ class SiAvatarComponent {
|
|
|
161
161
|
});
|
|
162
162
|
}
|
|
163
163
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: SiAvatarComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
164
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: SiAvatarComponent, isStandalone: true, selector: "si-avatar", inputs: { size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, imageUrl: { classPropertyName: "imageUrl", publicName: "imageUrl", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, initials: { classPropertyName: "initials", publicName: "initials", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, altText: { classPropertyName: "altText", publicName: "altText", isSignal: true, isRequired: true, transformFunction: null }, status: { classPropertyName: "status", publicName: "status", isSignal: true, isRequired: false, transformFunction: null }, statusAriaLabel: { classPropertyName: "statusAriaLabel", publicName: "statusAriaLabel", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "size()" } }, hostDirectives: [{ directive: SiAvatarBackgroundColorDirective, inputs: ["color", "color", "autoColor", "autoColor"] }], ngImport: i0, template: "@if (imageUrl()) {\n <img [src]=\"imageUrl()\" [alt]=\"altText()\" />\n} @else if (icon()) {\n <si-icon class=\"icon\" [title]=\"altText()\" [icon]=\"icon()!\" />\n} @else {\n <div\n class=\"initials\"\n [class.text-body]=\"color() === 0\"\n [title]=\"altText()\"\n [attr.aria-label]=\"altText()\"\n >{{ displayInitials() }}</div\n >\n}\n@let iconConfig = statusIcon();\n@if (iconConfig) {\n <span class=\"indicator-size indicator icon-stack\">\n <si-icon [class]=\"`drop-shadow ${iconConfig.color}`\" [icon]=\"iconConfig.icon\" />\n <si-icon [class]=\"iconConfig.stackedColor\" [icon]=\"iconConfig.stacked\" />\n </span>\n}\n", styles: [":host{--avatar-size: calc(1.25rem + 20px) ;--indicator-size: 1.25rem;--background: var(--si-sys-background-0);--indicator-offset-x: -.625rem;--indicator-offset-y: -.375rem;flex:0 0 auto;display:inline-flex;vertical-align:middle;color:var(--si-sys-text-inverse);position:relative;align-items:center;justify-content:center;inline-size:var(--avatar-size);block-size:var(--avatar-size);border-radius:50%;background:var(--background)}:host.tiny,:host.xsmall,:host.small{--initials-size: .875rem;--indicator-size: 1rem;--indicator-offset-x: -.5rem;--indicator-offset-y: -.25rem}:host.tiny{--avatar-size: calc(1.25rem + 4px) }:host.xsmall{--avatar-size: calc(1.25rem + 8px) }:host.small{--avatar-size: calc(1.25rem + 12px) }:host.large{--avatar-size: calc(1.25rem + 36px) }:host.xlarge{--avatar-size: calc(1.25rem + 60px) }.initials{font-weight:600;font-size:var(--initials-size, 1.
|
|
164
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: SiAvatarComponent, isStandalone: true, selector: "si-avatar", inputs: { size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null }, imageUrl: { classPropertyName: "imageUrl", publicName: "imageUrl", isSignal: true, isRequired: false, transformFunction: null }, icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, initials: { classPropertyName: "initials", publicName: "initials", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, altText: { classPropertyName: "altText", publicName: "altText", isSignal: true, isRequired: true, transformFunction: null }, status: { classPropertyName: "status", publicName: "status", isSignal: true, isRequired: false, transformFunction: null }, statusAriaLabel: { classPropertyName: "statusAriaLabel", publicName: "statusAriaLabel", isSignal: true, isRequired: false, transformFunction: null } }, host: { properties: { "class": "size()" } }, hostDirectives: [{ directive: SiAvatarBackgroundColorDirective, inputs: ["color", "color", "autoColor", "autoColor"] }], ngImport: i0, template: "@if (imageUrl()) {\n <img [src]=\"imageUrl()\" [alt]=\"altText()\" />\n} @else if (icon()) {\n <si-icon class=\"icon\" [title]=\"altText()\" [icon]=\"icon()!\" />\n} @else {\n <div\n class=\"initials\"\n [class.text-body]=\"color() === 0\"\n [title]=\"altText()\"\n [attr.aria-label]=\"altText()\"\n >{{ displayInitials() }}</div\n >\n}\n@let iconConfig = statusIcon();\n@if (iconConfig) {\n <span class=\"indicator-size indicator icon-stack\">\n <si-icon [class]=\"`drop-shadow ${iconConfig.color}`\" [icon]=\"iconConfig.icon\" />\n <si-icon [class]=\"iconConfig.stackedColor\" [icon]=\"iconConfig.stacked\" />\n </span>\n}\n", styles: [":host{--avatar-size: calc(1.25rem + 20px) ;--indicator-size: 1.25rem;--background: var(--si-sys-background-0);--indicator-offset-x: -.625rem;--indicator-offset-y: -.375rem;flex:0 0 auto;display:inline-flex;vertical-align:middle;color:var(--si-sys-text-inverse);position:relative;align-items:center;justify-content:center;inline-size:var(--avatar-size);block-size:var(--avatar-size);border-radius:50%;background:var(--background)}:host.tiny,:host.xsmall,:host.small{--initials-size: .875rem;--indicator-size: 1rem;--indicator-offset-x: -.5rem;--indicator-offset-y: -.25rem}:host.tiny{--avatar-size: calc(1.25rem + 4px) }:host.xsmall{--avatar-size: calc(1.25rem + 8px) }:host.small{--avatar-size: calc(1.25rem + 12px) }:host.large{--avatar-size: calc(1.25rem + 36px) }:host.xlarge{--avatar-size: calc(1.25rem + 60px) }.initials{font-weight:600;font-size:var(--initials-size, 1.25rem);line-height:1}img{inline-size:var(--avatar-size);block-size:var(--avatar-size);border-radius:50%}.indicator{position:absolute;inset-block-start:var(--indicator-offset-y);inset-inline-end:var(--indicator-offset-x);font-size:var(--indicator-size);filter:drop-shadow(1px 0 0 var(--si-sys-background-1)) drop-shadow(-1px 0 0 var(--si-sys-background-1)) drop-shadow(0 1px 0 var(--si-sys-background-1)) drop-shadow(0 -1px 0 var(--si-sys-background-1))}\n"], dependencies: [{ kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }] });
|
|
165
165
|
}
|
|
166
166
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: SiAvatarComponent, decorators: [{
|
|
167
167
|
type: Component,
|
|
@@ -172,7 +172,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImpor
|
|
|
172
172
|
directive: SiAvatarBackgroundColorDirective,
|
|
173
173
|
inputs: ['color', 'autoColor']
|
|
174
174
|
}
|
|
175
|
-
], template: "@if (imageUrl()) {\n <img [src]=\"imageUrl()\" [alt]=\"altText()\" />\n} @else if (icon()) {\n <si-icon class=\"icon\" [title]=\"altText()\" [icon]=\"icon()!\" />\n} @else {\n <div\n class=\"initials\"\n [class.text-body]=\"color() === 0\"\n [title]=\"altText()\"\n [attr.aria-label]=\"altText()\"\n >{{ displayInitials() }}</div\n >\n}\n@let iconConfig = statusIcon();\n@if (iconConfig) {\n <span class=\"indicator-size indicator icon-stack\">\n <si-icon [class]=\"`drop-shadow ${iconConfig.color}`\" [icon]=\"iconConfig.icon\" />\n <si-icon [class]=\"iconConfig.stackedColor\" [icon]=\"iconConfig.stacked\" />\n </span>\n}\n", styles: [":host{--avatar-size: calc(1.25rem + 20px) ;--indicator-size: 1.25rem;--background: var(--si-sys-background-0);--indicator-offset-x: -.625rem;--indicator-offset-y: -.375rem;flex:0 0 auto;display:inline-flex;vertical-align:middle;color:var(--si-sys-text-inverse);position:relative;align-items:center;justify-content:center;inline-size:var(--avatar-size);block-size:var(--avatar-size);border-radius:50%;background:var(--background)}:host.tiny,:host.xsmall,:host.small{--initials-size: .875rem;--indicator-size: 1rem;--indicator-offset-x: -.5rem;--indicator-offset-y: -.25rem}:host.tiny{--avatar-size: calc(1.25rem + 4px) }:host.xsmall{--avatar-size: calc(1.25rem + 8px) }:host.small{--avatar-size: calc(1.25rem + 12px) }:host.large{--avatar-size: calc(1.25rem + 36px) }:host.xlarge{--avatar-size: calc(1.25rem + 60px) }.initials{font-weight:600;font-size:var(--initials-size, 1.
|
|
175
|
+
], template: "@if (imageUrl()) {\n <img [src]=\"imageUrl()\" [alt]=\"altText()\" />\n} @else if (icon()) {\n <si-icon class=\"icon\" [title]=\"altText()\" [icon]=\"icon()!\" />\n} @else {\n <div\n class=\"initials\"\n [class.text-body]=\"color() === 0\"\n [title]=\"altText()\"\n [attr.aria-label]=\"altText()\"\n >{{ displayInitials() }}</div\n >\n}\n@let iconConfig = statusIcon();\n@if (iconConfig) {\n <span class=\"indicator-size indicator icon-stack\">\n <si-icon [class]=\"`drop-shadow ${iconConfig.color}`\" [icon]=\"iconConfig.icon\" />\n <si-icon [class]=\"iconConfig.stackedColor\" [icon]=\"iconConfig.stacked\" />\n </span>\n}\n", styles: [":host{--avatar-size: calc(1.25rem + 20px) ;--indicator-size: 1.25rem;--background: var(--si-sys-background-0);--indicator-offset-x: -.625rem;--indicator-offset-y: -.375rem;flex:0 0 auto;display:inline-flex;vertical-align:middle;color:var(--si-sys-text-inverse);position:relative;align-items:center;justify-content:center;inline-size:var(--avatar-size);block-size:var(--avatar-size);border-radius:50%;background:var(--background)}:host.tiny,:host.xsmall,:host.small{--initials-size: .875rem;--indicator-size: 1rem;--indicator-offset-x: -.5rem;--indicator-offset-y: -.25rem}:host.tiny{--avatar-size: calc(1.25rem + 4px) }:host.xsmall{--avatar-size: calc(1.25rem + 8px) }:host.small{--avatar-size: calc(1.25rem + 12px) }:host.large{--avatar-size: calc(1.25rem + 36px) }:host.xlarge{--avatar-size: calc(1.25rem + 60px) }.initials{font-weight:600;font-size:var(--initials-size, 1.25rem);line-height:1}img{inline-size:var(--avatar-size);block-size:var(--avatar-size);border-radius:50%}.indicator{position:absolute;inset-block-start:var(--indicator-offset-y);inset-inline-end:var(--indicator-offset-x);font-size:var(--indicator-size);filter:drop-shadow(1px 0 0 var(--si-sys-background-1)) drop-shadow(-1px 0 0 var(--si-sys-background-1)) drop-shadow(0 1px 0 var(--si-sys-background-1)) drop-shadow(0 -1px 0 var(--si-sys-background-1))}\n"] }]
|
|
176
176
|
}], ctorParameters: () => [], propDecorators: { size: [{ type: i0.Input, args: [{ isSignal: true, alias: "size", required: false }] }], imageUrl: [{ type: i0.Input, args: [{ isSignal: true, alias: "imageUrl", required: false }] }], icon: [{ type: i0.Input, args: [{ isSignal: true, alias: "icon", required: false }] }], initials: [{ type: i0.Input, args: [{ isSignal: true, alias: "initials", required: false }] }], color: [{ type: i0.Input, args: [{ isSignal: true, alias: "color", required: false }] }], altText: [{ type: i0.Input, args: [{ isSignal: true, alias: "altText", required: true }] }], status: [{ type: i0.Input, args: [{ isSignal: true, alias: "status", required: false }] }], statusAriaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "statusAriaLabel", required: false }] }] } });
|
|
177
177
|
|
|
178
178
|
/**
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"siemens-element-ng-avatar.mjs","sources":["../../../../projects/element-ng/avatar/si-avatar-background-color.directive.ts","../../../../projects/element-ng/avatar/si-avatar.component.ts","../../../../projects/element-ng/avatar/si-avatar.component.html","../../../../projects/element-ng/avatar/index.ts","../../../../projects/element-ng/avatar/siemens-element-ng-avatar.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport {\n booleanAttribute,\n Directive,\n input,\n numberAttribute,\n OnChanges,\n signal,\n SimpleChanges\n} from '@angular/core';\n\nconst DATA_COLORS_MAX = 17;\nconst DATA_COLOR_NEUTRAL = 17;\nconst ASCII_CODE_INDEX_A = 64;\n\n/**\n * The directive provide a CSS variable --background with a color based on the initials or alt text.\n */\n@Directive({\n selector: '[siAvatarBackgroundColor]',\n host: {\n '[style.--background]': 'backgroundStyle()'\n }\n})\nexport class SiAvatarBackgroundColorDirective implements OnChanges {\n /**\n * The desired color index from $si-sys-data-categorial-* color tokens. This can be set to any kind of\n * positive integer that is then mapped to a color index.\n * A better way to set a pseudo-random color is to set {@link autoColor} to `true`.\n *\n * @defaultValue undefined\n */\n readonly color = input<number | undefined, unknown>(undefined, { transform: numberAttribute });\n\n /**\n * Automatically calculates the background color.\n * If set, {@link color} will be ignored.\n *\n * @defaultValue false\n */\n readonly autoColor = input(false, { transform: booleanAttribute });\n\n protected readonly backgroundStyle = signal<string | undefined>(\n 'var(--si-sys-data-categorial-17)'\n );\n\n ngOnChanges(changes: SimpleChanges<this>): void {\n if (changes.color) {\n this.setColor(this.color());\n }\n }\n\n /**\n * Update background color variable based on the initials or placeholder text.\n */\n public calculateColorFromInitials(displayInitials?: string): void {\n if (!this.autoColor() || !displayInitials) {\n return;\n }\n\n let color = 0;\n for (let i = 0; i < displayInitials.length; i++) {\n color *= 17; // this prevents 'JD' to have the same color as 'DJ'\n color += displayInitials.charCodeAt(i) - ASCII_CODE_INDEX_A;\n }\n this.setColor(color);\n }\n\n private setColor(color?: number): void {\n if (this.color() === 0) {\n this.backgroundStyle.set(undefined);\n } else {\n const actualColor = color ?? DATA_COLOR_NEUTRAL;\n const colorIndex = ((actualColor - 1) % DATA_COLORS_MAX) + 1;\n this.backgroundStyle.set(`var(--si-sys-data-categorial-${colorIndex})`);\n }\n }\n}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { Component, computed, effect, inject, input, numberAttribute } from '@angular/core';\nimport { EntityStatusType } from '@siemens/element-ng/common';\nimport { SiIconComponent, STATUS_ICON_CONFIG } from '@siemens/element-ng/icon';\nimport { TranslatableString } from '@siemens/element-translate-ng/translate';\n\nimport { SiAvatarBackgroundColorDirective } from './si-avatar-background-color.directive';\n\nexport type AvatarSize = 'tiny' | 'xsmall' | 'small' | 'regular' | 'large' | 'xlarge';\n\n@Component({\n selector: 'si-avatar',\n imports: [SiIconComponent],\n templateUrl: './si-avatar.component.html',\n styleUrl: './si-avatar.component.scss',\n host: {\n '[class]': 'size()'\n },\n hostDirectives: [\n {\n directive: SiAvatarBackgroundColorDirective,\n inputs: ['color', 'autoColor']\n }\n ]\n})\nexport class SiAvatarComponent {\n private readonly statusIcons = inject(STATUS_ICON_CONFIG);\n /**\n * Size of the component.\n *\n * @defaultValue 'regular'\n */\n readonly size = input<AvatarSize>('regular');\n /** Image src URL when using an image. */\n readonly imageUrl = input<string>();\n /** Icon name when using an icon. */\n readonly icon = input<string>();\n /**\n * Initials to be displayed as default avatar if no `icon` or `imageUrl` are provided.\n * If also no initials are provided, they will be automatically calculated from the `altText`.\n * The value will be used to calculate the background color when `autoColor` is true.\n */\n readonly initials = input<string>();\n /**\n * The desired color index from $element-data-* color tokens. This can be set to any kind of\n * positive integer that is then mapped to a color index.\n * A better way to set a pseudo-random color is to set * {@link autoColor} to `true`.\n *\n * @defaultValue undefined\n */\n readonly color = input<number | undefined, unknown>(undefined, { transform: numberAttribute });\n /** The `alt` text for image, `title` for other modes. */\n readonly altText = input.required<string>();\n /**\n * The status (success, info, warning, caution, danger, critical, pending, progress) to be\n * visualized.\n */\n readonly status = input<EntityStatusType>();\n /**\n * aria-label for status\n */\n readonly statusAriaLabel = input<TranslatableString>();\n\n protected readonly statusIcon = computed(() => {\n const status = this.status();\n return status ? this.statusIcons[status] : undefined;\n });\n\n protected readonly displayInitials = computed(() => {\n const initials = this.initials();\n if (initials) {\n return initials;\n }\n\n const name = this.altText()\n .replaceAll(/\\([^)]*\\)/g, '')\n .trim();\n const byComma = name.split(/,\\s*/);\n let first: string;\n let last: string;\n if (byComma.length > 1) {\n last = byComma[0];\n first = byComma[1];\n } else {\n const parts = name.split(' ');\n first = parts.shift() ?? '';\n last = parts.pop() ?? '';\n }\n if (first) {\n first = first[0].toLocaleUpperCase();\n }\n if (last) {\n last = last[0].toLocaleUpperCase();\n }\n return first + last;\n });\n\n private readonly autoBackgroundColorDirective = inject(SiAvatarBackgroundColorDirective);\n\n constructor() {\n effect(() => {\n this.autoBackgroundColorDirective.calculateColorFromInitials(this.displayInitials());\n });\n }\n}\n","@if (imageUrl()) {\n <img [src]=\"imageUrl()\" [alt]=\"altText()\" />\n} @else if (icon()) {\n <si-icon class=\"icon\" [title]=\"altText()\" [icon]=\"icon()!\" />\n} @else {\n <div\n class=\"initials\"\n [class.text-body]=\"color() === 0\"\n [title]=\"altText()\"\n [attr.aria-label]=\"altText()\"\n >{{ displayInitials() }}</div\n >\n}\n@let iconConfig = statusIcon();\n@if (iconConfig) {\n <span class=\"indicator-size indicator icon-stack\">\n <si-icon [class]=\"`drop-shadow ${iconConfig.color}`\" [icon]=\"iconConfig.icon\" />\n <si-icon [class]=\"iconConfig.stackedColor\" [icon]=\"iconConfig.stacked\" />\n </span>\n}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-avatar-background-color.directive';\nexport * from './si-avatar.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1.SiAvatarBackgroundColorDirective"],"mappings":";;;;AAAA;;;AAGG;AAWH,MAAM,eAAe,GAAG,EAAE;AAC1B,M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A,EAAA,QAAA,EAAA,+oBAAA,EAAA,MAAA,EAAA,CAAA,qzCAAA,CAAA,EAAA;;;AE1BH;;;AAGG;;ACHH;;AAEG;;;;"}
|
|
1
|
+
{"version":3,"file":"siemens-element-ng-avatar.mjs","sources":["../../../../projects/element-ng/avatar/si-avatar-background-color.directive.ts","../../../../projects/element-ng/avatar/si-avatar.component.ts","../../../../projects/element-ng/avatar/si-avatar.component.html","../../../../projects/element-ng/avatar/index.ts","../../../../projects/element-ng/avatar/siemens-element-ng-avatar.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport {\n booleanAttribute,\n Directive,\n input,\n numberAttribute,\n OnChanges,\n signal,\n SimpleChanges\n} from '@angular/core';\n\nconst DATA_COLORS_MAX = 17;\nconst DATA_COLOR_NEUTRAL = 17;\nconst ASCII_CODE_INDEX_A = 64;\n\n/**\n * The directive provide a CSS variable --background with a color based on the initials or alt text.\n */\n@Directive({\n selector: '[siAvatarBackgroundColor]',\n host: {\n '[style.--background]': 'backgroundStyle()'\n }\n})\nexport class SiAvatarBackgroundColorDirective implements OnChanges {\n /**\n * The desired color index from $si-sys-data-categorial-* color tokens. This can be set to any kind of\n * positive integer that is then mapped to a color index.\n * A better way to set a pseudo-random color is to set {@link autoColor} to `true`.\n *\n * @defaultValue undefined\n */\n readonly color = input<number | undefined, unknown>(undefined, { transform: numberAttribute });\n\n /**\n * Automatically calculates the background color.\n * If set, {@link color} will be ignored.\n *\n * @defaultValue false\n */\n readonly autoColor = input(false, { transform: booleanAttribute });\n\n protected readonly backgroundStyle = signal<string | undefined>(\n 'var(--si-sys-data-categorial-17)'\n );\n\n ngOnChanges(changes: SimpleChanges<this>): void {\n if (changes.color) {\n this.setColor(this.color());\n }\n }\n\n /**\n * Update background color variable based on the initials or placeholder text.\n */\n public calculateColorFromInitials(displayInitials?: string): void {\n if (!this.autoColor() || !displayInitials) {\n return;\n }\n\n let color = 0;\n for (let i = 0; i < displayInitials.length; i++) {\n color *= 17; // this prevents 'JD' to have the same color as 'DJ'\n color += displayInitials.charCodeAt(i) - ASCII_CODE_INDEX_A;\n }\n this.setColor(color);\n }\n\n private setColor(color?: number): void {\n if (this.color() === 0) {\n this.backgroundStyle.set(undefined);\n } else {\n const actualColor = color ?? DATA_COLOR_NEUTRAL;\n const colorIndex = ((actualColor - 1) % DATA_COLORS_MAX) + 1;\n this.backgroundStyle.set(`var(--si-sys-data-categorial-${colorIndex})`);\n }\n }\n}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { Component, computed, effect, inject, input, numberAttribute } from '@angular/core';\nimport { EntityStatusType } from '@siemens/element-ng/common';\nimport { SiIconComponent, STATUS_ICON_CONFIG } from '@siemens/element-ng/icon';\nimport { TranslatableString } from '@siemens/element-translate-ng/translate';\n\nimport { SiAvatarBackgroundColorDirective } from './si-avatar-background-color.directive';\n\nexport type AvatarSize = 'tiny' | 'xsmall' | 'small' | 'regular' | 'large' | 'xlarge';\n\n@Component({\n selector: 'si-avatar',\n imports: [SiIconComponent],\n templateUrl: './si-avatar.component.html',\n styleUrl: './si-avatar.component.scss',\n host: {\n '[class]': 'size()'\n },\n hostDirectives: [\n {\n directive: SiAvatarBackgroundColorDirective,\n inputs: ['color', 'autoColor']\n }\n ]\n})\nexport class SiAvatarComponent {\n private readonly statusIcons = inject(STATUS_ICON_CONFIG);\n /**\n * Size of the component.\n *\n * @defaultValue 'regular'\n */\n readonly size = input<AvatarSize>('regular');\n /** Image src URL when using an image. */\n readonly imageUrl = input<string>();\n /** Icon name when using an icon. */\n readonly icon = input<string>();\n /**\n * Initials to be displayed as default avatar if no `icon` or `imageUrl` are provided.\n * If also no initials are provided, they will be automatically calculated from the `altText`.\n * The value will be used to calculate the background color when `autoColor` is true.\n */\n readonly initials = input<string>();\n /**\n * The desired color index from $element-data-* color tokens. This can be set to any kind of\n * positive integer that is then mapped to a color index.\n * A better way to set a pseudo-random color is to set * {@link autoColor} to `true`.\n *\n * @defaultValue undefined\n */\n readonly color = input<number | undefined, unknown>(undefined, { transform: numberAttribute });\n /** The `alt` text for image, `title` for other modes. */\n readonly altText = input.required<string>();\n /**\n * The status (success, info, warning, caution, danger, critical, pending, progress) to be\n * visualized.\n */\n readonly status = input<EntityStatusType>();\n /**\n * aria-label for status\n */\n readonly statusAriaLabel = input<TranslatableString>();\n\n protected readonly statusIcon = computed(() => {\n const status = this.status();\n return status ? this.statusIcons[status] : undefined;\n });\n\n protected readonly displayInitials = computed(() => {\n const initials = this.initials();\n if (initials) {\n return initials;\n }\n\n const name = this.altText()\n .replaceAll(/\\([^)]*\\)/g, '')\n .trim();\n const byComma = name.split(/,\\s*/);\n let first: string;\n let last: string;\n if (byComma.length > 1) {\n last = byComma[0];\n first = byComma[1];\n } else {\n const parts = name.split(' ');\n first = parts.shift() ?? '';\n last = parts.pop() ?? '';\n }\n if (first) {\n first = first[0].toLocaleUpperCase();\n }\n if (last) {\n last = last[0].toLocaleUpperCase();\n }\n return first + last;\n });\n\n private readonly autoBackgroundColorDirective = inject(SiAvatarBackgroundColorDirective);\n\n constructor() {\n effect(() => {\n this.autoBackgroundColorDirective.calculateColorFromInitials(this.displayInitials());\n });\n }\n}\n","@if (imageUrl()) {\n <img [src]=\"imageUrl()\" [alt]=\"altText()\" />\n} @else if (icon()) {\n <si-icon class=\"icon\" [title]=\"altText()\" [icon]=\"icon()!\" />\n} @else {\n <div\n class=\"initials\"\n [class.text-body]=\"color() === 0\"\n [title]=\"altText()\"\n [attr.aria-label]=\"altText()\"\n >{{ displayInitials() }}</div\n >\n}\n@let iconConfig = statusIcon();\n@if (iconConfig) {\n <span class=\"indicator-size indicator icon-stack\">\n <si-icon [class]=\"`drop-shadow ${iconConfig.color}`\" [icon]=\"iconConfig.icon\" />\n <si-icon [class]=\"iconConfig.stackedColor\" [icon]=\"iconConfig.stacked\" />\n </span>\n}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-avatar-background-color.directive';\nexport * from './si-avatar.component';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1.SiAvatarBackgroundColorDirective"],"mappings":";;;;AAAA;;;AAGG;AAWH,MAAM,eAAe,GAAG,EAAE;AAC1B,MAAM,kBAAkB,GAAG,EAAE;AAC7B,MAAM,kBAAkB,GAAG,EAAE;AAE7B;;AAEG;MAOU,gCAAgC,CAAA;AAC3C;;;;;;AAMG;IACM,KAAK,GAAG,KAAK,CAA8B,SAAS,6EAAI,SAAS,EAAE,eAAe,EAAA,CAAG;AAE9F;;;;;AAKG;IACM,SAAS,GAAG,KAAK,CAAC,KAAK,iFAAI,SAAS,EAAE,gBAAgB,EAAA,CAAG;IAE/C,eAAe,GAAG,MAAM,CACzC,kCAAkC;wFACnC;AAED,IAAA,WAAW,CAAC,OAA4B,EAAA;AACtC,QAAA,IAAI,OAAO,CAAC,KAAK,EAAE;YACjB,IAAI,CAAC,QAAQ,CAAC,IAAI,CAAC,KAAK,EAAE,CAAC;QAC7B;IACF;AAEA;;AAEG;AACI,IAAA,0BAA0B,CAAC,eAAwB,EAAA;QACxD,IAAI,CAAC,IAAI,CAAC,SAAS,EAAE,IAAI,CAAC,eAAe,EAAE;YACzC;QACF;QAEA,IAAI,KAAK,GAAG,CAAC;AACb,QAAA,KAAK,IAAI,CAAC,GAAG,CAAC,EAAE,CAAC,GAAG,eAAe,CAAC,MAAM,EAAE,CAAC,EAAE,EAAE;AAC/C,YAAA,KAAK,IAAI,EAAE,CAAC;YACZ,KAAK,IAAI,eAAe,CAAC,UAAU,CAAC,CAAC,CAAC,GAAG,kBAAkB;QAC7D;AACA,QAAA,IAAI,CAAC,QAAQ,CAAC,KAAK,CAAC;IACtB;AAEQ,IAAA,QAAQ,CAAC,KAAc,EAAA;AAC7B,QAAA,IAAI,IAAI,CAAC,KAAK,EAAE,KAAK,CAAC,EAAE;AACtB,YAAA,IAAI,CAAC,eAAe,CA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C,eAAe,CAAC,EAAA,IAAA,EAGpB;AACJ,wBAAA,SAAS,EAAE;qBACZ,EAAA,cAAA,EACe;AACd,wBAAA;AACE,4BAAA,SAAS,EAAE,gCAAgC;AAC3C,4BAAA,MAAM,EAAE,CAAC,OAAO,EAAE,WAAW;AAC9B;AACF,qBAAA,EAAA,QAAA,EAAA,+oBAAA,EAAA,MAAA,EAAA,CAAA,ozCAAA,CAAA,EAAA;;;AE1BH;;;AAGG;;ACHH;;AAEG;;;;"}
|
|
@@ -259,7 +259,7 @@ class SiBreadcrumbComponent {
|
|
|
259
259
|
this.changeDetector.detectChanges();
|
|
260
260
|
}
|
|
261
261
|
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: SiBreadcrumbComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
262
|
-
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: SiBreadcrumbComponent, isStandalone: true, selector: "si-breadcrumb", inputs: { items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: true, transformFunction: null }, showRootAsText: { classPropertyName: "showRootAsText", publicName: "showRootAsText", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "document:click": "documentClick($event.target)" } }, viewQueries: [{ propertyName: "breadcrumbElement", first: true, predicate: ["breadcrumb"], descendants: true, isSignal: true }, { propertyName: "breadcrumbElements", predicate: ["breadcrumbItem"], descendants: true, isSignal: true }], usesOnChanges: true, ngImport: i0, template: "<nav class=\"py-2\" [attr.aria-label]=\"ariaLabel() | translate\">\n <ol #breadcrumb class=\"breadcrumb\" (siResizeObserver)=\"resetBreadcrumb()\">\n @for (item of itemsShown; track $index; let isFirst = $first) {\n @if (!breadcrumbShortened || item.level !== ellipsesLevel) {\n @if (item.shortened) {\n <li #breadcrumbItem class=\"item text-nowrap shortened\">\n @if (!isFirst) {\n <si-icon class=\"d-block separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <div class=\"breadcrumb-dropdown-wrapper\">\n <ng-container\n *ngTemplateOutlet=\"\n toggleTemplate;\n context: { item: item, title: item.shortenedTitle }\n \"\n />\n @if (addExpandDropdown) {\n <div\n class=\"dropdown-menu\"\n role=\"menu\"\n [id]=\"controlId + item.level\"\n [class.show]=\"breadcrumbDropdownOpen === item.level\"\n >\n <ng-container *ngTemplateOutlet=\"dropdownTemplate; context: { item: item }\" />\n </div>\n }\n </div>\n </li>\n } @else {\n <li #breadcrumbItem class=\"item\">\n @if (!isFirst) {\n <si-icon class=\"d-block icon-sm separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <ng-container *ngTemplateOutlet=\"itemTemplate; context: { item: item }\" />\n </li>\n }\n }\n @if (breadcrumbShortened && item.level === ellipsesLevel) {\n <li class=\"item breadcrumb-ellipses-item\">\n @if (!isFirst) {\n <si-icon class=\"d-block icon-sm separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <div class=\"breadcrumb-dropdown-wrapper\">\n <ng-container *ngTemplateOutlet=\"toggleTemplate; context: { item: item, title: '' }\" />\n <div\n class=\"dropdown-menu\"\n role=\"menu\"\n [id]=\"controlId + item.level\"\n [class.show]=\"breadcrumbDropdownOpen === item.level\"\n >\n @for (item of itemsHidden; track $index) {\n <ng-container *ngTemplateOutlet=\"dropdownTemplate; context: { item: item }\" />\n }\n </div>\n </div>\n </li>\n }\n }\n </ol>\n</nav>\n\n<ng-template #itemTemplate let-item=\"item\" siBreadcrumbItemTemplate>\n <a\n class=\"breadcrumb-link text-nowrap\"\n activeClass=\"active\"\n ariaCurrent=\"page\"\n [class.disable-router-link]=\"!item.link && !item.action && !item.href\"\n [class.text-secondary]=\"item.lastItem\"\n [siLink]=\"item\"\n [exactMatch]=\"true\"\n [attr.aria-label]=\"item.title\"\n [attr.aria-disabled]=\"!item.link && !item.href && !item.action\"\n >\n @if (item.level === 0) {\n <si-icon class=\"d-block icon-sm flip-rtl\" [icon]=\"icons.elementBreadcrumbRoot\" />\n } @else {\n <span>{{ item.title }}</span>\n }\n </a>\n</ng-template>\n\n<ng-template #toggleTemplate let-item=\"item\" let-title=\"title\" siBreadcrumbItemTemplate>\n <
|
|
262
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "22.0.8", type: SiBreadcrumbComponent, isStandalone: true, selector: "si-breadcrumb", inputs: { items: { classPropertyName: "items", publicName: "items", isSignal: true, isRequired: true, transformFunction: null }, showRootAsText: { classPropertyName: "showRootAsText", publicName: "showRootAsText", isSignal: true, isRequired: false, transformFunction: null }, ariaLabel: { classPropertyName: "ariaLabel", publicName: "ariaLabel", isSignal: true, isRequired: false, transformFunction: null } }, host: { listeners: { "document:click": "documentClick($event.target)" } }, viewQueries: [{ propertyName: "breadcrumbElement", first: true, predicate: ["breadcrumb"], descendants: true, isSignal: true }, { propertyName: "breadcrumbElements", predicate: ["breadcrumbItem"], descendants: true, isSignal: true }], usesOnChanges: true, ngImport: i0, template: "<nav class=\"py-2\" [attr.aria-label]=\"ariaLabel() | translate\">\n <ol #breadcrumb class=\"breadcrumb\" (siResizeObserver)=\"resetBreadcrumb()\">\n @for (item of itemsShown; track $index; let isFirst = $first) {\n @if (!breadcrumbShortened || item.level !== ellipsesLevel) {\n @if (item.shortened) {\n <li #breadcrumbItem class=\"item text-nowrap shortened\">\n @if (!isFirst) {\n <si-icon class=\"d-block separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <div class=\"breadcrumb-dropdown-wrapper\">\n <ng-container\n *ngTemplateOutlet=\"\n toggleTemplate;\n context: { item: item, title: item.shortenedTitle }\n \"\n />\n @if (addExpandDropdown) {\n <div\n class=\"dropdown-menu\"\n role=\"menu\"\n [id]=\"controlId + item.level\"\n [class.show]=\"breadcrumbDropdownOpen === item.level\"\n >\n <ng-container *ngTemplateOutlet=\"dropdownTemplate; context: { item: item }\" />\n </div>\n }\n </div>\n </li>\n } @else {\n <li #breadcrumbItem class=\"item\">\n @if (!isFirst) {\n <si-icon class=\"d-block icon-sm separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <ng-container *ngTemplateOutlet=\"itemTemplate; context: { item: item }\" />\n </li>\n }\n }\n @if (breadcrumbShortened && item.level === ellipsesLevel) {\n <li class=\"item breadcrumb-ellipses-item\">\n @if (!isFirst) {\n <si-icon class=\"d-block icon-sm separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <div class=\"breadcrumb-dropdown-wrapper\">\n <ng-container *ngTemplateOutlet=\"toggleTemplate; context: { item: item, title: '' }\" />\n <div\n class=\"dropdown-menu\"\n role=\"menu\"\n [id]=\"controlId + item.level\"\n [class.show]=\"breadcrumbDropdownOpen === item.level\"\n >\n @for (item of itemsHidden; track $index) {\n <ng-container *ngTemplateOutlet=\"dropdownTemplate; context: { item: item }\" />\n }\n </div>\n </div>\n </li>\n }\n }\n </ol>\n</nav>\n\n<ng-template #itemTemplate let-item=\"item\" siBreadcrumbItemTemplate>\n <a\n class=\"breadcrumb-link text-nowrap\"\n activeClass=\"active\"\n ariaCurrent=\"page\"\n [class.disable-router-link]=\"!item.link && !item.action && !item.href\"\n [class.text-secondary]=\"item.lastItem\"\n [siLink]=\"item\"\n [exactMatch]=\"true\"\n [attr.aria-label]=\"item.title\"\n [attr.aria-disabled]=\"!item.link && !item.href && !item.action\"\n >\n @if (item.level === 0) {\n <si-icon class=\"d-block icon-sm flip-rtl\" [icon]=\"icons.elementBreadcrumbRoot\" />\n } @else {\n <span>{{ item.title }}</span>\n }\n </a>\n</ng-template>\n\n<ng-template #toggleTemplate let-item=\"item\" let-title=\"title\" siBreadcrumbItemTemplate>\n <button\n type=\"button\"\n class=\"btn btn-link\"\n aria-haspopup=\"true\"\n [attr.aria-controls]=\"controlId + item.level\"\n [attr.aria-expanded]=\"breadcrumbDropdownOpen === item.level\"\n (click)=\"toggleBreadcrumbDropdown(item.level)\"\n >{{ title }}...</button\n >\n</ng-template>\n\n<ng-template #dropdownTemplate let-item=\"item\" siBreadcrumbItemTemplate>\n <a\n class=\"dropdown-item breadcrumb-link focus-inside\"\n activeClass=\"active\"\n ariaCurrent=\"page\"\n role=\"menuitem\"\n [class.disable-router-link]=\"!item.link && !item.action && !item.href\"\n [siLink]=\"item\"\n [exactMatch]=\"true\"\n [attr.aria-disabled]=\"!item.link && !item.action && !item.href\"\n >{{ item.title }}</a\n >\n</ng-template>\n", styles: [".breadcrumb{flex-wrap:nowrap}.item{display:flex;align-items:center}.separator{color:var(--si-sys-text-secondary);margin-block:0;margin-inline:0}.disable-router-link,.disable-router-link:hover{pointer-events:none;color:var(--si-sys-text-disabled)}\n"], dependencies: [{ kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }, { kind: "component", type: SiIconComponent, selector: "si-icon", inputs: ["icon"] }, { kind: "directive", type: SiLinkDirective, selector: "[siLink]", inputs: ["siLink", "siLinkDefaultTarget", "actionParam", "activeClass", "exactMatch", "ariaCurrent"], outputs: ["activeChange"], exportAs: ["siLink"] }, { kind: "directive", type: SiResizeObserverDirective, selector: "[siResizeObserver]", inputs: ["resizeThrottle", "emitInitial"], outputs: ["siResizeObserver"] }, { kind: "directive", type: SiBreadcrumbItemTemplateDirective, selector: "[siBreadcrumbItemTemplate]" }, { kind: "pipe", type: SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.Eager });
|
|
263
263
|
}
|
|
264
264
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImport: i0, type: SiBreadcrumbComponent, decorators: [{
|
|
265
265
|
type: Component,
|
|
@@ -270,7 +270,7 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "22.0.8", ngImpor
|
|
|
270
270
|
SiResizeObserverDirective,
|
|
271
271
|
SiTranslatePipe,
|
|
272
272
|
SiBreadcrumbItemTemplateDirective
|
|
273
|
-
], changeDetection: ChangeDetectionStrategy.Eager, template: "<nav class=\"py-2\" [attr.aria-label]=\"ariaLabel() | translate\">\n <ol #breadcrumb class=\"breadcrumb\" (siResizeObserver)=\"resetBreadcrumb()\">\n @for (item of itemsShown; track $index; let isFirst = $first) {\n @if (!breadcrumbShortened || item.level !== ellipsesLevel) {\n @if (item.shortened) {\n <li #breadcrumbItem class=\"item text-nowrap shortened\">\n @if (!isFirst) {\n <si-icon class=\"d-block separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <div class=\"breadcrumb-dropdown-wrapper\">\n <ng-container\n *ngTemplateOutlet=\"\n toggleTemplate;\n context: { item: item, title: item.shortenedTitle }\n \"\n />\n @if (addExpandDropdown) {\n <div\n class=\"dropdown-menu\"\n role=\"menu\"\n [id]=\"controlId + item.level\"\n [class.show]=\"breadcrumbDropdownOpen === item.level\"\n >\n <ng-container *ngTemplateOutlet=\"dropdownTemplate; context: { item: item }\" />\n </div>\n }\n </div>\n </li>\n } @else {\n <li #breadcrumbItem class=\"item\">\n @if (!isFirst) {\n <si-icon class=\"d-block icon-sm separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <ng-container *ngTemplateOutlet=\"itemTemplate; context: { item: item }\" />\n </li>\n }\n }\n @if (breadcrumbShortened && item.level === ellipsesLevel) {\n <li class=\"item breadcrumb-ellipses-item\">\n @if (!isFirst) {\n <si-icon class=\"d-block icon-sm separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <div class=\"breadcrumb-dropdown-wrapper\">\n <ng-container *ngTemplateOutlet=\"toggleTemplate; context: { item: item, title: '' }\" />\n <div\n class=\"dropdown-menu\"\n role=\"menu\"\n [id]=\"controlId + item.level\"\n [class.show]=\"breadcrumbDropdownOpen === item.level\"\n >\n @for (item of itemsHidden; track $index) {\n <ng-container *ngTemplateOutlet=\"dropdownTemplate; context: { item: item }\" />\n }\n </div>\n </div>\n </li>\n }\n }\n </ol>\n</nav>\n\n<ng-template #itemTemplate let-item=\"item\" siBreadcrumbItemTemplate>\n <a\n class=\"breadcrumb-link text-nowrap\"\n activeClass=\"active\"\n ariaCurrent=\"page\"\n [class.disable-router-link]=\"!item.link && !item.action && !item.href\"\n [class.text-secondary]=\"item.lastItem\"\n [siLink]=\"item\"\n [exactMatch]=\"true\"\n [attr.aria-label]=\"item.title\"\n [attr.aria-disabled]=\"!item.link && !item.href && !item.action\"\n >\n @if (item.level === 0) {\n <si-icon class=\"d-block icon-sm flip-rtl\" [icon]=\"icons.elementBreadcrumbRoot\" />\n } @else {\n <span>{{ item.title }}</span>\n }\n </a>\n</ng-template>\n\n<ng-template #toggleTemplate let-item=\"item\" let-title=\"title\" siBreadcrumbItemTemplate>\n <
|
|
273
|
+
], changeDetection: ChangeDetectionStrategy.Eager, template: "<nav class=\"py-2\" [attr.aria-label]=\"ariaLabel() | translate\">\n <ol #breadcrumb class=\"breadcrumb\" (siResizeObserver)=\"resetBreadcrumb()\">\n @for (item of itemsShown; track $index; let isFirst = $first) {\n @if (!breadcrumbShortened || item.level !== ellipsesLevel) {\n @if (item.shortened) {\n <li #breadcrumbItem class=\"item text-nowrap shortened\">\n @if (!isFirst) {\n <si-icon class=\"d-block separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <div class=\"breadcrumb-dropdown-wrapper\">\n <ng-container\n *ngTemplateOutlet=\"\n toggleTemplate;\n context: { item: item, title: item.shortenedTitle }\n \"\n />\n @if (addExpandDropdown) {\n <div\n class=\"dropdown-menu\"\n role=\"menu\"\n [id]=\"controlId + item.level\"\n [class.show]=\"breadcrumbDropdownOpen === item.level\"\n >\n <ng-container *ngTemplateOutlet=\"dropdownTemplate; context: { item: item }\" />\n </div>\n }\n </div>\n </li>\n } @else {\n <li #breadcrumbItem class=\"item\">\n @if (!isFirst) {\n <si-icon class=\"d-block icon-sm separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <ng-container *ngTemplateOutlet=\"itemTemplate; context: { item: item }\" />\n </li>\n }\n }\n @if (breadcrumbShortened && item.level === ellipsesLevel) {\n <li class=\"item breadcrumb-ellipses-item\">\n @if (!isFirst) {\n <si-icon class=\"d-block icon-sm separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <div class=\"breadcrumb-dropdown-wrapper\">\n <ng-container *ngTemplateOutlet=\"toggleTemplate; context: { item: item, title: '' }\" />\n <div\n class=\"dropdown-menu\"\n role=\"menu\"\n [id]=\"controlId + item.level\"\n [class.show]=\"breadcrumbDropdownOpen === item.level\"\n >\n @for (item of itemsHidden; track $index) {\n <ng-container *ngTemplateOutlet=\"dropdownTemplate; context: { item: item }\" />\n }\n </div>\n </div>\n </li>\n }\n }\n </ol>\n</nav>\n\n<ng-template #itemTemplate let-item=\"item\" siBreadcrumbItemTemplate>\n <a\n class=\"breadcrumb-link text-nowrap\"\n activeClass=\"active\"\n ariaCurrent=\"page\"\n [class.disable-router-link]=\"!item.link && !item.action && !item.href\"\n [class.text-secondary]=\"item.lastItem\"\n [siLink]=\"item\"\n [exactMatch]=\"true\"\n [attr.aria-label]=\"item.title\"\n [attr.aria-disabled]=\"!item.link && !item.href && !item.action\"\n >\n @if (item.level === 0) {\n <si-icon class=\"d-block icon-sm flip-rtl\" [icon]=\"icons.elementBreadcrumbRoot\" />\n } @else {\n <span>{{ item.title }}</span>\n }\n </a>\n</ng-template>\n\n<ng-template #toggleTemplate let-item=\"item\" let-title=\"title\" siBreadcrumbItemTemplate>\n <button\n type=\"button\"\n class=\"btn btn-link\"\n aria-haspopup=\"true\"\n [attr.aria-controls]=\"controlId + item.level\"\n [attr.aria-expanded]=\"breadcrumbDropdownOpen === item.level\"\n (click)=\"toggleBreadcrumbDropdown(item.level)\"\n >{{ title }}...</button\n >\n</ng-template>\n\n<ng-template #dropdownTemplate let-item=\"item\" siBreadcrumbItemTemplate>\n <a\n class=\"dropdown-item breadcrumb-link focus-inside\"\n activeClass=\"active\"\n ariaCurrent=\"page\"\n role=\"menuitem\"\n [class.disable-router-link]=\"!item.link && !item.action && !item.href\"\n [siLink]=\"item\"\n [exactMatch]=\"true\"\n [attr.aria-disabled]=\"!item.link && !item.action && !item.href\"\n >{{ item.title }}</a\n >\n</ng-template>\n", styles: [".breadcrumb{flex-wrap:nowrap}.item{display:flex;align-items:center}.separator{color:var(--si-sys-text-secondary);margin-block:0;margin-inline:0}.disable-router-link,.disable-router-link:hover{pointer-events:none;color:var(--si-sys-text-disabled)}\n"] }]
|
|
274
274
|
}], propDecorators: { items: [{ type: i0.Input, args: [{ isSignal: true, alias: "items", required: true }] }], showRootAsText: [{ type: i0.Input, args: [{ isSignal: true, alias: "showRootAsText", required: false }] }], ariaLabel: [{ type: i0.Input, args: [{ isSignal: true, alias: "ariaLabel", required: false }] }], breadcrumbElement: [{ type: i0.ViewChild, args: ['breadcrumb', { isSignal: true }] }], breadcrumbElements: [{ type: i0.ViewChildren, args: ['breadcrumbItem', { isSignal: true }] }], documentClick: [{
|
|
275
275
|
type: HostListener,
|
|
276
276
|
args: ['document:click', ['$event.target']]
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"siemens-element-ng-breadcrumb.mjs","sources":["../../../../projects/element-ng/breadcrumb/si-breadcrumb-item-template.directive.ts","../../../../projects/element-ng/breadcrumb/si-breadcrumb.component.ts","../../../../projects/element-ng/breadcrumb/si-breadcrumb.component.html","../../../../projects/element-ng/breadcrumb/si-breadcrumb.module.ts","../../../../projects/element-ng/breadcrumb/index.ts","../../../../projects/element-ng/breadcrumb/siemens-element-ng-breadcrumb.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { Directive } from '@angular/core';\n\nimport { EnumeratedBreadcrumbItem } from './breadcrumb-item.model';\n\n@Directive({ selector: '[siBreadcrumbItemTemplate]' })\nexport class SiBreadcrumbItemTemplateDirective {\n static ngTemplateContextGuard(\n directive: SiBreadcrumbItemTemplateDirective,\n context: unknown\n ): context is { item: EnumeratedBreadcrumbItem; title?: string } {\n return true;\n }\n}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { NgTemplateOutlet } from '@angular/common';\nimport {\n booleanAttribute,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n HostListener,\n inject,\n input,\n OnChanges,\n OnDestroy,\n viewChild,\n viewChildren\n} from '@angular/core';\nimport { elementBreadcrumbRoot, elementRight2 } from '@siemens/element-icons';\nimport { addIcons, SiIconComponent } from '@siemens/element-ng/icon';\nimport { SiLinkDirective } from '@siemens/element-ng/link';\nimport { SiResizeObserverDirective } from '@siemens/element-ng/resize-observer';\nimport {\n injectSiTranslateService,\n SiTranslatePipe,\n t\n} from '@siemens/element-translate-ng/translate';\nimport { merge, of, Subscription } from 'rxjs';\nimport { switchMap } from 'rxjs/operators';\n\nimport { BreadcrumbItem, EnumeratedBreadcrumbItem } from './breadcrumb-item.model';\nimport { SiBreadcrumbItemTemplateDirective } from './si-breadcrumb-item-template.directive';\n\n/**\n * Defines how many items should be displayed at the end of the breadcrumb if possible.\n */\nconst NUMBER_OF_SHOWN_ITEMS_AT_END = 2;\n\n/**\n * Defines how long a display item can be without it being shortened.\n * Cannot be lower than 4.\n * If this is 0, titles will not be shortened\n */\nconst ITEM_MAX_LENGTH = 30;\n\n/**\n * Defines how many characters of an item are always displayed in the beginning.\n * Must be at least 2 less than ITEM_MAX_LENGTH\n */\nconst ITEM_CHARACTERS_ALWAYS_DISPLAYED_IN_BEGINNING = 10;\n\n/**\n * Defines the width of the root icon in pixels.\n */\nconst ROOT_ICON_WIDTH = 24;\n\nlet controlIdCounter = 1;\n\n@Component({\n selector: 'si-breadcrumb',\n imports: [\n NgTemplateOutlet,\n SiIconComponent,\n SiLinkDirective,\n SiResizeObserverDirective,\n SiTranslatePipe,\n SiBreadcrumbItemTemplateDirective\n ],\n templateUrl: './si-breadcrumb.component.html',\n styleUrl: './si-breadcrumb.component.scss',\n changeDetection: ChangeDetectionStrategy.Eager\n})\nexport class SiBreadcrumbComponent implements OnChanges, OnDestroy {\n /** Array of breadcrumb items. */\n readonly items = input.required<BreadcrumbItem[]>();\n /**\n * Shows the \"root\" route as the provided title string instead of an icon.\n *\n * @defaultValue false\n */\n readonly showRootAsText = input(false, { transform: booleanAttribute });\n /**\n * Aria label for the main breadcrumb navigation. Needed for a11y.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_BREADCRUMB:Breadcrumb navigation`)\n * ```\n */\n readonly ariaLabel = input(t(() => $localize`:@@SI_BREADCRUMB:Breadcrumb navigation`));\n\n private translationSubscription?: Subscription;\n private itemsProcessed = false;\n private numberOfItems = 0;\n\n protected itemsShown: EnumeratedBreadcrumbItem[] = [];\n protected itemsHidden: EnumeratedBreadcrumbItem[] = [];\n protected breadcrumbShortened = false;\n protected ellipsesLevel = 0;\n // Record to allow for -1 (root).\n protected breadcrumbDropdownOpen: number | undefined = undefined;\n protected addExpandDropdown = false;\n protected controlId = `__si-breadcrumb-${controlIdCounter++}-`;\n protected readonly icons = addIcons({ elementBreadcrumbRoot, elementRight2 });\n\n private readonly breadcrumbElement = viewChild.required<ElementRef>('breadcrumb');\n private readonly breadcrumbElements = viewChildren<ElementRef>('breadcrumbItem');\n\n private changeDetector = inject(ChangeDetectorRef);\n private translate = injectSiTranslateService();\n\n ngOnChanges(): void {\n // Reprocess items on every change and on init\n this.processItems();\n }\n\n ngOnDestroy(): void {\n this.translationSubscription?.unsubscribe();\n }\n\n private processItems(): void {\n this.numberOfItems = this.items().length;\n\n this.translationSubscription?.unsubscribe();\n if (this.numberOfItems) {\n this.translationSubscription = merge(this.translate.translationChange, of(undefined))\n .pipe(switchMap(() => this.translate.translateAsync(this.items().map(item => item.title))))\n .subscribe(translatedTitles => {\n // Add the level to the items and check if they need to be shortened.\n // If they need to be shortened, shorten them at a convenient place.\n // Set the lastItem tag to true for the last item\n let counter = -1;\n const enumeratedItems = this.items().map(item => {\n counter++;\n const title = translatedTitles[item.title];\n let shortened = false;\n let shortenedTitle = title;\n // If this is not the last item and the title too long, shorten the title\n if (counter !== this.numberOfItems - 1 && title && title.length > ITEM_MAX_LENGTH) {\n shortened = true;\n // This regex gets the last space, dash or underscore.\n const regexMatch = title\n .slice(ITEM_CHARACTERS_ALWAYS_DISPLAYED_IN_BEGINNING, ITEM_MAX_LENGTH - 2)\n .match(/^.*[- _](?=.*?$)/);\n if (regexMatch) {\n shortenedTitle = title.slice(\n 0,\n ITEM_CHARACTERS_ALWAYS_DISPLAYED_IN_BEGINNING + regexMatch[0].length - 1\n );\n } else {\n shortenedTitle = title.slice(0, ITEM_MAX_LENGTH - 3);\n }\n }\n\n // If the root element should be displayed as text, set level not to 0.\n // This is used to distinguish in the template between icon and text.\n const level = counter === 0 && this.showRootAsText() ? -1 : counter;\n\n return {\n ...item,\n title,\n level,\n hide: false,\n shortened,\n shortenedTitle,\n lastItem: counter === this.numberOfItems - 1\n };\n });\n this.itemsShown = enumeratedItems;\n this.itemsHidden = [];\n this.breadcrumbShortened = false;\n this.breadcrumbDropdownOpen = undefined;\n this.itemsProcessed = true;\n this.resetBreadcrumb();\n });\n } else {\n this.itemsShown = [];\n this.itemsHidden = [];\n this.breadcrumbShortened = false;\n this.breadcrumbDropdownOpen = undefined;\n this.itemsProcessed = true;\n this.resetBreadcrumb();\n }\n }\n\n /*\n * Toggle dropdown (on click of ellipses), either for\n * the general dropdown list if itemLevel is at ellipsesLevel\n * or otherwise the name expansion at the specified item level.\n * Close any open dropdown before opening a new one.\n */\n protected toggleBreadcrumbDropdown(itemLevel: number): void {\n this.breadcrumbDropdownOpen = this.breadcrumbDropdownOpen === itemLevel ? undefined : itemLevel;\n }\n\n // Close dropdown on click anywhere else\n @HostListener('document:click', ['$event.target'])\n protected documentClick(targetElement: any): void {\n if (this.breadcrumbDropdownOpen) {\n if (!this.breadcrumbElement().nativeElement.contains(targetElement)) {\n // Close all dropdowns.\n this.breadcrumbDropdownOpen = undefined;\n }\n }\n }\n\n protected resetBreadcrumb(): void {\n if (this.itemsProcessed) {\n this.numberOfItems = this.items().length;\n // Add an additional the ellipses item to the end of the shownItems (breadcrumb items).\n // Disable addExpandDropdown for now, to make every item a proper SiBreadcrumbItemComponent.\n const ellipsesItem = { title: '...', level: this.numberOfItems, shortenedTitle: '' };\n this.itemsShown.push(ellipsesItem);\n if (this.breadcrumbShortened) {\n // If the breadcrumb was shortened before, remove the ellipses and add back itemsHidden (breadcrumb dropdown items).\n this.breadcrumbShortened = false;\n this.itemsShown.splice(this.ellipsesLevel, 1, ...this.itemsHidden);\n this.itemsHidden = [];\n }\n this.addExpandDropdown = false;\n // Wait for the next change detection cycle to measure the updated item length.\n this.changeDetector.detectChanges();\n this.calculateBreadcrumb();\n }\n }\n\n private calculateBreadcrumb(): void {\n this.addExpandDropdown = true;\n const maxWidth = this.breadcrumbElement().nativeElement.clientWidth;\n const breadcrumbElementsList = this.breadcrumbElements().map(item => item);\n // Measure the length of the last additional ellipses item, then remove it from itemsShown (breadcrumb items).\n const ellipsesWidth = breadcrumbElementsList[this.numberOfItems].nativeElement.offsetWidth;\n this.itemsShown.splice(this.numberOfItems, 1);\n let currentWidth = this.showRootAsText() ? 0 : ROOT_ICON_WIDTH;\n const numberOfItemsKeptAtEnd = Math.min(NUMBER_OF_SHOWN_ITEMS_AT_END, this.numberOfItems - 1);\n let reverseCounter = this.numberOfItems;\n // Test for numberOfItemsKeptAtEnd items from the end if they still fit, if not, set breadcrumbShortened to true.\n breadcrumbElementsList\n .slice(this.numberOfItems - numberOfItemsKeptAtEnd, this.numberOfItems)\n .reverse()\n .map(item => {\n if (!this.breadcrumbShortened) {\n const currentItemWidth = item.nativeElement.offsetWidth;\n if (currentWidth + currentItemWidth > maxWidth) {\n this.breadcrumbShortened = true;\n // Test if the ellipses item still fits, if not remove last (actually next in original order) item as well.\n if (currentWidth + ellipsesWidth > maxWidth) {\n reverseCounter++;\n }\n } else {\n currentWidth += currentItemWidth;\n reverseCounter--;\n }\n }\n });\n\n const start = this.showRootAsText() ? 0 : 1;\n let counter = start;\n // If breadcrumbShortened is not true yet, test for the rest of the items from the start\n // Whether they still fit, if not, set breadcrumbShortened to true.\n breadcrumbElementsList.slice(start, this.numberOfItems - numberOfItemsKeptAtEnd).map(item => {\n if (!this.breadcrumbShortened) {\n const currentItemWidth = item.nativeElement.offsetWidth;\n if (currentWidth + currentItemWidth > maxWidth) {\n this.breadcrumbShortened = true;\n // Test if the ellipses item still fits, if not remove last item as well.\n // If the counter is still on 1, instead remove last (actually next in original order) from\n // the previous reverse calculation\n if (currentWidth + ellipsesWidth > maxWidth) {\n if (counter > 1) {\n counter--;\n } else {\n reverseCounter++;\n }\n }\n } else {\n currentWidth += currentItemWidth;\n counter++;\n }\n }\n });\n // If breadcrumbShortened is true, move the items that do not fit to itemsHidden (breadcrumb dropdown items) and add ellipses item.\n if (this.breadcrumbShortened) {\n this.ellipsesLevel = counter;\n this.itemsHidden = this.itemsShown.slice(this.ellipsesLevel, reverseCounter);\n const ellipsesItem = { title: '...', level: this.ellipsesLevel, shortenedTitle: '' };\n this.itemsShown.splice(this.ellipsesLevel, reverseCounter - this.ellipsesLevel, ellipsesItem);\n }\n // Manually detect changes to prevent them from not being detected on language change\n this.changeDetector.detectChanges();\n }\n}\n","<nav class=\"py-2\" [attr.aria-label]=\"ariaLabel() | translate\">\n <ol #breadcrumb class=\"breadcrumb\" (siResizeObserver)=\"resetBreadcrumb()\">\n @for (item of itemsShown; track $index; let isFirst = $first) {\n @if (!breadcrumbShortened || item.level !== ellipsesLevel) {\n @if (item.shortened) {\n <li #breadcrumbItem class=\"item text-nowrap shortened\">\n @if (!isFirst) {\n <si-icon class=\"d-block separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <div class=\"breadcrumb-dropdown-wrapper\">\n <ng-container\n *ngTemplateOutlet=\"\n toggleTemplate;\n context: { item: item, title: item.shortenedTitle }\n \"\n />\n @if (addExpandDropdown) {\n <div\n class=\"dropdown-menu\"\n role=\"menu\"\n [id]=\"controlId + item.level\"\n [class.show]=\"breadcrumbDropdownOpen === item.level\"\n >\n <ng-container *ngTemplateOutlet=\"dropdownTemplate; context: { item: item }\" />\n </div>\n }\n </div>\n </li>\n } @else {\n <li #breadcrumbItem class=\"item\">\n @if (!isFirst) {\n <si-icon class=\"d-block icon-sm separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <ng-container *ngTemplateOutlet=\"itemTemplate; context: { item: item }\" />\n </li>\n }\n }\n @if (breadcrumbShortened && item.level === ellipsesLevel) {\n <li class=\"item breadcrumb-ellipses-item\">\n @if (!isFirst) {\n <si-icon class=\"d-block icon-sm separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <div class=\"breadcrumb-dropdown-wrapper\">\n <ng-container *ngTemplateOutlet=\"toggleTemplate; context: { item: item, title: '' }\" />\n <div\n class=\"dropdown-menu\"\n role=\"menu\"\n [id]=\"controlId + item.level\"\n [class.show]=\"breadcrumbDropdownOpen === item.level\"\n >\n @for (item of itemsHidden; track $index) {\n <ng-container *ngTemplateOutlet=\"dropdownTemplate; context: { item: item }\" />\n }\n </div>\n </div>\n </li>\n }\n }\n </ol>\n</nav>\n\n<ng-template #itemTemplate let-item=\"item\" siBreadcrumbItemTemplate>\n <a\n class=\"breadcrumb-link text-nowrap\"\n activeClass=\"active\"\n ariaCurrent=\"page\"\n [class.disable-router-link]=\"!item.link && !item.action && !item.href\"\n [class.text-secondary]=\"item.lastItem\"\n [siLink]=\"item\"\n [exactMatch]=\"true\"\n [attr.aria-label]=\"item.title\"\n [attr.aria-disabled]=\"!item.link && !item.href && !item.action\"\n >\n @if (item.level === 0) {\n <si-icon class=\"d-block icon-sm flip-rtl\" [icon]=\"icons.elementBreadcrumbRoot\" />\n } @else {\n <span>{{ item.title }}</span>\n }\n </a>\n</ng-template>\n\n<ng-template #toggleTemplate let-item=\"item\" let-title=\"title\" siBreadcrumbItemTemplate>\n <div\n class=\"breadcrumb-dropdown-toggle link\"\n role=\"button\"\n aria-haspopup=\"true\"\n tabindex=\"0\"\n [attr.aria-controls]=\"controlId + item.level\"\n [attr.aria-expanded]=\"breadcrumbDropdownOpen === item.level\"\n (keydown.enter)=\"toggleBreadcrumbDropdown(item.level)\"\n (click)=\"toggleBreadcrumbDropdown(item.level)\"\n >{{ title }}...</div\n >\n</ng-template>\n\n<ng-template #dropdownTemplate let-item=\"item\" siBreadcrumbItemTemplate>\n <a\n class=\"dropdown-item breadcrumb-link focus-inside\"\n activeClass=\"active\"\n ariaCurrent=\"page\"\n role=\"menuitem\"\n [class.disable-router-link]=\"!item.link && !item.action && !item.href\"\n [siLink]=\"item\"\n [exactMatch]=\"true\"\n [attr.aria-disabled]=\"!item.link && !item.action && !item.href\"\n >{{ item.title }}</a\n >\n</ng-template>\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { NgModule } from '@angular/core';\n\nimport { SiBreadcrumbComponent } from './si-breadcrumb.component';\n\n@NgModule({\n imports: [SiBreadcrumbComponent],\n exports: [SiBreadcrumbComponent]\n})\nexport class SiBreadcrumbModule {}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nexport * from './breadcrumb-item.model';\nexport * from './si-breadcrumb.component';\nexport * from './si-breadcrumb.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;AAAA;;;AAGG;MAMU,iCAAiC,CAAA;AAC5C,IAAA,OAAO,sBAAsB,CAC3B,SAA4C,EAC5C,OAAgB,EAAA;AAEhB,QAAA,OAAO,IAAI;IACb;uGANW,iCAAiC,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;2FAAjC,iCAAiC,EAAA,YAAA,EAAA,IAAA,EAAA,QAAA,EAAA,4BAAA,EAAA,QAAA,EAAA,EAAA,EAAA,CAAA;;2FAAjC,iCAAiC,EAAA,UAAA,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A,KAAA,EAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,IAAA,EAAA,KAAA,EAAA,WAAA,EAAA,QAAA,EAAA,KAAA,EAAA,CAAA,EAAA,CAAA,EAAA,iBAAA,EAAA,CAAA,EAAA,IAAA,EAAA,EAAA,CAAA,SAAA,EAAA,IAAA,EAAA,CAAA,YAAY,+EACjB,gBAAgB,EAAA,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA,EAAA,CAAA,EAAA,aAAA,EAAA,CAAA;sBA0F9E,YAAY;uBAAC,gBAAgB,EAAE,CAAC,eAAe,CAAC;;;AErMnD;;;AAGG;MASU,kBAAkB,CAAA;uGAAlB,kBAAkB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,QAAA,EAAA,CAAA;wGAAlB,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-breadcrumb.mjs","sources":["../../../../projects/element-ng/breadcrumb/si-breadcrumb-item-template.directive.ts","../../../../projects/element-ng/breadcrumb/si-breadcrumb.component.ts","../../../../projects/element-ng/breadcrumb/si-breadcrumb.component.html","../../../../projects/element-ng/breadcrumb/si-breadcrumb.module.ts","../../../../projects/element-ng/breadcrumb/index.ts","../../../../projects/element-ng/breadcrumb/siemens-element-ng-breadcrumb.ts"],"sourcesContent":["/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { Directive } from '@angular/core';\n\nimport { EnumeratedBreadcrumbItem } from './breadcrumb-item.model';\n\n@Directive({ selector: '[siBreadcrumbItemTemplate]' })\nexport class SiBreadcrumbItemTemplateDirective {\n static ngTemplateContextGuard(\n directive: SiBreadcrumbItemTemplateDirective,\n context: unknown\n ): context is { item: EnumeratedBreadcrumbItem; title?: string } {\n return true;\n }\n}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { NgTemplateOutlet } from '@angular/common';\nimport {\n booleanAttribute,\n ChangeDetectionStrategy,\n ChangeDetectorRef,\n Component,\n ElementRef,\n HostListener,\n inject,\n input,\n OnChanges,\n OnDestroy,\n viewChild,\n viewChildren\n} from '@angular/core';\nimport { elementBreadcrumbRoot, elementRight2 } from '@siemens/element-icons';\nimport { addIcons, SiIconComponent } from '@siemens/element-ng/icon';\nimport { SiLinkDirective } from '@siemens/element-ng/link';\nimport { SiResizeObserverDirective } from '@siemens/element-ng/resize-observer';\nimport {\n injectSiTranslateService,\n SiTranslatePipe,\n t\n} from '@siemens/element-translate-ng/translate';\nimport { merge, of, Subscription } from 'rxjs';\nimport { switchMap } from 'rxjs/operators';\n\nimport { BreadcrumbItem, EnumeratedBreadcrumbItem } from './breadcrumb-item.model';\nimport { SiBreadcrumbItemTemplateDirective } from './si-breadcrumb-item-template.directive';\n\n/**\n * Defines how many items should be displayed at the end of the breadcrumb if possible.\n */\nconst NUMBER_OF_SHOWN_ITEMS_AT_END = 2;\n\n/**\n * Defines how long a display item can be without it being shortened.\n * Cannot be lower than 4.\n * If this is 0, titles will not be shortened\n */\nconst ITEM_MAX_LENGTH = 30;\n\n/**\n * Defines how many characters of an item are always displayed in the beginning.\n * Must be at least 2 less than ITEM_MAX_LENGTH\n */\nconst ITEM_CHARACTERS_ALWAYS_DISPLAYED_IN_BEGINNING = 10;\n\n/**\n * Defines the width of the root icon in pixels.\n */\nconst ROOT_ICON_WIDTH = 24;\n\nlet controlIdCounter = 1;\n\n@Component({\n selector: 'si-breadcrumb',\n imports: [\n NgTemplateOutlet,\n SiIconComponent,\n SiLinkDirective,\n SiResizeObserverDirective,\n SiTranslatePipe,\n SiBreadcrumbItemTemplateDirective\n ],\n templateUrl: './si-breadcrumb.component.html',\n styleUrl: './si-breadcrumb.component.scss',\n changeDetection: ChangeDetectionStrategy.Eager\n})\nexport class SiBreadcrumbComponent implements OnChanges, OnDestroy {\n /** Array of breadcrumb items. */\n readonly items = input.required<BreadcrumbItem[]>();\n /**\n * Shows the \"root\" route as the provided title string instead of an icon.\n *\n * @defaultValue false\n */\n readonly showRootAsText = input(false, { transform: booleanAttribute });\n /**\n * Aria label for the main breadcrumb navigation. Needed for a11y.\n *\n * @defaultValue\n * ```\n * t(() => $localize`:@@SI_BREADCRUMB:Breadcrumb navigation`)\n * ```\n */\n readonly ariaLabel = input(t(() => $localize`:@@SI_BREADCRUMB:Breadcrumb navigation`));\n\n private translationSubscription?: Subscription;\n private itemsProcessed = false;\n private numberOfItems = 0;\n\n protected itemsShown: EnumeratedBreadcrumbItem[] = [];\n protected itemsHidden: EnumeratedBreadcrumbItem[] = [];\n protected breadcrumbShortened = false;\n protected ellipsesLevel = 0;\n // Record to allow for -1 (root).\n protected breadcrumbDropdownOpen: number | undefined = undefined;\n protected addExpandDropdown = false;\n protected controlId = `__si-breadcrumb-${controlIdCounter++}-`;\n protected readonly icons = addIcons({ elementBreadcrumbRoot, elementRight2 });\n\n private readonly breadcrumbElement = viewChild.required<ElementRef>('breadcrumb');\n private readonly breadcrumbElements = viewChildren<ElementRef>('breadcrumbItem');\n\n private changeDetector = inject(ChangeDetectorRef);\n private translate = injectSiTranslateService();\n\n ngOnChanges(): void {\n // Reprocess items on every change and on init\n this.processItems();\n }\n\n ngOnDestroy(): void {\n this.translationSubscription?.unsubscribe();\n }\n\n private processItems(): void {\n this.numberOfItems = this.items().length;\n\n this.translationSubscription?.unsubscribe();\n if (this.numberOfItems) {\n this.translationSubscription = merge(this.translate.translationChange, of(undefined))\n .pipe(switchMap(() => this.translate.translateAsync(this.items().map(item => item.title))))\n .subscribe(translatedTitles => {\n // Add the level to the items and check if they need to be shortened.\n // If they need to be shortened, shorten them at a convenient place.\n // Set the lastItem tag to true for the last item\n let counter = -1;\n const enumeratedItems = this.items().map(item => {\n counter++;\n const title = translatedTitles[item.title];\n let shortened = false;\n let shortenedTitle = title;\n // If this is not the last item and the title too long, shorten the title\n if (counter !== this.numberOfItems - 1 && title && title.length > ITEM_MAX_LENGTH) {\n shortened = true;\n // This regex gets the last space, dash or underscore.\n const regexMatch = title\n .slice(ITEM_CHARACTERS_ALWAYS_DISPLAYED_IN_BEGINNING, ITEM_MAX_LENGTH - 2)\n .match(/^.*[- _](?=.*?$)/);\n if (regexMatch) {\n shortenedTitle = title.slice(\n 0,\n ITEM_CHARACTERS_ALWAYS_DISPLAYED_IN_BEGINNING + regexMatch[0].length - 1\n );\n } else {\n shortenedTitle = title.slice(0, ITEM_MAX_LENGTH - 3);\n }\n }\n\n // If the root element should be displayed as text, set level not to 0.\n // This is used to distinguish in the template between icon and text.\n const level = counter === 0 && this.showRootAsText() ? -1 : counter;\n\n return {\n ...item,\n title,\n level,\n hide: false,\n shortened,\n shortenedTitle,\n lastItem: counter === this.numberOfItems - 1\n };\n });\n this.itemsShown = enumeratedItems;\n this.itemsHidden = [];\n this.breadcrumbShortened = false;\n this.breadcrumbDropdownOpen = undefined;\n this.itemsProcessed = true;\n this.resetBreadcrumb();\n });\n } else {\n this.itemsShown = [];\n this.itemsHidden = [];\n this.breadcrumbShortened = false;\n this.breadcrumbDropdownOpen = undefined;\n this.itemsProcessed = true;\n this.resetBreadcrumb();\n }\n }\n\n /*\n * Toggle dropdown (on click of ellipses), either for\n * the general dropdown list if itemLevel is at ellipsesLevel\n * or otherwise the name expansion at the specified item level.\n * Close any open dropdown before opening a new one.\n */\n protected toggleBreadcrumbDropdown(itemLevel: number): void {\n this.breadcrumbDropdownOpen = this.breadcrumbDropdownOpen === itemLevel ? undefined : itemLevel;\n }\n\n // Close dropdown on click anywhere else\n @HostListener('document:click', ['$event.target'])\n protected documentClick(targetElement: any): void {\n if (this.breadcrumbDropdownOpen) {\n if (!this.breadcrumbElement().nativeElement.contains(targetElement)) {\n // Close all dropdowns.\n this.breadcrumbDropdownOpen = undefined;\n }\n }\n }\n\n protected resetBreadcrumb(): void {\n if (this.itemsProcessed) {\n this.numberOfItems = this.items().length;\n // Add an additional the ellipses item to the end of the shownItems (breadcrumb items).\n // Disable addExpandDropdown for now, to make every item a proper SiBreadcrumbItemComponent.\n const ellipsesItem = { title: '...', level: this.numberOfItems, shortenedTitle: '' };\n this.itemsShown.push(ellipsesItem);\n if (this.breadcrumbShortened) {\n // If the breadcrumb was shortened before, remove the ellipses and add back itemsHidden (breadcrumb dropdown items).\n this.breadcrumbShortened = false;\n this.itemsShown.splice(this.ellipsesLevel, 1, ...this.itemsHidden);\n this.itemsHidden = [];\n }\n this.addExpandDropdown = false;\n // Wait for the next change detection cycle to measure the updated item length.\n this.changeDetector.detectChanges();\n this.calculateBreadcrumb();\n }\n }\n\n private calculateBreadcrumb(): void {\n this.addExpandDropdown = true;\n const maxWidth = this.breadcrumbElement().nativeElement.clientWidth;\n const breadcrumbElementsList = this.breadcrumbElements().map(item => item);\n // Measure the length of the last additional ellipses item, then remove it from itemsShown (breadcrumb items).\n const ellipsesWidth = breadcrumbElementsList[this.numberOfItems].nativeElement.offsetWidth;\n this.itemsShown.splice(this.numberOfItems, 1);\n let currentWidth = this.showRootAsText() ? 0 : ROOT_ICON_WIDTH;\n const numberOfItemsKeptAtEnd = Math.min(NUMBER_OF_SHOWN_ITEMS_AT_END, this.numberOfItems - 1);\n let reverseCounter = this.numberOfItems;\n // Test for numberOfItemsKeptAtEnd items from the end if they still fit, if not, set breadcrumbShortened to true.\n breadcrumbElementsList\n .slice(this.numberOfItems - numberOfItemsKeptAtEnd, this.numberOfItems)\n .reverse()\n .map(item => {\n if (!this.breadcrumbShortened) {\n const currentItemWidth = item.nativeElement.offsetWidth;\n if (currentWidth + currentItemWidth > maxWidth) {\n this.breadcrumbShortened = true;\n // Test if the ellipses item still fits, if not remove last (actually next in original order) item as well.\n if (currentWidth + ellipsesWidth > maxWidth) {\n reverseCounter++;\n }\n } else {\n currentWidth += currentItemWidth;\n reverseCounter--;\n }\n }\n });\n\n const start = this.showRootAsText() ? 0 : 1;\n let counter = start;\n // If breadcrumbShortened is not true yet, test for the rest of the items from the start\n // Whether they still fit, if not, set breadcrumbShortened to true.\n breadcrumbElementsList.slice(start, this.numberOfItems - numberOfItemsKeptAtEnd).map(item => {\n if (!this.breadcrumbShortened) {\n const currentItemWidth = item.nativeElement.offsetWidth;\n if (currentWidth + currentItemWidth > maxWidth) {\n this.breadcrumbShortened = true;\n // Test if the ellipses item still fits, if not remove last item as well.\n // If the counter is still on 1, instead remove last (actually next in original order) from\n // the previous reverse calculation\n if (currentWidth + ellipsesWidth > maxWidth) {\n if (counter > 1) {\n counter--;\n } else {\n reverseCounter++;\n }\n }\n } else {\n currentWidth += currentItemWidth;\n counter++;\n }\n }\n });\n // If breadcrumbShortened is true, move the items that do not fit to itemsHidden (breadcrumb dropdown items) and add ellipses item.\n if (this.breadcrumbShortened) {\n this.ellipsesLevel = counter;\n this.itemsHidden = this.itemsShown.slice(this.ellipsesLevel, reverseCounter);\n const ellipsesItem = { title: '...', level: this.ellipsesLevel, shortenedTitle: '' };\n this.itemsShown.splice(this.ellipsesLevel, reverseCounter - this.ellipsesLevel, ellipsesItem);\n }\n // Manually detect changes to prevent them from not being detected on language change\n this.changeDetector.detectChanges();\n }\n}\n","<nav class=\"py-2\" [attr.aria-label]=\"ariaLabel() | translate\">\n <ol #breadcrumb class=\"breadcrumb\" (siResizeObserver)=\"resetBreadcrumb()\">\n @for (item of itemsShown; track $index; let isFirst = $first) {\n @if (!breadcrumbShortened || item.level !== ellipsesLevel) {\n @if (item.shortened) {\n <li #breadcrumbItem class=\"item text-nowrap shortened\">\n @if (!isFirst) {\n <si-icon class=\"d-block separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <div class=\"breadcrumb-dropdown-wrapper\">\n <ng-container\n *ngTemplateOutlet=\"\n toggleTemplate;\n context: { item: item, title: item.shortenedTitle }\n \"\n />\n @if (addExpandDropdown) {\n <div\n class=\"dropdown-menu\"\n role=\"menu\"\n [id]=\"controlId + item.level\"\n [class.show]=\"breadcrumbDropdownOpen === item.level\"\n >\n <ng-container *ngTemplateOutlet=\"dropdownTemplate; context: { item: item }\" />\n </div>\n }\n </div>\n </li>\n } @else {\n <li #breadcrumbItem class=\"item\">\n @if (!isFirst) {\n <si-icon class=\"d-block icon-sm separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <ng-container *ngTemplateOutlet=\"itemTemplate; context: { item: item }\" />\n </li>\n }\n }\n @if (breadcrumbShortened && item.level === ellipsesLevel) {\n <li class=\"item breadcrumb-ellipses-item\">\n @if (!isFirst) {\n <si-icon class=\"d-block icon-sm separator flip-rtl\" [icon]=\"icons.elementRight2\" />\n }\n <div class=\"breadcrumb-dropdown-wrapper\">\n <ng-container *ngTemplateOutlet=\"toggleTemplate; context: { item: item, title: '' }\" />\n <div\n class=\"dropdown-menu\"\n role=\"menu\"\n [id]=\"controlId + item.level\"\n [class.show]=\"breadcrumbDropdownOpen === item.level\"\n >\n @for (item of itemsHidden; track $index) {\n <ng-container *ngTemplateOutlet=\"dropdownTemplate; context: { item: item }\" />\n }\n </div>\n </div>\n </li>\n }\n }\n </ol>\n</nav>\n\n<ng-template #itemTemplate let-item=\"item\" siBreadcrumbItemTemplate>\n <a\n class=\"breadcrumb-link text-nowrap\"\n activeClass=\"active\"\n ariaCurrent=\"page\"\n [class.disable-router-link]=\"!item.link && !item.action && !item.href\"\n [class.text-secondary]=\"item.lastItem\"\n [siLink]=\"item\"\n [exactMatch]=\"true\"\n [attr.aria-label]=\"item.title\"\n [attr.aria-disabled]=\"!item.link && !item.href && !item.action\"\n >\n @if (item.level === 0) {\n <si-icon class=\"d-block icon-sm flip-rtl\" [icon]=\"icons.elementBreadcrumbRoot\" />\n } @else {\n <span>{{ item.title }}</span>\n }\n </a>\n</ng-template>\n\n<ng-template #toggleTemplate let-item=\"item\" let-title=\"title\" siBreadcrumbItemTemplate>\n <button\n type=\"button\"\n class=\"btn btn-link\"\n aria-haspopup=\"true\"\n [attr.aria-controls]=\"controlId + item.level\"\n [attr.aria-expanded]=\"breadcrumbDropdownOpen === item.level\"\n (click)=\"toggleBreadcrumbDropdown(item.level)\"\n >{{ title }}...</button\n >\n</ng-template>\n\n<ng-template #dropdownTemplate let-item=\"item\" siBreadcrumbItemTemplate>\n <a\n class=\"dropdown-item breadcrumb-link focus-inside\"\n activeClass=\"active\"\n ariaCurrent=\"page\"\n role=\"menuitem\"\n [class.disable-router-link]=\"!item.link && !item.action && !item.href\"\n [siLink]=\"item\"\n [exactMatch]=\"true\"\n [attr.aria-disabled]=\"!item.link && !item.action && !item.href\"\n >{{ item.title }}</a\n >\n</ng-template>\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nimport { NgModule } from '@angular/core';\n\nimport { SiBreadcrumbComponent } from './si-breadcrumb.component';\n\n@NgModule({\n imports: [SiBreadcrumbComponent],\n exports: [SiBreadcrumbComponent]\n})\nexport class SiBreadcrumbModule {}\n","/**\n * Copyright (c) Siemens 2016 - 2026\n * SPDX-License-Identifier: MIT\n */\nexport * from './breadcrumb-item.model';\nexport * from './si-breadcrumb.component';\nexport * from './si-breadcrumb.module';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;;;;AAAA;;;AAGG;MAMU,iCAAiC,CAAA;AAC5C,IAAA,OAAO,sBAAsB,CAC3B,SAA4C,EAC5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