@leanix/components 0.4.540 → 0.4.541

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.
@@ -1,10 +1,10 @@
1
1
  import * as i0 from '@angular/core';
2
- import { InjectionToken, Input, Component, signal, ChangeDetectionStrategy, HostBinding, inject, input, computed, EventEmitter, HostListener, Output, Injectable, ElementRef, ViewChild, Inject, model, Directive, Optional, Pipe, NgModule, afterRenderEffect, ContentChildren, DestroyRef, ChangeDetectorRef, effect, ContentChild, ViewChildren, forwardRef, TemplateRef, viewChild, booleanAttribute, SecurityContext, Self, Host } from '@angular/core';
2
+ import { InjectionToken, Input, Component, signal, ChangeDetectionStrategy, HostBinding, inject, input, computed, EventEmitter, HostListener, Output, Injectable, ElementRef, ViewChild, Inject, model, Directive, Optional, Pipe, NgModule, DestroyRef, ChangeDetectorRef, effect, ContentChild, afterRenderEffect, ContentChildren, ViewChildren, forwardRef, TemplateRef, viewChild, booleanAttribute, SecurityContext, Self, Host } from '@angular/core';
3
3
  import * as i1 from '@ngx-translate/core';
4
4
  import { TranslatePipe, TranslateModule } from '@ngx-translate/core';
5
5
  import * as i1$6 from '@angular/common';
6
6
  import { NgTemplateOutlet, NgClass, AsyncPipe, NgIf, NgFor, UpperCasePipe, NgSwitch, NgSwitchCase, CommonModule, DecimalPipe, formatDate } from '@angular/common';
7
- import { toSignal, toObservable, takeUntilDestroyed } from '@angular/core/rxjs-interop';
7
+ import { toSignal, takeUntilDestroyed, toObservable } from '@angular/core/rxjs-interop';
8
8
  import { IconComponent as IconComponent$1 } from '@ui5/webcomponents-ngx/main/icon';
9
9
  import * as i5 from 'rxjs';
10
10
  import { BehaviorSubject, of, timer, Observable, Subject, combineLatest, merge, concat, fromEvent, ReplaySubject, map as map$1, switchMap as switchMap$1 } from 'rxjs';
@@ -2826,6 +2826,43 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImpor
2826
2826
  args: [{ selector: 'lx-token', standalone: true, changeDetection: ChangeDetectionStrategy.OnPush, template: "<ng-content />\n" }]
2827
2827
  }], ctorParameters: () => [{ type: i0.ElementRef }] });
2828
2828
 
2829
+ class TokenizerOverflowPopoverComponent {
2830
+ constructor() {
2831
+ this.destroyRef = inject(DestroyRef);
2832
+ this.startIndex = signal(0);
2833
+ this.changeDetectorRef = inject(ChangeDetectorRef);
2834
+ this.tokenizer = input.required();
2835
+ this.horizontalAlign = input('after');
2836
+ this.verticalAlign = input('start');
2837
+ effect(() => {
2838
+ this.overflowClickSubscription?.unsubscribe();
2839
+ this.overflowClickSubscription = this.tokenizer()
2840
+ .overflowPlaceholderClick.pipe(takeUntilDestroyed(this.destroyRef))
2841
+ .subscribe(({ startIndex, counterElement }) => {
2842
+ this.startIndex.set(startIndex);
2843
+ this.popover.anchor = counterElement;
2844
+ this.popover.open();
2845
+ });
2846
+ });
2847
+ }
2848
+ closePopover() {
2849
+ this.popover.close();
2850
+ this.changeDetectorRef.detectChanges();
2851
+ }
2852
+ static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: TokenizerOverflowPopoverComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
2853
+ static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.6", type: TokenizerOverflowPopoverComponent, isStandalone: true, selector: "lx-tokenizer-overflow-popover", inputs: { tokenizer: { classPropertyName: "tokenizer", publicName: "tokenizer", isSignal: true, isRequired: true, transformFunction: null }, horizontalAlign: { classPropertyName: "horizontalAlign", publicName: "horizontalAlign", isSignal: true, isRequired: false, transformFunction: null }, verticalAlign: { classPropertyName: "verticalAlign", publicName: "verticalAlign", isSignal: true, isRequired: false, transformFunction: null } }, queries: [{ propertyName: "popoverTemplate", first: true, predicate: ["popoverTemplate"], descendants: true }], viewQueries: [{ propertyName: "popover", first: true, predicate: SatPopoverComponent, descendants: true }], ngImport: i0, template: "<sat-popover\n (backdropClicked)=\"closePopover()\"\n [hasBackdrop]=\"true\"\n [horizontalAlign]=\"horizontalAlign()\"\n [verticalAlign]=\"verticalAlign()\"\n openTransition=\"100ms\"\n closeTransition=\"100ms\"\n>\n @if (popoverTemplate) {\n <div\n class=\"tokenizerPopoverContentWrapper\"\n [class.before]=\"horizontalAlign() === 'before'\"\n [class.after]=\"horizontalAlign() === 'after'\"\n >\n <ng-container *ngTemplateOutlet=\"popoverTemplate; context: { $implicit: startIndex() }\" />\n </div>\n }\n</sat-popover>\n", styles: [".tokenizerPopoverContentWrapper{padding:16px;background:#fff;border-radius:4px;box-shadow:0 8px 14px #5261794d}.tokenizerPopoverContentWrapper.before{margin-right:10px}.tokenizerPopoverContentWrapper.after{margin-left:10px}\n"], dependencies: [{ kind: "ngmodule", type: SatPopoverModule }, { kind: "component", type: i1$3.SatPopoverComponent, selector: "sat-popover", inputs: ["anchor", "horizontalAlign", "xAlign", "verticalAlign", "yAlign", "forceAlignment", "lockAlignment", "autoFocus", "restoreFocus", "scrollStrategy", "hasBackdrop", "interactiveClose", "openTransition", "closeTransition", "openAnimationStartAtScale", "closeAnimationEndAtScale", "backdropClass", "panelClass"], outputs: ["opened", "closed", "afterOpen", "afterClose", "backdropClicked", "overlayKeydown"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
2854
+ }
2855
+ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: TokenizerOverflowPopoverComponent, decorators: [{
2856
+ type: Component,
2857
+ args: [{ selector: 'lx-tokenizer-overflow-popover', standalone: true, imports: [SatPopoverModule, NgTemplateOutlet], changeDetection: ChangeDetectionStrategy.OnPush, template: "<sat-popover\n (backdropClicked)=\"closePopover()\"\n [hasBackdrop]=\"true\"\n [horizontalAlign]=\"horizontalAlign()\"\n [verticalAlign]=\"verticalAlign()\"\n openTransition=\"100ms\"\n closeTransition=\"100ms\"\n>\n @if (popoverTemplate) {\n <div\n class=\"tokenizerPopoverContentWrapper\"\n [class.before]=\"horizontalAlign() === 'before'\"\n [class.after]=\"horizontalAlign() === 'after'\"\n >\n <ng-container *ngTemplateOutlet=\"popoverTemplate; context: { $implicit: startIndex() }\" />\n </div>\n }\n</sat-popover>\n", styles: [".tokenizerPopoverContentWrapper{padding:16px;background:#fff;border-radius:4px;box-shadow:0 8px 14px #5261794d}.tokenizerPopoverContentWrapper.before{margin-right:10px}.tokenizerPopoverContentWrapper.after{margin-left:10px}\n"] }]
2858
+ }], ctorParameters: () => [], propDecorators: { popoverTemplate: [{
2859
+ type: ContentChild,
2860
+ args: ['popoverTemplate']
2861
+ }], popover: [{
2862
+ type: ViewChild,
2863
+ args: [SatPopoverComponent]
2864
+ }] } });
2865
+
2829
2866
  /**
2830
2867
  * The tokenizer component (`lx-tokenizer`) is responsible for rendering a list of items into a container and hiding those that do not fit behind a placeholder. The items are represented as `lx-token`. Each `lx-token` allows to project any content into it, so anything can become a token. The tokenizer calculates how many items fit into the container (based on width), hiding those items that are overflowing and showing a overflow placeholder instead (e.g. "+4").
2831
2868
  *
@@ -2963,43 +3000,6 @@ i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImpor
2963
3000
  args: ['tokensContainer', { read: ElementRef }]
2964
3001
  }] } });
2965
3002
 
2966
- class TokenizerOverflowPopoverComponent {
2967
- constructor() {
2968
- this.destroyRef = inject(DestroyRef);
2969
- this.startIndex = signal(0);
2970
- this.changeDetectorRef = inject(ChangeDetectorRef);
2971
- this.tokenizer = input.required();
2972
- this.horizontalAlign = input('after');
2973
- this.verticalAlign = input('start');
2974
- effect(() => {
2975
- this.overflowClickSubscription?.unsubscribe();
2976
- this.overflowClickSubscription = this.tokenizer()
2977
- .overflowPlaceholderClick.pipe(takeUntilDestroyed(this.destroyRef))
2978
- .subscribe(({ startIndex, counterElement }) => {
2979
- this.startIndex.set(startIndex);
2980
- this.popover.anchor = counterElement;
2981
- this.popover.open();
2982
- });
2983
- });
2984
- }
2985
- closePopover() {
2986
- this.popover.close();
2987
- this.changeDetectorRef.detectChanges();
2988
- }
2989
- static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: TokenizerOverflowPopoverComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
2990
- static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "17.0.0", version: "19.2.6", type: TokenizerOverflowPopoverComponent, isStandalone: true, selector: "lx-tokenizer-overflow-popover", inputs: { tokenizer: { classPropertyName: "tokenizer", publicName: "tokenizer", isSignal: true, isRequired: true, transformFunction: null }, horizontalAlign: { classPropertyName: "horizontalAlign", publicName: "horizontalAlign", isSignal: true, isRequired: false, transformFunction: null }, verticalAlign: { classPropertyName: "verticalAlign", publicName: "verticalAlign", isSignal: true, isRequired: false, transformFunction: null } }, queries: [{ propertyName: "popoverTemplate", first: true, predicate: ["popoverTemplate"], descendants: true }], viewQueries: [{ propertyName: "popover", first: true, predicate: SatPopoverComponent, descendants: true }], ngImport: i0, template: "<sat-popover\n (backdropClicked)=\"closePopover()\"\n [hasBackdrop]=\"true\"\n [horizontalAlign]=\"horizontalAlign()\"\n [verticalAlign]=\"verticalAlign()\"\n openTransition=\"100ms\"\n closeTransition=\"100ms\"\n>\n @if (popoverTemplate) {\n <div\n class=\"tokenizerPopoverContentWrapper\"\n [class.before]=\"horizontalAlign() === 'before'\"\n [class.after]=\"horizontalAlign() === 'after'\"\n >\n <ng-container *ngTemplateOutlet=\"popoverTemplate; context: { $implicit: startIndex() }\" />\n </div>\n }\n</sat-popover>\n", styles: [".tokenizerPopoverContentWrapper{padding:16px;background:#fff;border-radius:4px;box-shadow:0 8px 14px #5261794d}.tokenizerPopoverContentWrapper.before{margin-right:10px}.tokenizerPopoverContentWrapper.after{margin-left:10px}\n"], dependencies: [{ kind: "ngmodule", type: SatPopoverModule }, { kind: "component", type: i1$3.SatPopoverComponent, selector: "sat-popover", inputs: ["anchor", "horizontalAlign", "xAlign", "verticalAlign", "yAlign", "forceAlignment", "lockAlignment", "autoFocus", "restoreFocus", "scrollStrategy", "hasBackdrop", "interactiveClose", "openTransition", "closeTransition", "openAnimationStartAtScale", "closeAnimationEndAtScale", "backdropClass", "panelClass"], outputs: ["opened", "closed", "afterOpen", "afterClose", "backdropClicked", "overlayKeydown"] }, { kind: "directive", type: NgTemplateOutlet, selector: "[ngTemplateOutlet]", inputs: ["ngTemplateOutletContext", "ngTemplateOutlet", "ngTemplateOutletInjector"] }], changeDetection: i0.ChangeDetectionStrategy.OnPush }); }
2991
- }
2992
- i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: TokenizerOverflowPopoverComponent, decorators: [{
2993
- type: Component,
2994
- args: [{ selector: 'lx-tokenizer-overflow-popover', standalone: true, imports: [TokenizerComponent, SatPopoverModule, NgTemplateOutlet], changeDetection: ChangeDetectionStrategy.OnPush, template: "<sat-popover\n (backdropClicked)=\"closePopover()\"\n [hasBackdrop]=\"true\"\n [horizontalAlign]=\"horizontalAlign()\"\n [verticalAlign]=\"verticalAlign()\"\n openTransition=\"100ms\"\n closeTransition=\"100ms\"\n>\n @if (popoverTemplate) {\n <div\n class=\"tokenizerPopoverContentWrapper\"\n [class.before]=\"horizontalAlign() === 'before'\"\n [class.after]=\"horizontalAlign() === 'after'\"\n >\n <ng-container *ngTemplateOutlet=\"popoverTemplate; context: { $implicit: startIndex() }\" />\n </div>\n }\n</sat-popover>\n", styles: [".tokenizerPopoverContentWrapper{padding:16px;background:#fff;border-radius:4px;box-shadow:0 8px 14px #5261794d}.tokenizerPopoverContentWrapper.before{margin-right:10px}.tokenizerPopoverContentWrapper.after{margin-left:10px}\n"] }]
2995
- }], ctorParameters: () => [], propDecorators: { popoverTemplate: [{
2996
- type: ContentChild,
2997
- args: ['popoverTemplate']
2998
- }], popover: [{
2999
- type: ViewChild,
3000
- args: [SatPopoverComponent]
3001
- }] } });
3002
-
3003
3003
  /**
3004
3004
  * Generates an SVG for the avatar initials
3005
3005
  * @param displayName The name of the user
@@ -3141,7 +3141,7 @@ class BasicDropdownItemComponent {
3141
3141
  }
3142
3142
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: BasicDropdownItemComponent, decorators: [{
3143
3143
  type: Component,
3144
- args: [{ selector: 'lx-basic-dropdown-item', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [NgClass, NgIf, HighlightTermPipe], template: "@if (optionLabelSuffix) {\n <div [class.boldLabel]=\"labelFontWeight === 'bold'\" class=\"optionLabel\">\n <div [innerHtml]=\"label | lxHighlightTerm: highlightTerm\"></div>\n <ng-content [select]=\"optionLabelSuffix\" />\n </div>\n} @else {\n <div [class.boldLabel]=\"labelFontWeight === 'bold'\" [innerHtml]=\"label | lxHighlightTerm: highlightTerm\"></div>\n}\n<div\n class=\"optionDescription\"\n [style.font-style]=\"descriptionFontStyle\"\n [ngClass]=\"{ maxTextLines: descriptionStyleOptions?.maxLines }\"\n [style.-webkit-line-clamp]=\"descriptionStyleOptions?.maxLines || 'inherit'\"\n [innerHtml]=\"description | lxHighlightTerm: (descriptionStyleOptions?.shouldHighlightTerm ? highlightTerm : undefined)\"\n></div>\n", styles: [":host{display:block;padding:2px 0}:host.hasDescription{padding:4px 0}.boldLabel{font-weight:700}.optionDescription{padding-top:2px;color:#61779d;font-size:var(--lxFontSmallSize, 12px)}.optionDescription.maxTextLines{overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:inherit;-webkit-box-orient:vertical}.optionLabel{display:flex;align-items:center;justify-content:space-between}\n"] }]
3144
+ args: [{ selector: 'lx-basic-dropdown-item', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [NgClass, HighlightTermPipe], template: "@if (optionLabelSuffix) {\n <div [class.boldLabel]=\"labelFontWeight === 'bold'\" class=\"optionLabel\">\n <div [innerHtml]=\"label | lxHighlightTerm: highlightTerm\"></div>\n <ng-content [select]=\"optionLabelSuffix\" />\n </div>\n} @else {\n <div [class.boldLabel]=\"labelFontWeight === 'bold'\" [innerHtml]=\"label | lxHighlightTerm: highlightTerm\"></div>\n}\n<div\n class=\"optionDescription\"\n [style.font-style]=\"descriptionFontStyle\"\n [ngClass]=\"{ maxTextLines: descriptionStyleOptions?.maxLines }\"\n [style.-webkit-line-clamp]=\"descriptionStyleOptions?.maxLines || 'inherit'\"\n [innerHtml]=\"description | lxHighlightTerm: (descriptionStyleOptions?.shouldHighlightTerm ? highlightTerm : undefined)\"\n></div>\n", styles: [":host{display:block;padding:2px 0}:host.hasDescription{padding:4px 0}.boldLabel{font-weight:700}.optionDescription{padding-top:2px;color:#61779d;font-size:var(--lxFontSmallSize, 12px)}.optionDescription.maxTextLines{overflow:hidden;text-overflow:ellipsis;display:-webkit-box;-webkit-line-clamp:inherit;-webkit-box-orient:vertical}.optionLabel{display:flex;align-items:center;justify-content:space-between}\n"] }]
3145
3145
  }], propDecorators: { label: [{
3146
3146
  type: Input
3147
3147
  }], description: [{
@@ -10307,7 +10307,7 @@ __decorate([
10307
10307
  ], TabGroupComponent.prototype, "tabsQueryList$", void 0);
10308
10308
  i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "19.2.6", ngImport: i0, type: TabGroupComponent, decorators: [{
10309
10309
  type: Component,
10310
- args: [{ selector: 'lx-tab-group', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [PortalModule, NgTemplateOutlet], template: "<ul\n #tabListElement\n class=\"tabs\"\n role=\"tablist\"\n (focusout)=\"onFocusOut($event)\"\n [attr.aria-owns]=\"tabIds.join(' ')\"\n [class.centered]=\"isCentered\"\n>\n <ng-content />\n</ul>\n\n<ng-template [cdkPortalOutlet]=\"activeTabPortal\" />\n", styles: [":host{--tab-group-padding-y: 0}.tabs{display:inline-block;list-style:none;border-bottom:solid 1px #cfd5df;width:100%;margin:0;padding:0 var(--tab-group-padding-y);text-align:left}.tabs.centered{text-align:center}\n"] }]
10310
+ args: [{ selector: 'lx-tab-group', changeDetection: ChangeDetectionStrategy.OnPush, standalone: true, imports: [PortalModule], template: "<ul\n #tabListElement\n class=\"tabs\"\n role=\"tablist\"\n (focusout)=\"onFocusOut($event)\"\n [attr.aria-owns]=\"tabIds.join(' ')\"\n [class.centered]=\"isCentered\"\n>\n <ng-content />\n</ul>\n\n<ng-template [cdkPortalOutlet]=\"activeTabPortal\" />\n", styles: [":host{--tab-group-padding-y: 0}.tabs{display:inline-block;list-style:none;border-bottom:solid 1px #cfd5df;width:100%;margin:0;padding:0 var(--tab-group-padding-y);text-align:left}.tabs.centered{text-align:center}\n"] }]
10311
10311
  }], ctorParameters: () => [{ type: i0.ChangeDetectorRef }], propDecorators: { isCentered: [{
10312
10312
  type: Input
10313
10313
  }], selectedIndex: [{