@siemens/element-ng 47.0.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE.md +20 -0
- package/README.md +27 -0
- package/application-header/index.d.ts +17 -0
- package/application-header/launchpad/si-launchpad-app.component.d.ts +21 -0
- package/application-header/launchpad/si-launchpad-factory.component.d.ts +83 -0
- package/application-header/launchpad/si-launchpad.model.d.ts +33 -0
- package/application-header/package.json +3 -0
- package/application-header/si-application-header.component.d.ts +60 -0
- package/application-header/si-header-account-item.component.d.ts +13 -0
- package/application-header/si-header-action-item-icon-base.directive.d.ts +26 -0
- package/application-header/si-header-action-item.base.d.ts +19 -0
- package/application-header/si-header-action-item.component.d.ts +9 -0
- package/application-header/si-header-actions.directive.d.ts +5 -0
- package/application-header/si-header-brand.directive.d.ts +5 -0
- package/application-header/si-header-collapsible-actions.component.d.ts +33 -0
- package/application-header/si-header-logo.directive.d.ts +6 -0
- package/application-header/si-header-navigation-item.component.d.ts +10 -0
- package/application-header/si-header-navigation.component.d.ts +11 -0
- package/application-header/si-header-selection-item.component.d.ts +12 -0
- package/application-header/si-header-siemens-logo.component.d.ts +20 -0
- package/avatar/index.d.ts +6 -0
- package/avatar/package.json +3 -0
- package/avatar/si-avatar-background-color.directive.d.ts +35 -0
- package/avatar/si-avatar.component.d.ts +50 -0
- package/common/decorators/index.d.ts +5 -0
- package/common/decorators/webcomponent.decorator.d.ts +6 -0
- package/common/helpers/animation.helpers.d.ts +10 -0
- package/common/helpers/global-events.helpers.d.ts +5 -0
- package/common/helpers/index.d.ts +10 -0
- package/common/helpers/overlay-helper.d.ts +24 -0
- package/common/helpers/positioning.helpers.d.ts +58 -0
- package/common/helpers/rtl.d.ts +6 -0
- package/common/helpers/track-by.helper.d.ts +27 -0
- package/common/index.d.ts +8 -0
- package/common/models/color-variant.model.d.ts +8 -0
- package/common/models/index.d.ts +8 -0
- package/common/models/menu.model.d.ts +85 -0
- package/common/models/positions.model.d.ts +18 -0
- package/common/models/status-type.model.d.ts +19 -0
- package/common/package.json +3 -0
- package/common/services/blink.service.d.ts +41 -0
- package/common/services/index.d.ts +8 -0
- package/common/services/scrollbar-helper.service.d.ts +17 -0
- package/common/services/si-uistate.service.d.ts +61 -0
- package/common/services/text-measure.service.d.ts +21 -0
- package/element-ng.scss +14 -0
- package/fesm2022/siemens-element-ng-application-header.mjs +747 -0
- package/fesm2022/siemens-element-ng-application-header.mjs.map +1 -0
- package/fesm2022/siemens-element-ng-avatar.mjs +185 -0
- package/fesm2022/siemens-element-ng-avatar.mjs.map +1 -0
- package/fesm2022/siemens-element-ng-common.mjs +946 -0
- package/fesm2022/siemens-element-ng-common.mjs.map +1 -0
- package/fesm2022/siemens-element-ng-header-dropdown.mjs +384 -0
- package/fesm2022/siemens-element-ng-header-dropdown.mjs.map +1 -0
- package/fesm2022/siemens-element-ng-icon.mjs +236 -0
- package/fesm2022/siemens-element-ng-icon.mjs.map +1 -0
- package/fesm2022/siemens-element-ng-link.mjs +233 -0
- package/fesm2022/siemens-element-ng-link.mjs.map +1 -0
- package/fesm2022/siemens-element-ng-resize-observer.mjs +332 -0
- package/fesm2022/siemens-element-ng-resize-observer.mjs.map +1 -0
- package/fesm2022/siemens-element-ng-theme.mjs +770 -0
- package/fesm2022/siemens-element-ng-theme.mjs.map +1 -0
- package/fesm2022/siemens-element-ng-translate.mjs +22 -0
- package/fesm2022/siemens-element-ng-translate.mjs.map +1 -0
- package/fesm2022/siemens-element-ng.mjs +12 -0
- package/fesm2022/siemens-element-ng.mjs.map +1 -0
- package/header-dropdown/index.d.ts +9 -0
- package/header-dropdown/package.json +3 -0
- package/header-dropdown/si-header-dropdown-item.component.d.ts +23 -0
- package/header-dropdown/si-header-dropdown-items-factory.component.d.ts +14 -0
- package/header-dropdown/si-header-dropdown-trigger.directive.d.ts +57 -0
- package/header-dropdown/si-header-dropdown.component.d.ts +20 -0
- package/header-dropdown/si-header.model.d.ts +37 -0
- package/icon/element-icons.d.ts +12 -0
- package/icon/index.d.ts +9 -0
- package/icon/package.json +3 -0
- package/icon/si-icon-next.component.d.ts +68 -0
- package/icon/si-icon.component.d.ts +23 -0
- package/icon/si-icon.module.d.ts +7 -0
- package/icon/si-icons.d.ts +31 -0
- package/index.d.ts +5 -0
- package/link/aria-current.model.d.ts +5 -0
- package/link/index.d.ts +8 -0
- package/link/link.model.d.ts +57 -0
- package/link/package.json +3 -0
- package/link/si-link-action.service.d.ts +17 -0
- package/link/si-link.directive.d.ts +42 -0
- package/link/si-link.module.d.ts +7 -0
- package/package.json +86 -0
- package/public-api.d.ts +5 -0
- package/resize-observer/index.d.ts +8 -0
- package/resize-observer/package.json +3 -0
- package/resize-observer/resize-observer.service.d.ts +41 -0
- package/resize-observer/si-resize-observer.directive.d.ts +29 -0
- package/resize-observer/si-resize-observer.module.d.ts +8 -0
- package/resize-observer/si-responsive-container.directive.d.ts +73 -0
- package/theme/index.d.ts +7 -0
- package/theme/package.json +3 -0
- package/theme/si-theme-store.d.ts +82 -0
- package/theme/si-theme.model.d.ts +48 -0
- package/theme/si-theme.service.d.ts +129 -0
- package/translate/index.d.ts +7 -0
- package/translate/package.json +3 -0
- package/translate/si-translatable-keys.interface.d.ts +11 -0
- package/translate/si-translatable-overrides.provider.d.ts +7 -0
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"siemens-element-ng-header-dropdown.mjs","sources":["../../../../projects/element-ng/header-dropdown/si-header.model.ts","../../../../projects/element-ng/header-dropdown/si-header-dropdown-trigger.directive.ts","../../../../projects/element-ng/header-dropdown/si-header-dropdown.component.ts","../../../../projects/element-ng/header-dropdown/si-header-dropdown.component.html","../../../../projects/element-ng/header-dropdown/si-header-dropdown-item.component.ts","../../../../projects/element-ng/header-dropdown/si-header-dropdown-item.component.html","../../../../projects/element-ng/header-dropdown/si-header-dropdown-items-factory.component.ts","../../../../projects/element-ng/header-dropdown/si-header-dropdown-items-factory.component.html","../../../../projects/element-ng/header-dropdown/index.ts","../../../../projects/element-ng/header-dropdown/siemens-element-ng-header-dropdown.ts"],"sourcesContent":["/**\n * Copyright Siemens 2016 - 2025.\n * SPDX-License-Identifier: MIT\n */\nimport { ConnectedPosition } from '@angular/cdk/overlay';\nimport { InjectionToken } from '@angular/core';\nimport { Observable } from 'rxjs';\n\nimport { SiHeaderDropdownTriggerDirective } from './si-header-dropdown-trigger.directive';\n\n/** @internal */\nexport interface HeaderWithDropdowns {\n /** Called whenever an item is triggered that is not opening another dropdown. */\n onDropdownItemTriggered?(): void;\n /** Whether the dropdown should be opened inline. */\n inlineDropdown?: Observable<boolean>;\n /** The position of the dropdown if opened in an overlay. */\n overlayPosition?: ConnectedPosition[];\n /** Called whenever a dropdown is opened **/\n dropdownOpened?(trigger: SiHeaderDropdownTriggerDirective): void;\n /** Called whenever a dropdown is close **/\n dropdownClosed?(trigger: SiHeaderDropdownTriggerDirective): void;\n}\n\n/** @internal */\nexport const SI_HEADER_WITH_DROPDOWNS = new InjectionToken<HeaderWithDropdowns>(\n 'si-header.with-dropdowns'\n);\n\n/**\n * Can be used to pass context-specific options to a header-dropdown\n * that should / or cannot be provided by a consuming application.\n * @internal\n */\nexport interface HeaderDropdownOptions {\n /**\n * If the inline navbar is already wrapped in a focus trap,\n * set this property to prevent the header-dropdown from creating a focus trap.\n */\n disableRootFocusTrapForInlineMode: boolean;\n}\n\n/** @internal */\nexport const SI_HEADER_DROPDOWN_OPTIONS = new InjectionToken<HeaderDropdownOptions>(\n 'si-header-dropdown.options'\n);\n","/**\n * Copyright Siemens 2016 - 2025.\n * SPDX-License-Identifier: MIT\n */\nimport { Overlay, OverlayRef } from '@angular/cdk/overlay';\nimport { TemplatePortal } from '@angular/cdk/portal';\nimport {\n Component,\n ComponentRef,\n Directive,\n ElementRef,\n EmbeddedViewRef,\n HostBinding,\n HostListener,\n inject,\n Injector,\n input,\n OnChanges,\n OnDestroy,\n OnInit,\n output,\n TemplateRef,\n ViewContainerRef\n} from '@angular/core';\nimport { of, Subject } from 'rxjs';\nimport { filter, skip, take, takeUntil } from 'rxjs/operators';\n\nimport { SI_HEADER_WITH_DROPDOWNS } from './si-header.model';\n\n@Component({ template: '', host: { '[attr.aria-owns]': 'ariaOwns()' } })\nclass SiHeaderAnchorComponent {\n readonly ariaOwns = input<string>();\n}\n\n/**\n * Trigger to open dropdowns in a navbar.\n * A dropdown will always be attached to the view, even if not visible.\n *\n * If a dropdown is opened in desktop mode, it will be reattached to an overlay while being opened.\n */\n@Directive({\n selector: '[siHeaderDropdownTriggerFor]',\n exportAs: 'siHeaderDropdownTrigger',\n host: {\n class: 'dropdown-toggle'\n }\n})\nexport class SiHeaderDropdownTriggerDirective implements OnChanges, OnInit, OnDestroy {\n private static idCounter = 0;\n\n /** Template that be rendered inside the dropdown. */\n readonly dropdown = input.required<TemplateRef<unknown>>({ alias: 'siHeaderDropdownTriggerFor' });\n /** Data that should be passed as template context to the dropdown. */\n readonly dropdownData = input<unknown>();\n /** Emits whenever a dropdown is opened or closed. */\n readonly openChange = output<boolean>();\n\n private readonly dropdownClose = new Subject<void>();\n\n /** Child triggers will set themselves here if they are open. */\n private openSubmenu?: SiHeaderDropdownTriggerDirective;\n\n private readonly viewContainerRef = inject(ViewContainerRef);\n private readonly elementRef = inject<ElementRef<HTMLElement>>(ElementRef);\n private readonly overlay = inject(Overlay);\n private readonly parent = inject(SiHeaderDropdownTriggerDirective, {\n optional: true,\n skipSelf: true\n });\n /** @internal */\n readonly navbar = inject(SI_HEADER_WITH_DROPDOWNS, { optional: true });\n\n // we need to create a new injector, so that the parent can be injected properly\n private readonly injector = Injector.create({ parent: inject(Injector), providers: [] });\n private viewRef?: EmbeddedViewRef<unknown>;\n private portal?: TemplatePortal<unknown>;\n private overlayRef?: OverlayRef;\n\n /** @internal */\n readonly level: number = this.parent ? this.parent.level + 1 : 1;\n\n // used to prevent immediate re-creation of the overlay if this trigger was clicked while overlay is open\n private destroying = false;\n\n /** @internal */\n @HostBinding('id') readonly id =\n `si-navbar-dropdown-trigger-${SiHeaderDropdownTriggerDirective.idCounter++}`;\n\n @HostBinding('class.show') @HostBinding('attr.aria-expanded') private _isOpen = false;\n\n /** @internal */\n @HostBinding('attr.aria-controls') readonly ariaControls =\n `si-navbar-dropdown-${SiHeaderDropdownTriggerDirective.idCounter}`;\n\n private headerAnchorComponentRef?: ComponentRef<SiHeaderAnchorComponent>;\n\n /** Whether the dropdown is open. */\n get isOpen(): boolean {\n return this._isOpen;\n }\n\n /** @internal */\n get isOverlay(): boolean {\n return !!this.overlayRef;\n }\n\n ngOnChanges(): void {\n if (this.portal) {\n this.portal.templateRef = this.dropdown();\n this.portal.context = this.dropdownData();\n }\n }\n\n ngOnInit(): void {\n // Always attach the dropdown, so that it can be used with routerLinkActive\n this.attachDropdownInline();\n }\n\n ngOnDestroy(): void {\n this.close();\n this.dropdownClose.complete();\n }\n\n /** Opens the dropdown. */\n open(): void {\n if (this.destroying || this._isOpen) {\n return;\n }\n\n (this.navbar?.inlineDropdown ?? of(false)).pipe(take(1)).subscribe(inline => {\n this._isOpen = true;\n if (!inline) {\n this.attachDropdownOverlay();\n }\n this.navbar?.inlineDropdown\n ?.pipe(skip(1), takeUntil(this.dropdownClose))\n .subscribe(() => this.close());\n });\n\n if (this.parent) {\n this.parent.openSubmenu = this;\n }\n\n if (this.navbar?.dropdownOpened) {\n this.navbar?.dropdownOpened(this);\n }\n this.openChange.emit(true);\n }\n\n /** Closes the dropdown. */\n close(options?: { all?: boolean }): void {\n if (!this._isOpen) {\n return;\n }\n\n if (this.openSubmenu) {\n this.openSubmenu.close();\n }\n\n this.dropdownClose.next();\n this._isOpen = false;\n if (this.overlayRef) {\n this.destroying = true;\n this.overlayRef.detach();\n this.overlayRef.dispose();\n this.viewRef?.destroy();\n this.portal = undefined;\n this.overlayRef = undefined;\n this.headerAnchorComponentRef?.destroy();\n // do not use queueMicrotask, it executed to early\n setTimeout(() => (this.destroying = false));\n this.attachDropdownInline();\n } else {\n this.viewRef?.markForCheck();\n }\n\n if (this.parent) {\n this.parent.openSubmenu = undefined;\n }\n\n if (options?.all && this.parent) {\n this.parent.close(options);\n } else {\n if (this.navbar?.dropdownClosed) {\n this.navbar?.dropdownClosed(this);\n }\n this.openChange.emit(false);\n }\n }\n\n @HostListener('click')\n protected click(): void {\n if (this._isOpen) {\n this.close();\n } else {\n this.open();\n }\n }\n\n private attachDropdownInline(): void {\n this.viewRef = this.viewContainerRef.createEmbeddedView(this.dropdown(), this.dropdownData(), {\n injector: this.injector\n });\n this.viewRef.markForCheck();\n }\n\n private attachDropdownOverlay(): void {\n this.viewRef?.destroy();\n this.overlayRef = this.overlay.create({\n positionStrategy: this.overlay\n .position()\n .flexibleConnectedTo(this.elementRef)\n .withPositions(\n this.navbar?.overlayPosition ??\n (this.level > 1\n ? [\n {\n originX: 'end',\n originY: 'bottom',\n overlayX: 'end',\n overlayY: 'top',\n offsetX: 2\n }\n ]\n : [\n { originX: 'start', originY: 'bottom', overlayX: 'start', overlayY: 'top' },\n {\n originX: 'end',\n originY: 'bottom',\n overlayX: 'end',\n overlayY: 'top',\n offsetX: -4\n }\n ])\n )\n });\n this.portal = new TemplatePortal(\n this.dropdown(),\n this.viewContainerRef,\n this.dropdownData(),\n this.injector\n );\n this.viewRef = this.overlayRef.attach(this.portal);\n this.headerAnchorComponentRef = this.viewContainerRef.createComponent(SiHeaderAnchorComponent);\n this.headerAnchorComponentRef.setInput('ariaOwns', this.ariaControls);\n\n this.overlayRef\n .outsidePointerEvents()\n .pipe(\n filter(event => event.type === 'click'),\n filter(() => !this.openSubmenu),\n takeUntil(this.dropdownClose),\n take(1)\n )\n .subscribe(() => this.close());\n }\n}\n","/**\n * Copyright Siemens 2016 - 2025.\n * SPDX-License-Identifier: MIT\n */\nimport { A11yModule, CdkTrapFocus } from '@angular/cdk/a11y';\nimport { DOCUMENT } from '@angular/common';\nimport {\n ChangeDetectionStrategy,\n Component,\n HostBinding,\n HostListener,\n inject,\n viewChild\n} from '@angular/core';\n\nimport { SiHeaderDropdownTriggerDirective } from './si-header-dropdown-trigger.directive';\nimport { SI_HEADER_DROPDOWN_OPTIONS } from './si-header.model';\n\n/**\n * Wrapper component for {@link SiHeaderDropdownItemComponent}.\n * Must only be opened using an {@link SiHeaderDropdownTriggerDirective}.\n */\n@Component({\n selector: 'si-header-dropdown',\n imports: [A11yModule],\n templateUrl: './si-header-dropdown.component.html',\n host: {\n class: 'dropdown-menu position-static',\n role: 'group',\n '[id]': 'trigger.ariaControls',\n '[attr.aria-labelledby]': 'trigger.id'\n },\n styles: ':host.sub-menu {min-inline-size: 200px}',\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class SiHeaderDropdownComponent {\n protected trigger = inject(SiHeaderDropdownTriggerDirective);\n\n private readonly focusTrap = viewChild.required(CdkTrapFocus);\n private previousElement: Element | null = null;\n private readonly document = inject(DOCUMENT);\n private readonly options = inject(SI_HEADER_DROPDOWN_OPTIONS, { optional: true });\n\n constructor() {\n // The autoFocus feature of the focus trap is not enough, as this component is not newly created when opened in mobile (inline).\n // But we still need autofocus in desktop mode, as the close event is never executed (component is destroyed before).\n this.trigger.openChange.subscribe(change => {\n if (!this.trigger.isOverlay && this.trapFocus && change) {\n this.previousElement = this.document.activeElement;\n this.focusTrap().focusTrap.focusFirstTabbableElementWhenReady();\n } else {\n if (\n this.previousElement &&\n 'focus' in this.previousElement &&\n typeof this.previousElement.focus === 'function'\n ) {\n this.previousElement.focus();\n }\n this.previousElement = null;\n }\n });\n }\n\n @HostBinding('class.show')\n protected get show(): boolean {\n return this.trigger.isOpen;\n }\n\n @HostBinding('class.sub-menu') protected get submenu(): boolean {\n return this.trigger.level > 1;\n }\n\n protected get trapFocus(): boolean {\n return (\n this.trigger.isOverlay ||\n (!this.options?.disableRootFocusTrapForInlineMode && this.trigger.level === 1)\n );\n }\n\n @HostListener('keydown.escape')\n protected escape(): void {\n this.trigger?.close();\n }\n}\n","<div [cdkTrapFocus]=\"trapFocus\" [cdkTrapFocusAutoCapture]=\"this.trigger.isOverlay\">\n <ng-content />\n</div>\n","/**\n * Copyright Siemens 2016 - 2025.\n * SPDX-License-Identifier: MIT\n */\nimport { NgClass } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, HostListener, inject, input } from '@angular/core';\n\nimport { SiHeaderDropdownTriggerDirective } from './si-header-dropdown-trigger.directive';\nimport { SI_HEADER_WITH_DROPDOWNS } from './si-header.model';\n\n/**\n * Creates a dropdown-item. Must be used within an {@link SiHeaderDropdownComponent}.\n */\n@Component({\n selector: 'si-header-dropdown-item, a[si-header-dropdown-item], button[si-header-dropdown-item]',\n imports: [NgClass],\n templateUrl: './si-header-dropdown-item.component.html',\n styleUrl: './si-header-dropdown-item.component.scss',\n host: {\n class: 'dropdown-item focus-inside'\n },\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class SiHeaderDropdownItemComponent {\n /** Optional icon that will be rendered before the label. */\n readonly icon = input<string>();\n /** Badge that is rendered after the label. */\n readonly badge = input<string | number>();\n /** Badge (always red) that is attached to the icon. */\n readonly iconBadge = input<string | number>();\n /** Color of the badge (not iconBadge). */\n readonly badgeColor = input<string>();\n /** Whether the icon is checked with a radio or check mark. */\n readonly checked = input<'radio' | 'check' | ''>();\n\n protected readonly ownTrigger = inject(SiHeaderDropdownTriggerDirective, {\n self: true,\n optional: true\n });\n protected readonly parentTrigger = inject(SiHeaderDropdownTriggerDirective, { skipSelf: true });\n protected readonly navbar = inject(SI_HEADER_WITH_DROPDOWNS, { optional: true });\n\n @HostListener('click')\n protected click(): void {\n if (!this.ownTrigger) {\n this.parentTrigger.close({ all: true });\n if (this.navbar?.onDropdownItemTriggered) {\n this.navbar?.onDropdownItemTriggered();\n }\n }\n }\n}\n","@if (icon()) {\n <span\n class=\"icon\"\n aria-hidden=\"true\"\n [ngClass]=\"[icon(), ownTrigger?.isOpen ? icon() + '-filled' : '']\"\n ></span>\n}\n@if (iconBadge()) {\n <div class=\"badge-text\">{{ iconBadge() }}</div>\n}\n<span class=\"item-title text-truncate\">\n <ng-content />\n</span>\n<div class=\"item-end ps-2 d-flex me-n3 ms-auto gap-1\">\n @if (badge()) {\n <span class=\"mx-0 me-1 ms-2 badge\" [ngClass]=\"'bg-' + badgeColor()\">{{ badge() }}</span>\n }\n @if (checked() === 'check') {\n <div class=\"element-ok icon\" aria-hidden=\"true\"></div>\n }\n @if (checked() === 'radio') {\n <div class=\"element-record-filled icon-small me-2\" aria-hidden=\"true\"></div>\n }\n @if (ownTrigger) {\n <span class=\"element-down-2 dropdown-caret m-0 ps-0\" aria-hidden=\"true\"></span>\n }\n</div>\n","/**\n * Copyright Siemens 2016 - 2025.\n * SPDX-License-Identifier: MIT\n */\nimport { Component, input, output } from '@angular/core';\nimport { MenuItem } from '@siemens/element-ng/common';\nimport { SiLinkDirective } from '@siemens/element-ng/link';\nimport { SiTranslateModule } from '@siemens/element-translate-ng/translate';\n\nimport { SiHeaderDropdownItemComponent } from './si-header-dropdown-item.component';\nimport { SiHeaderDropdownTriggerDirective } from './si-header-dropdown-trigger.directive';\nimport { SiHeaderDropdownComponent } from './si-header-dropdown.component';\n\n/**\n * A factory to render multiple {@link MenuItem}.\n * Requires a wrapping {@link SiHeaderDropdownComponent}.\n *\n * @internal\n */\n@Component({\n selector: 'si-header-dropdown-items-factory',\n imports: [\n SiHeaderDropdownComponent,\n SiHeaderDropdownItemComponent,\n SiTranslateModule,\n SiLinkDirective,\n SiHeaderDropdownTriggerDirective\n ],\n templateUrl: './si-header-dropdown-items-factory.component.html'\n})\nexport class SiHeaderDropdownItemsFactoryComponent {\n readonly items = input.required<MenuItem[]>();\n readonly activeChange = output<boolean>();\n}\n","@for (item of items(); track item) {\n @if (item.isHeading) {\n <div class=\"dropdown-item dropdown-header dropdown-item-static\">\n {{ item.title | translate }}\n </div>\n } @else {\n @if (item.title !== '-') {\n @if (item.items) {\n <button\n type=\"button\"\n si-header-dropdown-item\n [icon]=\"item.icon\"\n [badge]=\"item.badgeStyle !== 'dot' ? item.badge : undefined\"\n [badgeColor]=\"item.badgeColor\"\n [iconBadge]=\"item.badgeStyle === 'dot' ? item.badge : undefined\"\n [siHeaderDropdownTriggerFor]=\"dropdown\"\n >\n {{ item.title | translate }}\n </button>\n <ng-template #dropdown>\n <si-header-dropdown>\n <si-header-dropdown-items-factory [items]=\"item.items\" />\n </si-header-dropdown>\n </ng-template>\n } @else {\n <a\n si-header-dropdown-item\n activeClass=\"active\"\n [siLink]=\"item\"\n [icon]=\"item.icon\"\n [badge]=\"item.badgeStyle !== 'dot' ? item.badge : undefined\"\n [badgeColor]=\"item.badgeColor\"\n [iconBadge]=\"item.badgeStyle === 'dot' ? item.badge : undefined\"\n [checked]=\"item.selectionState\"\n (activeChange)=\"activeChange.emit($event)\"\n >\n {{ item.title | translate }}\n </a>\n }\n } @else {\n <div class=\"dropdown-divider\"></div>\n }\n }\n}\n","/**\n * Copyright Siemens 2016 - 2025.\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-header-dropdown.component';\nexport * from './si-header-dropdown-trigger.directive';\nexport * from './si-header-dropdown-item.component';\nexport * from './si-header-dropdown-items-factory.component';\nexport * from './si-header.model';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":["i1"],"mappings":";;;;;;;;;;;;;AAwBA;MACa,wBAAwB,GAAG,IAAI,cAAc,CACxD,0BAA0B;AAgB5B;MACa,0BAA0B,GAAG,IAAI,cAAc,CAC1D,4BAA4B;;AC5C9B;;;AAGG;AA0BH,MACM,uBAAuB,CAAA;IAClB,QAAQ,GAAG,KAAK,EAAU;uGAD/B,uBAAuB,EAAA,IAAA,EAAA,EAAA,EAAA,MAAA,EAAA,EAAA,CAAA,eAAA,CAAA,SAAA,EAAA,CAAA;AAAvB,IAAA,OAAA,IAAA,GAAA,EAAA,CAAA,oBAAA,CAAA,EAAA,UAAA,EAAA,QAAA,EAAA,OAAA,EAAA,QAAA,EAAA,IAAA,EAAA,uBAAuB,+QADN,EAAE,EAAA,QAAA,EAAA,IAAA,EAAA,CAAA;;2FACnB,uBAAuB,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EAAA,OAAA,EAAA,WAAA,EAAA,YAAA,EAAA,SAAA,CAAA,EAAA,EAAA,EAAA,IAAA,EAAA,UAAA,EAAA,IAAA,EAAA,iBAAiB,EACjB,EAAA,EAAA,IAAA,EAAA,MAAA,EAAA,IAAA,EAAAA,IAAA,CAAA,eAAA,EAAA,IAAA,EAAA,WAAA,EAAA,EAAA,EAAA,IAAA,EAAA,WAAA,EAAA,IAAA,EAAA,eAAe,4MACf,gCAAgC,EAAA,QAAA,EAAA,8BAAA,EAAA,MAAA,EAAA,CAAA,4BAAA,EAAA,cAAA,CAAA,EAAA,OAAA,EAAA,CAAA,YAAA,CAAA,EAAA,QAAA,EAAA,CAAA,yBAAA,CAAA,EAAA,CAAA,EAAA,CAAA;;2FAIvB,qCAAqC,EAAA,UAAA,EAAA,CAAA;kBAXjD,SAAS;AACE,YAAA,IAAA,EAAA,CAAA,EAAA,QAAA,EAAA,kCAAkC,EACnC,OAAA,EAAA;wBACP,yBAAyB;wBACzB,6BAA6B;wBAC7B,iBAAiB;wBACjB,eAAe;wBACf;AACD,qBAAA,EAAA,QAAA,EAAA,g9CAAA,EAAA;;;AE3BH;;;AAGG;;ACHH;;AAEG;;;;"}
|
|
@@ -0,0 +1,236 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { input, computed, ChangeDetectionStrategy, Component, NgModule, inject, DestroyRef, Injectable, InjectionToken } from '@angular/core';
|
|
3
|
+
import { NgClass } from '@angular/common';
|
|
4
|
+
import * as i1 from '@siemens/element-translate-ng/translate';
|
|
5
|
+
import { SiTranslateModule } from '@siemens/element-translate-ng/translate';
|
|
6
|
+
import { DomSanitizer } from '@angular/platform-browser';
|
|
7
|
+
import { SiThemeService } from '@siemens/element-ng/theme';
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Copyright Siemens 2016 - 2025.
|
|
11
|
+
* SPDX-License-Identifier: MIT
|
|
12
|
+
*/
|
|
13
|
+
class SiIconComponent {
|
|
14
|
+
/** Icon token, see {@link https://element.siemens.io/icons/element} */
|
|
15
|
+
icon = input();
|
|
16
|
+
/** Color class, see {@link https://element.siemens.io/fundamentals/typography/#color-variants-classes} */
|
|
17
|
+
color = input();
|
|
18
|
+
/** Icon token, see {@link https://element.siemens.io/fundamentals/icons/} */
|
|
19
|
+
stackedIcon = input();
|
|
20
|
+
/** Color class, see {@link https://element.siemens.io/fundamentals/icons/} */
|
|
21
|
+
stackedColor = input();
|
|
22
|
+
/** Alternative name or translation key for icon. Used for A11y. */
|
|
23
|
+
alt = input();
|
|
24
|
+
/**
|
|
25
|
+
* Text-size class for icon size, see {@link https://element.siemens.io/fundamentals/typography/#type-styles-classes}
|
|
26
|
+
*
|
|
27
|
+
* @defaultValue 'icon'
|
|
28
|
+
*/
|
|
29
|
+
size = input('icon');
|
|
30
|
+
altText = computed(() => {
|
|
31
|
+
return this.alt() ?? this.icon()?.replace('element-', '').split('-').join(' ') ?? '';
|
|
32
|
+
});
|
|
33
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: SiIconComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
34
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.0.6", type: SiIconComponent, isStandalone: true, selector: "si-icon", inputs: { icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: false, transformFunction: null }, color: { classPropertyName: "color", publicName: "color", isSignal: true, isRequired: false, transformFunction: null }, stackedIcon: { classPropertyName: "stackedIcon", publicName: "stackedIcon", isSignal: true, isRequired: false, transformFunction: null }, stackedColor: { classPropertyName: "stackedColor", publicName: "stackedColor", isSignal: true, isRequired: false, transformFunction: null }, alt: { classPropertyName: "alt", publicName: "alt", isSignal: true, isRequired: false, transformFunction: null }, size: { classPropertyName: "size", publicName: "size", isSignal: true, isRequired: false, transformFunction: null } }, ngImport: i0, template: "<span\n class=\"d-inline-block position-relative\"\n [attr.aria-label]=\"altText() ? (altText() | translate) : null\"\n [attr.aria-hidden]=\"!altText()\"\n [attr.role]=\"altText() ? 'img' : 'presentation'\"\n [ngClass]=\"[icon() ?? '', color() ?? '', size()]\"\n>\n @if (stackedIcon()) {\n <i\n class=\"position-absolute start-0\"\n aria-hidden=\"true\"\n [ngClass]=\"[stackedIcon(), stackedColor() ?? '']\"\n ></i>\n }\n</span>\n", styles: [":host,span{line-height:1}\n"], dependencies: [{ kind: "directive", type: NgClass, selector: "[ngClass]", inputs: ["class", "ngClass"] }, { kind: "ngmodule", type: SiTranslateModule }, { kind: "pipe", type: i1.SiTranslatePipe, name: "translate" }], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
35
|
+
}
|
|
36
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: SiIconComponent, decorators: [{
|
|
37
|
+
type: Component,
|
|
38
|
+
args: [{ selector: 'si-icon', changeDetection: ChangeDetectionStrategy.OnPush, imports: [NgClass, SiTranslateModule], template: "<span\n class=\"d-inline-block position-relative\"\n [attr.aria-label]=\"altText() ? (altText() | translate) : null\"\n [attr.aria-hidden]=\"!altText()\"\n [attr.role]=\"altText() ? 'img' : 'presentation'\"\n [ngClass]=\"[icon() ?? '', color() ?? '', size()]\"\n>\n @if (stackedIcon()) {\n <i\n class=\"position-absolute start-0\"\n aria-hidden=\"true\"\n [ngClass]=\"[stackedIcon(), stackedColor() ?? '']\"\n ></i>\n }\n</span>\n", styles: [":host,span{line-height:1}\n"] }]
|
|
39
|
+
}] });
|
|
40
|
+
|
|
41
|
+
/**
|
|
42
|
+
* Copyright Siemens 2016 - 2025.
|
|
43
|
+
* SPDX-License-Identifier: MIT
|
|
44
|
+
*/
|
|
45
|
+
class SiIconModule {
|
|
46
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: SiIconModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
47
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.0.6", ngImport: i0, type: SiIconModule, imports: [SiIconComponent], exports: [SiIconComponent] });
|
|
48
|
+
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: SiIconModule, imports: [SiIconComponent] });
|
|
49
|
+
}
|
|
50
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: SiIconModule, decorators: [{
|
|
51
|
+
type: NgModule,
|
|
52
|
+
args: [{
|
|
53
|
+
imports: [SiIconComponent],
|
|
54
|
+
exports: [SiIconComponent]
|
|
55
|
+
}]
|
|
56
|
+
}] });
|
|
57
|
+
|
|
58
|
+
/**
|
|
59
|
+
* Copyright Siemens 2016 - 2025.
|
|
60
|
+
* SPDX-License-Identifier: MIT
|
|
61
|
+
*/
|
|
62
|
+
const parseDataSvgIcon = (icon, domSanitizer) => {
|
|
63
|
+
const parsed = /^data:image\/svg\+xml;utf8,(.*)$/.exec(icon);
|
|
64
|
+
if (!parsed) {
|
|
65
|
+
console.error('Failed to parse icon', icon);
|
|
66
|
+
return '';
|
|
67
|
+
}
|
|
68
|
+
return domSanitizer.bypassSecurityTrustHtml(parsed[1]);
|
|
69
|
+
};
|
|
70
|
+
const registeredIcons = new Map();
|
|
71
|
+
/**
|
|
72
|
+
* Adds the provided icons.
|
|
73
|
+
* It requires an Angular InjectionContent.
|
|
74
|
+
* The Icons are available until the component is destroyed.
|
|
75
|
+
* Call this function only in the component which actually uses the icon.
|
|
76
|
+
* Importing all icons on the global level is discouraged.
|
|
77
|
+
*
|
|
78
|
+
* When using a string instead of the object to use an icon,
|
|
79
|
+
* use the kebab-case version of the icon name.
|
|
80
|
+
*
|
|
81
|
+
* @example
|
|
82
|
+
* ```ts
|
|
83
|
+
* import { elementIcon } from '@simpl/element-icons/ionic';
|
|
84
|
+
* import { addIcons } from '@siemens/element-ng/icon'
|
|
85
|
+
*
|
|
86
|
+
* @Component({`<si-icon-next [icon]="icons.elementIcon"`})
|
|
87
|
+
* class MyComponent {
|
|
88
|
+
* icons = addIcons({ elementIcon })
|
|
89
|
+
* }
|
|
90
|
+
* ```
|
|
91
|
+
*/
|
|
92
|
+
const addIcons = (icons) => {
|
|
93
|
+
const iconMap = {};
|
|
94
|
+
const domSanitizer = inject(DomSanitizer);
|
|
95
|
+
for (const [key, rawContent] of Object.entries(icons)) {
|
|
96
|
+
const registeredIcon = registeredIcons.get(key) ?? {
|
|
97
|
+
content: parseDataSvgIcon(rawContent, domSanitizer),
|
|
98
|
+
referenceCount: 0
|
|
99
|
+
};
|
|
100
|
+
registeredIcon.referenceCount++;
|
|
101
|
+
registeredIcons.set(key, registeredIcon);
|
|
102
|
+
iconMap[key] = key;
|
|
103
|
+
}
|
|
104
|
+
// Delete registered Icons after Component is destroyed to optimize memory usage.
|
|
105
|
+
// WeakMap must not be used, as the Icon can only be removed on component destruction.
|
|
106
|
+
// When using a WeakMap it would also get destroyed if it is not referenced, but the component may use it later again.
|
|
107
|
+
inject(DestroyRef).onDestroy(() => {
|
|
108
|
+
for (const key of Object.keys(icons)) {
|
|
109
|
+
const registeredIcon = registeredIcons.get(key);
|
|
110
|
+
if (registeredIcon.referenceCount === 1) {
|
|
111
|
+
registeredIcons.delete(key);
|
|
112
|
+
}
|
|
113
|
+
else {
|
|
114
|
+
registeredIcon.referenceCount--;
|
|
115
|
+
}
|
|
116
|
+
}
|
|
117
|
+
});
|
|
118
|
+
return iconMap;
|
|
119
|
+
};
|
|
120
|
+
const getIcon = (key) => registeredIcons.get(key)?.content;
|
|
121
|
+
class IconService {
|
|
122
|
+
themeService = inject(SiThemeService);
|
|
123
|
+
getIcon(name) {
|
|
124
|
+
const camelCaseName = this.kebabToCamelCase(name);
|
|
125
|
+
return this.themeService.themeIcons()[camelCaseName] ?? getIcon(camelCaseName);
|
|
126
|
+
}
|
|
127
|
+
kebabToCamelCase(str) {
|
|
128
|
+
return str.replace(/-./g, match => match.charAt(1).toUpperCase());
|
|
129
|
+
}
|
|
130
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: IconService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
131
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: IconService, providedIn: 'root' });
|
|
132
|
+
}
|
|
133
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: IconService, decorators: [{
|
|
134
|
+
type: Injectable,
|
|
135
|
+
args: [{ providedIn: 'root' }]
|
|
136
|
+
}] });
|
|
137
|
+
|
|
138
|
+
/**
|
|
139
|
+
* Copyright Siemens 2016 - 2025.
|
|
140
|
+
* SPDX-License-Identifier: MIT
|
|
141
|
+
*/
|
|
142
|
+
const ICON_CONFIG = new InjectionToken('ICON_CONFIG', {
|
|
143
|
+
providedIn: 'root',
|
|
144
|
+
factory: () => ({ disableSvgIcons: true })
|
|
145
|
+
});
|
|
146
|
+
/**
|
|
147
|
+
* Configure how Element handles icons. Provide only once in your global configuration.
|
|
148
|
+
*
|
|
149
|
+
* @experimental
|
|
150
|
+
*/
|
|
151
|
+
const provideIconConfig = (config) => ({
|
|
152
|
+
provide: ICON_CONFIG,
|
|
153
|
+
useValue: config
|
|
154
|
+
});
|
|
155
|
+
/**
|
|
156
|
+
* Component to render a font or SVG icon depending on the configuration.
|
|
157
|
+
* If no SVG icon is found, the component will fall back to render the icon-font.
|
|
158
|
+
* In that case, an application must ensure that the icon font is loaded.
|
|
159
|
+
* This component will only attach the respective class.
|
|
160
|
+
*
|
|
161
|
+
* The content of this component is hidden in the a11y tree.
|
|
162
|
+
* If needed, the consumer must set proper labels.
|
|
163
|
+
*
|
|
164
|
+
* @experimental
|
|
165
|
+
*/
|
|
166
|
+
class SiIconNextComponent {
|
|
167
|
+
/**
|
|
168
|
+
* Define which icon should be rendered.
|
|
169
|
+
* Provide using:
|
|
170
|
+
* - value of the icon map provided by `addIcons`
|
|
171
|
+
* - (not recommended): plain string in kebab-case or camelCase
|
|
172
|
+
*
|
|
173
|
+
* @example
|
|
174
|
+
* ```ts
|
|
175
|
+
* import { elementUser } from '@simpl/element-icons/ionic';
|
|
176
|
+
*
|
|
177
|
+
* @Component({template: `
|
|
178
|
+
* <si-icon-next [icon]="icons.elementUser" />
|
|
179
|
+
* <si-icon-next icon="element-user" />
|
|
180
|
+
* <si-icon-next icon="elementUser" />
|
|
181
|
+
*
|
|
182
|
+
* `})
|
|
183
|
+
* class MyComponent {
|
|
184
|
+
* icons = addIcons(elementUser);
|
|
185
|
+
* }
|
|
186
|
+
* ```
|
|
187
|
+
*/
|
|
188
|
+
icon = input.required();
|
|
189
|
+
config = inject(ICON_CONFIG);
|
|
190
|
+
iconService = inject(IconService);
|
|
191
|
+
svgIcon = computed(() => this.config.disableSvgIcons ? undefined : this.iconService.getIcon(this.icon()));
|
|
192
|
+
/** Icon class, which is ensured to be kebab-case. */
|
|
193
|
+
fontIcon = computed(() => this.svgIcon() ? undefined : this.camelToKebabCase(this.icon()));
|
|
194
|
+
camelToKebabCase(str) {
|
|
195
|
+
return str
|
|
196
|
+
.replace(/([a-z])([A-Z0-9])/g, '$1-$2')
|
|
197
|
+
.replace(/([0-9])([A-Z])/g, '$1-$2')
|
|
198
|
+
.toLowerCase();
|
|
199
|
+
}
|
|
200
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: SiIconNextComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
|
|
201
|
+
static ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.1.0", version: "19.0.6", type: SiIconNextComponent, isStandalone: true, selector: "si-icon-next", inputs: { icon: { classPropertyName: "icon", publicName: "icon", isSignal: true, isRequired: true, transformFunction: null } }, host: { attributes: { "aria-hidden": "true" }, properties: { "class": "svgIcon() ? \"svg-icon\" : fontIcon()", "innerHTML": "svgIcon()" } }, ngImport: i0, template: ``, isInline: true, styles: [":host{display:inline-block;font-weight:400;vertical-align:middle;line-height:1}:host.svg-icon ::ng-deep svg{display:block;block-size:1em;fill:currentColor}\n"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
|
|
202
|
+
}
|
|
203
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: SiIconNextComponent, decorators: [{
|
|
204
|
+
type: Component,
|
|
205
|
+
args: [{ selector: 'si-icon-next', template: ``, host: {
|
|
206
|
+
'[class]': 'svgIcon() ? "svg-icon" : fontIcon()',
|
|
207
|
+
'[innerHTML]': 'svgIcon()',
|
|
208
|
+
// TODO: remove and actually hide the icon content. But wait until: https://github.com/microsoft/playwright/issues/35737 and https://github.com/dequelabs/axe-core/issues/4763 are fixed.
|
|
209
|
+
'aria-hidden': 'true'
|
|
210
|
+
}, changeDetection: ChangeDetectionStrategy.OnPush, styles: [":host{display:inline-block;font-weight:400;vertical-align:middle;line-height:1}:host.svg-icon ::ng-deep svg{display:block;block-size:1em;fill:currentColor}\n"] }]
|
|
211
|
+
}] });
|
|
212
|
+
|
|
213
|
+
/**
|
|
214
|
+
* Copyright Siemens 2016 - 2025.
|
|
215
|
+
* SPDX-License-Identifier: MIT
|
|
216
|
+
*/
|
|
217
|
+
const elementDown2 = "data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><path d='M352.79 203.21a12.45 12.45 0 0 1 1.44 15.86l-1.44 1.72-88 88a12.45 12.45 0 0 1-15.86 1.44l-1.72-1.44-88-88a12.43 12.43 0 0 1 15.86-19l1.72 1.44L256 282.42l79.21-79.21a12.45 12.45 0 0 1 15.86-1.44Z' data-name='Arrow/Right-3'/></svg>";
|
|
218
|
+
const elementCancel = "data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><path d='m273 256 87.52-87.51a12 12 0 0 0-17-17L256 239l-87.51-87.52a12 12 0 0 0-17 17L239 256l-87.52 87.51a12 12 0 0 0 17 17L256 273l87.51 87.52a12 12 0 0 0 17-17Z'/></svg>";
|
|
219
|
+
const elementFavoritesFilled = "data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><path d='M427.42 216.46a12 12 0 0 0-9.68-8.17L313.41 193l-46.65-94.47a12 12 0 0 0-21.52 0L198.59 193 94.26 208.29a12 12 0 0 0-6.63 20.47l75.48 73.51-17.82 103.86a12 12 0 0 0 17.42 12.65L256 369.72l93.29 49.06a12 12 0 0 0 17.42-12.65l-17.82-103.86 75.48-73.51a12 12 0 0 0 3.05-12.3Z'/></svg>";
|
|
220
|
+
const elementFavorites = "data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><path d='M427.42 216.46a12 12 0 0 0-9.68-8.17L313.41 193l-46.65-94.47a12 12 0 0 0-21.52 0L198.59 193 94.26 208.29a12 12 0 0 0-6.63 20.47l75.48 73.51-17.82 103.86a12 12 0 0 0 17.42 12.65L256 369.72l93.29 49.06a12 12 0 0 0 17.42-12.65l-17.82-103.86 75.48-73.51a12 12 0 0 0 3.05-12.3Zm-99.79 73a12 12 0 0 0-3.46 10.63l14.77 86.11-77.35-40.68a12 12 0 0 0-11.18 0l-77.35 40.68 14.77-86.11a12 12 0 0 0-3.46-10.63l-62.59-61 86.52-12.65a12 12 0 0 0 9-6.56L256 131l38.68 78.36a12 12 0 0 0 9 6.56l86.52 12.65Z'/></svg>";
|
|
221
|
+
const elementExport = "data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><path d='M364 248a12 12 0 0 0-12 12v96a20 20 0 0 1-20 20H156a20 20 0 0 1-20-20V180a20 20 0 0 1 20-20h96a12 12 0 0 0 0-24h-96a44.05 44.05 0 0 0-44 44v176a44.05 44.05 0 0 0 44 44h176a44.05 44.05 0 0 0 44-44v-96a12 12 0 0 0-12-12Z'/><path d='M423.94 98.82c0-.19-.05-.37-.08-.55s-.05-.41-.09-.61-.1-.41-.15-.61a4.58 4.58 0 0 0-.14-.53c-.06-.2-.13-.39-.2-.58s-.12-.36-.19-.53-.16-.35-.25-.53-.16-.36-.26-.54-.19-.32-.29-.48-.2-.35-.31-.52-.25-.35-.38-.52l-.32-.43c-.24-.29-.5-.58-.77-.85s-.56-.53-.85-.77l-.44-.33c-.17-.12-.33-.25-.51-.37l-.53-.32-.47-.28c-.18-.1-.37-.18-.56-.27l-.51-.24-.55-.2-.55-.19c-.19-.06-.38-.1-.57-.15l-.57-.14-.67-.1-.49-.07q-.6-.06-1.2-.06H316a12 12 0 0 0 0 24h67L227.51 267.51a12 12 0 0 0 17 17L400 129v67a12 12 0 0 0 24 0v-96a10.88 10.88 0 0 0-.06-1.18Z'/></svg>";
|
|
222
|
+
const elementThumbnails = "data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><circle cx='144' cy='144' r='24'/><circle cx='368' cy='144' r='24'/><circle cx='256' cy='144' r='24'/><circle cx='144' cy='368' r='24'/><circle cx='368' cy='368' r='24'/><circle cx='256' cy='368' r='24'/><circle cx='144' cy='256' r='24'/><circle cx='368' cy='256' r='24'/><circle cx='256' cy='256' r='24'/></svg>";
|
|
223
|
+
const elementOptionsVertical = "data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><path d='M284 256a28 28 0 1 1-28-28 28 28 0 0 1 28 28ZM284 144a28 28 0 1 1-28-28 28 28 0 0 1 28 28ZM284 368a28 28 0 1 1-28-28 28 28 0 0 1 28 28Z'/></svg>";
|
|
224
|
+
const elementMenu = "data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><path d='M400 244H112a12 12 0 0 0 0 24h288a12 12 0 0 0 0-24ZM400 148H112a12 12 0 0 0 0 24h288a12 12 0 0 0 0-24ZM400 340H112a12 12 0 0 0 0 24h288a12 12 0 0 0 0-24Z'/></svg>";
|
|
225
|
+
|
|
226
|
+
/**
|
|
227
|
+
* Copyright Siemens 2016 - 2025.
|
|
228
|
+
* SPDX-License-Identifier: MIT
|
|
229
|
+
*/
|
|
230
|
+
|
|
231
|
+
/**
|
|
232
|
+
* Generated bundle index. Do not edit.
|
|
233
|
+
*/
|
|
234
|
+
|
|
235
|
+
export { SiIconComponent, SiIconModule, SiIconNextComponent, addIcons, elementCancel, elementDown2, elementExport, elementFavorites, elementFavoritesFilled, elementMenu, elementOptionsVertical, elementThumbnails, provideIconConfig };
|
|
236
|
+
//# sourceMappingURL=siemens-element-ng-icon.mjs.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"siemens-element-ng-icon.mjs","sources":["../../../../projects/element-ng/icon/si-icon.component.ts","../../../../projects/element-ng/icon/si-icon.component.html","../../../../projects/element-ng/icon/si-icon.module.ts","../../../../projects/element-ng/icon/si-icons.ts","../../../../projects/element-ng/icon/si-icon-next.component.ts","../../../../projects/element-ng/icon/element-icons.ts","../../../../projects/element-ng/icon/index.ts","../../../../projects/element-ng/icon/siemens-element-ng-icon.ts"],"sourcesContent":["/**\n * Copyright Siemens 2016 - 2025.\n * SPDX-License-Identifier: MIT\n */\nimport { NgClass } from '@angular/common';\nimport { ChangeDetectionStrategy, Component, computed, input } from '@angular/core';\nimport { SiTranslateModule, TranslatableString } from '@siemens/element-translate-ng/translate';\n\n@Component({\n selector: 'si-icon',\n templateUrl: './si-icon.component.html',\n styles: ':host, span { line-height: 1; }',\n changeDetection: ChangeDetectionStrategy.OnPush,\n imports: [NgClass, SiTranslateModule]\n})\nexport class SiIconComponent {\n /** Icon token, see {@link https://element.siemens.io/icons/element} */\n readonly icon = input<string>();\n /** Color class, see {@link https://element.siemens.io/fundamentals/typography/#color-variants-classes} */\n readonly color = input<string>();\n /** Icon token, see {@link https://element.siemens.io/fundamentals/icons/} */\n readonly stackedIcon = input<string>();\n /** Color class, see {@link https://element.siemens.io/fundamentals/icons/} */\n readonly stackedColor = input<string>();\n /** Alternative name or translation key for icon. Used for A11y. */\n readonly alt = input<TranslatableString>();\n /**\n * Text-size class for icon size, see {@link https://element.siemens.io/fundamentals/typography/#type-styles-classes}\n *\n * @defaultValue 'icon'\n */\n readonly size = input<string>('icon');\n\n protected readonly altText = computed(() => {\n return this.alt() ?? this.icon()?.replace('element-', '').split('-').join(' ') ?? '';\n });\n}\n","<span\n class=\"d-inline-block position-relative\"\n [attr.aria-label]=\"altText() ? (altText() | translate) : null\"\n [attr.aria-hidden]=\"!altText()\"\n [attr.role]=\"altText() ? 'img' : 'presentation'\"\n [ngClass]=\"[icon() ?? '', color() ?? '', size()]\"\n>\n @if (stackedIcon()) {\n <i\n class=\"position-absolute start-0\"\n aria-hidden=\"true\"\n [ngClass]=\"[stackedIcon(), stackedColor() ?? '']\"\n ></i>\n }\n</span>\n","/**\n * Copyright Siemens 2016 - 2025.\n * SPDX-License-Identifier: MIT\n */\nimport { NgModule } from '@angular/core';\n\nimport { SiIconComponent } from './si-icon.component';\n\n@NgModule({\n imports: [SiIconComponent],\n exports: [SiIconComponent]\n})\nexport class SiIconModule {}\n","/**\n * Copyright Siemens 2016 - 2025.\n * SPDX-License-Identifier: MIT\n */\nimport { DestroyRef, inject, Injectable } from '@angular/core';\nimport { DomSanitizer, SafeHtml } from '@angular/platform-browser';\nimport { SiThemeService } from '@siemens/element-ng/theme';\n\ninterface RegisteredIcon {\n content: SafeHtml | undefined;\n // Count how often an icon was registered to only remove it if it is no longer in use.\n referenceCount: number;\n}\n\nconst parseDataSvgIcon = (icon: string, domSanitizer: DomSanitizer): SafeHtml => {\n const parsed = /^data:image\\/svg\\+xml;utf8,(.*)$/.exec(icon);\n if (!parsed) {\n console.error('Failed to parse icon', icon);\n return '';\n }\n return domSanitizer.bypassSecurityTrustHtml(parsed[1]);\n};\n\nconst registeredIcons = new Map<string, RegisteredIcon>();\n\n/**\n * Adds the provided icons.\n * It requires an Angular InjectionContent.\n * The Icons are available until the component is destroyed.\n * Call this function only in the component which actually uses the icon.\n * Importing all icons on the global level is discouraged.\n *\n * When using a string instead of the object to use an icon,\n * use the kebab-case version of the icon name.\n *\n * @example\n * ```ts\n * import { elementIcon } from '@simpl/element-icons/ionic';\n * import { addIcons } from '@siemens/element-ng/icon'\n *\n * @Component({`<si-icon-next [icon]=\"icons.elementIcon\"`})\n * class MyComponent {\n * icons = addIcons({ elementIcon })\n * }\n * ```\n */\nexport const addIcons = <T extends string>(icons: Record<T, string>): Record<T, string> => {\n const iconMap = {} as Record<T, string>;\n const domSanitizer = inject(DomSanitizer);\n for (const [key, rawContent] of Object.entries<string>(icons)) {\n const registeredIcon = registeredIcons.get(key) ?? {\n content: parseDataSvgIcon(rawContent, domSanitizer),\n referenceCount: 0\n };\n registeredIcon.referenceCount++;\n registeredIcons.set(key, registeredIcon);\n iconMap[key as T] = key;\n }\n\n // Delete registered Icons after Component is destroyed to optimize memory usage.\n // WeakMap must not be used, as the Icon can only be removed on component destruction.\n // When using a WeakMap it would also get destroyed if it is not referenced, but the component may use it later again.\n inject(DestroyRef).onDestroy(() => {\n for (const key of Object.keys(icons)) {\n const registeredIcon = registeredIcons.get(key);\n if (registeredIcon!.referenceCount === 1) {\n registeredIcons.delete(key);\n } else {\n registeredIcon!.referenceCount--;\n }\n }\n });\n\n return iconMap;\n};\n\nconst getIcon = (key: string): SafeHtml | undefined => registeredIcons.get(key)?.content;\n\n@Injectable({ providedIn: 'root' })\nexport class IconService {\n private themeService = inject(SiThemeService);\n\n getIcon(name: string): SafeHtml | undefined {\n const camelCaseName = this.kebabToCamelCase(name);\n return this.themeService.themeIcons()[camelCaseName] ?? getIcon(camelCaseName);\n }\n\n private kebabToCamelCase(str: string): string {\n return str.replace(/-./g, match => match.charAt(1).toUpperCase());\n }\n}\n","/**\n * Copyright Siemens 2016 - 2025.\n * SPDX-License-Identifier: MIT\n */\nimport {\n ChangeDetectionStrategy,\n Component,\n computed,\n inject,\n InjectionToken,\n input,\n Provider\n} from '@angular/core';\n\nimport { IconService } from './si-icons';\n\n/**\n * Global configuration for icons.\n *\n * @experimental\n */\nexport interface IconConfig {\n /**\n * If true, the si-icon-next component will always render the icon font instead of the svg.\n *\n * @defaultValue true\n */\n disableSvgIcons?: boolean;\n}\n\nconst ICON_CONFIG = new InjectionToken<IconConfig>('ICON_CONFIG', {\n providedIn: 'root',\n factory: () => ({ disableSvgIcons: true })\n});\n\n/**\n * Configure how Element handles icons. Provide only once in your global configuration.\n *\n * @experimental\n */\nexport const provideIconConfig = (config: IconConfig): Provider => ({\n provide: ICON_CONFIG,\n useValue: config\n});\n\n/**\n * Component to render a font or SVG icon depending on the configuration.\n * If no SVG icon is found, the component will fall back to render the icon-font.\n * In that case, an application must ensure that the icon font is loaded.\n * This component will only attach the respective class.\n *\n * The content of this component is hidden in the a11y tree.\n * If needed, the consumer must set proper labels.\n *\n * @experimental\n */\n@Component({\n selector: 'si-icon-next',\n template: ``,\n styles: `\n :host {\n display: inline-block;\n font-weight: normal;\n vertical-align: middle;\n line-height: 1;\n\n &.svg-icon ::ng-deep svg {\n display: block;\n block-size: 1em;\n fill: currentColor;\n }\n }\n `,\n host: {\n '[class]': 'svgIcon() ? \"svg-icon\" : fontIcon()',\n '[innerHTML]': 'svgIcon()',\n // TODO: remove and actually hide the icon content. But wait until: https://github.com/microsoft/playwright/issues/35737 and https://github.com/dequelabs/axe-core/issues/4763 are fixed.\n 'aria-hidden': 'true'\n },\n changeDetection: ChangeDetectionStrategy.OnPush\n})\nexport class SiIconNextComponent {\n /**\n * Define which icon should be rendered.\n * Provide using:\n * - value of the icon map provided by `addIcons`\n * - (not recommended): plain string in kebab-case or camelCase\n *\n * @example\n * ```ts\n * import { elementUser } from '@simpl/element-icons/ionic';\n *\n * @Component({template: `\n * <si-icon-next [icon]=\"icons.elementUser\" />\n * <si-icon-next icon=\"element-user\" />\n * <si-icon-next icon=\"elementUser\" />\n *\n * `})\n * class MyComponent {\n * icons = addIcons(elementUser);\n * }\n * ```\n */\n readonly icon = input.required<string>();\n\n private readonly config = inject(ICON_CONFIG);\n private readonly iconService = inject(IconService);\n\n protected readonly svgIcon = computed(() =>\n this.config.disableSvgIcons ? undefined : this.iconService.getIcon(this.icon())\n );\n\n /** Icon class, which is ensured to be kebab-case. */\n protected readonly fontIcon = computed(() =>\n this.svgIcon() ? undefined : this.camelToKebabCase(this.icon())\n );\n\n private camelToKebabCase(str: string): string {\n return str\n .replace(/([a-z])([A-Z0-9])/g, '$1-$2')\n .replace(/([0-9])([A-Z])/g, '$1-$2')\n .toLowerCase();\n }\n}\n","/**\n * Copyright Siemens 2016 - 2025.\n * SPDX-License-Identifier: MIT\n */\nexport const elementDown2 =\n \"data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><path d='M352.79 203.21a12.45 12.45 0 0 1 1.44 15.86l-1.44 1.72-88 88a12.45 12.45 0 0 1-15.86 1.44l-1.72-1.44-88-88a12.43 12.43 0 0 1 15.86-19l1.72 1.44L256 282.42l79.21-79.21a12.45 12.45 0 0 1 15.86-1.44Z' data-name='Arrow/Right-3'/></svg>\";\nexport const elementCancel =\n \"data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><path d='m273 256 87.52-87.51a12 12 0 0 0-17-17L256 239l-87.51-87.52a12 12 0 0 0-17 17L239 256l-87.52 87.51a12 12 0 0 0 17 17L256 273l87.51 87.52a12 12 0 0 0 17-17Z'/></svg>\";\nexport const elementFavoritesFilled =\n \"data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><path d='M427.42 216.46a12 12 0 0 0-9.68-8.17L313.41 193l-46.65-94.47a12 12 0 0 0-21.52 0L198.59 193 94.26 208.29a12 12 0 0 0-6.63 20.47l75.48 73.51-17.82 103.86a12 12 0 0 0 17.42 12.65L256 369.72l93.29 49.06a12 12 0 0 0 17.42-12.65l-17.82-103.86 75.48-73.51a12 12 0 0 0 3.05-12.3Z'/></svg>\";\nexport const elementFavorites =\n \"data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><path d='M427.42 216.46a12 12 0 0 0-9.68-8.17L313.41 193l-46.65-94.47a12 12 0 0 0-21.52 0L198.59 193 94.26 208.29a12 12 0 0 0-6.63 20.47l75.48 73.51-17.82 103.86a12 12 0 0 0 17.42 12.65L256 369.72l93.29 49.06a12 12 0 0 0 17.42-12.65l-17.82-103.86 75.48-73.51a12 12 0 0 0 3.05-12.3Zm-99.79 73a12 12 0 0 0-3.46 10.63l14.77 86.11-77.35-40.68a12 12 0 0 0-11.18 0l-77.35 40.68 14.77-86.11a12 12 0 0 0-3.46-10.63l-62.59-61 86.52-12.65a12 12 0 0 0 9-6.56L256 131l38.68 78.36a12 12 0 0 0 9 6.56l86.52 12.65Z'/></svg>\";\nexport const elementExport =\n \"data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><path d='M364 248a12 12 0 0 0-12 12v96a20 20 0 0 1-20 20H156a20 20 0 0 1-20-20V180a20 20 0 0 1 20-20h96a12 12 0 0 0 0-24h-96a44.05 44.05 0 0 0-44 44v176a44.05 44.05 0 0 0 44 44h176a44.05 44.05 0 0 0 44-44v-96a12 12 0 0 0-12-12Z'/><path d='M423.94 98.82c0-.19-.05-.37-.08-.55s-.05-.41-.09-.61-.1-.41-.15-.61a4.58 4.58 0 0 0-.14-.53c-.06-.2-.13-.39-.2-.58s-.12-.36-.19-.53-.16-.35-.25-.53-.16-.36-.26-.54-.19-.32-.29-.48-.2-.35-.31-.52-.25-.35-.38-.52l-.32-.43c-.24-.29-.5-.58-.77-.85s-.56-.53-.85-.77l-.44-.33c-.17-.12-.33-.25-.51-.37l-.53-.32-.47-.28c-.18-.1-.37-.18-.56-.27l-.51-.24-.55-.2-.55-.19c-.19-.06-.38-.1-.57-.15l-.57-.14-.67-.1-.49-.07q-.6-.06-1.2-.06H316a12 12 0 0 0 0 24h67L227.51 267.51a12 12 0 0 0 17 17L400 129v67a12 12 0 0 0 24 0v-96a10.88 10.88 0 0 0-.06-1.18Z'/></svg>\";\nexport const elementThumbnails =\n \"data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><circle cx='144' cy='144' r='24'/><circle cx='368' cy='144' r='24'/><circle cx='256' cy='144' r='24'/><circle cx='144' cy='368' r='24'/><circle cx='368' cy='368' r='24'/><circle cx='256' cy='368' r='24'/><circle cx='144' cy='256' r='24'/><circle cx='368' cy='256' r='24'/><circle cx='256' cy='256' r='24'/></svg>\";\nexport const elementOptionsVertical =\n \"data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><path d='M284 256a28 28 0 1 1-28-28 28 28 0 0 1 28 28ZM284 144a28 28 0 1 1-28-28 28 28 0 0 1 28 28ZM284 368a28 28 0 1 1-28-28 28 28 0 0 1 28 28Z'/></svg>\";\nexport const elementMenu =\n \"data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 512 512'><path d='M400 244H112a12 12 0 0 0 0 24h288a12 12 0 0 0 0-24ZM400 148H112a12 12 0 0 0 0 24h288a12 12 0 0 0 0-24ZM400 340H112a12 12 0 0 0 0 24h288a12 12 0 0 0 0-24Z'/></svg>\";\n","/**\n * Copyright Siemens 2016 - 2025.\n * SPDX-License-Identifier: MIT\n */\nexport * from './si-icon.module';\nexport { addIcons } from './si-icons';\nexport * from './si-icon-next.component';\nexport * from './si-icon.component';\nexport * from './element-icons';\n","/**\n * Generated bundle index. Do not edit.\n */\n\nexport * from './index';\n"],"names":[],"mappings":";;;;;;;;AAAA;;;AAGG;MAYU,eAAe,CAAA;;IAEjB,IAAI,GAAG,KAAK,EAAU;;IAEtB,KAAK,GAAG,KAAK,EAAU;;IAEvB,WAAW,GAAG,KAAK,EAAU;;IAE7B,YAAY,GAAG,KAAK,EAAU;;IAE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A,IAAA,EAAA,MAAA,EAAA,CAAA,+JAAA,CAAA,EAAA,eAAA,EAAA,EAAA,CAAA,uBAAA,CAAA,MAAA,EAAA,CAAA;;2FAuBD,mBAAmB,EAAA,UAAA,EAAA,CAAA;kBAzB/B,SAAS;+BACE,cAAc,EAAA,QAAA,EACd,EAAE,EAeN,IAAA,EAAA;AACJ,wBAAA,SAAS,EAAE,qCAAqC;AAChD,wBAAA,aAAa,EAAE,WAAW;;AAE1B,wBAAA,aAAa,EAAE;qBAChB,EACgB,eAAA,EAAA,uBAAuB,CAAC,MAAM,EAAA,MAAA,EAAA,CAAA,+JAAA,CAAA,EAAA;;;AC/EjD;;;AAGG;AACI,MAAM,YAAY,GACvB;AACK,MAAM,aAAa,GACxB;AACK,MAAM,sBAAsB,GACjC;AACK,MAAM,gBAAgB,GAC3B;AACK,MAAM,aAAa,GACxB;AACK,MAAM,iBAAiB,GAC5B;AACK,MAAM,sBAAsB,GACjC;AACK,MAAM,WAAW,GACtB;;ACnBF;;;AAGG;;ACHH;;AAEG;;;;"}
|
|
@@ -0,0 +1,233 @@
|
|
|
1
|
+
import * as i0 from '@angular/core';
|
|
2
|
+
import { Injectable, InjectionToken, input, booleanAttribute, output, signal, computed, inject, HostListener, Directive, NgModule } from '@angular/core';
|
|
3
|
+
import { Subject } from 'rxjs';
|
|
4
|
+
import { LocationStrategy } from '@angular/common';
|
|
5
|
+
import { Router, ActivatedRoute, NavigationEnd } from '@angular/router';
|
|
6
|
+
import { SiTranslateService } from '@siemens/element-translate-ng/translate';
|
|
7
|
+
import { takeUntil, filter } from 'rxjs/operators';
|
|
8
|
+
|
|
9
|
+
/**
|
|
10
|
+
* Copyright Siemens 2016 - 2025.
|
|
11
|
+
* SPDX-License-Identifier: MIT
|
|
12
|
+
*/
|
|
13
|
+
class SiLinkActionService {
|
|
14
|
+
actionSubject = new Subject();
|
|
15
|
+
/**
|
|
16
|
+
* Observable which emits the link and param to run the action on.
|
|
17
|
+
*
|
|
18
|
+
* @defaultValue this.actionSubject.asObservable()
|
|
19
|
+
*/
|
|
20
|
+
action$ = this.actionSubject.asObservable();
|
|
21
|
+
/**
|
|
22
|
+
* Emit a new link and param pair to run the action on.
|
|
23
|
+
*/
|
|
24
|
+
emit(link, param) {
|
|
25
|
+
this.actionSubject.next({ link, param });
|
|
26
|
+
}
|
|
27
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: SiLinkActionService, deps: [], target: i0.ɵɵFactoryTarget.Injectable });
|
|
28
|
+
static ɵprov = i0.ɵɵngDeclareInjectable({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: SiLinkActionService });
|
|
29
|
+
}
|
|
30
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: SiLinkActionService, decorators: [{
|
|
31
|
+
type: Injectable
|
|
32
|
+
}] });
|
|
33
|
+
|
|
34
|
+
/**
|
|
35
|
+
* Copyright Siemens 2016 - 2025.
|
|
36
|
+
* SPDX-License-Identifier: MIT
|
|
37
|
+
*/
|
|
38
|
+
/* eslint-disable @angular-eslint/no-conflicting-lifecycle */
|
|
39
|
+
const SI_LINK_DEFAULT_NAVIGATION_EXTRA = new InjectionToken('SI_LINK_DEFAULT_NAVIGATION_EXTRA');
|
|
40
|
+
class SiLinkDirective {
|
|
41
|
+
siLink = input();
|
|
42
|
+
siLinkDefaultTarget = input();
|
|
43
|
+
actionParam = input();
|
|
44
|
+
activeClass = input();
|
|
45
|
+
/** @defaultValue false */
|
|
46
|
+
exactMatch = input(false, { transform: booleanAttribute });
|
|
47
|
+
/**
|
|
48
|
+
* Type for `aria-current` to set if routerLink is active.
|
|
49
|
+
*/
|
|
50
|
+
ariaCurrent = input();
|
|
51
|
+
activeChange = output();
|
|
52
|
+
href = signal(undefined);
|
|
53
|
+
target = signal(undefined);
|
|
54
|
+
title = signal(undefined);
|
|
55
|
+
isAriaCurrent = computed(() => this.active() ? (this.ariaCurrent() ?? 'true') : undefined);
|
|
56
|
+
/** @defaultValue false */
|
|
57
|
+
active = signal(false);
|
|
58
|
+
destroyer = new Subject();
|
|
59
|
+
router = inject(Router, { optional: true });
|
|
60
|
+
activatedRoute = inject(ActivatedRoute, { optional: true });
|
|
61
|
+
locationStrategy = inject(LocationStrategy, { optional: true });
|
|
62
|
+
translateService = inject(SiTranslateService);
|
|
63
|
+
actionService = inject(SiLinkActionService, { optional: true });
|
|
64
|
+
defaultNavigationExtra = inject(SI_LINK_DEFAULT_NAVIGATION_EXTRA, { optional: true });
|
|
65
|
+
get urlTree() {
|
|
66
|
+
const link = this.siLink().link;
|
|
67
|
+
return this.router.createUrlTree(Array.isArray(link) ? link : [link], this.navigationExtras);
|
|
68
|
+
}
|
|
69
|
+
get navigationExtras() {
|
|
70
|
+
return {
|
|
71
|
+
relativeTo: this.activatedRoute,
|
|
72
|
+
preserveFragment: true,
|
|
73
|
+
queryParamsHandling: 'merge',
|
|
74
|
+
...this.defaultNavigationExtra,
|
|
75
|
+
...this.siLink().navigationExtras
|
|
76
|
+
};
|
|
77
|
+
}
|
|
78
|
+
ngOnDestroy() {
|
|
79
|
+
this.destroyer.next();
|
|
80
|
+
this.destroyer.complete();
|
|
81
|
+
}
|
|
82
|
+
ngOnChanges() {
|
|
83
|
+
const siLink = this.siLink();
|
|
84
|
+
if (!siLink) {
|
|
85
|
+
this.href.set(undefined);
|
|
86
|
+
return;
|
|
87
|
+
}
|
|
88
|
+
this.destroyer.next();
|
|
89
|
+
if (siLink.tooltip) {
|
|
90
|
+
this.translateService
|
|
91
|
+
.translateAsync(siLink.tooltip)
|
|
92
|
+
.pipe(takeUntil(this.destroyer))
|
|
93
|
+
.subscribe(text => this.title.set(text));
|
|
94
|
+
}
|
|
95
|
+
if (siLink.action) {
|
|
96
|
+
this.href.set('');
|
|
97
|
+
}
|
|
98
|
+
else if (siLink.link) {
|
|
99
|
+
this.subscribeRouter();
|
|
100
|
+
}
|
|
101
|
+
else if (siLink.href) {
|
|
102
|
+
this.href.set(siLink.href);
|
|
103
|
+
this.target.set(siLink.target ?? this.siLinkDefaultTarget());
|
|
104
|
+
}
|
|
105
|
+
else {
|
|
106
|
+
// In case the siLink has no link, href or action,
|
|
107
|
+
// we remove the href to avoid the mouse pointer.
|
|
108
|
+
this.href.set(undefined);
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
ngDoCheck() {
|
|
112
|
+
// this deep-checks if isActive has changed. It then updates the internal state and emits the event
|
|
113
|
+
// to be symmetric with the router-link case. queueMicroTask avoids "Expression has changed after it was checked" errors
|
|
114
|
+
const siLink = this.siLink();
|
|
115
|
+
if (siLink &&
|
|
116
|
+
!siLink.link &&
|
|
117
|
+
siLink.isActive !== undefined &&
|
|
118
|
+
this.active() !== siLink.isActive) {
|
|
119
|
+
this.active.set(siLink.isActive);
|
|
120
|
+
queueMicrotask(() => {
|
|
121
|
+
this.activeChange.emit(this.active());
|
|
122
|
+
});
|
|
123
|
+
}
|
|
124
|
+
}
|
|
125
|
+
subscribeRouter() {
|
|
126
|
+
if (!this.router || !this.activatedRoute) {
|
|
127
|
+
return;
|
|
128
|
+
}
|
|
129
|
+
// Initial check
|
|
130
|
+
this.updateActiveByRouter();
|
|
131
|
+
this.router.events
|
|
132
|
+
.pipe(takeUntil(this.destroyer), filter(e => e instanceof NavigationEnd))
|
|
133
|
+
.subscribe(() => this.updateActiveByRouter());
|
|
134
|
+
}
|
|
135
|
+
updateActiveByRouter() {
|
|
136
|
+
const urlTree = this.urlTree;
|
|
137
|
+
this.active.set(this.siLink().isActive ??
|
|
138
|
+
this.router.isActive(urlTree, this.exactMatch()
|
|
139
|
+
? {
|
|
140
|
+
queryParams: 'exact',
|
|
141
|
+
matrixParams: 'exact',
|
|
142
|
+
paths: 'exact',
|
|
143
|
+
fragment: 'exact'
|
|
144
|
+
}
|
|
145
|
+
: {
|
|
146
|
+
paths: 'subset',
|
|
147
|
+
queryParams: 'subset',
|
|
148
|
+
fragment: 'ignored',
|
|
149
|
+
matrixParams: 'ignored'
|
|
150
|
+
}));
|
|
151
|
+
this.href.set(this.locationStrategy.prepareExternalUrl(this.router.serializeUrl(urlTree)));
|
|
152
|
+
}
|
|
153
|
+
onClick(event) {
|
|
154
|
+
const siLink = this.siLink();
|
|
155
|
+
if (siLink?.action) {
|
|
156
|
+
event.preventDefault();
|
|
157
|
+
const actionParam = this.actionParam();
|
|
158
|
+
if (typeof siLink.action === 'string') {
|
|
159
|
+
this.actionService?.emit(siLink, this.actionParam());
|
|
160
|
+
}
|
|
161
|
+
else if (actionParam === undefined) {
|
|
162
|
+
siLink.action();
|
|
163
|
+
}
|
|
164
|
+
else {
|
|
165
|
+
siLink.action(actionParam);
|
|
166
|
+
}
|
|
167
|
+
return;
|
|
168
|
+
}
|
|
169
|
+
// ignore regular links, allow user to open links in new tab or window
|
|
170
|
+
if (!siLink ||
|
|
171
|
+
siLink.href ||
|
|
172
|
+
event.button > 0 ||
|
|
173
|
+
event.ctrlKey ||
|
|
174
|
+
event.metaKey ||
|
|
175
|
+
event.shiftKey) {
|
|
176
|
+
return;
|
|
177
|
+
}
|
|
178
|
+
event.preventDefault();
|
|
179
|
+
// We have links without any action, href or link. For example grouping navbar items that hold a
|
|
180
|
+
// dropdown with links. That is why we need to check if the link property is set.
|
|
181
|
+
if (siLink.link && this.router) {
|
|
182
|
+
this.router.navigateByUrl(this.urlTree, this.navigationExtras);
|
|
183
|
+
}
|
|
184
|
+
}
|
|
185
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: SiLinkDirective, deps: [], target: i0.ɵɵFactoryTarget.Directive });
|
|
186
|
+
static ɵdir = i0.ɵɵngDeclareDirective({ minVersion: "17.1.0", version: "19.0.6", type: SiLinkDirective, isStandalone: true, selector: "[siLink]", inputs: { siLink: { classPropertyName: "siLink", publicName: "siLink", isSignal: true, isRequired: false, transformFunction: null }, siLinkDefaultTarget: { classPropertyName: "siLinkDefaultTarget", publicName: "siLinkDefaultTarget", isSignal: true, isRequired: false, transformFunction: null }, actionParam: { classPropertyName: "actionParam", publicName: "actionParam", isSignal: true, isRequired: false, transformFunction: null }, activeClass: { classPropertyName: "activeClass", publicName: "activeClass", isSignal: true, isRequired: false, transformFunction: null }, exactMatch: { classPropertyName: "exactMatch", publicName: "exactMatch", isSignal: true, isRequired: false, transformFunction: null }, ariaCurrent: { classPropertyName: "ariaCurrent", publicName: "ariaCurrent", isSignal: true, isRequired: false, transformFunction: null } }, outputs: { activeChange: "activeChange" }, host: { listeners: { "click": "onClick($event)" }, properties: { "attr.href": "href()", "attr.target": "target()", "attr.title": "title()", "attr.aria-current": "isAriaCurrent()", "class": "active() ? activeClass() : null" } }, exportAs: ["siLink"], usesOnChanges: true, ngImport: i0 });
|
|
187
|
+
}
|
|
188
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: SiLinkDirective, decorators: [{
|
|
189
|
+
type: Directive,
|
|
190
|
+
args: [{
|
|
191
|
+
selector: '[siLink]',
|
|
192
|
+
exportAs: 'siLink',
|
|
193
|
+
host: {
|
|
194
|
+
'[attr.href]': 'href()',
|
|
195
|
+
'[attr.target]': 'target()',
|
|
196
|
+
'[attr.title]': 'title()',
|
|
197
|
+
'[attr.aria-current]': 'isAriaCurrent()',
|
|
198
|
+
'[class]': 'active() ? activeClass() : null'
|
|
199
|
+
}
|
|
200
|
+
}]
|
|
201
|
+
}], propDecorators: { onClick: [{
|
|
202
|
+
type: HostListener,
|
|
203
|
+
args: ['click', ['$event']]
|
|
204
|
+
}] } });
|
|
205
|
+
|
|
206
|
+
/**
|
|
207
|
+
* Copyright Siemens 2016 - 2025.
|
|
208
|
+
* SPDX-License-Identifier: MIT
|
|
209
|
+
*/
|
|
210
|
+
class SiLinkModule {
|
|
211
|
+
static ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: SiLinkModule, deps: [], target: i0.ɵɵFactoryTarget.NgModule });
|
|
212
|
+
static ɵmod = i0.ɵɵngDeclareNgModule({ minVersion: "14.0.0", version: "19.0.6", ngImport: i0, type: SiLinkModule, imports: [SiLinkDirective], exports: [SiLinkDirective] });
|
|
213
|
+
static ɵinj = i0.ɵɵngDeclareInjector({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: SiLinkModule });
|
|
214
|
+
}
|
|
215
|
+
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.0.6", ngImport: i0, type: SiLinkModule, decorators: [{
|
|
216
|
+
type: NgModule,
|
|
217
|
+
args: [{
|
|
218
|
+
imports: [SiLinkDirective],
|
|
219
|
+
exports: [SiLinkDirective]
|
|
220
|
+
}]
|
|
221
|
+
}] });
|
|
222
|
+
|
|
223
|
+
/**
|
|
224
|
+
* Copyright Siemens 2016 - 2025.
|
|
225
|
+
* SPDX-License-Identifier: MIT
|
|
226
|
+
*/
|
|
227
|
+
|
|
228
|
+
/**
|
|
229
|
+
* Generated bundle index. Do not edit.
|
|
230
|
+
*/
|
|
231
|
+
|
|
232
|
+
export { SI_LINK_DEFAULT_NAVIGATION_EXTRA, SiLinkActionService, SiLinkDirective, SiLinkModule };
|
|
233
|
+
//# sourceMappingURL=siemens-element-ng-link.mjs.map
|